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,a77191f3e4e3079e X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!news.glorb.com!border1.nntp.dca.giganews.com!nntp.giganews.com!peer01.cox.net!cox.net!elnk-pas-nf1!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!newsread2.news.pas.earthlink.net.POSTED!a6202946!not-for-mail From: Jeffrey Carter Organization: jrcarter commercial-at acm [period | full stop] org User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.4) Gecko/20030624 MSIE X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: trying to call HDF5 from ada -- problems with constants References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Fri, 27 Aug 2004 00:54:46 GMT NNTP-Posting-Host: 63.184.105.221 X-Complaints-To: abuse@earthlink.net X-Trace: newsread2.news.pas.earthlink.net 1093568086 63.184.105.221 (Thu, 26 Aug 2004 17:54:46 PDT) NNTP-Posting-Date: Thu, 26 Aug 2004 17:54:46 PDT Xref: g2news1.google.com comp.lang.ada:3065 Date: 2004-08-27T00:54:46+00:00 List-Id: Randy Brukardt wrote: > Since this object is going to be a constant in the Ada code, it's > unfortunate that you can't declare it that way: > > H5T_STD_I32BE_g : constant Hid_t; > > but that lack of an explicit initializer makes it illegal. (I think an > implementation could support this if it wanted to - pragma Import can be a > completion - but I don't know if any do.) What? I've thought this has always been legal Ada 95. Certainly package Import_Constant is I : constant Integer; pragma Import (C, I, "i"); end Import_Constant; compiles without error (GNAT 3.15p/Win98). -- Jeff Carter "My legs are gray, my ears are gnarled, my eyes are old and bent." Monty Python's Life of Brian 81