File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ repository:
124124
125125 method-declaration :
126126 name : meta.method.declaration.ts
127- begin : ' (?:\b(get|set)\s+)?(?:(new)|(?:([a-zA-Z_$][\.\w$]*)\s*(\??)))?\s*(?=\()'
127+ begin : ' (?:\b(get|set)\s+)?(?:(new)|(?:([a-zA-Z_$][\.\w$]*)\s*(\??)))?\s*(?=\(|\< )'
128128 beginCaptures :
129129 ' 1 ' : { name: storage.type.property.ts }
130130 ' 2 ' : { name: keyword.operator.ts }
@@ -133,6 +133,7 @@ repository:
133133 end : ' (?=\}|;|,)|(?<=\})'
134134 patterns :
135135 - include : ' #comment'
136+ - include : ' #type-parameters'
136137 - include : ' #function-parameters'
137138 - include : ' #type-annotation'
138139 - include : ' #decl-block'
@@ -241,7 +242,7 @@ repository:
241242 type-annotation :
242243 name : meta.type.annotation.ts
243244 begin : " :"
244- end : (?=$|[,);\}\[\]]|//)|(?==[^>])|(?<=\}|[a-z ]|>)\s*(?=\{)
245+ end : (?=$|[,);\}\[\]]|//)|(?==[^>])|(?<=\}|[a-zA-Z_$ ]|>)\s*(?=\{)
245246 patterns :
246247 - include : ' #type'
247248 - include : ' #comment'
Original file line number Diff line number Diff line change 660660 <key >method-declaration </key >
661661 <dict >
662662 <key >begin </key >
663- <string >(?:\b(get|set)\s+)?(?:(new)|(?:([a-zA-Z_$][\.\w$]*)\s*(\??)))?\s*(?=\() </string >
663+ <string >(?:\b(get|set)\s+)?(?:(new)|(?:([a-zA-Z_$][\.\w$]*)\s*(\??)))?\s*(?=\(|\ < ) </string >
664664 <key >beginCaptures </key >
665665 <dict >
666666 <key >1 </key >
694694 <key >include </key >
695695 <string >#comment </string >
696696 </dict >
697+ <dict >
698+ <key >include </key >
699+ <string >#type-parameters </string >
700+ </dict >
697701 <dict >
698702 <key >include </key >
699703 <string >#function-parameters </string >
12791283 <key >begin </key >
12801284 <string >: </string >
12811285 <key >end </key >
1282- <string >(?=$|[,);\}\[\]]|//)|(?==[^> ])|(?< =\}|[a-z ]|> )\s*(?=\{) </string >
1286+ <string >(?=$|[,);\}\[\]]|//)|(?==[^> ])|(?< =\}|[a-zA-Z_$ ]|> )\s*(?=\{) </string >
12831287 <key >name </key >
12841288 <string >meta.type.annotation.ts </string >
12851289 <key >patterns </key >
You can’t perform that action at this time.
0 commit comments