31 lines
513 B
C++
31 lines
513 B
C++
#ifndef jk_COMPILER_HPP
|
|
#define jk_COMPILER_HPP
|
|
|
|
#include "commons.hpp"
|
|
#include "SymTable.hpp"
|
|
#include "Logger.hpp"
|
|
#include "Node.hpp"
|
|
#include "Program.hpp"
|
|
#include "VM.hpp"
|
|
|
|
namespace jk
|
|
{
|
|
JK_ERROR(compile_error);
|
|
|
|
class Compiler
|
|
{
|
|
public:
|
|
explicit Compiler(Logger& logger);
|
|
virtual ~Compiler();
|
|
|
|
void compile(std::shared_ptr<Node> node,
|
|
std::shared_ptr<Program> program,
|
|
std::shared_ptr<SymTable> sym);
|
|
|
|
private:
|
|
Logger& m_logger;
|
|
};
|
|
}
|
|
|
|
#endif
|