[R6RS] multiple-value binding

Anton van Straaten anton at appsolutions.com
Thu Mar 2 00:45:19 EST 2006

> I have a couple of comments and a proposal to restart the multiple-value
> binding discussion.
> Comment 1: With option 4, I'm concerned about named let.  Do we allow
> "values" binding clauses when the let is named?  

How would that work, though?  I was assuming something like this 
wouldn't be permitted:

   (let foo ((a 0)
             ((values b c) (values 1 2)))

If it were permitted, would it be called using (foo x y z), or the more 
semantically startling (foo x (values y z)) [surely not], or am I just 
suffering from "confusion about how the procedure bound to the name is 

The root issue here seems to be that the longstanding, rather profoundly 
simple mapping between LET and LAMBDA has been compromised.  If it 
weren't for that, there presumably wouldn't be any need to consider an 
alternate form, and named LET wouldn't be a problem.

But now I'm standing in front of the door labelled "Multiple value 
semantics", which I suspect may have been firmly taped shut.

> Proposal: Go with option 4 and use the name mvlet rather than let-values.
> This has three benefits.  (1) The name of the let* version is obvious and
> natural: mvlet*.  (2) It addresses Anton's concern about "let-values"
> being too long.  (3) Because it's shorter, the transition from let
> to mvlet is a tad bit easier, in that it's less likely to necessitate
> reformatting.  On the downside, "mvlet" isn't a legal Scrabble word,
> and that will offend some people.  Also, it does not completely eliminate
> the discontinuity between let and multiple-value let.

For the name, how about let/v and let/v* ?  Or variations, like let-v or 
let/mv.  I don't think that being explicit about the "m" is necessary, 

I have a question about the overall rationale here: with an alternate 
form like mvlet, which is designed to support both single and multiple 
values well, should the original LET end up being deprecated (except for 
the named let form)?  After all, mvlet will have the same syntax as LET, 
for single values.  Alternatively, should they be considered coequal, 
intended to support two different programming styles?  While we may not 
get to decide what happens in practice, we may want to explain what is 


More information about the R6RS mailing list