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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,463c997594f91391 X-Google-Attributes: gid103376,public From: Robert Dewar Subject: Re: Get_Immediate warning, (was: How to get a character?) Date: 1999/04/14 Message-ID: <7f2biq$bqu$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 466308496 References: <370EE07D.67C71458@dave-world.net> <87k8vkag6f.fsf@bglbv.my-dejanews.com> <923936702.835.91@news.remarQ.com> <371304D4.81D40292@ddre.dk> <7eva5j$npf$1@nnrp1.dejanews.com> <87hfqkgnrm.fsf@bglbv.my-dejanews.com> X-Http-Proxy: 1.0 x1.dejanews.com:80 (Squid/1.1.22) for client 205.232.38.14 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Wed Apr 14 15:17:55 1999 GMT Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.04 [en] (OS/2; I) Date: 1999-04-14T00:00:00+00:00 List-Id: In article <87hfqkgnrm.fsf@bglbv.my-dejanews.com>, bglbv@my-dejanews.com wrote: > The standard is clearly written under the assumption that > interactive input isn't normally buffered more than one > line at a time, but this doesn't seem to be even an > Implementation Advice, much less a requirement. That's quite wrong. The standard is written under the assumption that Text_IO is reading and writing files. Well more accurately, the Ada 83 standard is written that way, and the Ada 95 standard copies the definitions, adding only Flush and Get_Immediate, both of which are pretty much completely implementation dependent. The entire issue of applying Text_IO to "interactive I/O" (whatever that may be, this is not a technical term), is in fact implementation dependent. If you try to do a VERY accurate implementation of Text_IO on interactive terminals, you sometimes have to press Line return twice, since you need to be sure there is no page mark in the input before you know exactly what is going on. Most reasonable Ada compilers do something about this (e.g. GNAT defines that there are no page marks for non regular files), but this is definitely in the implementation dependent area. Basically the design approach was that Text_IO is to be used for simple I/O with no fancy requirements (sort of like DISPLAY and ACCEPT in COBOL). The assumption (even more true in these windowed days) is that any serious I/O will be done with packages at a completely different level in any case. -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own