Open matthiaskrgr opened 9 months ago
This bisects to nightly-2022-03-16 , I suspect #94261 is the cause cc @michaelwoerister
This is probably missing an early exit for already instantiated types while dealing with generic arguments somewhere.
WG-prioritization assigning priority (Zulip discussion).
@rustbot label -I-prioritize +P-medium
Is the following the same, with the difference being that Single(T)
is changed to T(T)
?
use std::marker::PhantomData;
struct Digit<T> {
elem: T,
}
struct Node<T: 'static> {
m: PhantomData<&'static T>,
}
enum FingerTree<T: 'static> {
T(T),
Deep(Digit<T>, Node<FingerTree<Node<T>>>),
}
enum Wrapper<T: 'static> {
Simple,
Other(FingerTree<T>),
}
fn main() {
let w = Some(Wrapper::Simple::<u32>);
}
I tried this code:
This builds until you go for
-Cdebuginfo=2
Meta
rustc --version --verbose
:Backtrace
``` /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x2e9fcb3)[0x7f2de429fcb3] /usr/lib/libc.so.6(+0x40770)[0x7f2de1131770] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(_RNvNtNtCsiCYefPgEVI8_17rustc_codegen_ssa9debuginfo10type_names14push_item_name+0x1b)[0x7f2de5629ddb] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(_RNvNtNtCsiCYefPgEVI8_17rustc_codegen_ssa9debuginfo10type_names14push_item_name+0x1b4)[0x7f2de5629f74] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a70)[0x7f2de5907a70] ### cycle encountered after 5 frames with period 6 /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a8b)[0x7f2de5907a8b] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a8b)[0x7f2de5907a8b] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a8b)[0x7f2de5907a8b] ### recursed 41 times /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a8b)[0x7f2de5907a8b] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x4507a8b)[0x7f2de5907a8b] /home/matthias/.rustup/toolchains/master/lib/librustc_driver-3110cac9722aa818.so(+0x450674f)[0x7f2de590674f] note: rustc unexpectedly overflowed its stack! this is a bug note: maximum backtrace depth reached, frames may have been lost note: we would appreciate a report at https://github.com/rust-lang/rust note: backtrace dumped due to SIGSEGV! resuming signal [1] 3369027 segmentation fault rustc crash.rs -Cdebuginfo=2 ```