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!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: Ada package registry? Date: Mon, 8 Feb 2016 10:03:34 +0100 Organization: Aioe.org NNTP Server Message-ID: References: <02241ec4-0f95-4f63-9abc-092f167eb59e@googlegroups.com> <56af17b7$0$301$14726298@news.sunsite.dk> <56b06eb8$0$301$14726298@news.sunsite.dk> <1454483747.2785.135.camel@obry.net> NNTP-Posting-Host: bqgfK7NL3xTHnr0WRaLl4g.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:29427 Date: 2016-02-08T10:03:34+01:00 List-Id: On 07/02/2016 23:16, Georg Bauhaus wrote: > On 07.02.16 20:57, Dmitry A. Kazakov wrote: >> On 2016-02-07 20:21, Georg Bauhaus wrote: >>> Dmitry A. Kazakov wrote: >>>> On 2016-02-07 10:40, Georg Bauhaus wrote: >>>>> On 05.02.16 19:47, Dmitry A. Kazakov wrote: >>> >>>> Interfaces.X in Ada do not convert anything, it provides Ada types >>>> exactly matching their alien language counterparts. >>> >>> How does Interfaces.X provide matching >>> types for decimals or task types in C, Cobol, or Fortran? >> >> See ARM Annex B. > > Let me rephrase: How does the Interface hierarchy from Annex B > of the Ada LRM provide matching types for decimals or task types in > C, Cobol, or Fortran? For, if it does not, then the alleged exact > matches simply are not there. Not even one-way. The languages like C have few base integral types which Annex B defines. Derived types are arrays and records created from the base types with pragma Convention applied. So it boils down to the alien language types algebra mapped onto the Ada's types algebra. So far used: record type operation array type operation tagged type operation (for C++ virtual pointer tables) In short you should be able to describe the data type model in Ada. It works well for primitive procedural languages like C. It won't work for complicated declarative languages. > However, there is something in Ada from which to build interfaces for > SQL RDBMS, for practical reasons. Ada does not have operations to express RA. As for SQL types the problem that they are not the types the DBMS actually uses and not the types at the DB client's end. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de