Path: csiph.com!usenet.pasdenom.info!gegeweb.org!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed2.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.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'python.': 0.02; 'tom': 0.07; 'variables': 0.07; 'classes.': 0.09; 'literal': 0.09; 'methods,': 0.09; 'parsing': 0.09; 'subject:design': 0.09; 'type,': 0.09; 'cc:addr:python-list': 0.11; 'python': 0.11; 'wrote': 0.14; 'creates': 0.14; '11:09': 0.16; 'cc:name:python list': 0.16; 'dict': 0.16; 'direct,': 0.16; 'dynamic,': 0.16; 'gotcha.': 0.16; 'hashable': 0.16; 'keys.': 0.16; 'mutable': 0.16; 'new-style': 0.16; 'sins': 0.16; 'subject:Language': 0.16; 'to:addr:pearwood.info': 0.16; "to:name:steven d'aprano": 0.16; 'wrote:': 0.18; 'variable': 0.18; 'rules': 0.22; 'cc:addr:python.org': 0.22; 'mon,': 0.24; 'cc:2**0': 0.24; 'class.': 0.26; 'least': 0.26; 'header:In-Reply-To:1': 0.27; 'tried': 0.27; 'resolution': 0.29; 'sets': 0.30; 'message- id:@mail.gmail.com': 0.30; 'url:mailman': 0.30; 'work.': 0.31; "d'aprano": 0.31; 'keys': 0.31; 'operators': 0.31; 'sep': 0.31; 'steven': 0.31; 'regular': 0.32; 'url:python': 0.33; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'url:listinfo': 0.36; "didn't": 0.36; 'method': 0.36; 'url:org': 0.36; 'should': 0.36; 'pm,': 0.38; 'anything': 0.39; 'bad': 0.39; 'changed': 0.39; 'enough': 0.39; 'url:mail': 0.40; 'ago,': 0.61; 'god': 0.65; 'here': 0.66; 'close': 0.67; 'difficulty': 0.68; 'optimized': 0.68; 'default': 0.69; 'obvious': 0.74; 'dict,': 0.84; 'hardly': 0.84; 'mentally.': 0.84; 'mistakes,': 0.84; 'started,': 0.84; 'thing,': 0.91; 'washington': 0.93; '2013': 0.98 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 :cc:content-type; bh=nYrioWN7qw/ue3FohSiPiagp1O3qmT/2V1cMw1+oemw=; b=HRNnDIWoo5Qw78atjLNtUibs2Ddn7PWNfHTQEDbjreIa8g6RLFGZTpWxWnh3C7d3EE 6poeTA5v3j5R/+7xGbTL7hj/CiOag5gAuX1BX/LUcVbOIUqjyjiilMxXCuHEuVpJpeQb cz/Jjk6V/ORrhCnOOgUA3r1Aa9ftXkNL/a22iY8i5sp5OQv2pm0j3a5+VJ7TN/8Mrq+L YkEvLRKbCYsqnXjQC57iV54uqx1X7SDbVvwa3CCe9qbUpQRRt1ky9LFw9Re6kDHIL2OB Hj5FFrOlyIJ6I0Tic5CfrFq+LNpWcJfVM0dIIIZDG+fQTKJAtY+jCMfUjk1S1mUWu5iT T49Q== MIME-Version: 1.0 X-Received: by 10.194.201.202 with SMTP id kc10mr3193930wjc.1.1378935054402; Wed, 11 Sep 2013 14:30:54 -0700 (PDT) In-Reply-To: <522eb795$0$29999$c3e8da3$5496439d@news.astraweb.com> References: <522eb795$0$29999$c3e8da3$5496439d@news.astraweb.com> Date: Wed, 11 Sep 2013 14:30:54 -0700 Subject: Re: Language design From: Mark Janssen To: "Steven D'Aprano" Content-Type: text/plain; charset=ISO-8859-1 Cc: Python List 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: 48 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1378935062 news.xs4all.nl 15945 [2001:888:2000:d::a6]:33142 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:53999 1) It tried to make Object the parent of every class. No one's close enough to God to make that work. 2) It didn't make dicts inherit from sets when they were added to Python. 3) It used the set literal for dict, so that there's no obvious way to do it. This didn't get changed in Py3k. 4?) It allowed [reference] variables to be used as dict keys. This creates a parsing difficulty for me, mentally. Keys should be direct, hashable values, not hidden in a variable name. A few of the top of the head.... Mark On Mon, Sep 9, 2013 at 11:09 PM, Steven D'Aprano wrote: > Some time ago, Tom Christiansen wrote about the "Seven Deadly Sins of > Perl": > > http://www.perl.com/doc/FMTEYEWTK/versus/perl.html > > > What design mistakes, traps or gotchas do you think Python has? Gotchas > are not necessarily a bad thing, there may be good reasons for it, but > they're surprising. > > To get started, here are a couple of mine: > > > - Python is so dynamic, that there is hardly anything at all that can be > optimized at compile time. > > - The behaviour of mutable default variables is a gotcha. > > - Operators that call dunder methods like __add__ don't use the same > method resolution rules as regular methods, they bypass the instance and > go straight to the type, at least for new-style classes. > > > > -- > Steven > -- > https://mail.python.org/mailman/listinfo/python-list -- MarkJ Tacoma, Washington