[4.5, Patch, Fortran] PR34656 - Add -fruntime-check=do for DO variable checks
Sun Dec 7 00:23:00 GMT 2008
this patch adds two run-time checks for DO loops:
a) That the DO step is not zero
b) That a loop variable is not modified
Contrary to other compilers, the error message is a bit unspecific (it
points to the DO line and does not even contain the name of the DO
variable [code->sym* is NULL]), but on the other hand it detects
modifications other compilers do not detect (see PR). If someone has an
idea how the diagnostics can be improved ...
Also this patch needs Paul's/FX's patch and also does not include any
documentation. Due to interdiff problems, the libgfortran.h and
options.c part needs to be applied by hand for testing.
PS: That patch fixes also ARG5 on
http://www.polyhedron.com/pb05-linux-diagnose0html and thus 44->46%.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the Gcc-patches