Skip to content

Commit

Permalink
t/run/locale.t: Silence perl warning
Browse files Browse the repository at this point in the history
This pattern that contains [:ascii:] is executed under /l, and can raise
"wide character" warnings when matched against a UTF-8 string.  But we
really are interested in strict ASCII, so /u works perfectly and avoids
any such warnings.
  • Loading branch information
khwilliamson committed Apr 18, 2018
1 parent 7bb8f70 commit 8dcd53c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion t/run/locale.t
Expand Up @@ -135,7 +135,7 @@ EOF
# For utf8 locales with a non-ascii radix, it should be encoded as
# UTF-8 with the internal flag so set.
if (! defined $utf8_radix
&& $radix =~ /[[:^ascii:]]/
&& $radix =~ /[[:^ascii:]]/u # /u because /l can raise warnings
&& is_locale_utf8($_))
{
$utf8_radix = $_;
Expand Down

0 comments on commit 8dcd53c

Please sign in to comment.