sig/dolos/parser.rbs in dolos-0.2.0 vs sig/dolos/parser.rbs in dolos-0.2.1

- old
+ new

@@ -2,18 +2,22 @@ class Parser[A] attr_accessor parser_proc: ^(ParserState) -> Result[A] def initialize: (^(ParserState) -> Result[A]) -> Parser[A] def capture!: -> Parser[A] def choice: [B](Parser[B])-> Parser[A | B] + def combine: [B](^(A, B) -> Parser[B]) -> Parser[B] def flat_map: [B](Parser[A], ^(A) -> Parser[B]) -> Parser[B] def flatten: -> Parser[A] def map: [B](^(A) -> B) -> Parser[B] - def map_value: [B](^(A) -> B) -> Parser[B] + def map_captures: [B](^(A) -> B) -> Parser[B] def optional: -> Parser[A?] def product: [B](Parser[A]) -> Parser[B] + def product_l: [B](Parser[B]) -> Parser[B] + def product_r: [B](Parser[B]) -> Parser[A] def run: (String) -> Result[A] def run_with_state: (ParserState) -> Result[A] - def repeat: (Integer, Integer)-> Parser[Array[A]] + def repeat: [B](Integer, Integer, Parser[B]?)-> Parser[Array[A]] def zero_or_more: -> Parser[Array[A]] def one_or_more: (Integer?) -> Parser[Array[A]] + def lazy: -> Parser[A] end end