pack

fun <S, A, B : Any, C : Any> pack(p: Parser<S, A>, r: Parser<S, B>, q: Parser<S, C>): Parser<S, B>

Creates a parser that matches a sequence of three parsers, returning the result of the middle parser.

Return

A parser that matches the sequence of p, r, and q, returning the result of r.

Parameters

p

The first parser.

r

The second parser.

q

The third parser.