From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25569 invoked by alias); 15 May 2009 10:32:49 -0000 Received: (qmail 25480 invoked by uid 48); 15 May 2009 10:32:33 -0000 Date: Fri, 15 May 2009 10:32:00 -0000 Message-ID: <20090515103233.25479.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/39997] Procedure(), pointer & implicit typing: rejects-valid / accepts-invalid? In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "burnus at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2009-05/txt/msg01316.txt.bz2 ------- Comment #3 from burnus at gcc dot gnu dot org 2009-05-15 10:32 ------- Proc-pointer fun as written by Malcolm Cohen, http://j3-fortran.org/pipermail/j3/2009-May/002755.html If I understood his arguments correctly, even the following Fortran 90 program might be affected: module m IMPLICIT logical(1)(A-Z) external proc end module m program test use m implicit none ! << optionally remove this line logical(1) :: x x = proc() end program test It currently fails with ifort, NAG f95, sunf95, openf95, pathf95, pgf95, and gfortran. (g95 seeming properly accepts it - and rejects it if one changes the IMPLICIT logical to something incompatible.) * * * Otherwise, the example proposed by Richard is invalid. (I think that is line with current gfortran.) * * * Regarding implicit none PROCEDURE(REAL) :: func PROCEDURE(), POINTER :: ptr ptr => func that seems to be invalid and thus is needs to be rejected, but I think it is currently accepted. (Please follow the thread and check also the final outcome of the interpretation request.) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39997