News for hackers. Stuff that matters.
Re:Reasons to avoid static type checking by arialdomartini on Sunday January 28, 2024 @02:54AM (#39163416)
The wrong assumption in that page is that Static Typing implies the need for type hints or annotations.

In fact, type inference is a thing.

Most of the languages with Hindley Millner type system (such as oCaml, F#, Haskell, PureScript) do feel dynamic (e.g., developer does not need to hint the compiler) yet they are purely static typed.

What is the argument against having Python checking the types, without asking the developers to change their code?

Re:Reasons to avoid static type checking by tsss on Monday January 29, 2024 @08:25AM (#39175942)
Haskell has to pay _a lot_ to achieve full type inference. A price that is way too high imo for a feature that nobody uses anyway. Among many other things it precludes subtyping, which I assume Python relies on heavily.
Re:Reasons to avoid static type checking by tome on Monday January 29, 2024 @09:23AM (#39176578)
I suspect almost every Haskell uses full type inference almost constantly, if only to avoid having to write out top level types by hand. I know that applies to me. I've never considered that I paid a price for it. For me it was just something that came free with a language that is nice in other ways too. What price are you seeing? (For me, absence of subtyping is a feature.)