Pre-existing parsers and importers allow us to deal with well-known languages and data formats. However, in many situations we have to reason about systems written in custom languages or formats.
In such situations we need to have the possibility of specifying custom parsers. Moose comes with PetitParser, a parsing framework that enables us to build custom parsers easily.
This chapter covers this framework. We start with a hands-on tutorial (see Section 14.1), and then we move on to looking into the overall design and the various components.