[TriLUG] Gmail invite
mattfrye at gmail.com
Tue Aug 24 11:21:08 EDT 2004
> Here's a better explanation of call-by-name instead versus
> call-by-reference versus call-by-value:
Yes, it's true that a better method of explaining Jensen's device is
by comparing it to call-by-reference. Specifically, that
call-by-reference is now part of standard C and call-by-name isn't.
Not directly anyhow.
> The Canadians are all over this stuff :-).
> It seems that the pass-by-name thing involved a "thunk" which
> appears to be a parameter-less chunk of code. Passing-by-name
> is akin to passing in a pointer to a parameter-less function in
> Pass-by-name also appears to be computationally obscure. It can
> be simulated when needed (by those clever mathematicians).
Yes, and thus the question of its significance, which was a bit of a
trick question, but I didn't think anyone would get it.
"Although call-by-name is best-known for its use in Algol 60 (a very
influential language), you should understand this is something of a
historical dead-end. Later successor languages derived from Algol 60,
such as Pascal and Algol 68, abandoned call-by-name. Even within the
Algol 60 committee, the original plan had been for call-by-reference
and call-by-value to be the two options, rather than call-by-name and
call-by-value. To the very end, some members of the committee
preferred call-by-reference, but they were having difficulty
formulating a simple, correct specification of it. Other committee
members put forward a specification of call-by-name as an alternative,
on the last day of the committee meeting. It isn't clear whether
everyone understood that what was being suggested was a different
parameter passing mechanism, rather than just a different
specification of call-by-reference. The proposal was adopted, in the
last hour of the last day, but according to Peter Naur, "it seemingly
was understood in a coherent manner only by one member, Alan Perlis."
("The European Side of the Last Phase of the Development of Algol 60,"
in History of Programming Languages, Richard L. Wexelblat, ed.,
Academic Press, 1991, pp. 111-112.)"
More information about the TriLUG