From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32736 invoked by alias); 22 Apr 2009 14:56:55 -0000 Received: (qmail 32634 invoked by uid 48); 22 Apr 2009 14:56:20 -0000 Date: Wed, 22 Apr 2009 14:56:00 -0000 Subject: [Bug fortran/39850] New: Too strict checking for procedures as actual argument X-Bugzilla-Reason: CC Message-ID: 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-04/txt/msg01949.txt.bz2 Issue came up when testing/rewiewing proc pointers, cf. http://gcc.gnu.org/ml/fortran/2009-04/msg00214.html The following program is believed to be correct and it runs with g95, NAG f95, sunf95, openf95, and ifort, but not with gfortran: Error: Type/rank mismatch in argument 'a' real function func() func = 42.0 end function func program test external func ! subroutine or implicitly typed real function call sub(func) ! Error: Type/rank mismatch in argument 'a' contains subroutine sub(a) real, external :: a print *, a(0.4) end subroutine sub end -- Summary: Too strict checking for procedures as actual argument Product: gcc Version: 4.4.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: burnus at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39850