Weak Types Lie

Someone (many people) discovered that Weak Types Lie.

I mean, no kidding. It is obvious. Without structure, a house is weak and will fall apart. Without types, there are no truths.

There is unit testing, but some unit testing reinvents some of strong typing. One could write unit tests for other things, spending their valuable time writing tests for checks that can't be automated.

This caused people to reinvent strong typing and put it into the latest C language after they figured out the lies weren't helping.

Example C languages that are sprouting about now with stronger or stricter typing abilities (and/or clearer declaration syntax) are LimboLanguage, SawzallLanguage, JavaLanguage, CycloneLanguage.


Quote from famous Java/Sun architect James Gosling:

"Unlike C, where you can basically lie about anything. In fact, a lot of standard practice in C is all about lying about the identity of things. But once you've got an environment where you can't lie—you can't wiggle around things—then you can start building mechanisms that find what things can do, and you can then observe things and have some faith that what you're observing is true. You're not seeing somebody who is tricking you by going around the edges of an interface. Then a lot of the stuff layers up from there, and just falls into place, but the higher-level stuff is pointless unless you've got the lower-level integrity."

http://www.acmqueue.org/modules.php?name=Content&pa=showpage&pid=173&page=3

http://z505.com/cgi-bin/qkcont/qkcont.cgi?p=Java-Founder-Comments-On-Pascal

If weak types lie, then ignore what they say and go "type free". I was never a fan of weak typing, and feel one should either have strong typing or no typing. In-betweening leaves the author in a kind of mental limbo-land. (TypelessVsDynamic)


See also: LooseTypesSuck
CategoryLanguageTyping, CategoryTypingDebate

EditText of this page (last edited March 27, 2008) or FindPage with title or text search