Comment by zahlman

1 year ago

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".

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

  • 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.

  • 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.