diff options
| author | Dan Gohman <gohman@apple.com> | 2010-09-09 18:32:40 +0000 |
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2010-09-09 18:32:40 +0000 |
| commit | 19d19c525ce0bc34b2f360ea1068d19dbfacd745 (patch) | |
| tree | 821665b17673679a9906862e80c9e0833b676db7 /llvm | |
| parent | f20e8239cddff27d9dc0cc2fcadf397879f15608 (diff) | |
| download | bcm5719-llvm-19d19c525ce0bc34b2f360ea1068d19dbfacd745.tar.gz bcm5719-llvm-19d19c525ce0bc34b2f360ea1068d19dbfacd745.zip | |
Add a getPointerOperand() helper function to VAArgInst, for consistency
with LoadInst and StoreInst.
llvm-svn: 113520
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/include/llvm/Instructions.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/include/llvm/Instructions.h b/llvm/include/llvm/Instructions.h index bd1e889de07..a17fb9fc197 100644 --- a/llvm/include/llvm/Instructions.h +++ b/llvm/include/llvm/Instructions.h @@ -1207,6 +1207,10 @@ public: setName(NameStr); } + Value *getPointerOperand() { return getOperand(0); } + const Value *getPointerOperand() const { return getOperand(0); } + static unsigned getPointerOperandIndex() { return 0U; } + // Methods for support type inquiry through isa, cast, and dyn_cast: static inline bool classof(const VAArgInst *) { return true; } static inline bool classof(const Instruction *I) { |

