comp.lang.ada
 help / color / mirror / Atom feed
From: Jere <jhb.chat@gmail.com>
Subject: Re: Comparing Access Types
Date: Fri, 10 Nov 2017 08:22:27 -0800 (PST)
Date: 2017-11-10T08:22:27-08:00	[thread overview]
Message-ID: <0981102e-a656-43e5-8216-f18bf7cfd650@googlegroups.com> (raw)
In-Reply-To: <wccd14qjf8w.fsf@TheWorld.com>

On Friday, November 10, 2017 at 11:00:17 AM UTC-5, Robert A Duff wrote:
> Jere writes:
> 
> > I'm not hugely in disagreement here, but I am curious as to why it doesn't
> > make sense.
> 
> What would it mean?  If X /= Y, then X < Y returns either True
> or False arbitrarily?  That could work, but it doesn't seem all
> that useful.
> 
> If a garbage collector is moving things around in memory,
> then it would be hard to implement efficiently.

Ok, that makes sense.  The use case I had was more for keys in a map.  I
didn't really care about the actual order, but wanted a way to store a
collection of objects using the access types as the key.  That
would allow for quick searching in large groups.  With the incomplete
type formal parameter, I was having trouble coming up with options.

However, I don't have to implement it that way.  Dmitry comments 
gave me some ideas.  I can either push that off to the client in 
a different way or add more formal parameters to my generic to 
support it if I want.

> 
> > For debugging purposes, I do wish there was a way for me to get a printable
> > unique value for access types.
> 
> Unchecked convert to type Integer_Address, then use 'Image.
> 
> - Bob

Thanks!  This worked. I can use that in my debug package.


  reply	other threads:[~2017-11-10 16:22 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-09  5:37 Comparing Access Types Jere
2017-11-09  8:29 ` Simon Wright
2017-11-09  8:33 ` Dmitry A. Kazakov
2017-11-09 22:38   ` Robert A Duff
2017-11-10  8:35     ` Dmitry A. Kazakov
2017-11-10 15:11       ` Jere
2017-11-10 16:05       ` Robert A Duff
2017-11-10 16:30         ` Robert A Duff
2017-11-16  1:17           ` Randy Brukardt
2017-11-18 22:01             ` Robert A Duff
2017-11-20 22:25               ` Randy Brukardt
2017-11-21  0:30                 ` Shark8
2017-11-21  8:57                   ` Dmitry A. Kazakov
2017-11-22  1:01                     ` Randy Brukardt
2017-11-10 15:20     ` Jere
2017-11-10 16:00       ` Robert A Duff
2017-11-10 16:22         ` Jere [this message]
2017-11-10 15:06   ` Jere
2017-11-16  1:21     ` Randy Brukardt
2017-11-16  1:13 ` Randy Brukardt
replies disabled

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