diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-05-01 09:42:38 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-05-01 09:42:38 +0000 |
commit | fedf48986da718580062d081dda38c4ee182c254 (patch) | |
tree | 65e06d76c544a8d80296d686bf88ec3af41fdc50 /numeric.c | |
parent | acbb1c943457d3b8802f099ee0e34331bc78bd38 (diff) | |
download | ruby-fedf48986da718580062d081dda38c4ee182c254.tar.gz |
2000-05-01
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@678 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'numeric.c')
-rw-r--r-- | numeric.c | 14 |
1 files changed, 5 insertions, 9 deletions
@@ -1,4 +1,4 @@ -/************************************************ +/********************************************************************** numeric.c - @@ -8,12 +8,12 @@ Copyright (C) 1993-2000 Yukihiro Matsumoto -************************************************/ +**********************************************************************/ #include "ruby.h" #include <math.h> #include <stdio.h> -#if defined(FreeBSD) && __FreeBSD_version < 400012 +#if defined(__FreeBSD__) && __FreeBSD__ < 4 #include <floatingpoint.h> #endif @@ -28,10 +28,6 @@ VALUE rb_cFixnum; VALUE rb_eZeroDivError; VALUE rb_eFloatDomainError; -ID rb_frame_last_func(); -VALUE rb_float_new(); -double rb_big2dbl(); - void rb_num_zerodiv() { @@ -1451,7 +1447,7 @@ fix_zero_p(num) void Init_Numeric() { -#if defined(FreeBSD) && __FreeBSD_version < 400012 +#if defined(__FreeBSD__) && __FreeBSD__ < 4 /* allow divide by zero -- Inf */ fpsetmask(fpgetmask() & ~(FP_X_DZ|FP_X_INV|FP_X_OFL)); #endif @@ -1459,7 +1455,7 @@ Init_Numeric() to_i = rb_intern("to_i"); rb_eZeroDivError = rb_define_class("ZeroDivisionError", rb_eStandardError); - rb_eFloatDomainError = rb_define_class("FloatDomainError", rb_eStandardError); + rb_eFloatDomainError = rb_define_class("FloatDomainError", rb_eRangeError); rb_cNumeric = rb_define_class("Numeric", rb_cObject); rb_include_module(rb_cNumeric, rb_mComparable); |