##// END OF EJS Templates
formatter: convert float value to json...
Yuya Nishihara -
r22476:a0829ec3 default
parent child Browse files
Show More
@@ -91,8 +91,8 b' class pickleformatter(baseformatter):'
91 91 def _jsonifyobj(v):
92 92 if isinstance(v, tuple):
93 93 return '[' + ', '.join(_jsonifyobj(e) for e in v) + ']'
94 elif isinstance(v, int):
95 return '%d' % v
94 elif isinstance(v, (int, float)):
95 return str(v)
96 96 else:
97 97 return '"%s"' % encoding.jsonescape(v)
98 98
General Comments 0
You need to be logged in to leave comments. Login now