Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Nick Coghlan
On 14 July 2016 at 08:46, Guido van Rossum wrote: > On Wed, Jul 13, 2016 at 7:15 AM, Martin Teichmann > wrote: >> Another small change should be noted here: in the current implementation of >> CPython, ``type.__init__`` explicitly forbids the use of keyword arguments, >> while ``type.__new__`` a

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Martin Teichmann
Hi Guido, Hi list, Thanks for the nice review! I applied followed up your ideas and put it into a github pull request: https://github.com/python/peps/pull/53 Soon we'll be working there, until then, some responses to your comments: > I wonder if this should be renamed to __set_name__ or somethin

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Martin Teichmann
Hi Nick, hi list, > It would be worth spelling out the end result of the new behaviour in > the PEP to make sure it's what we want. Trying to reason about how > that code works is difficult, but looking at some class definition > scenarios and seeing how they behave with the old semantics and the

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Guido van Rossum
I just reviewed the changes you made, I like __set_name__(). I'll just wait for your next update, incorporating Nick's suggestions. Regarding who merges PRs to the PEPs repo, since you are the author the people who merge don't pass any judgment on the changes (unless it doesn't build cleanly or may

Re: [Python-Dev] __qualname__ exposed as a local variable: standard?

2016-07-14 Thread Guido van Rossum
I think this and similar issues suffer from a lack of people who have both the time and the understanding to review patches and answer questions of this nature. To the OP: I would recommend not depending on the presence of __qualname__ in the locals, as another compiler/interpreter may come up wit

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/14/2016 11:47 AM, Guido van Rossum wrote: > If you intend a PR as a base for discussion you can add a comment > saying e.g. "Don't merge yet". If you call out @gvanrossum, GitHub > will make sure I get a message about it. FWIW, I often use a Gi

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Brett Cannon
On Thu, 14 Jul 2016 at 11:05 Tres Seaver wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 07/14/2016 11:47 AM, Guido van Rossum wrote: > > > If you intend a PR as a base for discussion you can add a comment > > saying e.g. "Don't merge yet". If you call out @gvanrossum, GitHub > >

Re: [Python-Dev] PEP487: Simpler customization of class creation

2016-07-14 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/14/2016 02:10 PM, Brett Cannon wrote: > On Thu, 14 Jul 2016 at 11:05 Tres Seaver > wrote: > >> -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 >> >> On 07/14/2016 11:47 AM, Guido van Rossum wrote: >> >>> If you intend a PR as a base for discuss