The INI parser is a combinatorial top-down recursive-descent parser. Its monad instance creates a composable function that can be run later with runParser with input. We used monad/Applicative and Functor to combine the parser combinatorially from smaller units such as char, quotedchar, quotedvalue, and so on until we build the whole INI file parser.
Every time we compose two parsers, we create a function that first runs one parser, evaluates its value and remaining input, and then invokes the second parser to again evaluate its value. Such nesting and sequencing of parsers gives rise to a composition of parsing functions. The resultant parser function can be run on input to get the desirable value.
The parser is diagrammatically explained here:
