8#include <ext/algorithm>
39 template<
class T,
class TerminalSymbolType =
typename grammar::TerminalSymbolTypeOfGrammar < T >,
class NonterminalSymbolType =
typename grammar::NonterminalSymbolTypeOfGrammar < T > >
43template <
class T,
class TerminalSymbolType,
class NonterminalSymbolType >
53 return Ni.at (
i - 1 ).count ( symb );
60 for (
const auto & rule : rawRules ) {
61 for (
const auto & rhs : rule.second ) {
62 if ( rhs.empty ( ) ||
std::all_of ( rhs.begin ( ), rhs.end ( ), testCallback ) ) {
63 Ni.at (
i ).insert ( rule.first );
68 }
while ( Ni.at (
i ) != Ni.at (
i - 1 ) );
Class extending the deque class from the standard library. Original reason is to allow printing of th...
Definition: deque.hpp:44
Implementation of the variant class allowing to store any type of those listed in the template parame...
Definition: variant.hpp:98
static ext::map< NonterminalSymbolType, ext::set< ext::vector< ext::variant< TerminalSymbolType, NonterminalSymbolType > > > > getRawRules(const LG< TerminalSymbolType, NonterminalSymbolType > &grammar)
Definition: RawRules.h:92
Definition: NullableNonterminals.h:24
static ext::set< NonterminalSymbolType > getNullableNonterminals(const T &grammar)
Definition: NullableNonterminals.h:44
int i
Definition: AllEpsilonClosure.h:118
all_of(T &&...) -> all_of< T... >
Definition: ToAutomaton.h:24