class-based class decorator

Chris Angelico rosuav at gmail.com
Fri Jan 9 20:07:44 EST 2015


On Sat, Jan 10, 2015 at 8:26 AM, Albert-Jan Roskam
<fomcl at yahoo.com.dmarc.invalid> wrote:
> I am trying to write a class decorator that checks whether deprecated parameters with non-default
>
> arguments are used. More complete code is here: http://pastebin.com/ZqnMis6M. In the code below,
>

Any particular reason to make this a class decorator, rather than a
function decorator on __init__? After all, __init__ is where you're
defining the deprecated parameters.

ChrisA



More information about the Python-list mailing list