Library
Module
Module type
Parameter
Class
Class type
This modules defines a functor whose image is a parser for terms with applications, binary and unary operators. These terms are specified in the argument of the functor.
The algorithm implemented is an extension of the Pratt parser. The Shunting Yard algorithm could also be used.
Priority of operators, also called binding power. If *
has a higher priority than +
, than x + y * z
is parsed x + (y * z)
.
type operator =
| Bin of associativity
Binary operator with an associativity.
*)| Una
Unary operator.
*)A type to designate operators and their properties.
module type SUPPORT = sig ... end
Types and utilities on terms that are to be Pratt parsed.