[llvm-commits] [llvm] r115799 - /llvm/trunk/include/llvm/Instructions.h

Dan Gohman gohman at apple.com
Wed Oct 6 09:59:24 PDT 2010


Author: djg
Date: Wed Oct  6 11:59:24 2010
New Revision: 115799

URL: http://llvm.org/viewvc/llvm-project?rev=115799&view=rev
Log:
Remove compatibilty code for old-style multiple return values.

Modified:
    llvm/trunk/include/llvm/Instructions.h

Modified: llvm/trunk/include/llvm/Instructions.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Instructions.h?rev=115799&r1=115798&r2=115799&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Instructions.h (original)
+++ llvm/trunk/include/llvm/Instructions.h Wed Oct  6 11:59:24 2010
@@ -1989,11 +1989,9 @@
   /// Provide fast operand accessors
   DECLARE_TRANSPARENT_OPERAND_ACCESSORS(Value);
 
-  /// Convenience accessor
-  Value *getReturnValue(unsigned n = 0) const {
-    return n < getNumOperands()
-      ? getOperand(n)
-      : 0;
+  /// Convenience accessor. Returns null if there is no return value.
+  Value *getReturnValue() const {
+    return getNumOperands() != 0 ? getOperand(0) : 0;
   }
 
   unsigned getNumSuccessors() const { return 0; }





More information about the llvm-commits mailing list