mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-31 22:41:50 +00:00
FileCheck unwrap_unchecked
This commit is contained in:
parent
3faf05b6e7
commit
6ab66c3f37
@ -1,4 +1,3 @@
|
||||
// skip-filecheck
|
||||
#![crate_type = "lib"]
|
||||
|
||||
// EMIT_MIR_FOR_EACH_PANIC_STRATEGY
|
||||
@ -8,5 +7,7 @@
|
||||
// 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 {
|
||||
// CHECK-LABEL: fn unwrap_unchecked(
|
||||
// CHECK: (inlined #[track_caller] Option::<T>::unwrap_unchecked)
|
||||
slf.unwrap_unchecked()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user