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: some trivial questions? Date: Sat, 18 Nov 2017 10:19:13 +0100 Organization: Aioe.org NNTP Server Message-ID: References: <6a5368c5-f015-4dcb-9291-e77b40fa1bf1@googlegroups.com> NNTP-Posting-Host: MajGvm9MbNtGBKE7r8NgYA.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 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 Content-Language: en-US X-Notice: Filtered by postfilter v. 0.8.2 Xref: feeder.eternal-september.org comp.lang.ada:48984 Date: 2017-11-18T10:19:13+01:00 List-Id: On 2017-11-18 02:14, Randy Brukardt wrote: > "Dmitry A. Kazakov" wrote in message > news:oum6qv$1bdr$1@gioia.aioe.org... >> On 17/11/2017 01:51, Randy Brukardt wrote: > ... >>> As far as "use" clauses code, package use clauses are always a >>> maintenance hazard as they make non-overloadable things visible. >> >> Which would be good as it allowed earlier detection of errors. However the >> argument is obviously bogus because any name change is a maintenance >> problem regardless the length of that name. > > Changing names of overloadable things is not a maintenance hazard unless the > things have the exact same profile. (And that's a problem by any definition, > having two identical entities with different meanings.) And if they are not overloadable I still can use long names. Use-clause makes nothing worse than already is. > An alternative fix for this problem would be to make more things (preferably > all things) overloadable. But that would cause some existing Ada code to > silently change meaning, which is considered unacceptable. (It also would > require some sort of meta-types, which I'd rather not try to get into, but > that's a detail.) So it's not going to happen for Ada. Sure, nothing useful going to happen for Ada. But speaking of alternatives, another one is to make illegal use-clauses that cause hiding. > Use type clauses (and prefix notation) don't have these maintenance problems > (they only operate on overloadable entities), so I think they should be > preferred to package use. Use type is an ugly hack. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de