ART: Rename Handle hierarchy
Bring the names in line with normal OO principles: ConstHandle
becomes Handle, and Handle becomes MutableHandle.
Change-Id: I0f018eb7ba28bc422e3a23dd73a6cbe6fc2d2044
diff --git a/compiler/common_compiler_test.cc b/compiler/common_compiler_test.cc
index db9dcd4..fbaed9f 100644
--- a/compiler/common_compiler_test.cc
+++ b/compiler/common_compiler_test.cc
@@ -367,7 +367,7 @@
MakeExecutable(method);
}
-void CommonCompilerTest::CompileDirectMethod(ConstHandle<mirror::ClassLoader> class_loader,
+void CommonCompilerTest::CompileDirectMethod(Handle<mirror::ClassLoader> class_loader,
const char* class_name, const char* method_name,
const char* signature) {
std::string class_descriptor(DotToDescriptor(class_name));
@@ -380,7 +380,7 @@
CompileMethod(method);
}
-void CommonCompilerTest::CompileVirtualMethod(ConstHandle<mirror::ClassLoader> class_loader,
+void CommonCompilerTest::CompileVirtualMethod(Handle<mirror::ClassLoader> class_loader,
const char* class_name, const char* method_name,
const char* signature) {
std::string class_descriptor(DotToDescriptor(class_name));
diff --git a/compiler/common_compiler_test.h b/compiler/common_compiler_test.h
index 4e74f0a..df06b71 100644
--- a/compiler/common_compiler_test.h
+++ b/compiler/common_compiler_test.h
@@ -63,11 +63,11 @@
void CompileMethod(mirror::ArtMethod* method) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
- void CompileDirectMethod(ConstHandle<mirror::ClassLoader> class_loader, const char* class_name,
+ void CompileDirectMethod(Handle<mirror::ClassLoader> class_loader, const char* class_name,
const char* method_name, const char* signature)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
- void CompileVirtualMethod(ConstHandle<mirror::ClassLoader> class_loader, const char* class_name,
+ void CompileVirtualMethod(Handle<mirror::ClassLoader> class_loader, const char* class_name,
const char* method_name, const char* signature)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc
index b993015..6910e04 100644
--- a/compiler/driver/compiler_driver.cc
+++ b/compiler/driver/compiler_driver.cc
@@ -627,7 +627,7 @@
}
}
-static void ResolveExceptionsForMethod(MethodHelper* mh,
+static void ResolveExceptionsForMethod(MutableMethodHelper* mh,
std::set<std::pair<uint16_t, const DexFile*>>& exceptions_to_resolve)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
const DexFile::CodeItem* code_item = mh->GetMethod()->GetCodeItem();
@@ -670,7 +670,7 @@
std::set<std::pair<uint16_t, const DexFile*>>* exceptions_to_resolve =
reinterpret_cast<std::set<std::pair<uint16_t, const DexFile*>>*>(arg);
StackHandleScope<1> hs(Thread::Current());
- MethodHelper mh(hs.NewHandle<mirror::ArtMethod>(nullptr));
+ MutableMethodHelper mh(hs.NewHandle<mirror::ArtMethod>(nullptr));
for (size_t i = 0; i < c->NumVirtualMethods(); ++i) {
mh.ChangeMethod(c->GetVirtualMethod(i));
ResolveExceptionsForMethod(&mh, *exceptions_to_resolve);
@@ -761,7 +761,7 @@
Thread* self = Thread::Current();
StackHandleScope<1> hs(self);
// Make a copy of the handle so that we don't clobber it doing Assign.
- Handle<mirror::Class> klass(hs.NewHandle(c.Get()));
+ MutableHandle<mirror::Class> klass(hs.NewHandle(c.Get()));
std::string temp;
while (!klass->IsObjectClass()) {
const char* descriptor = klass->GetDescriptor(&temp);