This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
numeric.c: Add #error case
authorKarl Williamson <khw@cpan.org>
Sun, 5 May 2019 16:03:01 +0000 (10:03 -0600)
committerKarl Williamson <khw@cpan.org>
Fri, 24 May 2019 23:09:29 +0000 (17:09 -0600)
It's best to have a #error case when nothing in the #if #else series is
true, as it catches the problem at compile time.

numeric.c

index d4e3493..5d2fc5c 100644 (file)
--- a/numeric.c
+++ b/numeric.c
@@ -66,6 +66,8 @@ S_strtod(pTHX_ const char * const s, char ** e)
 
     result = strtod(s, e);
 
+#  else
+#    error No strtod() equivalent found
 #  endif
 
     RESTORE_LC_NUMERIC();