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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9d303864ae4c70ad X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-04-09 04:25:12 PST Path: archiver1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsmm00.sul.t-online.de!t-online.de!news.t-online.com!not-for-mail From: Martin Krischik Newsgroups: comp.lang.ada Subject: Re: Reprise: 'in out' parameters for functions Date: Fri, 09 Apr 2004 13:23:12 +0200 Organization: AdaCL Message-ID: <5058369.11AmbRLujt@linux1.krischik.com> References: <87brm1pksa.fsf@deneb.enyo.de> Reply-To: krischik@users.sourceforge.net Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: news.t-online.com 1081509886 01 26121 tyCIGbPrKzQWYgs 040409 11:24:46 X-Complaints-To: usenet-abuse@t-online.de X-ID: VUTVe0ZOYeURN9aTsNyjKADSbVvh0MaSv3BiCc-VMErVij4UFxUp4n User-Agent: KNode/0.7.7 Xref: archiver1.google.com comp.lang.ada:6889 Date: 2004-04-09T13:23:12+02:00 List-Id: Dmitry A. Kazakov wrote: > Florian Weimer wrote: > >> Stephen Leake writes: >> >>> Ada has a wart. Let's admit it, and move on. >> >> Can't we fix that one without breaking backwards compatibility? > > procedure Has_A_Result (...) return Result; This solution would call for precise documentation (advantages, disadvantages) etc. pp. Plus a quick summary ("functions are faster") for the beginner. Otherwise the same problems as with "access all" will arise. Many programers use "access all" all the time - even when not needed, ignoring the diadvantages. >> Or are politics involved? > > I think so. But there also is the problem of evaluation order, though > simply ignored for access parameters of functions. See above. Have you heard of GNATs "pragma Pure_Function"? Prehaps making function even more restive plus procedures with return plus a "functions are faster" statement might do the trick. With Regards Martin -- mailto://krischik@users.sourceforge.net http://www.ada.krischik.com