diff options
author | Dagfinn Ilmari Mannsåker <ilmari@ilmari.org> | 2019-10-19 15:36:30 +0200 |
---|---|---|
committer | Dagfinn Ilmari Mannsåker <ilmari@ilmari.org> | 2019-10-21 12:19:41 +0200 |
commit | eeaa50cc8bee7e926cf76d8fc4a212cc36fad252 (patch) | |
tree | dff179e87a9639674da2993d9d6b741283e0be6f | |
parent | 5015bd0bb5ee7e0fa1ede1669bdfcd7bb5f10ebd (diff) | |
download | perl-eeaa50cc8bee7e926cf76d8fc4a212cc36fad252.tar.gz |
Fully spell out "subroutine" and "variable"
A bunch of places were using "%se" and "subroutin" or "variabl" when
generating error messages that could refer to either a subroutine or
variable. Spell the words out and use plain "%s" instead.
-rw-r--r-- | pad.c | 10 | ||||
-rw-r--r-- | perl.h | 2 | ||||
-rw-r--r-- | toke.c | 6 |
3 files changed, 9 insertions, 9 deletions
@@ -1086,10 +1086,10 @@ S_unavailable(pTHX_ PADNAME *name) { /* diag_listed_as: Variable "%s" is not available */ Perl_ck_warner(aTHX_ packWARN(WARN_CLOSURE), - "%se \"%" PNf "\" is not available", + "%s \"%" PNf "\" is not available", *PadnamePV(name) == '&' - ? "Subroutin" - : "Variabl", + ? "Subroutine" + : "Variable", PNfARG(name)); } @@ -1205,8 +1205,8 @@ S_pad_findlex(pTHX_ const char *namepv, STRLEN namelen, U32 flags, const CV* cv, /* diag_listed_as: Variable "%s" will not stay shared */ Perl_warner(aTHX_ packWARN(WARN_CLOSURE), - "%se \"%" UTF8f "\" will not stay shared", - *namepv == '&' ? "Subroutin" : "Variabl", + "%s \"%" UTF8f "\" will not stay shared", + *namepv == '&' ? "Subroutine" : "Variable", UTF8fARG(1, namelen, namepv)); } @@ -4605,7 +4605,7 @@ EXTCONST char PL_no_dir_func[] EXTCONST char PL_no_func[] INIT("The %s function is unimplemented"); EXTCONST char PL_no_myglob[] - INIT("\"%s\" %se %s can't be in a package"); + INIT("\"%s\" %s %s can't be in a package"); EXTCONST char PL_no_localize_ref[] INIT("Can't localize through a reference"); EXTCONST char PL_memory_wrap[] @@ -9343,8 +9343,8 @@ S_pending_ident(pTHX) /* diag_listed_as: No package name allowed for variable %s in "our" */ yyerror_pv(Perl_form(aTHX_ "No package name allowed for " - "%se %s in \"our\"", - *PL_tokenbuf=='&' ?"subroutin":"variabl", + "%s %s in \"our\"", + *PL_tokenbuf=='&' ? "subroutine" : "variable", PL_tokenbuf), UTF ? SVf_UTF8 : 0); tmp = allocmy(PL_tokenbuf, tokenbuf_len, UTF ? SVf_UTF8 : 0); } @@ -9356,7 +9356,7 @@ S_pending_ident(pTHX) GCC_DIAG_IGNORE_STMT(-Wformat-nonliteral); yyerror_pv(Perl_form(aTHX_ PL_no_myglob, PL_in_my == KEY_my ? "my" : "state", - *PL_tokenbuf == '&' ? "subroutin" : "variabl", + *PL_tokenbuf == '&' ? "subroutine" : "variable", PL_tokenbuf), UTF ? SVf_UTF8 : 0); GCC_DIAG_RESTORE_STMT; |