Subj : JS like LISP? When to use eval(src)? To : netscape.public.mozilla.jseng From : Mark Turansky Date : Wed Jun 08 2005 01:39 pm Forgive me if this is off topic for this newsgroup. I want to talk about javascript itself, not so much the engines implementing the language. Please let me know if there is another news group I should be posting this question to. The more I read about high-level languages, the more I realize that javascript got so many things right. I've been writing some programs in Python and find it and JS to be remarkably similar in concept, if not syntax. I read online that JS is so high-level that it's much like Lisp. Paul Graham's name keeps coming up everywhere, and so I read about Lisp and high-level languages. PG writes about Lisp macros, about programs writing programs to be evaluated at runtime. And this brings me to my question: When is eval(src) a better way of solving a problem than using elegant datastructures, closures, first class functions, and any mix of advanced javascript techniques? Paul writes that it's bad form to use macros when there are alternatives, because macros are complex, but they're still used all the time in Lisp. When would I want to have js functions write functions that can be eval'd and executed at runtime? I'm missing this connection. Perhaps then I'll understand more what Graham is writing about. fervent Rhino fan but stuck thinking in java, Mark .