Am 08.03.2012 17:16, schrieb Troels Henriksen:
Christian Maeder writes:
The simplest solution is to parse the prefixes yourself and do not put
it into the table.
(Doing the infixes "&" and "|" by hand is no big deal, too, and
possibly easier then figuring out the capabilities of
buildExpressi
Christian Maeder writes:
> The simplest solution is to parse the prefixes yourself and do not put
> it into the table.
>
> (Doing the infixes "&" and "|" by hand is no big deal, too, and
> possibly easier then figuring out the capabilities of
> buildExpressionParser)
Is there another solution?
The simplest solution is to parse the prefixes yourself and do not put
it into the table.
(Doing the infixes "&" and "|" by hand is no big deal, too, and possibly
easier then figuring out the capabilities of buildExpressionParser)
Cheers C.
Am 07.03.2012 13:08, schrieb Troels Henriksen:
Con
Consider a simple language of logical expressions:
> import Control.Applicative
> import Text.Parsec hiding ((<|>), many)
> import Text.Parsec.String
> import Text.Parsec.Expr
>
> data Expr = Truth
> | Falsity
> | And Expr Expr
> | Or Expr Expr
> | Not Expr