A class question

Bruno Desthuilliers bdesth.quelquechose at free.quelquepart.fr
Tue Oct 30 21:02:54 CET 2007

Hrvoje Niksic a écrit :
> Bruno Desthuilliers <bruno.42.desthuilliers at wtf.websiteburo.oops.com>
> writes:
>>>While Java's variable declarations bear a superficial (syntactical)
>>>similarity to C, their semantics is in fact equivalent to the
>>>object-reference semantics we know in Python.   They implicitly refer
>>>to objects allocated on the heap and, just like in Python, the same
>>>object can be referenced by multiple variables. 
>>You're talking about reference types here - not primitive types. And
>>even then, from what I remember (not having done any Java these last
>>4 years at least), Java's reference types are much closer to C++
>>references than to Python.
> Feel free to look it up; I believe you will find the semantics of
> assignment, parameter-passing, etc., exactly the same as in Python.

I'll do - while perhaps not in a near future !-) - and keep you informed.

More information about the Python-list mailing list