Path: csiph.com!news.swapon.de!newsfeed.fsmpi.rwth-aachen.de!newsfeed.straub-nv.de!npeer.de.kpn-eurorings.net!npeer-ng0.de.kpn-eurorings.net!fu-berlin.de!uni-berlin.de!not-for-mail From: Ian Kelly Newsgroups: comp.lang.python Subject: Re: What is a function parameter =[] for? Date: Wed, 25 Nov 2015 13:39:44 -0700 Lines: 27 Message-ID: References: <56547337.4000709@rece.vub.ac.be> <56547C53.8030407@rece.vub.ac.be> <5654864E.2070906@rece.vub.ac.be> <56549324.8020607@rece.vub.ac.be> <56549F15.40206@rece.vub.ac.be> <5654B037.6020107@rece.vub.ac.be> <56550273$0$1585$c3e8da3$5496439d@news.astraweb.com> <5655f27b$0$1614$c3e8da3$5496439d@news.astraweb.com> <5655FDAC.4070305@rece.vub.ac.be> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: news.uni-berlin.de CIYxKNyzGxcOvDdvXUQ8bwZ5w8FBDQej4NayR35hDlXQ== 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; 'received:209.85.223': 0.03; 'expressions': 0.07; 'literal': 0.09; 'notation.': 0.09; 'tuple': 0.09; 'python': 0.10; 'wed,': 0.15; '(3,': 0.16; 'constructs': 0.16; 'literal.': 0.16; 'literals': 0.16; 'literals,': 0.16; 'literals.': 0.16; 'notations': 0.16; 'quoted': 0.16; 'received:209.85.223.173': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'wrote:': 0.16; 'language': 0.19; '2015': 0.20; 'constant': 0.22; 'am,': 0.23; 'header:In-Reply-To:1': 0.24; 'supported': 0.27; 'message-id:@mail.gmail.com': 0.27; 'values': 0.28; 'about.': 0.29; 'notation': 0.29; 'sentence': 0.29; 'types.': 0.29; 'says': 0.32; 'point': 0.33; 'values.': 0.33; 'definition': 0.34; 'received:google.com': 0.35; 'nov': 0.35; 'something': 0.35; 'but': 0.36; 'received:209.85': 0.36; 'to:addr :python-list': 0.36; 'subject:?': 0.36; 'subject:: ': 0.37; 'display': 0.37; 'things': 0.38; 'received:209': 0.38; 'mean': 0.38; 'to:addr:python.org': 0.40; 'still': 0.40; 'some': 0.40; 'believe': 0.66; 'talking': 0.67; 'therefore': 0.67; 'expresses': 0.84; 'pardon': 0.84; 'to:name:python': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=8yqMpB3KHz6mzsXzHk89Onbde+QUh3nyP7wJ0IvE7yE=; b=MxBVXSRETHF8sEPSHwyo5VIv4q3Qllx6pdDZwop5ZGiBucXmnFqHGkqRXGWHurb4sk 15C3QnceF8gI+V1w88oacIekGQ7Qlj7Oq2QeaFS1aTgsO9G3uyG0ZNDRTH9XPQU72jRO KiEq4dwiXDlYCPSkFK0WjdQeshGoukOStlyKoV/W4qlVNaUjTOuaufSXE2yj9QGIakxP E44+o/mDfP/TSR3ymNFWHUVomODdbS0Jz7dwWY95Wncvbfx8fGfXp7vzu4/2811smC7G 7x7thoN33X62jwKc+2Lv8vl7ydBGDTJvhvwkjvr4n+RGA5dOnTuHkC9V60Kriadq/B/A E23Q== X-Received: by 10.107.137.226 with SMTP id t95mr36659380ioi.188.1448484024079; Wed, 25 Nov 2015 12:40:24 -0800 (PST) In-Reply-To: <5655FDAC.4070305@rece.vub.ac.be> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.20+ Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:99483 On Wed, Nov 25, 2015 at 11:27 AM, Antoon Pardon wrote: > I don't know what you are talking about. The first thing I have argued > is that () is a literal. Then I have expaned that to that something > like (3, 5, 8) is a literal. I never argued that tuple expressions > in general are literals. And one way I supported my point was with the > following quote from the python language reference. > > Literals are notations for constant values of some built-in types. > > And I think that the things I argued were literals, were in fact > constant values of some built-in type. I believe that sentence from the docs is using "some" to mean "not all", whereas you are apparently using it to mean "any". frozenset([1,2,3]) constructs a constant value of a built-in type. Would you consider that a literal? How about tuple(1, 2+3, abs(-19))? Still a constant value of a built-in type. I think the most important word in the definition you quoted is actually "notation". It says it right there: literals are not "constant values", but notations for *expressing* constant values. The tuple display notation expresses values that may be constant but need not be. Therefore it's not a literal notation.