From: James Rogers <jimmaureenrogers@att.net>
Subject: Re: Converting numbers to strings without Ada.Text_IO?
Date: Fri, 09 Apr 2004 12:34:46 GMT
Date: 2004-04-09T12:34:46+00:00 [thread overview]
Message-ID: <Xns94C642A0A8BF7jimmaureenrogers@204.127.36.1> (raw)
In-Reply-To: c55ec1$gsj$1@sparta.btinternet.com
"Martin Dowie" <martin.dowie@btopenworld.com> wrote in
news:c55ec1$gsj$1@sparta.btinternet.com:
>> >> Well, my question is: how could in convert integer and real numbers
>> >> portably into strings without using Ada.Text_IO?
>> >
>> > You could copy the algorithm GNAT uses for conversions from
>> > Ada.Text_IO into your own package (with appropriate copyrighting kept)
>>
>> You could also simply call the 'Image attribute of the integer or
>> real number.
>
> My assumption (which could be wrong!) is the OP is using
> Ada.Text_IO.* to get access to finer levels of formatting
> the 'Image offers.
The Ada.Text_Io package provides the ability to convert between
number bases for integers. Other than that, there is no finer formatting
needed. Once a string version of an integer or real type is
created the programmer can parse and modify that string for any
additional formatting requirements.
Jim Rogers
next prev parent reply other threads:[~2004-04-09 12:34 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-04-08 17:25 Converting numbers to strings without Ada.Text_IO? Tapio Kelloniemi
2004-04-08 18:14 ` Martin Dowie
2004-04-09 3:50 ` James Rogers
2004-04-09 6:03 ` Martin Dowie
2004-04-09 12:34 ` James Rogers [this message]
2004-04-09 0:06 ` Stephen Leake
2004-04-09 9:58 ` Dmitry A. Kazakov
2004-04-12 5:13 ` Richard Riehle
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox