[llvm-commits] CVS: llvm/include/llvm/Module.h

Reid Spencer reid at x10sys.com
Wed May 31 09:40:41 PDT 2006



Changes in directory llvm/include/llvm:

Module.h updated: 1.72 -> 1.73
---
Log message:

Make the getNamedFunction and getNamedGlobal methods be const. They don't
change the module in any way and we should enforce that.


---
Diffs of the changes:  (+2 -2)

 Module.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/include/llvm/Module.h
diff -u llvm/include/llvm/Module.h:1.72 llvm/include/llvm/Module.h:1.73
--- llvm/include/llvm/Module.h:1.72	Wed May 17 21:10:31 2006
+++ llvm/include/llvm/Module.h	Wed May 31 11:40:28 2006
@@ -179,7 +179,7 @@
   /// getNamedFunction - Return the first function in the module with the
   /// specified name, of arbitrary type.  This method returns null if a function
   /// with the specified name is not found.
-  Function *getNamedFunction(const std::string &Name);
+  Function *getNamedFunction(const std::string &Name) const;
 
 /// @}
 /// @name Global Variable Accessors 
@@ -197,7 +197,7 @@
   /// getNamedGlobal - Return the first global variable in the module with the
   /// specified name, of arbitrary type.  This method returns null if a global
   /// with the specified name is not found.
-  GlobalVariable *getNamedGlobal(const std::string &Name);
+  GlobalVariable *getNamedGlobal(const std::string &Name) const;
   
 /// @}
 /// @name Type Accessors






More information about the llvm-commits mailing list