summaryrefslogtreecommitdiff
path: root/test/C++Frontend
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-03-01 22:45:12 +0000
committerChris Lattner <sabre@nondot.org>2006-03-01 22:45:12 +0000
commit5df594069342a75a1f83a5c351adbd2e7abd51ea (patch)
tree81f51ba4a5e197d9b9d1f8733623d5cf13a01cab /test/C++Frontend
parent246ae0dcf750401ee84e1319ebe0b790744097a5 (diff)
downloadllvm-5df594069342a75a1f83a5c351adbd2e7abd51ea.tar.gz
llvm-5df594069342a75a1f83a5c351adbd2e7abd51ea.tar.bz2
llvm-5df594069342a75a1f83a5c351adbd2e7abd51ea.tar.xz
testcase that crashed the new CFE
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26465 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/C++Frontend')
-rw-r--r--test/C++Frontend/2006-03-01-GimplifyCrash.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/C++Frontend/2006-03-01-GimplifyCrash.cpp b/test/C++Frontend/2006-03-01-GimplifyCrash.cpp
new file mode 100644
index 0000000000..b0d00fe17d
--- /dev/null
+++ b/test/C++Frontend/2006-03-01-GimplifyCrash.cpp
@@ -0,0 +1,14 @@
+// RUN: %llvmgxx -S %s -o -
+
+struct PrefMapElem {
+ virtual ~PrefMapElem();
+ unsigned int fPrefId;
+};
+
+int foo() {
+ PrefMapElem* fMap;
+ if (fMap[0].fPrefId == 1)
+ return 1;
+
+ return 0;
+}