https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66608

            Bug ID: 66608
           Summary: gnat 5.1 fails with compilation abandoned, minimal
                    testcase included
           Product: gcc
           Version: 5.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
          Assignee: unassigned at gcc dot gnu.org
          Reporter: siflfran at hawo dot net
  Target Milestone: ---

gnatmake test2
gcc -c test2.adb
+===========================GNAT BUG DETECTED==============================+
| 5.1.0 (x86_64-pc-linux-gnu) Program_Error sem_type.adb:813 explicit raise|
| Error detected at test2.adb:4:12                                         |
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.            |
| Use a subject line meaningful to you and us to track the bug.            |
| Include the entire contents of this bug box in the report.               |
| Include the exact command that you entered.                              |
| Also include sources listed below.                                       |
+==========================================================================+

Please include these source files with error report
Note that list may not be accurate in some cases,
so please double check that the problem can still
be reproduced with the set of files listed.
Consider also -gnatd.n switch (see debug.adb).

test2.adb
test2.ads
test1.ads

compilation abandoned
gnatmake: "test2.adb" compilation error

test2.adb:
======================================
package body test2 is
  function Make return blatest.T is
  begin
    return (N => 0);
  end Make;

end test2;
======================================

test2.ads:
======================================
with test1;

package test2 is
  type S;
  package blatest is new test1(S);

  type S is limited private;
  function Make return blatest.T;

  private

  type S is limited record
    N : Natural := 0;
  end record;

end test2;
======================================

test1.ads:
======================================
generic
  type Q;
package test1 is
  subtype T is Q;

  function Bla (Object : T) return T;
end test1;
======================================

Reply via email to