PR c++/81917 - ICE with void_t and partial specialization.
[official-gcc.git] / gcc / testsuite / g++.dg / template / qualified-id1.C
blobaf17b2d7a28413f7aefeee4806afdc3a9bf3d948
1 // { dg-do compile }
3 // Copyright (C) 2003 Free Software Foundation, Inc.
4 // Contributed by Nathan Sidwell 4 Sep 2003 <nathan@codesourcery.com>
5 // Origin Volker Reichelt reichelt@igpm.rwth-aachen.de
7 // PR 11922
9 struct A
11   template <bool> struct B;
12   struct C;
15 template <> struct A::B<false> {};
17 template <typename T> void foo()
19   T::C (); // { dg-error "parsed as a non-type|if a type is meant" }
20   T::template B<false>(); // { dg-error "parsed as a non-type" "non-type" }
21                           // { dg-message "if a type" "if a type" { target *-*-* } .-1 }
24 void bar()
26   foo<A>(); // { dg-message "required" }