laudz : weblog

Embedded systems, C/C++, GNU/Linux, and Infosec

Aug 3, 2018 - 1 minute read - Comments - compilation

Static typing vs. Dynamic typing

Static typing. I suppose dynamic types are fine if you’re hacking together a small tool. But static (strong, preferably HM-inferred) typing allows you to reason about your program much more powerfully.

Correctness by construction, enforced by the compiler, is a good thing. I used to write a lot of unit tests; now I write many fewer, and instead I write my code closer to the ideal of “if it compiles, it runs correctly”.