]> granicus.if.org Git - clang/commitdiff
Remove stale comment and tighten code.
authorTed Kremenek <kremenek@apple.com>
Tue, 20 Oct 2009 23:59:28 +0000 (23:59 +0000)
committerTed Kremenek <kremenek@apple.com>
Tue, 20 Oct 2009 23:59:28 +0000 (23:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@84697 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/CFG.cpp

index 6945c2f376e4ed98ed053ad7b16be8679b1f0f63..31417597f798950efda95a26a166952bdbf3bcde 100644 (file)
@@ -254,12 +254,7 @@ CFG* CFGBuilder::buildCFG(Stmt* Statement, ASTContext* C) {
   // Create an empty entry block that has no predecessors.
   cfg->setEntry(createBlock());
 
-  if (badCFG)
-    return NULL;
-
-  // NULL out cfg so that repeated calls to the builder will fail and that the
-  // ownership of the constructed CFG is passed to the caller.
-  return cfg.take();
+  return badCFG ? NULL : cfg.take();
 }
 
 /// createBlock - Used to lazily create blocks that are connected