(root)/
gcc-13.2.0/
gcc/
testsuite/
g++.dg/
lookup/
pr99116-1.C
// PR 99116 sliding hidden friends under template parm scopes

template<int T> struct Z {

  friend struct T; // { dg-error "shadows template parameter" }
};

struct Y {

  template<typename S> struct A {};

  friend struct S;
};

struct X
{
  struct S2 {};
  
  struct In
  {
    friend struct S2;
  };
};

typedef int S2;