summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp0x/initlist48.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.dg/cpp0x/initlist48.C')
-rw-r--r--gcc/testsuite/g++.dg/cpp0x/initlist48.C11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/cpp0x/initlist48.C b/gcc/testsuite/g++.dg/cpp0x/initlist48.C
new file mode 100644
index 000000000..9eb451a82
--- /dev/null
+++ b/gcc/testsuite/g++.dg/cpp0x/initlist48.C
@@ -0,0 +1,11 @@
+// PR c++/48726
+// { dg-options -std=c++0x }
+
+#include <memory>
+
+struct Foo{
+ int i;
+};
+typedef std::unique_ptr<Foo> up;
+
+std::initializer_list<up> il{up{new Foo}, up{new Foo}};