cpython/Lib/lib2to3
Michael Selik 11fa3c7cd1 bpo-29957: change LBYL key lookup to dict.setdefault (#938)
* change LBYL key lookup to dict.setdefault

The ``results`` was constructed as a defaultdict and we could simply
delete the check ``if key not in results``. However, I think it's safer
to use dict.setdefault as I'm not sure whether the caller expects a
regular dict or defaultdict.

* add name to the acknowledgements file

* use defaultdict to make the key-lookup cleaner
2017-04-01 23:02:31 -07:00
..
fixes Remove the debug print that i accidentally left in. 2016-09-10 20:39:50 -07:00
pgen2 bpo-29919: Remove unused imports found by pyflakes (#137) 2017-03-27 16:05:26 +02:00
tests Remove unused imports. 2016-12-16 20:00:15 +02:00
__init__.py
__main__.py Merged revisions 88535 via svnmerge from 2011-02-24 01:41:46 +00:00
btm_matcher.py bpo-29957: change LBYL key lookup to dict.setdefault (#938) 2017-04-01 23:02:31 -07:00
btm_utils.py Issue #27076: Doc, comment and tests spelling fixes 2016-05-26 05:35:26 +00:00
fixer_base.py rm unused import 2016-12-05 22:30:55 -08:00
fixer_util.py Removed unused imports. 2016-04-25 00:12:32 +03:00
Grammar.txt Issue #28394: Merge typo fixes from 3.5 into 3.6 2016-10-10 00:28:38 +00:00
main.py Issue #22173: Update lib2to3 tests to use unittest test discovery. 2014-10-29 12:24:59 -05:00
patcomp.py Issue #27076: Doc, comment and tests spelling fixes 2016-05-26 05:35:26 +00:00
PatternGrammar.txt
pygram.py Merged revisions 85510 via svnmerge from 2010-10-14 23:03:32 +00:00
pytree.py bpo-29776: Use decorator syntax for properties. (#585) 2017-03-19 08:40:32 +02:00
refactor.py Remove legacy "from __future__ import with_statement" lines. 2016-09-08 13:47:41 -07:00