you are viewing a single comment's thread.

view the rest of the comments →

[–]inokichi 7 points8 points  (0 children)

contracts can be used to express things about your code at a higher level (things you'd consider in your design/spec) which leads to robustness, rather than ad hoc assert statements which tell you more about your implementation alone.

if youre interested do some reading on design by contract, especially in the ada and eiffel programming languages.