-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Macro matching with anonymous variable fails #9570
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
Awkwardly the behavior is correct. The pattern case '{HCons($_,$t)} =>
// or
case '{HCons(${_},$t)} => where We should reject the |
Actually |
@nicolasstucki : Great diagnosis 👍 It's easy to have the wrong intuition when working with quoted patterns. |
Fix #9570: Warn on use of `_` in quoted pattern
Minimized code
In a Macros.scala file we have
In a Main.scala file we have
Output
Expectation
I expected a correct match. If we use:
or
matching works correctly.
Tested on
0.26.0-RC1
The text was updated successfully, but these errors were encountered: