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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,39f3c359196fe8b4 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-04-20 09:58:04 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!newsfeed.vmunix.org!newsfeed01.sul.t-online.de!t-online.de!newsfeed.tpinternet.pl!newsfeed.gazeta.pl!news.onet.pl!not-for-mail From: "kat-Zygfryd" <6667@wp.pl> Newsgroups: comp.lang.ada Subject: Re: for x'address or variant Date: Sun, 20 Apr 2003 18:57:36 +0200 Organization: news.onet.pl Sender: samael_@op.pl@pl171.poznan.cvx.ppp.tpnet.pl Message-ID: References: NNTP-Posting-Host: pl171.poznan.cvx.ppp.tpnet.pl X-Trace: news.onet.pl 1050857883 22873 217.99.113.171 (20 Apr 2003 16:58:03 GMT) X-Complaints-To: abuse@onet.pl NNTP-Posting-Date: 20 Apr 2003 16:58:03 GMT X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Xref: archiver1.google.com comp.lang.ada:36321 Date: 2003-04-20T16:58:03+00:00 List-Id: "Nick Roberts" wrote in message news:b7uhb9$4lb72$1@ID-25716.news.dfncis.de... > Declare the following: > > type Node; > type Node_Ref is access Node; > type Leaf_Direction is (Left, Right); > type Leaf_Pair is array (Leaf_Direction) of Node_Ref; > type Node is > record > Payload: ...; > Leaves: Leaf_Pair; > end record; > > Now you can reference, for example, the left leaf an object X1 of type Node > by: > > X1.Leaves(Left).all > > You can cycle through all the leaves of X1 by: > > for L in Leaf_Direction loop > ... X1.Leaves(L).all ... > end loop; > > I hope this solves the problem. Say if it doesn't. > > -- > Nick Roberts > Jabber: debater@charente.de [ICQ: 159718630] of course it does, but I wanted it to be done a little more good-looking, thanks anyway. Zygfryd