[Orca-checkins] rev 239 - in trunk/orca: . packages/TimeDate-1.14 packages/TimeDate-1.16 packages/TimeDate-1.16/lib/Date packages/TimeDate-1.16/lib/Date/Language packages/TimeDate-1.16/t

Blair Zajac blair at orcaware.com
Sun Jun 15 12:29:50 PDT 2003


Author: blair
Date: Sun Jun 15 12:29:44 2003
New Revision: 239

Added:
   trunk/orca/packages/TimeDate-1.16/
      - copied from rev 238, trunk/orca/packages/TimeDate-1.14/
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Afar.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Amharic.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Chinese_GB.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Finnish.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Gedeo.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Oromo.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Sidama.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Somali.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Swedish.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Tigrinya.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEritrean.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEthiopian.pm
Removed:
   trunk/orca/packages/TimeDate-1.14/
Modified:
   trunk/orca/INSTALL
   trunk/orca/configure.in
   trunk/orca/packages/TimeDate-1.16/ChangeLog
   trunk/orca/packages/TimeDate-1.16/MANIFEST
   trunk/orca/packages/TimeDate-1.16/Makefile.PL
   trunk/orca/packages/TimeDate-1.16/lib/Date/Format.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Dutch.pm
   trunk/orca/packages/TimeDate-1.16/lib/Date/Parse.pm
   trunk/orca/packages/TimeDate-1.16/t/date.t
   trunk/orca/packages/TimeDate-1.16/t/format.t
   trunk/orca/packages/TimeDate-1.16/t/getdate.t
Log:
Upgrade TimeDate from 1.14 to 1.16.  The Date::Parse module and its
version number is unchanged in this upgrade.

* INSTALL (Determine which Perl modules need compiling and installing):
  Update all references to TimeDate's package version number from 1.14 to
  1.16.

* configure.in:
  Bump DATE_PARSE_DIR from TimeDate-1.14 to TimeDate-1.16.

* packages/TimeDate-1.16:
  Renamed from packages/TimeDate-1.14.  Directory contents updated
  from TimeDate-1.16.tar.gz.


Modified: trunk/orca/INSTALL
==============================================================================
--- trunk/orca/INSTALL	(original)
+++ trunk/orca/INSTALL	Sun Jun 15 12:29:44 2003
@@ -204,10 +204,10 @@
 
     Date::Parse
 
-      http://www.perl.com/CPAN/authors/id/G/GB/GBARR/TimeDate-1.14.tar.gz
+      http://www.perl.com/CPAN/authors/id/G/GB/GBARR/TimeDate-1.16.tar.gz
 
-      % gunzip -c TimeDate-1.14.tar.gz | tar xvf -
-      % cd TimeDate-1.14
+      % gunzip -c TimeDate-1.16.tar.gz | tar xvf -
+      % cd TimeDate-1.16
       % perl Makefile.PL
       % make
       % make test

Modified: trunk/orca/configure.in
==============================================================================
--- trunk/orca/configure.in	(original)
+++ trunk/orca/configure.in	Sun Jun 15 12:29:44 2003
@@ -29,7 +29,7 @@
 COMPRESS_ZLIB_VER=1.05
 DATA_DUMPER_DIR=Data-Dumper-2.101
 DATA_DUMPER_VER=2.101
-DATE_PARSE_DIR=TimeDate-1.14
+DATE_PARSE_DIR=TimeDate-1.16
 DATE_PARSE_VER=2.24
 DEVEL_DPROF_DIR=DProf-19990108
 DEVEL_DPROF_VER=19990108

Modified: trunk/orca/packages/TimeDate-1.16/ChangeLog
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/ChangeLog	(original)
+++ trunk/orca/packages/TimeDate-1.16/ChangeLog	Sun Jun 15 12:29:44 2003
@@ -1,3 +1,67 @@
+Change 814 on 2003/06/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Date::Parse
+	- Time::Local in 5.8 does not support fractional seconds
+
+Change 813 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Release 1.15
+
+Change 812 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Fix comments about Language implementation in Date::Parse
+	(patch from Christian Hammers)
+
+Change 811 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Fix short name for 'maart' to be 'mrt' as suggested by Frank Maas
+
+Change 810 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Add %G format for GPS week (patch from Eric Richardson)
+
+Change 809 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Language updates from Daniel Yacob
+
+Change 808 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	str2time("") should return undef
+
+Change 807 on 2003/06/02 by <gbarr at pobox.com> (Graham Barr)
+
+	Added Swedish and Finnish languages from Matthew Musgrove
+
+Change 778 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Added Chinese_GB language.
+	Supplied by forehead (I don't even pretend tounderstand it)
+
+Change 777 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Return fractional seconds when specified in an ISO date
+
+Change 776 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	New languages from Daniel Yacob
+
+Change 775 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Fix UTC support on ISO dates
+
+Change 774 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Allow a : in a timezone so the dates specified in RSS can be parsed
+	(eg 2002-11-07T23:31:49-05:00) Patch from Kellan
+
+Change 773 on 2003/03/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Support parsing more formats
+
+Change 754 on 2002/11/03 by <gbarr at pobox.com> (Graham Barr)
+
+	Release 1.14
+
 Change 753 on 2002/11/03 by <gbarr at pobox.com> (Graham Barr)
 
 	Fix bug parsing 2002-11-02 11pm

Modified: trunk/orca/packages/TimeDate-1.16/MANIFEST
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/MANIFEST	(original)
+++ trunk/orca/packages/TimeDate-1.16/MANIFEST	Sun Jun 15 12:29:44 2003
@@ -4,17 +4,29 @@
 README
 lib/Date/Format.pm
 lib/Date/Language.pm
+lib/Date/Language/Afar.pm
+lib/Date/Language/Amharic.pm
 lib/Date/Language/Austrian.pm
 lib/Date/Language/Brazilian.pm
+lib/Date/Language/Chinese_GB.pm
 lib/Date/Language/Czech.pm
 lib/Date/Language/Danish.pm
 lib/Date/Language/Dutch.pm
 lib/Date/Language/English.pm
+lib/Date/Language/Finnish.pm
 lib/Date/Language/French.pm
+lib/Date/Language/Gedeo.pm
 lib/Date/Language/German.pm
 lib/Date/Language/Greek.pm
 lib/Date/Language/Italian.pm
 lib/Date/Language/Norwegian.pm
+lib/Date/Language/Oromo.pm
+lib/Date/Language/Sidama.pm
+lib/Date/Language/Somali.pm
+lib/Date/Language/Swedish.pm
+lib/Date/Language/Tigrinya.pm
+lib/Date/Language/TigrinyaEritrean.pm
+lib/Date/Language/TigrinyaEthiopian.pm
 lib/Date/Parse.pm
 lib/Time/Zone.pm
 t/date.t

Modified: trunk/orca/packages/TimeDate-1.16/Makefile.PL
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/Makefile.PL	(original)
+++ trunk/orca/packages/TimeDate-1.16/Makefile.PL	Sun Jun 15 12:29:44 2003
@@ -1,10 +1,10 @@
 # This -*- perl -*- script makes the Makefile
-# $Id: //depot/TimeDate/Makefile.PL#9 $
+# $Id: //depot/TimeDate/Makefile.PL#11 $
 
 #--- Distribution section ---
 
 $DISTNAME = 'TimeDate';
-$VERSION  = "1.14";
+$VERSION  = "1.16";
 
 #--- Write the Makefile
 

Modified: trunk/orca/packages/TimeDate-1.16/lib/Date/Format.pm
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/lib/Date/Format.pm	(original)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Format.pm	Sun Jun 15 12:29:44 2003
@@ -1,4 +1,4 @@
-# Date::Format $Id: //depot/TimeDate/lib/Date/Format.pm#8 $
+# Date::Format $Id: //depot/TimeDate/lib/Date/Format.pm#9 $
 #
 # Copyright (c) 1995-1999 Graham Barr. All rights reserved. This program is free
 # software; you can redistribute it and/or modify it under the same terms
@@ -122,6 +122,7 @@
   {
    @$me = localtime($time);
   }
+ $me->[9] = $time;
  _subs($me,$fmt);
 }
 
@@ -263,6 +264,8 @@
 sub format_Oy { roman(format_y(@_)) }
 sub format_OY { roman(format_Y(@_)) }
 
+sub format_G { int(($_[0]->[9] - 315993600) / 604800) }
+
 1;
 __END__
 
@@ -353,6 +356,7 @@
 	%d 	numeric day of the month, with leading zeros (eg 01..31)
 	%e 	numeric day of the month, without leading zeros (eg 1..31)
 	%D 	MM/DD/YY
+	%G	GPS week number (weeks since January 6, 1980)
 	%h 	month abbr
 	%H 	hour, 24 hour clock, leading 0's)
 	%I 	hour, 12 hour clock, leading 0's)

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Afar.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Afar.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,49 @@
+##
+## Afar tables
+##
+
+package Date::Language::Afar;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "0.99";
+
+ at DoW = qw(Acaada Etleeni Talaata Arbaqa Kamiisi Gumqata Sabti);
+ at MoY = (
+"Qunxa Garablu",
+"Kudo",
+"Ciggilta Kudo",
+"Agda Baxis",
+"Caxah Alsa",
+"Qasa Dirri",
+"Qado Dirri",
+"Liiqen",
+"Waysu",
+"Diteli",
+"Ximoli",
+"Kaxxa Garablu"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = qw(saaku carra);
+
+ at Dsuf = (qw(th st nd rd th th th th th th)) x 3;
+ at Dsuf[11,12,13] = qw(th th th);
+ at Dsuf[30,31] = qw(th st);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Amharic.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Amharic.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,87 @@
+##
+## Amharic tables
+##
+
+package Date::Language::Amharic;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.00";
+
+if ( $] >= 5.006 ) {
+ at DoW = (
+"\x{12a5}\x{1211}\x{12f5}",
+"\x{1230}\x{129e}",
+"\x{121b}\x{12ad}\x{1230}\x{129e}",
+"\x{1228}\x{1261}\x{12d5}",
+"\x{1210}\x{1219}\x{1235}",
+"\x{12d3}\x{122d}\x{1265}",
+"\x{1245}\x{12f3}\x{121c}"
+);
+ at MoY = (
+"\x{1303}\x{1295}\x{12e9}\x{12c8}\x{122a}",
+"\x{134c}\x{1265}\x{1229}\x{12c8}\x{122a}",
+"\x{121b}\x{122d}\x{127d}",
+"\x{12a4}\x{1355}\x{1228}\x{120d}",
+"\x{121c}\x{12ed}",
+"\x{1301}\x{1295}",
+"\x{1301}\x{120b}\x{12ed}",
+"\x{12a6}\x{1308}\x{1235}\x{1275}",
+"\x{1234}\x{1355}\x{1274}\x{121d}\x{1260}\x{122d}",
+"\x{12a6}\x{12ad}\x{1270}\x{12cd}\x{1260}\x{122d}",
+"\x{1296}\x{126c}\x{121d}\x{1260}\x{122d}",
+"\x{12f2}\x{1234}\x{121d}\x{1260}\x{122d}"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = ( "\x{1320}\x{12cb}\x{1275}", "\x{12a8}\x{1230}\x{12d3}\x{1275}" );
+
+ at Dsuf = ("\x{129b}" x 31);
+}
+else {
+ at DoW = (
+"እሑድ",
+"ሰኞ",
+"ማክሰኞ",
+"ረቡዕ",
+"ሐሙስ",
+"ዓርብ",
+"ቅዳሜ"
+);
+ at MoY = (
+"ጃንዩወሪ",
+"ፌብሩወሪ",
+"ማርች",
+"ኤፕረል",
+"ሜይ",
+"ጁን",
+"ጁላይ",
+"ኦገስት",
+"ሴፕቴምበር",
+"ኦክተውበር",
+"ኖቬምበር",
+"ዲሴምበር"
+);
+ at DoWs = map { substr($_,0,9) } @DoW;
+ at MoYs = map { substr($_,0,9) } @MoY;
+ at AMPM = ( "ጠዋት", "ከሰዓት" );
+
+ at Dsuf = ("ኛ" x 31);
+}
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Chinese_GB.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Chinese_GB.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,36 @@
+##
+## English tables
+##
+
+package Date::Language::Chinese_GB;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.01";
+
+ at DoW = qw(ÐÇÆÚÈÕ ÐÇÆÚÒ» ÐÇÆÚ¶þ ÐÇÆÚÈý ÐÇÆÚËÄ ÐÇÆÚÎå ÐÇÆÚÁù);
+ at MoY = qw(Ò»ÔÂ ¶þÔÂ ÈýÔÂ ËÄÔÂ ÎåÔÂ ÁùÔÂ
+	  ÆßÔ °ËÔ ¾ÅÔ ʮÔ ʮһÔ ʮ¶þÔÂ);
+ at DoWs = map { $_ } @DoW;
+ at MoYs = map { $_ } @MoY;
+ at AMPM = qw(ÉÏÎç ÏÂÎç);
+
+ at Dsuf = (qw(ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ ÈÕ)) x 3;
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+sub format_o { sprintf("%2d%s",$_[0]->[3],"ÈÕ") }
+1;

Modified: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Dutch.pm
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/lib/Date/Language/Dutch.pm	(original)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Dutch.pm	Sun Jun 15 12:29:44 2003
@@ -8,11 +8,12 @@
 use Date::Language ();
 use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
 @ISA = qw(Date::Language);
-$VERSION = "1.01";
+$VERSION = "1.02";
 
 @MoY  = qw(januari februari maart april mei juni juli
            augustus september oktober november december);
 @MoYs = map(substr($_, 0, 3), @MoY);
+$MoYs[2] = 'mrt'; # mrt is more common (Frank Maas)
 @DoW  = map($_ . "dag", qw(zon maan dins woens donder vrij zater));
 @DoWs = map(substr($_, 0, 2), @DoW);
 

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Finnish.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Finnish.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,45 @@
+##
+## Finnish tables
+## Contributed by Matthew Musgrove <muskrat at mindless.com>
+## Corrected by roke
+##
+
+package Date::Language::Finnish;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.01";
+
+# In Finnish, the names of the months and days are only capitalized at the beginning of sentences.
+ at MoY  = map($_ . "kuu", qw(tammi helmi maalis huhti touko kesä heinä elo syys loka marras joulu));
+ at DoW  = qw(sunnuntai maanantai tiistai keskiviikko torstai perjantai lauantai);
+
+# it is not customary to use abbreviated names of months or days
+# per Graham's suggestion:
+ at MoYs = @MoY;
+ at DoWs = @DoW;
+
+# the short form of ordinals
+ at Dsuf = ('.') x 31;
+
+# doesn't look like this is normally used...
+ at AMPM = qw(ap ip);
+
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+sub format_o { sprintf("%2de",$_[0]->[3]) }
+
+1;
\ No newline at end of file

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Gedeo.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Gedeo.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,51 @@
+##
+## Gedeo tables
+##
+
+package Date::Language::Gedeo;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "0.99";
+
+ at DoW = qw( Sanbbattaa Sanno Masano Roobe Hamusse Arbe Qiddamme);
+ at MoY = (
+"Oritto",
+"Birre'a",
+"Onkkollessa",
+"Saddasa",
+"Arrasa",
+"Qammo",
+"Ella",
+"Waacibajje",
+"Canissa",
+"Addolessa",
+"Bittitotessa",
+"Hegeya"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+$DoWs[0] = "Snb";
+$DoWs[1] = "Sno";
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = qw(gorsa warreti-udumma);
+
+ at Dsuf = (qw(th st nd rd th th th th th th)) x 3;
+ at Dsuf[11,12,13] = qw(th th th);
+ at Dsuf[30,31] = qw(th st);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Oromo.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Oromo.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,37 @@
+##
+## Oromo tables
+##
+
+package Date::Language::Oromo;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "0.99";
+
+ at DoW = qw(Dilbata Wiixata Qibxata Roobii Kamiisa Jimaata Sanbata);
+ at MoY = qw(Amajjii Guraandhala Bitooteessa Elba Caamsa Waxabajjii
+          Adooleessa Hagayya Fuulbana Onkololeessa Sadaasa Muddee);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = qw(WD WB);
+
+ at Dsuf = (qw(th st nd rd th th th th th th)) x 3;
+ at Dsuf[11,12,13] = qw(th th th);
+ at Dsuf[30,31] = qw(th st);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Sidama.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Sidama.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,37 @@
+##
+## Sidama tables
+##
+
+package Date::Language::Sidama;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "0.99";
+
+ at DoW = qw(Sambata Sanyo Maakisanyo Roowe Hamuse Arbe Qidaame);
+ at MoY = qw(January February March April May June
+          July August September October November December);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = qw(soodo hawwaro);
+
+ at Dsuf = (qw(th st nd rd th th th th th th)) x 3;
+ at Dsuf[11,12,13] = qw(th th th);
+ at Dsuf[30,31] = qw(th st);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Somali.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Somali.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,62 @@
+##
+## Somali tables
+##
+
+package Date::Language::Somali;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "0.99";
+
+ at DoW = qw(Axad Isniin Salaaso Arbaco Khamiis Jimco Sabti);
+ at MoY = (
+"Bisha Koobaad",
+"Bisha Labaad",
+"Bisha Saddexaad",
+"Bisha Afraad",
+"Bisha Shanaad",
+"Bisha Lixaad",
+"Bisha Todobaad",
+"Bisha Sideedaad",
+"Bisha Sagaalaad",
+"Bisha Tobnaad",
+"Bisha Kow iyo Tobnaad",
+"Bisha Laba iyo Tobnaad"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = (
+"Kob",
+"Lab",
+"Sad",
+"Afr",
+"Sha",
+"Lix",
+"Tod",
+"Sid",
+"Sag",
+"Tob",
+"KIT",
+"LIT"
+);
+ at AMPM = qw(SN GN);
+
+ at Dsuf = (qw(th st nd rd th th th th th th)) x 3;
+ at Dsuf[11,12,13] = qw(th th th);
+ at Dsuf[30,31] = qw(th st);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Swedish.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Swedish.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,40 @@
+##
+## Swedish tables
+## Contributed by Matthew Musgrove <muskrat at mindless.com>
+## Corrected by dempa
+##
+
+package Date::Language::Swedish;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.01";
+
+ at MoY  = qw(januari februari mars april maj juni juli augusti september oktober november december);
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at DoW  = map($_ . "dagen", qw(sön mån tis ons tors fre lör));
+ at DoWs = map { substr($_,0,2) } @DoW;
+
+# the ordinals are not typically used in modern times
+ at Dsuf = ('a' x 2, 'e' x 29);
+
+ at AMPM =   @{Date::Language::English::AMPM};
+
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+sub format_o { sprintf("%2de",$_[0]->[3]) }
+
+1;
\ No newline at end of file

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Tigrinya.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/Tigrinya.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,58 @@
+##
+## Tigrinya tables
+##
+
+package Date::Language::Tigrinya;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.00";
+
+ at DoW = qw(
+"\x{U1230}\x{U1295}\x{U1260}\x{U1275}",
+"\x{U1230}\x{U1291}\x{U12ed}",
+"\x{U1230}\x{U1209}\x{U1235}",
+"\x{U1228}\x{U1261}\x{U12d5}",
+"\x{U1213}\x{U1219}\x{U1235}",
+"\x{U12d3}\x{U122d}\x{U1262}",
+"\x{U1240}\x{U12f3}\x{U121d}"
+);
+ at MoY = qw(
+"\x{U1303}\x{U1295}\x{U12e9}\x{U12c8}\x{U122a}",
+"\x{U134c}\x{U1265}\x{U1229}\x{U12c8}\x{U122a}",
+"\x{U121b}\x{U122d}\x{U127d}",
+"\x{U12a4}\x{U1355}\x{U1228}\x{U120d}",
+"\x{U121c}\x{U12ed}",
+"\x{U1301}\x{U1295}",
+"\x{U1301}\x{U120b}\x{U12ed}",
+"\x{U12a6}\x{U1308}\x{U1235}\x{U1275}",
+"\x{U1234}\x{U1355}\x{U1274}\x{U121d}\x{U1260}\x{U122d}",
+"\x{U12a6}\x{U12ad}\x{U1270}\x{U12cd}\x{U1260}\x{U122d}",
+"\x{U1296}\x{U126c}\x{U121d}\x{U1260}\x{U122d}",
+"\x{U12f2}\x{U1234}\x{U121d}\x{U1260}\x{U122d}"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = (
+"\x{1295}/\x{1230}",
+"\x{12F5}/\x{1230}"
+);
+
+ at Dsuf = ("\x{12ed}" x 31);
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEritrean.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEritrean.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,93 @@
+##
+## Tigrinya-Eritrean tables
+##
+
+package Date::Language::TigrinyaEritrean;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.00";
+
+if ( $] >= 5.006 ) {
+ at DoW = (
+"\x{1230}\x{1295}\x{1260}\x{1275}",
+"\x{1230}\x{1291}\x{12ed}",
+"\x{1230}\x{1209}\x{1235}",
+"\x{1228}\x{1261}\x{12d5}",
+"\x{1213}\x{1219}\x{1235}",
+"\x{12d3}\x{122d}\x{1262}",
+"\x{1240}\x{12f3}\x{121d}"
+);
+ at MoY = (
+"\x{1303}\x{1295}\x{12e9}\x{12c8}\x{122a}",
+"\x{134c}\x{1265}\x{1229}\x{12c8}\x{122a}",
+"\x{121b}\x{122d}\x{127d}",
+"\x{12a4}\x{1355}\x{1228}\x{120d}",
+"\x{121c}\x{12ed}",
+"\x{1301}\x{1295}",
+"\x{1301}\x{120b}\x{12ed}",
+"\x{12a6}\x{1308}\x{1235}\x{1275}",
+"\x{1234}\x{1355}\x{1274}\x{121d}\x{1260}\x{122d}",
+"\x{12a6}\x{12ad}\x{1270}\x{12cd}\x{1260}\x{122d}",
+"\x{1296}\x{126c}\x{121d}\x{1260}\x{122d}",
+"\x{12f2}\x{1234}\x{121d}\x{1260}\x{122d}"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = (
+"\x{1295}/\x{1230}",
+"\x{12F5}/\x{1230}"
+);
+
+ at Dsuf = ("\x{12ed}" x 31);
+}
+else {
+ at DoW = (
+"ሰንበት",
+"ሰኑይ",
+"ሰሉስ",
+"ረቡዕ",
+"ሓሙስ",
+"ዓርቢ",
+"ቀዳም"
+);
+ at MoY = (
+"ጥሪ",
+"ለካቲት",
+"መጋቢት",
+"ሚያዝያ",
+"ግንቦት",
+"ሰነ",
+"ሓምለ",
+"ነሓሰ",
+"መስከረም",
+"ጥቅምቲ",
+"ሕዳር",
+"ታሕሳስ"
+);
+ at DoWs = map { substr($_,0,9) } @DoW;
+ at MoYs = map { substr($_,0,9) } @MoY;
+ at AMPM = (
+"ን/ሰ",
+"ድ/ሰ"
+);
+
+ at Dsuf = ("á‹­" x 31);
+}
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Added: trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEthiopian.pm
==============================================================================
--- (empty file)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Language/TigrinyaEthiopian.pm	Sun Jun 15 12:29:44 2003
@@ -0,0 +1,93 @@
+##
+## Tigrinya-Ethiopian tables
+##
+
+package Date::Language::TigrinyaEthiopian;
+
+use Date::Language ();
+use vars qw(@ISA @DoW @DoWs @MoY @MoYs @AMPM @Dsuf %MoY %DoW $VERSION);
+ at ISA = qw(Date::Language);
+$VERSION = "1.00";
+
+if ( $] >= 5.006 ) {
+ at DoW = (
+"\x{1230}\x{1295}\x{1260}\x{1275}",
+"\x{1230}\x{1291}\x{12ed}",
+"\x{1230}\x{1209}\x{1235}",
+"\x{1228}\x{1261}\x{12d5}",
+"\x{1213}\x{1219}\x{1235}",
+"\x{12d3}\x{122d}\x{1262}",
+"\x{1240}\x{12f3}\x{121d}"
+);
+ at MoY = (
+"\x{1303}\x{1295}\x{12e9}\x{12c8}\x{122a}",
+"\x{134c}\x{1265}\x{1229}\x{12c8}\x{122a}",
+"\x{121b}\x{122d}\x{127d}",
+"\x{12a4}\x{1355}\x{1228}\x{120d}",
+"\x{121c}\x{12ed}",
+"\x{1301}\x{1295}",
+"\x{1301}\x{120b}\x{12ed}",
+"\x{12a6}\x{1308}\x{1235}\x{1275}",
+"\x{1234}\x{1355}\x{1274}\x{121d}\x{1260}\x{122d}",
+"\x{12a6}\x{12ad}\x{1270}\x{12cd}\x{1260}\x{122d}",
+"\x{1296}\x{126c}\x{121d}\x{1260}\x{122d}",
+"\x{12f2}\x{1234}\x{121d}\x{1260}\x{122d}"
+);
+ at DoWs = map { substr($_,0,3) } @DoW;
+ at MoYs = map { substr($_,0,3) } @MoY;
+ at AMPM = (
+"\x{1295}/\x{1230}",
+"\x{12F5}/\x{1230}"
+);
+
+ at Dsuf = ("\x{12ed}" x 31);
+}
+else {
+ at DoW = (
+"ሰንበት",
+"ሰኑይ",
+"ሰሉስ",
+"ረቡዕ",
+"ሓሙስ",
+"ዓርቢ",
+"ቀዳም"
+);
+ at MoY = (
+"ጃንዩወሪ",
+"ፌብሩወሪ",
+"ማርች",
+"ኤፕረል",
+"ሜይ",
+"ጁን",
+"ጁላይ",
+"ኦገስት",
+"ሴፕቴምበር",
+"ኦክተውበር",
+"ኖቬምበር",
+"ዲሴምበር"
+);
+ at DoWs = map { substr($_,0,9) } @DoW;
+ at MoYs = map { substr($_,0,9) } @MoY;
+ at AMPM = (
+"ን/ሰ",
+"ድ/ሰ"
+);
+
+ at Dsuf = ("á‹­" x 31);
+}
+
+ at MoY{@MoY}  = (0 .. scalar(@MoY));
+ at MoY{@MoYs} = (0 .. scalar(@MoYs));
+ at DoW{@DoW}  = (0 .. scalar(@DoW));
+ at DoW{@DoWs} = (0 .. scalar(@DoWs));
+
+# Formatting routines
+
+sub format_a { $DoWs[$_[0]->[6]] }
+sub format_A { $DoW[$_[0]->[6]] }
+sub format_b { $MoYs[$_[0]->[4]] }
+sub format_B { $MoY[$_[0]->[4]] }
+sub format_h { $MoYs[$_[0]->[4]] }
+sub format_p { $_[0]->[2] >= 12 ?  $AMPM[1] : $AMPM[0] }
+
+1;

Modified: trunk/orca/packages/TimeDate-1.16/lib/Date/Parse.pm
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/lib/Date/Parse.pm	(original)
+++ trunk/orca/packages/TimeDate-1.16/lib/Date/Parse.pm	Sun Jun 15 12:29:44 2003
@@ -1,4 +1,4 @@
-# Date::Parse $Id: //depot/TimeDate/lib/Date/Parse.pm#15 $
+# Date::Parse $Id: //depot/TimeDate/lib/Date/Parse.pm#22 $
 #
 # Copyright (c) 1995 Graham Barr. All rights reserved. This program is free
 # software; you can redistribute it and/or modify it under the same terms
@@ -17,7 +17,7 @@
 @ISA = qw(Exporter);
 @EXPORT = qw(&strtotime &str2time &strptime);
 
-$VERSION = "2.24";
+$VERSION = "2.27";
 
 my %month = (
 	january		=> 0,
@@ -75,7 +75,7 @@
   my $dtstr = lc shift;
   my $merid = 24;
 
-  my($year,$month,$day,$hh,$mm,$ss,$zone,$dst);
+  my($year,$month,$day,$hh,$mm,$ss,$zone,$dst,$frac);
 
   $zone = tz_offset(shift) if @_;
 
@@ -85,15 +85,17 @@
 
   # ignore day names
   $dtstr =~ s#([\d\w\s])[\.\,]\s#$1 #sog;
+  $dtstr =~ s/,/ /g;
   $dtstr =~ s#($daypat)\s*(den\s)?# #o;
   # Time: 12:00 or 12:00:00 with optional am/pm
+
+  return unless $dtstr =~ /\S/;
   
-  if ($dtstr =~ s/(?:^|\s)(\d{4})([-:]?)(\d\d?)\2(\d\d?)(?:[Tt ](\d\d?)(?:([-:]?)(\d\d?)(?:\6(\d\d?)(?:[.,]\d+)?)?)?)?\b/ /) {
-    ($year,$month,$day,$hh,$mm,$ss) = ($1,$3-1,$4,$5,$7,$8);
+  if ($dtstr =~ s/\s(\d{4})([-:]?)(\d\d?)\2(\d\d?)(?:[Tt ](\d\d?)(?:([-:]?)(\d\d?)(?:\6(\d\d?)(?:[.,](\d+))?)?)?)?(?=\D)/ /) {
+    ($year,$month,$day,$hh,$mm,$ss,$frac) = ($1,$3-1,$4,$5,$7,$8,$9);
   }
 
   unless (defined $hh) {
-
     if ($dtstr =~ s#[:\s](\d\d?):(\d\d?)(:(\d\d?)(?:\.\d+)?)?\s*(?:([ap])\.?m?\.?)?\s# #o) {
       ($hh,$mm,$ss) = ($1,$2,$4 || 0);
       $merid = $ampm{$5} if $5;
@@ -107,6 +109,11 @@
     }
   }
     
+  if (defined $hh and $hh <= 12 and $dtstr =~ s# ([ap])\.?m?\.?\s# #o) {
+    $merid = $ampm{$1};
+  }
+
+
   unless (defined $year) {
     # Date: 12-June-96 (using - . or /)
     
@@ -153,7 +160,7 @@
     $zone = tz_offset($1);
     return unless defined $zone;
   }
-  elsif ($dtstr =~ s#\s([a-z]{3,4})?([\-\+]?)-?(\d\d?)(\d\d)?(00)?\s# #o) {
+  elsif ($dtstr =~ s#\s([a-z]{3,4})?([\-\+]?)-?(\d\d?):?(\d\d)?(00)?\s# #o) {
     my $m = defined($4) ? "$2$4" : 0;
     my $h = "$2$3";
     $zone = defined($1) ? tz_offset($1) : 0;
@@ -189,6 +196,7 @@
   $year -= 1900 if defined $year && $year > 1900;
 
   $zone += 3600 if defined $zone && $dst;
+  $ss += "0.$frac" if $frac;
 
   return ($ss,$mm,$hh,$day,$month,$year,$zone);
 }
@@ -230,6 +238,9 @@
  $mm    ||= 0;
  $ss    ||= 0;
 
+ my $frac = $ss - int($ss);
+ $ss = int $ss;
+
  $month = $lt[4]
 	unless(defined $month);
 
@@ -269,7 +280,7 @@
      	        ne join("",(localtime(-1))[0..5]);
  }
 
- return $result;
+ return $result + $frac;
 }
 
 1;
@@ -312,20 +323,11 @@
 =head1 MULTI-LANGUAGE SUPPORT
 
 Date::Parse is capable of parsing dates in several languages, these are
-English, French, German and Italian. Changing the language is done via
-a static method call, for example
-
-	Date::Parse->language('German');
-
-will cause Date::Parse to attempt to parse any subsequent dates in German.
-
-This is only a first pass, I am considering changing this to be
+English, French, German and Italian.
 
 	$lang = Date::Language->new('German');
 	$lang->str2time("25 Jun 1996 21:09:55 +0100");
 
-I am open to suggestions on this.
-
 =head1 EXAMPLE DATES
 
 Below is a sample list of dates that are known to be parsable with Date::Parse
@@ -342,6 +344,11 @@
  1999 10:02:18 "GMT"
  16 Nov 94 22:28:20 PST 
 
+=head1 LIMITATION
+
+Date::Parse uses Time::Local internally, so is limited to only parsing dates
+which result in valid values for Time::Local::timelocal
+
 =head1 BUGS
 
 When both the month and the date are specified in the date as numbers
@@ -368,5 +375,5 @@
 
 =cut
 
-# $Id: //depot/TimeDate/lib/Date/Parse.pm#15 $
+# $Id: //depot/TimeDate/lib/Date/Parse.pm#22 $
 

Modified: trunk/orca/packages/TimeDate-1.16/t/date.t
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/t/date.t	(original)
+++ trunk/orca/packages/TimeDate-1.16/t/date.t	Sun Jun 15 12:29:44 2003
@@ -130,12 +130,15 @@
 
 @data = split(/\n/, $data);
 
-print "1..", scalar(@data),"\n";
-$loop = 1;
+print "1..", 1+ at data,"\n";
+
+print  defined(str2time("")) ? "not ok 1\n" : "ok 1\n";
+
+$loop = 2;
 
 foreach (@data)
 {
- $time = str2time($_);
+ $time = int str2time($_);
 
  if(defined $time)
   {

Modified: trunk/orca/packages/TimeDate-1.16/t/format.t
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/t/format.t	(original)
+++ trunk/orca/packages/TimeDate-1.16/t/format.t	Sun Jun 15 12:29:44 2003
@@ -2,7 +2,7 @@
 use Date::Format qw(ctime time2str);
 use Date::Language;
 
-print "1..150\n";
+print "1..152\n";
 
 my $i = 1;
 
@@ -39,6 +39,7 @@
 %d	07
 %e	 7
 %D	09/07/99
+%G	1026
 %h	Sep
 %H	13
 %I	01
@@ -179,3 +180,5 @@
 %Oq	III
 %OY	MCMXCIX
 %Oy	XCIX
+316051200	# Mon Jan  7 00:00:00 1980 GMT
+%G	0

Modified: trunk/orca/packages/TimeDate-1.16/t/getdate.t
==============================================================================
--- trunk/orca/packages/TimeDate-1.14/t/getdate.t	(original)
+++ trunk/orca/packages/TimeDate-1.16/t/getdate.t	Sun Jun 15 12:29:44 2003
@@ -13,12 +13,14 @@
 92/01/02 12:01 AM		     ;694310460
 92/01/02 12:01 PM		     ;694353660
 2002-11-02 11pm GMT		     ;1036278000
+2002-11-02 11 pm GMT		     ;1036278000
 1995-01-24  GMT                      ;790905600
 1995-01-24  BST                      ;790902000
 1995-06-24  GMT                      ;803952000
 1995-06-24  BST                      ;803948400
 1992-1-2 12:01 GMT		     ;694353660
 Wed, 16 Jun 94 07:29:35 CST    	     ;771773375
+Wed,16 Jun 94 07:29:35 CST    	     ;771773375
 Wed, 16 Nov 94 07:29:35 CST 	     ;784992575
 Mon, 21 Nov 94 07:42:23 CST 	     ;785425343
 Mon, 21 Nov 94 04:28:18 CST 	     ;785413698
@@ -129,6 +131,7 @@
 Tue, 15 Nov 1994 0:18:38 -0800 	     ;784887518
 Jul 13 1999 1:23P GMT		     ;931872180
 Jul 13 1999 1:23P.M GMT		     ;931872180
+Jul 13 1999 1:23P.M. GMT	     ;931872180
 2001-02-26T13:44:12-0700	     ;983220252
 2001-02-26T13:44-0700		     ;983220240
 2001-02-26T13-0700		     ;983217600
@@ -136,6 +139,9 @@
 2001-02-26T13-44-0700		     ;983220240
 2001-02-26T13-0700		     ;983217600
 07/Nov/2000:16:45:56 +0100	     ;973611956
+2002-11-07T23:31:49-05:00	     ;1036729909
+2003-02-17T07:45:56Z		     ;1045467956
+2003-02-17T08:14:07.198189+0000	     ;1045469647.198189
 !;
 
 require Time::Local;
@@ -177,15 +183,15 @@
 
     $time_expect += $offset;
 
-    if($time==$time_expect) {
+    if(defined($time) and $time==$time_expect) {
 	print "ok $loop\n";
     }
     else {
         require Date::Format;
 	print "-"x50,"\nFAIL $loop\n";
         printf "%s\nDiff:    %d\n", $str, $time - $time_expect;
-        printf "Expect: %10d %s",$time_expect,Date::Format::ctime($time_expect);
-        printf "Got:    %10d %s",$time, Date::Format::ctime($time);
+        printf "Expect: %10f %s",$time_expect,Date::Format::ctime($time_expect);
+        printf "Got:    %10f %s",$time, Date::Format::ctime($time);
     }
     $loop++;
 }



More information about the Orca-checkins mailing list