Bug 47198 - -0.0 equals 0.0 in Excel, but not in POI
-0.0 equals 0.0 in Excel, but not in POI
Status: RESOLVED FIXED
Product: POI
Classification: Unclassified
Component: HSSF
3.5-dev
PC Windows XP
: P2 major (vote)
: ---
Assigned To: POI Developers List
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2009-05-15 04:55 UTC by Torbjørn G. Dahle
Modified: 2009-05-21 23:27 UTC (History)
0 users



Attachments
Test case XLS demonstrates error when parsed (17.00 KB, application/vnd.ms-excel)
2009-05-15 04:55 UTC, Torbjørn G. Dahle
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Torbjørn G. Dahle 2009-05-15 04:55:35 UTC
Created attachment 23664 [details]
Test case XLS demonstrates error when parsed

When opening the attached file in Excel 2007, 0.0 is evaluated to be equal to both 0.0 and -0.0. However, in POI, 0.0 and -0.0 are not equal. This causes IF to make the wrong decision.

When parsing the file in POI, I get true for the first comparison, false for the second.
Comment 1 Josh Micich 2009-05-21 23:27:02 UTC
Nicely spotted.

fixed in svn r777392

junit added