Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong JavaScript (and TypeScript) syntax highlight of keyword operand in ternary operator for particular styling. #724

Closed
escKeyStroke opened this issue Feb 23, 2019 · 2 comments

Comments

@escKeyStroke
Copy link

  • VSCode Version: 3.31.1
  • OS Version: Windows 10.0.17134 Build 17134

See the second method below for the syntax highlighting bug.

class C {

  a(){return false}
  b(){return false}

  Works(){
    return this.a()
    ? true
    : this.b()
      ? false
      : true;
  }

  doesNotWork = () =>
    this.a()
    ? true
    : this.b()
      ? false
      : true; // fails for apparently any keyword, e.g. "undefined", "null", ...

  alsoWorks = () =>
    this.a() ? true : this.b() ? false : true;

}

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

@vscodebot
Copy link

vscodebot bot commented Feb 23, 2019

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@escKeyStroke
Copy link
Author

@vscodebot At a first glance, to me, this issue doesn't appear to be a duplicate of that one.

@mjbvz mjbvz self-assigned this Feb 24, 2019
@mjbvz mjbvz transferred this issue from microsoft/vscode Feb 25, 2019
@mjbvz mjbvz removed their assignment Feb 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants