Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by zahlman on Tuesday December 24, 2024 @06:39AM
(#42501283)
IMX, people who use the term "untyped language" generally: a) use languages with Hindley-Milner inference; b) don't consider things that can "only the program can see at runtime" to qualify as "types".
Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by pjc50 on Tuesday December 24, 2024 @03:57PM
(#42504843)
If your language lets you add a number to a string or divide a dictionary by a boolean, that's .. exciting, but also the sort of thing that produces https://www.destroyallsoftware.com/talks/wat
Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by zahlman on Tuesday December 24, 2024 @04:06PM
(#42504917)
True, but also irrelevant. Python is strongly, but dynamically typed. You cannot do the things you describe in Python, but it's still considered "untyped" in that framework because it performs its type checks at runtime.
Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by teddyh on Tuesday December 24, 2024 @07:05PM
(#42505891)
Those “Wat”s are mostly the result ot weak typing, (as opposed to strong typing) which is an entirely orthogonal concept to static/dynamic typing. Don’t confuse the two concepts. Older languages which first started to experiment with dynamic typing also tended to use weak typing. But as things progressed, weak typing was considered less good in serious languages, while it was still expected in “scripting” languages, and Javascript was designed with that principle. Nowadays we have more or less decided that weak typing is almost always a bad idea, and Python is an example of a modern dynamically typed, and also strongly typed, language.
Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by rootnod3 on Tuesday December 24, 2024 @06:33AM
(#42501253)
Yeah, but even there, if one were to use no LSP or other completions, Hindley Milner doesn't help while editing as you won't see the inferred types. It comes down back to good naming and the compiler at the end.
Re:Ask HN: Programmers who don't use autocomplete/LSP, how d...
by wing-_-nuts on Tuesday December 24, 2024 @12:47PM
(#42503486)
Yeah this is probably someone that doesn't like type script or type hints in python. If you're slinging dynamically typed code for your own personal project, go nuts, but if you're working with a team that 'typing noise' really helps
Yeah, this is going to be extremely controversial: your so-called untyped language actually has types in, and they're important, but only the program can see them at runtime because you've not written them down anywhere.
The real solution to "repeating myself writing down types" is Hindley-Milner inference, which dates back to 1958, and more languages should use it!