How about "pure virtual methods"?

John Machin sjmachin at lexicon.net
Sun Dec 19 16:23:22 EST 2004


Alex Martelli wrote:
> John Machin <sjmachin at lexicon.net> wrote:
>    ...
> > 6. Alex's magnum opus appears to operate on problem a, and maybe on
b
> > (it's over my head). It involves a fair chunk of mucking about --
for
>
> A dozen lines of code to write *ONCE* and put in your utilities
module
> is a "magnum opus" and "a fair chunk of mucking about"?!  Oh my -- I
> wonder what would count for you as parvus and incredibly tiny -- SIX
> lines?  THREE?  ONE AND A HALF, for Pete's sake?!?!?!

"Magnum opus" was exaggerated politeness.

>
> If your problem with my code is simply that it uses parts of Python
that
> you're not familiar about, then I count this as a positive aspect of
my
> code, not a negative one: by providing motivation to study
metaclasses
> and inspect (by givin some small usefulness in very small space) it
may
> help you indirectly far more than directly.

Thank you for the motivation. I now understand what it is attempting to
do. Unfortunately it doesn't succeed. Instead of:

if v is notimplemented: abstract_methods.append(n)

you need:
if v.im_func is notimplemented: abstract_methods.append(n)




More information about the Python-list mailing list