I'm using Parsec and the example version of boolExpr http://hpaste.org/86299 at the moment. I'm compiling on Windows via GHC.
The code above will match a boolean expression like 3 < 4 or a not 3 however it will not match an expression like 3, true or (((3 < 1))). Can anyone give me advice on how to match such expressions like 3 and (((3 < 1))) the same as 3 > 0 and (((3 < 1))) > 0, where the >0 is assumed/added automatically on RHS-less expressions?
"3"into the same structure as"3 > 0"? - Tikhon Jelvis3 > 0results in an expression that validates if (expr) expr; however(3 > 0)results in (expr), hence, for that to be valid I must be able to parse any single term inside brackets against >0 if there is no RHS.(((3))) -> (((3 > 0) > 0) > 0) > 0unless you know a better way to do it so that expressions likewhile (1),while ((1))andwhile ((x>2))are valid. - kvanbere