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=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,6689542a60dbcc55 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!q1g2000yqg.googlegroups.com!not-for-mail From: Martin Newsgroups: comp.lang.ada Subject: Re: Discriminated records are not the most efficient, but ... Date: Mon, 23 Aug 2010 06:32:52 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <874oemcr37.fsf@mid.deneb.enyo.de> <4c71e5fc$0$2388$4d3efbfe@news.sover.net> <8dejelF6qlU1@mid.individual.net> <54fd0620-5ca9-45b9-80c7-497b02f85e10@j18g2000yqd.googlegroups.com> <4c7274ae$0$6770$9b4e6d93@newsspool3.arcor-online.net> NNTP-Posting-Host: 20.133.0.8 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1282570373 28809 127.0.0.1 (23 Aug 2010 13:32:53 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Mon, 23 Aug 2010 13:32:53 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: q1g2000yqg.googlegroups.com; posting-host=20.133.0.8; posting-account=g4n69woAAACHKbpceNrvOhHWViIbdQ9G User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.7) Gecko/20100701 Firefox/3.6.7,gzip(gfe) Xref: g2news1.google.com comp.lang.ada:13668 Date: 2010-08-23T06:32:52-07:00 List-Id: On 23 Aug, 14:16, Georg Bauhaus wrote: > On 23.08.10 13:44, Martin wrote: > > > On 23 Aug, 08:33, Simon Wright wrote: > >> Niklas Holsti writes: > >>> Subprograms can be compiled on their own, without being enclosed in a > >>> package. > > >> And a main subprogram is usually a compilation unit, ie not in a packa= ge > >> (though I can't see anything that actually requires that,http://www.ad= aic.com/standards/05rm/html/RM-10-2.html(7)). > > > Used to be required in Ada83 (seehttp://archive.adaic.com/standards/83l= rm/html/lrm-10-01.html#10.1 > > - just before 'Notes') but Ada95 relaxed the rules. > > package Empty is > =A0 =A0pragma Elaborate_Body (Empty); > end Empty; > > with Ada.Text_IO; > package body Empty is > begin > =A0 =A0Ada.Text_IO.Put_Line ("Psst!"); > end Empty; > > $ gnatchop empty.ada && gnatmake -z empty > > -- Georg Yup, note Ada83 allowed implementations to support this too - it just defined a 'minimum' level of support for a main subprograms as a library-level parameterless procedure (NB: not function!). -- Martin