diff options
author | Jed Barber <jjbarber@y7mail.com> | 2020-11-12 17:06:06 +1100 |
---|---|---|
committer | Jed Barber <jjbarber@y7mail.com> | 2020-11-12 17:06:06 +1100 |
commit | 84696069475bfa7732326dee94a2c8a852ece827 (patch) | |
tree | 9e48e554c21238150f24b9b5c94d499494772144 /src | |
parent | eccf08d5ee8915688841b47cff1d487732da8f06 (diff) |
Outline of tests for Parse_Graphs
Diffstat (limited to 'src')
-rw-r--r-- | src/packrat-parse_graphs.adb | 1 | ||||
-rw-r--r-- | src/packrat-parse_graphs.ads | 4 | ||||
-rw-r--r-- | src/packrat.ads | 4 |
3 files changed, 7 insertions, 2 deletions
diff --git a/src/packrat-parse_graphs.adb b/src/packrat-parse_graphs.adb index 1705d36..eed2eee 100644 --- a/src/packrat-parse_graphs.adb +++ b/src/packrat-parse_graphs.adb @@ -259,6 +259,7 @@ package body Packrat.Parse_Graphs is SU.Delete (Result, SU.Length (Result), SU.Length (Result)); end loop; -- what delete goes here? + SU.Append (Result, Latin.LF); end loop; return SU.To_String (Result); end Debug_String; diff --git a/src/packrat-parse_graphs.ads b/src/packrat-parse_graphs.ads index 2912110..de5e4e9 100644 --- a/src/packrat-parse_graphs.ads +++ b/src/packrat-parse_graphs.ads @@ -68,8 +68,8 @@ package Packrat.Parse_Graphs is (Left, Right : in Finished_Token_Array) return Boolean; - type Token_Group is private with Type_Invariant => - Ada.Containers.">" (Length (Token_Group), 0); + use type Ada.Containers.Count_Type; + type Token_Group is private with Type_Invariant => Length (Token_Group) > 0; type Token_Group_Array is array (Positive range <>) of Token_Group; function "<" diff --git a/src/packrat.ads b/src/packrat.ads index 6032cb1..58afbaa 100644 --- a/src/packrat.ads +++ b/src/packrat.ads @@ -20,6 +20,10 @@ package Packrat is + -- need to restructure all this to separate these nested packages out into their own files + -- and also to add in a Traits package to contain the Enum/Element/Array generic stuff + + package Errors is |