There was an error while loading. Please reload this page.
1 parent a80a323 commit daeb89cCopy full SHA for daeb89c
1 file changed
src/parser/scanner.ts
@@ -359,18 +359,8 @@ export class Scanner implements ITokenStream {
359
}
360
361
const value = decodeUnicodeEscapeSequence(rawValue);
362
- const [start, ...parts] = value;
363
- if (!identifierStart.test(start!)) {
364
- throw new AiScriptSyntaxError(`Invalid identifier: "${value}"`, pos);
365
- }
366
- for (const part of parts) {
367
- if (!identifierPart.test(part)) {
368
369
370
371
-
372
if (value !== rawValue) {
373
- throw new AiScriptSyntaxError(`Cannot use escape characters in identifier: "${rawValue}"`, pos);
+ throw new AiScriptSyntaxError(`Invalid identifier: "${rawValue}"`, pos);
374
375
376
// check word kind
0 commit comments