Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!proxad.net!feeder1-2.proxad.net!news.tele.dk!news.tele.dk!small.news.tele.dk!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'static': 0.04; 'guido': 0.05; 'implements': 0.09; 'method,': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'subject:Why': 0.09; 'subject:method': 0.09; 'python': 0.11; 'jan': 0.12; '__new__': 0.16; 'normally,': 0.16; 'partly': 0.16; 'reason.': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; ':-)': 0.16; 'all.': 0.16; 'wrote:': 0.18; 'header:User-Agent:1': 0.23; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'am,': 0.29; "skip:' 10": 0.31; 'explained': 0.31; 'class': 0.32; 'maybe': 0.34; "i'd": 0.34; 'could': 0.34; 'knows': 0.35; 'something': 0.35; 'beyond': 0.35; 'but': 0.35; 'there': 0.35; 'words,': 0.36; 'method': 0.36; 'subject:?': 0.36; 'searching': 0.37; 'to:addr:python-list': 0.38; 'issue': 0.38; 'does': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'how': 0.40; 'received:173': 0.61; 'teaching': 0.64; 'details': 0.65; 'once).': 0.84; 'received:fios.verizon.net': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: Why has __new__ been implemented as a static method? Date: Sat, 03 May 2014 16:32:37 -0400 References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable X-Gmane-NNTP-Posting-Host: pool-173-75-254-207.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 In-Reply-To: X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 29 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1399149214 news.xs4all.nl 2867 [2001:888:2000:d::a6]:58374 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:70900 On 5/3/2014 6:37 AM, Jurko Gospodneti=C4=87 wrote: > Hi all. > > I was wandering why Python implements its __new__ method as a static= > and not a class method? For a technical internal reason that Guido and maybe others have=20 explained on pydev (more than once). I forget the details partly because = I do not care beyond knowing that there is a reason. You might be able=20 to find something by searching the pydev archives at gmane.org for=20 '__new__ static method'. In other words, Guido knows that it 'should' be = a class method, if it could be. > Normally, I'd chalk this issue up under 'bike-shedding', but it came= > up while teaching others about Python and so does not feel right leavin= g > it as 'because that's the way it is'. :-) 'Because that is how it has to be for technical internal reasons beyond=20 the scope of my teaching.' --=20 Terry Jan Reedy