rust/tests/codegen/staticlib-external-inline-fns.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

44 lines
770 B
Rust
Raw Normal View History

2020-06-08 08:37:11 +00:00
//@ compile-flags: -C no-prepopulate-passes
#![crate_type = "staticlib"]
// CHECK: define{{.*}}void @a()
2020-06-08 08:37:11 +00:00
#[no_mangle]
#[inline]
pub extern "C" fn a() {}
// CHECK: define{{.*}}void @b()
2020-06-08 08:37:11 +00:00
#[export_name = "b"]
#[inline]
pub extern "C" fn b() {}
// CHECK: define{{.*}}void @c()
2020-06-08 08:37:11 +00:00
#[no_mangle]
#[inline]
extern "C" fn c() {}
// CHECK: define{{.*}}void @d()
2020-06-08 08:37:11 +00:00
#[export_name = "d"]
#[inline]
extern "C" fn d() {}
2020-06-09 14:49:59 +00:00
// CHECK: define{{.*}}void @e()
2020-06-09 14:49:59 +00:00
#[no_mangle]
#[inline(always)]
pub extern "C" fn e() {}
// CHECK: define{{.*}}void @f()
2020-06-09 14:49:59 +00:00
#[export_name = "f"]
#[inline(always)]
pub extern "C" fn f() {}
// CHECK: define{{.*}}void @g()
2020-06-09 14:49:59 +00:00
#[no_mangle]
#[inline(always)]
extern "C" fn g() {}
// CHECK: define{{.*}}void @h()
2020-06-09 14:49:59 +00:00
#[export_name = "h"]
#[inline(always)]
extern "C" fn h() {}