about summary refs log tree commit diff
path: root/tests/codegen-llvm/function-arguments.rs
diff options
context:
space:
mode:
authorNikita Popov <npopov@redhat.com>2025-08-26 11:13:03 +0200
committerNikita Popov <npopov@redhat.com>2025-08-26 16:16:23 +0200
commitc3ab409b4fa3b1fb18f34877d9811bb502ed507f (patch)
tree05ab8323d24155dd4d9459c873ce3f2358141503 /tests/codegen-llvm/function-arguments.rs
parentace9a74442aec13c75532d34e15d97428056866d (diff)
downloadrust-c3ab409b4fa3b1fb18f34877d9811bb502ed507f.tar.gz
rust-c3ab409b4fa3b1fb18f34877d9811bb502ed507f.zip
Use captures(address) instead of captures(none) for indirect args
While provenance cannot be captured through these arguments, the
address / object identity can.
Diffstat (limited to 'tests/codegen-llvm/function-arguments.rs')
-rw-r--r--tests/codegen-llvm/function-arguments.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/codegen-llvm/function-arguments.rs b/tests/codegen-llvm/function-arguments.rs
index db508682862..a0744e44c61 100644
--- a/tests/codegen-llvm/function-arguments.rs
+++ b/tests/codegen-llvm/function-arguments.rs
@@ -134,7 +134,7 @@ pub fn mutable_notunpin_borrow(_: &mut NotUnpin) {}
 #[no_mangle]
 pub fn notunpin_borrow(_: &NotUnpin) {}
 
-// CHECK: @indirect_struct(ptr{{( dead_on_return)?}} noalias{{( nocapture)?}} noundef readonly align 4{{( captures\(none\))?}} dereferenceable(32) %_1)
+// CHECK: @indirect_struct(ptr{{( dead_on_return)?}} noalias noundef readonly align 4{{( captures\(address\))?}} dereferenceable(32) %_1)
 #[no_mangle]
 pub fn indirect_struct(_: S) {}
 
@@ -197,7 +197,7 @@ pub fn notunpin_box(x: Box<NotUnpin>) -> Box<NotUnpin> {
     x
 }
 
-// CHECK: @struct_return(ptr{{( dead_on_unwind)?}} noalias{{( nocapture)?}} noundef{{( writable)?}} sret([32 x i8]) align 4{{( captures\(none\))?}} dereferenceable(32){{( %_0)?}})
+// CHECK: @struct_return(ptr{{( dead_on_unwind)?}} noalias noundef{{( writable)?}} sret([32 x i8]) align 4{{( captures\(address\))?}} dereferenceable(32){{( %_0)?}})
 #[no_mangle]
 pub fn struct_return() -> S {
     S { _field: [0, 0, 0, 0, 0, 0, 0, 0] }