This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
POSIX math: isunordered emulation was all broken.
authorJarkko Hietaniemi <jhi@iki.fi>
Wed, 3 Sep 2014 11:00:31 +0000 (07:00 -0400)
committerJarkko Hietaniemi <jhi@iki.fi>
Wed, 3 Sep 2014 11:53:47 +0000 (07:53 -0400)
ext/POSIX/POSIX.xs

index 38fdc62..859ac4c 100644 (file)
 #    define c99_trunc  trunc
 #  endif
 
-#  if !defined(isunordered) && defined(Perl_isnan)
-#    define isunordered(x, y) (Perl_isnan(x) || Perl-isnan(y))
-#  elsif defined(HAS_UNORDERED)
-#    define isunordered(x, y) unordered(x, y)
+#  ifndef isunordered
+#    ifdef Perl_isnan
+#      define isunordered(x, y) (Perl_isnan(x) || Perl_isnan(y))
+#    elif defined(HAS_UNORDERED)
+#      define isunordered(x, y) unordered(x, y)
+#    endif
 #  endif
 
 #  if !defined(isgreater) && defined(isunordered)