DKLoehr wrote:

I ended up with the following reproducer:
```
template <typename T> struct S {
  template <typename T2>
    using Arg = T::template Arg<T2>;
  void f(Arg<void>);
  void f(Arg<int>);
};
```

Running this with `clang++ repro.cc -fsyntax-only -std=c++20` yields
```
repro.cc:5:8: error: class member cannot be redeclared
    5 |   void f(Arg<int>);
      |        ^
repro.cc:4:8: note: previous declaration is here
    4 |   void f(Arg<void>);
      |        ^
```

The same error occurs regardless of which types are inside the < >.

https://github.com/llvm/llvm-project/pull/133610
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to