#include <skParser.h>
Public Methods | |
skParser (const skString &code, const skString &location) | |
constructor. More... | |
~skParser () | |
Destructor - *clears* the temporary node list. | |
void | parse () |
this method instructs the parser to begin parsing the string passed into the constructor <. More... | |
void | setTopNode (skMethodDefNode *pNode) |
sets the current top-level parse node. More... | |
skMethodDefNode * | getTopNode () |
returns the current top-level parse node. | |
void | addParseNode (skParseNode *pNode) |
Saves a parse node to the list of temporary nodes. More... | |
void | appendError (const skString &msg) |
this adds a compile error message to the list of messages. | |
const skCompileErrorList & | getErrList () |
This returns the current compile error list. | |
int | lex (void *lvalp, void *lloc) |
This message returns the next token in the stream. More... | |
int | nextChar () |
returns the next character to be lexed (might be a put-back character). | |
void | putbackchar (int i) |
puts the given character back. | |
bool | eof () |
returns true if the eof the stream has been reached. | |
void | cleanupTempNodes () |
deletes the parse tree if an error occurs during parsing. | |
void | clearTempNodes () |
clears the list of nodes, but does *not* delete them (this is done if no error occurs. |
|
constructor.
|
|
Saves a parse node to the list of temporary nodes. If an error occurs these will be cleared up |
|
This message returns the next token in the stream.
|
|
this method instructs the parser to begin parsing the string passed into the constructor <. p>If the parse is valid, then getTopNode() will return the top of the parse tree |
|
sets the current top-level parse node.
|