From: Nicholas Clark Date: Sun, 31 Oct 2004 10:40:11 +0000 (+0000) Subject: Assimilate I18N::LangTags 0.35 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=77b20956d615e3ae00cdb4d84d0e0dbc255b99f6;p=p5sagit%2Fp5-mst-13.2.git Assimilate I18N::LangTags 0.35 p4raw-id: //depot/perl@23440 --- diff --git a/MANIFEST b/MANIFEST index c029b1a..e5617e0 100644 --- a/MANIFEST +++ b/MANIFEST @@ -1421,6 +1421,7 @@ lib/I18N/LangTags/t/01_about_verbose.t See whether I18N::LangTags works lib/I18N/LangTags/t/05_main.t See whether I18N::LangTags works lib/I18N/LangTags/t/07_listy.t See whether I18N::LangTags works lib/I18N/LangTags/t/10_http.t See whether I18N::LangTags works +lib/I18N/LangTags/t/20_locales.t See whether I18N::LangTags works lib/I18N/LangTags/t/50_super.t See whether I18N::LangTags works lib/I18N/LangTags/t/55_supers_strict.t See whether I18N::LangTags works lib/I18N/LangTags/t/80_all_env.t See whether I18N::LangTags works diff --git a/lib/I18N/LangTags.pm b/lib/I18N/LangTags.pm index e57e076..6a39cae 100644 --- a/lib/I18N/LangTags.pm +++ b/lib/I18N/LangTags.pm @@ -1,5 +1,5 @@ -# Time-stamp: "2004-07-01 14:34:40 ADT" +# Time-stamp: "2004-10-06 23:26:33 ADT" # Sean M. Burke require 5.000; @@ -19,7 +19,7 @@ require Exporter; ); %EXPORT_TAGS = ('ALL' => \@EXPORT_OK); -$VERSION = "0.33"; +$VERSION = "0.35"; sub uniq { my %seen; return grep(!($seen{$_}++), @_); } # a util function @@ -403,7 +403,8 @@ sub locale2language_tag { return $lang if &is_language_tag($lang); # like "en" $lang =~ tr<_><->; # "en_US" -> en-US - $lang =~ s<\.[-_a-zA-Z0-9\.]*><>s; # "en_US.ISO8859-1" -> en-US + $lang =~ s<(?:[\.\@][-_a-zA-Z0-9]+)+$><>s; # "en_US.ISO8859-1" -> en-US + # it_IT.utf8@euro => it-IT return $lang if &is_language_tag($lang); @@ -868,7 +869,7 @@ C =head1 COPYRIGHT -Copyright (c) 1998-2004 Sean M. Burke. All rights reserved. +Copyright (c) 1998+ Sean M. Burke. All rights reserved. This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. diff --git a/lib/I18N/LangTags/ChangeLog b/lib/I18N/LangTags/ChangeLog index 403a3cb..6cd744e 100644 --- a/lib/I18N/LangTags/ChangeLog +++ b/lib/I18N/LangTags/ChangeLog @@ -1,6 +1,21 @@ Revision history for Perl module I18N::LangTags. - Time-stamp: "2004-07-01 14:28:23 ADT" + Time-stamp: "2004-10-06 23:26:53 ADT" +2004-10-06 Sean M. Burke sburke@cpan.org + + * Release 0.35 + + Bugfix version: locale2language_tag now correctly understands + locale-IDs with at-signs in them, like 'it_IT.utf8@euro' or + 'it_IT@euro'. This is now enforced by the new t/20_locales.t + + Thanks to Luca 'loopback' Cavalli for letting me know about these + new locale-ID name-styles. + + + * Release 0.34 -- never happened, because of an upload error + + 2004-07-01 Sean M. Burke sburke@cpan.org * Release 0.33 diff --git a/lib/I18N/LangTags/List.pm b/lib/I18N/LangTags/List.pm index ca2f059..5e5363f 100644 --- a/lib/I18N/LangTags/List.pm +++ b/lib/I18N/LangTags/List.pm @@ -1,10 +1,10 @@ require 5; package I18N::LangTags::List; -# Time-stamp: "2003-10-10 17:39:45 ADT" +# Time-stamp: "2004-10-06 23:26:21 ADT" use strict; use vars qw(%Name %Is_Disrec $Debug $VERSION); -$VERSION = '0.29'; +$VERSION = '0.35'; # POD at the end. #---------------------------------------------------------------------- @@ -1715,7 +1715,7 @@ L and its "See Also" section. =head1 COPYRIGHT AND DISCLAIMER -Copyright (c) 2001,2002,2003 Sean M. Burke. All rights reserved. +Copyright (c) 2001+ Sean M. Burke. All rights reserved. You can redistribute and/or modify this document under the same terms as Perl itself. diff --git a/lib/I18N/LangTags/README b/lib/I18N/LangTags/README index 2ac6053..ef0eb7b 100644 --- a/lib/I18N/LangTags/README +++ b/lib/I18N/LangTags/README @@ -1,5 +1,5 @@ README for I18N::LangTags - Time-stamp: "2001-05-29 21:52:15 MDT" + Time-stamp: "2004-10-06 23:19:39 ADT" I18N::LangTags @@ -66,7 +66,7 @@ Comprehensive Perl Archive Network (CPAN). Visit COPYRIGHT -Copyright 1998-2001, Sean M. Burke , all rights +Copyright 1998+, Sean M. Burke , all rights reserved. The programs and documentation in this dist are distributed in