comp.lang.ada
 help / color / mirror / Atom feed
From: Erlo Haugen <_elh_@_tema_._com_>
Subject: Re: types and non-contigous ranges
Date: Mon, 01 Mar 2004 09:50:22 +0100
Date: 2004-03-01T09:50:22+01:00	[thread overview]
Message-ID: <4042f968$0$179$edfadb0f@dread11.news.tele.dk> (raw)
In-Reply-To: <103vmg915hgv491@corp.supernews.com>

Randy Brukardt skrev:
> "Erlo Haugen" <_elh_@_tema_._com_> wrote in message
> news:403ef778$0$128$edfadb0f@dread11.news.tele.dk...
> 
>>I want to use the set/type like  this:
>>My_array : array[Valid_Characters] of something;
>>That excludes the character set, I guess.
> 
> 
> No, that excludes using an array. :-)
> 
> There is no such thing as discontiguous ranges in Ada; you'll have to create
> it yourself somehow. Ada.Strings.Maps is the easiest way for this particular
> case. For the array, I'd just make it an array (Character) of something, and
> just not use the 'invalid' slots. It's hardly worth the effort to do
> anything else unless "something" is very large.
> 
That was my conclusion too. So I create an array(character) of whatever 
and put empty (null) values in the unused positions.
It just seems like a "Non-Ada-ish" way..

-- 
Erlo
-----
Remove underscores from mail address.
The statements and opinions are mine and does not
neccesarily reflect those of my employers




      reply	other threads:[~2004-03-01  8:50 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-26 14:17 types and non-contigous ranges Erlo Haugen
2004-02-26 15:52 ` Jacob Sparre Andersen
2004-02-27  7:55   ` Erlo Haugen
2004-02-27 13:00     ` Jacob Sparre Andersen
2004-02-27 13:21       ` Erlo Haugen
2004-02-27 13:58         ` Character encoding (Was: types and non-contigous ranges) Jacob Sparre Andersen
2004-02-26 16:07 ` types and non-contigous ranges Dmitry A. Kazakov
2004-02-27  7:53   ` Erlo Haugen
2004-02-27 23:59     ` Randy Brukardt
2004-03-01  8:50       ` Erlo Haugen [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