[Python-Dev] [Python-checkins] peps: Update 422 based on python-dev feedback (original) (raw)
Daniel Urban urban.dani+py at gmail.com
Thu Jun 7 22:17:15 CEST 2012
- Previous message: [Python-Dev] [Python-checkins] cpython (3.2): Nudge readers towards a more accurate mental model for loop else clauses
- Next message: [Python-Dev] PEP 362 Second Revision
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Thu, Jun 7, 2012 at 9:47 PM, Terry Reedy <tjreedy at udel.edu> wrote:
On 6/7/2012 11:45 AM, Daniel Urban wrote:
On Thu, Jun 7, 2012 at 2:08 PM, nick.coghlan<python-checkins at python.org> wrote:
-* If the metaclass hint refers to an instance of
type
, then it is +* If the metaclass hint refers to a subclass oftype
, then it is considered as a candidate metaclass along with the metaclasses of all of the parents of the class being defined. If a more appropriate metaclass is found amongst the candidates, then it will be used instead of the one I think here "instance" was correct (see http://hg.python.org/cpython/file/default/Lib/types.py#l76 and http://hg.python.org/cpython/file/cedc68440a67/Python/bltinmodule.c#l90). If so, then the behavior of the standard case of a type subclass is not obviously (to me) covered.
A subclass of type is also necessarily an instance of type, so that is also covered by this case.
Daniel
- Previous message: [Python-Dev] [Python-checkins] cpython (3.2): Nudge readers towards a more accurate mental model for loop else clauses
- Next message: [Python-Dev] PEP 362 Second Revision
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]