5 ms·
The one of the biggest ideas behind a classic Lisp is now called Exploratory Programming - a natural way of evolving your program very quickly. When a programm
by dschiptsov 14y ago
The one of the biggest ideas behind a classic Lisp is now called Exploratory Programming - a natural way of evolving your program very quickly.
When a programmer is forced to think about a type before he already decided what it could be is a limiting factor. All scripting languages are based on this idea.
And, of course, having lists of elements of just the same type and different sets of functions for different types of, say, lists is an ugly thing.
The current mass-hysteria about necessity of static typing is due some sort of Bandwagon effect.
I think it is much better to learn the elegant approach of authors of Scheme and other Lisps to hide necessary hardware types inside a runtime and to allow programmers and themselves to think in terms of a problem domain.
So, statically typed Lisp is something like four-wheel bicycle. It is very "safe" and "stable" but for some reasons no one wants it.
- pwpwp 14y ago"And, of course, having lists of elements of just the same type and different sets of functions for different types of, say, lists is an ugly thing." Both of these are not the case with row polymorphism.
- sbt 14y agoI agree that it's important to retain the dynamism of LISP, but if types could be made optional, it could be useful. In my view, the expressive power of LISP is the same thing that hinders it for use in teams (unless the team is small and super qualified) and consequently what has prevented its widespread adoption. I think this is a wonderful initiative. I originally tried to do this a few years ago, but gave up after having considered the implementation too involved (I was using LLVM at the time and was effectively writing a compiler). I still think an optionally typed LISP compiler would be a great idea if somebody is willing to do it. EDIT: grammar.
- yvdriess 14y agoCL has optional types and quite an interesting type system. Check out Qi if you want a Lisp designed to have a rich type system.
- markokocic 14y agoShen is the new version of Qi. Qi is not developed anymore.
- pi18n 14y agoI don't think there's a mass hysteria, is there? Certainly a few arrogant Haskellers, but I don't see an epidemic. Static typing eliminates an entire class of bugs. It's not like any of us need it, it's just a powerful tool. It might be a nice option in a Lisp if it could be done elegantly.
- dschiptsov 14y agoThose bugs are not a big deal. For a quick checking for correctness there is REPL, and because we're doing mostly functional programming (self-discipline) this is good-enough. For some protection from being called with wrong arguments there are assertions. Those who believe that a sophisticated type-system is a protection from idiots, rather than unnecessary burden, seems like come from a corporate Java world, where they believe that something decent could be created by a crowd of mediocre coders piling up "safe" or even "protected" crap. And of course, Unit tests and CI are our friends.)
- pi18n 14y agoI just know I've made some mistakes in the past that would have been caught by a type checker, and I'll probably make similar mistakes in the future. I like trying stuff in the REPL, but when an idea has solidified, I'd like to have it fully type check (along with using unit tests and CI). I guess it just doesn't seem like a burden to me; most of it is just preventing passing a variable as something it is not or double-checking that you've handled all the cases for Maybes and Eithers. It's all stuff I'd like to be doing anyway.
- lispm 14y agoIts fate: just another Lisp-derived language no one uses and which has no software to run on.