"Serdar Tumgoren" <[email protected]> wrote

So is a reference simply a Python-level symbol (ie some collections of characters accessible from Python code) that corresponds to a pointer, which
in turn points to the location in memory where the object is stored?

Or to think of it in Python terms a reference or name is simply a key
in a dictionary, with one such dictionary per namespace. When you
do a dir() you are asking for the keys - the names - in that namespace.

The objects that the names refer to are the values in the dictionary.
But then it gets circular since the dictionary does not store the objects, just references to the objects - but those references could be pointers
depending on implementation :-)

HTH,


--
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/


_______________________________________________
Tutor maillist  -  [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to