================
@@ -8281,6 +8281,13 @@ static bool MatchTemplateParameterKind(
if (Kind != Sema::TPL_TemplateTemplateParmMatch ||
(!OldNTTP->getType()->isDependentType() &&
!NewNTTP->getType()->isDependentType())) {
+
+ // Matching against an invalid declaration is going to be rife with
+ // errors, particularly when `getUnconstrainedType` isn't really valid
+ // there. Just treat these as otherwise invalid.
+ if (OldNTTP->isInvalidDecl() || NewNTTP->isInvalidDecl())
+ return false;
+
----------------
erichkeane wrote:
Yeah, I like that better too. I thought about that at one point but was less
confident that we wouldn't ruin any dependencies though. I'll think about it
further.
https://github.com/llvm/llvm-project/pull/209893
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits