rustre_parser

Module parser

Source
Expand description

Individual parsers for Lustre’s grammar

If you want to parse an entire program, you’ll mostly use parse_program. However, this module gives you access to finer parsers, in case you need to build the syntax tree of a very specific element. Most parsers in this file are grouped in submodules according to the same “Ebnf groups” that appear in the official specification. There is however no guarantee that all parsers here map 1:1 to a parsing rule from the specification.

§Errors

While parsing an entire program isn’t supposed to make the actual parser fail, if you go about parsing individual syntax elements using a parser from this module, their parsers may fail, typically if the first (few) token(s) are/is unexpected.

Modules§

Functions§