Live data from Hacker News

Ask HN: Could a Lisp be Blub?

news.ycombinator.com

21–30 of 30 posts

Re: Ask HN: Could a Lisp be Blub?

#21
post #9

I've been thinking about this again because of the recent re-post of one of pg's Lisp essays (one of the two that originally provoked me into learning Lisp). The essay makes an argument that the answer to your question is roughly "No". The argument goes like this: no language that lacks Lisp-style macros can be as powerful as Lisp. Macros aren't possible without code=data, and code=data comes from sexps. But any lang…

Does'nt smalltalk have code=data behavior without s-expressions. I'm not an expert, but I thought that was the reason why Smalltalk has the IDE that everyone raves about along with image persistence

Or can Smalltalk be modelled as an s-exp based language?

http://en.wikipedia.org/wiki/Smalltalk#Image-based_persisten...

Re: Ask HN: Could a Lisp be Blub?

#22
post #11
post #8

There are languages that have useful features that lisp lacks. For example, Haskell has lazy evaluation and automatic compiler generated program correctness proofs (a decent type system). Then there are languages that try to be even more powerful than Haskell, for example Epigram, which has dependent types. Lazy evaluation is probably the language feature that is most mainstream that lisp lacks. For those not familia…

Clojure has lazy versions of most of the collections API (or possibly it defaults to laziness now, it has been a little while since I last played with it). They're implemented using macros of course, but they get you surprisingly far. I have a bit of a Haskell background, and was doing the Project Euler problems in Clojure frequently using the lazy stream processing idiom you just described.

I think you need laziness to be a little more prevalent than that before it makes a difference. Haskell's super-concise Fibonacci sequence illustrates that:

  let fib = 1 : 1 : zipWith (+) fib (tail fib)

Re: Ask HN: Could a Lisp be Blub?

#23
post #17

Clojure risks heading that way; for all its beauty, clojure is losing its culture fast! You can already see Design Patterns being shoehorned on top of it, Java programmers will embrace it and extend it in earnest. The sort of applications being written with the language are a huge factor in making it attractive to other users. All the truly beautiful languages had operating systems or huge desktop applications writte…

for all its beauty, clojure is losing its culture fast! You can already see Design Patterns being shoehorned on top of it, Java programmers will embrace it and extend it in earnest. Can you give an example of this?

This was posted here yesterday:

http://www.brool.com/index.php/snippet-automatic-proxy-creat...

A neat hack to get something working quickly, but very unlispy. I can't even make sense of the AUTO-PROXY macro. A syntax barf mixed with a gratuitous breaking of LET. Also note that Rich Hickey decided to use the proxy design pattern to interop with Java, instead of doing all business with Java through FFIs; in a sense, Clojure's type system is embedded in Java.

http://clojure.org/java_interop#toc25

This is a minor aesthetic nitpick from a concerned Lisper, mostly for selfish reasons. My thinking goes: "Today I have Common Lisp for my projects and I am happy with it. But tomorrow if I need Clojure, I hope to find it in a sane, Lispy world. I don't want to learn Java so please don't make me" ;-)

For a far more alarmist polemic, albeit a satirical one, see this:

http://jng.imagine27.com/articles/2009-08-19-011225_clojure_...

Re: Ask HN: Could a Lisp be Blub?

#24
post #9

I've been thinking about this again because of the recent re-post of one of pg's Lisp essays (one of the two that originally provoked me into learning Lisp). The essay makes an argument that the answer to your question is roughly "No". The argument goes like this: no language that lacks Lisp-style macros can be as powerful as Lisp. Macros aren't possible without code=data, and code=data comes from sexps. But any lang…

Does'nt smalltalk have code=data behavior without s-expressions. I'm not an expert, but I thought that was the reason why Smalltalk has the IDE that everyone raves about along with image persistence Or can Smalltalk be modelled as an s-exp based language? http://en.wikipedia.org/wiki/Smalltalk#Image-based_persisten...

Smalltalk would be trivial to model with s-exps: (object message args)

Re: Ask HN: Could a Lisp be Blub?

#25
post #9

I've been thinking about this again because of the recent re-post of one of pg's Lisp essays (one of the two that originally provoked me into learning Lisp). The essay makes an argument that the answer to your question is roughly "No". The argument goes like this: no language that lacks Lisp-style macros can be as powerful as Lisp. Macros aren't possible without code=data, and code=data comes from sexps. But any lang…

[deleted]

Re: Ask HN: Could a Lisp be Blub?

#26
post #11

Earlier quoted context omitted.

Clojure has lazy versions of most of the collections API (or possibly it defaults to laziness now, it has been a little while since I last played with it). They're implemented using macros of course, but they get you surprisingly far. I have a bit of a Haskell background, and was doing the Project Euler problems in Clojure frequently using the lazy stream processing idiom you just described.

I think you need laziness to be a little more prevalent than that before it makes a difference. Haskell's super-concise Fibonacci sequence illustrates that: let fib = 1 : 1 : zipWith (+) fib (tail fib)

You may need to reevaluate what's possible in Clojure.

    (def fib (lazy-cat [1 1] (map + fib (rest fib))))

Re: Ask HN: Could a Lisp be Blub?

#27
post #23

Earlier quoted context omitted.

for all its beauty, clojure is losing its culture fast! You can already see Design Patterns being shoehorned on top of it, Java programmers will embrace it and extend it in earnest. Can you give an example of this?

This was posted here yesterday: http://www.brool.com/index.php/snippet-automatic-proxy-creat... A neat hack to get something working quickly, but very unlispy. I can't even make sense of the AUTO-PROXY macro. A syntax barf mixed with a gratuitous breaking of LET. Also note that Rich Hickey decided to use the proxy design pattern to interop with Java, instead of doing all business with Java through FFIs; in a sense, C…

I don't think you understand Clojure as well as you think you do. Java libraries often expect interfaces to be passed in as a parameter, and Clojure proxies are just a way of generating anonymous interfaces. This is not the de facto method for Java interop, it's just a simple means of creating the IFactoryFactory behemoths that Java tends to expect. It's practical, clean, and useful. I honestly don't understand what the nature of your objection is.

Re: Ask HN: Could a Lisp be Blub?

#28
post #9

I've been thinking about this again because of the recent re-post of one of pg's Lisp essays (one of the two that originally provoked me into learning Lisp). The essay makes an argument that the answer to your question is roughly "No". The argument goes like this: no language that lacks Lisp-style macros can be as powerful as Lisp. Macros aren't possible without code=data, and code=data comes from sexps. But any lang…

Does'nt smalltalk have code=data behavior without s-expressions. I'm not an expert, but I thought that was the reason why Smalltalk has the IDE that everyone raves about along with image persistence Or can Smalltalk be modelled as an s-exp based language? http://en.wikipedia.org/wiki/Smalltalk#Image-based_persisten...

I don't think Smalltalk has code=data. It has object-based metaprogramming, i.e. the code that you write turns into objects that you can write other code to manipulate at runtime. But perhaps that's a distinction without a difference? I don't have enough experience with Smalltalk to say.

I was expecting someone to suggest that stack-based languages are fundamentally different from tree-based ones.

Re: Ask HN: Could a Lisp be Blub?

#29
post #19
post #15

Earlier quoted context omitted.

This is a significant psychological point that comes up in a lot of different contexts (sales contexts, mostly). But in the programming language context, I think it's a symptom of the dysfunction that the vast majority of discussions are at a superficial level (code snippets and theoretical features) and have little to do with building real systems over time.

That's true, although before we get too smug about those "out of touch with the realities of building software systems" academics, we should remember that often those seemingly absurd and fanciful little corners turn out to be serious game changers. Lisp itself, for instance.

I wasn't thinking of academics who are making new things so much as bloggers who aren't.

Re: Ask HN: Could a Lisp be Blub?

#30

Earlier quoted context omitted.

I think you need laziness to be a little more prevalent than that before it makes a difference. Haskell's super-concise Fibonacci sequence illustrates that: let fib = 1 : 1 : zipWith (+) fib (tail fib)

You may need to reevaluate what's possible in Clojure. (def fib (lazy-cat [1 1] (map + fib (rest fib))))

...Man, Clojure seems to have just about everything from every language ever.
Post reply on HN