Repository navigation
Closed
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)A-const-evalArea: Constant evaluation, covers all const contexts (static, const fn, ...)Area: Constant evaluation, covers all const contexts (static, const fn, ...)I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️I-unsoundIssue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessIssue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessNLL-completeWorking towards the "valid code works" goalWorking towards the "valid code works" goalP-highHigh priorityHigh priorityregression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Description
thread 'main' panicked at 'allocation missing in dead_alloc_map', libcore/option.rs:1008:5
stack backtrace:
0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
1: std::sys_common::backtrace::print
at libstd/sys_common/backtrace.rs:71
at libstd/sys_common/backtrace.rs:59
2: std::panicking::default_hook::{{closure}}
at libstd/panicking.rs:211
3: std::panicking::default_hook
at libstd/panicking.rs:227
4: rustc::util::common::panic_hook
5: std::panicking::rust_panic_with_hook
at libstd/panicking.rs:480
6: std::panicking::continue_panic_fmt
at libstd/panicking.rs:390
7: rust_begin_unwind
at libstd/panicking.rs:325
8: core::panicking::panic_fmt
at libcore/panicking.rs:77
9: core::option::expect_failed
at libcore/option.rs:1008
10: <rustc_mir::interpret::memory::Memory<'a, 'mir, 'tcx, M>>::check_align
11: rustc_mir::interpret::validity::<impl rustc_mir::interpret::eval_context::EvalContext<'a, 'mir, 'tcx, M>>::validate_primitive_type
12: rustc_mir::interpret::validity::<impl rustc_mir::interpret::eval_context::EvalContext<'a, 'mir, 'tcx, M>>::validate_operand
13: rustc_mir::interpret::validity::<impl rustc_mir::interpret::eval_context::EvalContext<'a, 'mir, 'tcx, M>>::validate_operand
14: rustc_mir::interpret::validity::<impl rustc_mir::interpret::eval_context::EvalContext<'a, 'mir, 'tcx, M>>::validate_operand
15: rustc_lint::builtin::check_const
16: <rustc_lint::register_builtins::BuiltinCombinedLateLintPass as rustc::lint::LateLintPass<'a, 'tcx>>::check_item
17: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_item
18: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_mod
19: rustc::hir::intravisit::walk_item
20: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_item
21: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_mod
22: rustc::hir::intravisit::walk_item
23: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_item
24: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_mod
25: rustc::hir::intravisit::walk_item
26: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_item
27: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_mod
28: rustc::hir::intravisit::walk_item
29: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_item
30: <rustc::lint::context::LateContext<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_mod
31: rustc::hir::intravisit::walk_crate
32: rustc::lint::context::check_crate
33: rustc::util::common::time
34: rustc::ty::context::tls::enter_context
35: <std::thread::local::LocalKey<T>>::with
36: rustc::ty::context::TyCtxt::create_and_enter
37: rustc_driver::driver::compile_input
38: rustc_driver::run_compiler_with_pool
39: rustc_driver::driver::spawn_thread_pool
40: rustc_driver::run_compiler
41: <scoped_tls::ScopedKey<T>>::set
42: <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
43: __rust_maybe_catch_panic
at libpanic_unwind/lib.rs:102
44: rustc_driver::run
45: rustc_driver::main
46: std::rt::lang_start::{{closure}}
47: std::panicking::try::do_call
at libstd/rt.rs:59
at libstd/panicking.rs:310
48: __rust_maybe_catch_panic
at libpanic_unwind/lib.rs:102
49: std::rt::lang_start_internal
at libstd/panicking.rs:289
at libstd/panic.rs:392
at libstd/rt.rs:58
50: main
51: __libc_start_main
52: <unknown>
query stack during panic:
end of query stack
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports
note: rustc 1.31.0-nightly (78ff609d7 2018-10-19) running on x86_64-unknown-linux-gnu
note: compiler flags: -C debuginfo=2 -C link-args=-fuse-ld=gold --crate-type lib
note: some of the compiler flags provided by cargo are hidden
�[0m�[0m�[1m�[31merror:�[0m Could not compile `script`.Metadata
Metadata
Assignees
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)A-const-evalArea: Constant evaluation, covers all const contexts (static, const fn, ...)Area: Constant evaluation, covers all const contexts (static, const fn, ...)I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️I-unsoundIssue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessIssue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessNLL-completeWorking towards the "valid code works" goalWorking towards the "valid code works" goalP-highHigh priorityHigh priorityregression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.Performance or correctness regression from stable to nightly.
Activity
SimonSapin commentedon Oct 22, 2018
Commit range: e7f5d48...78ff609. Merged PRs:
Path#54979 Custom E0277 diagnostic forPathSizedness #55004 Check the type of statics and constants forSizednessParamEnvwith a new type in chalk context. #55040 ReplaceParamEnvwith a new type in chalk contextmatch (return)#55166 (Don't warn about parentheses onmatch (return))copysignfunction to f32 and f64 #55169 (Add acopysignfunction to f32 and f64)oli-obk commentedon Oct 22, 2018
I honestly don't know what your code does, but from the error message and the backtrace I was able to create
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2015&gist=b23ea8c8d50f4a31a52780e27ef55fa5
oli-obk commentedon Oct 22, 2018
I have a repro now: https://github.com/rust-lang/rust/pull/55262/files#diff-c1369fee5bc12990c0cb1629b00a9893
oli-obk commentedon Oct 22, 2018
cc @nikomatsakis @pnkfelix I think (haven't bisected yet) that #55152 is the likelyest candidate to have regressed the following (previously successfully compiling code example):
the following warning will keep the code compiling but cause dangling safe references in downstream code
pnkfelix commentedon Oct 23, 2018
"dangling safe references" ? Oh, you must mean "dangling
&-references" ? Sorry, wasn't sure if the word "safe" there was meant to mean "this code is fine and should be accepted by the compiler.pnkfelix commentedon Oct 23, 2018
Do we not guarantee that an expression like
[ b"CloseEvent" as &'static [u8], ]can be promoted to a static value?pnkfelix commentedon Oct 23, 2018
in particular, the code seems to work fine if I replace
[ b"CloseEvent" as &'static [u8], ]with just[ b"CloseEvent", ]pnkfelix commentedon Oct 23, 2018
(We probably should fork off separate issues to track the distinct problems that @oli-obk has uncovered here...)
10 remaining items
pnkfelix commentedon Oct 25, 2018
closing as duplicate of #55288, which is where the bulk of the remaining work is
Rollup merge of rust-lang#55262 - oli-obk:dangling_alloc_id_ice, r=Ra…
Rollup merge of rust-lang#55262 - oli-obk:dangling_alloc_id_ice, r=Ra…
Auto merge of #55262 - oli-obk:dangling_alloc_id_ice, r=RalfJung