diff --git a/grammar.js b/grammar.js index 901bdce..33e6e6c 100644 --- a/grammar.js +++ b/grammar.js @@ -51,6 +51,7 @@ module.exports = grammar({ $.if_expression, $.while_expression, $.for_expression, + $.break_expression, ), nil_literal: (_) => "nil", @@ -204,6 +205,8 @@ module.exports = grammar({ "do", field("body", $._expr), ), + + break_expression: (_) => "break", } }); diff --git a/src/grammar.json b/src/grammar.json index 7fbfe07..5dd95a8 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -69,6 +69,10 @@ { "type": "SYMBOL", "name": "for_expression" + }, + { + "type": "SYMBOL", + "name": "break_expression" } ] }, @@ -937,6 +941,10 @@ } } ] + }, + "break_expression": { + "type": "STRING", + "value": "break" } }, "extras": [ diff --git a/src/node-types.json b/src/node-types.json index be83076..26ead1a 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -23,6 +23,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -93,6 +97,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -197,6 +205,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -291,6 +303,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -367,6 +383,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -447,6 +467,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -523,6 +547,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -593,6 +621,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -673,6 +705,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -753,6 +789,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -839,6 +879,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -909,6 +953,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -979,6 +1027,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1065,6 +1117,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1185,6 +1241,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1260,6 +1320,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1350,6 +1414,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1436,6 +1504,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1506,6 +1578,10 @@ "type": "binary_expression", "named": true }, + { + "type": "break_expression", + "named": true + }, { "type": "for_expression", "named": true @@ -1598,6 +1674,10 @@ "type": "]", "named": false }, + { + "type": "break_expression", + "named": true + }, { "type": "do", "named": false diff --git a/src/parser.c b/src/parser.c index 05e89a2..3b69030 100644 --- a/src/parser.c +++ b/src/parser.c @@ -8,9 +8,9 @@ #define LANGUAGE_VERSION 13 #define STATE_COUNT 84 #define LARGE_STATE_COUNT 2 -#define SYMBOL_COUNT 57 +#define SYMBOL_COUNT 58 #define ALIAS_COUNT 0 -#define TOKEN_COUNT 37 +#define TOKEN_COUNT 38 #define EXTERNAL_TOKEN_COUNT 0 #define FIELD_COUNT 19 #define MAX_ALIAS_SEQUENCE_LENGTH 8 @@ -53,26 +53,27 @@ enum { anon_sym_do = 34, anon_sym_for = 35, anon_sym_to = 36, - sym_source_file = 37, - sym__expr = 38, - sym_string_literal = 39, - sym__lvalue = 40, - sym_record_value = 41, - sym_array_value = 42, - sym_function_call = 43, - sym_unary_expression = 44, - sym_binary_expression = 45, - sym_sequence_expression = 46, - sym_array_expression = 47, - sym_record_expression = 48, - sym_assignment_expression = 49, - sym_if_expression = 50, - sym_while_expression = 51, - sym_for_expression = 52, - aux_sym_string_literal_repeat1 = 53, - aux_sym_function_call_repeat1 = 54, - aux_sym_sequence_expression_repeat1 = 55, - aux_sym_record_expression_repeat1 = 56, + sym_break_expression = 37, + sym_source_file = 38, + sym__expr = 39, + sym_string_literal = 40, + sym__lvalue = 41, + sym_record_value = 42, + sym_array_value = 43, + sym_function_call = 44, + sym_unary_expression = 45, + sym_binary_expression = 46, + sym_sequence_expression = 47, + sym_array_expression = 48, + sym_record_expression = 49, + sym_assignment_expression = 50, + sym_if_expression = 51, + sym_while_expression = 52, + sym_for_expression = 53, + aux_sym_string_literal_repeat1 = 54, + aux_sym_function_call_repeat1 = 55, + aux_sym_sequence_expression_repeat1 = 56, + aux_sym_record_expression_repeat1 = 57, }; static const char * const ts_symbol_names[] = { @@ -113,6 +114,7 @@ static const char * const ts_symbol_names[] = { [anon_sym_do] = "do", [anon_sym_for] = "for", [anon_sym_to] = "to", + [sym_break_expression] = "break_expression", [sym_source_file] = "source_file", [sym__expr] = "_expr", [sym_string_literal] = "string_literal", @@ -173,6 +175,7 @@ static const TSSymbol ts_symbol_map[] = { [anon_sym_do] = anon_sym_do, [anon_sym_for] = anon_sym_for, [anon_sym_to] = anon_sym_to, + [sym_break_expression] = sym_break_expression, [sym_source_file] = sym_source_file, [sym__expr] = sym__expr, [sym_string_literal] = sym_string_literal, @@ -344,6 +347,10 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = false, }, + [sym_break_expression] = { + .visible = true, + .named = true, + }, [sym_source_file] = { .visible = true, .named = true, @@ -826,96 +833,112 @@ static bool ts_lex_keywords(TSLexer *lexer, TSStateId state) { eof = lexer->eof(lexer); switch (state) { case 0: - if (lookahead == 'd') ADVANCE(1); - if (lookahead == 'e') ADVANCE(2); - if (lookahead == 'f') ADVANCE(3); - if (lookahead == 'i') ADVANCE(4); - if (lookahead == 'n') ADVANCE(5); - if (lookahead == 'o') ADVANCE(6); - if (lookahead == 't') ADVANCE(7); - if (lookahead == 'w') ADVANCE(8); + if (lookahead == 'b') ADVANCE(1); + if (lookahead == 'd') ADVANCE(2); + if (lookahead == 'e') ADVANCE(3); + if (lookahead == 'f') ADVANCE(4); + if (lookahead == 'i') ADVANCE(5); + if (lookahead == 'n') ADVANCE(6); + if (lookahead == 'o') ADVANCE(7); + if (lookahead == 't') ADVANCE(8); + if (lookahead == 'w') ADVANCE(9); if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' || lookahead == ' ') SKIP(0) END_STATE(); case 1: - if (lookahead == 'o') ADVANCE(9); + if (lookahead == 'r') ADVANCE(10); END_STATE(); case 2: - if (lookahead == 'l') ADVANCE(10); - END_STATE(); - case 3: if (lookahead == 'o') ADVANCE(11); END_STATE(); + case 3: + if (lookahead == 'l') ADVANCE(12); + END_STATE(); case 4: - if (lookahead == 'f') ADVANCE(12); + if (lookahead == 'o') ADVANCE(13); END_STATE(); case 5: - if (lookahead == 'i') ADVANCE(13); - END_STATE(); - case 6: if (lookahead == 'f') ADVANCE(14); END_STATE(); + case 6: + if (lookahead == 'i') ADVANCE(15); + END_STATE(); case 7: - if (lookahead == 'h') ADVANCE(15); - if (lookahead == 'o') ADVANCE(16); + if (lookahead == 'f') ADVANCE(16); END_STATE(); case 8: if (lookahead == 'h') ADVANCE(17); + if (lookahead == 'o') ADVANCE(18); END_STATE(); case 9: - ACCEPT_TOKEN(anon_sym_do); + if (lookahead == 'h') ADVANCE(19); END_STATE(); case 10: - if (lookahead == 's') ADVANCE(18); + if (lookahead == 'e') ADVANCE(20); END_STATE(); case 11: - if (lookahead == 'r') ADVANCE(19); + ACCEPT_TOKEN(anon_sym_do); END_STATE(); case 12: - ACCEPT_TOKEN(anon_sym_if); + if (lookahead == 's') ADVANCE(21); END_STATE(); case 13: - if (lookahead == 'l') ADVANCE(20); + if (lookahead == 'r') ADVANCE(22); END_STATE(); case 14: - ACCEPT_TOKEN(anon_sym_of); + ACCEPT_TOKEN(anon_sym_if); END_STATE(); case 15: - if (lookahead == 'e') ADVANCE(21); + if (lookahead == 'l') ADVANCE(23); END_STATE(); case 16: - ACCEPT_TOKEN(anon_sym_to); + ACCEPT_TOKEN(anon_sym_of); END_STATE(); case 17: - if (lookahead == 'i') ADVANCE(22); + if (lookahead == 'e') ADVANCE(24); END_STATE(); case 18: - if (lookahead == 'e') ADVANCE(23); + ACCEPT_TOKEN(anon_sym_to); END_STATE(); case 19: - ACCEPT_TOKEN(anon_sym_for); + if (lookahead == 'i') ADVANCE(25); END_STATE(); case 20: - ACCEPT_TOKEN(sym_nil_literal); + if (lookahead == 'a') ADVANCE(26); END_STATE(); case 21: - if (lookahead == 'n') ADVANCE(24); + if (lookahead == 'e') ADVANCE(27); END_STATE(); case 22: - if (lookahead == 'l') ADVANCE(25); + ACCEPT_TOKEN(anon_sym_for); END_STATE(); case 23: - ACCEPT_TOKEN(anon_sym_else); + ACCEPT_TOKEN(sym_nil_literal); END_STATE(); case 24: - ACCEPT_TOKEN(anon_sym_then); + if (lookahead == 'n') ADVANCE(28); END_STATE(); case 25: - if (lookahead == 'e') ADVANCE(26); + if (lookahead == 'l') ADVANCE(29); END_STATE(); case 26: + if (lookahead == 'k') ADVANCE(30); + END_STATE(); + case 27: + ACCEPT_TOKEN(anon_sym_else); + END_STATE(); + case 28: + ACCEPT_TOKEN(anon_sym_then); + END_STATE(); + case 29: + if (lookahead == 'e') ADVANCE(31); + END_STATE(); + case 30: + ACCEPT_TOKEN(sym_break_expression); + END_STATE(); + case 31: ACCEPT_TOKEN(anon_sym_while); END_STATE(); default: @@ -929,18 +952,18 @@ static const TSLexMode ts_lex_modes[STATE_COUNT] = { [2] = {.lex_state = 9}, [3] = {.lex_state = 0}, [4] = {.lex_state = 0}, - [5] = {.lex_state = 9}, - [6] = {.lex_state = 9}, - [7] = {.lex_state = 9}, + [5] = {.lex_state = 0}, + [6] = {.lex_state = 0}, + [7] = {.lex_state = 0}, [8] = {.lex_state = 0}, [9] = {.lex_state = 0}, [10] = {.lex_state = 0}, [11] = {.lex_state = 0}, - [12] = {.lex_state = 0}, - [13] = {.lex_state = 0}, + [12] = {.lex_state = 9}, + [13] = {.lex_state = 9}, [14] = {.lex_state = 0}, [15] = {.lex_state = 0}, - [16] = {.lex_state = 0}, + [16] = {.lex_state = 9}, [17] = {.lex_state = 0}, [18] = {.lex_state = 0}, [19] = {.lex_state = 0}, @@ -983,8 +1006,8 @@ static const TSLexMode ts_lex_modes[STATE_COUNT] = { [56] = {.lex_state = 0}, [57] = {.lex_state = 0}, [58] = {.lex_state = 0}, - [59] = {.lex_state = 0}, - [60] = {.lex_state = 9}, + [59] = {.lex_state = 9}, + [60] = {.lex_state = 0}, [61] = {.lex_state = 9}, [62] = {.lex_state = 0}, [63] = {.lex_state = 0}, @@ -1000,11 +1023,11 @@ static const TSLexMode ts_lex_modes[STATE_COUNT] = { [73] = {.lex_state = 0}, [74] = {.lex_state = 0}, [75] = {.lex_state = 9}, - [76] = {.lex_state = 9}, + [76] = {.lex_state = 0}, [77] = {.lex_state = 0}, [78] = {.lex_state = 9}, [79] = {.lex_state = 0}, - [80] = {.lex_state = 0}, + [80] = {.lex_state = 9}, [81] = {.lex_state = 9}, [82] = {.lex_state = 0}, [83] = {.lex_state = 9}, @@ -1048,24 +1071,25 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_do] = ACTIONS(1), [anon_sym_for] = ACTIONS(1), [anon_sym_to] = ACTIONS(1), + [sym_break_expression] = ACTIONS(1), }, [1] = { - [sym_source_file] = STATE(79), - [sym__expr] = STATE(59), - [sym_string_literal] = STATE(59), - [sym__lvalue] = STATE(7), - [sym_record_value] = STATE(7), - [sym_array_value] = STATE(7), - [sym_function_call] = STATE(59), - [sym_unary_expression] = STATE(59), - [sym_binary_expression] = STATE(59), - [sym_sequence_expression] = STATE(59), - [sym_array_expression] = STATE(59), - [sym_record_expression] = STATE(59), - [sym_assignment_expression] = STATE(59), - [sym_if_expression] = STATE(59), - [sym_while_expression] = STATE(59), - [sym_for_expression] = STATE(59), + [sym_source_file] = STATE(82), + [sym__expr] = STATE(60), + [sym_string_literal] = STATE(60), + [sym__lvalue] = STATE(12), + [sym_record_value] = STATE(12), + [sym_array_value] = STATE(12), + [sym_function_call] = STATE(60), + [sym_unary_expression] = STATE(60), + [sym_binary_expression] = STATE(60), + [sym_sequence_expression] = STATE(60), + [sym_array_expression] = STATE(60), + [sym_record_expression] = STATE(60), + [sym_assignment_expression] = STATE(60), + [sym_if_expression] = STATE(60), + [sym_while_expression] = STATE(60), + [sym_for_expression] = STATE(60), [sym_identifier] = ACTIONS(3), [sym_nil_literal] = ACTIONS(5), [sym_integer_literal] = ACTIONS(5), @@ -1075,6 +1099,7 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_if] = ACTIONS(13), [anon_sym_while] = ACTIONS(15), [anon_sym_for] = ACTIONS(17), + [sym_break_expression] = ACTIONS(5), }, }; @@ -1129,10 +1154,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_for, ACTIONS(32), 1, anon_sym_RPAREN, - ACTIONS(30), 2, + ACTIONS(30), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, @@ -1149,7 +1175,7 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [86] = 11, + [87] = 11, ACTIONS(3), 1, sym_identifier, ACTIONS(7), 1, @@ -1166,167 +1192,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_for, ACTIONS(36), 1, anon_sym_RPAREN, - ACTIONS(34), 2, + ACTIONS(34), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(55), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [134] = 2, - ACTIONS(40), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(38), 23, - ts_builtin_sym_end, - anon_sym_DOT, - anon_sym_LBRACK, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_DASH, - anon_sym_STAR, - anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_COLON_EQ, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [164] = 2, - ACTIONS(44), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(42), 23, - ts_builtin_sym_end, - anon_sym_DOT, - anon_sym_LBRACK, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_DASH, - anon_sym_STAR, - anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_COLON_EQ, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [194] = 5, - ACTIONS(48), 1, - anon_sym_DOT, - ACTIONS(50), 1, - anon_sym_LBRACK, - ACTIONS(54), 1, - anon_sym_COLON_EQ, - ACTIONS(52), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(46), 20, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_DASH, - anon_sym_STAR, - anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [230] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(56), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(49), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [275] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(58), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, @@ -1343,6 +1213,150 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, + [136] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(38), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(52), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [182] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(40), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(58), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [228] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(42), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(59), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [274] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(44), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(64), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, [320] = 10, ACTIONS(3), 1, sym_identifier, @@ -1358,220 +1372,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_while, ACTIONS(17), 1, anon_sym_for, - ACTIONS(60), 2, + ACTIONS(46), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(58), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [365] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(62), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(64), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [410] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(64), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(40), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [455] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(66), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(31), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [500] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(68), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(65), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [545] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(70), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(62), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [590] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(72), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, @@ -1588,7 +1393,7 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [635] = 10, + [366] = 10, ACTIONS(3), 1, sym_identifier, ACTIONS(7), 1, @@ -1603,185 +1408,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_while, ACTIONS(17), 1, anon_sym_for, - ACTIONS(74), 2, + ACTIONS(48), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(60), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [680] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(76), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(33), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [725] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(78), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(61), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [770] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(80), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(34), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [815] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(82), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(51), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [860] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(84), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, @@ -1798,7 +1429,7 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [905] = 10, + [412] = 10, ACTIONS(3), 1, sym_identifier, ACTIONS(7), 1, @@ -1813,14 +1444,15 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_while, ACTIONS(17), 1, anon_sym_for, - ACTIONS(86), 2, + ACTIONS(50), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, - STATE(36), 12, + STATE(51), 12, sym__expr, sym_string_literal, sym_function_call, @@ -1833,7 +1465,66 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [950] = 10, + [458] = 5, + ACTIONS(54), 1, + anon_sym_DOT, + ACTIONS(56), 1, + anon_sym_LBRACK, + ACTIONS(60), 1, + anon_sym_COLON_EQ, + ACTIONS(58), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(52), 20, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [494] = 2, + ACTIONS(64), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(62), 23, + ts_builtin_sym_end, + anon_sym_DOT, + anon_sym_LBRACK, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_COLON_EQ, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [524] = 10, ACTIONS(3), 1, sym_identifier, ACTIONS(7), 1, @@ -1848,14 +1539,15 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_while, ACTIONS(17), 1, anon_sym_for, - ACTIONS(88), 2, + ACTIONS(66), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, - STATE(41), 12, + STATE(39), 12, sym__expr, sym_string_literal, sym_function_call, @@ -1868,7 +1560,7 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [995] = 10, + [570] = 10, ACTIONS(3), 1, sym_identifier, ACTIONS(7), 1, @@ -1883,150 +1575,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_while, ACTIONS(17), 1, anon_sym_for, - ACTIONS(90), 2, + ACTIONS(68), 3, sym_nil_literal, sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(50), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [1040] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(92), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(47), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [1085] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(94), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(48), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [1130] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(96), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, - sym__lvalue, - sym_record_value, - sym_array_value, - STATE(30), 12, - sym__expr, - sym_string_literal, - sym_function_call, - sym_unary_expression, - sym_binary_expression, - sym_sequence_expression, - sym_array_expression, - sym_record_expression, - sym_assignment_expression, - sym_if_expression, - sym_while_expression, - sym_for_expression, - [1175] = 10, - ACTIONS(3), 1, - sym_identifier, - ACTIONS(7), 1, - anon_sym_DQUOTE, - ACTIONS(9), 1, - anon_sym_LPAREN, - ACTIONS(11), 1, - anon_sym_DASH, - ACTIONS(13), 1, - anon_sym_if, - ACTIONS(15), 1, - anon_sym_while, - ACTIONS(17), 1, - anon_sym_for, - ACTIONS(98), 2, - sym_nil_literal, - sym_integer_literal, - STATE(7), 3, + sym_break_expression, + STATE(12), 3, sym__lvalue, sym_record_value, sym_array_value, @@ -2043,12 +1596,14 @@ static const uint16_t ts_small_parse_table[] = { sym_if_expression, sym_while_expression, sym_for_expression, - [1220] = 2, - ACTIONS(102), 2, + [616] = 2, + ACTIONS(72), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(100), 20, + ACTIONS(70), 23, ts_builtin_sym_end, + anon_sym_DOT, + anon_sym_LBRACK, anon_sym_RBRACK, anon_sym_COMMA, anon_sym_RPAREN, @@ -2064,30 +1619,501 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_PIPE, anon_sym_SEMI, anon_sym_RBRACE, + anon_sym_COLON_EQ, anon_sym_then, anon_sym_else, anon_sym_do, anon_sym_to, - [1247] = 7, + [646] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(74), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(36), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [692] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(76), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(30), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [738] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(78), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(55), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [784] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(80), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(44), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [830] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(82), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(61), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [876] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(84), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(50), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [922] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(86), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(35), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [968] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(88), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(47), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1014] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(90), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(46), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1060] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(92), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(31), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1106] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(94), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(48), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1152] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(96), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(65), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1198] = 10, + ACTIONS(3), 1, + sym_identifier, + ACTIONS(7), 1, + anon_sym_DQUOTE, + ACTIONS(9), 1, + anon_sym_LPAREN, + ACTIONS(11), 1, + anon_sym_DASH, + ACTIONS(13), 1, + anon_sym_if, + ACTIONS(15), 1, + anon_sym_while, + ACTIONS(17), 1, + anon_sym_for, + ACTIONS(98), 3, + sym_nil_literal, + sym_integer_literal, + sym_break_expression, + STATE(12), 3, + sym__lvalue, + sym_record_value, + sym_array_value, + STATE(62), 12, + sym__expr, + sym_string_literal, + sym_function_call, + sym_unary_expression, + sym_binary_expression, + sym_sequence_expression, + sym_array_expression, + sym_record_expression, + sym_assignment_expression, + sym_if_expression, + sym_while_expression, + sym_for_expression, + [1244] = 8, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(116), 1, - anon_sym_PIPE, - ACTIONS(106), 2, + anon_sym_else, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - ACTIONS(104), 10, + ACTIONS(100), 9, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2095,10 +2121,37 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_SEMI, anon_sym_RBRACE, anon_sym_then, + anon_sym_do, + anon_sym_to, + [1283] = 5, + ACTIONS(102), 2, + anon_sym_DASH, + anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, + ACTIONS(108), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(106), 4, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + ACTIONS(116), 12, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, anon_sym_else, anon_sym_do, anon_sym_to, - [1284] = 2, + [1316] = 2, ACTIONS(120), 2, anon_sym_LT, anon_sym_GT, @@ -2123,67 +2176,32 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1311] = 7, - ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(116), 1, - anon_sym_PIPE, - ACTIONS(106), 2, - anon_sym_DASH, - anon_sym_PLUS, - ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, + [1343] = 2, + ACTIONS(124), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - ACTIONS(122), 10, + ACTIONS(122), 20, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, anon_sym_SEMI, anon_sym_RBRACE, anon_sym_then, anon_sym_else, anon_sym_do, anon_sym_to, - [1348] = 7, - ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(116), 1, - anon_sym_PIPE, - ACTIONS(106), 2, - anon_sym_DASH, - anon_sym_PLUS, - ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(110), 4, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - ACTIONS(124), 10, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [1385] = 2, + [1370] = 2, ACTIONS(128), 2, anon_sym_LT, anon_sym_GT, @@ -2208,14 +2226,14 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1412] = 3, - ACTIONS(108), 2, + [1397] = 3, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(132), 2, + ACTIONS(130), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(130), 18, + ACTIONS(116), 18, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2234,7 +2252,37 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1441] = 2, + [1426] = 7, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, + ACTIONS(102), 2, + anon_sym_DASH, + anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, + ACTIONS(108), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(106), 4, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + ACTIONS(132), 10, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1463] = 2, ACTIONS(136), 2, anon_sym_LT, anon_sym_GT, @@ -2259,7 +2307,7 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1468] = 2, + [1490] = 2, ACTIONS(140), 2, anon_sym_LT, anon_sym_GT, @@ -2284,51 +2332,26 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1495] = 2, - ACTIONS(144), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(142), 20, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, + [1517] = 7, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, + ACTIONS(102), 2, anon_sym_DASH, + anon_sym_PLUS, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [1522] = 7, - ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(116), 1, - anon_sym_PIPE, - ACTIONS(106), 2, - anon_sym_DASH, - anon_sym_PLUS, ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - ACTIONS(146), 10, + ACTIONS(142), 10, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2339,11 +2362,11 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1559] = 2, - ACTIONS(132), 2, + [1554] = 2, + ACTIONS(146), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(130), 20, + ACTIONS(144), 20, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2364,7 +2387,7 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1586] = 2, + [1581] = 2, ACTIONS(150), 2, anon_sym_LT, anon_sym_GT, @@ -2389,7 +2412,7 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1613] = 2, + [1608] = 2, ACTIONS(154), 2, anon_sym_LT, anon_sym_GT, @@ -2414,7 +2437,7 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1640] = 2, + [1635] = 2, ACTIONS(158), 2, anon_sym_LT, anon_sym_GT, @@ -2439,76 +2462,53 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1667] = 2, - ACTIONS(162), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(160), 20, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, + [1662] = 7, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, + ACTIONS(102), 2, anon_sym_DASH, + anon_sym_PLUS, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [1694] = 2, - ACTIONS(166), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(164), 20, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_DASH, - anon_sym_STAR, - anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [1721] = 5, - ACTIONS(106), 2, - anon_sym_DASH, - anon_sym_PLUS, ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - ACTIONS(130), 12, + ACTIONS(160), 10, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, anon_sym_RPAREN, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1699] = 2, + ACTIONS(164), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(162), 20, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, anon_sym_AMP, anon_sym_PIPE, anon_sym_SEMI, @@ -2517,24 +2517,76 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1754] = 6, - ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(106), 2, + [1726] = 4, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, + ACTIONS(130), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(116), 16, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1757] = 2, + ACTIONS(130), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(116), 20, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1784] = 6, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(102), 2, + anon_sym_DASH, + anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - ACTIONS(130), 11, + ACTIONS(116), 11, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2546,26 +2598,76 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1789] = 7, - ACTIONS(114), 1, + [1819] = 2, + ACTIONS(168), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(166), 20, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, anon_sym_AMP, - ACTIONS(116), 1, anon_sym_PIPE, - ACTIONS(106), 2, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1846] = 2, + ACTIONS(172), 2, + anon_sym_LT, + anon_sym_GT, + ACTIONS(170), 20, + ts_builtin_sym_end, + anon_sym_RBRACK, + anon_sym_COMMA, + anon_sym_RPAREN, + anon_sym_DASH, + anon_sym_STAR, + anon_sym_SLASH, + anon_sym_PLUS, + anon_sym_GT_EQ, + anon_sym_LT_EQ, + anon_sym_EQ, + anon_sym_LT_GT, + anon_sym_AMP, + anon_sym_PIPE, + anon_sym_SEMI, + anon_sym_RBRACE, + anon_sym_then, + anon_sym_else, + anon_sym_do, + anon_sym_to, + [1873] = 7, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - ACTIONS(168), 10, + ACTIONS(174), 10, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2576,55 +2678,26 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_else, anon_sym_do, anon_sym_to, - [1826] = 4, - ACTIONS(106), 2, + [1910] = 7, + ACTIONS(110), 1, + anon_sym_AMP, + ACTIONS(112), 1, + anon_sym_PIPE, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, + ACTIONS(104), 2, + anon_sym_STAR, + anon_sym_SLASH, ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(132), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(130), 16, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, - anon_sym_else, - anon_sym_do, - anon_sym_to, - [1857] = 8, - ACTIONS(114), 1, - anon_sym_AMP, - ACTIONS(116), 1, - anon_sym_PIPE, - ACTIONS(172), 1, - anon_sym_else, - ACTIONS(106), 2, - anon_sym_DASH, - anon_sym_PLUS, - ACTIONS(108), 2, - anon_sym_STAR, - anon_sym_SLASH, - ACTIONS(112), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(110), 4, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - ACTIONS(170), 9, + ACTIONS(176), 10, ts_builtin_sym_end, anon_sym_RBRACK, anon_sym_COMMA, @@ -2632,338 +2705,314 @@ static const uint16_t ts_small_parse_table[] = { anon_sym_SEMI, anon_sym_RBRACE, anon_sym_then, - anon_sym_do, - anon_sym_to, - [1896] = 2, - ACTIONS(176), 2, - anon_sym_LT, - anon_sym_GT, - ACTIONS(174), 20, - ts_builtin_sym_end, - anon_sym_RBRACK, - anon_sym_COMMA, - anon_sym_RPAREN, - anon_sym_DASH, - anon_sym_STAR, - anon_sym_SLASH, - anon_sym_PLUS, - anon_sym_GT_EQ, - anon_sym_LT_EQ, - anon_sym_EQ, - anon_sym_LT_GT, - anon_sym_AMP, - anon_sym_PIPE, - anon_sym_SEMI, - anon_sym_RBRACE, - anon_sym_then, anon_sym_else, anon_sym_do, anon_sym_to, - [1923] = 9, - ACTIONS(114), 1, + [1947] = 9, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(178), 1, - anon_sym_COMMA, + anon_sym_RPAREN, ACTIONS(180), 1, - anon_sym_RBRACE, - STATE(69), 1, - aux_sym_record_expression_repeat1, - ACTIONS(106), 2, + anon_sym_SEMI, + STATE(72), 1, + aux_sym_sequence_expression_repeat1, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [1957] = 9, - ACTIONS(114), 1, + [1981] = 9, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(182), 1, anon_sym_COMMA, ACTIONS(184), 1, anon_sym_RPAREN, - STATE(72), 1, + STATE(70), 1, aux_sym_function_call_repeat1, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [1991] = 9, - ACTIONS(114), 1, + [2015] = 9, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(186), 1, - anon_sym_RPAREN, + anon_sym_COMMA, ACTIONS(188), 1, - anon_sym_SEMI, + anon_sym_RBRACE, STATE(74), 1, - aux_sym_sequence_expression_repeat1, - ACTIONS(106), 2, + aux_sym_record_expression_repeat1, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2025] = 7, - ACTIONS(114), 1, + [2049] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, ACTIONS(190), 2, anon_sym_COMMA, anon_sym_RPAREN, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2054] = 7, - ACTIONS(114), 1, + [2078] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, ACTIONS(192), 2, - anon_sym_RPAREN, - anon_sym_SEMI, - ACTIONS(110), 4, + anon_sym_COMMA, + anon_sym_RBRACE, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2083] = 7, - ACTIONS(114), 1, + [2107] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, ACTIONS(194), 2, - anon_sym_COMMA, - anon_sym_RBRACE, - ACTIONS(110), 4, + anon_sym_RPAREN, + anon_sym_SEMI, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2112] = 7, - ACTIONS(114), 1, + [2136] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(196), 1, - ts_builtin_sym_end, - ACTIONS(106), 2, + anon_sym_then, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2140] = 7, - ACTIONS(114), 1, + [2164] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(198), 1, - anon_sym_do, - ACTIONS(106), 2, + ts_builtin_sym_end, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2168] = 7, - ACTIONS(114), 1, + [2192] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(200), 1, anon_sym_to, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2196] = 7, - ACTIONS(114), 1, + [2220] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(202), 1, anon_sym_RBRACK, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2224] = 7, - ACTIONS(114), 1, + [2248] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(204), 1, anon_sym_RBRACK, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2252] = 7, - ACTIONS(114), 1, + [2276] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(206), 1, anon_sym_do, - ACTIONS(106), 2, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2280] = 7, - ACTIONS(114), 1, + [2304] = 7, + ACTIONS(110), 1, anon_sym_AMP, - ACTIONS(116), 1, + ACTIONS(112), 1, anon_sym_PIPE, ACTIONS(208), 1, - anon_sym_then, - ACTIONS(106), 2, + anon_sym_do, + ACTIONS(102), 2, anon_sym_DASH, anon_sym_PLUS, - ACTIONS(108), 2, + ACTIONS(104), 2, anon_sym_STAR, anon_sym_SLASH, - ACTIONS(112), 2, + ACTIONS(108), 2, anon_sym_LT, anon_sym_GT, - ACTIONS(110), 4, + ACTIONS(106), 4, anon_sym_GT_EQ, anon_sym_LT_EQ, anon_sym_EQ, anon_sym_LT_GT, - [2308] = 3, + [2332] = 3, ACTIONS(210), 1, anon_sym_DQUOTE, - STATE(66), 1, + STATE(68), 1, aux_sym_string_literal_repeat1, ACTIONS(212), 2, aux_sym_string_literal_token1, sym_escape_sequence, - [2319] = 3, - ACTIONS(215), 1, + [2343] = 3, + ACTIONS(214), 1, anon_sym_DQUOTE, - STATE(66), 1, + STATE(67), 1, aux_sym_string_literal_repeat1, - ACTIONS(217), 2, + ACTIONS(216), 2, aux_sym_string_literal_token1, sym_escape_sequence, - [2330] = 3, + [2354] = 3, ACTIONS(219), 1, anon_sym_DQUOTE, STATE(67), 1, @@ -2971,293 +3020,293 @@ static const uint16_t ts_small_parse_table[] = { ACTIONS(221), 2, aux_sym_string_literal_token1, sym_escape_sequence, - [2341] = 3, - ACTIONS(178), 1, - anon_sym_COMMA, + [2365] = 3, ACTIONS(223), 1, - anon_sym_RBRACE, - STATE(73), 1, - aux_sym_record_expression_repeat1, - [2351] = 3, - ACTIONS(192), 1, - anon_sym_RPAREN, - ACTIONS(225), 1, - anon_sym_SEMI, - STATE(70), 1, - aux_sym_sequence_expression_repeat1, - [2361] = 3, - ACTIONS(190), 1, - anon_sym_RPAREN, - ACTIONS(228), 1, anon_sym_COMMA, - STATE(71), 1, - aux_sym_function_call_repeat1, - [2371] = 3, + ACTIONS(226), 1, + anon_sym_RBRACE, + STATE(69), 1, + aux_sym_record_expression_repeat1, + [2375] = 3, ACTIONS(182), 1, anon_sym_COMMA, - ACTIONS(231), 1, + ACTIONS(228), 1, + anon_sym_RPAREN, + STATE(73), 1, + aux_sym_function_call_repeat1, + [2385] = 3, + ACTIONS(194), 1, + anon_sym_RPAREN, + ACTIONS(230), 1, + anon_sym_SEMI, + STATE(71), 1, + aux_sym_sequence_expression_repeat1, + [2395] = 3, + ACTIONS(180), 1, + anon_sym_SEMI, + ACTIONS(233), 1, anon_sym_RPAREN, STATE(71), 1, - aux_sym_function_call_repeat1, - [2381] = 3, - ACTIONS(233), 1, - anon_sym_COMMA, - ACTIONS(236), 1, - anon_sym_RBRACE, - STATE(73), 1, - aux_sym_record_expression_repeat1, - [2391] = 3, - ACTIONS(188), 1, - anon_sym_SEMI, - ACTIONS(238), 1, - anon_sym_RPAREN, - STATE(70), 1, aux_sym_sequence_expression_repeat1, - [2401] = 2, + [2405] = 3, + ACTIONS(190), 1, + anon_sym_RPAREN, + ACTIONS(235), 1, + anon_sym_COMMA, + STATE(73), 1, + aux_sym_function_call_repeat1, + [2415] = 3, + ACTIONS(186), 1, + anon_sym_COMMA, + ACTIONS(238), 1, + anon_sym_RBRACE, + STATE(69), 1, + aux_sym_record_expression_repeat1, + [2425] = 2, ACTIONS(240), 1, sym_identifier, ACTIONS(242), 1, anon_sym_RBRACE, - [2408] = 1, - ACTIONS(244), 1, - sym_identifier, - [2412] = 1, - ACTIONS(246), 1, - anon_sym_EQ, - [2416] = 1, - ACTIONS(248), 1, - sym_identifier, - [2420] = 1, - ACTIONS(250), 1, - ts_builtin_sym_end, - [2424] = 1, - ACTIONS(252), 1, - anon_sym_COLON_EQ, - [2428] = 1, - ACTIONS(254), 1, - sym_identifier, [2432] = 1, - ACTIONS(256), 1, + ACTIONS(244), 1, anon_sym_EQ, [2436] = 1, - ACTIONS(258), 1, + ACTIONS(246), 1, + anon_sym_EQ, + [2440] = 1, + ACTIONS(248), 1, anon_sym_of, + [2444] = 1, + ACTIONS(250), 1, + anon_sym_COLON_EQ, + [2448] = 1, + ACTIONS(252), 1, + sym_identifier, + [2452] = 1, + ACTIONS(254), 1, + sym_identifier, + [2456] = 1, + ACTIONS(256), 1, + ts_builtin_sym_end, + [2460] = 1, + ACTIONS(258), 1, + sym_identifier, }; static const uint32_t ts_small_parse_table_map[] = { [SMALL_STATE(2)] = 0, [SMALL_STATE(3)] = 38, - [SMALL_STATE(4)] = 86, - [SMALL_STATE(5)] = 134, - [SMALL_STATE(6)] = 164, - [SMALL_STATE(7)] = 194, - [SMALL_STATE(8)] = 230, - [SMALL_STATE(9)] = 275, - [SMALL_STATE(10)] = 320, - [SMALL_STATE(11)] = 365, - [SMALL_STATE(12)] = 410, - [SMALL_STATE(13)] = 455, - [SMALL_STATE(14)] = 500, - [SMALL_STATE(15)] = 545, - [SMALL_STATE(16)] = 590, - [SMALL_STATE(17)] = 635, - [SMALL_STATE(18)] = 680, - [SMALL_STATE(19)] = 725, - [SMALL_STATE(20)] = 770, - [SMALL_STATE(21)] = 815, - [SMALL_STATE(22)] = 860, - [SMALL_STATE(23)] = 905, - [SMALL_STATE(24)] = 950, - [SMALL_STATE(25)] = 995, - [SMALL_STATE(26)] = 1040, - [SMALL_STATE(27)] = 1085, - [SMALL_STATE(28)] = 1130, - [SMALL_STATE(29)] = 1175, - [SMALL_STATE(30)] = 1220, - [SMALL_STATE(31)] = 1247, - [SMALL_STATE(32)] = 1284, - [SMALL_STATE(33)] = 1311, - [SMALL_STATE(34)] = 1348, - [SMALL_STATE(35)] = 1385, - [SMALL_STATE(36)] = 1412, - [SMALL_STATE(37)] = 1441, - [SMALL_STATE(38)] = 1468, - [SMALL_STATE(39)] = 1495, - [SMALL_STATE(40)] = 1522, - [SMALL_STATE(41)] = 1559, - [SMALL_STATE(42)] = 1586, - [SMALL_STATE(43)] = 1613, - [SMALL_STATE(44)] = 1640, - [SMALL_STATE(45)] = 1667, - [SMALL_STATE(46)] = 1694, - [SMALL_STATE(47)] = 1721, - [SMALL_STATE(48)] = 1754, - [SMALL_STATE(49)] = 1789, - [SMALL_STATE(50)] = 1826, - [SMALL_STATE(51)] = 1857, - [SMALL_STATE(52)] = 1896, - [SMALL_STATE(53)] = 1923, - [SMALL_STATE(54)] = 1957, - [SMALL_STATE(55)] = 1991, - [SMALL_STATE(56)] = 2025, - [SMALL_STATE(57)] = 2054, - [SMALL_STATE(58)] = 2083, - [SMALL_STATE(59)] = 2112, - [SMALL_STATE(60)] = 2140, - [SMALL_STATE(61)] = 2168, - [SMALL_STATE(62)] = 2196, - [SMALL_STATE(63)] = 2224, - [SMALL_STATE(64)] = 2252, - [SMALL_STATE(65)] = 2280, - [SMALL_STATE(66)] = 2308, - [SMALL_STATE(67)] = 2319, - [SMALL_STATE(68)] = 2330, - [SMALL_STATE(69)] = 2341, - [SMALL_STATE(70)] = 2351, - [SMALL_STATE(71)] = 2361, - [SMALL_STATE(72)] = 2371, - [SMALL_STATE(73)] = 2381, - [SMALL_STATE(74)] = 2391, - [SMALL_STATE(75)] = 2401, - [SMALL_STATE(76)] = 2408, - [SMALL_STATE(77)] = 2412, - [SMALL_STATE(78)] = 2416, - [SMALL_STATE(79)] = 2420, - [SMALL_STATE(80)] = 2424, - [SMALL_STATE(81)] = 2428, - [SMALL_STATE(82)] = 2432, - [SMALL_STATE(83)] = 2436, + [SMALL_STATE(4)] = 87, + [SMALL_STATE(5)] = 136, + [SMALL_STATE(6)] = 182, + [SMALL_STATE(7)] = 228, + [SMALL_STATE(8)] = 274, + [SMALL_STATE(9)] = 320, + [SMALL_STATE(10)] = 366, + [SMALL_STATE(11)] = 412, + [SMALL_STATE(12)] = 458, + [SMALL_STATE(13)] = 494, + [SMALL_STATE(14)] = 524, + [SMALL_STATE(15)] = 570, + [SMALL_STATE(16)] = 616, + [SMALL_STATE(17)] = 646, + [SMALL_STATE(18)] = 692, + [SMALL_STATE(19)] = 738, + [SMALL_STATE(20)] = 784, + [SMALL_STATE(21)] = 830, + [SMALL_STATE(22)] = 876, + [SMALL_STATE(23)] = 922, + [SMALL_STATE(24)] = 968, + [SMALL_STATE(25)] = 1014, + [SMALL_STATE(26)] = 1060, + [SMALL_STATE(27)] = 1106, + [SMALL_STATE(28)] = 1152, + [SMALL_STATE(29)] = 1198, + [SMALL_STATE(30)] = 1244, + [SMALL_STATE(31)] = 1283, + [SMALL_STATE(32)] = 1316, + [SMALL_STATE(33)] = 1343, + [SMALL_STATE(34)] = 1370, + [SMALL_STATE(35)] = 1397, + [SMALL_STATE(36)] = 1426, + [SMALL_STATE(37)] = 1463, + [SMALL_STATE(38)] = 1490, + [SMALL_STATE(39)] = 1517, + [SMALL_STATE(40)] = 1554, + [SMALL_STATE(41)] = 1581, + [SMALL_STATE(42)] = 1608, + [SMALL_STATE(43)] = 1635, + [SMALL_STATE(44)] = 1662, + [SMALL_STATE(45)] = 1699, + [SMALL_STATE(46)] = 1726, + [SMALL_STATE(47)] = 1757, + [SMALL_STATE(48)] = 1784, + [SMALL_STATE(49)] = 1819, + [SMALL_STATE(50)] = 1846, + [SMALL_STATE(51)] = 1873, + [SMALL_STATE(52)] = 1910, + [SMALL_STATE(53)] = 1947, + [SMALL_STATE(54)] = 1981, + [SMALL_STATE(55)] = 2015, + [SMALL_STATE(56)] = 2049, + [SMALL_STATE(57)] = 2078, + [SMALL_STATE(58)] = 2107, + [SMALL_STATE(59)] = 2136, + [SMALL_STATE(60)] = 2164, + [SMALL_STATE(61)] = 2192, + [SMALL_STATE(62)] = 2220, + [SMALL_STATE(63)] = 2248, + [SMALL_STATE(64)] = 2276, + [SMALL_STATE(65)] = 2304, + [SMALL_STATE(66)] = 2332, + [SMALL_STATE(67)] = 2343, + [SMALL_STATE(68)] = 2354, + [SMALL_STATE(69)] = 2365, + [SMALL_STATE(70)] = 2375, + [SMALL_STATE(71)] = 2385, + [SMALL_STATE(72)] = 2395, + [SMALL_STATE(73)] = 2405, + [SMALL_STATE(74)] = 2415, + [SMALL_STATE(75)] = 2425, + [SMALL_STATE(76)] = 2432, + [SMALL_STATE(77)] = 2436, + [SMALL_STATE(78)] = 2440, + [SMALL_STATE(79)] = 2444, + [SMALL_STATE(80)] = 2448, + [SMALL_STATE(81)] = 2452, + [SMALL_STATE(82)] = 2456, + [SMALL_STATE(83)] = 2460, }; static const TSParseActionEntry ts_parse_actions[] = { [0] = {.entry = {.count = 0, .reusable = false}}, [1] = {.entry = {.count = 1, .reusable = false}}, RECOVER(), [3] = {.entry = {.count = 1, .reusable = false}}, SHIFT(2), - [5] = {.entry = {.count = 1, .reusable = false}}, SHIFT(59), - [7] = {.entry = {.count = 1, .reusable = true}}, SHIFT(68), + [5] = {.entry = {.count = 1, .reusable = false}}, SHIFT(60), + [7] = {.entry = {.count = 1, .reusable = true}}, SHIFT(66), [9] = {.entry = {.count = 1, .reusable = true}}, SHIFT(4), - [11] = {.entry = {.count = 1, .reusable = true}}, SHIFT(13), - [13] = {.entry = {.count = 1, .reusable = false}}, SHIFT(14), - [15] = {.entry = {.count = 1, .reusable = false}}, SHIFT(17), - [17] = {.entry = {.count = 1, .reusable = false}}, SHIFT(76), + [11] = {.entry = {.count = 1, .reusable = true}}, SHIFT(14), + [13] = {.entry = {.count = 1, .reusable = false}}, SHIFT(7), + [15] = {.entry = {.count = 1, .reusable = false}}, SHIFT(8), + [17] = {.entry = {.count = 1, .reusable = false}}, SHIFT(80), [19] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym__lvalue, 1), [21] = {.entry = {.count = 2, .reusable = true}}, REDUCE(sym__lvalue, 1), SHIFT(15), [24] = {.entry = {.count = 1, .reusable = true}}, SHIFT(3), [26] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym__lvalue, 1), [28] = {.entry = {.count = 1, .reusable = true}}, SHIFT(75), [30] = {.entry = {.count = 1, .reusable = false}}, SHIFT(54), - [32] = {.entry = {.count = 1, .reusable = true}}, SHIFT(44), - [34] = {.entry = {.count = 1, .reusable = false}}, SHIFT(55), - [36] = {.entry = {.count = 1, .reusable = true}}, SHIFT(43), - [38] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_array_value, 4, .production_id = 10), - [40] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_array_value, 4, .production_id = 10), - [42] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_value, 3, .production_id = 5), - [44] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_value, 3, .production_id = 5), - [46] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym__expr, 1), - [48] = {.entry = {.count = 1, .reusable = true}}, SHIFT(81), - [50] = {.entry = {.count = 1, .reusable = true}}, SHIFT(29), - [52] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym__expr, 1), - [54] = {.entry = {.count = 1, .reusable = true}}, SHIFT(28), - [56] = {.entry = {.count = 1, .reusable = false}}, SHIFT(49), - [58] = {.entry = {.count = 1, .reusable = false}}, SHIFT(53), - [60] = {.entry = {.count = 1, .reusable = false}}, SHIFT(58), - [62] = {.entry = {.count = 1, .reusable = false}}, SHIFT(64), - [64] = {.entry = {.count = 1, .reusable = false}}, SHIFT(40), - [66] = {.entry = {.count = 1, .reusable = false}}, SHIFT(31), - [68] = {.entry = {.count = 1, .reusable = false}}, SHIFT(65), - [70] = {.entry = {.count = 1, .reusable = false}}, SHIFT(62), - [72] = {.entry = {.count = 1, .reusable = false}}, SHIFT(56), - [74] = {.entry = {.count = 1, .reusable = false}}, SHIFT(60), - [76] = {.entry = {.count = 1, .reusable = false}}, SHIFT(33), - [78] = {.entry = {.count = 1, .reusable = false}}, SHIFT(61), - [80] = {.entry = {.count = 1, .reusable = false}}, SHIFT(34), - [82] = {.entry = {.count = 1, .reusable = false}}, SHIFT(51), - [84] = {.entry = {.count = 1, .reusable = false}}, SHIFT(57), - [86] = {.entry = {.count = 1, .reusable = false}}, SHIFT(36), - [88] = {.entry = {.count = 1, .reusable = false}}, SHIFT(41), - [90] = {.entry = {.count = 1, .reusable = false}}, SHIFT(50), - [92] = {.entry = {.count = 1, .reusable = false}}, SHIFT(47), + [32] = {.entry = {.count = 1, .reusable = true}}, SHIFT(34), + [34] = {.entry = {.count = 1, .reusable = false}}, SHIFT(53), + [36] = {.entry = {.count = 1, .reusable = true}}, SHIFT(41), + [38] = {.entry = {.count = 1, .reusable = false}}, SHIFT(52), + [40] = {.entry = {.count = 1, .reusable = false}}, SHIFT(58), + [42] = {.entry = {.count = 1, .reusable = false}}, SHIFT(59), + [44] = {.entry = {.count = 1, .reusable = false}}, SHIFT(64), + [46] = {.entry = {.count = 1, .reusable = false}}, SHIFT(56), + [48] = {.entry = {.count = 1, .reusable = false}}, SHIFT(57), + [50] = {.entry = {.count = 1, .reusable = false}}, SHIFT(51), + [52] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym__expr, 1), + [54] = {.entry = {.count = 1, .reusable = true}}, SHIFT(81), + [56] = {.entry = {.count = 1, .reusable = true}}, SHIFT(29), + [58] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym__expr, 1), + [60] = {.entry = {.count = 1, .reusable = true}}, SHIFT(22), + [62] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_value, 3, .production_id = 5), + [64] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_value, 3, .production_id = 5), + [66] = {.entry = {.count = 1, .reusable = false}}, SHIFT(39), + [68] = {.entry = {.count = 1, .reusable = false}}, SHIFT(63), + [70] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_array_value, 4, .production_id = 10), + [72] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_array_value, 4, .production_id = 10), + [74] = {.entry = {.count = 1, .reusable = false}}, SHIFT(36), + [76] = {.entry = {.count = 1, .reusable = false}}, SHIFT(30), + [78] = {.entry = {.count = 1, .reusable = false}}, SHIFT(55), + [80] = {.entry = {.count = 1, .reusable = false}}, SHIFT(44), + [82] = {.entry = {.count = 1, .reusable = false}}, SHIFT(61), + [84] = {.entry = {.count = 1, .reusable = false}}, SHIFT(50), + [86] = {.entry = {.count = 1, .reusable = false}}, SHIFT(35), + [88] = {.entry = {.count = 1, .reusable = false}}, SHIFT(47), + [90] = {.entry = {.count = 1, .reusable = false}}, SHIFT(46), + [92] = {.entry = {.count = 1, .reusable = false}}, SHIFT(31), [94] = {.entry = {.count = 1, .reusable = false}}, SHIFT(48), - [96] = {.entry = {.count = 1, .reusable = false}}, SHIFT(30), - [98] = {.entry = {.count = 1, .reusable = false}}, SHIFT(63), - [100] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_assignment_expression, 3, .production_id = 6), - [102] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_assignment_expression, 3, .production_id = 6), - [104] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_unary_expression, 2, .production_id = 1), - [106] = {.entry = {.count = 1, .reusable = true}}, SHIFT(23), - [108] = {.entry = {.count = 1, .reusable = true}}, SHIFT(24), - [110] = {.entry = {.count = 1, .reusable = true}}, SHIFT(25), - [112] = {.entry = {.count = 1, .reusable = false}}, SHIFT(25), - [114] = {.entry = {.count = 1, .reusable = true}}, SHIFT(26), - [116] = {.entry = {.count = 1, .reusable = true}}, SHIFT(27), - [118] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sequence_expression, 4), - [120] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sequence_expression, 4), - [122] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_for_expression, 8, .production_id = 17), - [124] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_while_expression, 4, .production_id = 9), - [126] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_string_literal, 2), - [128] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_string_literal, 2), - [130] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_binary_expression, 3, .production_id = 4), - [132] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_binary_expression, 3, .production_id = 4), + [96] = {.entry = {.count = 1, .reusable = false}}, SHIFT(65), + [98] = {.entry = {.count = 1, .reusable = false}}, SHIFT(62), + [100] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_if_expression, 4, .production_id = 8), + [102] = {.entry = {.count = 1, .reusable = true}}, SHIFT(23), + [104] = {.entry = {.count = 1, .reusable = true}}, SHIFT(24), + [106] = {.entry = {.count = 1, .reusable = true}}, SHIFT(25), + [108] = {.entry = {.count = 1, .reusable = false}}, SHIFT(25), + [110] = {.entry = {.count = 1, .reusable = true}}, SHIFT(26), + [112] = {.entry = {.count = 1, .reusable = true}}, SHIFT(27), + [114] = {.entry = {.count = 1, .reusable = true}}, SHIFT(20), + [116] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_binary_expression, 3, .production_id = 4), + [118] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_expression, 6, .production_id = 13), + [120] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_expression, 6, .production_id = 13), + [122] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 5, .production_id = 11), + [124] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 5, .production_id = 11), + [126] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 3, .production_id = 2), + [128] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 3, .production_id = 2), + [130] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_binary_expression, 3, .production_id = 4), + [132] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_while_expression, 4, .production_id = 9), [134] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_expression, 3, .production_id = 3), [136] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_expression, 3, .production_id = 3), [138] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sequence_expression, 3), [140] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sequence_expression, 3), - [142] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_expression, 7, .production_id = 15), - [144] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_expression, 7, .production_id = 15), - [146] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_if_expression, 6, .production_id = 14), - [148] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_expression, 6, .production_id = 13), - [150] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_expression, 6, .production_id = 13), - [152] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sequence_expression, 2), - [154] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sequence_expression, 2), - [156] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 3, .production_id = 2), - [158] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 3, .production_id = 2), - [160] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_string_literal, 3), - [162] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_string_literal, 3), - [164] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 4, .production_id = 7), - [166] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 4, .production_id = 7), - [168] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_array_expression, 6, .production_id = 12), - [170] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_if_expression, 4, .production_id = 8), - [172] = {.entry = {.count = 1, .reusable = true}}, SHIFT(12), - [174] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 5, .production_id = 11), - [176] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 5, .production_id = 11), - [178] = {.entry = {.count = 1, .reusable = true}}, SHIFT(78), - [180] = {.entry = {.count = 1, .reusable = true}}, SHIFT(42), - [182] = {.entry = {.count = 1, .reusable = true}}, SHIFT(16), - [184] = {.entry = {.count = 1, .reusable = true}}, SHIFT(46), - [186] = {.entry = {.count = 1, .reusable = true}}, SHIFT(38), - [188] = {.entry = {.count = 1, .reusable = true}}, SHIFT(22), + [142] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_unary_expression, 2, .production_id = 1), + [144] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_function_call, 4, .production_id = 7), + [146] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_function_call, 4, .production_id = 7), + [148] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sequence_expression, 2), + [150] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sequence_expression, 2), + [152] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_string_literal, 3), + [154] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_string_literal, 3), + [156] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_sequence_expression, 4), + [158] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_sequence_expression, 4), + [160] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_if_expression, 6, .production_id = 14), + [162] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_record_expression, 7, .production_id = 15), + [164] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_record_expression, 7, .production_id = 15), + [166] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_string_literal, 2), + [168] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_string_literal, 2), + [170] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_assignment_expression, 3, .production_id = 6), + [172] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_assignment_expression, 3, .production_id = 6), + [174] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_for_expression, 8, .production_id = 17), + [176] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_array_expression, 6, .production_id = 12), + [178] = {.entry = {.count = 1, .reusable = true}}, SHIFT(38), + [180] = {.entry = {.count = 1, .reusable = true}}, SHIFT(6), + [182] = {.entry = {.count = 1, .reusable = true}}, SHIFT(9), + [184] = {.entry = {.count = 1, .reusable = true}}, SHIFT(40), + [186] = {.entry = {.count = 1, .reusable = true}}, SHIFT(83), + [188] = {.entry = {.count = 1, .reusable = true}}, SHIFT(32), [190] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_function_call_repeat1, 2), - [192] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_sequence_expression_repeat1, 2), - [194] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 4, .production_id = 18), - [196] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 1), - [198] = {.entry = {.count = 1, .reusable = true}}, SHIFT(20), - [200] = {.entry = {.count = 1, .reusable = true}}, SHIFT(11), - [202] = {.entry = {.count = 1, .reusable = true}}, SHIFT(83), - [204] = {.entry = {.count = 1, .reusable = true}}, SHIFT(5), - [206] = {.entry = {.count = 1, .reusable = true}}, SHIFT(18), - [208] = {.entry = {.count = 1, .reusable = true}}, SHIFT(21), - [210] = {.entry = {.count = 1, .reusable = false}}, REDUCE(aux_sym_string_literal_repeat1, 2), - [212] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_string_literal_repeat1, 2), SHIFT_REPEAT(66), - [215] = {.entry = {.count = 1, .reusable = false}}, SHIFT(45), - [217] = {.entry = {.count = 1, .reusable = true}}, SHIFT(66), - [219] = {.entry = {.count = 1, .reusable = false}}, SHIFT(35), + [192] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 4, .production_id = 18), + [194] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_sequence_expression_repeat1, 2), + [196] = {.entry = {.count = 1, .reusable = true}}, SHIFT(18), + [198] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 1), + [200] = {.entry = {.count = 1, .reusable = true}}, SHIFT(28), + [202] = {.entry = {.count = 1, .reusable = true}}, SHIFT(16), + [204] = {.entry = {.count = 1, .reusable = true}}, SHIFT(78), + [206] = {.entry = {.count = 1, .reusable = true}}, SHIFT(17), + [208] = {.entry = {.count = 1, .reusable = true}}, SHIFT(11), + [210] = {.entry = {.count = 1, .reusable = false}}, SHIFT(49), + [212] = {.entry = {.count = 1, .reusable = true}}, SHIFT(68), + [214] = {.entry = {.count = 1, .reusable = false}}, REDUCE(aux_sym_string_literal_repeat1, 2), + [216] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_string_literal_repeat1, 2), SHIFT_REPEAT(67), + [219] = {.entry = {.count = 1, .reusable = false}}, SHIFT(42), [221] = {.entry = {.count = 1, .reusable = true}}, SHIFT(67), - [223] = {.entry = {.count = 1, .reusable = true}}, SHIFT(39), - [225] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_sequence_expression_repeat1, 2), SHIFT_REPEAT(22), - [228] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_function_call_repeat1, 2), SHIFT_REPEAT(16), - [231] = {.entry = {.count = 1, .reusable = true}}, SHIFT(52), - [233] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 2, .production_id = 16), SHIFT_REPEAT(78), - [236] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 2, .production_id = 16), - [238] = {.entry = {.count = 1, .reusable = true}}, SHIFT(32), - [240] = {.entry = {.count = 1, .reusable = true}}, SHIFT(82), + [223] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 2, .production_id = 16), SHIFT_REPEAT(83), + [226] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_record_expression_repeat1, 2, .production_id = 16), + [228] = {.entry = {.count = 1, .reusable = true}}, SHIFT(33), + [230] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_sequence_expression_repeat1, 2), SHIFT_REPEAT(6), + [233] = {.entry = {.count = 1, .reusable = true}}, SHIFT(43), + [235] = {.entry = {.count = 2, .reusable = true}}, REDUCE(aux_sym_function_call_repeat1, 2), SHIFT_REPEAT(9), + [238] = {.entry = {.count = 1, .reusable = true}}, SHIFT(45), + [240] = {.entry = {.count = 1, .reusable = true}}, SHIFT(76), [242] = {.entry = {.count = 1, .reusable = true}}, SHIFT(37), - [244] = {.entry = {.count = 1, .reusable = true}}, SHIFT(80), + [244] = {.entry = {.count = 1, .reusable = true}}, SHIFT(19), [246] = {.entry = {.count = 1, .reusable = true}}, SHIFT(10), - [248] = {.entry = {.count = 1, .reusable = true}}, SHIFT(77), - [250] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), - [252] = {.entry = {.count = 1, .reusable = true}}, SHIFT(19), - [254] = {.entry = {.count = 1, .reusable = true}}, SHIFT(6), - [256] = {.entry = {.count = 1, .reusable = true}}, SHIFT(9), - [258] = {.entry = {.count = 1, .reusable = true}}, SHIFT(8), + [248] = {.entry = {.count = 1, .reusable = true}}, SHIFT(5), + [250] = {.entry = {.count = 1, .reusable = true}}, SHIFT(21), + [252] = {.entry = {.count = 1, .reusable = true}}, SHIFT(79), + [254] = {.entry = {.count = 1, .reusable = true}}, SHIFT(13), + [256] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), + [258] = {.entry = {.count = 1, .reusable = true}}, SHIFT(77), }; #ifdef __cplusplus diff --git a/test/corpus/control_flow.txt b/test/corpus/control_flow.txt index 5c5d587..1c22b63 100644 --- a/test/corpus/control_flow.txt +++ b/test/corpus/control_flow.txt @@ -111,3 +111,31 @@ for 12 to nil (identifier) (identifier)) (nil_literal)) + +================================================================================ +Break +================================================================================ + +break + +-------------------------------------------------------------------------------- + +(source_file + (break_expression)) + +================================================================================ +Break in loops +================================================================================ + +for i := break to break do while break do break + +-------------------------------------------------------------------------------- + +(source_file + (for_expression + (identifier) + (break_expression) + (break_expression) + (while_expression + (break_expression) + (break_expression))))