[Patch,Fortran] PR 40580 - add -fcheck=pointer for some actual argument checks

Tobias Burnus burnus@net-b.de
Mon Jun 29 20:17:00 GMT 2009


Hello,

after spending some time today to pinpoint a problem, I decided having a
-fcheck=pointer makes sense. The checking happens if one passes an
ALLOCATABLE or POINTER (or proc-pointer) actual argument to a dummy
which is not allocatable nor a pointer. In that case, the actual
argument needs to be allocated / associated, which this patch checks.

Build and regtested on x86-64-linux.
OK for the trunk?

Tobias

PS: The patch contains two other small changes; one to *def is trivial
and one to *.texi brings the words closer to the standard and describes
better what is actually done (e.g. copy-in/out is not really call by
reference, though the effect is [almost] the same).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: check-pointer.diff
Type: text/x-patch
Size: 17959 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20090629/cfbf157a/attachment.bin>


More information about the Fortran mailing list