News for hackers. Stuff that matters.
Re:Python's Mutable Default Problem by tswicegood on Sunday February 20, 2011 @02:46PM (#2242799)
You can also do:

    stuff = stuff is not None and stuff or []
That said, the `if stuff is not None:` is the most Pythonic way of doing it.

There are no comments on this comment yet.