An article about contract programming

Walter Bright newshound2 at digitalmars.com
Tue Feb 5 20:05:22 PST 2013


On 2/5/2013 8:57 AM, bearophile wrote:
> D doesn't call the invariant even in that second case, as you see from this code
> that doesn't assert:

Invariants, per the spec, are called on the end of constructors, the beginning 
of destructors, and the beginning and end of public functions. Foo does not have 
any ctors/dtors/functions, hence no invariant call.




More information about the Digitalmars-d-announce mailing list