X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=tests%2Foutput%2Fpivot-table-test.c;h=67edc0481fa8d8d99c0df7fb563f794eb9b4a2e4;hb=f4bf263b680ffe5dd0befe040b84c179919bbb7d;hp=9e91bfe3bf4e3c8e19f0f8b4b3e373005e51fd06;hpb=b0d11e19181e8b40639947e90724fac7926aee99;p=pspp diff --git a/tests/output/pivot-table-test.c b/tests/output/pivot-table-test.c index 9e91bfe3bf..67edc0481f 100644 --- a/tests/output/pivot-table-test.c +++ b/tests/output/pivot-table-test.c @@ -53,7 +53,7 @@ static const char *output_base = "render"; static const char *parse_options (int argc, char **argv); static void usage (void) NO_RETURN; static void read_table (struct lexer *); -static void output_msg (const struct msg *, void *); +static void output_msg (const struct msg *, struct lexer *); int main (int argc, char **argv) @@ -74,7 +74,7 @@ main (int argc, char **argv) exit (1); struct lexer *lexer = lex_create (); - msg_set_handler (output_msg, lexer); + lex_set_message_handler (lexer, output_msg); lex_include (lexer, reader); lex_get (lexer); @@ -661,7 +661,7 @@ read_value_option (struct lexer *lexer, const struct pivot_table *pt, return; } - lex_error (lexer, "Expecting valid value option"); + lex_error (lexer, "Syntax error expecting valid value option."); exit (1); } @@ -826,7 +826,7 @@ read_stroke (struct lexer *lexer) if (lex_match_id (lexer, table_stroke_to_string (stroke))) return stroke; - lex_error (lexer, "expecting stroke"); + lex_error (lexer, "Syntax error expecting stroke."); exit (1); } @@ -1230,9 +1230,8 @@ read_table (struct lexer *lexer) } static void -output_msg (const struct msg *m_, void *lexer_) +output_msg (const struct msg *m_, struct lexer *lexer) { - struct lexer *lexer = lexer_; struct msg m = { .category = m_->category, .severity = m_->severity,