2023-02-24 15:33:22 -06:00
|
|
|
#![crate_type = "lib"]
|
|
|
|
|
2023-03-25 15:47:56 -05:00
|
|
|
// ignore-wasm32-bare compiled with panic=abort by default
|
2023-02-24 15:33:22 -06:00
|
|
|
// ignore-debug: the debug assertions prevent the inlining we are testing for
|
|
|
|
// compile-flags: -Zmir-opt-level=2 -Zinline-mir
|
|
|
|
|
|
|
|
// EMIT_MIR unwrap_unchecked.unwrap_unchecked.Inline.diff
|
|
|
|
// EMIT_MIR unwrap_unchecked.unwrap_unchecked.PreCodegen.after.mir
|
|
|
|
pub unsafe fn unwrap_unchecked<T>(slf: Option<T>) -> T {
|
|
|
|
slf.unwrap_unchecked()
|
|
|
|
}
|