From fbc8ecb7ef65f0cf216e2da94f9bf899bf4c1c92 Mon Sep 17 00:00:00 2001 From: Marc Autret Date: Sun, 16 Dec 2001 01:45:19 +0000 Subject: [PATCH] * src/output.c (actions_output): Fix. When we use %no-lines, there is one less line per action. --- ChangeLog | 5 +++++ src/output.c | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index ed88b5cb..411d2313 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2001-12-16 Marc Autret + + * src/output.c (actions_output): Fix. When we use %no-lines, + there is one less line per action. + 2001-12-16 Marc Autret * src/bison.simple: Remove a useless #line directive. diff --git a/src/output.c b/src/output.c index 4de58e9e..841ebe4f 100644 --- a/src/output.c +++ b/src/output.c @@ -556,8 +556,11 @@ actions_output (FILE *out, size_t *line) rule_table[rule].action, yacc_flag ? ";" : ""); - /* We always output 5 '\n' per action. */ - *line += 5; + /* We always output 4 '\n' per action. */ + *line += 4; + /* Plus one if !no_lines_flag. */ + if (!no_lines_flag) + ++*line; /* Get the number of lines written by the user. */ *line += get_lines_number (rule_table[rule].action); } -- 2.47.2