Commit a40e443f by Steven G. Kargl

arith.c (gfc_check_integer_range): Disable range checking via -fno-range-check.

2006-09-28  Steven G. Kargl  <kargl@gcc.gnu.org>

	fortran/29147
	* arith.c (gfc_check_integer_range): Disable range checking via
	-fno-range-check.

From-SVN: r117297
parent 67796c1f
2006-09-28 Steven G. Kargl <kargl@gcc.gnu.org>
fortran/29147
* arith.c (gfc_check_integer_range): Disable range checking via
-fno-range-check.
2006-09-28 Steven G. Kargl <kargl@gcc.gnu.org> 2006-09-28 Steven G. Kargl <kargl@gcc.gnu.org>
* arith.c: Change conditional test for inclusion of arctangent(). * arith.c: Change conditional test for inclusion of arctangent().
......
...@@ -351,6 +351,10 @@ gfc_check_integer_range (mpz_t p, int kind) ...@@ -351,6 +351,10 @@ gfc_check_integer_range (mpz_t p, int kind)
result = ARITH_ASYMMETRIC; result = ARITH_ASYMMETRIC;
} }
if (gfc_option.flag_range_check == 0)
return result;
if (mpz_cmp (p, gfc_integer_kinds[i].min_int) < 0 if (mpz_cmp (p, gfc_integer_kinds[i].min_int) < 0
|| mpz_cmp (p, gfc_integer_kinds[i].huge) > 0) || mpz_cmp (p, gfc_integer_kinds[i].huge) > 0)
result = ARITH_OVERFLOW; result = ARITH_OVERFLOW;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment