[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / CodeGen / WebAssembly / wasm-export-name.c
blob3793842895a34f45a2520a7aebf6f8081e119cbc
1 // RUN: %clang_cc1 -triple wasm32-unknown-unknown-wasm -emit-llvm -o - %s | FileCheck %s
3 int __attribute__((export_name("bar"))) foo(void);
5 int foo(void) {
6 return 43;
9 // CHECK: @llvm.used = appending global [1 x ptr] [ptr @foo]
11 // CHECK: define i32 @foo() [[A:#[0-9]+]]
13 // CHECK: attributes [[A]] = {{{.*}} "wasm-export-name"="bar" {{.*}}}