[Tutor] definition question

Rodrigues op73418@mail.telepac.pt
Sun Aug 3 16:24:01 EDT 2003


> -----Original Message-----
> From: tutor-admin@python.org
> [mailto:tutor-admin@python.org]On Behalf Of
> Alan Gauld
>
> > One last tidbit: as of 2.3 you still cannot inherit from
> functions --
> > although, I don't know why would I want to do that anyway.
>
> Ah, I stand corrcted then, but as I said in my earlier post
> - I can't actually think of a case where I'd want to!
> Maybe to add some kind of debugging support or something...?
>

I don't have a use case either. All use cases I've met are solved
equally well by just handrolling your own callable class (e.g.
implementing __call__) since in Python we only care about protocol (is
it callable?) and not about type (is it a function? is it a method?).

With my best regards,
G. Rodrigues





More information about the Tutor mailing list