[Bug fortran/61429] New: SYSTEM_CLOCK used with non-default integer kind does not produce warning
thatcadguy at gmail dot com
gcc-bugzilla@gcc.gnu.org
Fri Jun 6 15:13:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61429
Bug ID: 61429
Summary: SYSTEM_CLOCK used with non-default integer kind does
not produce warning
Product: gcc
Version: 4.8.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: thatcadguy at gmail dot com
Compiling:
program main
implicit none
integer(kind=8) :: i
call system_clock(i)
end program main
with gfortran -std=f95 -pedantic -Wall -Wextra produces no warning. According
to the F95 standard (13.14.106), "COUNT (optional) shall be scalar and of type
default integer" (it's the same for COUNT_RATE and COUNT_MAX). It's not until
F2003 (13.7.117) that the wording is changed to "COUNT (optional) shall be
scalar and of type integer."
Summary: using any other kind but default integer with system_clock should not
be allowed or give a warning under -std=f95, but should be allowed for
-std=f2003 and later.
More information about the Gcc-bugs
mailing list