mirror of
https://github.com/python/cpython.git
synced 2025-08-01 07:33:08 +00:00
Automatic conversion of floats to integers for struct.pack integer codes
is deprecated. Use an explicit int() instead.
This commit is contained in:
parent
6c0b872f85
commit
9be2697fb6
1 changed files with 1 additions and 1 deletions
|
@ -57,7 +57,7 @@ def compile_dir(dir, maxlevels=10, ddir=None,
|
||||||
if tail == '.py':
|
if tail == '.py':
|
||||||
if not force:
|
if not force:
|
||||||
try:
|
try:
|
||||||
mtime = os.stat(fullname).st_mtime
|
mtime = int(os.stat(fullname).st_mtime)
|
||||||
expect = struct.pack('<4sl', imp.get_magic(), mtime)
|
expect = struct.pack('<4sl', imp.get_magic(), mtime)
|
||||||
cfile = fullname + (__debug__ and 'c' or 'o')
|
cfile = fullname + (__debug__ and 'c' or 'o')
|
||||||
with open(cfile, 'rb') as chandle:
|
with open(cfile, 'rb') as chandle:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue