1 2 3 4 5 6 7 8 9 10 11 12 13 14
// PR c++/17763 template <typename U> struct Outer { struct Inner {}; Inner foo(); }; typedef int X; typedef Outer<X> XOuter; int main() { Outer<int> ab; ab.foo() == 1; // { dg-error "operand types are 'Outer<int>::Inner' and 'int'" } }