mirror of
https://github.com/python/cpython.git
synced 2025-07-19 01:05:26 +00:00
Kill execfile(), use exec() instead
This commit is contained in:
parent
41eaedd361
commit
016880229a
98 changed files with 179 additions and 341 deletions
7
setup.py
7
setup.py
|
@ -1369,7 +1369,12 @@ class PyBuildExt(build_ext):
|
|||
return False
|
||||
|
||||
fficonfig = {}
|
||||
execfile(ffi_configfile, globals(), fficonfig)
|
||||
fp = open(ffi_configfile)
|
||||
try:
|
||||
script = fp.read()
|
||||
finally:
|
||||
fp.close()
|
||||
exec(script, globals(), fficonfig)
|
||||
ffi_srcdir = os.path.join(fficonfig['ffi_srcdir'], 'src')
|
||||
|
||||
# Add .S (preprocessed assembly) to C compiler source extensions.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue