From 8a0128a5ca0784f6d2b4ca27907e8967a74bc4c5 Mon Sep 17 00:00:00 2001 From: Andreas Gampe Date: Mon, 28 Nov 2016 07:38:35 -0800 Subject: ART: Add dex::StringIndex Add abstraction for uint32_t string index. Test: m test-art-host Change-Id: I917c2881702fe3df112c713f06980f2278ced7ed --- compiler/driver/compiler_driver.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'compiler/driver/compiler_driver.cc') diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc index ad75ec4604..42e5db3570 100644 --- a/compiler/driver/compiler_driver.cc +++ b/compiler/driver/compiler_driver.cc @@ -842,9 +842,9 @@ static void ResolveConstStrings(Handle dex_cache, switch (inst->Opcode()) { case Instruction::CONST_STRING: case Instruction::CONST_STRING_JUMBO: { - uint32_t string_index = (inst->Opcode() == Instruction::CONST_STRING) + dex::StringIndex string_index((inst->Opcode() == Instruction::CONST_STRING) ? inst->VRegB_21c() - : inst->VRegB_31c(); + : inst->VRegB_31c()); mirror::String* string = class_linker->ResolveString(dex_file, string_index, dex_cache); CHECK(string != nullptr) << "Could not allocate a string when forcing determinism"; break; -- cgit v1.2.3-59-g8ed1b