[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Opaque syntax objects

This page is part of the web mail archives of SRFI 72 from before July 7th, 2015. The new archives for SRFI 72 contain all messages, not just those from before July 7th, 2015.

Andre van Tonder <andre@xxxxxxxxxxxxxxxxxxx> writes:

>  Hi Mike, thanks for the comments.
>  > I'd like to suggest that compound expressions be represented by an
>  > opaque type rather than by pairs.  This would ensure a modicum of
>  > abstraction, and would *really* make comprehensive the ability of all
>  > syntax objects to carry location information.  
>  The current representation does allow source tracking for compound syntax
>  objects.  One would make the reader put the location of each node (pair or 
>  vector) in a hash table.  Each evaluation of a SYNTAX or QUASISYNTAX form
>  can do likewise.  Since pairs keep their identity during expansion, 
>  location information for every node (and identifier leaf) can always be 
>  looked up in the hash table at any stage of the expansion.  

[Sorry for replying out of order.]

You mean in a global hash table?  That's a hack around the lack of a
field in the syntax objects.  To make it work efficiently, you'd have
to bring weakness in---a lot of machinery to duplicate functionality
that would trivially work if syntax objects were abstract and thus

Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla