Boost Spirit Library

The BoostSpiritLibrary is one of the BoostLibraries. See

Spirit is an object-oriented recursive-descent parser generator framework implemented using template meta-programming techniques. Expression templates allow us to approximate the syntax of Extended Backus-Normal Form (EBNF) completely in C++.

The Spirit framework enables a target grammar to be written exclusively in C++. Inline EBNF grammar specifications can mix freely with other C++ code and, thanks to the generative power of C++ templates, are immediately executable. In retrospect, conventional compiler-compilers or parser-generators have to perform an additional translation step from the source EBNF code to C or C++ code.

It makes use of other BoostLibraries, including the BoostPhoenixLibrary.

See also CppTemplateMetaprogramming (book) which gives examples of its use.
See BoostLibraryDiscussion
CategoryBoost CategoryCpp CategoryMetaprogramming

View edit of June 25, 2012 or FindPage with title or text search