(no title)
12thwonder | 4 years ago
I don't do that any more. simply because I'm very lazy and also in a lot of cases, those types that I wrote will be replaced by more dynamic representation (e.g. strings) at some point.
12thwonder | 4 years ago
I don't do that any more. simply because I'm very lazy and also in a lot of cases, those types that I wrote will be replaced by more dynamic representation (e.g. strings) at some point.
ebingdom|4 years ago
I'm lazy too, but that's exactly why I use static types. So that when I refactor code, I can let the type checker tell me all the places that need to be updated instead of trying to piece that together from test failures (and praying that the tests didn't miss anything).
12thwonder|4 years ago
later in a project where you know for sure something can be known at compile time, of course I love to check them at compile time.
scns|4 years ago
ourcat|4 years ago
Initially, I couldn't really see the point, but if anything I find it helps with catching errors and response expectations before build-time and also auto-completion/pseudo-documentation/hinting in VSCode.
Now, I love it.
iamevn|4 years ago
I've only seen type systems that work like this on numbers, and usually only a very few integers at that.
jkhdigital|4 years ago
Hopefully we see these ideas make their way into functional languages soon.
dboreham|4 years ago
scns|4 years ago