[Tutor] Passing objects
alex at alexnewby.com
Thu Jul 8 04:49:39 CEST 2004
Continuing on my quest to understand how to pass around objects with
>>> def foo(shape):
shape = SWFShape()
>>> r = ""
<ming.SWFShape instance at 0x00B9CB20>
I am somewhat mystified by the above behaviour. A class instance is
instantiated, but r remains a string. How can I pass an instance of an
object to a function, that will permit the objects methods applied in
I was exploring the utility of the following.
instance = MainClass()
This clearly fails. Suggestions, comments, wit and sarcasm are
E-mail: alex at alexnewby.com
More information about the Tutor