diff options
Diffstat (limited to 'gcc/testsuite/g++.dg/cpp0x/initlist31.C')
-rw-r--r-- | gcc/testsuite/g++.dg/cpp0x/initlist31.C | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/cpp0x/initlist31.C b/gcc/testsuite/g++.dg/cpp0x/initlist31.C new file mode 100644 index 000000000..ffc985567 --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/initlist31.C @@ -0,0 +1,13 @@ +// PR c++/43028 +// { dg-options "-std=c++0x" } + +#include <initializer_list> + +struct string { string(std::initializer_list<char>) { } }; + +void f() { + auto y = + { + string(Equation()) // { dg-error "not declared" } + }; // { dg-error "unable to deduce" } +} |