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 Path: g2news1.google.com!postnews.google.com!z10g2000yqb.googlegroups.com!not-for-mail From: Ludovic Brenta Newsgroups: comp.lang.ada Subject: Re: S-expression I/O in Ada Date: Fri, 13 Aug 2010 02:08:02 -0700 (PDT) Organization: http://groups.google.com 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> <87k4nylb8c.fsf@ludovic-brenta.org> <4c617774$0$6765$9b4e6d93@newsspool3.arcor-online.net> <2610d347-27cf-4c88-ac18-84f73c7da858@h32g2000yqm.googlegroups.com> <878w4blhzj.fsf@ludovic-brenta.org> <85fc256b-bb92-43f5-9de7-5148f5b23622@k10g2000yqa.googlegroups.com> <87vd7fk1ar.fsf@ludovic-brenta.org> <518d22c5-2a6e-49b3-8022-b82f4402f216@m1g2000yqo.googlegroups.com> NNTP-Posting-Host: 153.98.68.197 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1281690483 19110 127.0.0.1 (13 Aug 2010 09:08:03 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 13 Aug 2010 09:08:03 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: z10g2000yqb.googlegroups.com; posting-host=153.98.68.197; posting-account=pcLQNgkAAAD9TrXkhkIgiY6-MDtJjIlC User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6,gzip(gfe) Xref: g2news1.google.com comp.lang.ada:13207 Date: 2010-08-13T02:08:02-07:00 List-Id: Natacha Kerensikova wrote on comp.lang.ada: > On Aug 12, 10:45=A0pm, Ludovic Brenta > wrote: >> The other notations: >> >> (tcp-connect ((host foo.example) (port 80))) >> >> and >> >> (tcp-connect (host foo.example) (port 80)) >> >> are shorthand for that. > > What bother me in this is that I feel those are two different objects. > > I won't go into writing explicit cons pairs again, this is quite > unreadable. So I'll go for an ASCII-art representation, I hope it > won't be scrambled (if so please tell me, I'll try to come up with a > textual representation). Let L and A represent nodes, respectively > lists and atoms, vertical lines for "next in list", "brother" or > "cons" relations, and horizontal lines for "first child of list" or > "atom contents" relations. > > Consider these two objects: > > L--A--tcp-connect > =A0 =A0| > =A0 =A0L--A--host > =A0 =A0| =A0| > =A0 =A0| =A0A--foo.example This part cannot exist: the second L cannot have more than 2 children; here you gave it three (A, A and the next L). The dot notation would have prevented that mistake :) > =A0 =A0| > =A0 =A0L--A--port > =A0 =A0 =A0 | > =A0 =A0 =A0 A--80 > > and: > > L--A--tcp-connect > =A0 =A0| > =A0 =A0L--L--A--host > =A0 =A0 =A0 | =A0| > =A0 =A0 =A0 | =A0A--foo.example > =A0 =A0 =A0 | > =A0 =A0 =A0 L--A--port > =A0 =A0 =A0 =A0 =A0| > =A0 =A0 =A0 =A0 =A0A--80 This one is the only correct topology. -- Ludovic Brenta.