diff options
author | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-12-14 12:29:47 +0100 |
---|---|---|
committer | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-12-14 12:29:47 +0100 |
commit | a9a4ba60a37eb351d3ed872f1cfcf53e673be9ef (patch) | |
tree | 59ab6fe348e7e42c10c33799b5ff51433dc16842 /tree-sitter-yts/src/parser.c | |
parent | fix(yt_dlp/wrappers/info_json): Add missing fields to `Subtitle` (diff) | |
download | yt-a9a4ba60a37eb351d3ed872f1cfcf53e673be9ef.tar.gz yt-a9a4ba60a37eb351d3ed872f1cfcf53e673be9ef.zip |
feat(tree-sitter-yts): Update to new tree-sitter version & improve parsing
Diffstat (limited to 'tree-sitter-yts/src/parser.c')
-rw-r--r-- | tree-sitter-yts/src/parser.c | 2150 |
1 files changed, 1100 insertions, 1050 deletions
diff --git a/tree-sitter-yts/src/parser.c b/tree-sitter-yts/src/parser.c index ea08f34..72974fe 100644 --- a/tree-sitter-yts/src/parser.c +++ b/tree-sitter-yts/src/parser.c @@ -10,76 +10,84 @@ * If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. */ -#include <tree_sitter/parser.h> +#include "tree_sitter/parser.h" #if defined(__GNUC__) || defined(__clang__) -#pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wmissing-field-initializers" #endif #define LANGUAGE_VERSION 14 #define STATE_COUNT 39 #define LARGE_STATE_COUNT 2 -#define SYMBOL_COUNT 42 +#define SYMBOL_COUNT 48 #define ALIAS_COUNT 0 -#define TOKEN_COUNT 30 +#define TOKEN_COUNT 36 #define EXTERNAL_TOKEN_COUNT 0 #define FIELD_COUNT 0 #define MAX_ALIAS_SEQUENCE_LENGTH 9 #define PRODUCTION_ID_COUNT 1 -enum -{ +enum ts_symbol_identifiers { anon_sym_LF = 1, anon_sym_pick = 2, anon_sym_p = 3, anon_sym_watch = 4, anon_sym_w = 5, - anon_sym_drop = 6, - anon_sym_d = 7, - anon_sym_url = 8, - anon_sym_u = 9, - aux_sym_flag_token1 = 10, - aux_sym_flag_token2 = 11, - aux_sym_flag_token3 = 12, - aux_sym_flag_token4 = 13, - aux_sym_flag_token5 = 14, - aux_sym_flag_token6 = 15, - aux_sym_flag_token7 = 16, - aux_sym_flag_token8 = 17, - aux_sym_flag_token9 = 18, - aux_sym_flag_token10 = 19, - aux_sym_flag_token11 = 20, - aux_sym_flag_token12 = 21, - sym_id = 22, - aux_sym_title_token1 = 23, - aux_sym_date_token1 = 24, - anon_sym_LBRACKNoDuration_RBRACK = 25, - aux_sym_duration_token1 = 26, - aux_sym_duration_token2 = 27, - sym_comment = 28, - sym_quote = 29, - sym_source_file = 30, - sym_line = 31, - sym_command = 32, - sym_flag = 33, - sym_title = 34, - sym_date = 35, - sym_author = 36, - sym_duration = 37, - sym_url = 38, - sym__q = 39, - aux_sym_source_file_repeat1 = 40, - aux_sym_line_repeat1 = 41, + anon_sym_watched = 6, + anon_sym_wd = 7, + anon_sym_add = 8, + anon_sym_a = 9, + anon_sym_drop = 10, + anon_sym_d = 11, + anon_sym_url = 12, + anon_sym_u = 13, + aux_sym_flag_token1 = 14, + aux_sym_flag_token2 = 15, + aux_sym_flag_token3 = 16, + aux_sym_flag_token4 = 17, + aux_sym_flag_token5 = 18, + aux_sym_flag_token6 = 19, + aux_sym_flag_token7 = 20, + aux_sym_flag_token8 = 21, + aux_sym_flag_token9 = 22, + aux_sym_flag_token10 = 23, + aux_sym_flag_token11 = 24, + aux_sym_flag_token12 = 25, + sym_id = 26, + aux_sym_title_token1 = 27, + anon_sym_LBRACKNoreleasedate_RBRACK = 28, + aux_sym_date_token1 = 29, + anon_sym_LBRACKNoauthor_RBRACK = 30, + anon_sym_LBRACKNoduration_RBRACK = 31, + aux_sym_duration_token1 = 32, + aux_sym_duration_token2 = 33, + sym_comment = 34, + sym_quote = 35, + sym_source_file = 36, + sym_line = 37, + sym_command = 38, + sym_flag = 39, + sym_title = 40, + sym_date = 41, + sym_author = 42, + sym_duration = 43, + sym_url = 44, + sym__q = 45, + aux_sym_source_file_repeat1 = 46, + aux_sym_line_repeat1 = 47, }; -static const char *const ts_symbol_names[] = { +static const char * const ts_symbol_names[] = { [ts_builtin_sym_end] = "end", [anon_sym_LF] = "\n", [anon_sym_pick] = "pick", [anon_sym_p] = "p", [anon_sym_watch] = "watch", [anon_sym_w] = "w", + [anon_sym_watched] = "watched", + [anon_sym_wd] = "wd", + [anon_sym_add] = "add", + [anon_sym_a] = "a", [anon_sym_drop] = "drop", [anon_sym_d] = "d", [anon_sym_url] = "url", @@ -98,8 +106,10 @@ static const char *const ts_symbol_names[] = { [aux_sym_flag_token12] = "flag_token12", [sym_id] = "id", [aux_sym_title_token1] = "title_token1", + [anon_sym_LBRACKNoreleasedate_RBRACK] = "[No release date]", [aux_sym_date_token1] = "date_token1", - [anon_sym_LBRACKNoDuration_RBRACK] = "[No Duration]", + [anon_sym_LBRACKNoauthor_RBRACK] = "[No author]", + [anon_sym_LBRACKNoduration_RBRACK] = "[No duration]", [aux_sym_duration_token1] = "duration_token1", [aux_sym_duration_token2] = "duration_token2", [sym_comment] = "comment", @@ -125,6 +135,10 @@ static const TSSymbol ts_symbol_map[] = { [anon_sym_p] = anon_sym_p, [anon_sym_watch] = anon_sym_watch, [anon_sym_w] = anon_sym_w, + [anon_sym_watched] = anon_sym_watched, + [anon_sym_wd] = anon_sym_wd, + [anon_sym_add] = anon_sym_add, + [anon_sym_a] = anon_sym_a, [anon_sym_drop] = anon_sym_drop, [anon_sym_d] = anon_sym_d, [anon_sym_url] = anon_sym_url, @@ -143,8 +157,10 @@ static const TSSymbol ts_symbol_map[] = { [aux_sym_flag_token12] = aux_sym_flag_token12, [sym_id] = sym_id, [aux_sym_title_token1] = aux_sym_title_token1, + [anon_sym_LBRACKNoreleasedate_RBRACK] = anon_sym_LBRACKNoreleasedate_RBRACK, [aux_sym_date_token1] = aux_sym_date_token1, - [anon_sym_LBRACKNoDuration_RBRACK] = anon_sym_LBRACKNoDuration_RBRACK, + [anon_sym_LBRACKNoauthor_RBRACK] = anon_sym_LBRACKNoauthor_RBRACK, + [anon_sym_LBRACKNoduration_RBRACK] = anon_sym_LBRACKNoduration_RBRACK, [aux_sym_duration_token1] = aux_sym_duration_token1, [aux_sym_duration_token2] = aux_sym_duration_token2, [sym_comment] = sym_comment, @@ -188,6 +204,22 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = false, }, + [anon_sym_watched] = { + .visible = true, + .named = false, + }, + [anon_sym_wd] = { + .visible = true, + .named = false, + }, + [anon_sym_add] = { + .visible = true, + .named = false, + }, + [anon_sym_a] = { + .visible = true, + .named = false, + }, [anon_sym_drop] = { .visible = true, .named = false, @@ -260,11 +292,19 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = false, .named = false, }, + [anon_sym_LBRACKNoreleasedate_RBRACK] = { + .visible = true, + .named = false, + }, [aux_sym_date_token1] = { .visible = false, .named = false, }, - [anon_sym_LBRACKNoDuration_RBRACK] = { + [anon_sym_LBRACKNoauthor_RBRACK] = { + .visible = true, + .named = false, + }, + [anon_sym_LBRACKNoduration_RBRACK] = { .visible = true, .named = false, }, @@ -334,603 +374,693 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { }, }; -static const TSSymbol ts_alias_sequences[PRODUCTION_ID_COUNT] - [MAX_ALIAS_SEQUENCE_LENGTH] - = { - [0] = { 0 }, - }; +static const TSSymbol ts_alias_sequences[PRODUCTION_ID_COUNT][MAX_ALIAS_SEQUENCE_LENGTH] = { + [0] = {0}, +}; static const uint16_t ts_non_terminal_alias_map[] = { 0, }; static const TSStateId ts_primary_state_ids[STATE_COUNT] = { - [0] = 0, [1] = 1, [2] = 2, [3] = 3, [4] = 4, [5] = 5, [6] = 6, - [7] = 7, [8] = 8, [9] = 9, [10] = 10, [11] = 11, [12] = 12, [13] = 13, - [14] = 14, [15] = 15, [16] = 16, [17] = 17, [18] = 18, [19] = 19, [20] = 20, - [21] = 21, [22] = 22, [23] = 23, [24] = 24, [25] = 25, [26] = 26, [27] = 27, - [28] = 28, [29] = 29, [30] = 30, [31] = 31, [32] = 32, [33] = 33, [34] = 34, - [35] = 35, [36] = 36, [37] = 37, [38] = 38, + [0] = 0, + [1] = 1, + [2] = 2, + [3] = 3, + [4] = 4, + [5] = 5, + [6] = 6, + [7] = 7, + [8] = 8, + [9] = 9, + [10] = 10, + [11] = 11, + [12] = 12, + [13] = 13, + [14] = 14, + [15] = 15, + [16] = 16, + [17] = 17, + [18] = 18, + [19] = 19, + [20] = 20, + [21] = 21, + [22] = 22, + [23] = 23, + [24] = 24, + [25] = 25, + [26] = 26, + [27] = 27, + [28] = 28, + [29] = 29, + [30] = 30, + [31] = 31, + [32] = 32, + [33] = 33, + [34] = 34, + [35] = 35, + [36] = 36, + [37] = 37, + [38] = 38, }; -static bool -ts_lex (TSLexer *lexer, TSStateId state) -{ - START_LEXER (); - eof = lexer->eof (lexer); - switch (state) - { +static bool ts_lex(TSLexer *lexer, TSStateId state) { + START_LEXER(); + eof = lexer->eof(lexer); + switch (state) { case 0: - if (eof) - ADVANCE (57); - if (lookahead == '"') - ADVANCE (95); - if (lookahead == '#') - ADVANCE (94); - if (lookahead == '-') - ADVANCE (20); - if (lookahead == '[') - ADVANCE (24); - if (lookahead == 'd') - ADVANCE (64); - if (lookahead == 'p') - ADVANCE (60); - if (lookahead == 'u') - ADVANCE (66); - if (lookahead == 'w') - ADVANCE (62); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - SKIP (0) - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (31); - END_STATE (); + if (eof) ADVANCE(78); + ADVANCE_MAP( + '"', 134, + '#', 133, + '-', 21, + '[', 24, + 'a', 87, + 'd', 89, + 'p', 81, + 'u', 91, + 'w', 83, + ); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') SKIP(0); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(44); + END_STATE(); case 1: - if (lookahead == '\n') - ADVANCE (58); - if (lookahead == '\t' || lookahead == '\r' || lookahead == ' ') - SKIP (1) - END_STATE (); + if (lookahead == '\n') ADVANCE(79); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') SKIP(1); + END_STATE(); case 2: - if (lookahead == ' ') - ADVANCE (7); - if (lookahead == '=') - ADVANCE (8); - END_STATE (); + if (lookahead == ' ') ADVANCE(8); + if (lookahead == '=') ADVANCE(9); + END_STATE(); case 3: - if (lookahead == ' ') - ADVANCE (49); - END_STATE (); + if (lookahead == ' ') ADVANCE(70); + END_STATE(); case 4: - if (lookahead == ' ') - ADVANCE (23); - END_STATE (); + if (lookahead == ' ') ADVANCE(29); + END_STATE(); case 5: - if (lookahead == ' ') - ADVANCE (50); - END_STATE (); + if (lookahead == ' ') ADVANCE(71); + END_STATE(); case 6: - if (lookahead == ' ') - ADVANCE (9); - if (lookahead == '=') - ADVANCE (10); - if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') - || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (6); - END_STATE (); + if (lookahead == ' ') ADVANCE(37); + END_STATE(); case 7: - if (lookahead == '"') - ADVANCE (67); - if (lookahead == '\'') - ADVANCE (68); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (69); - END_STATE (); + if (lookahead == ' ') ADVANCE(10); + if (lookahead == '=') ADVANCE(11); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(7); + END_STATE(); case 8: - if (lookahead == '"') - ADVANCE (72); - if (lookahead == '\'') - ADVANCE (73); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (74); - END_STATE (); + if (lookahead == '"') ADVANCE(92); + if (lookahead == '\'') ADVANCE(93); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(94); + END_STATE(); case 9: - if (lookahead == '"') - ADVANCE (77); - if (lookahead == '\'') - ADVANCE (78); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (79); - END_STATE (); + if (lookahead == '"') ADVANCE(97); + if (lookahead == '\'') ADVANCE(98); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(99); + END_STATE(); case 10: - if (lookahead == '"') - ADVANCE (82); - if (lookahead == '\'') - ADVANCE (83); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (84); - END_STATE (); + if (lookahead == '"') ADVANCE(102); + if (lookahead == '\'') ADVANCE(103); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(104); + END_STATE(); case 11: - if (lookahead == '"') - ADVANCE (71); - if (lookahead != 0) - ADVANCE (11); - END_STATE (); + if (lookahead == '"') ADVANCE(107); + if (lookahead == '\'') ADVANCE(108); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(109); + END_STATE(); case 12: - if (lookahead == '"') - ADVANCE (76); - if (lookahead != 0) - ADVANCE (12); - END_STATE (); + if (lookahead == '"') ADVANCE(96); + if (lookahead != 0) ADVANCE(12); + END_STATE(); case 13: - if (lookahead == '"') - ADVANCE (81); - if (lookahead != 0) - ADVANCE (13); - END_STATE (); + if (lookahead == '"') ADVANCE(101); + if (lookahead != 0) ADVANCE(13); + END_STATE(); case 14: - if (lookahead == '"') - ADVANCE (86); - if (lookahead != 0) - ADVANCE (14); - END_STATE (); + if (lookahead == '"') ADVANCE(106); + if (lookahead != 0) ADVANCE(14); + END_STATE(); case 15: - if (lookahead == '\'') - ADVANCE (70); - if (lookahead != 0) - ADVANCE (15); - END_STATE (); + if (lookahead == '"') ADVANCE(111); + if (lookahead != 0) ADVANCE(15); + END_STATE(); case 16: - if (lookahead == '\'') - ADVANCE (75); - if (lookahead != 0) - ADVANCE (16); - END_STATE (); + if (lookahead == '\'') ADVANCE(95); + if (lookahead != 0) ADVANCE(16); + END_STATE(); case 17: - if (lookahead == '\'') - ADVANCE (80); - if (lookahead != 0) - ADVANCE (17); - END_STATE (); + if (lookahead == '\'') ADVANCE(100); + if (lookahead != 0) ADVANCE(17); + END_STATE(); case 18: - if (lookahead == '\'') - ADVANCE (85); - if (lookahead != 0) - ADVANCE (18); - END_STATE (); + if (lookahead == '\'') ADVANCE(105); + if (lookahead != 0) ADVANCE(18); + END_STATE(); case 19: - if (lookahead == '-') - ADVANCE (20); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - SKIP (19) - if (('0' <= lookahead && lookahead <= '9') - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (87); - END_STATE (); + if (lookahead == '\'') ADVANCE(110); + if (lookahead != 0) ADVANCE(19); + END_STATE(); case 20: - if (lookahead == '-') - ADVANCE (55); - if (('0' <= lookahead && lookahead <= '9') - || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (2); - END_STATE (); + if (lookahead == '-') ADVANCE(21); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') SKIP(20); + if (('0' <= lookahead && lookahead <= '9') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(112); + END_STATE(); case 21: - if (lookahead == '-') - ADVANCE (53); - if (lookahead == 'h') - ADVANCE (3); - if (lookahead == 'm') - ADVANCE (5); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (32); - END_STATE (); + if (lookahead == '-') ADVANCE(76); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(2); + END_STATE(); case 22: - if (lookahead == '-') - ADVANCE (54); - END_STATE (); + if (lookahead == '-') ADVANCE(74); + if (lookahead == 'h') ADVANCE(3); + if (lookahead == 'm') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(45); + END_STATE(); case 23: - if (lookahead == 'D') - ADVANCE (47); - END_STATE (); + if (lookahead == '-') ADVANCE(75); + END_STATE(); case 24: - if (lookahead == 'N') - ADVANCE (41); - END_STATE (); + if (lookahead == 'N') ADVANCE(56); + END_STATE(); case 25: - if (lookahead == ']') - ADVANCE (91); - END_STATE (); + if (lookahead == '[') ADVANCE(114); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(115); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); case 26: - if (lookahead == 'a') - ADVANCE (45); - END_STATE (); + if (lookahead == ']') ADVANCE(128); + END_STATE(); case 27: - if (lookahead == 'c') - ADVANCE (35); - END_STATE (); + if (lookahead == ']') ADVANCE(130); + END_STATE(); case 28: - if (lookahead == 'c') - ADVANCE (33); - END_STATE (); + if (lookahead == ']') ADVANCE(126); + END_STATE(); case 29: - if (lookahead == 'h') - ADVANCE (3); - if (lookahead == 'm') - ADVANCE (5); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (21); - END_STATE (); + if (lookahead == 'a') ADVANCE(68); + if (lookahead == 'd') ADVANCE(67); + if (lookahead == 'r') ADVANCE(38); + END_STATE(); case 30: - if (lookahead == 'h') - ADVANCE (3); - if (lookahead == 'm') - ADVANCE (5); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (29); - END_STATE (); + if (lookahead == 'a') ADVANCE(62); + END_STATE(); case 31: - if (lookahead == 'h') - ADVANCE (3); - if (lookahead == 'm') - ADVANCE (5); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (30); - END_STATE (); + if (lookahead == 'a') ADVANCE(63); + END_STATE(); case 32: - if (lookahead == 'h') - ADVANCE (3); - if (lookahead == 'm') - ADVANCE (5); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (32); - END_STATE (); + if (lookahead == 'a') ADVANCE(66); + END_STATE(); case 33: - if (lookahead == 'h') - ADVANCE (61); - END_STATE (); + if (lookahead == 'c') ADVANCE(49); + END_STATE(); case 34: - if (lookahead == 'i') - ADVANCE (40); - END_STATE (); + if (lookahead == 'c') ADVANCE(46); + END_STATE(); case 35: - if (lookahead == 'k') - ADVANCE (59); - END_STATE (); + if (lookahead == 'd') ADVANCE(86); + END_STATE(); case 36: - if (lookahead == 'l') - ADVANCE (65); - END_STATE (); + if (lookahead == 'd') ADVANCE(84); + END_STATE(); case 37: - if (lookahead == 'm') - ADVANCE (93); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (37); - END_STATE (); + if (lookahead == 'd') ADVANCE(32); + END_STATE(); case 38: - if (lookahead == 'n') - ADVANCE (25); - END_STATE (); + if (lookahead == 'e') ADVANCE(51); + END_STATE(); case 39: - if (lookahead == 'o') - ADVANCE (42); - END_STATE (); + if (lookahead == 'e') ADVANCE(30); + END_STATE(); case 40: - if (lookahead == 'o') - ADVANCE (38); - END_STATE (); + if (lookahead == 'e') ADVANCE(6); + END_STATE(); case 41: - if (lookahead == 'o') - ADVANCE (4); - END_STATE (); + if (lookahead == 'e') ADVANCE(28); + END_STATE(); case 42: - if (lookahead == 'p') - ADVANCE (63); - END_STATE (); + if (lookahead == 'h') ADVANCE(3); + if (lookahead == 'm') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(22); + END_STATE(); case 43: - if (lookahead == 'r') - ADVANCE (26); - END_STATE (); + if (lookahead == 'h') ADVANCE(3); + if (lookahead == 'm') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(42); + END_STATE(); case 44: - if (lookahead == 's') - ADVANCE (92); - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (44); - END_STATE (); + if (lookahead == 'h') ADVANCE(3); + if (lookahead == 'm') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(43); + END_STATE(); case 45: - if (lookahead == 't') - ADVANCE (34); - END_STATE (); + if (lookahead == 'h') ADVANCE(3); + if (lookahead == 'm') ADVANCE(5); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(45); + END_STATE(); case 46: - if (lookahead == 't') - ADVANCE (28); - END_STATE (); + if (lookahead == 'h') ADVANCE(82); + END_STATE(); case 47: - if (lookahead == 'u') - ADVANCE (43); - END_STATE (); + if (lookahead == 'h') ADVANCE(57); + END_STATE(); case 48: - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (88); - if (lookahead != 0 && lookahead != '"') - ADVANCE (89); - END_STATE (); + if (lookahead == 'i') ADVANCE(55); + END_STATE(); case 49: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (37); - END_STATE (); + if (lookahead == 'k') ADVANCE(80); + END_STATE(); case 50: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (44); - END_STATE (); + if (lookahead == 'l') ADVANCE(90); + END_STATE(); case 51: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (22); - END_STATE (); + if (lookahead == 'l') ADVANCE(39); + END_STATE(); case 52: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (90); - END_STATE (); + if (lookahead == 'm') ADVANCE(132); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(52); + END_STATE(); case 53: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (51); - END_STATE (); + if (lookahead == 'n') ADVANCE(27); + END_STATE(); case 54: - if (('0' <= lookahead && lookahead <= '9')) - ADVANCE (52); - END_STATE (); + if (lookahead == 'o') ADVANCE(58); + END_STATE(); case 55: - if (('0' <= lookahead && lookahead <= '9') - || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (56); - END_STATE (); + if (lookahead == 'o') ADVANCE(53); + END_STATE(); case 56: - if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') - || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (6); - END_STATE (); + if (lookahead == 'o') ADVANCE(4); + END_STATE(); case 57: - ACCEPT_TOKEN (ts_builtin_sym_end); - END_STATE (); + if (lookahead == 'o') ADVANCE(60); + END_STATE(); case 58: - ACCEPT_TOKEN (anon_sym_LF); - if (lookahead == '\n') - ADVANCE (58); - END_STATE (); + if (lookahead == 'p') ADVANCE(88); + END_STATE(); case 59: - ACCEPT_TOKEN (anon_sym_pick); - END_STATE (); + if (lookahead == 'r') ADVANCE(31); + END_STATE(); case 60: - ACCEPT_TOKEN (anon_sym_p); - if (lookahead == 'i') - ADVANCE (27); - END_STATE (); + if (lookahead == 'r') ADVANCE(26); + END_STATE(); case 61: - ACCEPT_TOKEN (anon_sym_watch); - END_STATE (); + if (lookahead == 's') ADVANCE(131); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(61); + END_STATE(); case 62: - ACCEPT_TOKEN (anon_sym_w); - if (lookahead == 'a') - ADVANCE (46); - END_STATE (); + if (lookahead == 's') ADVANCE(40); + END_STATE(); case 63: - ACCEPT_TOKEN (anon_sym_drop); - END_STATE (); + if (lookahead == 't') ADVANCE(48); + END_STATE(); case 64: - ACCEPT_TOKEN (anon_sym_d); - if (lookahead == 'r') - ADVANCE (39); - END_STATE (); + if (lookahead == 't') ADVANCE(34); + END_STATE(); case 65: - ACCEPT_TOKEN (anon_sym_url); - END_STATE (); + if (lookahead == 't') ADVANCE(47); + END_STATE(); case 66: - ACCEPT_TOKEN (anon_sym_u); - if (lookahead == 'r') - ADVANCE (36); - END_STATE (); + if (lookahead == 't') ADVANCE(41); + END_STATE(); case 67: - ACCEPT_TOKEN (aux_sym_flag_token1); - if (lookahead == '"') - ADVANCE (69); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (11); - if (lookahead != 0) - ADVANCE (67); - END_STATE (); + if (lookahead == 'u') ADVANCE(59); + END_STATE(); case 68: - ACCEPT_TOKEN (aux_sym_flag_token1); - if (lookahead == '\'') - ADVANCE (69); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (15); - if (lookahead != 0) - ADVANCE (68); - END_STATE (); + if (lookahead == 'u') ADVANCE(65); + END_STATE(); case 69: - ACCEPT_TOKEN (aux_sym_flag_token1); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (69); - END_STATE (); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(124); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); case 70: - ACCEPT_TOKEN (aux_sym_flag_token2); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(52); + END_STATE(); case 71: - ACCEPT_TOKEN (aux_sym_flag_token3); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(61); + END_STATE(); case 72: - ACCEPT_TOKEN (aux_sym_flag_token4); - if (lookahead == '"') - ADVANCE (74); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (12); - if (lookahead != 0) - ADVANCE (72); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(23); + END_STATE(); case 73: - ACCEPT_TOKEN (aux_sym_flag_token4); - if (lookahead == '\'') - ADVANCE (74); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (16); - if (lookahead != 0) - ADVANCE (73); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(127); + END_STATE(); case 74: - ACCEPT_TOKEN (aux_sym_flag_token4); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (74); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(72); + END_STATE(); case 75: - ACCEPT_TOKEN (aux_sym_flag_token5); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(73); + END_STATE(); case 76: - ACCEPT_TOKEN (aux_sym_flag_token6); - END_STATE (); + if (('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(77); + END_STATE(); case 77: - ACCEPT_TOKEN (aux_sym_flag_token7); - if (lookahead == '"') - ADVANCE (79); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (13); - if (lookahead != 0) - ADVANCE (77); - END_STATE (); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(7); + END_STATE(); case 78: - ACCEPT_TOKEN (aux_sym_flag_token7); - if (lookahead == '\'') - ADVANCE (79); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (17); - if (lookahead != 0) - ADVANCE (78); - END_STATE (); + ACCEPT_TOKEN(ts_builtin_sym_end); + END_STATE(); case 79: - ACCEPT_TOKEN (aux_sym_flag_token7); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (79); - END_STATE (); + ACCEPT_TOKEN(anon_sym_LF); + if (lookahead == '\n') ADVANCE(79); + END_STATE(); case 80: - ACCEPT_TOKEN (aux_sym_flag_token8); - END_STATE (); + ACCEPT_TOKEN(anon_sym_pick); + END_STATE(); case 81: - ACCEPT_TOKEN (aux_sym_flag_token9); - END_STATE (); + ACCEPT_TOKEN(anon_sym_p); + if (lookahead == 'i') ADVANCE(33); + END_STATE(); case 82: - ACCEPT_TOKEN (aux_sym_flag_token10); - if (lookahead == '"') - ADVANCE (84); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (14); - if (lookahead != 0) - ADVANCE (82); - END_STATE (); + ACCEPT_TOKEN(anon_sym_watch); + if (lookahead == 'e') ADVANCE(36); + END_STATE(); case 83: - ACCEPT_TOKEN (aux_sym_flag_token10); - if (lookahead == '\'') - ADVANCE (84); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (18); - if (lookahead != 0) - ADVANCE (83); - END_STATE (); + ACCEPT_TOKEN(anon_sym_w); + if (lookahead == 'a') ADVANCE(64); + if (lookahead == 'd') ADVANCE(85); + END_STATE(); case 84: - ACCEPT_TOKEN (aux_sym_flag_token10); - if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' - && lookahead != '\r' && lookahead != ' ') - ADVANCE (84); - END_STATE (); + ACCEPT_TOKEN(anon_sym_watched); + END_STATE(); case 85: - ACCEPT_TOKEN (aux_sym_flag_token11); - END_STATE (); + ACCEPT_TOKEN(anon_sym_wd); + END_STATE(); case 86: - ACCEPT_TOKEN (aux_sym_flag_token12); - END_STATE (); + ACCEPT_TOKEN(anon_sym_add); + END_STATE(); case 87: - ACCEPT_TOKEN (sym_id); - if (('0' <= lookahead && lookahead <= '9') - || ('a' <= lookahead && lookahead <= 'z')) - ADVANCE (87); - END_STATE (); + ACCEPT_TOKEN(anon_sym_a); + if (lookahead == 'd') ADVANCE(35); + END_STATE(); case 88: - ACCEPT_TOKEN (aux_sym_title_token1); - if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' - || lookahead == ' ') - ADVANCE (88); - if (lookahead != 0 && lookahead != '"') - ADVANCE (89); - END_STATE (); + ACCEPT_TOKEN(anon_sym_drop); + END_STATE(); case 89: - ACCEPT_TOKEN (aux_sym_title_token1); - if (lookahead != 0 && lookahead != '"') - ADVANCE (89); - END_STATE (); + ACCEPT_TOKEN(anon_sym_d); + if (lookahead == 'r') ADVANCE(54); + END_STATE(); case 90: - ACCEPT_TOKEN (aux_sym_date_token1); - END_STATE (); + ACCEPT_TOKEN(anon_sym_url); + END_STATE(); case 91: - ACCEPT_TOKEN (anon_sym_LBRACKNoDuration_RBRACK); - END_STATE (); + ACCEPT_TOKEN(anon_sym_u); + if (lookahead == 'r') ADVANCE(50); + END_STATE(); case 92: - ACCEPT_TOKEN (aux_sym_duration_token1); - END_STATE (); + ACCEPT_TOKEN(aux_sym_flag_token1); + if (lookahead == '"') ADVANCE(94); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(12); + if (lookahead != 0) ADVANCE(92); + END_STATE(); case 93: - ACCEPT_TOKEN (aux_sym_duration_token2); - END_STATE (); + ACCEPT_TOKEN(aux_sym_flag_token1); + if (lookahead == '\'') ADVANCE(94); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(16); + if (lookahead != 0) ADVANCE(93); + END_STATE(); case 94: - ACCEPT_TOKEN (sym_comment); - if (lookahead != 0 && lookahead != '\n') - ADVANCE (94); - END_STATE (); + ACCEPT_TOKEN(aux_sym_flag_token1); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(94); + END_STATE(); case 95: - ACCEPT_TOKEN (sym_quote); - END_STATE (); + ACCEPT_TOKEN(aux_sym_flag_token2); + END_STATE(); + case 96: + ACCEPT_TOKEN(aux_sym_flag_token3); + END_STATE(); + case 97: + ACCEPT_TOKEN(aux_sym_flag_token4); + if (lookahead == '"') ADVANCE(99); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(13); + if (lookahead != 0) ADVANCE(97); + END_STATE(); + case 98: + ACCEPT_TOKEN(aux_sym_flag_token4); + if (lookahead == '\'') ADVANCE(99); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(17); + if (lookahead != 0) ADVANCE(98); + END_STATE(); + case 99: + ACCEPT_TOKEN(aux_sym_flag_token4); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(99); + END_STATE(); + case 100: + ACCEPT_TOKEN(aux_sym_flag_token5); + END_STATE(); + case 101: + ACCEPT_TOKEN(aux_sym_flag_token6); + END_STATE(); + case 102: + ACCEPT_TOKEN(aux_sym_flag_token7); + if (lookahead == '"') ADVANCE(104); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(14); + if (lookahead != 0) ADVANCE(102); + END_STATE(); + case 103: + ACCEPT_TOKEN(aux_sym_flag_token7); + if (lookahead == '\'') ADVANCE(104); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(18); + if (lookahead != 0) ADVANCE(103); + END_STATE(); + case 104: + ACCEPT_TOKEN(aux_sym_flag_token7); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(104); + END_STATE(); + case 105: + ACCEPT_TOKEN(aux_sym_flag_token8); + END_STATE(); + case 106: + ACCEPT_TOKEN(aux_sym_flag_token9); + END_STATE(); + case 107: + ACCEPT_TOKEN(aux_sym_flag_token10); + if (lookahead == '"') ADVANCE(109); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(15); + if (lookahead != 0) ADVANCE(107); + END_STATE(); + case 108: + ACCEPT_TOKEN(aux_sym_flag_token10); + if (lookahead == '\'') ADVANCE(109); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(19); + if (lookahead != 0) ADVANCE(108); + END_STATE(); + case 109: + ACCEPT_TOKEN(aux_sym_flag_token10); + if (lookahead != 0 && + (lookahead < '\t' || '\r' < lookahead) && + lookahead != ' ') ADVANCE(109); + END_STATE(); + case 110: + ACCEPT_TOKEN(aux_sym_flag_token11); + END_STATE(); + case 111: + ACCEPT_TOKEN(aux_sym_flag_token12); + END_STATE(); + case 112: + ACCEPT_TOKEN(sym_id); + if (('0' <= lookahead && lookahead <= '9') || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(112); + END_STATE(); + case 113: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == ' ') ADVANCE(117); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 114: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'N') ADVANCE(119); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 115: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == '[') ADVANCE(114); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(115); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 116: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == ']') ADVANCE(129); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 117: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'a') ADVANCE(123); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 118: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'h') ADVANCE(120); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 119: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'o') ADVANCE(113); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 120: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'o') ADVANCE(121); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 121: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'r') ADVANCE(116); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 122: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 't') ADVANCE(118); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 123: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead == 'u') ADVANCE(122); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 124: + ACCEPT_TOKEN(aux_sym_title_token1); + if (('\t' <= lookahead && lookahead <= '\r') || + lookahead == ' ') ADVANCE(124); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 125: + ACCEPT_TOKEN(aux_sym_title_token1); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 126: + ACCEPT_TOKEN(anon_sym_LBRACKNoreleasedate_RBRACK); + END_STATE(); + case 127: + ACCEPT_TOKEN(aux_sym_date_token1); + END_STATE(); + case 128: + ACCEPT_TOKEN(anon_sym_LBRACKNoauthor_RBRACK); + END_STATE(); + case 129: + ACCEPT_TOKEN(anon_sym_LBRACKNoauthor_RBRACK); + if (lookahead != 0 && + lookahead != '"') ADVANCE(125); + END_STATE(); + case 130: + ACCEPT_TOKEN(anon_sym_LBRACKNoduration_RBRACK); + END_STATE(); + case 131: + ACCEPT_TOKEN(aux_sym_duration_token1); + END_STATE(); + case 132: + ACCEPT_TOKEN(aux_sym_duration_token2); + END_STATE(); + case 133: + ACCEPT_TOKEN(sym_comment); + if (lookahead != 0 && + lookahead != '\n') ADVANCE(133); + END_STATE(); + case 134: + ACCEPT_TOKEN(sym_quote); + END_STATE(); default: return false; - } + } } static const TSLexMode ts_lex_modes[STATE_COUNT] = { - [0] = { .lex_state = 0 }, [1] = { .lex_state = 0 }, - [2] = { .lex_state = 19 }, [3] = { .lex_state = 19 }, - [4] = { .lex_state = 19 }, [5] = { .lex_state = 19 }, - [6] = { .lex_state = 0 }, [7] = { .lex_state = 19 }, - [8] = { .lex_state = 0 }, [9] = { .lex_state = 0 }, - [10] = { .lex_state = 0 }, [11] = { .lex_state = 0 }, - [12] = { .lex_state = 0 }, [13] = { .lex_state = 0 }, - [14] = { .lex_state = 0 }, [15] = { .lex_state = 0 }, - [16] = { .lex_state = 0 }, [17] = { .lex_state = 0 }, - [18] = { .lex_state = 0 }, [19] = { .lex_state = 0 }, - [20] = { .lex_state = 0 }, [21] = { .lex_state = 0 }, - [22] = { .lex_state = 0 }, [23] = { .lex_state = 0 }, - [24] = { .lex_state = 0 }, [25] = { .lex_state = 0 }, - [26] = { .lex_state = 0 }, [27] = { .lex_state = 0 }, - [28] = { .lex_state = 48 }, [29] = { .lex_state = 0 }, - [30] = { .lex_state = 1 }, [31] = { .lex_state = 48 }, - [32] = { .lex_state = 0 }, [33] = { .lex_state = 0 }, - [34] = { .lex_state = 0 }, [35] = { .lex_state = 0 }, - [36] = { .lex_state = 1 }, [37] = { .lex_state = 1 }, - [38] = { .lex_state = 48 }, + [0] = {.lex_state = 0}, + [1] = {.lex_state = 0}, + [2] = {.lex_state = 0}, + [3] = {.lex_state = 0}, + [4] = {.lex_state = 20}, + [5] = {.lex_state = 20}, + [6] = {.lex_state = 20}, + [7] = {.lex_state = 0}, + [8] = {.lex_state = 0}, + [9] = {.lex_state = 20}, + [10] = {.lex_state = 20}, + [11] = {.lex_state = 0}, + [12] = {.lex_state = 0}, + [13] = {.lex_state = 0}, + [14] = {.lex_state = 0}, + [15] = {.lex_state = 0}, + [16] = {.lex_state = 0}, + [17] = {.lex_state = 0}, + [18] = {.lex_state = 0}, + [19] = {.lex_state = 0}, + [20] = {.lex_state = 0}, + [21] = {.lex_state = 0}, + [22] = {.lex_state = 0}, + [23] = {.lex_state = 25}, + [24] = {.lex_state = 0}, + [25] = {.lex_state = 0}, + [26] = {.lex_state = 0}, + [27] = {.lex_state = 0}, + [28] = {.lex_state = 0}, + [29] = {.lex_state = 69}, + [30] = {.lex_state = 0}, + [31] = {.lex_state = 0}, + [32] = {.lex_state = 0}, + [33] = {.lex_state = 0}, + [34] = {.lex_state = 1}, + [35] = {.lex_state = 0}, + [36] = {.lex_state = 1}, + [37] = {.lex_state = 1}, + [38] = {.lex_state = 69}, }; static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { @@ -940,6 +1070,10 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_p] = ACTIONS(1), [anon_sym_watch] = ACTIONS(1), [anon_sym_w] = ACTIONS(1), + [anon_sym_watched] = ACTIONS(1), + [anon_sym_wd] = ACTIONS(1), + [anon_sym_add] = ACTIONS(1), + [anon_sym_a] = ACTIONS(1), [anon_sym_drop] = ACTIONS(1), [anon_sym_d] = ACTIONS(1), [anon_sym_url] = ACTIONS(1), @@ -956,23 +1090,29 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [aux_sym_flag_token10] = ACTIONS(1), [aux_sym_flag_token11] = ACTIONS(1), [aux_sym_flag_token12] = ACTIONS(1), + [anon_sym_LBRACKNoreleasedate_RBRACK] = ACTIONS(1), [aux_sym_date_token1] = ACTIONS(1), - [anon_sym_LBRACKNoDuration_RBRACK] = ACTIONS(1), + [anon_sym_LBRACKNoauthor_RBRACK] = ACTIONS(1), + [anon_sym_LBRACKNoduration_RBRACK] = ACTIONS(1), [aux_sym_duration_token1] = ACTIONS(1), [aux_sym_duration_token2] = ACTIONS(1), [sym_comment] = ACTIONS(1), [sym_quote] = ACTIONS(1), }, [1] = { - [sym_source_file] = STATE(34), - [sym_line] = STATE(6), - [sym_command] = STATE(3), - [aux_sym_source_file_repeat1] = STATE(6), + [sym_source_file] = STATE(30), + [sym_line] = STATE(3), + [sym_command] = STATE(4), + [aux_sym_source_file_repeat1] = STATE(3), [ts_builtin_sym_end] = ACTIONS(3), [anon_sym_pick] = ACTIONS(5), [anon_sym_p] = ACTIONS(7), - [anon_sym_watch] = ACTIONS(5), + [anon_sym_watch] = ACTIONS(7), [anon_sym_w] = ACTIONS(7), + [anon_sym_watched] = ACTIONS(5), + [anon_sym_wd] = ACTIONS(5), + [anon_sym_add] = ACTIONS(5), + [anon_sym_a] = ACTIONS(7), [anon_sym_drop] = ACTIONS(5), [anon_sym_d] = ACTIONS(7), [anon_sym_url] = ACTIONS(5), @@ -982,536 +1122,446 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { }; static const uint16_t ts_small_parse_table[] = { - [0] = 3, - ACTIONS (14), - 1, - sym_id, - STATE (2), - 2, - sym_flag, - aux_sym_line_repeat1, - ACTIONS (11), - 12, - aux_sym_flag_token1, - aux_sym_flag_token2, - aux_sym_flag_token3, - aux_sym_flag_token4, - aux_sym_flag_token5, - aux_sym_flag_token6, - aux_sym_flag_token7, - aux_sym_flag_token8, - aux_sym_flag_token9, - aux_sym_flag_token10, - aux_sym_flag_token11, - aux_sym_flag_token12, - [22] = 3, - ACTIONS (18), - 1, - sym_id, - STATE (4), - 2, - sym_flag, - aux_sym_line_repeat1, - ACTIONS (16), - 12, - aux_sym_flag_token1, - aux_sym_flag_token2, - aux_sym_flag_token3, - aux_sym_flag_token4, - aux_sym_flag_token5, - aux_sym_flag_token6, - aux_sym_flag_token7, - aux_sym_flag_token8, - aux_sym_flag_token9, - aux_sym_flag_token10, - aux_sym_flag_token11, - aux_sym_flag_token12, - [44] = 3, - ACTIONS (20), - 1, - sym_id, - STATE (2), - 2, - sym_flag, - aux_sym_line_repeat1, - ACTIONS (16), - 12, - aux_sym_flag_token1, - aux_sym_flag_token2, - aux_sym_flag_token3, - aux_sym_flag_token4, - aux_sym_flag_token5, - aux_sym_flag_token6, - aux_sym_flag_token7, - aux_sym_flag_token8, - aux_sym_flag_token9, - aux_sym_flag_token10, - aux_sym_flag_token11, - aux_sym_flag_token12, - [66] = 2, - ACTIONS (24), - 1, - sym_id, - ACTIONS (22), - 12, - aux_sym_flag_token1, - aux_sym_flag_token2, - aux_sym_flag_token3, - aux_sym_flag_token4, - aux_sym_flag_token5, - aux_sym_flag_token6, - aux_sym_flag_token7, - aux_sym_flag_token8, - aux_sym_flag_token9, - aux_sym_flag_token10, - aux_sym_flag_token11, - aux_sym_flag_token12, - [84] = 6, - ACTIONS (26), - 1, - ts_builtin_sym_end, - ACTIONS (28), - 1, - sym_comment, - STATE (3), - 1, - sym_command, - STATE (8), - 2, - sym_line, - aux_sym_source_file_repeat1, - ACTIONS (5), - 4, - anon_sym_pick, - anon_sym_watch, - anon_sym_drop, - anon_sym_url, - ACTIONS (7), - 4, - anon_sym_p, - anon_sym_w, - anon_sym_d, - anon_sym_u, - [110] = 2, - ACTIONS (32), - 1, - sym_id, - ACTIONS (30), - 12, - aux_sym_flag_token1, - aux_sym_flag_token2, - aux_sym_flag_token3, - aux_sym_flag_token4, - aux_sym_flag_token5, - aux_sym_flag_token6, - aux_sym_flag_token7, - aux_sym_flag_token8, - aux_sym_flag_token9, - aux_sym_flag_token10, - aux_sym_flag_token11, - aux_sym_flag_token12, - [128] = 6, - ACTIONS (34), - 1, - ts_builtin_sym_end, - ACTIONS (42), - 1, - sym_comment, - STATE (3), - 1, - sym_command, - STATE (8), - 2, - sym_line, - aux_sym_source_file_repeat1, - ACTIONS (36), - 4, - anon_sym_pick, - anon_sym_watch, - anon_sym_drop, - anon_sym_url, - ACTIONS (39), - 4, - anon_sym_p, - anon_sym_w, - anon_sym_d, - anon_sym_u, - [154] = 2, - ACTIONS (47), - 4, - anon_sym_p, - anon_sym_w, - anon_sym_d, - anon_sym_u, - ACTIONS (45), - 6, - ts_builtin_sym_end, - anon_sym_pick, - anon_sym_watch, - anon_sym_drop, - anon_sym_url, - sym_comment, - [169] = 2, - ACTIONS (51), - 4, - anon_sym_p, - anon_sym_w, - anon_sym_d, - anon_sym_u, - ACTIONS (49), - 6, - ts_builtin_sym_end, - anon_sym_pick, - anon_sym_watch, - anon_sym_drop, - anon_sym_url, - sym_comment, - [184] = 3, - ACTIONS (53), - 1, - sym_quote, - STATE (12), - 1, - sym__q, - STATE (20), - 1, - sym_duration, - [194] = 1, - ACTIONS (55), - 3, - anon_sym_LBRACKNoDuration_RBRACK, - aux_sym_duration_token1, - aux_sym_duration_token2, + [0] = 6, + ACTIONS(11), 1, + ts_builtin_sym_end, + ACTIONS(19), 1, + sym_comment, + STATE(4), 1, + sym_command, + STATE(2), 2, + sym_line, + aux_sym_source_file_repeat1, + ACTIONS(13), 6, + anon_sym_pick, + anon_sym_watched, + anon_sym_wd, + anon_sym_add, + anon_sym_drop, + anon_sym_url, + ACTIONS(16), 6, + anon_sym_p, + anon_sym_watch, + anon_sym_w, + anon_sym_a, + anon_sym_d, + anon_sym_u, + [30] = 6, + ACTIONS(22), 1, + ts_builtin_sym_end, + ACTIONS(24), 1, + sym_comment, + STATE(4), 1, + sym_command, + STATE(2), 2, + sym_line, + aux_sym_source_file_repeat1, + ACTIONS(5), 6, + anon_sym_pick, + anon_sym_watched, + anon_sym_wd, + anon_sym_add, + anon_sym_drop, + anon_sym_url, + ACTIONS(7), 6, + anon_sym_p, + anon_sym_watch, + anon_sym_w, + anon_sym_a, + anon_sym_d, + anon_sym_u, + [60] = 3, + ACTIONS(28), 1, + sym_id, + STATE(5), 2, + sym_flag, + aux_sym_line_repeat1, + ACTIONS(26), 12, + aux_sym_flag_token1, + aux_sym_flag_token2, + aux_sym_flag_token3, + aux_sym_flag_token4, + aux_sym_flag_token5, + aux_sym_flag_token6, + aux_sym_flag_token7, + aux_sym_flag_token8, + aux_sym_flag_token9, + aux_sym_flag_token10, + aux_sym_flag_token11, + aux_sym_flag_token12, + [82] = 3, + ACTIONS(30), 1, + sym_id, + STATE(6), 2, + sym_flag, + aux_sym_line_repeat1, + ACTIONS(26), 12, + aux_sym_flag_token1, + aux_sym_flag_token2, + aux_sym_flag_token3, + aux_sym_flag_token4, + aux_sym_flag_token5, + aux_sym_flag_token6, + aux_sym_flag_token7, + aux_sym_flag_token8, + aux_sym_flag_token9, + aux_sym_flag_token10, + aux_sym_flag_token11, + aux_sym_flag_token12, + [104] = 3, + ACTIONS(35), 1, + sym_id, + STATE(6), 2, + sym_flag, + aux_sym_line_repeat1, + ACTIONS(32), 12, + aux_sym_flag_token1, + aux_sym_flag_token2, + aux_sym_flag_token3, + aux_sym_flag_token4, + aux_sym_flag_token5, + aux_sym_flag_token6, + aux_sym_flag_token7, + aux_sym_flag_token8, + aux_sym_flag_token9, + aux_sym_flag_token10, + aux_sym_flag_token11, + aux_sym_flag_token12, + [126] = 2, + ACTIONS(39), 6, + anon_sym_p, + anon_sym_watch, + anon_sym_w, + anon_sym_a, + anon_sym_d, + anon_sym_u, + ACTIONS(37), 8, + ts_builtin_sym_end, + anon_sym_pick, + anon_sym_watched, + anon_sym_wd, + anon_sym_add, + anon_sym_drop, + anon_sym_url, + sym_comment, + [145] = 2, + ACTIONS(43), 6, + anon_sym_p, + anon_sym_watch, + anon_sym_w, + anon_sym_a, + anon_sym_d, + anon_sym_u, + ACTIONS(41), 8, + ts_builtin_sym_end, + anon_sym_pick, + anon_sym_watched, + anon_sym_wd, + anon_sym_add, + anon_sym_drop, + anon_sym_url, + sym_comment, + [164] = 2, + ACTIONS(47), 1, + sym_id, + ACTIONS(45), 12, + aux_sym_flag_token1, + aux_sym_flag_token2, + aux_sym_flag_token3, + aux_sym_flag_token4, + aux_sym_flag_token5, + aux_sym_flag_token6, + aux_sym_flag_token7, + aux_sym_flag_token8, + aux_sym_flag_token9, + aux_sym_flag_token10, + aux_sym_flag_token11, + aux_sym_flag_token12, + [182] = 2, + ACTIONS(51), 1, + sym_id, + ACTIONS(49), 12, + aux_sym_flag_token1, + aux_sym_flag_token2, + aux_sym_flag_token3, + aux_sym_flag_token4, + aux_sym_flag_token5, + aux_sym_flag_token6, + aux_sym_flag_token7, + aux_sym_flag_token8, + aux_sym_flag_token9, + aux_sym_flag_token10, + aux_sym_flag_token11, + aux_sym_flag_token12, [200] = 3, - ACTIONS (57), - 1, - sym_quote, - STATE (19), - 1, - sym_title, - STATE (38), - 1, - sym__q, + ACTIONS(53), 1, + sym_quote, + STATE(12), 1, + sym_title, + STATE(38), 1, + sym__q, [210] = 3, - ACTIONS (57), - 1, - sym_quote, - STATE (18), - 1, - sym_title, - STATE (38), - 1, - sym__q, + ACTIONS(55), 1, + sym_quote, + STATE(14), 1, + sym_date, + STATE(24), 1, + sym__q, [220] = 3, - ACTIONS (59), - 1, - sym_quote, - STATE (11), - 1, - sym_author, - STATE (28), - 1, - sym__q, + ACTIONS(53), 1, + sym_quote, + STATE(15), 1, + sym_title, + STATE(38), 1, + sym__q, [230] = 3, - ACTIONS (61), - 1, - sym_quote, - STATE (31), - 1, - sym__q, - STATE (36), - 1, - sym_url, + ACTIONS(57), 1, + sym_quote, + STATE(16), 1, + sym_author, + STATE(23), 1, + sym__q, [240] = 3, - ACTIONS (53), - 1, - sym_quote, - STATE (12), - 1, - sym__q, - STATE (16), - 1, - sym_duration, + ACTIONS(55), 1, + sym_quote, + STATE(17), 1, + sym_date, + STATE(24), 1, + sym__q, [250] = 3, - ACTIONS (63), - 1, - sym_quote, - STATE (21), - 1, - sym_date, - STATE (33), - 1, - sym__q, + ACTIONS(59), 1, + sym_quote, + STATE(18), 1, + sym_duration, + STATE(19), 1, + sym__q, [260] = 3, - ACTIONS (63), - 1, - sym_quote, - STATE (15), - 1, - sym_date, - STATE (33), - 1, - sym__q, + ACTIONS(57), 1, + sym_quote, + STATE(20), 1, + sym_author, + STATE(23), 1, + sym__q, [270] = 3, - ACTIONS (61), - 1, - sym_quote, - STATE (30), - 1, - sym_url, - STATE (31), - 1, - sym__q, - [280] = 3, - ACTIONS (59), - 1, - sym_quote, - STATE (17), - 1, - sym_author, - STATE (28), - 1, - sym__q, - [290] = 2, - ACTIONS (65), - 1, - sym_quote, - STATE (29), - 1, - sym__q, - [297] = 2, - ACTIONS (67), - 1, - sym_quote, - STATE (32), - 1, - sym__q, - [304] = 2, - ACTIONS (69), - 1, - sym_quote, - STATE (27), - 1, - sym__q, - [311] = 2, - ACTIONS (71), - 1, - sym_quote, - STATE (35), - 1, - sym__q, - [318] = 2, - ACTIONS (73), - 1, - sym_quote, - STATE (37), - 1, - sym__q, - [325] = 1, - ACTIONS (75), - 1, - sym_quote, - [329] = 1, - ACTIONS (77), - 1, - aux_sym_title_token1, - [333] = 1, - ACTIONS (79), - 1, - sym_quote, - [337] = 1, - ACTIONS (81), - 1, - anon_sym_LF, - [341] = 1, - ACTIONS (83), - 1, - aux_sym_title_token1, - [345] = 1, - ACTIONS (85), - 1, - sym_quote, - [349] = 1, - ACTIONS (87), - 1, - aux_sym_date_token1, - [353] = 1, - ACTIONS (89), - 1, - ts_builtin_sym_end, - [357] = 1, - ACTIONS (91), - 1, - sym_quote, - [361] = 1, - ACTIONS (93), - 1, - anon_sym_LF, - [365] = 1, - ACTIONS (95), - 1, - anon_sym_LF, - [369] = 1, - ACTIONS (97), - 1, - aux_sym_title_token1, + ACTIONS(61), 1, + sym_quote, + STATE(29), 1, + sym__q, + STATE(34), 1, + sym_url, + [280] = 1, + ACTIONS(63), 3, + anon_sym_LBRACKNoduration_RBRACK, + aux_sym_duration_token1, + aux_sym_duration_token2, + [286] = 3, + ACTIONS(59), 1, + sym_quote, + STATE(19), 1, + sym__q, + STATE(21), 1, + sym_duration, + [296] = 3, + ACTIONS(61), 1, + sym_quote, + STATE(29), 1, + sym__q, + STATE(36), 1, + sym_url, + [306] = 2, + ACTIONS(65), 1, + sym_quote, + STATE(33), 1, + sym__q, + [313] = 1, + ACTIONS(67), 2, + aux_sym_title_token1, + anon_sym_LBRACKNoauthor_RBRACK, + [318] = 1, + ACTIONS(69), 2, + anon_sym_LBRACKNoreleasedate_RBRACK, + aux_sym_date_token1, + [323] = 2, + ACTIONS(71), 1, + sym_quote, + STATE(31), 1, + sym__q, + [330] = 2, + ACTIONS(73), 1, + sym_quote, + STATE(35), 1, + sym__q, + [337] = 2, + ACTIONS(75), 1, + sym_quote, + STATE(32), 1, + sym__q, + [344] = 2, + ACTIONS(77), 1, + sym_quote, + STATE(37), 1, + sym__q, + [351] = 1, + ACTIONS(79), 1, + aux_sym_title_token1, + [355] = 1, + ACTIONS(81), 1, + ts_builtin_sym_end, + [359] = 1, + ACTIONS(83), 1, + sym_quote, + [363] = 1, + ACTIONS(85), 1, + sym_quote, + [367] = 1, + ACTIONS(87), 1, + sym_quote, + [371] = 1, + ACTIONS(89), 1, + anon_sym_LF, + [375] = 1, + ACTIONS(91), 1, + sym_quote, + [379] = 1, + ACTIONS(93), 1, + anon_sym_LF, + [383] = 1, + ACTIONS(95), 1, + anon_sym_LF, + [387] = 1, + ACTIONS(97), 1, + aux_sym_title_token1, }; static const uint32_t ts_small_parse_table_map[] = { - [SMALL_STATE (2)] = 0, [SMALL_STATE (3)] = 22, [SMALL_STATE (4)] = 44, - [SMALL_STATE (5)] = 66, [SMALL_STATE (6)] = 84, [SMALL_STATE (7)] = 110, - [SMALL_STATE (8)] = 128, [SMALL_STATE (9)] = 154, [SMALL_STATE (10)] = 169, - [SMALL_STATE (11)] = 184, [SMALL_STATE (12)] = 194, [SMALL_STATE (13)] = 200, - [SMALL_STATE (14)] = 210, [SMALL_STATE (15)] = 220, [SMALL_STATE (16)] = 230, - [SMALL_STATE (17)] = 240, [SMALL_STATE (18)] = 250, [SMALL_STATE (19)] = 260, - [SMALL_STATE (20)] = 270, [SMALL_STATE (21)] = 280, [SMALL_STATE (22)] = 290, - [SMALL_STATE (23)] = 297, [SMALL_STATE (24)] = 304, [SMALL_STATE (25)] = 311, - [SMALL_STATE (26)] = 318, [SMALL_STATE (27)] = 325, [SMALL_STATE (28)] = 329, - [SMALL_STATE (29)] = 333, [SMALL_STATE (30)] = 337, [SMALL_STATE (31)] = 341, - [SMALL_STATE (32)] = 345, [SMALL_STATE (33)] = 349, [SMALL_STATE (34)] = 353, - [SMALL_STATE (35)] = 357, [SMALL_STATE (36)] = 361, [SMALL_STATE (37)] = 365, - [SMALL_STATE (38)] = 369, + [SMALL_STATE(2)] = 0, + [SMALL_STATE(3)] = 30, + [SMALL_STATE(4)] = 60, + [SMALL_STATE(5)] = 82, + [SMALL_STATE(6)] = 104, + [SMALL_STATE(7)] = 126, + [SMALL_STATE(8)] = 145, + [SMALL_STATE(9)] = 164, + [SMALL_STATE(10)] = 182, + [SMALL_STATE(11)] = 200, + [SMALL_STATE(12)] = 210, + [SMALL_STATE(13)] = 220, + [SMALL_STATE(14)] = 230, + [SMALL_STATE(15)] = 240, + [SMALL_STATE(16)] = 250, + [SMALL_STATE(17)] = 260, + [SMALL_STATE(18)] = 270, + [SMALL_STATE(19)] = 280, + [SMALL_STATE(20)] = 286, + [SMALL_STATE(21)] = 296, + [SMALL_STATE(22)] = 306, + [SMALL_STATE(23)] = 313, + [SMALL_STATE(24)] = 318, + [SMALL_STATE(25)] = 323, + [SMALL_STATE(26)] = 330, + [SMALL_STATE(27)] = 337, + [SMALL_STATE(28)] = 344, + [SMALL_STATE(29)] = 351, + [SMALL_STATE(30)] = 355, + [SMALL_STATE(31)] = 359, + [SMALL_STATE(32)] = 363, + [SMALL_STATE(33)] = 367, + [SMALL_STATE(34)] = 371, + [SMALL_STATE(35)] = 375, + [SMALL_STATE(36)] = 379, + [SMALL_STATE(37)] = 383, + [SMALL_STATE(38)] = 387, }; static const TSParseActionEntry ts_parse_actions[] = { - [0] = { .entry = { .count = 0, .reusable = false } }, - [1] = { .entry = { .count = 1, .reusable = false } }, - RECOVER (), - [3] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_source_file, 0), - [5] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (5), - [7] = { .entry = { .count = 1, .reusable = false } }, - SHIFT (5), - [9] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (6), - [11] = { .entry = { .count = 2, .reusable = false } }, - REDUCE (aux_sym_line_repeat1, 2), - SHIFT_REPEAT (7), - [14] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (aux_sym_line_repeat1, 2), - [16] = { .entry = { .count = 1, .reusable = false } }, - SHIFT (7), - [18] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (13), - [20] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (14), - [22] = { .entry = { .count = 1, .reusable = false } }, - REDUCE (sym_command, 1), - [24] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_command, 1), - [26] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_source_file, 1), - [28] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (8), - [30] = { .entry = { .count = 1, .reusable = false } }, - REDUCE (sym_flag, 1), - [32] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_flag, 1), - [34] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (aux_sym_source_file_repeat1, 2), - [36] = { .entry = { .count = 2, .reusable = true } }, - REDUCE (aux_sym_source_file_repeat1, 2), - SHIFT_REPEAT (5), - [39] = { .entry = { .count = 2, .reusable = false } }, - REDUCE (aux_sym_source_file_repeat1, 2), - SHIFT_REPEAT (5), - [42] = { .entry = { .count = 2, .reusable = true } }, - REDUCE (aux_sym_source_file_repeat1, 2), - SHIFT_REPEAT (8), - [45] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_line, 9), - [47] = { .entry = { .count = 1, .reusable = false } }, - REDUCE (sym_line, 9), - [49] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_line, 8), - [51] = { .entry = { .count = 1, .reusable = false } }, - REDUCE (sym_line, 8), - [53] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (12), - [55] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (25), - [57] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (38), - [59] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (28), - [61] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (31), - [63] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (33), - [65] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (29), - [67] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (32), - [69] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (27), - [71] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (35), - [73] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (37), - [75] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_title, 3), - [77] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (23), - [79] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_date, 3), - [81] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (10), - [83] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (26), - [85] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_author, 3), - [87] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (22), - [89] = { .entry = { .count = 1, .reusable = true } }, - ACCEPT_INPUT (), - [91] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_duration, 3), - [93] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (9), - [95] = { .entry = { .count = 1, .reusable = true } }, - REDUCE (sym_url, 3), - [97] = { .entry = { .count = 1, .reusable = true } }, - SHIFT (24), + [0] = {.entry = {.count = 0, .reusable = false}}, + [1] = {.entry = {.count = 1, .reusable = false}}, RECOVER(), + [3] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 0, 0, 0), + [5] = {.entry = {.count = 1, .reusable = true}}, SHIFT(10), + [7] = {.entry = {.count = 1, .reusable = false}}, SHIFT(10), + [9] = {.entry = {.count = 1, .reusable = true}}, SHIFT(3), + [11] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_source_file_repeat1, 2, 0, 0), + [13] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_file_repeat1, 2, 0, 0), SHIFT_REPEAT(10), + [16] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2, 0, 0), SHIFT_REPEAT(10), + [19] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_source_file_repeat1, 2, 0, 0), SHIFT_REPEAT(2), + [22] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 1, 0, 0), + [24] = {.entry = {.count = 1, .reusable = true}}, SHIFT(2), + [26] = {.entry = {.count = 1, .reusable = false}}, SHIFT(9), + [28] = {.entry = {.count = 1, .reusable = true}}, SHIFT(11), + [30] = {.entry = {.count = 1, .reusable = true}}, SHIFT(13), + [32] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_line_repeat1, 2, 0, 0), SHIFT_REPEAT(9), + [35] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_line_repeat1, 2, 0, 0), + [37] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_line, 8, 0, 0), + [39] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_line, 8, 0, 0), + [41] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_line, 9, 0, 0), + [43] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_line, 9, 0, 0), + [45] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_flag, 1, 0, 0), + [47] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_flag, 1, 0, 0), + [49] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_command, 1, 0, 0), + [51] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_command, 1, 0, 0), + [53] = {.entry = {.count = 1, .reusable = true}}, SHIFT(38), + [55] = {.entry = {.count = 1, .reusable = true}}, SHIFT(24), + [57] = {.entry = {.count = 1, .reusable = true}}, SHIFT(23), + [59] = {.entry = {.count = 1, .reusable = true}}, SHIFT(19), + [61] = {.entry = {.count = 1, .reusable = true}}, SHIFT(29), + [63] = {.entry = {.count = 1, .reusable = true}}, SHIFT(26), + [65] = {.entry = {.count = 1, .reusable = true}}, SHIFT(33), + [67] = {.entry = {.count = 1, .reusable = false}}, SHIFT(25), + [69] = {.entry = {.count = 1, .reusable = true}}, SHIFT(27), + [71] = {.entry = {.count = 1, .reusable = true}}, SHIFT(31), + [73] = {.entry = {.count = 1, .reusable = true}}, SHIFT(35), + [75] = {.entry = {.count = 1, .reusable = true}}, SHIFT(32), + [77] = {.entry = {.count = 1, .reusable = true}}, SHIFT(37), + [79] = {.entry = {.count = 1, .reusable = true}}, SHIFT(28), + [81] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), + [83] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_author, 3, 0, 0), + [85] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_date, 3, 0, 0), + [87] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_title, 3, 0, 0), + [89] = {.entry = {.count = 1, .reusable = true}}, SHIFT(7), + [91] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_duration, 3, 0, 0), + [93] = {.entry = {.count = 1, .reusable = true}}, SHIFT(8), + [95] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_url, 3, 0, 0), + [97] = {.entry = {.count = 1, .reusable = true}}, SHIFT(22), }; #ifdef __cplusplus -extern "C" -{ +extern "C" { #endif -#ifdef _WIN32 -#define extern __declspec (dllexport) +#ifdef TREE_SITTER_HIDE_SYMBOLS +#define TS_PUBLIC +#elif defined(_WIN32) +#define TS_PUBLIC __declspec(dllexport) +#else +#define TS_PUBLIC __attribute__((visibility("default"))) #endif - extern const TSLanguage * - tree_sitter_yts (void) - { - static const TSLanguage language = { - .version = LANGUAGE_VERSION, - .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, - .production_id_count = PRODUCTION_ID_COUNT, - .field_count = FIELD_COUNT, - .max_alias_sequence_length = MAX_ALIAS_SEQUENCE_LENGTH, - .parse_table = &ts_parse_table[0][0], - .small_parse_table = ts_small_parse_table, - .small_parse_table_map = ts_small_parse_table_map, - .parse_actions = ts_parse_actions, - .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 = &ts_alias_sequences[0][0], - .lex_modes = ts_lex_modes, - .lex_fn = ts_lex, - .primary_state_ids = ts_primary_state_ids, - }; - return &language; - } +TS_PUBLIC const TSLanguage *tree_sitter_yts(void) { + static const TSLanguage language = { + .version = LANGUAGE_VERSION, + .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, + .production_id_count = PRODUCTION_ID_COUNT, + .field_count = FIELD_COUNT, + .max_alias_sequence_length = MAX_ALIAS_SEQUENCE_LENGTH, + .parse_table = &ts_parse_table[0][0], + .small_parse_table = ts_small_parse_table, + .small_parse_table_map = ts_small_parse_table_map, + .parse_actions = ts_parse_actions, + .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 = &ts_alias_sequences[0][0], + .lex_modes = ts_lex_modes, + .lex_fn = ts_lex, + .primary_state_ids = ts_primary_state_ids, + }; + return &language; +} #ifdef __cplusplus } #endif |