Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference
A newer version of this document is available. Customers should click here to go to the newest version.
Visible to Intel only — GUID: GUID-68A42603-8EDF-466D-81C1-840DA76CDDED
Visible to Intel only — GUID: GUID-68A42603-8EDF-466D-81C1-840DA76CDDED
EXIT Subroutine
Intrinsic Subroutine (Generic): Terminates program execution, closes all files, and returns control to the operating system. Intrinsic subroutines cannot be passed as actual arguments.
CALL EXIT [( [status] )]
status |
(Output; optional) Is an integer argument you can use to specify the image exit-status value. |
The exit-status value may not be accessible after program termination in some application environments.
Example
INTEGER(4) exvalue ! all is well, exit with 1 exvalue = 1 CALL EXIT(exvalue) ! all is not well, exit with diagnostic -4 exvalue = -4 CALL EXIT(exvalue) ! give no diagnostic, just exit CALL EXIT ( )