Changeset View
Changeset View
Standalone View
Standalone View
parser/parsesession.cpp
Show First 20 Lines • Show All 77 Lines • ▼ Show 20 Line(s) | 77 | { | |||
---|---|---|---|---|---|
78 | if(!lex()) | 78 | if(!lex()) | ||
79 | return false; | 79 | return false; | ||
80 | 80 | | |||
81 | return m_parser->parseStart(&m_ast); | 81 | return m_parser->parseStart(&m_ast); | ||
82 | } | 82 | } | ||
83 | 83 | | |||
84 | bool ParseSession::lex() | 84 | bool ParseSession::lex() | ||
85 | { | 85 | { | ||
86 | KDevPG::Token token; | 86 | // KDevPG::Token token; | ||
87 | int kind = go::Parser::Token_EOF; | 87 | int kind = go::Parser::Token_EOF; | ||
88 | while((kind = m_lexer->read().kind) != go::Parser::Token_EOF) | 88 | while((kind = m_lexer->read().kind) != go::Parser::Token_EOF) | ||
89 | { | 89 | { | ||
90 | //qDebug() << go::tokenText(kind); | 90 | //qDebug() << go::tokenText(kind); | ||
91 | if(kind == go::Parser::Token_TEST) | 91 | if(kind == go::Parser::Token_TEST) | ||
92 | { | 92 | { | ||
93 | qint64 line, column; | 93 | qint64 line, column; | ||
94 | m_lexer->locationTable()->positionAt(m_lexer->index(), &line, &column); | 94 | m_lexer->locationTable()->positionAt(m_lexer->index(), &line, &column); | ||
▲ Show 20 Lines • Show All 328 Lines • Show Last 20 Lines |