This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/51268] New: [Regression] A subroutine can not know anymore its own interface
- From: "bardeau at iram dot fr" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 22 Nov 2011 12:30:10 +0000
- Subject: [Bug fortran/51268] New: [Regression] A subroutine can not know anymore its own interface
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51268
Bug #: 51268
Summary: [Regression] A subroutine can not know anymore its own
interface
Classification: Unclassified
Product: gcc
Version: fortran-dev
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: bardeau@iram.fr
Created attachment 25881
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25881
Declare a subroutine interface and use this interface in the subroutine
This a regression which appeared in the last months: problem is in 4.7.0
20111119 but not in 4.7.0 20110507
In the latest version, a subroutine can not know its own interface and an error
is raised about duplicate symbols (see example attached):
test.f90:15.6:
use myinterfaces
1
Error: 'mysub' of module 'myinterfaces', imported at (1), is also the name of
the current program unit
>From our developer point of view, this is a very annoying regression, since we
are in charge of several libraries, with hundreds of subroutines in each. We
made the choice to provide all the interfaces of all the subroutines to all of
them, in order to ensure a correct use of the subroutines everywhere. For each
library we thus have a dedicated interface module which is used everywhere.
Forbidding a subroutine to know its own interface would imply to use the
statement "use only", which is definitely not well suited for large programs.
Thanks for your help.