Index: runtime/lib/mirrors.cc |
diff --git a/runtime/lib/mirrors.cc b/runtime/lib/mirrors.cc |
index f8cc5c8b2082a5734a4f6156cb0300c0fa644d38..a6641b33b6e8b30296ac7df380360f4995dbad33 100644 |
--- a/runtime/lib/mirrors.cc |
+++ b/runtime/lib/mirrors.cc |
@@ -2110,4 +2110,17 @@ DEFINE_NATIVE_ENTRY(VariableMirror_type, 2) { |
return InstantiateType(type, instantiator); |
} |
+DEFINE_NATIVE_ENTRY(TypeMirror_subtypeTest, 2) { |
+ GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, a, arguments->NativeArgAt(0)); |
+ GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, b, arguments->NativeArgAt(1)); |
+ return Bool::Get(a.IsSubtypeOf(b, NULL)).raw(); |
+} |
+ |
+DEFINE_NATIVE_ENTRY(TypeMirror_moreSpecificTest, 2) { |
+ GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, a, arguments->NativeArgAt(0)); |
+ GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, b, arguments->NativeArgAt(1)); |
+ return Bool::Get(a.IsMoreSpecificThan(b, NULL)).raw(); |
+} |
+ |
+ |
} // namespace dart |