diff options
Diffstat (limited to 'runtime/method_helper-inl.h')
-rw-r--r-- | runtime/method_helper-inl.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/runtime/method_helper-inl.h b/runtime/method_helper-inl.h index 9af835ff70..143f4bc9bb 100644 --- a/runtime/method_helper-inl.h +++ b/runtime/method_helper-inl.h @@ -26,7 +26,9 @@ namespace art { -inline bool MethodHelper::HasSameNameAndSignature(MethodHelper* other) { +template <template <class T> class HandleKind> +template <template <class T2> class HandleKind2> +inline bool MethodHelperT<HandleKind>::HasSameNameAndSignature(MethodHelperT<HandleKind2>* other) { const DexFile* dex_file = method_->GetDexFile(); const DexFile::MethodId& mid = dex_file->GetMethodId(GetMethod()->GetDexMethodIndex()); if (method_->GetDexCache() == other->method_->GetDexCache()) { @@ -43,7 +45,9 @@ inline bool MethodHelper::HasSameNameAndSignature(MethodHelper* other) { return dex_file->GetMethodSignature(mid) == other_dex_file->GetMethodSignature(other_mid); } -inline mirror::Class* MethodHelper::GetClassFromTypeIdx(uint16_t type_idx, bool resolve) { +template <template <class T> class HandleKind> +inline mirror::Class* MethodHelperT<HandleKind>::GetClassFromTypeIdx(uint16_t type_idx, + bool resolve) { mirror::ArtMethod* method = GetMethod(); mirror::Class* type = method->GetDexCacheResolvedType(type_idx); if (type == nullptr && resolve) { @@ -53,7 +57,8 @@ inline mirror::Class* MethodHelper::GetClassFromTypeIdx(uint16_t type_idx, bool return type; } -inline mirror::Class* MethodHelper::GetReturnType(bool resolve) { +template <template <class T> class HandleKind> +inline mirror::Class* MethodHelperT<HandleKind>::GetReturnType(bool resolve) { mirror::ArtMethod* method = GetMethod(); const DexFile* dex_file = method->GetDexFile(); const DexFile::MethodId& method_id = dex_file->GetMethodId(method->GetDexMethodIndex()); @@ -62,7 +67,8 @@ inline mirror::Class* MethodHelper::GetReturnType(bool resolve) { return GetClassFromTypeIdx(return_type_idx, resolve); } -inline mirror::String* MethodHelper::ResolveString(uint32_t string_idx) { +template <template <class T> class HandleKind> +inline mirror::String* MethodHelperT<HandleKind>::ResolveString(uint32_t string_idx) { mirror::ArtMethod* method = GetMethod(); mirror::String* s = method->GetDexCacheStrings()->Get(string_idx); if (UNLIKELY(s == nullptr)) { |