Address review comments for change 25352fc06c84cdab8a2ab.

Test: make test-art-host
Bug: 30550796

Change-Id: Ic689e4c9bee691f03703288c3b12634a26841140
diff --git a/runtime/class_linker_test.cc b/runtime/class_linker_test.cc
index 593702d..451b752 100644
--- a/runtime/class_linker_test.cc
+++ b/runtime/class_linker_test.cc
@@ -1328,7 +1328,7 @@
   // This is the MethodType corresponding to the prototype of
   // String MethodTypes# method1(String).
   // Its RType = Ljava/lang/String;
-  // Its PTypes = { Ljava/langString; }
+  // Its PTypes = { Ljava/lang/String; }
   Handle<mirror::MethodType> method1_type = hs.NewHandle(
       class_linker_->ResolveMethodType(dex_file, method1_id.proto_idx_, dex_cache, class_loader));
 
diff --git a/runtime/mirror/dex_cache-inl.h b/runtime/mirror/dex_cache-inl.h
index 41692da..0fa6d6b 100644
--- a/runtime/mirror/dex_cache-inl.h
+++ b/runtime/mirror/dex_cache-inl.h
@@ -92,7 +92,7 @@
 
 inline void DexCache::SetResolvedMethodType(uint32_t proto_idx, MethodType* resolved) {
   DCHECK(Runtime::Current()->IsMethodHandlesEnabled());
-  DCHECK_LT(proto_idx, NumResolvedMethodTypes());  // NOTE: Unchecked, i.e. not throwing AIOOB.
+  DCHECK_LT(proto_idx, GetDexFile()->NumProtoIds());
 
   GetResolvedMethodTypes()[proto_idx % NumResolvedMethodTypes()].store(
       MethodTypeDexCachePair(resolved, proto_idx), std::memory_order_relaxed);