This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug ada/31415] New: Illegal program not detected, Ada 2005, 3.9.4(12/2) and 7.5(6.1/2)
- From: "ludovic at ludovic-brenta dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 31 Mar 2007 22:04:41 -0000
- Subject: [Bug ada/31415] New: Illegal program not detected, Ada 2005, 3.9.4(12/2) and 7.5(6.1/2)
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Debian Bug#416973
In the following program, the declaration of T3 is illegal because it
extends a limited type (T1) and a nonlimited interface (T2).
-- compiled -gnat05
-- error not detected
package pak1 is
-- RM 3.9.4(12/2) and 7.5(6.1/2)
-- check that both ancestors must be either limited or nonlimited
type T1 is tagged limited null record;
type T2 is interface;
type T3 is new pak1.T1 and pak1.T2 with null record; --ERROR: mixed types
end pak1;
To reproduce:
gnatmake -gnat05 pak1.ads
Error expected:
pak1.ads:8:30: all ancestors must be either limited or nonlimited
--
Summary: Illegal program not detected, Ada 2005, 3.9.4(12/2) and
7.5(6.1/2)
Product: gcc
Version: 4.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ludovic at ludovic-brenta dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31415