I need to take a string typed by dirty users’ fingers, that should
boolean expression, like this:
one and (two or three or (four and five) or six) and (seven or eight)
…and parse it into some kind of sensible data structure, like a tree or
something. Or reject it if it’s mal-formed.
I figure it might take me two or three days to write and debug from
(…hey, I’m fairly new to Ruby :\ ), but I’m sure there’s a library
somewhere that will do the job.
I’ve tried searching for bool*, expr* and pars* in fxri but didn’t get
anything, and Googling just tells me that my search terms are too
find what I want. Any suggestions?
Thanks in advance!