1. 4

  2. 20

    I always thought this was by far the worst argument that proponents of static typing were giving, by telling fans of dynamic typing they were flat out stupid and inferior. This is insulting and will not bring your point across. This venn diagram that is always quoted is misleading at best, consider how many Java/C++/C/C# programmers are out there, how many of those know type theory? I use Haskell and OCaml and even I don’t have much of a clue.

    The argument should be how static typing can help people and maybe, just maybe, looking at the dynamic languages camp can help to see what is useful and what can be copied.

    1. 9

      Indeed. This is the sort of post that makes people who already agree with the author feel good, and people who don’t feel uncomfortable. It doesn’t do anything to change minds or improve things. If anything, it makes it worse by arrogantly deriding anyone who disagrees as implicitly wrong and stupid.

      1. 3

        In the author’s defense he’s not claiming the opponents are dumb, but rather that they are uninformed. There’s a big difference. People familiar with type theory although anecdotal to my experience, do tend to prefer static typing. Leonidas is very correct in saying that people who do prefer statically typed languages are often unaware of type theory, but that’s not really a counterpoint. The author is only making the argument that informed developers tend to choose static typing, not that developers who use static types are informed.

        1. 2

          The effect is the same though. Either way, it’s “if you only learned X, you would agree with me.” Which is not a good way of getting people to change their mind.

          1. 2

            You can’t reason people out of positions they didn’t reason themselves into.

          2. 2

            I certainly prefer static typing for most projects (and have championed it at work), but I don’t agree with the author at all. There is a giant chasm between preferring an expressive type system and this:

            The new generation of statically typed languages with proper type inference is simply objectively better

            I am a user of dynamic languages, and I have tons of experience with type systems. Therefore, according to the author, I am an anti-intellectual! Yippee.

      2. 6

        Wow. What a stunningly bad argument. He’s essentially saying, “People who disagree with me and like dynamic typing are either ignorant, stupid, or trolling.” It shouldn’t come as a surprise to anybody that he’s had a hard time advocating static typing with an argument like that.

        The silliest thing about this argument is that there’s arguably more working software written in languages like PHP, Python, and Ruby, than there are in languages like Scala, Haskell, and ML.

        I personally find I’m more efficient using dynamically typed languages. With proper variable naming and decent software design I very rarely run into issues that’d be solved by a strict typing system. If you find yourself thinking, “I’m not sure what’s in this variable,” then you’re doing something wrong. Further, in languages like Haskell, I waste time jumping through hoops to “solve” issues that are only issues because the type system.

        That said, my preferences is for the Common Lisp model, where typing defaults to dynamic, but optional types can specified for optimization and documentation purposes.

        But I guess that makes me an ignorant troll…

        1. 2

          I find the article linked in the top of this post to convey the arguments that are missing. This post is a statistic.