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.1 required=5.0 tests=BAYES_00, PP_MIME_FAKE_ASCII_TEXT autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!mx05.eternal-september.org!feeder.eternal-september.org!nuzba.szn.dk!news.jacob-sparre.dk!munin.jacob-sparre.dk!pnx.dk!.POSTED!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Seeking for papers about tagged types vs access to subprograms Date: Wed, 1 May 2013 20:18:55 -0500 Organization: Jacob Sparre Andersen Research & Innovation Message-ID: References: <8b517bcc-c85a-413a-abd3-1f232f764473@googlegroups.com> NNTP-Posting-Host: static-69-95-181-76.mad.choiceone.net X-Trace: munin.nbi.dk 1367457537 25236 69.95.181.76 (2 May 2013 01:18:57 GMT) X-Complaints-To: news@jacob-sparre.dk NNTP-Posting-Date: Thu, 2 May 2013 01:18:57 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5931 X-RFC2646: Format=Flowed; Response X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 Xref: news.eternal-september.org comp.lang.ada:15280 Date: 2013-05-01T20:18:55-05:00 List-Id: "Yannick Duchêne (Hibou57)" wrote in message news:op.wwbw2ho9ule2fv@cardamome... ... >However, tagged types may be excluded (ex. if there are proof >requirements) or not available (ex. the runtime in use does not support >it). That's a bit a pity to not be able to use something like >`Ada.Finalization` for applications not using tagged types. I even believe >`Ada.Finalization` is harder to avoid than tagged types >(`Ada.Finalization` looks more fundamental to me), especially that it >comes with added safety (as much as strong typing and ability to return >unconstrained types are). My understanding is that safety-critical people are scared of anything that has implicit behavior (like Finalization or dispatching). As such, there isn't much value to having them separated as the people that can't use the one probably can't use the other as well. And outside of such restricted environments, there's not value to avoiding tagged types. It should be noted that finalization on all types had some semantic problems (such as finalization on by-copy parameter passing - which would make it hard to call a procedure Finalize without infinite regress) which were solved by limiting the capability to tagged types. Whether there was a better solution is hard to say at this distance -- keep in mind that the prevailing feeling among the reviewers was that the general finalization you are talking about was too complex for the Ada 95 definition. A small group of die-hards (which I somehow got the reputation of being the leader of), convinced Tucker to try again with a simpler model -- which turned into the tagged model we have today. So my point is the that the question is not whether general finalization would have been better than tagged-type only finalization. It was whether tagged-type only finalization was better than nothing, because there was no chance of the general finalization being in Ada 95. Finalization is far too important for us to have waited another 12 years to get it, so what we've got is the best that we could have gotten. Randy. -- "Syntactic sugar causes cancer of the semi-colons." [1] "Structured Programming supports the law of the excluded muddle." [1] [1]: Epigrams on Programming - Alan J. - P. Yale University