News for hackers. Stuff that matters.
Re:Clojure.spec – Rationale and Overview by pklausler on Monday May 23, 2016 @01:49PM (#11755505)
If static type systems cannot do everything, it does not make sense to me to conclude that they shouldn't then be used for anything. Type systems aren't part of "regular testing", they're part of compile-time error checking.
Re:Clojure.spec – Rationale and Overview by ComNik on Monday May 23, 2016 @01:58PM (#11755578)
That was not the intension behind my comment at all. I rely on type systems a lot, myself.

I was trying to note that Clojure, as a dynamic language, is making a (to my eyes) very interesting choice, of doubling down on these dynamic methods of verification. For some uses, I can see this as the better choice, for others it isn't and won't be.

Re:Clojure.spec – Rationale and Overview by pklausler on Monday May 23, 2016 @02:05PM (#11755621)
Sure, and I can't fault anyone for wanting less dangerous dynamic languages. But to me it's kind of like wanting less dangerous cigarettes.
Re:Clojure.spec – Rationale and Overview by KingMob on Monday May 23, 2016 @02:45PM (#11755902)
As I commented elsewhere, Clojure very deliberately adopts the stance that type systems like Haskell's are valuable but heavyweight, and chose development speed and concision over types.

In my own work, I chose Clojure because it mirrored my experiences: that type systems weren't worth the trade-offs for me and my field.

Would I prefer stronger typing in different domains (longer project times available, greater consequences of failure like medical devices, etc.)? Sure, and I have in the past. But it's not the case that dynamic languages are always the incorrect choice, like smoking cigarettes.

Re:Clojure.spec – Rationale and Overview by stuarthalloway on Monday May 23, 2016 @03:35PM (#11756271)
Or like leaving the house without a suit of plate mail.
Re:Clojure.spec – Rationale and Overview by pron on Monday May 23, 2016 @02:36PM (#11755848)
When you prove that a language like Clojure (untyped, but with dispatch that is no more dynamic than that of many modern typed languages) combined with a construct like specs is significantly less safe than any typed language, then you can make that statement. It's not like untyped and typed are two binary categories; otherwise, I could say that wanting less dangerous typed languages as opposed to formal tools are just like wanting less dangerous cigarettes. These ideas exist on a spectrum.