[plt-scheme] Re: When does eqv? differ from eq? , from equal?

From: Alan Watson (alan at alan-watson.org)
Date: Tue Oct 7 15:05:02 EDT 2008

Both the R5RS and R6RS have mutable strings. However, in order to  
obtain access to the mutators in the R6RS, you have to import the  
mutable-strings library.

When I said that standard Scheme does not have "real" mutable strings,  
I meant that while string literals in programs or obtained from read  
should not be modified, there are no distinctions between such strings  
and other strings except for the possibility of bad things happening  
if you attempt to mutate them. In particular, there is no safe and  
portable means to tell if a string is mutable or immutable. Ditto with  
lists in standard Scheme.

Now, PLT Scheme has real immutable pairs and real immutable strings,  
which is nice as far as it goes. It's a shame that eqv? doesn't do the  
Right Thing on them, but I guess the PLTers were scared off by the  
torpedoes :-)


Alan Watson

Posted on the users mailing list.