package pratter
An extended Pratt parser
Install
Dune Dependency
Authors
Maintainers
Sources
pratter-2.0.0.tar.gz
sha512=89fc9d0645e55dda7201a2cb47fe7bee774db92892c528efcbec179f270563088b1fab1d8d25ebca97b389947c2741f7a05127996cd1a4e3c7fe726be45ab835
doc/pratter/Pratter/index.html
Module Pratter
Source
This modules defines a functor whose image is a parser for terms with applications, infix, prefix or postfix 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.
Associativity of an operator.
Priority of operators, also called binding power. If *
has a higher priority than +
, than x + y * z
is parsed x + (y * z)
.
Source
type operator =
| Infix of associativity
(*Infix operator with an associativity.
*)| Prefix
| Postfix
A type to designate operators and their properties.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>