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/15844] New: Illegal program not detected, RM 8.3(8)


package pak1 is
   generic
   package pak2 is
   end pak2;
end pak1;

--  RM 8.3(8)
--  An inner declaration hides any outer homograph from direct visibility.
with pak1;
package Test_247018 is
   package PAK1 is new pak1.pak2;   --ERROR: illegal reference to pak1
end Test_247018;


I expect an error message like this:
test_247018.ads:4:11: warning: this declaration hides pak1 declared at line 3
test_247018.ads:4:23: pak1 has no selector named pak2


But the compiler says nothing.

-- 
           Summary: Illegal program not detected, RM 8.3(8)
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          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


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


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