19#include <QtCore/qglobal.h>
26 enum VariousConstants {
54 NON_TERMINAL_COUNT = 24,
56 GOTO_INDEX_OFFSET = 69,
57 GOTO_INFO_OFFSET = 57,
58 GOTO_CHECK_OFFSET = 57
61 static const char *
const spell[];
62 static const short lhs[];
63 static const short rhs[];
64 static const short goto_default[];
65 static const short action_default[];
66 static const short action_index[];
67 static const short action_info[];
68 static const short action_check[];
70 static inline int nt_action (
int state,
int nt)
72 const int yyn = action_index [GOTO_INDEX_OFFSET + state] + nt;
73 if (yyn < 0 || action_check [GOTO_CHECK_OFFSET + yyn] != nt)
74 return goto_default [nt];
76 return action_info [GOTO_INFO_OFFSET + yyn];
79 static inline int t_action (
int state,
int token)
81 const int yyn = action_index [state] + token;
83 if (yyn < 0 || action_check [yyn] != token)
84 return - action_default [state];
86 return action_info [yyn];
ReadsGraph::iterator ReadNode
void buildDefaultReduceActions()
void visitReadNode(ReadNode node)
void dump(QTextStream &out, IncludeNode incl)
void buildIncludesDigraph()
std::pair< StatePointer, bool > internState(const State &state)
IncludesGraph::iterator IncludeNode
void buildIncludesAndFollows()
void visitIncludeNode(IncludeNode node)
void dump(QTextStream &out, const Lookback &lp)
Node< Include > IncludesGraph
QMultiMap< ItemPointer, Lookback > lookbacks
void closure(StatePointer state)
QMap< ItemPointer, NameSet > lookaheads
void operator()(int *table, int row_count, int column_count)
CppGenerator(const Recognizer &p, Grammar &grammar, Automaton &aut, bool verbose)
void setWarningsAreErrors(bool e)
void setDebugInfo(bool d)
void setCopyright(bool t)
void operator()(Automaton *a)
DotGraph(QTextStream &out)
QMap< Name, QString > spells
Name intern(const char *id)
int expected_reduce_reduce
QMap< Name, TokenInfo > token_info
bool isNonTerminal(Name name) const
std::list< QString > names
bool isTerminal(Name name) const
void buildExtendedGrammar()
Name intern(const QString &id)
int expected_shift_reduce
bool operator<(const Include &other) const
Include(StatePointer s, Name n)
bool operator==(const Include &other) const
bool operator!=(const Include &other) const
bool isReduceItem() const
bool operator!=(const Item &other) const
NameList::iterator end_rhs() const
bool operator==(const Item &other) const
NameList::iterator begin_rhs() const
Lookback(StatePointer s, Name n)
bool operator<(const Lookback &other) const
bool operator!=(const Lookback &other) const
bool operator==(const Lookback &other) const
ParseTable(QTextStream &out)
void operator()(Automaton *a)
bool operator!=(const Read &other) const
bool operator<(const Read &other) const
Read(StatePointer s, Name n)
bool operator==(const Read &other) const
QT_FORWARD_DECLARE_CLASS(QTextStream)
std::list< Item > ItemList
ItemList::iterator ItemPointer
StateList::iterator StatePointer
std::list< QString >::iterator Name
QMap< Name, StatePointer > Bundle
std::list< State > StateList
std::list< Rule > debug_infot
QMultiMap< Name, RulePointer > RuleMap
QTextStream & operator<<(QTextStream &out, const Rule &r)
debug_infot::iterator RulePointer
std::list< Name > NameList
QTextStream & operator<<(QTextStream &out, const Item &item)
bool operator<(Name a, Name b)
int main(int argc, char *argv[])
[ctor_close]
QDataStream & operator<<(QDataStream &stream, const QImage &image)
[0]
bool operator<(const Node< _Tp > &other) const
static Repository & repository()
edge_iterator end() const
static iterator get(_Tp data)
bool root
Returns a pointer to the root of the Tree this node is in.
static iterator begin_nodes()
edge_iterator begin() const
std::list< iterator > outs
std::pair< edge_iterator, bool > insertEdge(iterator other) const
std::list< iterator >::iterator edge_iterator
bool operator==(const Node< _Tp > &other) const
bool operator!=(const Node< _Tp > &other) const
Repository::iterator iterator
std::set< Node< _Tp > > Repository
static iterator end_nodes()
bool operator!=(const State &other) const
std::pair< ItemPointer, bool > insertClosure(const Item &item)
std::pair< ItemPointer, bool > insert(const Item &item)
RulePointer defaultReduce
QMap< Name, NameSet > reads
bool operator==(const State &o) const
QMap< Name, NameSet > follows