-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correct flags scanning for non-BMP characters
- Loading branch information
1 parent
76acd92
commit e67692a
Showing
6 changed files
with
66 additions
and
15 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
23 changes: 23 additions & 0 deletions
23
tests/baselines/reference/regularExpressionWithNonBMPFlags.errors.txt
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
regularExpressionWithNonBMPFlags.ts(1,23): error TS1499: Unknown regular expression flag. | ||
regularExpressionWithNonBMPFlags.ts(1,25): error TS1499: Unknown regular expression flag. | ||
regularExpressionWithNonBMPFlags.ts(1,28): error TS1499: Unknown regular expression flag. | ||
regularExpressionWithNonBMPFlags.ts(1,41): error TS1499: Unknown regular expression flag. | ||
regularExpressionWithNonBMPFlags.ts(1,43): error TS1499: Unknown regular expression flag. | ||
regularExpressionWithNonBMPFlags.ts(1,45): error TS1499: Unknown regular expression flag. | ||
|
||
|
||
==== regularExpressionWithNonBMPFlags.ts (6 errors) ==== | ||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
~~ | ||
!!! error TS1499: Unknown regular expression flag. | ||
|
8 changes: 8 additions & 0 deletions
8
tests/baselines/reference/regularExpressionWithNonBMPFlags.js
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
//// [tests/cases/compiler/regularExpressionWithNonBMPFlags.ts] //// | ||
|
||
//// [regularExpressionWithNonBMPFlags.ts] | ||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; | ||
|
||
|
||
//// [regularExpressionWithNonBMPFlags.js] | ||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; |
6 changes: 6 additions & 0 deletions
6
tests/baselines/reference/regularExpressionWithNonBMPFlags.symbols
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
//// [tests/cases/compiler/regularExpressionWithNonBMPFlags.ts] //// | ||
|
||
=== regularExpressionWithNonBMPFlags.ts === | ||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; | ||
>𝘳𝘦𝘨𝘦𝘹 : Symbol(𝘳𝘦𝘨𝘦𝘹, Decl(regularExpressionWithNonBMPFlags.ts, 0, 5)) | ||
|
9 changes: 9 additions & 0 deletions
9
tests/baselines/reference/regularExpressionWithNonBMPFlags.types
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
//// [tests/cases/compiler/regularExpressionWithNonBMPFlags.ts] //// | ||
|
||
=== regularExpressionWithNonBMPFlags.ts === | ||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; | ||
>𝘳𝘦𝘨𝘦𝘹 : RegExp | ||
> : ^^^^^^ | ||
>/(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶 : RegExp | ||
> : ^^^^^^ | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
// @target: esnext | ||
|
||
const 𝘳𝘦𝘨𝘦𝘹 = /(?𝘴𝘪-𝘮:^𝘧𝘰𝘰.)/𝘨𝘮𝘶; |