"James Harris" <james.harris.1@gmail.com> wrote in message> On Dec 29 2012, 1:11 pm, James Harris <james.harri...@gmail.com> wrote:> ...>>> 1. Hand-written, not the output of a parser generator.>> 2. Efficient and without backtracking.>> 3. Precedences (and possibly associativities) defined in tables.>> 4. Output to be a tree structure.>> 5. Parenthesised subexpressions allowed.>> 6. Some operator families are *not* to associate with each other. See>> below.>> 7. Monadic prefix, dyadic infix and monadic postfix operators are all>> allowed.>> 8. Prefix and infix operators can use some same symbols (e.g. minus>> sign).>>>> Infix and postfix operators use distinct symbols.>> ...>> Here is an idea for an expression parser to try to address the points> mentioned. I am not sure if it covers all the bases yet.

<snipped>

In case anyone is later looking for some code to parse expressions I should
say that I have placed an updated copy at