Since DateTime aims at cleaning up the module mess related to time,
wouldn't it be a good thing to avoid using Date:: and Time:: modules
altogether?
Particularely in this case, I really don't see the need to use an
external module. It only requires one line of Perl code to figure out
whether a given year is a leap year or a common year in the Gregorian
calendar. Take your pick:
sub isleap {
$_[0] % 4 ? 0 : $_[0] % 100 ? 1 : $_[0] % 400 ? 0 : 1;
}
sub isleap {
($_[0] % 4 == 0 && $_[0] % 100 != 0) || $_[0] % 400 == 0;
}
sub isleap {
(! ($_[0] % 4) && ($_[0] % 100)) || ! ($_[0] % 400);
}
Peter
--
Peter J. Acklam - [EMAIL PROTECTED] - http://home.online.no/~pjacklam