Abstract
Design contracts can be used in software development to ensure the preservation of assertions for program correctness. This can increase reliability in software design. Design by Contractâ„¢ (DBC) was developed by Bertrand Meyer and is supported by the Eiffel programming language. Eiffel provides support for checking preconditions, postconditions, and class invariants automatically at runtime.
Even though DBC has been supported by Eiffel since 1985, other programming languages that offer built-in DBC support are still rare. Redundant efforts have taken place to implement the support of DBC for different object-oriented programming languages. This project designs and implements a framework for extending object oriented languages to support DBC. The framework can eliminate this redundant effort for various languages and can simplify the addition of DBC mechanisms for programming language developers.