blog-static/code/compiler/02/main.cpp

15 lines
302 B
C++
Raw Permalink Normal View History

2019-08-06 13:53:46 -07:00
#include "ast.hpp"
#include "parser.hpp"
2019-08-05 00:10:10 -07:00
void yy::parser::error(const std::string& msg) {
2019-08-06 14:24:26 -07:00
std::cout << "An error occured: " << msg << std::endl;
2019-08-05 00:10:10 -07:00
}
extern std::vector<definition_ptr> program;
int main() {
yy::parser parser;
parser.parse();
std::cout << program.size() << std::endl;
}