<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<title></title>
</head>
<body text="#330033" bgcolor="#ffffff">
On 12/13/2010 11:17 AM, Antoine Pitrou wrote:
<blockquote cite="mid:20101213201759.422b15de@pitrou.net"
type="cite">
<pre wrap="">On Mon, 13 Dec 2010 14:09:02 -0500
Alexander Belopolsky <a class="moz-txt-link-rfc2396E" href="mailto:alexander.belopolsky@gmail.com"><alexander.belopolsky@gmail.com></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">On Mon, Dec 13, 2010 at 11:54 AM, Guido van Rossum <a class="moz-txt-link-rfc2396E" href="mailto:guido@python.org"><guido@python.org></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">I'm at least +0 on
allowing trailing commas in the situation the OP mentioned.
</pre>
</blockquote>
<pre wrap="">
FWIW, I am also about +0.5 on allowing trailing comma. Note that in a
similar situation, the C standardization committee has erred on the
side of consistency:
"""
A new feature of C99: a common extension in many implementations
allows a trailing comma after the list of enumeration constants. The
Committee decided to adopt this feature as an innocuous extension that
mirrors the trailing commas allowed in initializers.
""" <a class="moz-txt-link-freetext" href="http://www.open-std.org/jtc1/sc22/wg14/www/C99RationaleV5.10.pdf">http://www.open-std.org/jtc1/sc22/wg14/www/C99RationaleV5.10.pdf</a>
Similarly, I find allowing trailing comma in keyword only arguments
lists to be an innocuous extension that mirrors the trailing commas
allowed in the positional arguments lists.
</pre>
</blockquote>
<pre wrap="">
+1 from me as well. Special cases are hard to remember.
</pre>
</blockquote>
<br>
+1. I tend to put them in, and then take out the ones that Python
won't accept.<br>
Then, when I add another item to the list, Python tells me to go
back and put the one I took out back in again, and take out the one
I put in at the new end of the list. Annoying. (for vertically
arranged lists, one per line, primarily, with ) on the last line by
itself.<br>
</body>
</html>