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,b2df4819ac8b566a X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!news.glorb.com!newsfeed.stueberl.de!newsfeed.vmunix.org!peer-uk.news.demon.net!kibo.news.demon.net!news.demon.co.uk!demon!diphi.demon.co.uk!jpt From: JP Thornley Newsgroups: comp.lang.ada Subject: Re: SPARK and Interfaces.C Date: Fri, 13 May 2005 20:40:05 +0100 Message-ID: References: <1116005688.002279.128010@g43g2000cwa.googlegroups.com> NNTP-Posting-Host: diphi.demon.co.uk Mime-Version: 1.0 Content-Type: text/plain;charset=us-ascii X-Trace: news.demon.co.uk 1116013255 12056 80.177.171.182 (13 May 2005 19:40:55 GMT) X-Complaints-To: abuse@demon.net NNTP-Posting-Date: Fri, 13 May 2005 19:40:55 +0000 (UTC) User-Agent: Turnpike/6.04-S () Xref: g2news1.google.com comp.lang.ada:11024 Date: 2005-05-13T20:40:05+01:00 List-Id: In article <1116005688.002279.128010@g43g2000cwa.googlegroups.com>, ich_bin_elvis@hotmail.com writes >Hi, > >Im trying to spark a program that uses Interfaces.C and >Ada.Numerics.Elementary_Functions; I read in John Barnes book that >there is a method callded shadowing that allows you to use these >packages. I understand that you create a dummy package and uses this >with the spark examiner. But i get an error when i try to examin the >dummy package. Does anybody have any good examples how this is done?? >any article regarding multilanguage development and spark would be >apriciated. > >Regrads >Ronny > What errors are you getting? The following packages (based on the examples in John's book) go through the Examiner without any errors. (You have to add a couple of parent packages that aren't there at present.) Cheers, Phil Thornley ------------------------------------------------- package Interfaces is end Interfaces; package Interfaces.C is UCHAR_MAX : constant := 255; type unsigned_char is mod (UCHAR_MAX+1); end Interfaces.C; package Ada.Numerics is end Ada.Numerics; package Ada.Numerics.Elementary_Functions is function Sqrt(X : Float) return Float; function Log(X : Float) return Float; function Cos(X : Float) return Float; end Ada.Numerics.Elementary_Functions; ----------------------------------------------------- -- JP Thornley