summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.other/conv3.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.other/conv3.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.other/conv3.C13
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.other/conv3.C b/gcc/testsuite/g++.old-deja/g++.other/conv3.C
new file mode 100644
index 000000000..383932d8c
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.other/conv3.C
@@ -0,0 +1,13 @@
+// { dg-do assemble }
+
+// submitted by David C Binderman <dcb@pncl.co.uk>
+
+typedef const int ci;
+typedef ci aci[ 10];
+aci var = { 2, 3, 5, 7, 11, 13 };
+
+void
+f()
+{
+ int * ip = var; // { dg-error "" } requires const_cast
+}