Add main code to tie it all together
This commit is contained in:
parent
85908ae0c4
commit
f6c6a2be28
14
code/compiler_main.cpp
Normal file
14
code/compiler_main.cpp
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
#include "compiler_ast.hpp"
|
||||||
|
#include "compiler_parser.hpp"
|
||||||
|
|
||||||
|
void yy::parser::error(const std::string& msg) {
|
||||||
|
std::cout << "An error occured: " << std::endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
extern std::vector<definition_ptr> program;
|
||||||
|
|
||||||
|
int main() {
|
||||||
|
yy::parser parser;
|
||||||
|
parser.parse();
|
||||||
|
std::cout << program.size() << std::endl;
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user