Hi,

committed to mainline.

Thanks,
Paolo.

///////////////////
2013-11-15  Paolo Carlini  <paolo.carl...@oracle.com>

        PR c++/58188
        * g++.dg/cpp0x/nsdmi-template8.C: New.

2013-11-15  Paolo Carlini  <paolo.carl...@oracle.com>

        PR c++/58725
        * g++.dg/cpp0x/nsdmi-template7.C: New.

2013-11-15  Paolo Carlini  <paolo.carl...@oracle.com>

        PR c++/58829
        * g++.dg/cpp0x/nsdmi-template6.C: New.
Index: g++.dg/cpp0x/nsdmi-template8.C
===================================================================
--- g++.dg/cpp0x/nsdmi-template8.C      (revision 0)
+++ g++.dg/cpp0x/nsdmi-template8.C      (working copy)
@@ -0,0 +1,27 @@
+// PR c++/58188
+// { dg-do compile { target c++11 } }
+
+struct B {};
+struct A
+{
+  A( B );
+};
+
+struct Bar
+{
+  template< unsigned v >
+  struct Foo
+  {
+    A z = B();
+    unsigned value;
+    Foo(): value( v ) {}
+  };
+
+  struct Baz
+  {
+    Foo< 8 > foo1;
+    Foo< 1 > foo3;
+  };
+};
+
+Bar::Baz baz;
Index: g++.dg/cpp0x/nsdmi-template7.C
===================================================================
--- g++.dg/cpp0x/nsdmi-template7.C      (revision 0)
+++ g++.dg/cpp0x/nsdmi-template7.C      (working copy)
@@ -0,0 +1,15 @@
+// PR c++/58725
+// { dg-do compile { target c++11 } }
+
+struct A {
+    template<int=0>
+    struct B {
+        struct C {
+            int x = 0;
+            double y = x;
+        } c;
+    };
+};
+int main() {
+    A::B<>();
+}
Index: g++.dg/cpp0x/nsdmi-template6.C
===================================================================
--- g++.dg/cpp0x/nsdmi-template6.C      (revision 0)
+++ g++.dg/cpp0x/nsdmi-template6.C      (working copy)
@@ -0,0 +1,13 @@
+// PR c++/58829
+// { dg-do compile { target c++11 } }
+
+struct A {
+    int f() {return 0;}
+} a;
+
+struct B {
+    template<int=0> struct C {
+        int i = a.f();
+    };
+};
+B::C<> c;

Reply via email to