Struct nff::NonTerminals

source ·
pub struct NonTerminals { /* private fields */ }
Expand description

Put all nonterminals in a single struct, one hashmap for rules and one each for nullable, first, and follow.

Implementations

Init takes the grammar in the form of a string and initializes all the hashmaps.

Determines which nonterminals are nullable

Determines the first set of each nonterminal

Determines the follow set of each nonterminal

You can use this function to verify that nff understood your rules correctly

Print results

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.