summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/parse/invalid-op1.C
blob: 0b75d079135a89e64ebce19e72ca083af14ab875 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// PR c++/10150
// Origin: Tom Evans <te200@eng.cam.ac.uk>
// { dg-do compile }

template <int I> struct A
{
    template <int> struct B
    {
        enum { e = I * A<I-1>::B }; // { dg-error "dependent-name" "depname" }
         // { dg-message "note" "note" { target *-*-* } 9 }
    };
};

A<0>::B<0> a; // { dg-message "instantiated" }