From 3bbef0f780fe9dc68e1676230afe56c9ea650170 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sat, 11 Apr 2020 16:06:55 +0100 Subject: [PATCH 02/34] Initial commit --- .gitignore | 4 + README.md | 106 +++++++++++++++++++++++ binding.gyp | 19 ++++ grammar.js | 216 ++++++++++++++++++++++++++++++++++++++++++++++ index.js | 9 ++ package-lock.json | 24 ++++++ package.json | 28 ++++++ src/scanner.cc | 103 ++++++++++++++++++++++ 8 files changed, 509 insertions(+) create mode 100644 .gitignore create mode 100644 README.md create mode 100644 binding.gyp create mode 100644 grammar.js create mode 100644 index.js create mode 100644 package-lock.json create mode 100644 package.json create mode 100644 src/scanner.cc diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000..3244d5a88 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +node_modules +bin +build +*.log diff --git a/README.md b/README.md new file mode 100644 index 000000000..1c1b7c51c --- /dev/null +++ b/README.md @@ -0,0 +1,106 @@ +# tree-sitter-janet + +## Status + +Subject to change, grammar still evolving. + +## Prerequisites + +* [emsdk](https://emscripten.org/docs/getting_started/downloads.html#installation-instructions) -- emscripten via homebrew seems to work for macos +* node >= 12 (nvm recommended) -- recently tested 12.9.1, 12,16,1 + +## Fine Print + +* The instructions below assume emsdk has been installed, but `emcc` (tool that can be used to compile to wasm) is not necessarily on one's `PATH`. If an appropriate `emcc` is on one's `PATH` (e.g. emscripten installed via homebrew), the emsdk steps (e.g. `source ~/src/emsdk/emsdk_env.sh`) below may be ignored. + +* `node-gyp` (tool for compiling native addon modules for Node.js) may fail on machines upgraded to macos Catalina. [This document](https://github.com/nodejs/node-gyp/blob/master/macOS_Catalina.md) may help cope with such a situation. + +## Initial Setup + +Suppose typical development sources are stored under `~/src`. + +``` +# clone repository +cd ~/src +git clone https://github.com/sogaiu/tree-sitter-janet +cd tree-sitter-janet + +# create / populate +# `node_modules` with dependencies +# `src` with tree-sitter .c goodness +# `build` +# `build/Release` and build `tree_sitter_janet_binding.node` +npm install + +# included in previous command +#npx tree-sitter generate +#npx node-gyp configure +#npx node-gyp rebuild +``` + +## Grammar Development + +Hack on grammar and interactively test. + +``` +# prepare emsdk (specifically emcc) for building .wasm +source ~/src/emsdk/emsdk_env.sh + +# edit grammar.js using some editor + +# rebuild tree-sitter stuff and invoke web-ui for interactive testing +npx tree-sitter generate && \ +npx node-gyp rebuild && \ +npx tree-sitter build-wasm && \ +npx tree-sitter web-ui + +# in appropriate browser window, paste code in left pane + +# examine results in right pane -- can even click on nodes + +# find errors and loop back to edit step above... +``` + +Parse individual files. + +``` +# create and populate sample code file for parsing named `sample.clj` + +# parse sample file +npx tree-sitter parse sample.clj + +# examine output similar to web-ui, but less convenient +``` + +## Measure Performance + +``` +# single measurement +npx tree-sitter parse --time sample.clj + +# mutliple measurements with `multitime` +multitime -n10 -s1 npx tree-sitter parse --time --quiet sample.clj +``` + +## Build .wasm + +Assuming emsdk is installed appropriately under `~/src/emsdk`. + +``` +# prepare emsdk (specifically emcc) for use +source ~/src/emsdk/emsdk_env.sh + +# create `tree-sitter-janet.wasm` +npx tree-sitter build-wasm +``` + +## Resources + +* [Guide to your first Tree-sitter grammar](https://gist.github.com/Aerijo/df27228d70c633e088b0591b8857eeef) +* [tree-sitter](http://tree-sitter.github.io/tree-sitter/) + +## Acknowledgments + +* Aerijo - Guide to your first Tree-sitter grammar +* bakpakin - janet +* maxbrunsfeld - tree-sitter and related diff --git a/binding.gyp b/binding.gyp new file mode 100644 index 000000000..53b526b6c --- /dev/null +++ b/binding.gyp @@ -0,0 +1,19 @@ +{ + "targets": [ + { + "target_name": "tree_sitter_janet_binding", + "include_dirs": [ + "@^_]/; +const SYM_CHAR = + /[0-9:a-zA-Z!$%&*+\-./:@^_]/; + +// strings +const STRING_DOUBLE_QUOTE_CONTENT = + repeat(choice(/[^\\"]/, + /\\(.|\n)/)); // thanks to tree-sitter-haskell + +module.exports = grammar({ + name: 'janet', + + extras: $ => + [/\s/, $.comment], + + externals: $ => [ + $.long_buffer, + $.long_string + ], + + rules: { + // THIS MUST BE FIRST -- even though this doesn't look like it matters + source_file: $ => + repeat($._form), + + comment: $ => + /#.*/, + + _form: $ => + choice($.boolean, + $.buffer, + $.keyword, + $.long_buffer, + $.long_string, + $.nil, + $.number, + $.string, + $.symbol, + // + $.array, + $.array_literal, + $.struct, + $.table, + $.tuple, + $.tuple_literal, + // + $.quasi_quote_form, + $.quote_form, + $.short_fn_form, + $.splice_form, + $.unquote_form), + + // simplest things + + boolean: $ => + choice('false', + 'true'), + + keyword: $ => + prec(2, token(seq(':', + repeat(SYM_CHAR)))), + + nil: $ => + 'nil', + + number: $ => + prec(5, choice($._dec, + $._hex, + $._radix)), + + _dec: $ => + token(seq(optional(SIGN), + choice(seq(repeat1(DIGIT), + repeat('_'), + optional('.'), + repeat('_'), + repeat(DIGIT), + repeat('_')), + seq(repeat(DIGIT), + repeat('_'), + optional('.'), + repeat('_'), + repeat1(DIGIT), + repeat('_'))), + optional(seq(choice('e', 'E'), + optional(SIGN), + repeat1(DIGIT))))), + + _hex: $ => + token(seq(optional(SIGN), + '0', + 'x', + choice(seq(repeat1(HEX_DIGIT), + repeat('_'), + optional('.'), + repeat('_'), + repeat(HEX_DIGIT), + repeat('_')), + seq(repeat(HEX_DIGIT), + repeat('_'), + optional('.'), + repeat('_'), + repeat1(HEX_DIGIT), + repeat('_'))))), + + _radix: $ => + token(seq(optional(SIGN), + seq(RADIX, + choice('r', 'R'), + ALPHA_NUM, + repeat(choice(repeat(ALPHA_NUM), + repeat('_'))), + optional(seq('&', + optional(SIGN), + repeat1(DIGIT)))))), + + string: $ => + token(seq('"', + STRING_DOUBLE_QUOTE_CONTENT, + '"')), + + buffer: $ => + token(seq('@"', + STRING_DOUBLE_QUOTE_CONTENT, + '"')), + + symbol: $ => + token(seq(SYM_CHAR_NO_DIGIT_NO_COLON, + repeat(SYM_CHAR))), + + // collection-ish things + + array: $ => + seq('@(', + repeat($._form), + ')'), + + array_literal: $ => + seq('@[', + repeat($._form), + ']'), + + struct: $ => + seq('{', + repeat($._form), + '}'), + + table: $ => + seq('@{', + repeat($._form), + '}'), + + tuple: $ => + seq('(', + repeat($._form), + ')'), + + tuple_literal: $ => + seq('[', + repeat($._form), + ']'), + + // macro-related + + quasi_quote_form: $ => + seq('~', + $._form), + + quote_form: $ => + seq("'", + $._form), + + // following all work at the repl.. + // |8, ||8, |||8, etc. + // |~(:x) + // |{:a 1} + // |[1 2] + // |"a" + // |:w + // |a-sym + // |@[8 9] + // |(= $ 1) + // XXX: |() doesn't work...but don't bother disallowing + short_fn_form: $ => + seq('|', + $._form), + + // XXX: ? + splice_form: $ => + seq(';', + $._form), + + unquote_form: $ => + seq(',', + $._form), + + } +}); diff --git a/index.js b/index.js new file mode 100644 index 000000000..2d8d767f3 --- /dev/null +++ b/index.js @@ -0,0 +1,9 @@ +try { + module.exports = require("./build/Release/tree_sitter_janet_binding"); +} catch (error) { + try { + module.exports = require("./build/Debug/tree_sitter_janet_binding"); + } catch (_) { + throw error + } +} diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 000000000..9edfb26d6 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,24 @@ +{ + "name": "tree-sitter-janet", + "version": "0.0.1", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "nan": { + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", + "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" + }, + "tree-sitter-cli": { + "version": "0.16.5", + "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.16.5.tgz", + "integrity": "sha512-758kas02AmfLdjsyIlsAMuSmsWpwNFu7ljTcffPxt2Lm00pV+0TW6xFjZCI9MYurB3ghTFjv/hLeRyb3IzJH4Q==", + "dev": true + }, + "web-tree-sitter": { + "version": "0.16.2", + "resolved": "https://registry.npmjs.org/web-tree-sitter/-/web-tree-sitter-0.16.2.tgz", + "integrity": "sha512-vxZHqu4nItCARmE+oGvTgjFBrMbhEuGI9PWYSgF4ET/nLuW3K11KQQIVhAsoGtYvTI9jdbjc/THj38P7nhYwow==" + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 000000000..d62a40024 --- /dev/null +++ b/package.json @@ -0,0 +1,28 @@ +{ + "name": "tree-sitter-janet", + "version": "0.0.1", + "description": "Janet grammar for tree-sitter", + "main": "index.js", + "scripts": { + "build": "npx tree-sitter generate && npx node-gyp build", + "fresh-build": "npx tree-sitter generate && npx node-gyp configure && npx node-gyp rebuild", + "install": "npx tree-sitter generate && npx node-gyp configure && npx node-gyp rebuild" + }, + "author": "", + "license": "", + "dependencies": { + "nan": "2.14.0", + "web-tree-sitter": "0.16.2" + }, + "devDependencies": { + "tree-sitter-cli": "0.16.5" + }, + "tree-sitter": [ + { + "scope": "source.janet", + "file-types": [ + "janet" + ] + } + ] +} diff --git a/src/scanner.cc b/src/scanner.cc new file mode 100644 index 000000000..b0c3bf92f --- /dev/null +++ b/src/scanner.cc @@ -0,0 +1,103 @@ +#include +#include +#include + +namespace { + +using std::wstring; +using std::iswspace; + +enum TokenType { + LONG_BUFFER, + LONG_STRING +}; + +struct Scanner { + bool scan(TSLexer *lexer, const bool *valid_symbols) { + while (iswspace(lexer->lookahead)) { + lexer->advance(lexer, true); + } + + if (lexer->lookahead == '@') { + lexer->result_symbol = LONG_BUFFER; + lexer->advance(lexer, false); + } else { + lexer->result_symbol = LONG_STRING; + } + + // long strings start with one or more backticks + // consume the first backtick + if (lexer->lookahead != '`') { + return false; + } + // getting here means a backtick was encountered + lexer->advance(lexer, false); + uint32_t n_backticks = 1; + + // arrive at a total number of backticks + for (;;) { + if (lexer->lookahead == 0) { + return false; + } + if (lexer->lookahead == '`') { + n_backticks++; + lexer->advance(lexer, false); + continue; + } else { + lexer->advance(lexer, false); + break; + } + } + // getting here means that the last character examined was NOT a + // backtick + + // keep looking until n_backticks are found + uint32_t cbt = 0; // consecutive backticks + for (;;) { + if (lexer->lookahead == 0) { + return false; + } + + if (lexer->lookahead == '`') { + cbt++; + if (cbt == n_backticks) { + lexer->advance(lexer, false); + return true; + } + } else { + cbt = 0; + } + + lexer->advance(lexer, false); + } + } +}; + +} + +extern "C" { + +void *tree_sitter_janet_external_scanner_create() { + return new Scanner(); +} + +bool tree_sitter_janet_external_scanner_scan(void *payload, TSLexer *lexer, + const bool *valid_symbols) { + Scanner *scanner = static_cast(payload); + return scanner->scan(lexer, valid_symbols); +} + +unsigned tree_sitter_janet_external_scanner_serialize(void *payload, char *buffer) { + return 0; +} + +void tree_sitter_janet_external_scanner_deserialize(void *payload, const char *buffer, + unsigned length) { +} + +void tree_sitter_janet_external_scanner_destroy(void *payload) { + Scanner *scanner = static_cast(payload); + delete scanner; +} + +} From b4a5ff839e8f8885dd4143aedacb3cdfe29e39a1 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 12 Apr 2020 04:03:02 +0100 Subject: [PATCH 03/34] Tweak index.js --- index.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/index.js b/index.js index 2d8d767f3..8e0ce96dc 100644 --- a/index.js +++ b/index.js @@ -7,3 +7,8 @@ try { throw error } } + +try { + module.exports.nodeTypeInfo = require("./src/node-types.json"); +} catch (_) {} + From 1e7ce98c1aebefca3f1ef7b3209ed2dfd65d1265 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 12 Apr 2020 04:03:44 +0100 Subject: [PATCH 04/34] Update status --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1c1b7c51c..04eb4a5a5 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,9 @@ ## Status -Subject to change, grammar still evolving. +~Subject to change, grammar still evolving.~ + +Coincidentally, it appears [another effort by GrayJack](https://github.com/GrayJack/tree-sitter-janet/) was started at about the same time, and that effort looks to be pretty decent. So this effort will be put on hold. ## Prerequisites @@ -103,4 +105,5 @@ npx tree-sitter build-wasm * Aerijo - Guide to your first Tree-sitter grammar * bakpakin - janet +* GrayJack - a better-looking attempt at tree-sitter-janet * maxbrunsfeld - tree-sitter and related From d6e4774f90b948e78bc3bc7e1e3ec1548e2c7c68 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 11 Jan 2021 20:11:22 +0900 Subject: [PATCH 05/34] Add src --- src/binding.cc | 28 + src/grammar.json | 1055 ++++++++++++++ src/node-types.json | 1197 +++++++++++++++ src/parser.c | 2988 ++++++++++++++++++++++++++++++++++++++ src/tree_sitter/parser.h | 223 +++ 5 files changed, 5491 insertions(+) create mode 100644 src/binding.cc create mode 100644 src/grammar.json create mode 100644 src/node-types.json create mode 100644 src/parser.c create mode 100644 src/tree_sitter/parser.h diff --git a/src/binding.cc b/src/binding.cc new file mode 100644 index 000000000..028f15811 --- /dev/null +++ b/src/binding.cc @@ -0,0 +1,28 @@ +#include "tree_sitter/parser.h" +#include +#include "nan.h" + +using namespace v8; + +extern "C" TSLanguage * tree_sitter_janet(); + +namespace { + +NAN_METHOD(New) {} + +void Init(Local exports, Local module) { + Local tpl = Nan::New(New); + tpl->SetClassName(Nan::New("Language").ToLocalChecked()); + tpl->InstanceTemplate()->SetInternalFieldCount(1); + + Local constructor = Nan::GetFunction(tpl).ToLocalChecked(); + Local instance = constructor->NewInstance(Nan::GetCurrentContext()).ToLocalChecked(); + Nan::SetInternalFieldPointer(instance, 0, tree_sitter_janet()); + + Nan::Set(instance, Nan::New("name").ToLocalChecked(), Nan::New("janet").ToLocalChecked()); + Nan::Set(module, Nan::New("exports").ToLocalChecked(), instance); +} + +NODE_MODULE(tree_sitter_janet_binding, Init) + +} // namespace diff --git a/src/grammar.json b/src/grammar.json new file mode 100644 index 000000000..de57ecf8f --- /dev/null +++ b/src/grammar.json @@ -0,0 +1,1055 @@ +{ + "name": "janet", + "rules": { + "source_file": { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + "comment": { + "type": "PATTERN", + "value": "#.*" + }, + "_form": { + "type": "CHOICE", + "members": [ + { + "type": "SYMBOL", + "name": "boolean" + }, + { + "type": "SYMBOL", + "name": "buffer" + }, + { + "type": "SYMBOL", + "name": "keyword" + }, + { + "type": "SYMBOL", + "name": "long_buffer" + }, + { + "type": "SYMBOL", + "name": "long_string" + }, + { + "type": "SYMBOL", + "name": "nil" + }, + { + "type": "SYMBOL", + "name": "number" + }, + { + "type": "SYMBOL", + "name": "string" + }, + { + "type": "SYMBOL", + "name": "symbol" + }, + { + "type": "SYMBOL", + "name": "array" + }, + { + "type": "SYMBOL", + "name": "array_literal" + }, + { + "type": "SYMBOL", + "name": "struct" + }, + { + "type": "SYMBOL", + "name": "table" + }, + { + "type": "SYMBOL", + "name": "tuple" + }, + { + "type": "SYMBOL", + "name": "tuple_literal" + }, + { + "type": "SYMBOL", + "name": "quasi_quote_form" + }, + { + "type": "SYMBOL", + "name": "quote_form" + }, + { + "type": "SYMBOL", + "name": "short_fn_form" + }, + { + "type": "SYMBOL", + "name": "splice_form" + }, + { + "type": "SYMBOL", + "name": "unquote_form" + } + ] + }, + "boolean": { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "false" + }, + { + "type": "STRING", + "value": "true" + } + ] + }, + "keyword": { + "type": "PREC", + "value": 2, + "content": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": ":" + }, + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + } + } + ] + } + } + }, + "nil": { + "type": "STRING", + "value": "nil" + }, + "number": { + "type": "PREC", + "value": 5, + "content": { + "type": "CHOICE", + "members": [ + { + "type": "SYMBOL", + "name": "_dec" + }, + { + "type": "SYMBOL", + "name": "_hex" + }, + { + "type": "SYMBOL", + "name": "_radix" + } + ] + } + }, + "_dec": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "-" + }, + { + "type": "STRING", + "value": "+" + } + ] + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "CHOICE", + "members": [ + { + "type": "SEQ", + "members": [ + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "." + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + } + ] + }, + { + "type": "SEQ", + "members": [ + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "." + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + } + ] + } + ] + }, + { + "type": "CHOICE", + "members": [ + { + "type": "SEQ", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "e" + }, + { + "type": "STRING", + "value": "E" + } + ] + }, + { + "type": "CHOICE", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "-" + }, + { + "type": "STRING", + "value": "+" + } + ] + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + } + ] + }, + { + "type": "BLANK" + } + ] + } + ] + } + }, + "_hex": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "-" + }, + { + "type": "STRING", + "value": "+" + } + ] + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "STRING", + "value": "0" + }, + { + "type": "STRING", + "value": "x" + }, + { + "type": "CHOICE", + "members": [ + { + "type": "SEQ", + "members": [ + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9A-F]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "." + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9A-F]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + } + ] + }, + { + "type": "SEQ", + "members": [ + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9A-F]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "." + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + }, + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9A-F]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + } + ] + } + ] + } + ] + } + }, + "_radix": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "-" + }, + { + "type": "STRING", + "value": "+" + } + ] + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "SEQ", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "2" + }, + { + "type": "STRING", + "value": "3" + }, + { + "type": "STRING", + "value": "4" + }, + { + "type": "STRING", + "value": "5" + }, + { + "type": "STRING", + "value": "6" + }, + { + "type": "STRING", + "value": "7" + }, + { + "type": "STRING", + "value": "8" + }, + { + "type": "STRING", + "value": "9" + }, + { + "type": "STRING", + "value": "10" + }, + { + "type": "STRING", + "value": "11" + }, + { + "type": "STRING", + "value": "12" + }, + { + "type": "STRING", + "value": "13" + }, + { + "type": "STRING", + "value": "14" + }, + { + "type": "STRING", + "value": "15" + }, + { + "type": "STRING", + "value": "16" + }, + { + "type": "STRING", + "value": "17" + }, + { + "type": "STRING", + "value": "18" + }, + { + "type": "STRING", + "value": "19" + }, + { + "type": "STRING", + "value": "20" + }, + { + "type": "STRING", + "value": "21" + }, + { + "type": "STRING", + "value": "22" + }, + { + "type": "STRING", + "value": "23" + }, + { + "type": "STRING", + "value": "24" + }, + { + "type": "STRING", + "value": "25" + }, + { + "type": "STRING", + "value": "26" + }, + { + "type": "STRING", + "value": "27" + }, + { + "type": "STRING", + "value": "28" + }, + { + "type": "STRING", + "value": "29" + }, + { + "type": "STRING", + "value": "30" + }, + { + "type": "STRING", + "value": "31" + }, + { + "type": "STRING", + "value": "32" + }, + { + "type": "STRING", + "value": "33" + }, + { + "type": "STRING", + "value": "34" + }, + { + "type": "STRING", + "value": "35" + }, + { + "type": "STRING", + "value": "36" + } + ] + }, + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "r" + }, + { + "type": "STRING", + "value": "R" + } + ] + }, + { + "type": "PATTERN", + "value": "[a-zA-Z0-9]" + }, + { + "type": "REPEAT", + "content": { + "type": "CHOICE", + "members": [ + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[a-zA-Z0-9]" + } + }, + { + "type": "REPEAT", + "content": { + "type": "STRING", + "value": "_" + } + } + ] + } + }, + { + "type": "CHOICE", + "members": [ + { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "&" + }, + { + "type": "CHOICE", + "members": [ + { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "-" + }, + { + "type": "STRING", + "value": "+" + } + ] + }, + { + "type": "BLANK" + } + ] + }, + { + "type": "REPEAT1", + "content": { + "type": "PATTERN", + "value": "[0-9]" + } + } + ] + }, + { + "type": "BLANK" + } + ] + } + ] + } + ] + } + }, + "string": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "\"" + }, + { + "type": "REPEAT", + "content": { + "type": "CHOICE", + "members": [ + { + "type": "PATTERN", + "value": "[^\\\\\"]" + }, + { + "type": "PATTERN", + "value": "\\\\(.|\\n)" + } + ] + } + }, + { + "type": "STRING", + "value": "\"" + } + ] + } + }, + "buffer": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "@\"" + }, + { + "type": "REPEAT", + "content": { + "type": "CHOICE", + "members": [ + { + "type": "PATTERN", + "value": "[^\\\\\"]" + }, + { + "type": "PATTERN", + "value": "\\\\(.|\\n)" + } + ] + } + }, + { + "type": "STRING", + "value": "\"" + } + ] + } + }, + "symbol": { + "type": "TOKEN", + "content": { + "type": "SEQ", + "members": [ + { + "type": "PATTERN", + "value": "[a-zA-Z!$%&*+\\-./:@^_]" + }, + { + "type": "REPEAT", + "content": { + "type": "PATTERN", + "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + } + } + ] + } + }, + "array": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "@(" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": ")" + } + ] + }, + "array_literal": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "@[" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": "]" + } + ] + }, + "struct": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "{" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": "}" + } + ] + }, + "table": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "@{" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": "}" + } + ] + }, + "tuple": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "(" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": ")" + } + ] + }, + "tuple_literal": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "[" + }, + { + "type": "REPEAT", + "content": { + "type": "SYMBOL", + "name": "_form" + } + }, + { + "type": "STRING", + "value": "]" + } + ] + }, + "quasi_quote_form": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "~" + }, + { + "type": "SYMBOL", + "name": "_form" + } + ] + }, + "quote_form": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "'" + }, + { + "type": "SYMBOL", + "name": "_form" + } + ] + }, + "short_fn_form": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "|" + }, + { + "type": "SYMBOL", + "name": "_form" + } + ] + }, + "splice_form": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": ";" + }, + { + "type": "SYMBOL", + "name": "_form" + } + ] + }, + "unquote_form": { + "type": "SEQ", + "members": [ + { + "type": "STRING", + "value": "," + }, + { + "type": "SYMBOL", + "name": "_form" + } + ] + } + }, + "extras": [ + { + "type": "PATTERN", + "value": "\\s" + }, + { + "type": "SYMBOL", + "name": "comment" + } + ], + "conflicts": [], + "externals": [ + { + "type": "SYMBOL", + "name": "long_buffer" + }, + { + "type": "SYMBOL", + "name": "long_string" + } + ], + "inline": [], + "supertypes": [] +} + diff --git a/src/node-types.json b/src/node-types.json new file mode 100644 index 000000000..3c9d52a7d --- /dev/null +++ b/src/node-types.json @@ -0,0 +1,1197 @@ +[ + { + "type": "array", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "array_literal", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "boolean", + "named": true, + "fields": {} + }, + { + "type": "keyword", + "named": true, + "fields": {} + }, + { + "type": "number", + "named": true, + "fields": {} + }, + { + "type": "quasi_quote_form", + "named": true, + "fields": {}, + "children": { + "multiple": false, + "required": true, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "quote_form", + "named": true, + "fields": {}, + "children": { + "multiple": false, + "required": true, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "short_fn_form", + "named": true, + "fields": {}, + "children": { + "multiple": false, + "required": true, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "source_file", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "splice_form", + "named": true, + "fields": {}, + "children": { + "multiple": false, + "required": true, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "struct", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "table", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "tuple", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "tuple_literal", + "named": true, + "fields": {}, + "children": { + "multiple": true, + "required": false, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "unquote_form", + "named": true, + "fields": {}, + "children": { + "multiple": false, + "required": true, + "types": [ + { + "type": "array", + "named": true + }, + { + "type": "array_literal", + "named": true + }, + { + "type": "boolean", + "named": true + }, + { + "type": "buffer", + "named": true + }, + { + "type": "keyword", + "named": true + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "number", + "named": true + }, + { + "type": "quasi_quote_form", + "named": true + }, + { + "type": "quote_form", + "named": true + }, + { + "type": "short_fn_form", + "named": true + }, + { + "type": "splice_form", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "struct", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "table", + "named": true + }, + { + "type": "tuple", + "named": true + }, + { + "type": "tuple_literal", + "named": true + }, + { + "type": "unquote_form", + "named": true + } + ] + } + }, + { + "type": "'", + "named": false + }, + { + "type": "(", + "named": false + }, + { + "type": ")", + "named": false + }, + { + "type": ",", + "named": false + }, + { + "type": ";", + "named": false + }, + { + "type": "@(", + "named": false + }, + { + "type": "@[", + "named": false + }, + { + "type": "@{", + "named": false + }, + { + "type": "[", + "named": false + }, + { + "type": "]", + "named": false + }, + { + "type": "buffer", + "named": true + }, + { + "type": "false", + "named": false + }, + { + "type": "long_buffer", + "named": true + }, + { + "type": "long_string", + "named": true + }, + { + "type": "nil", + "named": true + }, + { + "type": "string", + "named": true + }, + { + "type": "symbol", + "named": true + }, + { + "type": "true", + "named": false + }, + { + "type": "{", + "named": false + }, + { + "type": "|", + "named": false + }, + { + "type": "}", + "named": false + }, + { + "type": "~", + "named": false + } +] \ No newline at end of file diff --git a/src/parser.c b/src/parser.c new file mode 100644 index 000000000..69da9e2e8 --- /dev/null +++ b/src/parser.c @@ -0,0 +1,2988 @@ +#include + +#if defined(__GNUC__) || defined(__clang__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wmissing-field-initializers" +#endif + +#define LANGUAGE_VERSION 11 +#define STATE_COUNT 42 +#define LARGE_STATE_COUNT 41 +#define SYMBOL_COUNT 45 +#define ALIAS_COUNT 0 +#define TOKEN_COUNT 28 +#define EXTERNAL_TOKEN_COUNT 2 +#define FIELD_COUNT 0 +#define MAX_ALIAS_SEQUENCE_LENGTH 3 + +enum { + sym_comment = 1, + anon_sym_false = 2, + anon_sym_true = 3, + aux_sym_keyword_token1 = 4, + sym_nil = 5, + sym__dec = 6, + sym__hex = 7, + sym__radix = 8, + sym_string = 9, + sym_buffer = 10, + sym_symbol = 11, + anon_sym_AT_LPAREN = 12, + anon_sym_RPAREN = 13, + anon_sym_AT_LBRACK = 14, + anon_sym_RBRACK = 15, + anon_sym_LBRACE = 16, + anon_sym_RBRACE = 17, + anon_sym_AT_LBRACE = 18, + anon_sym_LPAREN = 19, + anon_sym_LBRACK = 20, + anon_sym_TILDE = 21, + anon_sym_SQUOTE = 22, + anon_sym_PIPE = 23, + anon_sym_SEMI = 24, + anon_sym_COMMA = 25, + sym_long_buffer = 26, + sym_long_string = 27, + sym_source_file = 28, + sym__form = 29, + sym_boolean = 30, + sym_keyword = 31, + sym_number = 32, + sym_array = 33, + sym_array_literal = 34, + sym_struct = 35, + sym_table = 36, + sym_tuple = 37, + sym_tuple_literal = 38, + sym_quasi_quote_form = 39, + sym_quote_form = 40, + sym_short_fn_form = 41, + sym_splice_form = 42, + sym_unquote_form = 43, + aux_sym_source_file_repeat1 = 44, +}; + +static const char *ts_symbol_names[] = { + [ts_builtin_sym_end] = "end", + [sym_comment] = "comment", + [anon_sym_false] = "false", + [anon_sym_true] = "true", + [aux_sym_keyword_token1] = "keyword_token1", + [sym_nil] = "nil", + [sym__dec] = "_dec", + [sym__hex] = "_hex", + [sym__radix] = "_radix", + [sym_string] = "string", + [sym_buffer] = "buffer", + [sym_symbol] = "symbol", + [anon_sym_AT_LPAREN] = "@(", + [anon_sym_RPAREN] = ")", + [anon_sym_AT_LBRACK] = "@[", + [anon_sym_RBRACK] = "]", + [anon_sym_LBRACE] = "{", + [anon_sym_RBRACE] = "}", + [anon_sym_AT_LBRACE] = "@{", + [anon_sym_LPAREN] = "(", + [anon_sym_LBRACK] = "[", + [anon_sym_TILDE] = "~", + [anon_sym_SQUOTE] = "'", + [anon_sym_PIPE] = "|", + [anon_sym_SEMI] = ";", + [anon_sym_COMMA] = ",", + [sym_long_buffer] = "long_buffer", + [sym_long_string] = "long_string", + [sym_source_file] = "source_file", + [sym__form] = "_form", + [sym_boolean] = "boolean", + [sym_keyword] = "keyword", + [sym_number] = "number", + [sym_array] = "array", + [sym_array_literal] = "array_literal", + [sym_struct] = "struct", + [sym_table] = "table", + [sym_tuple] = "tuple", + [sym_tuple_literal] = "tuple_literal", + [sym_quasi_quote_form] = "quasi_quote_form", + [sym_quote_form] = "quote_form", + [sym_short_fn_form] = "short_fn_form", + [sym_splice_form] = "splice_form", + [sym_unquote_form] = "unquote_form", + [aux_sym_source_file_repeat1] = "source_file_repeat1", +}; + +static TSSymbol ts_symbol_map[] = { + [ts_builtin_sym_end] = ts_builtin_sym_end, + [sym_comment] = sym_comment, + [anon_sym_false] = anon_sym_false, + [anon_sym_true] = anon_sym_true, + [aux_sym_keyword_token1] = aux_sym_keyword_token1, + [sym_nil] = sym_nil, + [sym__dec] = sym__dec, + [sym__hex] = sym__hex, + [sym__radix] = sym__radix, + [sym_string] = sym_string, + [sym_buffer] = sym_buffer, + [sym_symbol] = sym_symbol, + [anon_sym_AT_LPAREN] = anon_sym_AT_LPAREN, + [anon_sym_RPAREN] = anon_sym_RPAREN, + [anon_sym_AT_LBRACK] = anon_sym_AT_LBRACK, + [anon_sym_RBRACK] = anon_sym_RBRACK, + [anon_sym_LBRACE] = anon_sym_LBRACE, + [anon_sym_RBRACE] = anon_sym_RBRACE, + [anon_sym_AT_LBRACE] = anon_sym_AT_LBRACE, + [anon_sym_LPAREN] = anon_sym_LPAREN, + [anon_sym_LBRACK] = anon_sym_LBRACK, + [anon_sym_TILDE] = anon_sym_TILDE, + [anon_sym_SQUOTE] = anon_sym_SQUOTE, + [anon_sym_PIPE] = anon_sym_PIPE, + [anon_sym_SEMI] = anon_sym_SEMI, + [anon_sym_COMMA] = anon_sym_COMMA, + [sym_long_buffer] = sym_long_buffer, + [sym_long_string] = sym_long_string, + [sym_source_file] = sym_source_file, + [sym__form] = sym__form, + [sym_boolean] = sym_boolean, + [sym_keyword] = sym_keyword, + [sym_number] = sym_number, + [sym_array] = sym_array, + [sym_array_literal] = sym_array_literal, + [sym_struct] = sym_struct, + [sym_table] = sym_table, + [sym_tuple] = sym_tuple, + [sym_tuple_literal] = sym_tuple_literal, + [sym_quasi_quote_form] = sym_quasi_quote_form, + [sym_quote_form] = sym_quote_form, + [sym_short_fn_form] = sym_short_fn_form, + [sym_splice_form] = sym_splice_form, + [sym_unquote_form] = sym_unquote_form, + [aux_sym_source_file_repeat1] = aux_sym_source_file_repeat1, +}; + +static const TSSymbolMetadata ts_symbol_metadata[] = { + [ts_builtin_sym_end] = { + .visible = false, + .named = true, + }, + [sym_comment] = { + .visible = true, + .named = true, + }, + [anon_sym_false] = { + .visible = true, + .named = false, + }, + [anon_sym_true] = { + .visible = true, + .named = false, + }, + [aux_sym_keyword_token1] = { + .visible = false, + .named = false, + }, + [sym_nil] = { + .visible = true, + .named = true, + }, + [sym__dec] = { + .visible = false, + .named = true, + }, + [sym__hex] = { + .visible = false, + .named = true, + }, + [sym__radix] = { + .visible = false, + .named = true, + }, + [sym_string] = { + .visible = true, + .named = true, + }, + [sym_buffer] = { + .visible = true, + .named = true, + }, + [sym_symbol] = { + .visible = true, + .named = true, + }, + [anon_sym_AT_LPAREN] = { + .visible = true, + .named = false, + }, + [anon_sym_RPAREN] = { + .visible = true, + .named = false, + }, + [anon_sym_AT_LBRACK] = { + .visible = true, + .named = false, + }, + [anon_sym_RBRACK] = { + .visible = true, + .named = false, + }, + [anon_sym_LBRACE] = { + .visible = true, + .named = false, + }, + [anon_sym_RBRACE] = { + .visible = true, + .named = false, + }, + [anon_sym_AT_LBRACE] = { + .visible = true, + .named = false, + }, + [anon_sym_LPAREN] = { + .visible = true, + .named = false, + }, + [anon_sym_LBRACK] = { + .visible = true, + .named = false, + }, + [anon_sym_TILDE] = { + .visible = true, + .named = false, + }, + [anon_sym_SQUOTE] = { + .visible = true, + .named = false, + }, + [anon_sym_PIPE] = { + .visible = true, + .named = false, + }, + [anon_sym_SEMI] = { + .visible = true, + .named = false, + }, + [anon_sym_COMMA] = { + .visible = true, + .named = false, + }, + [sym_long_buffer] = { + .visible = true, + .named = true, + }, + [sym_long_string] = { + .visible = true, + .named = true, + }, + [sym_source_file] = { + .visible = true, + .named = true, + }, + [sym__form] = { + .visible = false, + .named = true, + }, + [sym_boolean] = { + .visible = true, + .named = true, + }, + [sym_keyword] = { + .visible = true, + .named = true, + }, + [sym_number] = { + .visible = true, + .named = true, + }, + [sym_array] = { + .visible = true, + .named = true, + }, + [sym_array_literal] = { + .visible = true, + .named = true, + }, + [sym_struct] = { + .visible = true, + .named = true, + }, + [sym_table] = { + .visible = true, + .named = true, + }, + [sym_tuple] = { + .visible = true, + .named = true, + }, + [sym_tuple_literal] = { + .visible = true, + .named = true, + }, + [sym_quasi_quote_form] = { + .visible = true, + .named = true, + }, + [sym_quote_form] = { + .visible = true, + .named = true, + }, + [sym_short_fn_form] = { + .visible = true, + .named = true, + }, + [sym_splice_form] = { + .visible = true, + .named = true, + }, + [sym_unquote_form] = { + .visible = true, + .named = true, + }, + [aux_sym_source_file_repeat1] = { + .visible = false, + .named = false, + }, +}; + +static TSSymbol ts_alias_sequences[1][MAX_ALIAS_SEQUENCE_LENGTH] = { + [0] = {0}, +}; + +static bool ts_lex(TSLexer *lexer, TSStateId state) { + START_LEXER(); + eof = lexer->eof(lexer); + switch (state) { + case 0: + if (eof) ADVANCE(13); + if (lookahead == '"') ADVANCE(1); + if (lookahead == '#') ADVANCE(14); + if (lookahead == '\'') ADVANCE(89); + if (lookahead == '(') ADVANCE(86); + if (lookahead == ')') ADVANCE(80); + if (lookahead == '+' || + lookahead == '-') ADVANCE(58); + if (lookahead == ',') ADVANCE(92); + if (lookahead == '.') ADVANCE(62); + if (lookahead == '0') ADVANCE(19); + if (lookahead == '1') ADVANCE(24); + if (lookahead == '2') ADVANCE(25); + if (lookahead == '3') ADVANCE(23); + if (('4' <= lookahead && lookahead <= '9')) ADVANCE(22); + if (lookahead == ':') ADVANCE(17); + if (lookahead == ';') ADVANCE(91); + if (lookahead == '@') ADVANCE(57); + if (lookahead == '[') ADVANCE(87); + if (lookahead == ']') ADVANCE(82); + if (lookahead == '_') ADVANCE(59); + if (lookahead == 'f') ADVANCE(64); + if (lookahead == 'n') ADVANCE(67); + if (lookahead == 't') ADVANCE(70); + if (lookahead == '{') ADVANCE(83); + if (lookahead == '|') ADVANCE(90); + if (lookahead == '}') ADVANCE(84); + if (lookahead == '~') ADVANCE(88); + if (lookahead == '\t' || + lookahead == '\n' || + lookahead == '\r' || + lookahead == ' ') SKIP(0) + if (('!' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 1: + if (lookahead == '"') ADVANCE(55); + if (lookahead == '\\') ADVANCE(11); + if (lookahead != 0) ADVANCE(1); + END_STATE(); + case 2: + if (lookahead == '"') ADVANCE(56); + if (lookahead == '\\') ADVANCE(12); + if (lookahead != 0) ADVANCE(2); + END_STATE(); + case 3: + if (lookahead == '.') ADVANCE(5); + if (lookahead == '_') ADVANCE(4); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(41); + END_STATE(); + case 4: + if (lookahead == '.') ADVANCE(5); + if (lookahead == '_') ADVANCE(4); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + END_STATE(); + case 5: + if (lookahead == '_') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + END_STATE(); + case 6: + if (lookahead == '+' || + lookahead == '-') ADVANCE(8); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + END_STATE(); + case 7: + if (lookahead == '+' || + lookahead == '-') ADVANCE(9); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + END_STATE(); + case 8: + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + END_STATE(); + case 9: + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + END_STATE(); + case 10: + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); + END_STATE(); + case 11: + if (lookahead != 0) ADVANCE(1); + END_STATE(); + case 12: + if (lookahead != 0) ADVANCE(2); + END_STATE(); + case 13: + ACCEPT_TOKEN(ts_builtin_sym_end); + END_STATE(); + case 14: + ACCEPT_TOKEN(sym_comment); + if (lookahead != 0 && + lookahead != '\n') ADVANCE(14); + END_STATE(); + case 15: + ACCEPT_TOKEN(anon_sym_false); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 16: + ACCEPT_TOKEN(anon_sym_true); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 17: + ACCEPT_TOKEN(aux_sym_keyword_token1); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(17); + END_STATE(); + case 18: + ACCEPT_TOKEN(sym_nil); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 19: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(20); + if (lookahead == 'x') ADVANCE(3); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + END_STATE(); + case 20: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(20); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); + END_STATE(); + case 21: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(20); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + END_STATE(); + case 22: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(10); + if (lookahead == '_') ADVANCE(20); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + END_STATE(); + case 23: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (('0' <= lookahead && lookahead <= '6')) ADVANCE(22); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(10); + if (lookahead == '_') ADVANCE(20); + if (('7' <= lookahead && lookahead <= '9')) ADVANCE(21); + END_STATE(); + case 24: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(22); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(20); + END_STATE(); + case 25: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(33); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(22); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(10); + if (lookahead == '_') ADVANCE(20); + END_STATE(); + case 26: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(27); + if (lookahead == 'x') ADVANCE(60); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 27: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(27); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 28: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(27); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 29: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(77); + if (lookahead == '_') ADVANCE(27); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 30: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (('0' <= lookahead && lookahead <= '6')) ADVANCE(29); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(77); + if (lookahead == '_') ADVANCE(27); + if (('7' <= lookahead && lookahead <= '9')) ADVANCE(28); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 31: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(29); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(27); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 32: + ACCEPT_TOKEN(sym__dec); + if (lookahead == '.') ADVANCE(38); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(29); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == 'R' || + lookahead == 'r') ADVANCE(77); + if (lookahead == '_') ADVANCE(27); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 33: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(33); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); + END_STATE(); + case 34: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(34); + END_STATE(); + case 35: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(34); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); + END_STATE(); + case 36: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(37); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 37: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(37); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 38: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(73); + if (lookahead == '_') ADVANCE(38); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 39: + ACCEPT_TOKEN(sym__dec); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + END_STATE(); + case 40: + ACCEPT_TOKEN(sym__dec); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 41: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '.') ADVANCE(49); + if (lookahead == '_') ADVANCE(42); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(41); + END_STATE(); + case 42: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '.') ADVANCE(49); + if (lookahead == '_') ADVANCE(42); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + END_STATE(); + case 43: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '.') ADVANCE(50); + if (lookahead == '_') ADVANCE(44); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(43); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 44: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '.') ADVANCE(50); + if (lookahead == '_') ADVANCE(44); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 45: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(45); + END_STATE(); + case 46: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(45); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + END_STATE(); + case 47: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(48); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 48: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(48); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 49: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(49); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + END_STATE(); + case 50: + ACCEPT_TOKEN(sym__hex); + if (lookahead == '_') ADVANCE(50); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 51: + ACCEPT_TOKEN(sym__radix); + if (lookahead == '&') ADVANCE(7); + if (lookahead == '_') ADVANCE(51); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); + END_STATE(); + case 52: + ACCEPT_TOKEN(sym__radix); + if (lookahead == '&') ADVANCE(74); + if (lookahead == '_') ADVANCE(52); + if (lookahead == '!' || + lookahead == '$' || + lookahead == '%' || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= '/') || + lookahead == ':' || + ('<' <= lookahead && lookahead <= '@') || + lookahead == '^') ADVANCE(78); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(52); + END_STATE(); + case 53: + ACCEPT_TOKEN(sym__radix); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + END_STATE(); + case 54: + ACCEPT_TOKEN(sym__radix); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 55: + ACCEPT_TOKEN(sym_string); + END_STATE(); + case 56: + ACCEPT_TOKEN(sym_buffer); + END_STATE(); + case 57: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '"') ADVANCE(2); + if (lookahead == '(') ADVANCE(79); + if (lookahead == '[') ADVANCE(81); + if (lookahead == '{') ADVANCE(85); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 58: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '.') ADVANCE(62); + if (lookahead == '0') ADVANCE(26); + if (lookahead == '1') ADVANCE(31); + if (lookahead == '2') ADVANCE(32); + if (lookahead == '3') ADVANCE(30); + if (('4' <= lookahead && lookahead <= '9')) ADVANCE(29); + if (lookahead == '_') ADVANCE(59); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 59: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '.') ADVANCE(62); + if (lookahead == '_') ADVANCE(59); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 60: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '.') ADVANCE(63); + if (lookahead == '_') ADVANCE(61); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(43); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 61: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '.') ADVANCE(63); + if (lookahead == '_') ADVANCE(61); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 62: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '_') ADVANCE(62); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 63: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '_') ADVANCE(63); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 64: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'a') ADVANCE(68); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('b' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 65: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'e') ADVANCE(16); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 66: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'e') ADVANCE(15); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 67: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'i') ADVANCE(69); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 68: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'l') ADVANCE(71); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 69: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'l') ADVANCE(18); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 70: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'r') ADVANCE(72); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 71: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 's') ADVANCE(66); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 72: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == 'u') ADVANCE(65); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 73: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '+' || + lookahead == '-') ADVANCE(75); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + ('.' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 74: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '+' || + lookahead == '-') ADVANCE(76); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + ('.' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 75: + ACCEPT_TOKEN(sym_symbol); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 76: + ACCEPT_TOKEN(sym_symbol); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 77: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= '/') || + lookahead == ':' || + ('<' <= lookahead && lookahead <= '@') || + lookahead == '^' || + lookahead == '_') ADVANCE(78); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(52); + END_STATE(); + case 78: + ACCEPT_TOKEN(sym_symbol); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + END_STATE(); + case 79: + ACCEPT_TOKEN(anon_sym_AT_LPAREN); + END_STATE(); + case 80: + ACCEPT_TOKEN(anon_sym_RPAREN); + END_STATE(); + case 81: + ACCEPT_TOKEN(anon_sym_AT_LBRACK); + END_STATE(); + case 82: + ACCEPT_TOKEN(anon_sym_RBRACK); + END_STATE(); + case 83: + ACCEPT_TOKEN(anon_sym_LBRACE); + END_STATE(); + case 84: + ACCEPT_TOKEN(anon_sym_RBRACE); + END_STATE(); + case 85: + ACCEPT_TOKEN(anon_sym_AT_LBRACE); + END_STATE(); + case 86: + ACCEPT_TOKEN(anon_sym_LPAREN); + END_STATE(); + case 87: + ACCEPT_TOKEN(anon_sym_LBRACK); + END_STATE(); + case 88: + ACCEPT_TOKEN(anon_sym_TILDE); + END_STATE(); + case 89: + ACCEPT_TOKEN(anon_sym_SQUOTE); + END_STATE(); + case 90: + ACCEPT_TOKEN(anon_sym_PIPE); + END_STATE(); + case 91: + ACCEPT_TOKEN(anon_sym_SEMI); + END_STATE(); + case 92: + ACCEPT_TOKEN(anon_sym_COMMA); + END_STATE(); + default: + return false; + } +} + +static TSLexMode ts_lex_modes[STATE_COUNT] = { + [0] = {.lex_state = 0, .external_lex_state = 1}, + [1] = {.lex_state = 0, .external_lex_state = 1}, + [2] = {.lex_state = 0, .external_lex_state = 1}, + [3] = {.lex_state = 0, .external_lex_state = 1}, + [4] = {.lex_state = 0, .external_lex_state = 1}, + [5] = {.lex_state = 0, .external_lex_state = 1}, + [6] = {.lex_state = 0, .external_lex_state = 1}, + [7] = {.lex_state = 0, .external_lex_state = 1}, + [8] = {.lex_state = 0, .external_lex_state = 1}, + [9] = {.lex_state = 0, .external_lex_state = 1}, + [10] = {.lex_state = 0, .external_lex_state = 1}, + [11] = {.lex_state = 0, .external_lex_state = 1}, + [12] = {.lex_state = 0, .external_lex_state = 1}, + [13] = {.lex_state = 0, .external_lex_state = 1}, + [14] = {.lex_state = 0, .external_lex_state = 1}, + [15] = {.lex_state = 0, .external_lex_state = 1}, + [16] = {.lex_state = 0, .external_lex_state = 1}, + [17] = {.lex_state = 0, .external_lex_state = 1}, + [18] = {.lex_state = 0, .external_lex_state = 1}, + [19] = {.lex_state = 0, .external_lex_state = 1}, + [20] = {.lex_state = 0, .external_lex_state = 1}, + [21] = {.lex_state = 0, .external_lex_state = 1}, + [22] = {.lex_state = 0, .external_lex_state = 1}, + [23] = {.lex_state = 0, .external_lex_state = 1}, + [24] = {.lex_state = 0, .external_lex_state = 1}, + [25] = {.lex_state = 0, .external_lex_state = 1}, + [26] = {.lex_state = 0, .external_lex_state = 1}, + [27] = {.lex_state = 0, .external_lex_state = 1}, + [28] = {.lex_state = 0, .external_lex_state = 1}, + [29] = {.lex_state = 0, .external_lex_state = 1}, + [30] = {.lex_state = 0, .external_lex_state = 1}, + [31] = {.lex_state = 0, .external_lex_state = 1}, + [32] = {.lex_state = 0, .external_lex_state = 1}, + [33] = {.lex_state = 0, .external_lex_state = 1}, + [34] = {.lex_state = 0, .external_lex_state = 1}, + [35] = {.lex_state = 0, .external_lex_state = 1}, + [36] = {.lex_state = 0, .external_lex_state = 1}, + [37] = {.lex_state = 0, .external_lex_state = 1}, + [38] = {.lex_state = 0, .external_lex_state = 1}, + [39] = {.lex_state = 0, .external_lex_state = 1}, + [40] = {.lex_state = 0, .external_lex_state = 1}, + [41] = {.lex_state = 0}, +}; + +enum { + ts_external_token_long_buffer = 0, + ts_external_token_long_string = 1, +}; + +static TSSymbol ts_external_scanner_symbol_map[EXTERNAL_TOKEN_COUNT] = { + [ts_external_token_long_buffer] = sym_long_buffer, + [ts_external_token_long_string] = sym_long_string, +}; + +static bool ts_external_scanner_states[2][EXTERNAL_TOKEN_COUNT] = { + [1] = { + [ts_external_token_long_buffer] = true, + [ts_external_token_long_string] = true, + }, +}; + +static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { + [0] = { + [ts_builtin_sym_end] = ACTIONS(1), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(1), + [anon_sym_true] = ACTIONS(1), + [aux_sym_keyword_token1] = ACTIONS(1), + [sym_nil] = ACTIONS(1), + [sym__dec] = ACTIONS(1), + [sym__hex] = ACTIONS(1), + [sym__radix] = ACTIONS(1), + [sym_string] = ACTIONS(1), + [sym_buffer] = ACTIONS(1), + [sym_symbol] = ACTIONS(1), + [anon_sym_AT_LPAREN] = ACTIONS(1), + [anon_sym_RPAREN] = ACTIONS(1), + [anon_sym_AT_LBRACK] = ACTIONS(1), + [anon_sym_RBRACK] = ACTIONS(1), + [anon_sym_LBRACE] = ACTIONS(1), + [anon_sym_RBRACE] = ACTIONS(1), + [anon_sym_AT_LBRACE] = ACTIONS(1), + [anon_sym_LPAREN] = ACTIONS(1), + [anon_sym_LBRACK] = ACTIONS(1), + [anon_sym_TILDE] = ACTIONS(1), + [anon_sym_SQUOTE] = ACTIONS(1), + [anon_sym_PIPE] = ACTIONS(1), + [anon_sym_SEMI] = ACTIONS(1), + [anon_sym_COMMA] = ACTIONS(1), + [sym_long_buffer] = ACTIONS(1), + [sym_long_string] = ACTIONS(1), + }, + [1] = { + [sym_source_file] = STATE(41), + [sym__form] = STATE(12), + [sym_boolean] = STATE(12), + [sym_keyword] = STATE(12), + [sym_number] = STATE(12), + [sym_array] = STATE(12), + [sym_array_literal] = STATE(12), + [sym_struct] = STATE(12), + [sym_table] = STATE(12), + [sym_tuple] = STATE(12), + [sym_tuple_literal] = STATE(12), + [sym_quasi_quote_form] = STATE(12), + [sym_quote_form] = STATE(12), + [sym_short_fn_form] = STATE(12), + [sym_splice_form] = STATE(12), + [sym_unquote_form] = STATE(12), + [aux_sym_source_file_repeat1] = STATE(12), + [ts_builtin_sym_end] = ACTIONS(5), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(11), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(15), + [sym_buffer] = ACTIONS(15), + [sym_symbol] = ACTIONS(11), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(15), + [sym_long_string] = ACTIONS(15), + }, + [2] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [ts_builtin_sym_end] = ACTIONS(39), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(41), + [anon_sym_true] = ACTIONS(41), + [aux_sym_keyword_token1] = ACTIONS(44), + [sym_nil] = ACTIONS(47), + [sym__dec] = ACTIONS(50), + [sym__hex] = ACTIONS(50), + [sym__radix] = ACTIONS(50), + [sym_string] = ACTIONS(53), + [sym_buffer] = ACTIONS(53), + [sym_symbol] = ACTIONS(47), + [anon_sym_AT_LPAREN] = ACTIONS(56), + [anon_sym_RPAREN] = ACTIONS(39), + [anon_sym_AT_LBRACK] = ACTIONS(59), + [anon_sym_RBRACK] = ACTIONS(39), + [anon_sym_LBRACE] = ACTIONS(62), + [anon_sym_RBRACE] = ACTIONS(39), + [anon_sym_AT_LBRACE] = ACTIONS(65), + [anon_sym_LPAREN] = ACTIONS(68), + [anon_sym_LBRACK] = ACTIONS(71), + [anon_sym_TILDE] = ACTIONS(74), + [anon_sym_SQUOTE] = ACTIONS(77), + [anon_sym_PIPE] = ACTIONS(80), + [anon_sym_SEMI] = ACTIONS(83), + [anon_sym_COMMA] = ACTIONS(86), + [sym_long_buffer] = ACTIONS(53), + [sym_long_string] = ACTIONS(53), + }, + [3] = { + [sym__form] = STATE(15), + [sym_boolean] = STATE(15), + [sym_keyword] = STATE(15), + [sym_number] = STATE(15), + [sym_array] = STATE(15), + [sym_array_literal] = STATE(15), + [sym_struct] = STATE(15), + [sym_table] = STATE(15), + [sym_tuple] = STATE(15), + [sym_tuple_literal] = STATE(15), + [sym_quasi_quote_form] = STATE(15), + [sym_quote_form] = STATE(15), + [sym_short_fn_form] = STATE(15), + [sym_splice_form] = STATE(15), + [sym_unquote_form] = STATE(15), + [aux_sym_source_file_repeat1] = STATE(15), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(89), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(91), + [sym_buffer] = ACTIONS(91), + [sym_symbol] = ACTIONS(89), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_RBRACK] = ACTIONS(93), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(91), + [sym_long_string] = ACTIONS(91), + }, + [4] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_RPAREN] = ACTIONS(99), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [5] = { + [sym__form] = STATE(14), + [sym_boolean] = STATE(14), + [sym_keyword] = STATE(14), + [sym_number] = STATE(14), + [sym_array] = STATE(14), + [sym_array_literal] = STATE(14), + [sym_struct] = STATE(14), + [sym_table] = STATE(14), + [sym_tuple] = STATE(14), + [sym_tuple_literal] = STATE(14), + [sym_quasi_quote_form] = STATE(14), + [sym_quote_form] = STATE(14), + [sym_short_fn_form] = STATE(14), + [sym_splice_form] = STATE(14), + [sym_unquote_form] = STATE(14), + [aux_sym_source_file_repeat1] = STATE(14), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(101), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(103), + [sym_buffer] = ACTIONS(103), + [sym_symbol] = ACTIONS(101), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_RPAREN] = ACTIONS(105), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(103), + [sym_long_string] = ACTIONS(103), + }, + [6] = { + [sym__form] = STATE(10), + [sym_boolean] = STATE(10), + [sym_keyword] = STATE(10), + [sym_number] = STATE(10), + [sym_array] = STATE(10), + [sym_array_literal] = STATE(10), + [sym_struct] = STATE(10), + [sym_table] = STATE(10), + [sym_tuple] = STATE(10), + [sym_tuple_literal] = STATE(10), + [sym_quasi_quote_form] = STATE(10), + [sym_quote_form] = STATE(10), + [sym_short_fn_form] = STATE(10), + [sym_splice_form] = STATE(10), + [sym_unquote_form] = STATE(10), + [aux_sym_source_file_repeat1] = STATE(10), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(107), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(109), + [sym_buffer] = ACTIONS(109), + [sym_symbol] = ACTIONS(107), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_RBRACK] = ACTIONS(111), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(109), + [sym_long_string] = ACTIONS(109), + }, + [7] = { + [sym__form] = STATE(13), + [sym_boolean] = STATE(13), + [sym_keyword] = STATE(13), + [sym_number] = STATE(13), + [sym_array] = STATE(13), + [sym_array_literal] = STATE(13), + [sym_struct] = STATE(13), + [sym_table] = STATE(13), + [sym_tuple] = STATE(13), + [sym_tuple_literal] = STATE(13), + [sym_quasi_quote_form] = STATE(13), + [sym_quote_form] = STATE(13), + [sym_short_fn_form] = STATE(13), + [sym_splice_form] = STATE(13), + [sym_unquote_form] = STATE(13), + [aux_sym_source_file_repeat1] = STATE(13), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(113), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(115), + [sym_buffer] = ACTIONS(115), + [sym_symbol] = ACTIONS(113), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_RBRACE] = ACTIONS(117), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(115), + [sym_long_string] = ACTIONS(115), + }, + [8] = { + [sym__form] = STATE(11), + [sym_boolean] = STATE(11), + [sym_keyword] = STATE(11), + [sym_number] = STATE(11), + [sym_array] = STATE(11), + [sym_array_literal] = STATE(11), + [sym_struct] = STATE(11), + [sym_table] = STATE(11), + [sym_tuple] = STATE(11), + [sym_tuple_literal] = STATE(11), + [sym_quasi_quote_form] = STATE(11), + [sym_quote_form] = STATE(11), + [sym_short_fn_form] = STATE(11), + [sym_splice_form] = STATE(11), + [sym_unquote_form] = STATE(11), + [aux_sym_source_file_repeat1] = STATE(11), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(119), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(121), + [sym_buffer] = ACTIONS(121), + [sym_symbol] = ACTIONS(119), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_RBRACE] = ACTIONS(123), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(121), + [sym_long_string] = ACTIONS(121), + }, + [9] = { + [sym__form] = STATE(4), + [sym_boolean] = STATE(4), + [sym_keyword] = STATE(4), + [sym_number] = STATE(4), + [sym_array] = STATE(4), + [sym_array_literal] = STATE(4), + [sym_struct] = STATE(4), + [sym_table] = STATE(4), + [sym_tuple] = STATE(4), + [sym_tuple_literal] = STATE(4), + [sym_quasi_quote_form] = STATE(4), + [sym_quote_form] = STATE(4), + [sym_short_fn_form] = STATE(4), + [sym_splice_form] = STATE(4), + [sym_unquote_form] = STATE(4), + [aux_sym_source_file_repeat1] = STATE(4), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(125), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(127), + [sym_buffer] = ACTIONS(127), + [sym_symbol] = ACTIONS(125), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_RPAREN] = ACTIONS(129), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(127), + [sym_long_string] = ACTIONS(127), + }, + [10] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_RBRACK] = ACTIONS(131), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [11] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_RBRACE] = ACTIONS(133), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [12] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [ts_builtin_sym_end] = ACTIONS(135), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [13] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_RBRACE] = ACTIONS(137), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [14] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_RPAREN] = ACTIONS(139), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [15] = { + [sym__form] = STATE(2), + [sym_boolean] = STATE(2), + [sym_keyword] = STATE(2), + [sym_number] = STATE(2), + [sym_array] = STATE(2), + [sym_array_literal] = STATE(2), + [sym_struct] = STATE(2), + [sym_table] = STATE(2), + [sym_tuple] = STATE(2), + [sym_tuple_literal] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_file_repeat1] = STATE(2), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(95), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(97), + [sym_buffer] = ACTIONS(97), + [sym_symbol] = ACTIONS(95), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_RBRACK] = ACTIONS(141), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(97), + [sym_long_string] = ACTIONS(97), + }, + [16] = { + [sym__form] = STATE(29), + [sym_boolean] = STATE(29), + [sym_keyword] = STATE(29), + [sym_number] = STATE(29), + [sym_array] = STATE(29), + [sym_array_literal] = STATE(29), + [sym_struct] = STATE(29), + [sym_table] = STATE(29), + [sym_tuple] = STATE(29), + [sym_tuple_literal] = STATE(29), + [sym_quasi_quote_form] = STATE(29), + [sym_quote_form] = STATE(29), + [sym_short_fn_form] = STATE(29), + [sym_splice_form] = STATE(29), + [sym_unquote_form] = STATE(29), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(143), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(145), + [sym_buffer] = ACTIONS(145), + [sym_symbol] = ACTIONS(143), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(145), + [sym_long_string] = ACTIONS(145), + }, + [17] = { + [sym__form] = STATE(30), + [sym_boolean] = STATE(30), + [sym_keyword] = STATE(30), + [sym_number] = STATE(30), + [sym_array] = STATE(30), + [sym_array_literal] = STATE(30), + [sym_struct] = STATE(30), + [sym_table] = STATE(30), + [sym_tuple] = STATE(30), + [sym_tuple_literal] = STATE(30), + [sym_quasi_quote_form] = STATE(30), + [sym_quote_form] = STATE(30), + [sym_short_fn_form] = STATE(30), + [sym_splice_form] = STATE(30), + [sym_unquote_form] = STATE(30), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(147), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(149), + [sym_buffer] = ACTIONS(149), + [sym_symbol] = ACTIONS(147), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(149), + [sym_long_string] = ACTIONS(149), + }, + [18] = { + [sym__form] = STATE(31), + [sym_boolean] = STATE(31), + [sym_keyword] = STATE(31), + [sym_number] = STATE(31), + [sym_array] = STATE(31), + [sym_array_literal] = STATE(31), + [sym_struct] = STATE(31), + [sym_table] = STATE(31), + [sym_tuple] = STATE(31), + [sym_tuple_literal] = STATE(31), + [sym_quasi_quote_form] = STATE(31), + [sym_quote_form] = STATE(31), + [sym_short_fn_form] = STATE(31), + [sym_splice_form] = STATE(31), + [sym_unquote_form] = STATE(31), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(151), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(153), + [sym_buffer] = ACTIONS(153), + [sym_symbol] = ACTIONS(151), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(153), + [sym_long_string] = ACTIONS(153), + }, + [19] = { + [sym__form] = STATE(32), + [sym_boolean] = STATE(32), + [sym_keyword] = STATE(32), + [sym_number] = STATE(32), + [sym_array] = STATE(32), + [sym_array_literal] = STATE(32), + [sym_struct] = STATE(32), + [sym_table] = STATE(32), + [sym_tuple] = STATE(32), + [sym_tuple_literal] = STATE(32), + [sym_quasi_quote_form] = STATE(32), + [sym_quote_form] = STATE(32), + [sym_short_fn_form] = STATE(32), + [sym_splice_form] = STATE(32), + [sym_unquote_form] = STATE(32), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(155), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(157), + [sym_buffer] = ACTIONS(157), + [sym_symbol] = ACTIONS(155), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(157), + [sym_long_string] = ACTIONS(157), + }, + [20] = { + [sym__form] = STATE(33), + [sym_boolean] = STATE(33), + [sym_keyword] = STATE(33), + [sym_number] = STATE(33), + [sym_array] = STATE(33), + [sym_array_literal] = STATE(33), + [sym_struct] = STATE(33), + [sym_table] = STATE(33), + [sym_tuple] = STATE(33), + [sym_tuple_literal] = STATE(33), + [sym_quasi_quote_form] = STATE(33), + [sym_quote_form] = STATE(33), + [sym_short_fn_form] = STATE(33), + [sym_splice_form] = STATE(33), + [sym_unquote_form] = STATE(33), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(7), + [anon_sym_true] = ACTIONS(7), + [aux_sym_keyword_token1] = ACTIONS(9), + [sym_nil] = ACTIONS(159), + [sym__dec] = ACTIONS(13), + [sym__hex] = ACTIONS(13), + [sym__radix] = ACTIONS(13), + [sym_string] = ACTIONS(161), + [sym_buffer] = ACTIONS(161), + [sym_symbol] = ACTIONS(159), + [anon_sym_AT_LPAREN] = ACTIONS(17), + [anon_sym_AT_LBRACK] = ACTIONS(19), + [anon_sym_LBRACE] = ACTIONS(21), + [anon_sym_AT_LBRACE] = ACTIONS(23), + [anon_sym_LPAREN] = ACTIONS(25), + [anon_sym_LBRACK] = ACTIONS(27), + [anon_sym_TILDE] = ACTIONS(29), + [anon_sym_SQUOTE] = ACTIONS(31), + [anon_sym_PIPE] = ACTIONS(33), + [anon_sym_SEMI] = ACTIONS(35), + [anon_sym_COMMA] = ACTIONS(37), + [sym_long_buffer] = ACTIONS(161), + [sym_long_string] = ACTIONS(161), + }, + [21] = { + [ts_builtin_sym_end] = ACTIONS(163), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(165), + [anon_sym_true] = ACTIONS(165), + [aux_sym_keyword_token1] = ACTIONS(163), + [sym_nil] = ACTIONS(165), + [sym__dec] = ACTIONS(165), + [sym__hex] = ACTIONS(165), + [sym__radix] = ACTIONS(165), + [sym_string] = ACTIONS(163), + [sym_buffer] = ACTIONS(163), + [sym_symbol] = ACTIONS(165), + [anon_sym_AT_LPAREN] = ACTIONS(163), + [anon_sym_RPAREN] = ACTIONS(163), + [anon_sym_AT_LBRACK] = ACTIONS(163), + [anon_sym_RBRACK] = ACTIONS(163), + [anon_sym_LBRACE] = ACTIONS(163), + [anon_sym_RBRACE] = ACTIONS(163), + [anon_sym_AT_LBRACE] = ACTIONS(163), + [anon_sym_LPAREN] = ACTIONS(163), + [anon_sym_LBRACK] = ACTIONS(163), + [anon_sym_TILDE] = ACTIONS(163), + [anon_sym_SQUOTE] = ACTIONS(163), + [anon_sym_PIPE] = ACTIONS(163), + [anon_sym_SEMI] = ACTIONS(163), + [anon_sym_COMMA] = ACTIONS(163), + [sym_long_buffer] = ACTIONS(163), + [sym_long_string] = ACTIONS(163), + }, + [22] = { + [ts_builtin_sym_end] = ACTIONS(167), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(169), + [anon_sym_true] = ACTIONS(169), + [aux_sym_keyword_token1] = ACTIONS(167), + [sym_nil] = ACTIONS(169), + [sym__dec] = ACTIONS(169), + [sym__hex] = ACTIONS(169), + [sym__radix] = ACTIONS(169), + [sym_string] = ACTIONS(167), + [sym_buffer] = ACTIONS(167), + [sym_symbol] = ACTIONS(169), + [anon_sym_AT_LPAREN] = ACTIONS(167), + [anon_sym_RPAREN] = ACTIONS(167), + [anon_sym_AT_LBRACK] = ACTIONS(167), + [anon_sym_RBRACK] = ACTIONS(167), + [anon_sym_LBRACE] = ACTIONS(167), + [anon_sym_RBRACE] = ACTIONS(167), + [anon_sym_AT_LBRACE] = ACTIONS(167), + [anon_sym_LPAREN] = ACTIONS(167), + [anon_sym_LBRACK] = ACTIONS(167), + [anon_sym_TILDE] = ACTIONS(167), + [anon_sym_SQUOTE] = ACTIONS(167), + [anon_sym_PIPE] = ACTIONS(167), + [anon_sym_SEMI] = ACTIONS(167), + [anon_sym_COMMA] = ACTIONS(167), + [sym_long_buffer] = ACTIONS(167), + [sym_long_string] = ACTIONS(167), + }, + [23] = { + [ts_builtin_sym_end] = ACTIONS(171), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(173), + [anon_sym_true] = ACTIONS(173), + [aux_sym_keyword_token1] = ACTIONS(171), + [sym_nil] = ACTIONS(173), + [sym__dec] = ACTIONS(173), + [sym__hex] = ACTIONS(173), + [sym__radix] = ACTIONS(173), + [sym_string] = ACTIONS(171), + [sym_buffer] = ACTIONS(171), + [sym_symbol] = ACTIONS(173), + [anon_sym_AT_LPAREN] = ACTIONS(171), + [anon_sym_RPAREN] = ACTIONS(171), + [anon_sym_AT_LBRACK] = ACTIONS(171), + [anon_sym_RBRACK] = ACTIONS(171), + [anon_sym_LBRACE] = ACTIONS(171), + [anon_sym_RBRACE] = ACTIONS(171), + [anon_sym_AT_LBRACE] = ACTIONS(171), + [anon_sym_LPAREN] = ACTIONS(171), + [anon_sym_LBRACK] = ACTIONS(171), + [anon_sym_TILDE] = ACTIONS(171), + [anon_sym_SQUOTE] = ACTIONS(171), + [anon_sym_PIPE] = ACTIONS(171), + [anon_sym_SEMI] = ACTIONS(171), + [anon_sym_COMMA] = ACTIONS(171), + [sym_long_buffer] = ACTIONS(171), + [sym_long_string] = ACTIONS(171), + }, + [24] = { + [ts_builtin_sym_end] = ACTIONS(175), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(177), + [anon_sym_true] = ACTIONS(177), + [aux_sym_keyword_token1] = ACTIONS(175), + [sym_nil] = ACTIONS(177), + [sym__dec] = ACTIONS(177), + [sym__hex] = ACTIONS(177), + [sym__radix] = ACTIONS(177), + [sym_string] = ACTIONS(175), + [sym_buffer] = ACTIONS(175), + [sym_symbol] = ACTIONS(177), + [anon_sym_AT_LPAREN] = ACTIONS(175), + [anon_sym_RPAREN] = ACTIONS(175), + [anon_sym_AT_LBRACK] = ACTIONS(175), + [anon_sym_RBRACK] = ACTIONS(175), + [anon_sym_LBRACE] = ACTIONS(175), + [anon_sym_RBRACE] = ACTIONS(175), + [anon_sym_AT_LBRACE] = ACTIONS(175), + [anon_sym_LPAREN] = ACTIONS(175), + [anon_sym_LBRACK] = ACTIONS(175), + [anon_sym_TILDE] = ACTIONS(175), + [anon_sym_SQUOTE] = ACTIONS(175), + [anon_sym_PIPE] = ACTIONS(175), + [anon_sym_SEMI] = ACTIONS(175), + [anon_sym_COMMA] = ACTIONS(175), + [sym_long_buffer] = ACTIONS(175), + [sym_long_string] = ACTIONS(175), + }, + [25] = { + [ts_builtin_sym_end] = ACTIONS(179), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(181), + [anon_sym_true] = ACTIONS(181), + [aux_sym_keyword_token1] = ACTIONS(179), + [sym_nil] = ACTIONS(181), + [sym__dec] = ACTIONS(181), + [sym__hex] = ACTIONS(181), + [sym__radix] = ACTIONS(181), + [sym_string] = ACTIONS(179), + [sym_buffer] = ACTIONS(179), + [sym_symbol] = ACTIONS(181), + [anon_sym_AT_LPAREN] = ACTIONS(179), + [anon_sym_RPAREN] = ACTIONS(179), + [anon_sym_AT_LBRACK] = ACTIONS(179), + [anon_sym_RBRACK] = ACTIONS(179), + [anon_sym_LBRACE] = ACTIONS(179), + [anon_sym_RBRACE] = ACTIONS(179), + [anon_sym_AT_LBRACE] = ACTIONS(179), + [anon_sym_LPAREN] = ACTIONS(179), + [anon_sym_LBRACK] = ACTIONS(179), + [anon_sym_TILDE] = ACTIONS(179), + [anon_sym_SQUOTE] = ACTIONS(179), + [anon_sym_PIPE] = ACTIONS(179), + [anon_sym_SEMI] = ACTIONS(179), + [anon_sym_COMMA] = ACTIONS(179), + [sym_long_buffer] = ACTIONS(179), + [sym_long_string] = ACTIONS(179), + }, + [26] = { + [ts_builtin_sym_end] = ACTIONS(183), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(185), + [anon_sym_true] = ACTIONS(185), + [aux_sym_keyword_token1] = ACTIONS(183), + [sym_nil] = ACTIONS(185), + [sym__dec] = ACTIONS(185), + [sym__hex] = ACTIONS(185), + [sym__radix] = ACTIONS(185), + [sym_string] = ACTIONS(183), + [sym_buffer] = ACTIONS(183), + [sym_symbol] = ACTIONS(185), + [anon_sym_AT_LPAREN] = ACTIONS(183), + [anon_sym_RPAREN] = ACTIONS(183), + [anon_sym_AT_LBRACK] = ACTIONS(183), + [anon_sym_RBRACK] = ACTIONS(183), + [anon_sym_LBRACE] = ACTIONS(183), + [anon_sym_RBRACE] = ACTIONS(183), + [anon_sym_AT_LBRACE] = ACTIONS(183), + [anon_sym_LPAREN] = ACTIONS(183), + [anon_sym_LBRACK] = ACTIONS(183), + [anon_sym_TILDE] = ACTIONS(183), + [anon_sym_SQUOTE] = ACTIONS(183), + [anon_sym_PIPE] = ACTIONS(183), + [anon_sym_SEMI] = ACTIONS(183), + [anon_sym_COMMA] = ACTIONS(183), + [sym_long_buffer] = ACTIONS(183), + [sym_long_string] = ACTIONS(183), + }, + [27] = { + [ts_builtin_sym_end] = ACTIONS(187), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(189), + [anon_sym_true] = ACTIONS(189), + [aux_sym_keyword_token1] = ACTIONS(187), + [sym_nil] = ACTIONS(189), + [sym__dec] = ACTIONS(189), + [sym__hex] = ACTIONS(189), + [sym__radix] = ACTIONS(189), + [sym_string] = ACTIONS(187), + [sym_buffer] = ACTIONS(187), + [sym_symbol] = ACTIONS(189), + [anon_sym_AT_LPAREN] = ACTIONS(187), + [anon_sym_RPAREN] = ACTIONS(187), + [anon_sym_AT_LBRACK] = ACTIONS(187), + [anon_sym_RBRACK] = ACTIONS(187), + [anon_sym_LBRACE] = ACTIONS(187), + [anon_sym_RBRACE] = ACTIONS(187), + [anon_sym_AT_LBRACE] = ACTIONS(187), + [anon_sym_LPAREN] = ACTIONS(187), + [anon_sym_LBRACK] = ACTIONS(187), + [anon_sym_TILDE] = ACTIONS(187), + [anon_sym_SQUOTE] = ACTIONS(187), + [anon_sym_PIPE] = ACTIONS(187), + [anon_sym_SEMI] = ACTIONS(187), + [anon_sym_COMMA] = ACTIONS(187), + [sym_long_buffer] = ACTIONS(187), + [sym_long_string] = ACTIONS(187), + }, + [28] = { + [ts_builtin_sym_end] = ACTIONS(191), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(193), + [anon_sym_true] = ACTIONS(193), + [aux_sym_keyword_token1] = ACTIONS(191), + [sym_nil] = ACTIONS(193), + [sym__dec] = ACTIONS(193), + [sym__hex] = ACTIONS(193), + [sym__radix] = ACTIONS(193), + [sym_string] = ACTIONS(191), + [sym_buffer] = ACTIONS(191), + [sym_symbol] = ACTIONS(193), + [anon_sym_AT_LPAREN] = ACTIONS(191), + [anon_sym_RPAREN] = ACTIONS(191), + [anon_sym_AT_LBRACK] = ACTIONS(191), + [anon_sym_RBRACK] = ACTIONS(191), + [anon_sym_LBRACE] = ACTIONS(191), + [anon_sym_RBRACE] = ACTIONS(191), + [anon_sym_AT_LBRACE] = ACTIONS(191), + [anon_sym_LPAREN] = ACTIONS(191), + [anon_sym_LBRACK] = ACTIONS(191), + [anon_sym_TILDE] = ACTIONS(191), + [anon_sym_SQUOTE] = ACTIONS(191), + [anon_sym_PIPE] = ACTIONS(191), + [anon_sym_SEMI] = ACTIONS(191), + [anon_sym_COMMA] = ACTIONS(191), + [sym_long_buffer] = ACTIONS(191), + [sym_long_string] = ACTIONS(191), + }, + [29] = { + [ts_builtin_sym_end] = ACTIONS(195), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(197), + [anon_sym_true] = ACTIONS(197), + [aux_sym_keyword_token1] = ACTIONS(195), + [sym_nil] = ACTIONS(197), + [sym__dec] = ACTIONS(197), + [sym__hex] = ACTIONS(197), + [sym__radix] = ACTIONS(197), + [sym_string] = ACTIONS(195), + [sym_buffer] = ACTIONS(195), + [sym_symbol] = ACTIONS(197), + [anon_sym_AT_LPAREN] = ACTIONS(195), + [anon_sym_RPAREN] = ACTIONS(195), + [anon_sym_AT_LBRACK] = ACTIONS(195), + [anon_sym_RBRACK] = ACTIONS(195), + [anon_sym_LBRACE] = ACTIONS(195), + [anon_sym_RBRACE] = ACTIONS(195), + [anon_sym_AT_LBRACE] = ACTIONS(195), + [anon_sym_LPAREN] = ACTIONS(195), + [anon_sym_LBRACK] = ACTIONS(195), + [anon_sym_TILDE] = ACTIONS(195), + [anon_sym_SQUOTE] = ACTIONS(195), + [anon_sym_PIPE] = ACTIONS(195), + [anon_sym_SEMI] = ACTIONS(195), + [anon_sym_COMMA] = ACTIONS(195), + [sym_long_buffer] = ACTIONS(195), + [sym_long_string] = ACTIONS(195), + }, + [30] = { + [ts_builtin_sym_end] = ACTIONS(199), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(201), + [anon_sym_true] = ACTIONS(201), + [aux_sym_keyword_token1] = ACTIONS(199), + [sym_nil] = ACTIONS(201), + [sym__dec] = ACTIONS(201), + [sym__hex] = ACTIONS(201), + [sym__radix] = ACTIONS(201), + [sym_string] = ACTIONS(199), + [sym_buffer] = ACTIONS(199), + [sym_symbol] = ACTIONS(201), + [anon_sym_AT_LPAREN] = ACTIONS(199), + [anon_sym_RPAREN] = ACTIONS(199), + [anon_sym_AT_LBRACK] = ACTIONS(199), + [anon_sym_RBRACK] = ACTIONS(199), + [anon_sym_LBRACE] = ACTIONS(199), + [anon_sym_RBRACE] = ACTIONS(199), + [anon_sym_AT_LBRACE] = ACTIONS(199), + [anon_sym_LPAREN] = ACTIONS(199), + [anon_sym_LBRACK] = ACTIONS(199), + [anon_sym_TILDE] = ACTIONS(199), + [anon_sym_SQUOTE] = ACTIONS(199), + [anon_sym_PIPE] = ACTIONS(199), + [anon_sym_SEMI] = ACTIONS(199), + [anon_sym_COMMA] = ACTIONS(199), + [sym_long_buffer] = ACTIONS(199), + [sym_long_string] = ACTIONS(199), + }, + [31] = { + [ts_builtin_sym_end] = ACTIONS(203), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(205), + [anon_sym_true] = ACTIONS(205), + [aux_sym_keyword_token1] = ACTIONS(203), + [sym_nil] = ACTIONS(205), + [sym__dec] = ACTIONS(205), + [sym__hex] = ACTIONS(205), + [sym__radix] = ACTIONS(205), + [sym_string] = ACTIONS(203), + [sym_buffer] = ACTIONS(203), + [sym_symbol] = ACTIONS(205), + [anon_sym_AT_LPAREN] = ACTIONS(203), + [anon_sym_RPAREN] = ACTIONS(203), + [anon_sym_AT_LBRACK] = ACTIONS(203), + [anon_sym_RBRACK] = ACTIONS(203), + [anon_sym_LBRACE] = ACTIONS(203), + [anon_sym_RBRACE] = ACTIONS(203), + [anon_sym_AT_LBRACE] = ACTIONS(203), + [anon_sym_LPAREN] = ACTIONS(203), + [anon_sym_LBRACK] = ACTIONS(203), + [anon_sym_TILDE] = ACTIONS(203), + [anon_sym_SQUOTE] = ACTIONS(203), + [anon_sym_PIPE] = ACTIONS(203), + [anon_sym_SEMI] = ACTIONS(203), + [anon_sym_COMMA] = ACTIONS(203), + [sym_long_buffer] = ACTIONS(203), + [sym_long_string] = ACTIONS(203), + }, + [32] = { + [ts_builtin_sym_end] = ACTIONS(207), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(209), + [anon_sym_true] = ACTIONS(209), + [aux_sym_keyword_token1] = ACTIONS(207), + [sym_nil] = ACTIONS(209), + [sym__dec] = ACTIONS(209), + [sym__hex] = ACTIONS(209), + [sym__radix] = ACTIONS(209), + [sym_string] = ACTIONS(207), + [sym_buffer] = ACTIONS(207), + [sym_symbol] = ACTIONS(209), + [anon_sym_AT_LPAREN] = ACTIONS(207), + [anon_sym_RPAREN] = ACTIONS(207), + [anon_sym_AT_LBRACK] = ACTIONS(207), + [anon_sym_RBRACK] = ACTIONS(207), + [anon_sym_LBRACE] = ACTIONS(207), + [anon_sym_RBRACE] = ACTIONS(207), + [anon_sym_AT_LBRACE] = ACTIONS(207), + [anon_sym_LPAREN] = ACTIONS(207), + [anon_sym_LBRACK] = ACTIONS(207), + [anon_sym_TILDE] = ACTIONS(207), + [anon_sym_SQUOTE] = ACTIONS(207), + [anon_sym_PIPE] = ACTIONS(207), + [anon_sym_SEMI] = ACTIONS(207), + [anon_sym_COMMA] = ACTIONS(207), + [sym_long_buffer] = ACTIONS(207), + [sym_long_string] = ACTIONS(207), + }, + [33] = { + [ts_builtin_sym_end] = ACTIONS(211), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(213), + [anon_sym_true] = ACTIONS(213), + [aux_sym_keyword_token1] = ACTIONS(211), + [sym_nil] = ACTIONS(213), + [sym__dec] = ACTIONS(213), + [sym__hex] = ACTIONS(213), + [sym__radix] = ACTIONS(213), + [sym_string] = ACTIONS(211), + [sym_buffer] = ACTIONS(211), + [sym_symbol] = ACTIONS(213), + [anon_sym_AT_LPAREN] = ACTIONS(211), + [anon_sym_RPAREN] = ACTIONS(211), + [anon_sym_AT_LBRACK] = ACTIONS(211), + [anon_sym_RBRACK] = ACTIONS(211), + [anon_sym_LBRACE] = ACTIONS(211), + [anon_sym_RBRACE] = ACTIONS(211), + [anon_sym_AT_LBRACE] = ACTIONS(211), + [anon_sym_LPAREN] = ACTIONS(211), + [anon_sym_LBRACK] = ACTIONS(211), + [anon_sym_TILDE] = ACTIONS(211), + [anon_sym_SQUOTE] = ACTIONS(211), + [anon_sym_PIPE] = ACTIONS(211), + [anon_sym_SEMI] = ACTIONS(211), + [anon_sym_COMMA] = ACTIONS(211), + [sym_long_buffer] = ACTIONS(211), + [sym_long_string] = ACTIONS(211), + }, + [34] = { + [ts_builtin_sym_end] = ACTIONS(215), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(217), + [anon_sym_true] = ACTIONS(217), + [aux_sym_keyword_token1] = ACTIONS(215), + [sym_nil] = ACTIONS(217), + [sym__dec] = ACTIONS(217), + [sym__hex] = ACTIONS(217), + [sym__radix] = ACTIONS(217), + [sym_string] = ACTIONS(215), + [sym_buffer] = ACTIONS(215), + [sym_symbol] = ACTIONS(217), + [anon_sym_AT_LPAREN] = ACTIONS(215), + [anon_sym_RPAREN] = ACTIONS(215), + [anon_sym_AT_LBRACK] = ACTIONS(215), + [anon_sym_RBRACK] = ACTIONS(215), + [anon_sym_LBRACE] = ACTIONS(215), + [anon_sym_RBRACE] = ACTIONS(215), + [anon_sym_AT_LBRACE] = ACTIONS(215), + [anon_sym_LPAREN] = ACTIONS(215), + [anon_sym_LBRACK] = ACTIONS(215), + [anon_sym_TILDE] = ACTIONS(215), + [anon_sym_SQUOTE] = ACTIONS(215), + [anon_sym_PIPE] = ACTIONS(215), + [anon_sym_SEMI] = ACTIONS(215), + [anon_sym_COMMA] = ACTIONS(215), + [sym_long_buffer] = ACTIONS(215), + [sym_long_string] = ACTIONS(215), + }, + [35] = { + [ts_builtin_sym_end] = ACTIONS(219), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(221), + [anon_sym_true] = ACTIONS(221), + [aux_sym_keyword_token1] = ACTIONS(219), + [sym_nil] = ACTIONS(221), + [sym__dec] = ACTIONS(221), + [sym__hex] = ACTIONS(221), + [sym__radix] = ACTIONS(221), + [sym_string] = ACTIONS(219), + [sym_buffer] = ACTIONS(219), + [sym_symbol] = ACTIONS(221), + [anon_sym_AT_LPAREN] = ACTIONS(219), + [anon_sym_RPAREN] = ACTIONS(219), + [anon_sym_AT_LBRACK] = ACTIONS(219), + [anon_sym_RBRACK] = ACTIONS(219), + [anon_sym_LBRACE] = ACTIONS(219), + [anon_sym_RBRACE] = ACTIONS(219), + [anon_sym_AT_LBRACE] = ACTIONS(219), + [anon_sym_LPAREN] = ACTIONS(219), + [anon_sym_LBRACK] = ACTIONS(219), + [anon_sym_TILDE] = ACTIONS(219), + [anon_sym_SQUOTE] = ACTIONS(219), + [anon_sym_PIPE] = ACTIONS(219), + [anon_sym_SEMI] = ACTIONS(219), + [anon_sym_COMMA] = ACTIONS(219), + [sym_long_buffer] = ACTIONS(219), + [sym_long_string] = ACTIONS(219), + }, + [36] = { + [ts_builtin_sym_end] = ACTIONS(223), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(225), + [anon_sym_true] = ACTIONS(225), + [aux_sym_keyword_token1] = ACTIONS(223), + [sym_nil] = ACTIONS(225), + [sym__dec] = ACTIONS(225), + [sym__hex] = ACTIONS(225), + [sym__radix] = ACTIONS(225), + [sym_string] = ACTIONS(223), + [sym_buffer] = ACTIONS(223), + [sym_symbol] = ACTIONS(225), + [anon_sym_AT_LPAREN] = ACTIONS(223), + [anon_sym_RPAREN] = ACTIONS(223), + [anon_sym_AT_LBRACK] = ACTIONS(223), + [anon_sym_RBRACK] = ACTIONS(223), + [anon_sym_LBRACE] = ACTIONS(223), + [anon_sym_RBRACE] = ACTIONS(223), + [anon_sym_AT_LBRACE] = ACTIONS(223), + [anon_sym_LPAREN] = ACTIONS(223), + [anon_sym_LBRACK] = ACTIONS(223), + [anon_sym_TILDE] = ACTIONS(223), + [anon_sym_SQUOTE] = ACTIONS(223), + [anon_sym_PIPE] = ACTIONS(223), + [anon_sym_SEMI] = ACTIONS(223), + [anon_sym_COMMA] = ACTIONS(223), + [sym_long_buffer] = ACTIONS(223), + [sym_long_string] = ACTIONS(223), + }, + [37] = { + [ts_builtin_sym_end] = ACTIONS(227), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(229), + [anon_sym_true] = ACTIONS(229), + [aux_sym_keyword_token1] = ACTIONS(227), + [sym_nil] = ACTIONS(229), + [sym__dec] = ACTIONS(229), + [sym__hex] = ACTIONS(229), + [sym__radix] = ACTIONS(229), + [sym_string] = ACTIONS(227), + [sym_buffer] = ACTIONS(227), + [sym_symbol] = ACTIONS(229), + [anon_sym_AT_LPAREN] = ACTIONS(227), + [anon_sym_RPAREN] = ACTIONS(227), + [anon_sym_AT_LBRACK] = ACTIONS(227), + [anon_sym_RBRACK] = ACTIONS(227), + [anon_sym_LBRACE] = ACTIONS(227), + [anon_sym_RBRACE] = ACTIONS(227), + [anon_sym_AT_LBRACE] = ACTIONS(227), + [anon_sym_LPAREN] = ACTIONS(227), + [anon_sym_LBRACK] = ACTIONS(227), + [anon_sym_TILDE] = ACTIONS(227), + [anon_sym_SQUOTE] = ACTIONS(227), + [anon_sym_PIPE] = ACTIONS(227), + [anon_sym_SEMI] = ACTIONS(227), + [anon_sym_COMMA] = ACTIONS(227), + [sym_long_buffer] = ACTIONS(227), + [sym_long_string] = ACTIONS(227), + }, + [38] = { + [ts_builtin_sym_end] = ACTIONS(231), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(233), + [anon_sym_true] = ACTIONS(233), + [aux_sym_keyword_token1] = ACTIONS(231), + [sym_nil] = ACTIONS(233), + [sym__dec] = ACTIONS(233), + [sym__hex] = ACTIONS(233), + [sym__radix] = ACTIONS(233), + [sym_string] = ACTIONS(231), + [sym_buffer] = ACTIONS(231), + [sym_symbol] = ACTIONS(233), + [anon_sym_AT_LPAREN] = ACTIONS(231), + [anon_sym_RPAREN] = ACTIONS(231), + [anon_sym_AT_LBRACK] = ACTIONS(231), + [anon_sym_RBRACK] = ACTIONS(231), + [anon_sym_LBRACE] = ACTIONS(231), + [anon_sym_RBRACE] = ACTIONS(231), + [anon_sym_AT_LBRACE] = ACTIONS(231), + [anon_sym_LPAREN] = ACTIONS(231), + [anon_sym_LBRACK] = ACTIONS(231), + [anon_sym_TILDE] = ACTIONS(231), + [anon_sym_SQUOTE] = ACTIONS(231), + [anon_sym_PIPE] = ACTIONS(231), + [anon_sym_SEMI] = ACTIONS(231), + [anon_sym_COMMA] = ACTIONS(231), + [sym_long_buffer] = ACTIONS(231), + [sym_long_string] = ACTIONS(231), + }, + [39] = { + [ts_builtin_sym_end] = ACTIONS(235), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(237), + [anon_sym_true] = ACTIONS(237), + [aux_sym_keyword_token1] = ACTIONS(235), + [sym_nil] = ACTIONS(237), + [sym__dec] = ACTIONS(237), + [sym__hex] = ACTIONS(237), + [sym__radix] = ACTIONS(237), + [sym_string] = ACTIONS(235), + [sym_buffer] = ACTIONS(235), + [sym_symbol] = ACTIONS(237), + [anon_sym_AT_LPAREN] = ACTIONS(235), + [anon_sym_RPAREN] = ACTIONS(235), + [anon_sym_AT_LBRACK] = ACTIONS(235), + [anon_sym_RBRACK] = ACTIONS(235), + [anon_sym_LBRACE] = ACTIONS(235), + [anon_sym_RBRACE] = ACTIONS(235), + [anon_sym_AT_LBRACE] = ACTIONS(235), + [anon_sym_LPAREN] = ACTIONS(235), + [anon_sym_LBRACK] = ACTIONS(235), + [anon_sym_TILDE] = ACTIONS(235), + [anon_sym_SQUOTE] = ACTIONS(235), + [anon_sym_PIPE] = ACTIONS(235), + [anon_sym_SEMI] = ACTIONS(235), + [anon_sym_COMMA] = ACTIONS(235), + [sym_long_buffer] = ACTIONS(235), + [sym_long_string] = ACTIONS(235), + }, + [40] = { + [ts_builtin_sym_end] = ACTIONS(239), + [sym_comment] = ACTIONS(3), + [anon_sym_false] = ACTIONS(241), + [anon_sym_true] = ACTIONS(241), + [aux_sym_keyword_token1] = ACTIONS(239), + [sym_nil] = ACTIONS(241), + [sym__dec] = ACTIONS(241), + [sym__hex] = ACTIONS(241), + [sym__radix] = ACTIONS(241), + [sym_string] = ACTIONS(239), + [sym_buffer] = ACTIONS(239), + [sym_symbol] = ACTIONS(241), + [anon_sym_AT_LPAREN] = ACTIONS(239), + [anon_sym_RPAREN] = ACTIONS(239), + [anon_sym_AT_LBRACK] = ACTIONS(239), + [anon_sym_RBRACK] = ACTIONS(239), + [anon_sym_LBRACE] = ACTIONS(239), + [anon_sym_RBRACE] = ACTIONS(239), + [anon_sym_AT_LBRACE] = ACTIONS(239), + [anon_sym_LPAREN] = ACTIONS(239), + [anon_sym_LBRACK] = ACTIONS(239), + [anon_sym_TILDE] = ACTIONS(239), + [anon_sym_SQUOTE] = ACTIONS(239), + [anon_sym_PIPE] = ACTIONS(239), + [anon_sym_SEMI] = ACTIONS(239), + [anon_sym_COMMA] = ACTIONS(239), + [sym_long_buffer] = ACTIONS(239), + [sym_long_string] = ACTIONS(239), + }, +}; + +static uint16_t ts_small_parse_table[] = { + [0] = 2, + ACTIONS(3), 1, + sym_comment, + ACTIONS(243), 1, + ts_builtin_sym_end, +}; + +static uint32_t ts_small_parse_table_map[] = { + [SMALL_STATE(41)] = 0, +}; + +static TSParseActionEntry ts_parse_actions[] = { + [0] = {.count = 0, .reusable = false}, + [1] = {.count = 1, .reusable = false}, RECOVER(), + [3] = {.count = 1, .reusable = true}, SHIFT_EXTRA(), + [5] = {.count = 1, .reusable = true}, REDUCE(sym_source_file, 0), + [7] = {.count = 1, .reusable = false}, SHIFT(23), + [9] = {.count = 1, .reusable = true}, SHIFT(34), + [11] = {.count = 1, .reusable = false}, SHIFT(12), + [13] = {.count = 1, .reusable = false}, SHIFT(28), + [15] = {.count = 1, .reusable = true}, SHIFT(12), + [17] = {.count = 1, .reusable = true}, SHIFT(5), + [19] = {.count = 1, .reusable = true}, SHIFT(6), + [21] = {.count = 1, .reusable = true}, SHIFT(7), + [23] = {.count = 1, .reusable = true}, SHIFT(8), + [25] = {.count = 1, .reusable = true}, SHIFT(9), + [27] = {.count = 1, .reusable = true}, SHIFT(3), + [29] = {.count = 1, .reusable = true}, SHIFT(16), + [31] = {.count = 1, .reusable = true}, SHIFT(17), + [33] = {.count = 1, .reusable = true}, SHIFT(18), + [35] = {.count = 1, .reusable = true}, SHIFT(19), + [37] = {.count = 1, .reusable = true}, SHIFT(20), + [39] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), + [41] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(23), + [44] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(34), + [47] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(2), + [50] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(28), + [53] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(2), + [56] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(5), + [59] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(6), + [62] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(7), + [65] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(8), + [68] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(9), + [71] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(3), + [74] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(16), + [77] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(17), + [80] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(18), + [83] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(19), + [86] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(20), + [89] = {.count = 1, .reusable = false}, SHIFT(15), + [91] = {.count = 1, .reusable = true}, SHIFT(15), + [93] = {.count = 1, .reusable = true}, SHIFT(27), + [95] = {.count = 1, .reusable = false}, SHIFT(2), + [97] = {.count = 1, .reusable = true}, SHIFT(2), + [99] = {.count = 1, .reusable = true}, SHIFT(39), + [101] = {.count = 1, .reusable = false}, SHIFT(14), + [103] = {.count = 1, .reusable = true}, SHIFT(14), + [105] = {.count = 1, .reusable = true}, SHIFT(25), + [107] = {.count = 1, .reusable = false}, SHIFT(10), + [109] = {.count = 1, .reusable = true}, SHIFT(10), + [111] = {.count = 1, .reusable = true}, SHIFT(21), + [113] = {.count = 1, .reusable = false}, SHIFT(13), + [115] = {.count = 1, .reusable = true}, SHIFT(13), + [117] = {.count = 1, .reusable = true}, SHIFT(22), + [119] = {.count = 1, .reusable = false}, SHIFT(11), + [121] = {.count = 1, .reusable = true}, SHIFT(11), + [123] = {.count = 1, .reusable = true}, SHIFT(24), + [125] = {.count = 1, .reusable = false}, SHIFT(4), + [127] = {.count = 1, .reusable = true}, SHIFT(4), + [129] = {.count = 1, .reusable = true}, SHIFT(26), + [131] = {.count = 1, .reusable = true}, SHIFT(36), + [133] = {.count = 1, .reusable = true}, SHIFT(38), + [135] = {.count = 1, .reusable = true}, REDUCE(sym_source_file, 1), + [137] = {.count = 1, .reusable = true}, SHIFT(37), + [139] = {.count = 1, .reusable = true}, SHIFT(35), + [141] = {.count = 1, .reusable = true}, SHIFT(40), + [143] = {.count = 1, .reusable = false}, SHIFT(29), + [145] = {.count = 1, .reusable = true}, SHIFT(29), + [147] = {.count = 1, .reusable = false}, SHIFT(30), + [149] = {.count = 1, .reusable = true}, SHIFT(30), + [151] = {.count = 1, .reusable = false}, SHIFT(31), + [153] = {.count = 1, .reusable = true}, SHIFT(31), + [155] = {.count = 1, .reusable = false}, SHIFT(32), + [157] = {.count = 1, .reusable = true}, SHIFT(32), + [159] = {.count = 1, .reusable = false}, SHIFT(33), + [161] = {.count = 1, .reusable = true}, SHIFT(33), + [163] = {.count = 1, .reusable = true}, REDUCE(sym_array_literal, 2), + [165] = {.count = 1, .reusable = false}, REDUCE(sym_array_literal, 2), + [167] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 2), + [169] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 2), + [171] = {.count = 1, .reusable = true}, REDUCE(sym_boolean, 1), + [173] = {.count = 1, .reusable = false}, REDUCE(sym_boolean, 1), + [175] = {.count = 1, .reusable = true}, REDUCE(sym_table, 2), + [177] = {.count = 1, .reusable = false}, REDUCE(sym_table, 2), + [179] = {.count = 1, .reusable = true}, REDUCE(sym_array, 2), + [181] = {.count = 1, .reusable = false}, REDUCE(sym_array, 2), + [183] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 2), + [185] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 2), + [187] = {.count = 1, .reusable = true}, REDUCE(sym_tuple_literal, 2), + [189] = {.count = 1, .reusable = false}, REDUCE(sym_tuple_literal, 2), + [191] = {.count = 1, .reusable = true}, REDUCE(sym_number, 1), + [193] = {.count = 1, .reusable = false}, REDUCE(sym_number, 1), + [195] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), + [197] = {.count = 1, .reusable = false}, REDUCE(sym_quasi_quote_form, 2), + [199] = {.count = 1, .reusable = true}, REDUCE(sym_quote_form, 2), + [201] = {.count = 1, .reusable = false}, REDUCE(sym_quote_form, 2), + [203] = {.count = 1, .reusable = true}, REDUCE(sym_short_fn_form, 2), + [205] = {.count = 1, .reusable = false}, REDUCE(sym_short_fn_form, 2), + [207] = {.count = 1, .reusable = true}, REDUCE(sym_splice_form, 2), + [209] = {.count = 1, .reusable = false}, REDUCE(sym_splice_form, 2), + [211] = {.count = 1, .reusable = true}, REDUCE(sym_unquote_form, 2), + [213] = {.count = 1, .reusable = false}, REDUCE(sym_unquote_form, 2), + [215] = {.count = 1, .reusable = true}, REDUCE(sym_keyword, 1), + [217] = {.count = 1, .reusable = false}, REDUCE(sym_keyword, 1), + [219] = {.count = 1, .reusable = true}, REDUCE(sym_array, 3), + [221] = {.count = 1, .reusable = false}, REDUCE(sym_array, 3), + [223] = {.count = 1, .reusable = true}, REDUCE(sym_array_literal, 3), + [225] = {.count = 1, .reusable = false}, REDUCE(sym_array_literal, 3), + [227] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 3), + [229] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 3), + [231] = {.count = 1, .reusable = true}, REDUCE(sym_table, 3), + [233] = {.count = 1, .reusable = false}, REDUCE(sym_table, 3), + [235] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 3), + [237] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 3), + [239] = {.count = 1, .reusable = true}, REDUCE(sym_tuple_literal, 3), + [241] = {.count = 1, .reusable = false}, REDUCE(sym_tuple_literal, 3), + [243] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), +}; + +#ifdef __cplusplus +extern "C" { +#endif +void *tree_sitter_janet_external_scanner_create(void); +void tree_sitter_janet_external_scanner_destroy(void *); +bool tree_sitter_janet_external_scanner_scan(void *, TSLexer *, const bool *); +unsigned tree_sitter_janet_external_scanner_serialize(void *, char *); +void tree_sitter_janet_external_scanner_deserialize(void *, const char *, unsigned); + +#ifdef _WIN32 +#define extern __declspec(dllexport) +#endif + +extern const TSLanguage *tree_sitter_janet(void) { + static TSLanguage language = { + .version = LANGUAGE_VERSION, + .symbol_count = SYMBOL_COUNT, + .alias_count = ALIAS_COUNT, + .token_count = TOKEN_COUNT, + .large_state_count = LARGE_STATE_COUNT, + .symbol_metadata = ts_symbol_metadata, + .parse_table = (const unsigned short *)ts_parse_table, + .small_parse_table = (const uint16_t *)ts_small_parse_table, + .small_parse_table_map = (const uint32_t *)ts_small_parse_table_map, + .parse_actions = ts_parse_actions, + .lex_modes = ts_lex_modes, + .symbol_names = ts_symbol_names, + .public_symbol_map = ts_symbol_map, + .alias_sequences = (const TSSymbol *)ts_alias_sequences, + .field_count = FIELD_COUNT, + .max_alias_sequence_length = MAX_ALIAS_SEQUENCE_LENGTH, + .lex_fn = ts_lex, + .external_token_count = EXTERNAL_TOKEN_COUNT, + .external_scanner = { + (const bool *)ts_external_scanner_states, + ts_external_scanner_symbol_map, + tree_sitter_janet_external_scanner_create, + tree_sitter_janet_external_scanner_destroy, + tree_sitter_janet_external_scanner_scan, + tree_sitter_janet_external_scanner_serialize, + tree_sitter_janet_external_scanner_deserialize, + }, + }; + return &language; +} +#ifdef __cplusplus +} +#endif diff --git a/src/tree_sitter/parser.h b/src/tree_sitter/parser.h new file mode 100644 index 000000000..9df91f8c3 --- /dev/null +++ b/src/tree_sitter/parser.h @@ -0,0 +1,223 @@ +#ifndef TREE_SITTER_PARSER_H_ +#define TREE_SITTER_PARSER_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#include +#include + +#define ts_builtin_sym_error ((TSSymbol)-1) +#define ts_builtin_sym_end 0 +#define TREE_SITTER_SERIALIZATION_BUFFER_SIZE 1024 + +#ifndef TREE_SITTER_API_H_ +typedef uint16_t TSSymbol; +typedef uint16_t TSFieldId; +typedef struct TSLanguage TSLanguage; +#endif + +typedef struct { + TSFieldId field_id; + uint8_t child_index; + bool inherited; +} TSFieldMapEntry; + +typedef struct { + uint16_t index; + uint16_t length; +} TSFieldMapSlice; + +typedef uint16_t TSStateId; + +typedef struct { + bool visible : 1; + bool named : 1; +} TSSymbolMetadata; + +typedef struct TSLexer TSLexer; + +struct TSLexer { + int32_t lookahead; + TSSymbol result_symbol; + void (*advance)(TSLexer *, bool); + void (*mark_end)(TSLexer *); + uint32_t (*get_column)(TSLexer *); + bool (*is_at_included_range_start)(const TSLexer *); + bool (*eof)(const TSLexer *); +}; + +typedef enum { + TSParseActionTypeShift, + TSParseActionTypeReduce, + TSParseActionTypeAccept, + TSParseActionTypeRecover, +} TSParseActionType; + +typedef struct { + union { + struct { + TSStateId state; + bool extra : 1; + bool repetition : 1; + }; + struct { + TSSymbol symbol; + int16_t dynamic_precedence; + uint8_t child_count; + uint8_t production_id; + }; + } params; + TSParseActionType type : 4; +} TSParseAction; + +typedef struct { + uint16_t lex_state; + uint16_t external_lex_state; +} TSLexMode; + +typedef union { + TSParseAction action; + struct { + uint8_t count; + bool reusable : 1; + }; +} TSParseActionEntry; + +struct TSLanguage { + uint32_t version; + uint32_t symbol_count; + uint32_t alias_count; + uint32_t token_count; + uint32_t external_token_count; + const char **symbol_names; + const TSSymbolMetadata *symbol_metadata; + const uint16_t *parse_table; + const TSParseActionEntry *parse_actions; + const TSLexMode *lex_modes; + const TSSymbol *alias_sequences; + uint16_t max_alias_sequence_length; + bool (*lex_fn)(TSLexer *, TSStateId); + bool (*keyword_lex_fn)(TSLexer *, TSStateId); + TSSymbol keyword_capture_token; + struct { + const bool *states; + const TSSymbol *symbol_map; + void *(*create)(void); + void (*destroy)(void *); + bool (*scan)(void *, TSLexer *, const bool *symbol_whitelist); + unsigned (*serialize)(void *, char *); + void (*deserialize)(void *, const char *, unsigned); + } external_scanner; + uint32_t field_count; + const TSFieldMapSlice *field_map_slices; + const TSFieldMapEntry *field_map_entries; + const char **field_names; + uint32_t large_state_count; + const uint16_t *small_parse_table; + const uint32_t *small_parse_table_map; + const TSSymbol *public_symbol_map; +}; + +/* + * Lexer Macros + */ + +#define START_LEXER() \ + bool result = false; \ + bool skip = false; \ + bool eof = false; \ + int32_t lookahead; \ + goto start; \ + next_state: \ + lexer->advance(lexer, skip); \ + start: \ + skip = false; \ + lookahead = lexer->lookahead; + +#define ADVANCE(state_value) \ + { \ + state = state_value; \ + goto next_state; \ + } + +#define SKIP(state_value) \ + { \ + skip = true; \ + state = state_value; \ + goto next_state; \ + } + +#define ACCEPT_TOKEN(symbol_value) \ + result = true; \ + lexer->result_symbol = symbol_value; \ + lexer->mark_end(lexer); + +#define END_STATE() return result; + +/* + * Parse Table Macros + */ + +#define SMALL_STATE(id) id - LARGE_STATE_COUNT + +#define STATE(id) id + +#define ACTIONS(id) id + +#define SHIFT(state_value) \ + { \ + { \ + .type = TSParseActionTypeShift, \ + .params = {.state = state_value}, \ + } \ + } + +#define SHIFT_REPEAT(state_value) \ + { \ + { \ + .type = TSParseActionTypeShift, \ + .params = { \ + .state = state_value, \ + .repetition = true \ + }, \ + } \ + } + +#define RECOVER() \ + { \ + { .type = TSParseActionTypeRecover } \ + } + +#define SHIFT_EXTRA() \ + { \ + { \ + .type = TSParseActionTypeShift, \ + .params = {.extra = true} \ + } \ + } + +#define REDUCE(symbol_val, child_count_val, ...) \ + { \ + { \ + .type = TSParseActionTypeReduce, \ + .params = { \ + .symbol = symbol_val, \ + .child_count = child_count_val, \ + __VA_ARGS__ \ + } \ + } \ + } + +#define ACCEPT_INPUT() \ + { \ + { .type = TSParseActionTypeAccept } \ + } + +#ifdef __cplusplus +} +#endif + +#endif // TREE_SITTER_PARSER_H_ From c66c4bd2cd5f2d59bec0e8b0fa4aca8df2909335 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 11 Jan 2021 20:30:45 +0900 Subject: [PATCH 06/34] Rename to tree-sitter-janet-simple --- README.md | 18 +++++++++++------- binding.gyp | 2 +- grammar.js | 2 +- index.js | 4 ++-- package.json | 2 +- src/binding.cc | 8 ++++---- src/grammar.json | 8 ++++---- src/parser.c | 22 +++++++++++----------- src/scanner.cc | 17 ++++++++++------- 9 files changed, 45 insertions(+), 38 deletions(-) diff --git a/README.md b/README.md index 04eb4a5a5..d323cdb03 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,14 @@ -# tree-sitter-janet +# tree-sitter-janet-simple ## Status ~Subject to change, grammar still evolving.~ -Coincidentally, it appears [another effort by GrayJack](https://github.com/GrayJack/tree-sitter-janet/) was started at about the same time, and that effort looks to be pretty decent. So this effort will be put on hold. +Coincidentally, it appears [another effort by GrayJack](https://github.com/GrayJack/tree-sitter-janet/) was started at about the same time. + +The main difference between these two are that GrayJack's grammar supports higher level constructs (e.g. `def` is recognized by the grammar). + +There might end up being different trade-offs in either approach and my belief is that there is room in the world for multiple attempts (especially for lisp-like languages). ## Prerequisites @@ -24,14 +28,14 @@ Suppose typical development sources are stored under `~/src`. ``` # clone repository cd ~/src -git clone https://github.com/sogaiu/tree-sitter-janet -cd tree-sitter-janet +git clone https://github.com/sogaiu/tree-sitter-janet-simple +cd tree-sitter-janet-simple # create / populate # `node_modules` with dependencies # `src` with tree-sitter .c goodness # `build` -# `build/Release` and build `tree_sitter_janet_binding.node` +# `build/Release` and build `tree_sitter_janet_simple_binding.node` npm install # included in previous command @@ -92,7 +96,7 @@ Assuming emsdk is installed appropriately under `~/src/emsdk`. # prepare emsdk (specifically emcc) for use source ~/src/emsdk/emsdk_env.sh -# create `tree-sitter-janet.wasm` +# create `tree-sitter-janet-simple.wasm` npx tree-sitter build-wasm ``` @@ -105,5 +109,5 @@ npx tree-sitter build-wasm * Aerijo - Guide to your first Tree-sitter grammar * bakpakin - janet -* GrayJack - a better-looking attempt at tree-sitter-janet +* GrayJack - tree-sitter-janet * maxbrunsfeld - tree-sitter and related diff --git a/binding.gyp b/binding.gyp index 53b526b6c..c29bf5732 100644 --- a/binding.gyp +++ b/binding.gyp @@ -1,7 +1,7 @@ { "targets": [ { - "target_name": "tree_sitter_janet_binding", + "target_name": "tree_sitter_janet_simple_binding", "include_dirs": [ " [/\s/, $.comment], diff --git a/index.js b/index.js index 8e0ce96dc..0b35515e9 100644 --- a/index.js +++ b/index.js @@ -1,8 +1,8 @@ try { - module.exports = require("./build/Release/tree_sitter_janet_binding"); + module.exports = require("./build/Release/tree_sitter_janet_simple_binding"); } catch (error) { try { - module.exports = require("./build/Debug/tree_sitter_janet_binding"); + module.exports = require("./build/Debug/tree_sitter_janet_simple_binding"); } catch (_) { throw error } diff --git a/package.json b/package.json index d62a40024..7604cea42 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "tree-sitter-janet", + "name": "tree-sitter-janet-simple", "version": "0.0.1", "description": "Janet grammar for tree-sitter", "main": "index.js", diff --git a/src/binding.cc b/src/binding.cc index 028f15811..346560475 100644 --- a/src/binding.cc +++ b/src/binding.cc @@ -4,7 +4,7 @@ using namespace v8; -extern "C" TSLanguage * tree_sitter_janet(); +extern "C" TSLanguage * tree_sitter_janet_simple(); namespace { @@ -17,12 +17,12 @@ void Init(Local exports, Local module) { Local constructor = Nan::GetFunction(tpl).ToLocalChecked(); Local instance = constructor->NewInstance(Nan::GetCurrentContext()).ToLocalChecked(); - Nan::SetInternalFieldPointer(instance, 0, tree_sitter_janet()); + Nan::SetInternalFieldPointer(instance, 0, tree_sitter_janet_simple()); - Nan::Set(instance, Nan::New("name").ToLocalChecked(), Nan::New("janet").ToLocalChecked()); + Nan::Set(instance, Nan::New("name").ToLocalChecked(), Nan::New("janet_simple").ToLocalChecked()); Nan::Set(module, Nan::New("exports").ToLocalChecked(), instance); } -NODE_MODULE(tree_sitter_janet_binding, Init) +NODE_MODULE(tree_sitter_janet_simple_binding, Init) } // namespace diff --git a/src/grammar.json b/src/grammar.json index de57ecf8f..a6af4e28b 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -1,5 +1,5 @@ { - "name": "janet", + "name": "janet_simple", "rules": { "source_file": { "type": "REPEAT", @@ -126,7 +126,7 @@ "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-.\\/:@^_]" } } ] @@ -830,13 +830,13 @@ "members": [ { "type": "PATTERN", - "value": "[a-zA-Z!$%&*+\\-./:@^_]" + "value": "[a-zA-Z!$%&*+\\-.\\/:@^_]" }, { "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-.\\/:@^_]" } } ] diff --git a/src/parser.c b/src/parser.c index 69da9e2e8..b5904045d 100644 --- a/src/parser.c +++ b/src/parser.c @@ -2941,17 +2941,17 @@ static TSParseActionEntry ts_parse_actions[] = { #ifdef __cplusplus extern "C" { #endif -void *tree_sitter_janet_external_scanner_create(void); -void tree_sitter_janet_external_scanner_destroy(void *); -bool tree_sitter_janet_external_scanner_scan(void *, TSLexer *, const bool *); -unsigned tree_sitter_janet_external_scanner_serialize(void *, char *); -void tree_sitter_janet_external_scanner_deserialize(void *, const char *, unsigned); +void *tree_sitter_janet_simple_external_scanner_create(void); +void tree_sitter_janet_simple_external_scanner_destroy(void *); +bool tree_sitter_janet_simple_external_scanner_scan(void *, TSLexer *, const bool *); +unsigned tree_sitter_janet_simple_external_scanner_serialize(void *, char *); +void tree_sitter_janet_simple_external_scanner_deserialize(void *, const char *, unsigned); #ifdef _WIN32 #define extern __declspec(dllexport) #endif -extern const TSLanguage *tree_sitter_janet(void) { +extern const TSLanguage *tree_sitter_janet_simple(void) { static TSLanguage language = { .version = LANGUAGE_VERSION, .symbol_count = SYMBOL_COUNT, @@ -2974,11 +2974,11 @@ extern const TSLanguage *tree_sitter_janet(void) { .external_scanner = { (const bool *)ts_external_scanner_states, ts_external_scanner_symbol_map, - tree_sitter_janet_external_scanner_create, - tree_sitter_janet_external_scanner_destroy, - tree_sitter_janet_external_scanner_scan, - tree_sitter_janet_external_scanner_serialize, - tree_sitter_janet_external_scanner_deserialize, + tree_sitter_janet_simple_external_scanner_create, + tree_sitter_janet_simple_external_scanner_destroy, + tree_sitter_janet_simple_external_scanner_scan, + tree_sitter_janet_simple_external_scanner_serialize, + tree_sitter_janet_simple_external_scanner_deserialize, }, }; return &language; diff --git a/src/scanner.cc b/src/scanner.cc index b0c3bf92f..f7f291cb9 100644 --- a/src/scanner.cc +++ b/src/scanner.cc @@ -77,25 +77,28 @@ struct Scanner { extern "C" { -void *tree_sitter_janet_external_scanner_create() { +void *tree_sitter_janet_simple_external_scanner_create() { return new Scanner(); } -bool tree_sitter_janet_external_scanner_scan(void *payload, TSLexer *lexer, - const bool *valid_symbols) { +bool tree_sitter_janet_simple_external_scanner_scan( + void *payload, TSLexer *lexer, + const bool *valid_symbols) { Scanner *scanner = static_cast(payload); return scanner->scan(lexer, valid_symbols); } -unsigned tree_sitter_janet_external_scanner_serialize(void *payload, char *buffer) { +unsigned tree_sitter_janet_simple_external_scanner_serialize(void *payload, + char *buffer) { return 0; } -void tree_sitter_janet_external_scanner_deserialize(void *payload, const char *buffer, - unsigned length) { +void tree_sitter_janet_simple_external_scanner_deserialize(void *payload, + const char *buffer, + unsigned length) { } -void tree_sitter_janet_external_scanner_destroy(void *payload) { +void tree_sitter_janet_simple_external_scanner_destroy(void *payload) { Scanner *scanner = static_cast(payload); delete scanner; } From 68cb312adff9655ff5e7ce707580660cf3552548 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 11 Jan 2021 21:05:41 +0900 Subject: [PATCH 07/34] Use "bracket" in names --- grammar.js | 8 +- src/grammar.json | 8 +- src/node-types.json | 210 ++++++++++++++++++++++---------------------- src/parser.c | 112 +++++++++++------------ 4 files changed, 169 insertions(+), 169 deletions(-) diff --git a/grammar.js b/grammar.js index 35a368a32..24ce9d598 100644 --- a/grammar.js +++ b/grammar.js @@ -56,11 +56,11 @@ module.exports = grammar({ $.symbol, // $.array, - $.array_literal, + $.bracket_array, $.struct, $.table, $.tuple, - $.tuple_literal, + $.bracket_tuple, // $.quasi_quote_form, $.quote_form, @@ -153,7 +153,7 @@ module.exports = grammar({ repeat($._form), ')'), - array_literal: $ => + bracket_array: $ => seq('@[', repeat($._form), ']'), @@ -173,7 +173,7 @@ module.exports = grammar({ repeat($._form), ')'), - tuple_literal: $ => + bracket_tuple: $ => seq('[', repeat($._form), ']'), diff --git a/src/grammar.json b/src/grammar.json index a6af4e28b..57bc5bad5 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -57,7 +57,7 @@ }, { "type": "SYMBOL", - "name": "array_literal" + "name": "bracket_array" }, { "type": "SYMBOL", @@ -73,7 +73,7 @@ }, { "type": "SYMBOL", - "name": "tuple_literal" + "name": "bracket_tuple" }, { "type": "SYMBOL", @@ -862,7 +862,7 @@ } ] }, - "array_literal": { + "bracket_array": { "type": "SEQ", "members": [ { @@ -942,7 +942,7 @@ } ] }, - "tuple_literal": { + "bracket_tuple": { "type": "SEQ", "members": [ { diff --git a/src/node-types.json b/src/node-types.json index 3c9d52a7d..471bc3e2d 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -12,11 +12,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -79,10 +83,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -91,7 +91,12 @@ } }, { - "type": "array_literal", + "type": "boolean", + "named": true, + "fields": {} + }, + { + "type": "bracket_array", "named": true, "fields": {}, "children": { @@ -103,11 +108,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -170,10 +179,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -182,38 +187,27 @@ } }, { - "type": "boolean", - "named": true, - "fields": {} - }, - { - "type": "keyword", - "named": true, - "fields": {} - }, - { - "type": "number", - "named": true, - "fields": {} - }, - { - "type": "quasi_quote_form", + "type": "bracket_tuple", "named": true, "fields": {}, "children": { - "multiple": false, - "required": true, + "multiple": true, + "required": false, "types": [ { "type": "array", "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -276,10 +270,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -288,7 +278,17 @@ } }, { - "type": "quote_form", + "type": "keyword", + "named": true, + "fields": {} + }, + { + "type": "number", + "named": true, + "fields": {} + }, + { + "type": "quasi_quote_form", "named": true, "fields": {}, "children": { @@ -300,11 +300,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -367,10 +371,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -379,7 +379,7 @@ } }, { - "type": "short_fn_form", + "type": "quote_form", "named": true, "fields": {}, "children": { @@ -391,11 +391,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -458,10 +462,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -470,23 +470,27 @@ } }, { - "type": "source_file", + "type": "short_fn_form", "named": true, "fields": {}, "children": { - "multiple": true, - "required": false, + "multiple": false, + "required": true, "types": [ { "type": "array", "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -549,10 +553,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -561,23 +561,27 @@ } }, { - "type": "splice_form", + "type": "source_file", "named": true, "fields": {}, "children": { - "multiple": false, - "required": true, + "multiple": true, + "required": false, "types": [ { "type": "array", "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -640,10 +644,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -652,23 +652,27 @@ } }, { - "type": "struct", + "type": "splice_form", "named": true, "fields": {}, "children": { - "multiple": true, - "required": false, + "multiple": false, + "required": true, "types": [ { "type": "array", "named": true }, { - "type": "array_literal", + "type": "boolean", + "named": true + }, + { + "type": "bracket_array", "named": true }, { - "type": "boolean", + "type": "bracket_tuple", "named": true }, { @@ -731,10 +735,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -743,7 +743,7 @@ } }, { - "type": "table", + "type": "struct", "named": true, "fields": {}, "children": { @@ -755,11 +755,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", + "named": true + }, + { + "type": "bracket_array", "named": true }, { - "type": "boolean", + "type": "bracket_tuple", "named": true }, { @@ -822,10 +826,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -834,7 +834,7 @@ } }, { - "type": "tuple", + "type": "table", "named": true, "fields": {}, "children": { @@ -846,11 +846,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", + "named": true + }, + { + "type": "bracket_array", "named": true }, { - "type": "boolean", + "type": "bracket_tuple", "named": true }, { @@ -913,10 +917,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -925,7 +925,7 @@ } }, { - "type": "tuple_literal", + "type": "tuple", "named": true, "fields": {}, "children": { @@ -937,11 +937,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -1004,10 +1008,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true @@ -1028,11 +1028,15 @@ "named": true }, { - "type": "array_literal", + "type": "boolean", "named": true }, { - "type": "boolean", + "type": "bracket_array", + "named": true + }, + { + "type": "bracket_tuple", "named": true }, { @@ -1095,10 +1099,6 @@ "type": "tuple", "named": true }, - { - "type": "tuple_literal", - "named": true - }, { "type": "unquote_form", "named": true diff --git a/src/parser.c b/src/parser.c index b5904045d..efb1e718d 100644 --- a/src/parser.c +++ b/src/parser.c @@ -49,11 +49,11 @@ enum { sym_keyword = 31, sym_number = 32, sym_array = 33, - sym_array_literal = 34, + sym_bracket_array = 34, sym_struct = 35, sym_table = 36, sym_tuple = 37, - sym_tuple_literal = 38, + sym_bracket_tuple = 38, sym_quasi_quote_form = 39, sym_quote_form = 40, sym_short_fn_form = 41, @@ -97,11 +97,11 @@ static const char *ts_symbol_names[] = { [sym_keyword] = "keyword", [sym_number] = "number", [sym_array] = "array", - [sym_array_literal] = "array_literal", + [sym_bracket_array] = "bracket_array", [sym_struct] = "struct", [sym_table] = "table", [sym_tuple] = "tuple", - [sym_tuple_literal] = "tuple_literal", + [sym_bracket_tuple] = "bracket_tuple", [sym_quasi_quote_form] = "quasi_quote_form", [sym_quote_form] = "quote_form", [sym_short_fn_form] = "short_fn_form", @@ -145,11 +145,11 @@ static TSSymbol ts_symbol_map[] = { [sym_keyword] = sym_keyword, [sym_number] = sym_number, [sym_array] = sym_array, - [sym_array_literal] = sym_array_literal, + [sym_bracket_array] = sym_bracket_array, [sym_struct] = sym_struct, [sym_table] = sym_table, [sym_tuple] = sym_tuple, - [sym_tuple_literal] = sym_tuple_literal, + [sym_bracket_tuple] = sym_bracket_tuple, [sym_quasi_quote_form] = sym_quasi_quote_form, [sym_quote_form] = sym_quote_form, [sym_short_fn_form] = sym_short_fn_form, @@ -295,7 +295,7 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym_array_literal] = { + [sym_bracket_array] = { .visible = true, .named = true, }, @@ -311,7 +311,7 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym_tuple_literal] = { + [sym_bracket_tuple] = { .visible = true, .named = true, }, @@ -1359,11 +1359,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(12), [sym_number] = STATE(12), [sym_array] = STATE(12), - [sym_array_literal] = STATE(12), + [sym_bracket_array] = STATE(12), [sym_struct] = STATE(12), [sym_table] = STATE(12), [sym_tuple] = STATE(12), - [sym_tuple_literal] = STATE(12), + [sym_bracket_tuple] = STATE(12), [sym_quasi_quote_form] = STATE(12), [sym_quote_form] = STATE(12), [sym_short_fn_form] = STATE(12), @@ -1402,11 +1402,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1448,11 +1448,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(15), [sym_number] = STATE(15), [sym_array] = STATE(15), - [sym_array_literal] = STATE(15), + [sym_bracket_array] = STATE(15), [sym_struct] = STATE(15), [sym_table] = STATE(15), [sym_tuple] = STATE(15), - [sym_tuple_literal] = STATE(15), + [sym_bracket_tuple] = STATE(15), [sym_quasi_quote_form] = STATE(15), [sym_quote_form] = STATE(15), [sym_short_fn_form] = STATE(15), @@ -1491,11 +1491,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1534,11 +1534,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(14), [sym_number] = STATE(14), [sym_array] = STATE(14), - [sym_array_literal] = STATE(14), + [sym_bracket_array] = STATE(14), [sym_struct] = STATE(14), [sym_table] = STATE(14), [sym_tuple] = STATE(14), - [sym_tuple_literal] = STATE(14), + [sym_bracket_tuple] = STATE(14), [sym_quasi_quote_form] = STATE(14), [sym_quote_form] = STATE(14), [sym_short_fn_form] = STATE(14), @@ -1577,11 +1577,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(10), [sym_number] = STATE(10), [sym_array] = STATE(10), - [sym_array_literal] = STATE(10), + [sym_bracket_array] = STATE(10), [sym_struct] = STATE(10), [sym_table] = STATE(10), [sym_tuple] = STATE(10), - [sym_tuple_literal] = STATE(10), + [sym_bracket_tuple] = STATE(10), [sym_quasi_quote_form] = STATE(10), [sym_quote_form] = STATE(10), [sym_short_fn_form] = STATE(10), @@ -1620,11 +1620,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(13), [sym_number] = STATE(13), [sym_array] = STATE(13), - [sym_array_literal] = STATE(13), + [sym_bracket_array] = STATE(13), [sym_struct] = STATE(13), [sym_table] = STATE(13), [sym_tuple] = STATE(13), - [sym_tuple_literal] = STATE(13), + [sym_bracket_tuple] = STATE(13), [sym_quasi_quote_form] = STATE(13), [sym_quote_form] = STATE(13), [sym_short_fn_form] = STATE(13), @@ -1663,11 +1663,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(11), [sym_number] = STATE(11), [sym_array] = STATE(11), - [sym_array_literal] = STATE(11), + [sym_bracket_array] = STATE(11), [sym_struct] = STATE(11), [sym_table] = STATE(11), [sym_tuple] = STATE(11), - [sym_tuple_literal] = STATE(11), + [sym_bracket_tuple] = STATE(11), [sym_quasi_quote_form] = STATE(11), [sym_quote_form] = STATE(11), [sym_short_fn_form] = STATE(11), @@ -1706,11 +1706,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(4), [sym_number] = STATE(4), [sym_array] = STATE(4), - [sym_array_literal] = STATE(4), + [sym_bracket_array] = STATE(4), [sym_struct] = STATE(4), [sym_table] = STATE(4), [sym_tuple] = STATE(4), - [sym_tuple_literal] = STATE(4), + [sym_bracket_tuple] = STATE(4), [sym_quasi_quote_form] = STATE(4), [sym_quote_form] = STATE(4), [sym_short_fn_form] = STATE(4), @@ -1749,11 +1749,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1792,11 +1792,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1835,11 +1835,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1878,11 +1878,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1921,11 +1921,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1964,11 +1964,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(2), [sym_number] = STATE(2), [sym_array] = STATE(2), - [sym_array_literal] = STATE(2), + [sym_bracket_array] = STATE(2), [sym_struct] = STATE(2), [sym_table] = STATE(2), [sym_tuple] = STATE(2), - [sym_tuple_literal] = STATE(2), + [sym_bracket_tuple] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -2007,11 +2007,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(29), [sym_number] = STATE(29), [sym_array] = STATE(29), - [sym_array_literal] = STATE(29), + [sym_bracket_array] = STATE(29), [sym_struct] = STATE(29), [sym_table] = STATE(29), [sym_tuple] = STATE(29), - [sym_tuple_literal] = STATE(29), + [sym_bracket_tuple] = STATE(29), [sym_quasi_quote_form] = STATE(29), [sym_quote_form] = STATE(29), [sym_short_fn_form] = STATE(29), @@ -2048,11 +2048,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(30), [sym_number] = STATE(30), [sym_array] = STATE(30), - [sym_array_literal] = STATE(30), + [sym_bracket_array] = STATE(30), [sym_struct] = STATE(30), [sym_table] = STATE(30), [sym_tuple] = STATE(30), - [sym_tuple_literal] = STATE(30), + [sym_bracket_tuple] = STATE(30), [sym_quasi_quote_form] = STATE(30), [sym_quote_form] = STATE(30), [sym_short_fn_form] = STATE(30), @@ -2089,11 +2089,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(31), [sym_number] = STATE(31), [sym_array] = STATE(31), - [sym_array_literal] = STATE(31), + [sym_bracket_array] = STATE(31), [sym_struct] = STATE(31), [sym_table] = STATE(31), [sym_tuple] = STATE(31), - [sym_tuple_literal] = STATE(31), + [sym_bracket_tuple] = STATE(31), [sym_quasi_quote_form] = STATE(31), [sym_quote_form] = STATE(31), [sym_short_fn_form] = STATE(31), @@ -2130,11 +2130,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(32), [sym_number] = STATE(32), [sym_array] = STATE(32), - [sym_array_literal] = STATE(32), + [sym_bracket_array] = STATE(32), [sym_struct] = STATE(32), [sym_table] = STATE(32), [sym_tuple] = STATE(32), - [sym_tuple_literal] = STATE(32), + [sym_bracket_tuple] = STATE(32), [sym_quasi_quote_form] = STATE(32), [sym_quote_form] = STATE(32), [sym_short_fn_form] = STATE(32), @@ -2171,11 +2171,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_keyword] = STATE(33), [sym_number] = STATE(33), [sym_array] = STATE(33), - [sym_array_literal] = STATE(33), + [sym_bracket_array] = STATE(33), [sym_struct] = STATE(33), [sym_table] = STATE(33), [sym_tuple] = STATE(33), - [sym_tuple_literal] = STATE(33), + [sym_bracket_tuple] = STATE(33), [sym_quasi_quote_form] = STATE(33), [sym_quote_form] = STATE(33), [sym_short_fn_form] = STATE(33), @@ -2895,8 +2895,8 @@ static TSParseActionEntry ts_parse_actions[] = { [157] = {.count = 1, .reusable = true}, SHIFT(32), [159] = {.count = 1, .reusable = false}, SHIFT(33), [161] = {.count = 1, .reusable = true}, SHIFT(33), - [163] = {.count = 1, .reusable = true}, REDUCE(sym_array_literal, 2), - [165] = {.count = 1, .reusable = false}, REDUCE(sym_array_literal, 2), + [163] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_array, 2), + [165] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_array, 2), [167] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 2), [169] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 2), [171] = {.count = 1, .reusable = true}, REDUCE(sym_boolean, 1), @@ -2907,8 +2907,8 @@ static TSParseActionEntry ts_parse_actions[] = { [181] = {.count = 1, .reusable = false}, REDUCE(sym_array, 2), [183] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 2), [185] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 2), - [187] = {.count = 1, .reusable = true}, REDUCE(sym_tuple_literal, 2), - [189] = {.count = 1, .reusable = false}, REDUCE(sym_tuple_literal, 2), + [187] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_tuple, 2), + [189] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_tuple, 2), [191] = {.count = 1, .reusable = true}, REDUCE(sym_number, 1), [193] = {.count = 1, .reusable = false}, REDUCE(sym_number, 1), [195] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), @@ -2925,16 +2925,16 @@ static TSParseActionEntry ts_parse_actions[] = { [217] = {.count = 1, .reusable = false}, REDUCE(sym_keyword, 1), [219] = {.count = 1, .reusable = true}, REDUCE(sym_array, 3), [221] = {.count = 1, .reusable = false}, REDUCE(sym_array, 3), - [223] = {.count = 1, .reusable = true}, REDUCE(sym_array_literal, 3), - [225] = {.count = 1, .reusable = false}, REDUCE(sym_array_literal, 3), + [223] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_array, 3), + [225] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_array, 3), [227] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 3), [229] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 3), [231] = {.count = 1, .reusable = true}, REDUCE(sym_table, 3), [233] = {.count = 1, .reusable = false}, REDUCE(sym_table, 3), [235] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 3), [237] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 3), - [239] = {.count = 1, .reusable = true}, REDUCE(sym_tuple_literal, 3), - [241] = {.count = 1, .reusable = false}, REDUCE(sym_tuple_literal, 3), + [239] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_tuple, 3), + [241] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_tuple, 3), [243] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), }; From 45a5c0adc17e25cb635f72557ac066e7ccd479a3 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 11 Jan 2021 22:19:24 +0900 Subject: [PATCH 08/34] Update README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index d323cdb03..b635f81a6 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ ## Status -~Subject to change, grammar still evolving.~ +Subject to change, grammar still evolving. Coincidentally, it appears [another effort by GrayJack](https://github.com/GrayJack/tree-sitter-janet/) was started at about the same time. From 8d99a782473bcdf99db075156468b68f56871722 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 11 Jan 2021 22:21:07 +0900 Subject: [PATCH 09/34] Tweak README again --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index b635f81a6..4364e52ff 100644 --- a/README.md +++ b/README.md @@ -70,10 +70,10 @@ npx tree-sitter web-ui Parse individual files. ``` -# create and populate sample code file for parsing named `sample.clj` +# create and populate sample code file for parsing named `sample.janet` # parse sample file -npx tree-sitter parse sample.clj +npx tree-sitter parse sample.janet # examine output similar to web-ui, but less convenient ``` @@ -82,10 +82,10 @@ npx tree-sitter parse sample.clj ``` # single measurement -npx tree-sitter parse --time sample.clj +npx tree-sitter parse --time sample.janet # mutliple measurements with `multitime` -multitime -n10 -s1 npx tree-sitter parse --time --quiet sample.clj +multitime -n10 -s1 npx tree-sitter parse --time --quiet sample.janet ``` ## Build .wasm From a89ebab6e5daf690505971e33c92bb910efb63dc Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sat, 16 Jan 2021 18:57:54 +0900 Subject: [PATCH 10/34] Rename source_file to source --- grammar.js | 2 +- src/grammar.json | 2 +- src/node-types.json | 2 +- src/parser.c | 86 ++++++++++++++++++++++----------------------- 4 files changed, 46 insertions(+), 46 deletions(-) diff --git a/grammar.js b/grammar.js index 24ce9d598..2734df6d3 100644 --- a/grammar.js +++ b/grammar.js @@ -38,7 +38,7 @@ module.exports = grammar({ rules: { // THIS MUST BE FIRST -- even though this doesn't look like it matters - source_file: $ => + source: $ => repeat($._form), comment: $ => diff --git a/src/grammar.json b/src/grammar.json index 57bc5bad5..b3214f3e8 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -1,7 +1,7 @@ { "name": "janet_simple", "rules": { - "source_file": { + "source": { "type": "REPEAT", "content": { "type": "SYMBOL", diff --git a/src/node-types.json b/src/node-types.json index 471bc3e2d..ac4791060 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -561,7 +561,7 @@ } }, { - "type": "source_file", + "type": "source", "named": true, "fields": {}, "children": { diff --git a/src/parser.c b/src/parser.c index efb1e718d..e2436a0e3 100644 --- a/src/parser.c +++ b/src/parser.c @@ -43,7 +43,7 @@ enum { anon_sym_COMMA = 25, sym_long_buffer = 26, sym_long_string = 27, - sym_source_file = 28, + sym_source = 28, sym__form = 29, sym_boolean = 30, sym_keyword = 31, @@ -59,7 +59,7 @@ enum { sym_short_fn_form = 41, sym_splice_form = 42, sym_unquote_form = 43, - aux_sym_source_file_repeat1 = 44, + aux_sym_source_repeat1 = 44, }; static const char *ts_symbol_names[] = { @@ -91,7 +91,7 @@ static const char *ts_symbol_names[] = { [anon_sym_COMMA] = ",", [sym_long_buffer] = "long_buffer", [sym_long_string] = "long_string", - [sym_source_file] = "source_file", + [sym_source] = "source", [sym__form] = "_form", [sym_boolean] = "boolean", [sym_keyword] = "keyword", @@ -107,7 +107,7 @@ static const char *ts_symbol_names[] = { [sym_short_fn_form] = "short_fn_form", [sym_splice_form] = "splice_form", [sym_unquote_form] = "unquote_form", - [aux_sym_source_file_repeat1] = "source_file_repeat1", + [aux_sym_source_repeat1] = "source_repeat1", }; static TSSymbol ts_symbol_map[] = { @@ -139,7 +139,7 @@ static TSSymbol ts_symbol_map[] = { [anon_sym_COMMA] = anon_sym_COMMA, [sym_long_buffer] = sym_long_buffer, [sym_long_string] = sym_long_string, - [sym_source_file] = sym_source_file, + [sym_source] = sym_source, [sym__form] = sym__form, [sym_boolean] = sym_boolean, [sym_keyword] = sym_keyword, @@ -155,7 +155,7 @@ static TSSymbol ts_symbol_map[] = { [sym_short_fn_form] = sym_short_fn_form, [sym_splice_form] = sym_splice_form, [sym_unquote_form] = sym_unquote_form, - [aux_sym_source_file_repeat1] = aux_sym_source_file_repeat1, + [aux_sym_source_repeat1] = aux_sym_source_repeat1, }; static const TSSymbolMetadata ts_symbol_metadata[] = { @@ -271,7 +271,7 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym_source_file] = { + [sym_source] = { .visible = true, .named = true, }, @@ -335,7 +335,7 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [aux_sym_source_file_repeat1] = { + [aux_sym_source_repeat1] = { .visible = false, .named = false, }, @@ -1353,7 +1353,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_string] = ACTIONS(1), }, [1] = { - [sym_source_file] = STATE(41), + [sym_source] = STATE(41), [sym__form] = STATE(12), [sym_boolean] = STATE(12), [sym_keyword] = STATE(12), @@ -1369,7 +1369,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(12), [sym_splice_form] = STATE(12), [sym_unquote_form] = STATE(12), - [aux_sym_source_file_repeat1] = STATE(12), + [aux_sym_source_repeat1] = STATE(12), [ts_builtin_sym_end] = ACTIONS(5), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), @@ -1412,7 +1412,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [ts_builtin_sym_end] = ACTIONS(39), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(41), @@ -1458,7 +1458,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(15), [sym_splice_form] = STATE(15), [sym_unquote_form] = STATE(15), - [aux_sym_source_file_repeat1] = STATE(15), + [aux_sym_source_repeat1] = STATE(15), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1501,7 +1501,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1544,7 +1544,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(14), [sym_splice_form] = STATE(14), [sym_unquote_form] = STATE(14), - [aux_sym_source_file_repeat1] = STATE(14), + [aux_sym_source_repeat1] = STATE(14), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1587,7 +1587,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(10), [sym_splice_form] = STATE(10), [sym_unquote_form] = STATE(10), - [aux_sym_source_file_repeat1] = STATE(10), + [aux_sym_source_repeat1] = STATE(10), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1630,7 +1630,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(13), [sym_splice_form] = STATE(13), [sym_unquote_form] = STATE(13), - [aux_sym_source_file_repeat1] = STATE(13), + [aux_sym_source_repeat1] = STATE(13), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1673,7 +1673,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(11), [sym_splice_form] = STATE(11), [sym_unquote_form] = STATE(11), - [aux_sym_source_file_repeat1] = STATE(11), + [aux_sym_source_repeat1] = STATE(11), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1716,7 +1716,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(4), [sym_splice_form] = STATE(4), [sym_unquote_form] = STATE(4), - [aux_sym_source_file_repeat1] = STATE(4), + [aux_sym_source_repeat1] = STATE(4), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1759,7 +1759,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1802,7 +1802,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1845,7 +1845,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [ts_builtin_sym_end] = ACTIONS(135), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), @@ -1888,7 +1888,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1931,7 +1931,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -1974,7 +1974,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_short_fn_form] = STATE(2), [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), - [aux_sym_source_file_repeat1] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), @@ -2824,7 +2824,7 @@ static TSParseActionEntry ts_parse_actions[] = { [0] = {.count = 0, .reusable = false}, [1] = {.count = 1, .reusable = false}, RECOVER(), [3] = {.count = 1, .reusable = true}, SHIFT_EXTRA(), - [5] = {.count = 1, .reusable = true}, REDUCE(sym_source_file, 0), + [5] = {.count = 1, .reusable = true}, REDUCE(sym_source, 0), [7] = {.count = 1, .reusable = false}, SHIFT(23), [9] = {.count = 1, .reusable = true}, SHIFT(34), [11] = {.count = 1, .reusable = false}, SHIFT(12), @@ -2841,23 +2841,23 @@ static TSParseActionEntry ts_parse_actions[] = { [33] = {.count = 1, .reusable = true}, SHIFT(18), [35] = {.count = 1, .reusable = true}, SHIFT(19), [37] = {.count = 1, .reusable = true}, SHIFT(20), - [39] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), - [41] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(23), - [44] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(34), - [47] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(2), - [50] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(28), - [53] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(2), - [56] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(5), - [59] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(6), - [62] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(7), - [65] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(8), - [68] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(9), - [71] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(3), - [74] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(16), - [77] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(17), - [80] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(18), - [83] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(19), - [86] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(20), + [39] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), + [41] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(23), + [44] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(34), + [47] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [50] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(28), + [53] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [56] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(5), + [59] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(6), + [62] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(7), + [65] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(8), + [68] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(9), + [71] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(3), + [74] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(16), + [77] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(17), + [80] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(18), + [83] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(19), + [86] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(20), [89] = {.count = 1, .reusable = false}, SHIFT(15), [91] = {.count = 1, .reusable = true}, SHIFT(15), [93] = {.count = 1, .reusable = true}, SHIFT(27), @@ -2881,7 +2881,7 @@ static TSParseActionEntry ts_parse_actions[] = { [129] = {.count = 1, .reusable = true}, SHIFT(26), [131] = {.count = 1, .reusable = true}, SHIFT(36), [133] = {.count = 1, .reusable = true}, SHIFT(38), - [135] = {.count = 1, .reusable = true}, REDUCE(sym_source_file, 1), + [135] = {.count = 1, .reusable = true}, REDUCE(sym_source, 1), [137] = {.count = 1, .reusable = true}, SHIFT(37), [139] = {.count = 1, .reusable = true}, SHIFT(35), [141] = {.count = 1, .reusable = true}, SHIFT(40), From 24ff63fce75c4fcf96662d332261468634bd7ba6 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 25 Jan 2021 17:53:05 +0900 Subject: [PATCH 11/34] Rename nodes --- grammar.js | 60 +-- src/grammar.json | 66 +-- src/node-types.json | 512 +++++++++---------- src/parser.c | 1186 +++++++++++++++++++++---------------------- src/scanner.cc | 8 +- 5 files changed, 916 insertions(+), 916 deletions(-) diff --git a/grammar.js b/grammar.js index 2734df6d3..d6242eb51 100644 --- a/grammar.js +++ b/grammar.js @@ -32,8 +32,8 @@ module.exports = grammar({ [/\s/, $.comment], externals: $ => [ - $.long_buffer, - $.long_string + $.long_buf_lit, + $.long_str_lit ], rules: { @@ -45,22 +45,22 @@ module.exports = grammar({ /#.*/, _form: $ => - choice($.boolean, - $.buffer, - $.keyword, - $.long_buffer, - $.long_string, - $.nil, - $.number, - $.string, - $.symbol, + choice($.bool_lit, + $.buf_lit, + $.kwd_lit, + $.long_buf_lit, + $.long_str_lit, + $.nil_lit, + $.num_lit, + $.str_lit, + $.sym_lit, // - $.array, - $.bracket_array, - $.struct, - $.table, - $.tuple, - $.bracket_tuple, + $.par_arr_lit, + $.sqr_arr_lit, + $.struct_lit, + $.tbl_lit, + $.par_tup_lit, + $.sqr_tup_lit, // $.quasi_quote_form, $.quote_form, @@ -70,18 +70,18 @@ module.exports = grammar({ // simplest things - boolean: $ => + bool_lit: $ => choice('false', 'true'), - keyword: $ => + kwd_lit: $ => prec(2, token(seq(':', repeat(SYM_CHAR)))), - nil: $ => + nil_lit: $ => 'nil', - number: $ => + num_lit: $ => prec(5, choice($._dec, $._hex, $._radix)), @@ -132,48 +132,48 @@ module.exports = grammar({ optional(SIGN), repeat1(DIGIT)))))), - string: $ => + str_lit: $ => token(seq('"', STRING_DOUBLE_QUOTE_CONTENT, '"')), - buffer: $ => + buf_lit: $ => token(seq('@"', STRING_DOUBLE_QUOTE_CONTENT, '"')), - symbol: $ => + sym_lit: $ => token(seq(SYM_CHAR_NO_DIGIT_NO_COLON, repeat(SYM_CHAR))), // collection-ish things - array: $ => + par_arr_lit: $ => seq('@(', repeat($._form), ')'), - bracket_array: $ => + sqr_arr_lit: $ => seq('@[', repeat($._form), ']'), - struct: $ => + struct_lit: $ => seq('{', repeat($._form), '}'), - table: $ => + tbl_lit: $ => seq('@{', repeat($._form), '}'), - tuple: $ => + par_tup_lit: $ => seq('(', repeat($._form), ')'), - bracket_tuple: $ => + sqr_tup_lit: $ => seq('[', repeat($._form), ']'), diff --git a/src/grammar.json b/src/grammar.json index b3214f3e8..f93a9d41a 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -17,63 +17,63 @@ "members": [ { "type": "SYMBOL", - "name": "boolean" + "name": "bool_lit" }, { "type": "SYMBOL", - "name": "buffer" + "name": "buf_lit" }, { "type": "SYMBOL", - "name": "keyword" + "name": "kwd_lit" }, { "type": "SYMBOL", - "name": "long_buffer" + "name": "long_buf_lit" }, { "type": "SYMBOL", - "name": "long_string" + "name": "long_str_lit" }, { "type": "SYMBOL", - "name": "nil" + "name": "nil_lit" }, { "type": "SYMBOL", - "name": "number" + "name": "num_lit" }, { "type": "SYMBOL", - "name": "string" + "name": "str_lit" }, { "type": "SYMBOL", - "name": "symbol" + "name": "sym_lit" }, { "type": "SYMBOL", - "name": "array" + "name": "par_arr_lit" }, { "type": "SYMBOL", - "name": "bracket_array" + "name": "sqr_arr_lit" }, { "type": "SYMBOL", - "name": "struct" + "name": "struct_lit" }, { "type": "SYMBOL", - "name": "table" + "name": "tbl_lit" }, { "type": "SYMBOL", - "name": "tuple" + "name": "par_tup_lit" }, { "type": "SYMBOL", - "name": "bracket_tuple" + "name": "sqr_tup_lit" }, { "type": "SYMBOL", @@ -97,7 +97,7 @@ } ] }, - "boolean": { + "bool_lit": { "type": "CHOICE", "members": [ { @@ -110,7 +110,7 @@ } ] }, - "keyword": { + "kwd_lit": { "type": "PREC", "value": 2, "content": { @@ -126,18 +126,18 @@ "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-.\\/:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" } } ] } } }, - "nil": { + "nil_lit": { "type": "STRING", "value": "nil" }, - "number": { + "num_lit": { "type": "PREC", "value": 5, "content": { @@ -759,7 +759,7 @@ ] } }, - "string": { + "str_lit": { "type": "TOKEN", "content": { "type": "SEQ", @@ -791,7 +791,7 @@ ] } }, - "buffer": { + "buf_lit": { "type": "TOKEN", "content": { "type": "SEQ", @@ -823,26 +823,26 @@ ] } }, - "symbol": { + "sym_lit": { "type": "TOKEN", "content": { "type": "SEQ", "members": [ { "type": "PATTERN", - "value": "[a-zA-Z!$%&*+\\-.\\/:@^_]" + "value": "[a-zA-Z!$%&*+\\-./:@^_]" }, { "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-.\\/:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" } } ] } }, - "array": { + "par_arr_lit": { "type": "SEQ", "members": [ { @@ -862,7 +862,7 @@ } ] }, - "bracket_array": { + "sqr_arr_lit": { "type": "SEQ", "members": [ { @@ -882,7 +882,7 @@ } ] }, - "struct": { + "struct_lit": { "type": "SEQ", "members": [ { @@ -902,7 +902,7 @@ } ] }, - "table": { + "tbl_lit": { "type": "SEQ", "members": [ { @@ -922,7 +922,7 @@ } ] }, - "tuple": { + "par_tup_lit": { "type": "SEQ", "members": [ { @@ -942,7 +942,7 @@ } ] }, - "bracket_tuple": { + "sqr_tup_lit": { "type": "SEQ", "members": [ { @@ -1042,11 +1042,11 @@ "externals": [ { "type": "SYMBOL", - "name": "long_buffer" + "name": "long_buf_lit" }, { "type": "SYMBOL", - "name": "long_string" + "name": "long_str_lit" } ], "inline": [], diff --git a/src/node-types.json b/src/node-types.json index ac4791060..8d7b131aa 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -1,6 +1,21 @@ [ { - "type": "array", + "type": "bool_lit", + "named": true, + "fields": {} + }, + { + "type": "kwd_lit", + "named": true, + "fields": {} + }, + { + "type": "num_lit", + "named": true, + "fields": {} + }, + { + "type": "par_arr_lit", "named": true, "fields": {}, "children": { @@ -8,43 +23,39 @@ "required": false, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -64,23 +75,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", "named": true }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true }, { - "type": "symbol", + "type": "str_lit", "named": true }, { - "type": "table", + "type": "struct_lit", "named": true }, { - "type": "tuple", + "type": "sym_lit", + "named": true + }, + { + "type": "tbl_lit", "named": true }, { @@ -91,12 +106,7 @@ } }, { - "type": "boolean", - "named": true, - "fields": {} - }, - { - "type": "bracket_array", + "type": "par_tup_lit", "named": true, "fields": {}, "children": { @@ -104,43 +114,39 @@ "required": false, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -160,23 +166,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -187,51 +197,47 @@ } }, { - "type": "bracket_tuple", + "type": "quasi_quote_form", "named": true, "fields": {}, "children": { - "multiple": true, - "required": false, + "multiple": false, + "required": true, "types": [ { - "type": "array", - "named": true - }, - { - "type": "boolean", + "type": "bool_lit", "named": true }, { - "type": "bracket_array", + "type": "buf_lit", "named": true }, { - "type": "bracket_tuple", + "type": "kwd_lit", "named": true }, { - "type": "buffer", + "type": "long_buf_lit", "named": true }, { - "type": "keyword", + "type": "long_str_lit", "named": true }, { - "type": "long_buffer", + "type": "nil_lit", "named": true }, { - "type": "long_string", + "type": "num_lit", "named": true }, { - "type": "nil", + "type": "par_arr_lit", "named": true }, { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -251,23 +257,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -278,17 +288,7 @@ } }, { - "type": "keyword", - "named": true, - "fields": {} - }, - { - "type": "number", - "named": true, - "fields": {} - }, - { - "type": "quasi_quote_form", + "type": "quote_form", "named": true, "fields": {}, "children": { @@ -296,43 +296,39 @@ "required": true, "types": [ { - "type": "array", - "named": true - }, - { - "type": "boolean", + "type": "bool_lit", "named": true }, { - "type": "bracket_array", + "type": "buf_lit", "named": true }, { - "type": "bracket_tuple", + "type": "kwd_lit", "named": true }, { - "type": "buffer", + "type": "long_buf_lit", "named": true }, { - "type": "keyword", + "type": "long_str_lit", "named": true }, { - "type": "long_buffer", + "type": "nil_lit", "named": true }, { - "type": "long_string", + "type": "num_lit", "named": true }, { - "type": "nil", + "type": "par_arr_lit", "named": true }, { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -352,23 +348,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", "named": true }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true }, { - "type": "symbol", + "type": "str_lit", "named": true }, { - "type": "table", + "type": "struct_lit", "named": true }, { - "type": "tuple", + "type": "sym_lit", + "named": true + }, + { + "type": "tbl_lit", "named": true }, { @@ -379,7 +379,7 @@ } }, { - "type": "quote_form", + "type": "short_fn_form", "named": true, "fields": {}, "children": { @@ -387,43 +387,39 @@ "required": true, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -443,23 +439,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -470,51 +470,47 @@ } }, { - "type": "short_fn_form", + "type": "source", "named": true, "fields": {}, "children": { - "multiple": false, - "required": true, + "multiple": true, + "required": false, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -534,23 +530,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -561,51 +561,47 @@ } }, { - "type": "source", + "type": "splice_form", "named": true, "fields": {}, "children": { - "multiple": true, - "required": false, + "multiple": false, + "required": true, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -625,23 +621,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", "named": true }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true }, { - "type": "symbol", + "type": "str_lit", "named": true }, { - "type": "table", + "type": "struct_lit", "named": true }, { - "type": "tuple", + "type": "sym_lit", + "named": true + }, + { + "type": "tbl_lit", "named": true }, { @@ -652,51 +652,47 @@ } }, { - "type": "splice_form", + "type": "sqr_arr_lit", "named": true, "fields": {}, "children": { - "multiple": false, - "required": true, + "multiple": true, + "required": false, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -716,23 +712,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -743,7 +743,7 @@ } }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true, "fields": {}, "children": { @@ -751,43 +751,39 @@ "required": false, "types": [ { - "type": "array", + "type": "bool_lit", "named": true }, { - "type": "boolean", + "type": "buf_lit", "named": true }, { - "type": "bracket_array", + "type": "kwd_lit", "named": true }, { - "type": "bracket_tuple", + "type": "long_buf_lit", "named": true }, { - "type": "buffer", + "type": "long_str_lit", "named": true }, { - "type": "keyword", + "type": "nil_lit", "named": true }, { - "type": "long_buffer", + "type": "num_lit", "named": true }, { - "type": "long_string", + "type": "par_arr_lit", "named": true }, { - "type": "nil", - "named": true - }, - { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -807,23 +803,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -834,7 +834,7 @@ } }, { - "type": "table", + "type": "struct_lit", "named": true, "fields": {}, "children": { @@ -842,43 +842,39 @@ "required": false, "types": [ { - "type": "array", - "named": true - }, - { - "type": "boolean", + "type": "bool_lit", "named": true }, { - "type": "bracket_array", + "type": "buf_lit", "named": true }, { - "type": "bracket_tuple", + "type": "kwd_lit", "named": true }, { - "type": "buffer", + "type": "long_buf_lit", "named": true }, { - "type": "keyword", + "type": "long_str_lit", "named": true }, { - "type": "long_buffer", + "type": "nil_lit", "named": true }, { - "type": "long_string", + "type": "num_lit", "named": true }, { - "type": "nil", + "type": "par_arr_lit", "named": true }, { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -898,23 +894,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", "named": true }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true }, { - "type": "symbol", + "type": "str_lit", "named": true }, { - "type": "table", + "type": "struct_lit", "named": true }, { - "type": "tuple", + "type": "sym_lit", + "named": true + }, + { + "type": "tbl_lit", "named": true }, { @@ -925,7 +925,7 @@ } }, { - "type": "tuple", + "type": "tbl_lit", "named": true, "fields": {}, "children": { @@ -933,43 +933,39 @@ "required": false, "types": [ { - "type": "array", - "named": true - }, - { - "type": "boolean", + "type": "bool_lit", "named": true }, { - "type": "bracket_array", + "type": "buf_lit", "named": true }, { - "type": "bracket_tuple", + "type": "kwd_lit", "named": true }, { - "type": "buffer", + "type": "long_buf_lit", "named": true }, { - "type": "keyword", + "type": "long_str_lit", "named": true }, { - "type": "long_buffer", + "type": "nil_lit", "named": true }, { - "type": "long_string", + "type": "num_lit", "named": true }, { - "type": "nil", + "type": "par_arr_lit", "named": true }, { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -989,23 +985,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", "named": true }, { - "type": "struct", + "type": "sqr_tup_lit", "named": true }, { - "type": "symbol", + "type": "str_lit", "named": true }, { - "type": "table", + "type": "struct_lit", "named": true }, { - "type": "tuple", + "type": "sym_lit", + "named": true + }, + { + "type": "tbl_lit", "named": true }, { @@ -1024,43 +1024,39 @@ "required": true, "types": [ { - "type": "array", - "named": true - }, - { - "type": "boolean", + "type": "bool_lit", "named": true }, { - "type": "bracket_array", + "type": "buf_lit", "named": true }, { - "type": "bracket_tuple", + "type": "kwd_lit", "named": true }, { - "type": "buffer", + "type": "long_buf_lit", "named": true }, { - "type": "keyword", + "type": "long_str_lit", "named": true }, { - "type": "long_buffer", + "type": "nil_lit", "named": true }, { - "type": "long_string", + "type": "num_lit", "named": true }, { - "type": "nil", + "type": "par_arr_lit", "named": true }, { - "type": "number", + "type": "par_tup_lit", "named": true }, { @@ -1080,23 +1076,27 @@ "named": true }, { - "type": "string", + "type": "sqr_arr_lit", + "named": true + }, + { + "type": "sqr_tup_lit", "named": true }, { - "type": "struct", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "struct_lit", "named": true }, { - "type": "table", + "type": "sym_lit", "named": true }, { - "type": "tuple", + "type": "tbl_lit", "named": true }, { @@ -1147,7 +1147,7 @@ "named": false }, { - "type": "buffer", + "type": "buf_lit", "named": true }, { @@ -1155,23 +1155,23 @@ "named": false }, { - "type": "long_buffer", + "type": "long_buf_lit", "named": true }, { - "type": "long_string", + "type": "long_str_lit", "named": true }, { - "type": "nil", + "type": "nil_lit", "named": true }, { - "type": "string", + "type": "str_lit", "named": true }, { - "type": "symbol", + "type": "sym_lit", "named": true }, { diff --git a/src/parser.c b/src/parser.c index e2436a0e3..38cac5f10 100644 --- a/src/parser.c +++ b/src/parser.c @@ -19,14 +19,14 @@ enum { sym_comment = 1, anon_sym_false = 2, anon_sym_true = 3, - aux_sym_keyword_token1 = 4, - sym_nil = 5, + aux_sym_kwd_lit_token1 = 4, + sym_nil_lit = 5, sym__dec = 6, sym__hex = 7, sym__radix = 8, - sym_string = 9, - sym_buffer = 10, - sym_symbol = 11, + sym_str_lit = 9, + sym_buf_lit = 10, + sym_sym_lit = 11, anon_sym_AT_LPAREN = 12, anon_sym_RPAREN = 13, anon_sym_AT_LBRACK = 14, @@ -41,19 +41,19 @@ enum { anon_sym_PIPE = 23, anon_sym_SEMI = 24, anon_sym_COMMA = 25, - sym_long_buffer = 26, - sym_long_string = 27, + sym_long_buf_lit = 26, + sym_long_str_lit = 27, sym_source = 28, sym__form = 29, - sym_boolean = 30, - sym_keyword = 31, - sym_number = 32, - sym_array = 33, - sym_bracket_array = 34, - sym_struct = 35, - sym_table = 36, - sym_tuple = 37, - sym_bracket_tuple = 38, + sym_bool_lit = 30, + sym_kwd_lit = 31, + sym_num_lit = 32, + sym_par_arr_lit = 33, + sym_sqr_arr_lit = 34, + sym_struct_lit = 35, + sym_tbl_lit = 36, + sym_par_tup_lit = 37, + sym_sqr_tup_lit = 38, sym_quasi_quote_form = 39, sym_quote_form = 40, sym_short_fn_form = 41, @@ -67,14 +67,14 @@ static const char *ts_symbol_names[] = { [sym_comment] = "comment", [anon_sym_false] = "false", [anon_sym_true] = "true", - [aux_sym_keyword_token1] = "keyword_token1", - [sym_nil] = "nil", + [aux_sym_kwd_lit_token1] = "kwd_lit_token1", + [sym_nil_lit] = "nil_lit", [sym__dec] = "_dec", [sym__hex] = "_hex", [sym__radix] = "_radix", - [sym_string] = "string", - [sym_buffer] = "buffer", - [sym_symbol] = "symbol", + [sym_str_lit] = "str_lit", + [sym_buf_lit] = "buf_lit", + [sym_sym_lit] = "sym_lit", [anon_sym_AT_LPAREN] = "@(", [anon_sym_RPAREN] = ")", [anon_sym_AT_LBRACK] = "@[", @@ -89,19 +89,19 @@ static const char *ts_symbol_names[] = { [anon_sym_PIPE] = "|", [anon_sym_SEMI] = ";", [anon_sym_COMMA] = ",", - [sym_long_buffer] = "long_buffer", - [sym_long_string] = "long_string", + [sym_long_buf_lit] = "long_buf_lit", + [sym_long_str_lit] = "long_str_lit", [sym_source] = "source", [sym__form] = "_form", - [sym_boolean] = "boolean", - [sym_keyword] = "keyword", - [sym_number] = "number", - [sym_array] = "array", - [sym_bracket_array] = "bracket_array", - [sym_struct] = "struct", - [sym_table] = "table", - [sym_tuple] = "tuple", - [sym_bracket_tuple] = "bracket_tuple", + [sym_bool_lit] = "bool_lit", + [sym_kwd_lit] = "kwd_lit", + [sym_num_lit] = "num_lit", + [sym_par_arr_lit] = "par_arr_lit", + [sym_sqr_arr_lit] = "sqr_arr_lit", + [sym_struct_lit] = "struct_lit", + [sym_tbl_lit] = "tbl_lit", + [sym_par_tup_lit] = "par_tup_lit", + [sym_sqr_tup_lit] = "sqr_tup_lit", [sym_quasi_quote_form] = "quasi_quote_form", [sym_quote_form] = "quote_form", [sym_short_fn_form] = "short_fn_form", @@ -115,14 +115,14 @@ static TSSymbol ts_symbol_map[] = { [sym_comment] = sym_comment, [anon_sym_false] = anon_sym_false, [anon_sym_true] = anon_sym_true, - [aux_sym_keyword_token1] = aux_sym_keyword_token1, - [sym_nil] = sym_nil, + [aux_sym_kwd_lit_token1] = aux_sym_kwd_lit_token1, + [sym_nil_lit] = sym_nil_lit, [sym__dec] = sym__dec, [sym__hex] = sym__hex, [sym__radix] = sym__radix, - [sym_string] = sym_string, - [sym_buffer] = sym_buffer, - [sym_symbol] = sym_symbol, + [sym_str_lit] = sym_str_lit, + [sym_buf_lit] = sym_buf_lit, + [sym_sym_lit] = sym_sym_lit, [anon_sym_AT_LPAREN] = anon_sym_AT_LPAREN, [anon_sym_RPAREN] = anon_sym_RPAREN, [anon_sym_AT_LBRACK] = anon_sym_AT_LBRACK, @@ -137,19 +137,19 @@ static TSSymbol ts_symbol_map[] = { [anon_sym_PIPE] = anon_sym_PIPE, [anon_sym_SEMI] = anon_sym_SEMI, [anon_sym_COMMA] = anon_sym_COMMA, - [sym_long_buffer] = sym_long_buffer, - [sym_long_string] = sym_long_string, + [sym_long_buf_lit] = sym_long_buf_lit, + [sym_long_str_lit] = sym_long_str_lit, [sym_source] = sym_source, [sym__form] = sym__form, - [sym_boolean] = sym_boolean, - [sym_keyword] = sym_keyword, - [sym_number] = sym_number, - [sym_array] = sym_array, - [sym_bracket_array] = sym_bracket_array, - [sym_struct] = sym_struct, - [sym_table] = sym_table, - [sym_tuple] = sym_tuple, - [sym_bracket_tuple] = sym_bracket_tuple, + [sym_bool_lit] = sym_bool_lit, + [sym_kwd_lit] = sym_kwd_lit, + [sym_num_lit] = sym_num_lit, + [sym_par_arr_lit] = sym_par_arr_lit, + [sym_sqr_arr_lit] = sym_sqr_arr_lit, + [sym_struct_lit] = sym_struct_lit, + [sym_tbl_lit] = sym_tbl_lit, + [sym_par_tup_lit] = sym_par_tup_lit, + [sym_sqr_tup_lit] = sym_sqr_tup_lit, [sym_quasi_quote_form] = sym_quasi_quote_form, [sym_quote_form] = sym_quote_form, [sym_short_fn_form] = sym_short_fn_form, @@ -175,11 +175,11 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = false, }, - [aux_sym_keyword_token1] = { + [aux_sym_kwd_lit_token1] = { .visible = false, .named = false, }, - [sym_nil] = { + [sym_nil_lit] = { .visible = true, .named = true, }, @@ -195,15 +195,15 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = false, .named = true, }, - [sym_string] = { + [sym_str_lit] = { .visible = true, .named = true, }, - [sym_buffer] = { + [sym_buf_lit] = { .visible = true, .named = true, }, - [sym_symbol] = { + [sym_sym_lit] = { .visible = true, .named = true, }, @@ -263,11 +263,11 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = false, }, - [sym_long_buffer] = { + [sym_long_buf_lit] = { .visible = true, .named = true, }, - [sym_long_string] = { + [sym_long_str_lit] = { .visible = true, .named = true, }, @@ -279,39 +279,39 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = false, .named = true, }, - [sym_boolean] = { + [sym_bool_lit] = { .visible = true, .named = true, }, - [sym_keyword] = { + [sym_kwd_lit] = { .visible = true, .named = true, }, - [sym_number] = { + [sym_num_lit] = { .visible = true, .named = true, }, - [sym_array] = { + [sym_par_arr_lit] = { .visible = true, .named = true, }, - [sym_bracket_array] = { + [sym_sqr_arr_lit] = { .visible = true, .named = true, }, - [sym_struct] = { + [sym_struct_lit] = { .visible = true, .named = true, }, - [sym_table] = { + [sym_tbl_lit] = { .visible = true, .named = true, }, - [sym_tuple] = { + [sym_par_tup_lit] = { .visible = true, .named = true, }, - [sym_bracket_tuple] = { + [sym_sqr_tup_lit] = { .visible = true, .named = true, }, @@ -473,7 +473,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 17: - ACCEPT_TOKEN(aux_sym_keyword_token1); + ACCEPT_TOKEN(aux_sym_kwd_lit_token1); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -485,7 +485,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(17); END_STATE(); case 18: - ACCEPT_TOKEN(sym_nil); + ACCEPT_TOKEN(sym_nil_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -904,13 +904,13 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 55: - ACCEPT_TOKEN(sym_string); + ACCEPT_TOKEN(sym_str_lit); END_STATE(); case 56: - ACCEPT_TOKEN(sym_buffer); + ACCEPT_TOKEN(sym_buf_lit); END_STATE(); case 57: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '"') ADVANCE(2); if (lookahead == '(') ADVANCE(79); if (lookahead == '[') ADVANCE(81); @@ -926,7 +926,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 58: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(62); if (lookahead == '0') ADVANCE(26); if (lookahead == '1') ADVANCE(31); @@ -944,7 +944,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 59: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(62); if (lookahead == '_') ADVANCE(59); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); @@ -958,7 +958,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 60: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(63); if (lookahead == '_') ADVANCE(61); if (('0' <= lookahead && lookahead <= '9') || @@ -973,7 +973,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 61: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(63); if (lookahead == '_') ADVANCE(61); if (('0' <= lookahead && lookahead <= '9') || @@ -988,7 +988,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 62: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '_') ADVANCE(62); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); if (lookahead == '!' || @@ -1001,7 +1001,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 63: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '_') ADVANCE(63); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); @@ -1015,7 +1015,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 64: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'a') ADVANCE(68); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1028,7 +1028,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('b' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 65: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'e') ADVANCE(16); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1041,7 +1041,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 66: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'e') ADVANCE(15); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1054,7 +1054,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 67: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'i') ADVANCE(69); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1067,7 +1067,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 68: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'l') ADVANCE(71); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1080,7 +1080,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 69: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'l') ADVANCE(18); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1093,7 +1093,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 70: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'r') ADVANCE(72); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1106,7 +1106,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 71: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 's') ADVANCE(66); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1119,7 +1119,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 72: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == 'u') ADVANCE(65); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1132,7 +1132,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 73: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '+' || lookahead == '-') ADVANCE(75); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); @@ -1146,7 +1146,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 74: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '+' || lookahead == '-') ADVANCE(76); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); @@ -1160,7 +1160,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 75: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1173,7 +1173,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 76: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1186,7 +1186,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 77: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1201,7 +1201,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('a' <= lookahead && lookahead <= 'z')) ADVANCE(52); END_STATE(); case 78: - ACCEPT_TOKEN(sym_symbol); + ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1305,19 +1305,19 @@ static TSLexMode ts_lex_modes[STATE_COUNT] = { }; enum { - ts_external_token_long_buffer = 0, - ts_external_token_long_string = 1, + ts_external_token_long_buf_lit = 0, + ts_external_token_long_str_lit = 1, }; static TSSymbol ts_external_scanner_symbol_map[EXTERNAL_TOKEN_COUNT] = { - [ts_external_token_long_buffer] = sym_long_buffer, - [ts_external_token_long_string] = sym_long_string, + [ts_external_token_long_buf_lit] = sym_long_buf_lit, + [ts_external_token_long_str_lit] = sym_long_str_lit, }; static bool ts_external_scanner_states[2][EXTERNAL_TOKEN_COUNT] = { [1] = { - [ts_external_token_long_buffer] = true, - [ts_external_token_long_string] = true, + [ts_external_token_long_buf_lit] = true, + [ts_external_token_long_str_lit] = true, }, }; @@ -1327,14 +1327,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(1), [anon_sym_true] = ACTIONS(1), - [aux_sym_keyword_token1] = ACTIONS(1), - [sym_nil] = ACTIONS(1), + [aux_sym_kwd_lit_token1] = ACTIONS(1), + [sym_nil_lit] = ACTIONS(1), [sym__dec] = ACTIONS(1), [sym__hex] = ACTIONS(1), [sym__radix] = ACTIONS(1), - [sym_string] = ACTIONS(1), - [sym_buffer] = ACTIONS(1), - [sym_symbol] = ACTIONS(1), + [sym_str_lit] = ACTIONS(1), + [sym_buf_lit] = ACTIONS(1), + [sym_sym_lit] = ACTIONS(1), [anon_sym_AT_LPAREN] = ACTIONS(1), [anon_sym_RPAREN] = ACTIONS(1), [anon_sym_AT_LBRACK] = ACTIONS(1), @@ -1349,21 +1349,21 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(1), [anon_sym_SEMI] = ACTIONS(1), [anon_sym_COMMA] = ACTIONS(1), - [sym_long_buffer] = ACTIONS(1), - [sym_long_string] = ACTIONS(1), + [sym_long_buf_lit] = ACTIONS(1), + [sym_long_str_lit] = ACTIONS(1), }, [1] = { [sym_source] = STATE(41), [sym__form] = STATE(12), - [sym_boolean] = STATE(12), - [sym_keyword] = STATE(12), - [sym_number] = STATE(12), - [sym_array] = STATE(12), - [sym_bracket_array] = STATE(12), - [sym_struct] = STATE(12), - [sym_table] = STATE(12), - [sym_tuple] = STATE(12), - [sym_bracket_tuple] = STATE(12), + [sym_bool_lit] = STATE(12), + [sym_kwd_lit] = STATE(12), + [sym_num_lit] = STATE(12), + [sym_par_arr_lit] = STATE(12), + [sym_sqr_arr_lit] = STATE(12), + [sym_struct_lit] = STATE(12), + [sym_tbl_lit] = STATE(12), + [sym_par_tup_lit] = STATE(12), + [sym_sqr_tup_lit] = STATE(12), [sym_quasi_quote_form] = STATE(12), [sym_quote_form] = STATE(12), [sym_short_fn_form] = STATE(12), @@ -1374,14 +1374,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(11), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(11), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(15), - [sym_buffer] = ACTIONS(15), - [sym_symbol] = ACTIONS(11), + [sym_str_lit] = ACTIONS(15), + [sym_buf_lit] = ACTIONS(15), + [sym_sym_lit] = ACTIONS(11), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1393,20 +1393,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(15), - [sym_long_string] = ACTIONS(15), + [sym_long_buf_lit] = ACTIONS(15), + [sym_long_str_lit] = ACTIONS(15), }, [2] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1417,14 +1417,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(41), [anon_sym_true] = ACTIONS(41), - [aux_sym_keyword_token1] = ACTIONS(44), - [sym_nil] = ACTIONS(47), + [aux_sym_kwd_lit_token1] = ACTIONS(44), + [sym_nil_lit] = ACTIONS(47), [sym__dec] = ACTIONS(50), [sym__hex] = ACTIONS(50), [sym__radix] = ACTIONS(50), - [sym_string] = ACTIONS(53), - [sym_buffer] = ACTIONS(53), - [sym_symbol] = ACTIONS(47), + [sym_str_lit] = ACTIONS(53), + [sym_buf_lit] = ACTIONS(53), + [sym_sym_lit] = ACTIONS(47), [anon_sym_AT_LPAREN] = ACTIONS(56), [anon_sym_RPAREN] = ACTIONS(39), [anon_sym_AT_LBRACK] = ACTIONS(59), @@ -1439,20 +1439,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(80), [anon_sym_SEMI] = ACTIONS(83), [anon_sym_COMMA] = ACTIONS(86), - [sym_long_buffer] = ACTIONS(53), - [sym_long_string] = ACTIONS(53), + [sym_long_buf_lit] = ACTIONS(53), + [sym_long_str_lit] = ACTIONS(53), }, [3] = { [sym__form] = STATE(15), - [sym_boolean] = STATE(15), - [sym_keyword] = STATE(15), - [sym_number] = STATE(15), - [sym_array] = STATE(15), - [sym_bracket_array] = STATE(15), - [sym_struct] = STATE(15), - [sym_table] = STATE(15), - [sym_tuple] = STATE(15), - [sym_bracket_tuple] = STATE(15), + [sym_bool_lit] = STATE(15), + [sym_kwd_lit] = STATE(15), + [sym_num_lit] = STATE(15), + [sym_par_arr_lit] = STATE(15), + [sym_sqr_arr_lit] = STATE(15), + [sym_struct_lit] = STATE(15), + [sym_tbl_lit] = STATE(15), + [sym_par_tup_lit] = STATE(15), + [sym_sqr_tup_lit] = STATE(15), [sym_quasi_quote_form] = STATE(15), [sym_quote_form] = STATE(15), [sym_short_fn_form] = STATE(15), @@ -1462,14 +1462,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(89), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(89), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(91), - [sym_buffer] = ACTIONS(91), - [sym_symbol] = ACTIONS(89), + [sym_str_lit] = ACTIONS(91), + [sym_buf_lit] = ACTIONS(91), + [sym_sym_lit] = ACTIONS(89), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_RBRACK] = ACTIONS(93), @@ -1482,20 +1482,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(91), - [sym_long_string] = ACTIONS(91), + [sym_long_buf_lit] = ACTIONS(91), + [sym_long_str_lit] = ACTIONS(91), }, [4] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1505,14 +1505,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_RPAREN] = ACTIONS(99), [anon_sym_AT_LBRACK] = ACTIONS(19), @@ -1525,20 +1525,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [5] = { [sym__form] = STATE(14), - [sym_boolean] = STATE(14), - [sym_keyword] = STATE(14), - [sym_number] = STATE(14), - [sym_array] = STATE(14), - [sym_bracket_array] = STATE(14), - [sym_struct] = STATE(14), - [sym_table] = STATE(14), - [sym_tuple] = STATE(14), - [sym_bracket_tuple] = STATE(14), + [sym_bool_lit] = STATE(14), + [sym_kwd_lit] = STATE(14), + [sym_num_lit] = STATE(14), + [sym_par_arr_lit] = STATE(14), + [sym_sqr_arr_lit] = STATE(14), + [sym_struct_lit] = STATE(14), + [sym_tbl_lit] = STATE(14), + [sym_par_tup_lit] = STATE(14), + [sym_sqr_tup_lit] = STATE(14), [sym_quasi_quote_form] = STATE(14), [sym_quote_form] = STATE(14), [sym_short_fn_form] = STATE(14), @@ -1548,14 +1548,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(101), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(101), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(103), - [sym_buffer] = ACTIONS(103), - [sym_symbol] = ACTIONS(101), + [sym_str_lit] = ACTIONS(103), + [sym_buf_lit] = ACTIONS(103), + [sym_sym_lit] = ACTIONS(101), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_RPAREN] = ACTIONS(105), [anon_sym_AT_LBRACK] = ACTIONS(19), @@ -1568,20 +1568,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(103), - [sym_long_string] = ACTIONS(103), + [sym_long_buf_lit] = ACTIONS(103), + [sym_long_str_lit] = ACTIONS(103), }, [6] = { [sym__form] = STATE(10), - [sym_boolean] = STATE(10), - [sym_keyword] = STATE(10), - [sym_number] = STATE(10), - [sym_array] = STATE(10), - [sym_bracket_array] = STATE(10), - [sym_struct] = STATE(10), - [sym_table] = STATE(10), - [sym_tuple] = STATE(10), - [sym_bracket_tuple] = STATE(10), + [sym_bool_lit] = STATE(10), + [sym_kwd_lit] = STATE(10), + [sym_num_lit] = STATE(10), + [sym_par_arr_lit] = STATE(10), + [sym_sqr_arr_lit] = STATE(10), + [sym_struct_lit] = STATE(10), + [sym_tbl_lit] = STATE(10), + [sym_par_tup_lit] = STATE(10), + [sym_sqr_tup_lit] = STATE(10), [sym_quasi_quote_form] = STATE(10), [sym_quote_form] = STATE(10), [sym_short_fn_form] = STATE(10), @@ -1591,14 +1591,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(107), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(107), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(109), - [sym_buffer] = ACTIONS(109), - [sym_symbol] = ACTIONS(107), + [sym_str_lit] = ACTIONS(109), + [sym_buf_lit] = ACTIONS(109), + [sym_sym_lit] = ACTIONS(107), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_RBRACK] = ACTIONS(111), @@ -1611,20 +1611,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(109), - [sym_long_string] = ACTIONS(109), + [sym_long_buf_lit] = ACTIONS(109), + [sym_long_str_lit] = ACTIONS(109), }, [7] = { [sym__form] = STATE(13), - [sym_boolean] = STATE(13), - [sym_keyword] = STATE(13), - [sym_number] = STATE(13), - [sym_array] = STATE(13), - [sym_bracket_array] = STATE(13), - [sym_struct] = STATE(13), - [sym_table] = STATE(13), - [sym_tuple] = STATE(13), - [sym_bracket_tuple] = STATE(13), + [sym_bool_lit] = STATE(13), + [sym_kwd_lit] = STATE(13), + [sym_num_lit] = STATE(13), + [sym_par_arr_lit] = STATE(13), + [sym_sqr_arr_lit] = STATE(13), + [sym_struct_lit] = STATE(13), + [sym_tbl_lit] = STATE(13), + [sym_par_tup_lit] = STATE(13), + [sym_sqr_tup_lit] = STATE(13), [sym_quasi_quote_form] = STATE(13), [sym_quote_form] = STATE(13), [sym_short_fn_form] = STATE(13), @@ -1634,14 +1634,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(113), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(113), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(115), - [sym_buffer] = ACTIONS(115), - [sym_symbol] = ACTIONS(113), + [sym_str_lit] = ACTIONS(115), + [sym_buf_lit] = ACTIONS(115), + [sym_sym_lit] = ACTIONS(113), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1654,20 +1654,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(115), - [sym_long_string] = ACTIONS(115), + [sym_long_buf_lit] = ACTIONS(115), + [sym_long_str_lit] = ACTIONS(115), }, [8] = { [sym__form] = STATE(11), - [sym_boolean] = STATE(11), - [sym_keyword] = STATE(11), - [sym_number] = STATE(11), - [sym_array] = STATE(11), - [sym_bracket_array] = STATE(11), - [sym_struct] = STATE(11), - [sym_table] = STATE(11), - [sym_tuple] = STATE(11), - [sym_bracket_tuple] = STATE(11), + [sym_bool_lit] = STATE(11), + [sym_kwd_lit] = STATE(11), + [sym_num_lit] = STATE(11), + [sym_par_arr_lit] = STATE(11), + [sym_sqr_arr_lit] = STATE(11), + [sym_struct_lit] = STATE(11), + [sym_tbl_lit] = STATE(11), + [sym_par_tup_lit] = STATE(11), + [sym_sqr_tup_lit] = STATE(11), [sym_quasi_quote_form] = STATE(11), [sym_quote_form] = STATE(11), [sym_short_fn_form] = STATE(11), @@ -1677,14 +1677,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(119), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(119), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(121), - [sym_buffer] = ACTIONS(121), - [sym_symbol] = ACTIONS(119), + [sym_str_lit] = ACTIONS(121), + [sym_buf_lit] = ACTIONS(121), + [sym_sym_lit] = ACTIONS(119), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1697,20 +1697,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(121), - [sym_long_string] = ACTIONS(121), + [sym_long_buf_lit] = ACTIONS(121), + [sym_long_str_lit] = ACTIONS(121), }, [9] = { [sym__form] = STATE(4), - [sym_boolean] = STATE(4), - [sym_keyword] = STATE(4), - [sym_number] = STATE(4), - [sym_array] = STATE(4), - [sym_bracket_array] = STATE(4), - [sym_struct] = STATE(4), - [sym_table] = STATE(4), - [sym_tuple] = STATE(4), - [sym_bracket_tuple] = STATE(4), + [sym_bool_lit] = STATE(4), + [sym_kwd_lit] = STATE(4), + [sym_num_lit] = STATE(4), + [sym_par_arr_lit] = STATE(4), + [sym_sqr_arr_lit] = STATE(4), + [sym_struct_lit] = STATE(4), + [sym_tbl_lit] = STATE(4), + [sym_par_tup_lit] = STATE(4), + [sym_sqr_tup_lit] = STATE(4), [sym_quasi_quote_form] = STATE(4), [sym_quote_form] = STATE(4), [sym_short_fn_form] = STATE(4), @@ -1720,14 +1720,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(125), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(125), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(127), - [sym_buffer] = ACTIONS(127), - [sym_symbol] = ACTIONS(125), + [sym_str_lit] = ACTIONS(127), + [sym_buf_lit] = ACTIONS(127), + [sym_sym_lit] = ACTIONS(125), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_RPAREN] = ACTIONS(129), [anon_sym_AT_LBRACK] = ACTIONS(19), @@ -1740,20 +1740,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(127), - [sym_long_string] = ACTIONS(127), + [sym_long_buf_lit] = ACTIONS(127), + [sym_long_str_lit] = ACTIONS(127), }, [10] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1763,14 +1763,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_RBRACK] = ACTIONS(131), @@ -1783,20 +1783,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [11] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1806,14 +1806,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1826,20 +1826,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [12] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1850,14 +1850,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1869,20 +1869,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [13] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1892,14 +1892,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -1912,20 +1912,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [14] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1935,14 +1935,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_RPAREN] = ACTIONS(139), [anon_sym_AT_LBRACK] = ACTIONS(19), @@ -1955,20 +1955,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [15] = { [sym__form] = STATE(2), - [sym_boolean] = STATE(2), - [sym_keyword] = STATE(2), - [sym_number] = STATE(2), - [sym_array] = STATE(2), - [sym_bracket_array] = STATE(2), - [sym_struct] = STATE(2), - [sym_table] = STATE(2), - [sym_tuple] = STATE(2), - [sym_bracket_tuple] = STATE(2), + [sym_bool_lit] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), [sym_quasi_quote_form] = STATE(2), [sym_quote_form] = STATE(2), [sym_short_fn_form] = STATE(2), @@ -1978,14 +1978,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(95), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(95), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(97), - [sym_buffer] = ACTIONS(97), - [sym_symbol] = ACTIONS(95), + [sym_str_lit] = ACTIONS(97), + [sym_buf_lit] = ACTIONS(97), + [sym_sym_lit] = ACTIONS(95), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_RBRACK] = ACTIONS(141), @@ -1998,20 +1998,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(97), - [sym_long_string] = ACTIONS(97), + [sym_long_buf_lit] = ACTIONS(97), + [sym_long_str_lit] = ACTIONS(97), }, [16] = { [sym__form] = STATE(29), - [sym_boolean] = STATE(29), - [sym_keyword] = STATE(29), - [sym_number] = STATE(29), - [sym_array] = STATE(29), - [sym_bracket_array] = STATE(29), - [sym_struct] = STATE(29), - [sym_table] = STATE(29), - [sym_tuple] = STATE(29), - [sym_bracket_tuple] = STATE(29), + [sym_bool_lit] = STATE(29), + [sym_kwd_lit] = STATE(29), + [sym_num_lit] = STATE(29), + [sym_par_arr_lit] = STATE(29), + [sym_sqr_arr_lit] = STATE(29), + [sym_struct_lit] = STATE(29), + [sym_tbl_lit] = STATE(29), + [sym_par_tup_lit] = STATE(29), + [sym_sqr_tup_lit] = STATE(29), [sym_quasi_quote_form] = STATE(29), [sym_quote_form] = STATE(29), [sym_short_fn_form] = STATE(29), @@ -2020,14 +2020,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(143), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(143), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(145), - [sym_buffer] = ACTIONS(145), - [sym_symbol] = ACTIONS(143), + [sym_str_lit] = ACTIONS(145), + [sym_buf_lit] = ACTIONS(145), + [sym_sym_lit] = ACTIONS(143), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -2039,20 +2039,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(145), - [sym_long_string] = ACTIONS(145), + [sym_long_buf_lit] = ACTIONS(145), + [sym_long_str_lit] = ACTIONS(145), }, [17] = { [sym__form] = STATE(30), - [sym_boolean] = STATE(30), - [sym_keyword] = STATE(30), - [sym_number] = STATE(30), - [sym_array] = STATE(30), - [sym_bracket_array] = STATE(30), - [sym_struct] = STATE(30), - [sym_table] = STATE(30), - [sym_tuple] = STATE(30), - [sym_bracket_tuple] = STATE(30), + [sym_bool_lit] = STATE(30), + [sym_kwd_lit] = STATE(30), + [sym_num_lit] = STATE(30), + [sym_par_arr_lit] = STATE(30), + [sym_sqr_arr_lit] = STATE(30), + [sym_struct_lit] = STATE(30), + [sym_tbl_lit] = STATE(30), + [sym_par_tup_lit] = STATE(30), + [sym_sqr_tup_lit] = STATE(30), [sym_quasi_quote_form] = STATE(30), [sym_quote_form] = STATE(30), [sym_short_fn_form] = STATE(30), @@ -2061,14 +2061,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(147), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(147), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(149), - [sym_buffer] = ACTIONS(149), - [sym_symbol] = ACTIONS(147), + [sym_str_lit] = ACTIONS(149), + [sym_buf_lit] = ACTIONS(149), + [sym_sym_lit] = ACTIONS(147), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -2080,20 +2080,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(149), - [sym_long_string] = ACTIONS(149), + [sym_long_buf_lit] = ACTIONS(149), + [sym_long_str_lit] = ACTIONS(149), }, [18] = { [sym__form] = STATE(31), - [sym_boolean] = STATE(31), - [sym_keyword] = STATE(31), - [sym_number] = STATE(31), - [sym_array] = STATE(31), - [sym_bracket_array] = STATE(31), - [sym_struct] = STATE(31), - [sym_table] = STATE(31), - [sym_tuple] = STATE(31), - [sym_bracket_tuple] = STATE(31), + [sym_bool_lit] = STATE(31), + [sym_kwd_lit] = STATE(31), + [sym_num_lit] = STATE(31), + [sym_par_arr_lit] = STATE(31), + [sym_sqr_arr_lit] = STATE(31), + [sym_struct_lit] = STATE(31), + [sym_tbl_lit] = STATE(31), + [sym_par_tup_lit] = STATE(31), + [sym_sqr_tup_lit] = STATE(31), [sym_quasi_quote_form] = STATE(31), [sym_quote_form] = STATE(31), [sym_short_fn_form] = STATE(31), @@ -2102,14 +2102,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(151), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(151), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(153), - [sym_buffer] = ACTIONS(153), - [sym_symbol] = ACTIONS(151), + [sym_str_lit] = ACTIONS(153), + [sym_buf_lit] = ACTIONS(153), + [sym_sym_lit] = ACTIONS(151), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -2121,20 +2121,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(153), - [sym_long_string] = ACTIONS(153), + [sym_long_buf_lit] = ACTIONS(153), + [sym_long_str_lit] = ACTIONS(153), }, [19] = { [sym__form] = STATE(32), - [sym_boolean] = STATE(32), - [sym_keyword] = STATE(32), - [sym_number] = STATE(32), - [sym_array] = STATE(32), - [sym_bracket_array] = STATE(32), - [sym_struct] = STATE(32), - [sym_table] = STATE(32), - [sym_tuple] = STATE(32), - [sym_bracket_tuple] = STATE(32), + [sym_bool_lit] = STATE(32), + [sym_kwd_lit] = STATE(32), + [sym_num_lit] = STATE(32), + [sym_par_arr_lit] = STATE(32), + [sym_sqr_arr_lit] = STATE(32), + [sym_struct_lit] = STATE(32), + [sym_tbl_lit] = STATE(32), + [sym_par_tup_lit] = STATE(32), + [sym_sqr_tup_lit] = STATE(32), [sym_quasi_quote_form] = STATE(32), [sym_quote_form] = STATE(32), [sym_short_fn_form] = STATE(32), @@ -2143,14 +2143,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(155), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(155), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(157), - [sym_buffer] = ACTIONS(157), - [sym_symbol] = ACTIONS(155), + [sym_str_lit] = ACTIONS(157), + [sym_buf_lit] = ACTIONS(157), + [sym_sym_lit] = ACTIONS(155), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -2162,20 +2162,20 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(157), - [sym_long_string] = ACTIONS(157), + [sym_long_buf_lit] = ACTIONS(157), + [sym_long_str_lit] = ACTIONS(157), }, [20] = { [sym__form] = STATE(33), - [sym_boolean] = STATE(33), - [sym_keyword] = STATE(33), - [sym_number] = STATE(33), - [sym_array] = STATE(33), - [sym_bracket_array] = STATE(33), - [sym_struct] = STATE(33), - [sym_table] = STATE(33), - [sym_tuple] = STATE(33), - [sym_bracket_tuple] = STATE(33), + [sym_bool_lit] = STATE(33), + [sym_kwd_lit] = STATE(33), + [sym_num_lit] = STATE(33), + [sym_par_arr_lit] = STATE(33), + [sym_sqr_arr_lit] = STATE(33), + [sym_struct_lit] = STATE(33), + [sym_tbl_lit] = STATE(33), + [sym_par_tup_lit] = STATE(33), + [sym_sqr_tup_lit] = STATE(33), [sym_quasi_quote_form] = STATE(33), [sym_quote_form] = STATE(33), [sym_short_fn_form] = STATE(33), @@ -2184,14 +2184,14 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(7), [anon_sym_true] = ACTIONS(7), - [aux_sym_keyword_token1] = ACTIONS(9), - [sym_nil] = ACTIONS(159), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(159), [sym__dec] = ACTIONS(13), [sym__hex] = ACTIONS(13), [sym__radix] = ACTIONS(13), - [sym_string] = ACTIONS(161), - [sym_buffer] = ACTIONS(161), - [sym_symbol] = ACTIONS(159), + [sym_str_lit] = ACTIONS(161), + [sym_buf_lit] = ACTIONS(161), + [sym_sym_lit] = ACTIONS(159), [anon_sym_AT_LPAREN] = ACTIONS(17), [anon_sym_AT_LBRACK] = ACTIONS(19), [anon_sym_LBRACE] = ACTIONS(21), @@ -2203,22 +2203,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(33), [anon_sym_SEMI] = ACTIONS(35), [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buffer] = ACTIONS(161), - [sym_long_string] = ACTIONS(161), + [sym_long_buf_lit] = ACTIONS(161), + [sym_long_str_lit] = ACTIONS(161), }, [21] = { [ts_builtin_sym_end] = ACTIONS(163), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(165), [anon_sym_true] = ACTIONS(165), - [aux_sym_keyword_token1] = ACTIONS(163), - [sym_nil] = ACTIONS(165), + [aux_sym_kwd_lit_token1] = ACTIONS(163), + [sym_nil_lit] = ACTIONS(165), [sym__dec] = ACTIONS(165), [sym__hex] = ACTIONS(165), [sym__radix] = ACTIONS(165), - [sym_string] = ACTIONS(163), - [sym_buffer] = ACTIONS(163), - [sym_symbol] = ACTIONS(165), + [sym_str_lit] = ACTIONS(163), + [sym_buf_lit] = ACTIONS(163), + [sym_sym_lit] = ACTIONS(165), [anon_sym_AT_LPAREN] = ACTIONS(163), [anon_sym_RPAREN] = ACTIONS(163), [anon_sym_AT_LBRACK] = ACTIONS(163), @@ -2233,22 +2233,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(163), [anon_sym_SEMI] = ACTIONS(163), [anon_sym_COMMA] = ACTIONS(163), - [sym_long_buffer] = ACTIONS(163), - [sym_long_string] = ACTIONS(163), + [sym_long_buf_lit] = ACTIONS(163), + [sym_long_str_lit] = ACTIONS(163), }, [22] = { [ts_builtin_sym_end] = ACTIONS(167), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(169), [anon_sym_true] = ACTIONS(169), - [aux_sym_keyword_token1] = ACTIONS(167), - [sym_nil] = ACTIONS(169), + [aux_sym_kwd_lit_token1] = ACTIONS(167), + [sym_nil_lit] = ACTIONS(169), [sym__dec] = ACTIONS(169), [sym__hex] = ACTIONS(169), [sym__radix] = ACTIONS(169), - [sym_string] = ACTIONS(167), - [sym_buffer] = ACTIONS(167), - [sym_symbol] = ACTIONS(169), + [sym_str_lit] = ACTIONS(167), + [sym_buf_lit] = ACTIONS(167), + [sym_sym_lit] = ACTIONS(169), [anon_sym_AT_LPAREN] = ACTIONS(167), [anon_sym_RPAREN] = ACTIONS(167), [anon_sym_AT_LBRACK] = ACTIONS(167), @@ -2263,22 +2263,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(167), [anon_sym_SEMI] = ACTIONS(167), [anon_sym_COMMA] = ACTIONS(167), - [sym_long_buffer] = ACTIONS(167), - [sym_long_string] = ACTIONS(167), + [sym_long_buf_lit] = ACTIONS(167), + [sym_long_str_lit] = ACTIONS(167), }, [23] = { [ts_builtin_sym_end] = ACTIONS(171), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(173), [anon_sym_true] = ACTIONS(173), - [aux_sym_keyword_token1] = ACTIONS(171), - [sym_nil] = ACTIONS(173), + [aux_sym_kwd_lit_token1] = ACTIONS(171), + [sym_nil_lit] = ACTIONS(173), [sym__dec] = ACTIONS(173), [sym__hex] = ACTIONS(173), [sym__radix] = ACTIONS(173), - [sym_string] = ACTIONS(171), - [sym_buffer] = ACTIONS(171), - [sym_symbol] = ACTIONS(173), + [sym_str_lit] = ACTIONS(171), + [sym_buf_lit] = ACTIONS(171), + [sym_sym_lit] = ACTIONS(173), [anon_sym_AT_LPAREN] = ACTIONS(171), [anon_sym_RPAREN] = ACTIONS(171), [anon_sym_AT_LBRACK] = ACTIONS(171), @@ -2293,22 +2293,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(171), [anon_sym_SEMI] = ACTIONS(171), [anon_sym_COMMA] = ACTIONS(171), - [sym_long_buffer] = ACTIONS(171), - [sym_long_string] = ACTIONS(171), + [sym_long_buf_lit] = ACTIONS(171), + [sym_long_str_lit] = ACTIONS(171), }, [24] = { [ts_builtin_sym_end] = ACTIONS(175), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(177), [anon_sym_true] = ACTIONS(177), - [aux_sym_keyword_token1] = ACTIONS(175), - [sym_nil] = ACTIONS(177), + [aux_sym_kwd_lit_token1] = ACTIONS(175), + [sym_nil_lit] = ACTIONS(177), [sym__dec] = ACTIONS(177), [sym__hex] = ACTIONS(177), [sym__radix] = ACTIONS(177), - [sym_string] = ACTIONS(175), - [sym_buffer] = ACTIONS(175), - [sym_symbol] = ACTIONS(177), + [sym_str_lit] = ACTIONS(175), + [sym_buf_lit] = ACTIONS(175), + [sym_sym_lit] = ACTIONS(177), [anon_sym_AT_LPAREN] = ACTIONS(175), [anon_sym_RPAREN] = ACTIONS(175), [anon_sym_AT_LBRACK] = ACTIONS(175), @@ -2323,22 +2323,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(175), [anon_sym_SEMI] = ACTIONS(175), [anon_sym_COMMA] = ACTIONS(175), - [sym_long_buffer] = ACTIONS(175), - [sym_long_string] = ACTIONS(175), + [sym_long_buf_lit] = ACTIONS(175), + [sym_long_str_lit] = ACTIONS(175), }, [25] = { [ts_builtin_sym_end] = ACTIONS(179), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(181), [anon_sym_true] = ACTIONS(181), - [aux_sym_keyword_token1] = ACTIONS(179), - [sym_nil] = ACTIONS(181), + [aux_sym_kwd_lit_token1] = ACTIONS(179), + [sym_nil_lit] = ACTIONS(181), [sym__dec] = ACTIONS(181), [sym__hex] = ACTIONS(181), [sym__radix] = ACTIONS(181), - [sym_string] = ACTIONS(179), - [sym_buffer] = ACTIONS(179), - [sym_symbol] = ACTIONS(181), + [sym_str_lit] = ACTIONS(179), + [sym_buf_lit] = ACTIONS(179), + [sym_sym_lit] = ACTIONS(181), [anon_sym_AT_LPAREN] = ACTIONS(179), [anon_sym_RPAREN] = ACTIONS(179), [anon_sym_AT_LBRACK] = ACTIONS(179), @@ -2353,22 +2353,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(179), [anon_sym_SEMI] = ACTIONS(179), [anon_sym_COMMA] = ACTIONS(179), - [sym_long_buffer] = ACTIONS(179), - [sym_long_string] = ACTIONS(179), + [sym_long_buf_lit] = ACTIONS(179), + [sym_long_str_lit] = ACTIONS(179), }, [26] = { [ts_builtin_sym_end] = ACTIONS(183), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(185), [anon_sym_true] = ACTIONS(185), - [aux_sym_keyword_token1] = ACTIONS(183), - [sym_nil] = ACTIONS(185), + [aux_sym_kwd_lit_token1] = ACTIONS(183), + [sym_nil_lit] = ACTIONS(185), [sym__dec] = ACTIONS(185), [sym__hex] = ACTIONS(185), [sym__radix] = ACTIONS(185), - [sym_string] = ACTIONS(183), - [sym_buffer] = ACTIONS(183), - [sym_symbol] = ACTIONS(185), + [sym_str_lit] = ACTIONS(183), + [sym_buf_lit] = ACTIONS(183), + [sym_sym_lit] = ACTIONS(185), [anon_sym_AT_LPAREN] = ACTIONS(183), [anon_sym_RPAREN] = ACTIONS(183), [anon_sym_AT_LBRACK] = ACTIONS(183), @@ -2383,22 +2383,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(183), [anon_sym_SEMI] = ACTIONS(183), [anon_sym_COMMA] = ACTIONS(183), - [sym_long_buffer] = ACTIONS(183), - [sym_long_string] = ACTIONS(183), + [sym_long_buf_lit] = ACTIONS(183), + [sym_long_str_lit] = ACTIONS(183), }, [27] = { [ts_builtin_sym_end] = ACTIONS(187), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(189), [anon_sym_true] = ACTIONS(189), - [aux_sym_keyword_token1] = ACTIONS(187), - [sym_nil] = ACTIONS(189), + [aux_sym_kwd_lit_token1] = ACTIONS(187), + [sym_nil_lit] = ACTIONS(189), [sym__dec] = ACTIONS(189), [sym__hex] = ACTIONS(189), [sym__radix] = ACTIONS(189), - [sym_string] = ACTIONS(187), - [sym_buffer] = ACTIONS(187), - [sym_symbol] = ACTIONS(189), + [sym_str_lit] = ACTIONS(187), + [sym_buf_lit] = ACTIONS(187), + [sym_sym_lit] = ACTIONS(189), [anon_sym_AT_LPAREN] = ACTIONS(187), [anon_sym_RPAREN] = ACTIONS(187), [anon_sym_AT_LBRACK] = ACTIONS(187), @@ -2413,22 +2413,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(187), [anon_sym_SEMI] = ACTIONS(187), [anon_sym_COMMA] = ACTIONS(187), - [sym_long_buffer] = ACTIONS(187), - [sym_long_string] = ACTIONS(187), + [sym_long_buf_lit] = ACTIONS(187), + [sym_long_str_lit] = ACTIONS(187), }, [28] = { [ts_builtin_sym_end] = ACTIONS(191), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(193), [anon_sym_true] = ACTIONS(193), - [aux_sym_keyword_token1] = ACTIONS(191), - [sym_nil] = ACTIONS(193), + [aux_sym_kwd_lit_token1] = ACTIONS(191), + [sym_nil_lit] = ACTIONS(193), [sym__dec] = ACTIONS(193), [sym__hex] = ACTIONS(193), [sym__radix] = ACTIONS(193), - [sym_string] = ACTIONS(191), - [sym_buffer] = ACTIONS(191), - [sym_symbol] = ACTIONS(193), + [sym_str_lit] = ACTIONS(191), + [sym_buf_lit] = ACTIONS(191), + [sym_sym_lit] = ACTIONS(193), [anon_sym_AT_LPAREN] = ACTIONS(191), [anon_sym_RPAREN] = ACTIONS(191), [anon_sym_AT_LBRACK] = ACTIONS(191), @@ -2443,22 +2443,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(191), [anon_sym_SEMI] = ACTIONS(191), [anon_sym_COMMA] = ACTIONS(191), - [sym_long_buffer] = ACTIONS(191), - [sym_long_string] = ACTIONS(191), + [sym_long_buf_lit] = ACTIONS(191), + [sym_long_str_lit] = ACTIONS(191), }, [29] = { [ts_builtin_sym_end] = ACTIONS(195), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(197), [anon_sym_true] = ACTIONS(197), - [aux_sym_keyword_token1] = ACTIONS(195), - [sym_nil] = ACTIONS(197), + [aux_sym_kwd_lit_token1] = ACTIONS(195), + [sym_nil_lit] = ACTIONS(197), [sym__dec] = ACTIONS(197), [sym__hex] = ACTIONS(197), [sym__radix] = ACTIONS(197), - [sym_string] = ACTIONS(195), - [sym_buffer] = ACTIONS(195), - [sym_symbol] = ACTIONS(197), + [sym_str_lit] = ACTIONS(195), + [sym_buf_lit] = ACTIONS(195), + [sym_sym_lit] = ACTIONS(197), [anon_sym_AT_LPAREN] = ACTIONS(195), [anon_sym_RPAREN] = ACTIONS(195), [anon_sym_AT_LBRACK] = ACTIONS(195), @@ -2473,22 +2473,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(195), [anon_sym_SEMI] = ACTIONS(195), [anon_sym_COMMA] = ACTIONS(195), - [sym_long_buffer] = ACTIONS(195), - [sym_long_string] = ACTIONS(195), + [sym_long_buf_lit] = ACTIONS(195), + [sym_long_str_lit] = ACTIONS(195), }, [30] = { [ts_builtin_sym_end] = ACTIONS(199), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(201), [anon_sym_true] = ACTIONS(201), - [aux_sym_keyword_token1] = ACTIONS(199), - [sym_nil] = ACTIONS(201), + [aux_sym_kwd_lit_token1] = ACTIONS(199), + [sym_nil_lit] = ACTIONS(201), [sym__dec] = ACTIONS(201), [sym__hex] = ACTIONS(201), [sym__radix] = ACTIONS(201), - [sym_string] = ACTIONS(199), - [sym_buffer] = ACTIONS(199), - [sym_symbol] = ACTIONS(201), + [sym_str_lit] = ACTIONS(199), + [sym_buf_lit] = ACTIONS(199), + [sym_sym_lit] = ACTIONS(201), [anon_sym_AT_LPAREN] = ACTIONS(199), [anon_sym_RPAREN] = ACTIONS(199), [anon_sym_AT_LBRACK] = ACTIONS(199), @@ -2503,22 +2503,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(199), [anon_sym_SEMI] = ACTIONS(199), [anon_sym_COMMA] = ACTIONS(199), - [sym_long_buffer] = ACTIONS(199), - [sym_long_string] = ACTIONS(199), + [sym_long_buf_lit] = ACTIONS(199), + [sym_long_str_lit] = ACTIONS(199), }, [31] = { [ts_builtin_sym_end] = ACTIONS(203), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(205), [anon_sym_true] = ACTIONS(205), - [aux_sym_keyword_token1] = ACTIONS(203), - [sym_nil] = ACTIONS(205), + [aux_sym_kwd_lit_token1] = ACTIONS(203), + [sym_nil_lit] = ACTIONS(205), [sym__dec] = ACTIONS(205), [sym__hex] = ACTIONS(205), [sym__radix] = ACTIONS(205), - [sym_string] = ACTIONS(203), - [sym_buffer] = ACTIONS(203), - [sym_symbol] = ACTIONS(205), + [sym_str_lit] = ACTIONS(203), + [sym_buf_lit] = ACTIONS(203), + [sym_sym_lit] = ACTIONS(205), [anon_sym_AT_LPAREN] = ACTIONS(203), [anon_sym_RPAREN] = ACTIONS(203), [anon_sym_AT_LBRACK] = ACTIONS(203), @@ -2533,22 +2533,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(203), [anon_sym_SEMI] = ACTIONS(203), [anon_sym_COMMA] = ACTIONS(203), - [sym_long_buffer] = ACTIONS(203), - [sym_long_string] = ACTIONS(203), + [sym_long_buf_lit] = ACTIONS(203), + [sym_long_str_lit] = ACTIONS(203), }, [32] = { [ts_builtin_sym_end] = ACTIONS(207), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(209), [anon_sym_true] = ACTIONS(209), - [aux_sym_keyword_token1] = ACTIONS(207), - [sym_nil] = ACTIONS(209), + [aux_sym_kwd_lit_token1] = ACTIONS(207), + [sym_nil_lit] = ACTIONS(209), [sym__dec] = ACTIONS(209), [sym__hex] = ACTIONS(209), [sym__radix] = ACTIONS(209), - [sym_string] = ACTIONS(207), - [sym_buffer] = ACTIONS(207), - [sym_symbol] = ACTIONS(209), + [sym_str_lit] = ACTIONS(207), + [sym_buf_lit] = ACTIONS(207), + [sym_sym_lit] = ACTIONS(209), [anon_sym_AT_LPAREN] = ACTIONS(207), [anon_sym_RPAREN] = ACTIONS(207), [anon_sym_AT_LBRACK] = ACTIONS(207), @@ -2563,22 +2563,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(207), [anon_sym_SEMI] = ACTIONS(207), [anon_sym_COMMA] = ACTIONS(207), - [sym_long_buffer] = ACTIONS(207), - [sym_long_string] = ACTIONS(207), + [sym_long_buf_lit] = ACTIONS(207), + [sym_long_str_lit] = ACTIONS(207), }, [33] = { [ts_builtin_sym_end] = ACTIONS(211), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(213), [anon_sym_true] = ACTIONS(213), - [aux_sym_keyword_token1] = ACTIONS(211), - [sym_nil] = ACTIONS(213), + [aux_sym_kwd_lit_token1] = ACTIONS(211), + [sym_nil_lit] = ACTIONS(213), [sym__dec] = ACTIONS(213), [sym__hex] = ACTIONS(213), [sym__radix] = ACTIONS(213), - [sym_string] = ACTIONS(211), - [sym_buffer] = ACTIONS(211), - [sym_symbol] = ACTIONS(213), + [sym_str_lit] = ACTIONS(211), + [sym_buf_lit] = ACTIONS(211), + [sym_sym_lit] = ACTIONS(213), [anon_sym_AT_LPAREN] = ACTIONS(211), [anon_sym_RPAREN] = ACTIONS(211), [anon_sym_AT_LBRACK] = ACTIONS(211), @@ -2593,22 +2593,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(211), [anon_sym_SEMI] = ACTIONS(211), [anon_sym_COMMA] = ACTIONS(211), - [sym_long_buffer] = ACTIONS(211), - [sym_long_string] = ACTIONS(211), + [sym_long_buf_lit] = ACTIONS(211), + [sym_long_str_lit] = ACTIONS(211), }, [34] = { [ts_builtin_sym_end] = ACTIONS(215), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(217), [anon_sym_true] = ACTIONS(217), - [aux_sym_keyword_token1] = ACTIONS(215), - [sym_nil] = ACTIONS(217), + [aux_sym_kwd_lit_token1] = ACTIONS(215), + [sym_nil_lit] = ACTIONS(217), [sym__dec] = ACTIONS(217), [sym__hex] = ACTIONS(217), [sym__radix] = ACTIONS(217), - [sym_string] = ACTIONS(215), - [sym_buffer] = ACTIONS(215), - [sym_symbol] = ACTIONS(217), + [sym_str_lit] = ACTIONS(215), + [sym_buf_lit] = ACTIONS(215), + [sym_sym_lit] = ACTIONS(217), [anon_sym_AT_LPAREN] = ACTIONS(215), [anon_sym_RPAREN] = ACTIONS(215), [anon_sym_AT_LBRACK] = ACTIONS(215), @@ -2623,22 +2623,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(215), [anon_sym_SEMI] = ACTIONS(215), [anon_sym_COMMA] = ACTIONS(215), - [sym_long_buffer] = ACTIONS(215), - [sym_long_string] = ACTIONS(215), + [sym_long_buf_lit] = ACTIONS(215), + [sym_long_str_lit] = ACTIONS(215), }, [35] = { [ts_builtin_sym_end] = ACTIONS(219), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(221), [anon_sym_true] = ACTIONS(221), - [aux_sym_keyword_token1] = ACTIONS(219), - [sym_nil] = ACTIONS(221), + [aux_sym_kwd_lit_token1] = ACTIONS(219), + [sym_nil_lit] = ACTIONS(221), [sym__dec] = ACTIONS(221), [sym__hex] = ACTIONS(221), [sym__radix] = ACTIONS(221), - [sym_string] = ACTIONS(219), - [sym_buffer] = ACTIONS(219), - [sym_symbol] = ACTIONS(221), + [sym_str_lit] = ACTIONS(219), + [sym_buf_lit] = ACTIONS(219), + [sym_sym_lit] = ACTIONS(221), [anon_sym_AT_LPAREN] = ACTIONS(219), [anon_sym_RPAREN] = ACTIONS(219), [anon_sym_AT_LBRACK] = ACTIONS(219), @@ -2653,22 +2653,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(219), [anon_sym_SEMI] = ACTIONS(219), [anon_sym_COMMA] = ACTIONS(219), - [sym_long_buffer] = ACTIONS(219), - [sym_long_string] = ACTIONS(219), + [sym_long_buf_lit] = ACTIONS(219), + [sym_long_str_lit] = ACTIONS(219), }, [36] = { [ts_builtin_sym_end] = ACTIONS(223), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(225), [anon_sym_true] = ACTIONS(225), - [aux_sym_keyword_token1] = ACTIONS(223), - [sym_nil] = ACTIONS(225), + [aux_sym_kwd_lit_token1] = ACTIONS(223), + [sym_nil_lit] = ACTIONS(225), [sym__dec] = ACTIONS(225), [sym__hex] = ACTIONS(225), [sym__radix] = ACTIONS(225), - [sym_string] = ACTIONS(223), - [sym_buffer] = ACTIONS(223), - [sym_symbol] = ACTIONS(225), + [sym_str_lit] = ACTIONS(223), + [sym_buf_lit] = ACTIONS(223), + [sym_sym_lit] = ACTIONS(225), [anon_sym_AT_LPAREN] = ACTIONS(223), [anon_sym_RPAREN] = ACTIONS(223), [anon_sym_AT_LBRACK] = ACTIONS(223), @@ -2683,22 +2683,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(223), [anon_sym_SEMI] = ACTIONS(223), [anon_sym_COMMA] = ACTIONS(223), - [sym_long_buffer] = ACTIONS(223), - [sym_long_string] = ACTIONS(223), + [sym_long_buf_lit] = ACTIONS(223), + [sym_long_str_lit] = ACTIONS(223), }, [37] = { [ts_builtin_sym_end] = ACTIONS(227), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(229), [anon_sym_true] = ACTIONS(229), - [aux_sym_keyword_token1] = ACTIONS(227), - [sym_nil] = ACTIONS(229), + [aux_sym_kwd_lit_token1] = ACTIONS(227), + [sym_nil_lit] = ACTIONS(229), [sym__dec] = ACTIONS(229), [sym__hex] = ACTIONS(229), [sym__radix] = ACTIONS(229), - [sym_string] = ACTIONS(227), - [sym_buffer] = ACTIONS(227), - [sym_symbol] = ACTIONS(229), + [sym_str_lit] = ACTIONS(227), + [sym_buf_lit] = ACTIONS(227), + [sym_sym_lit] = ACTIONS(229), [anon_sym_AT_LPAREN] = ACTIONS(227), [anon_sym_RPAREN] = ACTIONS(227), [anon_sym_AT_LBRACK] = ACTIONS(227), @@ -2713,22 +2713,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(227), [anon_sym_SEMI] = ACTIONS(227), [anon_sym_COMMA] = ACTIONS(227), - [sym_long_buffer] = ACTIONS(227), - [sym_long_string] = ACTIONS(227), + [sym_long_buf_lit] = ACTIONS(227), + [sym_long_str_lit] = ACTIONS(227), }, [38] = { [ts_builtin_sym_end] = ACTIONS(231), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(233), [anon_sym_true] = ACTIONS(233), - [aux_sym_keyword_token1] = ACTIONS(231), - [sym_nil] = ACTIONS(233), + [aux_sym_kwd_lit_token1] = ACTIONS(231), + [sym_nil_lit] = ACTIONS(233), [sym__dec] = ACTIONS(233), [sym__hex] = ACTIONS(233), [sym__radix] = ACTIONS(233), - [sym_string] = ACTIONS(231), - [sym_buffer] = ACTIONS(231), - [sym_symbol] = ACTIONS(233), + [sym_str_lit] = ACTIONS(231), + [sym_buf_lit] = ACTIONS(231), + [sym_sym_lit] = ACTIONS(233), [anon_sym_AT_LPAREN] = ACTIONS(231), [anon_sym_RPAREN] = ACTIONS(231), [anon_sym_AT_LBRACK] = ACTIONS(231), @@ -2743,22 +2743,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(231), [anon_sym_SEMI] = ACTIONS(231), [anon_sym_COMMA] = ACTIONS(231), - [sym_long_buffer] = ACTIONS(231), - [sym_long_string] = ACTIONS(231), + [sym_long_buf_lit] = ACTIONS(231), + [sym_long_str_lit] = ACTIONS(231), }, [39] = { [ts_builtin_sym_end] = ACTIONS(235), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(237), [anon_sym_true] = ACTIONS(237), - [aux_sym_keyword_token1] = ACTIONS(235), - [sym_nil] = ACTIONS(237), + [aux_sym_kwd_lit_token1] = ACTIONS(235), + [sym_nil_lit] = ACTIONS(237), [sym__dec] = ACTIONS(237), [sym__hex] = ACTIONS(237), [sym__radix] = ACTIONS(237), - [sym_string] = ACTIONS(235), - [sym_buffer] = ACTIONS(235), - [sym_symbol] = ACTIONS(237), + [sym_str_lit] = ACTIONS(235), + [sym_buf_lit] = ACTIONS(235), + [sym_sym_lit] = ACTIONS(237), [anon_sym_AT_LPAREN] = ACTIONS(235), [anon_sym_RPAREN] = ACTIONS(235), [anon_sym_AT_LBRACK] = ACTIONS(235), @@ -2773,22 +2773,22 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(235), [anon_sym_SEMI] = ACTIONS(235), [anon_sym_COMMA] = ACTIONS(235), - [sym_long_buffer] = ACTIONS(235), - [sym_long_string] = ACTIONS(235), + [sym_long_buf_lit] = ACTIONS(235), + [sym_long_str_lit] = ACTIONS(235), }, [40] = { [ts_builtin_sym_end] = ACTIONS(239), [sym_comment] = ACTIONS(3), [anon_sym_false] = ACTIONS(241), [anon_sym_true] = ACTIONS(241), - [aux_sym_keyword_token1] = ACTIONS(239), - [sym_nil] = ACTIONS(241), + [aux_sym_kwd_lit_token1] = ACTIONS(239), + [sym_nil_lit] = ACTIONS(241), [sym__dec] = ACTIONS(241), [sym__hex] = ACTIONS(241), [sym__radix] = ACTIONS(241), - [sym_string] = ACTIONS(239), - [sym_buffer] = ACTIONS(239), - [sym_symbol] = ACTIONS(241), + [sym_str_lit] = ACTIONS(239), + [sym_buf_lit] = ACTIONS(239), + [sym_sym_lit] = ACTIONS(241), [anon_sym_AT_LPAREN] = ACTIONS(239), [anon_sym_RPAREN] = ACTIONS(239), [anon_sym_AT_LBRACK] = ACTIONS(239), @@ -2803,8 +2803,8 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PIPE] = ACTIONS(239), [anon_sym_SEMI] = ACTIONS(239), [anon_sym_COMMA] = ACTIONS(239), - [sym_long_buffer] = ACTIONS(239), - [sym_long_string] = ACTIONS(239), + [sym_long_buf_lit] = ACTIONS(239), + [sym_long_str_lit] = ACTIONS(239), }, }; @@ -2895,22 +2895,22 @@ static TSParseActionEntry ts_parse_actions[] = { [157] = {.count = 1, .reusable = true}, SHIFT(32), [159] = {.count = 1, .reusable = false}, SHIFT(33), [161] = {.count = 1, .reusable = true}, SHIFT(33), - [163] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_array, 2), - [165] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_array, 2), - [167] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 2), - [169] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 2), - [171] = {.count = 1, .reusable = true}, REDUCE(sym_boolean, 1), - [173] = {.count = 1, .reusable = false}, REDUCE(sym_boolean, 1), - [175] = {.count = 1, .reusable = true}, REDUCE(sym_table, 2), - [177] = {.count = 1, .reusable = false}, REDUCE(sym_table, 2), - [179] = {.count = 1, .reusable = true}, REDUCE(sym_array, 2), - [181] = {.count = 1, .reusable = false}, REDUCE(sym_array, 2), - [183] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 2), - [185] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 2), - [187] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_tuple, 2), - [189] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_tuple, 2), - [191] = {.count = 1, .reusable = true}, REDUCE(sym_number, 1), - [193] = {.count = 1, .reusable = false}, REDUCE(sym_number, 1), + [163] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 2), + [165] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 2), + [167] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 2), + [169] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 2), + [171] = {.count = 1, .reusable = true}, REDUCE(sym_bool_lit, 1), + [173] = {.count = 1, .reusable = false}, REDUCE(sym_bool_lit, 1), + [175] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 2), + [177] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 2), + [179] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 2), + [181] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 2), + [183] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 2), + [185] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 2), + [187] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 2), + [189] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 2), + [191] = {.count = 1, .reusable = true}, REDUCE(sym_num_lit, 1), + [193] = {.count = 1, .reusable = false}, REDUCE(sym_num_lit, 1), [195] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), [197] = {.count = 1, .reusable = false}, REDUCE(sym_quasi_quote_form, 2), [199] = {.count = 1, .reusable = true}, REDUCE(sym_quote_form, 2), @@ -2921,20 +2921,20 @@ static TSParseActionEntry ts_parse_actions[] = { [209] = {.count = 1, .reusable = false}, REDUCE(sym_splice_form, 2), [211] = {.count = 1, .reusable = true}, REDUCE(sym_unquote_form, 2), [213] = {.count = 1, .reusable = false}, REDUCE(sym_unquote_form, 2), - [215] = {.count = 1, .reusable = true}, REDUCE(sym_keyword, 1), - [217] = {.count = 1, .reusable = false}, REDUCE(sym_keyword, 1), - [219] = {.count = 1, .reusable = true}, REDUCE(sym_array, 3), - [221] = {.count = 1, .reusable = false}, REDUCE(sym_array, 3), - [223] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_array, 3), - [225] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_array, 3), - [227] = {.count = 1, .reusable = true}, REDUCE(sym_struct, 3), - [229] = {.count = 1, .reusable = false}, REDUCE(sym_struct, 3), - [231] = {.count = 1, .reusable = true}, REDUCE(sym_table, 3), - [233] = {.count = 1, .reusable = false}, REDUCE(sym_table, 3), - [235] = {.count = 1, .reusable = true}, REDUCE(sym_tuple, 3), - [237] = {.count = 1, .reusable = false}, REDUCE(sym_tuple, 3), - [239] = {.count = 1, .reusable = true}, REDUCE(sym_bracket_tuple, 3), - [241] = {.count = 1, .reusable = false}, REDUCE(sym_bracket_tuple, 3), + [215] = {.count = 1, .reusable = true}, REDUCE(sym_kwd_lit, 1), + [217] = {.count = 1, .reusable = false}, REDUCE(sym_kwd_lit, 1), + [219] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 3), + [221] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 3), + [223] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 3), + [225] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 3), + [227] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 3), + [229] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 3), + [231] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 3), + [233] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 3), + [235] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 3), + [237] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 3), + [239] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 3), + [241] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 3), [243] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), }; diff --git a/src/scanner.cc b/src/scanner.cc index f7f291cb9..ab50478c0 100644 --- a/src/scanner.cc +++ b/src/scanner.cc @@ -8,8 +8,8 @@ using std::wstring; using std::iswspace; enum TokenType { - LONG_BUFFER, - LONG_STRING + LONG_BUF_LIT, + LONG_STR_LIT }; struct Scanner { @@ -19,10 +19,10 @@ struct Scanner { } if (lexer->lookahead == '@') { - lexer->result_symbol = LONG_BUFFER; + lexer->result_symbol = LONG_BUF_LIT; lexer->advance(lexer, false); } else { - lexer->result_symbol = LONG_STRING; + lexer->result_symbol = LONG_STR_LIT; } // long strings start with one or more backticks From c583c42ad5876cd193e7f5f7f60cc941d8d55130 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 25 Jan 2021 18:49:39 +0900 Subject: [PATCH 12/34] Recognize a-f in hex --- grammar.js | 2 +- src/grammar.json | 8 +++---- src/parser.c | 56 ++++++++++++++++++++++++++++++------------------ 3 files changed, 40 insertions(+), 26 deletions(-) diff --git a/grammar.js b/grammar.js index d6242eb51..2a63e54e6 100644 --- a/grammar.js +++ b/grammar.js @@ -4,7 +4,7 @@ const SIGN = const DIGIT = /[0-9]/; const HEX_DIGIT = - /[0-9A-F]/; + /[0-9A-Fa-f]/; const RADIX = choice('2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', diff --git a/src/grammar.json b/src/grammar.json index f93a9d41a..999c0c6ea 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -394,7 +394,7 @@ "type": "REPEAT1", "content": { "type": "PATTERN", - "value": "[0-9A-F]" + "value": "[0-9A-Fa-f]" } }, { @@ -427,7 +427,7 @@ "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9A-F]" + "value": "[0-9A-Fa-f]" } }, { @@ -446,7 +446,7 @@ "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9A-F]" + "value": "[0-9A-Fa-f]" } }, { @@ -479,7 +479,7 @@ "type": "REPEAT1", "content": { "type": "PATTERN", - "value": "[0-9A-F]" + "value": "[0-9A-Fa-f]" } }, { diff --git a/src/parser.c b/src/parser.c index 38cac5f10..d6e4ef790 100644 --- a/src/parser.c +++ b/src/parser.c @@ -400,18 +400,21 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (lookahead == '.') ADVANCE(5); if (lookahead == '_') ADVANCE(4); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(41); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(41); END_STATE(); case 4: if (lookahead == '.') ADVANCE(5); if (lookahead == '_') ADVANCE(4); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); END_STATE(); case 5: if (lookahead == '_') ADVANCE(5); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); END_STATE(); case 6: if (lookahead == '+' || @@ -766,21 +769,24 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (lookahead == '.') ADVANCE(49); if (lookahead == '_') ADVANCE(42); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(41); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(41); END_STATE(); case 42: ACCEPT_TOKEN(sym__hex); if (lookahead == '.') ADVANCE(49); if (lookahead == '_') ADVANCE(42); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); END_STATE(); case 43: ACCEPT_TOKEN(sym__hex); if (lookahead == '.') ADVANCE(50); if (lookahead == '_') ADVANCE(44); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(43); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(43); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -788,14 +794,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 44: ACCEPT_TOKEN(sym__hex); if (lookahead == '.') ADVANCE(50); if (lookahead == '_') ADVANCE(44); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -803,7 +810,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 45: ACCEPT_TOKEN(sym__hex); @@ -813,13 +820,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ACCEPT_TOKEN(sym__hex); if (lookahead == '_') ADVANCE(45); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); END_STATE(); case 47: ACCEPT_TOKEN(sym__hex); if (lookahead == '_') ADVANCE(48); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -827,7 +836,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 48: ACCEPT_TOKEN(sym__hex); @@ -845,13 +854,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ACCEPT_TOKEN(sym__hex); if (lookahead == '_') ADVANCE(49); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(46); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); END_STATE(); case 50: ACCEPT_TOKEN(sym__hex); if (lookahead == '_') ADVANCE(50); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -859,7 +870,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 51: ACCEPT_TOKEN(sym__radix); @@ -962,7 +973,8 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (lookahead == '.') ADVANCE(63); if (lookahead == '_') ADVANCE(61); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(43); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(43); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -970,14 +982,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 61: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(63); if (lookahead == '_') ADVANCE(61); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -985,7 +998,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 62: ACCEPT_TOKEN(sym_sym_lit); @@ -1004,7 +1017,8 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '_') ADVANCE(63); if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F')) ADVANCE(47); + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1012,7 +1026,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); END_STATE(); case 64: ACCEPT_TOKEN(sym_sym_lit); From 45418f750c44f409c698733e4b9276eeac91eaaa Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 25 Jan 2021 18:57:02 +0900 Subject: [PATCH 13/34] Use token for bool_lit --- grammar.js | 7 +- src/grammar.json | 25 +- src/node-types.json | 15 +- src/parser.c | 3104 +++++++++++++++++++++---------------------- 4 files changed, 1507 insertions(+), 1644 deletions(-) diff --git a/grammar.js b/grammar.js index 2a63e54e6..a63101356 100644 --- a/grammar.js +++ b/grammar.js @@ -71,8 +71,11 @@ module.exports = grammar({ // simplest things bool_lit: $ => - choice('false', - 'true'), + // XXX: without the token here, false and true are exposed as + // anonymous nodes it seems... + // yet, the same does not happen for nil...strange + token(choice('false', + 'true')), kwd_lit: $ => prec(2, token(seq(':', diff --git a/src/grammar.json b/src/grammar.json index 999c0c6ea..d35ea00ac 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -98,17 +98,20 @@ ] }, "bool_lit": { - "type": "CHOICE", - "members": [ - { - "type": "STRING", - "value": "false" - }, - { - "type": "STRING", - "value": "true" - } - ] + "type": "TOKEN", + "content": { + "type": "CHOICE", + "members": [ + { + "type": "STRING", + "value": "false" + }, + { + "type": "STRING", + "value": "true" + } + ] + } }, "kwd_lit": { "type": "PREC", diff --git a/src/node-types.json b/src/node-types.json index 8d7b131aa..57901ff55 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -1,9 +1,4 @@ [ - { - "type": "bool_lit", - "named": true, - "fields": {} - }, { "type": "kwd_lit", "named": true, @@ -1147,12 +1142,12 @@ "named": false }, { - "type": "buf_lit", + "type": "bool_lit", "named": true }, { - "type": "false", - "named": false + "type": "buf_lit", + "named": true }, { "type": "long_buf_lit", @@ -1174,10 +1169,6 @@ "type": "sym_lit", "named": true }, - { - "type": "true", - "named": false - }, { "type": "{", "named": false diff --git a/src/parser.c b/src/parser.c index d6e4ef790..a17d9bb74 100644 --- a/src/parser.c +++ b/src/parser.c @@ -6,67 +6,64 @@ #endif #define LANGUAGE_VERSION 11 -#define STATE_COUNT 42 -#define LARGE_STATE_COUNT 41 -#define SYMBOL_COUNT 45 +#define STATE_COUNT 41 +#define LARGE_STATE_COUNT 40 +#define SYMBOL_COUNT 43 #define ALIAS_COUNT 0 -#define TOKEN_COUNT 28 +#define TOKEN_COUNT 27 #define EXTERNAL_TOKEN_COUNT 2 #define FIELD_COUNT 0 #define MAX_ALIAS_SEQUENCE_LENGTH 3 enum { sym_comment = 1, - anon_sym_false = 2, - anon_sym_true = 3, - aux_sym_kwd_lit_token1 = 4, - sym_nil_lit = 5, - sym__dec = 6, - sym__hex = 7, - sym__radix = 8, - sym_str_lit = 9, - sym_buf_lit = 10, - sym_sym_lit = 11, - anon_sym_AT_LPAREN = 12, - anon_sym_RPAREN = 13, - anon_sym_AT_LBRACK = 14, - anon_sym_RBRACK = 15, - anon_sym_LBRACE = 16, - anon_sym_RBRACE = 17, - anon_sym_AT_LBRACE = 18, - anon_sym_LPAREN = 19, - anon_sym_LBRACK = 20, - anon_sym_TILDE = 21, - anon_sym_SQUOTE = 22, - anon_sym_PIPE = 23, - anon_sym_SEMI = 24, - anon_sym_COMMA = 25, - sym_long_buf_lit = 26, - sym_long_str_lit = 27, - sym_source = 28, - sym__form = 29, - sym_bool_lit = 30, - sym_kwd_lit = 31, - sym_num_lit = 32, - sym_par_arr_lit = 33, - sym_sqr_arr_lit = 34, - sym_struct_lit = 35, - sym_tbl_lit = 36, - sym_par_tup_lit = 37, - sym_sqr_tup_lit = 38, - sym_quasi_quote_form = 39, - sym_quote_form = 40, - sym_short_fn_form = 41, - sym_splice_form = 42, - sym_unquote_form = 43, - aux_sym_source_repeat1 = 44, + sym_bool_lit = 2, + aux_sym_kwd_lit_token1 = 3, + sym_nil_lit = 4, + sym__dec = 5, + sym__hex = 6, + sym__radix = 7, + sym_str_lit = 8, + sym_buf_lit = 9, + sym_sym_lit = 10, + anon_sym_AT_LPAREN = 11, + anon_sym_RPAREN = 12, + anon_sym_AT_LBRACK = 13, + anon_sym_RBRACK = 14, + anon_sym_LBRACE = 15, + anon_sym_RBRACE = 16, + anon_sym_AT_LBRACE = 17, + anon_sym_LPAREN = 18, + anon_sym_LBRACK = 19, + anon_sym_TILDE = 20, + anon_sym_SQUOTE = 21, + anon_sym_PIPE = 22, + anon_sym_SEMI = 23, + anon_sym_COMMA = 24, + sym_long_buf_lit = 25, + sym_long_str_lit = 26, + sym_source = 27, + sym__form = 28, + sym_kwd_lit = 29, + sym_num_lit = 30, + sym_par_arr_lit = 31, + sym_sqr_arr_lit = 32, + sym_struct_lit = 33, + sym_tbl_lit = 34, + sym_par_tup_lit = 35, + sym_sqr_tup_lit = 36, + sym_quasi_quote_form = 37, + sym_quote_form = 38, + sym_short_fn_form = 39, + sym_splice_form = 40, + sym_unquote_form = 41, + aux_sym_source_repeat1 = 42, }; static const char *ts_symbol_names[] = { [ts_builtin_sym_end] = "end", [sym_comment] = "comment", - [anon_sym_false] = "false", - [anon_sym_true] = "true", + [sym_bool_lit] = "bool_lit", [aux_sym_kwd_lit_token1] = "kwd_lit_token1", [sym_nil_lit] = "nil_lit", [sym__dec] = "_dec", @@ -93,7 +90,6 @@ static const char *ts_symbol_names[] = { [sym_long_str_lit] = "long_str_lit", [sym_source] = "source", [sym__form] = "_form", - [sym_bool_lit] = "bool_lit", [sym_kwd_lit] = "kwd_lit", [sym_num_lit] = "num_lit", [sym_par_arr_lit] = "par_arr_lit", @@ -113,8 +109,7 @@ static const char *ts_symbol_names[] = { static TSSymbol ts_symbol_map[] = { [ts_builtin_sym_end] = ts_builtin_sym_end, [sym_comment] = sym_comment, - [anon_sym_false] = anon_sym_false, - [anon_sym_true] = anon_sym_true, + [sym_bool_lit] = sym_bool_lit, [aux_sym_kwd_lit_token1] = aux_sym_kwd_lit_token1, [sym_nil_lit] = sym_nil_lit, [sym__dec] = sym__dec, @@ -141,7 +136,6 @@ static TSSymbol ts_symbol_map[] = { [sym_long_str_lit] = sym_long_str_lit, [sym_source] = sym_source, [sym__form] = sym__form, - [sym_bool_lit] = sym_bool_lit, [sym_kwd_lit] = sym_kwd_lit, [sym_num_lit] = sym_num_lit, [sym_par_arr_lit] = sym_par_arr_lit, @@ -167,13 +161,9 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [anon_sym_false] = { - .visible = true, - .named = false, - }, - [anon_sym_true] = { + [sym_bool_lit] = { .visible = true, - .named = false, + .named = true, }, [aux_sym_kwd_lit_token1] = { .visible = false, @@ -279,10 +269,6 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = false, .named = true, }, - [sym_bool_lit] = { - .visible = true, - .named = true, - }, [sym_kwd_lit] = { .visible = true, .named = true, @@ -353,46 +339,46 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (eof) ADVANCE(13); if (lookahead == '"') ADVANCE(1); if (lookahead == '#') ADVANCE(14); - if (lookahead == '\'') ADVANCE(89); - if (lookahead == '(') ADVANCE(86); - if (lookahead == ')') ADVANCE(80); + if (lookahead == '\'') ADVANCE(87); + if (lookahead == '(') ADVANCE(84); + if (lookahead == ')') ADVANCE(78); if (lookahead == '+' || - lookahead == '-') ADVANCE(58); - if (lookahead == ',') ADVANCE(92); - if (lookahead == '.') ADVANCE(62); - if (lookahead == '0') ADVANCE(19); - if (lookahead == '1') ADVANCE(24); - if (lookahead == '2') ADVANCE(25); - if (lookahead == '3') ADVANCE(23); - if (('4' <= lookahead && lookahead <= '9')) ADVANCE(22); - if (lookahead == ':') ADVANCE(17); - if (lookahead == ';') ADVANCE(91); - if (lookahead == '@') ADVANCE(57); - if (lookahead == '[') ADVANCE(87); - if (lookahead == ']') ADVANCE(82); - if (lookahead == '_') ADVANCE(59); - if (lookahead == 'f') ADVANCE(64); - if (lookahead == 'n') ADVANCE(67); - if (lookahead == 't') ADVANCE(70); - if (lookahead == '{') ADVANCE(83); - if (lookahead == '|') ADVANCE(90); - if (lookahead == '}') ADVANCE(84); - if (lookahead == '~') ADVANCE(88); + lookahead == '-') ADVANCE(57); + if (lookahead == ',') ADVANCE(90); + if (lookahead == '.') ADVANCE(61); + if (lookahead == '0') ADVANCE(18); + if (lookahead == '1') ADVANCE(23); + if (lookahead == '2') ADVANCE(24); + if (lookahead == '3') ADVANCE(22); + if (('4' <= lookahead && lookahead <= '9')) ADVANCE(21); + if (lookahead == ':') ADVANCE(16); + if (lookahead == ';') ADVANCE(89); + if (lookahead == '@') ADVANCE(56); + if (lookahead == '[') ADVANCE(85); + if (lookahead == ']') ADVANCE(80); + if (lookahead == '_') ADVANCE(58); + if (lookahead == 'f') ADVANCE(63); + if (lookahead == 'n') ADVANCE(65); + if (lookahead == 't') ADVANCE(68); + if (lookahead == '{') ADVANCE(81); + if (lookahead == '|') ADVANCE(88); + if (lookahead == '}') ADVANCE(82); + if (lookahead == '~') ADVANCE(86); if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' || lookahead == ' ') SKIP(0) if (('!' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 1: - if (lookahead == '"') ADVANCE(55); + if (lookahead == '"') ADVANCE(54); if (lookahead == '\\') ADVANCE(11); if (lookahead != 0) ADVANCE(1); END_STATE(); case 2: - if (lookahead == '"') ADVANCE(56); + if (lookahead == '"') ADVANCE(55); if (lookahead == '\\') ADVANCE(12); if (lookahead != 0) ADVANCE(2); END_STATE(); @@ -401,41 +387,41 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (lookahead == '_') ADVANCE(4); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(41); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(40); END_STATE(); case 4: if (lookahead == '.') ADVANCE(5); if (lookahead == '_') ADVANCE(4); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(45); END_STATE(); case 5: if (lookahead == '_') ADVANCE(5); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(45); END_STATE(); case 6: if (lookahead == '+' || lookahead == '-') ADVANCE(8); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(38); END_STATE(); case 7: if (lookahead == '+' || lookahead == '-') ADVANCE(9); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(52); END_STATE(); case 8: - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(38); END_STATE(); case 9: - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(52); END_STATE(); case 10: if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(50); END_STATE(); case 11: if (lookahead != 0) ADVANCE(1); @@ -452,7 +438,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { lookahead != '\n') ADVANCE(14); END_STATE(); case 15: - ACCEPT_TOKEN(anon_sym_false); + ACCEPT_TOKEN(sym_bool_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -461,21 +447,9 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 16: - ACCEPT_TOKEN(anon_sym_true); - if (lookahead == '!' || - ('$' <= lookahead && lookahead <= '&') || - lookahead == '*' || - lookahead == '+' || - ('-' <= lookahead && lookahead <= ':') || - ('<' <= lookahead && lookahead <= 'Z') || - lookahead == '^' || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); - END_STATE(); - case 17: ACCEPT_TOKEN(aux_sym_kwd_lit_token1); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -485,9 +459,9 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(17); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(16); END_STATE(); - case 18: + case 17: ACCEPT_TOKEN(sym_nil_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -497,80 +471,80 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 19: + case 18: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); + if (lookahead == '.') ADVANCE(32); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(20); + if (lookahead == '_') ADVANCE(19); if (lookahead == 'x') ADVANCE(3); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(20); END_STATE(); - case 20: + case 19: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); + if (lookahead == '.') ADVANCE(32); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(20); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); + if (lookahead == '_') ADVANCE(19); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(34); END_STATE(); - case 21: + case 20: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); + if (lookahead == '.') ADVANCE(32); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(20); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + if (lookahead == '_') ADVANCE(19); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(20); END_STATE(); - case 22: + case 21: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); + if (lookahead == '.') ADVANCE(32); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); if (lookahead == 'R' || lookahead == 'r') ADVANCE(10); - if (lookahead == '_') ADVANCE(20); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); + if (lookahead == '_') ADVANCE(19); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(20); END_STATE(); - case 23: + case 22: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); - if (('0' <= lookahead && lookahead <= '6')) ADVANCE(22); + if (lookahead == '.') ADVANCE(32); + if (('0' <= lookahead && lookahead <= '6')) ADVANCE(21); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); if (lookahead == 'R' || lookahead == 'r') ADVANCE(10); - if (lookahead == '_') ADVANCE(20); - if (('7' <= lookahead && lookahead <= '9')) ADVANCE(21); + if (lookahead == '_') ADVANCE(19); + if (('7' <= lookahead && lookahead <= '9')) ADVANCE(20); END_STATE(); - case 24: + case 23: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(22); + if (lookahead == '.') ADVANCE(32); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(20); + if (lookahead == '_') ADVANCE(19); END_STATE(); - case 25: + case 24: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(33); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(22); + if (lookahead == '.') ADVANCE(32); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(21); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); if (lookahead == 'R' || lookahead == 'r') ADVANCE(10); - if (lookahead == '_') ADVANCE(20); + if (lookahead == '_') ADVANCE(19); END_STATE(); - case 26: + case 25: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); + if (lookahead == '.') ADVANCE(37); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(27); - if (lookahead == 'x') ADVANCE(60); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(26); + if (lookahead == 'x') ADVANCE(59); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(27); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -578,15 +552,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 27: + case 26: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); + if (lookahead == '.') ADVANCE(37); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(27); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(26); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -594,15 +568,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 28: + case 27: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); + if (lookahead == '.') ADVANCE(37); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(27); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(26); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(27); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -610,17 +584,17 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 29: + case 28: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); + if (lookahead == '.') ADVANCE(37); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); + lookahead == 'e') ADVANCE(71); if (lookahead == 'R' || - lookahead == 'r') ADVANCE(77); - if (lookahead == '_') ADVANCE(27); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); + lookahead == 'r') ADVANCE(75); + if (lookahead == '_') ADVANCE(26); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(27); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -628,18 +602,18 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 30: + case 29: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); - if (('0' <= lookahead && lookahead <= '6')) ADVANCE(29); + if (lookahead == '.') ADVANCE(37); + if (('0' <= lookahead && lookahead <= '6')) ADVANCE(28); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); + lookahead == 'e') ADVANCE(71); if (lookahead == 'R' || - lookahead == 'r') ADVANCE(77); - if (lookahead == '_') ADVANCE(27); - if (('7' <= lookahead && lookahead <= '9')) ADVANCE(28); + lookahead == 'r') ADVANCE(75); + if (lookahead == '_') ADVANCE(26); + if (('7' <= lookahead && lookahead <= '9')) ADVANCE(27); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -647,15 +621,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 31: + case 30: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(29); + if (lookahead == '.') ADVANCE(37); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(27); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(26); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -663,17 +637,17 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 32: + case 31: ACCEPT_TOKEN(sym__dec); - if (lookahead == '.') ADVANCE(38); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(29); + if (lookahead == '.') ADVANCE(37); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(28); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); + lookahead == 'e') ADVANCE(71); if (lookahead == 'R' || - lookahead == 'r') ADVANCE(77); - if (lookahead == '_') ADVANCE(27); + lookahead == 'r') ADVANCE(75); + if (lookahead == '_') ADVANCE(26); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -681,34 +655,34 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); + END_STATE(); + case 32: + ACCEPT_TOKEN(sym__dec); + if (lookahead == 'E' || + lookahead == 'e') ADVANCE(6); + if (lookahead == '_') ADVANCE(32); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(34); END_STATE(); case 33: ACCEPT_TOKEN(sym__dec); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); if (lookahead == '_') ADVANCE(33); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); END_STATE(); case 34: ACCEPT_TOKEN(sym__dec); if (lookahead == 'E' || lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(34); + if (lookahead == '_') ADVANCE(33); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(34); END_STATE(); case 35: ACCEPT_TOKEN(sym__dec); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(6); - if (lookahead == '_') ADVANCE(34); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(36); if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); - END_STATE(); - case 36: - ACCEPT_TOKEN(sym__dec); - if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(37); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -716,13 +690,13 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 37: + case 36: ACCEPT_TOKEN(sym__dec); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(37); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(36); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -730,14 +704,14 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 38: + case 37: ACCEPT_TOKEN(sym__dec); if (lookahead == 'E' || - lookahead == 'e') ADVANCE(73); - if (lookahead == '_') ADVANCE(38); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + lookahead == 'e') ADVANCE(71); + if (lookahead == '_') ADVANCE(37); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -745,15 +719,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 39: + case 38: ACCEPT_TOKEN(sym__dec); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(38); END_STATE(); - case 40: + case 39: ACCEPT_TOKEN(sym__dec); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -762,31 +736,31 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 41: + case 40: ACCEPT_TOKEN(sym__hex); - if (lookahead == '.') ADVANCE(49); - if (lookahead == '_') ADVANCE(42); + if (lookahead == '.') ADVANCE(48); + if (lookahead == '_') ADVANCE(41); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(41); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(40); END_STATE(); - case 42: + case 41: ACCEPT_TOKEN(sym__hex); - if (lookahead == '.') ADVANCE(49); - if (lookahead == '_') ADVANCE(42); + if (lookahead == '.') ADVANCE(48); + if (lookahead == '_') ADVANCE(41); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(45); END_STATE(); - case 43: + case 42: ACCEPT_TOKEN(sym__hex); - if (lookahead == '.') ADVANCE(50); - if (lookahead == '_') ADVANCE(44); + if (lookahead == '.') ADVANCE(49); + if (lookahead == '_') ADVANCE(43); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(43); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(42); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -794,15 +768,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 44: + case 43: ACCEPT_TOKEN(sym__hex); - if (lookahead == '.') ADVANCE(50); - if (lookahead == '_') ADVANCE(44); + if (lookahead == '.') ADVANCE(49); + if (lookahead == '_') ADVANCE(43); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -810,25 +784,25 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 45: + case 44: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(45); + if (lookahead == '_') ADVANCE(44); END_STATE(); - case 46: + case 45: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(45); + if (lookahead == '_') ADVANCE(44); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(45); END_STATE(); - case 47: + case 46: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(48); + if (lookahead == '_') ADVANCE(47); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -836,11 +810,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 48: + case 47: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(48); + if (lookahead == '_') ADVANCE(47); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -848,21 +822,21 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 49: + case 48: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(49); + if (lookahead == '_') ADVANCE(48); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(45); END_STATE(); - case 50: + case 49: ACCEPT_TOKEN(sym__hex); - if (lookahead == '_') ADVANCE(50); + if (lookahead == '_') ADVANCE(49); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -870,20 +844,20 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 51: + case 50: ACCEPT_TOKEN(sym__radix); if (lookahead == '&') ADVANCE(7); - if (lookahead == '_') ADVANCE(51); + if (lookahead == '_') ADVANCE(50); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(50); END_STATE(); - case 52: + case 51: ACCEPT_TOKEN(sym__radix); - if (lookahead == '&') ADVANCE(74); - if (lookahead == '_') ADVANCE(52); + if (lookahead == '&') ADVANCE(72); + if (lookahead == '_') ADVANCE(51); if (lookahead == '!' || lookahead == '$' || lookahead == '%' || @@ -892,18 +866,18 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= '/') || lookahead == ':' || ('<' <= lookahead && lookahead <= '@') || - lookahead == '^') ADVANCE(78); + lookahead == '^') ADVANCE(76); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(52); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); END_STATE(); - case 53: + case 52: ACCEPT_TOKEN(sym__radix); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(52); END_STATE(); - case 54: + case 53: ACCEPT_TOKEN(sym__radix); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -912,20 +886,20 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 55: + case 54: ACCEPT_TOKEN(sym_str_lit); END_STATE(); - case 56: + case 55: ACCEPT_TOKEN(sym_buf_lit); END_STATE(); - case 57: + case 56: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '"') ADVANCE(2); - if (lookahead == '(') ADVANCE(79); - if (lookahead == '[') ADVANCE(81); - if (lookahead == '{') ADVANCE(85); + if (lookahead == '(') ADVANCE(77); + if (lookahead == '[') ADVANCE(79); + if (lookahead == '{') ADVANCE(83); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -934,17 +908,31 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); + END_STATE(); + case 57: + ACCEPT_TOKEN(sym_sym_lit); + if (lookahead == '.') ADVANCE(61); + if (lookahead == '0') ADVANCE(25); + if (lookahead == '1') ADVANCE(30); + if (lookahead == '2') ADVANCE(31); + if (lookahead == '3') ADVANCE(29); + if (('4' <= lookahead && lookahead <= '9')) ADVANCE(28); + if (lookahead == '_') ADVANCE(58); + if (lookahead == '!' || + ('$' <= lookahead && lookahead <= '&') || + lookahead == '*' || + lookahead == '+' || + ('-' <= lookahead && lookahead <= ':') || + ('<' <= lookahead && lookahead <= 'Z') || + lookahead == '^' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 58: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == '.') ADVANCE(62); - if (lookahead == '0') ADVANCE(26); - if (lookahead == '1') ADVANCE(31); - if (lookahead == '2') ADVANCE(32); - if (lookahead == '3') ADVANCE(30); - if (('4' <= lookahead && lookahead <= '9')) ADVANCE(29); - if (lookahead == '_') ADVANCE(59); + if (lookahead == '.') ADVANCE(61); + if (lookahead == '_') ADVANCE(58); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -952,13 +940,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 59: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '.') ADVANCE(62); - if (lookahead == '_') ADVANCE(59); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (lookahead == '_') ADVANCE(60); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(42); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -966,15 +956,15 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 60: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == '.') ADVANCE(63); - if (lookahead == '_') ADVANCE(61); + if (lookahead == '.') ADVANCE(62); + if (lookahead == '_') ADVANCE(60); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(43); + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -982,15 +972,12 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 61: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == '.') ADVANCE(63); if (lookahead == '_') ADVANCE(61); - if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(35); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -998,12 +985,14 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 62: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '_') ADVANCE(62); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(36); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'F') || + ('a' <= lookahead && lookahead <= 'f')) ADVANCE(46); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1011,14 +1000,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('g' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 63: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == '_') ADVANCE(63); - if (('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'F') || - ('a' <= lookahead && lookahead <= 'f')) ADVANCE(47); + if (lookahead == 'a') ADVANCE(66); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1026,11 +1012,12 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('-' <= lookahead && lookahead <= ':') || ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || - ('g' <= lookahead && lookahead <= 'z')) ADVANCE(78); + lookahead == '_' || + ('b' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 64: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'a') ADVANCE(68); + if (lookahead == 'e') ADVANCE(15); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1039,11 +1026,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('b' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 65: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'e') ADVANCE(16); + if (lookahead == 'i') ADVANCE(67); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1052,11 +1039,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 66: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'e') ADVANCE(15); + if (lookahead == 'l') ADVANCE(69); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1065,11 +1052,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 67: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'i') ADVANCE(69); + if (lookahead == 'l') ADVANCE(17); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1078,11 +1065,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 68: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'l') ADVANCE(71); + if (lookahead == 'r') ADVANCE(70); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1091,11 +1078,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 69: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'l') ADVANCE(18); + if (lookahead == 's') ADVANCE(64); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1104,11 +1091,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 70: ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'r') ADVANCE(72); + if (lookahead == 'u') ADVANCE(64); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1117,39 +1104,13 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); case 71: - ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 's') ADVANCE(66); - if (lookahead == '!' || - ('$' <= lookahead && lookahead <= '&') || - lookahead == '*' || - lookahead == '+' || - ('-' <= lookahead && lookahead <= ':') || - ('<' <= lookahead && lookahead <= 'Z') || - lookahead == '^' || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); - END_STATE(); - case 72: - ACCEPT_TOKEN(sym_sym_lit); - if (lookahead == 'u') ADVANCE(65); - if (lookahead == '!' || - ('$' <= lookahead && lookahead <= '&') || - lookahead == '*' || - lookahead == '+' || - ('-' <= lookahead && lookahead <= ':') || - ('<' <= lookahead && lookahead <= 'Z') || - lookahead == '^' || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); - END_STATE(); - case 73: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '+' || - lookahead == '-') ADVANCE(75); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + lookahead == '-') ADVANCE(73); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1157,13 +1118,13 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 74: + case 72: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '+' || - lookahead == '-') ADVANCE(76); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + lookahead == '-') ADVANCE(74); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1171,11 +1132,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 75: + case 73: ACCEPT_TOKEN(sym_sym_lit); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(40); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(39); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1184,11 +1145,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 76: + case 74: ACCEPT_TOKEN(sym_sym_lit); - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(54); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(53); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || lookahead == '*' || @@ -1197,9 +1158,9 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 77: + case 75: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1209,12 +1170,12 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { lookahead == ':' || ('<' <= lookahead && lookahead <= '@') || lookahead == '^' || - lookahead == '_') ADVANCE(78); + lookahead == '_') ADVANCE(76); if (('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(52); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(51); END_STATE(); - case 78: + case 76: ACCEPT_TOKEN(sym_sym_lit); if (lookahead == '!' || ('$' <= lookahead && lookahead <= '&') || @@ -1224,48 +1185,48 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { ('<' <= lookahead && lookahead <= 'Z') || lookahead == '^' || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(78); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); END_STATE(); - case 79: + case 77: ACCEPT_TOKEN(anon_sym_AT_LPAREN); END_STATE(); - case 80: + case 78: ACCEPT_TOKEN(anon_sym_RPAREN); END_STATE(); - case 81: + case 79: ACCEPT_TOKEN(anon_sym_AT_LBRACK); END_STATE(); - case 82: + case 80: ACCEPT_TOKEN(anon_sym_RBRACK); END_STATE(); - case 83: + case 81: ACCEPT_TOKEN(anon_sym_LBRACE); END_STATE(); - case 84: + case 82: ACCEPT_TOKEN(anon_sym_RBRACE); END_STATE(); - case 85: + case 83: ACCEPT_TOKEN(anon_sym_AT_LBRACE); END_STATE(); - case 86: + case 84: ACCEPT_TOKEN(anon_sym_LPAREN); END_STATE(); - case 87: + case 85: ACCEPT_TOKEN(anon_sym_LBRACK); END_STATE(); - case 88: + case 86: ACCEPT_TOKEN(anon_sym_TILDE); END_STATE(); - case 89: + case 87: ACCEPT_TOKEN(anon_sym_SQUOTE); END_STATE(); - case 90: + case 88: ACCEPT_TOKEN(anon_sym_PIPE); END_STATE(); - case 91: + case 89: ACCEPT_TOKEN(anon_sym_SEMI); END_STATE(); - case 92: + case 90: ACCEPT_TOKEN(anon_sym_COMMA); END_STATE(); default: @@ -1314,8 +1275,7 @@ static TSLexMode ts_lex_modes[STATE_COUNT] = { [37] = {.lex_state = 0, .external_lex_state = 1}, [38] = {.lex_state = 0, .external_lex_state = 1}, [39] = {.lex_state = 0, .external_lex_state = 1}, - [40] = {.lex_state = 0, .external_lex_state = 1}, - [41] = {.lex_state = 0}, + [40] = {.lex_state = 0}, }; enum { @@ -1339,8 +1299,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [0] = { [ts_builtin_sym_end] = ACTIONS(1), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(1), - [anon_sym_true] = ACTIONS(1), + [sym_bool_lit] = ACTIONS(1), [aux_sym_kwd_lit_token1] = ACTIONS(1), [sym_nil_lit] = ACTIONS(1), [sym__dec] = ACTIONS(1), @@ -1367,52 +1326,49 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(1), }, [1] = { - [sym_source] = STATE(41), - [sym__form] = STATE(12), - [sym_bool_lit] = STATE(12), - [sym_kwd_lit] = STATE(12), - [sym_num_lit] = STATE(12), - [sym_par_arr_lit] = STATE(12), - [sym_sqr_arr_lit] = STATE(12), - [sym_struct_lit] = STATE(12), - [sym_tbl_lit] = STATE(12), - [sym_par_tup_lit] = STATE(12), - [sym_sqr_tup_lit] = STATE(12), - [sym_quasi_quote_form] = STATE(12), - [sym_quote_form] = STATE(12), - [sym_short_fn_form] = STATE(12), - [sym_splice_form] = STATE(12), - [sym_unquote_form] = STATE(12), - [aux_sym_source_repeat1] = STATE(12), + [sym_source] = STATE(40), + [sym__form] = STATE(3), + [sym_kwd_lit] = STATE(3), + [sym_num_lit] = STATE(3), + [sym_par_arr_lit] = STATE(3), + [sym_sqr_arr_lit] = STATE(3), + [sym_struct_lit] = STATE(3), + [sym_tbl_lit] = STATE(3), + [sym_par_tup_lit] = STATE(3), + [sym_sqr_tup_lit] = STATE(3), + [sym_quasi_quote_form] = STATE(3), + [sym_quote_form] = STATE(3), + [sym_short_fn_form] = STATE(3), + [sym_splice_form] = STATE(3), + [sym_unquote_form] = STATE(3), + [aux_sym_source_repeat1] = STATE(3), [ts_builtin_sym_end] = ACTIONS(5), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(7), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(11), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(15), - [sym_buf_lit] = ACTIONS(15), - [sym_sym_lit] = ACTIONS(11), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(15), - [sym_long_str_lit] = ACTIONS(15), + [sym_nil_lit] = ACTIONS(7), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(13), + [sym_buf_lit] = ACTIONS(13), + [sym_sym_lit] = ACTIONS(7), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(13), + [sym_long_str_lit] = ACTIONS(13), }, [2] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1427,81 +1383,77 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), - [ts_builtin_sym_end] = ACTIONS(39), + [ts_builtin_sym_end] = ACTIONS(37), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(41), - [anon_sym_true] = ACTIONS(41), - [aux_sym_kwd_lit_token1] = ACTIONS(44), - [sym_nil_lit] = ACTIONS(47), - [sym__dec] = ACTIONS(50), - [sym__hex] = ACTIONS(50), - [sym__radix] = ACTIONS(50), - [sym_str_lit] = ACTIONS(53), - [sym_buf_lit] = ACTIONS(53), - [sym_sym_lit] = ACTIONS(47), - [anon_sym_AT_LPAREN] = ACTIONS(56), - [anon_sym_RPAREN] = ACTIONS(39), - [anon_sym_AT_LBRACK] = ACTIONS(59), - [anon_sym_RBRACK] = ACTIONS(39), - [anon_sym_LBRACE] = ACTIONS(62), - [anon_sym_RBRACE] = ACTIONS(39), - [anon_sym_AT_LBRACE] = ACTIONS(65), - [anon_sym_LPAREN] = ACTIONS(68), - [anon_sym_LBRACK] = ACTIONS(71), - [anon_sym_TILDE] = ACTIONS(74), - [anon_sym_SQUOTE] = ACTIONS(77), - [anon_sym_PIPE] = ACTIONS(80), - [anon_sym_SEMI] = ACTIONS(83), - [anon_sym_COMMA] = ACTIONS(86), - [sym_long_buf_lit] = ACTIONS(53), - [sym_long_str_lit] = ACTIONS(53), + [sym_bool_lit] = ACTIONS(39), + [aux_sym_kwd_lit_token1] = ACTIONS(42), + [sym_nil_lit] = ACTIONS(39), + [sym__dec] = ACTIONS(45), + [sym__hex] = ACTIONS(45), + [sym__radix] = ACTIONS(45), + [sym_str_lit] = ACTIONS(48), + [sym_buf_lit] = ACTIONS(48), + [sym_sym_lit] = ACTIONS(39), + [anon_sym_AT_LPAREN] = ACTIONS(51), + [anon_sym_RPAREN] = ACTIONS(37), + [anon_sym_AT_LBRACK] = ACTIONS(54), + [anon_sym_RBRACK] = ACTIONS(37), + [anon_sym_LBRACE] = ACTIONS(57), + [anon_sym_RBRACE] = ACTIONS(37), + [anon_sym_AT_LBRACE] = ACTIONS(60), + [anon_sym_LPAREN] = ACTIONS(63), + [anon_sym_LBRACK] = ACTIONS(66), + [anon_sym_TILDE] = ACTIONS(69), + [anon_sym_SQUOTE] = ACTIONS(72), + [anon_sym_PIPE] = ACTIONS(75), + [anon_sym_SEMI] = ACTIONS(78), + [anon_sym_COMMA] = ACTIONS(81), + [sym_long_buf_lit] = ACTIONS(48), + [sym_long_str_lit] = ACTIONS(48), }, [3] = { - [sym__form] = STATE(15), - [sym_bool_lit] = STATE(15), - [sym_kwd_lit] = STATE(15), - [sym_num_lit] = STATE(15), - [sym_par_arr_lit] = STATE(15), - [sym_sqr_arr_lit] = STATE(15), - [sym_struct_lit] = STATE(15), - [sym_tbl_lit] = STATE(15), - [sym_par_tup_lit] = STATE(15), - [sym_sqr_tup_lit] = STATE(15), - [sym_quasi_quote_form] = STATE(15), - [sym_quote_form] = STATE(15), - [sym_short_fn_form] = STATE(15), - [sym_splice_form] = STATE(15), - [sym_unquote_form] = STATE(15), - [aux_sym_source_repeat1] = STATE(15), + [sym__form] = STATE(2), + [sym_kwd_lit] = STATE(2), + [sym_num_lit] = STATE(2), + [sym_par_arr_lit] = STATE(2), + [sym_sqr_arr_lit] = STATE(2), + [sym_struct_lit] = STATE(2), + [sym_tbl_lit] = STATE(2), + [sym_par_tup_lit] = STATE(2), + [sym_sqr_tup_lit] = STATE(2), + [sym_quasi_quote_form] = STATE(2), + [sym_quote_form] = STATE(2), + [sym_short_fn_form] = STATE(2), + [sym_splice_form] = STATE(2), + [sym_unquote_form] = STATE(2), + [aux_sym_source_repeat1] = STATE(2), + [ts_builtin_sym_end] = ACTIONS(84), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(89), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(91), - [sym_buf_lit] = ACTIONS(91), - [sym_sym_lit] = ACTIONS(89), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_RBRACK] = ACTIONS(93), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(91), - [sym_long_str_lit] = ACTIONS(91), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [4] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1517,34 +1469,73 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_RPAREN] = ACTIONS(99), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_RBRACK] = ACTIONS(90), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [5] = { + [sym__form] = STATE(15), + [sym_kwd_lit] = STATE(15), + [sym_num_lit] = STATE(15), + [sym_par_arr_lit] = STATE(15), + [sym_sqr_arr_lit] = STATE(15), + [sym_struct_lit] = STATE(15), + [sym_tbl_lit] = STATE(15), + [sym_par_tup_lit] = STATE(15), + [sym_sqr_tup_lit] = STATE(15), + [sym_quasi_quote_form] = STATE(15), + [sym_quote_form] = STATE(15), + [sym_short_fn_form] = STATE(15), + [sym_splice_form] = STATE(15), + [sym_unquote_form] = STATE(15), + [aux_sym_source_repeat1] = STATE(15), + [sym_comment] = ACTIONS(3), + [sym_bool_lit] = ACTIONS(92), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(92), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(94), + [sym_buf_lit] = ACTIONS(94), + [sym_sym_lit] = ACTIONS(92), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_RPAREN] = ACTIONS(96), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(94), + [sym_long_str_lit] = ACTIONS(94), + }, + [6] = { [sym__form] = STATE(14), - [sym_bool_lit] = STATE(14), [sym_kwd_lit] = STATE(14), [sym_num_lit] = STATE(14), [sym_par_arr_lit] = STATE(14), @@ -1560,77 +1551,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(14), [aux_sym_source_repeat1] = STATE(14), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), - [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(101), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(103), - [sym_buf_lit] = ACTIONS(103), - [sym_sym_lit] = ACTIONS(101), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_RPAREN] = ACTIONS(105), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(103), - [sym_long_str_lit] = ACTIONS(103), - }, - [6] = { - [sym__form] = STATE(10), - [sym_bool_lit] = STATE(10), - [sym_kwd_lit] = STATE(10), - [sym_num_lit] = STATE(10), - [sym_par_arr_lit] = STATE(10), - [sym_sqr_arr_lit] = STATE(10), - [sym_struct_lit] = STATE(10), - [sym_tbl_lit] = STATE(10), - [sym_par_tup_lit] = STATE(10), - [sym_sqr_tup_lit] = STATE(10), - [sym_quasi_quote_form] = STATE(10), - [sym_quote_form] = STATE(10), - [sym_short_fn_form] = STATE(10), - [sym_splice_form] = STATE(10), - [sym_unquote_form] = STATE(10), - [aux_sym_source_repeat1] = STATE(10), - [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(98), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(107), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(109), - [sym_buf_lit] = ACTIONS(109), - [sym_sym_lit] = ACTIONS(107), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_RBRACK] = ACTIONS(111), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(109), - [sym_long_str_lit] = ACTIONS(109), + [sym_nil_lit] = ACTIONS(98), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(100), + [sym_buf_lit] = ACTIONS(100), + [sym_sym_lit] = ACTIONS(98), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_RBRACK] = ACTIONS(102), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(100), + [sym_long_str_lit] = ACTIONS(100), }, [7] = { [sym__form] = STATE(13), - [sym_bool_lit] = STATE(13), [sym_kwd_lit] = STATE(13), [sym_num_lit] = STATE(13), [sym_par_arr_lit] = STATE(13), @@ -1646,34 +1592,73 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(13), [aux_sym_source_repeat1] = STATE(13), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(104), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(113), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(115), - [sym_buf_lit] = ACTIONS(115), - [sym_sym_lit] = ACTIONS(113), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_RBRACE] = ACTIONS(117), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(115), - [sym_long_str_lit] = ACTIONS(115), + [sym_nil_lit] = ACTIONS(104), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(106), + [sym_buf_lit] = ACTIONS(106), + [sym_sym_lit] = ACTIONS(104), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_RBRACE] = ACTIONS(108), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(106), + [sym_long_str_lit] = ACTIONS(106), }, [8] = { + [sym__form] = STATE(12), + [sym_kwd_lit] = STATE(12), + [sym_num_lit] = STATE(12), + [sym_par_arr_lit] = STATE(12), + [sym_sqr_arr_lit] = STATE(12), + [sym_struct_lit] = STATE(12), + [sym_tbl_lit] = STATE(12), + [sym_par_tup_lit] = STATE(12), + [sym_sqr_tup_lit] = STATE(12), + [sym_quasi_quote_form] = STATE(12), + [sym_quote_form] = STATE(12), + [sym_short_fn_form] = STATE(12), + [sym_splice_form] = STATE(12), + [sym_unquote_form] = STATE(12), + [aux_sym_source_repeat1] = STATE(12), + [sym_comment] = ACTIONS(3), + [sym_bool_lit] = ACTIONS(110), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(110), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(112), + [sym_buf_lit] = ACTIONS(112), + [sym_sym_lit] = ACTIONS(110), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_RBRACE] = ACTIONS(114), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(112), + [sym_long_str_lit] = ACTIONS(112), + }, + [9] = { [sym__form] = STATE(11), - [sym_bool_lit] = STATE(11), [sym_kwd_lit] = STATE(11), [sym_num_lit] = STATE(11), [sym_par_arr_lit] = STATE(11), @@ -1689,34 +1674,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(11), [aux_sym_source_repeat1] = STATE(11), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(116), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(119), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(121), - [sym_buf_lit] = ACTIONS(121), - [sym_sym_lit] = ACTIONS(119), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_RBRACE] = ACTIONS(123), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(121), - [sym_long_str_lit] = ACTIONS(121), + [sym_nil_lit] = ACTIONS(116), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(118), + [sym_buf_lit] = ACTIONS(118), + [sym_sym_lit] = ACTIONS(116), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_RPAREN] = ACTIONS(120), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(118), + [sym_long_str_lit] = ACTIONS(118), }, - [9] = { + [10] = { [sym__form] = STATE(4), - [sym_bool_lit] = STATE(4), [sym_kwd_lit] = STATE(4), [sym_num_lit] = STATE(4), [sym_par_arr_lit] = STATE(4), @@ -1732,77 +1715,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(4), [aux_sym_source_repeat1] = STATE(4), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(122), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(125), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(127), - [sym_buf_lit] = ACTIONS(127), - [sym_sym_lit] = ACTIONS(125), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_RPAREN] = ACTIONS(129), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(127), - [sym_long_str_lit] = ACTIONS(127), - }, - [10] = { - [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), - [sym_kwd_lit] = STATE(2), - [sym_num_lit] = STATE(2), - [sym_par_arr_lit] = STATE(2), - [sym_sqr_arr_lit] = STATE(2), - [sym_struct_lit] = STATE(2), - [sym_tbl_lit] = STATE(2), - [sym_par_tup_lit] = STATE(2), - [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), - [aux_sym_source_repeat1] = STATE(2), - [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), - [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_RBRACK] = ACTIONS(131), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(122), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(124), + [sym_buf_lit] = ACTIONS(124), + [sym_sym_lit] = ACTIONS(122), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_RBRACK] = ACTIONS(126), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(124), + [sym_long_str_lit] = ACTIONS(124), }, [11] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1818,34 +1756,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_RBRACE] = ACTIONS(133), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_RPAREN] = ACTIONS(128), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [12] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1860,35 +1796,33 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_splice_form] = STATE(2), [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), - [ts_builtin_sym_end] = ACTIONS(135), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_RBRACE] = ACTIONS(130), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [13] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1904,34 +1838,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_RBRACE] = ACTIONS(137), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_RBRACE] = ACTIONS(132), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [14] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1947,34 +1879,32 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_RPAREN] = ACTIONS(139), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_RBRACK] = ACTIONS(134), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [15] = { [sym__form] = STATE(2), - [sym_bool_lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1990,34 +1920,110 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_unquote_form] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(86), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(95), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(97), - [sym_buf_lit] = ACTIONS(97), - [sym_sym_lit] = ACTIONS(95), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_RBRACK] = ACTIONS(141), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(97), - [sym_long_str_lit] = ACTIONS(97), + [sym_nil_lit] = ACTIONS(86), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(88), + [sym_buf_lit] = ACTIONS(88), + [sym_sym_lit] = ACTIONS(86), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_RPAREN] = ACTIONS(136), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(88), + [sym_long_str_lit] = ACTIONS(88), }, [16] = { + [sym__form] = STATE(21), + [sym_kwd_lit] = STATE(21), + [sym_num_lit] = STATE(21), + [sym_par_arr_lit] = STATE(21), + [sym_sqr_arr_lit] = STATE(21), + [sym_struct_lit] = STATE(21), + [sym_tbl_lit] = STATE(21), + [sym_par_tup_lit] = STATE(21), + [sym_sqr_tup_lit] = STATE(21), + [sym_quasi_quote_form] = STATE(21), + [sym_quote_form] = STATE(21), + [sym_short_fn_form] = STATE(21), + [sym_splice_form] = STATE(21), + [sym_unquote_form] = STATE(21), + [sym_comment] = ACTIONS(3), + [sym_bool_lit] = ACTIONS(138), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(138), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(140), + [sym_buf_lit] = ACTIONS(140), + [sym_sym_lit] = ACTIONS(138), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(140), + [sym_long_str_lit] = ACTIONS(140), + }, + [17] = { + [sym__form] = STATE(32), + [sym_kwd_lit] = STATE(32), + [sym_num_lit] = STATE(32), + [sym_par_arr_lit] = STATE(32), + [sym_sqr_arr_lit] = STATE(32), + [sym_struct_lit] = STATE(32), + [sym_tbl_lit] = STATE(32), + [sym_par_tup_lit] = STATE(32), + [sym_sqr_tup_lit] = STATE(32), + [sym_quasi_quote_form] = STATE(32), + [sym_quote_form] = STATE(32), + [sym_short_fn_form] = STATE(32), + [sym_splice_form] = STATE(32), + [sym_unquote_form] = STATE(32), + [sym_comment] = ACTIONS(3), + [sym_bool_lit] = ACTIONS(142), + [aux_sym_kwd_lit_token1] = ACTIONS(9), + [sym_nil_lit] = ACTIONS(142), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(144), + [sym_buf_lit] = ACTIONS(144), + [sym_sym_lit] = ACTIONS(142), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(144), + [sym_long_str_lit] = ACTIONS(144), + }, + [18] = { [sym__form] = STATE(29), - [sym_bool_lit] = STATE(29), [sym_kwd_lit] = STATE(29), [sym_num_lit] = STATE(29), [sym_par_arr_lit] = STATE(29), @@ -2032,33 +2038,31 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_splice_form] = STATE(29), [sym_unquote_form] = STATE(29), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(146), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(143), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(145), - [sym_buf_lit] = ACTIONS(145), - [sym_sym_lit] = ACTIONS(143), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(145), - [sym_long_str_lit] = ACTIONS(145), + [sym_nil_lit] = ACTIONS(146), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(148), + [sym_buf_lit] = ACTIONS(148), + [sym_sym_lit] = ACTIONS(146), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(148), + [sym_long_str_lit] = ACTIONS(148), }, - [17] = { + [19] = { [sym__form] = STATE(30), - [sym_bool_lit] = STATE(30), [sym_kwd_lit] = STATE(30), [sym_num_lit] = STATE(30), [sym_par_arr_lit] = STATE(30), @@ -2073,33 +2077,31 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_splice_form] = STATE(30), [sym_unquote_form] = STATE(30), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(150), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(147), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(149), - [sym_buf_lit] = ACTIONS(149), - [sym_sym_lit] = ACTIONS(147), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(149), - [sym_long_str_lit] = ACTIONS(149), + [sym_nil_lit] = ACTIONS(150), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(152), + [sym_buf_lit] = ACTIONS(152), + [sym_sym_lit] = ACTIONS(150), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(152), + [sym_long_str_lit] = ACTIONS(152), }, - [18] = { + [20] = { [sym__form] = STATE(31), - [sym_bool_lit] = STATE(31), [sym_kwd_lit] = STATE(31), [sym_num_lit] = STATE(31), [sym_par_arr_lit] = STATE(31), @@ -2114,711 +2116,579 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_splice_form] = STATE(31), [sym_unquote_form] = STATE(31), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), + [sym_bool_lit] = ACTIONS(154), [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(151), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(153), - [sym_buf_lit] = ACTIONS(153), - [sym_sym_lit] = ACTIONS(151), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(153), - [sym_long_str_lit] = ACTIONS(153), - }, - [19] = { - [sym__form] = STATE(32), - [sym_bool_lit] = STATE(32), - [sym_kwd_lit] = STATE(32), - [sym_num_lit] = STATE(32), - [sym_par_arr_lit] = STATE(32), - [sym_sqr_arr_lit] = STATE(32), - [sym_struct_lit] = STATE(32), - [sym_tbl_lit] = STATE(32), - [sym_par_tup_lit] = STATE(32), - [sym_sqr_tup_lit] = STATE(32), - [sym_quasi_quote_form] = STATE(32), - [sym_quote_form] = STATE(32), - [sym_short_fn_form] = STATE(32), - [sym_splice_form] = STATE(32), - [sym_unquote_form] = STATE(32), - [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), - [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(155), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(157), - [sym_buf_lit] = ACTIONS(157), - [sym_sym_lit] = ACTIONS(155), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(157), - [sym_long_str_lit] = ACTIONS(157), - }, - [20] = { - [sym__form] = STATE(33), - [sym_bool_lit] = STATE(33), - [sym_kwd_lit] = STATE(33), - [sym_num_lit] = STATE(33), - [sym_par_arr_lit] = STATE(33), - [sym_sqr_arr_lit] = STATE(33), - [sym_struct_lit] = STATE(33), - [sym_tbl_lit] = STATE(33), - [sym_par_tup_lit] = STATE(33), - [sym_sqr_tup_lit] = STATE(33), - [sym_quasi_quote_form] = STATE(33), - [sym_quote_form] = STATE(33), - [sym_short_fn_form] = STATE(33), - [sym_splice_form] = STATE(33), - [sym_unquote_form] = STATE(33), - [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(7), - [anon_sym_true] = ACTIONS(7), - [aux_sym_kwd_lit_token1] = ACTIONS(9), - [sym_nil_lit] = ACTIONS(159), - [sym__dec] = ACTIONS(13), - [sym__hex] = ACTIONS(13), - [sym__radix] = ACTIONS(13), - [sym_str_lit] = ACTIONS(161), - [sym_buf_lit] = ACTIONS(161), - [sym_sym_lit] = ACTIONS(159), - [anon_sym_AT_LPAREN] = ACTIONS(17), - [anon_sym_AT_LBRACK] = ACTIONS(19), - [anon_sym_LBRACE] = ACTIONS(21), - [anon_sym_AT_LBRACE] = ACTIONS(23), - [anon_sym_LPAREN] = ACTIONS(25), - [anon_sym_LBRACK] = ACTIONS(27), - [anon_sym_TILDE] = ACTIONS(29), - [anon_sym_SQUOTE] = ACTIONS(31), - [anon_sym_PIPE] = ACTIONS(33), - [anon_sym_SEMI] = ACTIONS(35), - [anon_sym_COMMA] = ACTIONS(37), - [sym_long_buf_lit] = ACTIONS(161), - [sym_long_str_lit] = ACTIONS(161), + [sym_nil_lit] = ACTIONS(154), + [sym__dec] = ACTIONS(11), + [sym__hex] = ACTIONS(11), + [sym__radix] = ACTIONS(11), + [sym_str_lit] = ACTIONS(156), + [sym_buf_lit] = ACTIONS(156), + [sym_sym_lit] = ACTIONS(154), + [anon_sym_AT_LPAREN] = ACTIONS(15), + [anon_sym_AT_LBRACK] = ACTIONS(17), + [anon_sym_LBRACE] = ACTIONS(19), + [anon_sym_AT_LBRACE] = ACTIONS(21), + [anon_sym_LPAREN] = ACTIONS(23), + [anon_sym_LBRACK] = ACTIONS(25), + [anon_sym_TILDE] = ACTIONS(27), + [anon_sym_SQUOTE] = ACTIONS(29), + [anon_sym_PIPE] = ACTIONS(31), + [anon_sym_SEMI] = ACTIONS(33), + [anon_sym_COMMA] = ACTIONS(35), + [sym_long_buf_lit] = ACTIONS(156), + [sym_long_str_lit] = ACTIONS(156), }, [21] = { - [ts_builtin_sym_end] = ACTIONS(163), + [ts_builtin_sym_end] = ACTIONS(158), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(165), - [anon_sym_true] = ACTIONS(165), - [aux_sym_kwd_lit_token1] = ACTIONS(163), - [sym_nil_lit] = ACTIONS(165), - [sym__dec] = ACTIONS(165), - [sym__hex] = ACTIONS(165), - [sym__radix] = ACTIONS(165), - [sym_str_lit] = ACTIONS(163), - [sym_buf_lit] = ACTIONS(163), - [sym_sym_lit] = ACTIONS(165), - [anon_sym_AT_LPAREN] = ACTIONS(163), - [anon_sym_RPAREN] = ACTIONS(163), - [anon_sym_AT_LBRACK] = ACTIONS(163), - [anon_sym_RBRACK] = ACTIONS(163), - [anon_sym_LBRACE] = ACTIONS(163), - [anon_sym_RBRACE] = ACTIONS(163), - [anon_sym_AT_LBRACE] = ACTIONS(163), - [anon_sym_LPAREN] = ACTIONS(163), - [anon_sym_LBRACK] = ACTIONS(163), - [anon_sym_TILDE] = ACTIONS(163), - [anon_sym_SQUOTE] = ACTIONS(163), - [anon_sym_PIPE] = ACTIONS(163), - [anon_sym_SEMI] = ACTIONS(163), - [anon_sym_COMMA] = ACTIONS(163), - [sym_long_buf_lit] = ACTIONS(163), - [sym_long_str_lit] = ACTIONS(163), + [sym_bool_lit] = ACTIONS(160), + [aux_sym_kwd_lit_token1] = ACTIONS(158), + [sym_nil_lit] = ACTIONS(160), + [sym__dec] = ACTIONS(160), + [sym__hex] = ACTIONS(160), + [sym__radix] = ACTIONS(160), + [sym_str_lit] = ACTIONS(158), + [sym_buf_lit] = ACTIONS(158), + [sym_sym_lit] = ACTIONS(160), + [anon_sym_AT_LPAREN] = ACTIONS(158), + [anon_sym_RPAREN] = ACTIONS(158), + [anon_sym_AT_LBRACK] = ACTIONS(158), + [anon_sym_RBRACK] = ACTIONS(158), + [anon_sym_LBRACE] = ACTIONS(158), + [anon_sym_RBRACE] = ACTIONS(158), + [anon_sym_AT_LBRACE] = ACTIONS(158), + [anon_sym_LPAREN] = ACTIONS(158), + [anon_sym_LBRACK] = ACTIONS(158), + [anon_sym_TILDE] = ACTIONS(158), + [anon_sym_SQUOTE] = ACTIONS(158), + [anon_sym_PIPE] = ACTIONS(158), + [anon_sym_SEMI] = ACTIONS(158), + [anon_sym_COMMA] = ACTIONS(158), + [sym_long_buf_lit] = ACTIONS(158), + [sym_long_str_lit] = ACTIONS(158), }, [22] = { - [ts_builtin_sym_end] = ACTIONS(167), + [ts_builtin_sym_end] = ACTIONS(162), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(169), - [anon_sym_true] = ACTIONS(169), - [aux_sym_kwd_lit_token1] = ACTIONS(167), - [sym_nil_lit] = ACTIONS(169), - [sym__dec] = ACTIONS(169), - [sym__hex] = ACTIONS(169), - [sym__radix] = ACTIONS(169), - [sym_str_lit] = ACTIONS(167), - [sym_buf_lit] = ACTIONS(167), - [sym_sym_lit] = ACTIONS(169), - [anon_sym_AT_LPAREN] = ACTIONS(167), - [anon_sym_RPAREN] = ACTIONS(167), - [anon_sym_AT_LBRACK] = ACTIONS(167), - [anon_sym_RBRACK] = ACTIONS(167), - [anon_sym_LBRACE] = ACTIONS(167), - [anon_sym_RBRACE] = ACTIONS(167), - [anon_sym_AT_LBRACE] = ACTIONS(167), - [anon_sym_LPAREN] = ACTIONS(167), - [anon_sym_LBRACK] = ACTIONS(167), - [anon_sym_TILDE] = ACTIONS(167), - [anon_sym_SQUOTE] = ACTIONS(167), - [anon_sym_PIPE] = ACTIONS(167), - [anon_sym_SEMI] = ACTIONS(167), - [anon_sym_COMMA] = ACTIONS(167), - [sym_long_buf_lit] = ACTIONS(167), - [sym_long_str_lit] = ACTIONS(167), + [sym_bool_lit] = ACTIONS(164), + [aux_sym_kwd_lit_token1] = ACTIONS(162), + [sym_nil_lit] = ACTIONS(164), + [sym__dec] = ACTIONS(164), + [sym__hex] = ACTIONS(164), + [sym__radix] = ACTIONS(164), + [sym_str_lit] = ACTIONS(162), + [sym_buf_lit] = ACTIONS(162), + [sym_sym_lit] = ACTIONS(164), + [anon_sym_AT_LPAREN] = ACTIONS(162), + [anon_sym_RPAREN] = ACTIONS(162), + [anon_sym_AT_LBRACK] = ACTIONS(162), + [anon_sym_RBRACK] = ACTIONS(162), + [anon_sym_LBRACE] = ACTIONS(162), + [anon_sym_RBRACE] = ACTIONS(162), + [anon_sym_AT_LBRACE] = ACTIONS(162), + [anon_sym_LPAREN] = ACTIONS(162), + [anon_sym_LBRACK] = ACTIONS(162), + [anon_sym_TILDE] = ACTIONS(162), + [anon_sym_SQUOTE] = ACTIONS(162), + [anon_sym_PIPE] = ACTIONS(162), + [anon_sym_SEMI] = ACTIONS(162), + [anon_sym_COMMA] = ACTIONS(162), + [sym_long_buf_lit] = ACTIONS(162), + [sym_long_str_lit] = ACTIONS(162), }, [23] = { - [ts_builtin_sym_end] = ACTIONS(171), + [ts_builtin_sym_end] = ACTIONS(166), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(173), - [anon_sym_true] = ACTIONS(173), - [aux_sym_kwd_lit_token1] = ACTIONS(171), - [sym_nil_lit] = ACTIONS(173), - [sym__dec] = ACTIONS(173), - [sym__hex] = ACTIONS(173), - [sym__radix] = ACTIONS(173), - [sym_str_lit] = ACTIONS(171), - [sym_buf_lit] = ACTIONS(171), - [sym_sym_lit] = ACTIONS(173), - [anon_sym_AT_LPAREN] = ACTIONS(171), - [anon_sym_RPAREN] = ACTIONS(171), - [anon_sym_AT_LBRACK] = ACTIONS(171), - [anon_sym_RBRACK] = ACTIONS(171), - [anon_sym_LBRACE] = ACTIONS(171), - [anon_sym_RBRACE] = ACTIONS(171), - [anon_sym_AT_LBRACE] = ACTIONS(171), - [anon_sym_LPAREN] = ACTIONS(171), - [anon_sym_LBRACK] = ACTIONS(171), - [anon_sym_TILDE] = ACTIONS(171), - [anon_sym_SQUOTE] = ACTIONS(171), - [anon_sym_PIPE] = ACTIONS(171), - [anon_sym_SEMI] = ACTIONS(171), - [anon_sym_COMMA] = ACTIONS(171), - [sym_long_buf_lit] = ACTIONS(171), - [sym_long_str_lit] = ACTIONS(171), + [sym_bool_lit] = ACTIONS(168), + [aux_sym_kwd_lit_token1] = ACTIONS(166), + [sym_nil_lit] = ACTIONS(168), + [sym__dec] = ACTIONS(168), + [sym__hex] = ACTIONS(168), + [sym__radix] = ACTIONS(168), + [sym_str_lit] = ACTIONS(166), + [sym_buf_lit] = ACTIONS(166), + [sym_sym_lit] = ACTIONS(168), + [anon_sym_AT_LPAREN] = ACTIONS(166), + [anon_sym_RPAREN] = ACTIONS(166), + [anon_sym_AT_LBRACK] = ACTIONS(166), + [anon_sym_RBRACK] = ACTIONS(166), + [anon_sym_LBRACE] = ACTIONS(166), + [anon_sym_RBRACE] = ACTIONS(166), + [anon_sym_AT_LBRACE] = ACTIONS(166), + [anon_sym_LPAREN] = ACTIONS(166), + [anon_sym_LBRACK] = ACTIONS(166), + [anon_sym_TILDE] = ACTIONS(166), + [anon_sym_SQUOTE] = ACTIONS(166), + [anon_sym_PIPE] = ACTIONS(166), + [anon_sym_SEMI] = ACTIONS(166), + [anon_sym_COMMA] = ACTIONS(166), + [sym_long_buf_lit] = ACTIONS(166), + [sym_long_str_lit] = ACTIONS(166), }, [24] = { - [ts_builtin_sym_end] = ACTIONS(175), + [ts_builtin_sym_end] = ACTIONS(170), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(177), - [anon_sym_true] = ACTIONS(177), - [aux_sym_kwd_lit_token1] = ACTIONS(175), - [sym_nil_lit] = ACTIONS(177), - [sym__dec] = ACTIONS(177), - [sym__hex] = ACTIONS(177), - [sym__radix] = ACTIONS(177), - [sym_str_lit] = ACTIONS(175), - [sym_buf_lit] = ACTIONS(175), - [sym_sym_lit] = ACTIONS(177), - [anon_sym_AT_LPAREN] = ACTIONS(175), - [anon_sym_RPAREN] = ACTIONS(175), - [anon_sym_AT_LBRACK] = ACTIONS(175), - [anon_sym_RBRACK] = ACTIONS(175), - [anon_sym_LBRACE] = ACTIONS(175), - [anon_sym_RBRACE] = ACTIONS(175), - [anon_sym_AT_LBRACE] = ACTIONS(175), - [anon_sym_LPAREN] = ACTIONS(175), - [anon_sym_LBRACK] = ACTIONS(175), - [anon_sym_TILDE] = ACTIONS(175), - [anon_sym_SQUOTE] = ACTIONS(175), - [anon_sym_PIPE] = ACTIONS(175), - [anon_sym_SEMI] = ACTIONS(175), - [anon_sym_COMMA] = ACTIONS(175), - [sym_long_buf_lit] = ACTIONS(175), - [sym_long_str_lit] = ACTIONS(175), + [sym_bool_lit] = ACTIONS(172), + [aux_sym_kwd_lit_token1] = ACTIONS(170), + [sym_nil_lit] = ACTIONS(172), + [sym__dec] = ACTIONS(172), + [sym__hex] = ACTIONS(172), + [sym__radix] = ACTIONS(172), + [sym_str_lit] = ACTIONS(170), + [sym_buf_lit] = ACTIONS(170), + [sym_sym_lit] = ACTIONS(172), + [anon_sym_AT_LPAREN] = ACTIONS(170), + [anon_sym_RPAREN] = ACTIONS(170), + [anon_sym_AT_LBRACK] = ACTIONS(170), + [anon_sym_RBRACK] = ACTIONS(170), + [anon_sym_LBRACE] = ACTIONS(170), + [anon_sym_RBRACE] = ACTIONS(170), + [anon_sym_AT_LBRACE] = ACTIONS(170), + [anon_sym_LPAREN] = ACTIONS(170), + [anon_sym_LBRACK] = ACTIONS(170), + [anon_sym_TILDE] = ACTIONS(170), + [anon_sym_SQUOTE] = ACTIONS(170), + [anon_sym_PIPE] = ACTIONS(170), + [anon_sym_SEMI] = ACTIONS(170), + [anon_sym_COMMA] = ACTIONS(170), + [sym_long_buf_lit] = ACTIONS(170), + [sym_long_str_lit] = ACTIONS(170), }, [25] = { - [ts_builtin_sym_end] = ACTIONS(179), + [ts_builtin_sym_end] = ACTIONS(174), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(181), - [anon_sym_true] = ACTIONS(181), - [aux_sym_kwd_lit_token1] = ACTIONS(179), - [sym_nil_lit] = ACTIONS(181), - [sym__dec] = ACTIONS(181), - [sym__hex] = ACTIONS(181), - [sym__radix] = ACTIONS(181), - [sym_str_lit] = ACTIONS(179), - [sym_buf_lit] = ACTIONS(179), - [sym_sym_lit] = ACTIONS(181), - [anon_sym_AT_LPAREN] = ACTIONS(179), - [anon_sym_RPAREN] = ACTIONS(179), - [anon_sym_AT_LBRACK] = ACTIONS(179), - [anon_sym_RBRACK] = ACTIONS(179), - [anon_sym_LBRACE] = ACTIONS(179), - [anon_sym_RBRACE] = ACTIONS(179), - [anon_sym_AT_LBRACE] = ACTIONS(179), - [anon_sym_LPAREN] = ACTIONS(179), - [anon_sym_LBRACK] = ACTIONS(179), - [anon_sym_TILDE] = ACTIONS(179), - [anon_sym_SQUOTE] = ACTIONS(179), - [anon_sym_PIPE] = ACTIONS(179), - [anon_sym_SEMI] = ACTIONS(179), - [anon_sym_COMMA] = ACTIONS(179), - [sym_long_buf_lit] = ACTIONS(179), - [sym_long_str_lit] = ACTIONS(179), + [sym_bool_lit] = ACTIONS(176), + [aux_sym_kwd_lit_token1] = ACTIONS(174), + [sym_nil_lit] = ACTIONS(176), + [sym__dec] = ACTIONS(176), + [sym__hex] = ACTIONS(176), + [sym__radix] = ACTIONS(176), + [sym_str_lit] = ACTIONS(174), + [sym_buf_lit] = ACTIONS(174), + [sym_sym_lit] = ACTIONS(176), + [anon_sym_AT_LPAREN] = ACTIONS(174), + [anon_sym_RPAREN] = ACTIONS(174), + [anon_sym_AT_LBRACK] = ACTIONS(174), + [anon_sym_RBRACK] = ACTIONS(174), + [anon_sym_LBRACE] = ACTIONS(174), + [anon_sym_RBRACE] = ACTIONS(174), + [anon_sym_AT_LBRACE] = ACTIONS(174), + [anon_sym_LPAREN] = ACTIONS(174), + [anon_sym_LBRACK] = ACTIONS(174), + [anon_sym_TILDE] = ACTIONS(174), + [anon_sym_SQUOTE] = ACTIONS(174), + [anon_sym_PIPE] = ACTIONS(174), + [anon_sym_SEMI] = ACTIONS(174), + [anon_sym_COMMA] = ACTIONS(174), + [sym_long_buf_lit] = ACTIONS(174), + [sym_long_str_lit] = ACTIONS(174), }, [26] = { - [ts_builtin_sym_end] = ACTIONS(183), + [ts_builtin_sym_end] = ACTIONS(178), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(185), - [anon_sym_true] = ACTIONS(185), - [aux_sym_kwd_lit_token1] = ACTIONS(183), - [sym_nil_lit] = ACTIONS(185), - [sym__dec] = ACTIONS(185), - [sym__hex] = ACTIONS(185), - [sym__radix] = ACTIONS(185), - [sym_str_lit] = ACTIONS(183), - [sym_buf_lit] = ACTIONS(183), - [sym_sym_lit] = ACTIONS(185), - [anon_sym_AT_LPAREN] = ACTIONS(183), - [anon_sym_RPAREN] = ACTIONS(183), - [anon_sym_AT_LBRACK] = ACTIONS(183), - [anon_sym_RBRACK] = ACTIONS(183), - [anon_sym_LBRACE] = ACTIONS(183), - [anon_sym_RBRACE] = ACTIONS(183), - [anon_sym_AT_LBRACE] = ACTIONS(183), - [anon_sym_LPAREN] = ACTIONS(183), - [anon_sym_LBRACK] = ACTIONS(183), - [anon_sym_TILDE] = ACTIONS(183), - [anon_sym_SQUOTE] = ACTIONS(183), - [anon_sym_PIPE] = ACTIONS(183), - [anon_sym_SEMI] = ACTIONS(183), - [anon_sym_COMMA] = ACTIONS(183), - [sym_long_buf_lit] = ACTIONS(183), - [sym_long_str_lit] = ACTIONS(183), + [sym_bool_lit] = ACTIONS(180), + [aux_sym_kwd_lit_token1] = ACTIONS(178), + [sym_nil_lit] = ACTIONS(180), + [sym__dec] = ACTIONS(180), + [sym__hex] = ACTIONS(180), + [sym__radix] = ACTIONS(180), + [sym_str_lit] = ACTIONS(178), + [sym_buf_lit] = ACTIONS(178), + [sym_sym_lit] = ACTIONS(180), + [anon_sym_AT_LPAREN] = ACTIONS(178), + [anon_sym_RPAREN] = ACTIONS(178), + [anon_sym_AT_LBRACK] = ACTIONS(178), + [anon_sym_RBRACK] = ACTIONS(178), + [anon_sym_LBRACE] = ACTIONS(178), + [anon_sym_RBRACE] = ACTIONS(178), + [anon_sym_AT_LBRACE] = ACTIONS(178), + [anon_sym_LPAREN] = ACTIONS(178), + [anon_sym_LBRACK] = ACTIONS(178), + [anon_sym_TILDE] = ACTIONS(178), + [anon_sym_SQUOTE] = ACTIONS(178), + [anon_sym_PIPE] = ACTIONS(178), + [anon_sym_SEMI] = ACTIONS(178), + [anon_sym_COMMA] = ACTIONS(178), + [sym_long_buf_lit] = ACTIONS(178), + [sym_long_str_lit] = ACTIONS(178), }, [27] = { - [ts_builtin_sym_end] = ACTIONS(187), + [ts_builtin_sym_end] = ACTIONS(182), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(189), - [anon_sym_true] = ACTIONS(189), - [aux_sym_kwd_lit_token1] = ACTIONS(187), - [sym_nil_lit] = ACTIONS(189), - [sym__dec] = ACTIONS(189), - [sym__hex] = ACTIONS(189), - [sym__radix] = ACTIONS(189), - [sym_str_lit] = ACTIONS(187), - [sym_buf_lit] = ACTIONS(187), - [sym_sym_lit] = ACTIONS(189), - [anon_sym_AT_LPAREN] = ACTIONS(187), - [anon_sym_RPAREN] = ACTIONS(187), - [anon_sym_AT_LBRACK] = ACTIONS(187), - [anon_sym_RBRACK] = ACTIONS(187), - [anon_sym_LBRACE] = ACTIONS(187), - [anon_sym_RBRACE] = ACTIONS(187), - [anon_sym_AT_LBRACE] = ACTIONS(187), - [anon_sym_LPAREN] = ACTIONS(187), - [anon_sym_LBRACK] = ACTIONS(187), - [anon_sym_TILDE] = ACTIONS(187), - [anon_sym_SQUOTE] = ACTIONS(187), - [anon_sym_PIPE] = ACTIONS(187), - [anon_sym_SEMI] = ACTIONS(187), - [anon_sym_COMMA] = ACTIONS(187), - [sym_long_buf_lit] = ACTIONS(187), - [sym_long_str_lit] = ACTIONS(187), + [sym_bool_lit] = ACTIONS(184), + [aux_sym_kwd_lit_token1] = ACTIONS(182), + [sym_nil_lit] = ACTIONS(184), + [sym__dec] = ACTIONS(184), + [sym__hex] = ACTIONS(184), + [sym__radix] = ACTIONS(184), + [sym_str_lit] = ACTIONS(182), + [sym_buf_lit] = ACTIONS(182), + [sym_sym_lit] = ACTIONS(184), + [anon_sym_AT_LPAREN] = ACTIONS(182), + [anon_sym_RPAREN] = ACTIONS(182), + [anon_sym_AT_LBRACK] = ACTIONS(182), + [anon_sym_RBRACK] = ACTIONS(182), + [anon_sym_LBRACE] = ACTIONS(182), + [anon_sym_RBRACE] = ACTIONS(182), + [anon_sym_AT_LBRACE] = ACTIONS(182), + [anon_sym_LPAREN] = ACTIONS(182), + [anon_sym_LBRACK] = ACTIONS(182), + [anon_sym_TILDE] = ACTIONS(182), + [anon_sym_SQUOTE] = ACTIONS(182), + [anon_sym_PIPE] = ACTIONS(182), + [anon_sym_SEMI] = ACTIONS(182), + [anon_sym_COMMA] = ACTIONS(182), + [sym_long_buf_lit] = ACTIONS(182), + [sym_long_str_lit] = ACTIONS(182), }, [28] = { - [ts_builtin_sym_end] = ACTIONS(191), + [ts_builtin_sym_end] = ACTIONS(186), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(193), - [anon_sym_true] = ACTIONS(193), - [aux_sym_kwd_lit_token1] = ACTIONS(191), - [sym_nil_lit] = ACTIONS(193), - [sym__dec] = ACTIONS(193), - [sym__hex] = ACTIONS(193), - [sym__radix] = ACTIONS(193), - [sym_str_lit] = ACTIONS(191), - [sym_buf_lit] = ACTIONS(191), - [sym_sym_lit] = ACTIONS(193), - [anon_sym_AT_LPAREN] = ACTIONS(191), - [anon_sym_RPAREN] = ACTIONS(191), - [anon_sym_AT_LBRACK] = ACTIONS(191), - [anon_sym_RBRACK] = ACTIONS(191), - [anon_sym_LBRACE] = ACTIONS(191), - [anon_sym_RBRACE] = ACTIONS(191), - [anon_sym_AT_LBRACE] = ACTIONS(191), - [anon_sym_LPAREN] = ACTIONS(191), - [anon_sym_LBRACK] = ACTIONS(191), - [anon_sym_TILDE] = ACTIONS(191), - [anon_sym_SQUOTE] = ACTIONS(191), - [anon_sym_PIPE] = ACTIONS(191), - [anon_sym_SEMI] = ACTIONS(191), - [anon_sym_COMMA] = ACTIONS(191), - [sym_long_buf_lit] = ACTIONS(191), - [sym_long_str_lit] = ACTIONS(191), + [sym_bool_lit] = ACTIONS(188), + [aux_sym_kwd_lit_token1] = ACTIONS(186), + [sym_nil_lit] = ACTIONS(188), + [sym__dec] = ACTIONS(188), + [sym__hex] = ACTIONS(188), + [sym__radix] = ACTIONS(188), + [sym_str_lit] = ACTIONS(186), + [sym_buf_lit] = ACTIONS(186), + [sym_sym_lit] = ACTIONS(188), + [anon_sym_AT_LPAREN] = ACTIONS(186), + [anon_sym_RPAREN] = ACTIONS(186), + [anon_sym_AT_LBRACK] = ACTIONS(186), + [anon_sym_RBRACK] = ACTIONS(186), + [anon_sym_LBRACE] = ACTIONS(186), + [anon_sym_RBRACE] = ACTIONS(186), + [anon_sym_AT_LBRACE] = ACTIONS(186), + [anon_sym_LPAREN] = ACTIONS(186), + [anon_sym_LBRACK] = ACTIONS(186), + [anon_sym_TILDE] = ACTIONS(186), + [anon_sym_SQUOTE] = ACTIONS(186), + [anon_sym_PIPE] = ACTIONS(186), + [anon_sym_SEMI] = ACTIONS(186), + [anon_sym_COMMA] = ACTIONS(186), + [sym_long_buf_lit] = ACTIONS(186), + [sym_long_str_lit] = ACTIONS(186), }, [29] = { - [ts_builtin_sym_end] = ACTIONS(195), + [ts_builtin_sym_end] = ACTIONS(190), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(197), - [anon_sym_true] = ACTIONS(197), - [aux_sym_kwd_lit_token1] = ACTIONS(195), - [sym_nil_lit] = ACTIONS(197), - [sym__dec] = ACTIONS(197), - [sym__hex] = ACTIONS(197), - [sym__radix] = ACTIONS(197), - [sym_str_lit] = ACTIONS(195), - [sym_buf_lit] = ACTIONS(195), - [sym_sym_lit] = ACTIONS(197), - [anon_sym_AT_LPAREN] = ACTIONS(195), - [anon_sym_RPAREN] = ACTIONS(195), - [anon_sym_AT_LBRACK] = ACTIONS(195), - [anon_sym_RBRACK] = ACTIONS(195), - [anon_sym_LBRACE] = ACTIONS(195), - [anon_sym_RBRACE] = ACTIONS(195), - [anon_sym_AT_LBRACE] = ACTIONS(195), - [anon_sym_LPAREN] = ACTIONS(195), - [anon_sym_LBRACK] = ACTIONS(195), - [anon_sym_TILDE] = ACTIONS(195), - [anon_sym_SQUOTE] = ACTIONS(195), - [anon_sym_PIPE] = ACTIONS(195), - [anon_sym_SEMI] = ACTIONS(195), - [anon_sym_COMMA] = ACTIONS(195), - [sym_long_buf_lit] = ACTIONS(195), - [sym_long_str_lit] = ACTIONS(195), + [sym_bool_lit] = ACTIONS(192), + [aux_sym_kwd_lit_token1] = ACTIONS(190), + [sym_nil_lit] = ACTIONS(192), + [sym__dec] = ACTIONS(192), + [sym__hex] = ACTIONS(192), + [sym__radix] = ACTIONS(192), + [sym_str_lit] = ACTIONS(190), + [sym_buf_lit] = ACTIONS(190), + [sym_sym_lit] = ACTIONS(192), + [anon_sym_AT_LPAREN] = ACTIONS(190), + [anon_sym_RPAREN] = ACTIONS(190), + [anon_sym_AT_LBRACK] = ACTIONS(190), + [anon_sym_RBRACK] = ACTIONS(190), + [anon_sym_LBRACE] = ACTIONS(190), + [anon_sym_RBRACE] = ACTIONS(190), + [anon_sym_AT_LBRACE] = ACTIONS(190), + [anon_sym_LPAREN] = ACTIONS(190), + [anon_sym_LBRACK] = ACTIONS(190), + [anon_sym_TILDE] = ACTIONS(190), + [anon_sym_SQUOTE] = ACTIONS(190), + [anon_sym_PIPE] = ACTIONS(190), + [anon_sym_SEMI] = ACTIONS(190), + [anon_sym_COMMA] = ACTIONS(190), + [sym_long_buf_lit] = ACTIONS(190), + [sym_long_str_lit] = ACTIONS(190), }, [30] = { - [ts_builtin_sym_end] = ACTIONS(199), + [ts_builtin_sym_end] = ACTIONS(194), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(201), - [anon_sym_true] = ACTIONS(201), - [aux_sym_kwd_lit_token1] = ACTIONS(199), - [sym_nil_lit] = ACTIONS(201), - [sym__dec] = ACTIONS(201), - [sym__hex] = ACTIONS(201), - [sym__radix] = ACTIONS(201), - [sym_str_lit] = ACTIONS(199), - [sym_buf_lit] = ACTIONS(199), - [sym_sym_lit] = ACTIONS(201), - [anon_sym_AT_LPAREN] = ACTIONS(199), - [anon_sym_RPAREN] = ACTIONS(199), - [anon_sym_AT_LBRACK] = ACTIONS(199), - [anon_sym_RBRACK] = ACTIONS(199), - [anon_sym_LBRACE] = ACTIONS(199), - [anon_sym_RBRACE] = ACTIONS(199), - [anon_sym_AT_LBRACE] = ACTIONS(199), - [anon_sym_LPAREN] = ACTIONS(199), - [anon_sym_LBRACK] = ACTIONS(199), - [anon_sym_TILDE] = ACTIONS(199), - [anon_sym_SQUOTE] = ACTIONS(199), - [anon_sym_PIPE] = ACTIONS(199), - [anon_sym_SEMI] = ACTIONS(199), - [anon_sym_COMMA] = ACTIONS(199), - [sym_long_buf_lit] = ACTIONS(199), - [sym_long_str_lit] = ACTIONS(199), + [sym_bool_lit] = ACTIONS(196), + [aux_sym_kwd_lit_token1] = ACTIONS(194), + [sym_nil_lit] = ACTIONS(196), + [sym__dec] = ACTIONS(196), + [sym__hex] = ACTIONS(196), + [sym__radix] = ACTIONS(196), + [sym_str_lit] = ACTIONS(194), + [sym_buf_lit] = ACTIONS(194), + [sym_sym_lit] = ACTIONS(196), + [anon_sym_AT_LPAREN] = ACTIONS(194), + [anon_sym_RPAREN] = ACTIONS(194), + [anon_sym_AT_LBRACK] = ACTIONS(194), + [anon_sym_RBRACK] = ACTIONS(194), + [anon_sym_LBRACE] = ACTIONS(194), + [anon_sym_RBRACE] = ACTIONS(194), + [anon_sym_AT_LBRACE] = ACTIONS(194), + [anon_sym_LPAREN] = ACTIONS(194), + [anon_sym_LBRACK] = ACTIONS(194), + [anon_sym_TILDE] = ACTIONS(194), + [anon_sym_SQUOTE] = ACTIONS(194), + [anon_sym_PIPE] = ACTIONS(194), + [anon_sym_SEMI] = ACTIONS(194), + [anon_sym_COMMA] = ACTIONS(194), + [sym_long_buf_lit] = ACTIONS(194), + [sym_long_str_lit] = ACTIONS(194), }, [31] = { - [ts_builtin_sym_end] = ACTIONS(203), + [ts_builtin_sym_end] = ACTIONS(198), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(205), - [anon_sym_true] = ACTIONS(205), - [aux_sym_kwd_lit_token1] = ACTIONS(203), - [sym_nil_lit] = ACTIONS(205), - [sym__dec] = ACTIONS(205), - [sym__hex] = ACTIONS(205), - [sym__radix] = ACTIONS(205), - [sym_str_lit] = ACTIONS(203), - [sym_buf_lit] = ACTIONS(203), - [sym_sym_lit] = ACTIONS(205), - [anon_sym_AT_LPAREN] = ACTIONS(203), - [anon_sym_RPAREN] = ACTIONS(203), - [anon_sym_AT_LBRACK] = ACTIONS(203), - [anon_sym_RBRACK] = ACTIONS(203), - [anon_sym_LBRACE] = ACTIONS(203), - [anon_sym_RBRACE] = ACTIONS(203), - [anon_sym_AT_LBRACE] = ACTIONS(203), - [anon_sym_LPAREN] = ACTIONS(203), - [anon_sym_LBRACK] = ACTIONS(203), - [anon_sym_TILDE] = ACTIONS(203), - [anon_sym_SQUOTE] = ACTIONS(203), - [anon_sym_PIPE] = ACTIONS(203), - [anon_sym_SEMI] = ACTIONS(203), - [anon_sym_COMMA] = ACTIONS(203), - [sym_long_buf_lit] = ACTIONS(203), - [sym_long_str_lit] = ACTIONS(203), + [sym_bool_lit] = ACTIONS(200), + [aux_sym_kwd_lit_token1] = ACTIONS(198), + [sym_nil_lit] = ACTIONS(200), + [sym__dec] = ACTIONS(200), + [sym__hex] = ACTIONS(200), + [sym__radix] = ACTIONS(200), + [sym_str_lit] = ACTIONS(198), + [sym_buf_lit] = ACTIONS(198), + [sym_sym_lit] = ACTIONS(200), + [anon_sym_AT_LPAREN] = ACTIONS(198), + [anon_sym_RPAREN] = ACTIONS(198), + [anon_sym_AT_LBRACK] = ACTIONS(198), + [anon_sym_RBRACK] = ACTIONS(198), + [anon_sym_LBRACE] = ACTIONS(198), + [anon_sym_RBRACE] = ACTIONS(198), + [anon_sym_AT_LBRACE] = ACTIONS(198), + [anon_sym_LPAREN] = ACTIONS(198), + [anon_sym_LBRACK] = ACTIONS(198), + [anon_sym_TILDE] = ACTIONS(198), + [anon_sym_SQUOTE] = ACTIONS(198), + [anon_sym_PIPE] = ACTIONS(198), + [anon_sym_SEMI] = ACTIONS(198), + [anon_sym_COMMA] = ACTIONS(198), + [sym_long_buf_lit] = ACTIONS(198), + [sym_long_str_lit] = ACTIONS(198), }, [32] = { - [ts_builtin_sym_end] = ACTIONS(207), + [ts_builtin_sym_end] = ACTIONS(202), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(209), - [anon_sym_true] = ACTIONS(209), - [aux_sym_kwd_lit_token1] = ACTIONS(207), - [sym_nil_lit] = ACTIONS(209), - [sym__dec] = ACTIONS(209), - [sym__hex] = ACTIONS(209), - [sym__radix] = ACTIONS(209), - [sym_str_lit] = ACTIONS(207), - [sym_buf_lit] = ACTIONS(207), - [sym_sym_lit] = ACTIONS(209), - [anon_sym_AT_LPAREN] = ACTIONS(207), - [anon_sym_RPAREN] = ACTIONS(207), - [anon_sym_AT_LBRACK] = ACTIONS(207), - [anon_sym_RBRACK] = ACTIONS(207), - [anon_sym_LBRACE] = ACTIONS(207), - [anon_sym_RBRACE] = ACTIONS(207), - [anon_sym_AT_LBRACE] = ACTIONS(207), - [anon_sym_LPAREN] = ACTIONS(207), - [anon_sym_LBRACK] = ACTIONS(207), - [anon_sym_TILDE] = ACTIONS(207), - [anon_sym_SQUOTE] = ACTIONS(207), - [anon_sym_PIPE] = ACTIONS(207), - [anon_sym_SEMI] = ACTIONS(207), - [anon_sym_COMMA] = ACTIONS(207), - [sym_long_buf_lit] = ACTIONS(207), - [sym_long_str_lit] = ACTIONS(207), + [sym_bool_lit] = ACTIONS(204), + [aux_sym_kwd_lit_token1] = ACTIONS(202), + [sym_nil_lit] = ACTIONS(204), + [sym__dec] = ACTIONS(204), + [sym__hex] = ACTIONS(204), + [sym__radix] = ACTIONS(204), + [sym_str_lit] = ACTIONS(202), + [sym_buf_lit] = ACTIONS(202), + [sym_sym_lit] = ACTIONS(204), + [anon_sym_AT_LPAREN] = ACTIONS(202), + [anon_sym_RPAREN] = ACTIONS(202), + [anon_sym_AT_LBRACK] = ACTIONS(202), + [anon_sym_RBRACK] = ACTIONS(202), + [anon_sym_LBRACE] = ACTIONS(202), + [anon_sym_RBRACE] = ACTIONS(202), + [anon_sym_AT_LBRACE] = ACTIONS(202), + [anon_sym_LPAREN] = ACTIONS(202), + [anon_sym_LBRACK] = ACTIONS(202), + [anon_sym_TILDE] = ACTIONS(202), + [anon_sym_SQUOTE] = ACTIONS(202), + [anon_sym_PIPE] = ACTIONS(202), + [anon_sym_SEMI] = ACTIONS(202), + [anon_sym_COMMA] = ACTIONS(202), + [sym_long_buf_lit] = ACTIONS(202), + [sym_long_str_lit] = ACTIONS(202), }, [33] = { - [ts_builtin_sym_end] = ACTIONS(211), + [ts_builtin_sym_end] = ACTIONS(206), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(213), - [anon_sym_true] = ACTIONS(213), - [aux_sym_kwd_lit_token1] = ACTIONS(211), - [sym_nil_lit] = ACTIONS(213), - [sym__dec] = ACTIONS(213), - [sym__hex] = ACTIONS(213), - [sym__radix] = ACTIONS(213), - [sym_str_lit] = ACTIONS(211), - [sym_buf_lit] = ACTIONS(211), - [sym_sym_lit] = ACTIONS(213), - [anon_sym_AT_LPAREN] = ACTIONS(211), - [anon_sym_RPAREN] = ACTIONS(211), - [anon_sym_AT_LBRACK] = ACTIONS(211), - [anon_sym_RBRACK] = ACTIONS(211), - [anon_sym_LBRACE] = ACTIONS(211), - [anon_sym_RBRACE] = ACTIONS(211), - [anon_sym_AT_LBRACE] = ACTIONS(211), - [anon_sym_LPAREN] = ACTIONS(211), - [anon_sym_LBRACK] = ACTIONS(211), - [anon_sym_TILDE] = ACTIONS(211), - [anon_sym_SQUOTE] = ACTIONS(211), - [anon_sym_PIPE] = ACTIONS(211), - [anon_sym_SEMI] = ACTIONS(211), - [anon_sym_COMMA] = ACTIONS(211), - [sym_long_buf_lit] = ACTIONS(211), - [sym_long_str_lit] = ACTIONS(211), + [sym_bool_lit] = ACTIONS(208), + [aux_sym_kwd_lit_token1] = ACTIONS(206), + [sym_nil_lit] = ACTIONS(208), + [sym__dec] = ACTIONS(208), + [sym__hex] = ACTIONS(208), + [sym__radix] = ACTIONS(208), + [sym_str_lit] = ACTIONS(206), + [sym_buf_lit] = ACTIONS(206), + [sym_sym_lit] = ACTIONS(208), + [anon_sym_AT_LPAREN] = ACTIONS(206), + [anon_sym_RPAREN] = ACTIONS(206), + [anon_sym_AT_LBRACK] = ACTIONS(206), + [anon_sym_RBRACK] = ACTIONS(206), + [anon_sym_LBRACE] = ACTIONS(206), + [anon_sym_RBRACE] = ACTIONS(206), + [anon_sym_AT_LBRACE] = ACTIONS(206), + [anon_sym_LPAREN] = ACTIONS(206), + [anon_sym_LBRACK] = ACTIONS(206), + [anon_sym_TILDE] = ACTIONS(206), + [anon_sym_SQUOTE] = ACTIONS(206), + [anon_sym_PIPE] = ACTIONS(206), + [anon_sym_SEMI] = ACTIONS(206), + [anon_sym_COMMA] = ACTIONS(206), + [sym_long_buf_lit] = ACTIONS(206), + [sym_long_str_lit] = ACTIONS(206), }, [34] = { - [ts_builtin_sym_end] = ACTIONS(215), + [ts_builtin_sym_end] = ACTIONS(210), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(217), - [anon_sym_true] = ACTIONS(217), - [aux_sym_kwd_lit_token1] = ACTIONS(215), - [sym_nil_lit] = ACTIONS(217), - [sym__dec] = ACTIONS(217), - [sym__hex] = ACTIONS(217), - [sym__radix] = ACTIONS(217), - [sym_str_lit] = ACTIONS(215), - [sym_buf_lit] = ACTIONS(215), - [sym_sym_lit] = ACTIONS(217), - [anon_sym_AT_LPAREN] = ACTIONS(215), - [anon_sym_RPAREN] = ACTIONS(215), - [anon_sym_AT_LBRACK] = ACTIONS(215), - [anon_sym_RBRACK] = ACTIONS(215), - [anon_sym_LBRACE] = ACTIONS(215), - [anon_sym_RBRACE] = ACTIONS(215), - [anon_sym_AT_LBRACE] = ACTIONS(215), - [anon_sym_LPAREN] = ACTIONS(215), - [anon_sym_LBRACK] = ACTIONS(215), - [anon_sym_TILDE] = ACTIONS(215), - [anon_sym_SQUOTE] = ACTIONS(215), - [anon_sym_PIPE] = ACTIONS(215), - [anon_sym_SEMI] = ACTIONS(215), - [anon_sym_COMMA] = ACTIONS(215), - [sym_long_buf_lit] = ACTIONS(215), - [sym_long_str_lit] = ACTIONS(215), + [sym_bool_lit] = ACTIONS(212), + [aux_sym_kwd_lit_token1] = ACTIONS(210), + [sym_nil_lit] = ACTIONS(212), + [sym__dec] = ACTIONS(212), + [sym__hex] = ACTIONS(212), + [sym__radix] = ACTIONS(212), + [sym_str_lit] = ACTIONS(210), + [sym_buf_lit] = ACTIONS(210), + [sym_sym_lit] = ACTIONS(212), + [anon_sym_AT_LPAREN] = ACTIONS(210), + [anon_sym_RPAREN] = ACTIONS(210), + [anon_sym_AT_LBRACK] = ACTIONS(210), + [anon_sym_RBRACK] = ACTIONS(210), + [anon_sym_LBRACE] = ACTIONS(210), + [anon_sym_RBRACE] = ACTIONS(210), + [anon_sym_AT_LBRACE] = ACTIONS(210), + [anon_sym_LPAREN] = ACTIONS(210), + [anon_sym_LBRACK] = ACTIONS(210), + [anon_sym_TILDE] = ACTIONS(210), + [anon_sym_SQUOTE] = ACTIONS(210), + [anon_sym_PIPE] = ACTIONS(210), + [anon_sym_SEMI] = ACTIONS(210), + [anon_sym_COMMA] = ACTIONS(210), + [sym_long_buf_lit] = ACTIONS(210), + [sym_long_str_lit] = ACTIONS(210), }, [35] = { - [ts_builtin_sym_end] = ACTIONS(219), + [ts_builtin_sym_end] = ACTIONS(214), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(221), - [anon_sym_true] = ACTIONS(221), - [aux_sym_kwd_lit_token1] = ACTIONS(219), - [sym_nil_lit] = ACTIONS(221), - [sym__dec] = ACTIONS(221), - [sym__hex] = ACTIONS(221), - [sym__radix] = ACTIONS(221), - [sym_str_lit] = ACTIONS(219), - [sym_buf_lit] = ACTIONS(219), - [sym_sym_lit] = ACTIONS(221), - [anon_sym_AT_LPAREN] = ACTIONS(219), - [anon_sym_RPAREN] = ACTIONS(219), - [anon_sym_AT_LBRACK] = ACTIONS(219), - [anon_sym_RBRACK] = ACTIONS(219), - [anon_sym_LBRACE] = ACTIONS(219), - [anon_sym_RBRACE] = ACTIONS(219), - [anon_sym_AT_LBRACE] = ACTIONS(219), - [anon_sym_LPAREN] = ACTIONS(219), - [anon_sym_LBRACK] = ACTIONS(219), - [anon_sym_TILDE] = ACTIONS(219), - [anon_sym_SQUOTE] = ACTIONS(219), - [anon_sym_PIPE] = ACTIONS(219), - [anon_sym_SEMI] = ACTIONS(219), - [anon_sym_COMMA] = ACTIONS(219), - [sym_long_buf_lit] = ACTIONS(219), - [sym_long_str_lit] = ACTIONS(219), + [sym_bool_lit] = ACTIONS(216), + [aux_sym_kwd_lit_token1] = ACTIONS(214), + [sym_nil_lit] = ACTIONS(216), + [sym__dec] = ACTIONS(216), + [sym__hex] = ACTIONS(216), + [sym__radix] = ACTIONS(216), + [sym_str_lit] = ACTIONS(214), + [sym_buf_lit] = ACTIONS(214), + [sym_sym_lit] = ACTIONS(216), + [anon_sym_AT_LPAREN] = ACTIONS(214), + [anon_sym_RPAREN] = ACTIONS(214), + [anon_sym_AT_LBRACK] = ACTIONS(214), + [anon_sym_RBRACK] = ACTIONS(214), + [anon_sym_LBRACE] = ACTIONS(214), + [anon_sym_RBRACE] = ACTIONS(214), + [anon_sym_AT_LBRACE] = ACTIONS(214), + [anon_sym_LPAREN] = ACTIONS(214), + [anon_sym_LBRACK] = ACTIONS(214), + [anon_sym_TILDE] = ACTIONS(214), + [anon_sym_SQUOTE] = ACTIONS(214), + [anon_sym_PIPE] = ACTIONS(214), + [anon_sym_SEMI] = ACTIONS(214), + [anon_sym_COMMA] = ACTIONS(214), + [sym_long_buf_lit] = ACTIONS(214), + [sym_long_str_lit] = ACTIONS(214), }, [36] = { - [ts_builtin_sym_end] = ACTIONS(223), + [ts_builtin_sym_end] = ACTIONS(218), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(225), - [anon_sym_true] = ACTIONS(225), - [aux_sym_kwd_lit_token1] = ACTIONS(223), - [sym_nil_lit] = ACTIONS(225), - [sym__dec] = ACTIONS(225), - [sym__hex] = ACTIONS(225), - [sym__radix] = ACTIONS(225), - [sym_str_lit] = ACTIONS(223), - [sym_buf_lit] = ACTIONS(223), - [sym_sym_lit] = ACTIONS(225), - [anon_sym_AT_LPAREN] = ACTIONS(223), - [anon_sym_RPAREN] = ACTIONS(223), - [anon_sym_AT_LBRACK] = ACTIONS(223), - [anon_sym_RBRACK] = ACTIONS(223), - [anon_sym_LBRACE] = ACTIONS(223), - [anon_sym_RBRACE] = ACTIONS(223), - [anon_sym_AT_LBRACE] = ACTIONS(223), - [anon_sym_LPAREN] = ACTIONS(223), - [anon_sym_LBRACK] = ACTIONS(223), - [anon_sym_TILDE] = ACTIONS(223), - [anon_sym_SQUOTE] = ACTIONS(223), - [anon_sym_PIPE] = ACTIONS(223), - [anon_sym_SEMI] = ACTIONS(223), - [anon_sym_COMMA] = ACTIONS(223), - [sym_long_buf_lit] = ACTIONS(223), - [sym_long_str_lit] = ACTIONS(223), + [sym_bool_lit] = ACTIONS(220), + [aux_sym_kwd_lit_token1] = ACTIONS(218), + [sym_nil_lit] = ACTIONS(220), + [sym__dec] = ACTIONS(220), + [sym__hex] = ACTIONS(220), + [sym__radix] = ACTIONS(220), + [sym_str_lit] = ACTIONS(218), + [sym_buf_lit] = ACTIONS(218), + [sym_sym_lit] = ACTIONS(220), + [anon_sym_AT_LPAREN] = ACTIONS(218), + [anon_sym_RPAREN] = ACTIONS(218), + [anon_sym_AT_LBRACK] = ACTIONS(218), + [anon_sym_RBRACK] = ACTIONS(218), + [anon_sym_LBRACE] = ACTIONS(218), + [anon_sym_RBRACE] = ACTIONS(218), + [anon_sym_AT_LBRACE] = ACTIONS(218), + [anon_sym_LPAREN] = ACTIONS(218), + [anon_sym_LBRACK] = ACTIONS(218), + [anon_sym_TILDE] = ACTIONS(218), + [anon_sym_SQUOTE] = ACTIONS(218), + [anon_sym_PIPE] = ACTIONS(218), + [anon_sym_SEMI] = ACTIONS(218), + [anon_sym_COMMA] = ACTIONS(218), + [sym_long_buf_lit] = ACTIONS(218), + [sym_long_str_lit] = ACTIONS(218), }, [37] = { - [ts_builtin_sym_end] = ACTIONS(227), + [ts_builtin_sym_end] = ACTIONS(222), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(229), - [anon_sym_true] = ACTIONS(229), - [aux_sym_kwd_lit_token1] = ACTIONS(227), - [sym_nil_lit] = ACTIONS(229), - [sym__dec] = ACTIONS(229), - [sym__hex] = ACTIONS(229), - [sym__radix] = ACTIONS(229), - [sym_str_lit] = ACTIONS(227), - [sym_buf_lit] = ACTIONS(227), - [sym_sym_lit] = ACTIONS(229), - [anon_sym_AT_LPAREN] = ACTIONS(227), - [anon_sym_RPAREN] = ACTIONS(227), - [anon_sym_AT_LBRACK] = ACTIONS(227), - [anon_sym_RBRACK] = ACTIONS(227), - [anon_sym_LBRACE] = ACTIONS(227), - [anon_sym_RBRACE] = ACTIONS(227), - [anon_sym_AT_LBRACE] = ACTIONS(227), - [anon_sym_LPAREN] = ACTIONS(227), - [anon_sym_LBRACK] = ACTIONS(227), - [anon_sym_TILDE] = ACTIONS(227), - [anon_sym_SQUOTE] = ACTIONS(227), - [anon_sym_PIPE] = ACTIONS(227), - [anon_sym_SEMI] = ACTIONS(227), - [anon_sym_COMMA] = ACTIONS(227), - [sym_long_buf_lit] = ACTIONS(227), - [sym_long_str_lit] = ACTIONS(227), + [sym_bool_lit] = ACTIONS(224), + [aux_sym_kwd_lit_token1] = ACTIONS(222), + [sym_nil_lit] = ACTIONS(224), + [sym__dec] = ACTIONS(224), + [sym__hex] = ACTIONS(224), + [sym__radix] = ACTIONS(224), + [sym_str_lit] = ACTIONS(222), + [sym_buf_lit] = ACTIONS(222), + [sym_sym_lit] = ACTIONS(224), + [anon_sym_AT_LPAREN] = ACTIONS(222), + [anon_sym_RPAREN] = ACTIONS(222), + [anon_sym_AT_LBRACK] = ACTIONS(222), + [anon_sym_RBRACK] = ACTIONS(222), + [anon_sym_LBRACE] = ACTIONS(222), + [anon_sym_RBRACE] = ACTIONS(222), + [anon_sym_AT_LBRACE] = ACTIONS(222), + [anon_sym_LPAREN] = ACTIONS(222), + [anon_sym_LBRACK] = ACTIONS(222), + [anon_sym_TILDE] = ACTIONS(222), + [anon_sym_SQUOTE] = ACTIONS(222), + [anon_sym_PIPE] = ACTIONS(222), + [anon_sym_SEMI] = ACTIONS(222), + [anon_sym_COMMA] = ACTIONS(222), + [sym_long_buf_lit] = ACTIONS(222), + [sym_long_str_lit] = ACTIONS(222), }, [38] = { - [ts_builtin_sym_end] = ACTIONS(231), + [ts_builtin_sym_end] = ACTIONS(226), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(233), - [anon_sym_true] = ACTIONS(233), - [aux_sym_kwd_lit_token1] = ACTIONS(231), - [sym_nil_lit] = ACTIONS(233), - [sym__dec] = ACTIONS(233), - [sym__hex] = ACTIONS(233), - [sym__radix] = ACTIONS(233), - [sym_str_lit] = ACTIONS(231), - [sym_buf_lit] = ACTIONS(231), - [sym_sym_lit] = ACTIONS(233), - [anon_sym_AT_LPAREN] = ACTIONS(231), - [anon_sym_RPAREN] = ACTIONS(231), - [anon_sym_AT_LBRACK] = ACTIONS(231), - [anon_sym_RBRACK] = ACTIONS(231), - [anon_sym_LBRACE] = ACTIONS(231), - [anon_sym_RBRACE] = ACTIONS(231), - [anon_sym_AT_LBRACE] = ACTIONS(231), - [anon_sym_LPAREN] = ACTIONS(231), - [anon_sym_LBRACK] = ACTIONS(231), - [anon_sym_TILDE] = ACTIONS(231), - [anon_sym_SQUOTE] = ACTIONS(231), - [anon_sym_PIPE] = ACTIONS(231), - [anon_sym_SEMI] = ACTIONS(231), - [anon_sym_COMMA] = ACTIONS(231), - [sym_long_buf_lit] = ACTIONS(231), - [sym_long_str_lit] = ACTIONS(231), + [sym_bool_lit] = ACTIONS(228), + [aux_sym_kwd_lit_token1] = ACTIONS(226), + [sym_nil_lit] = ACTIONS(228), + [sym__dec] = ACTIONS(228), + [sym__hex] = ACTIONS(228), + [sym__radix] = ACTIONS(228), + [sym_str_lit] = ACTIONS(226), + [sym_buf_lit] = ACTIONS(226), + [sym_sym_lit] = ACTIONS(228), + [anon_sym_AT_LPAREN] = ACTIONS(226), + [anon_sym_RPAREN] = ACTIONS(226), + [anon_sym_AT_LBRACK] = ACTIONS(226), + [anon_sym_RBRACK] = ACTIONS(226), + [anon_sym_LBRACE] = ACTIONS(226), + [anon_sym_RBRACE] = ACTIONS(226), + [anon_sym_AT_LBRACE] = ACTIONS(226), + [anon_sym_LPAREN] = ACTIONS(226), + [anon_sym_LBRACK] = ACTIONS(226), + [anon_sym_TILDE] = ACTIONS(226), + [anon_sym_SQUOTE] = ACTIONS(226), + [anon_sym_PIPE] = ACTIONS(226), + [anon_sym_SEMI] = ACTIONS(226), + [anon_sym_COMMA] = ACTIONS(226), + [sym_long_buf_lit] = ACTIONS(226), + [sym_long_str_lit] = ACTIONS(226), }, [39] = { - [ts_builtin_sym_end] = ACTIONS(235), - [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(237), - [anon_sym_true] = ACTIONS(237), - [aux_sym_kwd_lit_token1] = ACTIONS(235), - [sym_nil_lit] = ACTIONS(237), - [sym__dec] = ACTIONS(237), - [sym__hex] = ACTIONS(237), - [sym__radix] = ACTIONS(237), - [sym_str_lit] = ACTIONS(235), - [sym_buf_lit] = ACTIONS(235), - [sym_sym_lit] = ACTIONS(237), - [anon_sym_AT_LPAREN] = ACTIONS(235), - [anon_sym_RPAREN] = ACTIONS(235), - [anon_sym_AT_LBRACK] = ACTIONS(235), - [anon_sym_RBRACK] = ACTIONS(235), - [anon_sym_LBRACE] = ACTIONS(235), - [anon_sym_RBRACE] = ACTIONS(235), - [anon_sym_AT_LBRACE] = ACTIONS(235), - [anon_sym_LPAREN] = ACTIONS(235), - [anon_sym_LBRACK] = ACTIONS(235), - [anon_sym_TILDE] = ACTIONS(235), - [anon_sym_SQUOTE] = ACTIONS(235), - [anon_sym_PIPE] = ACTIONS(235), - [anon_sym_SEMI] = ACTIONS(235), - [anon_sym_COMMA] = ACTIONS(235), - [sym_long_buf_lit] = ACTIONS(235), - [sym_long_str_lit] = ACTIONS(235), - }, - [40] = { - [ts_builtin_sym_end] = ACTIONS(239), + [ts_builtin_sym_end] = ACTIONS(230), [sym_comment] = ACTIONS(3), - [anon_sym_false] = ACTIONS(241), - [anon_sym_true] = ACTIONS(241), - [aux_sym_kwd_lit_token1] = ACTIONS(239), - [sym_nil_lit] = ACTIONS(241), - [sym__dec] = ACTIONS(241), - [sym__hex] = ACTIONS(241), - [sym__radix] = ACTIONS(241), - [sym_str_lit] = ACTIONS(239), - [sym_buf_lit] = ACTIONS(239), - [sym_sym_lit] = ACTIONS(241), - [anon_sym_AT_LPAREN] = ACTIONS(239), - [anon_sym_RPAREN] = ACTIONS(239), - [anon_sym_AT_LBRACK] = ACTIONS(239), - [anon_sym_RBRACK] = ACTIONS(239), - [anon_sym_LBRACE] = ACTIONS(239), - [anon_sym_RBRACE] = ACTIONS(239), - [anon_sym_AT_LBRACE] = ACTIONS(239), - [anon_sym_LPAREN] = ACTIONS(239), - [anon_sym_LBRACK] = ACTIONS(239), - [anon_sym_TILDE] = ACTIONS(239), - [anon_sym_SQUOTE] = ACTIONS(239), - [anon_sym_PIPE] = ACTIONS(239), - [anon_sym_SEMI] = ACTIONS(239), - [anon_sym_COMMA] = ACTIONS(239), - [sym_long_buf_lit] = ACTIONS(239), - [sym_long_str_lit] = ACTIONS(239), + [sym_bool_lit] = ACTIONS(232), + [aux_sym_kwd_lit_token1] = ACTIONS(230), + [sym_nil_lit] = ACTIONS(232), + [sym__dec] = ACTIONS(232), + [sym__hex] = ACTIONS(232), + [sym__radix] = ACTIONS(232), + [sym_str_lit] = ACTIONS(230), + [sym_buf_lit] = ACTIONS(230), + [sym_sym_lit] = ACTIONS(232), + [anon_sym_AT_LPAREN] = ACTIONS(230), + [anon_sym_RPAREN] = ACTIONS(230), + [anon_sym_AT_LBRACK] = ACTIONS(230), + [anon_sym_RBRACK] = ACTIONS(230), + [anon_sym_LBRACE] = ACTIONS(230), + [anon_sym_RBRACE] = ACTIONS(230), + [anon_sym_AT_LBRACE] = ACTIONS(230), + [anon_sym_LPAREN] = ACTIONS(230), + [anon_sym_LBRACK] = ACTIONS(230), + [anon_sym_TILDE] = ACTIONS(230), + [anon_sym_SQUOTE] = ACTIONS(230), + [anon_sym_PIPE] = ACTIONS(230), + [anon_sym_SEMI] = ACTIONS(230), + [anon_sym_COMMA] = ACTIONS(230), + [sym_long_buf_lit] = ACTIONS(230), + [sym_long_str_lit] = ACTIONS(230), }, }; @@ -2826,12 +2696,12 @@ static uint16_t ts_small_parse_table[] = { [0] = 2, ACTIONS(3), 1, sym_comment, - ACTIONS(243), 1, + ACTIONS(234), 1, ts_builtin_sym_end, }; static uint32_t ts_small_parse_table_map[] = { - [SMALL_STATE(41)] = 0, + [SMALL_STATE(40)] = 0, }; static TSParseActionEntry ts_parse_actions[] = { @@ -2839,117 +2709,113 @@ static TSParseActionEntry ts_parse_actions[] = { [1] = {.count = 1, .reusable = false}, RECOVER(), [3] = {.count = 1, .reusable = true}, SHIFT_EXTRA(), [5] = {.count = 1, .reusable = true}, REDUCE(sym_source, 0), - [7] = {.count = 1, .reusable = false}, SHIFT(23), - [9] = {.count = 1, .reusable = true}, SHIFT(34), - [11] = {.count = 1, .reusable = false}, SHIFT(12), - [13] = {.count = 1, .reusable = false}, SHIFT(28), - [15] = {.count = 1, .reusable = true}, SHIFT(12), - [17] = {.count = 1, .reusable = true}, SHIFT(5), - [19] = {.count = 1, .reusable = true}, SHIFT(6), - [21] = {.count = 1, .reusable = true}, SHIFT(7), - [23] = {.count = 1, .reusable = true}, SHIFT(8), - [25] = {.count = 1, .reusable = true}, SHIFT(9), - [27] = {.count = 1, .reusable = true}, SHIFT(3), - [29] = {.count = 1, .reusable = true}, SHIFT(16), - [31] = {.count = 1, .reusable = true}, SHIFT(17), - [33] = {.count = 1, .reusable = true}, SHIFT(18), - [35] = {.count = 1, .reusable = true}, SHIFT(19), - [37] = {.count = 1, .reusable = true}, SHIFT(20), - [39] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), - [41] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(23), - [44] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(34), - [47] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), - [50] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(28), - [53] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), - [56] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(5), - [59] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(6), - [62] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(7), - [65] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(8), - [68] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(9), - [71] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(3), - [74] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(16), - [77] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(17), - [80] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(18), - [83] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(19), - [86] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(20), - [89] = {.count = 1, .reusable = false}, SHIFT(15), - [91] = {.count = 1, .reusable = true}, SHIFT(15), - [93] = {.count = 1, .reusable = true}, SHIFT(27), - [95] = {.count = 1, .reusable = false}, SHIFT(2), - [97] = {.count = 1, .reusable = true}, SHIFT(2), - [99] = {.count = 1, .reusable = true}, SHIFT(39), - [101] = {.count = 1, .reusable = false}, SHIFT(14), - [103] = {.count = 1, .reusable = true}, SHIFT(14), - [105] = {.count = 1, .reusable = true}, SHIFT(25), - [107] = {.count = 1, .reusable = false}, SHIFT(10), - [109] = {.count = 1, .reusable = true}, SHIFT(10), - [111] = {.count = 1, .reusable = true}, SHIFT(21), - [113] = {.count = 1, .reusable = false}, SHIFT(13), - [115] = {.count = 1, .reusable = true}, SHIFT(13), - [117] = {.count = 1, .reusable = true}, SHIFT(22), - [119] = {.count = 1, .reusable = false}, SHIFT(11), - [121] = {.count = 1, .reusable = true}, SHIFT(11), - [123] = {.count = 1, .reusable = true}, SHIFT(24), - [125] = {.count = 1, .reusable = false}, SHIFT(4), - [127] = {.count = 1, .reusable = true}, SHIFT(4), - [129] = {.count = 1, .reusable = true}, SHIFT(26), - [131] = {.count = 1, .reusable = true}, SHIFT(36), - [133] = {.count = 1, .reusable = true}, SHIFT(38), - [135] = {.count = 1, .reusable = true}, REDUCE(sym_source, 1), - [137] = {.count = 1, .reusable = true}, SHIFT(37), - [139] = {.count = 1, .reusable = true}, SHIFT(35), - [141] = {.count = 1, .reusable = true}, SHIFT(40), - [143] = {.count = 1, .reusable = false}, SHIFT(29), - [145] = {.count = 1, .reusable = true}, SHIFT(29), - [147] = {.count = 1, .reusable = false}, SHIFT(30), - [149] = {.count = 1, .reusable = true}, SHIFT(30), - [151] = {.count = 1, .reusable = false}, SHIFT(31), - [153] = {.count = 1, .reusable = true}, SHIFT(31), - [155] = {.count = 1, .reusable = false}, SHIFT(32), - [157] = {.count = 1, .reusable = true}, SHIFT(32), - [159] = {.count = 1, .reusable = false}, SHIFT(33), - [161] = {.count = 1, .reusable = true}, SHIFT(33), - [163] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 2), - [165] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 2), - [167] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 2), - [169] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 2), - [171] = {.count = 1, .reusable = true}, REDUCE(sym_bool_lit, 1), - [173] = {.count = 1, .reusable = false}, REDUCE(sym_bool_lit, 1), - [175] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 2), - [177] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 2), - [179] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 2), - [181] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 2), - [183] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 2), - [185] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 2), - [187] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 2), - [189] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 2), - [191] = {.count = 1, .reusable = true}, REDUCE(sym_num_lit, 1), - [193] = {.count = 1, .reusable = false}, REDUCE(sym_num_lit, 1), - [195] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), - [197] = {.count = 1, .reusable = false}, REDUCE(sym_quasi_quote_form, 2), - [199] = {.count = 1, .reusable = true}, REDUCE(sym_quote_form, 2), - [201] = {.count = 1, .reusable = false}, REDUCE(sym_quote_form, 2), - [203] = {.count = 1, .reusable = true}, REDUCE(sym_short_fn_form, 2), - [205] = {.count = 1, .reusable = false}, REDUCE(sym_short_fn_form, 2), - [207] = {.count = 1, .reusable = true}, REDUCE(sym_splice_form, 2), - [209] = {.count = 1, .reusable = false}, REDUCE(sym_splice_form, 2), - [211] = {.count = 1, .reusable = true}, REDUCE(sym_unquote_form, 2), - [213] = {.count = 1, .reusable = false}, REDUCE(sym_unquote_form, 2), - [215] = {.count = 1, .reusable = true}, REDUCE(sym_kwd_lit, 1), - [217] = {.count = 1, .reusable = false}, REDUCE(sym_kwd_lit, 1), - [219] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 3), - [221] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 3), - [223] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 3), - [225] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 3), - [227] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 3), - [229] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 3), - [231] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 3), - [233] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 3), - [235] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 3), - [237] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 3), - [239] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 3), - [241] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 3), - [243] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), + [7] = {.count = 1, .reusable = false}, SHIFT(3), + [9] = {.count = 1, .reusable = true}, SHIFT(24), + [11] = {.count = 1, .reusable = false}, SHIFT(33), + [13] = {.count = 1, .reusable = true}, SHIFT(3), + [15] = {.count = 1, .reusable = true}, SHIFT(5), + [17] = {.count = 1, .reusable = true}, SHIFT(6), + [19] = {.count = 1, .reusable = true}, SHIFT(7), + [21] = {.count = 1, .reusable = true}, SHIFT(8), + [23] = {.count = 1, .reusable = true}, SHIFT(9), + [25] = {.count = 1, .reusable = true}, SHIFT(10), + [27] = {.count = 1, .reusable = true}, SHIFT(16), + [29] = {.count = 1, .reusable = true}, SHIFT(18), + [31] = {.count = 1, .reusable = true}, SHIFT(19), + [33] = {.count = 1, .reusable = true}, SHIFT(20), + [35] = {.count = 1, .reusable = true}, SHIFT(17), + [37] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), + [39] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [42] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(24), + [45] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(33), + [48] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [51] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(5), + [54] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(6), + [57] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(7), + [60] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(8), + [63] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(9), + [66] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(10), + [69] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(16), + [72] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(18), + [75] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(19), + [78] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(20), + [81] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(17), + [84] = {.count = 1, .reusable = true}, REDUCE(sym_source, 1), + [86] = {.count = 1, .reusable = false}, SHIFT(2), + [88] = {.count = 1, .reusable = true}, SHIFT(2), + [90] = {.count = 1, .reusable = true}, SHIFT(39), + [92] = {.count = 1, .reusable = false}, SHIFT(15), + [94] = {.count = 1, .reusable = true}, SHIFT(15), + [96] = {.count = 1, .reusable = true}, SHIFT(28), + [98] = {.count = 1, .reusable = false}, SHIFT(14), + [100] = {.count = 1, .reusable = true}, SHIFT(14), + [102] = {.count = 1, .reusable = true}, SHIFT(27), + [104] = {.count = 1, .reusable = false}, SHIFT(13), + [106] = {.count = 1, .reusable = true}, SHIFT(13), + [108] = {.count = 1, .reusable = true}, SHIFT(22), + [110] = {.count = 1, .reusable = false}, SHIFT(12), + [112] = {.count = 1, .reusable = true}, SHIFT(12), + [114] = {.count = 1, .reusable = true}, SHIFT(23), + [116] = {.count = 1, .reusable = false}, SHIFT(11), + [118] = {.count = 1, .reusable = true}, SHIFT(11), + [120] = {.count = 1, .reusable = true}, SHIFT(25), + [122] = {.count = 1, .reusable = false}, SHIFT(4), + [124] = {.count = 1, .reusable = true}, SHIFT(4), + [126] = {.count = 1, .reusable = true}, SHIFT(26), + [128] = {.count = 1, .reusable = true}, SHIFT(38), + [130] = {.count = 1, .reusable = true}, SHIFT(37), + [132] = {.count = 1, .reusable = true}, SHIFT(36), + [134] = {.count = 1, .reusable = true}, SHIFT(35), + [136] = {.count = 1, .reusable = true}, SHIFT(34), + [138] = {.count = 1, .reusable = false}, SHIFT(21), + [140] = {.count = 1, .reusable = true}, SHIFT(21), + [142] = {.count = 1, .reusable = false}, SHIFT(32), + [144] = {.count = 1, .reusable = true}, SHIFT(32), + [146] = {.count = 1, .reusable = false}, SHIFT(29), + [148] = {.count = 1, .reusable = true}, SHIFT(29), + [150] = {.count = 1, .reusable = false}, SHIFT(30), + [152] = {.count = 1, .reusable = true}, SHIFT(30), + [154] = {.count = 1, .reusable = false}, SHIFT(31), + [156] = {.count = 1, .reusable = true}, SHIFT(31), + [158] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), + [160] = {.count = 1, .reusable = false}, REDUCE(sym_quasi_quote_form, 2), + [162] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 2), + [164] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 2), + [166] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 2), + [168] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 2), + [170] = {.count = 1, .reusable = true}, REDUCE(sym_kwd_lit, 1), + [172] = {.count = 1, .reusable = false}, REDUCE(sym_kwd_lit, 1), + [174] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 2), + [176] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 2), + [178] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 2), + [180] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 2), + [182] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 2), + [184] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 2), + [186] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 2), + [188] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 2), + [190] = {.count = 1, .reusable = true}, REDUCE(sym_quote_form, 2), + [192] = {.count = 1, .reusable = false}, REDUCE(sym_quote_form, 2), + [194] = {.count = 1, .reusable = true}, REDUCE(sym_short_fn_form, 2), + [196] = {.count = 1, .reusable = false}, REDUCE(sym_short_fn_form, 2), + [198] = {.count = 1, .reusable = true}, REDUCE(sym_splice_form, 2), + [200] = {.count = 1, .reusable = false}, REDUCE(sym_splice_form, 2), + [202] = {.count = 1, .reusable = true}, REDUCE(sym_unquote_form, 2), + [204] = {.count = 1, .reusable = false}, REDUCE(sym_unquote_form, 2), + [206] = {.count = 1, .reusable = true}, REDUCE(sym_num_lit, 1), + [208] = {.count = 1, .reusable = false}, REDUCE(sym_num_lit, 1), + [210] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 3), + [212] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 3), + [214] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 3), + [216] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 3), + [218] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 3), + [220] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 3), + [222] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 3), + [224] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 3), + [226] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 3), + [228] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 3), + [230] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 3), + [232] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 3), + [234] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), }; #ifdef __cplusplus From af34f158bce1d638efc5f9ca570f5baef4a19207 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 9 Mar 2021 21:47:05 +0900 Subject: [PATCH 14/34] Upgrade tree-sitter to 0.19.2 plus related --- Cargo.toml | 25 +++ binding.gyp | 2 +- {src => bindings/node}/binding.cc | 0 bindings/node/index.js | 19 +++ bindings/rust/build.rs | 40 +++++ bindings/rust/lib.rs | 52 +++++++ index.js | 14 -- package-lock.json | 20 +-- package.json | 8 +- src/grammar.json | 1 + src/node-types.json | 4 + src/parser.c | 246 +++++++++++++++--------------- src/tree_sitter/parser.h | 140 ++++++++--------- 13 files changed, 353 insertions(+), 218 deletions(-) create mode 100644 Cargo.toml rename {src => bindings/node}/binding.cc (100%) create mode 100644 bindings/node/index.js create mode 100644 bindings/rust/build.rs create mode 100644 bindings/rust/lib.rs delete mode 100644 index.js diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 000000000..0d84ef459 --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,25 @@ +[package] +name = "tree-sitter-janet-simple" +description = "janet grammar for the tree-sitter parsing library" +version = "0.0.1" +keywords = ["incremental", "parsing", "janet"] +categories = ["parsing", "text-editors"] +repository = "https://github.com/sogaiu/tree-sitter-janet-simple" +edition = "2018" + +build = "bindings/rust/build.rs" +include = [ + "bindings/rust/*", + "grammar.js", + "queries/*", + "src/*", +] + +[lib] +path = "bindings/rust/lib.rs" + +[dependencies] +tree-sitter = "0.19.1" + +[build-dependencies] +cc = "1.0" diff --git a/binding.gyp b/binding.gyp index c29bf5732..dbbacf6b0 100644 --- a/binding.gyp +++ b/binding.gyp @@ -8,7 +8,7 @@ ], "sources": [ "src/parser.c", - "src/binding.cc", + "bindings/node/binding.cc", "src/scanner.cc" ], "cflags_c": [ diff --git a/src/binding.cc b/bindings/node/binding.cc similarity index 100% rename from src/binding.cc rename to bindings/node/binding.cc diff --git a/bindings/node/index.js b/bindings/node/index.js new file mode 100644 index 000000000..90eb22761 --- /dev/null +++ b/bindings/node/index.js @@ -0,0 +1,19 @@ +try { + module.exports = require("../../build/Release/tree_sitter_janet_simple_binding"); +} catch (error1) { + if (error1.code !== 'MODULE_NOT_FOUND') { + throw error1; + } + try { + module.exports = require("../../build/Debug/tree_sitter_janet_simple_binding"); + } catch (error2) { + if (error2.code !== 'MODULE_NOT_FOUND') { + throw error2; + } + throw error1 + } +} + +try { + module.exports.nodeTypeInfo = require("../../src/node-types.json"); +} catch (_) {} diff --git a/bindings/rust/build.rs b/bindings/rust/build.rs new file mode 100644 index 000000000..c6061f099 --- /dev/null +++ b/bindings/rust/build.rs @@ -0,0 +1,40 @@ +fn main() { + let src_dir = std::path::Path::new("src"); + + let mut c_config = cc::Build::new(); + c_config.include(&src_dir); + c_config + .flag_if_supported("-Wno-unused-parameter") + .flag_if_supported("-Wno-unused-but-set-variable") + .flag_if_supported("-Wno-trigraphs"); + let parser_path = src_dir.join("parser.c"); + c_config.file(&parser_path); + + // If your language uses an external scanner written in C, + // then include this block of code: + + /* + let scanner_path = src_dir.join("scanner.c"); + c_config.file(&scanner_path); + println!("cargo:rerun-if-changed={}", scanner_path.to_str().unwrap()); + */ + + c_config.compile("parser"); + println!("cargo:rerun-if-changed={}", parser_path.to_str().unwrap()); + + // If your language uses an external scanner written in C++, + // then include this block of code: + + /* + let mut cpp_config = cc::Build::new(); + cpp_config.cpp(true); + cpp_config.include(&src_dir); + cpp_config + .flag_if_supported("-Wno-unused-parameter") + .flag_if_supported("-Wno-unused-but-set-variable"); + let scanner_path = src_dir.join("scanner.cc"); + cpp_config.file(&scanner_path); + cpp_config.compile("scanner"); + println!("cargo:rerun-if-changed={}", scanner_path.to_str().unwrap()); + */ +} diff --git a/bindings/rust/lib.rs b/bindings/rust/lib.rs new file mode 100644 index 000000000..44911fc39 --- /dev/null +++ b/bindings/rust/lib.rs @@ -0,0 +1,52 @@ +//! This crate provides janet_simple language support for the [tree-sitter][] parsing library. +//! +//! Typically, you will use the [language][language func] function to add this language to a +//! tree-sitter [Parser][], and then use the parser to parse some code: +//! +//! ``` +//! let code = ""; +//! let mut parser = tree_sitter::Parser::new(); +//! parser.set_language(tree_sitter_janet_simple::language()).expect("Error loading janet_simple grammar"); +//! let tree = parser.parse(code, None).unwrap(); +//! ``` +//! +//! [Language]: https://docs.rs/tree-sitter/*/tree_sitter/struct.Language.html +//! [language func]: fn.language.html +//! [Parser]: https://docs.rs/tree-sitter/*/tree_sitter/struct.Parser.html +//! [tree-sitter]: https://tree-sitter.github.io/ + +use tree_sitter::Language; + +extern "C" { + fn tree_sitter_janet_simple() -> Language; +} + +/// Get the tree-sitter [Language][] for this grammar. +/// +/// [Language]: https://docs.rs/tree-sitter/*/tree_sitter/struct.Language.html +pub fn language() -> Language { + unsafe { tree_sitter_janet_simple() } +} + +/// The content of the [`node-types.json`][] file for this grammar. +/// +/// [`node-types.json`]: https://tree-sitter.github.io/tree-sitter/using-parsers#static-node-types +pub const NODE_TYPES: &'static str = include_str!("../../src/node-types.json"); + +// Uncomment these to include any queries that this grammar contains + +// pub const HIGHLIGHTS_QUERY: &'static str = include_str!("../../queries/highlights.scm"); +// pub const INJECTIONS_QUERY: &'static str = include_str!("../../queries/injections.scm"); +// pub const LOCALS_QUERY: &'static str = include_str!("../../queries/locals.scm"); +// pub const TAGS_QUERY: &'static str = include_str!("../../queries/tags.scm"); + +#[cfg(test)] +mod tests { + #[test] + fn test_can_load_grammar() { + let mut parser = tree_sitter::Parser::new(); + parser + .set_language(super::language()) + .expect("Error loading janet_simple language"); + } +} diff --git a/index.js b/index.js deleted file mode 100644 index 0b35515e9..000000000 --- a/index.js +++ /dev/null @@ -1,14 +0,0 @@ -try { - module.exports = require("./build/Release/tree_sitter_janet_simple_binding"); -} catch (error) { - try { - module.exports = require("./build/Debug/tree_sitter_janet_simple_binding"); - } catch (_) { - throw error - } -} - -try { - module.exports.nodeTypeInfo = require("./src/node-types.json"); -} catch (_) {} - diff --git a/package-lock.json b/package-lock.json index 9edfb26d6..228e49a5c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,24 +1,24 @@ { - "name": "tree-sitter-janet", + "name": "tree-sitter-janet-simple", "version": "0.0.1", "lockfileVersion": 1, "requires": true, "dependencies": { "nan": { - "version": "2.14.0", - "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", - "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" + "version": "2.14.2", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.2.tgz", + "integrity": "sha512-M2ufzIiINKCuDfBSAUr1vWQ+vuVcA9kqx8JJUsbQi6yf1uGRyb7HfpdfUr5qLXf3B/t8dPvcjhKMmlfnP47EzQ==" }, "tree-sitter-cli": { - "version": "0.16.5", - "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.16.5.tgz", - "integrity": "sha512-758kas02AmfLdjsyIlsAMuSmsWpwNFu7ljTcffPxt2Lm00pV+0TW6xFjZCI9MYurB3ghTFjv/hLeRyb3IzJH4Q==", + "version": "0.19.2", + "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.19.2.tgz", + "integrity": "sha512-Ykmza3kS9QmPOkpNikKXR5c3IwPhTCrWj+Okj9vVilrPlR1gFlgnjoKWoX2aTDW8ODFKsT0KqFRm1Ey4+xvTxg==", "dev": true }, "web-tree-sitter": { - "version": "0.16.2", - "resolved": "https://registry.npmjs.org/web-tree-sitter/-/web-tree-sitter-0.16.2.tgz", - "integrity": "sha512-vxZHqu4nItCARmE+oGvTgjFBrMbhEuGI9PWYSgF4ET/nLuW3K11KQQIVhAsoGtYvTI9jdbjc/THj38P7nhYwow==" + "version": "0.19.1", + "resolved": "https://registry.npmjs.org/web-tree-sitter/-/web-tree-sitter-0.19.1.tgz", + "integrity": "sha512-Wlveh+zdegmNdK733B18pf+NmliKs2t5+Aid8IOFIBV2MqJmnYVo3AdukbdZJ+iIxzBnIreYFKfcFFCWVEf4AA==" } } } diff --git a/package.json b/package.json index 7604cea42..66232879a 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "tree-sitter-janet-simple", "version": "0.0.1", "description": "Janet grammar for tree-sitter", - "main": "index.js", + "main": "bindings/node", "scripts": { "build": "npx tree-sitter generate && npx node-gyp build", "fresh-build": "npx tree-sitter generate && npx node-gyp configure && npx node-gyp rebuild", @@ -11,11 +11,11 @@ "author": "", "license": "", "dependencies": { - "nan": "2.14.0", - "web-tree-sitter": "0.16.2" + "nan": "2.14.2", + "web-tree-sitter": "0.19.1" }, "devDependencies": { - "tree-sitter-cli": "0.16.5" + "tree-sitter-cli": "0.19.2" }, "tree-sitter": [ { diff --git a/src/grammar.json b/src/grammar.json index d35ea00ac..1b6f39282 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -1042,6 +1042,7 @@ } ], "conflicts": [], + "precedences": [], "externals": [ { "type": "SYMBOL", diff --git a/src/node-types.json b/src/node-types.json index 57901ff55..71c47eb7f 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -1149,6 +1149,10 @@ "type": "buf_lit", "named": true }, + { + "type": "comment", + "named": true + }, { "type": "long_buf_lit", "named": true diff --git a/src/parser.c b/src/parser.c index a17d9bb74..adb780d07 100644 --- a/src/parser.c +++ b/src/parser.c @@ -5,7 +5,7 @@ #pragma GCC diagnostic ignored "-Wmissing-field-initializers" #endif -#define LANGUAGE_VERSION 11 +#define LANGUAGE_VERSION 13 #define STATE_COUNT 41 #define LARGE_STATE_COUNT 40 #define SYMBOL_COUNT 43 @@ -14,6 +14,7 @@ #define EXTERNAL_TOKEN_COUNT 2 #define FIELD_COUNT 0 #define MAX_ALIAS_SEQUENCE_LENGTH 3 +#define PRODUCTION_ID_COUNT 1 enum { sym_comment = 1, @@ -327,10 +328,14 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { }, }; -static TSSymbol ts_alias_sequences[1][MAX_ALIAS_SEQUENCE_LENGTH] = { +static TSSymbol ts_alias_sequences[PRODUCTION_ID_COUNT][MAX_ALIAS_SEQUENCE_LENGTH] = { [0] = {0}, }; +static uint16_t ts_non_terminal_alias_map[] = { + 0, +}; + static bool ts_lex(TSLexer *lexer, TSStateId state) { START_LEXER(); eof = lexer->eof(lexer); @@ -2705,117 +2710,117 @@ static uint32_t ts_small_parse_table_map[] = { }; static TSParseActionEntry ts_parse_actions[] = { - [0] = {.count = 0, .reusable = false}, - [1] = {.count = 1, .reusable = false}, RECOVER(), - [3] = {.count = 1, .reusable = true}, SHIFT_EXTRA(), - [5] = {.count = 1, .reusable = true}, REDUCE(sym_source, 0), - [7] = {.count = 1, .reusable = false}, SHIFT(3), - [9] = {.count = 1, .reusable = true}, SHIFT(24), - [11] = {.count = 1, .reusable = false}, SHIFT(33), - [13] = {.count = 1, .reusable = true}, SHIFT(3), - [15] = {.count = 1, .reusable = true}, SHIFT(5), - [17] = {.count = 1, .reusable = true}, SHIFT(6), - [19] = {.count = 1, .reusable = true}, SHIFT(7), - [21] = {.count = 1, .reusable = true}, SHIFT(8), - [23] = {.count = 1, .reusable = true}, SHIFT(9), - [25] = {.count = 1, .reusable = true}, SHIFT(10), - [27] = {.count = 1, .reusable = true}, SHIFT(16), - [29] = {.count = 1, .reusable = true}, SHIFT(18), - [31] = {.count = 1, .reusable = true}, SHIFT(19), - [33] = {.count = 1, .reusable = true}, SHIFT(20), - [35] = {.count = 1, .reusable = true}, SHIFT(17), - [37] = {.count = 1, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), - [39] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), - [42] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(24), - [45] = {.count = 2, .reusable = false}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(33), - [48] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), - [51] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(5), - [54] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(6), - [57] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(7), - [60] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(8), - [63] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(9), - [66] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(10), - [69] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(16), - [72] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(18), - [75] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(19), - [78] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(20), - [81] = {.count = 2, .reusable = true}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(17), - [84] = {.count = 1, .reusable = true}, REDUCE(sym_source, 1), - [86] = {.count = 1, .reusable = false}, SHIFT(2), - [88] = {.count = 1, .reusable = true}, SHIFT(2), - [90] = {.count = 1, .reusable = true}, SHIFT(39), - [92] = {.count = 1, .reusable = false}, SHIFT(15), - [94] = {.count = 1, .reusable = true}, SHIFT(15), - [96] = {.count = 1, .reusable = true}, SHIFT(28), - [98] = {.count = 1, .reusable = false}, SHIFT(14), - [100] = {.count = 1, .reusable = true}, SHIFT(14), - [102] = {.count = 1, .reusable = true}, SHIFT(27), - [104] = {.count = 1, .reusable = false}, SHIFT(13), - [106] = {.count = 1, .reusable = true}, SHIFT(13), - [108] = {.count = 1, .reusable = true}, SHIFT(22), - [110] = {.count = 1, .reusable = false}, SHIFT(12), - [112] = {.count = 1, .reusable = true}, SHIFT(12), - [114] = {.count = 1, .reusable = true}, SHIFT(23), - [116] = {.count = 1, .reusable = false}, SHIFT(11), - [118] = {.count = 1, .reusable = true}, SHIFT(11), - [120] = {.count = 1, .reusable = true}, SHIFT(25), - [122] = {.count = 1, .reusable = false}, SHIFT(4), - [124] = {.count = 1, .reusable = true}, SHIFT(4), - [126] = {.count = 1, .reusable = true}, SHIFT(26), - [128] = {.count = 1, .reusable = true}, SHIFT(38), - [130] = {.count = 1, .reusable = true}, SHIFT(37), - [132] = {.count = 1, .reusable = true}, SHIFT(36), - [134] = {.count = 1, .reusable = true}, SHIFT(35), - [136] = {.count = 1, .reusable = true}, SHIFT(34), - [138] = {.count = 1, .reusable = false}, SHIFT(21), - [140] = {.count = 1, .reusable = true}, SHIFT(21), - [142] = {.count = 1, .reusable = false}, SHIFT(32), - [144] = {.count = 1, .reusable = true}, SHIFT(32), - [146] = {.count = 1, .reusable = false}, SHIFT(29), - [148] = {.count = 1, .reusable = true}, SHIFT(29), - [150] = {.count = 1, .reusable = false}, SHIFT(30), - [152] = {.count = 1, .reusable = true}, SHIFT(30), - [154] = {.count = 1, .reusable = false}, SHIFT(31), - [156] = {.count = 1, .reusable = true}, SHIFT(31), - [158] = {.count = 1, .reusable = true}, REDUCE(sym_quasi_quote_form, 2), - [160] = {.count = 1, .reusable = false}, REDUCE(sym_quasi_quote_form, 2), - [162] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 2), - [164] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 2), - [166] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 2), - [168] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 2), - [170] = {.count = 1, .reusable = true}, REDUCE(sym_kwd_lit, 1), - [172] = {.count = 1, .reusable = false}, REDUCE(sym_kwd_lit, 1), - [174] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 2), - [176] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 2), - [178] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 2), - [180] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 2), - [182] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 2), - [184] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 2), - [186] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 2), - [188] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 2), - [190] = {.count = 1, .reusable = true}, REDUCE(sym_quote_form, 2), - [192] = {.count = 1, .reusable = false}, REDUCE(sym_quote_form, 2), - [194] = {.count = 1, .reusable = true}, REDUCE(sym_short_fn_form, 2), - [196] = {.count = 1, .reusable = false}, REDUCE(sym_short_fn_form, 2), - [198] = {.count = 1, .reusable = true}, REDUCE(sym_splice_form, 2), - [200] = {.count = 1, .reusable = false}, REDUCE(sym_splice_form, 2), - [202] = {.count = 1, .reusable = true}, REDUCE(sym_unquote_form, 2), - [204] = {.count = 1, .reusable = false}, REDUCE(sym_unquote_form, 2), - [206] = {.count = 1, .reusable = true}, REDUCE(sym_num_lit, 1), - [208] = {.count = 1, .reusable = false}, REDUCE(sym_num_lit, 1), - [210] = {.count = 1, .reusable = true}, REDUCE(sym_par_arr_lit, 3), - [212] = {.count = 1, .reusable = false}, REDUCE(sym_par_arr_lit, 3), - [214] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_arr_lit, 3), - [216] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_arr_lit, 3), - [218] = {.count = 1, .reusable = true}, REDUCE(sym_struct_lit, 3), - [220] = {.count = 1, .reusable = false}, REDUCE(sym_struct_lit, 3), - [222] = {.count = 1, .reusable = true}, REDUCE(sym_tbl_lit, 3), - [224] = {.count = 1, .reusable = false}, REDUCE(sym_tbl_lit, 3), - [226] = {.count = 1, .reusable = true}, REDUCE(sym_par_tup_lit, 3), - [228] = {.count = 1, .reusable = false}, REDUCE(sym_par_tup_lit, 3), - [230] = {.count = 1, .reusable = true}, REDUCE(sym_sqr_tup_lit, 3), - [232] = {.count = 1, .reusable = false}, REDUCE(sym_sqr_tup_lit, 3), - [234] = {.count = 1, .reusable = true}, ACCEPT_INPUT(), + [0] = {.entry = {.count = 0, .reusable = false}}, + [1] = {.entry = {.count = 1, .reusable = false}}, RECOVER(), + [3] = {.entry = {.count = 1, .reusable = true}}, SHIFT_EXTRA(), + [5] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source, 0), + [7] = {.entry = {.count = 1, .reusable = false}}, SHIFT(3), + [9] = {.entry = {.count = 1, .reusable = true}}, SHIFT(24), + [11] = {.entry = {.count = 1, .reusable = false}}, SHIFT(33), + [13] = {.entry = {.count = 1, .reusable = true}}, SHIFT(3), + [15] = {.entry = {.count = 1, .reusable = true}}, SHIFT(5), + [17] = {.entry = {.count = 1, .reusable = true}}, SHIFT(6), + [19] = {.entry = {.count = 1, .reusable = true}}, SHIFT(7), + [21] = {.entry = {.count = 1, .reusable = true}}, SHIFT(8), + [23] = {.entry = {.count = 1, .reusable = true}}, SHIFT(9), + [25] = {.entry = {.count = 1, .reusable = true}}, SHIFT(10), + [27] = {.entry = {.count = 1, .reusable = true}}, SHIFT(16), + [29] = {.entry = {.count = 1, .reusable = true}}, SHIFT(18), + [31] = {.entry = {.count = 1, .reusable = true}}, SHIFT(19), + [33] = {.entry = {.count = 1, .reusable = true}}, SHIFT(20), + [35] = {.entry = {.count = 1, .reusable = true}}, SHIFT(17), + [37] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), + [39] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [42] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(24), + [45] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(33), + [48] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(2), + [51] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(5), + [54] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(6), + [57] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(7), + [60] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(8), + [63] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(9), + [66] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(10), + [69] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(16), + [72] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(18), + [75] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(19), + [78] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(20), + [81] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_repeat1, 2), SHIFT_REPEAT(17), + [84] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source, 1), + [86] = {.entry = {.count = 1, .reusable = false}}, SHIFT(2), + [88] = {.entry = {.count = 1, .reusable = true}}, SHIFT(2), + [90] = {.entry = {.count = 1, .reusable = true}}, SHIFT(39), + [92] = {.entry = {.count = 1, .reusable = false}}, SHIFT(15), + [94] = {.entry = {.count = 1, .reusable = true}}, SHIFT(15), + [96] = {.entry = {.count = 1, .reusable = true}}, SHIFT(28), + [98] = {.entry = {.count = 1, .reusable = false}}, SHIFT(14), + [100] = {.entry = {.count = 1, .reusable = true}}, SHIFT(14), + [102] = {.entry = {.count = 1, .reusable = true}}, SHIFT(27), + [104] = {.entry = {.count = 1, .reusable = false}}, SHIFT(13), + [106] = {.entry = {.count = 1, .reusable = true}}, SHIFT(13), + [108] = {.entry = {.count = 1, .reusable = true}}, SHIFT(22), + [110] = {.entry = {.count = 1, .reusable = false}}, SHIFT(12), + [112] = {.entry = {.count = 1, .reusable = true}}, SHIFT(12), + [114] = {.entry = {.count = 1, .reusable = true}}, SHIFT(23), + [116] = {.entry = {.count = 1, .reusable = false}}, SHIFT(11), + [118] = {.entry = {.count = 1, .reusable = true}}, SHIFT(11), + [120] = {.entry = {.count = 1, .reusable = true}}, SHIFT(25), + [122] = {.entry = {.count = 1, .reusable = false}}, SHIFT(4), + [124] = {.entry = {.count = 1, .reusable = true}}, SHIFT(4), + [126] = {.entry = {.count = 1, .reusable = true}}, SHIFT(26), + [128] = {.entry = {.count = 1, .reusable = true}}, SHIFT(38), + [130] = {.entry = {.count = 1, .reusable = true}}, SHIFT(37), + [132] = {.entry = {.count = 1, .reusable = true}}, SHIFT(36), + [134] = {.entry = {.count = 1, .reusable = true}}, SHIFT(35), + [136] = {.entry = {.count = 1, .reusable = true}}, SHIFT(34), + [138] = {.entry = {.count = 1, .reusable = false}}, SHIFT(21), + [140] = {.entry = {.count = 1, .reusable = true}}, SHIFT(21), + [142] = {.entry = {.count = 1, .reusable = false}}, SHIFT(32), + [144] = {.entry = {.count = 1, .reusable = true}}, SHIFT(32), + [146] = {.entry = {.count = 1, .reusable = false}}, SHIFT(29), + [148] = {.entry = {.count = 1, .reusable = true}}, SHIFT(29), + [150] = {.entry = {.count = 1, .reusable = false}}, SHIFT(30), + [152] = {.entry = {.count = 1, .reusable = true}}, SHIFT(30), + [154] = {.entry = {.count = 1, .reusable = false}}, SHIFT(31), + [156] = {.entry = {.count = 1, .reusable = true}}, SHIFT(31), + [158] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_quasi_quote_form, 2), + [160] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_quasi_quote_form, 2), + [162] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_struct_lit, 2), + [164] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_struct_lit, 2), + [166] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_tbl_lit, 2), + [168] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_tbl_lit, 2), + [170] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_kwd_lit, 1), + [172] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_kwd_lit, 1), + [174] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_tup_lit, 2), + [176] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_par_tup_lit, 2), + [178] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sqr_tup_lit, 2), + [180] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sqr_tup_lit, 2), + [182] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sqr_arr_lit, 2), + [184] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sqr_arr_lit, 2), + [186] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_arr_lit, 2), + [188] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_par_arr_lit, 2), + [190] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_quote_form, 2), + [192] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_quote_form, 2), + [194] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_short_fn_form, 2), + [196] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_short_fn_form, 2), + [198] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_splice_form, 2), + [200] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_splice_form, 2), + [202] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_unquote_form, 2), + [204] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_unquote_form, 2), + [206] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_num_lit, 1), + [208] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_num_lit, 1), + [210] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_arr_lit, 3), + [212] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_par_arr_lit, 3), + [214] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sqr_arr_lit, 3), + [216] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sqr_arr_lit, 3), + [218] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_struct_lit, 3), + [220] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_struct_lit, 3), + [222] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_tbl_lit, 3), + [224] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_tbl_lit, 3), + [226] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_tup_lit, 3), + [228] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_par_tup_lit, 3), + [230] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sqr_tup_lit, 3), + [232] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sqr_tup_lit, 3), + [234] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), }; #ifdef __cplusplus @@ -2837,20 +2842,23 @@ extern const TSLanguage *tree_sitter_janet_simple(void) { .symbol_count = SYMBOL_COUNT, .alias_count = ALIAS_COUNT, .token_count = TOKEN_COUNT, + .external_token_count = EXTERNAL_TOKEN_COUNT, + .state_count = STATE_COUNT, .large_state_count = LARGE_STATE_COUNT, - .symbol_metadata = ts_symbol_metadata, - .parse_table = (const unsigned short *)ts_parse_table, + .production_id_count = PRODUCTION_ID_COUNT, + .field_count = FIELD_COUNT, + .max_alias_sequence_length = MAX_ALIAS_SEQUENCE_LENGTH, + .parse_table = (const uint16_t *)ts_parse_table, .small_parse_table = (const uint16_t *)ts_small_parse_table, .small_parse_table_map = (const uint32_t *)ts_small_parse_table_map, .parse_actions = ts_parse_actions, - .lex_modes = ts_lex_modes, .symbol_names = ts_symbol_names, + .symbol_metadata = ts_symbol_metadata, .public_symbol_map = ts_symbol_map, + .alias_map = ts_non_terminal_alias_map, .alias_sequences = (const TSSymbol *)ts_alias_sequences, - .field_count = FIELD_COUNT, - .max_alias_sequence_length = MAX_ALIAS_SEQUENCE_LENGTH, + .lex_modes = ts_lex_modes, .lex_fn = ts_lex, - .external_token_count = EXTERNAL_TOKEN_COUNT, .external_scanner = { (const bool *)ts_external_scanner_states, ts_external_scanner_symbol_map, diff --git a/src/tree_sitter/parser.h b/src/tree_sitter/parser.h index 9df91f8c3..a3a87bd1d 100644 --- a/src/tree_sitter/parser.h +++ b/src/tree_sitter/parser.h @@ -13,6 +13,8 @@ extern "C" { #define ts_builtin_sym_end 0 #define TREE_SITTER_SERIALIZATION_BUFFER_SIZE 1024 +typedef uint16_t TSStateId; + #ifndef TREE_SITTER_API_H_ typedef uint16_t TSSymbol; typedef uint16_t TSFieldId; @@ -30,11 +32,10 @@ typedef struct { uint16_t length; } TSFieldMapSlice; -typedef uint16_t TSStateId; - typedef struct { - bool visible : 1; - bool named : 1; + bool visible; + bool named; + bool supertype; } TSSymbolMetadata; typedef struct TSLexer TSLexer; @@ -56,21 +57,21 @@ typedef enum { TSParseActionTypeRecover, } TSParseActionType; -typedef struct { - union { - struct { - TSStateId state; - bool extra : 1; - bool repetition : 1; - }; - struct { - TSSymbol symbol; - int16_t dynamic_precedence; - uint8_t child_count; - uint8_t production_id; - }; - } params; - TSParseActionType type : 4; +typedef union { + struct { + uint8_t type; + TSStateId state; + bool extra; + bool repetition; + } shift; + struct { + uint8_t type; + uint8_t child_count; + TSSymbol symbol; + int16_t dynamic_precedence; + uint16_t production_id; + } reduce; + uint8_t type; } TSParseAction; typedef struct { @@ -82,8 +83,8 @@ typedef union { TSParseAction action; struct { uint8_t count; - bool reusable : 1; - }; + bool reusable; + } entry; } TSParseActionEntry; struct TSLanguage { @@ -92,13 +93,24 @@ struct TSLanguage { uint32_t alias_count; uint32_t token_count; uint32_t external_token_count; - const char **symbol_names; - const TSSymbolMetadata *symbol_metadata; + uint32_t state_count; + uint32_t large_state_count; + uint32_t production_id_count; + uint32_t field_count; + uint16_t max_alias_sequence_length; const uint16_t *parse_table; + const uint16_t *small_parse_table; + const uint32_t *small_parse_table_map; const TSParseActionEntry *parse_actions; - const TSLexMode *lex_modes; + const char **symbol_names; + const char **field_names; + const TSFieldMapSlice *field_map_slices; + const TSFieldMapEntry *field_map_entries; + const TSSymbolMetadata *symbol_metadata; + const TSSymbol *public_symbol_map; + const uint16_t *alias_map; const TSSymbol *alias_sequences; - uint16_t max_alias_sequence_length; + const TSLexMode *lex_modes; bool (*lex_fn)(TSLexer *, TSStateId); bool (*keyword_lex_fn)(TSLexer *, TSStateId); TSSymbol keyword_capture_token; @@ -111,14 +123,6 @@ struct TSLanguage { unsigned (*serialize)(void *, char *); void (*deserialize)(void *, const char *, unsigned); } external_scanner; - uint32_t field_count; - const TSFieldMapSlice *field_map_slices; - const TSFieldMapEntry *field_map_entries; - const char **field_names; - uint32_t large_state_count; - const uint16_t *small_parse_table; - const uint32_t *small_parse_table_map; - const TSSymbol *public_symbol_map; }; /* @@ -167,54 +171,50 @@ struct TSLanguage { #define ACTIONS(id) id -#define SHIFT(state_value) \ - { \ - { \ - .type = TSParseActionTypeShift, \ - .params = {.state = state_value}, \ - } \ - } +#define SHIFT(state_value) \ + {{ \ + .shift = { \ + .type = TSParseActionTypeShift, \ + .state = state_value \ + } \ + }} #define SHIFT_REPEAT(state_value) \ - { \ - { \ + {{ \ + .shift = { \ .type = TSParseActionTypeShift, \ - .params = { \ - .state = state_value, \ - .repetition = true \ - }, \ + .state = state_value, \ + .repetition = true \ } \ - } - -#define RECOVER() \ - { \ - { .type = TSParseActionTypeRecover } \ - } + }} #define SHIFT_EXTRA() \ - { \ - { \ + {{ \ + .shift = { \ .type = TSParseActionTypeShift, \ - .params = {.extra = true} \ + .extra = true \ } \ - } + }} #define REDUCE(symbol_val, child_count_val, ...) \ - { \ - { \ + {{ \ + .reduce = { \ .type = TSParseActionTypeReduce, \ - .params = { \ - .symbol = symbol_val, \ - .child_count = child_count_val, \ - __VA_ARGS__ \ - } \ - } \ - } - -#define ACCEPT_INPUT() \ - { \ - { .type = TSParseActionTypeAccept } \ - } + .symbol = symbol_val, \ + .child_count = child_count_val, \ + __VA_ARGS__ \ + }, \ + }} + +#define RECOVER() \ + {{ \ + .type = TSParseActionTypeRecover \ + }} + +#define ACCEPT_INPUT() \ + {{ \ + .type = TSParseActionTypeAccept \ + }} #ifdef __cplusplus } From 34db97ec3a55a90af9b6781fc59032fcb0e33cb6 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 9 Mar 2021 23:53:53 +0900 Subject: [PATCH 15/34] Rewrite scanner c++ -> c --- binding.gyp | 2 +- src/{scanner.cc => scanner.c} | 111 ++++++++++++++++++---------------- 2 files changed, 59 insertions(+), 54 deletions(-) rename src/{scanner.cc => scanner.c} (51%) diff --git a/binding.gyp b/binding.gyp index dbbacf6b0..ea369d001 100644 --- a/binding.gyp +++ b/binding.gyp @@ -9,7 +9,7 @@ "sources": [ "src/parser.c", "bindings/node/binding.cc", - "src/scanner.cc" + "src/scanner.c" ], "cflags_c": [ "-std=c99", diff --git a/src/scanner.cc b/src/scanner.c similarity index 51% rename from src/scanner.cc rename to src/scanner.c index ab50478c0..cb6ab1b85 100644 --- a/src/scanner.cc +++ b/src/scanner.c @@ -1,30 +1,65 @@ #include -#include -#include - -namespace { - -using std::wstring; -using std::iswspace; +#include enum TokenType { LONG_BUF_LIT, LONG_STR_LIT }; -struct Scanner { - bool scan(TSLexer *lexer, const bool *valid_symbols) { - while (iswspace(lexer->lookahead)) { - lexer->advance(lexer, true); - } +void* tree_sitter_janet_simple_external_scanner_create( + void +) +{ + return NULL; +} + +void tree_sitter_janet_simple_external_scanner_destroy( + void* payload +) +{ +} + +void tree_sitter_janet_simple_external_scanner_reset( + void* payload +) +{ +} + +unsigned tree_sitter_janet_simple_external_scanner_serialize( + void* payload, + char* buffer +) +{ + return 0; +} +void tree_sitter_janet_simple_external_scanner_deserialize( + void *payload, + const char *buffer, + unsigned length +) +{ +} + +bool tree_sitter_janet_simple_external_scanner_scan( + void *payload, + TSLexer *lexer, + const bool *valid_symbols +) +{ + // skip a bit brother + while (iswspace(lexer->lookahead)) { + lexer->advance(lexer, true); + } + // there can be only...two? + if (valid_symbols[LONG_BUF_LIT] || valid_symbols[LONG_STR_LIT]) { + // so which one was it? if (lexer->lookahead == '@') { lexer->result_symbol = LONG_BUF_LIT; lexer->advance(lexer, false); } else { lexer->result_symbol = LONG_STR_LIT; } - // long strings start with one or more backticks // consume the first backtick if (lexer->lookahead != '`') { @@ -33,74 +68,44 @@ struct Scanner { // getting here means a backtick was encountered lexer->advance(lexer, false); uint32_t n_backticks = 1; - // arrive at a total number of backticks for (;;) { if (lexer->lookahead == 0) { return false; } + // found one! if (lexer->lookahead == '`') { n_backticks++; lexer->advance(lexer, false); continue; - } else { + } else { // nope, time to bail lexer->advance(lexer, false); break; } } - // getting here means that the last character examined was NOT a - // backtick - - // keep looking until n_backticks are found + // getting here means the last character examined was NOT a backtick. + // now keep looking until n_backticks are found uint32_t cbt = 0; // consecutive backticks for (;;) { if (lexer->lookahead == 0) { return false; } - + // found one! if (lexer->lookahead == '`') { cbt++; + // are we there yet? if (cbt == n_backticks) { lexer->advance(lexer, false); return true; } - } else { + } else { // nope, better reset the count cbt = 0; } - + // next! lexer->advance(lexer, false); } - } -}; - -} - -extern "C" { -void *tree_sitter_janet_simple_external_scanner_create() { - return new Scanner(); -} - -bool tree_sitter_janet_simple_external_scanner_scan( - void *payload, TSLexer *lexer, - const bool *valid_symbols) { - Scanner *scanner = static_cast(payload); - return scanner->scan(lexer, valid_symbols); -} - -unsigned tree_sitter_janet_simple_external_scanner_serialize(void *payload, - char *buffer) { - return 0; -} - -void tree_sitter_janet_simple_external_scanner_deserialize(void *payload, - const char *buffer, - unsigned length) { -} - -void tree_sitter_janet_simple_external_scanner_destroy(void *payload) { - Scanner *scanner = static_cast(payload); - delete scanner; -} + } + return false; } From 13cd7cea44ea0041e69a18f06fa61eb24956dcd8 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 14 Mar 2021 13:05:28 +0900 Subject: [PATCH 16/34] Updates to 0.19.3 --- Cargo.toml | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 0d84ef459..460896801 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ include = [ path = "bindings/rust/lib.rs" [dependencies] -tree-sitter = "0.19.1" +tree-sitter = "0.19.3" [build-dependencies] cc = "1.0" diff --git a/package.json b/package.json index 66232879a..0f3d3b966 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "web-tree-sitter": "0.19.1" }, "devDependencies": { - "tree-sitter-cli": "0.19.2" + "tree-sitter-cli": "0.19.3" }, "tree-sitter": [ { From 49fa3c8ffd93cbed060e111d6dd5c084cd9a5fb4 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 14 Mar 2021 13:08:10 +0900 Subject: [PATCH 17/34] Fix erroneous inclusions of colon --- grammar.js | 4 ++-- src/grammar.json | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/grammar.js b/grammar.js index a63101356..4a9ae0b86 100644 --- a/grammar.js +++ b/grammar.js @@ -16,9 +16,9 @@ const ALPHA_NUM = // symbols and keywords // janet/tools/symcharsgen.c const SYM_CHAR_NO_DIGIT_NO_COLON = - /[a-zA-Z!$%&*+\-./:@^_]/; + /[a-zA-Z!$%&*+\-./@^_]/; const SYM_CHAR = - /[0-9:a-zA-Z!$%&*+\-./:@^_]/; + /[0-9:a-zA-Z!$%&*+\-./@^_]/; // strings const STRING_DOUBLE_QUOTE_CONTENT = diff --git a/src/grammar.json b/src/grammar.json index 1b6f39282..e126efdcd 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -129,7 +129,7 @@ "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-./@^_]" } } ] @@ -833,13 +833,13 @@ "members": [ { "type": "PATTERN", - "value": "[a-zA-Z!$%&*+\\-./:@^_]" + "value": "[a-zA-Z!$%&*+\\-./@^_]" }, { "type": "REPEAT", "content": { "type": "PATTERN", - "value": "[0-9:a-zA-Z!$%&*+\\-./:@^_]" + "value": "[0-9:a-zA-Z!$%&*+\\-./@^_]" } } ] From 0ecb2a529659f443c0b01b26fb97900436f4e6fe Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 15 Mar 2021 19:05:21 +0900 Subject: [PATCH 18/34] Handle null bytes as whitespace --- README.md | 1 + grammar.js | 2 +- src/grammar.json | 2 +- src/parser.c | 9 +++++---- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 4364e52ff..58a564725 100644 --- a/README.md +++ b/README.md @@ -107,6 +107,7 @@ npx tree-sitter build-wasm ## Acknowledgments +* 314eter - handling null characters * Aerijo - Guide to your first Tree-sitter grammar * bakpakin - janet * GrayJack - tree-sitter-janet diff --git a/grammar.js b/grammar.js index 4a9ae0b86..6e2d1aee2 100644 --- a/grammar.js +++ b/grammar.js @@ -29,7 +29,7 @@ module.exports = grammar({ name: 'janet_simple', extras: $ => - [/\s/, $.comment], + [/\s|\x00/, $.comment], externals: $ => [ $.long_buf_lit, diff --git a/src/grammar.json b/src/grammar.json index e126efdcd..a85fc0cce 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -1034,7 +1034,7 @@ "extras": [ { "type": "PATTERN", - "value": "\\s" + "value": "\\s|\\x00" }, { "type": "SYMBOL", diff --git a/src/parser.c b/src/parser.c index adb780d07..c5e372ec5 100644 --- a/src/parser.c +++ b/src/parser.c @@ -342,6 +342,11 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { switch (state) { case 0: if (eof) ADVANCE(13); + if (lookahead == 0 || + lookahead == '\t' || + lookahead == '\n' || + lookahead == '\r' || + lookahead == ' ') SKIP(0) if (lookahead == '"') ADVANCE(1); if (lookahead == '#') ADVANCE(14); if (lookahead == '\'') ADVANCE(87); @@ -369,10 +374,6 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { if (lookahead == '|') ADVANCE(88); if (lookahead == '}') ADVANCE(82); if (lookahead == '~') ADVANCE(86); - if (lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || - lookahead == ' ') SKIP(0) if (('!' <= lookahead && lookahead <= 'Z') || lookahead == '^' || ('a' <= lookahead && lookahead <= 'z')) ADVANCE(76); From e2d27db284195de53b29a9fa004f45cf1d6ceb2c Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 15 Mar 2021 19:05:38 +0900 Subject: [PATCH 19/34] Release 0.0.2 --- Cargo.toml | 2 +- package-lock.json | 8 ++++---- package.json | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 460896801..8bb048d3a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "tree-sitter-janet-simple" description = "janet grammar for the tree-sitter parsing library" -version = "0.0.1" +version = "0.0.2" keywords = ["incremental", "parsing", "janet"] categories = ["parsing", "text-editors"] repository = "https://github.com/sogaiu/tree-sitter-janet-simple" diff --git a/package-lock.json b/package-lock.json index 228e49a5c..57028cea9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "tree-sitter-janet-simple", - "version": "0.0.1", + "version": "0.0.2", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -10,9 +10,9 @@ "integrity": "sha512-M2ufzIiINKCuDfBSAUr1vWQ+vuVcA9kqx8JJUsbQi6yf1uGRyb7HfpdfUr5qLXf3B/t8dPvcjhKMmlfnP47EzQ==" }, "tree-sitter-cli": { - "version": "0.19.2", - "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.19.2.tgz", - "integrity": "sha512-Ykmza3kS9QmPOkpNikKXR5c3IwPhTCrWj+Okj9vVilrPlR1gFlgnjoKWoX2aTDW8ODFKsT0KqFRm1Ey4+xvTxg==", + "version": "0.19.3", + "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.19.3.tgz", + "integrity": "sha512-UlntGxLrlkQCKVrhm7guzfi+ovM4wDLVCCu3z5jmfDgFNoUoKa/23ddaQON5afD5jB9a02xv4N5MXJfCx+/mpw==", "dev": true }, "web-tree-sitter": { diff --git a/package.json b/package.json index 0f3d3b966..d59442c95 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "tree-sitter-janet-simple", - "version": "0.0.1", + "version": "0.0.2", "description": "Janet grammar for tree-sitter", "main": "bindings/node", "scripts": { From d4801f65fd79abb3f3bcf0dbc86a99adcbf2c3b9 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 21 Mar 2021 12:48:31 +0900 Subject: [PATCH 20/34] Rename *_form as *_lit and use qq --- grammar.js | 46 +++---- src/grammar.json | 46 +++---- src/node-types.json | 130 +++++++++---------- src/parser.c | 308 ++++++++++++++++++++++---------------------- 4 files changed, 265 insertions(+), 265 deletions(-) diff --git a/grammar.js b/grammar.js index 6e2d1aee2..5f7b23430 100644 --- a/grammar.js +++ b/grammar.js @@ -39,12 +39,12 @@ module.exports = grammar({ rules: { // THIS MUST BE FIRST -- even though this doesn't look like it matters source: $ => - repeat($._form), + repeat($._lit), comment: $ => /#.*/, - _form: $ => + _lit: $ => choice($.bool_lit, $.buf_lit, $.kwd_lit, @@ -62,11 +62,11 @@ module.exports = grammar({ $.par_tup_lit, $.sqr_tup_lit, // - $.quasi_quote_form, - $.quote_form, - $.short_fn_form, - $.splice_form, - $.unquote_form), + $.qq_lit, + $.quote_lit, + $.short_fn_lit, + $.splice_lit, + $.unquote_lit), // simplest things @@ -153,43 +153,43 @@ module.exports = grammar({ par_arr_lit: $ => seq('@(', - repeat($._form), + repeat($._lit), ')'), sqr_arr_lit: $ => seq('@[', - repeat($._form), + repeat($._lit), ']'), struct_lit: $ => seq('{', - repeat($._form), + repeat($._lit), '}'), tbl_lit: $ => seq('@{', - repeat($._form), + repeat($._lit), '}'), par_tup_lit: $ => seq('(', - repeat($._form), + repeat($._lit), ')'), sqr_tup_lit: $ => seq('[', - repeat($._form), + repeat($._lit), ']'), // macro-related - quasi_quote_form: $ => + qq_lit: $ => seq('~', - $._form), + $._lit), - quote_form: $ => + quote_lit: $ => seq("'", - $._form), + $._lit), // following all work at the repl.. // |8, ||8, |||8, etc. @@ -202,18 +202,18 @@ module.exports = grammar({ // |@[8 9] // |(= $ 1) // XXX: |() doesn't work...but don't bother disallowing - short_fn_form: $ => + short_fn_lit: $ => seq('|', - $._form), + $._lit), // XXX: ? - splice_form: $ => + splice_lit: $ => seq(';', - $._form), + $._lit), - unquote_form: $ => + unquote_lit: $ => seq(',', - $._form), + $._lit), } }); diff --git a/src/grammar.json b/src/grammar.json index a85fc0cce..a59003346 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -5,14 +5,14 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, "comment": { "type": "PATTERN", "value": "#.*" }, - "_form": { + "_lit": { "type": "CHOICE", "members": [ { @@ -77,23 +77,23 @@ }, { "type": "SYMBOL", - "name": "quasi_quote_form" + "name": "qq_lit" }, { "type": "SYMBOL", - "name": "quote_form" + "name": "quote_lit" }, { "type": "SYMBOL", - "name": "short_fn_form" + "name": "short_fn_lit" }, { "type": "SYMBOL", - "name": "splice_form" + "name": "splice_lit" }, { "type": "SYMBOL", - "name": "unquote_form" + "name": "unquote_lit" } ] }, @@ -856,7 +856,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -876,7 +876,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -896,7 +896,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -916,7 +916,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -936,7 +936,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -956,7 +956,7 @@ "type": "REPEAT", "content": { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } }, { @@ -965,7 +965,7 @@ } ] }, - "quasi_quote_form": { + "qq_lit": { "type": "SEQ", "members": [ { @@ -974,11 +974,11 @@ }, { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } ] }, - "quote_form": { + "quote_lit": { "type": "SEQ", "members": [ { @@ -987,11 +987,11 @@ }, { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } ] }, - "short_fn_form": { + "short_fn_lit": { "type": "SEQ", "members": [ { @@ -1000,11 +1000,11 @@ }, { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } ] }, - "splice_form": { + "splice_lit": { "type": "SEQ", "members": [ { @@ -1013,11 +1013,11 @@ }, { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } ] }, - "unquote_form": { + "unquote_lit": { "type": "SEQ", "members": [ { @@ -1026,7 +1026,7 @@ }, { "type": "SYMBOL", - "name": "_form" + "name": "_lit" } ] } diff --git a/src/node-types.json b/src/node-types.json index 71c47eb7f..4bd1d4020 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -54,19 +54,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -94,7 +94,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -145,19 +145,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -185,14 +185,14 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] } }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true, "fields": {}, "children": { @@ -236,19 +236,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -276,14 +276,14 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] } }, { - "type": "quote_form", + "type": "quote_lit", "named": true, "fields": {}, "children": { @@ -327,19 +327,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -367,14 +367,14 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] } }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true, "fields": {}, "children": { @@ -418,19 +418,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -458,7 +458,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -509,19 +509,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -549,14 +549,14 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] } }, { - "type": "splice_form", + "type": "splice_lit", "named": true, "fields": {}, "children": { @@ -600,19 +600,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -640,7 +640,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -691,19 +691,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -731,7 +731,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -782,19 +782,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -822,7 +822,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -873,19 +873,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -913,7 +913,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] @@ -964,19 +964,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -1004,14 +1004,14 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] } }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true, "fields": {}, "children": { @@ -1055,19 +1055,19 @@ "named": true }, { - "type": "quasi_quote_form", + "type": "qq_lit", "named": true }, { - "type": "quote_form", + "type": "quote_lit", "named": true }, { - "type": "short_fn_form", + "type": "short_fn_lit", "named": true }, { - "type": "splice_form", + "type": "splice_lit", "named": true }, { @@ -1095,7 +1095,7 @@ "named": true }, { - "type": "unquote_form", + "type": "unquote_lit", "named": true } ] diff --git a/src/parser.c b/src/parser.c index c5e372ec5..37ec12f96 100644 --- a/src/parser.c +++ b/src/parser.c @@ -44,7 +44,7 @@ enum { sym_long_buf_lit = 25, sym_long_str_lit = 26, sym_source = 27, - sym__form = 28, + sym__lit = 28, sym_kwd_lit = 29, sym_num_lit = 30, sym_par_arr_lit = 31, @@ -53,11 +53,11 @@ enum { sym_tbl_lit = 34, sym_par_tup_lit = 35, sym_sqr_tup_lit = 36, - sym_quasi_quote_form = 37, - sym_quote_form = 38, - sym_short_fn_form = 39, - sym_splice_form = 40, - sym_unquote_form = 41, + sym_qq_lit = 37, + sym_quote_lit = 38, + sym_short_fn_lit = 39, + sym_splice_lit = 40, + sym_unquote_lit = 41, aux_sym_source_repeat1 = 42, }; @@ -90,7 +90,7 @@ static const char *ts_symbol_names[] = { [sym_long_buf_lit] = "long_buf_lit", [sym_long_str_lit] = "long_str_lit", [sym_source] = "source", - [sym__form] = "_form", + [sym__lit] = "_lit", [sym_kwd_lit] = "kwd_lit", [sym_num_lit] = "num_lit", [sym_par_arr_lit] = "par_arr_lit", @@ -99,11 +99,11 @@ static const char *ts_symbol_names[] = { [sym_tbl_lit] = "tbl_lit", [sym_par_tup_lit] = "par_tup_lit", [sym_sqr_tup_lit] = "sqr_tup_lit", - [sym_quasi_quote_form] = "quasi_quote_form", - [sym_quote_form] = "quote_form", - [sym_short_fn_form] = "short_fn_form", - [sym_splice_form] = "splice_form", - [sym_unquote_form] = "unquote_form", + [sym_qq_lit] = "qq_lit", + [sym_quote_lit] = "quote_lit", + [sym_short_fn_lit] = "short_fn_lit", + [sym_splice_lit] = "splice_lit", + [sym_unquote_lit] = "unquote_lit", [aux_sym_source_repeat1] = "source_repeat1", }; @@ -136,7 +136,7 @@ static TSSymbol ts_symbol_map[] = { [sym_long_buf_lit] = sym_long_buf_lit, [sym_long_str_lit] = sym_long_str_lit, [sym_source] = sym_source, - [sym__form] = sym__form, + [sym__lit] = sym__lit, [sym_kwd_lit] = sym_kwd_lit, [sym_num_lit] = sym_num_lit, [sym_par_arr_lit] = sym_par_arr_lit, @@ -145,11 +145,11 @@ static TSSymbol ts_symbol_map[] = { [sym_tbl_lit] = sym_tbl_lit, [sym_par_tup_lit] = sym_par_tup_lit, [sym_sqr_tup_lit] = sym_sqr_tup_lit, - [sym_quasi_quote_form] = sym_quasi_quote_form, - [sym_quote_form] = sym_quote_form, - [sym_short_fn_form] = sym_short_fn_form, - [sym_splice_form] = sym_splice_form, - [sym_unquote_form] = sym_unquote_form, + [sym_qq_lit] = sym_qq_lit, + [sym_quote_lit] = sym_quote_lit, + [sym_short_fn_lit] = sym_short_fn_lit, + [sym_splice_lit] = sym_splice_lit, + [sym_unquote_lit] = sym_unquote_lit, [aux_sym_source_repeat1] = aux_sym_source_repeat1, }; @@ -266,7 +266,7 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym__form] = { + [sym__lit] = { .visible = false, .named = true, }, @@ -302,23 +302,23 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym_quasi_quote_form] = { + [sym_qq_lit] = { .visible = true, .named = true, }, - [sym_quote_form] = { + [sym_quote_lit] = { .visible = true, .named = true, }, - [sym_short_fn_form] = { + [sym_short_fn_lit] = { .visible = true, .named = true, }, - [sym_splice_form] = { + [sym_splice_lit] = { .visible = true, .named = true, }, - [sym_unquote_form] = { + [sym_unquote_lit] = { .visible = true, .named = true, }, @@ -1333,7 +1333,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { }, [1] = { [sym_source] = STATE(40), - [sym__form] = STATE(3), + [sym__lit] = STATE(3), [sym_kwd_lit] = STATE(3), [sym_num_lit] = STATE(3), [sym_par_arr_lit] = STATE(3), @@ -1342,11 +1342,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(3), [sym_par_tup_lit] = STATE(3), [sym_sqr_tup_lit] = STATE(3), - [sym_quasi_quote_form] = STATE(3), - [sym_quote_form] = STATE(3), - [sym_short_fn_form] = STATE(3), - [sym_splice_form] = STATE(3), - [sym_unquote_form] = STATE(3), + [sym_qq_lit] = STATE(3), + [sym_quote_lit] = STATE(3), + [sym_short_fn_lit] = STATE(3), + [sym_splice_lit] = STATE(3), + [sym_unquote_lit] = STATE(3), [aux_sym_source_repeat1] = STATE(3), [ts_builtin_sym_end] = ACTIONS(5), [sym_comment] = ACTIONS(3), @@ -1374,7 +1374,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(13), }, [2] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1383,11 +1383,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [ts_builtin_sym_end] = ACTIONS(37), [sym_comment] = ACTIONS(3), @@ -1418,7 +1418,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(48), }, [3] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1427,11 +1427,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [ts_builtin_sym_end] = ACTIONS(84), [sym_comment] = ACTIONS(3), @@ -1459,7 +1459,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [4] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1468,11 +1468,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1500,7 +1500,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [5] = { - [sym__form] = STATE(15), + [sym__lit] = STATE(15), [sym_kwd_lit] = STATE(15), [sym_num_lit] = STATE(15), [sym_par_arr_lit] = STATE(15), @@ -1509,11 +1509,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(15), [sym_par_tup_lit] = STATE(15), [sym_sqr_tup_lit] = STATE(15), - [sym_quasi_quote_form] = STATE(15), - [sym_quote_form] = STATE(15), - [sym_short_fn_form] = STATE(15), - [sym_splice_form] = STATE(15), - [sym_unquote_form] = STATE(15), + [sym_qq_lit] = STATE(15), + [sym_quote_lit] = STATE(15), + [sym_short_fn_lit] = STATE(15), + [sym_splice_lit] = STATE(15), + [sym_unquote_lit] = STATE(15), [aux_sym_source_repeat1] = STATE(15), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(92), @@ -1541,7 +1541,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(94), }, [6] = { - [sym__form] = STATE(14), + [sym__lit] = STATE(14), [sym_kwd_lit] = STATE(14), [sym_num_lit] = STATE(14), [sym_par_arr_lit] = STATE(14), @@ -1550,11 +1550,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(14), [sym_par_tup_lit] = STATE(14), [sym_sqr_tup_lit] = STATE(14), - [sym_quasi_quote_form] = STATE(14), - [sym_quote_form] = STATE(14), - [sym_short_fn_form] = STATE(14), - [sym_splice_form] = STATE(14), - [sym_unquote_form] = STATE(14), + [sym_qq_lit] = STATE(14), + [sym_quote_lit] = STATE(14), + [sym_short_fn_lit] = STATE(14), + [sym_splice_lit] = STATE(14), + [sym_unquote_lit] = STATE(14), [aux_sym_source_repeat1] = STATE(14), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(98), @@ -1582,7 +1582,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(100), }, [7] = { - [sym__form] = STATE(13), + [sym__lit] = STATE(13), [sym_kwd_lit] = STATE(13), [sym_num_lit] = STATE(13), [sym_par_arr_lit] = STATE(13), @@ -1591,11 +1591,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(13), [sym_par_tup_lit] = STATE(13), [sym_sqr_tup_lit] = STATE(13), - [sym_quasi_quote_form] = STATE(13), - [sym_quote_form] = STATE(13), - [sym_short_fn_form] = STATE(13), - [sym_splice_form] = STATE(13), - [sym_unquote_form] = STATE(13), + [sym_qq_lit] = STATE(13), + [sym_quote_lit] = STATE(13), + [sym_short_fn_lit] = STATE(13), + [sym_splice_lit] = STATE(13), + [sym_unquote_lit] = STATE(13), [aux_sym_source_repeat1] = STATE(13), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(104), @@ -1623,7 +1623,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(106), }, [8] = { - [sym__form] = STATE(12), + [sym__lit] = STATE(12), [sym_kwd_lit] = STATE(12), [sym_num_lit] = STATE(12), [sym_par_arr_lit] = STATE(12), @@ -1632,11 +1632,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(12), [sym_par_tup_lit] = STATE(12), [sym_sqr_tup_lit] = STATE(12), - [sym_quasi_quote_form] = STATE(12), - [sym_quote_form] = STATE(12), - [sym_short_fn_form] = STATE(12), - [sym_splice_form] = STATE(12), - [sym_unquote_form] = STATE(12), + [sym_qq_lit] = STATE(12), + [sym_quote_lit] = STATE(12), + [sym_short_fn_lit] = STATE(12), + [sym_splice_lit] = STATE(12), + [sym_unquote_lit] = STATE(12), [aux_sym_source_repeat1] = STATE(12), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(110), @@ -1664,7 +1664,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(112), }, [9] = { - [sym__form] = STATE(11), + [sym__lit] = STATE(11), [sym_kwd_lit] = STATE(11), [sym_num_lit] = STATE(11), [sym_par_arr_lit] = STATE(11), @@ -1673,11 +1673,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(11), [sym_par_tup_lit] = STATE(11), [sym_sqr_tup_lit] = STATE(11), - [sym_quasi_quote_form] = STATE(11), - [sym_quote_form] = STATE(11), - [sym_short_fn_form] = STATE(11), - [sym_splice_form] = STATE(11), - [sym_unquote_form] = STATE(11), + [sym_qq_lit] = STATE(11), + [sym_quote_lit] = STATE(11), + [sym_short_fn_lit] = STATE(11), + [sym_splice_lit] = STATE(11), + [sym_unquote_lit] = STATE(11), [aux_sym_source_repeat1] = STATE(11), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(116), @@ -1705,7 +1705,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(118), }, [10] = { - [sym__form] = STATE(4), + [sym__lit] = STATE(4), [sym_kwd_lit] = STATE(4), [sym_num_lit] = STATE(4), [sym_par_arr_lit] = STATE(4), @@ -1714,11 +1714,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(4), [sym_par_tup_lit] = STATE(4), [sym_sqr_tup_lit] = STATE(4), - [sym_quasi_quote_form] = STATE(4), - [sym_quote_form] = STATE(4), - [sym_short_fn_form] = STATE(4), - [sym_splice_form] = STATE(4), - [sym_unquote_form] = STATE(4), + [sym_qq_lit] = STATE(4), + [sym_quote_lit] = STATE(4), + [sym_short_fn_lit] = STATE(4), + [sym_splice_lit] = STATE(4), + [sym_unquote_lit] = STATE(4), [aux_sym_source_repeat1] = STATE(4), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(122), @@ -1746,7 +1746,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(124), }, [11] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1755,11 +1755,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1787,7 +1787,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [12] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1796,11 +1796,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1828,7 +1828,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [13] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1837,11 +1837,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1869,7 +1869,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [14] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1878,11 +1878,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1910,7 +1910,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [15] = { - [sym__form] = STATE(2), + [sym__lit] = STATE(2), [sym_kwd_lit] = STATE(2), [sym_num_lit] = STATE(2), [sym_par_arr_lit] = STATE(2), @@ -1919,11 +1919,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(2), [sym_par_tup_lit] = STATE(2), [sym_sqr_tup_lit] = STATE(2), - [sym_quasi_quote_form] = STATE(2), - [sym_quote_form] = STATE(2), - [sym_short_fn_form] = STATE(2), - [sym_splice_form] = STATE(2), - [sym_unquote_form] = STATE(2), + [sym_qq_lit] = STATE(2), + [sym_quote_lit] = STATE(2), + [sym_short_fn_lit] = STATE(2), + [sym_splice_lit] = STATE(2), + [sym_unquote_lit] = STATE(2), [aux_sym_source_repeat1] = STATE(2), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(86), @@ -1951,7 +1951,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(88), }, [16] = { - [sym__form] = STATE(21), + [sym__lit] = STATE(21), [sym_kwd_lit] = STATE(21), [sym_num_lit] = STATE(21), [sym_par_arr_lit] = STATE(21), @@ -1960,11 +1960,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(21), [sym_par_tup_lit] = STATE(21), [sym_sqr_tup_lit] = STATE(21), - [sym_quasi_quote_form] = STATE(21), - [sym_quote_form] = STATE(21), - [sym_short_fn_form] = STATE(21), - [sym_splice_form] = STATE(21), - [sym_unquote_form] = STATE(21), + [sym_qq_lit] = STATE(21), + [sym_quote_lit] = STATE(21), + [sym_short_fn_lit] = STATE(21), + [sym_splice_lit] = STATE(21), + [sym_unquote_lit] = STATE(21), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(138), [aux_sym_kwd_lit_token1] = ACTIONS(9), @@ -1990,7 +1990,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(140), }, [17] = { - [sym__form] = STATE(32), + [sym__lit] = STATE(32), [sym_kwd_lit] = STATE(32), [sym_num_lit] = STATE(32), [sym_par_arr_lit] = STATE(32), @@ -1999,11 +1999,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(32), [sym_par_tup_lit] = STATE(32), [sym_sqr_tup_lit] = STATE(32), - [sym_quasi_quote_form] = STATE(32), - [sym_quote_form] = STATE(32), - [sym_short_fn_form] = STATE(32), - [sym_splice_form] = STATE(32), - [sym_unquote_form] = STATE(32), + [sym_qq_lit] = STATE(32), + [sym_quote_lit] = STATE(32), + [sym_short_fn_lit] = STATE(32), + [sym_splice_lit] = STATE(32), + [sym_unquote_lit] = STATE(32), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(142), [aux_sym_kwd_lit_token1] = ACTIONS(9), @@ -2029,7 +2029,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(144), }, [18] = { - [sym__form] = STATE(29), + [sym__lit] = STATE(29), [sym_kwd_lit] = STATE(29), [sym_num_lit] = STATE(29), [sym_par_arr_lit] = STATE(29), @@ -2038,11 +2038,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(29), [sym_par_tup_lit] = STATE(29), [sym_sqr_tup_lit] = STATE(29), - [sym_quasi_quote_form] = STATE(29), - [sym_quote_form] = STATE(29), - [sym_short_fn_form] = STATE(29), - [sym_splice_form] = STATE(29), - [sym_unquote_form] = STATE(29), + [sym_qq_lit] = STATE(29), + [sym_quote_lit] = STATE(29), + [sym_short_fn_lit] = STATE(29), + [sym_splice_lit] = STATE(29), + [sym_unquote_lit] = STATE(29), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(146), [aux_sym_kwd_lit_token1] = ACTIONS(9), @@ -2068,7 +2068,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(148), }, [19] = { - [sym__form] = STATE(30), + [sym__lit] = STATE(30), [sym_kwd_lit] = STATE(30), [sym_num_lit] = STATE(30), [sym_par_arr_lit] = STATE(30), @@ -2077,11 +2077,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(30), [sym_par_tup_lit] = STATE(30), [sym_sqr_tup_lit] = STATE(30), - [sym_quasi_quote_form] = STATE(30), - [sym_quote_form] = STATE(30), - [sym_short_fn_form] = STATE(30), - [sym_splice_form] = STATE(30), - [sym_unquote_form] = STATE(30), + [sym_qq_lit] = STATE(30), + [sym_quote_lit] = STATE(30), + [sym_short_fn_lit] = STATE(30), + [sym_splice_lit] = STATE(30), + [sym_unquote_lit] = STATE(30), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(150), [aux_sym_kwd_lit_token1] = ACTIONS(9), @@ -2107,7 +2107,7 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_long_str_lit] = ACTIONS(152), }, [20] = { - [sym__form] = STATE(31), + [sym__lit] = STATE(31), [sym_kwd_lit] = STATE(31), [sym_num_lit] = STATE(31), [sym_par_arr_lit] = STATE(31), @@ -2116,11 +2116,11 @@ static uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym_tbl_lit] = STATE(31), [sym_par_tup_lit] = STATE(31), [sym_sqr_tup_lit] = STATE(31), - [sym_quasi_quote_form] = STATE(31), - [sym_quote_form] = STATE(31), - [sym_short_fn_form] = STATE(31), - [sym_splice_form] = STATE(31), - [sym_unquote_form] = STATE(31), + [sym_qq_lit] = STATE(31), + [sym_quote_lit] = STATE(31), + [sym_short_fn_lit] = STATE(31), + [sym_splice_lit] = STATE(31), + [sym_unquote_lit] = STATE(31), [sym_comment] = ACTIONS(3), [sym_bool_lit] = ACTIONS(154), [aux_sym_kwd_lit_token1] = ACTIONS(9), @@ -2783,8 +2783,8 @@ static TSParseActionEntry ts_parse_actions[] = { [152] = {.entry = {.count = 1, .reusable = true}}, SHIFT(30), [154] = {.entry = {.count = 1, .reusable = false}}, SHIFT(31), [156] = {.entry = {.count = 1, .reusable = true}}, SHIFT(31), - [158] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_quasi_quote_form, 2), - [160] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_quasi_quote_form, 2), + [158] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_qq_lit, 2), + [160] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_qq_lit, 2), [162] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_struct_lit, 2), [164] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_struct_lit, 2), [166] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_tbl_lit, 2), @@ -2799,14 +2799,14 @@ static TSParseActionEntry ts_parse_actions[] = { [184] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sqr_arr_lit, 2), [186] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_arr_lit, 2), [188] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_par_arr_lit, 2), - [190] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_quote_form, 2), - [192] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_quote_form, 2), - [194] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_short_fn_form, 2), - [196] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_short_fn_form, 2), - [198] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_splice_form, 2), - [200] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_splice_form, 2), - [202] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_unquote_form, 2), - [204] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_unquote_form, 2), + [190] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_quote_lit, 2), + [192] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_quote_lit, 2), + [194] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_short_fn_lit, 2), + [196] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_short_fn_lit, 2), + [198] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_splice_lit, 2), + [200] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_splice_lit, 2), + [202] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_unquote_lit, 2), + [204] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_unquote_lit, 2), [206] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_num_lit, 1), [208] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_num_lit, 1), [210] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_par_arr_lit, 3), From 6b832fc7c995d1944889b5e31dfe6b68fdffa946 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 21 Mar 2021 12:50:31 +0900 Subject: [PATCH 21/34] Add comment about \s meaning --- grammar.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/grammar.js b/grammar.js index 5f7b23430..a5a992468 100644 --- a/grammar.js +++ b/grammar.js @@ -28,6 +28,13 @@ const STRING_DOUBLE_QUOTE_CONTENT = module.exports = grammar({ name: 'janet_simple', + // mdn says \s is: + // + // [ \f\n\r\t\v\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff] + // + // but that doesn't seem to match what tree-sitter thinks as it appears that + // for example, leaving out \x0b, \x0c, or \x00 from the following yields + // different behavior (other stuff may also differ) extras: $ => [/\s|\x00/, $.comment], From d1e8009c6faf8e02038c957ca43c4ead3fe40611 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sun, 21 Mar 2021 12:52:22 +0900 Subject: [PATCH 22/34] Treat form feed and vertical tab as whitespace --- grammar.js | 6 ++++-- src/grammar.json | 2 +- src/parser.c | 4 +--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/grammar.js b/grammar.js index a5a992468..b8cfdfc9c 100644 --- a/grammar.js +++ b/grammar.js @@ -35,8 +35,10 @@ module.exports = grammar({ // but that doesn't seem to match what tree-sitter thinks as it appears that // for example, leaving out \x0b, \x0c, or \x00 from the following yields // different behavior (other stuff may also differ) - extras: $ => - [/\s|\x00/, $.comment], + extras: $ => [ + /\s|\x0b|\x0c|\x00/, + $.comment + ], externals: $ => [ $.long_buf_lit, diff --git a/src/grammar.json b/src/grammar.json index a59003346..16e3b04d6 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -1034,7 +1034,7 @@ "extras": [ { "type": "PATTERN", - "value": "\\s|\\x00" + "value": "\\s|\\x0b|\\x0c|\\x00" }, { "type": "SYMBOL", diff --git a/src/parser.c b/src/parser.c index 37ec12f96..e4c981990 100644 --- a/src/parser.c +++ b/src/parser.c @@ -343,9 +343,7 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { case 0: if (eof) ADVANCE(13); if (lookahead == 0 || - lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || + ('\t' <= lookahead && lookahead <= '\r') || lookahead == ' ') SKIP(0) if (lookahead == '"') ADVANCE(1); if (lookahead == '#') ADVANCE(14); From 00c6653c37930011647b780e57e06cade00cae8b Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Sat, 19 Feb 2022 09:01:51 +0900 Subject: [PATCH 23/34] Remove web-tree-sitter dependency --- package-lock.json | 5 ----- package.json | 3 +-- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/package-lock.json b/package-lock.json index 57028cea9..2b1efa0ab 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,11 +14,6 @@ "resolved": "https://registry.npmjs.org/tree-sitter-cli/-/tree-sitter-cli-0.19.3.tgz", "integrity": "sha512-UlntGxLrlkQCKVrhm7guzfi+ovM4wDLVCCu3z5jmfDgFNoUoKa/23ddaQON5afD5jB9a02xv4N5MXJfCx+/mpw==", "dev": true - }, - "web-tree-sitter": { - "version": "0.19.1", - "resolved": "https://registry.npmjs.org/web-tree-sitter/-/web-tree-sitter-0.19.1.tgz", - "integrity": "sha512-Wlveh+zdegmNdK733B18pf+NmliKs2t5+Aid8IOFIBV2MqJmnYVo3AdukbdZJ+iIxzBnIreYFKfcFFCWVEf4AA==" } } } diff --git a/package.json b/package.json index d59442c95..305c0a542 100644 --- a/package.json +++ b/package.json @@ -11,8 +11,7 @@ "author": "", "license": "", "dependencies": { - "nan": "2.14.2", - "web-tree-sitter": "0.19.1" + "nan": "2.14.2" }, "devDependencies": { "tree-sitter-cli": "0.19.3" From 12e2b7a0fae7bf0e172ff5fc7cb1d97fff005a7f Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 28 Mar 2022 15:17:29 +0900 Subject: [PATCH 24/34] Fix rust binding --- bindings/rust/build.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/bindings/rust/build.rs b/bindings/rust/build.rs index c6061f099..f7aaf1661 100644 --- a/bindings/rust/build.rs +++ b/bindings/rust/build.rs @@ -13,11 +13,9 @@ fn main() { // If your language uses an external scanner written in C, // then include this block of code: - /* let scanner_path = src_dir.join("scanner.c"); c_config.file(&scanner_path); println!("cargo:rerun-if-changed={}", scanner_path.to_str().unwrap()); - */ c_config.compile("parser"); println!("cargo:rerun-if-changed={}", parser_path.to_str().unwrap()); From aceea17420f9620e62afcd0385ab61d6aeaa52c6 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 28 Mar 2022 15:17:45 +0900 Subject: [PATCH 25/34] Add queries/highlights.scm --- queries/highlights.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 queries/highlights.scm diff --git a/queries/highlights.scm b/queries/highlights.scm new file mode 100644 index 000000000..19b7a6dd7 --- /dev/null +++ b/queries/highlights.scm @@ -0,0 +1,23 @@ +(num_lit) @number + +[ + (buf_lit) + (long_buf_lit) + (long_str_lit) + (str_lit) +] @string + +[ + (bool_lit) + (nil_lit) +] @constant.builtin + +(kwd_lit) @constant + +;; Treat quasiquotation as operators for the purpose of highlighting. + +[ + "'" + "~" + "," +] @operator From 784a9afca554e24ed749b16f3de8671a94213d42 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Mon, 28 Mar 2022 16:13:21 +0900 Subject: [PATCH 26/34] Add comment-handling to highlights.scm --- queries/highlights.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/queries/highlights.scm b/queries/highlights.scm index 19b7a6dd7..c96c1c20b 100644 --- a/queries/highlights.scm +++ b/queries/highlights.scm @@ -14,6 +14,8 @@ (kwd_lit) @constant +(comment) @comment + ;; Treat quasiquotation as operators for the purpose of highlighting. [ From e6c04e4b243cf3e5aca8f201e48926a72cc18334 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 29 Mar 2022 10:00:03 +0900 Subject: [PATCH 27/34] Release 0.0.3 --- Cargo.toml | 2 +- package-lock.json | 2 +- package.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 8bb048d3a..7ed04956f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "tree-sitter-janet-simple" description = "janet grammar for the tree-sitter parsing library" -version = "0.0.2" +version = "0.0.3" keywords = ["incremental", "parsing", "janet"] categories = ["parsing", "text-editors"] repository = "https://github.com/sogaiu/tree-sitter-janet-simple" diff --git a/package-lock.json b/package-lock.json index 2b1efa0ab..1027fb333 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "tree-sitter-janet-simple", - "version": "0.0.2", + "version": "0.0.3", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 305c0a542..d07e223a9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "tree-sitter-janet-simple", - "version": "0.0.2", + "version": "0.0.3", "description": "Janet grammar for tree-sitter", "main": "bindings/node", "scripts": { From 5ecc0fbde554a2fb2a0fde927e5db87bf47bc98d Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 29 Mar 2022 10:22:14 +0900 Subject: [PATCH 28/34] Add janet support --- build.rs | 5 +++++ src/guess_language.rs | 3 +++ src/tree_sitter_parser.rs | 18 ++++++++++++++++++ vendor/highlights/janet_simple.scm | 1 + vendor/tree-sitter-janet-simple-src | 1 + 5 files changed, 28 insertions(+) create mode 120000 vendor/highlights/janet_simple.scm create mode 120000 vendor/tree-sitter-janet-simple-src diff --git a/build.rs b/build.rs index 64d9109ce..ea530e228 100644 --- a/build.rs +++ b/build.rs @@ -114,6 +114,11 @@ fn main() { src_dir: "vendor/tree-sitter-haskell-src", extra_files: vec!["scanner.cc"], }, + TreeSitterParser { + name: "tree-sitter-janet-simple", + src_dir: "vendor/tree-sitter-janet-simple-src", + extra_files: vec!["scanner.c"], + }, TreeSitterParser { name: "tree-sitter-java", src_dir: "vendor/tree-sitter-java-src", diff --git a/src/guess_language.rs b/src/guess_language.rs index 7cc4d7553..bc3f4b45c 100644 --- a/src/guess_language.rs +++ b/src/guess_language.rs @@ -30,6 +30,7 @@ pub enum Language { EmacsLisp, Go, Haskell, + JanetSimple, Java, JavaScript, Json, @@ -94,6 +95,7 @@ fn from_emacs_mode_header(src: &str) -> Option { "emacs-lisp" => Some(EmacsLisp), "go" => Some(Go), "haskell" => Some(Haskell), + "janet" => Some(JanetSimple), "java" => Some(Java), "js" | "js2" => Some(JavaScript), "lisp" => Some(CommonLisp), @@ -188,6 +190,7 @@ fn from_extension(extension: &OsStr, src: &str) -> Option { "ex" | "exs" => Some(Elixir), "go" => Some(Go), "hs" => Some(Haskell), + "janet" | "jdn" => Some(JanetSimple), "java" => Some(Java), "cjs" | "js" | "mjs" => Some(JavaScript), "jsx" => Some(Jsx), diff --git a/src/tree_sitter_parser.rs b/src/tree_sitter_parser.rs index 8a5a4a927..096281808 100644 --- a/src/tree_sitter_parser.rs +++ b/src/tree_sitter_parser.rs @@ -55,6 +55,7 @@ extern "C" { fn tree_sitter_elixir() -> ts::Language; fn tree_sitter_go() -> ts::Language; fn tree_sitter_haskell() -> ts::Language; + fn tree_sitter_janet_simple() -> ts::Language; fn tree_sitter_java() -> ts::Language; fn tree_sitter_javascript() -> ts::Language; fn tree_sitter_json() -> ts::Language; @@ -273,6 +274,23 @@ pub fn from_language(language: guess::Language) -> TreeSitterConfig { .unwrap(), } } + JanetSimple => { + let language = unsafe { tree_sitter_janet_simple() }; + TreeSitterConfig { + name: "Janet Simple", + language, + atom_nodes: (vec![]).into_iter().collect(), + delimiter_tokens: (vec![("@{", "}"), ("@(", ")"), ("@[", "]"), + ("{", "}"), ("(", ")"), ("[", "]")]) + .into_iter() + .collect(), + highlight_query: ts::Query::new( + language, + include_str!("../vendor/highlights/janet_simple.scm"), + ) + .unwrap(), + } + } Java => { let language = unsafe { tree_sitter_java() }; TreeSitterConfig { diff --git a/vendor/highlights/janet_simple.scm b/vendor/highlights/janet_simple.scm new file mode 120000 index 000000000..8709326ff --- /dev/null +++ b/vendor/highlights/janet_simple.scm @@ -0,0 +1 @@ +../tree-sitter-janet-simple/queries/highlights.scm \ No newline at end of file diff --git a/vendor/tree-sitter-janet-simple-src b/vendor/tree-sitter-janet-simple-src new file mode 120000 index 000000000..a4fde20f2 --- /dev/null +++ b/vendor/tree-sitter-janet-simple-src @@ -0,0 +1 @@ +tree-sitter-janet-simple/src \ No newline at end of file From 9ed951044a1e98368d5bbe5678d63a1a37f44883 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 29 Mar 2022 14:14:07 +0900 Subject: [PATCH 29/34] Format via cargo fmt --- src/tree_sitter_parser.rs | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/tree_sitter_parser.rs b/src/tree_sitter_parser.rs index 096281808..ba9b0b475 100644 --- a/src/tree_sitter_parser.rs +++ b/src/tree_sitter_parser.rs @@ -280,10 +280,16 @@ pub fn from_language(language: guess::Language) -> TreeSitterConfig { name: "Janet Simple", language, atom_nodes: (vec![]).into_iter().collect(), - delimiter_tokens: (vec![("@{", "}"), ("@(", ")"), ("@[", "]"), - ("{", "}"), ("(", ")"), ("[", "]")]) - .into_iter() - .collect(), + delimiter_tokens: (vec![ + ("@{", "}"), + ("@(", ")"), + ("@[", "]"), + ("{", "}"), + ("(", ")"), + ("[", "]"), + ]) + .into_iter() + .collect(), highlight_query: ts::Query::new( language, include_str!("../vendor/highlights/janet_simple.scm"), From 5696ef6016083673edbc9beada3764a6dbeefd39 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 29 Mar 2022 14:20:23 +0900 Subject: [PATCH 30/34] Change name shown to users --- src/tree_sitter_parser.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tree_sitter_parser.rs b/src/tree_sitter_parser.rs index ba9b0b475..98db42d59 100644 --- a/src/tree_sitter_parser.rs +++ b/src/tree_sitter_parser.rs @@ -277,7 +277,7 @@ pub fn from_language(language: guess::Language) -> TreeSitterConfig { JanetSimple => { let language = unsafe { tree_sitter_janet_simple() }; TreeSitterConfig { - name: "Janet Simple", + name: "Janet", language, atom_nodes: (vec![]).into_iter().collect(), delimiter_tokens: (vec![ From d36224229e7e363d5c9272ec9d4221ea9f93739e Mon Sep 17 00:00:00 2001 From: Wilfred Hughes Date: Mon, 28 Mar 2022 22:23:42 -0700 Subject: [PATCH 31/34] Downgrade rpds to last Rust 2018 version This will allow difftastic to build on earlier rust versions, and is also a ~2% instruction count reduction on slow_before.rs. --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 1073c64d8..0bfec900f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -435,9 +435,9 @@ checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" [[package]] name = "rpds" -version = "0.11.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4ef5140bcb576bfd6d56cd2de709a7d17851ac1f3805e67fe9d99e42a11821f" +checksum = "054e417ded02a19ae192c8c89412eaec7d1c2cdd826aa412565761d86ca6315e" dependencies = [ "archery", ] diff --git a/Cargo.toml b/Cargo.toml index 1dc650e6a..2f56954ad 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -39,7 +39,7 @@ walkdir = "2.3.2" term_size = "0.3.2" const_format = "0.2.22" owo-colors = "3.2.0" -rpds = "0.11.0" +rpds = "0.10.0" wu-diff = "0.1.2" [dev-dependencies] From e1e735752de9bafba1a0746785c705e9f7ec0a94 Mon Sep 17 00:00:00 2001 From: sogaiu <983021772@users.noreply.github.com> Date: Tue, 29 Mar 2022 14:53:10 +0900 Subject: [PATCH 32/34] Add sample files and update compare.expected --- sample_files/compare.expected | 3 + sample_files/janet_after.janet | 314 +++++++++++++++++++++++++++++++ sample_files/janet_before.janet | 320 ++++++++++++++++++++++++++++++++ 3 files changed, 637 insertions(+) create mode 100644 sample_files/janet_after.janet create mode 100644 sample_files/janet_before.janet diff --git a/sample_files/compare.expected b/sample_files/compare.expected index cfcedc84a..7bfdd086d 100644 --- a/sample_files/compare.expected +++ b/sample_files/compare.expected @@ -46,6 +46,9 @@ sample_files/identical_before.scala sample_files/identical_after.scala sample_files/if_before.py sample_files/if_after.py e633761742973b2ef3b2ed078cedbdf2 - +sample_files/janet_before.janet sample_files/janet_after.janet +677604a16ef62f6b6252d76d76e86265 - + sample_files/java_before.java sample_files/java_after.java 7fda19b66481b0658fc476b2a0e2657b - diff --git a/sample_files/janet_after.janet b/sample_files/janet_after.janet new file mode 100644 index 000000000..6a4ad2f8d --- /dev/null +++ b/sample_files/janet_after.janet @@ -0,0 +1,314 @@ +# the "GNU Emacs Lisp Reference Manual" has very useful info +# in the code below section names will be mentioned, like: +# see "Special Read Syntax" + +# bl - begin line +# bc - begin column +# el - end line +# ec - end column +(defn make-attrs + [& items] + (zipcoll [:bl :bc :el :ec] + items)) + +(defn atom-node + [node-type peg-form] + ~(cmt (capture (sequence (line) (column) + ,peg-form + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 -2)) (last $&)])) + +(defn reader-macro-node + [node-type sigil] + ~(cmt (capture (sequence (line) (column) + ,sigil + (any :non-form) + :form + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + ;(slice $& 2 -4)])) + +(defn collection-node + [node-type open-delim close-delim] + ~(cmt + (capture + (sequence + (line) (column) + ,open-delim + (any :input) + (choice ,close-delim + (error + (replace (sequence (line) (column)) + ,|(string/format + "line: %p column: %p missing %p for %p" + $0 $1 close-delim node-type)))) + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + ;(slice $& 2 -4)])) + +(def loc-grammar + ~{:main (sequence (line) (column) + (some :input) + (line) (column)) + # + :input (choice :non-form + :form) + # + :non-form (choice :whitespace + :comment) + # + :whitespace ,(atom-node :whitespace + '(choice (some (set " \f\t\v")) + (choice "\r\n" + "\r" + "\n"))) + # + :comment ,(atom-node :comment + '(sequence ";" + (any (if-not (set "\r\n") 1)))) + # + :form (choice # reader macros + :backquote + :function + :quote + :unquote-splice + :unquote + # collections + :list + :vector + :char-table + :sub-char-table + :hash-table + :record + :bytecode + :string-text-props + # atoms + # XXX: might need assertions at end of things before + # symbols. see the partial job in :integer-10 below + :float + :integer + :char + :string + :symbol) + # see "Backquote" + :backquote ,(reader-macro-node :backquote "`") + # see "Anonymous Functions" + :function ,(reader-macro-node :function "#'") + # see "Quoting" + :quote ,(reader-macro-node :quote "'") + # see "Backquote" + :unquote-splice ,(reader-macro-node :unquote-splice ",@") + # see "Backquote" + :unquote ,(reader-macro-node :unquote ",") + # + # see "Cons Cell Type" + :list ,(collection-node :list "(" ")") + # see "Vectors" + :vector ,(collection-node :vector "[" "]") + # see "Char-Table Type" + :char-table ,(collection-node :char-table "#^[" "]") + # see "Char-Table Type" + :sub-char-table ,(collection-node :sub-char-table "#^^[" "]") + # see "Byte-Code Objects" + :bytecode ,(collection-node :bytecode "#[" "]") + # see "Hash Tables" + :hash-table ,(collection-node :hash-table "#s(hash-table" ")") + # see "Records" + :record ,(collection-node :record "#s(" ")") + # see "Text Props and Strings" + :string-text-props + ,(collection-node :string-text-props "#(" ")") + # + # see "Float Basics" + :float ,(atom-node :float + '(choice :float-dec + :float-exp + :float-both + :float-inf + :float-nan)) + # + :float-dec (sequence (opt (choice "+" "-")) + :d* + "." + :d+) + # + :float-exp (sequence (opt (choice "+" "-")) + :d* + (choice "e" "E") + :d+) + # + :float-both (sequence (opt (choice "+" "-")) + :d* + "." + :d+ + (choice "e" "E") + :d+) + # + :float-inf (sequence (opt "-") + "1.0" + (choice "e" "E") + "+INF") + # + :float-nan (sequence (opt "-") + "0.0" + (choice "e" "E") + "+NaN") + # see "Integer Basics" + :integer ,(atom-node :integer + '(choice :integer-10 + :integer-base)) + # + :integer-10 (sequence (opt (choice "+" "-")) + :d+ + (opt ".") + # XXX: hack? + (not (set "+-"))) + # + :integer-base (sequence "#" + (choice "b" + "o" + "x" + # XXX: found in xml.el, but docs...(?) + "X" + (sequence :d+ "r")) + # XXX: docs contradict this(?), but works... + (opt (choice "+" "-")) + (some (choice :a :d))) + # see "Basic Char Syntax" + :char ,(atom-node :char + '(sequence "?" + (choice :char-octal + :char-hex + :char-uni-name + #:char-uni-val + :char-uni-val-low + :char-uni-val-up + :char-meta-octal + :char-key + :char-basic))) + # see "General Escape Syntax" + :char-octal (sequence "\\" (3 (range "07"))) + :char-hex (sequence "\\x" :h+) + :char-uni-name (sequence "\\N{" (thru "}")) + #:char-uni-val (sequence "\\N{U+" :h+ "}") + :char-uni-val-low (sequence "\\u" (4 :h)) + :char-uni-val-up (sequence "\\U" (8 :h)) + # see "Meta-Char Syntax" + :char-meta-octal (sequence "\\M-" :char-octal) + # see "Ctl-Char Syntax" + # see "Other Char Bits" + :char-key + (sequence (some (sequence "\\" + (choice (sequence (set "ACHMSs") "-") + "^"))) + # XXX: not strictly correct? + (choice :char-octal + :char-hex + :char-uni-name + #:char-uni-val + :char-uni-val-low + :char-uni-val-up + :char-meta-octal + :char-basic)) + # XXX: not strictly correct, but perhaps it's ok? + :char-basic (choice (sequence "\\" 1) + 1) + # see "Syntax for Strings" + # XXX: escaped newline and escaped space in "Syntax for Strings"? + :string + ,(atom-node :string + '(sequence "\"" + (any (choice :escape + (if-not "\"" 1))) + "\"")) + # XXX: is this complete? + :escape (sequence "\\" (set "0abdefnrstvx\"\\")) + # see "Symbol Type" + # XXX: review about whitespace in symbol names + :symbol + ,(atom-node :symbol + '(choice (sequence :sym-char-head + (any :sym-char-rest)) + # XXX: some below not really symbols + # see "Circular Objects" + (sequence "#" :d+ "=") + (sequence "#" :d+ "#") + # see "Special Read Syntax" + #(sequence "#" :d+) + # see "Documentation Strings and Compilation" + "#$" + # see "Symbol Type" + "##")) + # + :sym-char-head (choice :sym-char-esc + # don't start with + #(if-not (set " \"#'(),.;?[]`") 1)) # allow . + (if-not (set " \"#'(),;?[]`") 1)) + # + :sym-char-rest (choice :sym-char-esc + # . and ? are allowed "inside" + (if-not (set " \"#'(),;[]`\n") 1)) + # need to be escaped + :sym-char-esc (sequence "\\" (set " \"#'(),;?[]`")) + }) + +(comment + + (get (peg/match loc-grammar " ") 2) + # => + '(:whitespace @{:bc 1 :bl 1 :ec 2 :el 1} " ") + + (get (peg/match loc-grammar "; hi there") 2) + # => + '(:comment @{:bc 1 :bl 1 :ec 11 :el 1} "; hi there") + + (get (peg/match loc-grammar "8.3") 2) + # => + '(:float @{:bc 1 :bl 1 :ec 4 :el 1} "8.3") + + (get (peg/match loc-grammar "printf") 2) + # => + '(:symbol @{:bc 1 :bl 1 :ec 7 :el 1} "printf") + + (get (peg/match loc-grammar ":smile") 2) + # => + '(:symbol @{:bc 1 :bl 1 :ec 7 :el 1} ":smile") + + (get (peg/match loc-grammar `"fun"`) 2) + # => + '(:string @{:bc 1 :bl 1 :ec 6 :el 1} "\"fun\"") + + (get (peg/match loc-grammar "[8]") 2) + # => + '(:vector @{:bc 1 :bl 1 + :ec 4 :el 1} + (:integer @{:bc 2 :bl 1 + :ec 3 :el 1} "8")) + + (get (peg/match loc-grammar "(1+ 1)") 2) + # => + '(:list @{:bc 1 :bl 1 + :ec 7 :el 1} + (:symbol @{:bc 2 :bl 1 + :ec 4 :el 1} "1+") + (:whitespace @{:bc 4 :bl 1 + :ec 5 :el 1} " ") + (:integer @{:bc 5 :bl 1 + :ec 6 :el 1} "1")) + + (get (peg/match loc-grammar "`x") 2) + # => + '(:backquote @{:bc 1 :bl 1 + :ec 3 :el 1} + (:symbol @{:bc 2 :bl 1 + :ec 3 :el 1} "x")) + + (try + (peg/match loc-grammar "(+ 1") + ([e] + e)) + # => + `line: 1 column: 5 missing ")" for :list` + + ) + diff --git a/sample_files/janet_before.janet b/sample_files/janet_before.janet new file mode 100644 index 000000000..6ae47698a --- /dev/null +++ b/sample_files/janet_before.janet @@ -0,0 +1,320 @@ +# the "GNU Emacs Lisp Reference Manual" has very useful info +# in the code below section names will be mentioned, like: +# see "Special Read Syntax" + +# bl - begin line +# bc - begin column +# el - end line +# ec - end column +(defn make-attrs + [& items] + (zipcoll [:bl :bc :el :ec] + items)) + +(defn atom-node + [node-type peg-form] + ~(cmt (capture (sequence (line) (column) + ,peg-form + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 -2)) (last $&)])) + +(defn reader-macro-node + [node-type sigil] + ~(cmt (capture (sequence (line) (column) + ,sigil + (any :non-form) + :form + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + ;(slice $& 2 -4)])) + +(defn collection-node + [node-type open-delim close-delim] + ~(cmt + (capture + (sequence + (line) (column) + ,open-delim + (any :input) + (choice ,close-delim + (error + (replace (sequence (line) (column)) + ,|(string/format + "line: %p column: %p missing %p for %p" + $0 $1 close-delim node-type)))) + (line) (column))) + ,|[node-type (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + ;(slice $& 2 -4)])) + +(def loc-grammar + ~{:main (sequence (line) (column) + (some :input) + (line) (column)) + # + :input (choice :non-form + :form) + # + :non-form (choice :whitespace + :comment) + # + :whitespace ,(atom-node :whitespace + '(choice (some (set " \f\t\v")) + (choice "\r\n" + "\r" + "\n"))) + # :whitespace + # (cmt (capture (sequence (line) (column) + # (choice (some (set " \f\t\v")) + # (choice "\r\n" + # "\r" + # "\n")) + # (line) (column))) + # ,|[:whitespace (make-attrs ;(slice $& 0 -2)) (last $&)]) + # + :comment ,(atom-node :comment + '(sequence ";" + (any (if-not (set "\r\n") 1)))) + # + :form (choice # reader macros + :backquote + :function + :quote + :unquote-splice + :unquote + # collections + :list + :vector + :char-table + :sub-char-table + :hash-table + :record + :bytecode + :string-text-props + # atoms + # XXX: might need assertions at end of things before + # symbols. see the partial job in :integer-10 below + :float + :integer + :char + :string + :symbol) + # see "Backquote" + :backquote ,(reader-macro-node :backquote "`") + # :backquote + # (cmt (capture (sequence (line) (column) + # "`" + # (any :non-form) + # :form + # (line) (column))) + # ,|[:backquote (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + # ;(slice $& 2 -4)]) + # see "Anonymous Functions" + :function ,(reader-macro-node :function "#'") + # see "Quoting" + :quote ,(reader-macro-node :quote "'") + # see "Backquote" + :unquote-splice ,(reader-macro-node :unquote-splice ",@") + # see "Backquote" + :unquote ,(reader-macro-node :unquote ",") + # + # see "Cons Cell Type" + :list ,(collection-node :list "(" ")") + # :list + # (cmt + # (capture + # (sequence + # (line) (column) + # "(" + # (any :input) + # (choice ")" + # (error + # (replace (sequence (line) (column)) + # ,|(string/format + # "line: %p column: %p missing %p for %p" + # $0 $1 ")" :list)))) + # (line) (column))) + # ,|[:list (make-attrs ;(slice $& 0 2) ;(slice $& -4 -2)) + # ;(slice $& 2 -4)]) + # see "Vectors" + :vector ,(collection-node :vector "[" "]") + # see "Char-Table Type" + :char-table ,(collection-node :char-table "#^[" "]") + # see "Char-Table Type" + :sub-char-table ,(collection-node :sub-char-table "#^^[" "]") + # see "Byte-Code Objects" + :bytecode ,(collection-node :bytecode "#[" "]") + # see "Hash Tables" + :hash-table ,(collection-node :hash-table "#s(hash-table" ")") + # see "Records" + :record ,(collection-node :record "#s(" ")") + # see "Text Props and Strings" + :string-text-props + ,(collection-node :string-text-props "#(" ")") + # + # see "Float Basics" + :float ,(atom-node :float + '(choice :float-dec + :float-exp + :float-both + :float-inf + :float-nan)) + # + :float-dec (sequence (opt (choice "+" "-")) + :d* + "." + :d+) + # + :float-exp (sequence (opt (choice "+" "-")) + :d* + (choice "e" "E") + :d+) + # + :float-both (sequence (opt (choice "+" "-")) + :d* + "." + :d+ + (choice "e" "E") + :d+) + # + :float-inf (sequence (opt "-") + "1.0" + (choice "e" "E") + "+INF") + # + :float-nan (sequence (opt "-") + "0.0" + (choice "e" "E") + "+NaN") + # see "Integer Basics" + :integer ,(atom-node :integer + '(choice :integer-10 + :integer-base)) + # + :integer-10 (sequence (opt (choice "+" "-")) + :d+ + (opt ".") + # XXX: hack? + (not (set "+-"))) + # + :integer-base (sequence "#" + (choice "b" + "o" + "x" + # XXX: found in xml.el, but docs...(?) + "X" + (sequence :d+ "r")) + # XXX: docs contradict this(?), but works... + (opt (choice "+" "-")) + (some (choice :a :d))) + # see "Basic Char Syntax" + :char ,(atom-node :char + '(sequence "?" + (choice :char-octal + :char-hex + :char-uni-name + #:char-uni-val + :char-uni-val-low + :char-uni-val-up + :char-meta-octal + :char-key + :char-basic))) + # see "General Escape Syntax" + :char-octal (sequence "\\" (3 (range "07"))) + :char-hex (sequence "\\x" :h+) + :char-uni-name (sequence "\\N{" (thru "}")) + #:char-uni-val (sequence "\\N{U+" :h+ "}") + :char-uni-val-low (sequence "\\u" (4 :h)) + :char-uni-val-up (sequence "\\U" (8 :h)) + # see "Meta-Char Syntax" + :char-meta-octal (sequence "\\M-" :char-octal) + # see "Ctl-Char Syntax" + # see "Other Char Bits" + :char-key + (sequence (some (sequence "\\" + (choice (sequence (set "ACHMSs") "-") + "^"))) + # XXX: not strictly correct? + (choice :char-octal + :char-hex + :char-uni-name + #:char-uni-val + :char-uni-val-low + :char-uni-val-up + :char-meta-octal + :char-basic)) + # XXX: not strictly correct, but perhaps it's ok? + :char-basic (choice (sequence "\\" 1) + 1) + # see "Syntax for Strings" + # XXX: escaped newline and escaped space in "Syntax for Strings"? + :string + ,(atom-node :string + '(sequence "\"" + (any (choice :escape + (if-not "\"" 1))) + "\"")) + # XXX: is this complete? + :escape (sequence "\\" (set "0abdefnrstvx\"\\")) + # see "Symbol Type" + # XXX: review about whitespace in symbol names + :symbol + ,(atom-node :symbol + '(choice (sequence :sym-char-head + (any :sym-char-rest)) + # XXX: some below not really symbols + # see "Circular Objects" + (sequence "#" :d+ "=") + (sequence "#" :d+ "#") + # see "Special Read Syntax" + #(sequence "#" :d+) + # see "Documentation Strings and Compilation" + "#$" + # see "Symbol Type" + "##")) + # + :sym-char-head (choice :sym-char-esc + # don't start with + #(if-not (set " \"#'(),.;?[]`") 1)) # allow . + (if-not (set " \"#'(),;?[]`") 1)) + # + :sym-char-rest (choice :sym-char-esc + # . and ? are allowed "inside" + (if-not (set " \"#'(),;[]`\n") 1)) + # need to be escaped + :sym-char-esc (sequence "\\" (set " \"#'(),;?[]`")) + }) + +(comment + + (get (peg/match loc-grammar " ") 2) + # => + '(:whitespace @{:bc 1 :bl 1 :ec 2 :el 1} " ") + + (get (peg/match loc-grammar "8.3") 2) + # => + '(:float @{:bc 1 :bl 1 :ec 4 :el 1} "8.3") + + (get (peg/match loc-grammar "printf") 2) + # => + '(:symbol @{:bc 1 :bl 1 :ec 7 :el 1} "printf") + + (get (peg/match loc-grammar ":smile") 2) + # => + '(:symbol @{:bc 1 :bl 1 :ec 7 :el 1} ":smile") + + (get (peg/match loc-grammar "[8]") 2) + # => + '(:vector @{:bc 1 :bl 1 + :ec 4 :el 1} + (:integer @{:bc 2 :bl 1 + :ec 3 :el 1} "8")) + + (get (peg/match loc-grammar "`x") 2) + # => + '(:backquote @{:bc 1 :bl 1 + :ec 3 :el 1} + (:symbol @{:bc 2 :bl 1 + :ec 3 :el 1} "x")) + + ) + From d92cb9633f3d0535490d8ec780de72d4fdccd62f Mon Sep 17 00:00:00 2001 From: Felix Yan Date: Wed, 30 Mar 2022 02:23:07 +0800 Subject: [PATCH 33/34] Correct a typo in tricky_cases.md --- manual/src/tricky_cases.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manual/src/tricky_cases.md b/manual/src/tricky_cases.md index 93ffb4a6b..fe3a8a13c 100644 --- a/manual/src/tricky_cases.md +++ b/manual/src/tricky_cases.md @@ -256,7 +256,7 @@ with lots of NOVEL words about lots of stuff.""" ``` -It would be correct to higlight the entire string literal as being +It would be correct to highlight the entire string literal as being removed and replaced with a new string literal. However, this makes it hard to see what's actually changed. From 646ab39cbb88a8d226f0553511000a141d7d7b2e Mon Sep 17 00:00:00 2001 From: Wilfred Hughes Date: Tue, 29 Mar 2022 19:50:25 -0700 Subject: [PATCH 34/34] Mention that Janet is supported --- CHANGELOG.md | 2 ++ README.md | 1 + manual/src/introduction.md | 1 + manual/src/upstream_parsers.md | 1 + 4 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1ca8f2f94..44e7268b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,8 @@ syntactic changes". Fixed an issue in C and C++ where blank lines were highlighted after novel preprocessor lines. +Added support for Janet. + ## 0.24 (release 26th March 2022) ### Diffing diff --git a/README.md b/README.md index 1d29eba90..8e3244827 100644 --- a/README.md +++ b/README.md @@ -50,6 +50,7 @@ Difftastic supports the following languages: * Emacs Lisp * Go * Haskell +* Janet * Java * JavaScript (and JSX) * JSON diff --git a/manual/src/introduction.md b/manual/src/introduction.md index be1141b27..c80610084 100644 --- a/manual/src/introduction.md +++ b/manual/src/introduction.md @@ -16,6 +16,7 @@ tool that understands syntax. It supports the following languages: * Go * Hack * Haskell +* Janet * Java * JavaScript (and JSX) * JSON diff --git a/manual/src/upstream_parsers.md b/manual/src/upstream_parsers.md index 557422c38..50baaed17 100644 --- a/manual/src/upstream_parsers.md +++ b/manual/src/upstream_parsers.md @@ -16,6 +16,7 @@ Difftastic uses the following tree-sitter parsers: | Emacs Lisp | [wilfred/tree-sitter-elisp](https://github.com/Wilfred/tree-sitter-elisp) | | Go | [tree-sitter/tree-sitter-go](https://github.com/tree-sitter/tree-sitter-go) | | Haskell | [tree-sitter/tree-sitter-haskell](https://github.com/tree-sitter/tree-sitter-haskell) | +| Janet | [sogaiu/tree-sitter-janet-simple](https://github.com/sogaiu/tree-sitter-janet-simple) | | Java | [tree-sitter/tree-sitter-java](https://github.com/tree-sitter/tree-sitter-java) | | JavaScript, JSX | [tree-sitter/tree-sitter-javascript](https://github.com/tree-sitter/tree-sitter-javascript) | | JSON | [tree-sitter/tree-sitter-json](https://github.com/tree-sitter/tree-sitter-json) |