Skip to Main Content
While object types are an abstract specification of object behaviors, object behaviors are significantly affected by method interdependencies in objects. Conventionally, method interdependency information of objects is not reflected in object types. As a result, objects with sufficiently distinct behaviors can be confused to have the same type in conventional type systems, which, among other things, opens the door to let more faulty programs to be compiled and thus weakens the reliability of programs. In this paper, we (1) introduce the notion of object type graphs (OTG) which captures method interdependencies and integrates them into object types; (2) define object typing and subtyping under OTG; (3) demonstrate how problems existing in conventional type systems can be easily resolved under OTG; (4) present an algorithm for computing object method interdependencies; and (5) provide a soundness proof of the OTG system. We argue that OTG system is one step forward towards increasing the reliability of programs.