@@ -418,7 +418,7 @@ ExceptionAnalyzer::ExceptionInfo::filterIgnoredExceptions(
418418 if (TD->getDeclName ().isIdentifier ()) {
419419 if ((IgnoreBadAlloc &&
420420 (TD->getName () == " bad_alloc" && TD->isInStdNamespace ())) ||
421- (IgnoredTypes.count (TD->getName ()) > 0 ))
421+ (IgnoredTypes.contains (TD->getName ())))
422422 TypesToDelete.push_back (T);
423423 }
424424 }
@@ -449,7 +449,8 @@ void ExceptionAnalyzer::ExceptionInfo::reevaluateBehaviour() {
449449ExceptionAnalyzer::ExceptionInfo ExceptionAnalyzer::throwsException (
450450 const FunctionDecl *Func, const ExceptionInfo::Throwables &Caught,
451451 llvm::SmallSet<const FunctionDecl *, 32 > &CallStack) {
452- if (!Func || CallStack.count (Func) || (!CallStack.empty () && !canThrow (Func)))
452+ if (!Func || CallStack.contains (Func) ||
453+ (!CallStack.empty () && !canThrow (Func)))
453454 return ExceptionInfo::createNonThrowing ();
454455
455456 if (const Stmt *Body = Func->getBody ()) {
@@ -507,7 +508,7 @@ ExceptionAnalyzer::ExceptionInfo ExceptionAnalyzer::throwsException(
507508 for (unsigned I = 0 ; I < Try->getNumHandlers (); ++I) {
508509 const CXXCatchStmt *Catch = Try->getHandler (I);
509510
510- // Everything is catched through 'catch(...)'.
511+ // Everything is caught through 'catch(...)'.
511512 if (!Catch->getExceptionDecl ()) {
512513 ExceptionInfo Rethrown = throwsException (
513514 Catch->getHandlerBlock (), Uncaught.getExceptionTypes (), CallStack);
0 commit comments