Change:
v.s. is less verbose, but I remember it also filtering out some stack frames in some previous compiler versions. (Only frame # 6 is really useful to me here.) Indeed, contains some code that looks for a symbol on the stack to find out what to filter. It looks like some functionality has regressed. Stepping through the program in gdb it looks like the function is called, but despite there’s apparently no stack frame (anymore?) for it. CC and for , , and .
contains a fix for this
Now being worked on in instead afaict?
It is.
This issue hasn't been active in almost two years, and so have the issues linked here. Is there any intention of resuming work on this? It's mostly a small papercut because currently when crashing, programs suggest: run with environment variable to display a backtrace. and after setting that, also claim that: Some details are omitted, run with for a verbose backtrace. even though no details were omitted at all (which is the issue of course)
A simple fix would be to just look for "std::rt::lang_start::{{closure}}" instead until the real solution to the disappearing function is found..
This single fix is likely to have the biggest positive effect on my use of Rust since async/await. Thank you so much!
Awesome! I'm happy to see this finally fixed :D Thanks to everyone who had a part in this fix :)

Discussion:
let loc = info.location().unwrap(); // The current implementation always returns Some let msg = info.message().unwrap(); // The current implementation always returns Some <del> rust_panic_with_hook(&mut PanicPayload::new(msg), info.message(), loc); </del> <ins> crate::sys_common::backtrace::__rust_end_short_backtrace(move || { rust_panic_with_hook(&mut PanicPayload::new(msg), info.message(), loc); }) </ins> } /// This is the entry point of panicking for the non-format-string variants of

intrinsics::abort() } <del> rust_panic_with_hook(&mut PanicPayload::new(msg), None, Location::caller()); </del> <ins> let loc = Location::caller(); return crate::sys_common::backtrace::__rust_end_short_backtrace(move || { rust_panic_with_hook(&mut PanicPayload::new(msg), None, loc) }); </ins> struct PanicPayload<A> { inner: Option<A>,

sys::args::init(argc, argv); // Let's run some code! <del> let exit_code = panic::catch_unwind(|| { sys_common::backtrace::__rust_begin_short_backtrace(move || main()) }); </del> <ins> let exit_code = panic::catch_unwind(main); </ins> sys_common::cleanup(); exit_code.unwrap_or(101) as isize

argc: isize, argv: *const *const u8, ) -> isize { <del> lang_start_internal(&move || main().report(), argc, argv) </del> <ins> lang_start_internal( &move || crate::sys_common::backtrace::__rust_begin_short_backtrace(main).report(), argc, argv, ) </ins> }

bt_fmt.add_context()?; let mut idx = 0; let mut res = Ok(()); <ins> // Start immediately if we're not using a short backtrace. let mut start = print_fmt != PrintFmt::Short; </ins> backtrace_rs::trace_unsynchronized(|frame| { if print_fmt == PrintFmt::Short && idx > MAX_NB_FRAMES { return false;

stop = true; return; } <ins> if sym.contains("__rust_end_short_backtrace") { start = true; return; } </ins> } } <del> res = bt_fmt.frame().symbol(frame, symbol); </del> <ins> if start { res = bt_fmt.frame().symbol(frame, symbol); } </ins> }); if stop { return false; } if !hit { <del> res = bt_fmt.frame().print_raw(frame.ip(), None, None, None); </del> <ins> if start { res = bt_fmt.frame().print_raw(frame.ip(), None, None, None); } </ins> } idx += 1;

pub fn __rust_begin_short_backtrace<F, T>(f: F) -> T where F: FnOnce() -> T, <del> F: Send, T: Send, </del> { <del> f() </del> <ins> let result = f(); // prevent this frame from being tail-call optimised away crate::hint::black_box(()); result } /// Fixed frame used to clean the backtrace with `RUST_BACKTRACE=1`. Note that /// this is only inline(never) when backtraces in libstd are enabled, otherwise /// it's fine to optimize away. #[cfg_attr(feature = "backtrace", inline(never))] pub fn __rust_end_short_backtrace<F, T>(f: F) -> T where F: FnOnce() -> T, { let result = f(); // prevent this frame from being tail-call optimised away crate::hint::black_box(()); result </ins> } pub enum RustBacktrace {

/// Fixed frame used to clean the backtrace with `RUST_BACKTRACE=1`. #[inline(never)] fn __rust_begin_short_backtrace<F: FnOnce()>(f: F) { <del> f() </del> <ins> f(); // prevent this frame from being tail-call optimised away black_box(()); </ins> } fn run_test_in_process(

<ins> // Regression test for #47429: short backtraces were not terminating correctly // compile-flags: -O // run-fail // check-run-results // exec-env:RUST_BACKTRACE=1 // ignore-msvc see #62897 and `backtrace-debuginfo.rs` test // ignore-android FIXME #17520 // ignore-cloudabi spawning processes is not supported // ignore-openbsd no support for libbacktrace without filename // ignore-wasm no panic or subprocess support // ignore-emscripten no panic or subprocess support // ignore-sgx no subprocess support fn main() { panic!() } </ins>

<ins> thread 'main' panicked at 'explicit panic', $DIR/issue-47429-short-backtraces.rs:17:5 stack backtrace: 0: std::panicking::begin_panic 1: issue_47429_short_backtraces::main note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace. </ins>