From 4c53e876b789c79a3c29f9f39f439b5326c8d417 Mon Sep 17 00:00:00 2001 From: Jarkko Hietaniemi Date: Sun, 12 Aug 2001 18:43:50 +0000 Subject: Mark tests (and one module) having explicit Latin-1 (and one file having explicit UTF-8) with an explicit 'no utf8' (and one explicit 'use utf8'). NOTE: t/op/pat.t #64 fails mysteriously under 'use utf8'. p4raw-id: //depot/perl@11648 --- lib/Locale/Codes/t/languages.t | 2 +- lib/Locale/Language.pm | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'lib/Locale') diff --git a/lib/Locale/Codes/t/languages.t b/lib/Locale/Codes/t/languages.t index 9facd3509d..c643f3a307 100644 --- a/lib/Locale/Codes/t/languages.t +++ b/lib/Locale/Codes/t/languages.t @@ -10,7 +10,7 @@ BEGIN { use Locale::Language; -no utf8; # so that the naked 8-bit characters won't gripe under use utf8 +no utf8; # we contain Latin-1 #----------------------------------------------------------------------- # This is an array of tests. Each test is eval'd as an expression. diff --git a/lib/Locale/Language.pm b/lib/Locale/Language.pm index 391cffab78..9e0cf19541 100644 --- a/lib/Locale/Language.pm +++ b/lib/Locale/Language.pm @@ -247,13 +247,15 @@ modify it under the same terms as Perl itself. # initialisation code - stuff the DATA into the CODES hash #======================================================================= { + no utf8; # __DATA__ contains Latin-1 + my $code; my $language; while () { - next unless /\S/; + next unless /\S/; chop; ($code, $language) = split(/:/, $_, 2); $CODES{$code} = $language; -- cgit v1.2.1