From 84b322eb170ee8c8dfc74aa33ac2107241a8f3e9 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sat, 10 Nov 2001 06:48:14 +0000 Subject: [PATCH] Provide const version of function with the name the other will be eventually renamed to git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1241 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/iMemory.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/llvm/iMemory.h b/include/llvm/iMemory.h index f3ec30281da..29518686cfe 100644 --- a/include/llvm/iMemory.h +++ b/include/llvm/iMemory.h @@ -187,6 +187,9 @@ public: inline bool hasIndices() const { return !indexVec.empty(); } virtual Value *getPtrOperand() = 0; + const Value *getPointerOperand() const { + return ((MemAccessInst*)this)->getPtrOperand(); + } virtual int getFirstOffsetIdx() const = 0; }; -- 2.34.1