From c34df2ccaa77f10205c76d9d77bcffb00f60e710 Mon Sep 17 00:00:00 2001 From: kjuulh Date: Tue, 4 Jul 2023 20:56:48 +0200 Subject: [PATCH] for now no escaping comment Signed-off-by: kjuulh --- corpus/extras.txt | 21 + corpus/requests.txt | 32 +- grammar.js | 14 +- src/grammar.json | 23 +- src/node-types.json | 4 + src/parser.c | 1062 ++++++++++++++++++++++--------------------- 6 files changed, 615 insertions(+), 541 deletions(-) create mode 100644 corpus/extras.txt diff --git a/corpus/extras.txt b/corpus/extras.txt new file mode 100644 index 0000000..5f22950 --- /dev/null +++ b/corpus/extras.txt @@ -0,0 +1,21 @@ +=== +Comments +=== + +GET https://somewhere.com # some comment +# comment + +HTTP 200 # comment + +--- + +(source_file + (request_declaration + (request_literal) + (url)) + (comment) + (comment) + (response + (scheme_literal) + (status_code_pattern)) + (comment)) diff --git a/corpus/requests.txt b/corpus/requests.txt index f2dabfb..e14887b 100644 --- a/corpus/requests.txt +++ b/corpus/requests.txt @@ -47,7 +47,7 @@ More Headers POST https://somewhere.com?query=something some: header -A123a-123: someA asdfasdf asdf c123 +A123a-123: someAasdfasdfasdfc123 --- @@ -55,9 +55,13 @@ A123a-123: someA asdfasdf asdf c123 (request_declaration (request_literal) (url)) - (header_declaration - (header_name) - (header_value))) + (header_declaration + (header_name) + (header_value)) + (header_declaration + (header_name) + (header_value)) + ) === HTTP Status codes 200 @@ -92,3 +96,23 @@ HTTP 302 (response (scheme_literal) (status_code_pattern))) + +=== +HTTP Status codes 302 +=== + +POST https://somewhere.com?query=something +Header: something +HTTP 302 +--- + +(source_file + (request_declaration + (request_literal) + (url)) + (header_declaration + (header_name) + (header_value)) + (response + (scheme_literal) + (status_code_pattern))) diff --git a/grammar.js b/grammar.js index 86d9011..0348099 100644 --- a/grammar.js +++ b/grammar.js @@ -1,6 +1,11 @@ module.exports = grammar({ name: "hurl", + extras: $ => [ + $.comment, + /\s/ + ], + rules: { source_file: ($) => repeat($._statement), @@ -28,7 +33,7 @@ module.exports = grammar({ field("header_value", $.header_value) ), - http_response_declaration: $ => seq($.scheme_literal, $._space_literal, $.status_code_pattern), + http_response_declaration: $ => seq($.scheme_literal, $.status_code_pattern), // literals @@ -55,14 +60,15 @@ module.exports = grammar({ scheme_literal: $ => "HTTP", - _space_literal: $ => " ", - // patterns + comment: $ => token(prec(-10, /#.*/)), + + status_code_pattern: $ => /[\d]{3}/, header_name: ($) => /[a-zA-Z-_0-9]+/, header_value: ($) => - /[a-zA-Z-_0-9\s:;\.,\\\/\"\'\?\!\(\)\{\}\[\]@<>=\-\+\*\#\$\&`|~^%]+/, + /[a-zA-Z\-_0-9\/\\]+/, url: ($) => /\S+/, }, diff --git a/src/grammar.json b/src/grammar.json index 647c9c4..0a114e9 100644 --- a/src/grammar.json +++ b/src/grammar.json @@ -88,10 +88,6 @@ "type": "SYMBOL", "name": "scheme_literal" }, - { - "type": "SYMBOL", - "name": "_space_literal" - }, { "type": "SYMBOL", "name": "status_code_pattern" @@ -176,9 +172,16 @@ "type": "STRING", "value": "HTTP" }, - "_space_literal": { - "type": "STRING", - "value": " " + "comment": { + "type": "TOKEN", + "content": { + "type": "PREC", + "value": -10, + "content": { + "type": "PATTERN", + "value": "#.*" + } + } }, "status_code_pattern": { "type": "PATTERN", @@ -190,7 +193,7 @@ }, "header_value": { "type": "PATTERN", - "value": "[a-zA-Z-_0-9\\s:;\\.,\\\\\\/\\\"\\'\\?\\!\\(\\)\\{\\}\\[\\]@<>=\\-\\+\\*\\#\\$\\&`|~^%]+" + "value": "[a-zA-Z\\-_0-9\\/\\\\]+" }, "url": { "type": "PATTERN", @@ -198,6 +201,10 @@ } }, "extras": [ + { + "type": "SYMBOL", + "name": "comment" + }, { "type": "PATTERN", "value": "\\s" diff --git a/src/node-types.json b/src/node-types.json index f8530c8..fa0d3e7 100644 --- a/src/node-types.json +++ b/src/node-types.json @@ -162,6 +162,10 @@ "type": "VIEW", "named": false }, + { + "type": "comment", + "named": true + }, { "type": "header_name", "named": true diff --git a/src/parser.c b/src/parser.c index 0a05bab..8a53b78 100644 --- a/src/parser.c +++ b/src/parser.c @@ -6,7 +6,7 @@ #endif #define LANGUAGE_VERSION 14 -#define STATE_COUNT 14 +#define STATE_COUNT 13 #define LARGE_STATE_COUNT 7 #define SYMBOL_COUNT 32 #define ALIAS_COUNT 0 @@ -34,7 +34,7 @@ enum { anon_sym_PROPFIND = 15, anon_sym_VIEW = 16, sym_scheme_literal = 17, - sym__space_literal = 18, + sym_comment = 18, sym_status_code_pattern = 19, sym_header_name = 20, sym_header_value = 21, @@ -69,7 +69,7 @@ static const char * const ts_symbol_names[] = { [anon_sym_PROPFIND] = "PROPFIND", [anon_sym_VIEW] = "VIEW", [sym_scheme_literal] = "scheme_literal", - [sym__space_literal] = "_space_literal", + [sym_comment] = "comment", [sym_status_code_pattern] = "status_code_pattern", [sym_header_name] = "header_name", [sym_header_value] = "header_value", @@ -104,7 +104,7 @@ static const TSSymbol ts_symbol_map[] = { [anon_sym_PROPFIND] = anon_sym_PROPFIND, [anon_sym_VIEW] = anon_sym_VIEW, [sym_scheme_literal] = sym_scheme_literal, - [sym__space_literal] = sym__space_literal, + [sym_comment] = sym_comment, [sym_status_code_pattern] = sym_status_code_pattern, [sym_header_name] = sym_header_name, [sym_header_value] = sym_header_value, @@ -193,8 +193,8 @@ static const TSSymbolMetadata ts_symbol_metadata[] = { .visible = true, .named = true, }, - [sym__space_literal] = { - .visible = false, + [sym_comment] = { + .visible = true, .named = true, }, [sym_status_code_pattern] = { @@ -299,7 +299,6 @@ static const TSStateId ts_primary_state_ids[STATE_COUNT] = { [10] = 10, [11] = 11, [12] = 12, - [13] = 13, }; static bool ts_lex(TSLexer *lexer, TSStateId state) { @@ -307,975 +306,973 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { eof = lexer->eof(lexer); switch (state) { case 0: - if (eof) ADVANCE(63); - if (lookahead == ':') ADVANCE(64); - if (lookahead == 'C') ADVANCE(39); - if (lookahead == 'D') ADVANCE(10); - if (lookahead == 'G') ADVANCE(15); - if (lookahead == 'H') ADVANCE(55); - if (lookahead == 'L') ADVANCE(22); - if (lookahead == 'O') ADVANCE(44); - if (lookahead == 'P') ADVANCE(3); - if (lookahead == 'T') ADVANCE(45); - if (lookahead == 'U') ADVANCE(34); - if (lookahead == 'V') ADVANCE(21); + if (eof) ADVANCE(62); + if (lookahead == '#') ADVANCE(96); + if (lookahead == ':') ADVANCE(63); + if (lookahead == 'C') ADVANCE(40); + if (lookahead == 'D') ADVANCE(11); + if (lookahead == 'G') ADVANCE(16); + if (lookahead == 'H') ADVANCE(56); + if (lookahead == 'L') ADVANCE(23); + if (lookahead == 'O') ADVANCE(45); + if (lookahead == 'P') ADVANCE(4); + if (lookahead == 'T') ADVANCE(46); + if (lookahead == 'U') ADVANCE(35); + if (lookahead == 'V') ADVANCE(22); if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' || lookahead == ' ') SKIP(0) - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(61); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(60); END_STATE(); case 1: - if (lookahead == ' ') ADVANCE(97); + if (lookahead == '#') ADVANCE(96); if (lookahead == '\t' || lookahead == '\n' || - lookahead == '\r') SKIP(1) + lookahead == '\r' || + lookahead == ' ') SKIP(1) + if (lookahead == '-' || + ('/' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '\\' || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); END_STATE(); case 2: - if (lookahead == 'A') ADVANCE(7); + if (lookahead == '#') ADVANCE(156); + if (lookahead == '\t' || + lookahead == '\n' || + lookahead == '\r' || + lookahead == ' ') SKIP(2) + if (lookahead != 0) ADVANCE(156); END_STATE(); case 3: - if (lookahead == 'A') ADVANCE(54); - if (lookahead == 'O') ADVANCE(48); - if (lookahead == 'R') ADVANCE(40); - if (lookahead == 'U') ADVANCE(46); + if (lookahead == 'A') ADVANCE(8); END_STATE(); case 4: - if (lookahead == 'C') ADVANCE(20); + if (lookahead == 'A') ADVANCE(55); + if (lookahead == 'O') ADVANCE(49); + if (lookahead == 'R') ADVANCE(41); + if (lookahead == 'U') ADVANCE(47); END_STATE(); case 5: - if (lookahead == 'C') ADVANCE(27); + if (lookahead == 'C') ADVANCE(21); END_STATE(); case 6: - if (lookahead == 'C') ADVANCE(29); + if (lookahead == 'C') ADVANCE(28); END_STATE(); case 7: - if (lookahead == 'C') ADVANCE(13); + if (lookahead == 'C') ADVANCE(30); END_STATE(); case 8: - if (lookahead == 'C') ADVANCE(51); + if (lookahead == 'C') ADVANCE(14); END_STATE(); case 9: - if (lookahead == 'D') ADVANCE(91); + if (lookahead == 'C') ADVANCE(52); END_STATE(); case 10: - if (lookahead == 'E') ADVANCE(31); + if (lookahead == 'D') ADVANCE(90); END_STATE(); case 11: - if (lookahead == 'E') ADVANCE(57); + if (lookahead == 'E') ADVANCE(32); END_STATE(); case 12: - if (lookahead == 'E') ADVANCE(85); + if (lookahead == 'E') ADVANCE(58); END_STATE(); case 13: - if (lookahead == 'E') ADVANCE(77); + if (lookahead == 'E') ADVANCE(84); END_STATE(); case 14: - if (lookahead == 'E') ADVANCE(71); + if (lookahead == 'E') ADVANCE(76); END_STATE(); case 15: - if (lookahead == 'E') ADVANCE(49); + if (lookahead == 'E') ADVANCE(70); END_STATE(); case 16: - if (lookahead == 'E') ADVANCE(8); + if (lookahead == 'E') ADVANCE(50); END_STATE(); case 17: - if (lookahead == 'E') ADVANCE(56); + if (lookahead == 'E') ADVANCE(9); END_STATE(); case 18: - if (lookahead == 'F') ADVANCE(24); + if (lookahead == 'E') ADVANCE(57); END_STATE(); case 19: - if (lookahead == 'G') ADVANCE(12); + if (lookahead == 'F') ADVANCE(25); END_STATE(); case 20: - if (lookahead == 'H') ADVANCE(79); + if (lookahead == 'G') ADVANCE(13); END_STATE(); case 21: - if (lookahead == 'I') ADVANCE(11); + if (lookahead == 'H') ADVANCE(78); END_STATE(); case 22: - if (lookahead == 'I') ADVANCE(32); - if (lookahead == 'O') ADVANCE(5); + if (lookahead == 'I') ADVANCE(12); END_STATE(); case 23: - if (lookahead == 'I') ADVANCE(36); + if (lookahead == 'I') ADVANCE(33); if (lookahead == 'O') ADVANCE(6); END_STATE(); case 24: - if (lookahead == 'I') ADVANCE(33); + if (lookahead == 'I') ADVANCE(37); + if (lookahead == 'O') ADVANCE(7); END_STATE(); case 25: - if (lookahead == 'I') ADVANCE(41); + if (lookahead == 'I') ADVANCE(34); END_STATE(); case 26: - if (lookahead == 'K') ADVANCE(81); + if (lookahead == 'I') ADVANCE(42); END_STATE(); case 27: - if (lookahead == 'K') ADVANCE(87); + if (lookahead == 'K') ADVANCE(80); END_STATE(); case 28: - if (lookahead == 'K') ADVANCE(83); + if (lookahead == 'K') ADVANCE(86); END_STATE(); case 29: - if (lookahead == 'K') ADVANCE(89); + if (lookahead == 'K') ADVANCE(82); END_STATE(); case 30: - if (lookahead == 'L') ADVANCE(23); + if (lookahead == 'K') ADVANCE(88); END_STATE(); case 31: - if (lookahead == 'L') ADVANCE(17); + if (lookahead == 'L') ADVANCE(24); END_STATE(); case 32: - if (lookahead == 'N') ADVANCE(26); + if (lookahead == 'L') ADVANCE(18); END_STATE(); case 33: - if (lookahead == 'N') ADVANCE(9); + if (lookahead == 'N') ADVANCE(27); END_STATE(); case 34: - if (lookahead == 'N') ADVANCE(30); + if (lookahead == 'N') ADVANCE(10); END_STATE(); case 35: - if (lookahead == 'N') ADVANCE(47); + if (lookahead == 'N') ADVANCE(31); END_STATE(); case 36: - if (lookahead == 'N') ADVANCE(28); + if (lookahead == 'N') ADVANCE(48); END_STATE(); case 37: - if (lookahead == 'N') ADVANCE(16); + if (lookahead == 'N') ADVANCE(29); END_STATE(); case 38: - if (lookahead == 'N') ADVANCE(37); + if (lookahead == 'N') ADVANCE(17); END_STATE(); case 39: - if (lookahead == 'O') ADVANCE(38); + if (lookahead == 'N') ADVANCE(38); END_STATE(); case 40: - if (lookahead == 'O') ADVANCE(43); + if (lookahead == 'O') ADVANCE(39); END_STATE(); case 41: - if (lookahead == 'O') ADVANCE(35); + if (lookahead == 'O') ADVANCE(44); END_STATE(); case 42: - if (lookahead == 'P') ADVANCE(95); + if (lookahead == 'O') ADVANCE(36); END_STATE(); case 43: - if (lookahead == 'P') ADVANCE(18); + if (lookahead == 'P') ADVANCE(94); END_STATE(); case 44: - if (lookahead == 'P') ADVANCE(53); + if (lookahead == 'P') ADVANCE(19); END_STATE(); case 45: - if (lookahead == 'R') ADVANCE(2); + if (lookahead == 'P') ADVANCE(54); END_STATE(); case 46: - if (lookahead == 'R') ADVANCE(19); - if (lookahead == 'T') ADVANCE(69); + if (lookahead == 'R') ADVANCE(3); END_STATE(); case 47: - if (lookahead == 'S') ADVANCE(75); + if (lookahead == 'R') ADVANCE(20); + if (lookahead == 'T') ADVANCE(68); END_STATE(); case 48: - if (lookahead == 'S') ADVANCE(50); + if (lookahead == 'S') ADVANCE(74); END_STATE(); case 49: - if (lookahead == 'T') ADVANCE(65); + if (lookahead == 'S') ADVANCE(51); END_STATE(); case 50: - if (lookahead == 'T') ADVANCE(67); + if (lookahead == 'T') ADVANCE(64); END_STATE(); case 51: - if (lookahead == 'T') ADVANCE(73); + if (lookahead == 'T') ADVANCE(66); END_STATE(); case 52: - if (lookahead == 'T') ADVANCE(42); + if (lookahead == 'T') ADVANCE(72); END_STATE(); case 53: - if (lookahead == 'T') ADVANCE(25); + if (lookahead == 'T') ADVANCE(43); END_STATE(); case 54: - if (lookahead == 'T') ADVANCE(4); + if (lookahead == 'T') ADVANCE(26); END_STATE(); case 55: - if (lookahead == 'T') ADVANCE(52); + if (lookahead == 'T') ADVANCE(5); END_STATE(); case 56: - if (lookahead == 'T') ADVANCE(14); + if (lookahead == 'T') ADVANCE(53); END_STATE(); case 57: - if (lookahead == 'W') ADVANCE(93); + if (lookahead == 'T') ADVANCE(15); END_STATE(); case 58: - if (lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || - lookahead == ' ') SKIP(58) - if (lookahead != 0) ADVANCE(158); + if (lookahead == 'W') ADVANCE(92); END_STATE(); case 59: - if (lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || - lookahead == ' ') ADVANCE(156); - if (('!' <= lookahead && lookahead <= '~')) ADVANCE(157); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(97); END_STATE(); case 60: - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(98); + if (('0' <= lookahead && lookahead <= '9')) ADVANCE(59); END_STATE(); case 61: - if (('0' <= lookahead && lookahead <= '9')) ADVANCE(60); - END_STATE(); - case 62: - if (eof) ADVANCE(63); - if (lookahead == 'C') ADVANCE(136); - if (lookahead == 'D') ADVANCE(107); - if (lookahead == 'G') ADVANCE(112); - if (lookahead == 'H') ADVANCE(152); - if (lookahead == 'L') ADVANCE(119); - if (lookahead == 'O') ADVANCE(141); - if (lookahead == 'P') ADVANCE(100); - if (lookahead == 'T') ADVANCE(142); - if (lookahead == 'U') ADVANCE(131); - if (lookahead == 'V') ADVANCE(118); + if (eof) ADVANCE(62); + if (lookahead == '#') ADVANCE(96); + if (lookahead == 'C') ADVANCE(135); + if (lookahead == 'D') ADVANCE(106); + if (lookahead == 'G') ADVANCE(111); + if (lookahead == 'H') ADVANCE(151); + if (lookahead == 'L') ADVANCE(118); + if (lookahead == 'O') ADVANCE(140); + if (lookahead == 'P') ADVANCE(99); + if (lookahead == 'T') ADVANCE(141); + if (lookahead == 'U') ADVANCE(130); + if (lookahead == 'V') ADVANCE(117); if (lookahead == '\t' || lookahead == '\n' || lookahead == '\r' || - lookahead == ' ') SKIP(62) + lookahead == ' ') SKIP(61) if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); - case 63: + case 62: ACCEPT_TOKEN(ts_builtin_sym_end); END_STATE(); - case 64: + case 63: ACCEPT_TOKEN(anon_sym_COLON); END_STATE(); + case 64: + ACCEPT_TOKEN(anon_sym_GET); + END_STATE(); case 65: - ACCEPT_TOKEN(anon_sym_GET); - END_STATE(); - case 66: ACCEPT_TOKEN(anon_sym_GET); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 66: + ACCEPT_TOKEN(anon_sym_POST); END_STATE(); case 67: - ACCEPT_TOKEN(anon_sym_POST); - END_STATE(); - case 68: ACCEPT_TOKEN(anon_sym_POST); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 68: + ACCEPT_TOKEN(anon_sym_PUT); END_STATE(); case 69: - ACCEPT_TOKEN(anon_sym_PUT); - END_STATE(); - case 70: ACCEPT_TOKEN(anon_sym_PUT); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 70: + ACCEPT_TOKEN(anon_sym_DELETE); END_STATE(); case 71: - ACCEPT_TOKEN(anon_sym_DELETE); - END_STATE(); - case 72: ACCEPT_TOKEN(anon_sym_DELETE); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 72: + ACCEPT_TOKEN(anon_sym_CONNECT); END_STATE(); case 73: - ACCEPT_TOKEN(anon_sym_CONNECT); - END_STATE(); - case 74: ACCEPT_TOKEN(anon_sym_CONNECT); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 74: + ACCEPT_TOKEN(anon_sym_OPTIONS); END_STATE(); case 75: - ACCEPT_TOKEN(anon_sym_OPTIONS); - END_STATE(); - case 76: ACCEPT_TOKEN(anon_sym_OPTIONS); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 76: + ACCEPT_TOKEN(anon_sym_TRACE); END_STATE(); case 77: - ACCEPT_TOKEN(anon_sym_TRACE); - END_STATE(); - case 78: ACCEPT_TOKEN(anon_sym_TRACE); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 78: + ACCEPT_TOKEN(anon_sym_PATCH); END_STATE(); case 79: - ACCEPT_TOKEN(anon_sym_PATCH); - END_STATE(); - case 80: ACCEPT_TOKEN(anon_sym_PATCH); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 80: + ACCEPT_TOKEN(anon_sym_LINK); END_STATE(); case 81: - ACCEPT_TOKEN(anon_sym_LINK); - END_STATE(); - case 82: ACCEPT_TOKEN(anon_sym_LINK); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 82: + ACCEPT_TOKEN(anon_sym_UNLINK); END_STATE(); case 83: - ACCEPT_TOKEN(anon_sym_UNLINK); - END_STATE(); - case 84: ACCEPT_TOKEN(anon_sym_UNLINK); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 84: + ACCEPT_TOKEN(anon_sym_PURGE); END_STATE(); case 85: - ACCEPT_TOKEN(anon_sym_PURGE); - END_STATE(); - case 86: ACCEPT_TOKEN(anon_sym_PURGE); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 86: + ACCEPT_TOKEN(anon_sym_LOCK); END_STATE(); case 87: - ACCEPT_TOKEN(anon_sym_LOCK); - END_STATE(); - case 88: ACCEPT_TOKEN(anon_sym_LOCK); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 88: + ACCEPT_TOKEN(anon_sym_UNLOCK); END_STATE(); case 89: - ACCEPT_TOKEN(anon_sym_UNLOCK); - END_STATE(); - case 90: ACCEPT_TOKEN(anon_sym_UNLOCK); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 90: + ACCEPT_TOKEN(anon_sym_PROPFIND); END_STATE(); case 91: - ACCEPT_TOKEN(anon_sym_PROPFIND); - END_STATE(); - case 92: ACCEPT_TOKEN(anon_sym_PROPFIND); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 92: + ACCEPT_TOKEN(anon_sym_VIEW); END_STATE(); case 93: - ACCEPT_TOKEN(anon_sym_VIEW); - END_STATE(); - case 94: ACCEPT_TOKEN(anon_sym_VIEW); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 94: + ACCEPT_TOKEN(sym_scheme_literal); END_STATE(); case 95: - ACCEPT_TOKEN(sym_scheme_literal); - END_STATE(); - case 96: ACCEPT_TOKEN(sym_scheme_literal); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 96: + ACCEPT_TOKEN(sym_comment); + if (lookahead != 0 && + lookahead != '\n') ADVANCE(96); END_STATE(); case 97: - ACCEPT_TOKEN(sym__space_literal); - if (lookahead == ' ') ADVANCE(97); + ACCEPT_TOKEN(sym_status_code_pattern); END_STATE(); case 98: - ACCEPT_TOKEN(sym_status_code_pattern); + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'A') ADVANCE(103); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('B' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 99: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'A') ADVANCE(104); + if (lookahead == 'A') ADVANCE(150); + if (lookahead == 'O') ADVANCE(144); + if (lookahead == 'R') ADVANCE(136); + if (lookahead == 'U') ADVANCE(142); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('B' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 100: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'A') ADVANCE(151); - if (lookahead == 'O') ADVANCE(145); - if (lookahead == 'R') ADVANCE(137); - if (lookahead == 'U') ADVANCE(143); + if (lookahead == 'C') ADVANCE(116); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || - ('B' <= lookahead && lookahead <= 'Z') || + ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 101: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'C') ADVANCE(117); + if (lookahead == 'C') ADVANCE(123); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 102: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'C') ADVANCE(124); + if (lookahead == 'C') ADVANCE(125); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 103: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'C') ADVANCE(126); + if (lookahead == 'C') ADVANCE(109); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 104: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'C') ADVANCE(110); + if (lookahead == 'C') ADVANCE(147); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 105: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'C') ADVANCE(148); + if (lookahead == 'D') ADVANCE(91); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 106: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'D') ADVANCE(92); + if (lookahead == 'E') ADVANCE(127); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 107: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(128); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 108: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(154); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 109: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(86); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 110: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(78); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 111: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(72); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 112: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(146); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 113: - ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'E') ADVANCE(105); - if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || - ('A' <= lookahead && lookahead <= 'Z') || - lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); - END_STATE(); - case 114: ACCEPT_TOKEN(sym_header_name); if (lookahead == 'E') ADVANCE(153); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 108: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(85); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 109: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(77); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 110: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(71); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 111: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(145); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 112: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(104); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 113: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'E') ADVANCE(152); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); + END_STATE(); + case 114: + ACCEPT_TOKEN(sym_header_name); + if (lookahead == 'F') ADVANCE(120); + if (lookahead == '-' || + ('0' <= lookahead && lookahead <= '9') || + ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '_' || + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 115: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'F') ADVANCE(121); + if (lookahead == 'G') ADVANCE(108); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 116: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'G') ADVANCE(109); + if (lookahead == 'H') ADVANCE(79); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 117: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'H') ADVANCE(80); + if (lookahead == 'I') ADVANCE(107); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 118: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'I') ADVANCE(108); + if (lookahead == 'I') ADVANCE(128); + if (lookahead == 'O') ADVANCE(101); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 119: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'I') ADVANCE(129); + if (lookahead == 'I') ADVANCE(132); if (lookahead == 'O') ADVANCE(102); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 120: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'I') ADVANCE(133); - if (lookahead == 'O') ADVANCE(103); + if (lookahead == 'I') ADVANCE(129); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 121: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'I') ADVANCE(130); + if (lookahead == 'I') ADVANCE(137); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 122: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'I') ADVANCE(138); + if (lookahead == 'K') ADVANCE(81); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 123: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'K') ADVANCE(82); + if (lookahead == 'K') ADVANCE(87); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 124: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'K') ADVANCE(88); + if (lookahead == 'K') ADVANCE(83); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 125: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'K') ADVANCE(84); + if (lookahead == 'K') ADVANCE(89); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 126: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'K') ADVANCE(90); + if (lookahead == 'L') ADVANCE(119); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 127: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'L') ADVANCE(120); + if (lookahead == 'L') ADVANCE(113); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 128: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'L') ADVANCE(114); + if (lookahead == 'N') ADVANCE(122); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 129: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(123); + if (lookahead == 'N') ADVANCE(105); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 130: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(106); + if (lookahead == 'N') ADVANCE(126); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 131: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(127); + if (lookahead == 'N') ADVANCE(143); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 132: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(144); + if (lookahead == 'N') ADVANCE(124); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 133: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(125); + if (lookahead == 'N') ADVANCE(112); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 134: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(113); + if (lookahead == 'N') ADVANCE(133); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 135: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'N') ADVANCE(134); + if (lookahead == 'O') ADVANCE(134); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 136: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'O') ADVANCE(135); + if (lookahead == 'O') ADVANCE(139); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 137: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'O') ADVANCE(140); + if (lookahead == 'O') ADVANCE(131); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 138: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'O') ADVANCE(132); + if (lookahead == 'P') ADVANCE(95); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 139: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'P') ADVANCE(96); + if (lookahead == 'P') ADVANCE(114); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 140: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'P') ADVANCE(115); + if (lookahead == 'P') ADVANCE(149); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 141: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'P') ADVANCE(150); + if (lookahead == 'R') ADVANCE(98); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 142: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'R') ADVANCE(99); + if (lookahead == 'R') ADVANCE(115); + if (lookahead == 'T') ADVANCE(69); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 143: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'R') ADVANCE(116); - if (lookahead == 'T') ADVANCE(70); + if (lookahead == 'S') ADVANCE(75); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 144: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'S') ADVANCE(76); + if (lookahead == 'S') ADVANCE(146); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 145: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'S') ADVANCE(147); + if (lookahead == 'T') ADVANCE(65); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 146: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(66); + if (lookahead == 'T') ADVANCE(67); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 147: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(68); + if (lookahead == 'T') ADVANCE(73); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 148: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(74); + if (lookahead == 'T') ADVANCE(138); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 149: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(139); + if (lookahead == 'T') ADVANCE(121); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 150: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(122); + if (lookahead == 'T') ADVANCE(100); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 151: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(101); + if (lookahead == 'T') ADVANCE(148); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 152: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(149); + if (lookahead == 'T') ADVANCE(110); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 153: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'T') ADVANCE(111); + if (lookahead == 'W') ADVANCE(93); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 154: ACCEPT_TOKEN(sym_header_name); - if (lookahead == 'W') ADVANCE(94); if (lookahead == '-' || ('0' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || lookahead == '_' || - ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); + ('a' <= lookahead && lookahead <= 'z')) ADVANCE(154); END_STATE(); case 155: - ACCEPT_TOKEN(sym_header_name); + ACCEPT_TOKEN(sym_header_value); if (lookahead == '-' || - ('0' <= lookahead && lookahead <= '9') || + ('/' <= lookahead && lookahead <= '9') || ('A' <= lookahead && lookahead <= 'Z') || + lookahead == '\\' || lookahead == '_' || ('a' <= lookahead && lookahead <= 'z')) ADVANCE(155); END_STATE(); case 156: - ACCEPT_TOKEN(sym_header_value); - if (lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || - lookahead == ' ') ADVANCE(156); - if (('!' <= lookahead && lookahead <= '~')) ADVANCE(157); - END_STATE(); - case 157: - ACCEPT_TOKEN(sym_header_value); - if (lookahead == '\t' || - lookahead == '\n' || - lookahead == '\r' || - (' ' <= lookahead && lookahead <= '~')) ADVANCE(157); - END_STATE(); - case 158: ACCEPT_TOKEN(sym_url); if (lookahead != 0 && lookahead != '\t' && lookahead != '\n' && lookahead != '\r' && - lookahead != ' ') ADVANCE(158); + lookahead != ' ') ADVANCE(156); END_STATE(); default: return false; @@ -1284,19 +1281,18 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) { static const TSLexMode ts_lex_modes[STATE_COUNT] = { [0] = {.lex_state = 0}, - [1] = {.lex_state = 62}, - [2] = {.lex_state = 62}, - [3] = {.lex_state = 62}, - [4] = {.lex_state = 62}, - [5] = {.lex_state = 62}, - [6] = {.lex_state = 62}, - [7] = {.lex_state = 58}, - [8] = {.lex_state = 1}, + [1] = {.lex_state = 61}, + [2] = {.lex_state = 61}, + [3] = {.lex_state = 61}, + [4] = {.lex_state = 61}, + [5] = {.lex_state = 61}, + [6] = {.lex_state = 61}, + [7] = {.lex_state = 2}, + [8] = {.lex_state = 0}, [9] = {.lex_state = 0}, [10] = {.lex_state = 0}, - [11] = {.lex_state = 58}, - [12] = {.lex_state = 0}, - [13] = {.lex_state = 59}, + [11] = {.lex_state = 2}, + [12] = {.lex_state = 1}, }; static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { @@ -1319,6 +1315,7 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [anon_sym_PROPFIND] = ACTIONS(1), [anon_sym_VIEW] = ACTIONS(1), [sym_scheme_literal] = ACTIONS(1), + [sym_comment] = ACTIONS(3), [sym_status_code_pattern] = ACTIONS(1), }, [1] = { @@ -1331,24 +1328,25 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym__literal] = STATE(11), [sym_request_literal] = STATE(11), [aux_sym_source_file_repeat1] = STATE(2), - [ts_builtin_sym_end] = ACTIONS(3), - [anon_sym_GET] = ACTIONS(5), - [anon_sym_POST] = ACTIONS(5), - [anon_sym_PUT] = ACTIONS(5), - [anon_sym_DELETE] = ACTIONS(5), - [anon_sym_CONNECT] = ACTIONS(5), - [anon_sym_OPTIONS] = ACTIONS(5), - [anon_sym_TRACE] = ACTIONS(5), - [anon_sym_PATCH] = ACTIONS(5), - [anon_sym_LINK] = ACTIONS(5), - [anon_sym_UNLINK] = ACTIONS(5), - [anon_sym_PURGE] = ACTIONS(5), - [anon_sym_LOCK] = ACTIONS(5), - [anon_sym_UNLOCK] = ACTIONS(5), - [anon_sym_PROPFIND] = ACTIONS(5), - [anon_sym_VIEW] = ACTIONS(5), - [sym_scheme_literal] = ACTIONS(7), - [sym_header_name] = ACTIONS(9), + [ts_builtin_sym_end] = ACTIONS(5), + [anon_sym_GET] = ACTIONS(7), + [anon_sym_POST] = ACTIONS(7), + [anon_sym_PUT] = ACTIONS(7), + [anon_sym_DELETE] = ACTIONS(7), + [anon_sym_CONNECT] = ACTIONS(7), + [anon_sym_OPTIONS] = ACTIONS(7), + [anon_sym_TRACE] = ACTIONS(7), + [anon_sym_PATCH] = ACTIONS(7), + [anon_sym_LINK] = ACTIONS(7), + [anon_sym_UNLINK] = ACTIONS(7), + [anon_sym_PURGE] = ACTIONS(7), + [anon_sym_LOCK] = ACTIONS(7), + [anon_sym_UNLOCK] = ACTIONS(7), + [anon_sym_PROPFIND] = ACTIONS(7), + [anon_sym_VIEW] = ACTIONS(7), + [sym_scheme_literal] = ACTIONS(9), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(11), }, [2] = { [sym__statement] = STATE(3), @@ -1359,24 +1357,25 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym__literal] = STATE(11), [sym_request_literal] = STATE(11), [aux_sym_source_file_repeat1] = STATE(3), - [ts_builtin_sym_end] = ACTIONS(11), - [anon_sym_GET] = ACTIONS(5), - [anon_sym_POST] = ACTIONS(5), - [anon_sym_PUT] = ACTIONS(5), - [anon_sym_DELETE] = ACTIONS(5), - [anon_sym_CONNECT] = ACTIONS(5), - [anon_sym_OPTIONS] = ACTIONS(5), - [anon_sym_TRACE] = ACTIONS(5), - [anon_sym_PATCH] = ACTIONS(5), - [anon_sym_LINK] = ACTIONS(5), - [anon_sym_UNLINK] = ACTIONS(5), - [anon_sym_PURGE] = ACTIONS(5), - [anon_sym_LOCK] = ACTIONS(5), - [anon_sym_UNLOCK] = ACTIONS(5), - [anon_sym_PROPFIND] = ACTIONS(5), - [anon_sym_VIEW] = ACTIONS(5), - [sym_scheme_literal] = ACTIONS(7), - [sym_header_name] = ACTIONS(9), + [ts_builtin_sym_end] = ACTIONS(13), + [anon_sym_GET] = ACTIONS(7), + [anon_sym_POST] = ACTIONS(7), + [anon_sym_PUT] = ACTIONS(7), + [anon_sym_DELETE] = ACTIONS(7), + [anon_sym_CONNECT] = ACTIONS(7), + [anon_sym_OPTIONS] = ACTIONS(7), + [anon_sym_TRACE] = ACTIONS(7), + [anon_sym_PATCH] = ACTIONS(7), + [anon_sym_LINK] = ACTIONS(7), + [anon_sym_UNLINK] = ACTIONS(7), + [anon_sym_PURGE] = ACTIONS(7), + [anon_sym_LOCK] = ACTIONS(7), + [anon_sym_UNLOCK] = ACTIONS(7), + [anon_sym_PROPFIND] = ACTIONS(7), + [anon_sym_VIEW] = ACTIONS(7), + [sym_scheme_literal] = ACTIONS(9), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(11), }, [3] = { [sym__statement] = STATE(3), @@ -1387,146 +1386,159 @@ static const uint16_t ts_parse_table[LARGE_STATE_COUNT][SYMBOL_COUNT] = { [sym__literal] = STATE(11), [sym_request_literal] = STATE(11), [aux_sym_source_file_repeat1] = STATE(3), - [ts_builtin_sym_end] = ACTIONS(13), - [anon_sym_GET] = ACTIONS(15), - [anon_sym_POST] = ACTIONS(15), - [anon_sym_PUT] = ACTIONS(15), - [anon_sym_DELETE] = ACTIONS(15), - [anon_sym_CONNECT] = ACTIONS(15), - [anon_sym_OPTIONS] = ACTIONS(15), - [anon_sym_TRACE] = ACTIONS(15), - [anon_sym_PATCH] = ACTIONS(15), - [anon_sym_LINK] = ACTIONS(15), - [anon_sym_UNLINK] = ACTIONS(15), - [anon_sym_PURGE] = ACTIONS(15), - [anon_sym_LOCK] = ACTIONS(15), - [anon_sym_UNLOCK] = ACTIONS(15), - [anon_sym_PROPFIND] = ACTIONS(15), - [anon_sym_VIEW] = ACTIONS(15), - [sym_scheme_literal] = ACTIONS(18), - [sym_header_name] = ACTIONS(21), + [ts_builtin_sym_end] = ACTIONS(15), + [anon_sym_GET] = ACTIONS(17), + [anon_sym_POST] = ACTIONS(17), + [anon_sym_PUT] = ACTIONS(17), + [anon_sym_DELETE] = ACTIONS(17), + [anon_sym_CONNECT] = ACTIONS(17), + [anon_sym_OPTIONS] = ACTIONS(17), + [anon_sym_TRACE] = ACTIONS(17), + [anon_sym_PATCH] = ACTIONS(17), + [anon_sym_LINK] = ACTIONS(17), + [anon_sym_UNLINK] = ACTIONS(17), + [anon_sym_PURGE] = ACTIONS(17), + [anon_sym_LOCK] = ACTIONS(17), + [anon_sym_UNLOCK] = ACTIONS(17), + [anon_sym_PROPFIND] = ACTIONS(17), + [anon_sym_VIEW] = ACTIONS(17), + [sym_scheme_literal] = ACTIONS(20), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(23), }, [4] = { - [ts_builtin_sym_end] = ACTIONS(24), - [anon_sym_GET] = ACTIONS(26), - [anon_sym_POST] = ACTIONS(26), - [anon_sym_PUT] = ACTIONS(26), - [anon_sym_DELETE] = ACTIONS(26), - [anon_sym_CONNECT] = ACTIONS(26), - [anon_sym_OPTIONS] = ACTIONS(26), - [anon_sym_TRACE] = ACTIONS(26), - [anon_sym_PATCH] = ACTIONS(26), - [anon_sym_LINK] = ACTIONS(26), - [anon_sym_UNLINK] = ACTIONS(26), - [anon_sym_PURGE] = ACTIONS(26), - [anon_sym_LOCK] = ACTIONS(26), - [anon_sym_UNLOCK] = ACTIONS(26), - [anon_sym_PROPFIND] = ACTIONS(26), - [anon_sym_VIEW] = ACTIONS(26), - [sym_scheme_literal] = ACTIONS(26), - [sym_header_name] = ACTIONS(26), + [ts_builtin_sym_end] = ACTIONS(26), + [anon_sym_GET] = ACTIONS(28), + [anon_sym_POST] = ACTIONS(28), + [anon_sym_PUT] = ACTIONS(28), + [anon_sym_DELETE] = ACTIONS(28), + [anon_sym_CONNECT] = ACTIONS(28), + [anon_sym_OPTIONS] = ACTIONS(28), + [anon_sym_TRACE] = ACTIONS(28), + [anon_sym_PATCH] = ACTIONS(28), + [anon_sym_LINK] = ACTIONS(28), + [anon_sym_UNLINK] = ACTIONS(28), + [anon_sym_PURGE] = ACTIONS(28), + [anon_sym_LOCK] = ACTIONS(28), + [anon_sym_UNLOCK] = ACTIONS(28), + [anon_sym_PROPFIND] = ACTIONS(28), + [anon_sym_VIEW] = ACTIONS(28), + [sym_scheme_literal] = ACTIONS(28), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(28), }, [5] = { - [ts_builtin_sym_end] = ACTIONS(28), - [anon_sym_GET] = ACTIONS(30), - [anon_sym_POST] = ACTIONS(30), - [anon_sym_PUT] = ACTIONS(30), - [anon_sym_DELETE] = ACTIONS(30), - [anon_sym_CONNECT] = ACTIONS(30), - [anon_sym_OPTIONS] = ACTIONS(30), - [anon_sym_TRACE] = ACTIONS(30), - [anon_sym_PATCH] = ACTIONS(30), - [anon_sym_LINK] = ACTIONS(30), - [anon_sym_UNLINK] = ACTIONS(30), - [anon_sym_PURGE] = ACTIONS(30), - [anon_sym_LOCK] = ACTIONS(30), - [anon_sym_UNLOCK] = ACTIONS(30), - [anon_sym_PROPFIND] = ACTIONS(30), - [anon_sym_VIEW] = ACTIONS(30), - [sym_scheme_literal] = ACTIONS(30), - [sym_header_name] = ACTIONS(30), + [ts_builtin_sym_end] = ACTIONS(30), + [anon_sym_GET] = ACTIONS(32), + [anon_sym_POST] = ACTIONS(32), + [anon_sym_PUT] = ACTIONS(32), + [anon_sym_DELETE] = ACTIONS(32), + [anon_sym_CONNECT] = ACTIONS(32), + [anon_sym_OPTIONS] = ACTIONS(32), + [anon_sym_TRACE] = ACTIONS(32), + [anon_sym_PATCH] = ACTIONS(32), + [anon_sym_LINK] = ACTIONS(32), + [anon_sym_UNLINK] = ACTIONS(32), + [anon_sym_PURGE] = ACTIONS(32), + [anon_sym_LOCK] = ACTIONS(32), + [anon_sym_UNLOCK] = ACTIONS(32), + [anon_sym_PROPFIND] = ACTIONS(32), + [anon_sym_VIEW] = ACTIONS(32), + [sym_scheme_literal] = ACTIONS(32), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(32), }, [6] = { - [ts_builtin_sym_end] = ACTIONS(32), - [anon_sym_GET] = ACTIONS(34), - [anon_sym_POST] = ACTIONS(34), - [anon_sym_PUT] = ACTIONS(34), - [anon_sym_DELETE] = ACTIONS(34), - [anon_sym_CONNECT] = ACTIONS(34), - [anon_sym_OPTIONS] = ACTIONS(34), - [anon_sym_TRACE] = ACTIONS(34), - [anon_sym_PATCH] = ACTIONS(34), - [anon_sym_LINK] = ACTIONS(34), - [anon_sym_UNLINK] = ACTIONS(34), - [anon_sym_PURGE] = ACTIONS(34), - [anon_sym_LOCK] = ACTIONS(34), - [anon_sym_UNLOCK] = ACTIONS(34), - [anon_sym_PROPFIND] = ACTIONS(34), - [anon_sym_VIEW] = ACTIONS(34), - [sym_scheme_literal] = ACTIONS(34), - [sym_header_name] = ACTIONS(34), + [ts_builtin_sym_end] = ACTIONS(34), + [anon_sym_GET] = ACTIONS(36), + [anon_sym_POST] = ACTIONS(36), + [anon_sym_PUT] = ACTIONS(36), + [anon_sym_DELETE] = ACTIONS(36), + [anon_sym_CONNECT] = ACTIONS(36), + [anon_sym_OPTIONS] = ACTIONS(36), + [anon_sym_TRACE] = ACTIONS(36), + [anon_sym_PATCH] = ACTIONS(36), + [anon_sym_LINK] = ACTIONS(36), + [anon_sym_UNLINK] = ACTIONS(36), + [anon_sym_PURGE] = ACTIONS(36), + [anon_sym_LOCK] = ACTIONS(36), + [anon_sym_UNLOCK] = ACTIONS(36), + [anon_sym_PROPFIND] = ACTIONS(36), + [anon_sym_VIEW] = ACTIONS(36), + [sym_scheme_literal] = ACTIONS(36), + [sym_comment] = ACTIONS(3), + [sym_header_name] = ACTIONS(36), }, }; static const uint16_t ts_small_parse_table[] = { - [0] = 1, - ACTIONS(36), 1, - sym_url, - [4] = 1, + [0] = 2, ACTIONS(38), 1, - sym__space_literal, - [8] = 1, + sym_comment, ACTIONS(40), 1, - anon_sym_COLON, - [12] = 1, - ACTIONS(42), 1, - ts_builtin_sym_end, - [16] = 1, - ACTIONS(44), 1, sym_url, - [20] = 1, - ACTIONS(46), 1, + [7] = 2, + ACTIONS(3), 1, + sym_comment, + ACTIONS(42), 1, sym_status_code_pattern, - [24] = 1, + [14] = 2, + ACTIONS(3), 1, + sym_comment, + ACTIONS(44), 1, + anon_sym_COLON, + [21] = 2, + ACTIONS(3), 1, + sym_comment, + ACTIONS(46), 1, + ts_builtin_sym_end, + [28] = 2, + ACTIONS(38), 1, + sym_comment, ACTIONS(48), 1, + sym_url, + [35] = 2, + ACTIONS(3), 1, + sym_comment, + ACTIONS(50), 1, sym_header_value, }; static const uint32_t ts_small_parse_table_map[] = { [SMALL_STATE(7)] = 0, - [SMALL_STATE(8)] = 4, - [SMALL_STATE(9)] = 8, - [SMALL_STATE(10)] = 12, - [SMALL_STATE(11)] = 16, - [SMALL_STATE(12)] = 20, - [SMALL_STATE(13)] = 24, + [SMALL_STATE(8)] = 7, + [SMALL_STATE(9)] = 14, + [SMALL_STATE(10)] = 21, + [SMALL_STATE(11)] = 28, + [SMALL_STATE(12)] = 35, }; 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 = false}}, SHIFT(7), - [7] = {.entry = {.count = 1, .reusable = false}}, SHIFT(8), - [9] = {.entry = {.count = 1, .reusable = false}}, SHIFT(9), - [11] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 1), - [13] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_source_file_repeat1, 2), - [15] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(7), - [18] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(8), - [21] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(9), - [24] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_request_declaration, 2, .production_id = 1), - [26] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_request_declaration, 2, .production_id = 1), - [28] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_http_response_declaration, 3), - [30] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_http_response_declaration, 3), - [32] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_header_declaration, 3, .production_id = 2), - [34] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_header_declaration, 3, .production_id = 2), - [36] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_request_literal, 1), - [38] = {.entry = {.count = 1, .reusable = true}}, SHIFT(12), - [40] = {.entry = {.count = 1, .reusable = true}}, SHIFT(13), - [42] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), - [44] = {.entry = {.count = 1, .reusable = true}}, SHIFT(4), - [46] = {.entry = {.count = 1, .reusable = true}}, SHIFT(5), - [48] = {.entry = {.count = 1, .reusable = true}}, SHIFT(6), + [3] = {.entry = {.count = 1, .reusable = true}}, SHIFT_EXTRA(), + [5] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 0), + [7] = {.entry = {.count = 1, .reusable = false}}, SHIFT(7), + [9] = {.entry = {.count = 1, .reusable = false}}, SHIFT(8), + [11] = {.entry = {.count = 1, .reusable = false}}, SHIFT(9), + [13] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_source_file, 1), + [15] = {.entry = {.count = 1, .reusable = true}}, REDUCE(aux_sym_source_file_repeat1, 2), + [17] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(7), + [20] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(8), + [23] = {.entry = {.count = 2, .reusable = false}}, REDUCE(aux_sym_source_file_repeat1, 2), SHIFT_REPEAT(9), + [26] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_http_response_declaration, 2), + [28] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_http_response_declaration, 2), + [30] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_request_declaration, 2, .production_id = 1), + [32] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_request_declaration, 2, .production_id = 1), + [34] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_header_declaration, 3, .production_id = 2), + [36] = {.entry = {.count = 1, .reusable = false}}, REDUCE(sym_header_declaration, 3, .production_id = 2), + [38] = {.entry = {.count = 1, .reusable = false}}, SHIFT_EXTRA(), + [40] = {.entry = {.count = 1, .reusable = true}}, REDUCE(sym_request_literal, 1), + [42] = {.entry = {.count = 1, .reusable = true}}, SHIFT(4), + [44] = {.entry = {.count = 1, .reusable = true}}, SHIFT(12), + [46] = {.entry = {.count = 1, .reusable = true}}, ACCEPT_INPUT(), + [48] = {.entry = {.count = 1, .reusable = true}}, SHIFT(5), + [50] = {.entry = {.count = 1, .reusable = true}}, SHIFT(6), }; #ifdef __cplusplus