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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.ada Subject: Re: Why .ads as well as .adb? Date: Mon, 03 Jun 2019 12:51:14 -0700 Organization: None to speak of Message-ID: References: <28facad3-c55f-4ef2-8ef8-004925b7d1f1@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: reader02.eternal-september.org; posting-host="2e0b7da47f6ad3e1490831b7250ade4a"; logging-data="7230"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18hFteq74mHHbJxgAnudchT" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:XhO4UrJ7pHn8nHdpGR9+vXAS8ys= sha1:PFKOGk9yMovuj7CdbnEW4GZU554= Xref: reader01.eternal-september.org comp.lang.ada:56451 Date: 2019-06-03T12:51:14-07:00 List-Id: "Dmitry A. Kazakov" writes: > On 2019-06-03 09:35, Maciej Sobczak wrote: >>> That is not possible. You cannot generate specification from >>> implementation and conversely. >> >> Yes, you can. You can generate specs from implementations. > > No. Specification describes a class of implementations. You cannot > deduce class from its single member. I suspect the point is that you *could* have an Ada-like language in which specifications could be unambiguously generated from implementations. You'd need some kind of additional annotation to specify whether a given declaration is to be exported. You can't in Ada as it is, because Ada isn't designed that way. [...] -- Keith Thompson (The_Other_Keith) kst-u@mib.org Will write code for food. void Void(void) { Void(); } /* The recursive call of the void */