Re:Cold Showers
by glouwbug on Saturday June 18, 2022 @04:38PM
(#31793610)
Until the types don't match the execution model... see: python type hints
[ Parent
| on HN ]
Re:Cold Showers
by slaymaker1907 on Saturday June 18, 2022 @04:54PM
(#31793733)
I find that is a far less common problem than the documentation being wrong. Even if someone doesn't add documentation for some library, static types provide a lot more insight into how it works than dynamic languages (Racket style contracts are even better since they can check way more than static types while still working in a first class way with docs).
Re:Cold Showers
by HL33tibCe7 on Saturday June 18, 2022 @05:27PM
(#31793986)
That isn’t static typing
That’s a dynamic typed language with comments
They can be consumed by static analysis tooling, which assuming properly configured etc. makes it sort of 'dynamically typed language with the guarantees of a statically typed one', at least so far as the hints are complete.
Re:Cold Showers
by semiquaver on Saturday June 18, 2022 @09:00PM
(#31795212)
Most statically typed languages compile down to object code which runs in one of the most dynamic runtime environments imaginable. What are the types in the source code but “comments”?