On 2008-08-29, Roy Smith <[EMAIL PROTECTED]> wrote:
> Exactly. This is one of those little pieces of syntactic
> sugar which makes python so nice to work with. The
> alternative is (in C, for example) abominations like this:
>
> const char* l[] = {"foo"
> , "bar"
> , "baz"
> };
>
> and even those are not quite as good because you still have to
> special-case the first entry.
It's probably a spec violation, but I've never seen a C
compiler that objected to a comma after the last item in an
initializer list. (At least not at the warning levels I use,
which tend to be on the picky side.)
--
Grant Edwards grante Yow! There's enough money
at here to buy 5000 cans of
visi.com Noodle-Roni!
--
http://mail.python.org/mailman/listinfo/python-list