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,24d7acf9b853aac8 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newsgate.cuhk.edu.hk!news.netfront.net!not-for-mail From: Jeffrey Carter Newsgroups: comp.lang.ada Subject: Re: S-expression I/O in Ada Date: Mon, 09 Aug 2010 17:57:51 -0700 Organization: Netfront http://www.netfront.net/ Message-ID: References: <547afa6b-731e-475f-a7f2-eaefefb25861@k8g2000prh.googlegroups.com> <87aap6wcdx.fsf@ludovic-brenta.org> <87vd7jliyi.fsf@ludovic-brenta.org> <699464f5-7f04-4ced-bc09-6ffc42c5322a@w30g2000yqw.googlegroups.com> <87ocdbl41u.fsf@ludovic-brenta.org> NNTP-Posting-Host: 75.211.205.171 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: adenine.netfront.net 1281401873 90135 75.211.205.171 (10 Aug 2010 00:57:53 GMT) X-Complaints-To: news@netfront.net NNTP-Posting-Date: Tue, 10 Aug 2010 00:57:53 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.11) Gecko/20100713 Thunderbird/3.0.6 In-Reply-To: <87ocdbl41u.fsf@ludovic-brenta.org> X-Original-Bytes: 2644 Xref: g2news1.google.com comp.lang.ada:13029 Date: 2010-08-09T17:57:51-07:00 List-Id: > Natacha Kerensikova writes: > > For Jeffry Carter (and anybody interested in helping me understand the > Ada way): here is how it looks like when I haven't thought much about > it. Notice that all this is completely from the point of view of the > application using the package, with very few implementation choices. > If I knew Ada, wouldn't these explanations be pretty much the contents > of the specification file, with about everything from the body being > still to invent? How Ada-ish is that thought process? In general, describing it from the point of view of "the application using the package" (often referred to as "the client") is the purpose of the specification. The body is for the implementation, usually best left until the specification is finished. On the other hand, your proposed operations seem unnecessarily low level for the client. You have an internal representation, which is probably hidden from the client, and an external representation, and operations to write an object of the internal representation to that external representation and read the external representation to create an object of the internal representation. Thus, your client should probably invoke a single operation to write an object, and another single operation to read. -- Jeff Carter "Run away! Run away!" Monty Python and the Holy Grail 58 --- news://freenews.netfront.net/ - complaints: news@netfront.net ---