Because of limitations of the C++ language, the syntax of Spirit has been designed around the operator precedences of C++, while bearing resemblance to both EBNF and regular expressions.
This example shows how to use an inline parser expression with a semantic action.
Guzman, Joel de; Kaiser, Hartmut. "Spirit 2.59 - Introduction". Boost.org. Boost. Retrieved 22 March 2025. https://www.boost.org/doc/libs/1_87_0/libs/spirit/doc/html/spirit/introduction.html ↩