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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,69c50fc0d29ced1b,start X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!news1.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nx01.iad01.newshosting.com!newshosting.com!198.186.194.249.MISMATCH!transit3.readnews.com!textspool1.readnews.com!news-out.readnews.com!postnews3.readnews.com!not-for-mail Message-Id: <4bf3fce5$0$2399$4d3efbfe@news.sover.net> From: "Peter C. Chapin" Subject: Q: SPARK visibility rules and inherit annotations. Newsgroups: comp.lang.ada Date: Wed, 19 May 2010 11:04:05 -0400 User-Agent: KNode/0.10.9 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit Organization: SoVerNet (sover.net) NNTP-Posting-Host: 16c94937.news.sover.net X-Trace: DXC=QBF0F[@7fg@25]V9k:[LPCK6_LM2JZB_CQaD\]7@;ilG:WUUlR<856OKHFPRFAZQgHfiR=aEnAklL X-Complaints-To: abuse@sover.net Xref: g2news2.google.com comp.lang.ada:11770 Date: 2010-05-19T11:04:05-04:00 List-Id: I'm working on a SPARK program. Right now I'm just doing design so my focus is on package specifications; there are no package bodies. I'm having some trouble with the following: with TMLib.Cryptographic_Services; --# inherit TMLib.Cryptographic_Services; package TMLib.Credentials is type Credential_Type is private; -- Converts the raw bytes of a certificate transfer format to a credential. procedure Certificate_To_Credential (Raw_Data : in TMLib.Cryptographic_Services.Octet_Array; Credential : out Credential_Type; Valid : out Boolean); --# derives Credential from Raw_Data & --# Valid from Raw_Data; -- Other stuff not shown here... end TMLib.Credentials; The SPARK Examiner complains about the use of "Cryptographic_Services" in the declaration of the Raw_Data parameter to the procedure. Specifically I get error 754 that says (roughly) "The identifier Cryptographic_Services is not declared or not visible." I am then told that I probably need both a 'with' statement in the context clause and an 'inherit' annotation. Don't I have those things? Note that TMLib.Cryptographic_Services examines without error but it does generate a warning because the private section is empty and currently hidden from SPARK with a 'hide' annotation. It seems unlikely to me that has anything to do with my problem. Note that TMLib.Cryptographic_Services is a public child of TMLib. I tried adding a 'with TMLib;' in the context clause but that didn't have any effect. I realize the problem is probably something silly but I'm a bit baffled here. Any pointers would be appreciated. Thanks! Peter