aboutsummaryrefslogtreecommitdiffstats
path: root/src/dyn_tables.ads
diff options
context:
space:
mode:
Diffstat (limited to 'src/dyn_tables.ads')
-rw-r--r--src/dyn_tables.ads9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/dyn_tables.ads b/src/dyn_tables.ads
index 600e2bf85..f1cffac84 100644
--- a/src/dyn_tables.ads
+++ b/src/dyn_tables.ads
@@ -71,6 +71,9 @@ package Dyn_Tables is
function Last (T : Instance) return Table_Index_Type;
pragma Inline (Last);
+ -- Return the index of the next bound after last.
+ function Next (T : Instance) return Table_Index_Type;
+
-- Deallocate all the memory. Makes the array unusable until the next
-- call to Init.
procedure Free (T : in out Instance);
@@ -95,11 +98,13 @@ package Dyn_Tables is
procedure Allocate (T : in out Instance; Num : Natural := 1);
private
+ type Unsigned is mod 2**32;
+
type Instance_Private is record
-- Number of allocated elements in the table.
- Length : Natural := 0;
+ Length : Unsigned := 0;
-- Number of used elements in the table.
- Last_Pos : Natural := 0;
+ Last_Pos : Unsigned := 0;
end record;
end Dyn_Tables;