[Ironpython-users] IronPython, Daily Digest 12/16/2013
CodePlex
no_reply at codeplex.com
Tue Dec 17 09:20:32 CET 2013
Hi ironpython,
Here's your Daily Digest of new issues for project "IronPython".
In today's digest:ISSUES
1. [New issue] {}.update(b=1) -> TypeError
----------------------------------------------
ISSUES
1. [New issue] {}.update(b=1) -> TypeError
http://ironpython.codeplex.com/workitem/34742
User pekkaklarck has proposed the issue:
"It seems b is a somewhat special argument for dict.update:
IronPython 2.7.3 (2.7.0.40) on .NET 4.0.30319.18052 (32-bit)
Type "help", "copyright", "credits" or "license" for more information.
>>> d = {}
>>> d.update(a=1)
>>> d.update(a=2, c=3)
>>> d.update({}, a=3)
>>> d
{'c': 3, 'a': 3}
>>> d.update(b=1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: Multiple targets could match: update(object), update(object, dict), u
pdate(dict)
>>> d.update(a=1, b=2)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: expected dict, got int
>>> d.update({}, b=1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: update() takes at most 1 argument (2 given)
Otherwise using b as a key isn't an issue:
>>> d = dict(b=1)
>>> d.update({'b': 2})
>>> d
{'b': 2}
"
----------------------------------------------
----------------------------------------------
You are receiving this email because you subscribed to notifications on CodePlex.
To report a bug, request a feature, or add a comment, visit IronPython Issue Tracker. You can unsubscribe or change your issue notification settings on CodePlex.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20131217/36b04947/attachment.html>
More information about the Ironpython-users
mailing list