Type alias ParseState<D, E>Internal

ParseState<D, E>: ParseResult<D> | ParseError<E>

A unified type for the possible outcomes of parsing

A parse will output either:

  1. A ParseResult object, signaling a successful match on the target
  2. A ParseError object, signaling an erroneous parse.

Type Parameters