4 ms·
> unlike the type system, the enforcement of the convention does not come automatically This defeats the whole purpose. > the programmer has to write static a
by nine_k 9y ago
> unlike the type system, the enforcement of the convention does not come automatically
This defeats the whole purpose.
> the programmer has to write static analysis code
It is legwork that should be relegated to the computer. And, in fact, has been for a long time. I don't only mean type systems; various linters and checkers work where the compiler proper does not (see valgrind or findbugs). Frankly, a lot of test cases for code can be written automatically; the prime example is Haskell's QuickCheck, but a number of other languages has similar tools, all the way down to fully dynamic ones like Python.
- hzhou321 9y agoCreating and maintain type system is also leg walk (and I was arguing it is a bigger burden of leg walk). And a Turing complete type system can have Turing complete errors. Let's not pretend we have silver bullet and have a fair discussion