A philosophical difference between Haskell and Lisp (2015)
1–10 of 181 posts
Re: A philosophical difference between Haskell and Lisp (2015)
#2It feels so much easier to both understand and modify the evolved version of the code.
Re: A philosophical difference between Haskell and Lisp (2015)
#3Re: A philosophical difference between Haskell and Lisp (2015)
#4Any particular reason why Lisp doesn't also tend to compose with smaller functions? Did it just happen to evolve that way? Is it easier to get the types of the smaller functions right when you have a compiler to help you like you do in Haskell?
Re: A philosophical difference between Haskell and Lisp (2015)
#5Re: A philosophical difference between Haskell and Lisp (2015)
#6Any particular reason why Lisp doesn't also tend to compose with smaller functions? Did it just happen to evolve that way? Is it easier to get the types of the smaller functions right when you have a compiler to help you like you do in Haskell?
Re: A philosophical difference between Haskell and Lisp (2015)
#7 take 5 . filter (not . p) . drop 3
becomes (->> s (drop 3) (filter (complement p)) (take 5)) ; for some sequence s
I think it is also true of Clojure that it strives to have many small functions with a high degree of composability.Re: A philosophical difference between Haskell and Lisp (2015)
#8Any particular reason why Lisp doesn't also tend to compose with smaller functions? Did it just happen to evolve that way? Is it easier to get the types of the smaller functions right when you have a compiler to help you like you do in Haskell?
For one Lisp is not lazy like Haskell.
Re: A philosophical difference between Haskell and Lisp (2015)
#9Any particular reason why Lisp doesn't also tend to compose with smaller functions? Did it just happen to evolve that way? Is it easier to get the types of the smaller functions right when you have a compiler to help you like you do in Haskell?
For one Lisp is not lazy like Haskell.
Re: A philosophical difference between Haskell and Lisp (2015)
#10Any particular reason why Lisp doesn't also tend to compose with smaller functions? Did it just happen to evolve that way? Is it easier to get the types of the smaller functions right when you have a compiler to help you like you do in Haskell?
For one Lisp is not lazy like Haskell.
> Like pipes in UNIX, the functions are clever enough to be performant when composed together–we don’t traverse the whole list and generate a new list each time, each item is generated on demand. In fact, due to stream fusion, the code will be compiled into one fast loop.
I imagine it is hard to do the same optimization in a non-lazy language.