Skip Menu |

This queue is for tickets about the DateTime-Format-Baby CPAN distribution.

Report information
The Basics
Id: 69841
Status: resolved
Priority: 0/
Queue: DateTime-Format-Baby

People
Owner: Nobody in particular
Requestors: J2N-FORGET [...] orange.fr
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.0100
Fixed in: 1.0200



Subject: Warning: assignment to $[
Since perl 5.12.2 (or maybe even earlier), assignments to $[ trigger a warning. This is the case in DateTime::Format::Baby. So the attached patch removes this warning. In addition, the patch produces utf-8 output, fixes some spelling mistakes and fixes a pod error.
Subject: dt-f-baby.patch
diff -ur DateTime-Format-Baby-1.01/Changes DateTime-Format-Baby-1.02/Changes --- DateTime-Format-Baby-1.01/Changes 2003-06-28 10:34:35.000000000 +0200 +++ DateTime-Format-Baby-1.02/Changes 2011-07-27 20:17:52.855514792 +0200 @@ -54,3 +54,8 @@ returning 7:60 rather then 8:00, which used to work but doesn't anymore!) +1.0200 ??? + - Prevent warnings about assignments to $[ + - POD fix + - convert to utf-8 + - fix some spelling mistakes, following Abgail's Acme::Time::Baby 2010090301. diff -ur DateTime-Format-Baby-1.01/lib/DateTime/Format/Baby.pm DateTime-Format-Baby-1.02/lib/DateTime/Format/Baby.pm --- DateTime-Format-Baby-1.01/lib/DateTime/Format/Baby.pm 2003-06-28 10:23:20.000000000 +0200 +++ DateTime-Format-Baby-1.02/lib/DateTime/Format/Baby.pm 2011-07-27 20:14:42.503874351 +0200 @@ -5,7 +5,7 @@ use DateTime; use Carp; -$VERSION = '0.15.3'; +$VERSION = '1.0200'; my %languages = ( 'en' => {numbers => [qw /one two three four five six seven @@ -15,17 +15,17 @@ big => [qw/big long large minute/], little => [qw/little small short hour/]}, - 'br' => {numbers => [qw /um dois trÍs quatro cinco seis + 'br' => {numbers => [qw /um dois três quatro cinco seis sete oito nove dez onze doze/], - format => "O ponteiro grande est· no %s " . - "e o ponteiro pequeno est· no %s"}, + format => "O ponteiro grande está no %s " . + "e o ponteiro pequeno está no %s"}, - 'de' => {numbers => [qw /Eins Zwei Drei Vier F¸nf Sechs Sieben - Acht Neun Zehn Elf Zw–lf/], - format => "Der gro\xDFe Zeiger ist auf der %s " . + 'de' => {numbers => [qw /Eins Zwei Drei Vier Fünf Sechs Sieben + Acht Neun Zehn Elf Zwölf/], + format => "Der große Zeiger ist auf der %s " . "und der kleine Zeiger ist auf der %s", - big => [qw/groß lang groß Minute/], - little => [qw/wenig klein Kurzschluß Stunde/]}, + big => [qw/groß lang groß Minute/], + little => [qw/wenig klein Kurzschluß Stunde/]}, 'du' => {numbers => [qw /een twee drie vier vijf zes zeven acht negen tien elf twaalf/], @@ -34,18 +34,18 @@ 'es' => {numbers => [qw /uno dos tres cuatro cinco seis siete ocho nueve diez once doce/], - format => "La manecilla grande est· sobre el %s " . - "y la manecilla pequeÒa est· sobre el %s", + format => "La manecilla grande está sobre el %s " . + "y la manecilla pequeña está sobre el %s", big => [qw/grande grande minuto/, 'de largo'], - little => [qw/poco pequeño cortocircuito hora/]}, + little => [qw/poco pequeño cortocircuito hora/]}, 'fr' => {numbers => [qw /un deux trois quatre cinq six sept huit neuf dix onze douze/], format => "La grande aiguille est sur le %s " . "et la petite aiguille est sur le %s", - big => [qw/grand longtemps grand minute/], - little => [qw/peu petit short heure/]}, + big => [qw/grand long grand minute/], + little => [qw/peu petit court heure/]}, 'it' => {numbers => ['a una', 'e due', 'e tre', 'e quattro', 'e cinque', 'e sei', 'e sette', @@ -57,14 +57,14 @@ little => [qw/piccolo piccolo short ora/]}, 'no' => {numbers => [qw /en to tre fire fem seks syv - Âtte ni ti elleve tolv/], - format => "Den store viseren er p %s " . - "og den lille viseren er p %s"}, - - 'se' => {numbers => [qw /ett tv tre fyra fem sex sju - Âtta nio tio elva tolv/], - format => "Den stora visaren ”r p %s " . - "och den lilla visaren ”r p %s"}, + Ã¥tte ni ti elleve tolv/], + format => "Den store viseren er pÃ¥ %s " . + "og den lille viseren er pÃ¥ %s"}, + + 'se' => {numbers => [qw /ett tv tre fyra fem sex sju + Âtta nio tio elva tolv/], + format => "Den stora visaren är pÃ¥ %s " . + "och den lilla visaren är pÃ¥ %s"}, 'swedish chef' => {numbers => [qw /one tvu three ffuoor ffeefe six @@ -189,8 +189,7 @@ $minutes = sprintf "%.0f" => $minutes / 5; $minutes ||= 12; - local $[ = 1; - return sprintf $self->{format} => @{$self->{numbers}} [$minutes, $hours]; + return sprintf $self->{format} => @{$self->{numbers}} [$minutes -1, $hours -1]; } sub format_duration { @@ -254,6 +253,8 @@ This method return a list of known languages. +=back + =head1 SUPPORT Support for this module is provided via the datetime@perl.org email