This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Change enum names for new locale function parameters
authorKarl Williamson <khw@cpan.org>
Thu, 8 Mar 2018 17:51:09 +0000 (10:51 -0700)
committerKarl Williamson <khw@cpan.org>
Mon, 12 Mar 2018 16:17:14 +0000 (10:17 -0600)
Earlier in the 5.27 series, I introduced Perl_langinfo which calls
the system nl_langinfo() on platforms that have it, and emulates it
otherwise.  For each enum parameter 'foo', I made an equivalent
parameter PERL_foo.  I did this so that no conflicts would arise if
any 'foo' were negative.  This is less than ideal to have to rename the
parameters.

In looking further, I realized that perl has always excluded the
possibility of negative values for 'foo', so my precaution is
unnecessary.  And before this new code is released is the time to fix up
the interface.

ext/XS-APItest/t/locale.t
locale.c
perl_langinfo.h
pod/perldelta.pod

index 441b90f..9d33832 100644 (file)
@@ -113,11 +113,11 @@ SKIP: {
     # For non-nl_langinfo systems, those values are arbitrary negative numbers
     # set in the header.  Otherwise they are the nl_langinfo approved values,
     # which for the moment is the item name.
-    # The relevant lines look like: #  define PERL_YESSTR -54
+    # The relevant lines look like: #  define YESSTR -54
     while (<$fh>) {
         chomp;
         next unless / - \d+ $ /x;
-        s/ ^ .* PERL_ //x;
+        s/ ^ \# \s* define \s*//x;
         m/ (.*) \  (.*) /x;
         $items{$1} = ($has_nl_langinfo)
                      ? $1       # Yields 'YESSTR'
index ca163cd..052f5ab 100644 (file)
--- a/locale.c
+++ b/locale.c
@@ -1259,7 +1259,7 @@ S_set_numeric_radix(pTHX_ const bool use_locale)
                                     || defined(HAS_NL_LANGINFO))
 
     const char * radix = (use_locale)
-                         ? my_nl_langinfo(PERL_RADIXCHAR, FALSE)
+                         ? my_nl_langinfo(RADIXCHAR, FALSE)
                                         /* FALSE => already in dest locale */
                          : ".";
 
@@ -1347,10 +1347,9 @@ S_new_numeric(pTHX_ const char *newnum)
     /* If its name isn't C nor POSIX, it could still be indistinguishable from
      * them */
     if (! PL_numeric_standard) {
-        PL_numeric_standard = cBOOL(strEQ(".", my_nl_langinfo(PERL_RADIXCHAR,
+        PL_numeric_standard = cBOOL(strEQ(".", my_nl_langinfo(RADIXCHAR,
                                             FALSE /* Don't toggle locale */  ))
-                                 && strEQ("",  my_nl_langinfo(PERL_THOUSEP,
-                                                              FALSE)));
+                                 && strEQ("",  my_nl_langinfo(THOUSEP, FALSE)));
     }
 
     /* Save the new name if it isn't the same as the previous one, if any */
@@ -1693,7 +1692,7 @@ S_new_ctype(pTHX_ const char *newctype)
 
             Perl_sv_catpvf(aTHX_ PL_warn_locale, "; codeset=%s",
                                     /* parameter FALSE is a don't care here */
-                                    my_nl_langinfo(PERL_CODESET, FALSE));
+                                    my_nl_langinfo(CODESET, FALSE));
 
 #  endif
 
@@ -2398,11 +2397,6 @@ before the C<perl.h> C<#include>.  You can replace your C<langinfo.h>
 C<#include> with this one.  (Doing it this way keeps out the symbols that plain
 C<langinfo.h> imports into the namespace for code that doesn't need it.)
 
-You also should not use the bare C<langinfo.h> item names, but should preface
-them with C<PERL_>, so use C<PERL_RADIXCHAR> instead of plain C<RADIXCHAR>.
-The C<PERL_I<foo>> versions will also work for this function on systems that do
-have a native C<nl_langinfo>.
-
 The original impetus for C<Perl_langinfo()> was so that code that needs to
 find out the current currency symbol, floating point radix character, or digit
 grouping separator can use, on all systems, the simpler and more
@@ -2437,7 +2431,7 @@ S_my_nl_langinfo(const int item, bool toggle)
 
     /* We only need to toggle into the underlying LC_NUMERIC locale for these
      * two items, and only if not already there */
-    if (toggle && ((   item != PERL_RADIXCHAR && item != PERL_THOUSEP)
+    if (toggle && ((   item != RADIXCHAR && item != THOUSEP)
                     || PL_numeric_underlying))
     {
         toggle = FALSE;
@@ -2511,10 +2505,10 @@ S_my_nl_langinfo(const int item, bool toggle)
 #  endif
 
     if (strEQ(retval, "")) {
-        if (item == PERL_YESSTR) {
+        if (item == YESSTR) {
             return "yes";
         }
-        if (item == PERL_NOSTR) {
+        if (item == NOSTR) {
             return "no";
         }
     }
@@ -2552,21 +2546,22 @@ S_my_nl_langinfo(const int item, bool toggle)
             Size_t len;
 
             /* These 2 are unimplemented */
-            case PERL_CODESET:
-            case PERL_ERA:      /* For use with strftime() %E modifier */
+            case CODESET:
+            case ERA:      /* For use with strftime() %E modifier */
 
             default:
                 return "";
 
             /* We use only an English set, since we don't know any more */
-            case PERL_YESEXPR:   return "^[+1yY]";
-            case PERL_YESSTR:    return "yes";
-            case PERL_NOEXPR:    return "^[-0nN]";
-            case PERL_NOSTR:     return "no";
+            case YESEXPR:   return "^[+1yY]";
+            case YESSTR:    return "yes";
+            case NOEXPR:    return "^[-0nN]";
+            case NOSTR:     return "no";
+
 
 #  ifdef HAS_LOCALECONV
 
-            case PERL_CRNCYSTR:
+            case CRNCYSTR:
 
                 /* We don't bother with localeconv_l() because any system that
                  * has it is likely to also have nl_langinfo() */
@@ -2602,8 +2597,8 @@ S_my_nl_langinfo(const int item, bool toggle)
                 LOCALE_UNLOCK;
                 break;
 
-            case PERL_RADIXCHAR:
-            case PERL_THOUSEP:
+            case RADIXCHAR:
+            case THOUSEP:
 
                 if (toggle) {
                     STORE_LC_NUMERIC_FORCE_TO_UNDERLYING();
@@ -2617,7 +2612,7 @@ S_my_nl_langinfo(const int item, bool toggle)
                     temp = "";
                 }
                 else {
-                    temp = (item == PERL_RADIXCHAR)
+                    temp = (item == RADIXCHAR)
                              ? lc->decimal_point
                              : lc->thousands_sep;
                     if (! temp) {
@@ -2645,30 +2640,26 @@ S_my_nl_langinfo(const int item, bool toggle)
              * for someone using them as formats (as opposed to trying to parse
              * them to figure out what the locale says).  The other format
              * items are actually tested to verify they work on the platform */
-            case PERL_D_FMT:         return "%x";
-            case PERL_T_FMT:         return "%X";
-            case PERL_D_T_FMT:       return "%c";
+            case D_FMT:         return "%x";
+            case T_FMT:         return "%X";
+            case D_T_FMT:       return "%c";
 
             /* These formats are only available in later strfmtime's */
-            case PERL_ERA_D_FMT: case PERL_ERA_T_FMT: case PERL_ERA_D_T_FMT:
-            case PERL_T_FMT_AMPM:
+            case ERA_D_FMT: case ERA_T_FMT: case ERA_D_T_FMT: case T_FMT_AMPM:
 
             /* The rest can be gotten from most versions of strftime(). */
-            case PERL_ABDAY_1: case PERL_ABDAY_2: case PERL_ABDAY_3:
-            case PERL_ABDAY_4: case PERL_ABDAY_5: case PERL_ABDAY_6:
-            case PERL_ABDAY_7:
-            case PERL_ALT_DIGITS:
-            case PERL_AM_STR: case PERL_PM_STR:
-            case PERL_ABMON_1: case PERL_ABMON_2: case PERL_ABMON_3:
-            case PERL_ABMON_4: case PERL_ABMON_5: case PERL_ABMON_6:
-            case PERL_ABMON_7: case PERL_ABMON_8: case PERL_ABMON_9:
-            case PERL_ABMON_10: case PERL_ABMON_11: case PERL_ABMON_12:
-            case PERL_DAY_1: case PERL_DAY_2: case PERL_DAY_3: case PERL_DAY_4:
-            case PERL_DAY_5: case PERL_DAY_6: case PERL_DAY_7:
-            case PERL_MON_1: case PERL_MON_2: case PERL_MON_3: case PERL_MON_4:
-            case PERL_MON_5: case PERL_MON_6: case PERL_MON_7: case PERL_MON_8:
-            case PERL_MON_9: case PERL_MON_10: case PERL_MON_11:
-            case PERL_MON_12:
+            case ABDAY_1: case ABDAY_2: case ABDAY_3:
+            case ABDAY_4: case ABDAY_5: case ABDAY_6: case ABDAY_7:
+            case ALT_DIGITS:
+            case AM_STR: case PM_STR:
+            case ABMON_1: case ABMON_2: case ABMON_3: case ABMON_4:
+            case ABMON_5: case ABMON_6: case ABMON_7: case ABMON_8:
+            case ABMON_9: case ABMON_10: case ABMON_11: case ABMON_12:
+            case DAY_1: case DAY_2: case DAY_3: case DAY_4:
+            case DAY_5: case DAY_6: case DAY_7:
+            case MON_1: case MON_2: case MON_3: case MON_4:
+            case MON_5: case MON_6: case MON_7: case MON_8:
+            case MON_9: case MON_10: case MON_11: case MON_12:
 
                 LOCALE_LOCK;
 
@@ -2687,82 +2678,82 @@ S_my_nl_langinfo(const int item, bool toggle)
                                        __FILE__, __LINE__, item);
                         NOT_REACHED; /* NOTREACHED */
 
-                    case PERL_PM_STR: tm.tm_hour = 18;
-                    case PERL_AM_STR:
+                    case PM_STR: tm.tm_hour = 18;
+                    case AM_STR:
                         format = "%p";
                         break;
 
-                    case PERL_ABDAY_7: tm.tm_wday++;
-                    case PERL_ABDAY_6: tm.tm_wday++;
-                    case PERL_ABDAY_5: tm.tm_wday++;
-                    case PERL_ABDAY_4: tm.tm_wday++;
-                    case PERL_ABDAY_3: tm.tm_wday++;
-                    case PERL_ABDAY_2: tm.tm_wday++;
-                    case PERL_ABDAY_1:
+                    case ABDAY_7: tm.tm_wday++;
+                    case ABDAY_6: tm.tm_wday++;
+                    case ABDAY_5: tm.tm_wday++;
+                    case ABDAY_4: tm.tm_wday++;
+                    case ABDAY_3: tm.tm_wday++;
+                    case ABDAY_2: tm.tm_wday++;
+                    case ABDAY_1:
                         format = "%a";
                         break;
 
-                    case PERL_DAY_7: tm.tm_wday++;
-                    case PERL_DAY_6: tm.tm_wday++;
-                    case PERL_DAY_5: tm.tm_wday++;
-                    case PERL_DAY_4: tm.tm_wday++;
-                    case PERL_DAY_3: tm.tm_wday++;
-                    case PERL_DAY_2: tm.tm_wday++;
-                    case PERL_DAY_1:
+                    case DAY_7: tm.tm_wday++;
+                    case DAY_6: tm.tm_wday++;
+                    case DAY_5: tm.tm_wday++;
+                    case DAY_4: tm.tm_wday++;
+                    case DAY_3: tm.tm_wday++;
+                    case DAY_2: tm.tm_wday++;
+                    case DAY_1:
                         format = "%A";
                         break;
 
-                    case PERL_ABMON_12: tm.tm_mon++;
-                    case PERL_ABMON_11: tm.tm_mon++;
-                    case PERL_ABMON_10: tm.tm_mon++;
-                    case PERL_ABMON_9: tm.tm_mon++;
-                    case PERL_ABMON_8: tm.tm_mon++;
-                    case PERL_ABMON_7: tm.tm_mon++;
-                    case PERL_ABMON_6: tm.tm_mon++;
-                    case PERL_ABMON_5: tm.tm_mon++;
-                    case PERL_ABMON_4: tm.tm_mon++;
-                    case PERL_ABMON_3: tm.tm_mon++;
-                    case PERL_ABMON_2: tm.tm_mon++;
-                    case PERL_ABMON_1:
+                    case ABMON_12: tm.tm_mon++;
+                    case ABMON_11: tm.tm_mon++;
+                    case ABMON_10: tm.tm_mon++;
+                    case ABMON_9: tm.tm_mon++;
+                    case ABMON_8: tm.tm_mon++;
+                    case ABMON_7: tm.tm_mon++;
+                    case ABMON_6: tm.tm_mon++;
+                    case ABMON_5: tm.tm_mon++;
+                    case ABMON_4: tm.tm_mon++;
+                    case ABMON_3: tm.tm_mon++;
+                    case ABMON_2: tm.tm_mon++;
+                    case ABMON_1:
                         format = "%b";
                         break;
 
-                    case PERL_MON_12: tm.tm_mon++;
-                    case PERL_MON_11: tm.tm_mon++;
-                    case PERL_MON_10: tm.tm_mon++;
-                    case PERL_MON_9: tm.tm_mon++;
-                    case PERL_MON_8: tm.tm_mon++;
-                    case PERL_MON_7: tm.tm_mon++;
-                    case PERL_MON_6: tm.tm_mon++;
-                    case PERL_MON_5: tm.tm_mon++;
-                    case PERL_MON_4: tm.tm_mon++;
-                    case PERL_MON_3: tm.tm_mon++;
-                    case PERL_MON_2: tm.tm_mon++;
-                    case PERL_MON_1:
+                    case MON_12: tm.tm_mon++;
+                    case MON_11: tm.tm_mon++;
+                    case MON_10: tm.tm_mon++;
+                    case MON_9: tm.tm_mon++;
+                    case MON_8: tm.tm_mon++;
+                    case MON_7: tm.tm_mon++;
+                    case MON_6: tm.tm_mon++;
+                    case MON_5: tm.tm_mon++;
+                    case MON_4: tm.tm_mon++;
+                    case MON_3: tm.tm_mon++;
+                    case MON_2: tm.tm_mon++;
+                    case MON_1:
                         format = "%B";
                         break;
 
-                    case PERL_T_FMT_AMPM:
+                    case T_FMT_AMPM:
                         format = "%r";
                         return_format = TRUE;
                         break;
 
-                    case PERL_ERA_D_FMT:
+                    case ERA_D_FMT:
                         format = "%Ex";
                         return_format = TRUE;
                         break;
 
-                    case PERL_ERA_T_FMT:
+                    case ERA_T_FMT:
                         format = "%EX";
                         return_format = TRUE;
                         break;
 
-                    case PERL_ERA_D_T_FMT:
+                    case ERA_D_T_FMT:
                         format = "%Ec";
                         return_format = TRUE;
                         break;
 
-                    case PERL_ALT_DIGITS:
+                    case ALT_DIGITS:
                         tm.tm_wday = 0;
                         format = "%Ow";        /* Find the alternate digit for 0 */
                         break;
@@ -2830,7 +2821,7 @@ S_my_nl_langinfo(const int item, bool toggle)
                  * alternate format for wday 0.  If the value is the same as
                  * the normal 0, there isn't an alternate, so clear the buffer.
                  * */
-                if (   item == PERL_ALT_DIGITS
+                if (   item == ALT_DIGITS
                     && strEQ(PL_langinfo_buf, "0"))
                 {
                     *PL_langinfo_buf = '\0';
@@ -4377,7 +4368,7 @@ Perl__is_cur_LC_category_utf8(pTHX_ int category)
              defective locale definition.  XXX We should probably check for
              these in the Latin1 range and warn (but on glibc, requires
              iswalnum() etc. due to their not handling 80-FF correctly */
-            const char *codeset = my_nl_langinfo(PERL_CODESET, FALSE);
+            const char *codeset = my_nl_langinfo(CODESET, FALSE);
                                           /* FALSE => already in dest locale */
 
             DEBUG_Lv(PerlIO_printf(Perl_debug_log,
@@ -4480,7 +4471,7 @@ Perl__is_cur_LC_category_utf8(pTHX_ int category)
                                                              save_input_locale);
             bool only_ascii = FALSE;
             const U8 * currency_string
-                            = (const U8 *) my_nl_langinfo(PERL_CRNCYSTR, FALSE);
+                            = (const U8 *) my_nl_langinfo(CRNCYSTR, FALSE);
                                       /* 2nd param not relevant for this item */
             const U8 * first_variant;
 
index cd6eb07..ff96b38 100644 (file)
 /* NOTE that this file is parsed by ext/XS-APItest/t/locale.t, so be careful
  * with changes */
 
-/* Define PERL_foo to 'foo' if it exists; a negative number otherwise.  The
- * negatives are to minimize the possibility of collisions on platforms that
- * define some but not all of these item names (though each name is required by
- * the 2008 POSIX specification) */
+/* If foo doesn't exist deine it to a negative number. */
 
-#ifdef CODESET
-#  define PERL_CODESET CODESET
-#else
-#  define PERL_CODESET -1
-#endif
-#ifdef D_T_FMT
-#  define PERL_D_T_FMT D_T_FMT
-#else
-#  define PERL_D_T_FMT -2
-#endif
-#ifdef D_FMT
-#  define PERL_D_FMT D_FMT
-#else
-#  define PERL_D_FMT -3
-#endif
-#ifdef T_FMT
-#  define PERL_T_FMT T_FMT
-#else
-#  define PERL_T_FMT -4
-#endif
-#ifdef T_FMT_AMPM
-#  define PERL_T_FMT_AMPM T_FMT_AMPM
-#else
-#  define PERL_T_FMT_AMPM -5
-#endif
-#ifdef AM_STR
-#  define PERL_AM_STR AM_STR
-#else
-#  define PERL_AM_STR -6
-#endif
-#ifdef PM_STR
-#  define PERL_PM_STR PM_STR
-#else
-#  define PERL_PM_STR -7
-#endif
-#ifdef DAY_1
-#  define PERL_DAY_1 DAY_1
-#else
-#  define PERL_DAY_1 -8
-#endif
-#ifdef DAY_2
-#  define PERL_DAY_2 DAY_2
-#else
-#  define PERL_DAY_2 -9
-#endif
-#ifdef DAY_3
-#  define PERL_DAY_3 DAY_3
-#else
-#  define PERL_DAY_3 -10
-#endif
-#ifdef DAY_4
-#  define PERL_DAY_4 DAY_4
-#else
-#  define PERL_DAY_4 -11
-#endif
-#ifdef DAY_5
-#  define PERL_DAY_5 DAY_5
-#else
-#  define PERL_DAY_5 -12
-#endif
-#ifdef DAY_6
-#  define PERL_DAY_6 DAY_6
-#else
-#  define PERL_DAY_6 -13
-#endif
-#ifdef DAY_7
-#  define PERL_DAY_7 DAY_7
-#else
-#  define PERL_DAY_7 -14
-#endif
-#ifdef ABDAY_1
-#  define PERL_ABDAY_1 ABDAY_1
-#else
-#  define PERL_ABDAY_1 -15
-#endif
-#ifdef ABDAY_2
-#  define PERL_ABDAY_2 ABDAY_2
-#else
-#  define PERL_ABDAY_2 -16
-#endif
-#ifdef ABDAY_3
-#  define PERL_ABDAY_3 ABDAY_3
-#else
-#  define PERL_ABDAY_3 -17
-#endif
-#ifdef ABDAY_4
-#  define PERL_ABDAY_4 ABDAY_4
-#else
-#  define PERL_ABDAY_4 -18
-#endif
-#ifdef ABDAY_5
-#  define PERL_ABDAY_5 ABDAY_5
-#else
-#  define PERL_ABDAY_5 -19
-#endif
-#ifdef ABDAY_6
-#  define PERL_ABDAY_6 ABDAY_6
-#else
-#  define PERL_ABDAY_6 -20
-#endif
-#ifdef ABDAY_7
-#  define PERL_ABDAY_7 ABDAY_7
-#else
-#  define PERL_ABDAY_7 -21
-#endif
-#ifdef MON_1
-#  define PERL_MON_1 MON_1
-#else
-#  define PERL_MON_1 -22
-#endif
-#ifdef MON_2
-#  define PERL_MON_2 MON_2
-#else
-#  define PERL_MON_2 -23
-#endif
-#ifdef MON_3
-#  define PERL_MON_3 MON_3
-#else
-#  define PERL_MON_3 -24
-#endif
-#ifdef MON_4
-#  define PERL_MON_4 MON_4
-#else
-#  define PERL_MON_4 -25
-#endif
-#ifdef MON_5
-#  define PERL_MON_5 MON_5
-#else
-#  define PERL_MON_5 -26
-#endif
-#ifdef MON_6
-#  define PERL_MON_6 MON_6
-#else
-#  define PERL_MON_6 -27
-#endif
-#ifdef MON_7
-#  define PERL_MON_7 MON_7
-#else
-#  define PERL_MON_7 -28
-#endif
-#ifdef MON_8
-#  define PERL_MON_8 MON_8
-#else
-#  define PERL_MON_8 -29
-#endif
-#ifdef MON_9
-#  define PERL_MON_9 MON_9
-#else
-#  define PERL_MON_9 -30
-#endif
-#ifdef MON_10
-#  define PERL_MON_10 MON_10
-#else
-#  define PERL_MON_10 -31
-#endif
-#ifdef MON_11
-#  define PERL_MON_11 MON_11
-#else
-#  define PERL_MON_11 -32
-#endif
-#ifdef MON_12
-#  define PERL_MON_12 MON_12
-#else
-#  define PERL_MON_12 -33
-#endif
-#ifdef ABMON_1
-#  define PERL_ABMON_1 ABMON_1
-#else
-#  define PERL_ABMON_1 -34
-#endif
-#ifdef ABMON_2
-#  define PERL_ABMON_2 ABMON_2
-#else
-#  define PERL_ABMON_2 -35
-#endif
-#ifdef ABMON_3
-#  define PERL_ABMON_3 ABMON_3
-#else
-#  define PERL_ABMON_3 -36
-#endif
-#ifdef ABMON_4
-#  define PERL_ABMON_4 ABMON_4
-#else
-#  define PERL_ABMON_4 -37
-#endif
-#ifdef ABMON_5
-#  define PERL_ABMON_5 ABMON_5
-#else
-#  define PERL_ABMON_5 -38
-#endif
-#ifdef ABMON_6
-#  define PERL_ABMON_6 ABMON_6
-#else
-#  define PERL_ABMON_6 -39
-#endif
-#ifdef ABMON_7
-#  define PERL_ABMON_7 ABMON_7
-#else
-#  define PERL_ABMON_7 -40
-#endif
-#ifdef ABMON_8
-#  define PERL_ABMON_8 ABMON_8
-#else
-#  define PERL_ABMON_8 -41
-#endif
-#ifdef ABMON_9
-#  define PERL_ABMON_9 ABMON_9
-#else
-#  define PERL_ABMON_9 -42
-#endif
-#ifdef ABMON_10
-#  define PERL_ABMON_10 ABMON_10
-#else
-#  define PERL_ABMON_10 -43
-#endif
-#ifdef ABMON_11
-#  define PERL_ABMON_11 ABMON_11
-#else
-#  define PERL_ABMON_11 -44
-#endif
-#ifdef ABMON_12
-#  define PERL_ABMON_12 ABMON_12
-#else
-#  define PERL_ABMON_12 -45
-#endif
-#ifdef ERA
-#  define PERL_ERA ERA
-#else
-#  define PERL_ERA -46
-#endif
-#ifdef ERA_D_FMT
-#  define PERL_ERA_D_FMT ERA_D_FMT
-#else
-#  define PERL_ERA_D_FMT -47
-#endif
-#ifdef ERA_D_T_FMT
-#  define PERL_ERA_D_T_FMT ERA_D_T_FMT
-#else
-#  define PERL_ERA_D_T_FMT -48
-#endif
-#ifdef ERA_T_FMT
-#  define PERL_ERA_T_FMT ERA_T_FMT
-#else
-#  define PERL_ERA_T_FMT -49
-#endif
-#ifdef ALT_DIGITS
-#  define PERL_ALT_DIGITS ALT_DIGITS
-#else
-#  define PERL_ALT_DIGITS -50
-#endif
-#ifdef RADIXCHAR
-#  define PERL_RADIXCHAR RADIXCHAR
-#else
-#  define PERL_RADIXCHAR -51
-#endif
-#ifdef THOUSEP
-#  define PERL_THOUSEP THOUSEP
-#else
-#  define PERL_THOUSEP -52
-#endif
-#ifdef YESEXPR
-#  define PERL_YESEXPR YESEXPR
-#else
-#  define PERL_YESEXPR -53
-#endif
-#ifdef YESSTR
-#  define PERL_YESSTR YESSTR
-#else
-#  define PERL_YESSTR -54
-#endif
-#ifdef NOEXPR
-#  define PERL_NOEXPR NOEXPR
-#else
-#  define PERL_NOEXPR -55
-#endif
-#ifdef NOSTR
-#  define PERL_NOSTR NOSTR
-#else
-#  define PERL_NOSTR -56
-#endif
-#ifdef CRNCYSTR
-#  define PERL_CRNCYSTR CRNCYSTR
-#else
-#  define PERL_CRNCYSTR -57
+#ifndef CODESET
+#  define CODESET -1
+#endif
+#ifndef D_T_FMT
+#  define D_T_FMT -2
+#endif
+#ifndef D_FMT
+#  define D_FMT -3
+#endif
+#ifndef T_FMT
+#  define T_FMT -4
+#endif
+#ifndef T_FMT_AMPM
+#  define T_FMT_AMPM -5
+#endif
+#ifndef AM_STR
+#  define AM_STR -6
+#endif
+#ifndef PM_STR
+#  define PM_STR -7
+#endif
+#ifndef DAY_1
+#  define DAY_1 -8
+#endif
+#ifndef DAY_2
+#  define DAY_2 -9
+#endif
+#ifndef DAY_3
+#  define DAY_3 -10
+#endif
+#ifndef DAY_4
+#  define DAY_4 -11
+#endif
+#ifndef DAY_5
+#  define DAY_5 -12
+#endif
+#ifndef DAY_6
+#  define DAY_6 -13
+#endif
+#ifndef DAY_7
+#  define DAY_7 -14
+#endif
+#ifndef ABDAY_1
+#  define ABDAY_1 -15
+#endif
+#ifndef ABDAY_2
+#  define ABDAY_2 -16
+#endif
+#ifndef ABDAY_3
+#  define ABDAY_3 -17
+#endif
+#ifndef ABDAY_4
+#  define ABDAY_4 -18
+#endif
+#ifndef ABDAY_5
+#  define ABDAY_5 -19
+#endif
+#ifndef ABDAY_6
+#  define ABDAY_6 -20
+#endif
+#ifndef ABDAY_7
+#  define ABDAY_7 -21
+#endif
+#ifndef MON_1
+#  define MON_1 -22
+#endif
+#ifndef MON_2
+#  define MON_2 -23
+#endif
+#ifndef MON_3
+#  define MON_3 -24
+#endif
+#ifndef MON_4
+#  define MON_4 -25
+#endif
+#ifndef MON_5
+#  define MON_5 -26
+#endif
+#ifndef MON_6
+#  define MON_6 -27
+#endif
+#ifndef MON_7
+#  define MON_7 -28
+#endif
+#ifndef MON_8
+#  define MON_8 -29
+#endif
+#ifndef MON_9
+#  define MON_9 -30
+#endif
+#ifndef MON_10
+#  define MON_10 -31
+#endif
+#ifndef MON_11
+#  define MON_11 -32
+#endif
+#ifndef MON_12
+#  define MON_12 -33
+#endif
+#ifndef ABMON_1
+#  define ABMON_1 -34
+#endif
+#ifndef ABMON_2
+#  define ABMON_2 -35
+#endif
+#ifndef ABMON_3
+#  define ABMON_3 -36
+#endif
+#ifndef ABMON_4
+#  define ABMON_4 -37
+#endif
+#ifndef ABMON_5
+#  define ABMON_5 -38
+#endif
+#ifndef ABMON_6
+#  define ABMON_6 -39
+#endif
+#ifndef ABMON_7
+#  define ABMON_7 -40
+#endif
+#ifndef ABMON_8
+#  define ABMON_8 -41
+#endif
+#ifndef ABMON_9
+#  define ABMON_9 -42
+#endif
+#ifndef ABMON_10
+#  define ABMON_10 -43
+#endif
+#ifndef ABMON_11
+#  define ABMON_11 -44
+#endif
+#ifndef ABMON_12
+#  define ABMON_12 -45
+#endif
+#ifndef ERA
+#  define ERA -46
+#endif
+#ifndef ERA_D_FMT
+#  define ERA_D_FMT -47
+#endif
+#ifndef ERA_D_T_FMT
+#  define ERA_D_T_FMT -48
+#endif
+#ifndef ERA_T_FMT
+#  define ERA_T_FMT -49
+#endif
+#ifndef ALT_DIGITS
+#  define ALT_DIGITS -50
+#endif
+#ifndef RADIXCHAR
+#  define RADIXCHAR -51
+#endif
+#ifndef THOUSEP
+#  define THOUSEP -52
+#endif
+#ifndef YESEXPR
+#  define YESEXPR -53
+#endif
+#ifndef YESSTR
+#  define YESSTR -54
+#endif
+#ifndef NOEXPR
+#  define NOEXPR -55
+#endif
+#ifndef NOSTR
+#  define NOSTR -56
+#endif
+#ifndef CRNCYSTR
+#  define CRNCYSTR -57
 #endif
 
 #endif
index 85a0867..17dff72 100644 (file)
@@ -342,7 +342,10 @@ XXX
 
 =item *
 
-XXX
+The item names passed to the function L<perlapi/Perl_langinfo>,
+introduced in 5.27.4, may no longer be prefixed with C<PERL_>.  For
+example, if you want the current floating point radix character, you
+must call it like C<Perl_langinfo(RADIXCHAR)>.
 
 =back