Issue 140370
Summary [clang] Assertion `BaseTy->castAs<RecordType>()->getDecl()->getCanonicalDecl() == FD->getParent()->getCanonicalDecl() && "record / field mismatch"' failed.
Labels clang
Assignees
Reporter k-arrows
    Reproducer:
https://godbolt.org/z/a3jnKEz54
```cpp
template <class T> void f(T);

template <class U> class C {
  template <class T> friend void f(T) {
    C<U> c;
    c.i = 0;
  }

  int i;
};

int main() {
  f(0);
  C<float> c;
}
```
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to