Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
898d51da
Commit
898d51da
authored
May 21, 2012
by
Ezio Melotti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#14875: Use float('inf') instead of float('1e66666') in the json module.
parent
dfa46524
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
+3
-2
Lib/json/encoder.py
Lib/json/encoder.py
+1
-2
Misc/NEWS
Misc/NEWS
+2
-0
No files found.
Lib/json/encoder.py
View file @
898d51da
...
...
@@ -27,8 +27,7 @@ for i in range(0x20):
ESCAPE_DCT.setdefault(chr(i), '
\\
u
{
0
:
04
x
}
'.format(i))
#ESCAPE_DCT.setdefault(chr(i), '
\\
u
%
04
x
' % (i,))
# Assume this produces an infinity on all machines (probably not guaranteed)
INFINITY = float('
1e66666
')
INFINITY = float('
inf
')
FLOAT_REPR = repr
def encode_basestring(s):
...
...
Misc/NEWS
View file @
898d51da
...
...
@@ -67,6 +67,8 @@ Core and Builtins
Library
-------
- Issue #14875: Use float('inf') instead of float('1e66666') in the json module.
- Issue #14426: Correct the Date format in Expires attribute of Set-Cookie
Header in Cookie.py.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment