Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Are you perchance running on a 64-bit machine? -- Larry Wall in <199711102149.NAA16878@wall.org>


devel / comp.lang.ada / Re: array from static predicate on enumerated type

SubjectAuthor
o Re: array from static predicate on enumerated typeThomas

1
Re: array from static predicate on enumerated type

<fantome.forums.tDeContes-A2ED4E.01384016032022@news.free.fr>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=6715&group=comp.lang.ada#6715

 copy link   Newsgroups: comp.lang.ada
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!cleanfeed2-a.proxad.net!nnrp2-1.free.fr!not-for-mail
From: fantome....@free.fr.invalid (Thomas)
Newsgroups: comp.lang.ada
Mail-Copies-To: nobody
Subject: Re: array from static predicate on enumerated type
References: <89128f73-fcc5-4e57-8067-d09877ba0211n@googlegroups.com> <s2gqnf$vbs$1@gioia.aioe.org> <6ca041f3-2669-4497-9548-2f17666702a6n@googlegroups.com> <s2hrn2$3ee$1@gioia.aioe.org> <26c44e00-a899-455a-a929-1e23c7935fe3n@googlegroups.com> <9abb081d-a323-466d-9ae8-a2fc8fa24725n@googlegroups.com> <s2ofr1$1cg3$1@gioia.aioe.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit
User-Agent: MT-NewsWatcher/3.5.3b3 (Intel Mac OS X)
Date: Wed, 16 Mar 2022 01:38:41 +0100
Message-ID: <fantome.forums.tDeContes-A2ED4E.01384016032022@news.free.fr>
Lines: 38
Organization: Guest of ProXad - France
NNTP-Posting-Date: 16 Mar 2022 01:38:41 CET
NNTP-Posting-Host: 91.175.52.121
X-Trace: 1647391121 news-1.free.fr 29490 91.175.52.121:4334
X-Complaints-To: abuse@proxad.net
 by: Thomas - Wed, 16 Mar 2022 00:38 UTC

In article <s2ofr1$1cg3$1@gioia.aioe.org>,
"Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> wrote:

> On 2021-03-15 18:48, Shark8 wrote:
>
> > So, in Ada, there's no good choice for how to actually DO an array with
> > gaps in the index:
>
> That applies to all containers. The problem is mapping the key to a
> dense position when the key is not dense or might be unordered.
>
> There is no gaps in positions.
>
> > But Array *isn't* a map, though often it is substituted as one.
>
> Of course it is, per definition of mapping. f : key -> element.
>
> > Array has further constraints, like the contiguous memory labeled above.
>
> No. The constraint here is a dense index. That is not specific to a
> general map or an array. It is a fundamental property of the set of keys
> being a convex set. Convex ensures certain useful mathematical
> properties invariant to the representation of the mapping. In
> particular, it gives a way to enumerate elements.

> Arbitrary predicate kills convex, so the problem. Not array. A map would
> have just same problem: a map of LETTERS is in general not substitutable
> for a map of CURVED_LETTERS.

i don't understand,
since Ada.Containers.Ordered_Maps.Key_Type is private,
and so new Ada.Containers.Ordered_Maps (CURVED_LETTERS, Integer) is
allowed.

--
RAPID maintainer
http://savannah.nongnu.org/projects/rapid/

1
server_pubkey.txt

rocksolid light 0.9.7
clearnet tor