Skip to content

Commit 5351ec0

Browse files
committed
locale.c: Rmv unnecessary parameter from static function
This dates from an earlier implementation
1 parent 4c39aaa commit 5351ec0

File tree

4 files changed

+6
-11
lines changed

4 files changed

+6
-11
lines changed

embed.fnc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3368,8 +3368,7 @@ So |void |restore_toggled_locale_i|const unsigned cat_index \
33683368
S |bool |is_locale_utf8 |NN const char * locale
33693369
# if (defined(HAS_LOCALECONV) || defined(HAS_LOCALECONV_L)) \
33703370
&& (defined(USE_LOCALE_MONETARY) || defined(USE_LOCALE_NUMERIC))
3371-
S |HV * |my_localeconv|const int item \
3372-
|const locale_utf8ness_t locale_is_utf8
3371+
S |HV * |my_localeconv|const int item
33733372
S |HV * |populate_localeconv|NN const struct lconv *lcbuf \
33743373
|const int unused \
33753374
|const locale_utf8ness_t numeric_locale_is_utf8 \

embed.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1611,7 +1611,7 @@
16111611
# if (defined(HAS_LOCALECONV) || defined(HAS_LOCALECONV_L)) && (defined(USE_LOCALE_MONETARY) || defined(USE_LOCALE_NUMERIC))
16121612
# if defined(PERL_IN_LOCALE_C)
16131613
# if defined(USE_LOCALE)
1614-
#define my_localeconv(a,b) S_my_localeconv(aTHX_ a,b)
1614+
#define my_localeconv(a) S_my_localeconv(aTHX_ a)
16151615
#define populate_localeconv(a,b,c,d) S_populate_localeconv(aTHX_ a,b,c,d)
16161616
# endif
16171617
# endif

locale.c

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3122,7 +3122,7 @@ Perl_localeconv(pTHX)
31223122

31233123
#else
31243124

3125-
return my_localeconv(0, LOCALE_UTF8NESS_UNKNOWN);
3125+
return my_localeconv(0);
31263126

31273127
#endif
31283128

@@ -3132,7 +3132,7 @@ Perl_localeconv(pTHX)
31323132
&& (defined(USE_LOCALE_MONETARY) || defined(USE_LOCALE_NUMERIC))
31333133

31343134
HV *
3135-
S_my_localeconv(pTHX_ const int item, const locale_utf8ness_t locale_is_utf8)
3135+
S_my_localeconv(pTHX_ const int item)
31363136
{
31373137
HV * retval;
31383138
locale_utf8ness_t numeric_locale_is_utf8 = LOCALE_UTF8NESS_UNKNOWN;
@@ -3166,10 +3166,7 @@ S_my_localeconv(pTHX_ const int item, const locale_utf8ness_t locale_is_utf8)
31663166
# ifdef HAS_SOME_LANGINFO
31673167

31683168
PERL_UNUSED_ARG(item);
3169-
PERL_UNUSED_ARG(locale_is_utf8);
31703169

3171-
/* When there is a nl_langinfo, we will only be called for localeconv
3172-
* numeric purposes. */
31733170
const bool is_localeconv_call = true;
31743171

31753172
# else
@@ -3207,7 +3204,6 @@ S_my_localeconv(pTHX_ const int item, const locale_utf8ness_t locale_is_utf8)
32073204

32083205
else {
32093206
copy_localeconv = S_get_nl_item_from_localeconv;
3210-
numeric_locale_is_utf8 = locale_is_utf8;
32113207
}
32123208

32133209
# endif
@@ -4123,7 +4119,7 @@ S_my_langinfo_i(pTHX_
41234119
case CRNCYSTR:
41244120
case THOUSEP:
41254121
{
4126-
SV * string = (SV *) my_localeconv(item, LOCALE_UTF8NESS_UNKNOWN);
4122+
SV * string = (SV *) my_localeconv(item);
41274123

41284124
retval = save_to_buffer(SvPV_nolen(string), retbufp, retbuf_sizep);
41294125

proto.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5108,7 +5108,7 @@ PERL_CALLCONV bool Perl_do_exec3(pTHX_ const char *incmd, int fd, int do_report)
51085108
#if (defined(HAS_LOCALECONV) || defined(HAS_LOCALECONV_L)) && (defined(USE_LOCALE_MONETARY) || defined(USE_LOCALE_NUMERIC))
51095109
# if defined(PERL_IN_LOCALE_C)
51105110
# if defined(USE_LOCALE)
5111-
STATIC HV * S_my_localeconv(pTHX_ const int item, const locale_utf8ness_t locale_is_utf8);
5111+
STATIC HV * S_my_localeconv(pTHX_ const int item);
51125112
#define PERL_ARGS_ASSERT_MY_LOCALECONV
51135113
STATIC HV * S_populate_localeconv(pTHX_ const struct lconv *lcbuf, const int unused, const locale_utf8ness_t numeric_locale_is_utf8, const locale_utf8ness_t monetary_locale_is_utf8);
51145114
#define PERL_ARGS_ASSERT_POPULATE_LOCALECONV \

0 commit comments

Comments
 (0)