1 2001-12-15 Akim Demaille <akim@epita.fr>
3 Make `make distcheck' work.
5 * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses
6 system.h which uses libgettext.h.
8 2001-12-15 Akim Demaille <akim@epita.fr>
10 * src/nullable.c (set_nullable): Useless rules must be skipped,
11 otherwise, since we range over their symbols, we might look at a
12 nonterminal which no longer ``exists'', i.e., it is not counted in
13 `nvars', hence we overflow our arrays.
15 2001-12-15 Akim Demaille <akim@epita.fr>
17 The header can also be produced directly, without any obstack!
20 * src/files.c, src/files.h (defines_obstack): Remove.
21 (compute_header_macro): Global.
22 (defines_obstack_save): Remove.
23 * src/reader.c (parse_union_decl): No longer output to
24 defines_obstack: its content can be found in the `stype' muscle
26 (output_token_translations): Merge into...
27 (symbols_output): this.
31 * src/output.c (header_output): New.
34 2001-12-15 Akim Demaille <akim@epita.fr>
36 * src/reader.c (parse_union_decl): Instead of handling two obstack
37 simultaneously, use one to define the `stype' muscle, and use the
38 value of the latter to fill defines_obstack.
39 (copy_comment): Remove.
40 (copy_comment2): Work for a single obstack.
44 2001-12-15 Akim Demaille <akim@epita.fr>
46 * src/lex.c, src/lex.h (xgetc): No longer static.
47 * src/reader.c (parse_union_decl): Revamp.
49 2001-12-15 Akim Demaille <akim@epita.fr>
51 Still making progress in separating Bison into (i) input, (ii)
52 process, (iii) output: now we can directly output the parser file
53 without using table_obstack at all.
55 * src/files.c, src/files.h (table_obstack): Bye bye.
56 (parser_file_name): New.
57 * src/files.c (compute_output_file_names): Compute it.
58 * src/output.c (actions_output, output_parser)
59 (output_master_parser): To a file instead of an obstack.
61 2001-12-15 Akim Demaille <akim@epita.fr>
63 Attach actions to rules, instead of pre-outputting them to
66 * src/gram.h (rule_t): action and action_line are new members.
67 * src/reader.c (symbol_list): Likewise.
68 (copy_action): Save the actions within the rule.
69 (packgram): Save them in rule_table.
70 * src/output.c (actions_output): New.
71 (output_parser): Use it on `%%actions'.
72 (output_rule_data): Don't free rule_table.
74 (prepare): Don't save the `action' muscle.
75 * src/bison.simple: s/%%action/%%actions/.
77 2001-12-15 Akim Demaille <akim@epita.fr>
79 * src/reader.c (copy_action): When --yacc, don't append a `;'
80 to the user action: let it fail if lacking.
81 Suggested by Aharon Robbins and Tom Tromey.
83 2001-12-14 Akim Demaille <akim@epita.fr>
85 * src/lex.c (literalchar): Simply return the char you decoded, non
86 longer mess around with obstacks and int pointers.
89 2001-12-14 Akim Demaille <akim@epita.fr>
91 * src/lex.c (literalchar): Don't escape the special characters,
92 just decode them, and keep them as char (before, eol was output as
93 the 2 char string `\n' etc.).
94 * src/output.c (output_rule_data): Use quotearg to output the
97 2001-12-13 Paul Eggert <eggert@twinsun.com>
99 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
100 Do not infringe on the global user namespace when using C++.
101 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
102 All uses of `fprintf' and `stderr' changed.
104 * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR.
106 2001-12-13 Akim Demaille <akim@epita.fr>
108 The computation of nullable is broken: it doesn't handle empty
111 * tests/torture.at (GNU AWK Grammar): New.
112 * tests/sets.at (Nullable): New.
113 * src/nullable.c (set_nullable): Instead of blindly looping over
114 `ritems', loop over the rules, and then over their rhs's.
116 Work around Autotest bugs.
118 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
119 frame, because Autotest understand lines starting with a `+' as
120 traces from the shell. Then, they are not processed properly.
121 Admittedly an Autotest bug, but we don't have time to wait for
122 Autotest to catch up.
123 * tests/regression.at (Broken Closure): Adjust to the new table
126 * tests/sets.at: here.
128 2001-12-13 Akim Demaille <akim@epita.fr>
130 * src/closure.c (closure): Use nrules instead of playing tricks
133 2001-12-13 Akim Demaille <akim@epita.fr>
135 * src/print.c (print_actions): Output the handling of `$' as the
136 traces do: shifting the token EOF. Before EOF was treated as a
138 * tests/regression.at: Adjust some tests.
139 * src/print_graph.c (print_core): Complete the set of items via
140 closure. The next-to-final and final states are still unsatisfying,
141 but that's to be addressed elsewhere.
142 No longer output the rule numbers, but do output the state number.
143 A single loop for the shifts + gotos is enough, but picked a
144 distinct color for each.
145 (print_graph): Initialize and finalize closure.
147 2001-12-13 Akim Demaille <akim@epita.fr>
149 * src/reader.c (readgram): Remove dead code, an strip useless
151 (get_type): Remove, unused.
153 2001-12-12 Akim Demaille <akim@epita.fr>
155 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
156 on that of lib/error.c.
158 2001-12-12 Akim Demaille <akim@epita.fr>
160 Some hosts don't like `/' in includes.
162 * src/system.h: Include libgettext.h without qualifying the path.
163 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
166 2001-12-11 Marc Autret <autret_m@epita.fr>
168 * src/output.c (output_parser): Remove useless muscle.
170 2001-12-11 Marc Autret <autret_m@epita.fr>
172 * src/bison.simple: Remove #line just before %%epilogue. It
173 is now handled in ...
174 * src/reader.c (read_additionnal_code): Add the output of a
175 #line for the epilogue.
177 2001-12-10 Marc Autret <autret_m@epita.fr>
179 * src/reader.c (copy_definition): Re-use CPP-outed code which
180 replace precedent remove.
181 * src/bison.simple: Remove #line before %%prologue because
182 %%input-line is wrong at this time.
184 2001-12-10 Marc Autret <autret_m@epita.fr>
186 * src/reader.c (symbols_output): Clean up.
187 * src/output.c (output_gram, output): Clean up.
189 2001-12-10 Akim Demaille <akim@epita.fr>
191 * src/lalr.c (initialize_lookaheads): New. Extracted from...
192 * src/LR0.c (set_state_table): here.
193 * src/lalr.c (lalr): Call it.
195 2001-12-10 Akim Demaille <akim@epita.fr>
197 * src/state.h (shifts): Remove the `number' member: shifts are
198 attached to state, hence no longer need to be labelled with a
201 2001-12-10 Akim Demaille <akim@epita.fr>
203 Now that states have a complete set of members, the linked list of
204 shifts is useless: just fill directly the state's shifts member.
206 * src/state.h (shifts): Remove the `next' member.
207 * src/LR0.c (first_state, last_state): Remove.
209 (augment_automaton): Don't look for the shifts that must be added
210 a shift on EOF: it is those of the state we looked for! But now,
211 since shifts are attached, it is no longer needed to looking
212 merely by its id: its number.
214 2001-12-10 Akim Demaille <akim@epita.fr>
216 * src/LR0.c (augment_automaton): Better variable locality.
217 Remove an impossible branch: if there is a state corresponding to
218 the start symbol being shifted, then there is shift for the start
219 symbol from the initial state.
221 2001-12-10 Akim Demaille <akim@epita.fr>
223 * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state'
224 only when appropriate: when insert_start_shifting_state' is not
226 * tests/regression.at (Rule Line Numbers): Adjust.
228 2001-12-10 Akim Demaille <akim@epita.fr>
230 * src/LR0.c (augment_automaton): Now that all states have shifts,
231 merge the two cases addition shifts to the initial state.
233 2001-12-10 Akim Demaille <akim@epita.fr>
235 * src/lalr.c (set_state_table): Move to...
237 * src/lalr.c (lalr): Don't call it...
238 * src/LR0.c (generate_states): do it.
239 * src/LR0.h (first_state): Remove, only the table is used.
241 2001-12-10 Akim Demaille <akim@epita.fr>
243 * src/LR0.h (first_shift, first_reduction): Remove.
244 * src/lalr.c: Don't use first_shift: find shifts through the
247 2001-12-10 Akim Demaille <akim@epita.fr>
249 * src/LR0.c: Attach shifts to states as soon as they are
251 * src/lalr.c (set_state_table): Instead of assigning shifts to
252 state, just assert that the mapping was properly done.
254 2001-12-10 Akim Demaille <akim@epita.fr>
256 * src/LR0.c (insert_start_shift): Rename as...
257 (insert_start_shifting_state): this.
258 (insert_eof_shifting_state, insert_accepting_state): New.
259 (augment_automaton): Adjust.
260 Better locality of the variables.
261 When looking if the start_symbol is shifted from the initial
262 state, using `while (... symbol != start_symbol ...)' sounds
263 better than `while (... symbol < start_symbol ...)': If fail
264 to see how the order between symbols could be relevant!
266 2001-12-10 Akim Demaille <akim@epita.fr>
268 * src/getargs.h: Don't declare `spec_name_prefix' and
269 `spec_file_prefix', declared by src/files.h.
270 * src/files.c, src/files.h: Default for spec_name_prefix is "yy".
271 * src/muscle_tab.c (muscle_init): Default prefix to NULL.
272 * src/output.c (prepare): Adjust.
273 * src/reader.c (symbols_output): Likewise.
274 * src/vmsgetargs.c: Vaguely adjust, but who cares?
276 2001-12-10 Akim Demaille <akim@epita.fr>
278 * src/muscle_tab.c (muscle_init): NULL is a better default than
281 2001-12-10 Akim Demaille <akim@epita.fr>
283 * src/reader.c (reader): Calling symbols_output once is enough.
285 2001-12-10 Akim Demaille <akim@epita.fr>
287 Now that states have a complete set of members, the linked list of
288 reductions is useless: just fill directly the state's reductions
291 * src/state.h (struct reductions): Remove member `number' and
293 * src/LR0.c (first_reduction, last_reduction): Remove.
294 (save_reductions): Don't link the new reductions, store them in
296 * src/lalr.c (set_state_table): No need to attach reductions to
297 states, it's already done.
298 * src/output.c (output_actions): No longer free the shifts, then
299 the reductions, then the states: free all the states and their
302 2001-12-10 Akim Demaille <akim@epita.fr>
304 * src/options.c (OPTN, DRTV, BOTH): New.
305 (option_table): Use them.
307 * src/muscle_tab.c: Don't include xalloc.h and string.h: that's
309 * src/options.c: Don't include stdio.h and xalloc.h for the same
312 2001-12-10 Akim Demaille <akim@epita.fr>
314 * src/output.c (output, prepare): Make sure the values of the
315 muscles `action' and `prologue' are 0-terminated.
317 2001-12-10 Akim Demaille <akim@epita.fr>
319 Clean up GCC warnings.
321 * src/reader.c (copy_action): `buf' is not used.
322 (parse_skel_decl): Be static.
323 * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'.
324 * src/options.h (create_long_option_table): Have a real prototype.
325 * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete)
326 (hash_delete_at): Return const void *.
327 Adjust casts to preserve the const.
329 2001-12-10 Akim Demaille <akim@epita.fr>
331 * configure.in: Require 2.52g.
332 M4 is not needed, but AUTOM4TE is.
334 * tests/Makefile.am: Adjust.
336 2001-12-10 Akim Demaille <akim@epita.fr>
338 One structure for states is enough, even though theoretically
339 there are LR(0) states and LALR(1) states.
341 * src/lalr.h (state_t): Remove.
342 (state_table): Be state_t **, not state_t *.
343 * src/state.h (core, CORE_ALLOC): Rename as...
344 (state_t, STATE_ALLOC): this.
345 Add the LALR(1) members: shifts, reductions, errs.
346 * src/LR0.c (state_table): Rename as...
347 (state_hash): this, to avoid name clashes with the global
349 * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c
350 * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust.
352 2001-12-10 Akim Demaille <akim@epita.fr>
354 Bison dumps core on bash.y.
355 Reported by Pascal Bart.
357 * src/warshall.c (bitmatrix_print): New.
359 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
360 j must be the outer loop.
361 * tests/regression.at (Broken Closure): New.
363 2001-12-05 Akim Demaille <akim@epita.fr>
365 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
367 Reported by Peter Hámorský.
369 2001-12-05 Akim Demaille <akim@epita.fr>
371 * src/conflicts.c (err_table): Remove.
372 (resolve_sr_conflict): Adjust.
373 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
375 (state_t.reductions, state_t.shifts): this.
377 2001-12-05 Akim Demaille <akim@epita.fr>
379 * src/reduce.c (reduce_grammar_tables): No longer disable the
380 removal of useless rules via CPP but via `if (0)', so that the
381 compiler still check the code is valid.
382 For instance, it should have noticed `rline' no longer exists: use
383 the `line' member of rule_t.
384 * src/gram.c (dummy, rline): Remove, unused.
386 2001-12-05 Akim Demaille <akim@epita.fr>
388 * src/output.c (pack_vector): Use assert, not berror.
389 * src/main.c (berror): Remove, unused.
391 2001-12-05 Akim Demaille <akim@epita.fr>
393 New experimental feature: if --verbose --trace output all the
394 items of a state, not only its kernel.
396 * src/print.c (print_core): If `trace_flag', then invoke closure
397 before outputting the items of the state (print_core is no longer
398 a correct name them).
399 (print_results): Invoke new_closure/free_closure if needed.
401 2001-12-05 Akim Demaille <akim@epita.fr>
403 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
404 * src/closure.c, src/closure.h (itemsetsize): Rename as...
405 (nitemset): for consistency with the rest of the project.
407 2001-12-05 Akim Demaille <akim@epita.fr>
409 * src/closure.c (print_closure): Improve.
410 (closure): Use it for printing input and output.
412 2001-12-05 Akim Demaille <akim@epita.fr>
414 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
415 indexed by nonterminals.
417 2001-12-05 Akim Demaille <akim@epita.fr>
419 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
421 * src/warshall.h: Remove accidental duplication of the content.
423 2001-12-05 Akim Demaille <akim@epita.fr>
425 * src/closure.c (set_fderives): De-obfuscate.
427 2001-12-05 Akim Demaille <akim@epita.fr>
429 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
431 2001-12-05 Akim Demaille <akim@epita.fr>
433 * src/closure.c (set_firsts): De-obfuscate.
435 2001-12-05 Akim Demaille <akim@epita.fr>
437 * src/output.c (action_row): De-obfuscate
438 using the good o' techniques: arrays not pointers, variable
439 locality, BITISSET, RESETBIT etc.
441 2001-12-05 Akim Demaille <akim@epita.fr>
443 Pessimize the code to simplify it: from now on, all the states
444 have a valid SHIFTS, which NSHIFTS is possibly 0.
446 * src/LR0.c (shifts_new): Be global and move to..
447 * src/state.c, src/state.h: here.
448 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
449 * src/print_graph: Adjust.
451 2001-12-05 Akim Demaille <akim@epita.fr>
453 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
454 * src/conflicts.c: Use it.
455 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
456 incorrectly ``simplified''.
458 2001-12-05 Akim Demaille <akim@epita.fr>
460 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
461 using the good o' techniques: arrays not pointers, variable
462 locality, BITISSET, RESETBIT etc.
464 2001-12-05 Akim Demaille <akim@epita.fr>
466 * src/state.h (SHIFT_SYMBOL): New.
467 * src/conflicts.c: Use it to deobfuscate.
469 2001-12-05 Akim Demaille <akim@epita.fr>
471 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
472 (print_reductions): De-obfuscate using the good o' techniques:
473 arrays not pointers, variable locality, BITISSET.
475 2001-12-05 Akim Demaille <akim@epita.fr>
477 * src/conflicts.c (print_reductions): Arrays, not pointers.
480 2001-12-05 Akim Demaille <akim@epita.fr>
482 * src/conflicts.c (print_reductions): Pessimize, but clarify.
484 2001-12-05 Akim Demaille <akim@epita.fr>
486 * src/conflicts.c (print_reductions): Improve variable locality.
488 2001-12-05 Akim Demaille <akim@epita.fr>
490 * src/conflicts.c (print_reductions): Pessimize, but clarify.
492 2001-12-05 Akim Demaille <akim@epita.fr>
494 * src/conflicts.c (print_reductions): Improve variable locality.
496 2001-12-05 Akim Demaille <akim@epita.fr>
498 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
499 * src/lalr.c: Use them.
501 2001-12-05 Akim Demaille <akim@epita.fr>
503 * src/LR0.c (augment_automaton): Formatting changes.
504 Better variable locality.
506 2001-12-05 Akim Demaille <akim@epita.fr>
508 * src/lalr.c (matrix_print): New.
510 Use arrays instead of pointers.
512 2001-12-05 Akim Demaille <akim@epita.fr>
514 * src/lalr.c (maxrhs): Move to...
515 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
516 * src/lalr.c (build_relations): Adjust.
518 2001-12-05 Akim Demaille <akim@epita.fr>
520 * src/lalr.c (transpose): Free the memory allocated to the
521 argument, as it is replaced by the results by the unique caller.
522 (build_relations): Merely invoke transpose: it handles the memory
524 Improve variable locality.
525 Avoid variables used as mere abbreviations.
526 (compute_lookaheads): Use arrays instead of pointers.
528 2001-12-05 Akim Demaille <akim@epita.fr>
530 * src/lalr.c (initialize_F): Improve variable locality.
531 Avoid variables used as mere abbreviations.
533 2001-12-05 Akim Demaille <akim@epita.fr>
535 * src/derives.c (print_derives): Display the ruleno.
536 * src/lalr.c (initialize_F, transpose): Better variable locality
537 to improve readability.
538 Avoid variables used as mere abbreviations.
540 2001-12-05 Akim Demaille <akim@epita.fr>
542 * src/lalr.c (traverse): Use arrays instead of pointers.
544 2001-12-05 Akim Demaille <akim@epita.fr>
546 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
547 the handling of squeue.
548 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
550 2001-12-05 Akim Demaille <akim@epita.fr>
552 Because useless nonterminals are now kept alive (instead of being
553 `destroyed'), we now sometimes examine them, and store information
554 related to them. Hence we need to know their number, and adjust
557 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
559 * src/LR0.c (allocate_itemsets): The memory allocated to
560 `symbol_count' was used for two different purpose: once to count
561 the number of occurrences of each symbol, and later reassigned to
562 `shift_symbol', containing the symbol that can be shifted from a
564 Deobfuscate, i.e., allocate, use and free `symbol_count' here
566 (new_itemsets): Allocate `shift_symbol' here.
567 (allocate_itemsets): symbol_count includes useless nonterminals.
569 (free_storage): Use `free', not `XFREE', for pointers that cannot
572 2001-12-05 Akim Demaille <akim@epita.fr>
574 * src/nullable.c (set_nullable): Deobfuscate the handling of
576 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
578 2001-12-05 Akim Demaille <akim@epita.fr>
580 * src/gram.c, src/gram.h (ritem_print): New.
581 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
582 (This useless function was defined only to work around VMS linkers
583 that can't handle compilation units with variables only).
584 * src/reduce.c (dump_grammar): Use it to trace the construction of
587 2001-12-04 Paul Eggert <eggert@twinsun.com>
589 * src/bison.simple (union yyalloc): Change member names
590 to be the same as the stack names.
591 (yyparse): yyptr is now union yyalloc *, not char *.
592 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
593 and may generate better code on some machines.
594 (yystpcpy): Use prototype if __STDC__ is defined, not just
595 if __cplusplus is defined.
597 2001-11-30 Akim Demaille <akim@epita.fr>
599 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
600 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
601 Gettext doesn't compile cleanly, and dies with -Werror.
602 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
603 Include WARNING_CFLAGS here.
604 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
605 before being defined.
607 2001-11-27 Paul Eggert <eggert@twinsun.com>
609 * lib/quotearg.h (quotearg_n, quotearg_n_style):
610 First arg is int, not unsigned.
611 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
612 (SIZE_MAX, UINT_MAX): New macros.
613 (quotearg_n_options): Abort if N is negative.
614 Avoid overflow check on hosts where size_t is 64 bits and int
615 is 32 bits, as overflow is impossible there.
616 Fix off-by-one typo that caused unnecessary reallocation.
618 2001-11-29 Paul Eggert <eggert@twinsun.com>
620 Name space cleanup in generated parser.
622 * doc/bison.texinfo (Bison Parser): Discuss system headers
623 and their effect on the user name space.
626 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
627 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
628 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
630 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
631 on user names when possible.
633 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
634 Simplify test for whather <alloca.h> exists.
636 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
638 (<stdio.h>): Include if YYDEBUG.
640 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
641 ! defined (yyoverflow) && ! defined (yymemcpy).
643 (yymemcpy, yyparse): Rename local variables as needed so that
644 they all begin with 'yy'.
646 (yystrlen, yystpcpy): New functions.
648 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
651 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
652 instead of relying on string.h functions. Use YYSTACK_ALLOC
653 and YYSTACK_FREE instead of malloc and free.
655 2001-11-30 Akim Demaille <akim@epita.fr>
657 * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions
658 before their first uses.
659 (YYBISON, YYPURE): Move to the top of the output.
661 2001-11-30 Akim Demaille <akim@epita.fr>
663 * tests/reduce.at (Useless Nonterminals): Fix.
665 2001-11-30 Akim Demaille <akim@epita.fr>
667 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
668 if body instead of `;' to pacify GCC's warnings.
670 2001-11-30 Akim Demaille <akim@epita.fr>
672 Instead of mapping the LHS of unused rules to -1, keep the LHS
673 valid, but flag the rules as invalid.
675 * src/gram.h (rule_t): `useful' is a new member.
676 * src/print.c (print_grammar): Adjust.
677 * src/derives.c (set_derives): Likewise.
678 * src/reader.c (packgram, reduce_output): Likewise.
679 * src/reduce.c (reduce_grammar_tables): Likewise.
680 * tests/reduce.at (Underivable Rules, Useless Rules): New.
682 2001-11-30 Akim Demaille <akim@epita.fr>
684 * src/reduce.c (reduce_output): Formatting changes.
685 * src/print.c (print_results, print_grammar): Likewise.
686 * tests/regression.at (Rule Line Numbers)
687 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
689 2001-11-30 Akim Demaille <akim@epita.fr>
691 * src/reduce.c (nonterminals_reduce): Instead of throwing away
692 useless nonterminals, move them at the end of the symbol arrays.
693 (reduce_output): Adjust.
694 * tests/reduce.at (Useless Nonterminals): Adjust.
696 2001-11-30 Akim Demaille <akim@epita.fr>
698 * src/reduce.c: Various comment/formatting changes.
699 (nonterminals_reduce): New, extracted from...
700 (reduce_grammar_tables): here.
701 (reduce_grammar): Call nonterminals_reduce.
703 2001-11-29 Paul Eggert <eggert@twinsun.com>
705 * src/bison.simple (YYSTACK_REALLOC): Remove.
706 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
707 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
709 (union yyalloc): New type.
710 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
711 an arbitrary restriction on hosts where size_t is wider than int.
713 (yyparse): Don't dump core if alloca or malloc fails; instead, report
714 a parser stack overflow. Allocate just one block of memory for all
715 three stacks, instead of allocating three blocks; this typically is
716 faster and reduces fragmentation.
718 Do not limit the number of items in the stack to a value that fits
719 in 'int', as this is an arbitrary limit on hosts with 64-bit
720 size_t and 32-bit int.
722 2001-11-29 Marc Autret <autret_m@epita.fr>
724 * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead
725 of defining YYERROR_VERBOSE.
726 [AT_DATA]: $4 is now out of C declarations in the prologue.
728 2001-11-28 Marc Autret <autret_m@epita.fr>
730 * src/reader.c (parse_dquoted_param): New.
731 (parse_skel_decl): Use it.
732 * src/lex.h: Add its prototype.
733 * src/lex.c (literalchar): Become not static.
735 2001-11-28 Marc Autret <autret_m@epita.fr>
737 * src/output.h: And put its extern declaration here.
738 * src/output.c (error_verbose): Define here.
739 (prepare): Echo name modification.
740 * src/getargs.h: Clean its extern declaration.
741 * src/getargs.c (error_verbose_flag): Remove.
742 (getargs): Remove case 'e'.
743 * src/options.c (option_table): 'error-verbose' is now seen as simple
747 * src/reader.c (read_declarations): Remove case tok_include.
748 (parse_include_decl): Remove.
749 * src/lex.h (token_t): Remove tok_include.
750 * src/options.c (option_table): 'include' is now a simple command line
753 2001-11-28 Marc Autret <autret_m@epita.fr>
755 * src/bison.simple: Adjust muscle names.
756 * src/muscle_tab.c (muscle_init): Also rename the muscles.
757 * src/output.c (prepare): s/_/-/ for the muscles names.
758 (output_parser): When scanning for a muscle, allow '-' instead of '_'.
760 2001-11-28 Marc Autret <autret_m@epita.fr>
762 * src/bison.simple: Fix debug.
763 [YYERROR_VERBOSE]: Re-integrate as an internal macro.
765 2001-11-28 Akim Demaille <akim@epita.fr>
767 * src/LR0.c (shifts_new): New.
768 (save_shifts, insert_start_shift, augment_automaton): Use it.
770 2001-11-28 Akim Demaille <akim@epita.fr>
772 * src/closure.c (closure): `b' and `ruleno' denote the same value:
775 2001-11-28 Akim Demaille <akim@epita.fr>
777 * src/closure.c (closure): Instead of looping over word in array
778 then bits in words, loop over bits in array.
780 2001-11-28 Akim Demaille <akim@epita.fr>
782 * src/closure.c (closure): No longer optimize the special case
783 where all the bits of `ruleset[r]' are set to 0, to make the code
786 2001-11-28 Akim Demaille <akim@epita.fr>
788 * src/closure.c (closure): `r' and `c' are new variables, used to
789 de-obfuscate accesses to RULESET and CORE.
791 2001-11-28 Akim Demaille <akim@epita.fr>
793 * src/reduce.c (reduce_print): Use ngettext.
794 (dump_grammar): Improve the trace accuracy.
796 2001-11-28 Akim Demaille <akim@epita.fr>
798 * src/reduce.c (dump_grammar): Don't translate trace messages.
800 2001-11-28 Akim Demaille <akim@epita.fr>
802 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
803 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
804 as all tags are free'ed afterwards.
807 2001-11-27 Paul Eggert <eggert@twinsun.com>
809 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
810 use alloca when we didn't want to, and vice versa.
812 2001-11-27 Marc Autret <autret_m@epita.fr>
814 * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle
816 * src/output.c (prepare): Remove its update.
818 2001-11-27 Marc Autret <autret_m@epita.fr>
820 * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition.
823 2001-11-27 Marc Autret <autret_m@epita.fr>
825 * src/bison.simple: Remove YYERROR_VERBOSE using.
828 * src/output.c (prepare): Give its final value.
829 * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'.
830 * src/getargs.h: Add its extern declaration.
831 * src/getargs.c (error_verbose_flag): New int.
832 (getargs): Update to catch new case.
833 * src/options.c (option_table): 'error-verbose' is a new option.
836 2001-11-27 Akim Demaille <akim@epita.fr>
838 * src/system.h: Use intl/libgettext.h.
839 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
841 2001-11-27 Akim Demaille <akim@epita.fr>
843 * tests/torture.at (Exploding the Stack Size with Malloc):
844 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
846 2001-11-27 Akim Demaille <akim@epita.fr>
848 * src/files.c: Include error.h.
849 Reported by Hans Aberg.
851 2001-11-26 Marc Autret <autret_m@epita.fr>
853 * src/reader.c (parse_include_decl): New, not yet implemented.
854 (read_declarations): Add case tok_include.
855 * src/getargs.h (include): Add its extern definition.
856 * src/getargs.c (include): New const char *.
857 (getargs): Add case '-I'.
858 * src/options.c (option_table): Add include as command line and
860 * src/lex.h (token_t): Add tok_include.
862 2001-11-26 Akim Demaille <akim@epita.fr>
864 * src/reader.c (readgram): Make sure rules for mid-rule actions
865 have a lineno equal to that of their host rule.
866 Reported by Hans Aberg.
867 * tests/regression.at (Rule Line Numbers): New.
869 2001-11-26 Akim Demaille <akim@epita.fr>
871 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
874 2001-11-26 Akim Demaille <akim@epita.fr>
876 * src/complain.c, src/complain.h (error): Remove, provided by
879 2001-11-26 Akim Demaille <akim@epita.fr>
881 * src/reader.c (read_declarations): Don't abort on tok_illegal,
882 issue an error message.
883 * tests/regression.at (Invalid %directive): New.
884 Reported by Hans Aberg.
886 2001-11-26 Akim Demaille <akim@epita.fr>
888 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
889 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
891 2001-11-26 Akim Demaille <akim@epita.fr>
893 * src/conflicts.c (conflicts_print): Don't complain at all when
894 there are no reduce/reduce conflicts, and as many shift/reduce
895 conflicts as expected.
896 * tests/regression.at (%expect right): Adjust.
898 2001-11-23 Akim Demaille <akim@epita.fr>
900 * lib/alloca.c: Update, from fileutils.
902 2001-11-23 Akim Demaille <akim@epita.fr>
904 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
906 2001-11-23 Akim Demaille <akim@epita.fr>
908 * src/system.h: Include alloca.h.
909 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
911 2001-11-23 Akim Demaille <akim@epita.fr>
913 * src/print_graph.c (print_actions): Remove `rule', unused.
914 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
915 pacify GCC's signed < unsigned warnings.
916 * src/closure.c (itemsetsize): Likewise.
917 * src/reader.c (symbol_list_new): Static.
919 2001-11-23 Akim Demaille <akim@epita.fr>
921 Attaching lineno to buckets is stupid, since only one copy of each
922 symbol is kept, only the line of the first occurrence is kept too.
924 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
925 * src/reader.c (rline_allocated): Remove, unused.
926 (symbol_list): Have a `line' member.
927 (symbol_list_new): New.
929 * src/print.c (print_grammar): Output the rule line numbers.
930 * tests/regression.at (Solved SR Conflicts)
931 (Unresolved SR Conflicts): Adjust.
932 Reported by Hans Aberg.
934 2001-11-22 Marc Autret <autret_m@epita.fr>
936 * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0.
938 2001-11-22 Marc Autret <autret_m@epita.fr>
940 * src/muscle_tab.c (muscle_init): Remove initialization of
942 * src/output.c (output_master_parser): Do it here.
944 2001-11-20 Akim Demaille <akim@epita.fr>
947 * configure.in (ALL_LINGUAS): Adjust.
948 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
949 longer contains strings to translate.
951 2001-11-19 Akim Demaille <akim@epita.fr>
953 * src/conflicts.c (conflicts_print): Add a missing \n.
955 2001-11-19 Akim Demaille <akim@epita.fr>
957 * src/nullable.c (nullable_print): New.
958 (set_nullable): Call it when tracing.
959 Better locality of variables.
961 2001-11-19 Akim Demaille <akim@epita.fr>
963 * src/print.c (print_actions): Better locality of variables.
965 2001-11-19 Akim Demaille <akim@epita.fr>
967 * src/derives.c (print_derives): Fix and enrich.
968 * src/closure.c (print_fderives): Likewise.
970 2001-11-19 Akim Demaille <akim@epita.fr>
972 * src/closure.c (itemsetend): Remove, replaced with...
975 2001-11-19 Akim Demaille <akim@epita.fr>
977 * src/LR0.c (kernel_end): Remove, replaced with...
980 2001-11-19 Akim Demaille <akim@epita.fr>
982 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
985 2001-11-19 Akim Demaille <akim@epita.fr>
987 * src/closure.c (closure): Use arrays instead of pointers to clarify.
989 2001-11-19 Akim Demaille <akim@epita.fr>
991 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
993 * src/LR0.c: Likewise.
994 (allocate_itemsets): Use arrays instead of pointers to clarify.
996 2001-11-19 Akim Demaille <akim@epita.fr>
998 * src/getargs.c (statistics_flag): Replace with...
1000 (longopts): Accept --trace instead of --statistics.
1001 * src/getargs.h, src/options.c: Adjust.
1002 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
1003 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
1005 2001-11-19 Akim Demaille <akim@epita.fr>
1007 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
1008 pointers to clarify the code.
1009 (save_reductions, save_shifts): Factor common parts of alternatives.
1011 2001-11-19 Akim Demaille <akim@epita.fr>
1013 * src/LR0.c (new_state, get_state): Complete TRACE code.
1014 * src/closure.c: Include `reader.h' to get `tags', needed by the
1016 Rename the conditional DEBUG as TRACE.
1017 Output consistently TRACEs to stderr, not stdout.
1018 * src/derives.c: Likewise.
1019 * src/reduce.c: (inaccessable_symbols): Using if is better style
1021 Use `#if TRACE' instead of `#if 0' for tracing code.
1023 2001-11-19 Akim Demaille <akim@epita.fr>
1025 * src/system.h (LIST_FREE, shortcpy): New.
1026 * src/LR0.c: Use them.
1027 * src/output.c (free_itemsets, free_reductions, free_shifts):
1028 Remove, replaced by LIST_FREE.
1030 2001-11-19 Akim Demaille <akim@epita.fr>
1032 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
1033 (REDUCTIONS_ALLOC): New.
1034 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
1037 2001-11-19 Akim Demaille <akim@epita.fr>
1039 * src/LR0.c (new_state): Complete trace code.
1040 * src/nullable.c (set_nullable): Don't translate traces.
1042 2001-11-19 Akim Demaille <akim@epita.fr>
1044 * src/print_graph.c (print_core): Better locality of variables.
1045 * src/print.c (print_core): Likewise.
1047 2001-11-19 Akim Demaille <akim@epita.fr>
1049 * src/vcg.c: You do the output, so you are responsible of the
1050 handling of VCG syntax, in particular: use quotearg.
1051 * src/print_graph.c: Don't.
1052 (print_actions): Don't output the actions as part of the nodes,
1053 since that's the job of the edges.
1054 (print_state): Don't output by hand: fill the node description,
1055 and ask for its output.
1057 2001-11-19 Akim Demaille <akim@epita.fr>
1059 * src/bison.simple (yyparse): When verbosely reporting an error,
1060 no longer put additional quotes around token names.
1061 * tests/calc.at: Adjust.
1063 2001-11-19 Akim Demaille <akim@epita.fr>
1065 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
1066 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
1067 * src/output.c: Adjust.
1069 2001-11-19 Akim Demaille <akim@epita.fr>
1071 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
1073 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
1075 2001-11-19 Akim Demaille <akim@epita.fr>
1077 * src/gram.h (rule_t): New.
1079 (rrhs, rlhs): Remove, part of state_t.
1080 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
1081 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
1082 * src/reader.c, src/reduce.c: Adjust.
1084 2001-11-19 Akim Demaille <akim@epita.fr>
1086 * src/reader.c (symbols_output): New, extracted from...
1087 (packsymbols): Here.
1090 2001-11-19 Akim Demaille <akim@epita.fr>
1092 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
1093 (maxrhs): this new function.
1095 2001-11-19 Akim Demaille <akim@epita.fr>
1097 * src/lalr.c (F): New macro to access the variable F.
1100 2001-11-19 Akim Demaille <akim@epita.fr>
1102 * src/lalr.h (LA): New macro to access the variable LA.
1103 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1104 * src/lalr.c: Adjust.
1106 2001-11-19 Akim Demaille <akim@epita.fr>
1108 * src/lalr.c (initialize_LA): Only initialize LA. Let...
1109 (set_state_table): handle the `lookaheads' members.
1111 2001-11-19 Akim Demaille <akim@epita.fr>
1113 * src/lalr.h (lookaheads): Removed array, whose contents is now
1115 (state_t): this structure.
1116 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1119 2001-11-19 Akim Demaille <akim@epita.fr>
1121 * src/lalr.h (consistent): Removed array, whose contents is now
1123 (state_t): this structure.
1124 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1127 2001-11-19 Akim Demaille <akim@epita.fr>
1129 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
1130 contents are now members of...
1131 (state_t): this structure.
1132 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1135 2001-11-19 Akim Demaille <akim@epita.fr>
1137 * src/lalr.h (state_t): New.
1138 (state_table): Be a state_t * instead of a core **.
1139 (accessing_symbol): Remove, part of state_t.
1140 * src/lalr.c: Adjust.
1141 (set_accessing_symbol): Merge into...
1142 (set_state_table): this.
1143 * src/print_graph.c, src/conflicts.c: Adjust.
1145 2001-11-14 Akim Demaille <akim@epita.fr>
1147 * tests/calc.at, tests/output.at, tests/regression.at,
1148 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
1149 now the tests are run in private dirs, therefore AC_CLEANUP and
1150 family can be simplified to 0-ary.
1151 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
1152 use abs. path to find config.h.
1153 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
1154 stderr, there can be way too much random noise.
1155 Instead pass -Werror to GCC and rely on the exit status.
1156 Reported by Wolfram Wagner.
1158 2001-11-14 Akim Demaille <akim@epita.fr>
1160 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
1161 defined only if yyoverflow is defined, to avoid `warning: unused
1163 Reported by The Test Suite.
1165 2001-11-14 Akim Demaille <akim@epita.fr>
1167 * src/print.c: Include reduce.h.
1168 Reported by Hans Aberg.
1170 2001-11-14 Akim Demaille <akim@epita.fr>
1172 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
1173 Revert a previous patch: these are really const.
1174 * src/conflicts.c (conflict_report): Additional useless pair of
1175 braces to pacify GCC's warnings for `if () if () {} else {}'.
1176 * src/lex.c (parse_percent_token): Replace equal_offset with
1179 Be sure to strdup `arg' when used, since there is no reason for
1180 token_buffer not to change.
1182 2001-11-14 Akim Demaille <akim@epita.fr>
1184 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
1186 * src/main.c (main): Use them.
1187 Suggested by Hans Aberg.
1189 2001-11-12 Akim Demaille <akim@epita.fr>
1191 * src/system.h (ngettext): Now that we use ngettext, be sure to
1192 provide a default definition when NLS are not used.
1194 2001-11-12 Akim Demaille <akim@epita.fr>
1196 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
1197 Use @kbd to denote user input.
1198 (Language and Grammar): ANSIfy the example.
1199 Adjust its layout for info/notinfo.
1200 (Location Tracking Calc): Output error messages to stderr.
1201 Output locations in a more GNUtically correct way.
1202 Fix a couple of Englishos.
1203 Adjust @group/@end group pairs.
1205 2001-11-12 Akim Demaille <akim@epita.fr>
1207 %expext was not functioning at all.
1209 * src/conflicts.c (expected_conflicts): Set to -1.
1210 (conflict_report): Use ngettext.
1211 (conflicts_print): Check %expect and make its violation an error.
1212 * doc/bison.texinfo (Expect Decl): Adjust.
1213 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
1214 * tests/regression.at (%expect not enough, %expect right)
1215 (%expect too much): New.
1217 2001-11-12 Akim Demaille <akim@epita.fr>
1219 * tests/regression.at (Conflicts): Rename as...
1220 (Unresolved SR Conflicts): this.
1221 (Solved SR Conflicts): New.
1223 2001-11-12 Akim Demaille <akim@epita.fr>
1225 * src/reduce.c (print_results): Rename as...
1226 (reduce_output): This.
1227 Output to OUT, passed as argument, instead of output_obstack.
1228 (dump_grammar): Likewise.
1231 (reduce_grammar): No longer call reduce_output, since...
1232 * src/print.c (print_results): do it.
1233 * src/main.c (main): Call reduce_free;
1235 2001-11-12 Akim Demaille <akim@epita.fr>
1237 * src/conflicts.c (print_reductions): Accept OUT as argument.
1238 Output to it, not to output_obstack.
1239 * src/print.c (print_actions): Adjust.
1241 2001-11-12 Akim Demaille <akim@epita.fr>
1243 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
1244 the result instead of using...
1245 (src_total, rrc_total, src_count, rrc_count): Remove.
1246 (any_conflicts): Remove.
1247 (print_conflicts): Split into...
1248 (conflicts_print, conflicts_output): New.
1249 * src/conflicts.h: Adjust.
1250 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
1251 * src/print.c (print_grammar): Issue `\n' between two rules.
1252 * tests/regression.at (Conflicts): New.
1253 Reported by Tom Lane.
1255 2001-11-12 Akim Demaille <akim@epita.fr>
1257 * tests/regression.at (Invalid input): Remove, duplicate with
1258 ``Invalid input: 1''.
1260 2001-11-12 Akim Demaille <akim@epita.fr>
1262 * tests/torture.at (AT_DATA_STACK_TORTURE)
1263 (Exploding the Stack Size with Alloca)
1264 (Exploding the Stack Size with Malloc): New.
1266 2001-11-12 Akim Demaille <akim@epita.fr>
1268 * src/bison.simple (YYSTACK_REALLOC): New.
1269 (yyparse) [!yyoverflow]: Use it and free the old stack.
1270 Reported by Per Allansson.
1272 2001-11-12 Pascal Bart <pascal.bart@epita.fr>
1274 * src/bison.simple: Define type yystype instead of YYSTYPE, and
1275 define CPP macro, which substitute YYSTYPE by yystype.
1276 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
1277 with yyltype/YYLTYPE. This allows inclusion of the generated
1278 header within the parser if the compiler, such as GGC, accepts
1279 multiple equivalent #defines.
1282 2001-11-05 Akim Demaille <akim@epita.fr>
1284 * src/reader.c (symbols_output): New, extracted from...
1285 (packsymbols): here.
1288 2001-11-05 Akim Demaille <akim@epita.fr>
1290 * src/lex.c (parse_percent_token): s/quotearg/quote/.
1292 2001-11-05 Akim Demaille <akim@epita.fr>
1294 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
1297 2001-11-05 Akim Demaille <akim@epita.fr>
1299 * src/options.h (struct option_table_struct): set_flags is void*.
1300 * src/options.c (longopts): Support `--output' and `%output'.
1302 * src/lex.h (tok_setopt): Remove, replaced with...
1303 (tok_intopt, tok_stropt): these new guys.
1304 * src/lex.c (getopt.h): Not needed.
1305 (token_buffer, unlexed_token_buffer): Not const.
1306 (percent_table): Promote `-' over `_' in directive names.
1307 Active `%name-prefix', `file-prefix', and `output'.
1308 (parse_percent_token): Accept possible arguments to directives.
1309 Promote `-' over `_' in directive names.
1311 2001-11-04 Akim Demaille <akim@epita.fr>
1313 * doc/bison.texinfo (Decl Summary): Split the list into
1314 `directives for grammars' and `directives for bison'.
1316 Add description of `%name-prefix', `file-prefix', and `output'.
1317 Promote `-' over `_' in directive names.
1318 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
1319 Simplify the description of `--name-prefix'.
1320 Promote `-' over `_' in directive names.
1321 Promote `--output' over `--output-file'.
1322 Fix the description of `--defines'.
1323 * tests/output.at: Exercise %file-prefix and %output.
1325 2001-11-02 Akim Demaille <akim@epita.fr>
1327 * doc/refcard.tex: Update.
1329 2001-11-02 Akim Demaille <akim@epita.fr>
1331 * src/symtab.h (SUNDEF): New.
1332 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
1333 stand for `uninitialized', instead of 0.
1334 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
1335 * src/lex.c (lex): Adjust.
1337 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
1339 Let yylex return it instead of a plain 0.
1340 Reported by Dick Streefland.
1342 2001-11-02 Akim Demaille <akim@epita.fr>
1344 * tests/regression.at (Mixing %token styles): New test.
1346 2001-11-02 Akim Demaille <akim@epita.fr>
1348 * src/reader.c (parse_thong_decl): Formatting changes.
1349 (token_translations_init): New, extracted from...
1350 (packsymbols): Here.
1353 2001-11-01 Akim Demaille <akim@epita.fr>
1355 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
1356 Check that `9foo.y' produces correct cpp guards.
1357 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
1361 2001-11-01 Akim Demaille <akim@epita.fr>
1363 * tests/regression.at (Invalid input: 2): New.
1364 * src/lex.c (unlexed_token_buffer): New.
1365 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
1369 2001-11-01 Akim Demaille <akim@epita.fr>
1371 * tests/calc.at: Catch up with 1.30.
1372 * configure.in: Bump to 1.49a.
1373 Adjust to newer Autotest.
1375 2001-10-19 Pascal Bart <pascal.bart@epita.fr>
1377 * src/conflicts.c: Move global variables rrc_total and src_total ...
1378 (print_conflicts): here.
1379 * src/output.c (output): Free global variable user_toknums.
1380 * src/lex.c (token_obstack): Become static.
1382 2001-10-18 Akim Demaille <akim@epita.fr>
1384 * tests/atlocal.in (GCC): Add.
1385 * tests/calc.at: s/m4_match/m4_bmatch/.
1386 s/m4_patsubst/m4_bpatsubst/.
1387 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
1388 * configure.in: AC_SUBST(GCC).
1390 2001-10-14 Marc Autret <autret_m@epita.fr>
1392 * src/options.c (create_long_option_table): Fix.
1394 2001-10-10 Akim Demaille <akim@epita.fr>
1396 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
1398 2001-10-04 Akim Demaille <akim@epita.fr>
1400 * src/reader.c (parse_union_decl): Push the caracters in
1401 union_obstack, not attrs_obstack.
1403 2001-10-04 Akim Demaille <akim@epita.fr>
1405 Merge in the branch 1.29.
1407 * src/reader.c (packsymbols): Use a temporary obstack for
1408 `%%tokendef', since output_stack is already used elsewhere.
1410 2001-10-02 Akim Demaille <akim@epita.fr>
1414 2001-10-02 Akim Demaille <akim@epita.fr>
1418 2001-10-02 Akim Demaille <akim@epita.fr>
1420 * tests/regression.at (Invalid CPP headers): New.
1421 From Alexander Belopolsky.
1422 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
1424 2001-10-02 Akim Demaille <akim@epita.fr>
1426 * tests/regression.at (Invalid input): New.
1427 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
1430 2001-10-02 Akim Demaille <akim@epita.fr>
1432 * tests/calc.at: Now that --debug works, the tests must be adjusted.
1434 2001-10-02 Akim Demaille <akim@epita.fr>
1436 * src/output.c (output_parser): Assert `skeleton'.
1437 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
1441 2001-10-01 Marc Autret <autret_m@epita.fr>
1443 * src/lex.h: Echo modifications.
1444 * src/lex.c (unlex): Parameter is now token_t.
1447 2001-10-01 Marc Autret <autret_m@epita.fr>
1449 * src/main.c: Include lex.h.
1452 2001-09-29 Akim Demaille <akim@epita.fr>
1454 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
1456 2001-09-28 Akim Demaille <akim@epita.fr>
1458 * tests/testsuite.at: Update to newer Autotest.
1459 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
1461 2001-09-27 Akim Demaille <akim@epita.fr>
1463 Position independent wrapper.
1465 * tests/bison: Remove.
1466 * tests/bison.in: New.
1467 * configure.in: Adjust.
1469 2001-09-27 Paul Eggert <eggert@twinsun.com>
1471 Port quotearg fixes from tar 1.13.24.
1473 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
1475 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
1476 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
1478 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
1479 * m4/mbrtowc.m4: New file.
1480 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
1481 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
1483 2001-09-27 Akim Demaille <akim@epita.fr>
1487 2001-09-27 Akim Demaille <akim@epita.fr>
1491 2001-09-25 Akim Demaille <akim@epita.fr>
1493 * src/system.h: Include `xalloc.h'.
1494 Remove it from the C files.
1495 * src/files.c (output_files): Free the obstacks.
1496 * src/lex.c (init_lex): Rename as...
1499 * src/main.c (main): Use it.
1501 2001-09-24 Marc Autret <autret_m@epita.fr>
1503 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
1504 to output informations in fout (FILE*).
1505 (open_graph, close_graph): Likewise.
1506 (output_graph, output_edge, output_node): Likewise.
1507 * src/vcg.h: Update function prototypes.
1508 * src/print_graph.c (print_graph): Open output graph file.
1509 (print_actions): Adjust.
1510 * src/files.h: Remove extern declaration.
1511 * src/files.c: Remove graph_obstack declaration.
1512 (open_files): Remove graph_obstack initialization.
1513 (output_files): Remove graph_obstack saving.
1515 2001-09-24 Marc Autret <autret_m@epita.fr>
1517 * src/files.c (compute_output_file_names): Fix.
1519 2001-09-24 Marc Autret <autret_m@epita.fr>,
1520 Akim Demaille <akim@epita.fr>
1522 * src/reader.c (reader): Remove call to free_symtab ().
1523 * src/main.c (main): Call it here.
1525 * src/conflicts.c (initialize_conflicts): Rename as...
1526 (solve_conflicts): this.
1527 * src/print.c (print_core, print_actions, print_state)
1528 (print_grammar): Dump to a file instead a `output_obstack'.
1529 (print_results): Dump `output_obstack', and then proceed with the
1531 * src/files.c (compute_output_file_names, close_files): New.
1532 (output_files): Adjust.
1533 * src/main.c (main): Adjust.
1535 2001-09-23 Marc Autret <autret_m@epita.fr>
1537 * src/files.c (compute_header_macro): Computes header macro name
1538 from spec_defines_file when given.
1540 2001-09-23 Marc Autret <autret_m@epita.fr>
1542 * src/files.c (output_files): Add default extensions.
1544 2001-09-22 Akim Demaille <akim@epita.fr>
1546 * src/conflicts.c (finalize_conflicts): Rename as...
1547 (free_conflicts): this.
1549 2001-09-22 Akim Demaille <akim@epita.fr>
1551 * src/gram.c (gram_free): Rename back as...
1553 (output_token_translations): Free `token_translations'.
1554 * src/symtab.c (free_symtab): Free the tag field.
1556 2001-09-22 Akim Demaille <akim@epita.fr>
1558 Remove `translations' as it is always set to true.
1560 * src/gram.h: Adjust.
1561 * src/reader.c (packsymbols, parse_token_decl): Adjust
1562 * src/print.c (print_grammar): Adjust.
1563 * src/output.c (output_token_translations): Adjust.
1564 * src/lex.c (lex): Adjust.
1565 * src/gram.c: Be sure the set pointers to NULL.
1566 (dummy): Rename as...
1569 2001-09-22 Akim Demaille <akim@epita.fr>
1571 * configure.in: Invoke AM_LIB_DMALLOC.
1572 * src/system.h: Use dmalloc.
1573 * src/LR0.c: Be sure to have pointers initialized to NULL.
1574 (allocate_itemsets): Allocate kernel_items only if needed.
1576 2001-09-22 Akim Demaille <akim@epita.fr>
1578 * configure.in: Bump to 1.29b.
1579 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
1580 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
1581 need xmalloc.c in calc.y.
1584 2001-09-21 Akim Demaille <akim@epita.fr>
1587 * Makefile.maint, config/config.guess, config/config.sub,
1588 * config/missing: Update from masters.
1589 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
1591 * configure.in (ALL_LINGUAS): Add `tr'.
1593 2001-09-21 Akim Demaille <akim@epita.fr>
1595 * tests/Makefile.am (package.m4): Move to...
1596 ($(srcdir)/$(TESTSUITE)): here.
1598 2001-09-20 Akim Demaille <akim@epita.fr>
1600 * src/complain.c: No longer try to be standalone: use system.h.
1601 Don't assume __STDC__ is defined to 1. Just test if it is defined.
1602 * src/complain.h: Likewise.
1603 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
1604 Remove the unused variable `n'.
1605 From Albert Chin-A-Young.
1607 2001-09-18 Marc Autret <autret_m@epita.fr>
1609 * doc/bison.1: Update.
1610 * doc/bison.texinfo (Bison Options): Update --defines and --graph
1612 (Option Cross Key): Update.
1615 2001-09-18 Marc Autret <autret_m@epita.fr>
1617 * tests/regression.at: New test (comment in %union).
1619 2001-09-18 Marc Autret <autret_m@epita.fr>
1621 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
1623 Reported by Keith Browne.
1625 2001-09-18 Marc Autret <autret_m@epita.fr>
1627 * tests/output.at: Add tests for --defines and --graph.
1629 2001-09-18 Marc Autret <autret_m@epita.fr>
1631 * tests/output.at: Removes tests of %{header,src}_extension features.
1633 2001-09-18 Akim Demaille <akim@epita.fr>
1635 * tests/Makefile.am (package.m4): New.
1636 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
1637 (_AT_CHECK_CALC_ERROR): Likewise.
1638 Factor the `, ' part of verbose error messages.
1640 2001-09-18 Marc Autret <autret_m@epita.fr>
1642 * src/getargs.c (longopts): Declare --defines and --graph as options
1643 with optional arguments.
1644 * src/files.h: Add extern declarations.
1645 * src/files.c (spec_graph_file, spec_defines_file): New.
1646 (output_files): Update.
1647 Remove CPP-outed code.
1649 2001-09-18 Marc Autret <autret_m@epita.fr>
1651 Turn off %{source,header}_extension feature.
1653 * src/files.c (compute_exts_from_gf): Update.
1654 (compute_exts_from_src): Update.
1655 (output_files): CPP-out useless code.
1656 * src/files.h: Remove {header,source}_extension extern declarations.
1657 * src/reader.c (parse_dquoted_param): CPP-out.
1658 (parse_header_extension_decl): Remove.
1659 (parse_source_extension_decl): Remove.
1660 (read_declarations): Remove cases tok_{hdrext,srcext}.
1661 * src/lex.c (percent_table): Remove {header,source}_extension entries.
1662 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
1664 2001-09-10 Akim Demaille <akim@epita.fr>
1666 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
1667 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
1668 (AT_CHECK_OUTPUT): this.
1669 Merely check ls' exit status, its output is useless.
1671 2001-09-10 Akim Demaille <akim@epita.fr>
1673 * tests/calc.at: Use m4_match.
1674 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
1676 2001-09-10 Marc Autret <autret_m@epita.fr>,
1677 Akim Demaille <akim@epita.fr>
1679 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
1681 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
1683 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
1684 * src/lex.h: Adjust prototype.
1685 (token_t): Add `tok_undef'.
1686 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
1687 (parse_percent_token): Now returns token_t.
1688 Add default statement in switch.
1689 (lex): Separate `c' as an input variable, from the token_t result
1691 (unlexed): Is a token_t.
1693 2001-09-10 Akim Demaille <akim@epita.fr>
1695 * configure.in: Bump to 1.29a.
1697 2001-09-07 Akim Demaille <akim@epita.fr>
1701 2001-08-30 Akim Demaille <akim@epita.fr>
1703 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
1704 * m4/atconfig.m4: Remove.
1705 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
1707 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
1708 m4_if, m4_patsubst, and m4_regexp.
1709 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
1710 `input' file instead of echo.
1712 2001-08-29 Akim Demaille <akim@epita.fr>
1716 2001-08-29 Akim Demaille <akim@epita.fr>
1720 2001-08-29 Paul Eggert <eggert@twinsun.com>
1722 * src/bison.simple (yyparse): Don't take the address of an
1723 item before the start of an array, as that doesn't conform to
1726 2001-08-29 Robert Anisko <anisko_r@epita.fr>
1728 * doc/bison.texinfo (Location Tracking Calc): New node.
1730 2001-08-29 Paul Eggert <eggert@twinsun.com>
1732 * src/output.c (output): Do not define const, as this now
1733 causes more problems than it cures.
1735 2001-08-29 Akim Demaille <akim@epita.fr>
1737 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
1739 Be sure to tag the `detailmenu'.
1741 2001-08-29 Akim Demaille <akim@epita.fr>
1743 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
1744 download in a tmp dir.
1746 2001-08-28 Marc Autret <autret_m@epita.fr>
1748 * config/depcomp: New file.
1750 2001-08-28 Marc Autret <autret_m@epita.fr>
1752 * doc/bison.1 (mandoc): Adjust.
1753 From Juan Manuel Guerrero.
1755 2001-08-28 Marc Autret <autret_m@epita.fr>
1757 * src/print_graph.c (print_state): Fix.
1759 2001-08-27 Marc Autret <autret_m@epita.fr>
1761 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
1763 Echo modifications to the functions prototypes.
1764 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
1766 2001-08-27 Marc Autret <autret_m@epita.fr>
1768 * src/vcg.c: Include `xalloc.h'.
1769 (add_colorentry): New.
1770 (add_classname): New.
1771 (add_infoname): New.
1772 * src/vcg.h: Add new prototypes.
1774 2001-08-27 Akim Demaille <akim@epita.fr>
1776 * Makefile.maint: Sync. again with CVS Autoconf.
1778 2001-08-27 Akim Demaille <akim@epita.fr>
1780 * Makefile.maint: Formatting changes.
1781 (po-update, cvs-update, update): New targets.
1784 2001-08-27 Akim Demaille <akim@epita.fr>
1786 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
1787 * Makefile.maint: Sync. with CVS Autoconf.
1789 2001-08-27 Marc Autret <autret_m@epita.fr>
1791 * src/vcg.h (struct infoname_s): New.
1792 (struct colorentry_s): New.
1793 (graph_s): New fields {vertical,horizontal}_order in structure.
1794 Add `infoname' field.
1795 Add `colorentry' field;
1796 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
1797 (G_HORIZONTAL_ORDER): New.
1799 (G_COLORENTRY): New.
1800 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
1801 Add output of `infoname'.
1802 Add output of `colorentry'.
1804 2001-08-27 Marc Autret <autret_m@epita.fr>
1806 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
1807 This one shadowed a global parameter.
1809 2001-08-24 Marc Autret <autret_m@epita.fr>
1811 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
1812 instead of `unsigned'.
1813 (print_state): Do not call obstack_object_size () in obstack_grow ()
1814 to avoid macro variables shadowing.
1816 2001-08-23 Marc Autret <autret_m@epita.fr>
1818 * src/lex.c (percent_table): Typo: s/naem/name/.
1820 Normalize new options declarations.
1822 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
1824 * tests/suite.at: Exercise %header_extension and %source_extension.
1826 2001-08-16 Marc Autret <autret_m@epita.fr>
1828 * src/reader.c (parse_dquoted_param): New.
1829 (parse_header_extension_decl): Use it.
1830 (parse_source_extension_decl): Likewise.
1832 2001-08-16 Marc Autret <autret_m@epita.fr>
1834 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
1835 (get_xxxx_str): Use assert () instead of complain ().
1836 Remove return invokations in default cases.
1837 (get_decision_str): Modify default behaviour. Remove second argument.
1838 Echo modifications on calls.
1839 (output_graph): Fix.
1841 2001-08-16 Marc Autret <autret_m@epita.fr>
1843 * src/getargs.c (usage): Update with ``-g, --graph''.
1845 2001-08-16 Marc Autret <autret_m@epita.fr>
1847 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
1848 (Option Cross Key): Likewise.
1849 * doc/bison.1: Update.
1851 2001-09-25 Pascal Bart <pascal.bart@epita.fr>
1853 * src/output.c (output_master_parser): Don't finish action_obstack.
1854 (output_parser): Don't care about the muscle action, here.
1855 (prepare): Copy the action_obstack in the action muscle.
1856 (output): Free action_obstack.
1858 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
1860 * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which
1861 will contain `%union' declaration.
1862 (parse_union_decl): Delete #line directive output.
1863 (parse_union_decl): Substitute /attrs_obstack/union_obstack for all
1864 informations about %union.
1865 (parse_union_decl): Copy the union_obstack in the muscle stype.
1866 * src/bison.simple: Add new #line directive.
1867 Add typdef %%stype YYSTYPE.
1869 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
1871 * src/bison.simple: Add new `#line' directive.
1873 2001-09-22 Pascal Bart <pascal.bart@epita.fr>
1875 * src/bison.simple: New `#line' directive.
1876 * src/output.c (output_parser): Support new dynamic muscle input_line.
1878 2001-09-22 Marc Autret <autret_m@epita.fr>
1880 * src/output.c (output_master_parser): New.
1881 (output_parser): Be more re-entrant.
1883 2001-09-21 Marc Autret <autret_m@epita.fr>
1885 * src/reader.c (copy_definition, parse_union_decl): Update and use
1887 (copy_action): Likewise.
1888 Use obstack_1grow ().
1889 * src/muscle_tab.c (muscle_init): Add muscle `linef'.
1891 2001-09-21 Marc Autret <autret_m@epita.fr>
1893 * src/options.c (option_table): Adjust.
1894 * src/lex.c (parse_percent_token): Fix.
1896 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
1898 * src/options.c (symtab.h): Include it, need by lex.h.
1900 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
1902 * src/lex.c (parse_percent_token): Change type of variable `tx', which
1903 is now an option_table_struct*.
1904 (option_strcmp): New function option_strcmp.
1905 (parse_percent_token): Call option_strcmp.
1906 * src/getargs.c (xalloc.h, options.h): Include it.
1907 (getargs): Call create_long_option_table.
1908 (getargs): Free longopts at the end of the function.
1909 (shortopts): Move in options.c.
1910 * src/options.c (create_long_option_table): New function. Convert
1911 information from option_table to option structure.
1912 * src/reader.c (options.h): Include it.
1914 * src/Makefile.am: Adjust.
1915 * src/options.c (option_table): Create from longopts and percent_table.
1916 * src/getargs.c (longopts): Delete.
1917 * src/lex.c (struct percent_table_struct): Delete.
1918 (percent_table): Delete.
1919 (options.h): Include it.
1920 * src/options.c: Create.
1921 * src/options.h: Create.
1922 Declare enum opt_access_e.
1923 Define struct option_table_struct.
1925 2001-09-20 Marc Autret <autret_m@epita.fr>
1927 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
1930 2001-09-19 Pascal Bart <pascal.bart@epita.fr>
1932 * src/bison.simple: s/%%filename/%%skeleton.
1933 * src/muscle_tab.c (getargs.h): Include it.
1934 (muscle_init): Insert new muscle skeleton.
1936 2001-09-18 Pascal Bart <pascal.bart@epita.fr>
1938 * src/output.c (output_parser): Delete unused variable actions_dumped.
1940 2001-09-07 Pascal Bart <pascal.bart@epita.fr>
1942 * src/output.c (output): Delete call to reader_output_yylsp.
1943 * src/reader.c (reader): Likewise.
1944 * src/reader.h: Delete declaration of reader_output_yylsp.
1946 2001-09-02 Marc Autret <autret_m@epita.fr>
1948 * src/reader.c: Include muscle_tab.h.
1949 (parse_union_decl): Update.
1950 (parse_macro_decl): Rename parse_muscle_decl.
1951 Update to use renamed functions and variable.
1952 (read_declarations, copy_action, read_additionnal_code, : Updated
1953 with correct variables and functions names.
1954 (packsymbols, reader): Likewise.
1956 * src/reader.h (muscle_obstack): Extern declaration update.
1958 * src/output.c: Include muscle_tab.h
1959 In all functions using macro_insert, change by using muscle_insert ().
1960 (macro_obstack): Rename muscle_obstack.
1961 Echo modifications in the whole file.
1962 (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT.
1963 (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING.
1964 (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX.
1966 * src/muscle_tab.h: Update double inclusion macros.
1967 (macro_entry_s): Rename muscle_entry_s.
1970 * src/muscle_tab.c: Include muscle_tab.h.
1971 Rename macro_tabble to muscle_table.
1972 (mhash1, mhash2, mcmp): Use muscle_entry.
1973 (macro_init): Rename muscle_init. Update.
1974 (macro_insert): Rename muscle_insert. Update.
1975 (macro_find): Rename muscle_find. Update.
1977 * src/main.c: Include muscle_tab.h.
1978 (main): Call muscle_init ().
1979 * src/Makefile.am (bison_SOURCES): Echo modifications.
1981 2001-09-02 Marc Autret <autret_m@epita.fr>
1983 Now the files macro_tab.[ch] are named muscle_tab.[ch].
1985 * src/muscle_tab.c, src/muscle_tab.h: Add files.
1987 2001-09-02 Marc Autret <autret_m@epita.fr>
1989 * src/macrotab.c, src/macrotab.h: Remove.
1991 2001-09-01 Pascal Bart <pascal.bart@epita.fr>
1993 * src/reader.c (copy_guard): Use muscle to specify the `#line'
1996 2001-09-01 Marc Autret <autret_m@epita.fr>
1998 * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set
1999 to an explicit value to activate the feature. We do it here.
2001 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2003 * src/output.c (prepare): Delete the `filename' muscule insertion.
2004 * src/reader.c (copy_action): Use `filename' muscule with `#line'.
2005 (parse_union_decl): Likewise.
2006 * src/macrotab.c (macro_init): Initialize filename by infile.
2008 2001-08-31 Marc Autret <autret_m@epita.fr>
2010 * src/bison.simple (YYLSP_NEEDED): New definition.
2011 * src/output.c (prepare): Add macro insertion of `locations_flag'
2013 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2015 * src/output.c (prepare): Delete insertion of previous muscles,
2016 and insert the `prefix' muscles.
2017 * src/macrotab.c (macro_init): Likewise.
2018 (macro_init): Initialization prefix directive by `yy'.
2019 * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval,
2020 %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar,
2021 yylval, yydebug, yyerror, yynerrs and yyparse.
2022 New directive `#define' to substitute yydebug, ... with option
2025 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2027 * src/main.c (main): Standardize.
2028 * src/output.c (output_table_data, output_parser): Likewise.
2029 * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise.
2031 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr>
2033 * src/reader.c (read_additionnal_code): Rename %%user_code to
2035 * src/output.c (output): Rename %%declarations to %%prologue.
2036 * src/bison.simple: Echo modifications.
2038 2001-08-31 Marc Autret <autret_m@epita.fr>
2040 * src/reader.c (readgram): CleanUp.
2041 (output_token_defines): Likewise.
2042 (packsymbols): Likewise.
2044 * src/output.c (output): CPP-out useless code.
2046 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2048 * src/reader.c (reader): Delete obsolete call to function
2049 output_trailers and output_headers.
2050 * src/output.h: Remove obsolete functions prototypes of output_headers
2051 and output_trailers.
2053 2001-08-30 Pascal Bart <pascal.bart@epita.fr>
2055 * src/main.c: Include macrotab.h.
2056 * src/macrotab.h (macro_entry_s): Constify fields.
2057 Adjust functions prototypes.
2058 * src/macrotab.c (macro_insert): Constify key and value.
2059 (macro_find): Constify key.
2060 (macro_insert): Include 'xalloc.h'
2061 (macro_insert): Use XMALLOC.
2062 (macro_find): Constify return value.
2063 * src/output.c (output_table_data): Rename table to table_data.
2064 (output_parser): Constify macro_key, macro_value.
2066 2001-08-30 Marc Autret <autret_m@epita.fr>
2068 * src/reader.c (parse_skel_decl): New.
2069 (read_declarations): Add case `tok_skel', call parse_skel_decl ().
2070 * src/lex.h (token_t): New token `tok_skel'.
2071 * src/lex.c (percent_table): Add skeleton option entry.
2074 2001-08-29 Marc Autret <autret_m@epita.fr>
2076 * src/bison.simple: Add %%user_code directive at the end.
2077 * src/reader.c (read_additionnal_code): New.
2079 * src/output.c (output_program): Remove.
2082 2001-08-28 Marc Autret <autret_m@epita.fr>
2084 * src/output.c (output_actions): Clean up.
2085 (output_gram): CPP-out useless code.
2086 * src/reader.c (reader): Clean up, CPP-out useless code.
2088 2001-08-28 Pascal Bart <pascal.bart@epita.fr>
2090 * src/output.c (output): Copy attrs_obstack in the '%%definitions'
2092 * src/bison.simple: Add `%%definitions'.
2094 2001-08-28 Marc Autret <autret_m@epita.fr>
2096 * config/depcomp: New file.
2098 2001-08-27 Paul Eggert <eggert@twinsun.com>
2100 * src/bison.simple (yyparse): Don't take the address of an
2101 item before the start of an array, as that doesn't conform to
2104 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2106 * src/output.c (output): Remove the initialization of the macro
2107 obstack. It was done too late here.
2109 * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was
2111 (reader): Initialize the macro obstack here, since we need it to grow
2112 '%define' directives.
2114 * src/reader.h: Declare the macro obstack as extern.
2116 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2118 * src/output.c (output_parser): Fix. Store single '%' characters in
2119 the output obstack instead of throwing them away.
2121 2001-08-27 Akim Demaille <akim@epita.fr>
2123 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
2125 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2127 * lib/Makefile.am: Adjust.
2129 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2131 * src/bison.simple: Update and add '%%' directives.
2133 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2135 * src/reader.c (reader): Remove calls to 'output_headers' and
2136 'output_trailers'. Remove some C output.
2137 (readgram): Disable a piece of code that was writing a default
2138 definition for 'YYSTYPE'.
2139 (reader_output_yylsp): Remove.
2140 (packsymbols): Output token defintions to a macro.
2141 (copy_definition): Disable C output.
2143 * src/reader.c (parse_macro_decl): New function used to parse macro
2145 (copy_string2): Put the body of copy_string into this new function.
2146 Add a parameter to let the caller choose whether he wants to copy the
2147 string delimiters or not.
2148 (copy_string): Be a simple call to copy_string2 with the last argument
2150 (read_declarations): Add case for macro definition.
2151 (copy_identifier): New.
2152 (parse_macro_decl): Read macro identifiers using copy_identifier
2155 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2157 * src/output.c (prepare): Add prefixed names.
2158 (output_parser): Output semantic actions.
2159 (output_parser): Fix bug on '%%line' directives.
2161 * src/output.c (output_headers): Remove. The C code printed by this
2162 function should now be in the skeletons.
2163 (output_trailers): Remove.
2164 (output): Disable call to 'reader_output_yylsp'.
2165 (output_rule_data): Do not output tables to the table obstack.
2167 * src/output.c: Remove some C dedicated output.
2168 Improve the use of macro and output obstacks.
2169 (output_defines): Remove.
2171 * src/output.c (output_token_translations): Associate 'translate'
2172 table with a macro. No output to the table obstack.
2173 (output_gram): Same for 'rhs' and 'prhs'.
2174 (output_stos): Same for 'stos'.
2175 (output_rule_data): Same for 'r1' and 'r2'.
2176 (token_actions): Same for 'defact'.
2177 (goto_actions): Same for 'defgoto'.
2178 (output_base): Same for 'pact' and 'pgoto'.
2179 (output_table): Same for 'table'.
2180 (output_check): Same for 'check'.
2182 * src/output.c (output_table_data): New function.
2183 (output_short_table): Remove.
2184 (output_short_or_char_table): Remove.
2186 * src/output.c (output_parser): Replace most of the skeleton copy code
2187 with something new. Skeletons are now processed character by character
2188 rather than line by line, and Bison looks for '%%' macros. This is the
2189 first step in making Bison's output process (a lot) more flexible.
2190 (output_parser): Use the macro table.
2192 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2194 * src/main.c (main): Initialize the macro table.
2196 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2198 * src/lex.c (percent_table): Add tok_define.
2199 * src/lex.h: Add tok_define.
2201 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2203 * src/macrotab.c: New file.
2204 * src/macrotab.h: New file.
2205 * src/Makefile.am: Update.
2207 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2209 * lib/hash.c: New file.
2210 * lib/hash.h: New file.
2211 * lib/Makefile.am: Update.
2213 2001-08-15 Akim Demaille <akim@epita.fr>
2217 2001-08-15 Marc Autret <autret_m@epita.fr>
2219 * src/reader.c (readgram): Indent output macro YYSTYPE.
2220 (packsymbols): Likewise.
2221 (output_token_defines): Likewise.
2222 * src/files.c: Standardize.
2223 (compute_header_macro): New.
2224 (defines_obstack_save): New. Use compute_header_macro.
2225 (output_files): Update. Use defines_obstack_save.
2227 2001-08-15 Akim Demaille <akim@epita.fr>
2229 * doc/bison.texinfo (Table of Symbols): Document
2232 2001-08-15 Akim Demaille <akim@epita.fr>
2234 * missing: Update from CVS Automake.
2235 * config/config.guess, config/config.sub, config/texinfo.tex:
2236 Update from gnu.org.
2238 2001-08-15 Akim Demaille <akim@epita.fr>
2240 * Makefile.maint: Sync with CVS Autoconf.
2242 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
2244 * doc/bison.texinfo: Include GNU Free Documentation License from
2246 * doc/fdl.texi: Add to package.
2248 2001-08-14 Marc Autret <autret_m@epita.fr>
2250 Turn on %{source,header}_extension features.
2252 * src/lex.c (percent_table): Un-CPP out header_extension and
2254 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
2255 (compute_exts_from_src): Remove conditions. It restores priorities
2258 2001-08-14 Marc Autret <autret_m@epita.fr>
2260 * src/files.c (compute_base_names): Add extensions computing when
2261 `--file-prefix' used.
2262 Standardize function calls.
2264 2001-08-13 Marc Autret <autret_m@epita.fr>
2266 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
2267 defining it (defined but null disables alloca).
2269 2001-08-13 Marc Autret <autret_m@epita.fr>
2271 * src/bison.simple (_yy_memcpy): CPP reformat.
2273 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
2275 * tests/atconfig.in (CPPFLAGS): Fix.
2277 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
2279 * doc/bison.texinfo: Include GNU General Public License from
2281 * doc/gpl.texi: Add to package.
2283 2001-08-10 Marc Autret <autret_m@epita.fr>
2285 * src/print_graph.h: Fix.
2286 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
2288 2001-08-10 Akim Demaille <akim@epita.fr>
2290 * src/system.h: Provide default declarations for stpcpy, strndup,
2293 2001-08-10 Robert Anisko <anisko_r@epita.fr>
2295 * doc/bison.texinfo (Locations): Update @$ stuff.
2297 2001-08-09 Robert Anisko <anisko_r@epita.fr>
2299 * src/bison.simple (YYLLOC_DEFAULT): Update.
2302 2001-08-08 Marc Autret <autret_m@epita.fr>
2304 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
2305 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
2306 Reported by Fabrice Bauzac.
2308 2001-08-08 Marc Autret <autret_m@epita.fr>
2310 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
2311 * src/vcg.c (output_node): Fix.
2312 * src/vcg.h: Cleanup.
2313 * src/print_graph.c: Add comments.
2314 (node_output_size): New global variable. Simplify the formatting of
2315 the VCG graph output.
2316 (print_actions): Unused code is now used. It notifies the final state
2317 and no action states in the VCG graph. It also give the reduce actions.
2318 The `shift and goto' edges are red and the `go to state' edges are
2320 Get the current node name and node_obstack by argument.
2321 (node_obstack): New variable.
2322 (print_state): Manage node_obstack.
2323 (print_core): Use node_obstack given by argument.
2324 A node is not only computed here but in print_actions also.
2325 (print_graph): CPP out useless code instead of commenting it.
2327 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
2329 * tests/atconfig.in (CPPFLAGS): Fix.
2331 2001-08-07 Akim Demaille <akim@epita.fr>
2333 * src/print_graph.c (quote): New.
2334 (print_core): Use it.
2336 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
2338 * src/vcg.c (complain.h): Include it.
2339 Unepitaize `return' invocations.
2340 [NDEBUG] (main): Remove.
2341 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
2342 * src/files.c (open_files): Initialize graph_obstack.
2343 * src/print_graph.c (print_actions): CPP out useless code.
2344 (print_core): Don't output the last `\n' in labels.
2346 * src/files.c (output_files): Output the VCG file.
2347 * src/main.c (main): Invoke print_graph ();
2349 2001-08-06 Marc Autret <autret_m@epita.fr>
2351 Automaton VCG graph output.
2352 Using option ``-g'' or long option ``--graph'', you can generate
2353 a gram_filename.vcg file containing a VCG description of the LALR (1)
2354 automaton of your grammar.
2356 * src/main.c: Call to print_graph() function.
2357 * src/getargs.h: Update.
2358 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
2359 (graph_flag): New flag.
2361 (getargs): Add case `g'.
2362 * src/files.c (graph_obstack): New obstack struct.
2363 (open_files): Initialize new obstack.
2364 (output_files): Saves graph_obstack if required.
2365 * src/files.h (graph_obstack): New extern declaration.
2366 * src/Makefile.am: Add new source files.
2368 2001-08-06 Marc Autret <autret_m@epita.fr>
2370 * src/print_graph.c, src/print_graph.h (graph): New.
2371 * src/vcg.h: New file.
2372 * src/vcg.c: New file, VCG graph handling.
2374 2001-08-06 Marc Autret <autret_m@epita.fr>
2376 Add of %source_extension and %header_extension which specify
2377 the source or/and the header output file extension.
2379 * src/files.c (compute_base_names): Remove initialisation of
2380 src_extension and header_extension.
2381 (compute_exts_from_gf): Update.
2382 (compute_exts_from_src): Update.
2383 (output_files): Update.
2384 * src/reader.c (parse_header_extension_decl): New.
2385 (parse_source_extension_decl): New.
2386 (read_declarations): New case statements for the new tokens.
2387 * src/lex.c (percent_table): Add entries for %source_extension
2388 and %header_extension.
2389 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
2391 2001-08-06 Marc Autret <autret_m@epita.fr>
2393 * configure.in: Bump to 1.28c.
2394 * doc/bison.texinfo: Texinfo thingies.
2396 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
2398 * tests/atconfig.in (CPPFLAGS): Add.
2399 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
2401 2001-08-03 Akim Demaille <akim@epita.fr>
2405 2001-08-03 Akim Demaille <akim@epita.fr>
2407 * tests/Makefile.am (check-local): Ship testsuite.
2408 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
2411 2001-08-03 Akim Demaille <akim@epita.fr>
2413 * configure.in: Try using -Wformat when compiling.
2415 2001-08-03 Akim Demaille <akim@epita.fr>
2417 * configure.in: Bump to 1.28b.
2419 2001-08-03 Akim Demaille <akim@epita.fr>
2421 * src/complain.c: Adjust strerror_r portability issues.
2423 2001-08-03 Akim Demaille <akim@epita.fr>
2427 2001-08-03 Akim Demaille <akim@epita.fr>
2429 * src/getargs.c, src/getarg.h (skeleton)): Constify.
2430 * src/lex.c (literalchar): Avoid name clashes on `buf'.
2431 * src/getargs.c: Include complain.h.
2432 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
2433 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
2435 2001-08-03 Akim Demaille <akim@epita.fr>
2437 * src/reader.c (readgram): Display hidden chars in error messages.
2439 2001-08-03 Akim Demaille <akim@epita.fr>
2441 Update to gettext 0.10.39.
2443 2001-08-03 Akim Demaille <akim@epita.fr>
2445 * lib/strspn.c: New.
2447 2001-08-01 Marc Autret <autret_m@epita.fr>
2449 * doc/bison.texinfo: Update.
2450 * doc/bison.1 (mandoc): Update.
2451 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
2452 * src/files.c: Support output files extensions computing.
2453 (src_extension): New static variable.
2454 (header_extension): New static variable.
2456 (get_extension_index): New function, gets the index of an extension
2457 filename in a string.
2458 (compute_exts_from_gf): New function, computes extensions from the
2459 grammar file extension.
2460 (compute_exts_from_src): New functions, computes extensions from the
2461 C source file extension, file given by ``-o'' option.
2462 (compute_base_names): Update.
2463 (output_files): Update.
2465 2001-08-01 Robert Anisko <anisko_r@epita.fr>
2467 * doc/bison.texi: Document @$.
2468 (Locations): New section.
2470 2001-07-18 Akim Demaille <akim@epita.fr>
2472 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
2473 * config/prev-version.txt, config/move-if-change: New.
2474 * Makefile.am: Adjust.
2476 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
2478 * src/bison.simple (yyparse): Suppress warning `comparaison
2479 between signed and unsigned'.
2481 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
2483 * src/getargs.h (raw_flag): Remove.
2484 * src/getargs.c: Die on `-r'/`--raw'.
2485 * src/lex.c (parse_percent_token): Die on `%raw'.
2486 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
2487 * tests/calc.at: Suppress test with option `--raw'.
2489 2001-07-14 Akim Demaille <akim@epita.fr>
2492 * configure.in: Require Autoconf 2.50.
2493 Update to gettext 0.10.38.
2495 2001-03-16 Akim Demaille <akim@epita.fr>
2497 * doc/bison.texinfo: ANSIfy the examples.
2499 2001-03-16 Akim Demaille <akim@epita.fr>
2501 * getargs.c (skeleton): New variable.
2502 (longopts): --skeleton is a new option.
2503 (shortopts, getargs): -S is a new option.
2504 * getargs.h: Declare skeleton.
2505 * output.c (output_parser): Use it.
2507 2001-03-16 Akim Demaille <akim@epita.fr>
2509 * m4/strerror_r.m4: New.
2510 * m4/error.m4: Run AC_FUNC_STRERROR_R.
2511 * lib/error.h, lib/error.c: Update.
2513 2001-03-16 Akim Demaille <akim@epita.fr>
2515 * src/getargs.c (longopts): Clean up.
2517 2001-02-21 Akim Demaille <akim@epita.fr>
2519 * src/reader.c (gensym): `gensym_count' is your own.
2520 Use a static buf to create the symbol name, as token_buffer is no
2523 2001-02-08 Akim Demaille <akim@epita.fr>
2525 * src/conflicts.c (conflict_report): Be sure not to append to res
2526 between two calls, which could happen if both first sprintf were
2527 skipped, but not the first cp += strlen.
2529 2001-02-08 Akim Demaille <akim@epita.fr>
2531 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
2532 New, from fileutils 4.0.37.
2533 * configure.in: Require Autoconf 2.49c. I took some time before
2534 making this decision. This is the only way out for portability
2535 issues in Bison, it would mean way too much duplicate effort to
2536 import in Bison features implemented in 2.49c since 2.13.
2537 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
2539 2001-02-02 Akim Demaille <akim@epita.fr>
2541 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
2542 * lib/xalloc.h, lib/xmalloc.c: Update.
2544 2001-01-19 Akim Demaille <akim@epita.fr>
2546 Get rid of the ad hoc handling of token_buffer in the scanner: use
2549 * src/lex.c (token_obstack): New.
2550 (init_lex): Initialize it. No longer call...
2551 (grow_token_buffer): this. Remove it.
2552 Adjust all the places which used it to use the obstack.
2554 2001-01-19 Akim Demaille <akim@epita.fr>
2556 * src/lex.h: Rename all the tokens:
2557 s/\bENDFILE\b/tok_eof/g;
2558 s/\bIDENTIFIER\b/tok_identifier/g;
2560 Let them be enums, not #define, to ease debugging.
2561 Adjust all the code.
2563 2001-01-18 Akim Demaille <akim@epita.fr>
2565 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
2566 * src/lex.c (maxtoken, grow_token_buffer): Static.
2568 2001-01-18 Akim Demaille <akim@epita.fr>
2570 Since we now use obstacks, more % directives can be enabled.
2572 * src/lex.c (percent_table): Also accept `%yacc',
2573 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
2575 Handle the actions for `%semantic_parser' and `%pure_parser' here,
2576 instead of returning a token.
2577 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
2578 * src/reader.c (read_declarations): Adjust.
2579 * src/files.c (open_files): Don't call `compute_base_names', don't
2580 compute `attrsfile' since they depend upon data which might be
2581 *in* the input file now.
2582 (output_files): Do it here.
2583 * src/output.c (output_headers): Document the fact that this patch
2584 introduces a guaranteed SEGV for semantic parsers.
2585 * doc/bison.texinfo: Document them.
2586 * tests/suite.at: Exercise these %options.
2588 2000-12-20 Akim Demaille <akim@epita.fr>
2590 Also handle the output file (--verbose) with obstacks.
2592 * files.c (foutput): Remove.
2593 (output_obstack): New.
2594 Adjust all dependencies.
2595 * src/conflicts.c: Return a string.
2596 * src/system.h (obstack_grow_string): Rename as...
2597 (obstack_sgrow): this. Be ready to work with non literals.
2598 (obstack_fgrow4): New.
2600 2000-12-20 Akim Demaille <akim@epita.fr>
2602 * src/files.c (open_files): Fix the computation of short_base_name
2603 in the case of `-o foo.tab.c'.
2605 2000-12-20 Akim Demaille <akim@epita.fr>
2607 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
2608 (copy_dollar): Now that everything uses obstacks, get rid of the
2611 2000-12-20 Akim Demaille <akim@epita.fr>
2613 * src/files.c (open_files): Actually the `.output' file is based
2614 on the short_base_name, not base_name.
2615 * tests/suite.at (Checking output file names): Adjust.
2617 2000-12-20 Akim Demaille <akim@epita.fr>
2619 * src/bison.s1: Remove, we now use directly...
2620 * src/bison.simple: this.
2621 * src/Makefile.am: Use pkgdata instead of data.
2623 2000-12-20 Akim Demaille <akim@epita.fr>
2625 * src/files.c (guard_obstack): New.
2626 (open_files): Initialize it.
2627 (output_files): Dump it...
2628 * src/files.h: Export it.
2629 * src/reader.c (copy_guard): Use it.
2631 2000-12-19 Akim Demaille <akim@epita.fr>
2633 * src/files.c (outfile, defsfile, actfile): Removed as global
2635 (open_files): Don't compute them.
2636 (output_files): Adjust.
2637 (base_name, short_base_name): Be global.
2638 Adjust dependencies.
2640 2000-12-19 Akim Demaille <akim@epita.fr>
2642 * src/files.c (strsuffix): New.
2643 (stringappend): Be just like strcat but allocate.
2644 (base_names): Eve out from open_files.
2645 Try to simplify the rather hairy computation of base_name and
2647 (open_files): Use it.
2648 * tests/suite.at (Checking output file names): New test.
2650 2000-12-19 Akim Demaille <akim@epita.fr>
2652 * src/system.h (obstack_grow_literal_string): Rename as...
2653 (obstack_grow_string): this.
2654 * src/output.c (output_parser): Recognize `%% actions' instead of
2656 * src/bison.s1: s/$/%% actions/.
2657 * src/bison.hairy: Likewise.
2659 2000-12-19 Akim Demaille <akim@epita.fr>
2661 * src/output.c (output_parser): Compute the `#line' lines when
2663 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
2664 Suggested by Hans Aberg.
2666 2000-12-19 Akim Demaille <akim@epita.fr>
2668 Let the handling of the skeleton files be local to the procedures
2671 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
2673 (fparser, open_extra_files): Remove.
2674 (open_files, output_files): Don't take care of fparser.
2675 * src/files.h: Adjust.
2676 * src/output.c (output_parser): Open and close the file to the
2678 * src/reader.c (read_declarations): When %semantic_parser, open
2681 2000-12-19 Akim Demaille <akim@epita.fr>
2683 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
2684 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
2686 2000-12-19 Akim Demaille <akim@epita.fr>
2688 * src/files.c (open_files): Yipee! We no longer need all the code
2689 looking for `/tmp' since we have no tmp file.
2691 2000-12-19 Akim Demaille <akim@epita.fr>
2693 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
2695 * src/files.c (open_files): Less dependency on MSDOS etc.
2697 2000-12-14 Akim Demaille <akim@epita.fr>
2699 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
2700 Provide a default definition.
2701 Use it when executing the default @ action.
2702 * src/reader.c (reader_output_yylsp): No longer include
2703 `timestamp' and `text' in the default YYLTYPE.
2705 2000-12-12 Akim Demaille <akim@epita.fr>
2707 * src/reader.c (copy_definition, parse_union_decl, copy_action)
2708 (copy_guard): Quote the file names.
2709 Reported by Laurent Mascherpa.
2711 2000-12-12 Akim Demaille <akim@epita.fr>
2713 * src/output.c (output_headers, output_program, output): Be sure
2714 to escape special characters when outputting filenames.
2715 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
2716 (output_headers): Don't depend on them, Use ACTSTR.
2718 2000-11-17 Akim Demaille <akim@epita.fr>
2720 * lib/obstack.h: Formatting changes.
2721 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
2722 prevents type checking.
2723 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
2724 cast the value to (void *): assigning a `foo *' to a `void *'
2726 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
2727 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
2730 2000-11-17 Akim Demaille <akim@epita.fr>
2732 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
2734 (suite.m4, regression.m4, calc.m4): these.
2735 * tests/atgeneral.m4: Update from CVS Autoconf.
2737 2000-11-17 Akim Demaille <akim@epita.fr>
2739 * tests/regression.m4 (%union and --defines): New test,
2740 demonstrating a current bug in the obstack implementation.
2742 2000-11-17 Akim Demaille <akim@epita.fr>
2744 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
2746 Use them to declare the variables which are global or local to
2749 2000-11-17 Akim Demaille <akim@epita.fr>
2751 * acconfig.h: Remove, no longer used.
2753 2000-11-07 Akim Demaille <akim@epita.fr>
2755 * src: s/Copyright (C)/Copyright/g.
2757 2000-11-07 Akim Demaille <akim@epita.fr>
2759 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
2761 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
2763 2000-11-07 Akim Demaille <akim@epita.fr>
2765 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
2766 Merge in a single CPP if/else.
2768 2000-11-07 Akim Demaille <akim@epita.fr>
2770 * src/output.c (output): Remove useless variables.
2771 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
2772 argument `data' for consistency with the prototypes.
2774 (obstack_copy, obstack_copy0): Rename the second argument as
2775 `address' for consistency. Qualify it `const'.
2776 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
2777 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
2778 `const' their input argument (`data' or `address').
2779 Adjust the corresponding macros to include `const' in casts.
2781 2000-11-03 Akim Demaille <akim@epita.fr>
2783 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
2784 s/PFILE1/BISON_HAIRY/.
2785 Adjust dependencies.
2787 2000-11-03 Akim Demaille <akim@epita.fr>
2789 For some reason, this was not applied.
2791 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2792 `unlink': it's no longer used.
2794 2000-11-03 Akim Demaille <akim@epita.fr>
2796 * src/files.c (skeleton_find): New function, eved out of...
2797 (open_files, open_extra_files): here.
2799 2000-11-03 Akim Demaille <akim@epita.fr>
2803 * src/files.c (obstack_save): New function.
2804 (done): Rename as...
2805 (output_files): this.
2807 * src/main.c (main): Don't use `atexit' to register `done', since
2808 it no longer has to remove tmp files, just call `output_files'
2809 when there are no errors.
2811 2000-11-02 Akim Demaille <akim@epita.fr>
2813 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2814 `unlink': it's no longer used.
2815 * src/files.h: Formatting changes.
2817 2000-11-02 Akim Demaille <akim@epita.fr>
2819 Remove the last uses of mktemp and unlink/delete.
2821 * src/files.c (fdefines, ftable): Removed.
2822 (defines_ostack, table_obstack): New.
2823 Adjust dependencies of the former into uses of the latter.
2824 * src/output.c (output_short_or_char_table, output_short_table):
2825 Convert to using obstacks.
2826 * src/reader.c (copy_comment2): Accept one FILE * and two
2828 (output_token_defines, reader_output_yylsp): Use obstacks.
2829 * src/system.h (obstack_fgrow3): New.
2831 2000-11-01 Akim Demaille <akim@epita.fr>
2833 Change each use of `fattrs' into a use of `attrs_obstack'.
2835 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
2836 * src/files.c (fattrs): Remove.
2837 (attrs_obstack): New.
2838 Adjust all dependencies.
2839 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
2841 2000-11-01 Akim Demaille <akim@epita.fr>
2844 Change each use of `faction' into a use of `action_obstack'.
2846 * lib/obstack.h, lib/obstack.c: New files.
2847 * src/files.c (faction): Remove.
2848 (action_obstack): New.
2849 Adjust all dependencies.
2851 2000-10-20 Akim Demaille <akim@epita.fr>
2853 * lib/quote.h (PARAMS): New macro. Use it.
2855 2000-10-16 Akim Demaille <akim@epita.fr>
2857 * src/output.c (output_short_or_char_table): New function.
2858 (output_short_table, output_token_translations): Use it.
2859 (goto_actions): Use output_short_table.
2861 2000-10-16 Akim Demaille <akim@epita.fr>
2863 * src/symtab.c (bucket_new): New function.
2866 * src/output.c (output_short_table): New argument to display the
2867 comment associated with the table.
2868 Adjust dependencies.
2869 (output_gram): Use it.
2870 (output_rule_data): Nicer output layout for YYTNAME.
2872 2000-10-16 Akim Demaille <akim@epita.fr>
2874 * src/lex.c (read_typename): New function.
2876 * src/reader.c (copy_dollar): Likewise.
2878 2000-10-16 Akim Demaille <akim@epita.fr>
2880 * src/reader.c (copy_comment2): Expect the input stream to be on
2881 the `/' which is suspected to open a comment, instead of being
2882 called after `//' or `/*' was read.
2883 (copy_comment, copy_definition, parse_union_decl, copy_action)
2884 (copy_guard): Adjust.
2886 2000-10-16 Akim Demaille <akim@epita.fr>
2888 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
2889 `read_signed_integer'.
2891 2000-10-16 Akim Demaille <akim@epita.fr>
2893 * src/reader.c (copy_dollar): New function.
2894 (copy_guard, copy_action): Use it.
2896 2000-10-16 Akim Demaille <akim@epita.fr>
2898 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
2899 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
2900 New files, from Fileutils 4.0.27.
2901 * src/main.c (printable_version): Remove.
2902 * src/lex.c, src/reader.c: Use `quote'.
2904 2000-10-04 Akim Demaille <akim@epita.fr>
2906 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
2908 2000-10-04 Akim Demaille <akim@epita.fr>
2910 * doc/bison.texinfo: Various typos spotted by Neil Booth.
2912 2000-10-04 Akim Demaille <akim@epita.fr>
2914 When a literal string is used to define two different tokens,
2915 `bison -v' segfaults.
2916 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
2918 * tests/regression.m4: New file.
2919 Include the core of the sample provided by Piotr Gackiewicz.
2920 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
2923 2000-10-04 Akim Demaille <akim@epita.fr>
2925 * src/reader.c (parse_expect_decl): Keep `count' within the size
2929 2000-10-02 Paul Eggert <eggert@twinsun.com>
2931 * bison.s1 (yyparse): Assign the default value
2932 unconditionally, to avoid a GCC warning and make the parser a
2935 2000-10-02 Akim Demaille <akim@epita.fr>
2937 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
2940 2000-10-02 Akim Demaille <akim@epita.fr>
2942 * src/derives.c, src/print.c, src/reduce.c: To ease the
2943 translation, move some `\n' out of the translated strings.
2945 2000-10-02 Akim Demaille <akim@epita.fr>
2947 The location tracking mechanism is precious for parse error
2948 messages. Nevertheless, it is enabled only when `@n' is used in
2949 the grammar, which is a different issue (you can use it in error
2950 message, but not in the grammar per se). Therefore, there should
2951 be another means to enable it.
2953 * src/getargs.c (getargs): Support `--locations'.
2955 * src/getargs.h (locationsflag): Export it.
2956 * src/lex.c (percent_table): Support `%locations'.
2957 * src/reader.c (yylsp_needed): Remove this variable, now replaced
2958 with `locationsflag'.
2959 * doc/bison.texinfo: Document `--locations' and `%locations'.
2961 * tests/calc.m4: Test it.
2963 For regularity of the names, replace each
2964 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
2965 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
2966 In addition replace each `flag' with `_flag'.
2968 2000-10-02 Akim Demaille <akim@epita.fr>
2970 Also test parse error messages, including with YYERROR_VERBOSE.
2972 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
2974 Use it to check the computations.
2975 Use it to check `nonassoc' is honored.
2976 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
2977 `--yyerror-verbose'.
2978 (_AT_CHECK_CALC): Adjust to this option.
2979 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
2981 2000-10-02 Akim Demaille <akim@epita.fr>
2983 Test also `--verbose', `--defines' and `--name-prefix'. Testing
2984 the latter demonstrates a flaw in the handling of non debugging
2985 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
2986 was used in order to simplify:
3002 unfortunately this leads to a CPP conflict when
3003 `--name-prefix=foo' is used since it produces `#define yydebug
3006 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
3007 (YYDPRINTF): New macro.
3009 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
3011 Also test `--verbose', `--defines' and `--name-prefix'.
3013 2000-10-02 Akim Demaille <akim@epita.fr>
3015 Improve the readability of the produced parsers.
3017 * src/bison.s1: Formatting changes.
3018 Improve the comment related to the `$' mark.
3019 (yydefault): Don't fall through to `yyresume': `goto' there.
3020 * src/output.c (output_parser): When the `$' is met, skip the end
3022 New variable, `number_of_dollar_signs', to check there's exactly
3023 one `$' in the parser skeleton.
3025 2000-10-02 Akim Demaille <akim@epita.fr>
3027 * lib/xstrdup.c: New file, from the fileutils.
3028 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
3029 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
3030 instead of strlen + xmalloc + strcpy.
3031 * src/symtab.c (copys): Remove, use xstrdup instead.
3033 2000-10-02 Akim Demaille <akim@epita.fr>
3035 * src/gram.h (associativity): New enum type which replaces the
3036 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
3037 `right_assoc', `left_assoc' and `non_assoc'.
3038 Adjust all dependencies.
3039 * src/reader.c: Formatting changes.
3040 (LTYPESTR): Don't define it, use it as a literal in
3041 `reader_output_yylsp'.
3042 * src/symtab.h (symbol_class): New enum type which replaces the
3043 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
3044 `sunknown', `stoken and `snterm'.
3046 2000-10-02 Akim Demaille <akim@epita.fr>
3048 * src/getargs.c (fixed_outfiles): Rename as...
3049 (yaccflag): for consistency and accuracy.
3050 Adjust dependencies.
3052 2000-10-02 Akim Demaille <akim@epita.fr>
3054 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
3055 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
3056 difficult and introduced a lot of core dump. It turns out that
3057 Bison used an implementation of `xmalloc' based on `calloc', and
3058 at various places it does depend upon the initialization to 0. I
3059 have not tried to isolate the pertinent places, and all the former
3060 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
3061 someone should address this issue.
3063 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
3064 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
3066 Adjust dependencies.
3067 * src/warshall.h: New file.
3070 2000-10-02 Akim Demaille <akim@epita.fr>
3072 Various anti-`extern in *.c' changes.
3074 * src/system.h: Include `assert.h'.
3076 2000-10-02 Akim Demaille <akim@epita.fr>
3078 * src/state.h (nstates, final_state, first_state, first_shift)
3079 (first_reduction): Move their exportation from here...
3080 * src/LR0.h: to here.
3081 Adjust dependencies.
3082 * src/getargs.c (statisticsflag): New variable.
3083 Add support for `--statistics'.
3084 Adjust dependencies.
3086 Remove a lot of now useless `extern' statements in most files.
3088 2000-10-02 Akim Demaille <akim@epita.fr>
3090 * src/LR0.h: New file.
3093 2000-10-02 Akim Demaille <akim@epita.fr>
3095 * src/print.h: New file.
3097 * src/print.c: Formatting and ordering changes.
3098 (verbose, terse): Replace with...
3099 (print_results): this new function.
3100 Adjust dependencies.
3102 2000-10-02 Akim Demaille <akim@epita.fr>
3104 * src/conflicts.c (conflict_report): New function.
3105 (conflict_log, verbose_conflict_log): Replace with...
3106 (print_conflicts): this function.
3107 Adjust dependencies.
3108 * src/conflicts.h: New file.
3109 Propagate its inclusion.
3111 2000-10-02 Akim Demaille <akim@epita.fr>
3113 * src/nullable.h: New file.
3114 Propagate its inclusion.
3115 * src/nullable.c: Formatting changes.
3117 2000-10-02 Akim Demaille <akim@epita.fr>
3119 * src/reduce.h: New file.
3120 Propagate its inclusion.
3121 * src/reduce.c: Topological sort and other formatting changes.
3122 (bool, TRUE, FALSE): Move their definition to...
3123 * src/system.h: here.
3125 2000-10-02 Akim Demaille <akim@epita.fr>
3127 * src/files.c: Formatting changes.
3128 (tryopen, tryclose, openfiles): Rename as...
3129 (xfopen, xfclose, open_files): this.
3130 (stringappend): static.
3131 * src/files.h: Complete the list of exported symbols.
3134 2000-10-02 Akim Demaille <akim@epita.fr>
3136 * src/reader.h: New file.
3137 Propagate its use instead of tedious list of `extern' and
3139 * src/reader.c: Formatting changes, topological sort,
3142 2000-10-02 Akim Demaille <akim@epita.fr>
3144 * src/lex.h: Prototype `lex.c' exported functions.
3145 * src/reader.c: Adjust.
3146 * src/lex.c: Formatting changes.
3147 (safegetc): Rename as...
3150 2000-10-02 Akim Demaille <akim@epita.fr>
3152 * src/lalr.h: New file.
3153 Propagate its inclusion instead of prototypes and `extern'.
3154 * src/lalr.c: Formatting changes, topological sorting etc.
3156 2000-10-02 Akim Demaille <akim@epita.fr>
3158 * src/output.c (token_actions): Introduce a temporary array,
3159 YYDEFACT, that makes it possible for this function to use
3162 2000-10-02 Akim Demaille <akim@epita.fr>
3164 `user_toknums' is output as a `short[]' in `output.c', while it is
3165 defined as a `int[]' in `reader.c'. For consistency with the
3166 other output tables, `user_toknums' is now defined as a table of
3169 * src/reader.c (user_toknums): Be a short table instead of an int
3171 Adjust dependencies.
3173 Factor the short table outputs.
3175 * src/output.c (output_short_table): New function.
3176 * src/output.c (output_gram, output_stos, output_rule_data)
3177 (output_base, output_table, output_check): Use it.
3179 2000-10-02 Akim Demaille <akim@epita.fr>
3181 * src/output.c (output): Topological sort of the functions, in
3182 order to get rid of the `static' prototypes.
3183 No longer use `register'.
3184 * src/output.h: New file.
3185 Propagate its inclusion in files explicitly prototyping functions
3188 2000-09-21 Akim Demaille <akim@epita.fr>
3190 * src/atgeneral.m4: Update from Autoconf.
3192 2000-09-21 Akim Demaille <akim@epita.fr>
3194 * src/closure.h: New file.
3195 * src/closure.c: Formatting changes, topological sort over the
3196 functions, use of closure.h.
3197 (initialize_closure, finalize_closure): Rename as...
3198 (new_closure, free_closure): these. Adjust dependencies.
3199 * src/LR0.c: Formatting changes, topological sort, use of
3201 (initialize_states): Rename as...
3203 * src/Makefile.am (noinst_HEADERS): Adjust.
3205 2000-09-20 Akim Demaille <akim@epita.fr>
3207 * src/acconfig.h: Don't protect config.h against multiple
3209 Don't define PARAMS.
3210 * src/system.h: Define PARAMS.
3211 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
3212 purpose of config.h. system.h must not try to fix wrong
3213 definitions in config.h.
3215 2000-09-20 Akim Demaille <akim@epita.fr>
3217 * src/derives.h: New file.
3218 * src/main.c, src/derives.h: Use it.
3220 * src/Makefile.am (noinst_HEADERS): Adjust.
3222 2000-09-20 Akim Demaille <akim@epita.fr>
3224 * tests/atgeneral.m4: Update from Autoconf.
3225 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
3226 (AT_CHECK_CALC): New macros.
3227 Use these macros to test bison with options `', `--raw',
3228 `--debug', `--yacc', `--yacc --debug'.
3230 2000-09-19 Akim Demaille <akim@epita.fr>
3232 * src/output.c: Formatting changes.
3233 * src/machine.h: Remove, leaving its contents in...
3234 * src/system.h: here.
3236 Adjust all dependencies on stdio.h and machine.h.
3237 * src/getargs.h: New file.
3238 Let all `extern' declarations about getargs.c be replaced with
3239 inclusion of `getargs.h'.
3240 * src/Makefile.am (noinst_HEADERS): Adjust.
3242 * tests/calc.m4 (yyin): Be initialized in main, not on the global
3244 (yyerror): Returns void, not int.
3245 * doc/bison.texinfo: Formatting changes.
3247 2000-09-19 Akim Demaille <akim@epita.fr>
3249 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
3252 2000-09-18 Akim Demaille <akim@epita.fr>
3254 * configure.in: Append WARNING_CFLAGS to CFLAGS.
3255 * src/Makefile.am (INCLUDES): Don't.
3256 Be ready to fetch headers in lib/.
3258 2000-09-18 Akim Demaille <akim@epita.fr>
3260 * doc/bison.texinfo: Update the copyright.
3261 ANSIfy and GNUify the examples.
3262 Remove the old menu.
3264 2000-09-18 Akim Demaille <akim@epita.fr>
3266 First set of tests: use the `calc' example from the documentation.
3268 * src/bison.s1 (yyparse): Condition the code using `yytname' which
3269 is defined only when YYDEBUG is.
3270 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
3271 * src/files.c (tryopen, tryclose): Formatting changes.
3272 Move to the top and be static.
3273 * src/reader.c (read_signed_integer): Likewise.
3274 * tests/calc.m4: New file.
3275 * Makefile.am, suite.m4: Adjust.
3276 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
3278 2000-09-18 Akim Demaille <akim@epita.fr>
3280 Add support for an Autotest test suite for Bison.
3282 * m4/m4.m4, m4/atconfig.m4: New files.
3283 * m4/Makefile.am (EXTRA_DIST): Adjust.
3284 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
3286 * src/getargs.c: Display a more standard --version message.
3287 * src/reader.c (reader): Formatting changes.
3288 No longer depend upon VERSION_STRING.
3289 * configure.in: No longer use `dnl'.
3290 Set up the test suite and the new directory `tests/.
3291 (VERSION_STRING): Remove.
3293 2000-04-14 Akim Demaille <akim@epita.fr>
3295 * src/reader.c (copy_comment2): New function, same as former
3296 `copy_comment', but outputs into two FILE *.
3297 (copy_comment): Use it.
3298 (parse_union_decl): Use it.
3299 (get_type, parse_start_decl): Use the same `invalid' message.
3300 (parse_start_decl, parse_union_decl): Use the same `multiple'
3302 (parse_union_decl, copy_guard, copy_action): Use the same
3303 `unmatched' message.
3304 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
3306 2000-03-31 Akim Demaille <akim@epita.fr>
3308 * src/files.c (tryopen, tryclose): Move to the top.
3311 2000-03-31 Akim Demaille <akim@epita.fr>
3313 * src/main.c (main): Don't call `done', exit does it.
3315 2000-03-31 Akim Demaille <akim@epita.fr>
3317 * allocate.c: s/return (foo)/return foo/.
3320 * output.c: Likewise.
3321 * reader.c: Likewise.
3322 * symtab.c: Likewise.
3323 * vmsgetargs.c: Likewise.
3325 2000-03-31 Akim Demaille <akim@epita.fr>
3327 Clean up the error reporting functions.
3329 * src/report.c: New file.
3330 * src/report.h: Likewise.
3331 * src/Makefile.am: Adjust.
3332 * m4/error.m4: New file.
3333 * m4/Makefile.am: Adjust.
3334 * configure.in (jm_PREREQ_ERROR): Call it.
3335 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
3337 (fatal, fatals): Remove. All callers use complain.c::fatal.
3338 (warn, warni, warns, warnss, warnss): Remove. All callers use
3339 complain.c::complain.
3340 (toomany): Remove, use fatal instead.
3341 * src/files.c (done): No argument, use complain_message_count.
3342 * src/main.c (main): Register `done' to `atexit'.
3344 * src/getargs.c (usage): More `fputs', less `fprintf'.
3346 2000-03-28 Akim Demaille <akim@epita.fr>
3348 * lib/: New directory.
3349 * Makefile.am (SUBDIRS): Adjust.
3350 * configure.in: Adjust.
3351 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
3353 * src/alloca.c: Moved to lib/.
3354 * src/getopt.c: Likewise.
3355 * src/getopt1.c: Likewise.
3356 * src/getopt.h: Likewise.
3357 * src/ansi2knr.c: Likewise.
3358 * src/ansi2knr.1: Likewise.
3359 * src/Makefile.am: Adjust.
3360 * lib/Makefile.am: New file.
3362 2000-03-28 Akim Demaille <akim@epita.fr>
3364 * src/getargs.c (usage): Refresh the help message.
3366 2000-03-17 Akim Demaille <akim@epita.fr>
3368 * src/getopt1.c: Updated from textutils 2.0e
3369 * src/getopt.c: Likewise.
3370 * src/getopt.h: Likewise.
3372 2000-03-17 Akim Demaille <akim@epita.fr>
3374 * src/Makefile.am (bison.simple): Fix the awk program: quote only
3375 the file name, not the whole `#line LINE FILE'.
3377 2000-03-17 Akim Demaille <akim@epita.fr>
3379 On syntax errors, report the token on which we choked.
3381 * src/bison.s1 (yyparse): In the label yyerrlab, when
3382 YYERROR_VERBOSE, add yychar in msg.
3384 2000-03-17 Akim Demaille <akim@epita.fr>
3386 * src/reader.c (copy_at): New function.
3387 (copy_guard): Use it.
3388 (copy_action): Use it.
3390 2000-03-17 Akim Demaille <akim@epita.fr>
3392 Be kind to translators, save some useless translations.
3394 * src/main.c (banner): New function.
3395 (fatal_banner): Use it.
3396 (warn_banner): Use it.
3398 2000-03-17 Akim Demaille <akim@epita.fr>
3400 * src/reader.c (copy_definition): Use copy_string and
3401 copy_comment. Removed now unused `match', `ended',
3403 (copy_comment, copy_string): Moved, to be visible from
3406 2000-03-17 Akim Demaille <akim@epita.fr>
3408 * src/reader.c (copy_string): Declare `static inline'. No
3409 problems with inline, since it is checked by configure.
3410 (copy_comment): Likewise.
3412 2000-03-17 Akim Demaille <akim@epita.fr>
3414 * src/reader.c (packsymbols): Formatting changes.
3416 2000-03-17 Akim Demaille <akim@epita.fr>
3418 * src/reader.c (copy_comment): New function, factored out from:
3419 (copy_action): Use it. Removed now unused `match', `ended',
3421 (copy_guard): Likewise.
3423 2000-03-17 Akim Demaille <akim@epita.fr>
3425 * src/reader.c (copy_string): New function, factored out from:
3426 (copy_action): Use it.
3427 (copy_guard): Likewise.
3429 2000-03-17 Akim Demaille <akim@epita.fr>
3431 Change the handling of @s so that they behave exactly like $s.
3432 There is now a pseudo variable @$ (readble and writable), location
3433 of the lhs of the rule (by default ranging from the location of
3434 the first symbol of the rhs, to the location of the last symbol,
3435 or, if the rhs is empty, YYLLOC).
3437 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
3439 (yyparse): When providing a default semantic action, provide a
3440 default location action.
3441 (after the $): No longer change `*YYLSP', just stack YYLOC the
3442 same way you stack YYVAL.
3443 * src/reader.c (read_declarations): Use warns.
3444 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
3445 (copy_action, case '@'): Likewise.
3446 Use a standard error message, to save useless work from
3449 2000-03-17 Akim Demaille <akim@epita.fr>
3451 * src/bison.s1: Formatting and cosmetics changes.
3452 * src/reader.c: Likewise.
3453 Update the Copyright notice.
3455 2000-03-17 Akim Demaille <akim@epita.fr>
3457 * src/bison.s1 (#line): All set to `#line' only, since the
3458 Makefile now handles them.
3460 2000-03-16 Akim Demaille <akim@epita.fr>
3462 * src/output.c (output_rule_data): Output the documentation of
3464 (Copyright notice): Update.
3467 2000-03-16 Akim Demaille <akim@epita.fr>
3469 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
3470 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
3471 One `#if YYDEBUG' remains, since it uses variables which are
3472 defined only if `YYDEBUG != 0'.
3474 2000-03-16 Akim Demaille <akim@epita.fr>
3476 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
3477 and related variables so that the similarities are highlighted.
3479 2000-03-16 Akim Demaille <akim@epita.fr>
3481 * src/bison.s1: Properly indent CPP directives.
3483 2000-03-16 Akim Demaille <akim@epita.fr>
3485 * src/bison.s1: Properly indent the `alloca' CPP section.
3487 2000-03-16 Akim Demaille <akim@epita.fr>
3489 Do not hard code values of directories in `configure.in'.
3490 Update the `configure' tool chain.
3492 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
3494 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
3495 (AC_OUTPUT): Add m4/Makefile.
3496 Bump to bison 1.28a, 1.29 has never been released.
3497 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
3498 handled via src/Makefile.am.
3499 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
3500 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
3502 * Makefile.am (SUBDIRS): Add m4.
3503 (ACLOCAL_AM_FLAGS): New variable.
3504 (AUTOMAKE_OPTIONS): Add check-news.
3505 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
3506 the proper line number and file name.
3507 (DEFS): Propagate the location of bison library files and of the
3509 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
3511 * acinclude.m4: Remove, replaced by the directory m4.
3512 * m4/Makefile.am (EXTRA_DIST): New variable.
3513 * m4/gettext.m4: New file, from the fileutils.
3514 * m4/lcmessage.m4: Likewise
3515 * m4/progtest.m4: Likewise.
3516 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
3518 2000-03-10 Akim Demaille <akim@epita.fr>
3521 Formatting changes of various comments.
3522 Respect the GNU coding standards at various places.
3523 Don't use `_()' when no translation is needed.
3525 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3528 OS/2 honors TMPDIR environment variable.
3530 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3532 * doc/bison.texinfo: Tweaked spelling and grammar.
3534 Removed reference to price of printed copy.
3535 Mention BISON_SIMPLE and BISON_HAIRY.
3537 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3539 * configure.in, NEWS:
3540 Bison 1.29 released.
3542 1999-10-27 Jesse Thilo <jthilo@gnu.org>
3544 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
3545 Added reference card.
3547 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3549 * po/ru.po: Added Russian translation.
3551 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3553 * configure.in: Added Russian translation.
3555 1999-07-06 Jesse Thilo <jthilo@gnu.org>
3557 * configure.in, NEWS, README:
3558 Released version 1.28.
3560 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3563 Squashed redefinition warning on some systems.
3565 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
3566 Have configure build version string instead of relying on ANSI string
3569 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3571 * po/POTFILES.in: Got rid of version.c.
3573 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3575 * acconfig.h, configure.in:
3576 Have configure build version string instead of relying on ANSI string
3579 1999-06-08 Jesse Thilo <jthilo@gnu.org>
3582 Dropped mention of `+' for long-named options.
3584 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3586 * src/files.c: Added <unistd.h> for unlink().
3588 * src/Makefile.am, src/system.h:
3591 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3593 * README: Added a FAQ list.
3595 * configure.in, acconfig.h:
3598 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3600 * doc/FAQ, doc/Makefile.am:
3603 1999-05-19 Jesse Thilo <jthilo@gnu.org>
3605 * src/alloc.h, src/symtab.h, src/version.c:
3606 Protected inclusion of "config.h" with HAVE_CONFIG_H.
3608 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3610 * src/.cvsignore, src/Makefile.am:
3611 Reorganized: sources in `src', documentation in `doc'.
3613 * src/lex.c (literalchar):
3614 fixed the code for escaping double quotes (thanks
3617 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3619 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
3620 Adjusted paths to reflect directory reorganization.
3622 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3624 * doc/.cvsignore, doc/Makefile.am:
3625 Reorganized: sources in `src', documentation in `doc'.
3627 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3630 Updated AC_INIT file to reflect directory reorganization.
3632 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
3633 Reorganized: sources in `src', documentation in `doc'.
3635 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3638 Don't declare calloc() and realloc() if not necessary.
3640 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3642 * configure.in, acconfig.h, acinclude.m4:
3643 Don't declare calloc() and realloc() if not necessary.
3645 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3647 * po/.cvsignore: Added i18n support.
3649 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3651 * acconfig.h, configure.in, Makefile.am:
3654 1999-03-22 Jesse Thilo <jthilo@gnu.org>
3656 * src/bison.s1: Fixed #line numbers.
3658 1999-03-15 Jesse Thilo <jthilo@gnu.org>
3660 * po/es.po, po/fr.po, po/nl.po, po/de.po:
3661 Added PO files from Translation Project.
3663 1999-03-03 Jesse Thilo <jthilo@gnu.org>
3666 Added support for non-ANSI compilers (ansi2knr).
3668 1999-02-16 Jesse Thilo <jthilo@gnu.org>
3670 * configure.in: Bumped version number to 1.27.
3673 Added `bison.simple' to list of files removed by `make distclean'.
3675 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3677 * src/files.c, src/files.h:
3678 Defined locations of parser files in config.h instead of Makefile.
3680 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3682 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
3683 Defined locations of parser files in config.h instead of Makefile.
3685 1999-02-09 Jesse Thilo <jthilo@gnu.org>
3688 Removed inappropriate use of $< macro.
3690 1999-02-05 Jesse Thilo <jthilo@gnu.org>
3692 * po/Makefile.in.in, po/POTFILES.in:
3693 Add `po' directory skeleton.
3695 1999-01-27 Jesse Thilo <jthilo@gnu.org>
3697 * README: Document help-bison list.
3699 * configure.in: Add check for mkstemp().
3701 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3703 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
3704 Hush a few compiler warnings.
3707 Add tryclose(), which verifies that fclose was successful.
3708 Hush a couple of compiler warnings.
3710 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3712 * Makefile.am, OChangeLog:
3713 ChangeLog is now automatically generated. Include the old version as
3716 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3718 * 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:
3721 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3723 * doc/bison.texinfo: Fix formatting glitch.
3725 * doc/bison.texinfo: Update FSF address.
3727 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3729 * acconfig.h: Update FSF address.
3731 1999-01-08 Jesse Thilo <jthilo@gnu.org>
3734 Don't define PACKAGE here, since config.h defines it.
3736 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3738 * src/reader.c: Update copyright date.
3741 Ditch sprintf to statically-sized buffers in fatal/warn functions in
3742 favor of output directly to stderr (avoids buffer overruns).
3744 * src/reader.c: Some checks for premature EOF.
3746 * 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:
3747 Use prototypes if the compiler understands them.
3749 * src/files.c: Honor TMPDIR on Unix hosts.
3750 Use prototypes if the compiler understands them.
3753 Fix a couple of buffer overrun bugs.
3754 Use prototypes if the compiler understands them.
3756 * src/system.h: Include unistd.h and ctype.h.
3757 Use #ifdef instead of #if for NLS symbols.
3759 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3761 * doc/bison.texinfo:
3762 Delete comment "consider using @set for edition number, etc..." since
3763 we now are doing so.
3765 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3768 Use prototypes if the compiler understands them.
3770 * NEWS: Document 1.26 highlights.
3772 * Makefile.am: Require Automake 1.3 or later.
3775 Use prototypes if the compiler understands them.
3777 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3780 Use VERSION symbol from automake for version number.
3782 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3784 * acconfig.h, configure.in, version.cin:
3785 Use VERSION symbol from automake for version number.
3787 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3790 Distribute original version of simple parser (bison.s1), not built
3791 version (bison.simple).
3793 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3795 * doc/bison.texinfo: Add info dir entry.
3797 * doc/bison.texinfo:
3798 Let automake put version number into documentation.
3800 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3802 * src/bison.cld, src/build.com, src/vmshlp.mar:
3803 Add non-RCS files from /gd/gnu/bison.
3805 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3808 Document the BISON_HAIRY and BISON_SIMPLE variables.
3810 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3812 * src/version.c: Build version.c automatically.
3815 Fix token numbering (used to start at 258, not 257).
3817 * src/system.h: Include config.h.
3819 * src/getargs.c: Update bug report address.
3821 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
3822 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
3824 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3827 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3829 * configure.in, version.cin:
3830 Build version.c automatically.
3832 * AUTHORS: Add AUTHORS file.
3834 * README: Update bug report address.
3837 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3839 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
3842 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3844 * doc/bison.texinfo: Clean up some formatting.
3846 1998-05-05 Richard Stallman <rms@gnu.org>
3848 * doc/bison.texinfo:
3849 Explain better why to make a pure parser.
3851 1998-01-05 Richard Stallman <rms@gnu.org>
3853 * src/files.c (openfiles):
3854 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
3855 find a temporary directory, if possible. Do not unlink files while
3858 1997-08-25 Richard Stallman <rms@gnu.org>
3860 * src/reader.c (stack_offset;):
3861 Change some warni to warns.
3863 * src/lex.c (literalchar): Use warns, not warni.
3865 1997-06-28 Richard Stallman <rms@gnu.org>
3867 * src/bison.s1: Add a Bison version comment.
3869 * src/main.c (fatal, warn, berror):
3872 1997-06-28 Richard Stallman <rms@gnu.org>
3874 * Makefile.in (bison_version): New variable.
3875 (dist): Use that variable.
3876 (bison.s1): Substitute the Bison version into bison.simple.
3878 * bison.simple: Add a Bison version comment.
3880 1997-06-18 Richard Stallman <rms@gnu.org>
3882 * src/main.c (fatal, warn, berror):
3883 Make error messages standard.
3884 (toomany): Improve error message text.
3886 * 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:
3887 new.h renamed to alloc.h.
3889 1997-06-18 Richard Stallman <rms@gnu.org>
3891 * Makefile.in: new.h renamed to alloc.h.
3893 1997-05-24 Richard Stallman <rms@gnu.org>
3895 * src/lex.c (literalchar):
3896 Fix the code for escaping \, " and '.
3898 (lex): Avoid trouble when there are many chars
3899 to discard in a char literal with just several chars in it.
3901 1997-05-17 Richard Stallman <rms@gnu.org>
3904 Use malloc, if using alloca is troublesome.
3905 (YYSTACK_USE_ALLOCA): New flag macro.
3906 Define it for some systems and compilers.
3907 (YYSTACK_ALLOC): New macro.
3908 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3909 If it was malloc'd, free it.
3911 1997-05-17 Richard Stallman <rms@gnu.org>
3914 Use malloc, if using alloca is troublesome.
3915 (YYSTACK_USE_ALLOCA): New flag macro.
3916 Define it for some systems and compilers.
3917 (YYSTACK_ALLOC): New macro.
3918 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3919 If it was malloc'd, free it.
3921 1997-04-23 Richard Stallman <rms@gnu.org>
3924 (alloca) [__hpux]: Always define as __builtin_alloca.
3926 1997-04-23 Richard Stallman <rms@gnu.org>
3929 (alloca) [__hpux]: Always define as __builtin_alloca.
3931 1997-04-22 Richard Stallman <rms@gnu.org>
3934 [__hpux]: Include alloca.h (right for HPUX 10)
3935 instead of declaring alloca (right for HPUX 9).
3937 * src/bison.s1 (__yy_memcpy):
3938 Declare arg `count' as unsigned int.
3939 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3941 1997-04-22 Richard Stallman <rms@gnu.org>
3944 [__hpux]: Include alloca.h (right for HPUX 10)
3945 instead of declaring alloca (right for HPUX 9).
3947 * bison.simple (__yy_memcpy):
3948 Declare arg `count' as unsigned int.
3949 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3951 1997-01-03 Richard Stallman <rms@gnu.org>
3953 * src/allocate.c: [__STDC__ or _MSC_VER]:
3954 Declare calloc and realloc to return void *.
3956 1997-01-02 Richard Stallman <rms@gnu.org>
3959 [_MSC_VER]: Include stdlib.h and process.h.
3960 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
3962 * src/main.c (main): Return FAILURE as a value.
3963 (printable_version): Declare arg as int, not char.
3965 1997-01-02 Richard Stallman <rms@gnu.org>
3967 * Makefile.in (dist):
3968 Explicitly check for symlinks, and copy them.
3970 1996-12-19 Richard Stallman <rms@gnu.org>
3973 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
3975 1996-12-18 Paul Eggert <eggert@gnu.org>
3977 * src/bison.s1 (yyparse):
3978 If __GNUC__ and YYPARSE_PARAM are both defined,
3979 declare yyparse to have a void * argument.
3981 1996-12-18 Paul Eggert <eggert@gnu.org>
3983 * bison.simple (yyparse):
3984 If __GNUC__ and YYPARSE_PARAM are both defined,
3985 declare yyparse to have a void * argument.
3987 1996-12-17 Richard Stallman <rms@gnu.org>
3989 * src/reduce.c (nbits): Add some casts.
3991 1996-08-12 Richard Stallman <rms@gnu.org>
3993 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
3995 1996-08-12 Richard Stallman <rms@gnu.org>
3997 * bison.simple: Test _MSDOS as well as _MSDOS_.
3999 1996-07-31 Richard Stallman <rms@gnu.org>
4002 [__sun && __i386]: Include alloca.h.
4004 1996-07-31 Richard Stallman <rms@gnu.org>
4007 [__sun && __i386]: Include alloca.h.
4009 1996-07-30 Richard Stallman <rms@gnu.org>
4011 * src/bison.s1: Comment change.
4013 * src/bison.s1: Test _MSDOS_, not MSDOS.
4015 1996-07-30 Richard Stallman <rms@gnu.org>
4017 * bison.simple: Comment change.
4019 * bison.simple: Test _MSDOS_, not MSDOS.
4021 1996-06-01 Richard Stallman <rms@gnu.org>
4023 * 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:
4024 Insert `_' macro around many string constants.
4027 Insert `_' macro around many string constants.
4029 (main): Call setlocale, bindtextdomain and textdomain.
4031 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
4032 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
4033 [ENABLE_NLS]: Include libintl.h.
4034 [ENABLE_NLS] (gettext): Define.
4035 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
4036 (N_, PACKAGE, LOCALEDIR): New macros.
4038 1996-06-01 Richard Stallman <rms@gnu.org>
4040 * POTFILES.in: New file.
4042 * Makefile.in (allocate.o):
4043 Define target explicitly.
4045 * Makefile.in (CFLAGS): Set to @CFLAGS@.
4046 (LDFLAGS): Set to @LDFLAGS@.
4047 (configure): Run autoconf only if preceding `cd' succeeds.
4048 (bison.s1): Redirect output to temporary file then move the
4049 temporary to the target, rather than redirecting directly to bison.s1.
4050 (clean): Remove config.status and config.log.
4051 (distclean): Don't remove config.status here.
4053 1996-05-12 Richard Stallman <rms@gnu.org>
4056 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4058 1996-05-12 Richard Stallman <rms@gnu.org>
4061 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4063 1996-05-11 Richard Stallman <rms@gnu.org>
4065 * src/bison.s1 (__yy_memcpy):
4066 Really reorder the args, as was supposedly done on Feb 14 1995.
4067 (yyparse): Calls changed accordingly.
4069 1996-05-11 Richard Stallman <rms@gnu.org>
4071 * Makefile.in (dist): Don't use $(srcdir).
4073 * bison.simple (__yy_memcpy):
4074 Really reorder the args, as was supposedly done on Feb 14 1995.
4075 (yyparse): Calls changed accordingly.
4077 1996-01-27 Richard Stallman <rms@gnu.org>
4079 * src/output.c (output_rule_data):
4080 Test YYERROR_VERBOSE in the conditional
4081 around the definition of ttyname.
4083 1995-12-29 Richard Stallman <rms@gnu.org>
4086 Fix line numbers in #line commands.
4088 1995-12-29 Richard Stallman <rms@gnu.org>
4091 Fix line numbers in #line commands.
4093 1995-12-27 Richard Stallman <rms@gnu.org>
4095 * src/bison.s1 (YYPARSE_PARAM_DECL):
4096 In C++, make it always null.
4097 (YYPARSE_PARAM_ARG): New macro.
4098 (yyparse): Use YYPARSE_PARAM_ARG.
4100 1995-12-27 Richard Stallman <rms@gnu.org>
4102 * bison.simple (YYPARSE_PARAM_DECL):
4103 In C++, make it always null.
4104 (YYPARSE_PARAM_ARG): New macro.
4105 (yyparse): Use YYPARSE_PARAM_ARG.
4107 1995-11-29 Richard Stallman <rms@gnu.org>
4109 * doc/bison.texinfo:
4110 Describe literal string tokens, %raw, %no_lines, %token_table.
4112 1995-11-29 Daniel Hagerty <hag@gnu.org>
4114 * doc/bison.texinfo: Fixed update date
4116 1995-10-16 Richard Stallman <rms@gnu.org>
4118 * src/version.c: Version 1.25.
4120 1995-10-16 Richard Stallman <rms@gnu.org>
4122 * NEWS: *** empty log message ***
4124 1995-10-16 Richard Stallman <rms@gnu.org>
4126 * doc/bison.1, doc/bison.rnh:
4129 1995-10-15 Richard Stallman <rms@gnu.org>
4131 * src/vmsgetargs.c, src/getargs.c:
4132 Added -n, -k, and -raw switches.
4133 (noparserflag, toknumflag, rawtoknumflag): New variables.
4135 * src/symtab.h (SALIAS):
4136 New #define for adding aliases to %token.
4137 (struct bucket): Added `alias' field.
4139 * src/reduce.c (reduce_grammar):
4140 Revise error message.
4141 (print_notices): Remove final `.' from error message.
4143 * src/reader.c (reader_output_yylsp):
4145 (readgram): Use `#if 0' around code that accepted %command
4146 inside grammar rules: The documentation doesn't allow it,
4147 and it will fail since the %command processors scan for the next %.
4148 (parse_token_decl): Extended the %token
4149 declaration to allow a multi-character symbol as an alias.
4150 (parse_thong_decl): New function.
4151 (read_declarations): Added %thong declarations.
4152 (read_declarations): Handle NOOP to deal with allowing
4153 % declarations as another means to specify the flags.
4154 (readgram): Allow %prec prior to semantics embedded in a rule.
4155 (skip_to_char, read_declarations, copy_definition)
4156 (parse_token_decl, parse_start_decl, parse_type_decl)
4157 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
4158 (get_type_name, copy_guard, copy_action, readgram)
4159 (get_type, packsymbols): Revised most error messages.
4160 Changed `fatal' to `warnxxx' to avoid aborting for error.
4161 Revised and use multiple warnxxx functions to avoid using VARARGS1.
4162 (read_declarations): Improve the error message for
4163 an invalid character. Do not abort.
4164 (read_declarations, copy_guard, copy_action): Use
4165 printable_version to avoid unprintable characters in printed output.
4166 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
4167 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
4168 Allow the type of a non-terminal can be given
4169 more than once, as long as all specifications give the same type.
4172 (output_headers, output_trailers, output, output_gram)
4173 (output_rule_data): Implement noparserflag variable.
4174 Implement toknumflag variable.
4175 (output): Call reader_output_yylsp to output LTYPESTR.
4177 * src/main.c (main):
4178 If reader sees an error, don't process the grammar.
4179 (fatals): Updated to not use VARARGS1.
4180 (printable_version, int_to_string, warn, warni, warns, warnss)
4181 (warnsss): New error reporting functions. Avoid abort for error.
4184 Added THONG and NOOP for alias processing.
4185 Added SETOPT for the new code that allows setting options with %flags.
4188 Include getopt.h. Add some extern decls.
4189 (safegetc): New function to deal with EOF gracefully.
4190 (literalchar); new function to deal with reading \ escapes.
4191 (lex): Use literalchar.
4192 (lex): Implemented "..." tokens.
4193 (literalchar, lex, parse_percent_token): Made tokenbuffer
4194 always contain the token. This includes growing the token
4195 buffer while reading an integer.
4196 (parse_percent_token): Replaced if-else statement with percent_table.
4197 (parse_percent_token): Added % declarations as another
4198 way to specify the flags -n, -l, and -r. Also added hooks for
4199 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
4200 major changes to files.c.
4201 (lex) Retain in the incoming stream a character following
4203 (skip_white_space, lex): Revised most error messages
4204 and changed fatal to warn to avoid aborting.
4205 (percent_table): Added %thong declarations.
4207 * src/gram.h: Comment changes.
4209 * src/files.c (openfiles, open_extra_files, done):
4211 and actfile file. Handle noparserflag. Both for -n switch.
4213 * src/conflicts.c (resolve_sr_conflict):
4214 Remove use of alloca.
4216 1995-06-01 Jim Meyering <meyering@gnu.org>
4218 * doc/bison.texinfo: *** empty log message ***
4220 1995-05-06 Richard Stallman <rms@gnu.org>
4222 * src/bison.s1: Comment change.
4224 1995-05-06 Richard Stallman <rms@gnu.org>
4226 * bison.simple: Comment change.
4228 1995-05-03 Richard Stallman <rms@gnu.org>
4230 * src/version.c: Version now 1.24.
4232 * src/bison.s1: Change distribution terms.
4234 * src/version.c: Version now 1.23.
4236 1995-05-03 Richard Stallman <rms@gnu.org>
4238 * doc/bison.texinfo:
4239 Rewrite "Conditions for Using Bison".
4240 Update version to 1.24.
4242 1995-05-03 Richard Stallman <rms@gnu.org>
4244 * bison.simple: Change distribution terms.
4246 1995-02-23 Richard Stallman <rms@gnu.org>
4248 * src/files.c: Test __VMS_POSIX as well as VMS.
4250 1995-02-14 Jim Meyering <meyering@gnu.org>
4252 * src/bison.s1 (__yy_memcpy):
4253 Renamed from __yy_bcopy to avoid
4254 confusion. Reverse FROM and TO arguments to be consistent with
4257 1995-02-14 Jim Meyering <meyering@gnu.org>
4259 * bison.simple (__yy_memcpy):
4260 Renamed from __yy_bcopy to avoid
4261 confusion. Reverse FROM and TO arguments to be consistent with
4264 1994-11-10 David J. MacKenzie <djm@gnu.org>
4270 * Makefile.in (DISTFILES): Include NEWS.
4272 * Makefile.in (DISTFILES):
4273 Include install-sh, not install.sh.
4275 * configure.in: Update to Autoconf v2 macro names.
4277 1994-10-05 David J. MacKenzie <djm@gnu.org>
4279 * Makefile.in: fix typo
4281 * Makefile.in (prefix, exec_prefix):
4282 Let configure set them.
4284 1994-09-28 David J. MacKenzie <djm@gnu.org>
4286 * Makefile.in: Set datadir to $(prefix)/share.
4288 1994-09-15 Richard Stallman <rms@gnu.org>
4291 Update copyright notice and GPL version.
4293 1994-09-15 Richard Stallman <rms@gnu.org>
4296 Update copyright notice and GPL version.
4298 1994-07-12 Richard Stallman <rms@gnu.org>
4300 * src/reduce.c, src/reader.c:
4303 1994-05-05 David J. MacKenzie <djm@gnu.org>
4305 * Makefile.in: entered into RCS
4307 1994-03-26 Richard Stallman <rms@gnu.org>
4309 * src/bison.s1: entered into RCS
4311 1994-03-26 Richard Stallman <rms@gnu.org>
4313 * bison.simple: entered into RCS
4315 1994-03-25 Richard Stallman <rms@gnu.org>
4317 * src/main.c: entered into RCS
4319 1994-03-24 Richard Stallman <rms@gnu.org>
4321 * src/conflicts.c: entered into RCS
4323 1994-01-02 Richard Stallman <rms@gnu.org>
4325 * Makefile.in: *** empty log message ***
4327 1993-11-21 Richard Stallman <rms@gnu.org>
4329 * src/bison.s1: *** empty log message ***
4331 1993-11-21 Richard Stallman <rms@gnu.org>
4333 * doc/bison.texinfo: entered into RCS
4335 * doc/bison.texinfo: *** empty log message ***
4337 1993-11-21 Richard Stallman <rms@gnu.org>
4339 * bison.simple: *** empty log message ***
4341 1993-10-25 David J. MacKenzie <djm@gnu.org>
4343 * doc/bison.texinfo: *** empty log message ***
4345 1993-10-19 Richard Stallman <rms@gnu.org>
4347 * src/bison.s1: *** empty log message ***
4349 1993-10-19 Richard Stallman <rms@gnu.org>
4351 * bison.simple: *** empty log message ***
4353 1993-10-14 Richard Stallman <rms@gnu.org>
4355 * src/bison.s1: *** empty log message ***
4357 1993-10-14 Richard Stallman <rms@gnu.org>
4359 * bison.simple: *** empty log message ***
4361 1993-09-14 David J. MacKenzie <djm@gnu.org>
4363 * doc/bison.texinfo: *** empty log message ***
4365 1993-09-13 Noah Friedman <friedman@gnu.org>
4367 * Makefile.in: *** empty log message ***
4369 1993-09-10 Richard Stallman <rms@gnu.org>
4371 * src/conflicts.c: *** empty log message ***
4373 * src/system.h: entered into RCS
4375 1993-09-10 Richard Stallman <rms@gnu.org>
4377 * doc/bison.1: entered into RCS
4379 1993-09-06 Noah Friedman <friedman@gnu.org>
4381 * src/version.c: entered into RCS
4383 1993-09-06 Noah Friedman <friedman@gnu.org>
4385 * Makefile.in: *** empty log message ***
4387 1993-07-30 David J. MacKenzie <djm@gnu.org>
4389 * Makefile.in: *** empty log message ***
4391 1993-07-24 Richard Stallman <rms@gnu.org>
4393 * src/bison.s1: *** empty log message ***
4395 1993-07-24 Richard Stallman <rms@gnu.org>
4397 * bison.simple: *** empty log message ***
4399 1993-07-08 David J. MacKenzie <djm@gnu.org>
4401 * Makefile.in: *** empty log message ***
4403 1993-07-04 Richard Stallman <rms@gnu.org>
4405 * src/bison.s1: *** empty log message ***
4407 1993-07-04 Richard Stallman <rms@gnu.org>
4409 * bison.simple: *** empty log message ***
4411 1993-06-26 David J. MacKenzie <djm@gnu.org>
4413 * src/getargs.c: entered into RCS
4415 1993-06-26 David J. MacKenzie <djm@gnu.org>
4417 * doc/bison.texinfo: *** empty log message ***
4419 * doc/bison.1: New file.
4421 1993-06-25 Richard Stallman <rms@gnu.org>
4423 * src/getargs.c: New file.
4425 1993-06-16 Richard Stallman <rms@gnu.org>
4427 * src/bison.s1: *** empty log message ***
4429 1993-06-16 Richard Stallman <rms@gnu.org>
4431 * bison.simple: *** empty log message ***
4433 1993-06-03 Richard Stallman <rms@gnu.org>
4435 * src/bison.s1: New file.
4437 1993-06-03 Richard Stallman <rms@gnu.org>
4439 * doc/bison.texinfo: *** empty log message ***
4441 1993-06-03 Richard Stallman <rms@gnu.org>
4443 * bison.simple: New file.
4445 1993-05-19 Richard Stallman <rms@gnu.org>
4447 * doc/bison.texinfo: New file.
4449 1993-05-07 Noah Friedman <friedman@gnu.org>
4451 * Makefile.in: *** empty log message ***
4453 1993-04-28 Noah Friedman <friedman@gnu.org>
4455 * src/reader.c: *** empty log message ***
4457 1993-04-23 Noah Friedman <friedman@gnu.org>
4459 * src/alloc.h: entered into RCS
4461 1993-04-20 David J. MacKenzie <djm@gnu.org>
4463 * src/version.c: *** empty log message ***
4465 * src/files.c, src/allocate.c:
4468 * src/reader.c: *** empty log message ***
4470 * src/lex.c: entered into RCS
4472 * src/conflicts.c: New file.
4474 * src/symtab.c: entered into RCS
4476 * src/alloc.h: New file.
4478 * src/LR0.c: entered into RCS
4480 1993-04-18 Noah Friedman <friedman@gnu.org>
4482 * src/reader.c: New file.
4484 * src/version.c: *** empty log message ***
4486 1993-04-18 Noah Friedman <friedman@gnu.org>
4488 * Makefile.in: *** empty log message ***
4490 1993-04-17 Noah Friedman <friedman@gnu.org>
4492 * Makefile.in: *** empty log message ***
4494 1993-04-15 Richard Stallman <rms@gnu.org>
4496 * src/main.c, src/files.c:
4499 1993-04-15 Noah Friedman <friedman@gnu.org>
4501 * configure.in: entered into RCS
4503 * configure.in: *** empty log message ***
4505 * configure.in: New file.
4507 1993-04-14 Richard Stallman <rms@gnu.org>
4509 * Makefile.in: New file.
4511 1993-04-13 Richard Stallman <rms@gnu.org>
4513 * src/version.c: New file.
4515 1993-03-25 Richard Stallman <rms@gnu.org>
4517 * src/output.c: entered into RCS
4519 1992-09-25 Richard Stallman <rms@gnu.org>
4521 * configure.bat: entered into RCS
4523 1992-06-22 Richard Stallman <rms@gnu.org>
4525 * src/vmsgetargs.c: entered into RCS
4527 1992-06-22 Richard Stallman <rms@gnu.org>
4529 * doc/bison.rnh: entered into RCS
4531 1992-04-20 David J. MacKenzie <djm@gnu.org>
4533 * README: entered into RCS
4535 1992-01-22 Richard Stallman <rms@gnu.org>
4537 * src/machine.h: entered into RCS
4539 1991-12-21 Richard Stallman <rms@gnu.org>
4541 * src/lalr.c, src/closure.c:
4544 1991-12-20 Richard Stallman <rms@gnu.org>
4546 * src/state.h: entered into RCS
4548 1991-12-18 Richard Stallman <rms@gnu.org>
4550 * src/print.c, src/nullable.c, src/derives.c:
4553 1991-11-03 David J. MacKenzie <djm@gnu.org>
4555 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
4558 1988-09-09 Richard Stallman <rms@gnu.org>
4560 * src/bison.hairy: entered into RCS
4562 1987-12-16 Richard Stallman <rms@gnu.org>
4564 * REFERENCES: entered into RCS