From d767a594c6818c1de586dba4f9c6b0a5cc6cae19 Mon Sep 17 00:00:00 2001 From: Marek Polacek Date: Wed, 17 Jul 2019 18:10:14 +0000 Subject: [PATCH] re PR c++/90455 (braced-init and incomplete type instantiation) PR c++/90455 * g++.dg/cpp0x/nsdmi-list6.C: New test. From-SVN: r273553 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C | 28 ++++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index d3d710796b8..61baf9c8648 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2019-07-17 Marek Polacek + + PR c++/90455 + * g++.dg/cpp0x/nsdmi-list6.C: New test. + 2019-07-17 Jan Hubicka * g++.dg/lto/alias-4_0.C diff --git a/gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C b/gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C new file mode 100644 index 00000000000..83ab2e106ca --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/nsdmi-list6.C @@ -0,0 +1,28 @@ +// PR c++/90455 +// { dg-do compile { target c++11 } } + +struct B; +template struct b { + void operator()(a *) { sizeof(a); } +}; +struct c { + struct D { + using d = B *; + }; + + using e = D::d; + e f(); +}; +template class g { + c h; + using i = b; +public: + ~g() { + auto j = h.f(); + k()(j); + } + i k(); +}; +struct l { + g m{}; +}; -- 2.30.2