diff options
Diffstat (limited to 'include/llvm/IR/GlobalVariable.h')
-rw-r--r-- | include/llvm/IR/GlobalVariable.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/llvm/IR/GlobalVariable.h b/include/llvm/IR/GlobalVariable.h index bfed50786e..a5ab97db23 100644 --- a/include/llvm/IR/GlobalVariable.h +++ b/include/llvm/IR/GlobalVariable.h @@ -48,6 +48,7 @@ class GlobalVariable : public GlobalValue, public ilist_node<GlobalVariable> { // can change from its initial // value before global // initializers are run? + bool notAddrTaken : 1; // Dose not have address taken. public: // allocate space for exactly one operand @@ -174,6 +175,9 @@ public: isExternallyInitializedConstant = Val; } + void setAddressMaybeTaken(bool Val) { notAddrTaken = !Val; } + bool AddressMaybeTaken(void) const { return !notAddrTaken; } + /// copyAttributesFrom - copy all additional attributes (those not needed to /// create a GlobalVariable) from the GlobalVariable Src to this one. void copyAttributesFrom(const GlobalValue *Src); |