Skip to content

Commit c469b4e

Browse files
committed
Convert leading underscore to trailing in internal global macro
Leading underscores of global names are reserved for the C implmentation itself. We are gradually fixing ours to conform.
1 parent dd0471c commit c469b4e

File tree

3 files changed

+13
-13
lines changed

3 files changed

+13
-13
lines changed

perl.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7545,7 +7545,7 @@ the plain locale pragma without a parameter (S<C<use locale>>) is in effect.
75457545
* and will do so if enabled. The first takes a single code point
75467546
* argument; the 2nd, is a pointer to the first byte of the UTF-8 encoded
75477547
* string, and an end position which it won't try to read past */
7548-
# define _CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG(cp) \
7548+
# define CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG_(cp) \
75497549
STMT_START { \
75507550
if (! IN_UTF8_CTYPE_LOCALE && ckWARN(WARN_LOCALE)) { \
75517551
Perl_warner(aTHX_ packWARN(WARN_LOCALE), \
@@ -7554,7 +7554,7 @@ the plain locale pragma without a parameter (S<C<use locale>>) is in effect.
75547554
} \
75557555
} STMT_END
75567556

7557-
# define _CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(s, send) \
7557+
# define CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(s, send) \
75587558
STMT_START { /* Check if to warn before doing the conversion work */\
75597559
if (! IN_UTF8_CTYPE_LOCALE && ckWARN(WARN_LOCALE)) { \
75607560
UV cp = utf8_to_uv_or_die((const U8 *) (s), \
@@ -7582,8 +7582,8 @@ the plain locale pragma without a parameter (S<C<use locale>>) is in effect.
75827582
# define IN_LC_RUNTIME(category) 0
75837583
# define IN_LC(category) 0
75847584
# define CHECK_AND_WARN_PROBLEMATIC_LOCALE_
7585-
# define _CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(s, send)
7586-
# define _CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG(c)
7585+
# define CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(s, send)
7586+
# define CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG_(c)
75877587
#endif
75887588

75897589
#define locale_panic_via_(m, f, l) Perl_locale_panic((m), __LINE__, f, l)

regexec.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ S_isFOO_utf8_lc(pTHX_ const U8 classnum, const U8* character, const U8* e)
609609
EIGHT_BIT_UTF8_TO_NATIVE(*character, *(character + 1)));
610610
}
611611

612-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(character, e);
612+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(character, e);
613613

614614
switch ((char_class_number_) classnum) {
615615
case CC_ENUM_SPACE_: return is_XPERLSPACE_high(character);
@@ -1812,7 +1812,7 @@ STMT_START { \
18121812
case trie_flu8: \
18131813
CHECK_AND_WARN_PROBLEMATIC_LOCALE_; \
18141814
if (UTF8_IS_ABOVE_LATIN1(*uc)) { \
1815-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(uc, uc_end); \
1815+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(uc, uc_end); \
18161816
} \
18171817
goto do_trie_utf8_fold; \
18181818
case trie_utf8_exactfa_fold: \
@@ -1862,7 +1862,7 @@ STMT_START { \
18621862
case trie_utf8l: \
18631863
CHECK_AND_WARN_PROBLEMATIC_LOCALE_; \
18641864
if (utf8_target && UTF8_IS_ABOVE_LATIN1(*uc)) { \
1865-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(uc, uc_end); \
1865+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(uc, uc_end); \
18661866
} \
18671867
/* FALLTHROUGH */ \
18681868
case trie_utf8: \
@@ -6764,7 +6764,7 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog)
67646764
/* We only output for EXACTL, as we let the folder
67656765
* output this message for EXACTFLU8 to avoid
67666766
* duplication */
6767-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(locinput,
6767+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(locinput,
67686768
reginfo->strend);
67696769
}
67706770
}
@@ -7091,7 +7091,7 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog)
70917091
* just to check for this warning is worth it. So this just checks
70927092
* the first character */
70937093
if (utf8_target && UTF8_IS_ABOVE_LATIN1(*locinput)) {
7094-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(locinput, reginfo->strend);
7094+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(locinput, reginfo->strend);
70957095
}
70967096
goto do_exact;
70977097
case EXACT_REQ8:
@@ -7777,7 +7777,7 @@ S_regmatch(pTHX_ regmatch_info *reginfo, char *startpos, regnode *prog)
77777777

77787778
if (! UTF8_IS_NEXT_CHAR_DOWNGRADEABLE(locinput, reginfo->strend)) {
77797779
/* An above Latin-1 code point, or malformed */
7780-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(locinput,
7780+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(locinput,
77817781
reginfo->strend);
77827782
goto utf8_posix_above_latin1;
77837783
}
@@ -10343,7 +10343,7 @@ S_regrepeat(pTHX_ regexp *prog, char **startposp, const regnode *p,
1034310343

1034410344
case EXACTL_t8:
1034510345
if (UTF8_IS_ABOVE_LATIN1(*scan)) {
10346-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(scan, loceol);
10346+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(scan, loceol);
1034710347
}
1034810348
/* FALLTHROUGH */
1034910349

@@ -10957,7 +10957,7 @@ S_reginclass(pTHX_ regexp * const prog, const regnode * const n, const U8* const
1095710957
&& (OP(n) == ANYOFL || OP(n) == ANYOFPOSIXL)
1095810958
&& ! (flags & ANYOFL_UTF8_LOCALE_REQD))
1095910959
{
10960-
_CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG(c);
10960+
CHECK_AND_OUTPUT_WIDE_LOCALE_CP_MSG_(c);
1096110961
}
1096210962
}
1096310963

utf8.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4221,7 +4221,7 @@ S_check_locale_boundary_crossing(pTHX_ const U8* const p, const UV result,
42214221
}
42224222

42234223
/* Here, no characters crossed, result is ok as-is, but we warn. */
4224-
_CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG(p, p + UTF8SKIP(p));
4224+
CHECK_AND_OUTPUT_WIDE_LOCALE_UTF8_MSG_(p, p + UTF8SKIP(p));
42254225
return result;
42264226
}
42274227

0 commit comments

Comments
 (0)