From: boaz@usa.pipeline.com(Boaz Chow)
Subject: Re: Problems in GNAT with get_line
Date: 1996/06/08
Date: 1996-06-08T00:00:00+00:00 [thread overview]
Message-ID: <4pb8tu$559@news2.h1.usa.pipeline.com> (raw)
In-Reply-To: p135577.833888371@proffa
Try put a SKIP_LINE in front of your GET_LINE.
On Jun 04, 1996 14:41:25 in article <Problems in GNAT with get_line>,
'p135577@proffa.cc.tut.fi (Peteri Matti)' wrote:
>
> Hi
>
>I've got this little problem that for some reason get_line doesn't stop
>to wait the user input.
>
>So, I use GNAT95, and in my main program I call this subprogram where I
>make these declarations
>
> ansStr :string(1..stringMax);
> strLgt :integer;
>
>and in the body I put something on the screen with put_line and put.
>After this I want to read a string with a command
>
> get_line(ansStr,strLgt);
>
>but to my suprise my program doesn't wait for the input and as I have on
>the next line
>
> put(ansStr & "foo");
>
>there's nothing intelligent on ansStr. And I get a "raised constraint
>error"...
>
>And if I use simply get(ansSTr); it stops waitin' for user input and waits
>and waits and nothing goes on...
>
>So where could I go wrong? At the GNAT examples there is an example
>that uses the same kind on declarations and commands.
>
>Thanks in advance - I'm sure it's some stupid little mistake but I
>haven't been able to detect it myself.
>
> Matti
>
>----------------------------------------------------------
>Matti Peteri Residence Universitaire
>Computer Science 4rth year 6 Bis Rue Winston Churchill
>peteri@linux.utc.fr 60200 Compiegne, France
>
>--
>----------------------------------------------------------
>Matti Peteri Residence Universitaire
>Computer Science 4rth year 6 Bis Rue Winston Churchill
>peteri@linux.utc.fr 60200 Compiegne, France
--
______ Meow
\ OO / _/
:(__ =)
U \\
http://www.sci.csupomona.edu/~cchow
prev parent reply other threads:[~1996-06-08 0:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-06-04 0:00 Problems in GNAT with get_line Peteri Matti
1996-06-08 0:00 ` Boaz Chow [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