comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: String literals and wide_string literals - how?
Date: Fri, 20 Apr 2007 22:48:39 +0200
Date: 2007-04-20T22:47:28+02:00	[thread overview]
Message-ID: <wk5ssmauy217$.v6n76a544he0.dlg@40tude.net> (raw)
In-Reply-To: f0b3e8$vec$1@jacob-sparre.dk

On Fri, 20 Apr 2007 14:16:11 -0500, Randy Brukardt wrote:

> "Robert A Duff" <bobduff@shell01.TheWorld.com> wrote in message
> news:wccbqhjw0we.fsf@shell01.TheWorld.com...
> ...
>> String literals are not necessarily of type String; they can be of any
>> "string type".  A string type is any one-dimensional array of some
>> character type.  You can even do weird things like this:
>>
>>     type Bit is ('0', '1');
> 
> That's not that weird. My favorite example of this came from an early Ada 83
> book:
> 
>     type Roman_Digit is ('I', 'V', 'X', 'L', 'C', 'D', 'M');

What about a DNA-sequences?

   type Nucleotide is ('A', 'C', 'G', 'T');
   type DNA_Sequence is array (Positive range <>) of Nucleotide;

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de



  parent reply	other threads:[~2007-04-20 20:48 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-20 10:07 String literals and wide_string literals - how? Gerd
2007-04-20 14:33 ` Adam Beneschan
2007-04-20 14:55 ` Robert A Duff
2007-04-20 19:16   ` Randy Brukardt
2007-04-20 20:01     ` Adam Beneschan
2007-04-20 20:41       ` Dmitry A. Kazakov
2007-04-20 20:02     ` Robert A Duff
2007-05-21  2:33       ` David Thompson
2007-05-22 22:32         ` Randy Brukardt
2007-05-23 18:42           ` Jeffrey R. Carter
     [not found]             ` <f324h5$fna$1@f04n12.cac.psu.edu>
2007-05-24 21:15               ` Jeffrey R. Carter
2007-05-23  2:27         ` Keith Thompson
2007-07-01  1:00           ` David Thompson
2007-05-23 12:28         ` brian.b.mcguinness
2007-04-20 20:48     ` Dmitry A. Kazakov [this message]
2007-04-20 22:09   ` Jeffrey R. Carter
2007-04-21  9:41     ` Simon Wright
2007-04-22  0:35       ` Jeffrey R. Carter
2007-04-22  9:45         ` Simon Wright
2007-04-22 20:15           ` Jeffrey R. Carter
2007-04-22 21:18             ` Simon Wright
2007-04-23  1:44               ` Jeffrey R. Carter
2007-04-22  1:00     ` Robert A Duff
2007-04-20 14:58 ` Georg Bauhaus
replies disabled

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