ObjPtr misc cleanup

Check for subtypes in constructor.

Remove various calls to MakeObjPtr and ObjPtr::Ptr.

Bug: 31113334

Test: test-art-host
Change-Id: I8d680d514ea52cd64fc4f7c2e988926bc726174e
diff --git a/runtime/class_linker_test.cc b/runtime/class_linker_test.cc
index 5466539..d45495c 100644
--- a/runtime/class_linker_test.cc
+++ b/runtime/class_linker_test.cc
@@ -875,7 +875,7 @@
   uint32_t type_idx = klass->GetClassDef()->class_idx_;
   ObjPtr<mirror::DexCache> dex_cache = klass->GetDexCache();
   const DexFile& dex_file = klass->GetDexFile();
-  EXPECT_EQ(dex_cache->GetResolvedType(type_idx), klass.Ptr());
+  EXPECT_OBJ_PTR_EQ(dex_cache->GetResolvedType(type_idx), klass);
   EXPECT_OBJ_PTR_EQ(
       class_linker_->LookupResolvedType(dex_file, type_idx, dex_cache, class_loader.Get()),
       klass);