summaryrefslogtreecommitdiff
path: root/tnslc/compile/error.tnsl
blob: 255aec10cc3af821350ebda173fd3708b63335a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

~uint8 ERR_NUM = ":%d\0"
~uint8 TOK_PRNT = " \"%s\": \0"

/; report_error (utils.File file, Token token, ~uint8 message)
	~uint s = file.path.to_cstr('/')
	_printf(s)
	_delete(s)
	_print_num(ERR_NUM, token.line)
	_print_num(ERR_NUM, token.col)
	_print_num(TOK_PRNT, token.data)
	_printf(message)
	_printf(newline)
;/