Question about subclassing - version 2

Steve Holden steve at holdenweb.com
Fri Sep 8 11:53:24 EDT 2006


Frank Millman wrote:
> Bruno Desthuilliers wrote:
> 
>>Frank Millman wrote:
>>
>>>I have not gone to the trouble of raising NotImplementedError - the
>>>methods that the subclasses *must* override just have a 'pass'
>>>statement. I guess it would be more correct to raise the error, as it
>>>would give me a quicker indication of an error if I happened to omit
>>>one, but in practice I would find out pretty quickly anyway.
>>
>>Mmm... My own experience is that methods that *must* be redefined are
>>better raising NotImplementedError. Makes things more obvious IMHO.
>>
> 
> 
> Can't argue with that. I have just gone through my app and changed them
> all :-)
> 
Yup, if a thing can't go wrong, it won't

regards
  Steve
-- 
Steve Holden       +44 150 684 7255  +1 800 494 3119
Holden Web LLC/Ltd          http://www.holdenweb.com
Skype: holdenweb       http://holdenweb.blogspot.com
Recent Ramblings     http://del.icio.us/steve.holden




More information about the Python-list mailing list