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

Easy misunderstanding: "! ===" #37837

Closed
zhangciwu opened this issue Apr 8, 2020 · 0 comments · Fixed by #37838
Closed

Easy misunderstanding: "! ===" #37837

zhangciwu opened this issue Apr 8, 2020 · 0 comments · Fixed by #37838
Labels
Experience Enhancement Noncontroversial enhancements
Milestone

Comments

@zhangciwu
Copy link
Contributor

zhangciwu commented Apr 8, 2020

When reading source code, I got confused when reading this line:

languageVersion! === ScriptTarget.ES5 ? lookupInUnicodeMap(code, unicodeES5IdentifierStart) :

And I finally realized that it's ! === (equals) than !== (not equals)
I think this writing would confuse many people

TypeScript Version: from 3.6 to current(3.8.3)

Search Terms: ! ===

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Experience Enhancement Noncontroversial enhancements
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants