diff options
Diffstat (limited to 'lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp')
-rw-r--r-- | lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp b/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp index 655ce33390c9e..849b1193c042c 100644 --- a/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp +++ b/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp @@ -113,8 +113,7 @@ NonLocalizedStringChecker::NonLocalizedStringChecker() { } namespace { -class NonLocalizedStringBRVisitor final - : public BugReporterVisitorImpl<NonLocalizedStringBRVisitor> { +class NonLocalizedStringBRVisitor final : public BugReporterVisitor { const MemRegion *NonLocalizedString; bool Satisfied; @@ -1017,8 +1016,7 @@ NonLocalizedStringBRVisitor::VisitNode(const ExplodedNode *Succ, if (!LiteralExpr) return nullptr; - ProgramStateRef State = Succ->getState(); - SVal LiteralSVal = State->getSVal(LiteralExpr, Succ->getLocationContext()); + SVal LiteralSVal = Succ->getSVal(LiteralExpr); if (LiteralSVal.getAsRegion() != NonLocalizedString) return nullptr; @@ -1108,7 +1106,7 @@ void EmptyLocalizationContextChecker::checkASTDecl( void EmptyLocalizationContextChecker::MethodCrawler::VisitObjCMessageExpr( const ObjCMessageExpr *ME) { - // FIXME: We may be able to use PPCallbacks to check for empy context + // FIXME: We may be able to use PPCallbacks to check for empty context // comments as part of preprocessing and avoid this re-lexing hack. const ObjCInterfaceDecl *OD = ME->getReceiverInterface(); if (!OD) @@ -1389,7 +1387,7 @@ void PluralMisuseChecker::MethodCrawler::reportPluralMisuseError( // Generate the bug report. BR.EmitBasicReport(AC->getDecl(), Checker, "Plural Misuse", "Localizability Issue (Apple)", - "Plural cases are not supported accross all languages. " + "Plural cases are not supported across all languages. " "Use a .stringsdict file instead", PathDiagnosticLocation(S, BR.getSourceManager(), AC)); } |