diff options
Diffstat (limited to 'gcc/ada/a-cdlili.ads')
-rw-r--r-- | gcc/ada/a-cdlili.ads | 33 |
1 files changed, 17 insertions, 16 deletions
diff --git a/gcc/ada/a-cdlili.ads b/gcc/ada/a-cdlili.ads index f87479cabe6..32f8d7749e7 100644 --- a/gcc/ada/a-cdlili.ads +++ b/gcc/ada/a-cdlili.ads @@ -2,11 +2,11 @@ -- -- -- GNAT LIBRARY COMPONENTS -- -- -- --- ADA.CONTAINERS.DOUBLY_LINKED_LISTS -- +-- A D A . C O N T A I N E R S . D O U B L Y _ L I N K E D _ L I S T S -- -- -- -- S p e c -- -- -- --- Copyright (C) 2004 Free Software Foundation, Inc. -- +-- Copyright (C) 2004-2005 Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- @@ -122,18 +122,20 @@ package Ada.Containers.Doubly_Linked_Lists is Count : Count_Type := 1); generic - with function "<" (Left, Right : Element_Type) - return Boolean is <>; - procedure Generic_Sort (Container : in out List); + with function "<" (Left, Right : Element_Type) return Boolean is <>; + package Generic_Sorting is - generic - with function "<" (Left, Right : Element_Type) - return Boolean is <>; - procedure Generic_Merge (Target : in out List; Source : in out List); + function Is_Sorted (Container : List) return Boolean; + + procedure Sort (Container : in out List); + + procedure Merge (Target, Source : in out List); + + end Generic_Sorting; procedure Reverse_List (Container : in out List); - procedure Swap (I, J : in Cursor); + procedure Swap (I, J : Cursor); procedure Swap_Links (Container : in out List; @@ -153,7 +155,7 @@ package Ada.Containers.Doubly_Linked_Lists is (Target : in out List; Before : Cursor; Source : in out List; - Position : Cursor); + Position : in out Cursor); function First (Container : List) return Cursor; @@ -200,14 +202,12 @@ private type Node_Access is access Node_Type; type Node_Type is - record + limited record Element : Element_Type; Next : Node_Access; Prev : Node_Access; end record; - function "=" (L, R : Node_Type) return Boolean is abstract; - use Ada.Finalization; type List is @@ -215,6 +215,8 @@ private First : Node_Access; Last : Node_Access; Length : Count_Type := 0; + Busy : Natural := 0; + Lock : Natural := 0; end record; procedure Adjust (Container : in out List); @@ -235,7 +237,7 @@ private for List'Write use Write; - Empty_List : constant List := List'(Controlled with null, null, 0); + Empty_List : constant List := (Controlled with null, null, 0, 0, 0); type List_Access is access constant List; for List_Access'Storage_Size use 0; @@ -249,4 +251,3 @@ private No_Element : constant Cursor := Cursor'(null, null); end Ada.Containers.Doubly_Linked_Lists; - |