> * Functions having the same signature share the same annotation tuple.

Is this true with code that have a mutable default?

>>> def a(arg = []):
...     arg.append('a')
...     return arg
...
>>> def b(arg = []):
...     arg.append('b')
...     return arg
...
>>> a()
['a']
>>> a()
['a', 'a']
>>> a()
['a', 'a', 'a']
>>> b()
['b']
>>> b()
['b', 'b']
>>> b()
['b', 'b', 'b']
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/5Y7PU6HAXGGG5TGNLTLAGQXDSPW65ZK2/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to