diff options
author | mischarf | 2008-12-14 03:42:39 +0000 |
---|---|---|
committer | mischarf | 2008-12-14 03:42:39 +0000 |
commit | 48fd445e1d217ef9e0b39dbd93ac98c65bc60d9b (patch) | |
tree | e4bc60dd42f8103a04ed03131e2d6775a1626304 /plugins | |
parent | b58489abb19e8186cdcf8bfe592751afaf6a474a (diff) | |
download | org.eclipse.tcf-48fd445e1d217ef9e0b39dbd93ac98c65bc60d9b.tar.gz org.eclipse.tcf-48fd445e1d217ef9e0b39dbd93ac98c65bc60d9b.tar.xz org.eclipse.tcf-48fd445e1d217ef9e0b39dbd93ac98c65bc60d9b.zip |
fixed parsing of floating point numbers
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/org.eclipse.tm.tcf/src/org/eclipse/tm/tcf/protocol/JSON.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/org.eclipse.tm.tcf/src/org/eclipse/tm/tcf/protocol/JSON.java b/plugins/org.eclipse.tm.tcf/src/org/eclipse/tm/tcf/protocol/JSON.java index e73be7976..88c1da7a2 100644 --- a/plugins/org.eclipse.tm.tcf/src/org/eclipse/tm/tcf/protocol/JSON.java +++ b/plugins/org.eclipse.tm.tcf/src/org/eclipse/tm/tcf/protocol/JSON.java @@ -208,7 +208,9 @@ public final class JSON { read(); } } - return new BigDecimal(val, scale - fraction); + // the scale is <tt>(unscaledVal × 10<sup>-scale</sup>)</tt>. + // the negative power!?! + return new BigDecimal(val, fraction - scale); } private static Object readNestedObject() throws IOException { |