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
[ no-constant-condition] should validate 'void' too #5726
Comments
Sounds reasonable to me. Although I think the primary case should be: if (void) {} |
@ilyavolodin You mean |
Yes I do:-) |
I would love to tackle this one if it gets accepted! |
There's also some other missing expression types in the |
Should it really be addressed in this issue? I have a PR ready for the |
Is anyone championing this? @eslint/eslint-team |
I count one 👍 (@ilyavolodin, maybe a stretch). I will add one more 👍. @vitorbal, you could champion or add 👍. Then we need whatever you don't do. 😄 @michaelficarra I think we should create a separate issue for the problem you've brought up. |
@alberto @platinumazure thanks for the ping! I am willing to champion this change and I've already got a PR almost ready, just in need of a rebase. I agree that we should open a separate issue for the extra checks. |
I'll 👍 @vitorbal as the champion, you should secure one more definitive 👍 and then you can mark as accepted. |
👍 |
Thanks all, I will get around to finishing this by the end of this week! |
Request type : Enhancement
Rule :
no-constant-condition
What version of ESLint are you using?
2.5.1
What parser (default, Babel-ESLint, etc.) are you using?
default
Please show your full configuration:
What did you do? Please include the actual source code causing the issue.
What did you expect to happen?
Error as it is a constant condition
What actually happened?
No error
As discussed in #5228 & #5696
The text was updated successfully, but these errors were encountered: