]> granicus.if.org Git - clang/commitdiff
Test for the previous commit/crash.
authorDavid Blaikie <dblaikie@gmail.com>
Tue, 24 Jan 2012 04:29:27 +0000 (04:29 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Tue, 24 Jan 2012 04:29:27 +0000 (04:29 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148776 91177308-0d34-0410-b5e6-96231b3b80d8

test/SemaCXX/warn-unreachable.cpp

index 3d368759d7a59ad1f763a204521a3e742fd4b9a2..52da0b922e1e46733d8ee3cbcbcd3a7f5094912c 100644 (file)
@@ -124,3 +124,11 @@ template <> void funcToSpecialize<int>() {
   halt();
   dead(); // expected-warning {{will never be executed}}
 }
+
+// Ensure we don't regress a fix involving undefined bases to template
+// destructors when computing the CFG for unreachable code analysis
+template<int> struct imp;
+template<int a>
+struct aligned_storage : imp<a> {
+ ~aligned_storage() { }
+};