Skip Menu |

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

Report information
The Basics
Id: 57346
Status: rejected
Priority: 0/
Queue: DateTime-Format-CLDR

People
Owner: Nobody in particular
Requestors: daxim [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.10
Fixed in: (no value)



Subject: locale zh_CN -> Could not get datetime
# adapted from http://stackoverflow.com/questions/1867550 use utf8; use DateTime::Format::CLDR (); my $cldr = DateTime::Format::CLDR->new(locale => 'zh_CN', on_error => 'croak',); $cldr->parse_datetime('2009/11/26 下午 04:40:54'); __END__ Show quoted text
> perl -MCarp::Always 4.pl
Could not get datetime for 2009/11/26 下午 04:40:54: /11/26 下午 04:40:54 at /home/daxim/local/lib/perl5/site_perl/5.10.1/DateTime/Format/CLDR.pm line 907 DateTime::Format::CLDR::_local_croak('DateTime::Format::CLDR=HASH(0xee7b68)', 'Could not get datetime for 2009/11/26 下午 04:40:54: /11/26 下午 ...') called at /home/daxim/local/lib/perl5/site_perl/5.10.1/DateTime/Format/CLDR.pm line 638 DateTime::Format::CLDR::parse_datetime('DateTime::Format::CLDR=HASH(0xee7b68)', '2009/11/26 下午 04:40:54') called at 4.pl line 4
Wrong CLDR pattern used (as discussed on IRC) Cheers Maroš