Module: wine Branch: master Commit: 38666006cb1fa0abe44687ede02e692bd37ed226 URL: https://source.winehq.org/git/wine.git/?a=commit;h=38666006cb1fa0abe44687ede...
Author: Piotr Caban piotr@codeweavers.com Date: Thu Dec 26 18:30:58 2019 +0100
msvcr90/tests: Improve floats comparison in _atoflt tests.
Signed-off-by: Piotr Caban piotr@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/msvcr90/tests/msvcr90.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/dlls/msvcr90/tests/msvcr90.c b/dlls/msvcr90/tests/msvcr90.c index 9bdaa1e3bd..9e7d280cf8 100644 --- a/dlls/msvcr90/tests/msvcr90.c +++ b/dlls/msvcr90/tests/msvcr90.c @@ -234,11 +234,6 @@ static int cb_called[4]; static int g_qsort_s_context_counter; static int g_bsearch_s_context_counter;
-static inline int almost_equal_f(float f1, float f2) -{ - return f1-f2 > -1e-30 && f1-f2 < 1e-30; -} - /* ########## */
/* thiscall emulation */ @@ -1009,7 +1004,7 @@ if (0) _atoflt_testdata[i].ret, _atoflt_testdata[i].str);
if (ret == 0) - ok(almost_equal_f(flt.f, _atoflt_testdata[i].flt), "got %f, expected %f, for %s\n", flt.f, + ok(flt.f == _atoflt_testdata[i].flt, "got %f, expected %f, for %s\n", flt.f, _atoflt_testdata[i].flt, _atoflt_testdata[i].str);
i++;