github-linguist 7.9.0 → 7.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/grammars/etc.json +260 -1
  3. data/grammars/hidden.manref.json +1 -1
  4. data/grammars/hidden.regexp.injection-shell.json +28 -0
  5. data/grammars/source.4dm.json +57 -1
  6. data/grammars/source.abap.json +1 -1
  7. data/grammars/source.abl.json +685 -83
  8. data/grammars/source.agda.json +7 -7
  9. data/grammars/source.ballerina.json +1 -1
  10. data/grammars/source.c++.json +4 -4
  11. data/grammars/source.c.platform.json +584 -33
  12. data/grammars/source.chapel.json +5 -2
  13. data/grammars/source.css.json +1 -1
  14. data/grammars/source.curlrc.json +4 -4
  15. data/grammars/source.d.json +2 -2
  16. data/grammars/source.futhark.json +146 -0
  17. data/grammars/source.gcode.json +2 -2
  18. data/grammars/source.gedcom.json +196 -0
  19. data/grammars/source.generic-db.json +41 -0
  20. data/grammars/source.gfm.blade.json +15 -0
  21. data/grammars/source.gfm.json +1697 -1439
  22. data/grammars/source.httpspec.json +1 -1
  23. data/grammars/source.hx.json +5 -5
  24. data/grammars/source.hxml.json +2 -2
  25. data/grammars/source.idris.json +1 -1
  26. data/grammars/source.inputrc.json +1 -1
  27. data/grammars/source.isabelle.root.json +1 -1
  28. data/grammars/source.jison.json +3 -0
  29. data/grammars/source.jisonlex.json +3 -0
  30. data/grammars/source.julia.json +1 -1
  31. data/grammars/source.kotlin.json +17 -51
  32. data/grammars/source.lcov.json +398 -0
  33. data/grammars/source.lean.json +1 -1
  34. data/grammars/source.m2.json +125 -0
  35. data/grammars/source.man-conf.json +2 -2
  36. data/grammars/source.modula-3.json +10 -0
  37. data/grammars/{source.mrc.json → source.msl.json} +114 -99
  38. data/grammars/source.neon.json +381 -0
  39. data/grammars/source.objc.platform.json +493 -35
  40. data/grammars/source.openbsd-pkg.contents.json +128 -0
  41. data/grammars/source.p4.json +5 -21
  42. data/grammars/source.perl6fe.json +1 -1
  43. data/grammars/source.postscript.json +358 -103
  44. data/grammars/source.prisma.json +1 -1
  45. data/grammars/source.purescript.json +29 -2
  46. data/grammars/source.python.json +50 -0
  47. data/grammars/source.q.json +150 -63
  48. data/grammars/source.r.json +4 -4
  49. data/grammars/source.sieve.json +383 -0
  50. data/grammars/source.solidity.json +1 -1
  51. data/grammars/source.tags.json +266 -0
  52. data/grammars/source.ts.json +104 -36
  53. data/grammars/source.tsx.json +104 -36
  54. data/grammars/source.v.json +55 -24
  55. data/grammars/source.viml.json +3 -3
  56. data/grammars/source.webidl.json +8 -0
  57. data/grammars/source.wsd.json +25 -19
  58. data/grammars/source.x86.json +7 -3
  59. data/grammars/source.zig.json +84 -78
  60. data/grammars/text.dfy.dafny.json +188 -0
  61. data/grammars/text.html.php.blade.json +535 -528
  62. data/grammars/text.openbsd-pkg.desc.json +78 -0
  63. data/grammars/text.roff.json +49 -1
  64. data/grammars/text.sfd.json +21 -0
  65. data/grammars/text.xml.svg.json +8 -2
  66. data/grammars/version +1 -1
  67. data/lib/linguist/VERSION +1 -1
  68. data/lib/linguist/generated.rb +23 -6
  69. data/lib/linguist/languages.json +1 -1
  70. data/lib/linguist/languages.yml +74 -6
  71. data/lib/linguist/samples.json +4614 -150
  72. data/lib/linguist/vendor.yml +64 -62
  73. metadata +22 -10
  74. data/grammars/text.html.abl.json +0 -70
@@ -9,13 +9,7 @@
9
9
  "include": "#statements"
10
10
  },
11
11
  {
12
- "name": "comment.line.shebang.ts",
13
- "match": "\\A(#!).*(?=$)",
14
- "captures": {
15
- "1": {
16
- "name": "punctuation.definition.comment.ts"
17
- }
18
- }
12
+ "include": "#shebang"
19
13
  }
20
14
  ],
21
15
  "repository": {
@@ -132,7 +126,7 @@
132
126
  },
133
127
  {
134
128
  "name": "meta.arrow.tsx",
135
- "begin": "(?x) (?:\n (?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(\\basync)\n)? ((?\u003c![})!\\]])\\s*\n (?=\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n )\n)",
129
+ "begin": "(?x) (?:\n (?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(\\basync)\n)? ((?\u003c![})!\\]])\\s*\n (?=\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n )\n)",
136
130
  "end": "(?==\u003e|\\{|(^\\s*(export|function|class|interface|let|var|const|import|enum|namespace|module|type|abstract|declare)\\s+))",
137
131
  "patterns": [
138
132
  {
@@ -1422,7 +1416,7 @@
1422
1416
  }
1423
1417
  },
1424
1418
  {
1425
- "match": "(?x)(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(public|private|protected|readonly)\\s+)?(?:(\\.\\.\\.)\\s*)?(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
1419
+ "match": "(?x)(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(public|private|protected|readonly)\\s+)?(?:(\\.\\.\\.)\\s*)?(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
1426
1420
  "captures": {
1427
1421
  "1": {
1428
1422
  "name": "storage.modifier.tsx"
@@ -1555,7 +1549,7 @@
1555
1549
  },
1556
1550
  {
1557
1551
  "begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+",
1558
- "end": "(?=$|^|[;,:})\\]]|\\|\\||\\\u0026\\\u0026|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+)|(\\s+\\\u003c))",
1552
+ "end": "(?=^|[;),}\\]:?\\-\\+\\\u003e]|\\|\\||\\\u0026\\\u0026|\\!\\=\\=|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+)|(\\s+\\\u003c))",
1559
1553
  "patterns": [
1560
1554
  {
1561
1555
  "include": "#type"
@@ -1592,7 +1586,7 @@
1592
1586
  "match": "\u003c=|\u003e=|\u003c\u003e|\u003c|\u003e"
1593
1587
  },
1594
1588
  {
1595
- "match": "(\\!)\\s*(/)(?![/*])",
1589
+ "match": "(?\u003c=[_$[:alnum:]])(\\!)\\s*(/)(?![/*])",
1596
1590
  "captures": {
1597
1591
  "1": {
1598
1592
  "name": "keyword.operator.logical.tsx"
@@ -1742,7 +1736,7 @@
1742
1736
  "include": "#comment"
1743
1737
  },
1744
1738
  {
1745
- "match": "(?x)(\\#?[_$[:alpha:]][_$[:alnum:]]*)(?:(\\?)|(\\!))?(?=\\s*\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
1739
+ "match": "(?x)(\\#?[_$[:alpha:]][_$[:alnum:]]*)(?:(\\?)|(\\!))?(?=\\s*\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
1746
1740
  "captures": {
1747
1741
  "1": {
1748
1742
  "name": "meta.definition.property.tsx entity.name.function.tsx"
@@ -1841,26 +1835,64 @@
1841
1835
  ]
1842
1836
  },
1843
1837
  "function-call": {
1844
- "begin": "(?=(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))\\s*(?:(\\?\\.\\s*)|(\\!))?(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\()",
1845
- "end": "(?\u003c=\\))(?!(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))\\s*(?:(\\?\\.\\s*)|(\\!))?(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\()",
1846
1838
  "patterns": [
1847
1839
  {
1848
- "name": "meta.function-call.tsx",
1849
- "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))",
1850
- "end": "(?=\\s*(?:(\\?\\.\\s*)|(\\!))?(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\()",
1840
+ "begin": "(?=(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))\\s*(?:(\\?\\.\\s*)|(\\!))?((\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\())",
1841
+ "end": "(?\u003c=\\))(?!(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))\\s*(?:(\\?\\.\\s*)|(\\!))?((\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\())",
1851
1842
  "patterns": [
1852
1843
  {
1853
- "include": "#support-function-call-identifiers"
1844
+ "name": "meta.function-call.tsx",
1845
+ "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))",
1846
+ "end": "(?=\\s*(?:(\\?\\.\\s*)|(\\!))?((\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?\\())",
1847
+ "patterns": [
1848
+ {
1849
+ "include": "#function-call-target"
1850
+ }
1851
+ ]
1852
+ },
1853
+ {
1854
+ "include": "#comment"
1855
+ },
1856
+ {
1857
+ "include": "#function-call-optionals"
1854
1858
  },
1855
1859
  {
1856
- "name": "entity.name.function.tsx",
1857
- "match": "(\\#?[_$[:alpha:]][_$[:alnum:]]*)"
1860
+ "include": "#type-arguments"
1861
+ },
1862
+ {
1863
+ "include": "#paren-expression"
1858
1864
  }
1859
1865
  ]
1860
1866
  },
1861
1867
  {
1862
- "include": "#comment"
1863
- },
1868
+ "begin": "(?=(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))(\u003c\\s*[\\{\\[\\(]\\s*$))",
1869
+ "end": "(?\u003c=\\\u003e)(?!(((([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))|(?\u003c=[\\)]))(\u003c\\s*[\\{\\[\\(]\\s*$))",
1870
+ "patterns": [
1871
+ {
1872
+ "name": "meta.function-call.tsx",
1873
+ "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*)(\\s*\\??\\.\\s*(\\#?[_$[:alpha:]][_$[:alnum:]]*))*)|(\\??\\.\\s*\\#?[_$[:alpha:]][_$[:alnum:]]*))",
1874
+ "end": "(?=(\u003c\\s*[\\{\\[\\(]\\s*$))",
1875
+ "patterns": [
1876
+ {
1877
+ "include": "#function-call-target"
1878
+ }
1879
+ ]
1880
+ },
1881
+ {
1882
+ "include": "#comment"
1883
+ },
1884
+ {
1885
+ "include": "#function-call-optionals"
1886
+ },
1887
+ {
1888
+ "include": "#type-arguments"
1889
+ }
1890
+ ]
1891
+ }
1892
+ ]
1893
+ },
1894
+ "function-call-optionals": {
1895
+ "patterns": [
1864
1896
  {
1865
1897
  "name": "meta.function-call.tsx punctuation.accessor.optional.tsx",
1866
1898
  "match": "\\?\\."
@@ -1868,12 +1900,17 @@
1868
1900
  {
1869
1901
  "name": "meta.function-call.tsx keyword.operator.definiteassignment.tsx",
1870
1902
  "match": "\\!"
1871
- },
1903
+ }
1904
+ ]
1905
+ },
1906
+ "function-call-target": {
1907
+ "patterns": [
1872
1908
  {
1873
- "include": "#type-arguments"
1909
+ "include": "#support-function-call-identifiers"
1874
1910
  },
1875
1911
  {
1876
- "include": "#paren-expression"
1912
+ "name": "entity.name.function.tsx",
1913
+ "match": "(\\#?[_$[:alpha:]][_$[:alnum:]]*)"
1877
1914
  }
1878
1915
  ]
1879
1916
  },
@@ -1999,7 +2036,7 @@
1999
2036
  "include": "#object-identifiers"
2000
2037
  },
2001
2038
  {
2002
- "match": "(?x)(?:(?:(\\.)|(\\?\\.(?!\\s*[[:digit:]])))\\s*)?([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n))",
2039
+ "match": "(?x)(?:(?:(\\.)|(\\?\\.(?!\\s*[[:digit:]])))\\s*)?([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n))",
2003
2040
  "captures": {
2004
2041
  "1": {
2005
2042
  "name": "punctuation.accessor.tsx"
@@ -2472,7 +2509,7 @@
2472
2509
  },
2473
2510
  "instanceof-expr": {
2474
2511
  "begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(instanceof)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
2475
- "end": "(?\u003c=\\))|(?=[;),}\\]:?]|\\|\\||\\\u0026\\\u0026|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
2512
+ "end": "(?\u003c=\\))|(?=[;),}\\]:?\\-\\+\\\u003e]|\\|\\||\\\u0026\\\u0026|\\!\\=\\=|$|(([\\\u0026\\~\\^\\|]\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s+instanceof(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
2476
2513
  "patterns": [
2477
2514
  {
2478
2515
  "include": "#type"
@@ -3072,7 +3109,7 @@
3072
3109
  "new-expr": {
3073
3110
  "name": "new.expr.tsx",
3074
3111
  "begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(new)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
3075
- "end": "(?\u003c=\\))|(?=[;),}\\]:\\-\\+]|\\|\\||\\\u0026\\\u0026|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))new(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
3112
+ "end": "(?\u003c=\\))|(?=[;),}\\]:?\\-\\+\\\u003e]|\\|\\||\\\u0026\\\u0026|\\!\\=\\=|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))new(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
3076
3113
  "patterns": [
3077
3114
  {
3078
3115
  "include": "#paren-expression"
@@ -3488,7 +3525,7 @@
3488
3525
  },
3489
3526
  {
3490
3527
  "name": "meta.object.member.tsx",
3491
- "match": "(?x)(?:([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*:(\\s*\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/)*\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
3528
+ "match": "(?x)(?:([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*:(\\s*\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/)*\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
3492
3529
  "captures": {
3493
3530
  "0": {
3494
3531
  "name": "meta.object-literal.key.tsx"
@@ -3546,7 +3583,7 @@
3546
3583
  {
3547
3584
  "name": "meta.object.member.tsx",
3548
3585
  "begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+",
3549
- "end": "(?=$|^|[,}]|\\|\\||\\\u0026\\\u0026|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+))",
3586
+ "end": "(?=[;),}\\]:?\\-\\+\\\u003e]|\\|\\||\\\u0026\\\u0026|\\!\\=\\=|$|^|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(as)\\s+))",
3550
3587
  "patterns": [
3551
3588
  {
3552
3589
  "include": "#type"
@@ -3743,7 +3780,7 @@
3743
3780
  }
3744
3781
  },
3745
3782
  {
3746
- "match": "(?x)(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(public|private|protected|readonly)\\s+)?(?:(\\.\\.\\.)\\s*)?(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
3783
+ "match": "(?x)(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(public|private|protected|readonly)\\s+)?(?:(\\.\\.\\.)\\s*)?(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
3747
3784
  "captures": {
3748
3785
  "1": {
3749
3786
  "name": "storage.modifier.tsx"
@@ -4284,6 +4321,15 @@
4284
4321
  }
4285
4322
  ]
4286
4323
  },
4324
+ "shebang": {
4325
+ "name": "comment.line.shebang.tsx",
4326
+ "match": "\\A(#!).*(?=$)",
4327
+ "captures": {
4328
+ "1": {
4329
+ "name": "punctuation.definition.comment.tsx"
4330
+ }
4331
+ }
4332
+ },
4287
4333
  "single-line-comment-consuming-line-ending": {
4288
4334
  "contentName": "comment.line.double-slash.tsx",
4289
4335
  "begin": "(^[ \\t]+)?((//)(?:\\s*((@)internal)(?=\\s|$))?)",
@@ -4709,12 +4755,12 @@
4709
4755
  "patterns": [
4710
4756
  {
4711
4757
  "name": "string.template.tsx",
4712
- "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?`)",
4758
+ "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)(\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?`)",
4713
4759
  "end": "(?=`)",
4714
4760
  "patterns": [
4715
4761
  {
4716
4762
  "begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*))",
4717
- "end": "(?=(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?`)",
4763
+ "end": "(?=(\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)?`)",
4718
4764
  "patterns": [
4719
4765
  {
4720
4766
  "include": "#support-function-call-identifiers"
@@ -4732,7 +4778,7 @@
4732
4778
  },
4733
4779
  {
4734
4780
  "name": "string.template.tsx",
4735
- "begin": "([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=(\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)`)",
4781
+ "begin": "([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=(\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))(([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer|awaited|typeof|readonly)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?\u003c!=)\\\u003e))*(?\u003c!=)\\\u003e)*(?\u003c!=)\u003e\\s*)`)",
4736
4782
  "end": "(?=`)",
4737
4783
  "patterns": [
4738
4784
  {
@@ -5299,6 +5345,10 @@
5299
5345
  "name": "keyword.operator.expression.infer.tsx",
5300
5346
  "match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))infer(?=\\s+[_$[:alpha:]])"
5301
5347
  },
5348
+ {
5349
+ "name": "keyword.operator.expression.awaited.tsx",
5350
+ "match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))awaited(?=\\s+[_$[:alpha:]])"
5351
+ },
5302
5352
  {
5303
5353
  "name": "keyword.operator.expression.import.tsx",
5304
5354
  "match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))import(?=\\s*\\()"
@@ -5458,6 +5508,24 @@
5458
5508
  "begin": "\\[",
5459
5509
  "end": "\\]",
5460
5510
  "patterns": [
5511
+ {
5512
+ "name": "keyword.operator.rest.tsx",
5513
+ "match": "\\.\\.\\."
5514
+ },
5515
+ {
5516
+ "match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))([_$[:alpha:]][_$[:alnum:]]*)\\s*(\\?)?\\s*(:)",
5517
+ "captures": {
5518
+ "1": {
5519
+ "name": "entity.name.label.tsx"
5520
+ },
5521
+ "2": {
5522
+ "name": "keyword.operator.optional.tsx"
5523
+ },
5524
+ "3": {
5525
+ "name": "punctuation.separator.label.tsx"
5526
+ }
5527
+ }
5528
+ },
5461
5529
  {
5462
5530
  "include": "#type"
5463
5531
  },
@@ -5629,7 +5697,7 @@
5629
5697
  "patterns": [
5630
5698
  {
5631
5699
  "name": "meta.var-single-variable.expr.tsx",
5632
- "begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
5700
+ "begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
5633
5701
  "end": "(?=$|^|[;,=}]|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(of|in)\\s+))",
5634
5702
  "patterns": [
5635
5703
  {
@@ -5663,7 +5731,7 @@
5663
5731
  "patterns": [
5664
5732
  {
5665
5733
  "name": "meta.var-single-variable.expr.tsx",
5666
- "begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(\\!)?(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
5734
+ "begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(\\!)?(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))Function(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))) |\n(:\\s*((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*))))))) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ((\u003c\\s*$)|([\\(]\\s*((([\\{\\[]\\s*)?$)|((\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})\\s*((:\\s*\\{?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))|((\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])\\s*((:\\s*\\[?$)|((\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+\\s*)?=\\s*)))))) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)?\n [(]\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\.\\.\\.\\s*[_$[:alpha:]]))([^()\\'\\\"\\`]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\'([^\\'\\\\]|\\\\.)*\\')|(\\\"([^\\\"\\\\]|\\\\.)*\\\")|(\\`([^\\`\\\\]|\\\\.)*\\`))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)\\{\\}]|\\\u003c([^\u003c\u003e]|\\\u003c[^\u003c\u003e]+\\\u003e)+\\\u003e|\\([^\\(\\)]+\\)|\\{[^\\{\\}]+\\})+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
5667
5735
  "end": "(?=$|^|[;,=}]|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(of|in)\\s+))",
5668
5736
  "patterns": [
5669
5737
  {
@@ -6,7 +6,7 @@
6
6
  "include": "#comments"
7
7
  },
8
8
  {
9
- "include": "#as"
9
+ "include": "#as-is"
10
10
  },
11
11
  {
12
12
  "include": "#attributes"
@@ -85,12 +85,12 @@
85
85
  }
86
86
  ],
87
87
  "repository": {
88
- "as": {
89
- "begin": "\\s+(as)\\s+",
88
+ "as-is": {
89
+ "begin": "\\s+(as|is)\\s+",
90
90
  "end": "([\\w.]*)",
91
91
  "beginCaptures": {
92
92
  "1": {
93
- "name": "keyword.as.v"
93
+ "name": "keyword.$1.v"
94
94
  }
95
95
  },
96
96
  "endCaptures": {
@@ -224,7 +224,7 @@
224
224
  },
225
225
  {
226
226
  "name": "keyword.control.v",
227
- "match": "\\b(in|or|break|continue|default|unsafe|match|if|else|for|go|goto|defer|return)\\b(?=\\s*\\()"
227
+ "match": "\\b(in|is|or|break|continue|default|unsafe|match|if|else|for|go|goto|defer|return)\\b(?=\\s*\\()"
228
228
  }
229
229
  ]
230
230
  },
@@ -307,7 +307,7 @@
307
307
  },
308
308
  "escaped-fix": {
309
309
  "name": "meta.escaped.keyword.v",
310
- "match": "((?:@)(?:mut|pub|fn|unsafe|module|import|as|const|map|assert|sizeof|type|struct|interface|enum|in|or|match|if|else|for|go|goto|defer|return|i?(?:8|16|nt|64|128)|u?(?:16|32|64|128)|f?(?:32|64)|bool|byte|byteptr|charptr|voidptr|string|ustring|rune|none))",
310
+ "match": "((?:@)(?:mut|var|pub|fn|unsafe|module|import|as|const|map|assert|sizeof|type|struct|interface|enum|in|is|or|match|if|else|for|go|goto|defer|return|i?(?:8|16|nt|64|128)|u?(?:16|32|64|128)|f?(?:32|64)|bool|byte|byteptr|charptr|voidptr|string|ustring|rune|none))",
311
311
  "captures": {
312
312
  "0": {
313
313
  "name": "keyword.other.escaped.v"
@@ -571,19 +571,38 @@
571
571
  }
572
572
  },
573
573
  "include-decl": {
574
- "name": "meta.include.v",
575
- "begin": "^\\s*(#include)",
576
- "end": "\\s+(([\\\u003c\"])\\s*(.*)([\\\u003e\"]))",
577
- "beginCaptures": {
578
- "1": {
579
- "name": "keyword.include.v"
580
- }
581
- },
582
- "endCaptures": {
583
- "1": {
584
- "name": "string.quoted.double.v"
574
+ "patterns": [
575
+ {
576
+ "name": "meta.include.v",
577
+ "begin": "^\\s*(#include)",
578
+ "end": "\\s+([0-9a-zA-Z_]+)",
579
+ "beginCaptures": {
580
+ "1": {
581
+ "name": "keyword.include.v"
582
+ }
583
+ },
584
+ "endCaptures": {
585
+ "1": {
586
+ "name": "entity.include.additional.value.v"
587
+ }
588
+ }
589
+ },
590
+ {
591
+ "name": "meta.include.v",
592
+ "begin": "^\\s*(#include)",
593
+ "end": "\\s+(([\\\u003c\"])\\s*(.*)([\\\u003e\"]))",
594
+ "beginCaptures": {
595
+ "1": {
596
+ "name": "keyword.include.v"
597
+ }
598
+ },
599
+ "endCaptures": {
600
+ "1": {
601
+ "name": "string.quoted.double.v"
602
+ }
603
+ }
585
604
  }
586
- }
605
+ ]
587
606
  },
588
607
  "interface": {
589
608
  "name": "meta.definition.interface.v",
@@ -616,7 +635,7 @@
616
635
  },
617
636
  {
618
637
  "name": "keyword.control.v",
619
- "match": "\\b(in|or|break|continue|default|unsafe|match|if|else|for|go|goto|defer|return)\\b"
638
+ "match": "\\b(it|is|in|or|break|continue|default|unsafe|match|if|else|for|go|goto|defer|return)\\b"
620
639
  },
621
640
  {
622
641
  "name": "keyword.$1.v",
@@ -645,9 +664,21 @@
645
664
  "name": "constant.numeric.float.v",
646
665
  "match": "(?:(?:[-]?)(?:[0-9e]*)(?:[.]){1}(?:[0-9]+))"
647
666
  },
667
+ {
668
+ "name": "constant.numeric.exponental.v",
669
+ "match": "[-+]?[0-9]*\\.?[0-9]+(?:[eE][-+]?[0-9]+)"
670
+ },
671
+ {
672
+ "name": "constant.numeric.binary.v",
673
+ "match": "\\b(?:0[b])(?:[0-1]+)"
674
+ },
675
+ {
676
+ "name": "constant.numeric.octal.v",
677
+ "match": "\\b(?:0[o])(?:[0-7]+)"
678
+ },
648
679
  {
649
680
  "name": "constant.numeric.hex.v",
650
- "match": "\\b(?:0[xX])(?:[0-9a-fA-F]+)"
681
+ "match": "\\b(?:0[x])(?:[0-9a-fA-F]+)"
651
682
  },
652
683
  {
653
684
  "name": "constant.numeric.integer.v",
@@ -705,7 +736,7 @@
705
736
  },
706
737
  "storage": {
707
738
  "name": "storage.modifier.v",
708
- "match": "\\b(const|mut|pub)\\b"
739
+ "match": "\\b(const|mut|var|pub)\\b"
709
740
  },
710
741
  "string-escaped-char": {
711
742
  "patterns": [
@@ -827,7 +858,7 @@
827
858
  "patterns": [
828
859
  {
829
860
  "name": "meta.definition.struct.v",
830
- "begin": "^\\s*(?:(mut|pub(?:\\s+mut)?|__global)\\s+)?(struct)\\s+([\\w.]+)\\s*({)",
861
+ "begin": "^\\s*(?:(mut|var|pub(?:\\s+mut|var)?|__global)\\s+)?(struct)\\s+([\\w.]+)\\s*({)",
831
862
  "end": "\\s*(})",
832
863
  "patterns": [
833
864
  {
@@ -897,7 +928,7 @@
897
928
  },
898
929
  {
899
930
  "name": "meta.definition.struct.v",
900
- "match": "^\\s*(?:(mut|pub(?:\\s+mut)?|__global)\\s+)?(struct)(?:\\s+([\\w.]+))?",
931
+ "match": "^\\s*(?:(mut|var|pub(?:\\s+mut|var)?|__global))\\s+?(struct)\\s+(?:\\s+([\\w.]+))?",
901
932
  "captures": {
902
933
  "1": {
903
934
  "name": "storage.modifier.$1.v"
@@ -913,7 +944,7 @@
913
944
  ]
914
945
  },
915
946
  "struct-access-modifier": {
916
- "match": "(?\u003c=\\s|^)(mut|pub(?:\\s+mut)?|__global)(:|\\b)",
947
+ "match": "(?\u003c=\\s|^)(mut|var|pub(?:\\s+mut|var)?|__global)(:|\\b)",
917
948
  "captures": {
918
949
  "1": {
919
950
  "name": "storage.modifier.$1.v"