Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed2a.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.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'root': 0.05; 'reject': 0.07; 'subject:bug': 0.07; 'accepted,': 0.09; 'arguments': 0.09; 'constructor': 0.09; 'fix.': 0.09; 'parsing': 0.09; 'cc:addr :python-list': 0.11; 'bug': 0.12; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'likewise': 0.16; 'wrote:': 0.18; 'thu,': 0.19; 'seems': 0.21; 'accepted.': 0.22; 'cc:addr:python.org': 0.22; 'manager.': 0.24; "shouldn't": 0.24; 'unicode': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'feature': 0.29; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'anyone': 0.31; 'could': 0.34; 'but': 0.35; 'received:google.com': 0.35; 'subject:?': 0.36; 'should': 0.36; 'being': 0.38; 'problems': 0.38; 'nov': 0.38; 'rather': 0.38; 'does': 0.39; 'release': 0.40; 'conversion': 0.61; 'improvement,': 0.84; 'to:none': 0.92 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:cc :content-type; bh=MWkc/vvCg6eKSssMAMw5in3O1fxlWdEVs3C/EN9Do3c=; b=RJVyk0iuwpnOeE7D1CO8z3QcwLD2OCoVODpnzSahD+L/JOXMId1PqEBF+Gu9TSMqs2 7AuLTUbYvf8ziKZfuZSShIyX1eVxnE4JeP3NCmcs7Ox4FpHq+AWcpSwn1s6durSdCTDO k1HBkQWEo+Nqlv52MQEoQHVZ6qmdGV4MYNKJLJBNMIpENXl97a67jmm5uX5IZYBfR7Q3 54MvhyEfb5g4otbWUQhrHxiz/oYKQE3DzSzVhBCbTvVH7ORjgZ2ZNiwFqSAnTxZ11wjO 7JB10BgNwGrEfQBC7CRh6MuiopVragGLtOp4Jli7cihfHq0LapbdazyJnSpHewc/lxry wxcA== MIME-Version: 1.0 X-Received: by 10.50.23.48 with SMTP id j16mr13929509igf.34.1417016804793; Wed, 26 Nov 2014 07:46:44 -0800 (PST) In-Reply-To: <1417015925.2961473.195688745.6F0FC175@webmail.messagingengine.com> References: <1b49aa55-ba5f-4e70-8ddb-ae5dea3a40da@googlegroups.com> <1417010748.2940071.195658861.2859C26B@webmail.messagingengine.com> <1417015925.2961473.195688745.6F0FC175@webmail.messagingengine.com> Date: Thu, 27 Nov 2014 02:46:44 +1100 Subject: Re: bug or feature in enum34 py2.7 backport? From: Chris Angelico Cc: "python-list@python.org" Content-Type: text/plain; charset=UTF-8 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: 16 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1417016807 news.xs4all.nl 2867 [2001:888:2000:d::a6]:44796 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:81588 On Thu, Nov 27, 2014 at 2:32 AM, wrote: > But why shouldn't the type constructor do the conversion (and any > validation of being ASCII-only) when parsing the arguments? The root > cause seems to be that it parses its arguments with "SO!O!:type" > (typeobject.c, line 2097). Does anyone know what problems would be > caused, in general, by having S do a conversion if provided with a > unicode object? > > It seems like if it is a bug to reject long where int is accepted, it > should be likewise considered a bug to reject ASCII-only unicode where > str is accepted. Hmm, that sounds like it would be a feature improvement, rather than a bug fix. But you could take that up with the release manager. ChrisA