You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
pubstructFoo{field:(),}pubfntest(x:(Foo,)){macro_rules! mac {($field:ident) => {match x.0.$field {() => {}}};}mac!(field);// missing match arm}fnmain(){}
Some observations:
Using x.0 .$field instead of x.0.$field makes the error go away, which suggests that 0. is getting parsed as a float literal (I have seen this issue before enough times to know not to write x.0.0, but some cursory rustc testing suggests that this isn't actually a problem anymore? Or maybe it was an RA problem all along...)
The text was updated successfully, but these errors were encountered:
digama0
changed the title
Regression: macro ident matcher + field notation = "missing match arm"
macro ident matcher + field notation = "missing match arm"
Apr 28, 2022
digama0
added a commit
to digama0/mm0
that referenced
this issue
Apr 28, 2022
Some observations:
x.0 .$field
instead ofx.0.$field
makes the error go away, which suggests that0.
is getting parsed as a float literal (I have seen this issue before enough times to know not to writex.0.0
, but some cursory rustc testing suggests that this isn't actually a problem anymore? Or maybe it was an RA problem all along...)x.0.field
works finerust-analyzer version:
241b9f9ae 2022-04-28 nightly
rustc version:
rustc 1.62.0-nightly (69a5d2481 2022-04-27)
The text was updated successfully, but these errors were encountered: