rust/tests/codegen/to_vec.rs

11 lines
183 B
Rust

//@ compile-flags: -O
#![crate_type = "lib"]
// CHECK-LABEL: @copy_to_vec
#[no_mangle]
fn copy_to_vec(s: &[u64]) -> Vec<u64> {
s.to_vec()
// CHECK: call void @llvm.memcpy
}