Today I learned that **kwargs style keyword arguments can be any string:

py> def test(**kw):
...     print(kw)
... 
py> kwargs = {'abc-def': 42, '': 23, '---': 999, '123': 17}
py> test(**kwargs)
{'': 23, '123': 17, '---': 999, 'abc-def': 42}


Bug or feature?



-- 
Steve

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to