From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17394 invoked by alias); 1 Dec 2006 00:59:44 -0000 Received: (qmail 17377 invoked by uid 48); 1 Dec 2006 00:59:36 -0000 Date: Fri, 01 Dec 2006 00:59:00 -0000 Subject: [Bug fortran/30034] New: pure subroutine requires intent for procedure argument X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "trumsko at yahoo dot com" 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: 2006-12/txt/msg00038.txt.bz2 The following declaration pure subroutine s_one ( anum, afun ) integer, intent(in) :: anum interface pure function afun (k) result (l) implicit none integer, intent(in) :: k integer :: l end function afun end interface results in the error (using lates build of gfortran-4.3): Error: Argument 'afun' of pure subroutine 's_one' at (1) must have its INTENT specified The section 12.6 of ISO/IEC 1539-1 says: Constraint: The specification-part of a pure function subprogram shall specify that all dummy arguments have INTENT (IN) except procedure arguments and arguments with the POINTER attribute. which as far I understand means theat the code above is corrent (without intent statement for 'afun'. Cheers, T. -- Summary: pure subroutine requires intent for procedure argument Product: gcc Version: 4.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: trumsko at yahoo dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30034