[New-bugs-announce] [issue27220] Add a pure Python version of 'collections.defaultdict'

Emanuel Barry report at bugs.python.org
Sat Jun 4 13:07:44 EDT 2016


New submission from Emanuel Barry:

Attached patch adds a pure Python version of `collections.defaultdict`. This is yet another step in providing better support for alternate implementations, which may or may not have `_collections`.

I also went ahead and fixed __all__ so that `from collections import *` doesn't fail if 'deque' isn't present (which it may not be in alternate implementations).

Patch includes (small) doc and test changes. All tests pass successfully for both versions.

----------
components: Library (Lib)
files: py_defaultdict_1.patch
keywords: patch
messages: 267276
nosy: ebarry, rhettinger
priority: normal
severity: normal
stage: patch review
status: open
title: Add a pure Python version of 'collections.defaultdict'
type: enhancement
versions: Python 3.6
Added file: http://bugs.python.org/file43200/py_defaultdict_1.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue27220>
_______________________________________


More information about the New-bugs-announce mailing list