Skip to content

Commit

Permalink
iterator based accessors for CodeGenInstruction operand list.
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206550 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
Jim Grosbach committed Apr 18, 2014
1 parent a361096 commit 3db76cc
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions utils/TableGen/CodeGenInstruction.h
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,13 @@ namespace llvm {
OperandInfo &back() { return OperandList.back(); }
const OperandInfo &back() const { return OperandList.back(); }

typedef std::vector<OperandInfo>::iterator iterator;
typedef std::vector<OperandInfo>::const_iterator const_iterator;
iterator begin() { return OperandList.begin(); }
const_iterator begin() const { return OperandList.begin(); }
iterator end() { return OperandList.end(); }
const_iterator end() const { return OperandList.end(); }


/// getOperandNamed - Return the index of the operand with the specified
/// non-empty name. If the instruction does not have an operand with the
Expand Down

0 comments on commit 3db76cc

Please sign in to comment.