PR17730: Add test that we don't crash on this testcase. (The bug is already fixed.)
authorRichard Smith <richard-llvm@metafoo.co.uk>
Tue, 28 Oct 2014 17:00:19 +0000 (17:00 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Tue, 28 Oct 2014 17:00:19 +0000 (17:00 +0000)
llvm-svn: 220787

clang/test/SemaTemplate/crash.cpp [new file with mode: 0644]

diff --git a/clang/test/SemaTemplate/crash.cpp b/clang/test/SemaTemplate/crash.cpp
new file mode 100644 (file)
index 0000000..428e95c
--- /dev/null
@@ -0,0 +1,11 @@
+// RUN: not %clang_cc1 -verify %s -std=c++11
+
+// PR17730
+template <typename T>
+void S<T>::mem1();
+
+template <typename T>
+void S<T>::mem2() {
+    const int I = sizeof(T);
+      (void)I;
+}