Contract programming: Support invariants
Submitted by Robin Sonefors (ozamosi)
Link to original bug (#603419)
Description
Vala has some support for contract programming, by allowing the programmer to specify preconditions with requires, and postconditions with ensures.
It would be nice if Vala also supported invariants: things that should be true both at the start of a function, and after the function has run.
It would be even nicer if the variant support consisted of both method invariants, and class invariants, where the latter should be true after the constructor has finished, and at the start and end of all member methods that run.