summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenCXX/goto.cpp
diff options
context:
space:
mode:
authorCharles Li <charles.li@sony.com>2017-01-09 18:24:16 +0000
committerCharles Li <charles.li@sony.com>2017-01-09 18:24:16 +0000
commitfad02411e05c2824d0d5dad74b356a378ce9665a (patch)
treed3d57a165d00edf27936ed08b84556679d9a6232 /clang/test/CodeGenCXX/goto.cpp
parent8fd58a6be815937f4dbb2b90c175acf0a994545d (diff)
downloadbcm5719-llvm-fad02411e05c2824d0d5dad74b356a378ce9665a.tar.gz
bcm5719-llvm-fad02411e05c2824d0d5dad74b356a378ce9665a.zip
[Lit Test] Make tests C++11 compatible - nothrow destructors
In C++11, a destructor's implicit exception-spec is nothrow. The IR for the destructor's invocation changed from invoke to call. Differential Revision: https://reviews.llvm.org/D28425 llvm-svn: 291458
Diffstat (limited to 'clang/test/CodeGenCXX/goto.cpp')
-rw-r--r--clang/test/CodeGenCXX/goto.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/clang/test/CodeGenCXX/goto.cpp b/clang/test/CodeGenCXX/goto.cpp
index 27bd7affbac..2f5b7197ca0 100644
--- a/clang/test/CodeGenCXX/goto.cpp
+++ b/clang/test/CodeGenCXX/goto.cpp
@@ -1,4 +1,5 @@
-// RUN: %clang_cc1 %s -triple=x86_64-apple-darwin10 -fcxx-exceptions -fexceptions -emit-llvm -o - | FileCheck %s
+// RUN: %clang_cc1 %s -triple=x86_64-apple-darwin10 -fcxx-exceptions -fexceptions -emit-llvm -std=c++98 -o - | FileCheck -check-prefix=CHECK -check-prefix=CHECK98 %s
+// RUN: %clang_cc1 %s -triple=x86_64-apple-darwin10 -fcxx-exceptions -fexceptions -emit-llvm -std=c++11 -o - | FileCheck -check-prefix=CHECK -check-prefix=CHECK11 %s
// Reduced from a crash on boost::interprocess's node_allocator_test.cpp.
namespace test0 {
@@ -24,7 +25,9 @@ namespace test0 {
// CHECK-NEXT: invoke void @_ZN5test01AC1Ev([[A]]* [[TMP]])
// CHECK: invoke void @_ZN5test01VC1ERKNS_1AE([[V]]* [[NEWCAST]], [[A]]* dereferenceable({{[0-9]+}}) [[TMP]])
// CHECK: store i1 false, i1* [[CLEANUPACTIVE]]
- // CHECK-NEXT: invoke void @_ZN5test01AD1Ev([[A]]* [[TMP]])
+
+ // CHECK98-NEXT: invoke void @_ZN5test01AD1Ev([[A]]* [[TMP]])
+ // CHECK11-NEXT: call void @_ZN5test01AD1Ev([[A]]* [[TMP]])
A y;
try {
A z;
OpenPOWER on IntegriCloud