Joe Strout wrote:
On Nov 10, 2008, at 8:30 AM, Terry Reedy wrote:

That hinges on what exactly is meant by "changes to
the arguments".

Mutating them, like Python does, which is why calling Python CBV leads people to write buggy code.

>In Python it can only mean assigning
directly to the bare name -- anything else isn't
changing the argument itself, but something else to
which the argument refers.

Hogwash. The argument is the object and mutable objects can be changed as seen by the caller.

By that definition, Java, REALbasic, C++, and VB.NET are all call-by-reference too (even when explicitly using the "ByVal" keyword in RB/VB.NET). This will come as quite a shock to the designers and users of those languages.

For what it's worth, I think Greg (double-quoted above) has it exactly right. The argument in any of these languages is an object reference;

In the Python I am talking about, the language defined in the Python Reference Manual, arguments are objects.

Bye,

tjr


--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to