-
Notifications
You must be signed in to change notification settings - Fork 13.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
rustc panics given malformed attribute #48387
Comments
Further detailsThe code snippetIt is short enough that it might as well be posted here:
Note: Commenting out the The error:
A DiagnosticBuilder is being dropped somewhere. The question is, who created it? Rustc or Rocket? (well, okay, it's obviously gotta be a bug in Rocket, I just haven't been able to prove it yet) Backtrace (nightly channel)
(No sign of Rocket in the backtrace, though I'm not sure how much this helps as I don't know if a plugin would normally show up in the stack trace or not; also, there is lots of inlining) I looked through the Rocket codegen plugin's source trying to brainstorm all sorts of ways that a drop of a DiagnosticBuilder might get hidden in the source code. I did learn something, which is that (I can picture it now; the compiler blows up just moments before printing the actual error message it was supposed to print, because somebody wrote |
Fix ICE on malformed plugin attributes See rust-lang#48941 for some discussion. This bug had several duplicate reports which were never closed as dupes: Fixes rust-lang#47612 Fixes rust-lang#48387 Fixes rust-lang#48941 Fixes rust-lang#48982
A typo in an attribute causes a compiler panic. It is probably connected with the presence of
#![plugin(rocket_codegen)]
I've reduced the offender to a tiny single .rs file and its Cargo.toml.
Rust_bug.zip
The text was updated successfully, but these errors were encountered: