Re: Real Time IO routines
- From: Adam Beneschan <adam@xxxxxxxxxx>
- Date: Mon, 29 Oct 2007 09:18:17 -0700
On Oct 27, 1:15 pm, a...@xxxxxxxx (anon) wrote:
Ada Purist never and I mean NEVER uses IMAGE attribute, in the body of
a program. They create a package or sub-package that performs the IO
functions with the use of the IMAGE attribute.
IMAGE attribute is the last thing a programmer should use. to print a value.
It is normally use for DEBUGGING ONLY! A programmer should always create
a routine or better yet a package that uses an algorithm to prints the value
without the use of attributes.
Sorry, that's just nonsense. The semantics and result of 'Image are
well-defined by the language. If those semantics are acceptable for a
particular use, then there's nothing wrong with using 'Image (unless
there's an issue with using a secondary stack as Ludovic mentioned).
If they're not, then don't use it. 'Image does not return things in a
way that makes it amenable to nicely formatted reports where things
line up. (If you are creating a report with real numbers where you
want all the decimal points to line up, 'Image is probably not
best.) Other than that, I can see no reason not to use 'Image except
that perhaps it has been decreed impure by the High Priests of Purity,
who apparently have determined this in some ritual in which they dance
around a statue of Ada Lovelace and burn huge listings of C++ code and
chant some incantation to ask the statue what constructs are
considered holy and pure. That's the only reason I can think of---
there doesn't seem to be any reason based in practical benefit to
anyone. On the other hand, any ritual in which a bunch of C++ code is
burned can't be all bad.
P.S. I have been working with Ada for 19 years and I use 'Image when
it's appropriate. I'm definitely not a newbie.
-- Adam
.
- Follow-Ups:
- Re: Real Time IO routines
- From: Jean-Pierre Rosen
- Re: Real Time IO routines
- From: Robert A Duff
- Re: Real Time IO routines
- References:
- Real Time IO routines
- From: andrew
- Re: Real Time IO routines
- From: anon
- Re: Real Time IO routines
- From: Dmitry A. Kazakov
- Re: Real Time IO routines
- From: anon
- Real Time IO routines
- Prev by Date: Re: Only one Ada vendor?
- Next by Date: Re: Real Time IO routines
- Previous by thread: Re: Real Time IO routines
- Next by thread: Re: Real Time IO routines
- Index(es):
Relevant Pages
|