]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.6] bpo-34320: Fix dict(o) didn't copy order of dict subclass (GH-8624) (GH-9583)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 26 Sep 2018 06:38:36 +0000 (23:38 -0700)
committerGitHub <noreply@github.com>
Wed, 26 Sep 2018 06:38:36 +0000 (23:38 -0700)
commitd45a9613402b686f8afd3dd5b6acf8141f14d711
treeec99aa32aba5b44f7200e409679dd547cca1b3d6
parentdc335ae77dfc1fb6a500eb1cd0baf23fcda45434
[3.6] bpo-34320: Fix dict(o) didn't copy order of dict subclass (GH-8624) (GH-9583)

When dict subclass overrides order (`__iter__()`, `keys()`, and `items()`), `dict(o)`
should use it instead of dict ordering.

https://bugs.python.org/issue34320
(cherry picked from commit 2aaf98c16ae3070378de523a173e29644037d8bd)

Co-authored-by: INADA Naoki <methane@users.noreply.github.com>
https://bugs.python.org/issue34320
Lib/test/test_builtin.py
Lib/test/test_call.py
Lib/test/test_dict.py
Misc/NEWS.d/next/Core and Builtins/2018-08-02-22-34-59.bpo-34320.hNshAA.rst [new file with mode: 0644]
Objects/dictobject.c