Skip to content

Missing error for keywords with escaped characters #32700

Closed
@ajafff

Description

@ajafff

TypeScript Version: 3.6.0-dev.20190804

Search Terms:

Code

v\u0061r a = 1;
// parses as: 'var a = 1;'

Expected behavior:
Keyword must not contain escaped characters

Actual behavior:
No parse/compile error. Instead Chrome gives Uncaught SyntaxError: Keyword must not contain escaped characters

Playground Link: doesn't use the correct version yet

Related Issues:
#32096 made parsing the above code possible. cc @weswigham

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScript

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions