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/15616] New: Linking error on legal program using generic package


procedure Test_246184 is
   generic
      type T1 is range <>;
   package pak1 is
      procedure p1 (x: in out T1);
   end pak1;

   package body pak1 is
      procedure p1 (x: in out T1'base) is
      begin
         null;
      end p1;
   end pak1;

   package np1 is new pak1(integer);
   x1: integer;
begin
   np1.p1(x1);
end Test_246184;


./test_246184.o(.text+0x15): In function `_ada_test_246184':
: undefined reference to `test_246184__np1__p1.1'
collect2: ld returned 1 exit status
gnatlink: cannot call /usr/bin/gcc-3.4
gnatmake: *** link failed.

-- 
           Summary: Linking error on legal program using generic package
           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
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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