Array Bounds
- the Fortran Standard says nothing about array-bounds-checking;
- if an array subscript is used which is outside of the declared extents:
- the programme may crash;
- an array-bound error may be given;
- the programme may continue but yield incorrect results;
depends on the compiler and compiler options;
- array-bounds-checking is inefficient --- use in development;
Examples
Sun compilers:
f90 -g my_code.f90
- -g: compile for debugging;
NAg compilers:
F90 -C=array my_code.f90
- -C: compile in run-time code, in this case for array-bound checking;
About this document:
Produced from the SGML: /home/isd/public_html/_course_fortran_90/_reml_grp/index.reml
On: 10/2/2003 at 10:33:52
Options: reml2 -i noindex -l long -o html -p multiple