3 ms·
Has anyone had success (or failure) in the real world with enforcing preconditions, postconditions and invariants? Has this caught bugs faster, reduced side eff
by symplee 7y ago
Has anyone had success (or failure) in the real world with enforcing preconditions, postconditions and invariants? Has this caught bugs faster, reduced side effects and helped ensure overall correctness? Or has it lead to more overhead and longer development time without much to show for all the effort?
https://en.wikipedia.org/wiki/Design_by_contract https://en.wikipedia.org/wiki/Design_by_contract
https://en.wikipedia.org/wiki/Class_invariant https://en.wikipedia.org/wiki/Class_invariant
- rytill 7y agoI remember doing this in one of my first programming courses, way too early to look at it with respect to any real-world usage. I wonder if it's still useful in combination with async/await.