comp.lang.ada
 help / color / mirror / Atom feed
From: jpwoodruff@gmail.com
Subject: Re: Noob question..  Autopromotion?
Date: Wed, 7 May 2014 09:13:45 -0700 (PDT)
Date: 2014-05-07T09:13:45-07:00	[thread overview]
Message-ID: <086f70f4-784b-4dd0-8b39-6e4815a378f3@googlegroups.com> (raw)
In-Reply-To: <ade7fae8-8b72-4530-aece-644425c0dfae@googlegroups.com>

On Tuesday, May 6, 2014 7:31:13 AM UTC-6, gautier...@hotmail.com wrote:
> Hello,
> 
> As Adam said, a figure read as a literal in the Ada source code and a figure read from a string from an user are different topics. Typically figures with or without .0 are valid (to GNAT and OA run-time libraries at least).
> 
Perhaps you might benefit from some old (1987 vintage) work of mine
that is useful for input of numeric (floating) values.

"The packages Numeric_IO and Name_IO, together with their children and
support, assist a program to read a user's input.  The packages are
intended to support numerical computation by providing Get and Put
procedures for floating numbers and for vectors and matrices of
floating numbers.

"The procedures ease an end-user's burden in preparing inputs for
computational programs.  The rules for input of floating numbers are
relaxed so that program inputs need not conform to the strict Ada
syntax for floating numbers. Facilities allow input either from files
or interactively. Consistent policies throughout all the services
allow programs to address input errors, to prompt the end-user
interactively or to specify optional default values."

http://www.dmitry-kazakov.de/ada/Numeric-Name-IO.htm

John

      reply	other threads:[~2014-05-07 16:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-05 14:22 Noob question.. Autopromotion? sdalemorrey
2014-05-05 14:54 ` Adam Beneschan
2014-05-05 15:32 ` Nasser M. Abbasi
2014-05-05 19:30   ` Simon Wright
2014-05-06 13:31 ` gautier_niouzes
2014-05-07 16:13   ` jpwoodruff [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox