comp.lang.ada
 help / color / mirror / Atom feed
From: Jeffrey Carter <spam@spam.com>
Subject: Re: Problems with Ada.Text_IO and strings.
Date: Tue, 14 Oct 2003 20:19:53 GMT
Date: 2003-10-14T20:19:53+00:00	[thread overview]
Message-ID: <JTYib.1060$7a4.695@newsread4.news.pas.earthlink.net> (raw)
In-Reply-To: <8336eb21.0310140439.393f2e8@posting.google.com>

Bleakcabal wrote:

> It would have been great if Ada strings read the end of line character
> and Put took care of them so the lines were automagicly sliced like C
> strings.

IIRC, C doesn't treat arrays of charany differently than any other 
array. There is, however, a large library in C that treats a NUL in an 
array of char as an EOS character.

Ada and C take 2 different, but consistent and workable, approaches to 
strings. You can certainly write a library in Ada to deal with strings 
the way C does. But this higher level of abstraction already exists in 
Ada as Ada.Strings.[Un]Bounded.

-- 
Jeff Carter
"Death awaits you all, with nasty, big, pointy teeth!"
Monty Python & the Holy Grail
20




  parent reply	other threads:[~2003-10-14 20:19 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-13 22:23 Problems with Ada.Text_IO and strings Bleakcabal
2003-10-13 23:51 ` Larry Hazel
2003-10-14  0:06 ` Chad R. Meiners
2003-10-14 12:32   ` Bleakcabal
2003-10-14 15:03     ` Robert I. Eachus
2003-10-14 15:16       ` Stephane Richard
2003-10-14 20:16         ` Jeffrey Carter
2003-10-14  1:29 ` Jeffrey Carter
2003-10-14 12:39   ` Bleakcabal
2003-10-14 12:57     ` sk
2003-10-14 14:14     ` Problems with Ada.Text_IO and strings. (wants EOL character) Larry Kilgallen
2003-10-14 16:20       ` Stephen Leake
2003-10-14 16:45         ` Stephane Richard
2003-10-14 20:19     ` Jeffrey Carter [this message]
2003-10-14 12:33 ` Problems with Ada.Text_IO and strings Bleakcabal
2003-10-15  6:25 ` CheGueVerra
2003-10-15 14:41   ` Martin Krischik
2003-10-15 19:50     ` CheGueVerra
2003-10-15 22:00       ` Ludovic Brenta
2003-10-16  1:19         ` Jeffrey Carter
2003-10-15 23:39       ` Chad R. Meiners
2003-10-19  7:36         ` Martin Krischik
2003-10-19 19:24           ` Chad R. Meiners
2003-10-15 17:23   ` Marius Amado Alves
2003-10-16  2:29   ` Steve
2003-10-16  5:51     ` CheGueVerra
2003-10-16  9:51       ` CheGueVerra
replies disabled

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