return value from fortran program

RadSurfer RadSurfer@yahoo.com
Tue Sep 16 20:38:00 GMT 2008


How can we pass the integer value we want to the calling shell, as a 'return' or
'error value' ?

 in 'C/C++' main() { return value; }  would do what I'm asking here for
gfortran. the final return that terminates the program and returns to the
calling shell...

  This discussion has caused some debut.... 
and using  
   echo $?
compared to using tcsh, and using
   echo $status

How can we be certain of a numerical (what we want) vs. a string return,
since STOP can display messages as well as ascii digits.

Sometimes we just want the termination and return status without any
strings involved; in case we need to parse over things in scripts, etc.

Does anyone understand how this should work, and can be made to
work consistantly, thanks.

[RadSurfer@chess fortran]$ gfortran --version
GNU Fortran (GCC) 4.1.2 20071124 (Red Hat 4.1.2-42)

RadSurfer@yahoo.com




More information about the Fortran mailing list