From 5c973d07ee28739ea036f68ef5af1feee48990d0 Mon Sep 17 00:00:00 2001 From: Marco Bodrato Date: Thu, 17 Sep 2020 12:00:00 +0200 Subject: tests/mpf/reuse.c: Check index, not function. Allows make check with CC=tcc --disable-assembly --- tests/mpf/reuse.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/mpf/reuse.c b/tests/mpf/reuse.c index 6e6d0c374..86db5b399 100644 --- a/tests/mpf/reuse.c +++ b/tests/mpf/reuse.c @@ -150,7 +150,7 @@ main (int argc, char **argv) unsigned long this_in2i = in2i; /* Don't divide by 0. */ - if (dsi_funcs[i] == mpf_div_ui && this_in2i == 0) + if (i == 0 && this_in2i == 0) /* dsi_funcs[i] == mpf_div_ui */ continue; /* Avoid overflow/underflow in the exponent. */ @@ -173,7 +173,7 @@ main (int argc, char **argv) for (i = 0; i < sizeof (dis_funcs) / sizeof (dis_func); i++) { /* Don't divide by 0. */ - if (dis_funcs[i] == mpf_ui_div + if (i == 0 /* dis_funcs[i] == mpf_ui_div */ && mpf_cmp_ui (in2, 0) == 0) continue; -- cgit v1.2.1