[clang] [RFC] Initial implementation of P2719 (PR #113510)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Fri Nov 1 07:07:46 PDT 2024


================
@@ -3096,6 +3096,29 @@ bool Type::isStdByteType() const {
   return false;
 }
 
+TemplateDecl *Type::getSpecializedTemplateDecl() const {
+  const auto *DesugaredType = getUnqualifiedDesugaredType();
+  if (auto *Specialization = DesugaredType->getAs<TemplateSpecializationType>())
----------------
AaronBallman wrote:

```suggestion
  if (const auto *Specialization = DesugaredType->getAs<TemplateSpecializationType>())
```

https://github.com/llvm/llvm-project/pull/113510


More information about the cfe-commits mailing list