mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
Whitespace normalization.
This commit is contained in:
parent
bc1c7a0854
commit
83e7ccc9fd
5 changed files with 7 additions and 8 deletions
|
@ -967,7 +967,7 @@ def formatdate(timeval=None):
|
||||||
timeval[2],
|
timeval[2],
|
||||||
["Jan", "Feb", "Mar", "Apr", "May", "Jun",
|
["Jan", "Feb", "Mar", "Apr", "May", "Jun",
|
||||||
"Jul", "Aug", "Sep", "Oct", "Nov", "Dec"][timeval[1]-1],
|
"Jul", "Aug", "Sep", "Oct", "Nov", "Dec"][timeval[1]-1],
|
||||||
timeval[0], timeval[3], timeval[4], timeval[5])
|
timeval[0], timeval[3], timeval[4], timeval[5])
|
||||||
|
|
||||||
|
|
||||||
# When used as script, run a small test program.
|
# When used as script, run a small test program.
|
||||||
|
|
|
@ -357,7 +357,7 @@ def test_float_overflow():
|
||||||
"math.sqrt(huge)", "math.sqrt(mhuge)", # should do better
|
"math.sqrt(huge)", "math.sqrt(mhuge)", # should do better
|
||||||
"math.log10(huge)", "math.log10(mhuge)", # should do better
|
"math.log10(huge)", "math.log10(mhuge)", # should do better
|
||||||
"math.floor(huge)", "math.floor(mhuge)"]:
|
"math.floor(huge)", "math.floor(mhuge)"]:
|
||||||
|
|
||||||
try:
|
try:
|
||||||
eval(test, namespace)
|
eval(test, namespace)
|
||||||
except OverflowError:
|
except OverflowError:
|
||||||
|
|
|
@ -118,4 +118,3 @@ for i in range(-10, 11):
|
||||||
o = pow(long(i),j) % k
|
o = pow(long(i),j) % k
|
||||||
n = pow(long(i),j,k)
|
n = pow(long(i),j,k)
|
||||||
if o != n: print 'Integer mismatch:', i,j,k
|
if o != n: print 'Integer mismatch:', i,j,k
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ if fname[1:2] == ":":
|
||||||
# And more hacking to get it to work on MacOS. This assumes
|
# And more hacking to get it to work on MacOS. This assumes
|
||||||
# urllib.pathname2url works, unfortunately...
|
# urllib.pathname2url works, unfortunately...
|
||||||
if os.name == 'mac':
|
if os.name == 'mac':
|
||||||
fname = '/' + fname.replace(':', '/')
|
fname = '/' + fname.replace(':', '/')
|
||||||
file_url = "file://%s" % fname
|
file_url = "file://%s" % fname
|
||||||
f = urllib2.urlopen(file_url)
|
f = urllib2.urlopen(file_url)
|
||||||
|
|
||||||
|
|
|
@ -230,10 +230,10 @@ def process(file, list):
|
||||||
print "*** Bad warning for line %d:" % row, bad
|
print "*** Bad warning for line %d:" % row, bad
|
||||||
print "*", line
|
print "*", line
|
||||||
elif intlong and not floatcomplex:
|
elif intlong and not floatcomplex:
|
||||||
print "%dc%d" % (row, row)
|
print "%dc%d" % (row, row)
|
||||||
print "<", line
|
print "<", line
|
||||||
print "---"
|
print "---"
|
||||||
print ">", line[:col] + "/" + line[col:]
|
print ">", line[:col] + "/" + line[col:]
|
||||||
elif floatcomplex and not intlong:
|
elif floatcomplex and not intlong:
|
||||||
print "True division / operator at line %d:" % row
|
print "True division / operator at line %d:" % row
|
||||||
print "=", line
|
print "=", line
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue