aboutsummaryrefslogtreecommitdiff
path: root/src/parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser.c')
-rw-r--r--src/parser.c40
1 files changed, 20 insertions, 20 deletions
diff --git a/src/parser.c b/src/parser.c
index 983827a..97761e6 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -336,18 +336,18 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) {
if (lookahead != 0) ADVANCE(16);
END_STATE();
case 4:
- if (lookahead == '-' ||
- ('0' <= lookahead && lookahead <= '9') ||
- ('A' <= lookahead && lookahead <= 'Z') ||
- lookahead == '_' ||
- ('a' <= lookahead && lookahead <= 'z')) ADVANCE(19);
+ if (lookahead != 0 &&
+ lookahead != '\t' &&
+ lookahead != '\n' &&
+ lookahead != '\r' &&
+ lookahead != ' ') ADVANCE(19);
END_STATE();
case 5:
- if (lookahead == '-' ||
- ('0' <= lookahead && lookahead <= '9') ||
- ('A' <= lookahead && lookahead <= 'Z') ||
- lookahead == '_' ||
- ('a' <= lookahead && lookahead <= 'z')) ADVANCE(18);
+ if (lookahead != 0 &&
+ lookahead != '\t' &&
+ lookahead != '\n' &&
+ lookahead != '\r' &&
+ lookahead != ' ') ADVANCE(18);
END_STATE();
case 6:
if (lookahead != 0 &&
@@ -403,19 +403,19 @@ static bool ts_lex(TSLexer *lexer, TSStateId state) {
END_STATE();
case 18:
ACCEPT_TOKEN(sym_class_shorthand);
- if (lookahead == '-' ||
- ('0' <= lookahead && lookahead <= '9') ||
- ('A' <= lookahead && lookahead <= 'Z') ||
- lookahead == '_' ||
- ('a' <= lookahead && lookahead <= 'z')) ADVANCE(18);
+ if (lookahead != 0 &&
+ lookahead != '\t' &&
+ lookahead != '\n' &&
+ lookahead != '\r' &&
+ lookahead != ' ') ADVANCE(18);
END_STATE();
case 19:
ACCEPT_TOKEN(sym_id_shorthand);
- if (lookahead == '-' ||
- ('0' <= lookahead && lookahead <= '9') ||
- ('A' <= lookahead && lookahead <= 'Z') ||
- lookahead == '_' ||
- ('a' <= lookahead && lookahead <= 'z')) ADVANCE(19);
+ if (lookahead != 0 &&
+ lookahead != '\t' &&
+ lookahead != '\n' &&
+ lookahead != '\r' &&
+ lookahead != ' ') ADVANCE(19);
END_STATE();
case 20:
ACCEPT_TOKEN(sym_attribute_name);