IR: Simplify code, NFC
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Mon, 12 Jan 2015 18:45:01 +0000 (18:45 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Mon, 12 Jan 2015 18:45:01 +0000 (18:45 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225647 91177308-0d34-0410-b5e6-96231b3b80d8

lib/IR/Metadata.cpp

index 7ed0b951a3affeef5ccaea11353297cd283098d2..d048a7f8031ba0c409dbcf3b1612b340ece02b1b 100644 (file)
@@ -619,7 +619,7 @@ void MDNode::replaceOperandWith(unsigned I, Metadata *New) {
   if (getOperand(I) == New)
     return;
 
-  if (isStoredDistinctInContext() || isa<MDNodeFwdDecl>(this)) {
+  if (isDistinct()) {
     setOperand(I, New);
     return;
   }