Comment Comment by kgeist What's the advantage of invariants over unit testing? Seems like there must be lot of overhead at runtime.>I was ending up with garbage, and not realizing it until I had visualized it with Graphviz!>Imagine if we had invariants that we could assert after every property change to the tree.Have you tried writing unit tests? What didn't work about them that you decided to try invariants? parent kgeist 3 years ago
>I was ending up with garbage, and not realizing it until I had visualized it with Graphviz!
>Imagine if we had invariants that we could assert after every property change to the tree.
Have you tried writing unit tests? What didn't work about them that you decided to try invariants?