-Werror now changes the word 'warning' into 'error'

This commit is contained in:
Wolfgang (Blub) Bumiller 2012-12-04 12:54:53 +01:00
parent 36fe4e2729
commit 8e077f378e
4 changed files with 5 additions and 5 deletions

2
con.c
View file

@ -393,7 +393,7 @@ bool GMQCC_WARN compile_warning(lex_ctx ctx, int warntype, const char *fmt, ...)
++compile_warnings;
va_start(ap, fmt);
con_vprintmsg(lvl, ctx.file, ctx.line, "warning", fmt, ap);
con_vprintmsg(lvl, ctx.file, ctx.line, (opts_werror ? "error" : "warning"), fmt, ap);
va_end(ap);
return opts_werror;

2
ir.c
View file

@ -218,7 +218,7 @@ static bool irwarning(lex_ctx ctx, int warntype, const char *fmt, ...)
lvl = LVL_ERROR;
va_start(ap, fmt);
con_vprintmsg(lvl, ctx.file, ctx.line, "warning", fmt, ap);
con_vprintmsg(lvl, ctx.file, ctx.line, (opts_werror ? "error" : "warning"), fmt, ap);
va_end(ap);
return opts_werror;

View file

@ -84,7 +84,7 @@ bool lexwarn(lex_file *lex, int warntype, const char *fmt, ...)
lvl = LVL_ERROR;
va_start(ap, fmt);
con_vprintmsg(lvl, lex->name, lex->sline, "warning", fmt, ap);
con_vprintmsg(lvl, lex->name, lex->sline, (opts_werror ? "error" : "warning"), fmt, ap);
va_end(ap);
return opts_werror;

View file

@ -136,7 +136,7 @@ static bool GMQCC_WARN parsewarning(parser_t *parser, int warntype, const char *
}
va_start(ap, fmt);
con_vprintmsg(lvl, parser->lex->tok.ctx.file, parser->lex->tok.ctx.line, "warning", fmt, ap);
con_vprintmsg(lvl, parser->lex->tok.ctx.file, parser->lex->tok.ctx.line, (opts_werror ? "error" : "warning"), fmt, ap);
va_end(ap);
return opts_werror;
@ -154,7 +154,7 @@ static bool GMQCC_WARN genwarning(lex_ctx ctx, int warntype, const char *fmt, ..
lvl = LVL_ERROR;
va_start(ap, fmt);
con_vprintmsg(lvl, ctx.file, ctx.line, "warning", fmt, ap);
con_vprintmsg(lvl, ctx.file, ctx.line, (opts_werror ? "error" : "warning"), fmt, ap);
va_end(ap);
return opts_werror;