[Bug ada/40185] New: Segmentation fault on legal program
ludovic at ludovic-brenta dot org
gcc-bugzilla@gcc.gnu.org
Mon May 18 12:32:00 GMT 2009
(Debian bug #519336)
The following illegal program causes gnat1 to crash with a segmentation fault:
with Ada.Unchecked_Conversion;
package Essai is
type Attributed_Character is record
I : Integer;
end record;
type Video_Array is array (Integer range 0 .. 1) of Attributed_Character;
type Video_Access is access Video_Array;
function To_VA is new Ada.Unchecked_Conversion (Integer, Video_Access);
Video : Video_Access := To_VA (0); -- line 9
end Essai;
/usr/lib/gcc/x86_64-linux-gnu/4.3.3/gnat1 -quiet -dumpbase essai.ads
- -mtune=generic essai.ads -o tutu.s
segmentation fault
Removing line 9 causes GNAT not to segfault.
Also confirmed on GNAT GPL 2008 on x86_64-linux-gnu and with GCC 4.3.3 on
powerpc-linux-gnu.
--
Summary: Segmentation fault on legal program
Product: gcc
Version: 4.3.0
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=40185
More information about the Gcc-bugs
mailing list