| Issue |
53139
|
| Summary |
Bug in partial class template specialization
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
vladon
|
```
template <class A>
struct Foo {
template <class Bar>
constexpr auto a_method();
};
template <class A>
template <class Bar>
constexpr auto Foo<A>::a_method() {
return 42;
}
template <>
template <class Bar>
constexpr auto Foo<void>::a_method() {
return 42;
}
```
It can be compiled with GCC, but not with Clang.
If we first provide explicit specialization, Clang will compile it.
Seems like a bug in Clang.
See also:
https://stackoverflow.com/questions/70670212/is-this-partial-class-specialization-buggy-or-is-it-a-bug-in-clang-or-gcc
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs