diff options
Diffstat (limited to 'src/packrat-parsers.ads')
-rw-r--r-- | src/packrat-parsers.ads | 42 |
1 files changed, 13 insertions, 29 deletions
diff --git a/src/packrat-parsers.ads b/src/packrat-parsers.ads index 6568238..471d667 100644 --- a/src/packrat-parsers.ads +++ b/src/packrat-parsers.ads @@ -63,17 +63,6 @@ package Packrat.Parsers is - type Component_Result is private; - - type Component is access function - (Input : in Traits.Element_Array; - Context : in out Parser_Context; - Start : in Positive) - return Component_Result; - - - - type With_Input is access function return Traits.Element_Array; @@ -82,36 +71,35 @@ package Packrat.Parsers is generic Label : in Traits.Label_Enum; - with function Combo + with function Root (Input : in Traits.Element_Array; Context : in out Parser_Context; Start : in Positive) return Combinator_Result; - function Root - (Input : in Traits.Element_Array; - Context : in out Parser_Context; - Start : in Positive) - return Component_Result; - - - - - generic - Root_Component : in Component; procedure Parse (Input : in Traits.Element_Array; Context : in out Parser_Context; Result : out Graphs.Parse_Graph); generic - Root_Component : in Component; + Label : in Traits.Label_Enum; + with function Root + (Input : in Traits.Element_Array; + Context : in out Parser_Context; + Start : in Positive) + return Combinator_Result; function Parse_Only (Input : in Traits.Element_Array; Context : in out Parser_Context) return Graphs.Parse_Graph; generic - Root_Component : in Component; + Label : in Traits.Label_Enum; + with function Root + (Input : in Traits.Element_Array; + Context : in out Parser_Context; + Start : in Positive) + return Combinator_Result; function Parse_With (Input : in With_Input; Context : in out Parser_Context) @@ -429,10 +417,6 @@ private Status : Result_Status := Failure; end record; - type Component_Result is record - Status : Result_Status; - end record; - Empty_Fail : constant Combinator_Result := (Results => Result_Sets.Empty_Set, Curtails => Curtail_Maps.Empty_Map, |