Re:JavaScript: The Curious Case of null >= 0
by alangpierce on Saturday September 09, 2017 @10:27AM
(#15207219)
> I really wish the industry settled on terms for this stuff
I've pretty consistently heard "strong typing" to mean that the language avoids coercing between types, and "static typing" to mean that types are known at compile time. So JS and Python are both dynamic typed, but Python is (more) strongly typed and JS is (more) weakly typed.
https://stackoverflow.com/questions/2690544/what-is-the-diff...
Re:JavaScript: The Curious Case of null >= 0
by mikebenfield on Saturday September 09, 2017 @12:19PM
(#15207731)
Yes, I've always understood this to be the correct terminology, but unfortunately in informal discussion among non-academically inclined software people, people use the terms wrong more often than they use them right. You get lots of people saying C is strongly typed (it certainly is not) and something like Scheme is weakly typed (it certainly is not).
Re:JavaScript: The Curious Case of null >= 0
by zzalpha on Saturday September 09, 2017 @12:37PM
(#15207804)
If you're really want a fun time, try having a conversation about "duck typing" some time... it was around the time that term became a thing that I realized no one seems to agree on what all these terms mean.
Re:JavaScript: The Curious Case of null >= 0
by marcosdumay on Saturday September 09, 2017 @02:50PM
(#15208559)
Using "strict" vs. "non-strict" and "static" vs. "dynamic" will increase a lot the odds of people understanding.
The difference is python is strict about its types and doesn't do automatic coercion. So at least you get type errors at runtime and not magic implicit behaviour.
That said, even Perl did this better (less magic and surprises)... JavaScript is like a language intentionally designed to surprise the developer. Half the time I feel like it's a practical joke that someone accidentally took seriously.