summaryrefslogtreecommitdiff
path: root/numeric.c
diff options
context:
space:
mode:
Diffstat (limited to 'numeric.c')
-rw-r--r--numeric.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/numeric.c b/numeric.c
index cd49ec2be9..7881531340 100644
--- a/numeric.c
+++ b/numeric.c
@@ -2081,6 +2081,10 @@ fix_minus(VALUE x, VALUE y)
}
}
+#define SQRT_LONG_MAX ((SIGNED_VALUE)1<<((SIZEOF_LONG*CHAR_BIT-1)/2))
+/*tests if N*N would overflow*/
+#define FIT_SQRT_LONG(n) (((n)<SQRT_LONG_MAX)&&((n)>=-SQRT_LONG_MAX))
+
/*
* call-seq:
* fix * numeric => numeric_result
@@ -2090,10 +2094,6 @@ fix_minus(VALUE x, VALUE y)
* result.
*/
-#define SQRT_LONG_MAX ((SIGNED_VALUE)1<<((SIZEOF_LONG*CHAR_BIT-1)/2))
-/*tests if N*N would overflow*/
-#define FIT_SQRT_LONG(n) (((n)<SQRT_LONG_MAX)&&((n)>=-SQRT_LONG_MAX))
-
static VALUE
fix_mul(VALUE x, VALUE y)
{