Allow modifying a global variables constness property
authorChris Lattner <sabre@nondot.org>
Sun, 2 Feb 2003 16:40:40 +0000 (16:40 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 2 Feb 2003 16:40:40 +0000 (16:40 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5468 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/GlobalVariable.h

index 372b7a25e66c975f369ee04b348888fe680e12be..a534d19008b9ede0c7f14e2ed7b6df880d502e9c 100644 (file)
@@ -85,8 +85,9 @@ public:
   /// runtime execution of the program.  Assigning a value into the constant
   /// leads to undefined behavior.
   ///
-  inline bool isConstant() const { return isConstantGlobal; }
-
+  bool isConstant() const { return isConstantGlobal; }
+  void setConstant(bool Value) { isConstantGlobal = Value; }
+  
   virtual void print(std::ostream &OS) const;
 
   // Methods for support type inquiry through isa, cast, and dyn_cast: