A Syntax-Directed Hoare Logic for Object-Oriented Programming Concepts
- Cite this paper as:
- Pierik C., de Boer F.S. (2003) A Syntax-Directed Hoare Logic for Object-Oriented Programming Concepts. In: Najm E., Nestmann U., Stevens P. (eds) Formal Methods for Open Object-Based Distributed Systems. FMOODS 2003. Lecture Notes in Computer Science, vol 2884. Springer, Berlin, Heidelberg
This paper outlines a sound and complete Hoare logic for a sequential object-oriented language with inheritance and subtyping like Java. It describes a weakest precondition calculus for assignments and object-creation, as well as Hoare rules for reasoning about (mutually recursive) method invocations with dynamic binding. Our approach enables reasoning at an abstraction level that coincides with the general abstraction level of object-oriented languages.