From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,80e617905d3d4857,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews.google.com!z14g2000cwz.googlegroups.com!not-for-mail From: "nicolas.b" Newsgroups: comp.lang.ada Subject: pragma Inline in generic Date: 20 Jul 2005 10:10:27 -0700 Organization: http://groups.google.com Message-ID: <1121879427.142113.314140@z14g2000cwz.googlegroups.com> NNTP-Posting-Host: 195.101.38.93 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1121879432 19208 127.0.0.1 (20 Jul 2005 17:10:32 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 20 Jul 2005 17:10:32 +0000 (UTC) User-Agent: G2/0.2 Complaints-To: groups-abuse@google.com Injection-Info: z14g2000cwz.googlegroups.com; posting-host=195.101.38.93; posting-account=IgNquA0AAABLwz_YwrXW7rQG9W2robWy Xref: g2news1.google.com comp.lang.ada:3707 Date: 2005-07-20T10:10:27-07:00 List-Id: This is my program (a short example) : -- A generic package generic type T_Real is digits <>; Default_Real : T_Real; package Toto is type T_Toto is private; function Length (Toto : in T_Toto) return T_Real; pragma Inline (Length); private type T_Toto is record Length : T_Real := Default_Real; end record; end Toto; -- the implementation : package body Toto is function Length (Toto : in T_Toto) return T_Real is begin return Toto.Length; end Length; end Toto; -- The instanciation : with Toto; pragma Elaborate_All (Toto); package Test is package Instance_Toto is new Toto ( T_Real => Float, Default_Real => 0.0); procedure Test; end Test; -- the implementation of this instanciation : package body Test is procedure Test is T : Instance_Toto.T_Toto; L : float; begin L := Instance_Toto.Length (T); end Test; end Test; I use gnat 5.02a1 : function "Length" seems not be Inline in generate code. Why? Thank you for your answer.