2014-07-12 07:54:29 +08:00
|
|
|
// RUN: %clang_cc1 -fms-extensions -triple x86_64-unknown-unknown -emit-llvm %s -o - | FileCheck %s
|
2012-10-14 06:30:41 +08:00
|
|
|
|
2014-07-12 07:54:29 +08:00
|
|
|
struct A {
|
2012-10-14 06:30:41 +08:00
|
|
|
~A() {}
|
|
|
|
};
|
|
|
|
|
2014-07-12 07:54:29 +08:00
|
|
|
extern "C" int f() {
|
2020-02-04 02:09:39 +08:00
|
|
|
// CHECK: define i32 @f()
|
2012-10-14 06:30:41 +08:00
|
|
|
// CHECK-NOT: call void @_ZN1AD1Ev
|
2014-07-12 04:22:55 +08:00
|
|
|
// CHECK: ret i32 0
|
|
|
|
return __noop(A());
|
2012-10-14 06:30:41 +08:00
|
|
|
};
|
2014-07-12 07:54:29 +08:00
|
|
|
|
|
|
|
extern "C" int g() {
|
|
|
|
return __noop;
|
2020-02-04 02:09:39 +08:00
|
|
|
// CHECK: define i32 @g()
|
2014-07-12 07:54:29 +08:00
|
|
|
// CHECK: ret i32 0
|
|
|
|
}
|
|
|
|
|
|
|
|
extern "C" int h() {
|
|
|
|
return (__noop);
|
2020-02-04 02:09:39 +08:00
|
|
|
// CHECK: define i32 @h()
|
2014-07-12 07:54:29 +08:00
|
|
|
// CHECK: ret i32 0
|
|
|
|
}
|
|
|
|
|
|
|
|
extern "C" int i() {
|
|
|
|
return __noop + 1;
|
2020-02-04 02:09:39 +08:00
|
|
|
// CHECK: define i32 @i()
|
2014-07-12 07:54:29 +08:00
|
|
|
// CHECK: ret i32 1
|
|
|
|
}
|