mirror of
https://github.com/rust-lang/rust.git
synced 2025-02-01 09:33:26 +00:00
inline Option panics on panic_immediate_abort
This commit is contained in:
parent
3cf9ae6ff3
commit
0adee2c01e
@ -1656,7 +1656,8 @@ impl<T, E> Option<Result<T, E>> {
|
||||
}
|
||||
|
||||
// This is a separate function to reduce the code size of .expect() itself.
|
||||
#[inline(never)]
|
||||
#[cfg_attr(not(feature = "panic_immediate_abort"), inline(never))]
|
||||
#[cfg_attr(feature = "panic_immediate_abort", inline)]
|
||||
#[cold]
|
||||
#[track_caller]
|
||||
const fn expect_failed(msg: &str) -> ! {
|
||||
|
Loading…
Reference in New Issue
Block a user