[Edu-sig] Properties use case

Arthur ajsiegel at optonline.net
Wed Mar 15 15:41:20 CET 2006

kirby urner wrote:

>>I am sure I am taking at least a bit of a performance hit by going this
>>route.  Does anyone see something simple I may be missing here to get to
>>where I am trying to get, without the hit?
>Sounds like the kind of question that should go with example code, but
>maybe that's just me.
What it seems to be is mostly a question of a limitation in my 
understanding of what means  type(xxx).  I want to create a class that 
impersonates a built-in type - in my case <type 'complex'>.  And in fact 
am working from pypy code that not only impersonates <type 'complex'>, 
but within the pypy implementation, *is* <type 'complex'>. How does pypy 
get there?

My motive is simply to con Numeric into a willingness to treat my 
implementation of the complex number type - the mutable one - on the 
same basis that it treats the built-in immutable one.

Is there a mechanism to con Numeric here?


>Edu-sig mailing list
>Edu-sig at python.org

More information about the Edu-sig mailing list