On 1/7/21 4:56 AM, Nick Coghlan wrote:
> Both EnumMeta and ABCMeta should probably be relying on `__set_name__`
> for their per-member set up work these days, rather than deferring
> that work until after __new__ returns.
And here I was thinking that `__set_name__` was for, well, setting the name. ;-)
Yeah, __set_owner__ was also discussed as a possible name, since the method notifies the descriptor of both the defining class and the attribute name within that class.
We decided we preferred __set_name__ out of the two short options.
Good to hear :)
Cheers,
Nick.