Swap by name

Chris Torek chris at umcp-cs.UUCP
Mon Jul 7 09:10:36 AEST 1986


>In article <1964 at brl-smoke.ARPA> rbj at icst-cmr.ARPA (Root Boy Jim) writes:
>>I was thinking of the caller squirrelling away the value in a temporary
>>location, passing it by reference (thus allowing modification by the
>>callee) and then copying the result to the real variable.

In article <1060 at umd5.UUCP> zben at umd5.UUCP (Ben Cranston) replies:
>Of course the difference between this and real call-by-name comes when 
>the subroutine has an alternate access to the global in question - perhaps
>because of scoping rules, or access to a pointer-to-it or something.

Careful, Ben: this was under a section about call by value-result,
and it does accomplish that quite handily.
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 1516)
UUCP:	seismo!umcp-cs!chris
CSNet:	chris at umcp-cs		ARPA:	chris at mimsy.umd.edu



More information about the Comp.lang.c mailing list