scheme@(guile-user)> (eq? 'abc 'abc)
$1 = #t
scheme@(guile-user)> (eq? '(+ x 1) '(+ x 1))
$2 = #f
why $1 is true and $2 is false?
when I looked for 'quoting' in the r6rs
I found it:
Different constants that are the value of aquote expression may share the same
locations
I think:
'abc ' is a con
[Your reply does not seem to be on the list, so I cc it.]
Thanks. I might try an iterated cons, that is a function f such such
that
(f x1 ... xk y) --> (cons x1 ... (cons xk y) ...))
Then
(lambda (x1 ... xk . y) (f x1 ... xk y))
should just return at least k arguments as a list.
I'm not
Hans Aberg writes:
> [Your reply does not seem to be on the list, so I cc it.]
>
> Thanks. I might try an iterated cons, that is a function f such such
> that
> (f x1 ... xk y) --> (cons x1 ... (cons xk y) ...))
Isn't that just `list'?
More generally: I've been reading your emails, but I'm af
On 11 Dec 2010, at 00:12, Neil Jerram wrote:
[Your reply does not seem to be on the list, so I cc it.]
Thanks. I might try an iterated cons, that is a function f such such
that
(f x1 ... xk y) --> (cons x1 ... (cons xk y) ...))
Isn't that just `list'?
More generally: I've been reading your
Hans Aberg writes:
> The reply I got was helpful, but I decided to settle for a macro
> implementation:
>
> (use-syntax (ice-9 syncase))
>
> (define-syntax tuple
> (syntax-rules ()
> ((tuple xs ...)
> `(tuple ,xs ...))
> ((tuple x1 x2 . y)
> (append `(tuple ,x1 ,x2) y))
>