File tree Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Expand file tree Collapse file tree 3 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -308,8 +308,7 @@ pub fn get_backtrace_style() -> Option<BacktraceStyle> {
308308 BacktraceStyle :: Short
309309 }
310310 } )
311- . unwrap_or ( if cfg ! ( target_os = "fuchsia" ) {
312- // Fuchsia components default to full backtrace.
311+ . unwrap_or ( if crate :: sys:: FULL_BACKTRACE_DEFAULT {
313312 BacktraceStyle :: Full
314313 } else {
315314 BacktraceStyle :: Off
Original file line number Diff line number Diff line change @@ -76,3 +76,12 @@ cfg_if::cfg_if! {
7676 pub mod c;
7777 }
7878}
79+
80+ cfg_if:: cfg_if! {
81+ // Fuchsia components default to full backtrace.
82+ if #[ cfg( target_os = "fuchsia" ) ] {
83+ pub const FULL_BACKTRACE_DEFAULT : bool = true ;
84+ } else {
85+ pub const FULL_BACKTRACE_DEFAULT : bool = false ;
86+ }
87+ }
Original file line number Diff line number Diff line change @@ -59,7 +59,6 @@ const EXCEPTION_PATHS: &[&str] = &[
5959 "library/std/src/path.rs" ,
6060 "library/std/src/sys_common" , // Should only contain abstractions over platforms
6161 "library/std/src/net/test.rs" , // Utility helpers for tests
62- "library/std/src/panic.rs" , // fuchsia-specific panic backtrace handling
6362 "library/std/src/personality.rs" ,
6463 "library/std/src/personality/" ,
6564] ;
You can’t perform that action at this time.
0 commit comments