This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug ada/15600] New: Illegal program not detected (subprogram overloaded with variable)


procedure P is
   generic
   procedure p1;
   procedure p1 is begin null; end;

   procedure p2 is begin null; end;
   procedure x1 is new p1;
   procedure x2 renames p2;
   x1: integer;        -- ERROR: x1 redefined
   x2: integer;        -- ERROR: x2 redefined
begin
   null;
end P;

$ gnatmake p
gnatgcc -c p.adb
p.adb:9:04: warning: "x1" is never assigned a value
p.adb:10:04: warning: "x2" is never assigned a value
gnatbind -x p.ali
gnatlink p.ali

Compilation finished at Wed Apr 14 19:17:18

-- 
           Summary: Illegal program not detected (subprogram overloaded with
                    variable)
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: ada
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: ludovic dot brenta at insalien dot org
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i696-pc-linux-gnu
  GCC host triplet: i696-pc-linux-gnu
GCC target triplet: i696-pc-linux-gnu


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]