osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Python-Dev] deprecation of abstractstaticmethod and abstractclassmethod


On 15May2019 1248, Nathaniel Smith wrote:
> I don't care about the deprecation either way. But can we fix the 
> individual decorators so both orders work? Even if it requires a special 
> case in the code, it seems worthwhile to remove a subtle user-visible 
> footgun.

The classmethod and staticmethod objects already have a getter for 
__isabstractmethod__ that forwards to the underlying object, so they 
should just need a setter as well, right?

I also have no strong opinion about deprecation. But fixing this seems 
pretty straightforward and may be a good task for someone's first C 
contribution?

Cheers,
Steve