Commit a0ad4c94 authored by Jason R. Coombs's avatar Jason R. Coombs

Rewrite init/loop/extend as dual-for generator expression.

parent fc28df6e
......@@ -187,14 +187,14 @@ class build_py(orig.build_py, Mixin2to3):
self.exclude_package_data.get('', [])
+ self.exclude_package_data.get(package, [])
)
bad = []
for pattern in globs:
bad.extend(
fnmatch.filter(
files, os.path.join(src_dir, convert_path(pattern))
)
bad = dict.fromkeys(
item
for pattern in globs
for item in fnmatch.filter(
files,
os.path.join(src_dir, convert_path(pattern)),
)
bad = dict.fromkeys(bad)
)
seen = {}
return [
f for f in files if f not in bad
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment