Skip to content

Commit

Permalink
Remove an unused private data member; NFC
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronBallman committed Mar 14, 2023
1 parent c2a17bf commit f2a6fe6
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions clang/lib/Sema/SemaStmt.cpp
Expand Up @@ -4401,18 +4401,16 @@ template <> struct DenseMapInfo<CatchHandlerType> {

namespace {
class CatchTypePublicBases {
ASTContext &Ctx;
const llvm::DenseMap<QualType, CXXCatchStmt *> &TypesToCheck;

CXXCatchStmt *FoundHandler;
QualType FoundHandlerType;
QualType TestAgainstType;

public:
CatchTypePublicBases(ASTContext &Ctx,
const llvm::DenseMap<QualType, CXXCatchStmt *> &T,
CatchTypePublicBases(const llvm::DenseMap<QualType, CXXCatchStmt *> &T,
QualType QT)
: Ctx(Ctx), TypesToCheck(T), FoundHandler(nullptr), TestAgainstType(QT) {}
: TypesToCheck(T), FoundHandler(nullptr), TestAgainstType(QT) {}

CXXCatchStmt *getFoundHandler() const { return FoundHandler; }
QualType getFoundHandlerType() const { return FoundHandlerType; }
Expand Down Expand Up @@ -4511,7 +4509,7 @@ StmtResult Sema::ActOnCXXTryBlock(SourceLocation TryLoc, Stmt *TryBlock,
// as the original type.
CXXBasePaths Paths;
Paths.setOrigin(RD);
CatchTypePublicBases CTPB(Context, HandledBaseTypes,
CatchTypePublicBases CTPB(HandledBaseTypes,
H->getCaughtType().getCanonicalType());
if (RD->lookupInBases(CTPB, Paths)) {
const CXXCatchStmt *Problem = CTPB.getFoundHandler();
Expand Down

0 comments on commit f2a6fe6

Please sign in to comment.