comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Generic warning
Date: Tue, 17 Jun 2008 19:17:01 +0200
Date: 2008-06-17T19:17:03+02:00	[thread overview]
Message-ID: <iyg4tdla7x2a.1e9ubbvqz88c0$.dlg@40tude.net> (raw)
In-Reply-To: g38pkv$vi9$1@registered.motzarella.org

On Tue, 17 Jun 2008 16:44:10 +0000, S�bastien Morand wrote:

> When I create an instance of the package using the following code:
> 
>  9   package IT is new SCMAL.Tools.BTrees(
> 10      Element => Integer,
> 11      Element_Null => 0,
> 12      Key => Integer,

As a guess, there could be a conflict upon instantiation when Element and
Key are the same type. I had once such a problem. GNAT always had problems
with generics.

> Where theses warnings come from? How to correct my code?

Maybe it is just a compiler bug. But you should post a complete compilable
code.

> Is there a way to avoid to take the default "<" and ">" function?

I don't see you using defaults for the formal parameters "<" and ">". You
have:

   with function "<"(k1: in Key; k2: in Key) return Boolean;
   with function ">"(k1: in Key; k2: in Key) return Boolean;

not

   with function "<"(k1: in Key; k2: in Key) return Boolean is <>;
   with function ">"(k1: in Key; k2: in Key) return Boolean is <>;

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



  reply	other threads:[~2008-06-17 17:17 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-17 16:44 Generic warning Sébastien Morand
2008-06-17 17:17 ` Dmitry A. Kazakov [this message]
2008-06-17 18:33   ` Sébastien Morand
2008-06-17 19:04     ` Dmitry A. Kazakov
2008-06-18  8:41       ` Sébastien Morand
2008-06-18 14:16         ` Brian Drummond
2008-06-18 14:32           ` Sébastien Morand
2008-06-18 14:39             ` Ed Falis
2008-06-18 14:42             ` Dmitry A. Kazakov
2008-06-18 15:10               ` Robert A Duff
2008-06-18 15:25                 ` Dmitry A. Kazakov
2008-06-18 15:38                   ` Ed Falis
2008-06-18 17:04                     ` Dmitry A. Kazakov
2008-06-17 18:20 ` Jeffrey R. Carter
2008-06-18  8:55   ` Sébastien Morand
replies disabled

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