From: Rafael Garcia-Suarez Date: Thu, 15 Mar 2007 09:35:14 +0000 (+0000) Subject: Make the isdst argument to asctime and mktime default to -1 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c1646883872c5259818f567a798ce6b27de42050;p=p5sagit%2Fp5-mst-13.2.git Make the isdst argument to asctime and mktime default to -1 instead of 0, as suggested by Mike Schilli. p4raw-id: //depot/perl@30590 --- diff --git a/ext/POSIX/POSIX.pm b/ext/POSIX/POSIX.pm index 3813e97..fbbd253 100644 --- a/ext/POSIX/POSIX.pm +++ b/ext/POSIX/POSIX.pm @@ -4,7 +4,7 @@ use warnings; our(@ISA, %EXPORT_TAGS, @EXPORT_OK, @EXPORT, $AUTOLOAD, %SIGRT) = (); -our $VERSION = "1.12"; +our $VERSION = "1.13"; use AutoLoader; diff --git a/ext/POSIX/POSIX.pod b/ext/POSIX/POSIX.pod index 124d0bd..e99a2b1 100644 --- a/ext/POSIX/POSIX.pod +++ b/ext/POSIX/POSIX.pod @@ -125,8 +125,8 @@ and it is called thusly $wday, $yday, $isdst); The C<$mon> is zero-based: January equals C<0>. The C<$year> is -1900-based: 2001 equals C<101>. The C<$wday>, C<$yday>, and C<$isdst> -default to zero (and the first two are usually ignored anyway). +1900-based: 2001 equals C<101>. C<$wday> and C<$yday> default to zero +(and are usually ignored anyway), and C<$isdst> defaults to -1. =item asin @@ -857,7 +857,7 @@ Convert date/time info to a calendar time. Synopsis: - mktime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = 0) + mktime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = -1) The month (C), weekday (C), and yearday (C) begin at zero. I.e. January is 0, not 1; Sunday is 0, not 1; January 1st is 0, not 1. The diff --git a/ext/POSIX/POSIX.xs b/ext/POSIX/POSIX.xs index 8f51750..207d02a 100644 --- a/ext/POSIX/POSIX.xs +++ b/ext/POSIX/POSIX.xs @@ -1727,7 +1727,7 @@ tcsendbreak(fd, duration) int duration char * -asctime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = 0) +asctime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = -1) int sec int min int hour @@ -1781,7 +1781,7 @@ difftime(time1, time2) Time_t time2 SysRetLong -mktime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = 0) +mktime(sec, min, hour, mday, mon, year, wday = 0, yday = 0, isdst = -1) int sec int min int hour