Subclassing array

TG girodt at gmail.com
Fri May 5 06:27:42 EDT 2006


That's great, thanks !

To put it short, when I create a Stimulus object, it first seek
__new__() method. But if I don't define it, it looks for the one
defined in Vector. This raises a problem because the parameters passed
to Stimulus(params) aren't fitting with Vector parameters, raising an
exception.

That's why I have to use this *arg **kw syntax in order to allow my
subclasses having any arguments without causing troubles. Am I right ?




More information about the Python-list mailing list