Re: Very poor Lisp performance



Jon Harrop <usenet@xxxxxxxxxxxxxx> writes:

> Brian Downing wrote:
>> In article <m2iry1q2j6.fsf@xxxxxxxxxxxxxxx>,
>>> I'm not sure it's been established that Mathematica has macros that
>>> are similar in power to Lisp's macros. If you want to see what an
>>> honest attempt to combine infix operators with Lisp-style macros looks
>>> like you should check out Dylan or (more recently) the Java Syntactic
>>> Extender[1]. However to understand the comparison you'll, of course,
>>> have to learn something about Common Lisp macros. And if you really
>>> want to go to town, look into Scheme's various macro systems which
>>> offer a slightly different take on the problem.
>
> Can you give me a reference explaining the difference between Lisp and
> Scheme here? I didn't realise this existed...

Sure. Read about Common Lisp macros. Then read about Scheme
macros. Then note that they are quite different. For extra credit,
note that they also share a deep underlying similarity. I don't mean
to be flip but you're going to have to learn about some of this stuff
yourself to be able to understand it.

>> There's certainly no concept of "macroexpansion time" and "run time" like
>> there is in CL,
>
> So you cannot use macros to generate code to generate macros to
> generate code in Lisp?

How on earth did you get from what Brian said to that.

>> and there's no simple QUOTE operator
>
> What does the quote operator do?

Hmmm. Do you know about the Hyperspec? The answer to all your
questions (and more) about Common Lisp are contained therein. Or if
you want to learn about Common Lisp in a more expository form form, I
can't help but recommend the book listed in my .sig. What kind of
comparative linguist are you if can't even go to the effort to look up
a few words in the "dictionary" to see what they mean.

-Peter

--
Peter Seibel * peter@xxxxxxxxxxxxxxx
Gigamonkeys Consulting * http://www.gigamonkeys.com/
Practical Common Lisp * http://www.gigamonkeys.com/book/
.



Relevant Pages

  • Re: ILC2005: McCarthy denounces Common Lisp, "Lisp", XML, and Rahul
    ... The examples I'm thinking of were DW to CLIM, ... > code) to Common Lisp in about 3 months. ... > function call parts, not the macros. ... > if it's part of the design strategy. ...
    (comp.lang.lisp)
  • Re: ILC2005: McCarthy denounces Common Lisp, "Lisp", XML, and Rahul
    ... code) to Common Lisp in about 3 months. ... few months at symbolics, I managed to use macrology to hide ... And at every step where it was tried, macrology hid the porting issues ... function call parts, not the macros. ...
    (comp.lang.lisp)
  • Re: Wondering if you guys would like to comment on this
    ... > in Java 1.5, as part of JSR-201. ... > annoyance that Common Lisp programmers can resolve for themselves ... > within five minutes plagues Java programmers for years. ... Macros are generally meant to make your program clearer. ...
    (comp.lang.lisp)
  • Re: LET improved, time wasted
    ... the syntax to his needs he is told that reader macros are ugly. ... Common Lisp provides you all the necessary tools to shoot yourself into your ... live with the basics of the language and try to write some more useful code. ... That you can change Common Lisp does NOT mean you should start with it. ...
    (comp.lang.lisp)
  • Re: Sacla loop: a new loop implementation
    ... >> use it to do type inference before macro expansion in order to supply ... > portably in common lisp, because the facilities just aren't there. ... useful type information at compile time, then you are working with a ... if you say that you are willing to accept that your macros ...
    (comp.lang.lisp)