Skip to content

Commit 8011e87

Browse files
committed
Fix the incorrect detection of arrow when it would be function call
Fixes #403
1 parent 9b0d80d commit 8011e87

5 files changed

+455
-3
lines changed

TypeScript.YAML-tmLanguage

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1595,7 +1595,7 @@ repository:
15951595
(?:
15961596
(?<!\.|\$)(\basync)(?=\s*[<(])
15971597
) |
1598-
((?<!\])\s*
1598+
((?<![})\]])\s*
15991599
(?=
16001600
# sure shot arrow functions even if => is on new line
16011601
(

TypeScript.tmLanguage

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4401,7 +4401,7 @@
44014401
<key>begin</key>
44024402
<string>(?x) (?:
44034403
(?&lt;!\.|\$)(\basync)(?=\s*[&lt;(])
4404-
) | ((?&lt;!\])\s*
4404+
) | ((?&lt;![})\]])\s*
44054405
(?=
44064406
# sure shot arrow functions even if =&gt; is on new line
44074407
(

TypeScriptReact.tmLanguage

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4383,7 +4383,7 @@
43834383
<key>begin</key>
43844384
<string>(?x) (?:
43854385
(?&lt;!\.|\$)(\basync)(?=\s*[&lt;(])
4386-
) | ((?&lt;!\])\s*
4386+
) | ((?&lt;![})\]])\s*
43874387
(?=
43884388
# sure shot arrow functions even if =&gt; is on new line
43894389
(

0 commit comments

Comments
 (0)