Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!feeder.erje.net!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.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'be:': 0.09; 'def': 0.13; ':-p': 0.16; 'obviously,': 0.16; 'subject:syntax': 0.16; 'to:addr:pearwood.info': 0.16; 'to:addr:steve+comp.lang.python': 0.16; "to:name:steven d'aprano": 0.16; '\xa0def': 0.16; 'cc:addr :python-list': 0.16; 'mon,': 0.16; 'received:74.125.82.44': 0.16; 'received:mail-ww0-f44.google.com': 0.16; 'syntax': 0.16; 'wrote:': 0.18; 'arguments': 0.18; 'string,': 0.18; 'this?': 0.19; 'cc:no real name:2**0': 0.20; 'dec': 0.22; 'header:In-Reply-To:1': 0.22; "shouldn't": 0.23; 'cc:2**0': 0.24; 'message- id:@mail.gmail.com': 0.28; "skip:' 10": 0.29; 'cc:addr:python.org': 0.29; 'pm,': 0.29; 'correct': 0.29; 'received:74.125.82': 0.35; '...': 0.36; 'sequence': 0.37; 'received:74.125': 0.37; 'received:google.com': 0.37; 'steven': 0.38; 'why': 0.39; '2011': 0.61; 'collect': 0.61 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:content-transfer-encoding; bh=JaTd886FGc3HsBRc8kAaRXZFWQZI9SYO78NloZRuppw=; b=pO8kPXYgT+Lr/UUwuoCMOhj/sCjEe9wjaj58Q3uGvTXU1Dp1+hgGwrHcoUqY27B1aQ B1piZznCDlsX8UaUpmKkQiDW66zxGEWNcijOilYBxFvQNZ5MtpQg9rob6qPocbJTI1mk Vt/nTw2GOuMl95sQFxrqSfx0nLs5eGsI3EDAQ= MIME-Version: 1.0 In-Reply-To: <4ee6bbb3$0$11091$c3e8da3@news.astraweb.com> References: <4ee554a3$0$11091$c3e8da3@news.astraweb.com> <5de94e20-314e-4185-ba8f-75e54f87968e@d10g2000vbk.googlegroups.com> <4ee6bbb3$0$11091$c3e8da3@news.astraweb.com> From: Ian Kelly Date: Mon, 12 Dec 2011 21:52:11 -0700 Subject: Re: Verbose and flexible args and kwargs syntax To: "Steven D'Aprano" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: python-list@python.org 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: 12 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1323751964 news.xs4all.nl 6914 [2001:888:2000:d::a6]:36892 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:17104 On Mon, Dec 12, 2011 at 7:43 PM, Steven D'Aprano wrote: > If I want to collect a sequence of arguments into a string, why shouldn't > I be allowed to write this? > > =A0 =A0def func(parg, str(args)): ... Obviously, because the correct syntax would be: def func(parg, ''.join(args)): ... :-P