gri6507 has asked for the wisdom of the Perl Monks concerning the following question:
Name "Date::Manip::Lang::english::Language" used only once: possible typo at Date/Manip/Base.pm line 1844. Not an ARRAY reference at Date/Manip/Date.pm line 1351.
I do not understand what it means or how to work around it. Does anyone have any suggestions?
use strict; use warnings; use Date::Manip; my @dateObject; push @dateObject, ParseDateString('1/12/2010 10:44:49 AM'); push @dateObject, ParseDateString('1/12/2010 10:44:59 AM'); print "Delta is " . interval_to_sec(DateCalc(@dateObject)) . " seconds +\n"; # parse interval string and yield seconds sub interval_to_sec { my ($intv) = @_; my ($sec) = 0; my $sign = ($intv =~ /^-/) ? -1 : 1; my @f = reverse(split(/:/, $intv)); # use just 5 least significant fields $sec = $f[0]; $sec += $f[1] * 60; $sec += $f[2] * 3600; $sec += $f[3] * 86400; $sec += $f[4] * 604800; # 7 days $sec += $f[5] * 2629800; # 30.4 days (365.25 / 12) $sec += $f[6] * 31557600; # 365.25 days (Julian year) return $sign * $sec; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: PAR::packer with Date::Manip gives error
by almut (Canon) on Jan 12, 2010 at 21:11 UTC | |
by gri6507 (Deacon) on Jan 12, 2010 at 21:21 UTC | |
by almut (Canon) on Jan 12, 2010 at 22:08 UTC | |
by gri6507 (Deacon) on Jan 12, 2010 at 22:13 UTC | |
by Khen1950fx (Canon) on Jan 12, 2010 at 22:01 UTC | |
|
Re: PAR::packer with Date::Manip gives error
by Anonymous Monk on Jan 12, 2010 at 22:37 UTC |