Edoardo Spadolini added the comment:
Not really, but putting something in your inheritance lattice only to mark a
class as providing an interface just doesn't seem right to me.
--
___
Python tracker
<http://bugs.python.org/is
Edoardo Spadolini added the comment:
Yeah, I should've waited for the test to finish, but come on, "it was just a
small change" :(
Now I know why you should always test everything at least, sorry about that :)
--
___
Python
Changes by Edoardo Spadolini :
Added file: http://bugs.python.org/file20337/abcmeta_register_v4_plus_tests.diff
___
Python tracker
<http://bugs.python.org/issue10
Changes by Edoardo Spadolini :
Removed file:
http://bugs.python.org/file20336/abcmeta_register_v4_plus_tests.diff
___
Python tracker
<http://bugs.python.org/issue10
Edoardo Spadolini added the comment:
Fair enough :)
--
Added file: http://bugs.python.org/file20336/abcmeta_register_v4_plus_tests.diff
___
Python tracker
<http://bugs.python.org/issue10
Changes by Edoardo Spadolini :
--
nosy: +benjamin.peterson, durban, eric.araujo, gvanrossum, pitrou, rhettinger
___
Python tracker
<http://bugs.python.org/issue10
Edoardo Spadolini added the comment:
Whoops, corrected that - should I add some more tests for that too?
--
nosy: -benjamin.peterson, durban, eric.araujo, gvanrossum, pitrou, rhettinger
Added file: http://bugs.python.org/file20335/abcmeta_register_v4.diff
Edoardo Spadolini added the comment:
Ok, edited the docs too; hope I did everything right...
--
Added file:
http://bugs.python.org/file20315/abcmeta_register_deco_with_docs.diff
___
Python tracker
<http://bugs.python.org/issue10
New submission from Edoardo Spadolini :
If we make ABCMeta.register() return the registered class, like
atexit.register() does for the registered function, we can then use it as a
decorator:
Now:
class Foo:
...
ABarC.register(Foo)
With this change:
@ABarC.register
class Foo