News for hackers. Stuff that matters.
Re:It's probably time to stop recommending Clean Code (2020) by randomswede on Wednesday May 26, 2021 @04:21AM (#27287802)
I don't really care about the static/dynamic typing spectrum, I care about the strong/weak typing spectrum.

At any point, will the code interpret a data item according to the type it was created with?

A prime example of "weakly typed" is when you can add "12" and 34 to get either "1234" or 46.

Re:It's probably time to stop recommending Clean Code (2020) by throwaway2037 on Thursday May 27, 2021 @09:55AM (#27303152)
This is an interesting distinction. I confess that I frequently interchange the pairs.
Re:It's probably time to stop recommending Clean Code (2020) by randomswede on Friday May 28, 2021 @03:41AM (#27312726)
I mean, to some respect, "dynamic typing" is "type the data" and "static typing" is "type the variable".

In both cases, there's the possibility for doing type propagation. But, if you somehow manage to pass in two floats to an addition that a C compiler thinks is an integer addition, you WILL have a bad day. Whereas in Common Lisp, the actual passed-in values are typed (for floats, usually boxed, for integers, if they're fixnums, usually tagged and having a few bits less than you would expect).