From: Dale Weiler Date: Sat, 31 Aug 2013 20:52:46 +0000 (-0400) Subject: Always print the char the lexer fails on for a token. X-Git-Tag: 0.3.5~103 X-Git-Url: https://git.xonotic.org/?a=commitdiff_plain;h=6800d15872a220ed80ce967c046489da5f95d053;p=xonotic%2Fgmqcc.git Always print the char the lexer fails on for a token. --- diff --git a/lexer.c b/lexer.c index 5177471..7642d26 100644 --- a/lexer.c +++ b/lexer.c @@ -1519,6 +1519,6 @@ int lex_do(lex_file *lex) return (lex->tok.ttype = ch); } - lexerror(lex, "unknown token: `%s`", lex->tok.value); + lexerror(lex, "unknown token: `%c`", ch); return (lex->tok.ttype = TOKEN_ERROR); }