Commit 37159e91 by Craig Burley Committed by Craig Burley

Fix IDATE (VXT) intrinsic

From-SVN: r25551
parent ba0b1e43
Wed Mar 3 00:57:56 1999 Craig Burley <craig@jcb-sc.com>
* news.texi: IDATE (VXT) fixed to return year as 0..99.
Wed Mar 3 00:43:49 1999 Craig Burley <craig@jcb-sc.com> Wed Mar 3 00:43:49 1999 Craig Burley <craig@jcb-sc.com>
* g77.texi: Add remaining changes pending from Dave Love. * g77.texi: Add remaining changes pending from Dave Love.
......
...@@ -65,6 +65,17 @@ somewhat more difficult. ...@@ -65,6 +65,17 @@ somewhat more difficult.
@heading In @code{egcs} 1.2: @heading In @code{egcs} 1.2:
@itemize @bullet @itemize @bullet
@item @item
Fix the @code{IDate} Intrinsic (VXT)
so the returned year is in the documented, non-Y2K-compliant range
of 0--99,
instead of being returned as 100 in the year 2000.
@ifnothtml
@xref{IDate Intrinsic (VXT)},
for more information.
@end ifnothtml
@item
Fix @code{g77} so it no longer crashes when compiling Fix @code{g77} so it no longer crashes when compiling
I/O statements using keywords that define @code{INTEGER} values, I/O statements using keywords that define @code{INTEGER} values,
such as @samp{IOSTAT=@var{j}}, such as @samp{IOSTAT=@var{j}},
......
1999-03-03 Craig Burley <craig@jcb-sc.com>
* libU77/vxtidate_.c (G77_vxtidate_0): Truncate
year to last two digits (i.e. modulo 100), as per
documentation and (documented) Y2K non-compliance.
1999-02-20 Craig Burley <craig@jcb-sc.com> 1999-02-20 Craig Burley <craig@jcb-sc.com>
From Krister Walfridsson <cato@df.lth.se>: From Krister Walfridsson <cato@df.lth.se>:
......
...@@ -48,7 +48,7 @@ int G77_vxtidate_0 (integer *m, integer *d, integer *y) ...@@ -48,7 +48,7 @@ int G77_vxtidate_0 (integer *m, integer *d, integer *y)
time_t tim; time_t tim;
tim = time(NULL); tim = time(NULL);
lt = localtime(&tim); lt = localtime(&tim);
*y = lt->tm_year; *y = lt->tm_year % 100;
*m = lt->tm_mon+1; *m = lt->tm_mon+1;
*d = lt->tm_mday; *d = lt->tm_mday;
return 0; return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment