write code file after successfull parsing

This commit is contained in:
Marc Zinnschlag 2010-06-28 14:07:55 +02:00
parent 0cfeab622d
commit a3ad61b4d0
9 changed files with 63 additions and 13 deletions

View file

@ -1,6 +1,10 @@
#ifndef COMPILER_SCRIPTPARSER_H_INCLUDED
#define COMPILER_SCRIPTPARSER_H_INCLUDED
#include <vector>
#include <components/interpreter/types.hpp>
#include "parser.hpp"
#include "lineparser.hpp"
@ -15,6 +19,7 @@ namespace Compiler
LineParser mLineParser;
Locals& mLocals;
bool mEnd;
std::vector<Interpreter::Type_Code> mCode;
public:
@ -22,6 +27,9 @@ namespace Compiler
ScriptParser (ErrorHandler& errorHandler, Context& context, Locals& locals,
bool end = false);
void getCode (std::vector<Interpreter::Type_Code>& code) const;
///< store generated code in \æ code.
virtual bool parseName (const std::string& name, const TokenLoc& loc,
Scanner& scanner);
///< Handle a name token.