+
+ # Check that `sub` is a subtype of `sup`.
+ # Do not display an error message.
+ #
+ # This method is used a an entry point for the modelize phase to test static subtypes.
+ # Some refinements could redefine it to collect statictics.
+ fun check_subtype(node: ANode, mmodule: MModule, anchor: nullable MClassType, sub, sup: MType): Bool
+ do
+ return sub.is_subtype(mmodule, anchor, sup)
+ end
+
+ # Check that `sub` and `sup` are equvalent types.
+ # Do not display an error message.
+ #
+ # This method is used a an entry point for the modelize phase to test static equivalent types.
+ # Some refinements could redefine it to collect statictics.
+ fun check_sametype(node: ANode, mmodule: MModule, anchor: nullable MClassType, sub, sup: MType): Bool
+ do
+ return sub.is_subtype(mmodule, anchor, sup) and sup.is_subtype(mmodule, anchor, sub)
+ end