summaryrefslogtreecommitdiff
path: root/test/C++Frontend
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-09-28 02:29:40 +0000
committerChris Lattner <sabre@nondot.org>2004-09-28 02:29:40 +0000
commit584902e0a3d79b9e6598da34cc5db798f833699a (patch)
tree7e88209c9d033f97417e0030aa0fcecaa591b3be /test/C++Frontend
parent148d2065e4eb60357014a39c8e0d66c908679ffd (diff)
downloadllvm-584902e0a3d79b9e6598da34cc5db798f833699a.tar.gz
llvm-584902e0a3d79b9e6598da34cc5db798f833699a.tar.bz2
llvm-584902e0a3d79b9e6598da34cc5db798f833699a.tar.xz
New testcase that crashes the C++ FE, encountered while working on PR445
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16532 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/C++Frontend')
-rw-r--r--test/C++Frontend/2004-09-27-CompilerCrash.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/C++Frontend/2004-09-27-CompilerCrash.cpp b/test/C++Frontend/2004-09-27-CompilerCrash.cpp
new file mode 100644
index 0000000000..71b3cc876d
--- /dev/null
+++ b/test/C++Frontend/2004-09-27-CompilerCrash.cpp
@@ -0,0 +1,17 @@
+
+
+struct Pass {} ;
+template<typename PassName>
+Pass *callDefaultCtor() { return new PassName(); }
+
+void foo(Pass *(*C)());
+
+#include <bits/c++config.h>
+#include <bits/stringfwd.h>
+#include <bits/char_traits.h>
+#include <memory> // For allocator.
+#include <bits/basic_string.h>
+
+bool foo(std::string &X) {
+ return X.empty();
+}