https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108680
--- Comment #8 from anlauf at gcc dot gnu.org --- (In reply to Jerry DeLisle from comment #7) > From the 2023 standard I find: > > "The keyword INTEGER with no kind-selector specifies type integer with > default kind; the kind type parameter value is equal to KIND (0). The > decimal exponent range of default integer shall be at least 5." > > Do I interpret this to mean a range of 1 to 99999? If so, this is a > signficant change which will ripple in a lot of places, I suspect in many > places and not only DTIO. I was looking at the following places in F2023: 12.5.6.2 Syntax of the OPEN statement [ UNIT = ] file-unit-number IOSTAT = stat-variable Now looking up 'stat-variable': R946 stat-variable is scalar-int-variable "A stat-variable should have a decimal exponent range of at least four; otherwise the processor-dependent error code might not be representable in the variable." R907 int-variable is variable C907 (R907) int-variable shall be of type integer. It does not give any restrictions on the kind, except the one explicitly given for a stat-variable. Similarly: R1202 file-unit-number is scalar-int-expr R1027 int-expr is expr C1009 (R1027) int-expr shall be of type integer. Since any kind is more or less allowed for arguments to intrinsic procedures, I do not see any restriction for arguments to I/O statements. (Not that I would ever use unit numbers so large that they only fit into an integer(kind>=8) ...)