4 ms·
Static typing
by eyelidlessness 7y ago
Static typing
- eyelidlessness 7y agoLove to get downvoted for something factually true that answers the explicit question above it
- hawski 7y agoI did not downvote you, but how is static typing in any sense revolutionary? It is certainly not a new concept and you know it, but your answer does not elaborate any of this at all. It may be factual, but it is factually useless.
- lmilcin 7y agoYou see, people tend to get hooked up on features of the language they are using especially if they have very limited choice of languages they know. They will vehemently defend their point of view fortified by whole range of cognitive biases. Their combined effect like more alcohol to the drunk to make him feel strong and able to overcome bouncers. I personally believe no person who can't program in both assembly and lisp should call themselves real/full programmers because they have not been exposed to full range of concepts. You have to, of course, start somewhere. But until you have experienced full variety of possible language features you are not really qualified to discuss any them with any authority. See also Blub Paradox (http://www.paulgraham.com/avg.html http://www.paulgraham.com/avg.html) by the very author of this site.
- eyelidlessness 7y agoI have plenty of experience in Clojure (even some of it still in production!), as well as "C family" languages, both statically and dynamically typed. I didn't answer the question out of ignorance. The thing that immediately jumped out at me that "can't be done as easily with Clojure" is static typing.
- eyelidlessness 7y agoThe question was "Challenge me, give one example that can't be done as easily with Clojure." The answer is "static typing". I never claimed it's revolutionary.
- lmilcin 7y agoStatic typing is a property of the programming language, not something you "do". Do you mean your clients want static type something? Static typing is a preference of the developer or development organization on whether they want speed or they need a bit of help to understand what they have before their eyes. It lets the compiler call you out on some of your transgressions at the cost of quirky type system and possibly having to need a bunch more code where a very simple solution would present itself when type system does not get in the way. Static typing is neither bad or good. It "depends".
- eyelidlessness 7y agoI didn't make any value claims about static typing (though I do prefer it), I just answered the question of what "can't be done as easily with Clojure". You cannot easily statically type Clojure, and as a consequence cannot easily do any of the things that static typing enables in a language, regardless of how much you value those things.
- hota_mazi 7y agoIt doesn't really depend, static typing is objectively superior to dynamic typing, starting with the simple observation that all the mainstream dynamically typed languages are busy adding/retrofitting static typing.