|
SciLex
A header-only C++20 lexer built on REAL
|
A parsed grammar: the rules in order, and each rule's name (index = the rule's kind). More...
#include <grammar.hpp>
Public Member Functions | |
| std::string_view | name (int kind) const noexcept |
The name of kind, or "?" for a kind no rule of this grammar has (a reserved kind such as error). | |
Public Attributes | |
| std::vector< rule > | rules |
| The rules, kind i at index i. | |
| std::vector< std::string > | names |
| The name of kind i. | |
A parsed grammar: the rules in order, and each rule's name (index = the rule's kind).
|
inlinenoexcept |
The name of kind, or "?" for a kind no rule of this grammar has (a reserved kind such as error).
| [in] | kind | A token kind. |
| std::vector<std::string> scilex::grammar::names |
The name of kind i.
| std::vector<rule> scilex::grammar::rules |
The rules, kind i at index i.