[R6RS] How to make -> a valid identifier

Marc Feeley feeley
Wed Jun 8 12:36:49 EDT 2005


On 8-Jun-05, at 12:22 PM, Michael Sperber wrote:

>
> Marc Feeley <feeley at iro.umontreal.ca> writes:
>
>
>> Gambit does as well (i.e. symbol = not a number and not a keyword).
>> The other problem with defining it this way in the R6RS is that
>> future revisions of the standard may have important backward
>> compatibility problems if the syntax of numbers is changed.  So
>> although "symbol = not a number and not a keyword" is fine for an
>> implementation of Scheme, it is not OK for the specification of  
>> Scheme.
>>
>
> You're right.  Given that I screwed up going the fancy route, how
> about
>
> <peculiar identifier> --> + | - | ... | -> <subsequent>*
>
> ?

Well, that would be acceptable, but I'm sure we can come up with  
something a bit more general that won't dramatically hinder revisions  
of R6RS.

While we're on the subject of symbol syntax, we should discuss a  
notation for write/read invariance of symbols.  For example, what is  
the external representation of (string->symbol "Will \"does\" |not|  
(like) this")?  I propose:

        |Will "does" \|not\| (like) this|

We may also want to prevent "unescaped" symbols from ending (or  
beginning) with a colon (so that this notation can be used for  
keywords).

Marc



More information about the R6RS mailing list