-
Notifications
You must be signed in to change notification settings - Fork 13k
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
ICE when printing paths in modules with non-DefId reexports (e.g. NonMacroAttr(Builtin)). #74236
Labels
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
jonas-schievink
added
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
I-prioritize
Issue: Indicates that prioritization has been requested for this issue.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
labels
Jul 11, 2020
da-x
added a commit
to da-x/rust
that referenced
this issue
Jul 11, 2020
Manishearth
added a commit
to Manishearth/rust
that referenced
this issue
Jul 11, 2020
Fix rust-lang#74081 and add the test case from rust-lang#74236
Manishearth
added a commit
to Manishearth/rust
that referenced
this issue
Jul 11, 2020
Fix rust-lang#74081 and add the test case from rust-lang#74236
Manishearth
added a commit
to Manishearth/rust
that referenced
this issue
Jul 11, 2020
Fix rust-lang#74081 and add the test case from rust-lang#74236
bors
added a commit
to rust-lang-ci/rust
that referenced
this issue
Jul 12, 2020
…arth Rollup of 10 pull requests Successful merges: - rust-lang#72920 (Stabilize `transmute` in constants and statics but not const fn) - rust-lang#73715 (debuginfo: Mangle tuples to be natvis friendly, typedef basic types) - rust-lang#74066 (Optimize is_ascii for str and [u8].) - rust-lang#74116 (Fix cross compilation of LLVM to aarch64 Windows targets) - rust-lang#74167 (linker: illumos ld does not support --eh-frame-hdr) - rust-lang#74168 (Add a help to use `in_band_lifetimes` in nightly) - rust-lang#74197 (Reword incorrect `self` token suggestion) - rust-lang#74213 (Minor refactor for rustc_resolve diagnostics match) - rust-lang#74240 (Fix rust-lang#74081 and add the test case from rust-lang#74236) - rust-lang#74241 (update miri) Failed merges: r? @ghost
#74240 fixed and added the test for this, closing as fixed. |
JohnTitor
removed
the
I-prioritize
Issue: Indicates that prioritization has been requested for this issue.
label
Jul 14, 2020
roxelo
pushed a commit
to sexxi-goose/rust
that referenced
this issue
Jul 22, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
dep.rs
(compiled with--edition=2018
):main.rs
:Results in
attempted .def_id() on invalid res: NonMacroAttr(Builtin)
due to the.def_id()
call in:rust/src/librustc_middle/ty/print/pretty.rs
Lines 391 to 401 in daecab3
The snippet above is searching
dep
's children for the reexport ofdep::private::Pub
in order to grab its reexported name (Renamed
here) when it runs into thepub use cfg_attr as attr;
reexport lacking aDefId
.Fix is straight-forward, we can just ignore siblings lacking a
DefId
:But I'm mostly making this issue to point out the fact that it is possible to create strange reexports that could break various parts of the compiler, even if it might be very rare (#74081 appears to be an instance of this).
(as I was writing this I found that @da-x had already tried out the fix - see #74081 (comment))
cc @rust-lang/compiler
The text was updated successfully, but these errors were encountered: