guile-user
[Top][All Lists]
Advanced

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

Re: Interesting Behavior of 'append!' In Local Context


From: Eric McDonald
Subject: Re: Interesting Behavior of 'append!' In Local Context
Date: Sat, 17 Oct 2009 20:36:41 -0400
User-agent: Thunderbird 2.0.0.23 (X11/20091003)

Stephen Compall wrote:

> Literals are literally literal.  That is to say:
> 
> (define (itsaliteral) '(42 42))

Thanks, Stephen. I never really looked at quote as declaring a literal.
I primarily saw its use for suppressing evaluation inside the quoted
entity, and as a convenient shorthand for making lists. I guess it's a
convenient shorthand for making _literal_ lists. (And, the Guile
documentation even uses the word literal - now that I'm looking for it. ;-)

> It is an error to modify literals, but it is also not required by R5RS
> to detect and inform of such erroneous modification.  It is, however,

Fair enough. I certainly wouldn't mind seeing "detect and inform"
implemented for this case. As a comparison: if I'm writing C or C++
code, and I try to modify a const value, the compiler is generally going
to let me know.

Anyway, sorry to trouble the list with a noobish oversight.

Regards,
  Eric





reply via email to

[Prev in Thread] Current Thread [Next in Thread]