diff options
Diffstat (limited to 'static/unix-v10/man3/ierror.3')
| -rw-r--r-- | static/unix-v10/man3/ierror.3 | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/static/unix-v10/man3/ierror.3 b/static/unix-v10/man3/ierror.3 new file mode 100644 index 00000000..e4c106b0 --- /dev/null +++ b/static/unix-v10/man3/ierror.3 @@ -0,0 +1,52 @@ +.th IERROR III 10/29/73 +.sh NAME +ierror \*- catch Fortran errors +.sh SYNOPSIS +.ft B +if ( ierror ( \fIerrno\fB ) .ne. 0 ) goto \fIlabel\fR +.sh DESCRIPTION +.it Ierror +provides a way of detecting errors during the running of a Fortran +program. +Its argument is a run-time error number +such as enumerated in +.it fc +(I). +.s3 +When +.it ierror +is called, +it returns a 0 value; thus the +.bd goto +statement in the synopsis is not executed. +However, the routine stores inside itself the +call point and invocation level. +If and when the indicated error occurs, +a +.bd return +is simulated from +.it ierror +with a non-zero value; +thus the +.bd goto +(or other statement) +is executed. +It is a ghastly error to call +.it ierror +from a subroutine which +has already returned when the error occurs. +.s3 +This routine is essentially tailored to +catching end-of-file situations. +Typically it is called just before the start +of the loop which reads the input file, +and the +.bd goto +jumps to a graceful termination of the program. +.s3 +There is a limit of 5 on the number +of different error numbers which can be caught. +.sh "SEE ALSO" +fc (I) +.sh BUGS +There is no way to ignore errors. |
