A simple query parser generated by flex and bison
This is a simple query parser that recognizes logic queries like:
- this that // Parsed as "this AND that"
- this AND that
- this AND NOT that
- this AND NOT (he AND her)
- $ mkdir build
- $ cd build
- $ cmake ..
- $ make
./parser "this AND that"
This parser is not thread-safe since it uses global variables while parsing.
For those who may want to embed a thread-safe parser into their own application, please see SimpleQueryParser++
This is a toy project. I tried three methods to build a query parser. You can find the other two:
- SimpleQueryParserPlusPlus : A simple query parser generated by flex and bison (C++ Language)
- SimpleQueryParserSpirit : A simple query parser written in Boost.Spirit (C++ Language)