call by reference howto????

Paul Rudin paul.nospam at rudin.co.uk
Thu Mar 13 04:54:43 EDT 2008


Antoon Pardon <apardon at forel.vub.ac.be> writes:

> On 2008-02-28, Steven D'Aprano <steve at REMOVE-THIS-cybersource.com.au> wrote:
>> On Thu, 28 Feb 2008 02:02:19 +0200, Tamer Higazi wrote:
>>
>>> Hi!
>>> Can somebody of you make me a sample how to define a function based on
>>> "call by reference" ???
>>
>> Python doesn't do call by reference. Nor does it do call by value. Please 
>> pay no attention to anyone who says it does.
>
> Whatever python has for a calling convention, it is close enough that
> naming it "call by reference" gives people a reasonable idea of what
> is going on.

Quite. The thing is not to get hung up with the label - but to
understand what actually happens.




More information about the Python-list mailing list