Alan Manuel Gloria wrote:
On Nov 20, 2007 3:19 AM, Neil Toronto <[EMAIL PROTECTED]> wrote:
Alan Manuel Gloria wrote:
Hmm.  "decorations" being...?  From my point of view s-exprs hardly
have decorations at all - list limits are all started and ended by ( )
pairs.
Sorry about that. "Decorations" == delimiting parsing rules using (), []
and {} enclosures.
So what you mean is, decorations would be used only to say "this is s-expr"?

Inside a sweet-expr, yes. IMO it's the only escape people using sweet-exprs would really want or need.

Finally - conventional wisdom claims that LISP's most important power,
macros, is possible only because of the sheer number of parens in the
s-expr syntax (I would contend this, though).  So, just in case macros
really, really need s-expr - better keep it in, since we don't want to
accidentally cut LISP's power.
I've read this in a few places, but never seen any concrete reason that
macros can't work with m-exprs. It usually comes down to "if you
understand macros, you'll already know why" - a type of answer I find
both maddening and unfortunately common. So... could you very sweetly
attempt to explain to a non-Lisper exactly why this might be? :)

I'm not attempting to argue the banishment of s-exprs, by the way. I
just want to understand why people think what they do.
Mind you, I also contend that s-exprs are not *completely* necessary.
However I must also add that in the office we use a proprietary
lisplike called Skill, which supports a subset of m-expr and the full
s-expr (the limitation of the m-expr is that you can't use something
like y = (x) to mean the value of x, as would be valid in C for
example).  I mostly used the m-expr syntax at first.  After I figured
out macros, however, I found myself switching over to s-exprs!

*** BIG FAT SNIP ***

That was totally awesome. Ha ha! I actually understand what macros are now! In fact, I want them in Python...

I can see how that might be a tad difficult, though. (I may try it anyway! I've been getting into bytecode and runtime hacking lately.) It seems like, to do them properly, you'd need a language with very little syntax. Lists of lists, really. Sounds familiar. Hmm...

I can see how they'd be difficult to do properly with a conventional procedural language. Would they be hard to do with sweet-exprs?

Thanks again,
Neil

Reply via email to