BEGIN(CLASS_CODE);
if(++found_classes > 1) {
- print_error(FALSE,
- "Only one class per file allowed",
- line_no);
+ error_print(GOB_ERROR, line_no,
+ "Only one class per file allowed");
}
return CLASS;
if(rmaj < maj ||
(rmaj == maj && rmin < min) ||
(rmaj == maj && rmin == min && rpl < pl)) {
- char *s;
- s = g_strdup_printf(
- "GOB version %d.%d.%d required "
- "(this is %s)\n"
- "To upgrade your gob, see: "
- "http://www.5z.com/jirka/gob.html",
- maj,min,pl,VERSION);
- print_error(FALSE, s, line_no);
- g_free(s);
+ error_printf(GOB_ERROR, line_no,
+ "GOB version %d.%d.%d required "
+ "(this is %s)\n"
+ "To upgrade your gob, see: "
+ "http://www.5z.com/jirka/gob.html",
+ maj, min, pl, VERSION);
}
}
<CLASS_CODE,CLASS_CODE_I>class|this {
if(for_cpp) {
- char *s;
- s = g_strdup_printf("'%s' keyword should not "
- "be used when generating "
- "C++ code", yytext);
- print_error(TRUE, s, line_no);
- g_free(s);
+ error_printf(GOB_WARN, line_no,
+ "'%s' keyword should not "
+ "be used when generating "
+ "C++ code", yytext);
}
REJECT;
}