guile-user
[Top][All Lists]
Advanced

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

Re: values->list elements


From: Jonathan Wilson
Subject: Re: values->list elements
Date: Tue, 13 Jun 2006 14:02:54 -0500
User-agent: Thunderbird 1.5.0.4 (X11/20060516)

Hi szgyg,

szgyg wrote:
No, this is impossible without redefining +. A macro produces 1 sexp, not more.


This is exactly what I am getting at.  values does return more than 1
sexp, but the mechanisms for using that are clumsy and painful.  It
seems that if values returns multiple s-expressions, then they should be
treated as multiple s-expressions.  In between a set of parentheses, N
s-expressions are usually treated as N elements of a list.  Why should
values be any different?

(list 0 (values 1 2) 3)
==>
(0 #<values(1 2)> 3)

This is strange.  If we had

(list 0 (values 1 2) 3)
==>
(0 1 2 3)

Then multiple values would actually be useful.

Regards,
Jon





reply via email to

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