This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug ada/28305] New: GNAT bug when inlining instance of a generic subprogram
- From: "dewi dot daniels at silver-software dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Jul 2006 15:49:08 -0000
- Subject: [Bug ada/28305] New: GNAT bug when inlining instance of a generic subprogram
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
A GNAT bug is detected whenever pragma Inline is applied to an instance of a
generic subprogram and front-end inlining is activated (-gnatN). The problem
can be worked around by either applying the pragma Inline to the generic
subprogram declaration or deactivating front-end inlining.
The test case I used is as follows:
gcc -c -gnatN test.ads
generic
type T is private;
function A (Value : T) return T;
function A (Value : T) return T is
begin
return Value;
end A;
with A;
pragma Elaborate_All (A);
function Test is new A (Integer);
pragma Inline (Test);
--
Summary: GNAT bug when inlining instance of a generic subprogram
Product: gcc
Version: 3.4.5
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dewi dot daniels at silver-software dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28305