Fix the conditions to unambiguously show the logic they represent. This is the
[oota-llvm.git] / lib / VMCore / Metadata.cpp
index 822dbd9521d289d0ccbf8eb1384befffe6d7d682..b4a981f3a02677339a3479ec786527d16f7d52bd 100644 (file)
@@ -159,10 +159,10 @@ const Function *MDNode::getFunction() const {
 
   for (unsigned i = 0, e = getNumOperands(); i != e; ++i) {
     if (Value *V = getOperand(i)) {
-      if (MDNode *MD = dyn_cast<MDNode>(V))
+      if (MDNode *MD = dyn_cast<MDNode>(V)) {
         if (const Function *F = MD->getFunction()) return F;
-      else
-        return getFunctionForValue(V);
+        else return getFunctionForValue(V);
+      }
     }
   }
   return NULL;