Bug 16082 - Legal program rejected, expect derived type in instantiation
Summary: Legal program rejected, expect derived type in instantiation
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: ada (show other bugs)
Version: 3.4.0
: P2 normal
Target Milestone: 4.8.0
Assignee: Not yet assigned to anyone
URL:
Keywords: rejects-valid
Depends on:
Blocks:
 
Reported: 2004-06-19 15:00 UTC by Ludovic Brenta
Modified: 2015-12-05 10:28 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail: 4.0.0
Last reconfirmed: 2005-06-14 20:22:18


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ludovic Brenta 2004-06-19 15:00:08 UTC
generic
package pak1 is
   type T1 is tagged null record;
end pak1;

generic
   type T2 is new T1 with private;
package pak1.pak2 is
end pak1.pak2;

with pak1.pak2;
package Test_248167 is
   package new_pak1 is new pak1;
   package new_pak2 is new new_pak1.pak2 (new_pak1.T1);
end Test_248167;


test_248167.ads:5:51: expect type derived from "T1" in instantiation
test_248167.ads:5:51: instantiation abandoned
gnatmake: "test_248167.ads" compilation error
Comment 1 Andrew Pinski 2004-10-31 19:50:42 UTC
Confirmed.
Comment 2 Nicolas Boulenguez 2011-08-31 11:15:38 UTC
found 4.6.1
Comment 3 Nicolas Boulenguez 2014-08-13 15:33:21 UTC
Fixed in 4.8.2.
Comment 4 Eric Botcazou 2015-12-05 10:28:49 UTC
.