Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Neil Cerutti Newsgroups: comp.lang.python Subject: Re: what does 'a=b=c=[]' do Date: 23 Dec 2011 13:10:53 GMT Organization: Norwich University Lines: 17 Message-ID: <9ljcutFemiU5@mid.individual.net> References: <18f78d0d-1e70-4c7b-9033-1422e6edb6db@t13g2000yqg.googlegroups.com> <10c62dac-2750-4f08-8962-21952c1c0a0b@v31g2000prg.googlegroups.com> <5a7a7aab-a320-4429-a130-ffcfcf0ac174@v24g2000prn.googlegroups.com> <4EF440A9.7030101@stoneleaf.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: individual.net qxMVrFMZRWaXh7q3+sQnZgVchFiRfwAF+uW7sINQ5kNTvnTnhu Cancel-Lock: sha1:GX4MHAv7EhBKobvT4cAci19CTkI= User-Agent: slrn/0.9.9p1/mm/ao (Win32) Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:17799 On 2011-12-23, Chris Angelico wrote: > On Fri, Dec 23, 2011 at 7:49 PM, Ethan Furman wrote: >> That is the most ridiculous thing I have heard in a while. >> ?Mutable default arguments are *not* a bug in Python. >> >> Reminds me of a bug report a couple years back claiming >> multiple inheritence was a bug and asking it to be removed. > > Both of these could arguably be called misfeaures, but not > bugs. Is the misfeature that Python doesn't evaluate the default argument expression every time you call the function? What would be the harm if it did? -- Neil Cerutti