File tree 5 files changed +47
-6
lines changed
5 files changed +47
-6
lines changed Original file line number Diff line number Diff line change @@ -1245,7 +1245,7 @@ repository:
1245
1245
- name : keyword.operator.arithmetic.ts
1246
1246
match : ' %|\*|/|-|\+'
1247
1247
# capture the arithmetic sign followed by variable or parenthesized expression so that it is not interpreted as regex
1248
- - match : (?<=[_$[:alnum:])])\s*(/)(?![/*])
1248
+ - match : (?<=[_$[:alnum:])\] ])\s*(/)(?![/*])
1249
1249
captures :
1250
1250
' 1 ' : { name: keyword.operator.arithmetic.ts }
1251
1251
@@ -2033,7 +2033,7 @@ repository:
2033
2033
- include : ' #regexp'
2034
2034
# Check if complete regexp syntax
2035
2035
- name : string.regexp.ts
2036
- begin : (?<![_$[:alnum:])])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$]))
2036
+ begin : (?<![_$[:alnum:])\] ])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$]))
2037
2037
beginCaptures :
2038
2038
' 0 ' : {name: punctuation.definition.string.begin.ts}
2039
2039
end : (/)([gimuy]*)
Original file line number Diff line number Diff line change 3868
3868
</dict >
3869
3869
<dict >
3870
3870
<key >match </key >
3871
- <string >(?< =[_$[:alnum:])])\s*(/)(?![/*]) </string >
3871
+ <string >(?< =[_$[:alnum:])\] ])\s*(/)(?![/*]) </string >
3872
3872
<key >captures </key >
3873
3873
<dict >
3874
3874
<key >1 </key >
5738
5738
<key >name </key >
5739
5739
<string >string.regexp.ts </string >
5740
5740
<key >begin </key >
5741
- <string >(?< ![_$[:alnum:])])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$])) </string >
5741
+ <string >(?< ![_$[:alnum:])\] ])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$])) </string >
5742
5742
<key >beginCaptures </key >
5743
5743
<dict >
5744
5744
<key >0 </key >
Original file line number Diff line number Diff line change 3814
3814
</dict >
3815
3815
<dict >
3816
3816
<key >match </key >
3817
- <string >(?< =[_$[:alnum:])])\s*(/)(?![/*]) </string >
3817
+ <string >(?< =[_$[:alnum:])\] ])\s*(/)(?![/*]) </string >
3818
3818
<key >captures </key >
3819
3819
<dict >
3820
3820
<key >1 </key >
5684
5684
<key >name </key >
5685
5685
<string >string.regexp.tsx </string >
5686
5686
<key >begin </key >
5687
- <string >(?< ![_$[:alnum:])])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$])) </string >
5687
+ <string >(?< ![_$[:alnum:])\] ])\/(?![\/*])(?=(?:[^\/\\\[]|\\.|\[([^\]\\]|\\.)+\])+\/(?![\/*])[gimuy]*(?!\s*[a-zA-Z0-9_$])) </string >
5688
5688
<key >beginCaptures </key >
5689
5689
<dict >
5690
5690
<key >0 </key >
Original file line number Diff line number Diff line change
1
+ original file
2
+ -----------------------------------
3
+ (a[0] / 2) / (2)
4
+ -----------------------------------
5
+
6
+ Grammar: TypeScript.tmLanguage
7
+ -----------------------------------
8
+ >(a[0] / 2) / (2)
9
+ ^
10
+ source.ts meta.brace.round.ts
11
+ ^
12
+ source.ts variable.other.readwrite.ts
13
+ ^
14
+ source.ts meta.array.literal.ts meta.brace.square.ts
15
+ ^
16
+ source.ts meta.array.literal.ts constant.numeric.decimal.ts
17
+ ^
18
+ source.ts meta.array.literal.ts meta.brace.square.ts
19
+ ^
20
+ source.ts
21
+ ^
22
+ source.ts keyword.operator.arithmetic.ts
23
+ ^
24
+ source.ts
25
+ ^
26
+ source.ts constant.numeric.decimal.ts
27
+ ^
28
+ source.ts meta.brace.round.ts
29
+ ^
30
+ source.ts
31
+ ^
32
+ source.ts keyword.operator.arithmetic.ts
33
+ ^
34
+ source.ts
35
+ ^
36
+ source.ts meta.brace.round.ts
37
+ ^
38
+ source.ts constant.numeric.decimal.ts
39
+ ^
40
+ source.ts meta.brace.round.ts
Original file line number Diff line number Diff line change
1
+ ( a [ 0 ] / 2 ) / ( 2 )
You can’t perform that action at this time.
0 commit comments