diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C')
-rw-r--r-- | gcc-4.9/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C b/gcc-4.9/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C new file mode 100644 index 0000000..9d8a3bd --- /dev/null +++ b/gcc-4.9/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C @@ -0,0 +1,16 @@ +// { dg-do compile { target c++11 } } +// { dg-options "" } + +struct S { }; + +struct T +{ + S s; +}; + +void f(T const &); + +void g() +{ + f((T){S()}); +} |