mirror of
https://github.com/rust-lang/rust.git
synced 2025-04-28 11:07:42 +00:00
11 lines
224 B
Rust
11 lines
224 B
Rust
//@ compile-flags: -Copt-level=3
|
|
#![crate_type = "lib"]
|
|
|
|
#[no_mangle]
|
|
pub fn get_len() -> usize {
|
|
// CHECK-LABEL: @get_len
|
|
// CHECK-NOT: call
|
|
// CHECK-NOT: invoke
|
|
[1, 2, 3].iter().collect::<Vec<_>>().len()
|
|
}
|