projects
/
tools
/
apitrace.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2af485a
)
Preserve floating point precision in JSON output.
author
José Fonseca
<jose.r.fonseca@gmail.com>
Fri, 15 Apr 2011 22:49:16 +0000
(23:49 +0100)
committer
José Fonseca
<jose.r.fonseca@gmail.com>
Fri, 15 Apr 2011 22:49:16 +0000
(23:49 +0100)
json.hpp
patch
|
blob
|
history
diff --git
a/json.hpp
b/json.hpp
index
ee2a9e0
..
24d9c87
100644
(file)
--- a/
json.hpp
+++ b/
json.hpp
@@
-295,7
+295,7
@@
public:
template<class T>
inline void writeNumber(T n) {
separator();
- os << std::dec << n;
+ os << std::dec <<
std::setprecision(9) <<
n;
value = true;
space = ' ';
}