Skip to content

No checks for the integer arguments of intrinsic "execute_command_line" #77990

@psteinfeld

Description

@psteinfeld

Section 16.9.73 says that the exitstat argument should have a decimal exponent range of at least nine, and the cmdstat argument should have a decimal exponent range of at least four. But the following program does not emit any compile time error messages:

program bug implicit none integer(kind = 1) :: exitstatvar integer(kind = 1) :: cmdstatvar character(len=256) :: msg character(len=:), allocatable :: command command='echo hello' call execute_command_line(command, exitstat=exitstatvar, cmdstat=cmdstatvar) end program 

All other compilers I've tried emit error messages for this program.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions