1 2002-01-11 Akim Demaille <akim@epita.fr>
3 * configure.in: Use AC_FUNC_STRNLEN.
5 2002-01-09 Akim Demaille <akim@epita.fr>
9 2002-01-09 Akim Demaille <akim@epita.fr>
11 * configure.in (WERROR_CFLAGS): Compute it.
12 * src/Makefile.am (CFLAGS): Pass it.
13 * tests/atlocal.in (CFLAGS): Idem.
15 2002-01-08 Akim Demaille <akim@epita.fr>
17 * lib/Makefile.am (libbison_a_SOURCES): Add xstrndup.c.
18 * src/getargs.c (AS_FILE_NAME): New.
19 (getargs): Use it to convert DOSish file names.
20 * src/files.c (base_name): Rename as full_base_name to avoid
21 clashes with `base_name ()'.
22 (get_extension_index): Remove.
23 (filename_split): New.
24 (compute_base_names): N-th rewrite, using filename_split.
26 2002-01-08 Akim Demaille <akim@epita.fr>
28 * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c,
29 * lib/xstrndup.c, lib/strchr.c:
30 New, stolen from the Fileutils 4.1.
31 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
32 * configure.in: Check for the presence of memrchr, strchr,
33 strnlen, and of their prototypes.
34 Don't check for strndup: we no longer use it.
35 * src/system.h: Adjust the prototypes.
37 2002-01-07 Akim Demaille <akim@epita.fr>
39 * src/conflicts.c (count_rr_conflicts): The previous RR conflicts
40 patch was improperly applied: fix it.
42 2002-01-07 Akim Demaille <akim@epita.fr>
44 * tests/torture.at (GNU Cim Grammar): Reintroduce their weird
45 'switch' without a following semicolon.
46 * tests/regression.at (braces parsing): New.
48 2002-01-06 Akim Demaille <akim@epita.fr>
50 Bison is dead wrong in its RR conflict reports.
52 * tests/torture.at (GNU Cim Grammar): New.
53 * src/conflicts.c (count_rr_conflicts): Fix.
55 2002-01-06 Akim Demaille <akim@epita.fr>
57 Creating package.m4 from configure.ac causes too many problems.
59 * tests/Makefile.am (package.m4): Create it by hand,
60 AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf.
62 2002-01-04 Paul Eggert <eggert@twinsun.com>
64 * doc/bison.texinfo (Debugging):
65 Remove YYSTDERR; it's no longer defined or used.
66 Also, s/cstdio.h/cstdio/.
68 2002-01-03 Akim Demaille <akim@epita.fr>
70 * src/files.h: Add it prototype.
72 2002-01-03 Akim Demaille <akim@epita.fr>
74 * src/files.c, src/files.h (strsuffix): Not static.
75 * src/conflicts.c (conflicts_print): Don't consider it is an error
76 to have a %expectation violation on a file ending by `plural.y'.
79 2002-01-03 Akim Demaille <akim@epita.fr>
81 * tests/bison.in: Adjust to CVS Autoconf.
82 * tests/calc.at (exp): We no longer need to special case GCC as
83 the warning flags are passed by configure.
84 * tests/atlocal.in: Adjust.
85 * configure.in: Bump to 1.30j.
87 2002-01-03 Akim Demaille <akim@epita.fr>
91 2002-01-03 Akim Demaille <akim@epita.fr>
93 * src/bison.simple (YYSTDERR): Remove, replace `stderr'.
94 The ISO C++ standard is extremely clear about it: stderr is
95 considered a macro, not a regular symbol (see table 94 `Header
96 <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files).
97 Therefore std:: does not apply to it. It still does with fprintf.
98 Also, s/cstdio.h/cstdio/.
100 2002-01-03 Akim Demaille <akim@epita.fr>
102 * lib/quotearg.c: Use `#include "..."' instead of `#include <...>'
103 for non system headers.
105 2001-12-27 Paul Eggert <eggert@twinsun.com>
107 * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special
108 cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and
109 Sparc, as they were causing more porting problems than the
110 (minor) performance improvement was worth.
112 2001-12-22 Akim Demaille <akim@epita.fr>
114 * src/output.c (output_short_table, output_short_or_char_table):
115 Change the prototype to use `int' for array ranges: some
116 invocations do pass an int, not a short.
117 Reported by Wayne Green.
119 2001-12-22 Akim Demaille <akim@epita.fr>
121 Some actions of web2c.y are improperly triggered.
122 Reported by Mike Castle.
124 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
125 * tests/regression.at (Web2c): Rename as...
126 (Web2c Report): this.
127 (Web2c Actions): New.
129 2001-12-22 Akim Demaille <akim@epita.fr>
131 Reductions in web2c.y are improperly reported.
132 Reported by Mike Castle.
134 * src/conflicts.c (print_reductions): Fix.
135 * tests/regression.at (Web2c): New.
137 2001-12-18 Akim Demaille <akim@epita.fr>
141 2001-12-18 Akim Demaille <akim@epita.fr>
143 Some host fail on `assert (!"foo")', which expands to
144 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
145 Reported by Nelson Beebee.
147 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
148 `#define it_succeeded 0' and `assert (it_succeeded)'.
150 2001-12-17 Paul Eggert <eggert@twinsun.com>
152 * src/bison.simple (YYSTD): New macro.
153 (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE, YYFPRINTF, YYSTDERR): Use
154 it to simplify macros, and fix some C++ porting problems reported
157 * src/output.c (output): Define YYDEBUG to 0 if it is not defined
158 and if we are not debugging. POSIX requires this.
159 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document this.
161 * src/output.c (output_gram, output_rule_data): Do not assume that
162 the user defines YYDEBUG to a properly parenthesized expression.
164 2001-12-15 Akim Demaille <akim@epita.fr>
166 * src/nullable.c (set_nullable): Useless rules must be skipped,
167 otherwise, since we range over their symbols, we might look at a
168 nonterminal which no longer ``exists'', i.e., it is not counted in
169 `nvars', hence we overflow our arrays.
171 2001-12-15 Akim Demaille <akim@epita.fr>
173 * src/reader.c (copy_action): When --yacc, don't append a `;'
174 to the user action: let it fail if lacking.
175 Suggested by Arnold Robbins and Tom Tromey.
177 2001-12-13 Akim Demaille <akim@epita.fr>
181 2001-12-13 Akim Demaille <akim@epita.fr>
183 The computation of nullable is broken: it doesn't handle empty
186 * tests/torture.at (GNU AWK Grammar): New.
187 * tests/sets.at (Nullable): New.
188 * src/nullable.c (set_nullable): Instead of blindly looping over
189 `ritems', loop over the rules, and then over their rhs's.
191 Work around Autotest bugs.
193 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
194 frame, because Autotest understand lines starting with a `+' as
195 traces from the shell. Then, they are not processed properly.
196 Admittedly an Autotest bug, but we don't have time to wait for
197 Autotest to catch up.
198 * tests/regression.at (Broken Closure): Adjust to the new table
201 * tests/sets.at: here.
203 2001-12-12 Paul Eggert <eggert@twinsun.com>
205 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
206 Do not infringe on the global user namespace when using C++.
207 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
208 All uses of `fprintf' and `stderr' changed.
210 * src/output.c (output): Do not output "#include <stdio.h>"; that
211 is bison.simple's job. stdio.h should be included only if
212 necessary, to avoid infringing on the user name space when
215 2001-12-12 Akim Demaille <akim@epita.fr>
217 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
218 on that of lib/error.c.
220 2001-12-12 Akim Demaille <akim@epita.fr>
222 Some hosts don't like `/' in includes.
224 * src/system.h: Include libgettext.h without qualifying the path.
225 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
228 2001-12-10 Akim Demaille <akim@epita.fr>
230 Bison dumps core on bash.y.
231 Reported by Pascal Bart.
233 * src/warshall.c (bitmatrix_print): New.
235 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
236 j must be the outer loop.
237 * tests/regression.at (Broken Closure): New.
239 2001-12-05 Akim Demaille <akim@epita.fr>
243 2001-12-05 Akim Demaille <akim@epita.fr>
245 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
247 Reported by Peter Hámorský.
249 2001-12-05 Akim Demaille <akim@epita.fr>
251 * src/conflicts.c (err_table): Remove.
252 (resolve_sr_conflict): Adjust.
253 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
255 (state_t.reductions, state_t.shifts): this.
257 2001-12-05 Akim Demaille <akim@epita.fr>
259 * src/reduce.c (reduce_grammar_tables): No longer disable the
260 removal of useless rules via CPP but via `if (0)', so that the
261 compiler still check the code is valid.
262 For instance, it should have noticed `rline' no longer exists: use
263 the `line' member of rule_t.
264 * src/gram.c (dummy, rline): Remove, unused.
266 2001-12-05 Akim Demaille <akim@epita.fr>
268 * src/output.c (pack_vector): Use assert, not berror.
269 * src/main.c (berror): Remove, unused.
271 2001-12-05 Akim Demaille <akim@epita.fr>
273 New experimental feature: if --verbose --trace output all the
274 items of a state, not only its kernel.
276 * src/print.c (print_core): If `trace_flag', then invoke closure
277 before outputting the items of the state (print_core is no longer
278 a correct name them).
279 (print_results): Invoke new_closure/free_closure if needed.
281 2001-12-05 Akim Demaille <akim@epita.fr>
283 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
284 * src/closure.c, src/closure.h (itemsetsize): Rename as...
285 (nitemset): for consistency with the rest of the project.
287 2001-12-05 Akim Demaille <akim@epita.fr>
289 * src/closure.c (print_closure): Improve.
290 (closure): Use it for printing input and output.
292 2001-12-05 Akim Demaille <akim@epita.fr>
294 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
295 indexed by nonterminals.
297 2001-12-05 Akim Demaille <akim@epita.fr>
299 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
301 * src/warshall.h: Remove accidental duplication of the content.
303 2001-12-05 Akim Demaille <akim@epita.fr>
305 * src/closure.c (set_fderives): De-obfuscate.
307 2001-12-05 Akim Demaille <akim@epita.fr>
309 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
311 2001-12-05 Akim Demaille <akim@epita.fr>
313 * src/closure.c (set_firsts): De-obfuscate.
315 2001-12-05 Akim Demaille <akim@epita.fr>
317 * src/output.c (action_row): De-obfuscate
318 using the good o' techniques: arrays not pointers, variable
319 locality, BITISSET, RESETBIT etc.
321 2001-12-05 Akim Demaille <akim@epita.fr>
323 Pessimize the code to simplify it: from now on, all the states
324 have a valid SHIFTS, which NSHIFTS is possibly 0.
326 * src/LR0.c (shifts_new): Be global and move to..
327 * src/state.c, src/state.h: here.
328 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
329 * src/print_graph: Adjust.
331 2001-12-05 Akim Demaille <akim@epita.fr>
333 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
334 * src/conflicts.c: Use it.
335 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
336 incorrectly ``simplified''.
338 2001-12-05 Akim Demaille <akim@epita.fr>
340 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
341 using the good o' techniques: arrays not pointers, variable
342 locality, BITISSET, RESETBIT etc.
344 2001-12-05 Akim Demaille <akim@epita.fr>
346 * src/state.h (SHIFT_SYMBOL): New.
347 * src/conflicts.c: Use it to deobfuscate.
349 2001-12-05 Akim Demaille <akim@epita.fr>
351 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
352 (print_reductions): De-obfuscate using the good o' techniques:
353 arrays not pointers, variable locality, BITISSET.
355 2001-12-05 Akim Demaille <akim@epita.fr>
357 * src/conflicts.c (print_reductions): Arrays, not pointers.
360 2001-12-05 Akim Demaille <akim@epita.fr>
362 * src/conflicts.c (print_reductions): Pessimize, but clarify.
364 2001-12-05 Akim Demaille <akim@epita.fr>
366 * src/conflicts.c (print_reductions): Improve variable locality.
368 2001-12-05 Akim Demaille <akim@epita.fr>
370 * src/conflicts.c (print_reductions): Pessimize, but clarify.
372 2001-12-05 Akim Demaille <akim@epita.fr>
374 * src/conflicts.c (print_reductions): Improve variable locality.
376 2001-12-05 Akim Demaille <akim@epita.fr>
378 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
379 * src/lalr.c: Use them.
381 2001-12-05 Akim Demaille <akim@epita.fr>
383 * src/LR0.c (augment_automaton): Formatting changes.
384 Better variable locality.
386 2001-12-05 Akim Demaille <akim@epita.fr>
388 * src/lalr.c (matrix_print): New.
390 Use arrays instead of pointers.
392 2001-12-05 Akim Demaille <akim@epita.fr>
394 * src/lalr.c (maxrhs): Move to...
395 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
396 * src/lalr.c (build_relations): Adjust.
398 2001-12-05 Akim Demaille <akim@epita.fr>
400 * src/lalr.c (transpose): Free the memory allocated to the
401 argument, as it is replaced by the results by the unique caller.
402 (build_relations): Merely invoke transpose: it handles the memory
404 Improve variable locality.
405 Avoid variables used as mere abbreviations.
406 (compute_lookaheads): Use arrays instead of pointers.
408 2001-12-05 Akim Demaille <akim@epita.fr>
410 * src/lalr.c (initialize_F): Improve variable locality.
411 Avoid variables used as mere abbreviations.
413 2001-12-05 Akim Demaille <akim@epita.fr>
415 * src/derives.c (print_derives): Display the ruleno.
416 * src/lalr.c (initialize_F, transpose): Better variable locality
417 to improve readability.
418 Avoid variables used as mere abbreviations.
420 2001-12-05 Akim Demaille <akim@epita.fr>
422 * src/lalr.c (traverse): Use arrays instead of pointers.
424 2001-12-05 Akim Demaille <akim@epita.fr>
426 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
427 the handling of squeue.
428 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
430 2001-12-05 Akim Demaille <akim@epita.fr>
432 Because useless nonterminals are now kept alive (instead of being
433 `destroyed'), we now sometimes examine them, and store information
434 related to them. Hence we need to know their number, and adjust
437 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
439 * src/LR0.c (allocate_itemsets): The memory allocated to
440 `symbol_count' was used for two different purpose: once to count
441 the number of occurrences of each symbol, and later reassigned to
442 `shift_symbol', containing the symbol that can be shifted from a
444 Deobfuscate, i.e., allocate, use and free `symbol_count' here
446 (new_itemsets): Allocate `shift_symbol' here.
447 (allocate_itemsets): symbol_count includes useless nonterminals.
449 (free_storage): Use `free', not `XFREE', for pointers that cannot
452 2001-12-05 Akim Demaille <akim@epita.fr>
454 * src/nullable.c (set_nullable): Deobfuscate the handling of
456 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
458 2001-12-05 Akim Demaille <akim@epita.fr>
460 * src/gram.c, src/gram.h (ritem_print): New.
461 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
462 (This useless function was defined only to work around VMS linkers
463 that can't handle compilation units with variables only).
464 * src/reduce.c (dump_grammar): Use it to trace the construction of
467 2001-12-04 Paul Eggert <eggert@twinsun.com>
469 * src/bison.simple (union yyalloc): Change member names
470 to be the same as the stack names.
471 (yyparse): yyptr is now union yyalloc *, not char *.
472 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
473 and may generate better code on some machines.
474 (yystpcpy): Use prototype if __STDC__ is defined, not just
475 if __cplusplus is defined.
477 2001-11-30 Akim Demaille <akim@epita.fr>
479 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
480 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
481 Gettext doesn't compile cleanly, and dies with -Werror.
482 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
483 Include WARNING_CFLAGS here.
484 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
485 before being defined.
487 2001-11-30 Paul Eggert <eggert@twinsun.com>
489 * lib/quotearg.h (quotearg_n, quotearg_n_style):
490 First arg is int, not unsigned.
491 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
492 (SIZE_MAX, UINT_MAX): New macros.
493 (quotearg_n_options): Abort if N is negative.
494 Avoid overflow check on hosts where size_t is 64 bits and int
495 is 32 bits, as overflow is impossible there.
496 Fix off-by-one typo that caused unnecessary reallocation.
498 2001-11-30 Paul Eggert <eggert@twinsun.com>
500 Name space cleanup in generated parser.
502 * doc/bison.texinfo (Bison Parser): Discuss system headers
503 and their effect on the user name space.
506 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
507 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
508 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
510 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
511 on user names when possible.
513 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
514 Simplify test for whather <alloca.h> exists.
516 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
518 (<stdio.h>): Include if YYDEBUG.
520 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
521 ! defined (yyoverflow) && ! defined (yymemcpy).
523 (yymemcpy, yyparse): Rename local variables as needed so that
524 they all begin with 'yy'.
526 (yystrlen, yystpcpy): New functions.
528 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
531 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
532 instead of relying on string.h functions. Use YYSTACK_ALLOC
533 and YYSTACK_FREE instead of malloc and free.
535 2001-11-30 Akim Demaille <akim@epita.fr>
537 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
538 if body instead of `;' to pacify GCC's warnings.
540 2001-11-30 Akim Demaille <akim@epita.fr>
542 Instead of mapping the LHS of unused rules to -1, keep the LHS
543 valid, but flag the rules as invalid.
545 * src/gram.h (rule_t): `useful' is a new member.
546 * src/print.c (print_grammar): Adjust.
547 * src/derives.c (set_derives): Likewise.
548 * src/reader.c (packgram, reduce_output): Likewise.
549 * src/reduce.c (reduce_grammar_tables): Likewise.
550 * tests/reduce.at (Underivable Rules, Useless Rules): New.
552 2001-11-30 Akim Demaille <akim@epita.fr>
554 * src/reduce.c (reduce_output): Formatting changes.
555 * src/print.c (print_results, print_grammar): Likewise.
556 * tests/regression.at (Rule Line Numbers)
557 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
559 2001-11-30 Akim Demaille <akim@epita.fr>
561 * src/reduce.c (nonterminals_reduce): Instead of throwing away
562 useless nonterminals, move them at the end of the symbol arrays.
563 (reduce_output): Adjust.
564 * tests/reduce.at (Useless Nonterminals): Adjust.
566 2001-11-30 Akim Demaille <akim@epita.fr>
568 * src/reduce.c: Various comment/formatting changes.
569 (nonterminals_reduce): New, extracted from...
570 (reduce_grammar_tables): here.
571 (reduce_grammar): Call nonterminals_reduce.
573 2001-11-29 Paul Eggert <eggert@twinsun.com>
575 * src/bison.simple (YYSTACK_REALLOC): Remove.
576 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
577 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
579 (union yyalloc): New type.
580 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
581 an arbitrary restriction on hosts where size_t is wider than int.
583 (yyparse): Don't dump core if alloca or malloc fails; instead, report
584 a parser stack overflow. Allocate just one block of memory for all
585 three stacks, instead of allocating three blocks; this typically is
586 faster and reduces fragmentation.
588 Do not limit the number of items in the stack to a value that fits
589 in 'int', as this is an arbitrary limit on hosts with 64-bit
590 size_t and 32-bit int.
592 2001-11-28 Akim Demaille <akim@epita.fr>
594 * src/LR0.c (shifts_new): New.
595 (save_shifts, insert_start_shift, augment_automaton): Use it.
597 2001-11-28 Akim Demaille <akim@epita.fr>
599 * src/closure.c (closure): `b' and `ruleno' denote the same value:
602 2001-11-28 Akim Demaille <akim@epita.fr>
604 * src/closure.c (closure): Instead of looping over word in array
605 then bits in words, loop over bits in array.
607 2001-11-28 Akim Demaille <akim@epita.fr>
609 * src/closure.c (closure): No longer optimize the special case
610 where all the bits of `ruleset[r]' are set to 0, to make the code
613 2001-11-28 Akim Demaille <akim@epita.fr>
615 * src/closure.c (closure): `r' and `c' are new variables, used to
616 de-obfuscate accesses to RULESET and CORE.
618 2001-11-28 Akim Demaille <akim@epita.fr>
620 * src/reduce.c (reduce_print): Use ngettext.
621 (dump_grammar): Improve the trace accuracy.
623 2001-11-28 Akim Demaille <akim@epita.fr>
625 * src/reduce.c (dump_grammar): Don't translate trace messages.
627 2001-11-28 Akim Demaille <akim@epita.fr>
629 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
630 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
631 as all tags are free'ed afterwards.
634 2001-11-27 Akim Demaille <akim@epita.fr>
636 * src/system.h: Use intl/libgettext.h.
637 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
639 2001-11-27 Paul Eggert <eggert@twinsun.com>
641 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
642 use alloca when we didn't want to, and vice versa.
644 2001-11-27 Akim Demaille <akim@epita.fr>
646 * tests/torture.at (Exploding the Stack Size with Malloc):
647 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
649 2001-11-27 Akim Demaille <akim@epita.fr>
651 * src/files.c: Include error.h.
654 2001-11-26 Akim Demaille <akim@epita.fr>
658 2001-11-26 Akim Demaille <akim@epita.fr>
660 * src/reader.c (readgram): Make sure rules for mid-rule actions
661 have a lineno equal to that of their host rule.
662 Reported by Hans Aberg.
663 * tests/regression.at (Rule Line Numbers): New.
665 2001-11-26 Akim Demaille <akim@epita.fr>
667 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
669 Reported by Hans Aberg.
671 2001-11-26 Akim Demaille <akim@epita.fr>
673 * src/complain.c, src/complain.h (error): Remove, provided by
676 2001-11-26 Akim Demaille <akim@epita.fr>
678 * src/reader.c (read_declarations): Don't abort on tok_illegal,
679 issue an error message.
680 * tests/regression.at (Invalid %directive): New.
681 Reported by Hans Aberg.
683 2001-11-26 Akim Demaille <akim@epita.fr>
685 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
686 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
688 2001-11-26 Akim Demaille <akim@epita.fr>
690 * src/conflicts.c (conflicts_print): Don't complain at all when
691 there are no reduce/reduce conflicts, and as many shift/reduce
692 conflicts as expected.
693 * tests/regression.at (%expect right): Adjust.
695 2001-11-23 Akim Demaille <akim@epita.fr>
697 * lib/alloca.c: Update, from fileutils.
699 2001-11-23 Akim Demaille <akim@epita.fr>
701 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
703 2001-11-23 Akim Demaille <akim@epita.fr>
705 * src/system.h: Include alloca.h.
706 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
708 2001-11-23 Akim Demaille <akim@epita.fr>
710 * src/print_graph.c (print_actions): Remove `rule', unused.
711 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
712 pacify GCC's signed < unsigned warnings.
713 * src/closure.c (itemsetsize): Likewise.
714 * src/reader.c (symbol_list_new): Static.
716 2001-11-23 Akim Demaille <akim@epita.fr>
718 Attaching lineno to buckets is stupid, since only one copy of each
719 symbol is kept, only the line of the first occurrence is kept too.
721 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
722 * src/reader.c (rline_allocated): Remove, unused.
723 (symbol_list): Have a `line' member.
724 (symbol_list_new): New.
726 * src/print.c (print_grammar): Output the rule line numbers.
727 * tests/regression.at (Solved SR Conflicts)
728 (Unresolved SR Conflicts): Adjust.
729 Reported by Hans Aberg.
731 2001-11-20 Akim Demaille <akim@epita.fr>
735 2001-11-20 Akim Demaille <akim@epita.fr>
738 * configure.in (ALL_LINGUAS): Adjust.
739 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
740 longer contains strings to translate.
742 2001-11-19 Akim Demaille <akim@epita.fr>
744 * src/conflicts.c (conflicts_print): Add a missing \n.
746 2001-11-19 Akim Demaille <akim@epita.fr>
748 * src/nullable.c (nullable_print): New.
749 (set_nullable): Call it when tracing.
750 Better locality of variables.
752 2001-11-19 Akim Demaille <akim@epita.fr>
754 * src/print.c (print_actions): Better locality of variables.
756 2001-11-19 Akim Demaille <akim@epita.fr>
758 * src/derives.c (print_derives): Fix and enrich.
759 * src/closure.c (print_fderives): Likewise.
761 2001-11-19 Akim Demaille <akim@epita.fr>
763 * src/closure.c (itemsetend): Remove, replaced with...
766 2001-11-19 Akim Demaille <akim@epita.fr>
768 * src/LR0.c (kernel_end): Remove, replaced with...
771 2001-11-19 Akim Demaille <akim@epita.fr>
773 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
776 2001-11-19 Akim Demaille <akim@epita.fr>
778 * src/closure.c (closure): Use arrays instead of pointers to clarify.
780 2001-11-19 Akim Demaille <akim@epita.fr>
782 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
784 * src/LR0.c: Likewise.
785 (allocate_itemsets): Use arrays instead of pointers to clarify.
787 2001-11-19 Akim Demaille <akim@epita.fr>
789 * src/getargs.c (statistics_flag): Replace with...
791 (longopts): Accept --trace instead of --statistics.
792 * src/getargs.h: Adjust.
793 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
794 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
796 2001-11-19 Akim Demaille <akim@epita.fr>
798 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
799 pointers to clarify the code.
800 (save_reductions, save_shifts): Factor common parts of alternatives.
802 2001-11-19 Akim Demaille <akim@epita.fr>
804 * src/LR0.c (new_state, get_state): Complete TRACE code.
805 * src/closure.c: Include `reader.h' to get `tags', needed by the
807 Rename the conditional DEBUG as TRACE.
808 Output consistently TRACEs to stderr, not stdout.
809 * src/derives.c: Likewise.
810 * src/reduce.c: (inaccessable_symbols): Using if is better style
812 Use `#if TRACE' instead of `#if 0' for tracing code.
814 2001-11-19 Akim Demaille <akim@epita.fr>
816 * src/system.h (LIST_FREE, shortcpy): New.
817 * src/LR0.c: Use them.
818 * src/output.c (free_itemsets, free_reductions, free_shifts):
819 Remove, replaced by LIST_FREE.
821 2001-11-19 Akim Demaille <akim@epita.fr>
823 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
824 (REDUCTIONS_ALLOC): New.
825 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
828 2001-11-19 Akim Demaille <akim@epita.fr>
830 * src/LR0.c (new_state): Complete trace code.
831 * src/nullable.c (set_nullable): Don't translate traces.
833 2001-11-19 Akim Demaille <akim@epita.fr>
835 * src/print_graph.c (print_core): Better locality of variables.
836 * src/print.c (print_core): Likewise.
838 2001-11-19 Akim Demaille <akim@epita.fr>
840 * src/vcg.c: You do the output, so you are responsible of the
841 handling of VCG syntax, in particular: use quotearg.
842 * src/print_graph.c: Don't.
843 (print_actions): Don't output the actions as part of the nodes,
844 since that's the job of the edges.
845 (print_state): Don't output by hand: fill the node description,
846 and ask for its output.
848 2001-11-19 Akim Demaille <akim@epita.fr>
850 * src/bison.simple (yyparse): When verbosely reporting an error,
851 no longer put additional quotes around token names.
852 * tests/calc.at: Adjust.
854 2001-11-19 Akim Demaille <akim@epita.fr>
856 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
857 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
858 * src/output.c: Adjust.
860 2001-11-19 Akim Demaille <akim@epita.fr>
862 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
864 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
866 2001-11-19 Akim Demaille <akim@epita.fr>
868 * src/gram.h (rule_t): New.
870 (rrhs, rlhs): Remove, part of state_t.
871 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
872 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
873 * src/reader.c, src/reduce.c: Adjust.
875 2001-11-19 Akim Demaille <akim@epita.fr>
877 * src/reader.c (symbols_output): New, extracted from...
881 2001-11-19 Akim Demaille <akim@epita.fr>
883 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
884 (maxrhs): this new function.
886 2001-11-19 Akim Demaille <akim@epita.fr>
888 * src/lalr.c (F): New macro to access the variable F.
891 2001-11-19 Akim Demaille <akim@epita.fr>
893 * src/lalr.h (LA): New macro to access the variable LA.
894 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
895 * src/lalr.c: Adjust.
897 2001-11-19 Akim Demaille <akim@epita.fr>
899 * src/lalr.c (initialize_LA): Only initialize LA. Let...
900 (set_state_table): handle the `lookaheads' members.
902 2001-11-19 Akim Demaille <akim@epita.fr>
904 * src/lalr.h (lookaheads): Removed array, whose contents is now
906 (state_t): this structure.
907 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
910 2001-11-19 Akim Demaille <akim@epita.fr>
912 * src/lalr.h (consistent): Removed array, whose contents is now
914 (state_t): this structure.
915 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
918 2001-11-19 Akim Demaille <akim@epita.fr>
920 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
921 contents are now members of...
922 (state_t): this structure.
923 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
926 2001-11-19 Akim Demaille <akim@epita.fr>
928 * src/lalr.h (state_t): New.
929 (state_table): Be a state_t * instead of a core **.
930 (accessing_symbol): Remove, part of state_t.
931 * src/lalr.c: Adjust.
932 (set_accessing_symbol): Merge into...
933 (set_state_table): this.
934 * src/print_graph.c, src/conflicts.c: Adjust.
936 2001-11-14 Akim Demaille <akim@epita.fr>
940 2001-11-14 Akim Demaille <akim@epita.fr>
942 * tests/calc.at, tests/output.at, tests/regression.at,
943 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
944 now the tests are run in private dirs, therefore AC_CLEANUP and
945 family can be simplified to 0-ary.
946 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
947 use abs. path to find config.h.
949 2001-11-14 Akim Demaille <akim@epita.fr>
951 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
952 stderr, there can be way too much random noise.
953 Instead pass -Werror to GCC and rely on the exit status.
954 Reported by Wolfram Wagner.
956 2001-11-14 Akim Demaille <akim@epita.fr>
958 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
959 defined only if yyoverflow is defined, to avoid `warning: unused
961 Reported by The Test Suite.
963 2001-11-14 Akim Demaille <akim@epita.fr>
965 * src/print.c: Include reduce.h.
966 Reported by Hans Aberg.
968 2001-11-14 Akim Demaille <akim@epita.fr>
970 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
971 Revert a previous patch: these are really const.
972 * src/conflicts.c (conflict_report): Additional useless pair of
973 braces to pacify GCC's warnings for `if () if () {} else {}'.
974 * src/lex.c (parse_percent_token): Replace equal_offset with
977 Be sure to strdup `arg' when used, since there is no reason for
978 token_buffer not to change.
980 2001-11-14 Akim Demaille <akim@epita.fr>
982 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
984 * src/main.c (main): Use them.
985 Suggested by Hans Aberg.
987 2001-11-12 Akim Demaille <akim@epita.fr>
991 * src/system.h (ngettext): Now that we use ngettext, be sure to
992 provide a default definition when NLS are not used that takes care
995 2001-11-12 Akim Demaille <akim@epita.fr>
997 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
998 Use @kbd to denote user input.
999 (Language and Grammar): ANSIfy the example.
1000 Adjust its layout for info/notinfo.
1001 (Location Tracking Calc): Output error messages to stderr.
1002 Output locations in a more GNUtically correct way.
1003 Fix a couple of Englishos.
1004 Adjust @group/@end group pairs.
1006 2001-11-12 Akim Demaille <akim@epita.fr>
1008 %expext was not functioning at all.
1010 * src/conflicts.c (expected_conflicts): Set to -1.
1011 (conflict_report): Use ngettext.
1012 (conflicts_print): Check %expect and make its violation an error.
1013 * doc/bison.texinfo (Expect Decl): Adjust.
1014 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
1015 * tests/regression.at (%expect not enough, %expect right)
1016 (%expect too much): New.
1018 2001-11-12 Akim Demaille <akim@epita.fr>
1020 * tests/regression.at (Conflicts): Rename as...
1021 (Unresolved SR Conflicts): this.
1022 (Solved SR Conflicts): New.
1024 2001-11-12 Akim Demaille <akim@epita.fr>
1026 * src/reduce.c (print_results): Rename as...
1027 (reduce_output): This.
1028 Output to OUT, passed as argument, instead of output_obstack.
1029 (dump_grammar): Likewise.
1032 (reduce_grammar): No longer call reduce_output, since...
1033 * src/print.c (print_results): do it.
1034 * src/main.c (main): Call reduce_free;
1036 2001-11-12 Akim Demaille <akim@epita.fr>
1038 * src/conflicts.c (print_reductions): Accept OUT as argument.
1039 Output to it, not to output_obstack.
1040 * src/print.c (print_actions): Adjust.
1042 2001-11-12 Akim Demaille <akim@epita.fr>
1044 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
1045 the result instead of using...
1046 (src_total, rrc_total, src_count, rrc_count): Remove.
1047 (any_conflicts): Remove.
1048 (print_conflicts): Split into...
1049 (conflicts_print, conflicts_output): New.
1050 * src/conflicts.h: Adjust.
1051 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
1052 * src/print.c (print_grammar): Issue `\n' between to rule outputs.
1053 * tests/regression.at (Conflicts): New.
1054 Reported by Tom Lane.
1056 2001-11-12 Akim Demaille <akim@epita.fr>
1058 * tests/regression.at (Invalid input): Remove, duplicate with
1059 ``Invalid input: 1''.
1061 2001-11-12 Akim Demaille <akim@epita.fr>
1063 * tests/torture.at (AT_DATA_STACK_TORTURE)
1064 (Exploding the Stack Size with Alloca)
1065 (Exploding the Stack Size with Malloc): New.
1067 2001-11-12 Akim Demaille <akim@epita.fr>
1069 * src/bison.simple (YYSTACK_REALLOC): New.
1070 (yyparse) [!yyoverflow]: Use it and free the old stack.
1071 Reported by Per Allansson.
1073 2001-11-05 Akim Demaille <akim@epita.fr>
1076 * src/lex.c (parse_percent_token): s/quotearg/quote/.
1078 2001-11-05 Akim Demaille <akim@epita.fr>
1080 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
1083 2001-11-05 Akim Demaille <akim@epita.fr>
1085 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
1086 with yyltype/YYLTYPE. This allows inclusion of the generated
1087 header within the parser if the compiler, such as GGC, accepts
1088 multiple equivalent #defines.
1090 2001-11-04 Akim Demaille <akim@epita.fr>
1092 * src/getargs.c (longopts): Support `--output'. getopt is now
1093 able to understand that `--out' is OK: the two racing long options
1096 * src/lex.h (tok_setopt): Remove, replaced with...
1097 (tok_intopt, tok_stropt): these new guys.
1098 * src/lex.c (getopt.h): Not needed.
1099 (token_buffer, unlexed_token_buffer): Not const.
1100 (percent_table): Promote `-' over `_' in directive names.
1101 Active `%name-prefix', `file-prefix', and `output'.
1102 (parse_percent_token): Accept possible arguments to directives.
1103 Promote `-' over `_' in directive names.
1104 * doc/bison.texinfo (Decl Summary): Split the list into
1105 `directives for grammars' and `directives for bison'.
1107 Add description of `%name-prefix', `file-prefix', and `output'.
1108 Promote `-' over `_' in directive names.
1109 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
1110 Simplify the description of `--name-prefix'.
1111 Promote `-' over `_' in directive names.
1112 Promote `--output' over `--output-file'.
1113 Fix the description of `--defines'.
1114 * tests/output.at: Exercise %file-prefix and %output.
1116 2001-11-02 Akim Demaille <akim@epita.fr>
1118 * doc/refcard.tex: Update.
1120 2001-11-02 Akim Demaille <akim@epita.fr>
1122 * src/symtab.h (SUNDEF): New.
1123 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
1124 stand for `uninitialized', instead of 0.
1125 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
1126 * src/lex.c (lex): Adjust.
1128 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
1130 Let yylex return it instead of a plain 0.
1131 Reported by Dick Streefland.
1133 2001-11-02 Akim Demaille <akim@epita.fr>
1135 * tests/regression.at (Mixing %token styles): New test.
1137 2001-11-02 Akim Demaille <akim@epita.fr>
1139 * src/reader.c (parse_thong_decl): Formatting changes.
1140 (token_translations_init): New, extracted from...
1141 (packsymbols): Here.
1144 2001-11-01 Akim Demaille <akim@epita.fr>
1146 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
1147 Check that `9foo.y' produces correct cpp guards.
1148 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
1152 2001-11-01 Akim Demaille <akim@epita.fr>
1154 * tests/regression.at (Invalid input: 2): New.
1155 * src/lex.c (unlexed_token_buffer): New.
1156 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
1160 2001-11-01 Akim Demaille <akim@epita.fr>
1162 * configure.in: Bump to 1.30a.
1163 Adjust to newer Autotest.
1165 2001-10-26 Akim Demaille <akim@epita.fr>
1169 2001-10-26 Paul Eggert <eggert@twinsun.com>
1171 * lib/error.c, lib/error.h, lib/getopt.c, lib/getopt.h,
1172 lib/getopt1.c, lib/obstack.c, lib/obstack.h, lib/quote.c,
1173 lib/strnlen.c, lib/xmalloc.c, m4/c-bs-a.m4, m4/error.m4,
1174 m4/gettext.m4, m4/lcmessage.m4, m4/malloc.m4, m4/mbstate_t.m4,
1175 m4/progtest.m4, m4/realloc.m4, m4/strerror_r.m4:
1176 Sync with fileutils 4.1.1.
1178 2001-10-18 Akim Demaille <akim@epita.fr>
1181 * tests/calc.at (_AT_CHECK_CALC_ERROR): Don't use `foo && bar', to
1182 avoid spurious failures.
1184 2001-10-18 Akim Demaille <akim@epita.fr>
1188 2001-10-18 Akim Demaille <akim@epita.fr>
1190 * tests/atlocal.in (GCC): Add.
1191 * tests/calc.at: s/m4_match/m4_bmatch/.
1192 s/m4_patsubst/m4_bpatsubst/.
1193 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
1194 * configure.in: AC_SUBST(GCC).
1196 2001-10-10 Akim Demaille <akim@epita.fr>
1199 * configure.in: M4 is no longer needed, but autom4te is.
1200 * tests/Makefile.am (AUTOTEST): Don't define AUTOM4TE, let
1203 2001-10-10 Akim Demaille <akim@epita.fr>
1207 2001-10-10 Akim Demaille <akim@epita.fr>
1210 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
1211 Use `#if !YYSTACK_USE_ALLOCA', not `#ifndef'.
1212 Reported by Airy Andre.
1214 2001-10-10 Akim Demaille <akim@epita.fr>
1216 * INSTALL, config/config.guess, config/config.sub, config/mdate-sh
1217 * config/mkinstalldirs, lib/ansi2knr.c: Update.
1219 2001-10-02 Akim Demaille <akim@epita.fr>
1223 2001-10-02 Akim Demaille <akim@epita.fr>
1227 2001-10-02 Akim Demaille <akim@epita.fr>
1229 * tests/regression.at (Invalid CPP headers): New.
1230 From Alexander Belopolsky.
1231 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
1233 2001-10-02 Akim Demaille <akim@epita.fr>
1235 * tests/regression.at (Invalid input): New.
1236 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
1239 2001-10-02 Akim Demaille <akim@epita.fr>
1241 * tests/calc.at: Now that --debug works, the tests must be adjusted.
1243 2001-10-02 Akim Demaille <akim@epita.fr>
1245 * src/output.c (output_parser): Assert `skeleton'.
1246 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
1250 2001-10-01 Marc Autret <autret_m@epita.fr>
1252 * src/lex.h: Echo modifications.
1253 * src/lex.c (unlex): Parameter is now token_t.
1256 2001-10-01 Marc Autret <autret_m@epita.fr>
1258 * src/main.c: Include lex.h.
1261 2001-09-29 Akim Demaille <akim@epita.fr>
1263 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
1265 2001-09-28 Akim Demaille <akim@epita.fr>
1267 * tests/testsuite.at: Update to newer Autotest.
1268 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
1270 2001-09-27 Akim Demaille <akim@epita.fr>
1272 Position independent wrapper.
1274 * tests/bison: Remove.
1275 * tests/bison.in: New.
1276 * configure.in: Adjust.
1278 2001-09-27 Paul Eggert <eggert@twinsun.com>
1280 Port quotearg fixes from tar 1.13.24.
1282 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
1284 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
1285 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
1287 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
1288 * m4/mbrtowc.m4: New file.
1289 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
1290 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
1292 2001-09-27 Akim Demaille <akim@epita.fr>
1296 2001-09-27 Akim Demaille <akim@epita.fr>
1300 2001-09-25 Akim Demaille <akim@epita.fr>
1302 * src/system.h: Include `xalloc.h'.
1303 Remove it from the C files.
1304 * src/files.c (output_files): Free the obstacks.
1305 * src/lex.c (init_lex): Rename as...
1308 * src/main.c (main): Use it.
1310 2001-09-24 Marc Autret <autret_m@epita.fr>
1312 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
1313 to output informations in fout (FILE*).
1314 (open_graph, close_graph): Likewise.
1315 (output_graph, output_edge, output_node): Likewise.
1316 * src/vcg.h: Update function prototypes.
1317 * src/print_graph.c (print_graph): Open output graph file.
1318 (print_actions): Adjust.
1319 * src/files.h: Remove extern declaration.
1320 * src/files.c: Remove graph_obstack declaration.
1321 (open_files): Remove graph_obstack initialization.
1322 (output_files): Remove graph_obstack saving.
1324 2001-09-24 Marc Autret <autret_m@epita.fr>
1326 * src/files.c (compute_output_file_names): Fix.
1328 2001-09-24 Marc Autret <autret_m@epita.fr>, Akim Demaille <akim@epita.fr>
1330 * src/reader.c (reader): Remove call to free_symtab ().
1331 * src/main.c (main): Call it here.
1333 * src/conflicts.c (initialize_conflicts): Rename as...
1334 (solve_conflicts): this.
1335 * src/print.c (print_core, print_actions, print_state)
1336 (print_grammar): Dump to a file instead a `output_obstack'.
1337 (print_results): Dump `output_obstack', and then proceed with the
1339 * src/files.c (compute_output_file_names, close_files): New.
1340 (output_files): Adjust.
1341 * src/main.c (main): Adjust.
1343 2001-09-23 Marc Autret <autret_m@epita.fr>
1345 * src/files.c (compute_header_macro): Computes header macro name
1346 from spec_defines_file when given.
1348 2001-09-23 Marc Autret <autret_m@epita.fr>
1350 * src/files.c (output_files): Add default extensions.
1352 2001-09-22 Akim Demaille <akim@epita.fr>
1354 * src/conflicts.c (finalize_conflicts): Rename as...
1355 (free_conflicts): this.
1357 2001-09-22 Akim Demaille <akim@epita.fr>
1359 * src/gram.c (gram_free): Rename back as...
1361 (output_token_translations): Free `token_translations'.
1362 * src/symtab.c (free_symtab): Free the tag field.
1364 2001-09-22 Akim Demaille <akim@epita.fr>
1366 Remove `translations' as it is always set to true.
1368 * src/gram.h: Adjust.
1369 * src/reader.c (packsymbols, parse_token_decl): Adjust
1370 * src/print.c (print_grammar): Adjust.
1371 * src/output.c (output_token_translations): Adjust.
1372 * src/lex.c (lex): Adjust.
1373 * src/gram.c: Be sure the set pointers to NULL.
1374 (dummy): Rename as...
1377 2001-09-22 Akim Demaille <akim@epita.fr>
1379 * configure.in: Invoke AM_LIB_DMALLOC.
1380 * src/system.h: Use dmalloc.
1381 * src/LR0.c: Be sure to have pointers initialized to NULL.
1382 (allocate_itemsets): Allocate kernel_items only if needed.
1384 2001-09-22 Akim Demaille <akim@epita.fr>
1386 * configure.in: Bump to 1.29b.
1387 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
1388 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
1389 need xmalloc.c in calc.y.
1392 2001-09-21 Akim Demaille <akim@epita.fr>
1395 * Makefile.maint, config/config.guess, config/config.sub,
1396 * config/missing: Update from masters.
1397 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
1399 * configure.in (ALL_LINGUAS): Add `tr'.
1401 2001-09-21 Akim Demaille <akim@epita.fr>
1403 * tests/Makefile.am (package.m4): Move to...
1404 ($(srcdir)/$(TESTSUITE)): here.
1406 2001-09-20 Akim Demaille <akim@epita.fr>
1408 * src/complain.c: No longer try to be standalone: use system.h.
1409 Don't assume __STDC__ is defined to 1. Just test if it is defined.
1410 * src/complain.h: Likewise.
1411 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
1412 Remove the unused variable `n'.
1413 From Albert Chin-A-Young.
1415 2001-09-18 Marc Autret <autret_m@epita.fr>
1417 * doc/bison.1: Update.
1418 * doc/bison.texinfo (Bison Options): Update --defines and --graph
1420 (Option Cross Key): Update.
1423 2001-09-18 Marc Autret <autret_m@epita.fr>
1425 * tests/regression.at: New test (comment in %union).
1427 2001-09-18 Marc Autret <autret_m@epita.fr>
1429 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
1431 Reported by Keith Browne.
1433 2001-09-18 Marc Autret <autret_m@epita.fr>
1435 * tests/output.at: Add tests for --defines and --graph.
1437 2001-09-18 Marc Autret <autret_m@epita.fr>
1439 * tests/output.at: Removes tests of %{header,src}_extension features.
1441 2001-09-18 Akim Demaille <akim@epita.fr>
1443 * tests/Makefile.am (package.m4): New.
1444 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
1445 (_AT_CHECK_CALC_ERROR): Likewise.
1446 Factor the `, ' part of verbose error messages.
1448 2001-09-18 Marc Autret <autret_m@epita.fr>
1450 * src/getargs.c (longopts): Declare --defines and --graph as options
1451 with optional arguments.
1452 * src/files.h: Add extern declarations.
1453 * src/files.c (spec_graph_file, spec_defines_file): New.
1454 (output_files): Update.
1455 Remove CPP-outed code.
1457 2001-09-18 Marc Autret <autret_m@epita.fr>
1459 Turn off %{source,header}_extension feature.
1461 * src/files.c (compute_exts_from_gf): Update.
1462 (compute_exts_from_src): Update.
1463 (output_files): CPP-out useless code.
1464 * src/files.h: Remove {header,source}_extension extern declarations.
1465 * src/reader.c (parse_dquoted_param): CPP-out.
1466 (parse_header_extension_decl): Remove.
1467 (parse_source_extension_decl): Remove.
1468 (read_declarations): Remove cases tok_{hdrext,srcext}.
1469 * src/lex.c (percent_table): Remove {header,source}_extension entries.
1470 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
1472 2001-09-10 Akim Demaille <akim@epita.fr>
1474 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
1475 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
1476 (AT_CHECK_OUTPUT): this.
1477 Merely check ls' exit status, its output is useless.
1479 2001-09-10 Akim Demaille <akim@epita.fr>
1481 * tests/calc.at: Use m4_match.
1482 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
1484 2001-09-10 Marc Autret <autret_m@epita.fr>, Akim Demaille <akim@epita.fr>
1486 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
1488 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
1490 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
1491 * src/lex.h: Adjust prototype.
1492 (token_t): Add `tok_undef'.
1493 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
1494 (parse_percent_token): Now returns token_t.
1495 Add default statement in switch.
1496 (lex): Separate `c' as an input variable, from the token_t result
1498 (unlexed): Is a token_t.
1500 2001-09-10 Akim Demaille <akim@epita.fr>
1502 * configure.in: Bump to 1.29a.
1504 2001-09-07 Akim Demaille <akim@epita.fr>
1508 2001-08-30 Akim Demaille <akim@epita.fr>
1510 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
1511 * m4/atconfig.m4: Remove.
1512 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
1514 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
1515 m4_if, m4_patsubst, and m4_regexp.
1516 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
1517 `input' file instead of echo.
1519 2001-08-29 Akim Demaille <akim@epita.fr>
1523 2001-08-29 Akim Demaille <akim@epita.fr>
1527 2001-08-29 Paul Eggert <eggert@twinsun.com>
1529 * src/bison.simple (yyparse): Don't take the address of an
1530 item before the start of an array, as that doesn't conform to
1533 2001-08-29 Robert Anisko <anisko_r@epita.fr>
1535 * doc/bison.texinfo (Location Tracking Calc): New node.
1537 2001-08-29 Paul Eggert <eggert@twinsun.com>
1539 * src/output.c (output): Do not define const, as this now
1540 causes more problems than it cures.
1542 2001-08-29 Akim Demaille <akim@epita.fr>
1544 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
1546 Be sure to tag the `detailmenu'.
1548 2001-08-29 Akim Demaille <akim@epita.fr>
1550 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
1551 download in a tmp dir.
1553 2001-08-28 Marc Autret <autret_m@epita.fr>
1555 * config/depcomp: New file.
1557 2001-08-28 Marc Autret <autret_m@epita.fr>
1559 * doc/bison.1 (mandoc): Adjust.
1560 From Juan Manuel Guerrero.
1562 2001-08-28 Marc Autret <autret_m@epita.fr>
1564 * src/print_graph.c (print_state): Fix.
1566 2001-08-27 Marc Autret <autret_m@epita.fr>
1568 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
1570 Echo modifications to the functions prototypes.
1571 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
1573 2001-08-27 Marc Autret <autret_m@epita.fr>
1575 * src/vcg.c: Include `xalloc.h'.
1576 (add_colorentry): New.
1577 (add_classname): New.
1578 (add_infoname): New.
1579 * src/vcg.h: Add new prototypes.
1581 2001-08-27 Akim Demaille <akim@epita.fr>
1583 * Makefile.maint: Sync. again with CVS Autoconf.
1585 2001-08-27 Akim Demaille <akim@epita.fr>
1587 * Makefile.maint: Formatting changes.
1588 (po-update, cvs-update, update): New targets.
1591 2001-08-27 Akim Demaille <akim@epita.fr>
1593 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
1594 * Makefile.maint: Sync. with CVS Autoconf.
1596 2001-08-27 Marc Autret <autret_m@epita.fr>
1598 * src/vcg.h (struct infoname_s): New.
1599 (struct colorentry_s): New.
1600 (graph_s): New fields {vertical,horizontal}_order in structure.
1601 Add `infoname' field.
1602 Add `colorentry' field;
1603 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
1604 (G_HORIZONTAL_ORDER): New.
1606 (G_COLORENTRY): New.
1607 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
1608 Add output of `infoname'.
1609 Add output of `colorentry'.
1611 2001-08-27 Marc Autret <autret_m@epita.fr>
1613 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
1614 This one shadowed a global parameter.
1616 2001-08-24 Marc Autret <autret_m@epita.fr>
1618 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
1619 instead of `unsigned'.
1620 (print_state): Do not call obstack_object_size () in obstack_grow ()
1621 to avoid macro variables shadowing.
1623 2001-08-23 Marc Autret <autret_m@epita.fr>
1625 * src/lex.c (percent_table): Typo: s/naem/name/.
1627 Normalize new options declarations.
1629 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
1631 * tests/suite.at: Exercise %header_extension and %source_extension.
1633 2001-08-16 Marc Autret <autret_m@epita.fr>
1635 * src/reader.c (parse_dquoted_param): New.
1636 (parse_header_extension_decl): Use it.
1637 (parse_source_extension_decl): Likewise.
1639 2001-08-16 Marc Autret <autret_m@epita.fr>
1641 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
1642 (get_xxxx_str): Use assert () instead of complain ().
1643 Remove return invokations in default cases.
1644 (get_decision_str): Modify default behaviour. Remove second argument.
1645 Echo modifications on calls.
1646 (output_graph): Fix.
1648 2001-08-16 Marc Autret <autret_m@epita.fr>
1650 * src/getargs.c (usage): Update with ``-g, --graph''.
1652 2001-08-16 Marc Autret <autret_m@epita.fr>
1654 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
1655 (Option Cross Key): Likewise.
1656 * doc/bison.1: Update.
1658 2001-08-15 Akim Demaille <akim@epita.fr>
1662 2001-08-15 Marc Autret <autret_m@epita.fr>
1664 * src/reader.c (readgram): Indent output macro YYSTYPE.
1665 (packsymbols): Likewise.
1666 (output_token_defines): Likewise.
1667 * src/files.c: Standardize.
1668 (compute_header_macro): New.
1669 (defines_obstack_save): New. Use compute_header_macro.
1670 (output_files): Update. Use defines_obstack_save.
1672 2001-08-15 Akim Demaille <akim@epita.fr>
1674 * doc/bison.texinfo (Table of Symbols): Document
1677 2001-08-15 Akim Demaille <akim@epita.fr>
1679 * missing: Update from CVS Automake.
1680 * config/config.guess, config/config.sub, config/texinfo.tex:
1681 Update from gnu.org.
1683 2001-08-15 Akim Demaille <akim@epita.fr>
1685 * Makefile.maint: Sync with CVS Autoconf.
1687 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
1689 * doc/bison.texinfo: Include GNU Free Documentation License from
1691 * doc/fdl.texi: Add to package.
1693 2001-08-14 Marc Autret <autret_m@epita.fr>
1695 Turn on %{source,header}_extension features.
1697 * src/lex.c (percent_table): Un-CPP out header_extension and
1699 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
1700 (compute_exts_from_src): Remove conditions. It restores priorities
1703 2001-08-14 Marc Autret <autret_m@epita.fr>
1705 * src/files.c (compute_base_names): Add extensions computing when
1706 `--file-prefix' used.
1707 Standardize function calls.
1709 2001-08-13 Marc Autret <autret_m@epita.fr>
1711 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
1712 defining it (defined but null disables alloca).
1714 2001-08-13 Marc Autret <autret_m@epita.fr>
1716 * src/bison.simple (_yy_memcpy): CPP reformat.
1718 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
1720 * tests/atconfig.in (CPPFLAGS): Fix.
1722 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
1724 * doc/bison.texinfo: Include GNU General Public License from
1726 * doc/gpl.texi: Add to package.
1728 2001-08-10 Marc Autret <autret_m@epita.fr>
1730 * src/print_graph.h: Fix.
1731 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
1733 2001-08-10 Akim Demaille <akim@epita.fr>
1735 * src/system.h: Provide default declarations for stpcpy, strndup,
1738 2001-08-10 Robert Anisko <anisko_r@epita.fr>
1740 * doc/bison.texinfo (Locations): Update @$ stuff.
1742 2001-08-09 Robert Anisko <anisko_r@epita.fr>
1744 * src/bison.simple (YYLLOC_DEFAULT): Update.
1747 2001-08-08 Marc Autret <autret_m@epita.fr>
1749 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
1750 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
1751 Reported by Fabrice Bauzac.
1753 2001-08-08 Marc Autret <autret_m@epita.fr>
1755 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
1756 * src/vcg.c (output_node): Fix.
1757 * src/vcg.h: Cleanup.
1758 * src/print_graph.c: Add comments.
1759 (node_output_size): New global variable. Simplify the formatting of
1760 the VCG graph output.
1761 (print_actions): Unused code is now used. It notifies the final state
1762 and no action states in the VCG graph. It also give the reduce actions.
1763 The `shift and goto' edges are red and the `go to state' edges are
1765 Get the current node name and node_obstack by argument.
1766 (node_obstack): New variable.
1767 (print_state): Manage node_obstack.
1768 (print_core): Use node_obstack given by argument.
1769 A node is not only computed here but in print_actions also.
1770 (print_graph): CPP out useless code instead of commenting it.
1772 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
1774 * tests/atconfig.in (CPPFLAGS): Fix.
1776 2001-08-07 Akim Demaille <akim@epita.fr>
1778 * src/print_graph.c (quote): New.
1779 (print_core): Use it.
1781 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
1783 * src/vcg.c (complain.h): Include it.
1784 Unepitaize `return' invocations.
1785 [NDEBUG] (main): Remove.
1786 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
1787 * src/files.c (open_files): Initialize graph_obstack.
1788 * src/print_graph.c (print_actions): CPP out useless code.
1789 (print_core): Don't output the last `\n' in labels.
1791 * src/files.c (output_files): Output the VCG file.
1792 * src/main.c (main): Invoke print_graph ();
1794 2001-08-06 Marc Autret <autret_m@epita.fr>
1796 Automaton VCG graph output.
1797 Using option ``-g'' or long option ``--graph'', you can generate
1798 a gram_filename.vcg file containing a VCG description of the LALR (1)
1799 automaton of your grammar.
1801 * src/main.c: Call to print_graph() function.
1802 * src/getargs.h: Update.
1803 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
1804 (graph_flag): New flag.
1806 (getargs): Add case `g'.
1807 * src/files.c (graph_obstack): New obstack struct.
1808 (open_files): Initialize new obstack.
1809 (output_files): Saves graph_obstack if required.
1810 * src/files.h (graph_obstack): New extern declaration.
1811 * src/Makefile.am: Add new source files.
1813 2001-08-06 Marc Autret <autret_m@epita.fr>
1815 * src/print_graph.c, src/print_graph.h (graph): New.
1816 * src/vcg.h: New file.
1817 * src/vcg.c: New file, VCG graph handling.
1819 2001-08-06 Marc Autret <autret_m@epita.fr>
1821 Add of %source_extension and %header_extension which specify
1822 the source or/and the header output file extension.
1824 * src/files.c (compute_base_names): Remove initialisation of
1825 src_extension and header_extension.
1826 (compute_exts_from_gf): Update.
1827 (compute_exts_from_src): Update.
1828 (output_files): Update.
1829 * src/reader.c (parse_header_extension_decl): New.
1830 (parse_source_extension_decl): New.
1831 (read_declarations): New case statements for the new tokens.
1832 * src/lex.c (percent_table): Add entries for %source_extension
1833 and %header_extension.
1834 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
1836 2001-08-06 Marc Autret <autret_m@epita.fr>
1838 * configure.in: Bump to 1.28c.
1839 * doc/bison.texinfo: Texinfo thingies.
1841 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
1843 * tests/atconfig.in (CPPFLAGS): Add.
1844 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
1846 2001-08-03 Akim Demaille <akim@epita.fr>
1850 2001-08-03 Akim Demaille <akim@epita.fr>
1852 * tests/Makefile.am (check-local): Ship testsuite.
1853 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
1856 2001-08-03 Akim Demaille <akim@epita.fr>
1858 * configure.in: Try using -Wformat when compiling.
1860 2001-08-03 Akim Demaille <akim@epita.fr>
1862 * configure.in: Bump to 1.28b.
1864 2001-08-03 Akim Demaille <akim@epita.fr>
1866 * src/complain.c: Adjust strerror_r portability issues.
1868 2001-08-03 Akim Demaille <akim@epita.fr>
1872 2001-08-03 Akim Demaille <akim@epita.fr>
1874 * src/getargs.c, src/getarg.h (skeleton)): Constify.
1875 * src/lex.c (literalchar): Avoid name clashes on `buf'.
1876 * src/getargs.c: Include complain.h.
1877 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
1878 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
1880 2001-08-03 Akim Demaille <akim@epita.fr>
1882 * src/reader.c (readgram): Display hidden chars in error messages.
1884 2001-08-03 Akim Demaille <akim@epita.fr>
1886 Update to gettext 0.10.39.
1888 2001-08-03 Akim Demaille <akim@epita.fr>
1890 * lib/strspn.c: New.
1892 2001-08-01 Marc Autret <autret_m@epita.fr>
1894 * doc/bison.texinfo: Update.
1895 * doc/bison.1 (mandoc): Update.
1896 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
1897 * src/files.c: Support output files extensions computing.
1898 (src_extension): New static variable.
1899 (header_extension): New static variable.
1901 (get_extension_index): New function, gets the index of an extension
1902 filename in a string.
1903 (compute_exts_from_gf): New function, computes extensions from the
1904 grammar file extension.
1905 (compute_exts_from_src): New functions, computes extensions from the
1906 C source file extension, file given by ``-o'' option.
1907 (compute_base_names): Update.
1908 (output_files): Update.
1910 2001-08-01 Robert Anisko <anisko_r@epita.fr>
1912 * doc/bison.texi: Document @$.
1913 (Locations): New section.
1915 2001-07-18 Akim Demaille <akim@epita.fr>
1917 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
1918 * config/prev-version.txt, config/move-if-change: New.
1919 * Makefile.am: Adjust.
1921 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
1923 * src/bison.simple (yyparse): Suppress warning `comparaison
1924 between signed and unsigned'.
1926 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
1928 * src/getargs.h (raw_flag): Remove.
1929 * src/getargs.c: Die on `-r'/`--raw'.
1930 * src/lex.c (parse_percent_token): Die on `%raw'.
1931 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
1932 * tests/calc.at: Suppress test with option `--raw'.
1934 2001-07-14 Akim Demaille <akim@epita.fr>
1937 * configure.in: Require Autoconf 2.50.
1938 Update to gettext 0.10.38.
1940 2001-03-16 Akim Demaille <akim@epita.fr>
1942 * doc/bison.texinfo: ANSIfy the examples.
1944 2001-03-16 Akim Demaille <akim@epita.fr>
1946 * getargs.c (skeleton): New variable.
1947 (longopts): --skeleton is a new option.
1948 (shortopts, getargs): -S is a new option.
1949 * getargs.h: Declare skeleton.
1950 * output.c (output_parser): Use it.
1952 2001-03-16 Akim Demaille <akim@epita.fr>
1954 * m4/strerror_r.m4: New.
1955 * m4/error.m4: Run AC_FUNC_STRERROR_R.
1956 * lib/error.h, lib/error.c: Update.
1958 2001-03-16 Akim Demaille <akim@epita.fr>
1960 * src/getargs.c (longopts): Clean up.
1962 2001-02-21 Akim Demaille <akim@epita.fr>
1964 * src/reader.c (gensym): `gensym_count' is your own.
1965 Use a static buf to create the symbol name, as token_buffer is no
1968 2001-02-08 Akim Demaille <akim@epita.fr>
1970 * src/conflicts.c (conflict_report): Be sure not to append to res
1971 between two calls, which could happen if both first sprintf were
1972 skipped, but not the first cp += strlen.
1974 2001-02-08 Akim Demaille <akim@epita.fr>
1976 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
1977 New, from fileutils 4.0.37.
1978 * configure.in: Require Autoconf 2.49c. I took some time before
1979 making this decision. This is the only way out for portability
1980 issues in Bison, it would mean way too much duplicate effort to
1981 import in Bison features implemented in 2.49c since 2.13.
1982 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
1984 2001-02-02 Akim Demaille <akim@epita.fr>
1986 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
1987 * lib/xalloc.h, lib/xmalloc.c: Update.
1989 2001-01-19 Akim Demaille <akim@epita.fr>
1991 Get rid of the ad hoc handling of token_buffer in the scanner: use
1994 * src/lex.c (token_obstack): New.
1995 (init_lex): Initialize it. No longer call...
1996 (grow_token_buffer): this. Remove it.
1997 Adjust all the places which used it to use the obstack.
1999 2001-01-19 Akim Demaille <akim@epita.fr>
2001 * src/lex.h: Rename all the tokens:
2002 s/\bENDFILE\b/tok_eof/g;
2003 s/\bIDENTIFIER\b/tok_identifier/g;
2005 Let them be enums, not #define, to ease debugging.
2006 Adjust all the code.
2008 2001-01-18 Akim Demaille <akim@epita.fr>
2010 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
2011 * src/lex.c (maxtoken, grow_token_buffer): Static.
2013 2001-01-18 Akim Demaille <akim@epita.fr>
2015 Since we now use obstacks, more % directives can be enabled.
2017 * src/lex.c (percent_table): Also accept `%yacc',
2018 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
2020 Handle the actions for `%semantic_parser' and `%pure_parser' here,
2021 instead of returning a token.
2022 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
2023 * src/reader.c (read_declarations): Adjust.
2024 * src/files.c (open_files): Don't call `compute_base_names', don't
2025 compute `attrsfile' since they depend upon data which might be
2026 *in* the input file now.
2027 (output_files): Do it here.
2028 * src/output.c (output_headers): Document the fact that this patch
2029 introduces a guaranteed SEGV for semantic parsers.
2030 * doc/bison.texinfo: Document them.
2031 * tests/suite.at: Exercise these %options.
2033 2000-12-20 Akim Demaille <akim@epita.fr>
2035 Also handle the output file (--verbose) with obstacks.
2037 * files.c (foutput): Remove.
2038 (output_obstack): New.
2039 Adjust all dependencies.
2040 * src/conflicts.c: Return a string.
2041 * src/system.h (obstack_grow_string): Rename as...
2042 (obstack_sgrow): this. Be ready to work with non literals.
2043 (obstack_fgrow4): New.
2045 2000-12-20 Akim Demaille <akim@epita.fr>
2047 * src/files.c (open_files): Fix the computation of short_base_name
2048 in the case of `-o foo.tab.c'.
2050 2000-12-20 Akim Demaille <akim@epita.fr>
2052 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
2053 (copy_dollar): Now that everything uses obstacks, get rid of the
2056 2000-12-20 Akim Demaille <akim@epita.fr>
2058 * src/files.c (open_files): Actually the `.output' file is based
2059 on the short_base_name, not base_name.
2060 * tests/suite.at (Checking output file names): Adjust.
2062 2000-12-20 Akim Demaille <akim@epita.fr>
2064 * src/bison.s1: Remove, we now use directly...
2065 * src/bison.simple: this.
2066 * src/Makefile.am: Use pkgdata instead of data.
2068 2000-12-20 Akim Demaille <akim@epita.fr>
2070 * src/files.c (guard_obstack): New.
2071 (open_files): Initialize it.
2072 (output_files): Dump it...
2073 * src/files.h: Export it.
2074 * src/reader.c (copy_guard): Use it.
2076 2000-12-19 Akim Demaille <akim@epita.fr>
2078 * src/files.c (outfile, defsfile, actfile): Removed as global
2080 (open_files): Don't compute them.
2081 (output_files): Adjust.
2082 (base_name, short_base_name): Be global.
2083 Adjust dependencies.
2085 2000-12-19 Akim Demaille <akim@epita.fr>
2087 * src/files.c (strsuffix): New.
2088 (stringappend): Be just like strcat but allocate.
2089 (base_names): Eve out from open_files.
2090 Try to simplify the rather hairy computation of base_name and
2092 (open_files): Use it.
2093 * tests/suite.at (Checking output file names): New test.
2095 2000-12-19 Akim Demaille <akim@epita.fr>
2097 * src/system.h (obstack_grow_literal_string): Rename as...
2098 (obstack_grow_string): this.
2099 * src/output.c (output_parser): Recognize `%% actions' instead of
2101 * src/bison.s1: s/$/%% actions/.
2102 * src/bison.hairy: Likewise.
2104 2000-12-19 Akim Demaille <akim@epita.fr>
2106 * src/output.c (output_parser): Compute the `#line' lines when
2108 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
2109 Suggested by Hans Aberg.
2111 2000-12-19 Akim Demaille <akim@epita.fr>
2113 Let the handling of the skeleton files be local to the procedures
2116 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
2118 (fparser, open_extra_files): Remove.
2119 (open_files, output_files): Don't take care of fparser.
2120 * src/files.h: Adjust.
2121 * src/output.c (output_parser): Open and close the file to the
2123 * src/reader.c (read_declarations): When %semantic_parser, open
2126 2000-12-19 Akim Demaille <akim@epita.fr>
2128 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
2129 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
2131 2000-12-19 Akim Demaille <akim@epita.fr>
2133 * src/files.c (open_files): Yipee! We no longer need all the code
2134 looking for `/tmp' since we have no tmp file.
2136 2000-12-19 Akim Demaille <akim@epita.fr>
2138 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
2140 * src/files.c (open_files): Less dependency on MSDOS etc.
2142 2000-12-14 Akim Demaille <akim@epita.fr>
2144 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
2145 Provide a default definition.
2146 Use it when executing the default @ action.
2147 * src/reader.c (reader_output_yylsp): No longer include
2148 `timestamp' and `text' in the default YYLTYPE.
2150 2000-12-12 Akim Demaille <akim@epita.fr>
2152 * src/reader.c (copy_definition, parse_union_decl, copy_action)
2153 (copy_guard): Quote the file names.
2154 Reported by Laurent Mascherpa.
2156 2000-12-12 Akim Demaille <akim@epita.fr>
2158 * src/output.c (output_headers, output_program, output): Be sure
2159 to escape special characters when outputting filenames.
2160 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
2161 (output_headers): Don't depend on them, Use ACTSTR.
2163 2000-11-17 Akim Demaille <akim@epita.fr>
2165 * lib/obstack.h: Formatting changes.
2166 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
2167 prevents type checking.
2168 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
2169 cast the value to (void *): assigning a `foo *' to a `void *'
2171 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
2172 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
2175 2000-11-17 Akim Demaille <akim@epita.fr>
2177 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
2179 (suite.m4, regression.m4, calc.m4): these.
2180 * tests/atgeneral.m4: Update from CVS Autoconf.
2182 2000-11-17 Akim Demaille <akim@epita.fr>
2184 * tests/regression.m4 (%union and --defines): New test,
2185 demonstrating a current bug in the obstack implementation.
2187 2000-11-17 Akim Demaille <akim@epita.fr>
2189 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
2191 Use them to declare the variables which are global or local to
2194 2000-11-17 Akim Demaille <akim@epita.fr>
2196 * acconfig.h: Remove, no longer used.
2198 2000-11-07 Akim Demaille <akim@epita.fr>
2200 * src: s/Copyright (C)/Copyright/g.
2202 2000-11-07 Akim Demaille <akim@epita.fr>
2204 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
2206 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
2208 2000-11-07 Akim Demaille <akim@epita.fr>
2210 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
2211 Merge in a single CPP if/else.
2213 2000-11-07 Akim Demaille <akim@epita.fr>
2215 * src/output.c (output): Remove useless variables.
2216 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
2217 argument `data' for consistency with the prototypes.
2219 (obstack_copy, obstack_copy0): Rename the second argument as
2220 `address' for consistency. Qualify it `const'.
2221 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
2222 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
2223 `const' their input argument (`data' or `address').
2224 Adjust the corresponding macros to include `const' in casts.
2226 2000-11-03 Akim Demaille <akim@epita.fr>
2228 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
2229 s/PFILE1/BISON_HAIRY/.
2230 Adjust dependencies.
2232 2000-11-03 Akim Demaille <akim@epita.fr>
2234 For some reason, this was not applied.
2236 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2237 `unlink': it's no longer used.
2239 2000-11-03 Akim Demaille <akim@epita.fr>
2241 * src/files.c (skeleton_find): New function, eved out of...
2242 (open_files, open_extra_files): here.
2244 2000-11-03 Akim Demaille <akim@epita.fr>
2248 * src/files.c (obstack_save): New function.
2249 (done): Rename as...
2250 (output_files): this.
2252 * src/main.c (main): Don't use `atexit' to register `done', since
2253 it no longer has to remove tmp files, just call `output_files'
2254 when there are no errors.
2256 2000-11-02 Akim Demaille <akim@epita.fr>
2258 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2259 `unlink': it's no longer used.
2260 * src/files.h: Formatting changes.
2262 2000-11-02 Akim Demaille <akim@epita.fr>
2264 Remove the last uses of mktemp and unlink/delete.
2266 * src/files.c (fdefines, ftable): Removed.
2267 (defines_ostack, table_obstack): New.
2268 Adjust dependencies of the former into uses of the latter.
2269 * src/output.c (output_short_or_char_table, output_short_table):
2270 Convert to using obstacks.
2271 * src/reader.c (copy_comment2): Accept one FILE * and two
2273 (output_token_defines, reader_output_yylsp): Use obstacks.
2274 * src/system.h (obstack_fgrow3): New.
2276 2000-11-01 Akim Demaille <akim@epita.fr>
2278 Change each use of `fattrs' into a use of `attrs_obstack'.
2280 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
2281 * src/files.c (fattrs): Remove.
2282 (attrs_obstack): New.
2283 Adjust all dependencies.
2284 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
2286 2000-11-01 Akim Demaille <akim@epita.fr>
2289 Change each use of `faction' into a use of `action_obstack'.
2291 * lib/obstack.h, lib/obstack.c: New files.
2292 * src/files.c (faction): Remove.
2293 (action_obstack): New.
2294 Adjust all dependencies.
2296 2000-10-20 Akim Demaille <akim@epita.fr>
2298 * lib/quote.h (PARAMS): New macro. Use it.
2300 2000-10-16 Akim Demaille <akim@epita.fr>
2302 * src/output.c (output_short_or_char_table): New function.
2303 (output_short_table, output_token_translations): Use it.
2304 (goto_actions): Use output_short_table.
2306 2000-10-16 Akim Demaille <akim@epita.fr>
2308 * src/symtab.c (bucket_new): New function.
2311 * src/output.c (output_short_table): New argument to display the
2312 comment associated with the table.
2313 Adjust dependencies.
2314 (output_gram): Use it.
2315 (output_rule_data): Nicer output layout for YYTNAME.
2317 2000-10-16 Akim Demaille <akim@epita.fr>
2319 * src/lex.c (read_typename): New function.
2321 * src/reader.c (copy_dollar): Likewise.
2323 2000-10-16 Akim Demaille <akim@epita.fr>
2325 * src/reader.c (copy_comment2): Expect the input stream to be on
2326 the `/' which is suspected to open a comment, instead of being
2327 called after `//' or `/*' was read.
2328 (copy_comment, copy_definition, parse_union_decl, copy_action)
2329 (copy_guard): Adjust.
2331 2000-10-16 Akim Demaille <akim@epita.fr>
2333 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
2334 `read_signed_integer'.
2336 2000-10-16 Akim Demaille <akim@epita.fr>
2338 * src/reader.c (copy_dollar): New function.
2339 (copy_guard, copy_action): Use it.
2341 2000-10-16 Akim Demaille <akim@epita.fr>
2343 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
2344 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
2345 New files, from Fileutils 4.0.27.
2346 * src/main.c (printable_version): Remove.
2347 * src/lex.c, src/reader.c: Use `quote'.
2349 2000-10-04 Akim Demaille <akim@epita.fr>
2351 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
2353 2000-10-04 Akim Demaille <akim@epita.fr>
2355 * doc/bison.texinfo: Various typos spotted by Neil Booth.
2357 2000-10-04 Akim Demaille <akim@epita.fr>
2359 When a literal string is used to define two different tokens,
2360 `bison -v' segfaults.
2361 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
2363 * tests/regression.m4: New file.
2364 Include the core of the sample provided by Piotr Gackiewicz.
2365 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
2368 2000-10-04 Akim Demaille <akim@epita.fr>
2370 * src/reader.c (parse_expect_decl): Keep `count' within the size
2374 2000-10-02 Paul Eggert <eggert@twinsun.com>
2376 * bison.s1 (yyparse): Assign the default value
2377 unconditionally, to avoid a GCC warning and make the parser a
2380 2000-10-02 Akim Demaille <akim@epita.fr>
2382 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
2385 2000-10-02 Akim Demaille <akim@epita.fr>
2387 * src/derives.c, src/print.c, src/reduce.c: To ease the
2388 translation, move some `\n' out of the translated strings.
2390 2000-10-02 Akim Demaille <akim@epita.fr>
2392 The location tracking mechanism is precious for parse error
2393 messages. Nevertheless, it is enabled only when `@n' is used in
2394 the grammar, which is a different issue (you can use it in error
2395 message, but not in the grammar per se). Therefore, there should
2396 be another means to enable it.
2398 * src/getargs.c (getargs): Support `--locations'.
2400 * src/getargs.h (locationsflag): Export it.
2401 * src/lex.c (percent_table): Support `%locations'.
2402 * src/reader.c (yylsp_needed): Remove this variable, now replaced
2403 with `locationsflag'.
2404 * doc/bison.texinfo: Document `--locations' and `%locations'.
2406 * tests/calc.m4: Test it.
2408 For regularity of the names, replace each
2409 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
2410 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
2411 In addition replace each `flag' with `_flag'.
2413 2000-10-02 Akim Demaille <akim@epita.fr>
2415 Also test parse error messages, including with YYERROR_VERBOSE.
2417 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
2419 Use it to check the computations.
2420 Use it to check `nonassoc' is honored.
2421 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
2422 `--yyerror-verbose'.
2423 (_AT_CHECK_CALC): Adjust to this option.
2424 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
2426 2000-10-02 Akim Demaille <akim@epita.fr>
2428 Test also `--verbose', `--defines' and `--name-prefix'. Testing
2429 the latter demonstrates a flaw in the handling of non debugging
2430 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
2431 was used in order to simplify:
2447 unfortunately this leads to a CPP conflict when
2448 `--name-prefix=foo' is used since it produces `#define yydebug
2451 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
2452 (YYDPRINTF): New macro.
2454 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
2456 Also test `--verbose', `--defines' and `--name-prefix'.
2458 2000-10-02 Akim Demaille <akim@epita.fr>
2460 Improve the readability of the produced parsers.
2462 * src/bison.s1: Formatting changes.
2463 Improve the comment related to the `$' mark.
2464 (yydefault): Don't fall through to `yyresume': `goto' there.
2465 * src/output.c (output_parser): When the `$' is met, skip the end
2467 New variable, `number_of_dollar_signs', to check there's exactly
2468 one `$' in the parser skeleton.
2470 2000-10-02 Akim Demaille <akim@epita.fr>
2472 * lib/xstrdup.c: New file, from the fileutils.
2473 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
2474 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
2475 instead of strlen + xmalloc + strcpy.
2476 * src/symtab.c (copys): Remove, use xstrdup instead.
2478 2000-10-02 Akim Demaille <akim@epita.fr>
2480 * src/gram.h (associativity): New enum type which replaces the
2481 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
2482 `right_assoc', `left_assoc' and `non_assoc'.
2483 Adjust all dependencies.
2484 * src/reader.c: Formatting changes.
2485 (LTYPESTR): Don't define it, use it as a literal in
2486 `reader_output_yylsp'.
2487 * src/symtab.h (symbol_class): New enum type which replaces the
2488 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
2489 `sunknown', `stoken and `snterm'.
2491 2000-10-02 Akim Demaille <akim@epita.fr>
2493 * src/getargs.c (fixed_outfiles): Rename as...
2494 (yaccflag): for consistency and accuracy.
2495 Adjust dependencies.
2497 2000-10-02 Akim Demaille <akim@epita.fr>
2499 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
2500 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
2501 difficult and introduced a lot of core dump. It turns out that
2502 Bison used an implementation of `xmalloc' based on `calloc', and
2503 at various places it does depend upon the initialization to 0. I
2504 have not tried to isolate the pertinent places, and all the former
2505 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
2506 someone should address this issue.
2508 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
2509 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
2511 Adjust dependencies.
2512 * src/warshall.h: New file.
2515 2000-10-02 Akim Demaille <akim@epita.fr>
2517 Various anti-`extern in *.c' changes.
2519 * src/system.h: Include `assert.h'.
2521 2000-10-02 Akim Demaille <akim@epita.fr>
2523 * src/state.h (nstates, final_state, first_state, first_shift)
2524 (first_reduction): Move their exportation from here...
2525 * src/LR0.h: to here.
2526 Adjust dependencies.
2527 * src/getargs.c (statisticsflag): New variable.
2528 Add support for `--statistics'.
2529 Adjust dependencies.
2531 Remove a lot of now useless `extern' statements in most files.
2533 2000-10-02 Akim Demaille <akim@epita.fr>
2535 * src/LR0.h: New file.
2538 2000-10-02 Akim Demaille <akim@epita.fr>
2540 * src/print.h: New file.
2542 * src/print.c: Formatting and ordering changes.
2543 (verbose, terse): Replace with...
2544 (print_results): this new function.
2545 Adjust dependencies.
2547 2000-10-02 Akim Demaille <akim@epita.fr>
2549 * src/conflicts.c (conflict_report): New function.
2550 (conflict_log, verbose_conflict_log): Replace with...
2551 (print_conflicts): this function.
2552 Adjust dependencies.
2553 * src/conflicts.h: New file.
2554 Propagate its inclusion.
2556 2000-10-02 Akim Demaille <akim@epita.fr>
2558 * src/nullable.h: New file.
2559 Propagate its inclusion.
2560 * src/nullable.c: Formatting changes.
2562 2000-10-02 Akim Demaille <akim@epita.fr>
2564 * src/reduce.h: New file.
2565 Propagate its inclusion.
2566 * src/reduce.c: Topological sort and other formatting changes.
2567 (bool, TRUE, FALSE): Move their definition to...
2568 * src/system.h: here.
2570 2000-10-02 Akim Demaille <akim@epita.fr>
2572 * src/files.c: Formatting changes.
2573 (tryopen, tryclose, openfiles): Rename as...
2574 (xfopen, xfclose, open_files): this.
2575 (stringappend): static.
2576 * src/files.h: Complete the list of exported symbols.
2579 2000-10-02 Akim Demaille <akim@epita.fr>
2581 * src/reader.h: New file.
2582 Propagate its use instead of tedious list of `extern' and
2584 * src/reader.c: Formatting changes, topological sort,
2587 2000-10-02 Akim Demaille <akim@epita.fr>
2589 * src/lex.h: Prototype `lex.c' exported functions.
2590 * src/reader.c: Adjust.
2591 * src/lex.c: Formatting changes.
2592 (safegetc): Rename as...
2595 2000-10-02 Akim Demaille <akim@epita.fr>
2597 * src/lalr.h: New file.
2598 Propagate its inclusion instead of prototypes and `extern'.
2599 * src/lalr.c: Formatting changes, topological sorting etc.
2601 2000-10-02 Akim Demaille <akim@epita.fr>
2603 * src/output.c (token_actions): Introduce a temporary array,
2604 YYDEFACT, that makes it possible for this function to use
2607 2000-10-02 Akim Demaille <akim@epita.fr>
2609 `user_toknums' is output as a `short[]' in `output.c', while it is
2610 defined as a `int[]' in `reader.c'. For consistency with the
2611 other output tables, `user_toknums' is now defined as a table of
2614 * src/reader.c (user_toknums): Be a short table instead of an int
2616 Adjust dependencies.
2618 Factor the short table outputs.
2620 * src/output.c (output_short_table): New function.
2621 * src/output.c (output_gram, output_stos, output_rule_data)
2622 (output_base, output_table, output_check): Use it.
2624 2000-10-02 Akim Demaille <akim@epita.fr>
2626 * src/output.c (output): Topological sort of the functions, in
2627 order to get rid of the `static' prototypes.
2628 No longer use `register'.
2629 * src/output.h: New file.
2630 Propagate its inclusion in files explicitly prototyping functions
2633 2000-09-21 Akim Demaille <akim@epita.fr>
2635 * src/atgeneral.m4: Update from Autoconf.
2637 2000-09-21 Akim Demaille <akim@epita.fr>
2639 * src/closure.h: New file.
2640 * src/closure.c: Formatting changes, topological sort over the
2641 functions, use of closure.h.
2642 (initialize_closure, finalize_closure): Rename as...
2643 (new_closure, free_closure): these. Adjust dependencies.
2644 * src/LR0.c: Formatting changes, topological sort, use of
2646 (initialize_states): Rename as...
2648 * src/Makefile.am (noinst_HEADERS): Adjust.
2650 2000-09-20 Akim Demaille <akim@epita.fr>
2652 * src/acconfig.h: Don't protect config.h against multiple
2654 Don't define PARAMS.
2655 * src/system.h: Define PARAMS.
2656 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
2657 purpose of config.h. system.h must not try to fix wrong
2658 definitions in config.h.
2660 2000-09-20 Akim Demaille <akim@epita.fr>
2662 * src/derives.h: New file.
2663 * src/main.c, src/derives.h: Use it.
2665 * src/Makefile.am (noinst_HEADERS): Adjust.
2667 2000-09-20 Akim Demaille <akim@epita.fr>
2669 * tests/atgeneral.m4: Update from Autoconf.
2670 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
2671 (AT_CHECK_CALC): New macros.
2672 Use these macros to test bison with options `', `--raw',
2673 `--debug', `--yacc', `--yacc --debug'.
2675 2000-09-19 Akim Demaille <akim@epita.fr>
2677 * src/output.c: Formatting changes.
2678 * src/machine.h: Remove, leaving its contents in...
2679 * src/system.h: here.
2681 Adjust all dependencies on stdio.h and machine.h.
2682 * src/getargs.h: New file.
2683 Let all `extern' declarations about getargs.c be replaced with
2684 inclusion of `getargs.h'.
2685 * src/Makefile.am (noinst_HEADERS): Adjust.
2687 * tests/calc.m4 (yyin): Be initialized in main, not on the global
2689 (yyerror): Returns void, not int.
2690 * doc/bison.texinfo: Formatting changes.
2692 2000-09-19 Akim Demaille <akim@epita.fr>
2694 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
2697 2000-09-18 Akim Demaille <akim@epita.fr>
2699 * configure.in: Append WARNING_CFLAGS to CFLAGS.
2700 * src/Makefile.am (INCLUDES): Don't.
2701 Be ready to fetch headers in lib/.
2703 2000-09-18 Akim Demaille <akim@epita.fr>
2705 * doc/bison.texinfo: Update the copyright.
2706 ANSIfy and GNUify the examples.
2707 Remove the old menu.
2709 2000-09-18 Akim Demaille <akim@epita.fr>
2711 First set of tests: use the `calc' example from the documentation.
2713 * src/bison.s1 (yyparse): Condition the code using `yytname' which
2714 is defined only when YYDEBUG is.
2715 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
2716 * src/files.c (tryopen, tryclose): Formatting changes.
2717 Move to the top and be static.
2718 * src/reader.c (read_signed_integer): Likewise.
2719 * tests/calc.m4: New file.
2720 * Makefile.am, suite.m4: Adjust.
2721 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
2723 2000-09-18 Akim Demaille <akim@epita.fr>
2725 Add support for an Autotest test suite for Bison.
2727 * m4/m4.m4, m4/atconfig.m4: New files.
2728 * m4/Makefile.am (EXTRA_DIST): Adjust.
2729 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
2731 * src/getargs.c: Display a more standard --version message.
2732 * src/reader.c (reader): Formatting changes.
2733 No longer depend upon VERSION_STRING.
2734 * configure.in: No longer use `dnl'.
2735 Set up the test suite and the new directory `tests/.
2736 (VERSION_STRING): Remove.
2738 2000-04-14 Akim Demaille <akim@epita.fr>
2740 * src/reader.c (copy_comment2): New function, same as former
2741 `copy_comment', but outputs into two FILE *.
2742 (copy_comment): Use it.
2743 (parse_union_decl): Use it.
2744 (get_type, parse_start_decl): Use the same `invalid' message.
2745 (parse_start_decl, parse_union_decl): Use the same `multiple'
2747 (parse_union_decl, copy_guard, copy_action): Use the same
2748 `unmatched' message.
2749 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
2751 2000-03-31 Akim Demaille <akim@epita.fr>
2753 * src/files.c (tryopen, tryclose): Move to the top.
2756 2000-03-31 Akim Demaille <akim@epita.fr>
2758 * src/main.c (main): Don't call `done', exit does it.
2760 2000-03-31 Akim Demaille <akim@epita.fr>
2762 * allocate.c: s/return (foo)/return foo/.
2765 * output.c: Likewise.
2766 * reader.c: Likewise.
2767 * symtab.c: Likewise.
2768 * vmsgetargs.c: Likewise.
2770 2000-03-31 Akim Demaille <akim@epita.fr>
2772 Clean up the error reporting functions.
2774 * src/report.c: New file.
2775 * src/report.h: Likewise.
2776 * src/Makefile.am: Adjust.
2777 * m4/error.m4: New file.
2778 * m4/Makefile.am: Adjust.
2779 * configure.in (jm_PREREQ_ERROR): Call it.
2780 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
2782 (fatal, fatals): Remove. All callers use complain.c::fatal.
2783 (warn, warni, warns, warnss, warnss): Remove. All callers use
2784 complain.c::complain.
2785 (toomany): Remove, use fatal instead.
2786 * src/files.c (done): No argument, use complain_message_count.
2787 * src/main.c (main): Register `done' to `atexit'.
2789 * src/getargs.c (usage): More `fputs', less `fprintf'.
2791 2000-03-28 Akim Demaille <akim@epita.fr>
2793 * lib/: New directory.
2794 * Makefile.am (SUBDIRS): Adjust.
2795 * configure.in: Adjust.
2796 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
2798 * src/alloca.c: Moved to lib/.
2799 * src/getopt.c: Likewise.
2800 * src/getopt1.c: Likewise.
2801 * src/getopt.h: Likewise.
2802 * src/ansi2knr.c: Likewise.
2803 * src/ansi2knr.1: Likewise.
2804 * src/Makefile.am: Adjust.
2805 * lib/Makefile.am: New file.
2807 2000-03-28 Akim Demaille <akim@epita.fr>
2809 * src/getargs.c (usage): Refresh the help message.
2811 2000-03-17 Akim Demaille <akim@epita.fr>
2813 * src/getopt1.c: Updated from textutils 2.0e
2814 * src/getopt.c: Likewise.
2815 * src/getopt.h: Likewise.
2817 2000-03-17 Akim Demaille <akim@epita.fr>
2819 * src/Makefile.am (bison.simple): Fix the awk program: quote only
2820 the file name, not the whole `#line LINE FILE'.
2822 2000-03-17 Akim Demaille <akim@epita.fr>
2824 On syntax errors, report the token on which we choked.
2826 * src/bison.s1 (yyparse): In the label yyerrlab, when
2827 YYERROR_VERBOSE, add yychar in msg.
2829 2000-03-17 Akim Demaille <akim@epita.fr>
2831 * src/reader.c (copy_at): New function.
2832 (copy_guard): Use it.
2833 (copy_action): Use it.
2835 2000-03-17 Akim Demaille <akim@epita.fr>
2837 Be kind to translators, save some useless translations.
2839 * src/main.c (banner): New function.
2840 (fatal_banner): Use it.
2841 (warn_banner): Use it.
2843 2000-03-17 Akim Demaille <akim@epita.fr>
2845 * src/reader.c (copy_definition): Use copy_string and
2846 copy_comment. Removed now unused `match', `ended',
2848 (copy_comment, copy_string): Moved, to be visible from
2851 2000-03-17 Akim Demaille <akim@epita.fr>
2853 * src/reader.c (copy_string): Declare `static inline'. No
2854 problems with inline, since it is checked by configure.
2855 (copy_comment): Likewise.
2857 2000-03-17 Akim Demaille <akim@epita.fr>
2859 * src/reader.c (packsymbols): Formatting changes.
2861 2000-03-17 Akim Demaille <akim@epita.fr>
2863 * src/reader.c (copy_comment): New function, factored out from:
2864 (copy_action): Use it. Removed now unused `match', `ended',
2866 (copy_guard): Likewise.
2868 2000-03-17 Akim Demaille <akim@epita.fr>
2870 * src/reader.c (copy_string): New function, factored out from:
2871 (copy_action): Use it.
2872 (copy_guard): Likewise.
2874 2000-03-17 Akim Demaille <akim@epita.fr>
2876 Change the handling of @s so that they behave exactly like $s.
2877 There is now a pseudo variable @$ (readble and writable), location
2878 of the lhs of the rule (by default ranging from the location of
2879 the first symbol of the rhs, to the location of the last symbol,
2880 or, if the rhs is empty, YYLLOC).
2882 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
2884 (yyparse): When providing a default semantic action, provide a
2885 default location action.
2886 (after the $): No longer change `*YYLSP', just stack YYLOC the
2887 same way you stack YYVAL.
2888 * src/reader.c (read_declarations): Use warns.
2889 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
2890 (copy_action, case '@'): Likewise.
2891 Use a standard error message, to save useless work from
2894 2000-03-17 Akim Demaille <akim@epita.fr>
2896 * src/bison.s1: Formatting and cosmetics changes.
2897 * src/reader.c: Likewise.
2898 Update the Copyright notice.
2900 2000-03-17 Akim Demaille <akim@epita.fr>
2902 * src/bison.s1 (#line): All set to `#line' only, since the
2903 Makefile now handles them.
2905 2000-03-16 Akim Demaille <akim@epita.fr>
2907 * src/output.c (output_rule_data): Output the documentation of
2909 (Copyright notice): Update.
2912 2000-03-16 Akim Demaille <akim@epita.fr>
2914 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
2915 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
2916 One `#if YYDEBUG' remains, since it uses variables which are
2917 defined only if `YYDEBUG != 0'.
2919 2000-03-16 Akim Demaille <akim@epita.fr>
2921 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
2922 and related variables so that the similarities are highlighted.
2924 2000-03-16 Akim Demaille <akim@epita.fr>
2926 * src/bison.s1: Properly indent CPP directives.
2928 2000-03-16 Akim Demaille <akim@epita.fr>
2930 * src/bison.s1: Properly indent the `alloca' CPP section.
2932 2000-03-16 Akim Demaille <akim@epita.fr>
2934 Do not hard code values of directories in `configure.in'.
2935 Update the `configure' tool chain.
2937 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
2939 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
2940 (AC_OUTPUT): Add m4/Makefile.
2941 Bump to bison 1.28a, 1.29 has never been released.
2942 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
2943 handled via src/Makefile.am.
2944 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
2945 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
2947 * Makefile.am (SUBDIRS): Add m4.
2948 (ACLOCAL_AM_FLAGS): New variable.
2949 (AUTOMAKE_OPTIONS): Add check-news.
2950 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
2951 the proper line number and file name.
2952 (DEFS): Propagate the location of bison library files and of the
2954 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
2956 * acinclude.m4: Remove, replaced by the directory m4.
2957 * m4/Makefile.am (EXTRA_DIST): New variable.
2958 * m4/gettext.m4: New file, from the fileutils.
2959 * m4/lcmessage.m4: Likewise
2960 * m4/progtest.m4: Likewise.
2961 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
2963 2000-03-10 Akim Demaille <akim@epita.fr>
2966 Formatting changes of various comments.
2967 Respect the GNU coding standards at various places.
2968 Don't use `_()' when no translation is needed.
2970 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2973 OS/2 honors TMPDIR environment variable.
2975 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2977 * doc/bison.texinfo: Tweaked spelling and grammar.
2979 Removed reference to price of printed copy.
2980 Mention BISON_SIMPLE and BISON_HAIRY.
2982 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2984 * configure.in, NEWS:
2985 Bison 1.29 released.
2987 1999-10-27 Jesse Thilo <jthilo@gnu.org>
2989 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
2990 Added reference card.
2992 1999-07-26 Jesse Thilo <jthilo@gnu.org>
2994 * po/ru.po: Added Russian translation.
2996 1999-07-26 Jesse Thilo <jthilo@gnu.org>
2998 * configure.in: Added Russian translation.
3000 1999-07-06 Jesse Thilo <jthilo@gnu.org>
3002 * configure.in, NEWS, README:
3003 Released version 1.28.
3005 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3008 Squashed redefinition warning on some systems.
3010 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
3011 Have configure build version string instead of relying on ANSI string
3014 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3016 * po/POTFILES.in: Got rid of version.c.
3018 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3020 * acconfig.h, configure.in:
3021 Have configure build version string instead of relying on ANSI string
3024 1999-06-08 Jesse Thilo <jthilo@gnu.org>
3027 Dropped mention of `+' for long-named options.
3029 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3031 * src/files.c: Added <unistd.h> for unlink().
3033 * src/Makefile.am, src/system.h:
3036 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3038 * README: Added a FAQ list.
3040 * configure.in, acconfig.h:
3043 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3045 * doc/FAQ, doc/Makefile.am:
3048 1999-05-19 Jesse Thilo <jthilo@gnu.org>
3050 * src/alloc.h, src/symtab.h, src/version.c:
3051 Protected inclusion of "config.h" with HAVE_CONFIG_H.
3053 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3055 * src/.cvsignore, src/Makefile.am:
3056 Reorganized: sources in `src', documentation in `doc'.
3058 * src/lex.c (literalchar):
3059 fixed the code for escaping double quotes (thanks
3062 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3064 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
3065 Adjusted paths to reflect directory reorganization.
3067 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3069 * doc/.cvsignore, doc/Makefile.am:
3070 Reorganized: sources in `src', documentation in `doc'.
3072 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3075 Updated AC_INIT file to reflect directory reorganization.
3077 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
3078 Reorganized: sources in `src', documentation in `doc'.
3080 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3083 Don't declare calloc() and realloc() if not necessary.
3085 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3087 * configure.in, acconfig.h, acinclude.m4:
3088 Don't declare calloc() and realloc() if not necessary.
3090 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3092 * po/.cvsignore: Added i18n support.
3094 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3096 * acconfig.h, configure.in, Makefile.am:
3099 1999-03-22 Jesse Thilo <jthilo@gnu.org>
3101 * src/bison.s1: Fixed #line numbers.
3103 1999-03-15 Jesse Thilo <jthilo@gnu.org>
3105 * po/es.po, po/fr.po, po/nl.po, po/de.po:
3106 Added PO files from Translation Project.
3108 1999-03-03 Jesse Thilo <jthilo@gnu.org>
3111 Added support for non-ANSI compilers (ansi2knr).
3113 1999-02-16 Jesse Thilo <jthilo@gnu.org>
3115 * configure.in: Bumped version number to 1.27.
3118 Added `bison.simple' to list of files removed by `make distclean'.
3120 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3122 * src/files.c, src/files.h:
3123 Defined locations of parser files in config.h instead of Makefile.
3125 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3127 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
3128 Defined locations of parser files in config.h instead of Makefile.
3130 1999-02-09 Jesse Thilo <jthilo@gnu.org>
3133 Removed inappropriate use of $< macro.
3135 1999-02-05 Jesse Thilo <jthilo@gnu.org>
3137 * po/Makefile.in.in, po/POTFILES.in:
3138 Add `po' directory skeleton.
3140 1999-01-27 Jesse Thilo <jthilo@gnu.org>
3142 * README: Document help-bison list.
3144 * configure.in: Add check for mkstemp().
3146 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3148 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
3149 Hush a few compiler warnings.
3152 Add tryclose(), which verifies that fclose was successful.
3153 Hush a couple of compiler warnings.
3155 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3157 * Makefile.am, OChangeLog:
3158 ChangeLog is now automatically generated. Include the old version as
3161 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3163 * 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:
3166 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3168 * doc/bison.texinfo: Fix formatting glitch.
3170 * doc/bison.texinfo: Update FSF address.
3172 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3174 * acconfig.h: Update FSF address.
3176 1999-01-08 Jesse Thilo <jthilo@gnu.org>
3179 Don't define PACKAGE here, since config.h defines it.
3181 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3183 * src/reader.c: Update copyright date.
3186 Ditch sprintf to statically-sized buffers in fatal/warn functions in
3187 favor of output directly to stderr (avoids buffer overruns).
3189 * src/reader.c: Some checks for premature EOF.
3191 * 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:
3192 Use prototypes if the compiler understands them.
3194 * src/files.c: Honor TMPDIR on Unix hosts.
3195 Use prototypes if the compiler understands them.
3198 Fix a couple of buffer overrun bugs.
3199 Use prototypes if the compiler understands them.
3201 * src/system.h: Include unistd.h and ctype.h.
3202 Use #ifdef instead of #if for NLS symbols.
3204 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3206 * doc/bison.texinfo:
3207 Delete comment "consider using @set for edition number, etc..." since
3208 we now are doing so.
3210 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3213 Use prototypes if the compiler understands them.
3215 * NEWS: Document 1.26 highlights.
3217 * Makefile.am: Require Automake 1.3 or later.
3220 Use prototypes if the compiler understands them.
3222 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3225 Use VERSION symbol from automake for version number.
3227 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3229 * acconfig.h, configure.in, version.cin:
3230 Use VERSION symbol from automake for version number.
3232 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3235 Distribute original version of simple parser (bison.s1), not built
3236 version (bison.simple).
3238 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3240 * doc/bison.texinfo: Add info dir entry.
3242 * doc/bison.texinfo:
3243 Let automake put version number into documentation.
3245 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3247 * src/bison.cld, src/build.com, src/vmshlp.mar:
3248 Add non-RCS files from /gd/gnu/bison.
3250 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3253 Document the BISON_HAIRY and BISON_SIMPLE variables.
3255 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3257 * src/version.c: Build version.c automatically.
3260 Fix token numbering (used to start at 258, not 257).
3262 * src/system.h: Include config.h.
3264 * src/getargs.c: Update bug report address.
3266 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
3267 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
3269 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3272 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3274 * configure.in, version.cin:
3275 Build version.c automatically.
3277 * AUTHORS: Add AUTHORS file.
3279 * README: Update bug report address.
3282 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3284 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
3287 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3289 * doc/bison.texinfo: Clean up some formatting.
3291 1998-05-05 Richard Stallman <rms@gnu.org>
3293 * doc/bison.texinfo:
3294 Explain better why to make a pure parser.
3296 1998-01-05 Richard Stallman <rms@gnu.org>
3298 * src/files.c (openfiles):
3299 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
3300 find a temporary directory, if possible. Do not unlink files while
3303 1997-08-25 Richard Stallman <rms@gnu.org>
3305 * src/reader.c (stack_offset;):
3306 Change some warni to warns.
3308 * src/lex.c (literalchar): Use warns, not warni.
3310 1997-06-28 Richard Stallman <rms@gnu.org>
3312 * src/bison.s1: Add a Bison version comment.
3314 * src/main.c (fatal, warn, berror):
3317 1997-06-28 Richard Stallman <rms@gnu.org>
3319 * Makefile.in (bison_version): New variable.
3320 (dist): Use that variable.
3321 (bison.s1): Substitute the Bison version into bison.simple.
3323 * bison.simple: Add a Bison version comment.
3325 1997-06-18 Richard Stallman <rms@gnu.org>
3327 * src/main.c (fatal, warn, berror):
3328 Make error messages standard.
3329 (toomany): Improve error message text.
3331 * 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:
3332 new.h renamed to alloc.h.
3334 1997-06-18 Richard Stallman <rms@gnu.org>
3336 * Makefile.in: new.h renamed to alloc.h.
3338 1997-05-24 Richard Stallman <rms@gnu.org>
3340 * src/lex.c (literalchar):
3341 Fix the code for escaping \, " and '.
3343 (lex): Avoid trouble when there are many chars
3344 to discard in a char literal with just several chars in it.
3346 1997-05-17 Richard Stallman <rms@gnu.org>
3349 Use malloc, if using alloca is troublesome.
3350 (YYSTACK_USE_ALLOCA): New flag macro.
3351 Define it for some systems and compilers.
3352 (YYSTACK_ALLOC): New macro.
3353 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3354 If it was malloc'd, free it.
3356 1997-05-17 Richard Stallman <rms@gnu.org>
3359 Use malloc, if using alloca is troublesome.
3360 (YYSTACK_USE_ALLOCA): New flag macro.
3361 Define it for some systems and compilers.
3362 (YYSTACK_ALLOC): New macro.
3363 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3364 If it was malloc'd, free it.
3366 1997-04-23 Richard Stallman <rms@gnu.org>
3369 (alloca) [__hpux]: Always define as __builtin_alloca.
3371 1997-04-23 Richard Stallman <rms@gnu.org>
3374 (alloca) [__hpux]: Always define as __builtin_alloca.
3376 1997-04-22 Richard Stallman <rms@gnu.org>
3379 [__hpux]: Include alloca.h (right for HPUX 10)
3380 instead of declaring alloca (right for HPUX 9).
3382 * src/bison.s1 (__yy_memcpy):
3383 Declare arg `count' as unsigned int.
3384 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3386 1997-04-22 Richard Stallman <rms@gnu.org>
3389 [__hpux]: Include alloca.h (right for HPUX 10)
3390 instead of declaring alloca (right for HPUX 9).
3392 * bison.simple (__yy_memcpy):
3393 Declare arg `count' as unsigned int.
3394 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3396 1997-01-03 Richard Stallman <rms@gnu.org>
3398 * src/allocate.c: [__STDC__ or _MSC_VER]:
3399 Declare calloc and realloc to return void *.
3401 1997-01-02 Richard Stallman <rms@gnu.org>
3404 [_MSC_VER]: Include stdlib.h and process.h.
3405 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
3407 * src/main.c (main): Return FAILURE as a value.
3408 (printable_version): Declare arg as int, not char.
3410 1997-01-02 Richard Stallman <rms@gnu.org>
3412 * Makefile.in (dist):
3413 Explicitly check for symlinks, and copy them.
3415 1996-12-19 Richard Stallman <rms@gnu.org>
3418 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
3420 1996-12-18 Paul Eggert <eggert@gnu.org>
3422 * src/bison.s1 (yyparse):
3423 If __GNUC__ and YYPARSE_PARAM are both defined,
3424 declare yyparse to have a void * argument.
3426 1996-12-18 Paul Eggert <eggert@gnu.org>
3428 * bison.simple (yyparse):
3429 If __GNUC__ and YYPARSE_PARAM are both defined,
3430 declare yyparse to have a void * argument.
3432 1996-12-17 Richard Stallman <rms@gnu.org>
3434 * src/reduce.c (nbits): Add some casts.
3436 1996-08-12 Richard Stallman <rms@gnu.org>
3438 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
3440 1996-08-12 Richard Stallman <rms@gnu.org>
3442 * bison.simple: Test _MSDOS as well as _MSDOS_.
3444 1996-07-31 Richard Stallman <rms@gnu.org>
3447 [__sun && __i386]: Include alloca.h.
3449 1996-07-31 Richard Stallman <rms@gnu.org>
3452 [__sun && __i386]: Include alloca.h.
3454 1996-07-30 Richard Stallman <rms@gnu.org>
3456 * src/bison.s1: Comment change.
3458 * src/bison.s1: Test _MSDOS_, not MSDOS.
3460 1996-07-30 Richard Stallman <rms@gnu.org>
3462 * bison.simple: Comment change.
3464 * bison.simple: Test _MSDOS_, not MSDOS.
3466 1996-06-01 Richard Stallman <rms@gnu.org>
3468 * 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:
3469 Insert `_' macro around many string constants.
3472 Insert `_' macro around many string constants.
3474 (main): Call setlocale, bindtextdomain and textdomain.
3476 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
3477 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
3478 [ENABLE_NLS]: Include libintl.h.
3479 [ENABLE_NLS] (gettext): Define.
3480 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
3481 (N_, PACKAGE, LOCALEDIR): New macros.
3483 1996-06-01 Richard Stallman <rms@gnu.org>
3485 * POTFILES.in: New file.
3487 * Makefile.in (allocate.o):
3488 Define target explicitly.
3490 * Makefile.in (CFLAGS): Set to @CFLAGS@.
3491 (LDFLAGS): Set to @LDFLAGS@.
3492 (configure): Run autoconf only if preceding `cd' succeeds.
3493 (bison.s1): Redirect output to temporary file then move the
3494 temporary to the target, rather than redirecting directly to bison.s1.
3495 (clean): Remove config.status and config.log.
3496 (distclean): Don't remove config.status here.
3498 1996-05-12 Richard Stallman <rms@gnu.org>
3501 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3503 1996-05-12 Richard Stallman <rms@gnu.org>
3506 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3508 1996-05-11 Richard Stallman <rms@gnu.org>
3510 * src/bison.s1 (__yy_memcpy):
3511 Really reorder the args, as was supposedly done on Feb 14 1995.
3512 (yyparse): Calls changed accordingly.
3514 1996-05-11 Richard Stallman <rms@gnu.org>
3516 * Makefile.in (dist): Don't use $(srcdir).
3518 * bison.simple (__yy_memcpy):
3519 Really reorder the args, as was supposedly done on Feb 14 1995.
3520 (yyparse): Calls changed accordingly.
3522 1996-01-27 Richard Stallman <rms@gnu.org>
3524 * src/output.c (output_rule_data):
3525 Test YYERROR_VERBOSE in the conditional
3526 around the definition of ttyname.
3528 1995-12-29 Richard Stallman <rms@gnu.org>
3531 Fix line numbers in #line commands.
3533 1995-12-29 Richard Stallman <rms@gnu.org>
3536 Fix line numbers in #line commands.
3538 1995-12-27 Richard Stallman <rms@gnu.org>
3540 * src/bison.s1 (YYPARSE_PARAM_DECL):
3541 In C++, make it always null.
3542 (YYPARSE_PARAM_ARG): New macro.
3543 (yyparse): Use YYPARSE_PARAM_ARG.
3545 1995-12-27 Richard Stallman <rms@gnu.org>
3547 * bison.simple (YYPARSE_PARAM_DECL):
3548 In C++, make it always null.
3549 (YYPARSE_PARAM_ARG): New macro.
3550 (yyparse): Use YYPARSE_PARAM_ARG.
3552 1995-11-29 Richard Stallman <rms@gnu.org>
3554 * doc/bison.texinfo:
3555 Describe literal string tokens, %raw, %no_lines, %token_table.
3557 1995-11-29 Daniel Hagerty <hag@gnu.org>
3559 * doc/bison.texinfo: Fixed update date
3561 1995-10-16 Richard Stallman <rms@gnu.org>
3563 * src/version.c: Version 1.25.
3565 1995-10-16 Richard Stallman <rms@gnu.org>
3567 * NEWS: *** empty log message ***
3569 1995-10-16 Richard Stallman <rms@gnu.org>
3571 * doc/bison.1, doc/bison.rnh:
3574 1995-10-15 Richard Stallman <rms@gnu.org>
3576 * src/vmsgetargs.c, src/getargs.c:
3577 Added -n, -k, and -raw switches.
3578 (noparserflag, toknumflag, rawtoknumflag): New variables.
3580 * src/symtab.h (SALIAS):
3581 New #define for adding aliases to %token.
3582 (struct bucket): Added `alias' field.
3584 * src/reduce.c (reduce_grammar):
3585 Revise error message.
3586 (print_notices): Remove final `.' from error message.
3588 * src/reader.c (reader_output_yylsp):
3590 (readgram): Use `#if 0' around code that accepted %command
3591 inside grammar rules: The documentation doesn't allow it,
3592 and it will fail since the %command processors scan for the next %.
3593 (parse_token_decl): Extended the %token
3594 declaration to allow a multi-character symbol as an alias.
3595 (parse_thong_decl): New function.
3596 (read_declarations): Added %thong declarations.
3597 (read_declarations): Handle NOOP to deal with allowing
3598 % declarations as another means to specify the flags.
3599 (readgram): Allow %prec prior to semantics embedded in a rule.
3600 (skip_to_char, read_declarations, copy_definition)
3601 (parse_token_decl, parse_start_decl, parse_type_decl)
3602 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
3603 (get_type_name, copy_guard, copy_action, readgram)
3604 (get_type, packsymbols): Revised most error messages.
3605 Changed `fatal' to `warnxxx' to avoid aborting for error.
3606 Revised and use multiple warnxxx functions to avoid using VARARGS1.
3607 (read_declarations): Improve the error message for
3608 an invalid character. Do not abort.
3609 (read_declarations, copy_guard, copy_action): Use
3610 printable_version to avoid unprintable characters in printed output.
3611 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
3612 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
3613 Allow the type of a non-terminal can be given
3614 more than once, as long as all specifications give the same type.
3617 (output_headers, output_trailers, output, output_gram)
3618 (output_rule_data): Implement noparserflag variable.
3619 Implement toknumflag variable.
3620 (output): Call reader_output_yylsp to output LTYPESTR.
3622 * src/main.c (main):
3623 If reader sees an error, don't process the grammar.
3624 (fatals): Updated to not use VARARGS1.
3625 (printable_version, int_to_string, warn, warni, warns, warnss)
3626 (warnsss): New error reporting functions. Avoid abort for error.
3629 Added THONG and NOOP for alias processing.
3630 Added SETOPT for the new code that allows setting options with %flags.
3633 Include getopt.h. Add some extern decls.
3634 (safegetc): New function to deal with EOF gracefully.
3635 (literalchar); new function to deal with reading \ escapes.
3636 (lex): Use literalchar.
3637 (lex): Implemented "..." tokens.
3638 (literalchar, lex, parse_percent_token): Made tokenbuffer
3639 always contain the token. This includes growing the token
3640 buffer while reading an integer.
3641 (parse_percent_token): Replaced if-else statement with percent_table.
3642 (parse_percent_token): Added % declarations as another
3643 way to specify the flags -n, -l, and -r. Also added hooks for
3644 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
3645 major changes to files.c.
3646 (lex) Retain in the incoming stream a character following
3648 (skip_white_space, lex): Revised most error messages
3649 and changed fatal to warn to avoid aborting.
3650 (percent_table): Added %thong declarations.
3652 * src/gram.h: Comment changes.
3654 * src/files.c (openfiles, open_extra_files, done):
3656 and actfile file. Handle noparserflag. Both for -n switch.
3658 * src/conflicts.c (resolve_sr_conflict):
3659 Remove use of alloca.
3661 1995-06-01 Jim Meyering <meyering@gnu.org>
3663 * doc/bison.texinfo: *** empty log message ***
3665 1995-05-06 Richard Stallman <rms@gnu.org>
3667 * src/bison.s1: Comment change.
3669 1995-05-06 Richard Stallman <rms@gnu.org>
3671 * bison.simple: Comment change.
3673 1995-05-03 Richard Stallman <rms@gnu.org>
3675 * src/version.c: Version now 1.24.
3677 * src/bison.s1: Change distribution terms.
3679 * src/version.c: Version now 1.23.
3681 1995-05-03 Richard Stallman <rms@gnu.org>
3683 * doc/bison.texinfo:
3684 Rewrite "Conditions for Using Bison".
3685 Update version to 1.24.
3687 1995-05-03 Richard Stallman <rms@gnu.org>
3689 * bison.simple: Change distribution terms.
3691 1995-02-23 Richard Stallman <rms@gnu.org>
3693 * src/files.c: Test __VMS_POSIX as well as VMS.
3695 1995-02-14 Jim Meyering <meyering@gnu.org>
3697 * src/bison.s1 (__yy_memcpy):
3698 Renamed from __yy_bcopy to avoid
3699 confusion. Reverse FROM and TO arguments to be consistent with
3702 1995-02-14 Jim Meyering <meyering@gnu.org>
3704 * bison.simple (__yy_memcpy):
3705 Renamed from __yy_bcopy to avoid
3706 confusion. Reverse FROM and TO arguments to be consistent with
3709 1994-11-10 David J. MacKenzie <djm@gnu.org>
3715 * Makefile.in (DISTFILES): Include NEWS.
3717 * Makefile.in (DISTFILES):
3718 Include install-sh, not install.sh.
3720 * configure.in: Update to Autoconf v2 macro names.
3722 1994-10-05 David J. MacKenzie <djm@gnu.org>
3724 * Makefile.in: fix typo
3726 * Makefile.in (prefix, exec_prefix):
3727 Let configure set them.
3729 1994-09-28 David J. MacKenzie <djm@gnu.org>
3731 * Makefile.in: Set datadir to $(prefix)/share.
3733 1994-09-15 Richard Stallman <rms@gnu.org>
3736 Update copyright notice and GPL version.
3738 1994-09-15 Richard Stallman <rms@gnu.org>
3741 Update copyright notice and GPL version.
3743 1994-07-12 Richard Stallman <rms@gnu.org>
3745 * src/reduce.c, src/reader.c:
3748 1994-05-05 David J. MacKenzie <djm@gnu.org>
3750 * Makefile.in: entered into RCS
3752 1994-03-26 Richard Stallman <rms@gnu.org>
3754 * src/bison.s1: entered into RCS
3756 1994-03-26 Richard Stallman <rms@gnu.org>
3758 * bison.simple: entered into RCS
3760 1994-03-25 Richard Stallman <rms@gnu.org>
3762 * src/main.c: entered into RCS
3764 1994-03-24 Richard Stallman <rms@gnu.org>
3766 * src/conflicts.c: entered into RCS
3768 1994-01-02 Richard Stallman <rms@gnu.org>
3770 * Makefile.in: *** empty log message ***
3772 1993-11-21 Richard Stallman <rms@gnu.org>
3774 * src/bison.s1: *** empty log message ***
3776 1993-11-21 Richard Stallman <rms@gnu.org>
3778 * doc/bison.texinfo: entered into RCS
3780 * doc/bison.texinfo: *** empty log message ***
3782 1993-11-21 Richard Stallman <rms@gnu.org>
3784 * bison.simple: *** empty log message ***
3786 1993-10-25 David J. MacKenzie <djm@gnu.org>
3788 * doc/bison.texinfo: *** empty log message ***
3790 1993-10-19 Richard Stallman <rms@gnu.org>
3792 * src/bison.s1: *** empty log message ***
3794 1993-10-19 Richard Stallman <rms@gnu.org>
3796 * bison.simple: *** empty log message ***
3798 1993-10-14 Richard Stallman <rms@gnu.org>
3800 * src/bison.s1: *** empty log message ***
3802 1993-10-14 Richard Stallman <rms@gnu.org>
3804 * bison.simple: *** empty log message ***
3806 1993-09-14 David J. MacKenzie <djm@gnu.org>
3808 * doc/bison.texinfo: *** empty log message ***
3810 1993-09-13 Noah Friedman <friedman@gnu.org>
3812 * Makefile.in: *** empty log message ***
3814 1993-09-10 Richard Stallman <rms@gnu.org>
3816 * src/conflicts.c: *** empty log message ***
3818 * src/system.h: entered into RCS
3820 1993-09-10 Richard Stallman <rms@gnu.org>
3822 * doc/bison.1: entered into RCS
3824 1993-09-06 Noah Friedman <friedman@gnu.org>
3826 * src/version.c: entered into RCS
3828 1993-09-06 Noah Friedman <friedman@gnu.org>
3830 * Makefile.in: *** empty log message ***
3832 1993-07-30 David J. MacKenzie <djm@gnu.org>
3834 * Makefile.in: *** empty log message ***
3836 1993-07-24 Richard Stallman <rms@gnu.org>
3838 * src/bison.s1: *** empty log message ***
3840 1993-07-24 Richard Stallman <rms@gnu.org>
3842 * bison.simple: *** empty log message ***
3844 1993-07-08 David J. MacKenzie <djm@gnu.org>
3846 * Makefile.in: *** empty log message ***
3848 1993-07-04 Richard Stallman <rms@gnu.org>
3850 * src/bison.s1: *** empty log message ***
3852 1993-07-04 Richard Stallman <rms@gnu.org>
3854 * bison.simple: *** empty log message ***
3856 1993-06-26 David J. MacKenzie <djm@gnu.org>
3858 * src/getargs.c: entered into RCS
3860 1993-06-26 David J. MacKenzie <djm@gnu.org>
3862 * doc/bison.texinfo: *** empty log message ***
3864 * doc/bison.1: New file.
3866 1993-06-25 Richard Stallman <rms@gnu.org>
3868 * src/getargs.c: New file.
3870 1993-06-16 Richard Stallman <rms@gnu.org>
3872 * src/bison.s1: *** empty log message ***
3874 1993-06-16 Richard Stallman <rms@gnu.org>
3876 * bison.simple: *** empty log message ***
3878 1993-06-03 Richard Stallman <rms@gnu.org>
3880 * src/bison.s1: New file.
3882 1993-06-03 Richard Stallman <rms@gnu.org>
3884 * doc/bison.texinfo: *** empty log message ***
3886 1993-06-03 Richard Stallman <rms@gnu.org>
3888 * bison.simple: New file.
3890 1993-05-19 Richard Stallman <rms@gnu.org>
3892 * doc/bison.texinfo: New file.
3894 1993-05-07 Noah Friedman <friedman@gnu.org>
3896 * Makefile.in: *** empty log message ***
3898 1993-04-28 Noah Friedman <friedman@gnu.org>
3900 * src/reader.c: *** empty log message ***
3902 1993-04-23 Noah Friedman <friedman@gnu.org>
3904 * src/alloc.h: entered into RCS
3906 1993-04-20 David J. MacKenzie <djm@gnu.org>
3908 * src/version.c: *** empty log message ***
3910 * src/files.c, src/allocate.c:
3913 * src/reader.c: *** empty log message ***
3915 * src/lex.c: entered into RCS
3917 * src/conflicts.c: New file.
3919 * src/symtab.c: entered into RCS
3921 * src/alloc.h: New file.
3923 * src/LR0.c: entered into RCS
3925 1993-04-18 Noah Friedman <friedman@gnu.org>
3927 * src/reader.c: New file.
3929 * src/version.c: *** empty log message ***
3931 1993-04-18 Noah Friedman <friedman@gnu.org>
3933 * Makefile.in: *** empty log message ***
3935 1993-04-17 Noah Friedman <friedman@gnu.org>
3937 * Makefile.in: *** empty log message ***
3939 1993-04-15 Richard Stallman <rms@gnu.org>
3941 * src/main.c, src/files.c:
3944 1993-04-15 Noah Friedman <friedman@gnu.org>
3946 * configure.in: entered into RCS
3948 * configure.in: *** empty log message ***
3950 * configure.in: New file.
3952 1993-04-14 Richard Stallman <rms@gnu.org>
3954 * Makefile.in: New file.
3956 1993-04-13 Richard Stallman <rms@gnu.org>
3958 * src/version.c: New file.
3960 1993-03-25 Richard Stallman <rms@gnu.org>
3962 * src/output.c: entered into RCS
3964 1992-09-25 Richard Stallman <rms@gnu.org>
3966 * configure.bat: entered into RCS
3968 1992-06-22 Richard Stallman <rms@gnu.org>
3970 * src/vmsgetargs.c: entered into RCS
3972 1992-06-22 Richard Stallman <rms@gnu.org>
3974 * doc/bison.rnh: entered into RCS
3976 1992-04-20 David J. MacKenzie <djm@gnu.org>
3978 * README: entered into RCS
3980 1992-01-22 Richard Stallman <rms@gnu.org>
3982 * src/machine.h: entered into RCS
3984 1991-12-21 Richard Stallman <rms@gnu.org>
3986 * src/lalr.c, src/closure.c:
3989 1991-12-20 Richard Stallman <rms@gnu.org>
3991 * src/state.h: entered into RCS
3993 1991-12-18 Richard Stallman <rms@gnu.org>
3995 * src/print.c, src/nullable.c, src/derives.c:
3998 1991-11-03 David J. MacKenzie <djm@gnu.org>
4000 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
4003 1988-09-09 Richard Stallman <rms@gnu.org>
4005 * src/bison.hairy: entered into RCS
4007 1987-12-16 Richard Stallman <rms@gnu.org>
4009 * REFERENCES: entered into RCS