On 12/23/11 10:22 AM, rusi wrote:
On Dec 23, 2:39 pm, Steven D'Aprano<steve
+comp.lang.pyt...@pearwood.info> wrote:
On Fri, 23 Dec 2011 00:38:07 -0800, rusi wrote:
Likewise function arguments that default to mutable entities is a known
gotcha of python which is best treated as a bug in python.
Nonsense. It is a feature, not a bug.
Tsk Tsk How can python have a bug? And that too on the python mailing
list?
Others however feel differently. See Chris Rebert's
http://mail.python.org/pipermail/python-ideas/2007-January/000073.html
and the links cited there.
Some people might argue that it is a mistake, a minor feature which
allegedly causes more difficulties than benefits. I do not hold with that
idea. But either way, it is not a bug to be fixed, but a deliberate
consequence of intended semantics.
I did not ask or imply that it should be 'fixed', just that language
misfeatures should be treated with extra care.
"Bug" means, roughly, "something that should be fixed" not just any "thing that
has some unwanted consequences". So yes, by calling it a bug you are asking and
implying just that. If you don't mean that, don't use the word "bug".
--
Robert Kern
"I have come to believe that the whole world is an enigma, a harmless enigma
that is made terrible by our own mad attempt to interpret it as though it had
an underlying truth."
-- Umberto Eco
--
http://mail.python.org/mailman/listinfo/python-list