Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
<*>
takes a function wrapped inside our parser context (created via return <some function>
), and a parser. It then forwards the value of the parsed result (if parser succeeds) and feeds it to the wrapped function. This is the apply
operator of our parser applicative functor.
p1 *> p2
takes two parsers p1 and p2, runs p1, discards its results and then returns the result of parser p2.
p1 <* p2
runs p1 followed by p2. It discards the result of p2 and returns the result of p1.