Math.tanh is wrong
------------------

                 Key: JRUBY-1591
                 URL: http://jira.codehaus.org/browse/JRUBY-1591
             Project: JRuby
          Issue Type: Bug
          Components: Core Classes/Modules
    Affects Versions: JRuby 1.x
         Environment: Ubuntu Linux 7.10,
ruby 1.8.5 (2007-11-20 rev 4842) [i386-jruby1.1b1]
            Reporter: Vladimir Sizikov


In MRI: Math.tanh(1.0/0.0) => 1.0

In JRuby: Math.tanh 1.0/0.0 => NaN

This problem is detected by Rubinius spec tests:

Math.tanh returns the hyperbolic tangent of the argument FAILED
Expected NaN to equal 1.0:
/opt/work/rubinius/spec/mini_rspec.rb:217:in `=='
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:12:in `=='
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:9:in `it'
/opt/work/rubinius/spec/mini_rspec.rb:403:in `it'
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:9:in `it'
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:9:in `describe'
/opt/work/rubinius/spec/mini_rspec.rb:399:in `describe'
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:4:in `describe'
/opt/work/rubinius/./spec/core/math/tanh_spec.rb:4:in `load'
last_mspec.rb:11:in `load'
last_mspec.rb:1:in `each'
last_mspec.rb:6:in `each


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to