[clang] [clang-tools-extra] [Clang][AST] Introduce `ExplicitInstantiationDecl` to preserve source info and fix diagnostic locations (PR #191658)
via cfe-commits
cfe-commits at lists.llvm.org
Sat Apr 11 20:23:14 PDT 2026
================
@@ -2101,6 +2101,14 @@ Decl *TemplateDeclInstantiator::VisitStaticAssertDecl(StaticAssertDecl *D) {
InstantiatedMessageExpr.get(), D->getRParenLoc(), D->isFailed());
}
+Decl *TemplateDeclInstantiator::VisitExplicitInstantiationDecl(
+ ExplicitInstantiationDecl *D) {
+ // ExplicitInstantiationDecl is a source-info-only node and should not
+ // appear inside a template pattern. Nothing to instantiate.
+ llvm_unreachable("ExplicitInstantiationDecl should not be instantiated");
+ return nullptr;
----------------
16bit-ykiko wrote:
Fixed.
https://github.com/llvm/llvm-project/pull/191658
More information about the cfe-commits
mailing list