Re: Real Time IO routines



anon@xxxxxxxx (anon) writes:

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.

Mostly programs that are created by newbees use IMAGE attribute.

I must be a newbie (NB spelling!) then.

Where on earth do you get this viewpoint from? Please say why it is
better to instantiate enumeration IO for Boolean rather than to use
Boolean'Image?

I suppose you would ban people from using Integer_IO, too. Good grief.

And as for my code! It answer the person question without adding extra
code that might confuse him. Plus, the "Ada.Real_Time" package uses:

type Time is new Duration;

which is in private section. So I know what to convert the value to.

This is true so long as you and the person to whom you are giving
advice are both using *this version of* *GNAT*. Whatever makes you
suppose that the code you see in that private part will be the same
for any other compiler? or for any other version of GNAT? or for GNAT
for a different platform?
.



Relevant Pages

  • Re: PowerEdge SC600 memory upgrade
    ... systems with Quickbooks 4 and the trash software, ... when I informed them that a software conversion to a newer custom ... CSV or other type file format, then have a programmer or perhaps the company ... whatever package they would like to buy will end up using addition/different ...
    (alt.sys.pc-clone.dell)
  • Re: GNAT on WinXP: System.OS_Lib.Spawn raises Program_Error
    ... But you're correct that I was wrong about the warning being generated in this case. ... packages with each package routine, and including the package limitations, ... It's called the GNAT Reference Manual, which does not document System.OS_Lib as part of the GNAT public library. ... Which allows the programmer to choose to use ...
    (comp.lang.ada)
  • Re: Literate Programming in Ada, AdaDoc, AdaBrowse
    ... This is my idea of what the beginning of a package specification might look ... the Titian term for them is that they have *'direct color'. ... The latter option will be more efficient for contexts which do not have direct ... the programmer could program two different algorithms for contexts ...
    (comp.lang.ada)
  • Re: Your strategies for managing code writing?
    ... whatever thats still up to the programmer itself. ... Delphi actually supports ... you could instead make one package and add all your units to that package, ... Bad -> requires lot's of space, a versioning system can safe space by only ...
    (alt.comp.lang.borland-delphi)
  • Re: Real Time IO routines -- answering Simon Wright part 1
    ... -- use of enumeration Boolean package and using the IMAGE attribute ... -- A) Full width control. ... -- I/O package for Boolean type. ... -- a routine in a programmer created package. ...
    (comp.lang.ada)