From: matz@... (Yukihiro Matsumoto) Date: 2002-06-25T23:23:28+09:00 Subject: Re: No exceptions from String#to_i Hi, In message "Re: No exceptions from String#to_i" on 02/06/25, Nikodemus Siivola writes: |> respectively [ruby-talk:43014], and Float() raises error if to_f |> return NaN? | |Sounds decent, but isn't NaN technically a float? Also, since code that |handles floats should also be able to handle NaNs, it might be simpler to |just pass it along. Having it raise an error means that in some cases |there will have to be handling for both the exception from Float() and |handling for NaNs in general. Good point. Hmm... |Also, why handle Float() differently? If because there is no to_flt as of |yet, then that holds for to_int as well... ;) Mostly because I didn't see cases "to_flt" is useful. matz.