-
-
Notifications
You must be signed in to change notification settings - Fork 509
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(parser): Span for invalid regex flags (#5225)
### Before ``` x Flag u is mentioned twice in regular expression literal ,-[1:20] 1 | const a = /\2(.)/uuxig; : ^ 2 | debugger; `---- x Unexpected flag x in regular expression literal ,-[1:21] 1 | const a = /\2(.)/uuxig; : ^ 2 | debugger; `---- ``` ### After ``` x Flag u is mentioned twice in regular expression literal ,-[1:19] 1 | const a = /\2(.)/uuxig; : ^ 2 | debugger; `---- x Unexpected flag x in regular expression literal ,-[1:20] 1 | const a = /\2(.)/uuxig; : ^ 2 | debugger; `---- ```
- Loading branch information
Showing
4 changed files
with
38 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters