view gcc/testsuite/g++.dg/template/dependent-name11.C @ 152:2b5abeee2509

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents
children
line wrap: on
line source

// PR c++/94057 - template keyword in a typename-specifier.
// { dg-do compile { target c++11 } }

template<typename T> struct A {
  template<typename U>
  struct W { };
};

void
g ()
{
  // class-key nested-name-specifier template[opt] simple-template-id
  struct A<int>::W<int> w;
  struct A<int>::template W<int> w2;
}