diff options
author | Takayuki Shimizukawa <shimizukawa@gmail.com> | 2014-04-30 23:25:44 +0900 |
---|---|---|
committer | Takayuki Shimizukawa <shimizukawa@gmail.com> | 2014-04-30 23:25:44 +0900 |
commit | 2d1549b35a4adea66aebd0b7d9266731dd7ece6f (patch) | |
tree | 7f82f3e5a85f1946276416a44272b6860c355d4a /sphinx/ext/autosummary/generate.py | |
parent | 6ae3b68859562f07a1a7e215a7b55dce800305a9 (diff) | |
download | sphinx-git-2d1549b35a4adea66aebd0b7d9266731dd7ece6f.tar.gz |
wrap py3 iterators with list() for each places that expect a list object. refs #1350.
Diffstat (limited to 'sphinx/ext/autosummary/generate.py')
-rw-r--r-- | sphinx/ext/autosummary/generate.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/sphinx/ext/autosummary/generate.py b/sphinx/ext/autosummary/generate.py index 5daf95f5b..7b7c0707d 100644 --- a/sphinx/ext/autosummary/generate.py +++ b/sphinx/ext/autosummary/generate.py @@ -110,14 +110,11 @@ def generate_autosummary_docs(sources, output_dir=None, suffix='.rst', # read items = find_autosummary_in_files(sources) - # remove possible duplicates - items = dict([(item, True) for item in items]).keys() - # keep track of new files new_files = [] # write - for name, path, template_name in sorted(items, key=str): + for name, path, template_name in sorted(set(items), key=str): if path is None: # The corresponding autosummary:: directive did not have # a :toctree: option |