This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/31822] Missing run-time bound checks for character pointer => target
- From: "burnus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Dec 2008 09:56:03 -0000
- Subject: [Bug fortran/31822] Missing run-time bound checks for character pointer => target
- References: <bug-31822-13404@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from burnus at gcc dot gnu dot org 2008-12-17 09:56 -------
For Fortran 97 I found it; it is in the first sentence after the "Contrain:"s
"The target shall have the same type parameters as the pointer-object"
For Fortran 2003 I'm still searching (it does not seem to be in the
corrigenda).
OK. Found it. I think the "Otherwise" clause of the following applies:
"If data-target is a disassociated pointer, all nondeferred type parameters of
the declared type of data pointer-object that correspond to nondeferred type
parameters of data-target shall have the same values as the corresponding type
parameters of data-target. Otherwise, all nondeferred type parameters of the
declared type of data-pointer-object shall have the same values as the
corresponding type parameters of data-target."
Thus: One indeed needs the check mentioned in comment 0.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31822