[issue11455] issue a warning when populating a CPython type dict with non-string keys
Alex
report at bugs.python.org
Wed Mar 9 21:54:48 CET 2011
Alex <alex.gaynor at gmail.com> added the comment:
2 ways to do it:
class A(object):
locals()[42] = "abc"
or
type("A", (object,), {42: "abc"})
----------
nosy: +alex
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11455>
_______________________________________
More information about the Python-bugs-list
mailing list