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,99e8b9cfc31999f4 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews2.google.com!not-for-mail From: evangeli@cnam.fr (Evangelista Sami) Newsgroups: comp.lang.ada Subject: Re: explanation about an error message Date: 7 Jul 2004 12:51:42 -0700 Organization: http://groups.google.com Message-ID: <5f59677c.0407071151.697198f6@posting.google.com> References: <5f59677c.0407070157.7e5d523@posting.google.com> NNTP-Posting-Host: 82.123.26.138 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1089229902 15053 127.0.0.1 (7 Jul 2004 19:51:42 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 7 Jul 2004 19:51:42 +0000 (UTC) Xref: g2news1.google.com comp.lang.ada:2104 Date: 2004-07-07T12:51:42-07:00 List-Id: Georg Bauhaus wrote in message news:... > Evangelista Sami wrote: > : > : generator.adb:4:06: unit in with clause is private child unit > : generator.adb:4:06: current unit must also have parent "Decls" > > : file generator.adb : > : ------------------------------- > : > : with Generator.Decls; use Generator.Decls; > : with Generator.Decls.Vars; use Generator.Decls.Vars; > : package body Generator is > : ... > : end generator; > : ------------------------------- > : > : line 4 is "with Generator.Decls.Vars; use Generator.Decls.Vars;". > : generator.decls and generator.decls.vars are two private packages. > > I've found it useful to think of children as of nested packages: > > package Generator is > > procedure run; > > private -- part of Generator > > foo: Wide_Character; > > package Vars is > > var_foo: Wide_Character; > > > private -- part of Vars > > package Decls is > decl_foo: Wide_Character; > end Decls; > > end Vars; > > end Generator; > > package body Generator is > > --------- > -- run -- > --------- > > procedure run is > oops: Wide_Character; > begin > oops := Vars.var_foo; > oops := Vars.Decls.decl_foo; > end run; > > end Generator; > > > 11. oops := Vars.Decls.decl_foo; > | > >>> "Decls" is not a visible entity of "Vars" so what i'm tryng to do is impossible?