3 ms·
> Software is broken because its not worth people’s while to write non-broken software This is the premise of a large part of the article. And it is wrong. At
by wereHamster 10y ago
> Software is broken because its not worth people’s while to write non-broken software
This is the premise of a large part of the article. And it is wrong. At the very least a citation is needed. And even if there is a scientific source, I disagree with it. I'd argue that many people do want to write non-broken software, but they do not know how to efficiently use static type system, or they don't know how effective it is. If all you know is Java or C then of course you're going to doubt if a type system is worth at all.
> As static typing becomes more elaborate the scope of the bugs it can prevent becomes wider, but it usually comes with an additional cost: Build times.
I disagree. When you are working with Haskell, use ghcid and you'll have near instant recompile times. I made a proof-of-concept of a web frontend in Haskell, and it reloads with sub-second delay. That is comparable to a JavaScript project which uses webpack and babel.
- yogthos 10y agoYou can disagree what you like, but the fact that a lot of software out there has bugs and these bugs don't stop it from being successful clearly supports the point the article makes. If catching the types of bugs that static typing prevents resulted in reduced costs of software development, you'd see static typing out-compete dynamic typing. It's really that simple.
- tome 10y ago> If catching the types of bugs that static typing prevents resulted in reduced costs of software development, you'd see static typing out-compete dynamic typing Apart from network effects, inertia, lack of education and awareness, and all the other confounding factors.
- yogthos 10y agoThe complete and utter lack of empirical evidence with regards to purported benefits of static typing is the real elephant in the room here I think. Considering how long both disciplines have been around, you'd think we'd see some clear benefits by now. Yet, here we are swapping anecdotal evidence.
- wereHamster 10y agoThe disciplines may have been around for long. But the industry has poured billions into educating people (students in universities) on C, Java, C++, C#. Comparatively little has been invested into educating people how to use and work with good type systems. You're comparing apples and oranges. You can't ask the general developer population how they feel about static vs dynamic typing. The result will be biased towards dynamic because that's the only thing most developers know.
- yogthos 10y agoConversely, a lot of people have have used dynamic typing in languages like JavaScript and Ruby. Their OO nature encourages creation of many types, while pervasive mutability removes any possibility to do local reasoning about the code. The situation is completely different in functional dynamic languages backed by immutable data structures.
- tome 10y agoIs there much empirical evidence for anything interesting in software development?
- yogthos 10y agoThere are lots of studies on the subject, none of them show anything even remotely conclusive. Here are a few examples: https://courses.cs.washington.edu/courses/cse590n/10au/hanenberg-oopsla2010.pdf https://courses.cs.washington.edu/courses/cse590n/10au/hanen... http://macbeth.cs.ucdavis.edu/lang_study.pdf http://macbeth.cs.ucdavis.edu/lang_study.pdf http://eprints.bournemouth.ac.uk/10668/1/tratt__dynamically_typed_languages.pdf http://eprints.bournemouth.ac.uk/10668/1/tratt__dynamically_...
- notacoward 10y ago> even if there is a scientific source, I disagree with it Well, that pretty much signals how people should interpret the rest of what you say.
- echlebek 10y agoThere are scientific sources that claim all sorts of wrong things. Not trusting things blindly is called critical thinking.
- notacoward 10y agoScience can be wrong, but announcing your disagreement before you've ever seen the evidence is the absolute opposite of critical thinking. It's not skepticism but dogmatism.