[Python-3000] PEP 3124 - Overloading, Generic Functions, Interfaces, etc.

Phillip J. Eby pje at telecommunity.com
Sat May 12 21:26:10 CEST 2007

At 03:03 PM 5/12/2007 -0400, Jim Jewett wrote:
>On 5/12/07, Phillip J. Eby <pje at telecommunity.com> wrote:
>>At 01:43 PM 5/12/2007 +1200, Greg Ewing wrote:
>>In practice, @around is mostly used for application-defined special
>>cases, and there is no higher authority than the application who
>>needs to override things.  If a library needs special combinators
>>internally, it's better off making them lower-than- at around
>>precedence.  Normal, before, and after methods are usually adequate
>>for libraries.  (Aside from special-purpose combinators like the
>>@discount example.)
>(1)  Would it be reaonable to say this in the PEP?


>(2)  Would it be reasonable to leave out (or at least, leave for
>another PEP) the extension methods like discount?

The emerging consensus appears to be that everything relating to 
method combination and Aspects should be a second PEP, much like the 
Python 2.2 type system overhaul was separated into a 
mro/metaclass-oriented PEP and a descriptor-oriented PEP, even though 
the two were  quite interrelated.

So, examples for custom method combination, as well as best-practices 
for the standard combinators' uses would reasonably both go in the 
method-combination-and-aspects PEP.

More information about the Python-3000 mailing list