[Patch, Fortran] PR 41733: Proc-pointer conformance checks: Elemental-proc-ptr => non-elemental-proc

Janus Weil janus@gcc.gnu.org
Wed Sep 21 21:07:00 GMT 2011


Hi all,

here is a patch which adds checks for the ELEMENTAL attribute in
procedure pointer assignments and dummy procedures. For details see
the PR and the c.l.f. thread mentioned therein. For the PURE
attribute, we already had a check, which I moved and reformulated (so
that it is applicable also to proc-ptr assignments).

The patch was regtested on x86_64-unknown-linux-gnu. Ok for trunk?

Cheers,
Janus



2011-09-21  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/41733
	* expr.c (gfc_check_pointer_assign): Check for nonintrinsic elemental
	procedures.
	* interface.c (gfc_compare_interfaces): Rename 'intent_flag'. Check
	for PURE and ELEMENTAL attributes.
	(compare_actual_formal): Remove pureness check here.

2011-09-21  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/41733
	* gfortran.dg/impure_actual_1.f90: Modified error message.
	* gfortran.dg/proc_ptr_32.f90: New.
	* gfortran.dg/proc_ptr_33.f90: New.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr41733.diff
Type: text/x-diff
Size: 4659 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110921/d5a01dbb/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: proc_ptr_32.f90
Type: text/x-fortran
Size: 395 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110921/d5a01dbb/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: proc_ptr_33.f90
Type: text/x-fortran
Size: 681 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110921/d5a01dbb/attachment-0002.bin>


More information about the Gcc-patches mailing list