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!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: grassroots thoughts on access types Date: Fri, 9 Feb 2018 12:06:07 +0100 Organization: Aioe.org NNTP Server Message-ID: References: <5d9134c9-a7d4-468e-8685-ebbb393eabea@googlegroups.com> NNTP-Posting-Host: MyFhHs417jM9AgzRpXn7yg.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:52.0) Gecko/20100101 Thunderbird/52.6.0 X-Notice: Filtered by postfilter v. 0.8.3 Content-Language: en-US Xref: reader02.eternal-september.org comp.lang.ada:50335 Date: 2018-02-09T12:06:07+01:00 List-Id: On 09/02/2018 10:13, Simon Wright wrote: > "Randy Brukardt" writes: > >> Generally, type conversions for general access types are equivalent to >> ".all'Access". > > .all'Access leaves it up to the compiler to figure out the conversion. > > A colleague (one of the distinguished reviewers for Ada95) said (~2000) > he'd got into the habit of writing .all'Access, when usually (? - maybe > compiler issues) some thought would lead to the actual required > conversion. I prefer .all'Unchecked_Access, no run-time surprises. I stopped feeling guilty for not trying to figure out the effect of accessibility rules in each case, when I realized that it would change nothing for the design. It is pure wasting time if the only difference would be having .all'Access instead (with some residual uncertainty whether it could blow up at run-time nevertheless). -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de