1 2001-12-29 Akim Demaille <akim@epita.fr>
5 * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here,
6 since it allocates it for each state, although only one is needed.
7 (allocate_storage): Do it here.
10 2001-12-29 Akim Demaille <akim@epita.fr>
12 * src/options.h, src/options.c (create_long_option_table): Rename
14 (long_option_table_new): this, with a clearer prototype.
15 (percent_table): Remove, unused,
16 * src/getargs.c (getargs): Adjust.
19 2001-12-29 Akim Demaille <akim@epita.fr>
21 * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c
22 * src/print.c, src/print_graph.c, src/state.h: Rename state_table
26 2001-12-29 Akim Demaille <akim@epita.fr>
28 * src/lalr.c (build_relations): Rename `states' as `states1'.
29 Sorry, I don't understand exactly what it is, no better name...
32 2001-12-29 Akim Demaille <akim@epita.fr>
34 * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c
35 * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c
36 * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table
40 2001-12-29 Akim Demaille <akim@epita.fr>
42 * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long
46 2001-12-29 Akim Demaille <akim@epita.fr>
48 * src/reader.c, src/reader.h (user_toknums): Remove.
49 Adjust all users to use symbols[i]->user_token_number.
52 2001-12-29 Akim Demaille <akim@epita.fr>
54 * src/gram.c, src/gram.h (sprec, sassoc): Remove.
55 Adjust all users to use symbols[i]->prec or ->assoc.
58 2001-12-29 Akim Demaille <akim@epita.fr>
60 * src/reader.c, src/reader.h (tags): Remove.
61 Adjust all users to use symbols[i]->tag.
64 2001-12-29 Akim Demaille <akim@epita.fr>
66 * src/gram.h, src/gram.c (symbols): New, similar to state_table
68 * src/reader.c (packsymbols): Fill this table.
70 * src/conflicts.c (resolve_sr_conflict): Adjust.
71 * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a
73 Use symbols[i]->tag instead of tags[i].
76 2001-12-29 Akim Demaille <akim@epita.fr>
78 * tests/calc.at (_AT_DATA_CALC_Y): Also use %union.
79 In addition, put a comment in there, to replace...
80 * tests/regression.at (%union and C comments): Remove.
83 2001-12-29 Akim Demaille <akim@epita.fr>
85 * tests/regression.at (Web2c Actions): Blindly move the actual
86 output as expected output. The contents *seem* right to me, but I
87 can't pretend reading perfectly parser tables... Nonetheless, all
88 the other tests pass correctly, the table look OK, even though the
89 presence of `$axiom' is to be noted: AFAICS it is useless (but
93 2001-12-29 Akim Demaille <akim@epita.fr>
95 * src/reader.c (readgram): Don't add the rule 0 if there were no
96 rules read. In other words, add it _after_ having performed
97 grammar sanity checks.
98 Fixes the `tests/regression.at (Invalid input: 1)' Failure.
101 2001-12-29 Akim Demaille <akim@epita.fr>
103 * tests/regression.at (Web2c Report): Catch up: the rule 0 is now
104 visible, and some states have now a different number.
107 2001-12-29 Akim Demaille <akim@epita.fr>
109 * src/reader.c (readgram): Bind the initial rule's lineno to that
111 * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts):
112 (Solved SR Conflicts): Adjust rule 0's line number.
115 2001-12-29 Akim Demaille <akim@epita.fr>
117 Fix the `GAWK Grammar' failure.
119 * src/LR0.c (final_state): Initialize to -1 so that we do compute
120 the reductions of the first state which was mistakenly confused
121 with the final state because precisely final_state was initialized
123 * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads,
124 now noticed by Bison.
125 * tests/regression.at (Rule Line Numbers): Adjust: state 0 does
126 have a reduction on $default.
129 2001-12-29 Akim Demaille <akim@epita.fr>
131 * src/gram.c (ritem_print): Be sure to subtract 1 when displaying
133 * src/closure.c (print_closure): Likewise.
134 * src/derives.c (print_derives): Likewise.
135 * tests/sets.at (Nullable): Adjust: the rule numbers are correct
138 2001-12-29 Akim Demaille <akim@epita.fr>
140 * src/lalr.c (lookaheads_print): New.
141 (lalr): Call it when --trace-flag.
142 * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads
146 2001-12-29 Akim Demaille <akim@epita.fr>
148 * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0',
149 when walking through ritem, even via rule->rhs.
150 * src/reduce.c (dump_grammar, useful_production, reduce_output)
151 (useful_production, useless_nonterminals): Likewise.
152 (reduce_grammar_tables): Likewise, plus update nritems.
153 * src/nullable.c (set_nullable): Likewise.
154 * src/lalr.c (build_relations): Likewise.
155 * tests/sets.at (Nullable): Adjust.
156 Fortunately, now, the $axiom is no longer nullable.
159 2001-12-29 Akim Demaille <akim@epita.fr>
161 * src/LR0.c (generate_states): Use nritems, not nitems, nor using
163 * src/gram.c (ritem_longest_rhs): Likewise.
164 * src/reduce.c (nonterminals_reduce): Likewise.
165 * src/print_graph.c (print_graph): Likewise.
166 * src/output.c (output_rule_data): Likewise.
167 * src/nullable.c (set_nullable): Likewise.
169 2001-12-29 Akim Demaille <akim@epita.fr>
171 * src/output.c: Comment changes.
173 2001-12-27 Paul Eggert <eggert@twinsun.com>
175 * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special
176 cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and
177 Sparc, as they were causing more porting problems than the
178 (minor) performance improvement was worth.
180 Also, catch up with 1.31's YYSTD.
182 2001-12-27 Akim Demaille <akim@epita.fr>
184 * src/output.c (output_gram): Rely on nritems, not the
185 0-sentinel. See below.
186 Use -1 as separator, not 0.
187 * src/bison.simple (yyparse): Subtract 1 to the rule numbers.
188 Rely on -1 as separator in yyrhs, instead of 0.
189 * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue
190 twice `Now at end of input', therefore there are two lines less to
193 2001-12-27 Akim Demaille <akim@epita.fr>
195 * tests/regression.at (Unresolved SR Conflicts):
196 (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes
199 2001-12-27 Akim Demaille <akim@epita.fr>
201 * src/LR0.c (new_state): Recognize the final state by the fact it
202 is reached by eoftoken.
203 (insert_start_shifting_state, insert_eof_shifting_state)
204 (insert_accepting_state, augment_automaton): Remove, since now
205 these states are automatically computed from the initial state.
206 (generate_states): Adjust.
207 * src/print.c: When reporting a rule number to the user, substract
208 1, so that the axiom rule is rule 0, and the first user rule is 1.
209 * src/reduce.c: Likewise.
210 * src/print_graph.c (print_core): For the time being, just as for
211 the report, depend upon --trace-flags to dump the full set of
213 * src/reader.c (readgram): Once the grammar read, insert the rule
214 0: `$axiom: START-SYMBOL $'.
215 * tests/set.at: Adjust: rule 0 is now displayed, and since the
216 number of the states has changed (the final state is no longer
217 necessarily the last), catch up.
219 2001-12-27 Akim Demaille <akim@epita.fr>
221 Try to make the use of the eoftoken valid. Given that its value
222 is 0 which was also used as a sentinel in ritem, (i) make sure >= 0
223 is used instead of > 0 where appropriate, (ii), depend upon nritems
224 instead of the 0-sentinel.
226 * src/gram.h, src/gram.c (nritems): New.
227 Expected to be duplication of nitems, but for the time being...
228 * src/reader.c (packgram): Assert nritems and nitems are equal.
229 * src/LR0.c (allocate_itemsets, new_itemsets): Adjust.
230 * src/closure.c (print_closure, print_fderives): Likewise.
231 * src/gram.c (ritem_print): Likewise.
232 * src/print.c (print_core, print_grammar): Likewise.
233 * src/print_graph.c: Likewise.
235 2001-12-27 Akim Demaille <akim@epita.fr>
237 * src/main.c (main): If there are complains after grammar
238 reductions, then output the report anyway if requested, then die.
239 * src/symtab.c (bucket_new): Initialize `value' to -1, not 0.
240 * src/reader.c (eoftoken): New.
241 (parse_token_decl): If the token being defined has value `0', it
243 (packsymbols): No longer hack `tags' to insert `$' by hand.
244 Be sure to preserve the value of the eoftoken.
245 (reader): Make sure eoftoken is defined.
246 Initialize nsyms to 0: now eoftoken is created just like the others.
247 * src/print.c (print_grammar): Don't special case the eof token.
248 * src/regression.at: Adjust: `$' has value 0, not -1, which was a
249 lie anyway, albeit pleasant.
250 * tests/calc.at: Exercise error messages with eoftoken.
251 Change the grammar so that empty input is invalid.
253 When yyungeting, be sure to use a valid yylloc: use last_yylloc.
255 2001-12-27 Akim Demaille <akim@epita.fr>
257 * configure.in: Check the protos of strchr ans strspn.
258 Replace strchr if needed.
259 * src/system.h: Provide the protos of strchr, strspn and memchr if
262 * src/reader.c (symbols_save): Use strchr.
264 2001-12-27 Akim Demaille <akim@epita.fr>
266 * src/print.c, src/print_graph.c (escape): New.
267 Use it to quote the TAGS outputs.
268 * src/print_graph.c (print_state): Now errors are in red, and
270 Prefer high to wide: output the state number on a line of its own.
272 2001-12-27 Akim Demaille <akim@epita.fr>
274 * src/state.h, src/state.c (reductions_new): New.
275 * src/LR0.c (set_state_table): Let all the states have a
276 `reductions', even if reduced to 0.
277 (save_reductions): Adjust.
278 * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust.
279 * src/print.c (print_reductions, print_actions): Adjust.
280 * src/output.c (action_row): Adjust.
282 2001-12-27 Akim Demaille <akim@epita.fr>
284 * src/state.h, src/state.c (errs_new, errs_dup): New.
285 * src/LR0.c (set_state_table): Let all the states have an errs,
286 even if reduced to 0.
287 * src/print.c (print_errs, print_reductions): Adjust.
288 * src/output.c (output_actions, action_row): Adjust.
289 * src/conflicts.c (resolve_sr_conflict): Adjust.
291 2001-12-27 Akim Demaille <akim@epita.fr>
293 * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL.
295 2001-12-27 Akim Demaille <akim@epita.fr>
297 * src/conflicts.c, src/conflicts.h (print_reductions): Move to...
299 (lookaheadset, shiftset): New, used as additional storage by
301 (print_results): Adjust.
302 (print_shifts, print_gotos, print_errs): New, extracted from...
303 (print_actions): here.
304 * src/print_graph.c (print_actions): Remove dead code.
306 2001-12-27 Akim Demaille <akim@epita.fr>
308 * src/reader.c (copy_dollar, copy_at): Better checking of `n' in
311 2001-12-27 Akim Demaille <akim@epita.fr>
313 * src/lalr.c (add_lookback_edge): Use state_t instead of ints.
314 (build_relations): Adjust.
316 2001-12-27 Akim Demaille <akim@epita.fr>
318 * src/lalr.c (set_goto_map): Remove a wrong but benign loop
321 2001-12-27 Akim Demaille <akim@epita.fr>
323 * src/reader.c (packgram): Catch nitems overflows.
325 2001-12-27 Akim Demaille <akim@epita.fr>
327 * src/files.c, src/files.h (guard_obstack): Remove.
328 * src/output.c (output): Adjust.
329 * src/reader.c (parse_braces): New, factoring...
330 (copy_action, copy_guard): these two which are renamed as...
331 (parse_action, parse_guard): these.
332 As a voluntary consequence, using braces around guards is now
335 2001-12-27 Akim Demaille <akim@epita.fr>
337 * src/gram.h (rule_t): `guard' and `guard_line' are new members.
338 * src/reader.c (symbol_list): `guard' and `guard_line' are new
340 (symbol_list_new): Adjust.
341 (copy_action): action_line is the first line, not the last.
342 (copy_guard): Just as for actions, store the `action' only, not
343 the switch/case/break flesh.
344 Don't parse the user action that might follow the guard, let...
345 (readgram): do it, i.e., now, there can be an action after a
347 In other words the guard is just explicitly optional.
349 * src/output.c (guards_output): New.
350 (output_parser): Call it when needed.
351 (output): Also free the guard and attrs obstacks.
352 * src/files.c, src/files.h (obstack_save): Remove.
353 (output_files): Remove.
354 As a result, if one needs the former `.act' file, using an
355 appropriate skeleton which requires actions and guards is now
357 * src/main.c (main): Adjust.
358 * tests/semantic.at: New.
359 * tests/regression.at: Use `input.y' as input file name.
360 Avoid 8+3 problems by requiring input.c when the test needs the
363 2001-12-27 Akim Demaille <akim@epita.fr>
365 * src/reader.c (symbol_list_new): Be sure to initialize all the
368 2001-12-27 Akim Demaille <akim@epita.fr>
370 All the hacks using a final pseudo state are now useless.
372 * src/LR0.c (set_state_table): state_table holds exactly nstates.
373 * src/lalr.c (nLA): New.
374 (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it
375 instead of lookaheadsp from the pseudo state (nstate + 1).
377 2001-12-27 Akim Demaille <akim@epita.fr>
379 * src/output.c (action_row, token_actions): Use a state_t instead
380 of a integer, and nlookaheads instead of the following state's
383 2001-12-27 Akim Demaille <akim@epita.fr>
385 * src/conflicts.c (log_resolution, flush_shift)
386 (resolve_sr_conflict, set_conflicts, solve_conflicts)
387 (count_sr_conflicts, count_rr_conflicts, conflicts_output)
388 (conflicts_print, print_reductions): Use a state_t instead of an
389 integer when referring to a state.
390 As much as possible, depend upon nlookaheads, instead of the
391 `lookaheadsp' member of the following state (since lookaheads of
392 successive states are successive, the difference between state n + 1
393 and n served as the number of lookaheads for state n).
394 * src/lalr.c (add_lookback_edge): Likewise.
395 * src/print.c (print_core, print_actions, print_state)
396 (print_results): Likewise.
397 * src/print_graph.c (print_core, print_actions, print_state)
398 (print_graph): Likewise.
399 * src/conflicts.h: Adjust.
401 2001-12-27 Akim Demaille <akim@epita.fr>
403 * src/bison.hairy: Formatting/comment changes.
405 Remove `register' indications.
406 Add plenty of `static'.
408 2001-12-27 Akim Demaille <akim@epita.fr>
410 * src/output.c (prepare): Drop the muscle `ntbase' which
412 * src/bison.simple: Formatting/comment changes.
413 Use YYNTOKENS only, which is documented, but not YYNTBASE, which
414 is an undocumented synonym.
416 2001-12-22 Akim Demaille <akim@epita.fr>
418 * src/output.c (output_table_data): Change the prototype to use
419 `int' for array ranges: some invocations do pass an int, not a
421 Reported by Wayne Green.
423 2001-12-22 Akim Demaille <akim@epita.fr>
425 Some actions of web2c.y are improperly triggered.
426 Reported by Mike Castle.
428 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
429 * tests/regression.at (Web2c): Rename as...
430 (Web2c Report): this.
431 (Web2c Actions): New.
433 2001-12-22 Akim Demaille <akim@epita.fr>
435 Reductions in web2c.y are improperly reported.
436 Reported by Mike Castle.
438 * src/conflicts.c (print_reductions): Fix.
439 * tests/regression.at (Web2c): New.
441 2001-12-18 Akim Demaille <akim@epita.fr>
443 Some host fail on `assert (!"foo")', which expands to
444 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
445 Reported by Nelson Beebee.
447 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
448 `#define it_succeeded 0' and `assert (it_succeeded)'.
450 2001-12-17 Marc Autret <autret_m@epita.fr>
452 * src/bison.simple: Don't hard code the skeleton line and filename.
453 * src/output.c (output_parser): Rename 'line' as 'output_line'.
454 New line counter 'skeleton_line' (skeleton-line muscle).
456 2001-12-17 Paul Eggert <eggert@twinsun.com>
458 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that
459 YYDEBUG must be defined to a nonzero value.
461 * src/bison.simple (yytname): Do not assume that the user defines
462 YYDEBUG to a properly parenthesized expression.
464 2001-12-17 Akim Demaille <akim@epita.fr>
466 * src/state.h (state_t): Rename lookaheads as lookaheadsp.
467 nlookaheads is a new member.
469 * src/lalr.h (nlookaheads): Remove this orphan declaration.
470 * src/lalr.c (initialize_lookaheads): Set nlookaheads for each
473 2001-12-17 Akim Demaille <akim@epita.fr>
475 * src/files.h, src/files.c (open_files, close_files): Remove.
476 * src/main.c (main): Don't open/close files, nor invoke lex_free,
478 * src/reader.c (reader): Do it.
480 2001-12-17 Akim Demaille <akim@epita.fr>
482 * src/conflicts.c (print_reductions): Formatting changes.
484 2001-12-17 Akim Demaille <akim@epita.fr>
486 * src/conflicts.c (flush_shift): Also adjust lookaheadset.
488 (resolve_sr_conflict): Adjust.
490 2001-12-17 Akim Demaille <akim@epita.fr>
492 * src/output.c (output_obstack): Be static and rename as...
493 (format_obstack): this, to avoid any confusion with files.c's
495 * src/reader.h (muscle_obstack): Move to...
496 * src/output.h: here, since it's defined in output.c.
498 2001-12-17 Akim Demaille <akim@epita.fr>
500 * src/output.c (action_row, save_column, default_goto)
501 (sort_actions, matching_state, pack_vector): Better variable
504 2001-12-17 Akim Demaille <akim@epita.fr>
506 * src/output.c: Various formatting changes.
508 2001-12-17 Akim Demaille <akim@epita.fr>
510 * src/files.c (output_files): Free the output_obstack.
511 * src/main.c (main): Call print and print_graph conditionally.
512 * src/print.c (print): Work unconditionally.
513 * src/print_graph.c (print_graph): Work unconditionally.
514 * src/conflicts.c (log_resolution): Output only if verbose_flag.
516 2001-12-16 Marc Autret <autret_m@epita.fr>
518 * src/output.c (actions_output): Fix. When we use %no-lines,
519 there is one less line per action.
521 2001-12-16 Marc Autret <autret_m@epita.fr>
523 * src/bison.simple: Remove a useless #line directive.
524 s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'.
525 * src/output.c (get_lines_number): New.
526 (output_parser): Adjust, now takes care about the lines of a
529 (actions_output): Computes the number of lines taken by actions.
530 (output_master_parser): Insert new skeleton which is the name of
531 the output parser file name.
533 2001-12-15 Marc Autret <autret_m@epita.fr>
535 * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility.
537 2001-12-15 Marc Autret <autret_m@epita.fr>
539 * src/output.c (output_gram): Keep track of the hairy one.
541 2001-12-15 Akim Demaille <akim@epita.fr>
543 Make `make distcheck' work.
545 * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses
546 system.h which uses libgettext.h.
548 2001-12-15 Akim Demaille <akim@epita.fr>
550 * src/nullable.c (set_nullable): Useless rules must be skipped,
551 otherwise, since we range over their symbols, we might look at a
552 nonterminal which no longer ``exists'', i.e., it is not counted in
553 `nvars', hence we overflow our arrays.
555 2001-12-15 Akim Demaille <akim@epita.fr>
557 The header can also be produced directly, without any obstack!
560 * src/files.c, src/files.h (defines_obstack): Remove.
561 (compute_header_macro): Global.
562 (defines_obstack_save): Remove.
563 * src/reader.c (parse_union_decl): No longer output to
564 defines_obstack: its content can be found in the `stype' muscle
566 (output_token_translations): Merge into...
567 (symbols_output): this.
569 (symbols_save): this.
571 * src/output.c (header_output): New.
574 2001-12-15 Akim Demaille <akim@epita.fr>
576 * src/reader.c (parse_union_decl): Instead of handling two obstack
577 simultaneously, use one to define the `stype' muscle, and use the
578 value of the latter to fill defines_obstack.
579 (copy_comment): Remove.
580 (copy_comment2): Work for a single obstack.
582 (copy_comment): this.
584 2001-12-15 Akim Demaille <akim@epita.fr>
586 * src/lex.c, src/lex.h (xgetc): No longer static.
587 * src/reader.c (parse_union_decl): Revamp.
589 2001-12-15 Akim Demaille <akim@epita.fr>
591 Still making progress in separating Bison into (i) input, (ii)
592 process, (iii) output: now we can directly output the parser file
593 without using table_obstack at all.
595 * src/files.c, src/files.h (table_obstack): Bye bye.
596 (parser_file_name): New.
597 * src/files.c (compute_output_file_names): Compute it.
598 * src/output.c (actions_output, output_parser)
599 (output_master_parser): To a file instead of an obstack.
601 2001-12-15 Akim Demaille <akim@epita.fr>
603 Attach actions to rules, instead of pre-outputting them to
606 * src/gram.h (rule_t): action and action_line are new members.
607 * src/reader.c (symbol_list): Likewise.
608 (copy_action): Save the actions within the rule.
609 (packgram): Save them in rule_table.
610 * src/output.c (actions_output): New.
611 (output_parser): Use it on `%%actions'.
612 (output_rule_data): Don't free rule_table.
614 (prepare): Don't save the `action' muscle.
615 * src/bison.simple: s/%%action/%%actions/.
617 2001-12-15 Akim Demaille <akim@epita.fr>
619 * src/reader.c (copy_action): When --yacc, don't append a `;'
620 to the user action: let it fail if lacking.
621 Suggested by Arnold Robbins and Tom Tromey.
623 2001-12-14 Akim Demaille <akim@epita.fr>
625 * src/lex.c (literalchar): Simply return the char you decoded, non
626 longer mess around with obstacks and int pointers.
629 2001-12-14 Akim Demaille <akim@epita.fr>
631 * src/lex.c (literalchar): Don't escape the special characters,
632 just decode them, and keep them as char (before, eol was output as
633 the 2 char string `\n' etc.).
634 * src/output.c (output_rule_data): Use quotearg to output the
637 2001-12-13 Paul Eggert <eggert@twinsun.com>
639 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
640 Do not infringe on the global user namespace when using C++.
641 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
642 All uses of `fprintf' and `stderr' changed.
644 * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR.
646 2001-12-13 Akim Demaille <akim@epita.fr>
648 The computation of nullable is broken: it doesn't handle empty
651 * tests/torture.at (GNU AWK Grammar): New.
652 * tests/sets.at (Nullable): New.
653 * src/nullable.c (set_nullable): Instead of blindly looping over
654 `ritems', loop over the rules, and then over their rhs's.
656 Work around Autotest bugs.
658 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
659 frame, because Autotest understand lines starting with a `+' as
660 traces from the shell. Then, they are not processed properly.
661 Admittedly an Autotest bug, but we don't have time to wait for
662 Autotest to catch up.
663 * tests/regression.at (Broken Closure): Adjust to the new table
666 * tests/sets.at: here.
668 2001-12-13 Akim Demaille <akim@epita.fr>
670 * src/closure.c (closure): Use nrules instead of playing tricks
673 2001-12-13 Akim Demaille <akim@epita.fr>
675 * src/print.c (print_actions): Output the handling of `$' as the
676 traces do: shifting the token EOF. Before EOF was treated as a
678 * tests/regression.at: Adjust some tests.
679 * src/print_graph.c (print_core): Complete the set of items via
680 closure. The next-to-final and final states are still unsatisfying,
681 but that's to be addressed elsewhere.
682 No longer output the rule numbers, but do output the state number.
683 A single loop for the shifts + gotos is enough, but picked a
684 distinct color for each.
685 (print_graph): Initialize and finalize closure.
687 2001-12-13 Akim Demaille <akim@epita.fr>
689 * src/reader.c (readgram): Remove dead code, an strip useless
691 (get_type): Remove, unused.
693 2001-12-12 Akim Demaille <akim@epita.fr>
695 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
696 on that of lib/error.c.
698 2001-12-12 Akim Demaille <akim@epita.fr>
700 Some hosts don't like `/' in includes.
702 * src/system.h: Include libgettext.h without qualifying the path.
703 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
706 2001-12-11 Marc Autret <autret_m@epita.fr>
708 * src/output.c (output_parser): Remove useless muscle.
710 2001-12-11 Marc Autret <autret_m@epita.fr>
712 * src/bison.simple: Remove #line just before %%epilogue. It
713 is now handled in ...
714 * src/reader.c (read_additionnal_code): Add the output of a
715 #line for the epilogue.
717 2001-12-10 Marc Autret <autret_m@epita.fr>
719 * src/reader.c (copy_definition): Re-use CPP-outed code which
720 replace precedent remove.
721 * src/bison.simple: Remove #line before %%prologue because
722 %%input-line is wrong at this time.
724 2001-12-10 Marc Autret <autret_m@epita.fr>
726 * src/reader.c (symbols_output): Clean up.
727 * src/output.c (output_gram, output): Clean up.
729 2001-12-10 Akim Demaille <akim@epita.fr>
731 * src/lalr.c (initialize_lookaheads): New. Extracted from...
732 * src/LR0.c (set_state_table): here.
733 * src/lalr.c (lalr): Call it.
735 2001-12-10 Akim Demaille <akim@epita.fr>
737 * src/state.h (shifts): Remove the `number' member: shifts are
738 attached to state, hence no longer need to be labelled with a
741 2001-12-10 Akim Demaille <akim@epita.fr>
743 Now that states have a complete set of members, the linked list of
744 shifts is useless: just fill directly the state's shifts member.
746 * src/state.h (shifts): Remove the `next' member.
747 * src/LR0.c (first_state, last_state): Remove.
749 (augment_automaton): Don't look for the shifts that must be added
750 a shift on EOF: it is those of the state we looked for! But now,
751 since shifts are attached, it is no longer needed to looking
752 merely by its id: its number.
754 2001-12-10 Akim Demaille <akim@epita.fr>
756 * src/LR0.c (augment_automaton): Better variable locality.
757 Remove an impossible branch: if there is a state corresponding to
758 the start symbol being shifted, then there is shift for the start
759 symbol from the initial state.
761 2001-12-10 Akim Demaille <akim@epita.fr>
763 * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state'
764 only when appropriate: when insert_start_shifting_state' is not
766 * tests/regression.at (Rule Line Numbers): Adjust.
768 2001-12-10 Akim Demaille <akim@epita.fr>
770 * src/LR0.c (augment_automaton): Now that all states have shifts,
771 merge the two cases addition shifts to the initial state.
773 2001-12-10 Akim Demaille <akim@epita.fr>
775 * src/lalr.c (set_state_table): Move to...
777 * src/lalr.c (lalr): Don't call it...
778 * src/LR0.c (generate_states): do it.
779 * src/LR0.h (first_state): Remove, only the table is used.
781 2001-12-10 Akim Demaille <akim@epita.fr>
783 * src/LR0.h (first_shift, first_reduction): Remove.
784 * src/lalr.c: Don't use first_shift: find shifts through the
787 2001-12-10 Akim Demaille <akim@epita.fr>
789 * src/LR0.c: Attach shifts to states as soon as they are
791 * src/lalr.c (set_state_table): Instead of assigning shifts to
792 state, just assert that the mapping was properly done.
794 2001-12-10 Akim Demaille <akim@epita.fr>
796 * src/LR0.c (insert_start_shift): Rename as...
797 (insert_start_shifting_state): this.
798 (insert_eof_shifting_state, insert_accepting_state): New.
799 (augment_automaton): Adjust.
800 Better locality of the variables.
801 When looking if the start_symbol is shifted from the initial
802 state, using `while (... symbol != start_symbol ...)' sounds
803 better than `while (... symbol < start_symbol ...)': If fail
804 to see how the order between symbols could be relevant!
806 2001-12-10 Akim Demaille <akim@epita.fr>
808 * src/getargs.h: Don't declare `spec_name_prefix' and
809 `spec_file_prefix', declared by src/files.h.
810 * src/files.c, src/files.h: Default for spec_name_prefix is "yy".
811 * src/muscle_tab.c (muscle_init): Default prefix to NULL.
812 * src/output.c (prepare): Adjust.
813 * src/reader.c (symbols_output): Likewise.
814 * src/vmsgetargs.c: Vaguely adjust, but who cares?
816 2001-12-10 Akim Demaille <akim@epita.fr>
818 * src/muscle_tab.c (muscle_init): NULL is a better default than
821 2001-12-10 Akim Demaille <akim@epita.fr>
823 * src/reader.c (reader): Calling symbols_output once is enough.
825 2001-12-10 Akim Demaille <akim@epita.fr>
827 Now that states have a complete set of members, the linked list of
828 reductions is useless: just fill directly the state's reductions
831 * src/state.h (struct reductions): Remove member `number' and
833 * src/LR0.c (first_reduction, last_reduction): Remove.
834 (save_reductions): Don't link the new reductions, store them in
836 * src/lalr.c (set_state_table): No need to attach reductions to
837 states, it's already done.
838 * src/output.c (output_actions): No longer free the shifts, then
839 the reductions, then the states: free all the states and their
842 2001-12-10 Akim Demaille <akim@epita.fr>
844 * src/options.c (OPTN, DRTV, BOTH): New.
845 (option_table): Use them.
847 * src/muscle_tab.c: Don't include xalloc.h and string.h: that's
849 * src/options.c: Don't include stdio.h and xalloc.h for the same
852 2001-12-10 Akim Demaille <akim@epita.fr>
854 * src/output.c (output, prepare): Make sure the values of the
855 muscles `action' and `prologue' are 0-terminated.
857 2001-12-10 Akim Demaille <akim@epita.fr>
859 Clean up GCC warnings.
861 * src/reader.c (copy_action): `buf' is not used.
862 (parse_skel_decl): Be static.
863 * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'.
864 * src/options.h (create_long_option_table): Have a real prototype.
865 * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete)
866 (hash_delete_at): Return const void *.
867 Adjust casts to preserve the const.
869 2001-12-10 Akim Demaille <akim@epita.fr>
871 * configure.in: Require 2.52g.
872 M4 is not needed, but AUTOM4TE is.
874 * tests/Makefile.am: Adjust.
876 2001-12-10 Akim Demaille <akim@epita.fr>
878 One structure for states is enough, even though theoretically
879 there are LR(0) states and LALR(1) states.
881 * src/lalr.h (state_t): Remove.
882 (state_table): Be state_t **, not state_t *.
883 * src/state.h (core, CORE_ALLOC): Rename as...
884 (state_t, STATE_ALLOC): this.
885 Add the LALR(1) members: shifts, reductions, errs.
886 * src/LR0.c (state_table): Rename as...
887 (state_hash): this, to avoid name clashes with the global
889 * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c
890 * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust.
892 2001-12-10 Akim Demaille <akim@epita.fr>
894 Bison dumps core on bash.y.
895 Reported by Pascal Bart.
897 * src/warshall.c (bitmatrix_print): New.
899 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
900 j must be the outer loop.
901 * tests/regression.at (Broken Closure): New.
903 2001-12-05 Akim Demaille <akim@epita.fr>
905 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
907 Reported by Peter Hámorský.
909 2001-12-05 Akim Demaille <akim@epita.fr>
911 * src/conflicts.c (err_table): Remove.
912 (resolve_sr_conflict): Adjust.
913 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
915 (state_t.reductions, state_t.shifts): this.
917 2001-12-05 Akim Demaille <akim@epita.fr>
919 * src/reduce.c (reduce_grammar_tables): No longer disable the
920 removal of useless rules via CPP but via `if (0)', so that the
921 compiler still check the code is valid.
922 For instance, it should have noticed `rline' no longer exists: use
923 the `line' member of rule_t.
924 * src/gram.c (dummy, rline): Remove, unused.
926 2001-12-05 Akim Demaille <akim@epita.fr>
928 * src/output.c (pack_vector): Use assert, not berror.
929 * src/main.c (berror): Remove, unused.
931 2001-12-05 Akim Demaille <akim@epita.fr>
933 New experimental feature: if --verbose --trace output all the
934 items of a state, not only its kernel.
936 * src/print.c (print_core): If `trace_flag', then invoke closure
937 before outputting the items of the state (print_core is no longer
938 a correct name them).
939 (print_results): Invoke new_closure/free_closure if needed.
941 2001-12-05 Akim Demaille <akim@epita.fr>
943 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
944 * src/closure.c, src/closure.h (itemsetsize): Rename as...
945 (nitemset): for consistency with the rest of the project.
947 2001-12-05 Akim Demaille <akim@epita.fr>
949 * src/closure.c (print_closure): Improve.
950 (closure): Use it for printing input and output.
952 2001-12-05 Akim Demaille <akim@epita.fr>
954 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
955 indexed by nonterminals.
957 2001-12-05 Akim Demaille <akim@epita.fr>
959 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
961 * src/warshall.h: Remove accidental duplication of the content.
963 2001-12-05 Akim Demaille <akim@epita.fr>
965 * src/closure.c (set_fderives): De-obfuscate.
967 2001-12-05 Akim Demaille <akim@epita.fr>
969 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
971 2001-12-05 Akim Demaille <akim@epita.fr>
973 * src/closure.c (set_firsts): De-obfuscate.
975 2001-12-05 Akim Demaille <akim@epita.fr>
977 * src/output.c (action_row): De-obfuscate
978 using the good o' techniques: arrays not pointers, variable
979 locality, BITISSET, RESETBIT etc.
981 2001-12-05 Akim Demaille <akim@epita.fr>
983 Pessimize the code to simplify it: from now on, all the states
984 have a valid SHIFTS, which NSHIFTS is possibly 0.
986 * src/LR0.c (shifts_new): Be global and move to..
987 * src/state.c, src/state.h: here.
988 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
989 * src/print_graph: Adjust.
991 2001-12-05 Akim Demaille <akim@epita.fr>
993 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
994 * src/conflicts.c: Use it.
995 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
996 incorrectly ``simplified''.
998 2001-12-05 Akim Demaille <akim@epita.fr>
1000 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
1001 using the good o' techniques: arrays not pointers, variable
1002 locality, BITISSET, RESETBIT etc.
1004 2001-12-05 Akim Demaille <akim@epita.fr>
1006 * src/state.h (SHIFT_SYMBOL): New.
1007 * src/conflicts.c: Use it to deobfuscate.
1009 2001-12-05 Akim Demaille <akim@epita.fr>
1011 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
1012 (print_reductions): De-obfuscate using the good o' techniques:
1013 arrays not pointers, variable locality, BITISSET.
1015 2001-12-05 Akim Demaille <akim@epita.fr>
1017 * src/conflicts.c (print_reductions): Arrays, not pointers.
1020 2001-12-05 Akim Demaille <akim@epita.fr>
1022 * src/conflicts.c (print_reductions): Pessimize, but clarify.
1024 2001-12-05 Akim Demaille <akim@epita.fr>
1026 * src/conflicts.c (print_reductions): Improve variable locality.
1028 2001-12-05 Akim Demaille <akim@epita.fr>
1030 * src/conflicts.c (print_reductions): Pessimize, but clarify.
1032 2001-12-05 Akim Demaille <akim@epita.fr>
1034 * src/conflicts.c (print_reductions): Improve variable locality.
1036 2001-12-05 Akim Demaille <akim@epita.fr>
1038 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
1039 * src/lalr.c: Use them.
1041 2001-12-05 Akim Demaille <akim@epita.fr>
1043 * src/LR0.c (augment_automaton): Formatting changes.
1044 Better variable locality.
1046 2001-12-05 Akim Demaille <akim@epita.fr>
1048 * src/lalr.c (matrix_print): New.
1049 (transpose): Use it.
1050 Use arrays instead of pointers.
1052 2001-12-05 Akim Demaille <akim@epita.fr>
1054 * src/lalr.c (maxrhs): Move to...
1055 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
1056 * src/lalr.c (build_relations): Adjust.
1058 2001-12-05 Akim Demaille <akim@epita.fr>
1060 * src/lalr.c (transpose): Free the memory allocated to the
1061 argument, as it is replaced by the results by the unique caller.
1062 (build_relations): Merely invoke transpose: it handles the memory
1064 Improve variable locality.
1065 Avoid variables used as mere abbreviations.
1066 (compute_lookaheads): Use arrays instead of pointers.
1068 2001-12-05 Akim Demaille <akim@epita.fr>
1070 * src/lalr.c (initialize_F): Improve variable locality.
1071 Avoid variables used as mere abbreviations.
1073 2001-12-05 Akim Demaille <akim@epita.fr>
1075 * src/derives.c (print_derives): Display the ruleno.
1076 * src/lalr.c (initialize_F, transpose): Better variable locality
1077 to improve readability.
1078 Avoid variables used as mere abbreviations.
1080 2001-12-05 Akim Demaille <akim@epita.fr>
1082 * src/lalr.c (traverse): Use arrays instead of pointers.
1084 2001-12-05 Akim Demaille <akim@epita.fr>
1086 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
1087 the handling of squeue.
1088 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
1090 2001-12-05 Akim Demaille <akim@epita.fr>
1092 Because useless nonterminals are now kept alive (instead of being
1093 `destroyed'), we now sometimes examine them, and store information
1094 related to them. Hence we need to know their number, and adjust
1097 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
1099 * src/LR0.c (allocate_itemsets): The memory allocated to
1100 `symbol_count' was used for two different purpose: once to count
1101 the number of occurrences of each symbol, and later reassigned to
1102 `shift_symbol', containing the symbol that can be shifted from a
1104 Deobfuscate, i.e., allocate, use and free `symbol_count' here
1106 (new_itemsets): Allocate `shift_symbol' here.
1107 (allocate_itemsets): symbol_count includes useless nonterminals.
1109 (free_storage): Use `free', not `XFREE', for pointers that cannot
1112 2001-12-05 Akim Demaille <akim@epita.fr>
1114 * src/nullable.c (set_nullable): Deobfuscate the handling of
1116 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
1118 2001-12-05 Akim Demaille <akim@epita.fr>
1120 * src/gram.c, src/gram.h (ritem_print): New.
1121 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
1122 (This useless function was defined only to work around VMS linkers
1123 that can't handle compilation units with variables only).
1124 * src/reduce.c (dump_grammar): Use it to trace the construction of
1127 2001-12-04 Paul Eggert <eggert@twinsun.com>
1129 * src/bison.simple (union yyalloc): Change member names
1130 to be the same as the stack names.
1131 (yyparse): yyptr is now union yyalloc *, not char *.
1132 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
1133 and may generate better code on some machines.
1134 (yystpcpy): Use prototype if __STDC__ is defined, not just
1135 if __cplusplus is defined.
1137 2001-11-30 Akim Demaille <akim@epita.fr>
1139 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
1140 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
1141 Gettext doesn't compile cleanly, and dies with -Werror.
1142 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
1143 Include WARNING_CFLAGS here.
1144 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
1145 before being defined.
1147 2001-11-27 Paul Eggert <eggert@twinsun.com>
1149 * lib/quotearg.h (quotearg_n, quotearg_n_style):
1150 First arg is int, not unsigned.
1151 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
1152 (SIZE_MAX, UINT_MAX): New macros.
1153 (quotearg_n_options): Abort if N is negative.
1154 Avoid overflow check on hosts where size_t is 64 bits and int
1155 is 32 bits, as overflow is impossible there.
1156 Fix off-by-one typo that caused unnecessary reallocation.
1158 2001-11-29 Paul Eggert <eggert@twinsun.com>
1160 Name space cleanup in generated parser.
1162 * doc/bison.texinfo (Bison Parser): Discuss system headers
1163 and their effect on the user name space.
1166 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
1167 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
1168 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
1170 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
1171 on user names when possible.
1173 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
1174 Simplify test for whather <alloca.h> exists.
1176 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
1178 (<stdio.h>): Include if YYDEBUG.
1180 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
1181 ! defined (yyoverflow) && ! defined (yymemcpy).
1183 (yymemcpy, yyparse): Rename local variables as needed so that
1184 they all begin with 'yy'.
1186 (yystrlen, yystpcpy): New functions.
1188 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
1191 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
1192 instead of relying on string.h functions. Use YYSTACK_ALLOC
1193 and YYSTACK_FREE instead of malloc and free.
1195 2001-11-30 Akim Demaille <akim@epita.fr>
1197 * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions
1198 before their first uses.
1199 (YYBISON, YYPURE): Move to the top of the output.
1201 2001-11-30 Akim Demaille <akim@epita.fr>
1203 * tests/reduce.at (Useless Nonterminals): Fix.
1205 2001-11-30 Akim Demaille <akim@epita.fr>
1207 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
1208 if body instead of `;' to pacify GCC's warnings.
1210 2001-11-30 Akim Demaille <akim@epita.fr>
1212 Instead of mapping the LHS of unused rules to -1, keep the LHS
1213 valid, but flag the rules as invalid.
1215 * src/gram.h (rule_t): `useful' is a new member.
1216 * src/print.c (print_grammar): Adjust.
1217 * src/derives.c (set_derives): Likewise.
1218 * src/reader.c (packgram, reduce_output): Likewise.
1219 * src/reduce.c (reduce_grammar_tables): Likewise.
1220 * tests/reduce.at (Underivable Rules, Useless Rules): New.
1222 2001-11-30 Akim Demaille <akim@epita.fr>
1224 * src/reduce.c (reduce_output): Formatting changes.
1225 * src/print.c (print_results, print_grammar): Likewise.
1226 * tests/regression.at (Rule Line Numbers)
1227 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
1229 2001-11-30 Akim Demaille <akim@epita.fr>
1231 * src/reduce.c (nonterminals_reduce): Instead of throwing away
1232 useless nonterminals, move them at the end of the symbol arrays.
1233 (reduce_output): Adjust.
1234 * tests/reduce.at (Useless Nonterminals): Adjust.
1236 2001-11-30 Akim Demaille <akim@epita.fr>
1238 * src/reduce.c: Various comment/formatting changes.
1239 (nonterminals_reduce): New, extracted from...
1240 (reduce_grammar_tables): here.
1241 (reduce_grammar): Call nonterminals_reduce.
1243 2001-11-29 Paul Eggert <eggert@twinsun.com>
1245 * src/bison.simple (YYSTACK_REALLOC): Remove.
1246 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
1247 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
1249 (union yyalloc): New type.
1250 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
1251 an arbitrary restriction on hosts where size_t is wider than int.
1253 (yyparse): Don't dump core if alloca or malloc fails; instead, report
1254 a parser stack overflow. Allocate just one block of memory for all
1255 three stacks, instead of allocating three blocks; this typically is
1256 faster and reduces fragmentation.
1258 Do not limit the number of items in the stack to a value that fits
1259 in 'int', as this is an arbitrary limit on hosts with 64-bit
1260 size_t and 32-bit int.
1262 2001-11-29 Marc Autret <autret_m@epita.fr>
1264 * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead
1265 of defining YYERROR_VERBOSE.
1266 [AT_DATA]: $4 is now out of C declarations in the prologue.
1268 2001-11-28 Marc Autret <autret_m@epita.fr>
1270 * src/reader.c (parse_dquoted_param): New.
1271 (parse_skel_decl): Use it.
1272 * src/lex.h: Add its prototype.
1273 * src/lex.c (literalchar): Become not static.
1275 2001-11-28 Marc Autret <autret_m@epita.fr>
1277 * src/output.h: And put its extern declaration here.
1278 * src/output.c (error_verbose): Define here.
1279 (prepare): Echo name modification.
1280 * src/getargs.h: Clean its extern declaration.
1281 * src/getargs.c (error_verbose_flag): Remove.
1282 (getargs): Remove case 'e'.
1283 * src/options.c (option_table): 'error-verbose' is now seen as simple
1287 * src/reader.c (read_declarations): Remove case tok_include.
1288 (parse_include_decl): Remove.
1289 * src/lex.h (token_t): Remove tok_include.
1290 * src/options.c (option_table): 'include' is now a simple command line
1293 2001-11-28 Marc Autret <autret_m@epita.fr>
1295 * src/bison.simple: Adjust muscle names.
1296 * src/muscle_tab.c (muscle_init): Also rename the muscles.
1297 * src/output.c (prepare): s/_/-/ for the muscles names.
1298 (output_parser): When scanning for a muscle, allow '-' instead of '_'.
1300 2001-11-28 Marc Autret <autret_m@epita.fr>
1302 * src/bison.simple: Fix debug.
1303 [YYERROR_VERBOSE]: Re-integrate as an internal macro.
1305 2001-11-28 Akim Demaille <akim@epita.fr>
1307 * src/LR0.c (shifts_new): New.
1308 (save_shifts, insert_start_shift, augment_automaton): Use it.
1310 2001-11-28 Akim Demaille <akim@epita.fr>
1312 * src/closure.c (closure): `b' and `ruleno' denote the same value:
1315 2001-11-28 Akim Demaille <akim@epita.fr>
1317 * src/closure.c (closure): Instead of looping over word in array
1318 then bits in words, loop over bits in array.
1320 2001-11-28 Akim Demaille <akim@epita.fr>
1322 * src/closure.c (closure): No longer optimize the special case
1323 where all the bits of `ruleset[r]' are set to 0, to make the code
1326 2001-11-28 Akim Demaille <akim@epita.fr>
1328 * src/closure.c (closure): `r' and `c' are new variables, used to
1329 de-obfuscate accesses to RULESET and CORE.
1331 2001-11-28 Akim Demaille <akim@epita.fr>
1333 * src/reduce.c (reduce_print): Use ngettext.
1334 (dump_grammar): Improve the trace accuracy.
1336 2001-11-28 Akim Demaille <akim@epita.fr>
1338 * src/reduce.c (dump_grammar): Don't translate trace messages.
1340 2001-11-28 Akim Demaille <akim@epita.fr>
1342 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
1343 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
1344 as all tags are free'ed afterwards.
1347 2001-11-27 Paul Eggert <eggert@twinsun.com>
1349 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
1350 use alloca when we didn't want to, and vice versa.
1352 2001-11-27 Marc Autret <autret_m@epita.fr>
1354 * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle
1356 * src/output.c (prepare): Remove its update.
1358 2001-11-27 Marc Autret <autret_m@epita.fr>
1360 * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition.
1363 2001-11-27 Marc Autret <autret_m@epita.fr>
1365 * src/bison.simple: Remove YYERROR_VERBOSE using.
1366 Use %%error_verbose.
1367 (yyparse): Likewise.
1368 * src/output.c (prepare): Give its final value.
1369 * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'.
1370 * src/getargs.h: Add its extern declaration.
1371 * src/getargs.c (error_verbose_flag): New int.
1372 (getargs): Update to catch new case.
1373 * src/options.c (option_table): 'error-verbose' is a new option.
1374 (shortopts): Update.
1376 2001-11-27 Akim Demaille <akim@epita.fr>
1378 * src/system.h: Use intl/libgettext.h.
1379 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
1381 2001-11-27 Akim Demaille <akim@epita.fr>
1383 * tests/torture.at (Exploding the Stack Size with Malloc):
1384 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
1386 2001-11-27 Akim Demaille <akim@epita.fr>
1388 * src/files.c: Include error.h.
1389 Reported by Hans Aberg.
1391 2001-11-26 Marc Autret <autret_m@epita.fr>
1393 * src/reader.c (parse_include_decl): New, not yet implemented.
1394 (read_declarations): Add case tok_include.
1395 * src/getargs.h (include): Add its extern definition.
1396 * src/getargs.c (include): New const char *.
1397 (getargs): Add case '-I'.
1398 * src/options.c (option_table): Add include as command line and
1400 * src/lex.h (token_t): Add tok_include.
1402 2001-11-26 Akim Demaille <akim@epita.fr>
1404 * src/reader.c (readgram): Make sure rules for mid-rule actions
1405 have a lineno equal to that of their host rule.
1406 Reported by Hans Aberg.
1407 * tests/regression.at (Rule Line Numbers): New.
1409 2001-11-26 Akim Demaille <akim@epita.fr>
1411 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
1414 2001-11-26 Akim Demaille <akim@epita.fr>
1416 * src/complain.c, src/complain.h (error): Remove, provided by
1419 2001-11-26 Akim Demaille <akim@epita.fr>
1421 * src/reader.c (read_declarations): Don't abort on tok_illegal,
1422 issue an error message.
1423 * tests/regression.at (Invalid %directive): New.
1424 Reported by Hans Aberg.
1426 2001-11-26 Akim Demaille <akim@epita.fr>
1428 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
1429 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
1431 2001-11-26 Akim Demaille <akim@epita.fr>
1433 * src/conflicts.c (conflicts_print): Don't complain at all when
1434 there are no reduce/reduce conflicts, and as many shift/reduce
1435 conflicts as expected.
1436 * tests/regression.at (%expect right): Adjust.
1438 2001-11-23 Akim Demaille <akim@epita.fr>
1440 * lib/alloca.c: Update, from fileutils.
1442 2001-11-23 Akim Demaille <akim@epita.fr>
1444 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
1446 2001-11-23 Akim Demaille <akim@epita.fr>
1448 * src/system.h: Include alloca.h.
1449 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
1451 2001-11-23 Akim Demaille <akim@epita.fr>
1453 * src/print_graph.c (print_actions): Remove `rule', unused.
1454 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
1455 pacify GCC's signed < unsigned warnings.
1456 * src/closure.c (itemsetsize): Likewise.
1457 * src/reader.c (symbol_list_new): Static.
1459 2001-11-23 Akim Demaille <akim@epita.fr>
1461 Attaching lineno to buckets is stupid, since only one copy of each
1462 symbol is kept, only the line of the first occurrence is kept too.
1464 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
1465 * src/reader.c (rline_allocated): Remove, unused.
1466 (symbol_list): Have a `line' member.
1467 (symbol_list_new): New.
1469 * src/print.c (print_grammar): Output the rule line numbers.
1470 * tests/regression.at (Solved SR Conflicts)
1471 (Unresolved SR Conflicts): Adjust.
1472 Reported by Hans Aberg.
1474 2001-11-22 Marc Autret <autret_m@epita.fr>
1476 * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0.
1478 2001-11-22 Marc Autret <autret_m@epita.fr>
1480 * src/muscle_tab.c (muscle_init): Remove initialization of
1482 * src/output.c (output_master_parser): Do it here.
1484 2001-11-20 Akim Demaille <akim@epita.fr>
1487 * configure.in (ALL_LINGUAS): Adjust.
1488 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
1489 longer contains strings to translate.
1491 2001-11-19 Akim Demaille <akim@epita.fr>
1493 * src/conflicts.c (conflicts_print): Add a missing \n.
1495 2001-11-19 Akim Demaille <akim@epita.fr>
1497 * src/nullable.c (nullable_print): New.
1498 (set_nullable): Call it when tracing.
1499 Better locality of variables.
1501 2001-11-19 Akim Demaille <akim@epita.fr>
1503 * src/print.c (print_actions): Better locality of variables.
1505 2001-11-19 Akim Demaille <akim@epita.fr>
1507 * src/derives.c (print_derives): Fix and enrich.
1508 * src/closure.c (print_fderives): Likewise.
1510 2001-11-19 Akim Demaille <akim@epita.fr>
1512 * src/closure.c (itemsetend): Remove, replaced with...
1515 2001-11-19 Akim Demaille <akim@epita.fr>
1517 * src/LR0.c (kernel_end): Remove, replaced with...
1520 2001-11-19 Akim Demaille <akim@epita.fr>
1522 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
1525 2001-11-19 Akim Demaille <akim@epita.fr>
1527 * src/closure.c (closure): Use arrays instead of pointers to clarify.
1529 2001-11-19 Akim Demaille <akim@epita.fr>
1531 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
1533 * src/LR0.c: Likewise.
1534 (allocate_itemsets): Use arrays instead of pointers to clarify.
1536 2001-11-19 Akim Demaille <akim@epita.fr>
1538 * src/getargs.c (statistics_flag): Replace with...
1540 (longopts): Accept --trace instead of --statistics.
1541 * src/getargs.h, src/options.c: Adjust.
1542 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
1543 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
1545 2001-11-19 Akim Demaille <akim@epita.fr>
1547 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
1548 pointers to clarify the code.
1549 (save_reductions, save_shifts): Factor common parts of alternatives.
1551 2001-11-19 Akim Demaille <akim@epita.fr>
1553 * src/LR0.c (new_state, get_state): Complete TRACE code.
1554 * src/closure.c: Include `reader.h' to get `tags', needed by the
1556 Rename the conditional DEBUG as TRACE.
1557 Output consistently TRACEs to stderr, not stdout.
1558 * src/derives.c: Likewise.
1559 * src/reduce.c: (inaccessable_symbols): Using if is better style
1561 Use `#if TRACE' instead of `#if 0' for tracing code.
1563 2001-11-19 Akim Demaille <akim@epita.fr>
1565 * src/system.h (LIST_FREE, shortcpy): New.
1566 * src/LR0.c: Use them.
1567 * src/output.c (free_itemsets, free_reductions, free_shifts):
1568 Remove, replaced by LIST_FREE.
1570 2001-11-19 Akim Demaille <akim@epita.fr>
1572 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
1573 (REDUCTIONS_ALLOC): New.
1574 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
1577 2001-11-19 Akim Demaille <akim@epita.fr>
1579 * src/LR0.c (new_state): Complete trace code.
1580 * src/nullable.c (set_nullable): Don't translate traces.
1582 2001-11-19 Akim Demaille <akim@epita.fr>
1584 * src/print_graph.c (print_core): Better locality of variables.
1585 * src/print.c (print_core): Likewise.
1587 2001-11-19 Akim Demaille <akim@epita.fr>
1589 * src/vcg.c: You do the output, so you are responsible of the
1590 handling of VCG syntax, in particular: use quotearg.
1591 * src/print_graph.c: Don't.
1592 (print_actions): Don't output the actions as part of the nodes,
1593 since that's the job of the edges.
1594 (print_state): Don't output by hand: fill the node description,
1595 and ask for its output.
1597 2001-11-19 Akim Demaille <akim@epita.fr>
1599 * src/bison.simple (yyparse): When verbosely reporting an error,
1600 no longer put additional quotes around token names.
1601 * tests/calc.at: Adjust.
1603 2001-11-19 Akim Demaille <akim@epita.fr>
1605 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
1606 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
1607 * src/output.c: Adjust.
1609 2001-11-19 Akim Demaille <akim@epita.fr>
1611 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
1613 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
1615 2001-11-19 Akim Demaille <akim@epita.fr>
1617 * src/gram.h (rule_t): New.
1619 (rrhs, rlhs): Remove, part of state_t.
1620 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
1621 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
1622 * src/reader.c, src/reduce.c: Adjust.
1624 2001-11-19 Akim Demaille <akim@epita.fr>
1626 * src/reader.c (symbols_output): New, extracted from...
1627 (packsymbols): Here.
1630 2001-11-19 Akim Demaille <akim@epita.fr>
1632 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
1633 (maxrhs): this new function.
1635 2001-11-19 Akim Demaille <akim@epita.fr>
1637 * src/lalr.c (F): New macro to access the variable F.
1640 2001-11-19 Akim Demaille <akim@epita.fr>
1642 * src/lalr.h (LA): New macro to access the variable LA.
1643 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1644 * src/lalr.c: Adjust.
1646 2001-11-19 Akim Demaille <akim@epita.fr>
1648 * src/lalr.c (initialize_LA): Only initialize LA. Let...
1649 (set_state_table): handle the `lookaheads' members.
1651 2001-11-19 Akim Demaille <akim@epita.fr>
1653 * src/lalr.h (lookaheads): Removed array, whose contents is now
1655 (state_t): this structure.
1656 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1659 2001-11-19 Akim Demaille <akim@epita.fr>
1661 * src/lalr.h (consistent): Removed array, whose contents is now
1663 (state_t): this structure.
1664 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1667 2001-11-19 Akim Demaille <akim@epita.fr>
1669 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
1670 contents are now members of...
1671 (state_t): this structure.
1672 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1675 2001-11-19 Akim Demaille <akim@epita.fr>
1677 * src/lalr.h (state_t): New.
1678 (state_table): Be a state_t * instead of a core **.
1679 (accessing_symbol): Remove, part of state_t.
1680 * src/lalr.c: Adjust.
1681 (set_accessing_symbol): Merge into...
1682 (set_state_table): this.
1683 * src/print_graph.c, src/conflicts.c: Adjust.
1685 2001-11-14 Akim Demaille <akim@epita.fr>
1687 * tests/calc.at, tests/output.at, tests/regression.at,
1688 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
1689 now the tests are run in private dirs, therefore AC_CLEANUP and
1690 family can be simplified to 0-ary.
1691 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
1692 use abs. path to find config.h.
1693 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
1694 stderr, there can be way too much random noise.
1695 Instead pass -Werror to GCC and rely on the exit status.
1696 Reported by Wolfram Wagner.
1698 2001-11-14 Akim Demaille <akim@epita.fr>
1700 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
1701 defined only if yyoverflow is defined, to avoid `warning: unused
1703 Reported by The Test Suite.
1705 2001-11-14 Akim Demaille <akim@epita.fr>
1707 * src/print.c: Include reduce.h.
1708 Reported by Hans Aberg.
1710 2001-11-14 Akim Demaille <akim@epita.fr>
1712 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
1713 Revert a previous patch: these are really const.
1714 * src/conflicts.c (conflict_report): Additional useless pair of
1715 braces to pacify GCC's warnings for `if () if () {} else {}'.
1716 * src/lex.c (parse_percent_token): Replace equal_offset with
1719 Be sure to strdup `arg' when used, since there is no reason for
1720 token_buffer not to change.
1722 2001-11-14 Akim Demaille <akim@epita.fr>
1724 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
1726 * src/main.c (main): Use them.
1727 Suggested by Hans Aberg.
1729 2001-11-12 Akim Demaille <akim@epita.fr>
1731 * src/system.h (ngettext): Now that we use ngettext, be sure to
1732 provide a default definition when NLS are not used.
1734 2001-11-12 Akim Demaille <akim@epita.fr>
1736 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
1737 Use @kbd to denote user input.
1738 (Language and Grammar): ANSIfy the example.
1739 Adjust its layout for info/notinfo.
1740 (Location Tracking Calc): Output error messages to stderr.
1741 Output locations in a more GNUtically correct way.
1742 Fix a couple of Englishos.
1743 Adjust @group/@end group pairs.
1745 2001-11-12 Akim Demaille <akim@epita.fr>
1747 %expext was not functioning at all.
1749 * src/conflicts.c (expected_conflicts): Set to -1.
1750 (conflict_report): Use ngettext.
1751 (conflicts_print): Check %expect and make its violation an error.
1752 * doc/bison.texinfo (Expect Decl): Adjust.
1753 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
1754 * tests/regression.at (%expect not enough, %expect right)
1755 (%expect too much): New.
1757 2001-11-12 Akim Demaille <akim@epita.fr>
1759 * tests/regression.at (Conflicts): Rename as...
1760 (Unresolved SR Conflicts): this.
1761 (Solved SR Conflicts): New.
1763 2001-11-12 Akim Demaille <akim@epita.fr>
1765 * src/reduce.c (print_results): Rename as...
1766 (reduce_output): This.
1767 Output to OUT, passed as argument, instead of output_obstack.
1768 (dump_grammar): Likewise.
1771 (reduce_grammar): No longer call reduce_output, since...
1772 * src/print.c (print_results): do it.
1773 * src/main.c (main): Call reduce_free;
1775 2001-11-12 Akim Demaille <akim@epita.fr>
1777 * src/conflicts.c (print_reductions): Accept OUT as argument.
1778 Output to it, not to output_obstack.
1779 * src/print.c (print_actions): Adjust.
1781 2001-11-12 Akim Demaille <akim@epita.fr>
1783 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
1784 the result instead of using...
1785 (src_total, rrc_total, src_count, rrc_count): Remove.
1786 (any_conflicts): Remove.
1787 (print_conflicts): Split into...
1788 (conflicts_print, conflicts_output): New.
1789 * src/conflicts.h: Adjust.
1790 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
1791 * src/print.c (print_grammar): Issue `\n' between two rules.
1792 * tests/regression.at (Conflicts): New.
1793 Reported by Tom Lane.
1795 2001-11-12 Akim Demaille <akim@epita.fr>
1797 * tests/regression.at (Invalid input): Remove, duplicate with
1798 ``Invalid input: 1''.
1800 2001-11-12 Akim Demaille <akim@epita.fr>
1802 * tests/torture.at (AT_DATA_STACK_TORTURE)
1803 (Exploding the Stack Size with Alloca)
1804 (Exploding the Stack Size with Malloc): New.
1806 2001-11-12 Akim Demaille <akim@epita.fr>
1808 * src/bison.simple (YYSTACK_REALLOC): New.
1809 (yyparse) [!yyoverflow]: Use it and free the old stack.
1810 Reported by Per Allansson.
1812 2001-11-12 Pascal Bart <pascal.bart@epita.fr>
1814 * src/bison.simple: Define type yystype instead of YYSTYPE, and
1815 define CPP macro, which substitute YYSTYPE by yystype.
1816 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
1817 with yyltype/YYLTYPE. This allows inclusion of the generated
1818 header within the parser if the compiler, such as GGC, accepts
1819 multiple equivalent #defines.
1822 2001-11-05 Akim Demaille <akim@epita.fr>
1824 * src/reader.c (symbols_output): New, extracted from...
1825 (packsymbols): here.
1828 2001-11-05 Akim Demaille <akim@epita.fr>
1830 * src/lex.c (parse_percent_token): s/quotearg/quote/.
1832 2001-11-05 Akim Demaille <akim@epita.fr>
1834 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
1837 2001-11-05 Akim Demaille <akim@epita.fr>
1839 * src/options.h (struct option_table_struct): set_flags is void*.
1840 * src/options.c (longopts): Support `--output' and `%output'.
1842 * src/lex.h (tok_setopt): Remove, replaced with...
1843 (tok_intopt, tok_stropt): these new guys.
1844 * src/lex.c (getopt.h): Not needed.
1845 (token_buffer, unlexed_token_buffer): Not const.
1846 (percent_table): Promote `-' over `_' in directive names.
1847 Active `%name-prefix', `file-prefix', and `output'.
1848 (parse_percent_token): Accept possible arguments to directives.
1849 Promote `-' over `_' in directive names.
1851 2001-11-04 Akim Demaille <akim@epita.fr>
1853 * doc/bison.texinfo (Decl Summary): Split the list into
1854 `directives for grammars' and `directives for bison'.
1856 Add description of `%name-prefix', `file-prefix', and `output'.
1857 Promote `-' over `_' in directive names.
1858 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
1859 Simplify the description of `--name-prefix'.
1860 Promote `-' over `_' in directive names.
1861 Promote `--output' over `--output-file'.
1862 Fix the description of `--defines'.
1863 * tests/output.at: Exercise %file-prefix and %output.
1865 2001-11-02 Akim Demaille <akim@epita.fr>
1867 * doc/refcard.tex: Update.
1869 2001-11-02 Akim Demaille <akim@epita.fr>
1871 * src/symtab.h (SUNDEF): New.
1872 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
1873 stand for `uninitialized', instead of 0.
1874 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
1875 * src/lex.c (lex): Adjust.
1877 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
1879 Let yylex return it instead of a plain 0.
1880 Reported by Dick Streefland.
1882 2001-11-02 Akim Demaille <akim@epita.fr>
1884 * tests/regression.at (Mixing %token styles): New test.
1886 2001-11-02 Akim Demaille <akim@epita.fr>
1888 * src/reader.c (parse_thong_decl): Formatting changes.
1889 (token_translations_init): New, extracted from...
1890 (packsymbols): Here.
1893 2001-11-01 Akim Demaille <akim@epita.fr>
1895 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
1896 Check that `9foo.y' produces correct cpp guards.
1897 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
1901 2001-11-01 Akim Demaille <akim@epita.fr>
1903 * tests/regression.at (Invalid input: 2): New.
1904 * src/lex.c (unlexed_token_buffer): New.
1905 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
1909 2001-11-01 Akim Demaille <akim@epita.fr>
1911 * tests/calc.at: Catch up with 1.30.
1912 * configure.in: Bump to 1.49a.
1913 Adjust to newer Autotest.
1915 2001-10-19 Pascal Bart <pascal.bart@epita.fr>
1917 * src/conflicts.c: Move global variables rrc_total and src_total ...
1918 (print_conflicts): here.
1919 * src/output.c (output): Free global variable user_toknums.
1920 * src/lex.c (token_obstack): Become static.
1922 2001-10-18 Akim Demaille <akim@epita.fr>
1924 * tests/atlocal.in (GCC): Add.
1925 * tests/calc.at: s/m4_match/m4_bmatch/.
1926 s/m4_patsubst/m4_bpatsubst/.
1927 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
1928 * configure.in: AC_SUBST(GCC).
1930 2001-10-14 Marc Autret <autret_m@epita.fr>
1932 * src/options.c (create_long_option_table): Fix.
1934 2001-10-10 Akim Demaille <akim@epita.fr>
1936 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
1938 2001-10-04 Akim Demaille <akim@epita.fr>
1940 * src/reader.c (parse_union_decl): Push the caracters in
1941 union_obstack, not attrs_obstack.
1943 2001-10-04 Akim Demaille <akim@epita.fr>
1945 Merge in the branch 1.29.
1947 * src/reader.c (packsymbols): Use a temporary obstack for
1948 `%%tokendef', since output_stack is already used elsewhere.
1950 2001-10-02 Akim Demaille <akim@epita.fr>
1954 2001-10-02 Akim Demaille <akim@epita.fr>
1958 2001-10-02 Akim Demaille <akim@epita.fr>
1960 * tests/regression.at (Invalid CPP headers): New.
1961 From Alexander Belopolsky.
1962 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
1964 2001-10-02 Akim Demaille <akim@epita.fr>
1966 * tests/regression.at (Invalid input): New.
1967 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
1970 2001-10-02 Akim Demaille <akim@epita.fr>
1972 * tests/calc.at: Now that --debug works, the tests must be adjusted.
1974 2001-10-02 Akim Demaille <akim@epita.fr>
1976 * src/output.c (output_parser): Assert `skeleton'.
1977 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
1981 2001-10-01 Marc Autret <autret_m@epita.fr>
1983 * src/lex.h: Echo modifications.
1984 * src/lex.c (unlex): Parameter is now token_t.
1987 2001-10-01 Marc Autret <autret_m@epita.fr>
1989 * src/main.c: Include lex.h.
1992 2001-09-29 Akim Demaille <akim@epita.fr>
1994 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
1996 2001-09-28 Akim Demaille <akim@epita.fr>
1998 * tests/testsuite.at: Update to newer Autotest.
1999 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
2001 2001-09-27 Akim Demaille <akim@epita.fr>
2003 Position independent wrapper.
2005 * tests/bison: Remove.
2006 * tests/bison.in: New.
2007 * configure.in: Adjust.
2009 2001-09-27 Paul Eggert <eggert@twinsun.com>
2011 Port quotearg fixes from tar 1.13.24.
2013 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
2015 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
2016 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
2018 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
2019 * m4/mbrtowc.m4: New file.
2020 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
2021 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
2023 2001-09-27 Akim Demaille <akim@epita.fr>
2027 2001-09-27 Akim Demaille <akim@epita.fr>
2031 2001-09-25 Akim Demaille <akim@epita.fr>
2033 * src/system.h: Include `xalloc.h'.
2034 Remove it from the C files.
2035 * src/files.c (output_files): Free the obstacks.
2036 * src/lex.c (init_lex): Rename as...
2039 * src/main.c (main): Use it.
2041 2001-09-24 Marc Autret <autret_m@epita.fr>
2043 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
2044 to output informations in fout (FILE*).
2045 (open_graph, close_graph): Likewise.
2046 (output_graph, output_edge, output_node): Likewise.
2047 * src/vcg.h: Update function prototypes.
2048 * src/print_graph.c (print_graph): Open output graph file.
2049 (print_actions): Adjust.
2050 * src/files.h: Remove extern declaration.
2051 * src/files.c: Remove graph_obstack declaration.
2052 (open_files): Remove graph_obstack initialization.
2053 (output_files): Remove graph_obstack saving.
2055 2001-09-24 Marc Autret <autret_m@epita.fr>
2057 * src/files.c (compute_output_file_names): Fix.
2059 2001-09-24 Marc Autret <autret_m@epita.fr>,
2060 Akim Demaille <akim@epita.fr>
2062 * src/reader.c (reader): Remove call to free_symtab ().
2063 * src/main.c (main): Call it here.
2065 * src/conflicts.c (initialize_conflicts): Rename as...
2066 (solve_conflicts): this.
2067 * src/print.c (print_core, print_actions, print_state)
2068 (print_grammar): Dump to a file instead a `output_obstack'.
2069 (print_results): Dump `output_obstack', and then proceed with the
2071 * src/files.c (compute_output_file_names, close_files): New.
2072 (output_files): Adjust.
2073 * src/main.c (main): Adjust.
2075 2001-09-23 Marc Autret <autret_m@epita.fr>
2077 * src/files.c (compute_header_macro): Computes header macro name
2078 from spec_defines_file when given.
2080 2001-09-23 Marc Autret <autret_m@epita.fr>
2082 * src/files.c (output_files): Add default extensions.
2084 2001-09-22 Akim Demaille <akim@epita.fr>
2086 * src/conflicts.c (finalize_conflicts): Rename as...
2087 (free_conflicts): this.
2089 2001-09-22 Akim Demaille <akim@epita.fr>
2091 * src/gram.c (gram_free): Rename back as...
2093 (output_token_translations): Free `token_translations'.
2094 * src/symtab.c (free_symtab): Free the tag field.
2096 2001-09-22 Akim Demaille <akim@epita.fr>
2098 Remove `translations' as it is always set to true.
2100 * src/gram.h: Adjust.
2101 * src/reader.c (packsymbols, parse_token_decl): Adjust
2102 * src/print.c (print_grammar): Adjust.
2103 * src/output.c (output_token_translations): Adjust.
2104 * src/lex.c (lex): Adjust.
2105 * src/gram.c: Be sure the set pointers to NULL.
2106 (dummy): Rename as...
2109 2001-09-22 Akim Demaille <akim@epita.fr>
2111 * configure.in: Invoke AM_LIB_DMALLOC.
2112 * src/system.h: Use dmalloc.
2113 * src/LR0.c: Be sure to have pointers initialized to NULL.
2114 (allocate_itemsets): Allocate kernel_items only if needed.
2116 2001-09-22 Akim Demaille <akim@epita.fr>
2118 * configure.in: Bump to 1.29b.
2119 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
2120 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
2121 need xmalloc.c in calc.y.
2124 2001-09-21 Akim Demaille <akim@epita.fr>
2127 * Makefile.maint, config/config.guess, config/config.sub,
2128 * config/missing: Update from masters.
2129 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
2131 * configure.in (ALL_LINGUAS): Add `tr'.
2133 2001-09-21 Akim Demaille <akim@epita.fr>
2135 * tests/Makefile.am (package.m4): Move to...
2136 ($(srcdir)/$(TESTSUITE)): here.
2138 2001-09-20 Akim Demaille <akim@epita.fr>
2140 * src/complain.c: No longer try to be standalone: use system.h.
2141 Don't assume __STDC__ is defined to 1. Just test if it is defined.
2142 * src/complain.h: Likewise.
2143 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
2144 Remove the unused variable `n'.
2145 From Albert Chin-A-Young.
2147 2001-09-18 Marc Autret <autret_m@epita.fr>
2149 * doc/bison.1: Update.
2150 * doc/bison.texinfo (Bison Options): Update --defines and --graph
2152 (Option Cross Key): Update.
2155 2001-09-18 Marc Autret <autret_m@epita.fr>
2157 * tests/regression.at: New test (comment in %union).
2159 2001-09-18 Marc Autret <autret_m@epita.fr>
2161 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
2163 Reported by Keith Browne.
2165 2001-09-18 Marc Autret <autret_m@epita.fr>
2167 * tests/output.at: Add tests for --defines and --graph.
2169 2001-09-18 Marc Autret <autret_m@epita.fr>
2171 * tests/output.at: Removes tests of %{header,src}_extension features.
2173 2001-09-18 Akim Demaille <akim@epita.fr>
2175 * tests/Makefile.am (package.m4): New.
2176 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
2177 (_AT_CHECK_CALC_ERROR): Likewise.
2178 Factor the `, ' part of verbose error messages.
2180 2001-09-18 Marc Autret <autret_m@epita.fr>
2182 * src/getargs.c (longopts): Declare --defines and --graph as options
2183 with optional arguments.
2184 * src/files.h: Add extern declarations.
2185 * src/files.c (spec_graph_file, spec_defines_file): New.
2186 (output_files): Update.
2187 Remove CPP-outed code.
2189 2001-09-18 Marc Autret <autret_m@epita.fr>
2191 Turn off %{source,header}_extension feature.
2193 * src/files.c (compute_exts_from_gf): Update.
2194 (compute_exts_from_src): Update.
2195 (output_files): CPP-out useless code.
2196 * src/files.h: Remove {header,source}_extension extern declarations.
2197 * src/reader.c (parse_dquoted_param): CPP-out.
2198 (parse_header_extension_decl): Remove.
2199 (parse_source_extension_decl): Remove.
2200 (read_declarations): Remove cases tok_{hdrext,srcext}.
2201 * src/lex.c (percent_table): Remove {header,source}_extension entries.
2202 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
2204 2001-09-10 Akim Demaille <akim@epita.fr>
2206 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
2207 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
2208 (AT_CHECK_OUTPUT): this.
2209 Merely check ls' exit status, its output is useless.
2211 2001-09-10 Akim Demaille <akim@epita.fr>
2213 * tests/calc.at: Use m4_match.
2214 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
2216 2001-09-10 Marc Autret <autret_m@epita.fr>,
2217 Akim Demaille <akim@epita.fr>
2219 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
2221 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
2223 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
2224 * src/lex.h: Adjust prototype.
2225 (token_t): Add `tok_undef'.
2226 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
2227 (parse_percent_token): Now returns token_t.
2228 Add default statement in switch.
2229 (lex): Separate `c' as an input variable, from the token_t result
2231 (unlexed): Is a token_t.
2233 2001-09-10 Akim Demaille <akim@epita.fr>
2235 * configure.in: Bump to 1.29a.
2237 2001-09-07 Akim Demaille <akim@epita.fr>
2241 2001-08-30 Akim Demaille <akim@epita.fr>
2243 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
2244 * m4/atconfig.m4: Remove.
2245 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
2247 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
2248 m4_if, m4_patsubst, and m4_regexp.
2249 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
2250 `input' file instead of echo.
2252 2001-08-29 Akim Demaille <akim@epita.fr>
2256 2001-08-29 Akim Demaille <akim@epita.fr>
2260 2001-08-29 Paul Eggert <eggert@twinsun.com>
2262 * src/bison.simple (yyparse): Don't take the address of an
2263 item before the start of an array, as that doesn't conform to
2266 2001-08-29 Robert Anisko <anisko_r@epita.fr>
2268 * doc/bison.texinfo (Location Tracking Calc): New node.
2270 2001-08-29 Paul Eggert <eggert@twinsun.com>
2272 * src/output.c (output): Do not define const, as this now
2273 causes more problems than it cures.
2275 2001-08-29 Akim Demaille <akim@epita.fr>
2277 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
2279 Be sure to tag the `detailmenu'.
2281 2001-08-29 Akim Demaille <akim@epita.fr>
2283 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
2284 download in a tmp dir.
2286 2001-08-28 Marc Autret <autret_m@epita.fr>
2288 * config/depcomp: New file.
2290 2001-08-28 Marc Autret <autret_m@epita.fr>
2292 * doc/bison.1 (mandoc): Adjust.
2293 From Juan Manuel Guerrero.
2295 2001-08-28 Marc Autret <autret_m@epita.fr>
2297 * src/print_graph.c (print_state): Fix.
2299 2001-08-27 Marc Autret <autret_m@epita.fr>
2301 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
2303 Echo modifications to the functions prototypes.
2304 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
2306 2001-08-27 Marc Autret <autret_m@epita.fr>
2308 * src/vcg.c: Include `xalloc.h'.
2309 (add_colorentry): New.
2310 (add_classname): New.
2311 (add_infoname): New.
2312 * src/vcg.h: Add new prototypes.
2314 2001-08-27 Akim Demaille <akim@epita.fr>
2316 * Makefile.maint: Sync. again with CVS Autoconf.
2318 2001-08-27 Akim Demaille <akim@epita.fr>
2320 * Makefile.maint: Formatting changes.
2321 (po-update, cvs-update, update): New targets.
2324 2001-08-27 Akim Demaille <akim@epita.fr>
2326 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
2327 * Makefile.maint: Sync. with CVS Autoconf.
2329 2001-08-27 Marc Autret <autret_m@epita.fr>
2331 * src/vcg.h (struct infoname_s): New.
2332 (struct colorentry_s): New.
2333 (graph_s): New fields {vertical,horizontal}_order in structure.
2334 Add `infoname' field.
2335 Add `colorentry' field;
2336 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
2337 (G_HORIZONTAL_ORDER): New.
2339 (G_COLORENTRY): New.
2340 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
2341 Add output of `infoname'.
2342 Add output of `colorentry'.
2344 2001-08-27 Marc Autret <autret_m@epita.fr>
2346 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
2347 This one shadowed a global parameter.
2349 2001-08-24 Marc Autret <autret_m@epita.fr>
2351 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
2352 instead of `unsigned'.
2353 (print_state): Do not call obstack_object_size () in obstack_grow ()
2354 to avoid macro variables shadowing.
2356 2001-08-23 Marc Autret <autret_m@epita.fr>
2358 * src/lex.c (percent_table): Typo: s/naem/name/.
2360 Normalize new options declarations.
2362 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
2364 * tests/suite.at: Exercise %header_extension and %source_extension.
2366 2001-08-16 Marc Autret <autret_m@epita.fr>
2368 * src/reader.c (parse_dquoted_param): New.
2369 (parse_header_extension_decl): Use it.
2370 (parse_source_extension_decl): Likewise.
2372 2001-08-16 Marc Autret <autret_m@epita.fr>
2374 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
2375 (get_xxxx_str): Use assert () instead of complain ().
2376 Remove return invokations in default cases.
2377 (get_decision_str): Modify default behaviour. Remove second argument.
2378 Echo modifications on calls.
2379 (output_graph): Fix.
2381 2001-08-16 Marc Autret <autret_m@epita.fr>
2383 * src/getargs.c (usage): Update with ``-g, --graph''.
2385 2001-08-16 Marc Autret <autret_m@epita.fr>
2387 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
2388 (Option Cross Key): Likewise.
2389 * doc/bison.1: Update.
2391 2001-09-25 Pascal Bart <pascal.bart@epita.fr>
2393 * src/output.c (output_master_parser): Don't finish action_obstack.
2394 (output_parser): Don't care about the muscle action, here.
2395 (prepare): Copy the action_obstack in the action muscle.
2396 (output): Free action_obstack.
2398 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
2400 * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which
2401 will contain `%union' declaration.
2402 (parse_union_decl): Delete #line directive output.
2403 (parse_union_decl): Substitute /attrs_obstack/union_obstack for all
2404 informations about %union.
2405 (parse_union_decl): Copy the union_obstack in the muscle stype.
2406 * src/bison.simple: Add new #line directive.
2407 Add typdef %%stype YYSTYPE.
2409 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
2411 * src/bison.simple: Add new `#line' directive.
2413 2001-09-22 Pascal Bart <pascal.bart@epita.fr>
2415 * src/bison.simple: New `#line' directive.
2416 * src/output.c (output_parser): Support new dynamic muscle input_line.
2418 2001-09-22 Marc Autret <autret_m@epita.fr>
2420 * src/output.c (output_master_parser): New.
2421 (output_parser): Be more re-entrant.
2423 2001-09-21 Marc Autret <autret_m@epita.fr>
2425 * src/reader.c (copy_definition, parse_union_decl): Update and use
2427 (copy_action): Likewise.
2428 Use obstack_1grow ().
2429 * src/muscle_tab.c (muscle_init): Add muscle `linef'.
2431 2001-09-21 Marc Autret <autret_m@epita.fr>
2433 * src/options.c (option_table): Adjust.
2434 * src/lex.c (parse_percent_token): Fix.
2436 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
2438 * src/options.c (symtab.h): Include it, need by lex.h.
2440 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
2442 * src/lex.c (parse_percent_token): Change type of variable `tx', which
2443 is now an option_table_struct*.
2444 (option_strcmp): New function option_strcmp.
2445 (parse_percent_token): Call option_strcmp.
2446 * src/getargs.c (xalloc.h, options.h): Include it.
2447 (getargs): Call create_long_option_table.
2448 (getargs): Free longopts at the end of the function.
2449 (shortopts): Move in options.c.
2450 * src/options.c (create_long_option_table): New function. Convert
2451 information from option_table to option structure.
2452 * src/reader.c (options.h): Include it.
2454 * src/Makefile.am: Adjust.
2455 * src/options.c (option_table): Create from longopts and percent_table.
2456 * src/getargs.c (longopts): Delete.
2457 * src/lex.c (struct percent_table_struct): Delete.
2458 (percent_table): Delete.
2459 (options.h): Include it.
2460 * src/options.c: Create.
2461 * src/options.h: Create.
2462 Declare enum opt_access_e.
2463 Define struct option_table_struct.
2465 2001-09-20 Marc Autret <autret_m@epita.fr>
2467 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
2470 2001-09-19 Pascal Bart <pascal.bart@epita.fr>
2472 * src/bison.simple: s/%%filename/%%skeleton.
2473 * src/muscle_tab.c (getargs.h): Include it.
2474 (muscle_init): Insert new muscle skeleton.
2476 2001-09-18 Pascal Bart <pascal.bart@epita.fr>
2478 * src/output.c (output_parser): Delete unused variable actions_dumped.
2480 2001-09-07 Pascal Bart <pascal.bart@epita.fr>
2482 * src/output.c (output): Delete call to reader_output_yylsp.
2483 * src/reader.c (reader): Likewise.
2484 * src/reader.h: Delete declaration of reader_output_yylsp.
2486 2001-09-02 Marc Autret <autret_m@epita.fr>
2488 * src/reader.c: Include muscle_tab.h.
2489 (parse_union_decl): Update.
2490 (parse_macro_decl): Rename parse_muscle_decl.
2491 Update to use renamed functions and variable.
2492 (read_declarations, copy_action, read_additionnal_code, : Updated
2493 with correct variables and functions names.
2494 (packsymbols, reader): Likewise.
2496 * src/reader.h (muscle_obstack): Extern declaration update.
2498 * src/output.c: Include muscle_tab.h
2499 In all functions using macro_insert, change by using muscle_insert ().
2500 (macro_obstack): Rename muscle_obstack.
2501 Echo modifications in the whole file.
2502 (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT.
2503 (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING.
2504 (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX.
2506 * src/muscle_tab.h: Update double inclusion macros.
2507 (macro_entry_s): Rename muscle_entry_s.
2510 * src/muscle_tab.c: Include muscle_tab.h.
2511 Rename macro_tabble to muscle_table.
2512 (mhash1, mhash2, mcmp): Use muscle_entry.
2513 (macro_init): Rename muscle_init. Update.
2514 (macro_insert): Rename muscle_insert. Update.
2515 (macro_find): Rename muscle_find. Update.
2517 * src/main.c: Include muscle_tab.h.
2518 (main): Call muscle_init ().
2519 * src/Makefile.am (bison_SOURCES): Echo modifications.
2521 2001-09-02 Marc Autret <autret_m@epita.fr>
2523 Now the files macro_tab.[ch] are named muscle_tab.[ch].
2525 * src/muscle_tab.c, src/muscle_tab.h: Add files.
2527 2001-09-02 Marc Autret <autret_m@epita.fr>
2529 * src/macrotab.c, src/macrotab.h: Remove.
2531 2001-09-01 Pascal Bart <pascal.bart@epita.fr>
2533 * src/reader.c (copy_guard): Use muscle to specify the `#line'
2536 2001-09-01 Marc Autret <autret_m@epita.fr>
2538 * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set
2539 to an explicit value to activate the feature. We do it here.
2541 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2543 * src/output.c (prepare): Delete the `filename' muscule insertion.
2544 * src/reader.c (copy_action): Use `filename' muscule with `#line'.
2545 (parse_union_decl): Likewise.
2546 * src/macrotab.c (macro_init): Initialize filename by infile.
2548 2001-08-31 Marc Autret <autret_m@epita.fr>
2550 * src/bison.simple (YYLSP_NEEDED): New definition.
2551 * src/output.c (prepare): Add macro insertion of `locations_flag'
2553 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2555 * src/output.c (prepare): Delete insertion of previous muscles,
2556 and insert the `prefix' muscles.
2557 * src/macrotab.c (macro_init): Likewise.
2558 (macro_init): Initialization prefix directive by `yy'.
2559 * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval,
2560 %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar,
2561 yylval, yydebug, yyerror, yynerrs and yyparse.
2562 New directive `#define' to substitute yydebug, ... with option
2565 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2567 * src/main.c (main): Standardize.
2568 * src/output.c (output_table_data, output_parser): Likewise.
2569 * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise.
2571 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr>
2573 * src/reader.c (read_additionnal_code): Rename %%user_code to
2575 * src/output.c (output): Rename %%declarations to %%prologue.
2576 * src/bison.simple: Echo modifications.
2578 2001-08-31 Marc Autret <autret_m@epita.fr>
2580 * src/reader.c (readgram): CleanUp.
2581 (output_token_defines): Likewise.
2582 (packsymbols): Likewise.
2584 * src/output.c (output): CPP-out useless code.
2586 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2588 * src/reader.c (reader): Delete obsolete call to function
2589 output_trailers and output_headers.
2590 * src/output.h: Remove obsolete functions prototypes of output_headers
2591 and output_trailers.
2593 2001-08-30 Pascal Bart <pascal.bart@epita.fr>
2595 * src/main.c: Include macrotab.h.
2596 * src/macrotab.h (macro_entry_s): Constify fields.
2597 Adjust functions prototypes.
2598 * src/macrotab.c (macro_insert): Constify key and value.
2599 (macro_find): Constify key.
2600 (macro_insert): Include 'xalloc.h'
2601 (macro_insert): Use XMALLOC.
2602 (macro_find): Constify return value.
2603 * src/output.c (output_table_data): Rename table to table_data.
2604 (output_parser): Constify macro_key, macro_value.
2606 2001-08-30 Marc Autret <autret_m@epita.fr>
2608 * src/reader.c (parse_skel_decl): New.
2609 (read_declarations): Add case `tok_skel', call parse_skel_decl ().
2610 * src/lex.h (token_t): New token `tok_skel'.
2611 * src/lex.c (percent_table): Add skeleton option entry.
2614 2001-08-29 Marc Autret <autret_m@epita.fr>
2616 * src/bison.simple: Add %%user_code directive at the end.
2617 * src/reader.c (read_additionnal_code): New.
2619 * src/output.c (output_program): Remove.
2622 2001-08-28 Marc Autret <autret_m@epita.fr>
2624 * src/output.c (output_actions): Clean up.
2625 (output_gram): CPP-out useless code.
2626 * src/reader.c (reader): Clean up, CPP-out useless code.
2628 2001-08-28 Pascal Bart <pascal.bart@epita.fr>
2630 * src/output.c (output): Copy attrs_obstack in the '%%definitions'
2632 * src/bison.simple: Add `%%definitions'.
2634 2001-08-28 Marc Autret <autret_m@epita.fr>
2636 * config/depcomp: New file.
2638 2001-08-27 Paul Eggert <eggert@twinsun.com>
2640 * src/bison.simple (yyparse): Don't take the address of an
2641 item before the start of an array, as that doesn't conform to
2644 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2646 * src/output.c (output): Remove the initialization of the macro
2647 obstack. It was done too late here.
2649 * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was
2651 (reader): Initialize the macro obstack here, since we need it to grow
2652 '%define' directives.
2654 * src/reader.h: Declare the macro obstack as extern.
2656 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2658 * src/output.c (output_parser): Fix. Store single '%' characters in
2659 the output obstack instead of throwing them away.
2661 2001-08-27 Akim Demaille <akim@epita.fr>
2663 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
2665 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2667 * lib/Makefile.am: Adjust.
2669 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2671 * src/bison.simple: Update and add '%%' directives.
2673 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2675 * src/reader.c (reader): Remove calls to 'output_headers' and
2676 'output_trailers'. Remove some C output.
2677 (readgram): Disable a piece of code that was writing a default
2678 definition for 'YYSTYPE'.
2679 (reader_output_yylsp): Remove.
2680 (packsymbols): Output token defintions to a macro.
2681 (copy_definition): Disable C output.
2683 * src/reader.c (parse_macro_decl): New function used to parse macro
2685 (copy_string2): Put the body of copy_string into this new function.
2686 Add a parameter to let the caller choose whether he wants to copy the
2687 string delimiters or not.
2688 (copy_string): Be a simple call to copy_string2 with the last argument
2690 (read_declarations): Add case for macro definition.
2691 (copy_identifier): New.
2692 (parse_macro_decl): Read macro identifiers using copy_identifier
2695 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2697 * src/output.c (prepare): Add prefixed names.
2698 (output_parser): Output semantic actions.
2699 (output_parser): Fix bug on '%%line' directives.
2701 * src/output.c (output_headers): Remove. The C code printed by this
2702 function should now be in the skeletons.
2703 (output_trailers): Remove.
2704 (output): Disable call to 'reader_output_yylsp'.
2705 (output_rule_data): Do not output tables to the table obstack.
2707 * src/output.c: Remove some C dedicated output.
2708 Improve the use of macro and output obstacks.
2709 (output_defines): Remove.
2711 * src/output.c (output_token_translations): Associate 'translate'
2712 table with a macro. No output to the table obstack.
2713 (output_gram): Same for 'rhs' and 'prhs'.
2714 (output_stos): Same for 'stos'.
2715 (output_rule_data): Same for 'r1' and 'r2'.
2716 (token_actions): Same for 'defact'.
2717 (goto_actions): Same for 'defgoto'.
2718 (output_base): Same for 'pact' and 'pgoto'.
2719 (output_table): Same for 'table'.
2720 (output_check): Same for 'check'.
2722 * src/output.c (output_table_data): New function.
2723 (output_short_table): Remove.
2724 (output_short_or_char_table): Remove.
2726 * src/output.c (output_parser): Replace most of the skeleton copy code
2727 with something new. Skeletons are now processed character by character
2728 rather than line by line, and Bison looks for '%%' macros. This is the
2729 first step in making Bison's output process (a lot) more flexible.
2730 (output_parser): Use the macro table.
2732 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2734 * src/main.c (main): Initialize the macro table.
2736 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2738 * src/lex.c (percent_table): Add tok_define.
2739 * src/lex.h: Add tok_define.
2741 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2743 * src/macrotab.c: New file.
2744 * src/macrotab.h: New file.
2745 * src/Makefile.am: Update.
2747 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2749 * lib/hash.c: New file.
2750 * lib/hash.h: New file.
2751 * lib/Makefile.am: Update.
2753 2001-08-15 Akim Demaille <akim@epita.fr>
2757 2001-08-15 Marc Autret <autret_m@epita.fr>
2759 * src/reader.c (readgram): Indent output macro YYSTYPE.
2760 (packsymbols): Likewise.
2761 (output_token_defines): Likewise.
2762 * src/files.c: Standardize.
2763 (compute_header_macro): New.
2764 (defines_obstack_save): New. Use compute_header_macro.
2765 (output_files): Update. Use defines_obstack_save.
2767 2001-08-15 Akim Demaille <akim@epita.fr>
2769 * doc/bison.texinfo (Table of Symbols): Document
2772 2001-08-15 Akim Demaille <akim@epita.fr>
2774 * missing: Update from CVS Automake.
2775 * config/config.guess, config/config.sub, config/texinfo.tex:
2776 Update from gnu.org.
2778 2001-08-15 Akim Demaille <akim@epita.fr>
2780 * Makefile.maint: Sync with CVS Autoconf.
2782 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
2784 * doc/bison.texinfo: Include GNU Free Documentation License from
2786 * doc/fdl.texi: Add to package.
2788 2001-08-14 Marc Autret <autret_m@epita.fr>
2790 Turn on %{source,header}_extension features.
2792 * src/lex.c (percent_table): Un-CPP out header_extension and
2794 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
2795 (compute_exts_from_src): Remove conditions. It restores priorities
2798 2001-08-14 Marc Autret <autret_m@epita.fr>
2800 * src/files.c (compute_base_names): Add extensions computing when
2801 `--file-prefix' used.
2802 Standardize function calls.
2804 2001-08-13 Marc Autret <autret_m@epita.fr>
2806 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
2807 defining it (defined but null disables alloca).
2809 2001-08-13 Marc Autret <autret_m@epita.fr>
2811 * src/bison.simple (_yy_memcpy): CPP reformat.
2813 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
2815 * tests/atconfig.in (CPPFLAGS): Fix.
2817 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
2819 * doc/bison.texinfo: Include GNU General Public License from
2821 * doc/gpl.texi: Add to package.
2823 2001-08-10 Marc Autret <autret_m@epita.fr>
2825 * src/print_graph.h: Fix.
2826 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
2828 2001-08-10 Akim Demaille <akim@epita.fr>
2830 * src/system.h: Provide default declarations for stpcpy, strndup,
2833 2001-08-10 Robert Anisko <anisko_r@epita.fr>
2835 * doc/bison.texinfo (Locations): Update @$ stuff.
2837 2001-08-09 Robert Anisko <anisko_r@epita.fr>
2839 * src/bison.simple (YYLLOC_DEFAULT): Update.
2842 2001-08-08 Marc Autret <autret_m@epita.fr>
2844 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
2845 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
2846 Reported by Fabrice Bauzac.
2848 2001-08-08 Marc Autret <autret_m@epita.fr>
2850 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
2851 * src/vcg.c (output_node): Fix.
2852 * src/vcg.h: Cleanup.
2853 * src/print_graph.c: Add comments.
2854 (node_output_size): New global variable. Simplify the formatting of
2855 the VCG graph output.
2856 (print_actions): Unused code is now used. It notifies the final state
2857 and no action states in the VCG graph. It also give the reduce actions.
2858 The `shift and goto' edges are red and the `go to state' edges are
2860 Get the current node name and node_obstack by argument.
2861 (node_obstack): New variable.
2862 (print_state): Manage node_obstack.
2863 (print_core): Use node_obstack given by argument.
2864 A node is not only computed here but in print_actions also.
2865 (print_graph): CPP out useless code instead of commenting it.
2867 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
2869 * tests/atconfig.in (CPPFLAGS): Fix.
2871 2001-08-07 Akim Demaille <akim@epita.fr>
2873 * src/print_graph.c (quote): New.
2874 (print_core): Use it.
2876 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
2878 * src/vcg.c (complain.h): Include it.
2879 Unepitaize `return' invocations.
2880 [NDEBUG] (main): Remove.
2881 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
2882 * src/files.c (open_files): Initialize graph_obstack.
2883 * src/print_graph.c (print_actions): CPP out useless code.
2884 (print_core): Don't output the last `\n' in labels.
2886 * src/files.c (output_files): Output the VCG file.
2887 * src/main.c (main): Invoke print_graph ();
2889 2001-08-06 Marc Autret <autret_m@epita.fr>
2891 Automaton VCG graph output.
2892 Using option ``-g'' or long option ``--graph'', you can generate
2893 a gram_filename.vcg file containing a VCG description of the LALR (1)
2894 automaton of your grammar.
2896 * src/main.c: Call to print_graph() function.
2897 * src/getargs.h: Update.
2898 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
2899 (graph_flag): New flag.
2901 (getargs): Add case `g'.
2902 * src/files.c (graph_obstack): New obstack struct.
2903 (open_files): Initialize new obstack.
2904 (output_files): Saves graph_obstack if required.
2905 * src/files.h (graph_obstack): New extern declaration.
2906 * src/Makefile.am: Add new source files.
2908 2001-08-06 Marc Autret <autret_m@epita.fr>
2910 * src/print_graph.c, src/print_graph.h (graph): New.
2911 * src/vcg.h: New file.
2912 * src/vcg.c: New file, VCG graph handling.
2914 2001-08-06 Marc Autret <autret_m@epita.fr>
2916 Add of %source_extension and %header_extension which specify
2917 the source or/and the header output file extension.
2919 * src/files.c (compute_base_names): Remove initialisation of
2920 src_extension and header_extension.
2921 (compute_exts_from_gf): Update.
2922 (compute_exts_from_src): Update.
2923 (output_files): Update.
2924 * src/reader.c (parse_header_extension_decl): New.
2925 (parse_source_extension_decl): New.
2926 (read_declarations): New case statements for the new tokens.
2927 * src/lex.c (percent_table): Add entries for %source_extension
2928 and %header_extension.
2929 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
2931 2001-08-06 Marc Autret <autret_m@epita.fr>
2933 * configure.in: Bump to 1.28c.
2934 * doc/bison.texinfo: Texinfo thingies.
2936 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
2938 * tests/atconfig.in (CPPFLAGS): Add.
2939 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
2941 2001-08-03 Akim Demaille <akim@epita.fr>
2945 2001-08-03 Akim Demaille <akim@epita.fr>
2947 * tests/Makefile.am (check-local): Ship testsuite.
2948 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
2951 2001-08-03 Akim Demaille <akim@epita.fr>
2953 * configure.in: Try using -Wformat when compiling.
2955 2001-08-03 Akim Demaille <akim@epita.fr>
2957 * configure.in: Bump to 1.28b.
2959 2001-08-03 Akim Demaille <akim@epita.fr>
2961 * src/complain.c: Adjust strerror_r portability issues.
2963 2001-08-03 Akim Demaille <akim@epita.fr>
2967 2001-08-03 Akim Demaille <akim@epita.fr>
2969 * src/getargs.c, src/getarg.h (skeleton)): Constify.
2970 * src/lex.c (literalchar): Avoid name clashes on `buf'.
2971 * src/getargs.c: Include complain.h.
2972 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
2973 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
2975 2001-08-03 Akim Demaille <akim@epita.fr>
2977 * src/reader.c (readgram): Display hidden chars in error messages.
2979 2001-08-03 Akim Demaille <akim@epita.fr>
2981 Update to gettext 0.10.39.
2983 2001-08-03 Akim Demaille <akim@epita.fr>
2985 * lib/strspn.c: New.
2987 2001-08-01 Marc Autret <autret_m@epita.fr>
2989 * doc/bison.texinfo: Update.
2990 * doc/bison.1 (mandoc): Update.
2991 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
2992 * src/files.c: Support output files extensions computing.
2993 (src_extension): New static variable.
2994 (header_extension): New static variable.
2996 (get_extension_index): New function, gets the index of an extension
2997 filename in a string.
2998 (compute_exts_from_gf): New function, computes extensions from the
2999 grammar file extension.
3000 (compute_exts_from_src): New functions, computes extensions from the
3001 C source file extension, file given by ``-o'' option.
3002 (compute_base_names): Update.
3003 (output_files): Update.
3005 2001-08-01 Robert Anisko <anisko_r@epita.fr>
3007 * doc/bison.texi: Document @$.
3008 (Locations): New section.
3010 2001-07-18 Akim Demaille <akim@epita.fr>
3012 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
3013 * config/prev-version.txt, config/move-if-change: New.
3014 * Makefile.am: Adjust.
3016 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
3018 * src/bison.simple (yyparse): Suppress warning `comparaison
3019 between signed and unsigned'.
3021 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
3023 * src/getargs.h (raw_flag): Remove.
3024 * src/getargs.c: Die on `-r'/`--raw'.
3025 * src/lex.c (parse_percent_token): Die on `%raw'.
3026 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
3027 * tests/calc.at: Suppress test with option `--raw'.
3029 2001-07-14 Akim Demaille <akim@epita.fr>
3032 * configure.in: Require Autoconf 2.50.
3033 Update to gettext 0.10.38.
3035 2001-03-16 Akim Demaille <akim@epita.fr>
3037 * doc/bison.texinfo: ANSIfy the examples.
3039 2001-03-16 Akim Demaille <akim@epita.fr>
3041 * getargs.c (skeleton): New variable.
3042 (longopts): --skeleton is a new option.
3043 (shortopts, getargs): -S is a new option.
3044 * getargs.h: Declare skeleton.
3045 * output.c (output_parser): Use it.
3047 2001-03-16 Akim Demaille <akim@epita.fr>
3049 * m4/strerror_r.m4: New.
3050 * m4/error.m4: Run AC_FUNC_STRERROR_R.
3051 * lib/error.h, lib/error.c: Update.
3053 2001-03-16 Akim Demaille <akim@epita.fr>
3055 * src/getargs.c (longopts): Clean up.
3057 2001-02-21 Akim Demaille <akim@epita.fr>
3059 * src/reader.c (gensym): `gensym_count' is your own.
3060 Use a static buf to create the symbol name, as token_buffer is no
3063 2001-02-08 Akim Demaille <akim@epita.fr>
3065 * src/conflicts.c (conflict_report): Be sure not to append to res
3066 between two calls, which could happen if both first sprintf were
3067 skipped, but not the first cp += strlen.
3069 2001-02-08 Akim Demaille <akim@epita.fr>
3071 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
3072 New, from fileutils 4.0.37.
3073 * configure.in: Require Autoconf 2.49c. I took some time before
3074 making this decision. This is the only way out for portability
3075 issues in Bison, it would mean way too much duplicate effort to
3076 import in Bison features implemented in 2.49c since 2.13.
3077 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
3079 2001-02-02 Akim Demaille <akim@epita.fr>
3081 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
3082 * lib/xalloc.h, lib/xmalloc.c: Update.
3084 2001-01-19 Akim Demaille <akim@epita.fr>
3086 Get rid of the ad hoc handling of token_buffer in the scanner: use
3089 * src/lex.c (token_obstack): New.
3090 (init_lex): Initialize it. No longer call...
3091 (grow_token_buffer): this. Remove it.
3092 Adjust all the places which used it to use the obstack.
3094 2001-01-19 Akim Demaille <akim@epita.fr>
3096 * src/lex.h: Rename all the tokens:
3097 s/\bENDFILE\b/tok_eof/g;
3098 s/\bIDENTIFIER\b/tok_identifier/g;
3100 Let them be enums, not #define, to ease debugging.
3101 Adjust all the code.
3103 2001-01-18 Akim Demaille <akim@epita.fr>
3105 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
3106 * src/lex.c (maxtoken, grow_token_buffer): Static.
3108 2001-01-18 Akim Demaille <akim@epita.fr>
3110 Since we now use obstacks, more % directives can be enabled.
3112 * src/lex.c (percent_table): Also accept `%yacc',
3113 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
3115 Handle the actions for `%semantic_parser' and `%pure_parser' here,
3116 instead of returning a token.
3117 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
3118 * src/reader.c (read_declarations): Adjust.
3119 * src/files.c (open_files): Don't call `compute_base_names', don't
3120 compute `attrsfile' since they depend upon data which might be
3121 *in* the input file now.
3122 (output_files): Do it here.
3123 * src/output.c (output_headers): Document the fact that this patch
3124 introduces a guaranteed SEGV for semantic parsers.
3125 * doc/bison.texinfo: Document them.
3126 * tests/suite.at: Exercise these %options.
3128 2000-12-20 Akim Demaille <akim@epita.fr>
3130 Also handle the output file (--verbose) with obstacks.
3132 * files.c (foutput): Remove.
3133 (output_obstack): New.
3134 Adjust all dependencies.
3135 * src/conflicts.c: Return a string.
3136 * src/system.h (obstack_grow_string): Rename as...
3137 (obstack_sgrow): this. Be ready to work with non literals.
3138 (obstack_fgrow4): New.
3140 2000-12-20 Akim Demaille <akim@epita.fr>
3142 * src/files.c (open_files): Fix the computation of short_base_name
3143 in the case of `-o foo.tab.c'.
3145 2000-12-20 Akim Demaille <akim@epita.fr>
3147 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
3148 (copy_dollar): Now that everything uses obstacks, get rid of the
3151 2000-12-20 Akim Demaille <akim@epita.fr>
3153 * src/files.c (open_files): Actually the `.output' file is based
3154 on the short_base_name, not base_name.
3155 * tests/suite.at (Checking output file names): Adjust.
3157 2000-12-20 Akim Demaille <akim@epita.fr>
3159 * src/bison.s1: Remove, we now use directly...
3160 * src/bison.simple: this.
3161 * src/Makefile.am: Use pkgdata instead of data.
3163 2000-12-20 Akim Demaille <akim@epita.fr>
3165 * src/files.c (guard_obstack): New.
3166 (open_files): Initialize it.
3167 (output_files): Dump it...
3168 * src/files.h: Export it.
3169 * src/reader.c (copy_guard): Use it.
3171 2000-12-19 Akim Demaille <akim@epita.fr>
3173 * src/files.c (outfile, defsfile, actfile): Removed as global
3175 (open_files): Don't compute them.
3176 (output_files): Adjust.
3177 (base_name, short_base_name): Be global.
3178 Adjust dependencies.
3180 2000-12-19 Akim Demaille <akim@epita.fr>
3182 * src/files.c (strsuffix): New.
3183 (stringappend): Be just like strcat but allocate.
3184 (base_names): Eve out from open_files.
3185 Try to simplify the rather hairy computation of base_name and
3187 (open_files): Use it.
3188 * tests/suite.at (Checking output file names): New test.
3190 2000-12-19 Akim Demaille <akim@epita.fr>
3192 * src/system.h (obstack_grow_literal_string): Rename as...
3193 (obstack_grow_string): this.
3194 * src/output.c (output_parser): Recognize `%% actions' instead of
3196 * src/bison.s1: s/$/%% actions/.
3197 * src/bison.hairy: Likewise.
3199 2000-12-19 Akim Demaille <akim@epita.fr>
3201 * src/output.c (output_parser): Compute the `#line' lines when
3203 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
3204 Suggested by Hans Aberg.
3206 2000-12-19 Akim Demaille <akim@epita.fr>
3208 Let the handling of the skeleton files be local to the procedures
3211 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
3213 (fparser, open_extra_files): Remove.
3214 (open_files, output_files): Don't take care of fparser.
3215 * src/files.h: Adjust.
3216 * src/output.c (output_parser): Open and close the file to the
3218 * src/reader.c (read_declarations): When %semantic_parser, open
3221 2000-12-19 Akim Demaille <akim@epita.fr>
3223 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
3224 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
3226 2000-12-19 Akim Demaille <akim@epita.fr>
3228 * src/files.c (open_files): Yipee! We no longer need all the code
3229 looking for `/tmp' since we have no tmp file.
3231 2000-12-19 Akim Demaille <akim@epita.fr>
3233 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
3235 * src/files.c (open_files): Less dependency on MSDOS etc.
3237 2000-12-14 Akim Demaille <akim@epita.fr>
3239 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
3240 Provide a default definition.
3241 Use it when executing the default @ action.
3242 * src/reader.c (reader_output_yylsp): No longer include
3243 `timestamp' and `text' in the default YYLTYPE.
3245 2000-12-12 Akim Demaille <akim@epita.fr>
3247 * src/reader.c (copy_definition, parse_union_decl, copy_action)
3248 (copy_guard): Quote the file names.
3249 Reported by Laurent Mascherpa.
3251 2000-12-12 Akim Demaille <akim@epita.fr>
3253 * src/output.c (output_headers, output_program, output): Be sure
3254 to escape special characters when outputting filenames.
3255 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
3256 (output_headers): Don't depend on them, Use ACTSTR.
3258 2000-11-17 Akim Demaille <akim@epita.fr>
3260 * lib/obstack.h: Formatting changes.
3261 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
3262 prevents type checking.
3263 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
3264 cast the value to (void *): assigning a `foo *' to a `void *'
3266 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
3267 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
3270 2000-11-17 Akim Demaille <akim@epita.fr>
3272 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
3274 (suite.m4, regression.m4, calc.m4): these.
3275 * tests/atgeneral.m4: Update from CVS Autoconf.
3277 2000-11-17 Akim Demaille <akim@epita.fr>
3279 * tests/regression.m4 (%union and --defines): New test,
3280 demonstrating a current bug in the obstack implementation.
3282 2000-11-17 Akim Demaille <akim@epita.fr>
3284 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
3286 Use them to declare the variables which are global or local to
3289 2000-11-17 Akim Demaille <akim@epita.fr>
3291 * acconfig.h: Remove, no longer used.
3293 2000-11-07 Akim Demaille <akim@epita.fr>
3295 * src: s/Copyright (C)/Copyright/g.
3297 2000-11-07 Akim Demaille <akim@epita.fr>
3299 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
3301 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
3303 2000-11-07 Akim Demaille <akim@epita.fr>
3305 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
3306 Merge in a single CPP if/else.
3308 2000-11-07 Akim Demaille <akim@epita.fr>
3310 * src/output.c (output): Remove useless variables.
3311 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
3312 argument `data' for consistency with the prototypes.
3314 (obstack_copy, obstack_copy0): Rename the second argument as
3315 `address' for consistency. Qualify it `const'.
3316 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
3317 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
3318 `const' their input argument (`data' or `address').
3319 Adjust the corresponding macros to include `const' in casts.
3321 2000-11-03 Akim Demaille <akim@epita.fr>
3323 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
3324 s/PFILE1/BISON_HAIRY/.
3325 Adjust dependencies.
3327 2000-11-03 Akim Demaille <akim@epita.fr>
3329 For some reason, this was not applied.
3331 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
3332 `unlink': it's no longer used.
3334 2000-11-03 Akim Demaille <akim@epita.fr>
3336 * src/files.c (skeleton_find): New function, eved out of...
3337 (open_files, open_extra_files): here.
3339 2000-11-03 Akim Demaille <akim@epita.fr>
3343 * src/files.c (obstack_save): New function.
3344 (done): Rename as...
3345 (output_files): this.
3347 * src/main.c (main): Don't use `atexit' to register `done', since
3348 it no longer has to remove tmp files, just call `output_files'
3349 when there are no errors.
3351 2000-11-02 Akim Demaille <akim@epita.fr>
3353 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
3354 `unlink': it's no longer used.
3355 * src/files.h: Formatting changes.
3357 2000-11-02 Akim Demaille <akim@epita.fr>
3359 Remove the last uses of mktemp and unlink/delete.
3361 * src/files.c (fdefines, ftable): Removed.
3362 (defines_ostack, table_obstack): New.
3363 Adjust dependencies of the former into uses of the latter.
3364 * src/output.c (output_short_or_char_table, output_short_table):
3365 Convert to using obstacks.
3366 * src/reader.c (copy_comment2): Accept one FILE * and two
3368 (output_token_defines, reader_output_yylsp): Use obstacks.
3369 * src/system.h (obstack_fgrow3): New.
3371 2000-11-01 Akim Demaille <akim@epita.fr>
3373 Change each use of `fattrs' into a use of `attrs_obstack'.
3375 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
3376 * src/files.c (fattrs): Remove.
3377 (attrs_obstack): New.
3378 Adjust all dependencies.
3379 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
3381 2000-11-01 Akim Demaille <akim@epita.fr>
3384 Change each use of `faction' into a use of `action_obstack'.
3386 * lib/obstack.h, lib/obstack.c: New files.
3387 * src/files.c (faction): Remove.
3388 (action_obstack): New.
3389 Adjust all dependencies.
3391 2000-10-20 Akim Demaille <akim@epita.fr>
3393 * lib/quote.h (PARAMS): New macro. Use it.
3395 2000-10-16 Akim Demaille <akim@epita.fr>
3397 * src/output.c (output_short_or_char_table): New function.
3398 (output_short_table, output_token_translations): Use it.
3399 (goto_actions): Use output_short_table.
3401 2000-10-16 Akim Demaille <akim@epita.fr>
3403 * src/symtab.c (bucket_new): New function.
3406 * src/output.c (output_short_table): New argument to display the
3407 comment associated with the table.
3408 Adjust dependencies.
3409 (output_gram): Use it.
3410 (output_rule_data): Nicer output layout for YYTNAME.
3412 2000-10-16 Akim Demaille <akim@epita.fr>
3414 * src/lex.c (read_typename): New function.
3416 * src/reader.c (copy_dollar): Likewise.
3418 2000-10-16 Akim Demaille <akim@epita.fr>
3420 * src/reader.c (copy_comment2): Expect the input stream to be on
3421 the `/' which is suspected to open a comment, instead of being
3422 called after `//' or `/*' was read.
3423 (copy_comment, copy_definition, parse_union_decl, copy_action)
3424 (copy_guard): Adjust.
3426 2000-10-16 Akim Demaille <akim@epita.fr>
3428 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
3429 `read_signed_integer'.
3431 2000-10-16 Akim Demaille <akim@epita.fr>
3433 * src/reader.c (copy_dollar): New function.
3434 (copy_guard, copy_action): Use it.
3436 2000-10-16 Akim Demaille <akim@epita.fr>
3438 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
3439 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
3440 New files, from Fileutils 4.0.27.
3441 * src/main.c (printable_version): Remove.
3442 * src/lex.c, src/reader.c: Use `quote'.
3444 2000-10-04 Akim Demaille <akim@epita.fr>
3446 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
3448 2000-10-04 Akim Demaille <akim@epita.fr>
3450 * doc/bison.texinfo: Various typos spotted by Neil Booth.
3452 2000-10-04 Akim Demaille <akim@epita.fr>
3454 When a literal string is used to define two different tokens,
3455 `bison -v' segfaults.
3456 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
3458 * tests/regression.m4: New file.
3459 Include the core of the sample provided by Piotr Gackiewicz.
3460 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
3463 2000-10-04 Akim Demaille <akim@epita.fr>
3465 * src/reader.c (parse_expect_decl): Keep `count' within the size
3469 2000-10-02 Paul Eggert <eggert@twinsun.com>
3471 * bison.s1 (yyparse): Assign the default value
3472 unconditionally, to avoid a GCC warning and make the parser a
3475 2000-10-02 Akim Demaille <akim@epita.fr>
3477 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
3480 2000-10-02 Akim Demaille <akim@epita.fr>
3482 * src/derives.c, src/print.c, src/reduce.c: To ease the
3483 translation, move some `\n' out of the translated strings.
3485 2000-10-02 Akim Demaille <akim@epita.fr>
3487 The location tracking mechanism is precious for parse error
3488 messages. Nevertheless, it is enabled only when `@n' is used in
3489 the grammar, which is a different issue (you can use it in error
3490 message, but not in the grammar per se). Therefore, there should
3491 be another means to enable it.
3493 * src/getargs.c (getargs): Support `--locations'.
3495 * src/getargs.h (locationsflag): Export it.
3496 * src/lex.c (percent_table): Support `%locations'.
3497 * src/reader.c (yylsp_needed): Remove this variable, now replaced
3498 with `locationsflag'.
3499 * doc/bison.texinfo: Document `--locations' and `%locations'.
3501 * tests/calc.m4: Test it.
3503 For regularity of the names, replace each
3504 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
3505 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
3506 In addition replace each `flag' with `_flag'.
3508 2000-10-02 Akim Demaille <akim@epita.fr>
3510 Also test parse error messages, including with YYERROR_VERBOSE.
3512 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
3514 Use it to check the computations.
3515 Use it to check `nonassoc' is honored.
3516 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
3517 `--yyerror-verbose'.
3518 (_AT_CHECK_CALC): Adjust to this option.
3519 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
3521 2000-10-02 Akim Demaille <akim@epita.fr>
3523 Test also `--verbose', `--defines' and `--name-prefix'. Testing
3524 the latter demonstrates a flaw in the handling of non debugging
3525 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
3526 was used in order to simplify:
3542 unfortunately this leads to a CPP conflict when
3543 `--name-prefix=foo' is used since it produces `#define yydebug
3546 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
3547 (YYDPRINTF): New macro.
3549 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
3551 Also test `--verbose', `--defines' and `--name-prefix'.
3553 2000-10-02 Akim Demaille <akim@epita.fr>
3555 Improve the readability of the produced parsers.
3557 * src/bison.s1: Formatting changes.
3558 Improve the comment related to the `$' mark.
3559 (yydefault): Don't fall through to `yyresume': `goto' there.
3560 * src/output.c (output_parser): When the `$' is met, skip the end
3562 New variable, `number_of_dollar_signs', to check there's exactly
3563 one `$' in the parser skeleton.
3565 2000-10-02 Akim Demaille <akim@epita.fr>
3567 * lib/xstrdup.c: New file, from the fileutils.
3568 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
3569 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
3570 instead of strlen + xmalloc + strcpy.
3571 * src/symtab.c (copys): Remove, use xstrdup instead.
3573 2000-10-02 Akim Demaille <akim@epita.fr>
3575 * src/gram.h (associativity): New enum type which replaces the
3576 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
3577 `right_assoc', `left_assoc' and `non_assoc'.
3578 Adjust all dependencies.
3579 * src/reader.c: Formatting changes.
3580 (LTYPESTR): Don't define it, use it as a literal in
3581 `reader_output_yylsp'.
3582 * src/symtab.h (symbol_class): New enum type which replaces the
3583 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
3584 `sunknown', `stoken and `snterm'.
3586 2000-10-02 Akim Demaille <akim@epita.fr>
3588 * src/getargs.c (fixed_outfiles): Rename as...
3589 (yaccflag): for consistency and accuracy.
3590 Adjust dependencies.
3592 2000-10-02 Akim Demaille <akim@epita.fr>
3594 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
3595 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
3596 difficult and introduced a lot of core dump. It turns out that
3597 Bison used an implementation of `xmalloc' based on `calloc', and
3598 at various places it does depend upon the initialization to 0. I
3599 have not tried to isolate the pertinent places, and all the former
3600 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
3601 someone should address this issue.
3603 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
3604 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
3606 Adjust dependencies.
3607 * src/warshall.h: New file.
3610 2000-10-02 Akim Demaille <akim@epita.fr>
3612 Various anti-`extern in *.c' changes.
3614 * src/system.h: Include `assert.h'.
3616 2000-10-02 Akim Demaille <akim@epita.fr>
3618 * src/state.h (nstates, final_state, first_state, first_shift)
3619 (first_reduction): Move their exportation from here...
3620 * src/LR0.h: to here.
3621 Adjust dependencies.
3622 * src/getargs.c (statisticsflag): New variable.
3623 Add support for `--statistics'.
3624 Adjust dependencies.
3626 Remove a lot of now useless `extern' statements in most files.
3628 2000-10-02 Akim Demaille <akim@epita.fr>
3630 * src/LR0.h: New file.
3633 2000-10-02 Akim Demaille <akim@epita.fr>
3635 * src/print.h: New file.
3637 * src/print.c: Formatting and ordering changes.
3638 (verbose, terse): Replace with...
3639 (print_results): this new function.
3640 Adjust dependencies.
3642 2000-10-02 Akim Demaille <akim@epita.fr>
3644 * src/conflicts.c (conflict_report): New function.
3645 (conflict_log, verbose_conflict_log): Replace with...
3646 (print_conflicts): this function.
3647 Adjust dependencies.
3648 * src/conflicts.h: New file.
3649 Propagate its inclusion.
3651 2000-10-02 Akim Demaille <akim@epita.fr>
3653 * src/nullable.h: New file.
3654 Propagate its inclusion.
3655 * src/nullable.c: Formatting changes.
3657 2000-10-02 Akim Demaille <akim@epita.fr>
3659 * src/reduce.h: New file.
3660 Propagate its inclusion.
3661 * src/reduce.c: Topological sort and other formatting changes.
3662 (bool, TRUE, FALSE): Move their definition to...
3663 * src/system.h: here.
3665 2000-10-02 Akim Demaille <akim@epita.fr>
3667 * src/files.c: Formatting changes.
3668 (tryopen, tryclose, openfiles): Rename as...
3669 (xfopen, xfclose, open_files): this.
3670 (stringappend): static.
3671 * src/files.h: Complete the list of exported symbols.
3674 2000-10-02 Akim Demaille <akim@epita.fr>
3676 * src/reader.h: New file.
3677 Propagate its use instead of tedious list of `extern' and
3679 * src/reader.c: Formatting changes, topological sort,
3682 2000-10-02 Akim Demaille <akim@epita.fr>
3684 * src/lex.h: Prototype `lex.c' exported functions.
3685 * src/reader.c: Adjust.
3686 * src/lex.c: Formatting changes.
3687 (safegetc): Rename as...
3690 2000-10-02 Akim Demaille <akim@epita.fr>
3692 * src/lalr.h: New file.
3693 Propagate its inclusion instead of prototypes and `extern'.
3694 * src/lalr.c: Formatting changes, topological sorting etc.
3696 2000-10-02 Akim Demaille <akim@epita.fr>
3698 * src/output.c (token_actions): Introduce a temporary array,
3699 YYDEFACT, that makes it possible for this function to use
3702 2000-10-02 Akim Demaille <akim@epita.fr>
3704 `user_toknums' is output as a `short[]' in `output.c', while it is
3705 defined as a `int[]' in `reader.c'. For consistency with the
3706 other output tables, `user_toknums' is now defined as a table of
3709 * src/reader.c (user_toknums): Be a short table instead of an int
3711 Adjust dependencies.
3713 Factor the short table outputs.
3715 * src/output.c (output_short_table): New function.
3716 * src/output.c (output_gram, output_stos, output_rule_data)
3717 (output_base, output_table, output_check): Use it.
3719 2000-10-02 Akim Demaille <akim@epita.fr>
3721 * src/output.c (output): Topological sort of the functions, in
3722 order to get rid of the `static' prototypes.
3723 No longer use `register'.
3724 * src/output.h: New file.
3725 Propagate its inclusion in files explicitly prototyping functions
3728 2000-09-21 Akim Demaille <akim@epita.fr>
3730 * src/atgeneral.m4: Update from Autoconf.
3732 2000-09-21 Akim Demaille <akim@epita.fr>
3734 * src/closure.h: New file.
3735 * src/closure.c: Formatting changes, topological sort over the
3736 functions, use of closure.h.
3737 (initialize_closure, finalize_closure): Rename as...
3738 (new_closure, free_closure): these. Adjust dependencies.
3739 * src/LR0.c: Formatting changes, topological sort, use of
3741 (initialize_states): Rename as...
3743 * src/Makefile.am (noinst_HEADERS): Adjust.
3745 2000-09-20 Akim Demaille <akim@epita.fr>
3747 * src/acconfig.h: Don't protect config.h against multiple
3749 Don't define PARAMS.
3750 * src/system.h: Define PARAMS.
3751 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
3752 purpose of config.h. system.h must not try to fix wrong
3753 definitions in config.h.
3755 2000-09-20 Akim Demaille <akim@epita.fr>
3757 * src/derives.h: New file.
3758 * src/main.c, src/derives.h: Use it.
3760 * src/Makefile.am (noinst_HEADERS): Adjust.
3762 2000-09-20 Akim Demaille <akim@epita.fr>
3764 * tests/atgeneral.m4: Update from Autoconf.
3765 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
3766 (AT_CHECK_CALC): New macros.
3767 Use these macros to test bison with options `', `--raw',
3768 `--debug', `--yacc', `--yacc --debug'.
3770 2000-09-19 Akim Demaille <akim@epita.fr>
3772 * src/output.c: Formatting changes.
3773 * src/machine.h: Remove, leaving its contents in...
3774 * src/system.h: here.
3776 Adjust all dependencies on stdio.h and machine.h.
3777 * src/getargs.h: New file.
3778 Let all `extern' declarations about getargs.c be replaced with
3779 inclusion of `getargs.h'.
3780 * src/Makefile.am (noinst_HEADERS): Adjust.
3782 * tests/calc.m4 (yyin): Be initialized in main, not on the global
3784 (yyerror): Returns void, not int.
3785 * doc/bison.texinfo: Formatting changes.
3787 2000-09-19 Akim Demaille <akim@epita.fr>
3789 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
3792 2000-09-18 Akim Demaille <akim@epita.fr>
3794 * configure.in: Append WARNING_CFLAGS to CFLAGS.
3795 * src/Makefile.am (INCLUDES): Don't.
3796 Be ready to fetch headers in lib/.
3798 2000-09-18 Akim Demaille <akim@epita.fr>
3800 * doc/bison.texinfo: Update the copyright.
3801 ANSIfy and GNUify the examples.
3802 Remove the old menu.
3804 2000-09-18 Akim Demaille <akim@epita.fr>
3806 First set of tests: use the `calc' example from the documentation.
3808 * src/bison.s1 (yyparse): Condition the code using `yytname' which
3809 is defined only when YYDEBUG is.
3810 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
3811 * src/files.c (tryopen, tryclose): Formatting changes.
3812 Move to the top and be static.
3813 * src/reader.c (read_signed_integer): Likewise.
3814 * tests/calc.m4: New file.
3815 * Makefile.am, suite.m4: Adjust.
3816 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
3818 2000-09-18 Akim Demaille <akim@epita.fr>
3820 Add support for an Autotest test suite for Bison.
3822 * m4/m4.m4, m4/atconfig.m4: New files.
3823 * m4/Makefile.am (EXTRA_DIST): Adjust.
3824 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
3826 * src/getargs.c: Display a more standard --version message.
3827 * src/reader.c (reader): Formatting changes.
3828 No longer depend upon VERSION_STRING.
3829 * configure.in: No longer use `dnl'.
3830 Set up the test suite and the new directory `tests/.
3831 (VERSION_STRING): Remove.
3833 2000-04-14 Akim Demaille <akim@epita.fr>
3835 * src/reader.c (copy_comment2): New function, same as former
3836 `copy_comment', but outputs into two FILE *.
3837 (copy_comment): Use it.
3838 (parse_union_decl): Use it.
3839 (get_type, parse_start_decl): Use the same `invalid' message.
3840 (parse_start_decl, parse_union_decl): Use the same `multiple'
3842 (parse_union_decl, copy_guard, copy_action): Use the same
3843 `unmatched' message.
3844 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
3846 2000-03-31 Akim Demaille <akim@epita.fr>
3848 * src/files.c (tryopen, tryclose): Move to the top.
3851 2000-03-31 Akim Demaille <akim@epita.fr>
3853 * src/main.c (main): Don't call `done', exit does it.
3855 2000-03-31 Akim Demaille <akim@epita.fr>
3857 * allocate.c: s/return (foo)/return foo/.
3860 * output.c: Likewise.
3861 * reader.c: Likewise.
3862 * symtab.c: Likewise.
3863 * vmsgetargs.c: Likewise.
3865 2000-03-31 Akim Demaille <akim@epita.fr>
3867 Clean up the error reporting functions.
3869 * src/report.c: New file.
3870 * src/report.h: Likewise.
3871 * src/Makefile.am: Adjust.
3872 * m4/error.m4: New file.
3873 * m4/Makefile.am: Adjust.
3874 * configure.in (jm_PREREQ_ERROR): Call it.
3875 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
3877 (fatal, fatals): Remove. All callers use complain.c::fatal.
3878 (warn, warni, warns, warnss, warnss): Remove. All callers use
3879 complain.c::complain.
3880 (toomany): Remove, use fatal instead.
3881 * src/files.c (done): No argument, use complain_message_count.
3882 * src/main.c (main): Register `done' to `atexit'.
3884 * src/getargs.c (usage): More `fputs', less `fprintf'.
3886 2000-03-28 Akim Demaille <akim@epita.fr>
3888 * lib/: New directory.
3889 * Makefile.am (SUBDIRS): Adjust.
3890 * configure.in: Adjust.
3891 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
3893 * src/alloca.c: Moved to lib/.
3894 * src/getopt.c: Likewise.
3895 * src/getopt1.c: Likewise.
3896 * src/getopt.h: Likewise.
3897 * src/ansi2knr.c: Likewise.
3898 * src/ansi2knr.1: Likewise.
3899 * src/Makefile.am: Adjust.
3900 * lib/Makefile.am: New file.
3902 2000-03-28 Akim Demaille <akim@epita.fr>
3904 * src/getargs.c (usage): Refresh the help message.
3906 2000-03-17 Akim Demaille <akim@epita.fr>
3908 * src/getopt1.c: Updated from textutils 2.0e
3909 * src/getopt.c: Likewise.
3910 * src/getopt.h: Likewise.
3912 2000-03-17 Akim Demaille <akim@epita.fr>
3914 * src/Makefile.am (bison.simple): Fix the awk program: quote only
3915 the file name, not the whole `#line LINE FILE'.
3917 2000-03-17 Akim Demaille <akim@epita.fr>
3919 On syntax errors, report the token on which we choked.
3921 * src/bison.s1 (yyparse): In the label yyerrlab, when
3922 YYERROR_VERBOSE, add yychar in msg.
3924 2000-03-17 Akim Demaille <akim@epita.fr>
3926 * src/reader.c (copy_at): New function.
3927 (copy_guard): Use it.
3928 (copy_action): Use it.
3930 2000-03-17 Akim Demaille <akim@epita.fr>
3932 Be kind to translators, save some useless translations.
3934 * src/main.c (banner): New function.
3935 (fatal_banner): Use it.
3936 (warn_banner): Use it.
3938 2000-03-17 Akim Demaille <akim@epita.fr>
3940 * src/reader.c (copy_definition): Use copy_string and
3941 copy_comment. Removed now unused `match', `ended',
3943 (copy_comment, copy_string): Moved, to be visible from
3946 2000-03-17 Akim Demaille <akim@epita.fr>
3948 * src/reader.c (copy_string): Declare `static inline'. No
3949 problems with inline, since it is checked by configure.
3950 (copy_comment): Likewise.
3952 2000-03-17 Akim Demaille <akim@epita.fr>
3954 * src/reader.c (packsymbols): Formatting changes.
3956 2000-03-17 Akim Demaille <akim@epita.fr>
3958 * src/reader.c (copy_comment): New function, factored out from:
3959 (copy_action): Use it. Removed now unused `match', `ended',
3961 (copy_guard): Likewise.
3963 2000-03-17 Akim Demaille <akim@epita.fr>
3965 * src/reader.c (copy_string): New function, factored out from:
3966 (copy_action): Use it.
3967 (copy_guard): Likewise.
3969 2000-03-17 Akim Demaille <akim@epita.fr>
3971 Change the handling of @s so that they behave exactly like $s.
3972 There is now a pseudo variable @$ (readble and writable), location
3973 of the lhs of the rule (by default ranging from the location of
3974 the first symbol of the rhs, to the location of the last symbol,
3975 or, if the rhs is empty, YYLLOC).
3977 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
3979 (yyparse): When providing a default semantic action, provide a
3980 default location action.
3981 (after the $): No longer change `*YYLSP', just stack YYLOC the
3982 same way you stack YYVAL.
3983 * src/reader.c (read_declarations): Use warns.
3984 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
3985 (copy_action, case '@'): Likewise.
3986 Use a standard error message, to save useless work from
3989 2000-03-17 Akim Demaille <akim@epita.fr>
3991 * src/bison.s1: Formatting and cosmetics changes.
3992 * src/reader.c: Likewise.
3993 Update the Copyright notice.
3995 2000-03-17 Akim Demaille <akim@epita.fr>
3997 * src/bison.s1 (#line): All set to `#line' only, since the
3998 Makefile now handles them.
4000 2000-03-16 Akim Demaille <akim@epita.fr>
4002 * src/output.c (output_rule_data): Output the documentation of
4004 (Copyright notice): Update.
4007 2000-03-16 Akim Demaille <akim@epita.fr>
4009 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
4010 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
4011 One `#if YYDEBUG' remains, since it uses variables which are
4012 defined only if `YYDEBUG != 0'.
4014 2000-03-16 Akim Demaille <akim@epita.fr>
4016 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
4017 and related variables so that the similarities are highlighted.
4019 2000-03-16 Akim Demaille <akim@epita.fr>
4021 * src/bison.s1: Properly indent CPP directives.
4023 2000-03-16 Akim Demaille <akim@epita.fr>
4025 * src/bison.s1: Properly indent the `alloca' CPP section.
4027 2000-03-16 Akim Demaille <akim@epita.fr>
4029 Do not hard code values of directories in `configure.in'.
4030 Update the `configure' tool chain.
4032 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
4034 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
4035 (AC_OUTPUT): Add m4/Makefile.
4036 Bump to bison 1.28a, 1.29 has never been released.
4037 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
4038 handled via src/Makefile.am.
4039 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
4040 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
4042 * Makefile.am (SUBDIRS): Add m4.
4043 (ACLOCAL_AM_FLAGS): New variable.
4044 (AUTOMAKE_OPTIONS): Add check-news.
4045 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
4046 the proper line number and file name.
4047 (DEFS): Propagate the location of bison library files and of the
4049 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
4051 * acinclude.m4: Remove, replaced by the directory m4.
4052 * m4/Makefile.am (EXTRA_DIST): New variable.
4053 * m4/gettext.m4: New file, from the fileutils.
4054 * m4/lcmessage.m4: Likewise
4055 * m4/progtest.m4: Likewise.
4056 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
4058 2000-03-10 Akim Demaille <akim@epita.fr>
4061 Formatting changes of various comments.
4062 Respect the GNU coding standards at various places.
4063 Don't use `_()' when no translation is needed.
4065 1999-12-13 Jesse Thilo <jthilo@gnu.org>
4068 OS/2 honors TMPDIR environment variable.
4070 1999-12-13 Jesse Thilo <jthilo@gnu.org>
4072 * doc/bison.texinfo: Tweaked spelling and grammar.
4074 Removed reference to price of printed copy.
4075 Mention BISON_SIMPLE and BISON_HAIRY.
4077 1999-12-13 Jesse Thilo <jthilo@gnu.org>
4079 * configure.in, NEWS:
4080 Bison 1.29 released.
4082 1999-10-27 Jesse Thilo <jthilo@gnu.org>
4084 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
4085 Added reference card.
4087 1999-07-26 Jesse Thilo <jthilo@gnu.org>
4089 * po/ru.po: Added Russian translation.
4091 1999-07-26 Jesse Thilo <jthilo@gnu.org>
4093 * configure.in: Added Russian translation.
4095 1999-07-06 Jesse Thilo <jthilo@gnu.org>
4097 * configure.in, NEWS, README:
4098 Released version 1.28.
4100 1999-06-14 Jesse Thilo <jthilo@gnu.org>
4103 Squashed redefinition warning on some systems.
4105 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
4106 Have configure build version string instead of relying on ANSI string
4109 1999-06-14 Jesse Thilo <jthilo@gnu.org>
4111 * po/POTFILES.in: Got rid of version.c.
4113 1999-06-14 Jesse Thilo <jthilo@gnu.org>
4115 * acconfig.h, configure.in:
4116 Have configure build version string instead of relying on ANSI string
4119 1999-06-08 Jesse Thilo <jthilo@gnu.org>
4122 Dropped mention of `+' for long-named options.
4124 1999-05-30 Jesse Thilo <jthilo@gnu.org>
4126 * src/files.c: Added <unistd.h> for unlink().
4128 * src/Makefile.am, src/system.h:
4131 1999-05-30 Jesse Thilo <jthilo@gnu.org>
4133 * README: Added a FAQ list.
4135 * configure.in, acconfig.h:
4138 1999-05-30 Jesse Thilo <jthilo@gnu.org>
4140 * doc/FAQ, doc/Makefile.am:
4143 1999-05-19 Jesse Thilo <jthilo@gnu.org>
4145 * src/alloc.h, src/symtab.h, src/version.c:
4146 Protected inclusion of "config.h" with HAVE_CONFIG_H.
4148 1999-04-18 Jesse Thilo <jthilo@gnu.org>
4150 * src/.cvsignore, src/Makefile.am:
4151 Reorganized: sources in `src', documentation in `doc'.
4153 * src/lex.c (literalchar):
4154 fixed the code for escaping double quotes (thanks
4157 1999-04-18 Jesse Thilo <jthilo@gnu.org>
4159 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
4160 Adjusted paths to reflect directory reorganization.
4162 1999-04-18 Jesse Thilo <jthilo@gnu.org>
4164 * doc/.cvsignore, doc/Makefile.am:
4165 Reorganized: sources in `src', documentation in `doc'.
4167 1999-04-18 Jesse Thilo <jthilo@gnu.org>
4170 Updated AC_INIT file to reflect directory reorganization.
4172 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
4173 Reorganized: sources in `src', documentation in `doc'.
4175 1999-04-13 Jesse Thilo <jthilo@gnu.org>
4178 Don't declare calloc() and realloc() if not necessary.
4180 1999-04-13 Jesse Thilo <jthilo@gnu.org>
4182 * configure.in, acconfig.h, acinclude.m4:
4183 Don't declare calloc() and realloc() if not necessary.
4185 1999-03-23 Jesse Thilo <jthilo@gnu.org>
4187 * po/.cvsignore: Added i18n support.
4189 1999-03-23 Jesse Thilo <jthilo@gnu.org>
4191 * acconfig.h, configure.in, Makefile.am:
4194 1999-03-22 Jesse Thilo <jthilo@gnu.org>
4196 * src/bison.s1: Fixed #line numbers.
4198 1999-03-15 Jesse Thilo <jthilo@gnu.org>
4200 * po/es.po, po/fr.po, po/nl.po, po/de.po:
4201 Added PO files from Translation Project.
4203 1999-03-03 Jesse Thilo <jthilo@gnu.org>
4206 Added support for non-ANSI compilers (ansi2knr).
4208 1999-02-16 Jesse Thilo <jthilo@gnu.org>
4210 * configure.in: Bumped version number to 1.27.
4213 Added `bison.simple' to list of files removed by `make distclean'.
4215 1999-02-12 Jesse Thilo <jthilo@gnu.org>
4217 * src/files.c, src/files.h:
4218 Defined locations of parser files in config.h instead of Makefile.
4220 1999-02-12 Jesse Thilo <jthilo@gnu.org>
4222 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
4223 Defined locations of parser files in config.h instead of Makefile.
4225 1999-02-09 Jesse Thilo <jthilo@gnu.org>
4228 Removed inappropriate use of $< macro.
4230 1999-02-05 Jesse Thilo <jthilo@gnu.org>
4232 * po/Makefile.in.in, po/POTFILES.in:
4233 Add `po' directory skeleton.
4235 1999-01-27 Jesse Thilo <jthilo@gnu.org>
4237 * README: Document help-bison list.
4239 * configure.in: Add check for mkstemp().
4241 1999-01-20 Jesse Thilo <jthilo@gnu.org>
4243 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
4244 Hush a few compiler warnings.
4247 Add tryclose(), which verifies that fclose was successful.
4248 Hush a couple of compiler warnings.
4250 1999-01-20 Jesse Thilo <jthilo@gnu.org>
4252 * Makefile.am, OChangeLog:
4253 ChangeLog is now automatically generated. Include the old version as
4256 1999-01-14 Jesse Thilo <jthilo@gnu.org>
4258 * src/gram.h, src/lalr.c, src/lex.c, src/lex.h, src/machine.h, src/main.c, src/nullable.c, src/output.c, src/print.c, src/reader.c, src/reduce.c, src/state.h, src/symtab.c, src/symtab.h, src/types.h, src/vmsgetargs.c, src/warshall.c, src/allocate.c, src/alloc.h, src/bison.s1, src/closure.c, src/conflicts.c, src/derives.c, src/files.c, src/files.h, src/getargs.c, src/gram.c, src/LR0.c:
4261 1999-01-14 Jesse Thilo <jthilo@gnu.org>
4263 * doc/bison.texinfo: Fix formatting glitch.
4265 * doc/bison.texinfo: Update FSF address.
4267 1999-01-14 Jesse Thilo <jthilo@gnu.org>
4269 * acconfig.h: Update FSF address.
4271 1999-01-08 Jesse Thilo <jthilo@gnu.org>
4274 Don't define PACKAGE here, since config.h defines it.
4276 1998-12-30 Jesse Thilo <jthilo@gnu.org>
4278 * src/reader.c: Update copyright date.
4281 Ditch sprintf to statically-sized buffers in fatal/warn functions in
4282 favor of output directly to stderr (avoids buffer overruns).
4284 * src/reader.c: Some checks for premature EOF.
4286 * src/allocate.c, src/alloc.h, src/closure.c, src/conflicts.c, src/derives.c, src/getargs.c, src/gram.c, src/lalr.c, src/lex.c, src/LR0.c, src/main.c, src/nullable.c, src/output.c, src/print.c, src/reduce.c, src/symtab.c, src/symtab.h, src/warshall.c:
4287 Use prototypes if the compiler understands them.
4289 * src/files.c: Honor TMPDIR on Unix hosts.
4290 Use prototypes if the compiler understands them.
4293 Fix a couple of buffer overrun bugs.
4294 Use prototypes if the compiler understands them.
4296 * src/system.h: Include unistd.h and ctype.h.
4297 Use #ifdef instead of #if for NLS symbols.
4299 1998-12-30 Jesse Thilo <jthilo@gnu.org>
4301 * doc/bison.texinfo:
4302 Delete comment "consider using @set for edition number, etc..." since
4303 we now are doing so.
4305 1998-12-30 Jesse Thilo <jthilo@gnu.org>
4308 Use prototypes if the compiler understands them.
4310 * NEWS: Document 1.26 highlights.
4312 * Makefile.am: Require Automake 1.3 or later.
4315 Use prototypes if the compiler understands them.
4317 1998-12-29 Jesse Thilo <jthilo@gnu.org>
4320 Use VERSION symbol from automake for version number.
4322 1998-12-29 Jesse Thilo <jthilo@gnu.org>
4324 * acconfig.h, configure.in, version.cin:
4325 Use VERSION symbol from automake for version number.
4327 1998-11-28 Jesse Thilo <jthilo@gnu.org>
4330 Distribute original version of simple parser (bison.s1), not built
4331 version (bison.simple).
4333 1998-11-28 Jesse Thilo <jthilo@gnu.org>
4335 * doc/bison.texinfo: Add info dir entry.
4337 * doc/bison.texinfo:
4338 Let automake put version number into documentation.
4340 1998-11-26 Jesse Thilo <jthilo@gnu.org>
4342 * src/bison.cld, src/build.com, src/vmshlp.mar:
4343 Add non-RCS files from /gd/gnu/bison.
4345 1998-11-26 Jesse Thilo <jthilo@gnu.org>
4348 Document the BISON_HAIRY and BISON_SIMPLE variables.
4350 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4352 * src/version.c: Build version.c automatically.
4355 Fix token numbering (used to start at 258, not 257).
4357 * src/system.h: Include config.h.
4359 * src/getargs.c: Update bug report address.
4361 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
4362 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
4364 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4367 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
4369 * configure.in, version.cin:
4370 Build version.c automatically.
4372 * AUTHORS: Add AUTHORS file.
4374 * README: Update bug report address.
4377 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
4379 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
4382 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4384 * doc/bison.texinfo: Clean up some formatting.
4386 1998-05-05 Richard Stallman <rms@gnu.org>
4388 * doc/bison.texinfo:
4389 Explain better why to make a pure parser.
4391 1998-01-05 Richard Stallman <rms@gnu.org>
4393 * src/files.c (openfiles):
4394 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
4395 find a temporary directory, if possible. Do not unlink files while
4398 1997-08-25 Richard Stallman <rms@gnu.org>
4400 * src/reader.c (stack_offset;):
4401 Change some warni to warns.
4403 * src/lex.c (literalchar): Use warns, not warni.
4405 1997-06-28 Richard Stallman <rms@gnu.org>
4407 * src/bison.s1: Add a Bison version comment.
4409 * src/main.c (fatal, warn, berror):
4412 1997-06-28 Richard Stallman <rms@gnu.org>
4414 * Makefile.in (bison_version): New variable.
4415 (dist): Use that variable.
4416 (bison.s1): Substitute the Bison version into bison.simple.
4418 * bison.simple: Add a Bison version comment.
4420 1997-06-18 Richard Stallman <rms@gnu.org>
4422 * src/main.c (fatal, warn, berror):
4423 Make error messages standard.
4424 (toomany): Improve error message text.
4426 * src/LR0.c, src/closure.c, src/conflicts.c, src/derives.c, src/files.c, src/lalr.c, src/lex.c, src/nullable.c, src/output.c, src/print.c, src/reader.c, src/reduce.c, src/symtab.c:
4427 new.h renamed to alloc.h.
4429 1997-06-18 Richard Stallman <rms@gnu.org>
4431 * Makefile.in: new.h renamed to alloc.h.
4433 1997-05-24 Richard Stallman <rms@gnu.org>
4435 * src/lex.c (literalchar):
4436 Fix the code for escaping \, " and '.
4438 (lex): Avoid trouble when there are many chars
4439 to discard in a char literal with just several chars in it.
4441 1997-05-17 Richard Stallman <rms@gnu.org>
4444 Use malloc, if using alloca is troublesome.
4445 (YYSTACK_USE_ALLOCA): New flag macro.
4446 Define it for some systems and compilers.
4447 (YYSTACK_ALLOC): New macro.
4448 (yyparse): Use YYSTACK_ALLOC to allocate stack.
4449 If it was malloc'd, free it.
4451 1997-05-17 Richard Stallman <rms@gnu.org>
4454 Use malloc, if using alloca is troublesome.
4455 (YYSTACK_USE_ALLOCA): New flag macro.
4456 Define it for some systems and compilers.
4457 (YYSTACK_ALLOC): New macro.
4458 (yyparse): Use YYSTACK_ALLOC to allocate stack.
4459 If it was malloc'd, free it.
4461 1997-04-23 Richard Stallman <rms@gnu.org>
4464 (alloca) [__hpux]: Always define as __builtin_alloca.
4466 1997-04-23 Richard Stallman <rms@gnu.org>
4469 (alloca) [__hpux]: Always define as __builtin_alloca.
4471 1997-04-22 Richard Stallman <rms@gnu.org>
4474 [__hpux]: Include alloca.h (right for HPUX 10)
4475 instead of declaring alloca (right for HPUX 9).
4477 * src/bison.s1 (__yy_memcpy):
4478 Declare arg `count' as unsigned int.
4479 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
4481 1997-04-22 Richard Stallman <rms@gnu.org>
4484 [__hpux]: Include alloca.h (right for HPUX 10)
4485 instead of declaring alloca (right for HPUX 9).
4487 * bison.simple (__yy_memcpy):
4488 Declare arg `count' as unsigned int.
4489 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
4491 1997-01-03 Richard Stallman <rms@gnu.org>
4493 * src/allocate.c: [__STDC__ or _MSC_VER]:
4494 Declare calloc and realloc to return void *.
4496 1997-01-02 Richard Stallman <rms@gnu.org>
4499 [_MSC_VER]: Include stdlib.h and process.h.
4500 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
4502 * src/main.c (main): Return FAILURE as a value.
4503 (printable_version): Declare arg as int, not char.
4505 1997-01-02 Richard Stallman <rms@gnu.org>
4507 * Makefile.in (dist):
4508 Explicitly check for symlinks, and copy them.
4510 1996-12-19 Richard Stallman <rms@gnu.org>
4513 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
4515 1996-12-18 Paul Eggert <eggert@gnu.org>
4517 * src/bison.s1 (yyparse):
4518 If __GNUC__ and YYPARSE_PARAM are both defined,
4519 declare yyparse to have a void * argument.
4521 1996-12-18 Paul Eggert <eggert@gnu.org>
4523 * bison.simple (yyparse):
4524 If __GNUC__ and YYPARSE_PARAM are both defined,
4525 declare yyparse to have a void * argument.
4527 1996-12-17 Richard Stallman <rms@gnu.org>
4529 * src/reduce.c (nbits): Add some casts.
4531 1996-08-12 Richard Stallman <rms@gnu.org>
4533 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
4535 1996-08-12 Richard Stallman <rms@gnu.org>
4537 * bison.simple: Test _MSDOS as well as _MSDOS_.
4539 1996-07-31 Richard Stallman <rms@gnu.org>
4542 [__sun && __i386]: Include alloca.h.
4544 1996-07-31 Richard Stallman <rms@gnu.org>
4547 [__sun && __i386]: Include alloca.h.
4549 1996-07-30 Richard Stallman <rms@gnu.org>
4551 * src/bison.s1: Comment change.
4553 * src/bison.s1: Test _MSDOS_, not MSDOS.
4555 1996-07-30 Richard Stallman <rms@gnu.org>
4557 * bison.simple: Comment change.
4559 * bison.simple: Test _MSDOS_, not MSDOS.
4561 1996-06-01 Richard Stallman <rms@gnu.org>
4563 * src/reduce.c, src/reader.c, src/print.c, src/output.c, src/nullable.c, src/lex.c, src/lalr.c, src/getargs.c, src/derives.c, src/conflicts.c, src/closure.c, src/allocate.c:
4564 Insert `_' macro around many string constants.
4567 Insert `_' macro around many string constants.
4569 (main): Call setlocale, bindtextdomain and textdomain.
4571 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
4572 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
4573 [ENABLE_NLS]: Include libintl.h.
4574 [ENABLE_NLS] (gettext): Define.
4575 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
4576 (N_, PACKAGE, LOCALEDIR): New macros.
4578 1996-06-01 Richard Stallman <rms@gnu.org>
4580 * POTFILES.in: New file.
4582 * Makefile.in (allocate.o):
4583 Define target explicitly.
4585 * Makefile.in (CFLAGS): Set to @CFLAGS@.
4586 (LDFLAGS): Set to @LDFLAGS@.
4587 (configure): Run autoconf only if preceding `cd' succeeds.
4588 (bison.s1): Redirect output to temporary file then move the
4589 temporary to the target, rather than redirecting directly to bison.s1.
4590 (clean): Remove config.status and config.log.
4591 (distclean): Don't remove config.status here.
4593 1996-05-12 Richard Stallman <rms@gnu.org>
4596 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4598 1996-05-12 Richard Stallman <rms@gnu.org>
4601 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4603 1996-05-11 Richard Stallman <rms@gnu.org>
4605 * src/bison.s1 (__yy_memcpy):
4606 Really reorder the args, as was supposedly done on Feb 14 1995.
4607 (yyparse): Calls changed accordingly.
4609 1996-05-11 Richard Stallman <rms@gnu.org>
4611 * Makefile.in (dist): Don't use $(srcdir).
4613 * bison.simple (__yy_memcpy):
4614 Really reorder the args, as was supposedly done on Feb 14 1995.
4615 (yyparse): Calls changed accordingly.
4617 1996-01-27 Richard Stallman <rms@gnu.org>
4619 * src/output.c (output_rule_data):
4620 Test YYERROR_VERBOSE in the conditional
4621 around the definition of ttyname.
4623 1995-12-29 Richard Stallman <rms@gnu.org>
4626 Fix line numbers in #line commands.
4628 1995-12-29 Richard Stallman <rms@gnu.org>
4631 Fix line numbers in #line commands.
4633 1995-12-27 Richard Stallman <rms@gnu.org>
4635 * src/bison.s1 (YYPARSE_PARAM_DECL):
4636 In C++, make it always null.
4637 (YYPARSE_PARAM_ARG): New macro.
4638 (yyparse): Use YYPARSE_PARAM_ARG.
4640 1995-12-27 Richard Stallman <rms@gnu.org>
4642 * bison.simple (YYPARSE_PARAM_DECL):
4643 In C++, make it always null.
4644 (YYPARSE_PARAM_ARG): New macro.
4645 (yyparse): Use YYPARSE_PARAM_ARG.
4647 1995-11-29 Richard Stallman <rms@gnu.org>
4649 * doc/bison.texinfo:
4650 Describe literal string tokens, %raw, %no_lines, %token_table.
4652 1995-11-29 Daniel Hagerty <hag@gnu.org>
4654 * doc/bison.texinfo: Fixed update date
4656 1995-10-16 Richard Stallman <rms@gnu.org>
4658 * src/version.c: Version 1.25.
4660 1995-10-16 Richard Stallman <rms@gnu.org>
4662 * NEWS: *** empty log message ***
4664 1995-10-16 Richard Stallman <rms@gnu.org>
4666 * doc/bison.1, doc/bison.rnh:
4669 1995-10-15 Richard Stallman <rms@gnu.org>
4671 * src/vmsgetargs.c, src/getargs.c:
4672 Added -n, -k, and -raw switches.
4673 (noparserflag, toknumflag, rawtoknumflag): New variables.
4675 * src/symtab.h (SALIAS):
4676 New #define for adding aliases to %token.
4677 (struct bucket): Added `alias' field.
4679 * src/reduce.c (reduce_grammar):
4680 Revise error message.
4681 (print_notices): Remove final `.' from error message.
4683 * src/reader.c (reader_output_yylsp):
4685 (readgram): Use `#if 0' around code that accepted %command
4686 inside grammar rules: The documentation doesn't allow it,
4687 and it will fail since the %command processors scan for the next %.
4688 (parse_token_decl): Extended the %token
4689 declaration to allow a multi-character symbol as an alias.
4690 (parse_thong_decl): New function.
4691 (read_declarations): Added %thong declarations.
4692 (read_declarations): Handle NOOP to deal with allowing
4693 % declarations as another means to specify the flags.
4694 (readgram): Allow %prec prior to semantics embedded in a rule.
4695 (skip_to_char, read_declarations, copy_definition)
4696 (parse_token_decl, parse_start_decl, parse_type_decl)
4697 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
4698 (get_type_name, copy_guard, copy_action, readgram)
4699 (get_type, packsymbols): Revised most error messages.
4700 Changed `fatal' to `warnxxx' to avoid aborting for error.
4701 Revised and use multiple warnxxx functions to avoid using VARARGS1.
4702 (read_declarations): Improve the error message for
4703 an invalid character. Do not abort.
4704 (read_declarations, copy_guard, copy_action): Use
4705 printable_version to avoid unprintable characters in printed output.
4706 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
4707 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
4708 Allow the type of a non-terminal can be given
4709 more than once, as long as all specifications give the same type.
4712 (output_headers, output_trailers, output, output_gram)
4713 (output_rule_data): Implement noparserflag variable.
4714 Implement toknumflag variable.
4715 (output): Call reader_output_yylsp to output LTYPESTR.
4717 * src/main.c (main):
4718 If reader sees an error, don't process the grammar.
4719 (fatals): Updated to not use VARARGS1.
4720 (printable_version, int_to_string, warn, warni, warns, warnss)
4721 (warnsss): New error reporting functions. Avoid abort for error.
4724 Added THONG and NOOP for alias processing.
4725 Added SETOPT for the new code that allows setting options with %flags.
4728 Include getopt.h. Add some extern decls.
4729 (safegetc): New function to deal with EOF gracefully.
4730 (literalchar); new function to deal with reading \ escapes.
4731 (lex): Use literalchar.
4732 (lex): Implemented "..." tokens.
4733 (literalchar, lex, parse_percent_token): Made tokenbuffer
4734 always contain the token. This includes growing the token
4735 buffer while reading an integer.
4736 (parse_percent_token): Replaced if-else statement with percent_table.
4737 (parse_percent_token): Added % declarations as another
4738 way to specify the flags -n, -l, and -r. Also added hooks for
4739 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
4740 major changes to files.c.
4741 (lex) Retain in the incoming stream a character following
4743 (skip_white_space, lex): Revised most error messages
4744 and changed fatal to warn to avoid aborting.
4745 (percent_table): Added %thong declarations.
4747 * src/gram.h: Comment changes.
4749 * src/files.c (openfiles, open_extra_files, done):
4751 and actfile file. Handle noparserflag. Both for -n switch.
4753 * src/conflicts.c (resolve_sr_conflict):
4754 Remove use of alloca.
4756 1995-06-01 Jim Meyering <meyering@gnu.org>
4758 * doc/bison.texinfo: *** empty log message ***
4760 1995-05-06 Richard Stallman <rms@gnu.org>
4762 * src/bison.s1: Comment change.
4764 1995-05-06 Richard Stallman <rms@gnu.org>
4766 * bison.simple: Comment change.
4768 1995-05-03 Richard Stallman <rms@gnu.org>
4770 * src/version.c: Version now 1.24.
4772 * src/bison.s1: Change distribution terms.
4774 * src/version.c: Version now 1.23.
4776 1995-05-03 Richard Stallman <rms@gnu.org>
4778 * doc/bison.texinfo:
4779 Rewrite "Conditions for Using Bison".
4780 Update version to 1.24.
4782 1995-05-03 Richard Stallman <rms@gnu.org>
4784 * bison.simple: Change distribution terms.
4786 1995-02-23 Richard Stallman <rms@gnu.org>
4788 * src/files.c: Test __VMS_POSIX as well as VMS.
4790 1995-02-14 Jim Meyering <meyering@gnu.org>
4792 * src/bison.s1 (__yy_memcpy):
4793 Renamed from __yy_bcopy to avoid
4794 confusion. Reverse FROM and TO arguments to be consistent with
4797 1995-02-14 Jim Meyering <meyering@gnu.org>
4799 * bison.simple (__yy_memcpy):
4800 Renamed from __yy_bcopy to avoid
4801 confusion. Reverse FROM and TO arguments to be consistent with
4804 1994-11-10 David J. MacKenzie <djm@gnu.org>
4810 * Makefile.in (DISTFILES): Include NEWS.
4812 * Makefile.in (DISTFILES):
4813 Include install-sh, not install.sh.
4815 * configure.in: Update to Autoconf v2 macro names.
4817 1994-10-05 David J. MacKenzie <djm@gnu.org>
4819 * Makefile.in: fix typo
4821 * Makefile.in (prefix, exec_prefix):
4822 Let configure set them.
4824 1994-09-28 David J. MacKenzie <djm@gnu.org>
4826 * Makefile.in: Set datadir to $(prefix)/share.
4828 1994-09-15 Richard Stallman <rms@gnu.org>
4831 Update copyright notice and GPL version.
4833 1994-09-15 Richard Stallman <rms@gnu.org>
4836 Update copyright notice and GPL version.
4838 1994-07-12 Richard Stallman <rms@gnu.org>
4840 * src/reduce.c, src/reader.c:
4843 1994-05-05 David J. MacKenzie <djm@gnu.org>
4845 * Makefile.in: entered into RCS
4847 1994-03-26 Richard Stallman <rms@gnu.org>
4849 * src/bison.s1: entered into RCS
4851 1994-03-26 Richard Stallman <rms@gnu.org>
4853 * bison.simple: entered into RCS
4855 1994-03-25 Richard Stallman <rms@gnu.org>
4857 * src/main.c: entered into RCS
4859 1994-03-24 Richard Stallman <rms@gnu.org>
4861 * src/conflicts.c: entered into RCS
4863 1994-01-02 Richard Stallman <rms@gnu.org>
4865 * Makefile.in: *** empty log message ***
4867 1993-11-21 Richard Stallman <rms@gnu.org>
4869 * src/bison.s1: *** empty log message ***
4871 1993-11-21 Richard Stallman <rms@gnu.org>
4873 * doc/bison.texinfo: entered into RCS
4875 * doc/bison.texinfo: *** empty log message ***
4877 1993-11-21 Richard Stallman <rms@gnu.org>
4879 * bison.simple: *** empty log message ***
4881 1993-10-25 David J. MacKenzie <djm@gnu.org>
4883 * doc/bison.texinfo: *** empty log message ***
4885 1993-10-19 Richard Stallman <rms@gnu.org>
4887 * src/bison.s1: *** empty log message ***
4889 1993-10-19 Richard Stallman <rms@gnu.org>
4891 * bison.simple: *** empty log message ***
4893 1993-10-14 Richard Stallman <rms@gnu.org>
4895 * src/bison.s1: *** empty log message ***
4897 1993-10-14 Richard Stallman <rms@gnu.org>
4899 * bison.simple: *** empty log message ***
4901 1993-09-14 David J. MacKenzie <djm@gnu.org>
4903 * doc/bison.texinfo: *** empty log message ***
4905 1993-09-13 Noah Friedman <friedman@gnu.org>
4907 * Makefile.in: *** empty log message ***
4909 1993-09-10 Richard Stallman <rms@gnu.org>
4911 * src/conflicts.c: *** empty log message ***
4913 * src/system.h: entered into RCS
4915 1993-09-10 Richard Stallman <rms@gnu.org>
4917 * doc/bison.1: entered into RCS
4919 1993-09-06 Noah Friedman <friedman@gnu.org>
4921 * src/version.c: entered into RCS
4923 1993-09-06 Noah Friedman <friedman@gnu.org>
4925 * Makefile.in: *** empty log message ***
4927 1993-07-30 David J. MacKenzie <djm@gnu.org>
4929 * Makefile.in: *** empty log message ***
4931 1993-07-24 Richard Stallman <rms@gnu.org>
4933 * src/bison.s1: *** empty log message ***
4935 1993-07-24 Richard Stallman <rms@gnu.org>
4937 * bison.simple: *** empty log message ***
4939 1993-07-08 David J. MacKenzie <djm@gnu.org>
4941 * Makefile.in: *** empty log message ***
4943 1993-07-04 Richard Stallman <rms@gnu.org>
4945 * src/bison.s1: *** empty log message ***
4947 1993-07-04 Richard Stallman <rms@gnu.org>
4949 * bison.simple: *** empty log message ***
4951 1993-06-26 David J. MacKenzie <djm@gnu.org>
4953 * src/getargs.c: entered into RCS
4955 1993-06-26 David J. MacKenzie <djm@gnu.org>
4957 * doc/bison.texinfo: *** empty log message ***
4959 * doc/bison.1: New file.
4961 1993-06-25 Richard Stallman <rms@gnu.org>
4963 * src/getargs.c: New file.
4965 1993-06-16 Richard Stallman <rms@gnu.org>
4967 * src/bison.s1: *** empty log message ***
4969 1993-06-16 Richard Stallman <rms@gnu.org>
4971 * bison.simple: *** empty log message ***
4973 1993-06-03 Richard Stallman <rms@gnu.org>
4975 * src/bison.s1: New file.
4977 1993-06-03 Richard Stallman <rms@gnu.org>
4979 * doc/bison.texinfo: *** empty log message ***
4981 1993-06-03 Richard Stallman <rms@gnu.org>
4983 * bison.simple: New file.
4985 1993-05-19 Richard Stallman <rms@gnu.org>
4987 * doc/bison.texinfo: New file.
4989 1993-05-07 Noah Friedman <friedman@gnu.org>
4991 * Makefile.in: *** empty log message ***
4993 1993-04-28 Noah Friedman <friedman@gnu.org>
4995 * src/reader.c: *** empty log message ***
4997 1993-04-23 Noah Friedman <friedman@gnu.org>
4999 * src/alloc.h: entered into RCS
5001 1993-04-20 David J. MacKenzie <djm@gnu.org>
5003 * src/version.c: *** empty log message ***
5005 * src/files.c, src/allocate.c:
5008 * src/reader.c: *** empty log message ***
5010 * src/lex.c: entered into RCS
5012 * src/conflicts.c: New file.
5014 * src/symtab.c: entered into RCS
5016 * src/alloc.h: New file.
5018 * src/LR0.c: entered into RCS
5020 1993-04-18 Noah Friedman <friedman@gnu.org>
5022 * src/reader.c: New file.
5024 * src/version.c: *** empty log message ***
5026 1993-04-18 Noah Friedman <friedman@gnu.org>
5028 * Makefile.in: *** empty log message ***
5030 1993-04-17 Noah Friedman <friedman@gnu.org>
5032 * Makefile.in: *** empty log message ***
5034 1993-04-15 Richard Stallman <rms@gnu.org>
5036 * src/main.c, src/files.c:
5039 1993-04-15 Noah Friedman <friedman@gnu.org>
5041 * configure.in: entered into RCS
5043 * configure.in: *** empty log message ***
5045 * configure.in: New file.
5047 1993-04-14 Richard Stallman <rms@gnu.org>
5049 * Makefile.in: New file.
5051 1993-04-13 Richard Stallman <rms@gnu.org>
5053 * src/version.c: New file.
5055 1993-03-25 Richard Stallman <rms@gnu.org>
5057 * src/output.c: entered into RCS
5059 1992-09-25 Richard Stallman <rms@gnu.org>
5061 * configure.bat: entered into RCS
5063 1992-06-22 Richard Stallman <rms@gnu.org>
5065 * src/vmsgetargs.c: entered into RCS
5067 1992-06-22 Richard Stallman <rms@gnu.org>
5069 * doc/bison.rnh: entered into RCS
5071 1992-04-20 David J. MacKenzie <djm@gnu.org>
5073 * README: entered into RCS
5075 1992-01-22 Richard Stallman <rms@gnu.org>
5077 * src/machine.h: entered into RCS
5079 1991-12-21 Richard Stallman <rms@gnu.org>
5081 * src/lalr.c, src/closure.c:
5084 1991-12-20 Richard Stallman <rms@gnu.org>
5086 * src/state.h: entered into RCS
5088 1991-12-18 Richard Stallman <rms@gnu.org>
5090 * src/print.c, src/nullable.c, src/derives.c:
5093 1991-11-03 David J. MacKenzie <djm@gnu.org>
5095 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
5098 1988-09-09 Richard Stallman <rms@gnu.org>
5100 * src/bison.hairy: entered into RCS
5102 1987-12-16 Richard Stallman <rms@gnu.org>
5104 * REFERENCES: entered into RCS