Skip to content

Commit

Permalink
Extract 'roots' variable.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Aug 3, 2022
1 parent f700a6b commit 107c6cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions distutils/unixccompiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -388,11 +388,11 @@ def find_library_file(self, dirs, lib, debug=0):
for type in 'dylib xcode_stub shared static'.split()
)

roots = map(self._library_root, dirs)

searched = (
os.path.join(root, lib_name)
for root, lib_name in itertools.product(
map(self._library_root, dirs), lib_names
)
for root, lib_name in itertools.product(roots, lib_names)
)

found = filter(os.path.exists, searched)
Expand Down

0 comments on commit 107c6cf

Please sign in to comment.