Scheme language standardization process
On Mon, 29 Aug 2011 12:16:40 -0400, Aubrey Jaffer <agj@x> wrote: > This would seem like a good application for multiple-value returns: > SCANF-READ would return the number of format directives matched > followed by the objects read. But LET-VALUES, LET*-VALUES, and > (srfi-8) RECEIVE expect the number of bindings to match the number of > return values. They can't be used if the number of return values is > not known in advance. This does not hold for the normal implementations of LET-VALUES or LET*-VALUES. In both cases, if you do not know how many bindings you will receive, you can do the following: (let-values ([x (values 1 2 3)]) (length x)) ; => 3 Aaron W. Hsu -- Programming is just another word for the lost Art of Thinking. _______________________________________________ Scheme-reports mailing list Scheme-reports@x http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports