From: gotoken@... (GOTO Kentaro) Date: 2001-03-06T19:54:22+09:00 Subject: [ruby-talk:12115] Re: NaN, Infinity (Bug?) In message "[ruby-talk:12112] NaN, Infinity (Bug?)" on 01/03/06, Tammo Freese writes: >After the Pickaxe Book, first print, p. 320 >a = -1.0 -> -1.0 >a.nan? -> false >a = Math.log(a) -> NaN >a.nan? -> true > >But testing (ruby 1.6.2 (2000-12-18) [i386-cygwin]) >-1.0 >false >-Infinity >false I've got: $ ruby -ve 'p [(x = Math::log(-1.0)), x.nan?]' ruby 1.6.2 (2000-12-13) [i386-freebsdelf4.1] [NaN, true] >Is this a defect or an error in the pickaxe book? The problem is in interpreter-binary or dll, IMHO. -- Gotoken