-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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: symbol-mangling-version=v0 attempt to subtract with overflow #130011
Labels
A-lifetimes
Area: Lifetimes / regions
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
P-medium
Medium priority
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
A smaller repro without involving trait Fun<'v> {
type Assoc;
}
trait Trait: for<'v> Fun<'v, Assoc = &'v ()> {}
fn main() {
let _ = core::ptr::drop_in_place::<dyn Trait> as usize;
} |
Bisects to #97597 in Rust 1.63. FYI @tmiasko @RalfJung $ git checkout 6277c3a9441
$ python3 x.py build library/std --stage 1
$ build/x86_64-unknown-linux-gnu/stage1/bin/rustc repro.rs --edition=2021 -Csymbol-mangling-version=v0
# ICE
$ git checkout HEAD^
$ python3 x.py build library/std --stage 1
$ build/x86_64-unknown-linux-gnu/stage1/bin/rustc repro.rs --edition=2021 -Csymbol-mangling-version=v0
# success |
Oh that's only an artifact of the |
WG-prioritization assigning priority (Zulip discussion). @rustbot label -I-prioritize +P-medium |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-lifetimes
Area: Lifetimes / regions
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
P-medium
Medium priority
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
using a rustc built from current master, with the following added to config.toml to enable overflow checks:
Error output
rustc --edition=2021 main.rs -Csymbol-mangling-version=v0
This is the subtraction:
rust/compiler/rustc_symbol_mangling/src/v0.rs
Line 298 in 9c01301
Backtrace
Tracking issue for v0 symbol mangling: #60705
The text was updated successfully, but these errors were encountered: