[clang] [Clang][Sema] fix a bug on constraint check with template friend function (PR #90646)
Krystian Stasiowski via cfe-commits
cfe-commits at lists.llvm.org
Wed May 1 06:08:10 PDT 2024
sdkrystian wrote:
```cpp
template<typename T, typename U>
concept D = sizeof(T) == sizeof(U);
template<typename T>
struct A
{
template<typename U, typename V> requires D<U, V>
static void f();
};
template<typename T, typename U>
struct B
{
template<typename V>
struct C
{
friend void A<char>::f<T, U>();
};
};
template struct B<int, int>::C<short>;
extern template void A<char>::f<int, int>(); // crash here
```
https://github.com/llvm/llvm-project/pull/90646
More information about the cfe-commits
mailing list