Hacker News new | ask | show | jobs
by JAlexoid 2157 days ago
Static vs dynamic is not for type checking, it's about conversion.

As in:

Static typing - 1 == "1" is false (Python style, integer isn't converted to string for comparison)

Dynamic typing - 1 == "1" is true (PHP style, integer or string may be converted)

1 comments

Where are you getting your definitions from? What you posted is what I understand to be weak vs strong.
Barbara Liskov defines strong typing as a compiler feature that prevents wrong type usage.

Liskov, B; Zilles, S (1974). "Programming with abstract data types".

http://web.cs.iastate.edu/~hridesh/teaching/362/07/01/papers...