Path: csiph.com!usenet.pasdenom.info!dedibox.gegeweb.org!gegeweb.eu!nntpfeed.proxad.net!proxad.net!feeder1-2.proxad.net!usenet-fr.net!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!newsfeed.eweka.nl!eweka.nl!feeder3.eweka.nl!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!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.024 X-Spam-Evidence: '*H*': 0.95; '*S*': 0.00; 'output': 0.04; 'function,': 0.07; 'sep': 0.09; 'producing': 0.15; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'lookups': 0.16; 'operator;': 0.16; 'operators.': 0.16; 'wrote:': 0.17; 'thu,': 0.17; 'received:209.85.214.174': 0.21; 'statement': 0.23; 'header:In-Reply-To:1': 0.25; 'message-id:@mail.gmail.com': 0.27; 'overhead': 0.29; 'subject: ?': 0.30; 'unlike': 0.30; 'function': 0.30; 'could': 0.32; 'to:addr:python-list': 0.33; 'received:google.com': 0.34; 'pm,': 0.35; 'similar': 0.35; 'received:209.85': 0.35; 'subject:with': 0.36; 'received:209': 0.37; 'far': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'received:209.85.214': 0.39; 'little': 0.39; 'header:Received:5': 0.40; 'high': 0.61; 'more': 0.63; 'making': 0.64; 'direct': 0.69; 'benefit': 0.70; 'device,': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=Zxu1RAR4vOfWNtO+gVPEIh1dllcW1L/zxLXOI+lml8g=; b=PHKhTCsttcq2lPfcQdGhLVSaHDadOUDXddf6NVwX13TTquNH078UpUcX4cjWWk3Ghk l4Trnch4qAQqk8sa1QLuTrAsjRLcATyaQByqaBZbFj/lF3vhfZngqEN2NAUjPzbyzJWm eY8rxjSoYgiey/a8381ZG0CkcDsXCEkDAzYJL43Te3Nley5AGDFRw+oomvY2JsZ8CdPY uRAc4pS0VVOA0Y7B4jWECnUsFZFT6zeghnvLg7rjl0LX5AOjmLpznt+Oaz7xCbXygm6+ hwQtLdBPdRwVIto/ITThpUi6RzlNgMwBDjR8Nv1VvorNeOhF2TDh3YHjQni5EJcw4jJP A6mQ== MIME-Version: 1.0 In-Reply-To: References: <504717ee$0$29977$c3e8da3$5496439d@news.astraweb.com> <50475e0a$0$29981$c3e8da3$5496439d@news.astraweb.com> Date: Thu, 6 Sep 2012 19:07:31 +1000 Subject: Re: is implemented with id ? From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 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: 11 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1346922453 news.xs4all.nl 6918 [2001:888:2000:d::a6]:49295 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:28561 On Thu, Sep 6, 2012 at 6:26 PM, Ramchandra Apte wrote: > the is statement could be made into a function It's not a statement, it's an operator; and functions have far more overhead than direct operators. There's little benefit in making 'is' into a function, and high cost; unlike 'print', whose cost is dominated by the cost of producing output to a console or similar device, 'is' would be dominated by the cost of name lookups and function call overhead. ChrisA