diff options
author | Brian Fraser <fraserbn@gmail.com> | 2012-03-23 17:37:15 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2012-03-25 13:43:59 -0700 |
commit | 3773592b8aa6557e5bedd85cd6e2cbb2d601f383 (patch) | |
tree | 4f5c258120d3f84d837155c5e60972774cbf1706 | |
parent | 43b5ab4c23566ca687eac39813feb9e9341f887d (diff) | |
download | perl-3773592b8aa6557e5bedd85cd6e2cbb2d601f383.tar.gz |
toke.c: "CORE::%s is not a keyword" cleanup.
-rw-r--r-- | t/lib/warnings/toke | 8 | ||||
-rw-r--r-- | toke.c | 4 |
2 files changed, 11 insertions, 1 deletions
diff --git a/t/lib/warnings/toke b/t/lib/warnings/toke index 79f287b261..313e5710b5 100644 --- a/t/lib/warnings/toke +++ b/t/lib/warnings/toke @@ -1194,3 +1194,11 @@ no warnings 'ambiguous' ; $a = ${f렏} ; EXPECT Ambiguous use of ${f렏} resolved to $f렏 at - line 6. +######## +# toke.c +use utf8; +use open qw( :utf8 :std ); +use warnings; +CORE::렏; +EXPECT +CORE::렏 is not a keyword at - line 5. @@ -7201,7 +7201,9 @@ Perl_yylex(pTHX) d = s; s = scan_word(s, PL_tokenbuf, sizeof PL_tokenbuf, FALSE, &len); if (!(tmp = keyword(PL_tokenbuf, len, 1))) - Perl_croak(aTHX_ "CORE::%s is not a keyword", PL_tokenbuf); + Perl_croak(aTHX_ "CORE::%"SVf" is not a keyword", + SVfARG(newSVpvn_flags(PL_tokenbuf, len, + (UTF ? SVf_UTF8 : 0) | SVs_TEMP))); if (tmp < 0) tmp = -tmp; else if (tmp == KEY_require || tmp == KEY_do |