News for hackers. Stuff that matters.
Re:Why I Prefer Dynamic Typing Over Static Typing (2017) by CharlesColeman on Tuesday February 19, 2019 @11:15AM (#19199971)
All of your data structures have types, whether you declare them or not. Your code expects things to be a certain way, and if it's not, things break. Static typing just means that you annotate you code with your expectations so you can get some automated error and consistency checking.

Automation is good, right?

With dynamic typing, you need to manually write more unit tests to get the same level of confidence. That's just not worth it for anything important.

Re:Why I Prefer Dynamic Typing Over Static Typing (2017) by glhaynes on Tuesday February 19, 2019 @11:20AM (#19200018)
Static typing just means that you annotate you code with your expectations so you can some automated error and consistency checking.

And in languages with type inference, you largely don't even have to do the annotating.

Re:Why I Prefer Dynamic Typing Over Static Typing (2017) by YouAreGreat on Wednesday February 20, 2019 @11:04AM (#19208951)
> All of your data structures have types ... Static typing just means that you annotate ...

Programs have (static) types, data does not. Static typing removes correct programs from the language. Try this in some ML-like language:

    let selfapply f = (f f) in
    let identity x = x in
    selfapply identity 42
If you transcribe this to (e.g.) Lisp, it will return the number 42. The program is short, simple, and safe, but well-regarded static type systems can't cope.
Re:Why I Prefer Dynamic Typing Over Static Typing (2017) by erik_seaberg on Wednesday February 20, 2019 @06:55PM (#19213287)
Any static constraint is likely to rule out good and bad programs. The tradeoff is how irreplacable those good programs are vs. how dangerous those bad programs are. "endofunction over either integers or endofunctions over integers (or over endo…)" is cute but I wouldn't lose a lot of sleep from underconstraining that domain.