by lucasyvas · 3y ago · 0 comments
Beyond initial prototyping (which I doubt will actually ever be thrown away), what logical defence is there for catching obvious bugs in production when they could have been caught at compile time instead? Dynamic typing straight up hides unavoidable realities of programming - you have to know what thing you have to cover all the cases. I don't just mean cases that "make the compiler happy". These cases are most often not mutually exclusive from the business domain - cases related to core business logic are missed, which produce more bugs which makes your software objectively worse for both the end user and whatever business the software is sold by.
The complaints I hear are that it's too cumbersome or annoying to satisfy these cases - my retort is to stop complaining because most of us are paid to write working software, not software we can pass off as being complete when it's not.
And don't suggest that tests cover this - they absolutely don't, and testing such things is a total waste of time. The train has left the station, best get aboard.
You can either hire 10 dynamic typing software developers or 30 static typing software developers. Businesses which choose to hire 30 static typing software developers will fall to the companies which hired 10 dynamic typing software developers. It's pure economics.
Static typing fills your codebase with bugs. Whilst an inexperienced software developer might not understand why static typing increases rather than decreases bugs, you can see the increase in bugs in research papers on the topic. As plan as day.
(Hint: You have made your code more complex by using static typing and more complex code contains more bugs.)
Even the article we're discussing points out there are cases for no- or dynamic typing.
All I'm pointing out, is that people who oppose strong static typing on the base of "but we don't want it everywhere" are drawing the wrong conclusions, because, indeed, we don't want it everywhere. We (I) do, however, need and want it in far more places than it's used today.
https://news.ycombinator.com/item?id=32806179
It's certainly not proven a static language can't cover this use case but in other areas static languages really have proven their merit.