Implemented grammer loading

This commit is contained in:
Nathan Braswell
2013-05-20 19:34:15 -04:00
parent 46d59ac595
commit d2698cf203
11 changed files with 342 additions and 4 deletions

31
include/ParseRule.h Normal file
View File

@@ -0,0 +1,31 @@
#ifndef PARSERULE_H
#define PARSERULE_H
#ifndef NULL
#define NULL 0
#endif
#include "Symbol.h"
#include <vector>
#include <string>
#include <iostream>
class ParseRule {
public:
ParseRule();
~ParseRule();
void setLeftHandle(Symbol* leftHandle);
void appendToRight(Symbol* appendee);
std::string toString();
private:
int pointerIndex;
Symbol* leftHandle;
std::vector<Symbol*> rightSide;
};
#endif