diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/assign1.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.pt/assign1.C | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/assign1.C b/gcc/testsuite/g++.old-deja/g++.pt/assign1.C new file mode 100644 index 000000000..854d8ee27 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.pt/assign1.C @@ -0,0 +1,14 @@ +// { dg-do compile } +// Origin: Mark Mitchell <mark@codesourcery.com> + +template <class T> +struct S { // { dg-error "const|operator=" } + S(); + T t; +}; + +void f() +{ + S<const int> s; + s = s; // { dg-message "synthesized|deleted" } +} |