From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,ce80c96b46825a21 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!news.flashnewsgroups.com-b7.4zTQh5tI3A!not-for-mail From: Stephen Leake Newsgroups: comp.lang.ada Subject: Re: Using the Hash function References: Date: Fri, 22 Jul 2011 02:33:47 -0400 Message-ID: <82y5zq4yes.fsf@stephe-leake.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (windows-nt) Cancel-Lock: sha1:8LctGqkZvc/ZwzEHTuszVj5/Ye4= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Complaints-To: abuse@flashnewsgroups.com Organization: FlashNewsgroups.com X-Trace: a1eaa4e2919c9e029e66118958 Xref: g2news1.google.com comp.lang.ada:20292 Date: 2011-07-22T02:33:47-04:00 List-Id: iloAda writes: > Hello everybody!! > > I am trying to use the hash function of the Unbounded_Strings package! > > Here's the code (very simple): > > 1 function Unbounded_String_Hash > 2 (U_Str : Ada.Strings.Unbounded.Unbounded_String) > 3 return Ada.Containers.Hash_Type > 4 is > 5 > 6 begin > 7 > 8 return Ada.Strings.Unbounded.Hash (U_Str); > 9 end Unbounded_String_Hash; > > I is giving me the following error on line 8 when I try to compile: > missing "with Unbounded.Hash"; > > > Can anybody tell me what's going on (knowing that Unbounded.Hash isn(t > an existing package)!! It isn't a package, it's a function. But it is declared at library level, as a separate compilation unit. So it needs a 'with' clause. -- -- Stephe