This clang test unfortunately depends on the actions of the optimizer,
which some of the buildbots hit.
This patch makes it so it cannot ignore the return value of 'f', so it
won't do away with the implementation.
// RUN: %clang_cc1 -emit-llvm -o - %s -O1 | FileCheck %s
+// RUN: %clang_cc1 -emit-llvm -o - -fexperimental-new-pass-manager %s -O1 | FileCheck %s
extern int global;
struct S {
return x;
}
-void f() {
- expect_taken<S>(global);
+int f() {
+ return expect_taken<S>(global);
}
int expect_taken2(int x) {