extracted main

This commit is contained in:
bronku 2025-11-18 16:37:35 +01:00
parent 8752f4e153
commit e0b407f8fb
3 changed files with 11 additions and 7 deletions

7
src/main.cpp Normal file
View file

@ -0,0 +1,7 @@
#include "../build/parser.hpp"
int main(int argc, char *argv[])
{
Elite::ParserCtx ctx;
return ctx.parser->parse();
}

View file

@ -74,12 +74,6 @@ program: FUNCTION;
%%
int main(int argc, char *argv[])
{
Elite::ParserCtx ctx;
return ctx.parser->parse();
}
void yy::Parser::error(const yy::location& l, const std::string& m)
{
std::cerr << l << ": " << m << std::endl;