Wiki

Changes between Version 7 and Version 8 of Contracts

Show
Ignore:
Timestamp:
07/02/11 21:04:59 (13 years ago)
Author:
Charles
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Contracts

    v7 v8  
    139139the preconditions/requirements ('''require''') can be augmented through an 
    140140    '''or require'''  
    141 clause meaning that the derivedClass is more flexible about what conditions  
     141clause meaning that the derived class is more flexible about what conditions  
    142142the work can be done in. 
    143143 
     
    147147about the results of the work. 
    148148 
     149Or in other words, an overriding method in a derived class: 
     150 * Can ''weaken'' the precondition/requirement, but not strengthen it. 
     151 * Can ''strengthen'' the postcondition/ensurement, but not weaken it. 
     152 
     153to-do: more explanation and examples are needed here 
     154 
     155See also ticket:280 for a faux bug report that didn't take into account the rules on inheritance and contracts. In comment #3 is more detailed explanation of what's going on. 
    149156 
    150157== Compiler Command Line ==