#include <Rule.h>
- Author
- piantado
- Date
- 08/02/20
◆ Rule()
◆ get_child_types()
auto& Rule::get_child_types |
( |
| ) |
const |
|
inline |
◆ get_hash()
size_t Rule::get_hash |
( |
| ) |
const |
|
inline |
◆ is_a()
bool Rule::is_a |
( |
Op |
o | ) |
const |
|
inline |
◆ is_recursive()
bool Rule::is_recursive |
( |
| ) |
const |
|
inline |
◆ is_terminal()
bool Rule::is_terminal |
( |
| ) |
const |
|
inline |
A terminal rule has no children.
- Returns
◆ makeInstruction() [1/2]
◆ makeInstruction() [2/2]
◆ operator()
auto Rule::operator |
( |
const Rule & |
r | ) |
const |
|
inline |
We sort rules so that they can be stored in arrays in a standard order. For enumeration, it's actually important that we sort them with the terminals first. So we sort first by terminals and then by probability (higher first).
- Parameters
-
- Returns
◆ operator==()
Two rules are equal if they have the same instructions, nonterminal, format, children, and children types
- Parameters
-
- Returns
◆ string()
std::string Rule::string |
( |
| ) |
const |
|
inline |
◆ type()
What type is my i'th child?
- Parameters
-
- Returns
◆ arg
◆ child_types
◆ ChildStr
const std::string Rule::ChildStr = "%s" |
|
static |
◆ format
◆ fptr
◆ my_hash
std::size_t Rule::my_hash |
|
protected |
◆ nt
◆ op
◆ SilentChildStr
const std::string Rule::SilentChildStr = "%!" |
|
static |
The documentation for this class was generated from the following file: