summaryrefslogtreecommitdiff
path: root/clang/test/SemaCXX/array-bound-merge.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/SemaCXX/array-bound-merge.cpp')
-rw-r--r--clang/test/SemaCXX/array-bound-merge.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/array-bound-merge.cpp b/clang/test/SemaCXX/array-bound-merge.cpp
new file mode 100644
index 0000000..74f58fa
--- /dev/null
+++ b/clang/test/SemaCXX/array-bound-merge.cpp
@@ -0,0 +1,9 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+// PR5515
+
+extern int a[];
+int a[10];
+extern int b[10];
+int b[];
+extern int c[1];
+int c[] = {1,2}; // expected-error {{excess elements in array initializer}}