Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)

2016-06-13 Thread Berker Peksağ
On Sun, Jun 12, 2016 at 5:37 AM, Eric Snow wrote: > The following code demonstrates roughly equivalent semantics for the > default behavior:: > >class Meta(type): >def __prepare__(cls, *args, **kwargs): Shouldn't this be wrapped with a classmethod

Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)

2016-06-11 Thread Émanuel Barry
> From: Eric Snow > Sent: Saturday, June 11, 2016 11:02 PM > To: Émanuel Barry > Cc: Python-Dev > Subject: Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace > (round 3) > > On Sat, Jun 11, 2016 at 7:51 PM, Émanuel Barry <vgr...@live.ca> wrote:

Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)

2016-06-11 Thread Eric Snow
On Sat, Jun 11, 2016 at 7:51 PM, Émanuel Barry wrote: >> From: Eric Snow >> 1. if ``__definition_order__`` is defined in the class body then it >> must be a ``tuple`` of identifiers or ``None``; any other value >> will result in ``TypeError`` > > Why not just any

Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)

2016-06-11 Thread Émanuel Barry
> From: Eric Snow > Sent: Saturday, June 11, 2016 10:37 PM > To: Python-Dev; Guido van Rossum > Subject: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round > 3) > The only change to the original proposal > has been that a manually set __definition_or

[Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)

2016-06-11 Thread Eric Snow
I've updated the PEP to reflect feedback up to this point. The reception has been positive. The only change to the original proposal has been that a manually set __definition_order__ must be a tuple of identifiers or None (rather that using the value as-is). All other updates to the PEP have