[Bese-devel] Re: Reader macro

Levente Mészáros levente.meszaros at gmail.com
Thu Mar 23 21:52:45 UTC 2006


I think >>>> is not that bad, actually we can live with )))) pretty well.
Also emacs can be easily configured to know about <>.

I added enable-xml-reader-syntax and friends. Also modified the reader macro
to use simply < without breaking the < function I hope (it did work). It
just looks ahead one character more and if it is a space, then it returns
the < symbol otherwise reads an XML element. I know it kills symbols
starting with < character, but I don't know how usual it is? Anyway one
would not enable this syntax but only in certain places, so I guess it's not
a big issue. Remember I was starting this whole stuff to help prototyping,
because predefining the XML elements may give you nice things such as
showing the possible attributes, child elements, etc.

Do you know any other problem that this solution may introduce?

So an example would looks like this:

(use-package :yaclml)

(use-package :iterate)

(enable-xml-reader-syntax)

(defun alma ()
  <alma :a 1 :b "2"
     (iter (for a from 0 to 3)
           <korte :a a>)>)

(disable-xml-reader-syntax)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/bese-devel/attachments/20060323/3801feb5/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xml-reader.patch
Type: text/x-patch
Size: 11424 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/bese-devel/attachments/20060323/3801feb5/attachment.bin>


More information about the bese-devel mailing list