Hans Georg Schaathun wrote:
In C it is pass by value, as the pointer
is explicit and do whatever you want with the pointer value.

You clearly are not a C programmer.

Most of my C data abstractions use dual circular linked lists of pointers to structures of pointers. *All* of that is only ever passed (at least in my programming) as references. My code almost never passes data by value.

We do not consider passing a pointer as *by value* because its an address; by definition, that is pass-by-reference. We are not passing the *value* of the data, we are passing the memory location (the reference) to the data. Pass by *value* on the other hand actually places the *value* of the data item on the call stack as a parameter.

Much of this conversation has more to do with semantics.


kind regards,
m harris




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

Reply via email to