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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,21f683a2c713b788 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-10-26 19:18:46 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!headwall.stanford.edu!newsfeed.news2me.com!newsfeed2.earthlink.net!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!newsread1.prod.itd.earthlink.net.POSTED!not-for-mail Message-ID: <3DBB4CF3.5020402@acm.org> From: Jeffrey Carter User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.0.0) Gecko/20020530 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Boolean Operation on pointer (access) References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Date: Sun, 27 Oct 2002 02:17:55 GMT NNTP-Posting-Host: 63.184.105.198 X-Complaints-To: abuse@earthlink.net X-Trace: newsread1.prod.itd.earthlink.net 1035685075 63.184.105.198 (Sat, 26 Oct 2002 19:17:55 PDT) NNTP-Posting-Date: Sat, 26 Oct 2002 19:17:55 PDT Organization: EarthLink Inc. -- http://www.EarthLink.net Xref: archiver1.google.com comp.lang.ada:30170 Date: 2002-10-27T02:17:55+00:00 List-Id: Dominic D'Apice wrote: > Ok then, i use the clause use in my .ada for my package ads, it's > working, > but i don't understand why i need to put a use clause for only this king > of operator ? > > For the rest of my .ada program i only precede each thing by the .ads > package name > Ex : package.var := xxx; The things in a package mentioned in a context clause ("with") are not directly visible. This means you have to precede them with the package name to reference them. You can make everything in a package directly visible by naming the package in a use clause. Instead of X : Package_Name.Var; X := Package_Name."+" (X, 1); you can have use Package_Name; X : Var; X := X + 1; This is not always desirable. To only make the operators of a specific type from the package visible, you can name the type in a "use type" clause: use type Package_Name.Var; X : Package_Name.Var; -- "Package_Name." needed here X := X + 1; -- "+" is an operator for Var, so not needed here -- Jeff Carter "Why don't you bore a hole in yourself and let the sap run out?" Horse Feathers