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,75c440b4b7ed5f91 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!news4.google.com!news.germany.com!newsfeed2.scan-plus.net!newsfeed.ision.net!newsfeed2.easynews.net!ision!newsfeed.arcor.de!newsspool3.arcor-online.net!news.arcor.de.POSTED!not-for-mail Newsgroups: comp.lang.ada Subject: Re: Real Time IO routines -- answering Simon Wright part 1 From: Georg Bauhaus In-Reply-To: References: <1193410739.367181.96050@50g2000hsm.googlegroups.com> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1193693060.13888.62.camel@kartoffel> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 Date: Mon, 29 Oct 2007 22:24:20 +0100 Organization: Arcor NNTP-Posting-Date: 29 Oct 2007 22:23:43 CET NNTP-Posting-Host: 39d88ced.newsspool3.arcor-online.net X-Trace: DXC=4:n3KFGAL7f]BlmkiiU@BiMcF=Q^Z^V3h4Fo<]lROoRa4nDHegD_]ReOghlW2cY=9aN[W On Mon, 2007-10-29 at 19:28 +0000, anon wrote: > -- Basically, what's wrong with the IMAGE attribute? > -- > -- Using IMAGE Attribute. Output formatted and style set by vendor > -- and the output format is not specified in Ada RM. > > [examples of formatted I/O] True, programming of formatted I/O of values in general requires this approach. Text_IO.Editing is also quite nice (though it is not available with every compiler...). But, IO packages help with _formatted_ output of non-String values. _Formatted_ output of simple String values will, by comparison, require formatting efforts, too! Same requirements, same approach. I can think of many good reasons to just write unformatted string values to Current_Output. (Which is 'Pseudo_Image for Strings ;-) [1] For example, tabulation may require narrowing to columns, paragraphs might have to be shaped, words truncated etc.. The circumstances are similar to those requiring numbers with Aft, say. So using 'Image or not seems a use case issue to me. Seen from this point of view, the language, or some notion of purity, cannot decide what the use case is. Using IO packages can, in my view, also be over the top when programmers apply their stylistic preferences to external representations of output, possibly, and unintentionally, hiding valuable information that would in fact be produced by 'Image, if used with someone else's Ada system. [1] I guess this sounds silly, but I don't see numbers to be special for the moment: For the reader, a word is an approximation of a value, too.