Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Gregory Ewing Newsgroups: comp.lang.python Subject: Re: Why has __new__ been implemented as a static method? Date: Sun, 04 May 2014 20:03:35 +1200 Lines: 10 Message-ID: References: <53650751$0$29965$c3e8da3$5496439d@news.astraweb.com> <5365b5f1$0$29965$c3e8da3$5496439d@news.astraweb.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net LSoGM6ffSEKaSg5XkBQcZQWKKMGZHDxh48KXeDfpBrjpJjoGqa Cancel-Lock: sha1:Ike977Ott5nIM0DisfmGOAe+BSI= User-Agent: Mozilla Thunderbird 1.0.5 (Macintosh/20050711) X-Accept-Language: en-us, en In-Reply-To: <5365b5f1$0$29965$c3e8da3$5496439d@news.astraweb.com> Xref: csiph.com comp.lang.python:70907 Steven D'Aprano wrote: > If it were a class method, you would call it by MyBaseClass.__new__() > rather than explicitly providing the cls argument. But that wouldn't be any good, because the base __new__ needs to receive the actual class being instantiated, not the class that the __new__ method belongs to. -- Greg