aboutsummaryrefslogtreecommitdiff
path: root/src/parser.cpp
blob: d9fd2d0548f569db7bd5ba0e7d68cf567b46e88a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "parser.h"
#include "build.h"

Parser::Parser()
{
}

Parser::~Parser()
{
}

void Parser::error( YYLTYPE *locp, const char *msg )
{
	fflush( stdout );
	throw BuildException("%s: %d.%d-%d.%d: %s",
			file.c_str(),
			locp->first_line, locp->first_column,
			locp->last_line, locp->last_column,
			msg );
}

void Parser::error( const std::string &msg )
{
	fflush( stdout );
	throw BuildException("%s", msg.c_str() );
}