using GNU Fortran 95 (GCC) 4.1.0 20051126 (prerelease) with '-g -pedantic -std=f95', I get a bad / no diagnostic for the following invalid code:
MODULE M1 TYPE SET INTEGER CARD END TYPE SET END MODULE M1 MODULE INTEGER_SETS INTERFACE OPERATOR (.IN.) FUNCTION ELEMENT(X,A) USE M1 CHARACTER(LEN=*) :: ELEMENT INTEGER, INTENT(IN) :: X TYPE(SET), INTENT(IN) :: A END FUNCTION ELEMENT END INTERFACE END MODULE END -- Summary: better diagnostic needed Product: gcc Version: 4.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: jv244 at cam dot ac dot uk http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25084