We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6fc978b commit aefcbe9Copy full SHA for aefcbe9
clang/include/clang/Sema/Template.h
@@ -486,8 +486,8 @@ enum class TemplateSubstitutionKind : char {
486
const Decl *D = I->first;
487
llvm::PointerUnion<Decl *, DeclArgumentPack *> &Stored =
488
newScope->LocalDecls[D];
489
- if (isa<Decl *>(I->second)) {
490
- Stored = cast<Decl *>(I->second);
+ if (auto *D2 = dyn_cast<Decl *>(I->second)) {
+ Stored = D2;
491
} else {
492
DeclArgumentPack *OldPack = cast<DeclArgumentPack *>(I->second);
493
DeclArgumentPack *NewPack = new DeclArgumentPack(*OldPack);
0 commit comments