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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4c049fca34123e80 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-08-13 08:07:13 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!paloalto-snf1.gtei.net!crtntx1-snh1.gtei.net!chcgil2-snf1.gtei.net!news.gtei.net!news.binc.net!kilgallen From: Kilgallen@eisner.decus.org.nospam (Larry Kilgallen) Newsgroups: comp.lang.ada Subject: Re: Variable length string Date: 13 Aug 2001 10:07:09 -0500 Organization: LJK Software Message-ID: <63Xq$pvvxihS@eisner.encompasserve.org> References: <9l82gv$j83$1@news.mch.sbs.de> <3B77AEAF.72F868DC@amsjv.com> <3B77E4A4.50FFA02B@amsjv.com> NNTP-Posting-Host: eisner.encompasserve.org X-Trace: grandcanyon.binc.net 997714676 20328 192.135.80.34 (13 Aug 2001 14:57:56 GMT) X-Complaints-To: abuse@binc.net NNTP-Posting-Date: Mon, 13 Aug 2001 14:57:56 +0000 (UTC) Xref: archiver1.google.com comp.lang.ada:11854 Date: 2001-08-13T10:07:09-05:00 List-Id: In article <3B77E4A4.50FFA02B@amsjv.com>, Des Walker writes: > Des Walker wrote: >> >> Hi, >> >> I think the Text_Io Get procedure attempts to get as many characters as >> the length of the supplied string and this can include multiple line >> feed characters. >> > > No, I was wrong here. Rereading the ARM suggests the Get procedure for a > string > "Determines the length of the given string and attempts that number of > Get operations for successive characters of the string (in particular, > no operation is performed if the string is null)." > > and the Get procedure for a Character > "After skipping any line terminators and any page terminators, reads the > next character from the specified input file and returns the value of > this character in the out parameter Item." But one should not infer any lack of efficiency in the implementation due to that description. Anybody skilled enough to write an Ada compiler knows how to make Get for a line operate without actual subprogram calls for each character. So long as the result is the same from the caller point of view, semantic equivalence is enough.