Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!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.004 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'attribute': 0.07; 'exec': 0.07; 'python': 0.08; 'reason?': 0.09; 'cc:addr:python-list': 0.15; 'syntax': 0.15; 'designate': 0.16; 'input.': 0.16; 'lookup': 0.16; 'subject:() ': 0.16; 'wed,': 0.17; 'cheers,': 0.18; 'wrote:': 0.18; 'arguments': 0.18; 'cc:no real name:2**0': 0.21; 'name?': 0.23; 'header:In-Reply-To:1': 0.23; 'keyword': 0.24; 'elements': 0.28; 'cc:addr:python.org': 0.29; 'message- id:@mail.gmail.com': 0.29; 'cases.': 0.30; 'subject:?': 0.31; 'error': 0.31; 'nov': 0.31; 'pm,': 0.31; 'received:209.85.161.46': 0.31; 'received:mail-fx0-f46.google.com': 0.31; 'actual': 0.32; "can't": 0.32; 'there': 0.33; 'things': 0.35; 'supposed': 0.35; 'received:209.85.161': 0.35; 'cc:2**1': 0.36; 'like,': 0.36; 'using': 0.37; 'received:google.com': 0.38; 'some': 0.38; 'received:209.85': 0.38; 'either': 0.39; 'why': 0.39; 'subject:: ': 0.39; 'received:209': 0.40; 'results': 0.61; '2011': 0.62 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=095G6vSeVlsBRjm3m1eDtTnyx7hHAdwkGIhFaUOYc6M=; b=Ivpws7i1OWKEB4KzAUNxd8ErZ0VvZg1YZJBpvrT2TPIAxh5clNfWoMSnf+EX5ppIXL A9VpyWZ8zilYXW5DPp/6Atj71rFlZEej/YP129qJhlWvVSa1F1JEtU1p46LTtyPSgXp9 brQIsFM2XM7Jh3ov6lEhnStoBILBay+DQcbnk= MIME-Version: 1.0 In-Reply-To: References: <436fb6a3-1075-45a6-8f93-5612d050b11a@q35g2000prh.googlegroups.com> <4eb9e9c2$0$29988$c3e8da3$5496439d@news.astraweb.com> <4ebb08b6$0$29970$c3e8da3$5496439d@news.astraweb.com> From: Ian Kelly Date: Wed, 9 Nov 2011 19:10:27 -0700 Subject: Re: all() is slow? To: Devin Jeanpierre Content-Type: text/plain; charset=ISO-8859-1 Cc: python-list@python.org, Steven D'Aprano X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 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: 13 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1320891059 news.xs4all.nl 6940 [2001:888:2000:d::a6]:45576 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:15523 On Wed, Nov 9, 2011 at 6:26 PM, Devin Jeanpierre wrote: > The use of exec also results in (seemingly) arbitrary constraints on > the input. Like, why can't "--" be a name? Because exec? Is there some > other reason? That's by design, not because of exec. The names are supposed to be actual Python names, things that can used to designate keyword arguments ("MyTuple(foo=42)") or to retrieve elements using attribute lookup ("my_tuple.foo"). Using "--" as a name would be a syntax error in either of those cases. Cheers, Ian