Newsgroups: comp.lang.scheme
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news2.near.net!howland.reston.ans.net!agate!library.ucla.edu!csulb.edu!csus.edu!netcom.com!NewsWatcher!user
From: hbaker@netcom.com (Henry Baker)
Subject: Re: multiple-value return & optimising compilers
Message-ID: <hbaker-0602950955270001@192.0.2.1>
Sender: hbaker@netcom.com (Henry G. Baker)
Organization: nil
References: <dig-Scheme-7.26@mc.lcs.mit.edu> <9501310741.AA25479@clark.lcs.mit.edu> <3gvd7v$og2@tools.near.net>
Date: Mon, 6 Feb 1995 17:52:53 GMT
Lines: 18

In article <3gvd7v$og2@tools.near.net>, barmar@nic.near.net (Barry
Margolin) wrote:

> In article <9501310741.AA25479@clark.lcs.mit.edu>
shivers@clark.lcs.mit.EDU (Olin Shivers) writes:
> >Multiple return values are completely symmetric with multiple parameters to
> >procedures.
> 
> Not quite.  The number of parameters that a procedure expects is a visible,
> static property of the procedure -- it's specified in the lambda
> expression.  On the other hand, the number of return values that the
> procedure must return is a dynamic property, determined by the points of
> invocation.

Well, only if the number of parameters isn't specified by &rest (or whatever
Scheme uses for this nonsense).  Your example will only work in a
'loosely-typed' language.  Strongly-typed languages need to know a precise
parameter list format, as well as a precise return 'list' format.
