mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-22 21:32:31 +00:00
Improve Python tree-shaking
This commit is contained in:
parent
5bb2275788
commit
4f41f2184d
169 changed files with 4182 additions and 2411 deletions
5
third_party/python/Lib/distutils/util.py
vendored
5
third_party/python/Lib/distutils/util.py
vendored
|
@ -488,7 +488,10 @@ def run_2to3(files, fixer_names=None, options=None, explicit=None):
|
|||
return
|
||||
|
||||
# Make this class local, to delay import of 2to3
|
||||
from lib2to3.refactor import RefactoringTool, get_fixers_from_package
|
||||
try:
|
||||
from lib2to3.refactor import RefactoringTool, get_fixers_from_package
|
||||
except ImportError:
|
||||
raise
|
||||
class DistutilsRefactoringTool(RefactoringTool):
|
||||
def log_error(self, msg, *args, **kw):
|
||||
log.error(msg, *args)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue