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
has r-a report the error "expected i32, found ()" (the i32 is the type in the match arm, changing the arm to e.g. "" changes the error to "expected &str, found ()"):
But it compiles just fine.
Possibly a duplicate of #15082? I don't know what that issue implies
This is a consequence of #15248. The gist of the problem is explained by this comment. Basically, panic! expands to $crate::panicking::panic_fmt() but we're now unable to resolve $crate, because our name resolver (or anything but eager expander) cannot see that the $crate originates from the panic! macro.
An obvious workaround is not to use any macro inside format_args! or any other macros that use it internally (e.g. println!). I'm thinking of introducing a hack so that the users won't need to deal with this themselves, but it may take a while (or forever -- it's fairly hard to get eager expansions right under our incremental architecture). Sorry for the inconvenience.
This code:
has r-a report the error "expected i32, found ()" (the
i32
is the type in the match arm, changing the arm to e.g.""
changes the error to "expected &str, found ()"):But it compiles just fine.
Possibly a duplicate of #15082? I don't know what that issue implies
rust-analyzer version: rust-analyzer version: 0.3.1591-standalone
rustc version: rustc 1.73.0-nightly (da6b55cc5 2023-07-17)
relevant settings: nothing particularly worthy of mention I think
The text was updated successfully, but these errors were encountered: