Skip to content

Commit 9b7ab10

Browse files
committed
Improve parser and add correct unescape function
1 parent e0992ff commit 9b7ab10

14 files changed

+2283
-3839
lines changed

parser/Expr.g4

Lines changed: 77 additions & 483 deletions
Large diffs are not rendered by default.

parser/gen/expr.interp

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
token literal names:
22
null
33
'..'
4+
'startsWith'
5+
'endsWith'
6+
'contains'
7+
'matches'
8+
'in'
9+
'not in'
410
'len'
511
'all'
612
'none'
@@ -22,7 +28,9 @@ null
2228
'.'
2329
'+'
2430
'-'
25-
null
31+
'!'
32+
'not'
33+
'nil'
2634
'*'
2735
'**'
2836
'/'
@@ -39,13 +47,7 @@ null
3947
null
4048
null
4149
null
42-
'startsWith'
43-
'endsWith'
44-
'contains'
45-
'matches'
46-
'in'
47-
'not in'
48-
'nil'
50+
null
4951
null
5052
null
5153
null
@@ -68,6 +70,12 @@ null
6870
null
6971
null
7072
null
73+
null
74+
null
75+
null
76+
null
77+
null
78+
null
7179
OpenBracket
7280
CloseBracket
7381
OpenParen
@@ -82,7 +90,9 @@ Colon
8290
Dot
8391
Plus
8492
Minus
93+
Negate
8594
Not
95+
Nil
8696
Multiply
8797
Exponent
8898
Divide
@@ -99,13 +109,7 @@ Pointer
99109
And
100110
Or
101111
Builtins
102-
StartsWith
103-
EndsWith
104-
Contains
105-
Matches
106-
In
107-
NotIn
108-
NilLiteral
112+
Ops
109113
BooleanLiteral
110114
IntegerLiteral
111115
FloatLiteral
@@ -129,10 +133,7 @@ mapLiteral
129133
propertyNameAndValueList
130134
propertyAssignment
131135
propertyName
132-
literal
133-
stringLiteral
134-
integerLiteral
135136

136137

137138
atn:
138-
[3, 24715, 42794, 33075, 47597, 16764, 15335, 30598, 22884, 3, 59, 225, 4, 2, 9, 2, 4, 3, 9, 3, 4, 4, 9, 4, 4, 5, 9, 5, 4, 6, 9, 6, 4, 7, 9, 7, 4, 8, 9, 8, 4, 9, 9, 9, 4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 3, 7, 3, 7, 5, 7, 187, 10, 7, 3, 8, 3, 8, 3, 8, 3, 8, 3, 8, 5, 8, 194, 10, 8, 3, 8, 3, 8, 5, 8, 198, 10, 8, 3, 9, 3, 9, 3, 9, 7, 9, 203, 10, 9, 12, 9, 14, 9, 206, 11, 9, 3, 10, 3, 10, 3, 10, 3, 10, 3, 11, 3, 11, 3, 12, 3, 12, 3, 12, 3, 12, 3, 12, 5, 12, 219, 10, 12, 3, 13, 3, 13, 3, 14, 3, 14, 3, 14, 2, 3, 4, 15, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 2, 10, 3, 2, 23, 25, 3, 2, 26, 29, 3, 2, 23, 24, 3, 2, 32, 35, 3, 2, 46, 47, 3, 2, 36, 37, 3, 2, 53, 54, 4, 2, 50, 50, 52, 52, 2, 253, 2, 28, 3, 2, 2, 2, 4, 46, 3, 2, 2, 2, 6, 156, 3, 2, 2, 2, 8, 158, 3, 2, 2, 2, 10, 162, 3, 2, 2, 2, 12, 186, 3, 2, 2, 2, 14, 197, 3, 2, 2, 2, 16, 199, 3, 2, 2, 2, 18, 207, 3, 2, 2, 2, 20, 211, 3, 2, 2, 2, 22, 218, 3, 2, 2, 2, 24, 220, 3, 2, 2, 2, 26, 222, 3, 2, 2, 2, 28, 29, 5, 4, 3, 2, 29, 30, 7, 2, 2, 3, 30, 3, 3, 2, 2, 2, 31, 32, 8, 3, 1, 2, 32, 33, 7, 22, 2, 2, 33, 47, 7, 53, 2, 2, 34, 47, 5, 6, 4, 2, 35, 36, 9, 2, 2, 2, 36, 47, 5, 4, 3, 22, 37, 47, 7, 53, 2, 2, 38, 47, 7, 38, 2, 2, 39, 47, 5, 22, 12, 2, 40, 47, 5, 12, 7, 2, 41, 47, 5, 14, 8, 2, 42, 43, 7, 13, 2, 2, 43, 44, 5, 4, 3, 2, 44, 45, 7, 14, 2, 2, 45, 47, 3, 2, 2, 2, 46, 31, 3, 2, 2, 2, 46, 34, 3, 2, 2, 2, 46, 35, 3, 2, 2, 2, 46, 37, 3, 2, 2, 2, 46, 38, 3, 2, 2, 2, 46, 39, 3, 2, 2, 2, 46, 40, 3, 2, 2, 2, 46, 41, 3, 2, 2, 2, 46, 42, 3, 2, 2, 2, 47, 106, 3, 2, 2, 2, 48, 49, 12, 21, 2, 2, 49, 50, 7, 3, 2, 2, 50, 105, 5, 4, 3, 22, 51, 52, 12, 20, 2, 2, 52, 53, 9, 3, 2, 2, 53, 105, 5, 4, 3, 21, 54, 55, 12, 19, 2, 2, 55, 56, 9, 4, 2, 2, 56, 105, 5, 4, 3, 20, 57, 58, 12, 18, 2, 2, 58, 59, 9, 5, 2, 2, 59, 105, 5, 4, 3, 19, 60, 61, 12, 17, 2, 2, 61, 62, 7, 42, 2, 2, 62, 105, 5, 4, 3, 18, 63, 64, 12, 16, 2, 2, 64, 65, 7, 43, 2, 2, 65, 105, 5, 4, 3, 17, 66, 67, 12, 15, 2, 2, 67, 68, 7, 44, 2, 2, 68, 105, 5, 4, 3, 16, 69, 70, 12, 14, 2, 2, 70, 71, 7, 45, 2, 2, 71, 105, 5, 4, 3, 15, 72, 73, 12, 13, 2, 2, 73, 74, 9, 6, 2, 2, 74, 105, 5, 4, 3, 14, 75, 76, 12, 12, 2, 2, 76, 77, 9, 7, 2, 2, 77, 105, 5, 4, 3, 13, 78, 79, 12, 11, 2, 2, 79, 80, 7, 39, 2, 2, 80, 105, 5, 4, 3, 12, 81, 82, 12, 10, 2, 2, 82, 83, 7, 40, 2, 2, 83, 105, 5, 4, 3, 11, 84, 85, 12, 9, 2, 2, 85, 86, 7, 20, 2, 2, 86, 87, 5, 4, 3, 2, 87, 88, 7, 21, 2, 2, 88, 89, 5, 4, 3, 10, 89, 105, 3, 2, 2, 2, 90, 91, 12, 26, 2, 2, 91, 92, 7, 11, 2, 2, 92, 93, 5, 4, 3, 2, 93, 94, 7, 12, 2, 2, 94, 105, 3, 2, 2, 2, 95, 96, 12, 25, 2, 2, 96, 97, 7, 22, 2, 2, 97, 105, 7, 53, 2, 2, 98, 99, 12, 23, 2, 2, 99, 101, 7, 13, 2, 2, 100, 102, 5, 10, 6, 2, 101, 100, 3, 2, 2, 2, 101, 102, 3, 2, 2, 2, 102, 103, 3, 2, 2, 2, 103, 105, 7, 14, 2, 2, 104, 48, 3, 2, 2, 2, 104, 51, 3, 2, 2, 2, 104, 54, 3, 2, 2, 2, 104, 57, 3, 2, 2, 2, 104, 60, 3, 2, 2, 2, 104, 63, 3, 2, 2, 2, 104, 66, 3, 2, 2, 2, 104, 69, 3, 2, 2, 2, 104, 72, 3, 2, 2, 2, 104, 75, 3, 2, 2, 2, 104, 78, 3, 2, 2, 2, 104, 81, 3, 2, 2, 2, 104, 84, 3, 2, 2, 2, 104, 90, 3, 2, 2, 2, 104, 95, 3, 2, 2, 2, 104, 98, 3, 2, 2, 2, 105, 108, 3, 2, 2, 2, 106, 104, 3, 2, 2, 2, 106, 107, 3, 2, 2, 2, 107, 5, 3, 2, 2, 2, 108, 106, 3, 2, 2, 2, 109, 110, 7, 4, 2, 2, 110, 111, 7, 13, 2, 2, 111, 112, 5, 4, 3, 2, 112, 113, 7, 14, 2, 2, 113, 157, 3, 2, 2, 2, 114, 115, 7, 5, 2, 2, 115, 116, 7, 13, 2, 2, 116, 117, 5, 4, 3, 2, 117, 118, 7, 18, 2, 2, 118, 119, 5, 8, 5, 2, 119, 120, 7, 14, 2, 2, 120, 157, 3, 2, 2, 2, 121, 122, 7, 6, 2, 2, 122, 123, 7, 13, 2, 2, 123, 124, 5, 4, 3, 2, 124, 125, 7, 18, 2, 2, 125, 126, 5, 8, 5, 2, 126, 127, 7, 14, 2, 2, 127, 157, 3, 2, 2, 2, 128, 129, 7, 7, 2, 2, 129, 130, 7, 13, 2, 2, 130, 131, 5, 4, 3, 2, 131, 132, 7, 18, 2, 2, 132, 133, 5, 8, 5, 2, 133, 134, 7, 14, 2, 2, 134, 157, 3, 2, 2, 2, 135, 136, 7, 8, 2, 2, 136, 137, 7, 13, 2, 2, 137, 138, 5, 4, 3, 2, 138, 139, 7, 18, 2, 2, 139, 140, 5, 8, 5, 2, 140, 141, 7, 14, 2, 2, 141, 157, 3, 2, 2, 2, 142, 143, 7, 9, 2, 2, 143, 144, 7, 13, 2, 2, 144, 145, 5, 4, 3, 2, 145, 146, 7, 18, 2, 2, 146, 147, 5, 8, 5, 2, 147, 148, 7, 14, 2, 2, 148, 157, 3, 2, 2, 2, 149, 150, 7, 10, 2, 2, 150, 151, 7, 13, 2, 2, 151, 152, 5, 4, 3, 2, 152, 153, 7, 18, 2, 2, 153, 154, 5, 8, 5, 2, 154, 155, 7, 14, 2, 2, 155, 157, 3, 2, 2, 2, 156, 109, 3, 2, 2, 2, 156, 114, 3, 2, 2, 2, 156, 121, 3, 2, 2, 2, 156, 128, 3, 2, 2, 2, 156, 135, 3, 2, 2, 2, 156, 142, 3, 2, 2, 2, 156, 149, 3, 2, 2, 2, 157, 7, 3, 2, 2, 2, 158, 159, 7, 15, 2, 2, 159, 160, 5, 4, 3, 2, 160, 161, 7, 16, 2, 2, 161, 9, 3, 2, 2, 2, 162, 167, 5, 4, 3, 2, 163, 164, 7, 18, 2, 2, 164, 166, 5, 4, 3, 2, 165, 163, 3, 2, 2, 2, 166, 169, 3, 2, 2, 2, 167, 165, 3, 2, 2, 2, 167, 168, 3, 2, 2, 2, 168, 11, 3, 2, 2, 2, 169, 167, 3, 2, 2, 2, 170, 171, 7, 11, 2, 2, 171, 187, 7, 12, 2, 2, 172, 173, 7, 11, 2, 2, 173, 178, 5, 4, 3, 2, 174, 175, 7, 18, 2, 2, 175, 177, 5, 4, 3, 2, 176, 174, 3, 2, 2, 2, 177, 180, 3, 2, 2, 2, 178, 176, 3, 2, 2, 2, 178, 179, 3, 2, 2, 2, 179, 182, 3, 2, 2, 2, 180, 178, 3, 2, 2, 2, 181, 183, 7, 18, 2, 2, 182, 181, 3, 2, 2, 2, 182, 183, 3, 2, 2, 2, 183, 184, 3, 2, 2, 2, 184, 185, 7, 12, 2, 2, 185, 187, 3, 2, 2, 2, 186, 170, 3, 2, 2, 2, 186, 172, 3, 2, 2, 2, 187, 13, 3, 2, 2, 2, 188, 189, 7, 15, 2, 2, 189, 198, 7, 16, 2, 2, 190, 191, 7, 15, 2, 2, 191, 193, 5, 16, 9, 2, 192, 194, 7, 18, 2, 2, 193, 192, 3, 2, 2, 2, 193, 194, 3, 2, 2, 2, 194, 195, 3, 2, 2, 2, 195, 196, 7, 16, 2, 2, 196, 198, 3, 2, 2, 2, 197, 188, 3, 2, 2, 2, 197, 190, 3, 2, 2, 2, 198, 15, 3, 2, 2, 2, 199, 204, 5, 18, 10, 2, 200, 201, 7, 18, 2, 2, 201, 203, 5, 18, 10, 2, 202, 200, 3, 2, 2, 2, 203, 206, 3, 2, 2, 2, 204, 202, 3, 2, 2, 2, 204, 205, 3, 2, 2, 2, 205, 17, 3, 2, 2, 2, 206, 204, 3, 2, 2, 2, 207, 208, 5, 20, 11, 2, 208, 209, 7, 21, 2, 2, 209, 210, 5, 4, 3, 2, 210, 19, 3, 2, 2, 2, 211, 212, 9, 8, 2, 2, 212, 21, 3, 2, 2, 2, 213, 219, 7, 48, 2, 2, 214, 219, 7, 49, 2, 2, 215, 219, 5, 24, 13, 2, 216, 219, 5, 26, 14, 2, 217, 219, 7, 51, 2, 2, 218, 213, 3, 2, 2, 2, 218, 214, 3, 2, 2, 2, 218, 215, 3, 2, 2, 2, 218, 216, 3, 2, 2, 2, 218, 217, 3, 2, 2, 2, 219, 23, 3, 2, 2, 2, 220, 221, 7, 54, 2, 2, 221, 25, 3, 2, 2, 2, 222, 223, 9, 9, 2, 2, 223, 27, 3, 2, 2, 2, 15, 46, 101, 104, 106, 156, 167, 178, 182, 186, 193, 197, 204, 218]
139+
[3, 24715, 42794, 33075, 47597, 16764, 15335, 30598, 22884, 3, 61, 213, 4, 2, 9, 2, 4, 3, 9, 3, 4, 4, 9, 4, 4, 5, 9, 5, 4, 6, 9, 6, 4, 7, 9, 7, 4, 8, 9, 8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 182, 10, 7, 3, 7, 3, 7, 5, 7, 186, 10, 7, 3, 8, 3, 8, 3, 8, 3, 8, 3, 8, 5, 8, 193, 10, 8, 3, 8, 3, 8, 5, 8, 197, 10, 8, 3, 9, 3, 9, 3, 9, 7, 9, 202, 10, 9, 12, 9, 14, 9, 205, 11, 9, 3, 10, 3, 10, 3, 10, 3, 10, 3, 11, 3, 11, 3, 11, 2, 3, 4, 12, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 2, 9, 3, 2, 29, 32, 3, 2, 34, 37, 3, 2, 29, 30, 3, 2, 40, 43, 3, 2, 8, 9, 3, 2, 44, 45, 3, 2, 55, 56, 2, 245, 2, 22, 3, 2, 2, 2, 4, 45, 3, 2, 2, 2, 6, 155, 3, 2, 2, 2, 8, 157, 3, 2, 2, 2, 10, 161, 3, 2, 2, 2, 12, 185, 3, 2, 2, 2, 14, 196, 3, 2, 2, 2, 16, 198, 3, 2, 2, 2, 18, 206, 3, 2, 2, 2, 20, 210, 3, 2, 2, 2, 22, 23, 5, 4, 3, 2, 23, 24, 7, 2, 2, 3, 24, 3, 3, 2, 2, 2, 25, 26, 8, 3, 1, 2, 26, 27, 7, 28, 2, 2, 27, 46, 7, 55, 2, 2, 28, 46, 5, 6, 4, 2, 29, 30, 9, 2, 2, 2, 30, 46, 5, 4, 3, 27, 31, 46, 7, 33, 2, 2, 32, 46, 7, 51, 2, 2, 33, 46, 7, 56, 2, 2, 34, 46, 7, 52, 2, 2, 35, 46, 7, 54, 2, 2, 36, 46, 7, 53, 2, 2, 37, 46, 7, 55, 2, 2, 38, 46, 7, 46, 2, 2, 39, 46, 5, 12, 7, 2, 40, 46, 5, 14, 8, 2, 41, 42, 7, 19, 2, 2, 42, 43, 5, 4, 3, 2, 43, 44, 7, 20, 2, 2, 44, 46, 3, 2, 2, 2, 45, 25, 3, 2, 2, 2, 45, 28, 3, 2, 2, 2, 45, 29, 3, 2, 2, 2, 45, 31, 3, 2, 2, 2, 45, 32, 3, 2, 2, 2, 45, 33, 3, 2, 2, 2, 45, 34, 3, 2, 2, 2, 45, 35, 3, 2, 2, 2, 45, 36, 3, 2, 2, 2, 45, 37, 3, 2, 2, 2, 45, 38, 3, 2, 2, 2, 45, 39, 3, 2, 2, 2, 45, 40, 3, 2, 2, 2, 45, 41, 3, 2, 2, 2, 46, 105, 3, 2, 2, 2, 47, 48, 12, 26, 2, 2, 48, 49, 7, 3, 2, 2, 49, 104, 5, 4, 3, 27, 50, 51, 12, 25, 2, 2, 51, 52, 9, 3, 2, 2, 52, 104, 5, 4, 3, 26, 53, 54, 12, 24, 2, 2, 54, 55, 9, 4, 2, 2, 55, 104, 5, 4, 3, 25, 56, 57, 12, 23, 2, 2, 57, 58, 9, 5, 2, 2, 58, 104, 5, 4, 3, 24, 59, 60, 12, 22, 2, 2, 60, 61, 7, 4, 2, 2, 61, 104, 5, 4, 3, 23, 62, 63, 12, 21, 2, 2, 63, 64, 7, 5, 2, 2, 64, 104, 5, 4, 3, 22, 65, 66, 12, 20, 2, 2, 66, 67, 7, 6, 2, 2, 67, 104, 5, 4, 3, 21, 68, 69, 12, 19, 2, 2, 69, 70, 7, 7, 2, 2, 70, 104, 5, 4, 3, 20, 71, 72, 12, 18, 2, 2, 72, 73, 9, 6, 2, 2, 73, 104, 5, 4, 3, 19, 74, 75, 12, 17, 2, 2, 75, 76, 9, 7, 2, 2, 76, 104, 5, 4, 3, 18, 77, 78, 12, 16, 2, 2, 78, 79, 7, 47, 2, 2, 79, 104, 5, 4, 3, 17, 80, 81, 12, 15, 2, 2, 81, 82, 7, 48, 2, 2, 82, 104, 5, 4, 3, 16, 83, 84, 12, 14, 2, 2, 84, 85, 7, 26, 2, 2, 85, 86, 5, 4, 3, 2, 86, 87, 7, 27, 2, 2, 87, 88, 5, 4, 3, 15, 88, 104, 3, 2, 2, 2, 89, 90, 12, 31, 2, 2, 90, 91, 7, 17, 2, 2, 91, 92, 5, 4, 3, 2, 92, 93, 7, 18, 2, 2, 93, 104, 3, 2, 2, 2, 94, 95, 12, 30, 2, 2, 95, 96, 7, 28, 2, 2, 96, 104, 7, 55, 2, 2, 97, 98, 12, 28, 2, 2, 98, 100, 7, 19, 2, 2, 99, 101, 5, 10, 6, 2, 100, 99, 3, 2, 2, 2, 100, 101, 3, 2, 2, 2, 101, 102, 3, 2, 2, 2, 102, 104, 7, 20, 2, 2, 103, 47, 3, 2, 2, 2, 103, 50, 3, 2, 2, 2, 103, 53, 3, 2, 2, 2, 103, 56, 3, 2, 2, 2, 103, 59, 3, 2, 2, 2, 103, 62, 3, 2, 2, 2, 103, 65, 3, 2, 2, 2, 103, 68, 3, 2, 2, 2, 103, 71, 3, 2, 2, 2, 103, 74, 3, 2, 2, 2, 103, 77, 3, 2, 2, 2, 103, 80, 3, 2, 2, 2, 103, 83, 3, 2, 2, 2, 103, 89, 3, 2, 2, 2, 103, 94, 3, 2, 2, 2, 103, 97, 3, 2, 2, 2, 104, 107, 3, 2, 2, 2, 105, 103, 3, 2, 2, 2, 105, 106, 3, 2, 2, 2, 106, 5, 3, 2, 2, 2, 107, 105, 3, 2, 2, 2, 108, 109, 7, 10, 2, 2, 109, 110, 7, 19, 2, 2, 110, 111, 5, 4, 3, 2, 111, 112, 7, 20, 2, 2, 112, 156, 3, 2, 2, 2, 113, 114, 7, 11, 2, 2, 114, 115, 7, 19, 2, 2, 115, 116, 5, 4, 3, 2, 116, 117, 7, 24, 2, 2, 117, 118, 5, 8, 5, 2, 118, 119, 7, 20, 2, 2, 119, 156, 3, 2, 2, 2, 120, 121, 7, 12, 2, 2, 121, 122, 7, 19, 2, 2, 122, 123, 5, 4, 3, 2, 123, 124, 7, 24, 2, 2, 124, 125, 5, 8, 5, 2, 125, 126, 7, 20, 2, 2, 126, 156, 3, 2, 2, 2, 127, 128, 7, 13, 2, 2, 128, 129, 7, 19, 2, 2, 129, 130, 5, 4, 3, 2, 130, 131, 7, 24, 2, 2, 131, 132, 5, 8, 5, 2, 132, 133, 7, 20, 2, 2, 133, 156, 3, 2, 2, 2, 134, 135, 7, 14, 2, 2, 135, 136, 7, 19, 2, 2, 136, 137, 5, 4, 3, 2, 137, 138, 7, 24, 2, 2, 138, 139, 5, 8, 5, 2, 139, 140, 7, 20, 2, 2, 140, 156, 3, 2, 2, 2, 141, 142, 7, 15, 2, 2, 142, 143, 7, 19, 2, 2, 143, 144, 5, 4, 3, 2, 144, 145, 7, 24, 2, 2, 145, 146, 5, 8, 5, 2, 146, 147, 7, 20, 2, 2, 147, 156, 3, 2, 2, 2, 148, 149, 7, 16, 2, 2, 149, 150, 7, 19, 2, 2, 150, 151, 5, 4, 3, 2, 151, 152, 7, 24, 2, 2, 152, 153, 5, 8, 5, 2, 153, 154, 7, 20, 2, 2, 154, 156, 3, 2, 2, 2, 155, 108, 3, 2, 2, 2, 155, 113, 3, 2, 2, 2, 155, 120, 3, 2, 2, 2, 155, 127, 3, 2, 2, 2, 155, 134, 3, 2, 2, 2, 155, 141, 3, 2, 2, 2, 155, 148, 3, 2, 2, 2, 156, 7, 3, 2, 2, 2, 157, 158, 7, 21, 2, 2, 158, 159, 5, 4, 3, 2, 159, 160, 7, 22, 2, 2, 160, 9, 3, 2, 2, 2, 161, 166, 5, 4, 3, 2, 162, 163, 7, 24, 2, 2, 163, 165, 5, 4, 3, 2, 164, 162, 3, 2, 2, 2, 165, 168, 3, 2, 2, 2, 166, 164, 3, 2, 2, 2, 166, 167, 3, 2, 2, 2, 167, 11, 3, 2, 2, 2, 168, 166, 3, 2, 2, 2, 169, 170, 7, 17, 2, 2, 170, 186, 7, 18, 2, 2, 171, 172, 7, 17, 2, 2, 172, 177, 5, 4, 3, 2, 173, 174, 7, 24, 2, 2, 174, 176, 5, 4, 3, 2, 175, 173, 3, 2, 2, 2, 176, 179, 3, 2, 2, 2, 177, 175, 3, 2, 2, 2, 177, 178, 3, 2, 2, 2, 178, 181, 3, 2, 2, 2, 179, 177, 3, 2, 2, 2, 180, 182, 7, 24, 2, 2, 181, 180, 3, 2, 2, 2, 181, 182, 3, 2, 2, 2, 182, 183, 3, 2, 2, 2, 183, 184, 7, 18, 2, 2, 184, 186, 3, 2, 2, 2, 185, 169, 3, 2, 2, 2, 185, 171, 3, 2, 2, 2, 186, 13, 3, 2, 2, 2, 187, 188, 7, 21, 2, 2, 188, 197, 7, 22, 2, 2, 189, 190, 7, 21, 2, 2, 190, 192, 5, 16, 9, 2, 191, 193, 7, 24, 2, 2, 192, 191, 3, 2, 2, 2, 192, 193, 3, 2, 2, 2, 193, 194, 3, 2, 2, 2, 194, 195, 7, 22, 2, 2, 195, 197, 3, 2, 2, 2, 196, 187, 3, 2, 2, 2, 196, 189, 3, 2, 2, 2, 197, 15, 3, 2, 2, 2, 198, 203, 5, 18, 10, 2, 199, 200, 7, 24, 2, 2, 200, 202, 5, 18, 10, 2, 201, 199, 3, 2, 2, 2, 202, 205, 3, 2, 2, 2, 203, 201, 3, 2, 2, 2, 203, 204, 3, 2, 2, 2, 204, 17, 3, 2, 2, 2, 205, 203, 3, 2, 2, 2, 206, 207, 5, 20, 11, 2, 207, 208, 7, 27, 2, 2, 208, 209, 5, 4, 3, 2, 209, 19, 3, 2, 2, 2, 210, 211, 9, 8, 2, 2, 211, 21, 3, 2, 2, 2, 14, 45, 100, 103, 105, 155, 166, 177, 181, 185, 192, 196, 203]

parser/gen/expr.tokens

Lines changed: 94 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -6,94 +6,98 @@ T__4=5
66
T__5=6
77
T__6=7
88
T__7=8
9-
OpenBracket=9
10-
CloseBracket=10
11-
OpenParen=11
12-
CloseParen=12
13-
OpenBrace=13
14-
CloseBrace=14
15-
SemiColon=15
16-
Comma=16
17-
Assign=17
18-
QuestionMark=18
19-
Colon=19
20-
Dot=20
21-
Plus=21
22-
Minus=22
23-
Not=23
24-
Multiply=24
25-
Exponent=25
26-
Divide=26
27-
Modulus=27
28-
RightShiftArithmetic=28
29-
LeftShiftArithmetic=29
30-
LessThan=30
31-
MoreThan=31
32-
LessThanEquals=32
33-
GreaterThanEquals=33
34-
Equals=34
35-
NotEquals=35
36-
Pointer=36
37-
And=37
38-
Or=38
39-
Builtins=39
40-
StartsWith=40
41-
EndsWith=41
42-
Contains=42
43-
Matches=43
44-
In=44
45-
NotIn=45
46-
NilLiteral=46
47-
BooleanLiteral=47
48-
IntegerLiteral=48
49-
FloatLiteral=49
50-
HexIntegerLiteral=50
51-
Identifier=51
52-
StringLiteral=52
53-
WhiteSpaces=53
54-
MultiLineComment=54
55-
SingleLineComment=55
56-
LineTerminator=56
57-
UnexpectedCharacter=57
9+
T__8=9
10+
T__9=10
11+
T__10=11
12+
T__11=12
13+
T__12=13
14+
T__13=14
15+
OpenBracket=15
16+
CloseBracket=16
17+
OpenParen=17
18+
CloseParen=18
19+
OpenBrace=19
20+
CloseBrace=20
21+
SemiColon=21
22+
Comma=22
23+
Assign=23
24+
QuestionMark=24
25+
Colon=25
26+
Dot=26
27+
Plus=27
28+
Minus=28
29+
Negate=29
30+
Not=30
31+
Nil=31
32+
Multiply=32
33+
Exponent=33
34+
Divide=34
35+
Modulus=35
36+
RightShiftArithmetic=36
37+
LeftShiftArithmetic=37
38+
LessThan=38
39+
MoreThan=39
40+
LessThanEquals=40
41+
GreaterThanEquals=41
42+
Equals=42
43+
NotEquals=43
44+
Pointer=44
45+
And=45
46+
Or=46
47+
Builtins=47
48+
Ops=48
49+
BooleanLiteral=49
50+
IntegerLiteral=50
51+
FloatLiteral=51
52+
HexIntegerLiteral=52
53+
Identifier=53
54+
StringLiteral=54
55+
WhiteSpaces=55
56+
MultiLineComment=56
57+
SingleLineComment=57
58+
LineTerminator=58
59+
UnexpectedCharacter=59
5860
'..'=1
59-
'len'=2
60-
'all'=3
61-
'none'=4
62-
'any'=5
63-
'one'=6
64-
'filter'=7
65-
'map'=8
66-
'['=9
67-
']'=10
68-
'('=11
69-
')'=12
70-
'{'=13
71-
'}'=14
72-
';'=15
73-
','=16
74-
'='=17
75-
'?'=18
76-
':'=19
77-
'.'=20
78-
'+'=21
79-
'-'=22
80-
'*'=24
81-
'**'=25
82-
'/'=26
83-
'%'=27
84-
'>>'=28
85-
'<<'=29
86-
'<'=30
87-
'>'=31
88-
'<='=32
89-
'>='=33
90-
'=='=34
91-
'!='=35
92-
'#'=36
93-
'startsWith'=40
94-
'endsWith'=41
95-
'contains'=42
96-
'matches'=43
97-
'in'=44
98-
'not in'=45
99-
'nil'=46
61+
'startsWith'=2
62+
'endsWith'=3
63+
'contains'=4
64+
'matches'=5
65+
'in'=6
66+
'not in'=7
67+
'len'=8
68+
'all'=9
69+
'none'=10
70+
'any'=11
71+
'one'=12
72+
'filter'=13
73+
'map'=14
74+
'['=15
75+
']'=16
76+
'('=17
77+
')'=18
78+
'{'=19
79+
'}'=20
80+
';'=21
81+
','=22
82+
'='=23
83+
'?'=24
84+
':'=25
85+
'.'=26
86+
'+'=27
87+
'-'=28
88+
'!'=29
89+
'not'=30
90+
'nil'=31
91+
'*'=32
92+
'**'=33
93+
'/'=34
94+
'%'=35
95+
'>>'=36
96+
'<<'=37
97+
'<'=38
98+
'>'=39
99+
'<='=40
100+
'>='=41
101+
'=='=42
102+
'!='=43
103+
'#'=44

0 commit comments

Comments
 (0)