diff options
author | Edward Welbourne <edward.welbourne@qt.io> | 2019-04-01 15:22:15 +0200 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2019-04-01 14:40:14 +0000 |
commit | 954b73445cfbfef01207d51d1b986c6dd796c6d0 (patch) | |
tree | ceaf9a26c330f96a795292d1620d1827144ae070 /tests/auto/gui/image/qpixmap | |
parent | e4532224145a0a72cde9b40cb7fd39011624d1c1 (diff) | |
download | qtbase-954b73445cfbfef01207d51d1b986c6dd796c6d0.tar.gz |
Refine underflow check in QLocaleData::convertDoubleToFloat()
A string can parse as a non-zero double that's smaller than the
smallest float yet be a faithful representation of the smallest float.
So rather than testing for non-zero doubles less than the smallest
float, test for non-zero doubles that cast to float zero; these
underflow. This means small values close below the smallest float
shall round up to it, rather than down to zero, requiring a tweak to
an existing test. Added a test for the boundary case (and tidied the
test data).
Fixes: QTBUG-74833
Change-Id: I4cb30b3c0e54683574b98253505607caaf88fbfb
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'tests/auto/gui/image/qpixmap')
0 files changed, 0 insertions, 0 deletions