Changes between Version 7 and Version 8 of Contracts
- Timestamp:
- 07/02/11 21:04:59 (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Contracts
v7 v8 139 139 the preconditions/requirements ('''require''') can be augmented through an 140 140 '''or require''' 141 clause meaning that the derived Class is more flexible about what conditions141 clause meaning that the derived class is more flexible about what conditions 142 142 the work can be done in. 143 143 … … 147 147 about the results of the work. 148 148 149 Or 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 153 to-do: more explanation and examples are needed here 154 155 See 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. 149 156 150 157 == Compiler Command Line ==