Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The correct balance depends on how critical the piece of code you are working on is, and how much you want to write unit tests for it.

In cases where the type system can encode the invariants you care about, it can be worth the extra complexity so that you have code that has compiler enforced correctness (at least in some aspects). Of course, you can't do this for any invariant in a given type system (eg lifetimes are not representable in Java). When it is possible though, debugging a type system has the advantage that it's done on your local machine, away from prod.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: