Skip to content

Commit

Permalink
const_panic: inline in bootstrap builds to avoid f16/f128 crashes
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Nov 18, 2024
1 parent c1beb25 commit e84f865
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/panic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ pub macro const_panic {
#[noinline]
if const #[track_caller] #[inline] { // Inline this, to prevent codegen
$crate::panic!($const_msg)
} else #[track_caller] { // Do not inline this, it makes perf worse
} else #[track_caller] #[cfg_attr(bootstrap, inline)] { // Do not inline this, it makes perf worse
$crate::panic!($runtime_msg)
}
)
Expand Down

0 comments on commit e84f865

Please sign in to comment.