11-219 To: J3 From: Van Snyder Subject: Interpretation request F03/0116 revisited Date: 2011 June 30 ---------------------------------------------------------------------- NUMBER: F03/0116 TITLE: indistinguishable specifics for a generic interface with use association KEYWORDS: GENERIC RESOLUTION USE ASSOCIATION DEFECT TYPE: Erratum STATUS: J3 consideration in progress Consider the following program MODULE M1 INTERFACE SUBR MODULE PROCEDURE SUBR1 END INTERFACE CONTAINS SUBROUTINE SUBR1 END SUBROUTINE END MODULE M2 INTERFACE SUBR MODULE PROCEDURE SUBR2 END INTERFACE CONTAINS SUBROUTINE SUBR2 END SUBROUTINE END PROGRAM MAIN USE M1 CALL S CONTAINS SUBROUTINE S USE M2 CALL SUBR END SUBROUTINE END Is this program standard conforming? ANSWER: Subclause 12.4.3.4.5 of the Fortran 2008 standard forbids the presence of such conflicting interfaces. If, as an extension, a processor allowed duplicate interfaces, provided one was declared within a scoping unit or accessed by use assocation, and the other accessed by host association, subclause 12.5.5.2 of the Fortran 2008 standard would be able to resolve the reference to SUBR in the example. That does not, however, negate the prohibition in subclause 12.4.3.4.5. EDITS: None. SUBMITTED BY: Robert Corbett and Michael Ingrassia HISTORY: 08-169 m184 F03/0116 submitted 11-xxx m195 Revised for Fortran 2008. ----------------------------------------------------------------------