microsoft / TypeScript-TmLanguage

TextMate grammar files for TypeScript for VS Code, Sublime Text, and Atom.
MIT License
413 stars 126 forks source link

Incorrect TypeScript syntax highlighting with variable type starting on a new line #981

Open Ilyat1337 opened 1 year ago

Ilyat1337 commented 1 year ago

Does this issue occur when all extensions are disabled?: Yes

Steps to Reproduce: (This issue can also be reproduced in VSCode Web)

  1. Create new text file
  2. Select TypeScript language
  3. Paste the following code:
    let a:
    number
    for (;;);
  4. Syntax highlighting starting with 'for' is broken. It does not occur if type specifier is on the same line as variable declaration.