This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/47136] [OOP] possible name resolution problems between MODULE and INTERFACE?
- From: "janus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 2 Jan 2011 13:33:59 +0000
- Subject: [Bug fortran/47136] [OOP] possible name resolution problems between MODULE and INTERFACE?
- Auto-submitted: auto-generated
- References: <bug-47136-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47136
--- Comment #3 from janus at gcc dot gnu.org 2011-01-02 13:33:50 UTC ---
Some related non-OOP examples:
module a
contains
subroutine s()
end subroutine
end module
module s
use a
contains
subroutine sub()
call s
end subroutine
end
gives:
call s
1
Error: Name 's' at (1) is an ambiguous reference to 's' from current program
unit
Example #2:
module a
contains
subroutine s()
end subroutine
end module
module m
use a
contains
subroutine s()
end subroutine
end
gives:
subroutine s()
1
test.f90:8.7:
use a
2
Error: Procedure 's' at (1) is already defined at (2)
Are these examples actually valid or invalid? Can someone give the relevant
quotes from the standard?