Commit 9e8e701d by Dave Love Committed by Dave Love

intdoc.in: Add entry for DATE_AND_TIME.

1998-07-05  Dave Love  <d.love@dl.ac.uk>
	* intdoc.in: Add entry for DATE_AND_TIME.
	* intrin.def: Add implementation for DATE_AND_TIME.  Make second
	and third args of SYSTEM_CLOCK optional.
	* com.c (ffecom_expr_intrinsic_): New case for DATE_AND_TIME.
	* com-rt.def (FFECOM_gfrtSYSTEM_CLOCK): Call G77_system_clock_0,
	not system_clock_.
	(FFECOM_gfrtDATE_AND_TIME): New DEFGFRT.

From-SVN: r20938
parent 55e859f2
1998-07-05 Dave Love <d.love@dl.ac.uk>
* intdoc.in: Add entry for DATE_AND_TIME.
* intrin.def: Add implementation for DATE_AND_TIME. Make second
and third args of SYSTEM_CLOCK optional.
* com.c (ffecom_expr_intrinsic_): New case for DATE_AND_TIME.
* com-rt.def (FFECOM_gfrtSYSTEM_CLOCK): Call G77_system_clock_0,
not system_clock_.
(FFECOM_gfrtDATE_AND_TIME): New DEFGFRT.
Wed Jul 1 11:19:13 1998 Craig Burley <burley@gnu.org> Wed Jul 1 11:19:13 1998 Craig Burley <burley@gnu.org>
Fix 980701-1.f (which was producing "unaligned trap" Fix 980701-1.f (which was producing "unaligned trap"
......
...@@ -143,6 +143,7 @@ DEFGFRT (FFECOM_gfrtDASIN, "d_asin", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE) ...@@ -143,6 +143,7 @@ DEFGFRT (FFECOM_gfrtDASIN, "d_asin", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtDATAN, "d_atan", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE) DEFGFRT (FFECOM_gfrtDATAN, "d_atan", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtDATAN2, "d_atn2", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE) DEFGFRT (FFECOM_gfrtDATAN2, "d_atn2", FFECOM_rttypeDOUBLE_, "&d", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtDATE, "G77_date_0", FFECOM_rttypeVOID_, "&a", FALSE, FALSE) DEFGFRT (FFECOM_gfrtDATE, "G77_date_0", FFECOM_rttypeVOID_, "&a", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtDATE_AND_TIME, "G77_date_and_time_0", FFECOM_rttypeVOID_, "&a&a&a&i", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtL_BESJ0, "j0", FFECOM_rttypeDOUBLE_, "d", FALSE, FALSE) DEFGFRT (FFECOM_gfrtL_BESJ0, "j0", FFECOM_rttypeDOUBLE_, "d", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtL_BESJ1, "j1", FFECOM_rttypeDOUBLE_, "d", FALSE, FALSE) DEFGFRT (FFECOM_gfrtL_BESJ1, "j1", FFECOM_rttypeDOUBLE_, "d", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtL_BESJN, "jn", FFECOM_rttypeDOUBLE_, "id", FALSE, FALSE) DEFGFRT (FFECOM_gfrtL_BESJN, "jn", FFECOM_rttypeDOUBLE_, "id", FALSE, FALSE)
...@@ -234,7 +235,7 @@ DEFGFRT (FFECOM_gfrtSRAND, "G77_srand_0", FFECOM_rttypeVOID_, "&i", FALSE, FALSE ...@@ -234,7 +235,7 @@ DEFGFRT (FFECOM_gfrtSRAND, "G77_srand_0", FFECOM_rttypeVOID_, "&i", FALSE, FALSE
DEFGFRT (FFECOM_gfrtSTAT, "G77_stat_0", FFECOM_rttypeINTEGER_, "&a&i", FALSE, FALSE) DEFGFRT (FFECOM_gfrtSTAT, "G77_stat_0", FFECOM_rttypeINTEGER_, "&a&i", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtSYMLNK, "G77_symlnk_0", FFECOM_rttypeINTEGER_, "&a&a", FALSE, FALSE) DEFGFRT (FFECOM_gfrtSYMLNK, "G77_symlnk_0", FFECOM_rttypeINTEGER_, "&a&a", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtSYSTEM, "G77_system_0", FFECOM_rttypeINTEGER_, "&a", FALSE, FALSE) DEFGFRT (FFECOM_gfrtSYSTEM, "G77_system_0", FFECOM_rttypeINTEGER_, "&a", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtSYSTEM_CLOCK, "system_clock_", FFECOM_rttypeVOID_, "&i&i&i", FALSE, FALSE) DEFGFRT (FFECOM_gfrtSYSTEM_CLOCK, "G77_system_clock_0", FFECOM_rttypeVOID_, "&i&i&i", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtTAN, "r_tan", FFECOM_rttypeREAL_F2C_, "&f", FALSE, FALSE) DEFGFRT (FFECOM_gfrtTAN, "r_tan", FFECOM_rttypeREAL_F2C_, "&f", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtTANH, "r_tanh", FFECOM_rttypeREAL_F2C_, "&f", FALSE, FALSE) DEFGFRT (FFECOM_gfrtTANH, "r_tanh", FFECOM_rttypeREAL_F2C_, "&f", FALSE, FALSE)
DEFGFRT (FFECOM_gfrtTIME, "G77_time_0", FFECOM_rttypeLONGINT_, 0, FALSE, FALSE) DEFGFRT (FFECOM_gfrtTIME, "G77_time_0", FFECOM_rttypeLONGINT_, 0, FALSE, FALSE)
......
...@@ -5204,6 +5204,7 @@ ffecom_expr_intrinsic_ (ffebld expr, tree dest_tree, ...@@ -5204,6 +5204,7 @@ ffecom_expr_intrinsic_ (ffebld expr, tree dest_tree,
case FFEINTRIN_impCHDIR_func: case FFEINTRIN_impCHDIR_func:
case FFEINTRIN_impCHMOD_func: case FFEINTRIN_impCHMOD_func:
case FFEINTRIN_impDATE: case FFEINTRIN_impDATE:
case FFEINTRIN_impDATE_AND_TIME:
case FFEINTRIN_impDBESJ0: case FFEINTRIN_impDBESJ0:
case FFEINTRIN_impDBESJ1: case FFEINTRIN_impDBESJ1:
case FFEINTRIN_impDBESJN: case FFEINTRIN_impDBESJN:
......
...@@ -2468,3 +2468,24 @@ scheduled alarm was due to be delivered, or zero if there was no ...@@ -2468,3 +2468,24 @@ scheduled alarm was due to be delivered, or zero if there was no
previously scheduled alarm. previously scheduled alarm.
@xref{Signal Intrinsic (subroutine)}. @xref{Signal Intrinsic (subroutine)}.
") ")
DEFDOC (DATE_AND_TIME, "Get the current date and time.", "\
Returns:
@table @var
@item @1@
The date in the form @var{ccyymmdd}: century, year, month and day;
@item @2@
The time in the form @samp{@var{hhmmss.ss}}: hours, minutes, seconds
and milliseconds;
@item @3@
The difference between local time and UTC (GMT) in the form @var{Shhmm}:
sign, hours and minutes, e.g.@ @samp{-0500} (winter in New York);
@item @4@
The year, month of the year, day of the month, time difference in
minutes from UTC, hour of the day, minutes of the hour and milliseconds
of the second in successive values of the array.
@end table
On systems where a millisecond timer isn't available, the millisecond
value is returned as zero.
")
...@@ -184,7 +184,7 @@ ...@@ -184,7 +184,7 @@
* Date Intrinsic:: Get current date as dd-Mon-yy. * Date Intrinsic:: Get current date as dd-Mon-yy.
@end ifset @end ifset
@ifset familyF90 @ifset familyF90
* Date_and_Time Intrinsic:: (Reserved for future use.) * Date_and_Time Intrinsic:: Get the current date and time.
@end ifset @end ifset
@ifset familyF2U @ifset familyF2U
* DbesJ0 Intrinsic:: Bessel function (archaic). * DbesJ0 Intrinsic:: Bessel function (archaic).
...@@ -2977,10 +2977,46 @@ for the current (or any) date. ...@@ -2977,10 +2977,46 @@ for the current (or any) date.
@cindex Date_and_Time intrinsic @cindex Date_and_Time intrinsic
@cindex intrinsics, Date_and_Time @cindex intrinsics, Date_and_Time
This intrinsic is not yet implemented. @noindent
The name is, however, reserved as an intrinsic. @example
Use @samp{EXTERNAL Date_and_Time} to use this name for an CALL Date_and_Time(@var{Date}, @var{Ftime}, @var{Zone}, @var{Values})
external procedure. @end example
@noindent
@var{Date}: @code{CHARACTER}; scalar; INTENT(OUT).
@noindent
@var{Ftime}: @code{CHARACTER}; OPTIONAL; scalar; INTENT(OUT).
@noindent
@var{Zone}: @code{CHARACTER}; OPTIONAL; scalar; INTENT(OUT).
@noindent
@var{Values}: @code{INTEGER(KIND=1)}; OPTIONAL; DIMENSION(8); INTENT(OUT).
@noindent
Intrinsic groups: @code{f90}.
@noindent
Description:
Returns
@table @var
@item Date
The date in the form @var{ccyymmdd}: century, year, month and day;
@item Ftime
The time in the form @samp{@var{hhmmss.ss}}: hours, minutes, seconds
and milliseconds;
@item Zone
The difference between local time and UTC (GMT) in the form @var{Shhmm}:
sign, hours and minutes, e.g.@ @samp{-0500} (winter in New York);
@item Values
The year, month of the year, day of the month, time difference in
minutes from UTC, hour of the day, minutes of the hour and milliseconds
of the second in successive values of the array.
@end table
On systems where a millisecond timer isn't available, the millisecond
value is returned as zero.
@end ifset @end ifset
@ifset familyF2U @ifset familyF2U
...@@ -10006,10 +10042,10 @@ CALL System_Clock(@var{Count}, @var{Rate}, @var{Max}) ...@@ -10006,10 +10042,10 @@ CALL System_Clock(@var{Count}, @var{Rate}, @var{Max})
@var{Count}: @code{INTEGER(KIND=1)}; scalar; INTENT(OUT). @var{Count}: @code{INTEGER(KIND=1)}; scalar; INTENT(OUT).
@noindent @noindent
@var{Rate}: @code{INTEGER(KIND=1)}; scalar; INTENT(OUT). @var{Rate}: @code{INTEGER(KIND=1)}; OPTIONAL; scalar; INTENT(OUT).
@noindent @noindent
@var{Max}: @code{INTEGER(KIND=1)}; scalar; INTENT(OUT). @var{Max}: @code{INTEGER(KIND=1)}; OPTIONAL; scalar; INTENT(OUT).
@noindent @noindent
Intrinsic groups: @code{f90}. Intrinsic groups: @code{f90}.
......
...@@ -1377,7 +1377,7 @@ DEFSPEC (DATE_AND_TIME, ...@@ -1377,7 +1377,7 @@ DEFSPEC (DATE_AND_TIME,
"DATE_AND_TIME", "DATE_AND_TIME",
FALSE, FALSE,
FFEINTRIN_familyF90, FFEINTRIN_familyF90,
FFEINTRIN_impNONE FFEINTRIN_impDATE_AND_TIME
) )
DEFSPEC (DBESJ0, DEFSPEC (DBESJ0,
"DBESJ0", "DBESJ0",
...@@ -3233,6 +3233,7 @@ DEFIMP (CPU_TIME, "CPU_TIME", SECOND,,, "--:-:Seconds=R*w") ...@@ -3233,6 +3233,7 @@ DEFIMP (CPU_TIME, "CPU_TIME", SECOND,,, "--:-:Seconds=R*w")
DEFIMP (CTIME_func, "CTIME_func", CTIME,,, "A1*:-:STime=I*") DEFIMP (CTIME_func, "CTIME_func", CTIME,,, "A1*:-:STime=I*")
DEFIMP (CTIME_subr, "CTIME_subr", CTIME,,, "--:-:Result=A1w,STime=I*") DEFIMP (CTIME_subr, "CTIME_subr", CTIME,,, "--:-:Result=A1w,STime=I*")
DEFIMP (DATE, "DATE", DATE,,, "--:-:Date=A1w") DEFIMP (DATE, "DATE", DATE,,, "--:-:Date=A1w")
DEFIMP (DATE_AND_TIME, "DATE_AND_TIME", DATE_AND_TIME,,, "--:-:Date=A1w,Time=?A1w,Zone=?A1w,Values=?I1(8)w")
DEFIMP (DBESJ0, "DBESJ0", L_BESJ0,,, "R2:-:X=R2") DEFIMP (DBESJ0, "DBESJ0", L_BESJ0,,, "R2:-:X=R2")
DEFIMP (DBESJ1, "DBESJ1", L_BESJ1,,, "R2:-:X=R2") DEFIMP (DBESJ1, "DBESJ1", L_BESJ1,,, "R2:-:X=R2")
DEFIMP (DBESJN, "DBESJN", L_BESJN,,, "R2:-:N=I*,X=R2") DEFIMP (DBESJN, "DBESJN", L_BESJN,,, "R2:-:N=I*,X=R2")
...@@ -3336,7 +3337,7 @@ DEFIMP (SYMLNK_func, "SYMLNK_func", SYMLNK,,, "I1:-:Path1=A1,Path2=A1") ...@@ -3336,7 +3337,7 @@ DEFIMP (SYMLNK_func, "SYMLNK_func", SYMLNK,,, "I1:-:Path1=A1,Path2=A1")
DEFIMP (SYMLNK_subr, "SYMLNK_subr", SYMLNK,,, "--:-:Path1=A1,Path2=A1,Status=?I1w") DEFIMP (SYMLNK_subr, "SYMLNK_subr", SYMLNK,,, "--:-:Path1=A1,Path2=A1,Status=?I1w")
DEFIMP (SYSTEM_func, "SYSTEM_func", SYSTEM,SYSTEM,SYSTEM,"I1:-:Command=A1") DEFIMP (SYSTEM_func, "SYSTEM_func", SYSTEM,SYSTEM,SYSTEM,"I1:-:Command=A1")
DEFIMP (SYSTEM_subr, "SYSTEM_subr", SYSTEM,,, "--:-:Command=A1,Status=?I1w") DEFIMP (SYSTEM_subr, "SYSTEM_subr", SYSTEM,,, "--:-:Command=A1,Status=?I1w")
DEFIMP (SYSTEM_CLOCK, "SYSTEM_CLOCK", SYSTEM_CLOCK,,, "--:-:Count=I1w,Rate=I1w,Max=I1w") DEFIMP (SYSTEM_CLOCK, "SYSTEM_CLOCK", SYSTEM_CLOCK,,, "--:-:Count=I1w,Rate=?I1w,Max=?I1w")
DEFIMP (TIME8, "TIME8", TIME,,, "I2:-:") DEFIMP (TIME8, "TIME8", TIME,,, "I2:-:")
DEFIMP (TIME_unix, "TIME_unix", TIME,,, "I1:-:") DEFIMP (TIME_unix, "TIME_unix", TIME,,, "I1:-:")
DEFIMP (TIME_vxt, "TIME_vxt", VXTTIME,,, "--:-:Time=A1[8]w") DEFIMP (TIME_vxt, "TIME_vxt", VXTTIME,,, "--:-:Time=A1[8]w")
......
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