-
- Downloads
Fortran: update DATE_AND_TIME intrinsic for Fortran 2018 [PR96580]
Fortran 2018 allows a non-default integer kind for its VALUES argument if it has a decimal exponent range of at least four. Update checks, library implementation and documentation. gcc/fortran/ChangeLog: PR fortran/96580 * check.cc (array_size_check): New helper function. (gfc_check_date_and_time): Use it for checking minimum size of VALUES argument. Update kind check to Fortran 2018. * intrinsic.texi: Fix documentation of DATE_AND_TIME. libgfortran/ChangeLog: PR fortran/96580 * intrinsics/date_and_time.c (date_and_time): Handle VALUES argument for kind=2 and kind=16 (if available). gcc/testsuite/ChangeLog: PR fortran/96580 * gfortran.dg/date_and_time_2.f90: New test. * gfortran.dg/date_and_time_3.f90: New test. * gfortran.dg/date_and_time_4.f90: New test.
Showing
- gcc/fortran/check.cc 48 additions, 0 deletionsgcc/fortran/check.cc
- gcc/fortran/intrinsic.texi 20 additions, 19 deletionsgcc/fortran/intrinsic.texi
- gcc/testsuite/gfortran.dg/date_and_time_2.f90 21 additions, 0 deletionsgcc/testsuite/gfortran.dg/date_and_time_2.f90
- gcc/testsuite/gfortran.dg/date_and_time_3.f90 29 additions, 0 deletionsgcc/testsuite/gfortran.dg/date_and_time_3.f90
- gcc/testsuite/gfortran.dg/date_and_time_4.f90 30 additions, 0 deletionsgcc/testsuite/gfortran.dg/date_and_time_4.f90
- libgfortran/intrinsics/date_and_time.c 29 additions, 3 deletionslibgfortran/intrinsics/date_and_time.c
Loading
Please register or sign in to comment