-
Notifications
You must be signed in to change notification settings - Fork 1.1k
false positive warning #23119
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
Comments
Forgot to mention - the issue is triggered starting with 3.7.0! 3.6.4 compiles both forms just fine, both with and without Could it be related to some sugar-improvements for for-comprehensions in 3.7.0? I remember reading about reduction of |
3.6 doesn't track pattern variables. Thanks for the report! Also thanks for the hint, I'll look at interactions with the different |
There is no false positive under The problem is the desugaring of |
Compiler version
3.7.0
Minimized example
Output Error/Warning message
Why this Error/Warning was not helpful
The message was unhelpful because the
given Int
is actually used - this is a "false positive".Suggested improvement
The issue is with how code is structured in for-comprehension. If for-comprehension gets restructured to:
The warning is not triggered any more!
The text was updated successfully, but these errors were encountered: