[llvm-commits] [dragonegg] r135881 - in /dragonegg/trunk: include/dragonegg/ABI.h src/Convert.cpp src/Types.cpp

Duncan Sands baldrick at free.fr
Sun Jul 24 11:46:44 PDT 2011


Author: baldrick
Date: Sun Jul 24 13:46:44 2011
New Revision: 135881

URL: http://llvm.org/viewvc/llvm-project?rev=135881&view=rev
Log:
As CallingConv::ID is a scalar, there is no point in returning it
by reference.

Modified:
    dragonegg/trunk/include/dragonegg/ABI.h
    dragonegg/trunk/src/Convert.cpp
    dragonegg/trunk/src/Types.cpp

Modified: dragonegg/trunk/include/dragonegg/ABI.h
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/include/dragonegg/ABI.h?rev=135881&r1=135880&r2=135881&view=diff
==============================================================================
--- dragonegg/trunk/include/dragonegg/ABI.h (original)
+++ dragonegg/trunk/include/dragonegg/ABI.h Sun Jul 24 13:46:44 2011
@@ -42,7 +42,7 @@
 /// interface that can be subclassed.
 struct DefaultABIClient {
   virtual ~DefaultABIClient() {}
-  virtual CallingConv::ID& getCallingConv(void) = 0;
+  virtual CallingConv::ID getCallingConv(void) = 0;
   virtual bool isShadowReturn() const { return false; }
 
   /// HandleScalarResult - This callback is invoked if the function returns a

Modified: dragonegg/trunk/src/Convert.cpp
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/src/Convert.cpp?rev=135881&r1=135880&r2=135881&view=diff
==============================================================================
--- dragonegg/trunk/src/Convert.cpp (original)
+++ dragonegg/trunk/src/Convert.cpp Sun Jul 24 13:46:44 2011
@@ -308,7 +308,7 @@
         isShadowRet(false) {}
 
     /// getCallingConv - This provides the desired CallingConv for the function.
-    CallingConv::ID& getCallingConv(void) { return CallingConv; }
+    CallingConv::ID getCallingConv(void) { return CallingConv; }
 
     void HandlePad(llvm::Type * /*LLVMTy*/) {
       ++AI;
@@ -2579,7 +2579,7 @@
         isShadowRet(false), isAggrRet(false), Offset(0) { }
 
     /// getCallingConv - This provides the desired CallingConv for the function.
-    CallingConv::ID& getCallingConv(void) { return CallingConv; }
+    CallingConv::ID getCallingConv(void) { return CallingConv; }
 
     // Push the address of an argument.
     void pushAddress(Value *Loc) {

Modified: dragonegg/trunk/src/Types.cpp
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/src/Types.cpp?rev=135881&r1=135880&r2=135881&view=diff
==============================================================================
--- dragonegg/trunk/src/Types.cpp (original)
+++ dragonegg/trunk/src/Types.cpp Sun Jul 24 13:46:44 2011
@@ -714,7 +714,7 @@
     }
 
     /// getCallingConv - This provides the desired CallingConv for the function.
-    CallingConv::ID& getCallingConv(void) { return CallingConv; }
+    CallingConv::ID getCallingConv(void) { return CallingConv; }
 
     bool isShadowReturn() const { return isShadowRet; }
 





More information about the llvm-commits mailing list