diff options
Diffstat (limited to 'runtime/dex_instruction.cc')
-rw-r--r-- | runtime/dex_instruction.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/runtime/dex_instruction.cc b/runtime/dex_instruction.cc index e64c0f62c2..6ebe2286e8 100644 --- a/runtime/dex_instruction.cc +++ b/runtime/dex_instruction.cc @@ -548,4 +548,14 @@ std::ostream& operator<<(std::ostream& os, const Instruction::Code& code) { return os << Instruction::Name(code); } +uint32_t RangeInstructionOperands::GetOperand(size_t operand_index) const { + DCHECK_LT(operand_index, GetNumberOfOperands()); + return first_operand_ + operand_index; +} + +uint32_t VarArgsInstructionOperands::GetOperand(size_t operand_index) const { + DCHECK_LT(operand_index, GetNumberOfOperands()); + return operands_[operand_index]; +} + } // namespace art |