3 ms·
I think there's considerable overlap between classes of bugs that could be caught by static type checking and those that could be caught by unit tests. That sa
by aix1 5y ago
I think there's considerable overlap between classes of bugs that could be caught by static type checking and those that could be caught by unit tests. That said, I view the two as complementary and use both extensively.
One particularly interesting (though in my experience, rare) class of bugs are typing errors _in unit tests_. For example, an API under test expects one thing and a unit test supplies something else. If the test passes, it's hard to spot the problem without static type checking.