-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
Proposal: emit warning or error when coercing array to boolean #14638
Comments
and |
Duplicate #9041 ? |
Or #14114 |
@mhegazy Yeah, good point. :-) I would say any @RyanCavanaugh Thanks. Man, you must have a really good memory. :-D |
I just keep all the issue numbers scrawled on a scrap of paper near my desk 😉 |
@RyanCavanaugh the hyperspace In | n ∈ Z ≥ 14638 over the field of Typescript issues reduced to a single flat physical object 😲 |
@RyanCavanaugh Man, you must have a really large desk. :) |
[email protected]
This snippet compiles without any warning:
And I'd argue it's almost always a masked bug (the programmer did not realise the return value was an array).
Would it be sensible to emit some sort of a warning?
The text was updated successfully, but these errors were encountered: