File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -373,11 +373,11 @@ static CheckersList getAnalyzerCheckersAndPackages(ClangTidyContext &Context,
373
373
374
374
const auto &RegisteredCheckers =
375
375
AnalyzerOptions::getRegisteredCheckers (IncludeExperimental);
376
- bool AnalyzerChecksEnabled = false ;
377
- for ( StringRef CheckName : RegisteredCheckers) {
378
- std::string ClangTidyCheckName ((AnalyzerCheckNamePrefix + CheckName). str ());
379
- AnalyzerChecksEnabled |= Context. isCheckEnabled (ClangTidyCheckName );
380
- }
376
+ const bool AnalyzerChecksEnabled =
377
+ llvm::any_of (RegisteredCheckers, [&]( StringRef CheckName) -> bool {
378
+ return Context. isCheckEnabled (
379
+ (AnalyzerCheckNamePrefix + CheckName). str () );
380
+ });
381
381
382
382
if (!AnalyzerChecksEnabled)
383
383
return List;
You can’t perform that action at this time.
0 commit comments