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=0.1 required=5.0 tests=BAYES_05,FREEMAIL_FROM, INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,955f3216aaa64cc0,start X-Google-Attributes: gid103376,public From: "Matt Tyler" Subject: Doubly linked list (again, sorry) Date: 1998/12/16 Message-ID: <7580p3$q00@romeo.logica.co.uk>#1/1 X-Deja-AN: 422822416 Organization: Logica UK Limited X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 Newsgroups: comp.lang.ada Date: 1998-12-16T00:00:00+00:00 List-Id: Hello. I have created a doubly linked list. With the procedure (body only) List:=new cell'(V,Next=>, Prev=>null); V=integer and prev,next are access types to next and previous cells in list. I want to loop through the list in both directions. I can loop in the reverse order to creation using a loop containing: L:=L.Next; (where L is also an access type to cell) To loop from start of list do I need to create a (say) Start_of_list access type to the first cell in the list or is there a more elegant way that I am missing. Also, when I remove (to delete) a record from the list do I have to de-allocate the memory occupied by the object or is it done for me. I am sorry to waste your time but I am having a few problems with access types. Thanks in advance Matt Tyler