Quote:
> Isn't the usefullness of having multiple return values
> for functions basically diminished by not allowing the
> returned values to be assigned to previously created
> variables?
Well, I sort of agree. However, I thought you could always "let" with the
same variable name as many times as you like in the same scope, so you
could:
let x := #"foo";
let y := #"bar";
let (x, y) := multivalue-function();
If so, then the only difference between single and multiple return values
is the use of the "let" keyword, which seems a little more formal but
doesn't seem to stand out as a problem to me.
Of course, if I'm wrong about "let" scope rules, then I think "(x, y) :=
foo()" should be added to the language unless there is a strong argument
against it.
--
Chris Page | Internet chain letters, adverti{*filter*}ts and SPAMs suck...
Don't Panic! |