expression  : andExpr 'or' expression | andExpr #{ "$item[1] $item[2]"}
    andExpr     : notExpr 'and' andExpr | notExpr
    notExpr     : 'not' brackExpr | brackExpr
    brackExpr   : '(' expression ')' | comparison
    comparison  : identifier compType identifier { "$item[1]  $item[2] $item[3]\n" }
    compType    : '=' | '>' | '<' | '>=' | '<='
    identifier  : fieldName | number
    fieldName   : /[a-z]+/
    number      : /\d+/


fieldx >  3 or fieldy < 12 

i get "fieldx > 3"

fieldx >  3 or fieldy < 12 and fieldX = 32

i get nothing... what is my problem ?! i got the example from Parse::RecDescent docs 
and extended it with "comparison"..
what i'm doing wrong... seems i can't figure out the recusrion

tia
raptor

Reply via email to