[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
cbrt test failure on Win32/MSVC
From: |
John W. Eaton |
Subject: |
cbrt test failure on Win32/MSVC |
Date: |
Fri, 21 Oct 2011 13:05:12 -0400 |
On 21-Oct-2011, Michael Goffioul wrote:
| While analyzing test failures under Win32/MSVC I found that cbtr(0) ->
| NaN. while the expected value is 0. MSVC does not provide cbrt
| implementation, so the octave implementation is used, but that
| implementation definitely returns NaN when the argument is 0 (because
| it computes 0/0). Shouldn't the test be changed, as it's weird to have
| a test that is known to fail when using octave's own code?
I guess something should be fixed, but I'm not sure it is the test. I
didn't even know we had a cbrt function and I had to think for a
moment about what it is. Ah, Jaroslav added. Maybe you can get him
to fix the replacement code? :-/
It looks like gnulib has some tests for cbrt but does not provide a
replacement function even though it seems to acknowledge that it is
not present on all systems. It looks like glibc provides a version of
cbrt that we could probably use. It would be nice to have it as a
gnulib module, but if not that, then maybe we could at least use the
code directly in Octave.
jwe