From: Ted Kremenek Date: Thu, 28 Mar 2013 18:43:18 +0000 (+0000) Subject: Use early return in printing logic. Minor cleanup. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=65a0892ff5f2c2a70d48b8b649c80967eab67c5e;p=clang Use early return in printing logic. Minor cleanup. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178264 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp b/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp index 856463a981..32a0852ee3 100644 --- a/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp +++ b/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp @@ -3661,8 +3661,10 @@ void RetainCountChecker::printState(raw_ostream &Out, ProgramStateRef State, RefBindingsTy B = State->get(); - if (!B.isEmpty()) - Out << Sep << NL; + if (B.isEmpty()) + return; + + Out << Sep << NL; for (RefBindingsTy::iterator I = B.begin(), E = B.end(); I != E; ++I) { Out << I->first << " : ";