public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/49025] New: gfortran bug: Local variable does not hide generic procedure.
@ 2011-05-17 15:53 david.sagan at gmail dot com
  2011-05-17 16:38 ` [Bug fortran/49025] " burnus at gcc dot gnu.org
  2011-07-23 23:39 ` pinskia at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: david.sagan at gmail dot com @ 2011-05-17 15:53 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49025

           Summary: gfortran bug: Local variable does not hide generic
                    procedure.
           Product: gcc
           Version: 4.5.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: david.sagan@gmail.com


Consider the following test code:

-----------------------------------

module test

interface kick
  subroutine a_kick
  end subroutine
end interface

contains

subroutine my_sub
  implicit none
  integer kick
  call some_sub(kick)
end subroutine

end module

----------------------------------
Compiling gives:

lnx4103:~/dcs/bmad_distribution/test_build> gfortran --version
GNU Fortran (GCC) 4.5.1
Copyright (C) 2010 Free Software Foundation, Inc.

lnx4103:~/dcs/bmad_distribution/test_build> gfortran -c test.f90
test.f90:13.16:

  call some_sub(kick)
                1
Error: GENERIC procedure 'kick' is not allowed as an actual argument at (1)


The local "kick" variable is not hiding the "kick" generic procedure. 
This code compiles with ifort v9 and v12.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug fortran/49025] gfortran bug: Local variable does not hide generic procedure.
  2011-05-17 15:53 [Bug fortran/49025] New: gfortran bug: Local variable does not hide generic procedure david.sagan at gmail dot com
@ 2011-05-17 16:38 ` burnus at gcc dot gnu.org
  2011-07-23 23:39 ` pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: burnus at gcc dot gnu.org @ 2011-05-17 16:38 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49025

Tobias Burnus <burnus at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |rejects-valid
                 CC|                            |burnus at gcc dot gnu.org
      Known to fail|                            |4.3.4, 4.5.1, 4.7.0

--- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-05-17 16:16:13 UTC ---
Confirmed.

That's an interesting issue. "external kick" and using "a_kick" works, only
generic + type spec fails.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug fortran/49025] gfortran bug: Local variable does not hide generic procedure.
  2011-05-17 15:53 [Bug fortran/49025] New: gfortran bug: Local variable does not hide generic procedure david.sagan at gmail dot com
  2011-05-17 16:38 ` [Bug fortran/49025] " burnus at gcc dot gnu.org
@ 2011-07-23 23:39 ` pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2011-07-23 23:39 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49025

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011.07.23 23:39:24
     Ever Confirmed|0                           |1


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-07-23 23:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-17 15:53 [Bug fortran/49025] New: gfortran bug: Local variable does not hide generic procedure david.sagan at gmail dot com
2011-05-17 16:38 ` [Bug fortran/49025] " burnus at gcc dot gnu.org
2011-07-23 23:39 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).