1 2002-01-04 Paul Eggert <eggert@twinsun.com>
3 * doc/bison.texinfo (Debugging):
4 Remove YYSTDERR; it's no longer defined or used.
5 Also, s/cstdio.h/cstdio/.
7 2002-01-03 Akim Demaille <akim@epita.fr>
9 * src/files.h: Add it prototype.
11 2002-01-03 Akim Demaille <akim@epita.fr>
13 * src/files.c, src/files.h (strsuffix): Not static.
14 * src/conflicts.c (conflicts_print): Don't consider it is an error
15 to have a %expectation violation on a file ending by `plural.y'.
18 2002-01-03 Akim Demaille <akim@epita.fr>
20 * tests/bison.in: Adjust to CVS Autoconf.
21 * tests/calc.at (exp): We no longer need to special case GCC as
22 the warning flags are passed by configure.
23 * tests/atlocal.in: Adjust.
24 * configure.in: Bump to 1.30j.
26 2002-01-03 Akim Demaille <akim@epita.fr>
30 2002-01-03 Akim Demaille <akim@epita.fr>
32 * src/bison.simple (YYSTDERR): Remove, replace `stderr'.
33 The ISO C++ standard is extremely clear about it: stderr is
34 considered a macro, not a regular symbol (see table 94 `Header
35 <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files).
36 Therefore std:: does not apply to it. It still does with fprintf.
37 Also, s/cstdio.h/cstdio/.
39 2002-01-03 Akim Demaille <akim@epita.fr>
41 * lib/quotearg.c: Use `#include "..."' instead of `#include <...>'
42 for non system headers.
44 2001-12-27 Paul Eggert <eggert@twinsun.com>
46 * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special
47 cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and
48 Sparc, as they were causing more porting problems than the
49 (minor) performance improvement was worth.
51 2001-12-22 Akim Demaille <akim@epita.fr>
53 * src/output.c (output_short_table, output_short_or_char_table):
54 Change the prototype to use `int' for array ranges: some
55 invocations do pass an int, not a short.
56 Reported by Wayne Green.
58 2001-12-22 Akim Demaille <akim@epita.fr>
60 Some actions of web2c.y are improperly triggered.
61 Reported by Mike Castle.
63 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
64 * tests/regression.at (Web2c): Rename as...
68 2001-12-22 Akim Demaille <akim@epita.fr>
70 Reductions in web2c.y are improperly reported.
71 Reported by Mike Castle.
73 * src/conflicts.c (print_reductions): Fix.
74 * tests/regression.at (Web2c): New.
76 2001-12-18 Akim Demaille <akim@epita.fr>
80 2001-12-18 Akim Demaille <akim@epita.fr>
82 Some host fail on `assert (!"foo")', which expands to
83 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
84 Reported by Nelson Beebee.
86 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
87 `#define it_succeeded 0' and `assert (it_succeeded)'.
89 2001-12-17 Paul Eggert <eggert@twinsun.com>
91 * src/bison.simple (YYSTD): New macro.
92 (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE, YYFPRINTF, YYSTDERR): Use
93 it to simplify macros, and fix some C++ porting problems reported
96 * src/output.c (output): Define YYDEBUG to 0 if it is not defined
97 and if we are not debugging. POSIX requires this.
98 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document this.
100 * src/output.c (output_gram, output_rule_data): Do not assume that
101 the user defines YYDEBUG to a properly parenthesized expression.
103 2001-12-15 Akim Demaille <akim@epita.fr>
105 * src/nullable.c (set_nullable): Useless rules must be skipped,
106 otherwise, since we range over their symbols, we might look at a
107 nonterminal which no longer ``exists'', i.e., it is not counted in
108 `nvars', hence we overflow our arrays.
110 2001-12-15 Akim Demaille <akim@epita.fr>
112 * src/reader.c (copy_action): When --yacc, don't append a `;'
113 to the user action: let it fail if lacking.
114 Suggested by Arnold Robbins and Tom Tromey.
116 2001-12-13 Akim Demaille <akim@epita.fr>
120 2001-12-13 Akim Demaille <akim@epita.fr>
122 The computation of nullable is broken: it doesn't handle empty
125 * tests/torture.at (GNU AWK Grammar): New.
126 * tests/sets.at (Nullable): New.
127 * src/nullable.c (set_nullable): Instead of blindly looping over
128 `ritems', loop over the rules, and then over their rhs's.
130 Work around Autotest bugs.
132 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
133 frame, because Autotest understand lines starting with a `+' as
134 traces from the shell. Then, they are not processed properly.
135 Admittedly an Autotest bug, but we don't have time to wait for
136 Autotest to catch up.
137 * tests/regression.at (Broken Closure): Adjust to the new table
140 * tests/sets.at: here.
142 2001-12-12 Paul Eggert <eggert@twinsun.com>
144 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
145 Do not infringe on the global user namespace when using C++.
146 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
147 All uses of `fprintf' and `stderr' changed.
149 * src/output.c (output): Do not output "#include <stdio.h>"; that
150 is bison.simple's job. stdio.h should be included only if
151 necessary, to avoid infringing on the user name space when
154 2001-12-12 Akim Demaille <akim@epita.fr>
156 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
157 on that of lib/error.c.
159 2001-12-12 Akim Demaille <akim@epita.fr>
161 Some hosts don't like `/' in includes.
163 * src/system.h: Include libgettext.h without qualifying the path.
164 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
167 2001-12-10 Akim Demaille <akim@epita.fr>
169 Bison dumps core on bash.y.
170 Reported by Pascal Bart.
172 * src/warshall.c (bitmatrix_print): New.
174 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
175 j must be the outer loop.
176 * tests/regression.at (Broken Closure): New.
178 2001-12-05 Akim Demaille <akim@epita.fr>
182 2001-12-05 Akim Demaille <akim@epita.fr>
184 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
186 Reported by Peter Hámorský.
188 2001-12-05 Akim Demaille <akim@epita.fr>
190 * src/conflicts.c (err_table): Remove.
191 (resolve_sr_conflict): Adjust.
192 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
194 (state_t.reductions, state_t.shifts): this.
196 2001-12-05 Akim Demaille <akim@epita.fr>
198 * src/reduce.c (reduce_grammar_tables): No longer disable the
199 removal of useless rules via CPP but via `if (0)', so that the
200 compiler still check the code is valid.
201 For instance, it should have noticed `rline' no longer exists: use
202 the `line' member of rule_t.
203 * src/gram.c (dummy, rline): Remove, unused.
205 2001-12-05 Akim Demaille <akim@epita.fr>
207 * src/output.c (pack_vector): Use assert, not berror.
208 * src/main.c (berror): Remove, unused.
210 2001-12-05 Akim Demaille <akim@epita.fr>
212 New experimental feature: if --verbose --trace output all the
213 items of a state, not only its kernel.
215 * src/print.c (print_core): If `trace_flag', then invoke closure
216 before outputting the items of the state (print_core is no longer
217 a correct name them).
218 (print_results): Invoke new_closure/free_closure if needed.
220 2001-12-05 Akim Demaille <akim@epita.fr>
222 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
223 * src/closure.c, src/closure.h (itemsetsize): Rename as...
224 (nitemset): for consistency with the rest of the project.
226 2001-12-05 Akim Demaille <akim@epita.fr>
228 * src/closure.c (print_closure): Improve.
229 (closure): Use it for printing input and output.
231 2001-12-05 Akim Demaille <akim@epita.fr>
233 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
234 indexed by nonterminals.
236 2001-12-05 Akim Demaille <akim@epita.fr>
238 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
240 * src/warshall.h: Remove accidental duplication of the content.
242 2001-12-05 Akim Demaille <akim@epita.fr>
244 * src/closure.c (set_fderives): De-obfuscate.
246 2001-12-05 Akim Demaille <akim@epita.fr>
248 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
250 2001-12-05 Akim Demaille <akim@epita.fr>
252 * src/closure.c (set_firsts): De-obfuscate.
254 2001-12-05 Akim Demaille <akim@epita.fr>
256 * src/output.c (action_row): De-obfuscate
257 using the good o' techniques: arrays not pointers, variable
258 locality, BITISSET, RESETBIT etc.
260 2001-12-05 Akim Demaille <akim@epita.fr>
262 Pessimize the code to simplify it: from now on, all the states
263 have a valid SHIFTS, which NSHIFTS is possibly 0.
265 * src/LR0.c (shifts_new): Be global and move to..
266 * src/state.c, src/state.h: here.
267 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
268 * src/print_graph: Adjust.
270 2001-12-05 Akim Demaille <akim@epita.fr>
272 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
273 * src/conflicts.c: Use it.
274 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
275 incorrectly ``simplified''.
277 2001-12-05 Akim Demaille <akim@epita.fr>
279 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
280 using the good o' techniques: arrays not pointers, variable
281 locality, BITISSET, RESETBIT etc.
283 2001-12-05 Akim Demaille <akim@epita.fr>
285 * src/state.h (SHIFT_SYMBOL): New.
286 * src/conflicts.c: Use it to deobfuscate.
288 2001-12-05 Akim Demaille <akim@epita.fr>
290 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
291 (print_reductions): De-obfuscate using the good o' techniques:
292 arrays not pointers, variable locality, BITISSET.
294 2001-12-05 Akim Demaille <akim@epita.fr>
296 * src/conflicts.c (print_reductions): Arrays, not pointers.
299 2001-12-05 Akim Demaille <akim@epita.fr>
301 * src/conflicts.c (print_reductions): Pessimize, but clarify.
303 2001-12-05 Akim Demaille <akim@epita.fr>
305 * src/conflicts.c (print_reductions): Improve variable locality.
307 2001-12-05 Akim Demaille <akim@epita.fr>
309 * src/conflicts.c (print_reductions): Pessimize, but clarify.
311 2001-12-05 Akim Demaille <akim@epita.fr>
313 * src/conflicts.c (print_reductions): Improve variable locality.
315 2001-12-05 Akim Demaille <akim@epita.fr>
317 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
318 * src/lalr.c: Use them.
320 2001-12-05 Akim Demaille <akim@epita.fr>
322 * src/LR0.c (augment_automaton): Formatting changes.
323 Better variable locality.
325 2001-12-05 Akim Demaille <akim@epita.fr>
327 * src/lalr.c (matrix_print): New.
329 Use arrays instead of pointers.
331 2001-12-05 Akim Demaille <akim@epita.fr>
333 * src/lalr.c (maxrhs): Move to...
334 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
335 * src/lalr.c (build_relations): Adjust.
337 2001-12-05 Akim Demaille <akim@epita.fr>
339 * src/lalr.c (transpose): Free the memory allocated to the
340 argument, as it is replaced by the results by the unique caller.
341 (build_relations): Merely invoke transpose: it handles the memory
343 Improve variable locality.
344 Avoid variables used as mere abbreviations.
345 (compute_lookaheads): Use arrays instead of pointers.
347 2001-12-05 Akim Demaille <akim@epita.fr>
349 * src/lalr.c (initialize_F): Improve variable locality.
350 Avoid variables used as mere abbreviations.
352 2001-12-05 Akim Demaille <akim@epita.fr>
354 * src/derives.c (print_derives): Display the ruleno.
355 * src/lalr.c (initialize_F, transpose): Better variable locality
356 to improve readability.
357 Avoid variables used as mere abbreviations.
359 2001-12-05 Akim Demaille <akim@epita.fr>
361 * src/lalr.c (traverse): Use arrays instead of pointers.
363 2001-12-05 Akim Demaille <akim@epita.fr>
365 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
366 the handling of squeue.
367 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
369 2001-12-05 Akim Demaille <akim@epita.fr>
371 Because useless nonterminals are now kept alive (instead of being
372 `destroyed'), we now sometimes examine them, and store information
373 related to them. Hence we need to know their number, and adjust
376 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
378 * src/LR0.c (allocate_itemsets): The memory allocated to
379 `symbol_count' was used for two different purpose: once to count
380 the number of occurrences of each symbol, and later reassigned to
381 `shift_symbol', containing the symbol that can be shifted from a
383 Deobfuscate, i.e., allocate, use and free `symbol_count' here
385 (new_itemsets): Allocate `shift_symbol' here.
386 (allocate_itemsets): symbol_count includes useless nonterminals.
388 (free_storage): Use `free', not `XFREE', for pointers that cannot
391 2001-12-05 Akim Demaille <akim@epita.fr>
393 * src/nullable.c (set_nullable): Deobfuscate the handling of
395 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
397 2001-12-05 Akim Demaille <akim@epita.fr>
399 * src/gram.c, src/gram.h (ritem_print): New.
400 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
401 (This useless function was defined only to work around VMS linkers
402 that can't handle compilation units with variables only).
403 * src/reduce.c (dump_grammar): Use it to trace the construction of
406 2001-12-04 Paul Eggert <eggert@twinsun.com>
408 * src/bison.simple (union yyalloc): Change member names
409 to be the same as the stack names.
410 (yyparse): yyptr is now union yyalloc *, not char *.
411 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
412 and may generate better code on some machines.
413 (yystpcpy): Use prototype if __STDC__ is defined, not just
414 if __cplusplus is defined.
416 2001-11-30 Akim Demaille <akim@epita.fr>
418 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
419 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
420 Gettext doesn't compile cleanly, and dies with -Werror.
421 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
422 Include WARNING_CFLAGS here.
423 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
424 before being defined.
426 2001-11-30 Paul Eggert <eggert@twinsun.com>
428 * lib/quotearg.h (quotearg_n, quotearg_n_style):
429 First arg is int, not unsigned.
430 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
431 (SIZE_MAX, UINT_MAX): New macros.
432 (quotearg_n_options): Abort if N is negative.
433 Avoid overflow check on hosts where size_t is 64 bits and int
434 is 32 bits, as overflow is impossible there.
435 Fix off-by-one typo that caused unnecessary reallocation.
437 2001-11-30 Paul Eggert <eggert@twinsun.com>
439 Name space cleanup in generated parser.
441 * doc/bison.texinfo (Bison Parser): Discuss system headers
442 and their effect on the user name space.
445 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
446 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
447 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
449 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
450 on user names when possible.
452 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
453 Simplify test for whather <alloca.h> exists.
455 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
457 (<stdio.h>): Include if YYDEBUG.
459 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
460 ! defined (yyoverflow) && ! defined (yymemcpy).
462 (yymemcpy, yyparse): Rename local variables as needed so that
463 they all begin with 'yy'.
465 (yystrlen, yystpcpy): New functions.
467 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
470 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
471 instead of relying on string.h functions. Use YYSTACK_ALLOC
472 and YYSTACK_FREE instead of malloc and free.
474 2001-11-30 Akim Demaille <akim@epita.fr>
476 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
477 if body instead of `;' to pacify GCC's warnings.
479 2001-11-30 Akim Demaille <akim@epita.fr>
481 Instead of mapping the LHS of unused rules to -1, keep the LHS
482 valid, but flag the rules as invalid.
484 * src/gram.h (rule_t): `useful' is a new member.
485 * src/print.c (print_grammar): Adjust.
486 * src/derives.c (set_derives): Likewise.
487 * src/reader.c (packgram, reduce_output): Likewise.
488 * src/reduce.c (reduce_grammar_tables): Likewise.
489 * tests/reduce.at (Underivable Rules, Useless Rules): New.
491 2001-11-30 Akim Demaille <akim@epita.fr>
493 * src/reduce.c (reduce_output): Formatting changes.
494 * src/print.c (print_results, print_grammar): Likewise.
495 * tests/regression.at (Rule Line Numbers)
496 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
498 2001-11-30 Akim Demaille <akim@epita.fr>
500 * src/reduce.c (nonterminals_reduce): Instead of throwing away
501 useless nonterminals, move them at the end of the symbol arrays.
502 (reduce_output): Adjust.
503 * tests/reduce.at (Useless Nonterminals): Adjust.
505 2001-11-30 Akim Demaille <akim@epita.fr>
507 * src/reduce.c: Various comment/formatting changes.
508 (nonterminals_reduce): New, extracted from...
509 (reduce_grammar_tables): here.
510 (reduce_grammar): Call nonterminals_reduce.
512 2001-11-29 Paul Eggert <eggert@twinsun.com>
514 * src/bison.simple (YYSTACK_REALLOC): Remove.
515 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
516 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
518 (union yyalloc): New type.
519 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
520 an arbitrary restriction on hosts where size_t is wider than int.
522 (yyparse): Don't dump core if alloca or malloc fails; instead, report
523 a parser stack overflow. Allocate just one block of memory for all
524 three stacks, instead of allocating three blocks; this typically is
525 faster and reduces fragmentation.
527 Do not limit the number of items in the stack to a value that fits
528 in 'int', as this is an arbitrary limit on hosts with 64-bit
529 size_t and 32-bit int.
531 2001-11-28 Akim Demaille <akim@epita.fr>
533 * src/LR0.c (shifts_new): New.
534 (save_shifts, insert_start_shift, augment_automaton): Use it.
536 2001-11-28 Akim Demaille <akim@epita.fr>
538 * src/closure.c (closure): `b' and `ruleno' denote the same value:
541 2001-11-28 Akim Demaille <akim@epita.fr>
543 * src/closure.c (closure): Instead of looping over word in array
544 then bits in words, loop over bits in array.
546 2001-11-28 Akim Demaille <akim@epita.fr>
548 * src/closure.c (closure): No longer optimize the special case
549 where all the bits of `ruleset[r]' are set to 0, to make the code
552 2001-11-28 Akim Demaille <akim@epita.fr>
554 * src/closure.c (closure): `r' and `c' are new variables, used to
555 de-obfuscate accesses to RULESET and CORE.
557 2001-11-28 Akim Demaille <akim@epita.fr>
559 * src/reduce.c (reduce_print): Use ngettext.
560 (dump_grammar): Improve the trace accuracy.
562 2001-11-28 Akim Demaille <akim@epita.fr>
564 * src/reduce.c (dump_grammar): Don't translate trace messages.
566 2001-11-28 Akim Demaille <akim@epita.fr>
568 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
569 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
570 as all tags are free'ed afterwards.
573 2001-11-27 Akim Demaille <akim@epita.fr>
575 * src/system.h: Use intl/libgettext.h.
576 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
578 2001-11-27 Paul Eggert <eggert@twinsun.com>
580 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
581 use alloca when we didn't want to, and vice versa.
583 2001-11-27 Akim Demaille <akim@epita.fr>
585 * tests/torture.at (Exploding the Stack Size with Malloc):
586 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
588 2001-11-27 Akim Demaille <akim@epita.fr>
590 * src/files.c: Include error.h.
593 2001-11-26 Akim Demaille <akim@epita.fr>
597 2001-11-26 Akim Demaille <akim@epita.fr>
599 * src/reader.c (readgram): Make sure rules for mid-rule actions
600 have a lineno equal to that of their host rule.
601 Reported by Hans Aberg.
602 * tests/regression.at (Rule Line Numbers): New.
604 2001-11-26 Akim Demaille <akim@epita.fr>
606 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
608 Reported by Hans Aberg.
610 2001-11-26 Akim Demaille <akim@epita.fr>
612 * src/complain.c, src/complain.h (error): Remove, provided by
615 2001-11-26 Akim Demaille <akim@epita.fr>
617 * src/reader.c (read_declarations): Don't abort on tok_illegal,
618 issue an error message.
619 * tests/regression.at (Invalid %directive): New.
620 Reported by Hans Aberg.
622 2001-11-26 Akim Demaille <akim@epita.fr>
624 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
625 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
627 2001-11-26 Akim Demaille <akim@epita.fr>
629 * src/conflicts.c (conflicts_print): Don't complain at all when
630 there are no reduce/reduce conflicts, and as many shift/reduce
631 conflicts as expected.
632 * tests/regression.at (%expect right): Adjust.
634 2001-11-23 Akim Demaille <akim@epita.fr>
636 * lib/alloca.c: Update, from fileutils.
638 2001-11-23 Akim Demaille <akim@epita.fr>
640 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
642 2001-11-23 Akim Demaille <akim@epita.fr>
644 * src/system.h: Include alloca.h.
645 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
647 2001-11-23 Akim Demaille <akim@epita.fr>
649 * src/print_graph.c (print_actions): Remove `rule', unused.
650 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
651 pacify GCC's signed < unsigned warnings.
652 * src/closure.c (itemsetsize): Likewise.
653 * src/reader.c (symbol_list_new): Static.
655 2001-11-23 Akim Demaille <akim@epita.fr>
657 Attaching lineno to buckets is stupid, since only one copy of each
658 symbol is kept, only the line of the first occurrence is kept too.
660 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
661 * src/reader.c (rline_allocated): Remove, unused.
662 (symbol_list): Have a `line' member.
663 (symbol_list_new): New.
665 * src/print.c (print_grammar): Output the rule line numbers.
666 * tests/regression.at (Solved SR Conflicts)
667 (Unresolved SR Conflicts): Adjust.
668 Reported by Hans Aberg.
670 2001-11-20 Akim Demaille <akim@epita.fr>
674 2001-11-20 Akim Demaille <akim@epita.fr>
677 * configure.in (ALL_LINGUAS): Adjust.
678 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
679 longer contains strings to translate.
681 2001-11-19 Akim Demaille <akim@epita.fr>
683 * src/conflicts.c (conflicts_print): Add a missing \n.
685 2001-11-19 Akim Demaille <akim@epita.fr>
687 * src/nullable.c (nullable_print): New.
688 (set_nullable): Call it when tracing.
689 Better locality of variables.
691 2001-11-19 Akim Demaille <akim@epita.fr>
693 * src/print.c (print_actions): Better locality of variables.
695 2001-11-19 Akim Demaille <akim@epita.fr>
697 * src/derives.c (print_derives): Fix and enrich.
698 * src/closure.c (print_fderives): Likewise.
700 2001-11-19 Akim Demaille <akim@epita.fr>
702 * src/closure.c (itemsetend): Remove, replaced with...
705 2001-11-19 Akim Demaille <akim@epita.fr>
707 * src/LR0.c (kernel_end): Remove, replaced with...
710 2001-11-19 Akim Demaille <akim@epita.fr>
712 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
715 2001-11-19 Akim Demaille <akim@epita.fr>
717 * src/closure.c (closure): Use arrays instead of pointers to clarify.
719 2001-11-19 Akim Demaille <akim@epita.fr>
721 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
723 * src/LR0.c: Likewise.
724 (allocate_itemsets): Use arrays instead of pointers to clarify.
726 2001-11-19 Akim Demaille <akim@epita.fr>
728 * src/getargs.c (statistics_flag): Replace with...
730 (longopts): Accept --trace instead of --statistics.
731 * src/getargs.h: Adjust.
732 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
733 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
735 2001-11-19 Akim Demaille <akim@epita.fr>
737 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
738 pointers to clarify the code.
739 (save_reductions, save_shifts): Factor common parts of alternatives.
741 2001-11-19 Akim Demaille <akim@epita.fr>
743 * src/LR0.c (new_state, get_state): Complete TRACE code.
744 * src/closure.c: Include `reader.h' to get `tags', needed by the
746 Rename the conditional DEBUG as TRACE.
747 Output consistently TRACEs to stderr, not stdout.
748 * src/derives.c: Likewise.
749 * src/reduce.c: (inaccessable_symbols): Using if is better style
751 Use `#if TRACE' instead of `#if 0' for tracing code.
753 2001-11-19 Akim Demaille <akim@epita.fr>
755 * src/system.h (LIST_FREE, shortcpy): New.
756 * src/LR0.c: Use them.
757 * src/output.c (free_itemsets, free_reductions, free_shifts):
758 Remove, replaced by LIST_FREE.
760 2001-11-19 Akim Demaille <akim@epita.fr>
762 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
763 (REDUCTIONS_ALLOC): New.
764 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
767 2001-11-19 Akim Demaille <akim@epita.fr>
769 * src/LR0.c (new_state): Complete trace code.
770 * src/nullable.c (set_nullable): Don't translate traces.
772 2001-11-19 Akim Demaille <akim@epita.fr>
774 * src/print_graph.c (print_core): Better locality of variables.
775 * src/print.c (print_core): Likewise.
777 2001-11-19 Akim Demaille <akim@epita.fr>
779 * src/vcg.c: You do the output, so you are responsible of the
780 handling of VCG syntax, in particular: use quotearg.
781 * src/print_graph.c: Don't.
782 (print_actions): Don't output the actions as part of the nodes,
783 since that's the job of the edges.
784 (print_state): Don't output by hand: fill the node description,
785 and ask for its output.
787 2001-11-19 Akim Demaille <akim@epita.fr>
789 * src/bison.simple (yyparse): When verbosely reporting an error,
790 no longer put additional quotes around token names.
791 * tests/calc.at: Adjust.
793 2001-11-19 Akim Demaille <akim@epita.fr>
795 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
796 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
797 * src/output.c: Adjust.
799 2001-11-19 Akim Demaille <akim@epita.fr>
801 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
803 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
805 2001-11-19 Akim Demaille <akim@epita.fr>
807 * src/gram.h (rule_t): New.
809 (rrhs, rlhs): Remove, part of state_t.
810 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
811 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
812 * src/reader.c, src/reduce.c: Adjust.
814 2001-11-19 Akim Demaille <akim@epita.fr>
816 * src/reader.c (symbols_output): New, extracted from...
820 2001-11-19 Akim Demaille <akim@epita.fr>
822 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
823 (maxrhs): this new function.
825 2001-11-19 Akim Demaille <akim@epita.fr>
827 * src/lalr.c (F): New macro to access the variable F.
830 2001-11-19 Akim Demaille <akim@epita.fr>
832 * src/lalr.h (LA): New macro to access the variable LA.
833 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
834 * src/lalr.c: Adjust.
836 2001-11-19 Akim Demaille <akim@epita.fr>
838 * src/lalr.c (initialize_LA): Only initialize LA. Let...
839 (set_state_table): handle the `lookaheads' members.
841 2001-11-19 Akim Demaille <akim@epita.fr>
843 * src/lalr.h (lookaheads): Removed array, whose contents is now
845 (state_t): this structure.
846 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
849 2001-11-19 Akim Demaille <akim@epita.fr>
851 * src/lalr.h (consistent): Removed array, whose contents is now
853 (state_t): this structure.
854 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
857 2001-11-19 Akim Demaille <akim@epita.fr>
859 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
860 contents are now members of...
861 (state_t): this structure.
862 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
865 2001-11-19 Akim Demaille <akim@epita.fr>
867 * src/lalr.h (state_t): New.
868 (state_table): Be a state_t * instead of a core **.
869 (accessing_symbol): Remove, part of state_t.
870 * src/lalr.c: Adjust.
871 (set_accessing_symbol): Merge into...
872 (set_state_table): this.
873 * src/print_graph.c, src/conflicts.c: Adjust.
875 2001-11-14 Akim Demaille <akim@epita.fr>
879 2001-11-14 Akim Demaille <akim@epita.fr>
881 * tests/calc.at, tests/output.at, tests/regression.at,
882 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
883 now the tests are run in private dirs, therefore AC_CLEANUP and
884 family can be simplified to 0-ary.
885 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
886 use abs. path to find config.h.
888 2001-11-14 Akim Demaille <akim@epita.fr>
890 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
891 stderr, there can be way too much random noise.
892 Instead pass -Werror to GCC and rely on the exit status.
893 Reported by Wolfram Wagner.
895 2001-11-14 Akim Demaille <akim@epita.fr>
897 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
898 defined only if yyoverflow is defined, to avoid `warning: unused
900 Reported by The Test Suite.
902 2001-11-14 Akim Demaille <akim@epita.fr>
904 * src/print.c: Include reduce.h.
905 Reported by Hans Aberg.
907 2001-11-14 Akim Demaille <akim@epita.fr>
909 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
910 Revert a previous patch: these are really const.
911 * src/conflicts.c (conflict_report): Additional useless pair of
912 braces to pacify GCC's warnings for `if () if () {} else {}'.
913 * src/lex.c (parse_percent_token): Replace equal_offset with
916 Be sure to strdup `arg' when used, since there is no reason for
917 token_buffer not to change.
919 2001-11-14 Akim Demaille <akim@epita.fr>
921 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
923 * src/main.c (main): Use them.
924 Suggested by Hans Aberg.
926 2001-11-12 Akim Demaille <akim@epita.fr>
930 * src/system.h (ngettext): Now that we use ngettext, be sure to
931 provide a default definition when NLS are not used that takes care
934 2001-11-12 Akim Demaille <akim@epita.fr>
936 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
937 Use @kbd to denote user input.
938 (Language and Grammar): ANSIfy the example.
939 Adjust its layout for info/notinfo.
940 (Location Tracking Calc): Output error messages to stderr.
941 Output locations in a more GNUtically correct way.
942 Fix a couple of Englishos.
943 Adjust @group/@end group pairs.
945 2001-11-12 Akim Demaille <akim@epita.fr>
947 %expext was not functioning at all.
949 * src/conflicts.c (expected_conflicts): Set to -1.
950 (conflict_report): Use ngettext.
951 (conflicts_print): Check %expect and make its violation an error.
952 * doc/bison.texinfo (Expect Decl): Adjust.
953 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
954 * tests/regression.at (%expect not enough, %expect right)
955 (%expect too much): New.
957 2001-11-12 Akim Demaille <akim@epita.fr>
959 * tests/regression.at (Conflicts): Rename as...
960 (Unresolved SR Conflicts): this.
961 (Solved SR Conflicts): New.
963 2001-11-12 Akim Demaille <akim@epita.fr>
965 * src/reduce.c (print_results): Rename as...
966 (reduce_output): This.
967 Output to OUT, passed as argument, instead of output_obstack.
968 (dump_grammar): Likewise.
971 (reduce_grammar): No longer call reduce_output, since...
972 * src/print.c (print_results): do it.
973 * src/main.c (main): Call reduce_free;
975 2001-11-12 Akim Demaille <akim@epita.fr>
977 * src/conflicts.c (print_reductions): Accept OUT as argument.
978 Output to it, not to output_obstack.
979 * src/print.c (print_actions): Adjust.
981 2001-11-12 Akim Demaille <akim@epita.fr>
983 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
984 the result instead of using...
985 (src_total, rrc_total, src_count, rrc_count): Remove.
986 (any_conflicts): Remove.
987 (print_conflicts): Split into...
988 (conflicts_print, conflicts_output): New.
989 * src/conflicts.h: Adjust.
990 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
991 * src/print.c (print_grammar): Issue `\n' between to rule outputs.
992 * tests/regression.at (Conflicts): New.
993 Reported by Tom Lane.
995 2001-11-12 Akim Demaille <akim@epita.fr>
997 * tests/regression.at (Invalid input): Remove, duplicate with
998 ``Invalid input: 1''.
1000 2001-11-12 Akim Demaille <akim@epita.fr>
1002 * tests/torture.at (AT_DATA_STACK_TORTURE)
1003 (Exploding the Stack Size with Alloca)
1004 (Exploding the Stack Size with Malloc): New.
1006 2001-11-12 Akim Demaille <akim@epita.fr>
1008 * src/bison.simple (YYSTACK_REALLOC): New.
1009 (yyparse) [!yyoverflow]: Use it and free the old stack.
1010 Reported by Per Allansson.
1012 2001-11-05 Akim Demaille <akim@epita.fr>
1015 * src/lex.c (parse_percent_token): s/quotearg/quote/.
1017 2001-11-05 Akim Demaille <akim@epita.fr>
1019 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
1022 2001-11-05 Akim Demaille <akim@epita.fr>
1024 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
1025 with yyltype/YYLTYPE. This allows inclusion of the generated
1026 header within the parser if the compiler, such as GGC, accepts
1027 multiple equivalent #defines.
1029 2001-11-04 Akim Demaille <akim@epita.fr>
1031 * src/getargs.c (longopts): Support `--output'. getopt is now
1032 able to understand that `--out' is OK: the two racing long options
1035 * src/lex.h (tok_setopt): Remove, replaced with...
1036 (tok_intopt, tok_stropt): these new guys.
1037 * src/lex.c (getopt.h): Not needed.
1038 (token_buffer, unlexed_token_buffer): Not const.
1039 (percent_table): Promote `-' over `_' in directive names.
1040 Active `%name-prefix', `file-prefix', and `output'.
1041 (parse_percent_token): Accept possible arguments to directives.
1042 Promote `-' over `_' in directive names.
1043 * doc/bison.texinfo (Decl Summary): Split the list into
1044 `directives for grammars' and `directives for bison'.
1046 Add description of `%name-prefix', `file-prefix', and `output'.
1047 Promote `-' over `_' in directive names.
1048 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
1049 Simplify the description of `--name-prefix'.
1050 Promote `-' over `_' in directive names.
1051 Promote `--output' over `--output-file'.
1052 Fix the description of `--defines'.
1053 * tests/output.at: Exercise %file-prefix and %output.
1055 2001-11-02 Akim Demaille <akim@epita.fr>
1057 * doc/refcard.tex: Update.
1059 2001-11-02 Akim Demaille <akim@epita.fr>
1061 * src/symtab.h (SUNDEF): New.
1062 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
1063 stand for `uninitialized', instead of 0.
1064 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
1065 * src/lex.c (lex): Adjust.
1067 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
1069 Let yylex return it instead of a plain 0.
1070 Reported by Dick Streefland.
1072 2001-11-02 Akim Demaille <akim@epita.fr>
1074 * tests/regression.at (Mixing %token styles): New test.
1076 2001-11-02 Akim Demaille <akim@epita.fr>
1078 * src/reader.c (parse_thong_decl): Formatting changes.
1079 (token_translations_init): New, extracted from...
1080 (packsymbols): Here.
1083 2001-11-01 Akim Demaille <akim@epita.fr>
1085 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
1086 Check that `9foo.y' produces correct cpp guards.
1087 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
1091 2001-11-01 Akim Demaille <akim@epita.fr>
1093 * tests/regression.at (Invalid input: 2): New.
1094 * src/lex.c (unlexed_token_buffer): New.
1095 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
1099 2001-11-01 Akim Demaille <akim@epita.fr>
1101 * configure.in: Bump to 1.30a.
1102 Adjust to newer Autotest.
1104 2001-10-26 Akim Demaille <akim@epita.fr>
1108 2001-10-26 Paul Eggert <eggert@twinsun.com>
1110 * lib/error.c, lib/error.h, lib/getopt.c, lib/getopt.h,
1111 lib/getopt1.c, lib/obstack.c, lib/obstack.h, lib/quote.c,
1112 lib/strnlen.c, lib/xmalloc.c, m4/c-bs-a.m4, m4/error.m4,
1113 m4/gettext.m4, m4/lcmessage.m4, m4/malloc.m4, m4/mbstate_t.m4,
1114 m4/progtest.m4, m4/realloc.m4, m4/strerror_r.m4:
1115 Sync with fileutils 4.1.1.
1117 2001-10-18 Akim Demaille <akim@epita.fr>
1120 * tests/calc.at (_AT_CHECK_CALC_ERROR): Don't use `foo && bar', to
1121 avoid spurious failures.
1123 2001-10-18 Akim Demaille <akim@epita.fr>
1127 2001-10-18 Akim Demaille <akim@epita.fr>
1129 * tests/atlocal.in (GCC): Add.
1130 * tests/calc.at: s/m4_match/m4_bmatch/.
1131 s/m4_patsubst/m4_bpatsubst/.
1132 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
1133 * configure.in: AC_SUBST(GCC).
1135 2001-10-10 Akim Demaille <akim@epita.fr>
1138 * configure.in: M4 is no longer needed, but autom4te is.
1139 * tests/Makefile.am (AUTOTEST): Don't define AUTOM4TE, let
1142 2001-10-10 Akim Demaille <akim@epita.fr>
1146 2001-10-10 Akim Demaille <akim@epita.fr>
1149 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
1150 Use `#if !YYSTACK_USE_ALLOCA', not `#ifndef'.
1151 Reported by Airy Andre.
1153 2001-10-10 Akim Demaille <akim@epita.fr>
1155 * INSTALL, config/config.guess, config/config.sub, config/mdate-sh
1156 * config/mkinstalldirs, lib/ansi2knr.c: Update.
1158 2001-10-02 Akim Demaille <akim@epita.fr>
1162 2001-10-02 Akim Demaille <akim@epita.fr>
1166 2001-10-02 Akim Demaille <akim@epita.fr>
1168 * tests/regression.at (Invalid CPP headers): New.
1169 From Alexander Belopolsky.
1170 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
1172 2001-10-02 Akim Demaille <akim@epita.fr>
1174 * tests/regression.at (Invalid input): New.
1175 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
1178 2001-10-02 Akim Demaille <akim@epita.fr>
1180 * tests/calc.at: Now that --debug works, the tests must be adjusted.
1182 2001-10-02 Akim Demaille <akim@epita.fr>
1184 * src/output.c (output_parser): Assert `skeleton'.
1185 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
1189 2001-10-01 Marc Autret <autret_m@epita.fr>
1191 * src/lex.h: Echo modifications.
1192 * src/lex.c (unlex): Parameter is now token_t.
1195 2001-10-01 Marc Autret <autret_m@epita.fr>
1197 * src/main.c: Include lex.h.
1200 2001-09-29 Akim Demaille <akim@epita.fr>
1202 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
1204 2001-09-28 Akim Demaille <akim@epita.fr>
1206 * tests/testsuite.at: Update to newer Autotest.
1207 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
1209 2001-09-27 Akim Demaille <akim@epita.fr>
1211 Position independent wrapper.
1213 * tests/bison: Remove.
1214 * tests/bison.in: New.
1215 * configure.in: Adjust.
1217 2001-09-27 Paul Eggert <eggert@twinsun.com>
1219 Port quotearg fixes from tar 1.13.24.
1221 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
1223 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
1224 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
1226 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
1227 * m4/mbrtowc.m4: New file.
1228 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
1229 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
1231 2001-09-27 Akim Demaille <akim@epita.fr>
1235 2001-09-27 Akim Demaille <akim@epita.fr>
1239 2001-09-25 Akim Demaille <akim@epita.fr>
1241 * src/system.h: Include `xalloc.h'.
1242 Remove it from the C files.
1243 * src/files.c (output_files): Free the obstacks.
1244 * src/lex.c (init_lex): Rename as...
1247 * src/main.c (main): Use it.
1249 2001-09-24 Marc Autret <autret_m@epita.fr>
1251 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
1252 to output informations in fout (FILE*).
1253 (open_graph, close_graph): Likewise.
1254 (output_graph, output_edge, output_node): Likewise.
1255 * src/vcg.h: Update function prototypes.
1256 * src/print_graph.c (print_graph): Open output graph file.
1257 (print_actions): Adjust.
1258 * src/files.h: Remove extern declaration.
1259 * src/files.c: Remove graph_obstack declaration.
1260 (open_files): Remove graph_obstack initialization.
1261 (output_files): Remove graph_obstack saving.
1263 2001-09-24 Marc Autret <autret_m@epita.fr>
1265 * src/files.c (compute_output_file_names): Fix.
1267 2001-09-24 Marc Autret <autret_m@epita.fr>, Akim Demaille <akim@epita.fr>
1269 * src/reader.c (reader): Remove call to free_symtab ().
1270 * src/main.c (main): Call it here.
1272 * src/conflicts.c (initialize_conflicts): Rename as...
1273 (solve_conflicts): this.
1274 * src/print.c (print_core, print_actions, print_state)
1275 (print_grammar): Dump to a file instead a `output_obstack'.
1276 (print_results): Dump `output_obstack', and then proceed with the
1278 * src/files.c (compute_output_file_names, close_files): New.
1279 (output_files): Adjust.
1280 * src/main.c (main): Adjust.
1282 2001-09-23 Marc Autret <autret_m@epita.fr>
1284 * src/files.c (compute_header_macro): Computes header macro name
1285 from spec_defines_file when given.
1287 2001-09-23 Marc Autret <autret_m@epita.fr>
1289 * src/files.c (output_files): Add default extensions.
1291 2001-09-22 Akim Demaille <akim@epita.fr>
1293 * src/conflicts.c (finalize_conflicts): Rename as...
1294 (free_conflicts): this.
1296 2001-09-22 Akim Demaille <akim@epita.fr>
1298 * src/gram.c (gram_free): Rename back as...
1300 (output_token_translations): Free `token_translations'.
1301 * src/symtab.c (free_symtab): Free the tag field.
1303 2001-09-22 Akim Demaille <akim@epita.fr>
1305 Remove `translations' as it is always set to true.
1307 * src/gram.h: Adjust.
1308 * src/reader.c (packsymbols, parse_token_decl): Adjust
1309 * src/print.c (print_grammar): Adjust.
1310 * src/output.c (output_token_translations): Adjust.
1311 * src/lex.c (lex): Adjust.
1312 * src/gram.c: Be sure the set pointers to NULL.
1313 (dummy): Rename as...
1316 2001-09-22 Akim Demaille <akim@epita.fr>
1318 * configure.in: Invoke AM_LIB_DMALLOC.
1319 * src/system.h: Use dmalloc.
1320 * src/LR0.c: Be sure to have pointers initialized to NULL.
1321 (allocate_itemsets): Allocate kernel_items only if needed.
1323 2001-09-22 Akim Demaille <akim@epita.fr>
1325 * configure.in: Bump to 1.29b.
1326 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
1327 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
1328 need xmalloc.c in calc.y.
1331 2001-09-21 Akim Demaille <akim@epita.fr>
1334 * Makefile.maint, config/config.guess, config/config.sub,
1335 * config/missing: Update from masters.
1336 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
1338 * configure.in (ALL_LINGUAS): Add `tr'.
1340 2001-09-21 Akim Demaille <akim@epita.fr>
1342 * tests/Makefile.am (package.m4): Move to...
1343 ($(srcdir)/$(TESTSUITE)): here.
1345 2001-09-20 Akim Demaille <akim@epita.fr>
1347 * src/complain.c: No longer try to be standalone: use system.h.
1348 Don't assume __STDC__ is defined to 1. Just test if it is defined.
1349 * src/complain.h: Likewise.
1350 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
1351 Remove the unused variable `n'.
1352 From Albert Chin-A-Young.
1354 2001-09-18 Marc Autret <autret_m@epita.fr>
1356 * doc/bison.1: Update.
1357 * doc/bison.texinfo (Bison Options): Update --defines and --graph
1359 (Option Cross Key): Update.
1362 2001-09-18 Marc Autret <autret_m@epita.fr>
1364 * tests/regression.at: New test (comment in %union).
1366 2001-09-18 Marc Autret <autret_m@epita.fr>
1368 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
1370 Reported by Keith Browne.
1372 2001-09-18 Marc Autret <autret_m@epita.fr>
1374 * tests/output.at: Add tests for --defines and --graph.
1376 2001-09-18 Marc Autret <autret_m@epita.fr>
1378 * tests/output.at: Removes tests of %{header,src}_extension features.
1380 2001-09-18 Akim Demaille <akim@epita.fr>
1382 * tests/Makefile.am (package.m4): New.
1383 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
1384 (_AT_CHECK_CALC_ERROR): Likewise.
1385 Factor the `, ' part of verbose error messages.
1387 2001-09-18 Marc Autret <autret_m@epita.fr>
1389 * src/getargs.c (longopts): Declare --defines and --graph as options
1390 with optional arguments.
1391 * src/files.h: Add extern declarations.
1392 * src/files.c (spec_graph_file, spec_defines_file): New.
1393 (output_files): Update.
1394 Remove CPP-outed code.
1396 2001-09-18 Marc Autret <autret_m@epita.fr>
1398 Turn off %{source,header}_extension feature.
1400 * src/files.c (compute_exts_from_gf): Update.
1401 (compute_exts_from_src): Update.
1402 (output_files): CPP-out useless code.
1403 * src/files.h: Remove {header,source}_extension extern declarations.
1404 * src/reader.c (parse_dquoted_param): CPP-out.
1405 (parse_header_extension_decl): Remove.
1406 (parse_source_extension_decl): Remove.
1407 (read_declarations): Remove cases tok_{hdrext,srcext}.
1408 * src/lex.c (percent_table): Remove {header,source}_extension entries.
1409 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
1411 2001-09-10 Akim Demaille <akim@epita.fr>
1413 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
1414 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
1415 (AT_CHECK_OUTPUT): this.
1416 Merely check ls' exit status, its output is useless.
1418 2001-09-10 Akim Demaille <akim@epita.fr>
1420 * tests/calc.at: Use m4_match.
1421 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
1423 2001-09-10 Marc Autret <autret_m@epita.fr>, Akim Demaille <akim@epita.fr>
1425 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
1427 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
1429 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
1430 * src/lex.h: Adjust prototype.
1431 (token_t): Add `tok_undef'.
1432 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
1433 (parse_percent_token): Now returns token_t.
1434 Add default statement in switch.
1435 (lex): Separate `c' as an input variable, from the token_t result
1437 (unlexed): Is a token_t.
1439 2001-09-10 Akim Demaille <akim@epita.fr>
1441 * configure.in: Bump to 1.29a.
1443 2001-09-07 Akim Demaille <akim@epita.fr>
1447 2001-08-30 Akim Demaille <akim@epita.fr>
1449 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
1450 * m4/atconfig.m4: Remove.
1451 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
1453 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
1454 m4_if, m4_patsubst, and m4_regexp.
1455 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
1456 `input' file instead of echo.
1458 2001-08-29 Akim Demaille <akim@epita.fr>
1462 2001-08-29 Akim Demaille <akim@epita.fr>
1466 2001-08-29 Paul Eggert <eggert@twinsun.com>
1468 * src/bison.simple (yyparse): Don't take the address of an
1469 item before the start of an array, as that doesn't conform to
1472 2001-08-29 Robert Anisko <anisko_r@epita.fr>
1474 * doc/bison.texinfo (Location Tracking Calc): New node.
1476 2001-08-29 Paul Eggert <eggert@twinsun.com>
1478 * src/output.c (output): Do not define const, as this now
1479 causes more problems than it cures.
1481 2001-08-29 Akim Demaille <akim@epita.fr>
1483 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
1485 Be sure to tag the `detailmenu'.
1487 2001-08-29 Akim Demaille <akim@epita.fr>
1489 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
1490 download in a tmp dir.
1492 2001-08-28 Marc Autret <autret_m@epita.fr>
1494 * config/depcomp: New file.
1496 2001-08-28 Marc Autret <autret_m@epita.fr>
1498 * doc/bison.1 (mandoc): Adjust.
1499 From Juan Manuel Guerrero.
1501 2001-08-28 Marc Autret <autret_m@epita.fr>
1503 * src/print_graph.c (print_state): Fix.
1505 2001-08-27 Marc Autret <autret_m@epita.fr>
1507 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
1509 Echo modifications to the functions prototypes.
1510 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
1512 2001-08-27 Marc Autret <autret_m@epita.fr>
1514 * src/vcg.c: Include `xalloc.h'.
1515 (add_colorentry): New.
1516 (add_classname): New.
1517 (add_infoname): New.
1518 * src/vcg.h: Add new prototypes.
1520 2001-08-27 Akim Demaille <akim@epita.fr>
1522 * Makefile.maint: Sync. again with CVS Autoconf.
1524 2001-08-27 Akim Demaille <akim@epita.fr>
1526 * Makefile.maint: Formatting changes.
1527 (po-update, cvs-update, update): New targets.
1530 2001-08-27 Akim Demaille <akim@epita.fr>
1532 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
1533 * Makefile.maint: Sync. with CVS Autoconf.
1535 2001-08-27 Marc Autret <autret_m@epita.fr>
1537 * src/vcg.h (struct infoname_s): New.
1538 (struct colorentry_s): New.
1539 (graph_s): New fields {vertical,horizontal}_order in structure.
1540 Add `infoname' field.
1541 Add `colorentry' field;
1542 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
1543 (G_HORIZONTAL_ORDER): New.
1545 (G_COLORENTRY): New.
1546 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
1547 Add output of `infoname'.
1548 Add output of `colorentry'.
1550 2001-08-27 Marc Autret <autret_m@epita.fr>
1552 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
1553 This one shadowed a global parameter.
1555 2001-08-24 Marc Autret <autret_m@epita.fr>
1557 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
1558 instead of `unsigned'.
1559 (print_state): Do not call obstack_object_size () in obstack_grow ()
1560 to avoid macro variables shadowing.
1562 2001-08-23 Marc Autret <autret_m@epita.fr>
1564 * src/lex.c (percent_table): Typo: s/naem/name/.
1566 Normalize new options declarations.
1568 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
1570 * tests/suite.at: Exercise %header_extension and %source_extension.
1572 2001-08-16 Marc Autret <autret_m@epita.fr>
1574 * src/reader.c (parse_dquoted_param): New.
1575 (parse_header_extension_decl): Use it.
1576 (parse_source_extension_decl): Likewise.
1578 2001-08-16 Marc Autret <autret_m@epita.fr>
1580 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
1581 (get_xxxx_str): Use assert () instead of complain ().
1582 Remove return invokations in default cases.
1583 (get_decision_str): Modify default behaviour. Remove second argument.
1584 Echo modifications on calls.
1585 (output_graph): Fix.
1587 2001-08-16 Marc Autret <autret_m@epita.fr>
1589 * src/getargs.c (usage): Update with ``-g, --graph''.
1591 2001-08-16 Marc Autret <autret_m@epita.fr>
1593 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
1594 (Option Cross Key): Likewise.
1595 * doc/bison.1: Update.
1597 2001-08-15 Akim Demaille <akim@epita.fr>
1601 2001-08-15 Marc Autret <autret_m@epita.fr>
1603 * src/reader.c (readgram): Indent output macro YYSTYPE.
1604 (packsymbols): Likewise.
1605 (output_token_defines): Likewise.
1606 * src/files.c: Standardize.
1607 (compute_header_macro): New.
1608 (defines_obstack_save): New. Use compute_header_macro.
1609 (output_files): Update. Use defines_obstack_save.
1611 2001-08-15 Akim Demaille <akim@epita.fr>
1613 * doc/bison.texinfo (Table of Symbols): Document
1616 2001-08-15 Akim Demaille <akim@epita.fr>
1618 * missing: Update from CVS Automake.
1619 * config/config.guess, config/config.sub, config/texinfo.tex:
1620 Update from gnu.org.
1622 2001-08-15 Akim Demaille <akim@epita.fr>
1624 * Makefile.maint: Sync with CVS Autoconf.
1626 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
1628 * doc/bison.texinfo: Include GNU Free Documentation License from
1630 * doc/fdl.texi: Add to package.
1632 2001-08-14 Marc Autret <autret_m@epita.fr>
1634 Turn on %{source,header}_extension features.
1636 * src/lex.c (percent_table): Un-CPP out header_extension and
1638 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
1639 (compute_exts_from_src): Remove conditions. It restores priorities
1642 2001-08-14 Marc Autret <autret_m@epita.fr>
1644 * src/files.c (compute_base_names): Add extensions computing when
1645 `--file-prefix' used.
1646 Standardize function calls.
1648 2001-08-13 Marc Autret <autret_m@epita.fr>
1650 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
1651 defining it (defined but null disables alloca).
1653 2001-08-13 Marc Autret <autret_m@epita.fr>
1655 * src/bison.simple (_yy_memcpy): CPP reformat.
1657 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
1659 * tests/atconfig.in (CPPFLAGS): Fix.
1661 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
1663 * doc/bison.texinfo: Include GNU General Public License from
1665 * doc/gpl.texi: Add to package.
1667 2001-08-10 Marc Autret <autret_m@epita.fr>
1669 * src/print_graph.h: Fix.
1670 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
1672 2001-08-10 Akim Demaille <akim@epita.fr>
1674 * src/system.h: Provide default declarations for stpcpy, strndup,
1677 2001-08-10 Robert Anisko <anisko_r@epita.fr>
1679 * doc/bison.texinfo (Locations): Update @$ stuff.
1681 2001-08-09 Robert Anisko <anisko_r@epita.fr>
1683 * src/bison.simple (YYLLOC_DEFAULT): Update.
1686 2001-08-08 Marc Autret <autret_m@epita.fr>
1688 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
1689 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
1690 Reported by Fabrice Bauzac.
1692 2001-08-08 Marc Autret <autret_m@epita.fr>
1694 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
1695 * src/vcg.c (output_node): Fix.
1696 * src/vcg.h: Cleanup.
1697 * src/print_graph.c: Add comments.
1698 (node_output_size): New global variable. Simplify the formatting of
1699 the VCG graph output.
1700 (print_actions): Unused code is now used. It notifies the final state
1701 and no action states in the VCG graph. It also give the reduce actions.
1702 The `shift and goto' edges are red and the `go to state' edges are
1704 Get the current node name and node_obstack by argument.
1705 (node_obstack): New variable.
1706 (print_state): Manage node_obstack.
1707 (print_core): Use node_obstack given by argument.
1708 A node is not only computed here but in print_actions also.
1709 (print_graph): CPP out useless code instead of commenting it.
1711 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
1713 * tests/atconfig.in (CPPFLAGS): Fix.
1715 2001-08-07 Akim Demaille <akim@epita.fr>
1717 * src/print_graph.c (quote): New.
1718 (print_core): Use it.
1720 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
1722 * src/vcg.c (complain.h): Include it.
1723 Unepitaize `return' invocations.
1724 [NDEBUG] (main): Remove.
1725 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
1726 * src/files.c (open_files): Initialize graph_obstack.
1727 * src/print_graph.c (print_actions): CPP out useless code.
1728 (print_core): Don't output the last `\n' in labels.
1730 * src/files.c (output_files): Output the VCG file.
1731 * src/main.c (main): Invoke print_graph ();
1733 2001-08-06 Marc Autret <autret_m@epita.fr>
1735 Automaton VCG graph output.
1736 Using option ``-g'' or long option ``--graph'', you can generate
1737 a gram_filename.vcg file containing a VCG description of the LALR (1)
1738 automaton of your grammar.
1740 * src/main.c: Call to print_graph() function.
1741 * src/getargs.h: Update.
1742 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
1743 (graph_flag): New flag.
1745 (getargs): Add case `g'.
1746 * src/files.c (graph_obstack): New obstack struct.
1747 (open_files): Initialize new obstack.
1748 (output_files): Saves graph_obstack if required.
1749 * src/files.h (graph_obstack): New extern declaration.
1750 * src/Makefile.am: Add new source files.
1752 2001-08-06 Marc Autret <autret_m@epita.fr>
1754 * src/print_graph.c, src/print_graph.h (graph): New.
1755 * src/vcg.h: New file.
1756 * src/vcg.c: New file, VCG graph handling.
1758 2001-08-06 Marc Autret <autret_m@epita.fr>
1760 Add of %source_extension and %header_extension which specify
1761 the source or/and the header output file extension.
1763 * src/files.c (compute_base_names): Remove initialisation of
1764 src_extension and header_extension.
1765 (compute_exts_from_gf): Update.
1766 (compute_exts_from_src): Update.
1767 (output_files): Update.
1768 * src/reader.c (parse_header_extension_decl): New.
1769 (parse_source_extension_decl): New.
1770 (read_declarations): New case statements for the new tokens.
1771 * src/lex.c (percent_table): Add entries for %source_extension
1772 and %header_extension.
1773 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
1775 2001-08-06 Marc Autret <autret_m@epita.fr>
1777 * configure.in: Bump to 1.28c.
1778 * doc/bison.texinfo: Texinfo thingies.
1780 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
1782 * tests/atconfig.in (CPPFLAGS): Add.
1783 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
1785 2001-08-03 Akim Demaille <akim@epita.fr>
1789 2001-08-03 Akim Demaille <akim@epita.fr>
1791 * tests/Makefile.am (check-local): Ship testsuite.
1792 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
1795 2001-08-03 Akim Demaille <akim@epita.fr>
1797 * configure.in: Try using -Wformat when compiling.
1799 2001-08-03 Akim Demaille <akim@epita.fr>
1801 * configure.in: Bump to 1.28b.
1803 2001-08-03 Akim Demaille <akim@epita.fr>
1805 * src/complain.c: Adjust strerror_r portability issues.
1807 2001-08-03 Akim Demaille <akim@epita.fr>
1811 2001-08-03 Akim Demaille <akim@epita.fr>
1813 * src/getargs.c, src/getarg.h (skeleton)): Constify.
1814 * src/lex.c (literalchar): Avoid name clashes on `buf'.
1815 * src/getargs.c: Include complain.h.
1816 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
1817 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
1819 2001-08-03 Akim Demaille <akim@epita.fr>
1821 * src/reader.c (readgram): Display hidden chars in error messages.
1823 2001-08-03 Akim Demaille <akim@epita.fr>
1825 Update to gettext 0.10.39.
1827 2001-08-03 Akim Demaille <akim@epita.fr>
1829 * lib/strspn.c: New.
1831 2001-08-01 Marc Autret <autret_m@epita.fr>
1833 * doc/bison.texinfo: Update.
1834 * doc/bison.1 (mandoc): Update.
1835 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
1836 * src/files.c: Support output files extensions computing.
1837 (src_extension): New static variable.
1838 (header_extension): New static variable.
1840 (get_extension_index): New function, gets the index of an extension
1841 filename in a string.
1842 (compute_exts_from_gf): New function, computes extensions from the
1843 grammar file extension.
1844 (compute_exts_from_src): New functions, computes extensions from the
1845 C source file extension, file given by ``-o'' option.
1846 (compute_base_names): Update.
1847 (output_files): Update.
1849 2001-08-01 Robert Anisko <anisko_r@epita.fr>
1851 * doc/bison.texi: Document @$.
1852 (Locations): New section.
1854 2001-07-18 Akim Demaille <akim@epita.fr>
1856 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
1857 * config/prev-version.txt, config/move-if-change: New.
1858 * Makefile.am: Adjust.
1860 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
1862 * src/bison.simple (yyparse): Suppress warning `comparaison
1863 between signed and unsigned'.
1865 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
1867 * src/getargs.h (raw_flag): Remove.
1868 * src/getargs.c: Die on `-r'/`--raw'.
1869 * src/lex.c (parse_percent_token): Die on `%raw'.
1870 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
1871 * tests/calc.at: Suppress test with option `--raw'.
1873 2001-07-14 Akim Demaille <akim@epita.fr>
1876 * configure.in: Require Autoconf 2.50.
1877 Update to gettext 0.10.38.
1879 2001-03-16 Akim Demaille <akim@epita.fr>
1881 * doc/bison.texinfo: ANSIfy the examples.
1883 2001-03-16 Akim Demaille <akim@epita.fr>
1885 * getargs.c (skeleton): New variable.
1886 (longopts): --skeleton is a new option.
1887 (shortopts, getargs): -S is a new option.
1888 * getargs.h: Declare skeleton.
1889 * output.c (output_parser): Use it.
1891 2001-03-16 Akim Demaille <akim@epita.fr>
1893 * m4/strerror_r.m4: New.
1894 * m4/error.m4: Run AC_FUNC_STRERROR_R.
1895 * lib/error.h, lib/error.c: Update.
1897 2001-03-16 Akim Demaille <akim@epita.fr>
1899 * src/getargs.c (longopts): Clean up.
1901 2001-02-21 Akim Demaille <akim@epita.fr>
1903 * src/reader.c (gensym): `gensym_count' is your own.
1904 Use a static buf to create the symbol name, as token_buffer is no
1907 2001-02-08 Akim Demaille <akim@epita.fr>
1909 * src/conflicts.c (conflict_report): Be sure not to append to res
1910 between two calls, which could happen if both first sprintf were
1911 skipped, but not the first cp += strlen.
1913 2001-02-08 Akim Demaille <akim@epita.fr>
1915 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
1916 New, from fileutils 4.0.37.
1917 * configure.in: Require Autoconf 2.49c. I took some time before
1918 making this decision. This is the only way out for portability
1919 issues in Bison, it would mean way too much duplicate effort to
1920 import in Bison features implemented in 2.49c since 2.13.
1921 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
1923 2001-02-02 Akim Demaille <akim@epita.fr>
1925 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
1926 * lib/xalloc.h, lib/xmalloc.c: Update.
1928 2001-01-19 Akim Demaille <akim@epita.fr>
1930 Get rid of the ad hoc handling of token_buffer in the scanner: use
1933 * src/lex.c (token_obstack): New.
1934 (init_lex): Initialize it. No longer call...
1935 (grow_token_buffer): this. Remove it.
1936 Adjust all the places which used it to use the obstack.
1938 2001-01-19 Akim Demaille <akim@epita.fr>
1940 * src/lex.h: Rename all the tokens:
1941 s/\bENDFILE\b/tok_eof/g;
1942 s/\bIDENTIFIER\b/tok_identifier/g;
1944 Let them be enums, not #define, to ease debugging.
1945 Adjust all the code.
1947 2001-01-18 Akim Demaille <akim@epita.fr>
1949 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
1950 * src/lex.c (maxtoken, grow_token_buffer): Static.
1952 2001-01-18 Akim Demaille <akim@epita.fr>
1954 Since we now use obstacks, more % directives can be enabled.
1956 * src/lex.c (percent_table): Also accept `%yacc',
1957 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
1959 Handle the actions for `%semantic_parser' and `%pure_parser' here,
1960 instead of returning a token.
1961 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
1962 * src/reader.c (read_declarations): Adjust.
1963 * src/files.c (open_files): Don't call `compute_base_names', don't
1964 compute `attrsfile' since they depend upon data which might be
1965 *in* the input file now.
1966 (output_files): Do it here.
1967 * src/output.c (output_headers): Document the fact that this patch
1968 introduces a guaranteed SEGV for semantic parsers.
1969 * doc/bison.texinfo: Document them.
1970 * tests/suite.at: Exercise these %options.
1972 2000-12-20 Akim Demaille <akim@epita.fr>
1974 Also handle the output file (--verbose) with obstacks.
1976 * files.c (foutput): Remove.
1977 (output_obstack): New.
1978 Adjust all dependencies.
1979 * src/conflicts.c: Return a string.
1980 * src/system.h (obstack_grow_string): Rename as...
1981 (obstack_sgrow): this. Be ready to work with non literals.
1982 (obstack_fgrow4): New.
1984 2000-12-20 Akim Demaille <akim@epita.fr>
1986 * src/files.c (open_files): Fix the computation of short_base_name
1987 in the case of `-o foo.tab.c'.
1989 2000-12-20 Akim Demaille <akim@epita.fr>
1991 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
1992 (copy_dollar): Now that everything uses obstacks, get rid of the
1995 2000-12-20 Akim Demaille <akim@epita.fr>
1997 * src/files.c (open_files): Actually the `.output' file is based
1998 on the short_base_name, not base_name.
1999 * tests/suite.at (Checking output file names): Adjust.
2001 2000-12-20 Akim Demaille <akim@epita.fr>
2003 * src/bison.s1: Remove, we now use directly...
2004 * src/bison.simple: this.
2005 * src/Makefile.am: Use pkgdata instead of data.
2007 2000-12-20 Akim Demaille <akim@epita.fr>
2009 * src/files.c (guard_obstack): New.
2010 (open_files): Initialize it.
2011 (output_files): Dump it...
2012 * src/files.h: Export it.
2013 * src/reader.c (copy_guard): Use it.
2015 2000-12-19 Akim Demaille <akim@epita.fr>
2017 * src/files.c (outfile, defsfile, actfile): Removed as global
2019 (open_files): Don't compute them.
2020 (output_files): Adjust.
2021 (base_name, short_base_name): Be global.
2022 Adjust dependencies.
2024 2000-12-19 Akim Demaille <akim@epita.fr>
2026 * src/files.c (strsuffix): New.
2027 (stringappend): Be just like strcat but allocate.
2028 (base_names): Eve out from open_files.
2029 Try to simplify the rather hairy computation of base_name and
2031 (open_files): Use it.
2032 * tests/suite.at (Checking output file names): New test.
2034 2000-12-19 Akim Demaille <akim@epita.fr>
2036 * src/system.h (obstack_grow_literal_string): Rename as...
2037 (obstack_grow_string): this.
2038 * src/output.c (output_parser): Recognize `%% actions' instead of
2040 * src/bison.s1: s/$/%% actions/.
2041 * src/bison.hairy: Likewise.
2043 2000-12-19 Akim Demaille <akim@epita.fr>
2045 * src/output.c (output_parser): Compute the `#line' lines when
2047 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
2048 Suggested by Hans Aberg.
2050 2000-12-19 Akim Demaille <akim@epita.fr>
2052 Let the handling of the skeleton files be local to the procedures
2055 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
2057 (fparser, open_extra_files): Remove.
2058 (open_files, output_files): Don't take care of fparser.
2059 * src/files.h: Adjust.
2060 * src/output.c (output_parser): Open and close the file to the
2062 * src/reader.c (read_declarations): When %semantic_parser, open
2065 2000-12-19 Akim Demaille <akim@epita.fr>
2067 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
2068 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
2070 2000-12-19 Akim Demaille <akim@epita.fr>
2072 * src/files.c (open_files): Yipee! We no longer need all the code
2073 looking for `/tmp' since we have no tmp file.
2075 2000-12-19 Akim Demaille <akim@epita.fr>
2077 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
2079 * src/files.c (open_files): Less dependency on MSDOS etc.
2081 2000-12-14 Akim Demaille <akim@epita.fr>
2083 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
2084 Provide a default definition.
2085 Use it when executing the default @ action.
2086 * src/reader.c (reader_output_yylsp): No longer include
2087 `timestamp' and `text' in the default YYLTYPE.
2089 2000-12-12 Akim Demaille <akim@epita.fr>
2091 * src/reader.c (copy_definition, parse_union_decl, copy_action)
2092 (copy_guard): Quote the file names.
2093 Reported by Laurent Mascherpa.
2095 2000-12-12 Akim Demaille <akim@epita.fr>
2097 * src/output.c (output_headers, output_program, output): Be sure
2098 to escape special characters when outputting filenames.
2099 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
2100 (output_headers): Don't depend on them, Use ACTSTR.
2102 2000-11-17 Akim Demaille <akim@epita.fr>
2104 * lib/obstack.h: Formatting changes.
2105 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
2106 prevents type checking.
2107 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
2108 cast the value to (void *): assigning a `foo *' to a `void *'
2110 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
2111 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
2114 2000-11-17 Akim Demaille <akim@epita.fr>
2116 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
2118 (suite.m4, regression.m4, calc.m4): these.
2119 * tests/atgeneral.m4: Update from CVS Autoconf.
2121 2000-11-17 Akim Demaille <akim@epita.fr>
2123 * tests/regression.m4 (%union and --defines): New test,
2124 demonstrating a current bug in the obstack implementation.
2126 2000-11-17 Akim Demaille <akim@epita.fr>
2128 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
2130 Use them to declare the variables which are global or local to
2133 2000-11-17 Akim Demaille <akim@epita.fr>
2135 * acconfig.h: Remove, no longer used.
2137 2000-11-07 Akim Demaille <akim@epita.fr>
2139 * src: s/Copyright (C)/Copyright/g.
2141 2000-11-07 Akim Demaille <akim@epita.fr>
2143 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
2145 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
2147 2000-11-07 Akim Demaille <akim@epita.fr>
2149 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
2150 Merge in a single CPP if/else.
2152 2000-11-07 Akim Demaille <akim@epita.fr>
2154 * src/output.c (output): Remove useless variables.
2155 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
2156 argument `data' for consistency with the prototypes.
2158 (obstack_copy, obstack_copy0): Rename the second argument as
2159 `address' for consistency. Qualify it `const'.
2160 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
2161 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
2162 `const' their input argument (`data' or `address').
2163 Adjust the corresponding macros to include `const' in casts.
2165 2000-11-03 Akim Demaille <akim@epita.fr>
2167 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
2168 s/PFILE1/BISON_HAIRY/.
2169 Adjust dependencies.
2171 2000-11-03 Akim Demaille <akim@epita.fr>
2173 For some reason, this was not applied.
2175 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2176 `unlink': it's no longer used.
2178 2000-11-03 Akim Demaille <akim@epita.fr>
2180 * src/files.c (skeleton_find): New function, eved out of...
2181 (open_files, open_extra_files): here.
2183 2000-11-03 Akim Demaille <akim@epita.fr>
2187 * src/files.c (obstack_save): New function.
2188 (done): Rename as...
2189 (output_files): this.
2191 * src/main.c (main): Don't use `atexit' to register `done', since
2192 it no longer has to remove tmp files, just call `output_files'
2193 when there are no errors.
2195 2000-11-02 Akim Demaille <akim@epita.fr>
2197 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2198 `unlink': it's no longer used.
2199 * src/files.h: Formatting changes.
2201 2000-11-02 Akim Demaille <akim@epita.fr>
2203 Remove the last uses of mktemp and unlink/delete.
2205 * src/files.c (fdefines, ftable): Removed.
2206 (defines_ostack, table_obstack): New.
2207 Adjust dependencies of the former into uses of the latter.
2208 * src/output.c (output_short_or_char_table, output_short_table):
2209 Convert to using obstacks.
2210 * src/reader.c (copy_comment2): Accept one FILE * and two
2212 (output_token_defines, reader_output_yylsp): Use obstacks.
2213 * src/system.h (obstack_fgrow3): New.
2215 2000-11-01 Akim Demaille <akim@epita.fr>
2217 Change each use of `fattrs' into a use of `attrs_obstack'.
2219 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
2220 * src/files.c (fattrs): Remove.
2221 (attrs_obstack): New.
2222 Adjust all dependencies.
2223 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
2225 2000-11-01 Akim Demaille <akim@epita.fr>
2228 Change each use of `faction' into a use of `action_obstack'.
2230 * lib/obstack.h, lib/obstack.c: New files.
2231 * src/files.c (faction): Remove.
2232 (action_obstack): New.
2233 Adjust all dependencies.
2235 2000-10-20 Akim Demaille <akim@epita.fr>
2237 * lib/quote.h (PARAMS): New macro. Use it.
2239 2000-10-16 Akim Demaille <akim@epita.fr>
2241 * src/output.c (output_short_or_char_table): New function.
2242 (output_short_table, output_token_translations): Use it.
2243 (goto_actions): Use output_short_table.
2245 2000-10-16 Akim Demaille <akim@epita.fr>
2247 * src/symtab.c (bucket_new): New function.
2250 * src/output.c (output_short_table): New argument to display the
2251 comment associated with the table.
2252 Adjust dependencies.
2253 (output_gram): Use it.
2254 (output_rule_data): Nicer output layout for YYTNAME.
2256 2000-10-16 Akim Demaille <akim@epita.fr>
2258 * src/lex.c (read_typename): New function.
2260 * src/reader.c (copy_dollar): Likewise.
2262 2000-10-16 Akim Demaille <akim@epita.fr>
2264 * src/reader.c (copy_comment2): Expect the input stream to be on
2265 the `/' which is suspected to open a comment, instead of being
2266 called after `//' or `/*' was read.
2267 (copy_comment, copy_definition, parse_union_decl, copy_action)
2268 (copy_guard): Adjust.
2270 2000-10-16 Akim Demaille <akim@epita.fr>
2272 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
2273 `read_signed_integer'.
2275 2000-10-16 Akim Demaille <akim@epita.fr>
2277 * src/reader.c (copy_dollar): New function.
2278 (copy_guard, copy_action): Use it.
2280 2000-10-16 Akim Demaille <akim@epita.fr>
2282 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
2283 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
2284 New files, from Fileutils 4.0.27.
2285 * src/main.c (printable_version): Remove.
2286 * src/lex.c, src/reader.c: Use `quote'.
2288 2000-10-04 Akim Demaille <akim@epita.fr>
2290 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
2292 2000-10-04 Akim Demaille <akim@epita.fr>
2294 * doc/bison.texinfo: Various typos spotted by Neil Booth.
2296 2000-10-04 Akim Demaille <akim@epita.fr>
2298 When a literal string is used to define two different tokens,
2299 `bison -v' segfaults.
2300 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
2302 * tests/regression.m4: New file.
2303 Include the core of the sample provided by Piotr Gackiewicz.
2304 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
2307 2000-10-04 Akim Demaille <akim@epita.fr>
2309 * src/reader.c (parse_expect_decl): Keep `count' within the size
2313 2000-10-02 Paul Eggert <eggert@twinsun.com>
2315 * bison.s1 (yyparse): Assign the default value
2316 unconditionally, to avoid a GCC warning and make the parser a
2319 2000-10-02 Akim Demaille <akim@epita.fr>
2321 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
2324 2000-10-02 Akim Demaille <akim@epita.fr>
2326 * src/derives.c, src/print.c, src/reduce.c: To ease the
2327 translation, move some `\n' out of the translated strings.
2329 2000-10-02 Akim Demaille <akim@epita.fr>
2331 The location tracking mechanism is precious for parse error
2332 messages. Nevertheless, it is enabled only when `@n' is used in
2333 the grammar, which is a different issue (you can use it in error
2334 message, but not in the grammar per se). Therefore, there should
2335 be another means to enable it.
2337 * src/getargs.c (getargs): Support `--locations'.
2339 * src/getargs.h (locationsflag): Export it.
2340 * src/lex.c (percent_table): Support `%locations'.
2341 * src/reader.c (yylsp_needed): Remove this variable, now replaced
2342 with `locationsflag'.
2343 * doc/bison.texinfo: Document `--locations' and `%locations'.
2345 * tests/calc.m4: Test it.
2347 For regularity of the names, replace each
2348 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
2349 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
2350 In addition replace each `flag' with `_flag'.
2352 2000-10-02 Akim Demaille <akim@epita.fr>
2354 Also test parse error messages, including with YYERROR_VERBOSE.
2356 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
2358 Use it to check the computations.
2359 Use it to check `nonassoc' is honored.
2360 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
2361 `--yyerror-verbose'.
2362 (_AT_CHECK_CALC): Adjust to this option.
2363 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
2365 2000-10-02 Akim Demaille <akim@epita.fr>
2367 Test also `--verbose', `--defines' and `--name-prefix'. Testing
2368 the latter demonstrates a flaw in the handling of non debugging
2369 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
2370 was used in order to simplify:
2386 unfortunately this leads to a CPP conflict when
2387 `--name-prefix=foo' is used since it produces `#define yydebug
2390 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
2391 (YYDPRINTF): New macro.
2393 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
2395 Also test `--verbose', `--defines' and `--name-prefix'.
2397 2000-10-02 Akim Demaille <akim@epita.fr>
2399 Improve the readability of the produced parsers.
2401 * src/bison.s1: Formatting changes.
2402 Improve the comment related to the `$' mark.
2403 (yydefault): Don't fall through to `yyresume': `goto' there.
2404 * src/output.c (output_parser): When the `$' is met, skip the end
2406 New variable, `number_of_dollar_signs', to check there's exactly
2407 one `$' in the parser skeleton.
2409 2000-10-02 Akim Demaille <akim@epita.fr>
2411 * lib/xstrdup.c: New file, from the fileutils.
2412 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
2413 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
2414 instead of strlen + xmalloc + strcpy.
2415 * src/symtab.c (copys): Remove, use xstrdup instead.
2417 2000-10-02 Akim Demaille <akim@epita.fr>
2419 * src/gram.h (associativity): New enum type which replaces the
2420 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
2421 `right_assoc', `left_assoc' and `non_assoc'.
2422 Adjust all dependencies.
2423 * src/reader.c: Formatting changes.
2424 (LTYPESTR): Don't define it, use it as a literal in
2425 `reader_output_yylsp'.
2426 * src/symtab.h (symbol_class): New enum type which replaces the
2427 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
2428 `sunknown', `stoken and `snterm'.
2430 2000-10-02 Akim Demaille <akim@epita.fr>
2432 * src/getargs.c (fixed_outfiles): Rename as...
2433 (yaccflag): for consistency and accuracy.
2434 Adjust dependencies.
2436 2000-10-02 Akim Demaille <akim@epita.fr>
2438 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
2439 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
2440 difficult and introduced a lot of core dump. It turns out that
2441 Bison used an implementation of `xmalloc' based on `calloc', and
2442 at various places it does depend upon the initialization to 0. I
2443 have not tried to isolate the pertinent places, and all the former
2444 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
2445 someone should address this issue.
2447 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
2448 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
2450 Adjust dependencies.
2451 * src/warshall.h: New file.
2454 2000-10-02 Akim Demaille <akim@epita.fr>
2456 Various anti-`extern in *.c' changes.
2458 * src/system.h: Include `assert.h'.
2460 2000-10-02 Akim Demaille <akim@epita.fr>
2462 * src/state.h (nstates, final_state, first_state, first_shift)
2463 (first_reduction): Move their exportation from here...
2464 * src/LR0.h: to here.
2465 Adjust dependencies.
2466 * src/getargs.c (statisticsflag): New variable.
2467 Add support for `--statistics'.
2468 Adjust dependencies.
2470 Remove a lot of now useless `extern' statements in most files.
2472 2000-10-02 Akim Demaille <akim@epita.fr>
2474 * src/LR0.h: New file.
2477 2000-10-02 Akim Demaille <akim@epita.fr>
2479 * src/print.h: New file.
2481 * src/print.c: Formatting and ordering changes.
2482 (verbose, terse): Replace with...
2483 (print_results): this new function.
2484 Adjust dependencies.
2486 2000-10-02 Akim Demaille <akim@epita.fr>
2488 * src/conflicts.c (conflict_report): New function.
2489 (conflict_log, verbose_conflict_log): Replace with...
2490 (print_conflicts): this function.
2491 Adjust dependencies.
2492 * src/conflicts.h: New file.
2493 Propagate its inclusion.
2495 2000-10-02 Akim Demaille <akim@epita.fr>
2497 * src/nullable.h: New file.
2498 Propagate its inclusion.
2499 * src/nullable.c: Formatting changes.
2501 2000-10-02 Akim Demaille <akim@epita.fr>
2503 * src/reduce.h: New file.
2504 Propagate its inclusion.
2505 * src/reduce.c: Topological sort and other formatting changes.
2506 (bool, TRUE, FALSE): Move their definition to...
2507 * src/system.h: here.
2509 2000-10-02 Akim Demaille <akim@epita.fr>
2511 * src/files.c: Formatting changes.
2512 (tryopen, tryclose, openfiles): Rename as...
2513 (xfopen, xfclose, open_files): this.
2514 (stringappend): static.
2515 * src/files.h: Complete the list of exported symbols.
2518 2000-10-02 Akim Demaille <akim@epita.fr>
2520 * src/reader.h: New file.
2521 Propagate its use instead of tedious list of `extern' and
2523 * src/reader.c: Formatting changes, topological sort,
2526 2000-10-02 Akim Demaille <akim@epita.fr>
2528 * src/lex.h: Prototype `lex.c' exported functions.
2529 * src/reader.c: Adjust.
2530 * src/lex.c: Formatting changes.
2531 (safegetc): Rename as...
2534 2000-10-02 Akim Demaille <akim@epita.fr>
2536 * src/lalr.h: New file.
2537 Propagate its inclusion instead of prototypes and `extern'.
2538 * src/lalr.c: Formatting changes, topological sorting etc.
2540 2000-10-02 Akim Demaille <akim@epita.fr>
2542 * src/output.c (token_actions): Introduce a temporary array,
2543 YYDEFACT, that makes it possible for this function to use
2546 2000-10-02 Akim Demaille <akim@epita.fr>
2548 `user_toknums' is output as a `short[]' in `output.c', while it is
2549 defined as a `int[]' in `reader.c'. For consistency with the
2550 other output tables, `user_toknums' is now defined as a table of
2553 * src/reader.c (user_toknums): Be a short table instead of an int
2555 Adjust dependencies.
2557 Factor the short table outputs.
2559 * src/output.c (output_short_table): New function.
2560 * src/output.c (output_gram, output_stos, output_rule_data)
2561 (output_base, output_table, output_check): Use it.
2563 2000-10-02 Akim Demaille <akim@epita.fr>
2565 * src/output.c (output): Topological sort of the functions, in
2566 order to get rid of the `static' prototypes.
2567 No longer use `register'.
2568 * src/output.h: New file.
2569 Propagate its inclusion in files explicitly prototyping functions
2572 2000-09-21 Akim Demaille <akim@epita.fr>
2574 * src/atgeneral.m4: Update from Autoconf.
2576 2000-09-21 Akim Demaille <akim@epita.fr>
2578 * src/closure.h: New file.
2579 * src/closure.c: Formatting changes, topological sort over the
2580 functions, use of closure.h.
2581 (initialize_closure, finalize_closure): Rename as...
2582 (new_closure, free_closure): these. Adjust dependencies.
2583 * src/LR0.c: Formatting changes, topological sort, use of
2585 (initialize_states): Rename as...
2587 * src/Makefile.am (noinst_HEADERS): Adjust.
2589 2000-09-20 Akim Demaille <akim@epita.fr>
2591 * src/acconfig.h: Don't protect config.h against multiple
2593 Don't define PARAMS.
2594 * src/system.h: Define PARAMS.
2595 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
2596 purpose of config.h. system.h must not try to fix wrong
2597 definitions in config.h.
2599 2000-09-20 Akim Demaille <akim@epita.fr>
2601 * src/derives.h: New file.
2602 * src/main.c, src/derives.h: Use it.
2604 * src/Makefile.am (noinst_HEADERS): Adjust.
2606 2000-09-20 Akim Demaille <akim@epita.fr>
2608 * tests/atgeneral.m4: Update from Autoconf.
2609 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
2610 (AT_CHECK_CALC): New macros.
2611 Use these macros to test bison with options `', `--raw',
2612 `--debug', `--yacc', `--yacc --debug'.
2614 2000-09-19 Akim Demaille <akim@epita.fr>
2616 * src/output.c: Formatting changes.
2617 * src/machine.h: Remove, leaving its contents in...
2618 * src/system.h: here.
2620 Adjust all dependencies on stdio.h and machine.h.
2621 * src/getargs.h: New file.
2622 Let all `extern' declarations about getargs.c be replaced with
2623 inclusion of `getargs.h'.
2624 * src/Makefile.am (noinst_HEADERS): Adjust.
2626 * tests/calc.m4 (yyin): Be initialized in main, not on the global
2628 (yyerror): Returns void, not int.
2629 * doc/bison.texinfo: Formatting changes.
2631 2000-09-19 Akim Demaille <akim@epita.fr>
2633 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
2636 2000-09-18 Akim Demaille <akim@epita.fr>
2638 * configure.in: Append WARNING_CFLAGS to CFLAGS.
2639 * src/Makefile.am (INCLUDES): Don't.
2640 Be ready to fetch headers in lib/.
2642 2000-09-18 Akim Demaille <akim@epita.fr>
2644 * doc/bison.texinfo: Update the copyright.
2645 ANSIfy and GNUify the examples.
2646 Remove the old menu.
2648 2000-09-18 Akim Demaille <akim@epita.fr>
2650 First set of tests: use the `calc' example from the documentation.
2652 * src/bison.s1 (yyparse): Condition the code using `yytname' which
2653 is defined only when YYDEBUG is.
2654 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
2655 * src/files.c (tryopen, tryclose): Formatting changes.
2656 Move to the top and be static.
2657 * src/reader.c (read_signed_integer): Likewise.
2658 * tests/calc.m4: New file.
2659 * Makefile.am, suite.m4: Adjust.
2660 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
2662 2000-09-18 Akim Demaille <akim@epita.fr>
2664 Add support for an Autotest test suite for Bison.
2666 * m4/m4.m4, m4/atconfig.m4: New files.
2667 * m4/Makefile.am (EXTRA_DIST): Adjust.
2668 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
2670 * src/getargs.c: Display a more standard --version message.
2671 * src/reader.c (reader): Formatting changes.
2672 No longer depend upon VERSION_STRING.
2673 * configure.in: No longer use `dnl'.
2674 Set up the test suite and the new directory `tests/.
2675 (VERSION_STRING): Remove.
2677 2000-04-14 Akim Demaille <akim@epita.fr>
2679 * src/reader.c (copy_comment2): New function, same as former
2680 `copy_comment', but outputs into two FILE *.
2681 (copy_comment): Use it.
2682 (parse_union_decl): Use it.
2683 (get_type, parse_start_decl): Use the same `invalid' message.
2684 (parse_start_decl, parse_union_decl): Use the same `multiple'
2686 (parse_union_decl, copy_guard, copy_action): Use the same
2687 `unmatched' message.
2688 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
2690 2000-03-31 Akim Demaille <akim@epita.fr>
2692 * src/files.c (tryopen, tryclose): Move to the top.
2695 2000-03-31 Akim Demaille <akim@epita.fr>
2697 * src/main.c (main): Don't call `done', exit does it.
2699 2000-03-31 Akim Demaille <akim@epita.fr>
2701 * allocate.c: s/return (foo)/return foo/.
2704 * output.c: Likewise.
2705 * reader.c: Likewise.
2706 * symtab.c: Likewise.
2707 * vmsgetargs.c: Likewise.
2709 2000-03-31 Akim Demaille <akim@epita.fr>
2711 Clean up the error reporting functions.
2713 * src/report.c: New file.
2714 * src/report.h: Likewise.
2715 * src/Makefile.am: Adjust.
2716 * m4/error.m4: New file.
2717 * m4/Makefile.am: Adjust.
2718 * configure.in (jm_PREREQ_ERROR): Call it.
2719 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
2721 (fatal, fatals): Remove. All callers use complain.c::fatal.
2722 (warn, warni, warns, warnss, warnss): Remove. All callers use
2723 complain.c::complain.
2724 (toomany): Remove, use fatal instead.
2725 * src/files.c (done): No argument, use complain_message_count.
2726 * src/main.c (main): Register `done' to `atexit'.
2728 * src/getargs.c (usage): More `fputs', less `fprintf'.
2730 2000-03-28 Akim Demaille <akim@epita.fr>
2732 * lib/: New directory.
2733 * Makefile.am (SUBDIRS): Adjust.
2734 * configure.in: Adjust.
2735 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
2737 * src/alloca.c: Moved to lib/.
2738 * src/getopt.c: Likewise.
2739 * src/getopt1.c: Likewise.
2740 * src/getopt.h: Likewise.
2741 * src/ansi2knr.c: Likewise.
2742 * src/ansi2knr.1: Likewise.
2743 * src/Makefile.am: Adjust.
2744 * lib/Makefile.am: New file.
2746 2000-03-28 Akim Demaille <akim@epita.fr>
2748 * src/getargs.c (usage): Refresh the help message.
2750 2000-03-17 Akim Demaille <akim@epita.fr>
2752 * src/getopt1.c: Updated from textutils 2.0e
2753 * src/getopt.c: Likewise.
2754 * src/getopt.h: Likewise.
2756 2000-03-17 Akim Demaille <akim@epita.fr>
2758 * src/Makefile.am (bison.simple): Fix the awk program: quote only
2759 the file name, not the whole `#line LINE FILE'.
2761 2000-03-17 Akim Demaille <akim@epita.fr>
2763 On syntax errors, report the token on which we choked.
2765 * src/bison.s1 (yyparse): In the label yyerrlab, when
2766 YYERROR_VERBOSE, add yychar in msg.
2768 2000-03-17 Akim Demaille <akim@epita.fr>
2770 * src/reader.c (copy_at): New function.
2771 (copy_guard): Use it.
2772 (copy_action): Use it.
2774 2000-03-17 Akim Demaille <akim@epita.fr>
2776 Be kind to translators, save some useless translations.
2778 * src/main.c (banner): New function.
2779 (fatal_banner): Use it.
2780 (warn_banner): Use it.
2782 2000-03-17 Akim Demaille <akim@epita.fr>
2784 * src/reader.c (copy_definition): Use copy_string and
2785 copy_comment. Removed now unused `match', `ended',
2787 (copy_comment, copy_string): Moved, to be visible from
2790 2000-03-17 Akim Demaille <akim@epita.fr>
2792 * src/reader.c (copy_string): Declare `static inline'. No
2793 problems with inline, since it is checked by configure.
2794 (copy_comment): Likewise.
2796 2000-03-17 Akim Demaille <akim@epita.fr>
2798 * src/reader.c (packsymbols): Formatting changes.
2800 2000-03-17 Akim Demaille <akim@epita.fr>
2802 * src/reader.c (copy_comment): New function, factored out from:
2803 (copy_action): Use it. Removed now unused `match', `ended',
2805 (copy_guard): Likewise.
2807 2000-03-17 Akim Demaille <akim@epita.fr>
2809 * src/reader.c (copy_string): New function, factored out from:
2810 (copy_action): Use it.
2811 (copy_guard): Likewise.
2813 2000-03-17 Akim Demaille <akim@epita.fr>
2815 Change the handling of @s so that they behave exactly like $s.
2816 There is now a pseudo variable @$ (readble and writable), location
2817 of the lhs of the rule (by default ranging from the location of
2818 the first symbol of the rhs, to the location of the last symbol,
2819 or, if the rhs is empty, YYLLOC).
2821 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
2823 (yyparse): When providing a default semantic action, provide a
2824 default location action.
2825 (after the $): No longer change `*YYLSP', just stack YYLOC the
2826 same way you stack YYVAL.
2827 * src/reader.c (read_declarations): Use warns.
2828 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
2829 (copy_action, case '@'): Likewise.
2830 Use a standard error message, to save useless work from
2833 2000-03-17 Akim Demaille <akim@epita.fr>
2835 * src/bison.s1: Formatting and cosmetics changes.
2836 * src/reader.c: Likewise.
2837 Update the Copyright notice.
2839 2000-03-17 Akim Demaille <akim@epita.fr>
2841 * src/bison.s1 (#line): All set to `#line' only, since the
2842 Makefile now handles them.
2844 2000-03-16 Akim Demaille <akim@epita.fr>
2846 * src/output.c (output_rule_data): Output the documentation of
2848 (Copyright notice): Update.
2851 2000-03-16 Akim Demaille <akim@epita.fr>
2853 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
2854 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
2855 One `#if YYDEBUG' remains, since it uses variables which are
2856 defined only if `YYDEBUG != 0'.
2858 2000-03-16 Akim Demaille <akim@epita.fr>
2860 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
2861 and related variables so that the similarities are highlighted.
2863 2000-03-16 Akim Demaille <akim@epita.fr>
2865 * src/bison.s1: Properly indent CPP directives.
2867 2000-03-16 Akim Demaille <akim@epita.fr>
2869 * src/bison.s1: Properly indent the `alloca' CPP section.
2871 2000-03-16 Akim Demaille <akim@epita.fr>
2873 Do not hard code values of directories in `configure.in'.
2874 Update the `configure' tool chain.
2876 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
2878 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
2879 (AC_OUTPUT): Add m4/Makefile.
2880 Bump to bison 1.28a, 1.29 has never been released.
2881 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
2882 handled via src/Makefile.am.
2883 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
2884 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
2886 * Makefile.am (SUBDIRS): Add m4.
2887 (ACLOCAL_AM_FLAGS): New variable.
2888 (AUTOMAKE_OPTIONS): Add check-news.
2889 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
2890 the proper line number and file name.
2891 (DEFS): Propagate the location of bison library files and of the
2893 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
2895 * acinclude.m4: Remove, replaced by the directory m4.
2896 * m4/Makefile.am (EXTRA_DIST): New variable.
2897 * m4/gettext.m4: New file, from the fileutils.
2898 * m4/lcmessage.m4: Likewise
2899 * m4/progtest.m4: Likewise.
2900 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
2902 2000-03-10 Akim Demaille <akim@epita.fr>
2905 Formatting changes of various comments.
2906 Respect the GNU coding standards at various places.
2907 Don't use `_()' when no translation is needed.
2909 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2912 OS/2 honors TMPDIR environment variable.
2914 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2916 * doc/bison.texinfo: Tweaked spelling and grammar.
2918 Removed reference to price of printed copy.
2919 Mention BISON_SIMPLE and BISON_HAIRY.
2921 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2923 * configure.in, NEWS:
2924 Bison 1.29 released.
2926 1999-10-27 Jesse Thilo <jthilo@gnu.org>
2928 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
2929 Added reference card.
2931 1999-07-26 Jesse Thilo <jthilo@gnu.org>
2933 * po/ru.po: Added Russian translation.
2935 1999-07-26 Jesse Thilo <jthilo@gnu.org>
2937 * configure.in: Added Russian translation.
2939 1999-07-06 Jesse Thilo <jthilo@gnu.org>
2941 * configure.in, NEWS, README:
2942 Released version 1.28.
2944 1999-06-14 Jesse Thilo <jthilo@gnu.org>
2947 Squashed redefinition warning on some systems.
2949 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
2950 Have configure build version string instead of relying on ANSI string
2953 1999-06-14 Jesse Thilo <jthilo@gnu.org>
2955 * po/POTFILES.in: Got rid of version.c.
2957 1999-06-14 Jesse Thilo <jthilo@gnu.org>
2959 * acconfig.h, configure.in:
2960 Have configure build version string instead of relying on ANSI string
2963 1999-06-08 Jesse Thilo <jthilo@gnu.org>
2966 Dropped mention of `+' for long-named options.
2968 1999-05-30 Jesse Thilo <jthilo@gnu.org>
2970 * src/files.c: Added <unistd.h> for unlink().
2972 * src/Makefile.am, src/system.h:
2975 1999-05-30 Jesse Thilo <jthilo@gnu.org>
2977 * README: Added a FAQ list.
2979 * configure.in, acconfig.h:
2982 1999-05-30 Jesse Thilo <jthilo@gnu.org>
2984 * doc/FAQ, doc/Makefile.am:
2987 1999-05-19 Jesse Thilo <jthilo@gnu.org>
2989 * src/alloc.h, src/symtab.h, src/version.c:
2990 Protected inclusion of "config.h" with HAVE_CONFIG_H.
2992 1999-04-18 Jesse Thilo <jthilo@gnu.org>
2994 * src/.cvsignore, src/Makefile.am:
2995 Reorganized: sources in `src', documentation in `doc'.
2997 * src/lex.c (literalchar):
2998 fixed the code for escaping double quotes (thanks
3001 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3003 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
3004 Adjusted paths to reflect directory reorganization.
3006 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3008 * doc/.cvsignore, doc/Makefile.am:
3009 Reorganized: sources in `src', documentation in `doc'.
3011 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3014 Updated AC_INIT file to reflect directory reorganization.
3016 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
3017 Reorganized: sources in `src', documentation in `doc'.
3019 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3022 Don't declare calloc() and realloc() if not necessary.
3024 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3026 * configure.in, acconfig.h, acinclude.m4:
3027 Don't declare calloc() and realloc() if not necessary.
3029 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3031 * po/.cvsignore: Added i18n support.
3033 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3035 * acconfig.h, configure.in, Makefile.am:
3038 1999-03-22 Jesse Thilo <jthilo@gnu.org>
3040 * src/bison.s1: Fixed #line numbers.
3042 1999-03-15 Jesse Thilo <jthilo@gnu.org>
3044 * po/es.po, po/fr.po, po/nl.po, po/de.po:
3045 Added PO files from Translation Project.
3047 1999-03-03 Jesse Thilo <jthilo@gnu.org>
3050 Added support for non-ANSI compilers (ansi2knr).
3052 1999-02-16 Jesse Thilo <jthilo@gnu.org>
3054 * configure.in: Bumped version number to 1.27.
3057 Added `bison.simple' to list of files removed by `make distclean'.
3059 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3061 * src/files.c, src/files.h:
3062 Defined locations of parser files in config.h instead of Makefile.
3064 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3066 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
3067 Defined locations of parser files in config.h instead of Makefile.
3069 1999-02-09 Jesse Thilo <jthilo@gnu.org>
3072 Removed inappropriate use of $< macro.
3074 1999-02-05 Jesse Thilo <jthilo@gnu.org>
3076 * po/Makefile.in.in, po/POTFILES.in:
3077 Add `po' directory skeleton.
3079 1999-01-27 Jesse Thilo <jthilo@gnu.org>
3081 * README: Document help-bison list.
3083 * configure.in: Add check for mkstemp().
3085 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3087 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
3088 Hush a few compiler warnings.
3091 Add tryclose(), which verifies that fclose was successful.
3092 Hush a couple of compiler warnings.
3094 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3096 * Makefile.am, OChangeLog:
3097 ChangeLog is now automatically generated. Include the old version as
3100 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3102 * 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:
3105 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3107 * doc/bison.texinfo: Fix formatting glitch.
3109 * doc/bison.texinfo: Update FSF address.
3111 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3113 * acconfig.h: Update FSF address.
3115 1999-01-08 Jesse Thilo <jthilo@gnu.org>
3118 Don't define PACKAGE here, since config.h defines it.
3120 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3122 * src/reader.c: Update copyright date.
3125 Ditch sprintf to statically-sized buffers in fatal/warn functions in
3126 favor of output directly to stderr (avoids buffer overruns).
3128 * src/reader.c: Some checks for premature EOF.
3130 * 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:
3131 Use prototypes if the compiler understands them.
3133 * src/files.c: Honor TMPDIR on Unix hosts.
3134 Use prototypes if the compiler understands them.
3137 Fix a couple of buffer overrun bugs.
3138 Use prototypes if the compiler understands them.
3140 * src/system.h: Include unistd.h and ctype.h.
3141 Use #ifdef instead of #if for NLS symbols.
3143 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3145 * doc/bison.texinfo:
3146 Delete comment "consider using @set for edition number, etc..." since
3147 we now are doing so.
3149 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3152 Use prototypes if the compiler understands them.
3154 * NEWS: Document 1.26 highlights.
3156 * Makefile.am: Require Automake 1.3 or later.
3159 Use prototypes if the compiler understands them.
3161 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3164 Use VERSION symbol from automake for version number.
3166 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3168 * acconfig.h, configure.in, version.cin:
3169 Use VERSION symbol from automake for version number.
3171 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3174 Distribute original version of simple parser (bison.s1), not built
3175 version (bison.simple).
3177 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3179 * doc/bison.texinfo: Add info dir entry.
3181 * doc/bison.texinfo:
3182 Let automake put version number into documentation.
3184 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3186 * src/bison.cld, src/build.com, src/vmshlp.mar:
3187 Add non-RCS files from /gd/gnu/bison.
3189 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3192 Document the BISON_HAIRY and BISON_SIMPLE variables.
3194 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3196 * src/version.c: Build version.c automatically.
3199 Fix token numbering (used to start at 258, not 257).
3201 * src/system.h: Include config.h.
3203 * src/getargs.c: Update bug report address.
3205 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
3206 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
3208 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3211 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3213 * configure.in, version.cin:
3214 Build version.c automatically.
3216 * AUTHORS: Add AUTHORS file.
3218 * README: Update bug report address.
3221 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3223 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
3226 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3228 * doc/bison.texinfo: Clean up some formatting.
3230 1998-05-05 Richard Stallman <rms@gnu.org>
3232 * doc/bison.texinfo:
3233 Explain better why to make a pure parser.
3235 1998-01-05 Richard Stallman <rms@gnu.org>
3237 * src/files.c (openfiles):
3238 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
3239 find a temporary directory, if possible. Do not unlink files while
3242 1997-08-25 Richard Stallman <rms@gnu.org>
3244 * src/reader.c (stack_offset;):
3245 Change some warni to warns.
3247 * src/lex.c (literalchar): Use warns, not warni.
3249 1997-06-28 Richard Stallman <rms@gnu.org>
3251 * src/bison.s1: Add a Bison version comment.
3253 * src/main.c (fatal, warn, berror):
3256 1997-06-28 Richard Stallman <rms@gnu.org>
3258 * Makefile.in (bison_version): New variable.
3259 (dist): Use that variable.
3260 (bison.s1): Substitute the Bison version into bison.simple.
3262 * bison.simple: Add a Bison version comment.
3264 1997-06-18 Richard Stallman <rms@gnu.org>
3266 * src/main.c (fatal, warn, berror):
3267 Make error messages standard.
3268 (toomany): Improve error message text.
3270 * 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:
3271 new.h renamed to alloc.h.
3273 1997-06-18 Richard Stallman <rms@gnu.org>
3275 * Makefile.in: new.h renamed to alloc.h.
3277 1997-05-24 Richard Stallman <rms@gnu.org>
3279 * src/lex.c (literalchar):
3280 Fix the code for escaping \, " and '.
3282 (lex): Avoid trouble when there are many chars
3283 to discard in a char literal with just several chars in it.
3285 1997-05-17 Richard Stallman <rms@gnu.org>
3288 Use malloc, if using alloca is troublesome.
3289 (YYSTACK_USE_ALLOCA): New flag macro.
3290 Define it for some systems and compilers.
3291 (YYSTACK_ALLOC): New macro.
3292 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3293 If it was malloc'd, free it.
3295 1997-05-17 Richard Stallman <rms@gnu.org>
3298 Use malloc, if using alloca is troublesome.
3299 (YYSTACK_USE_ALLOCA): New flag macro.
3300 Define it for some systems and compilers.
3301 (YYSTACK_ALLOC): New macro.
3302 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3303 If it was malloc'd, free it.
3305 1997-04-23 Richard Stallman <rms@gnu.org>
3308 (alloca) [__hpux]: Always define as __builtin_alloca.
3310 1997-04-23 Richard Stallman <rms@gnu.org>
3313 (alloca) [__hpux]: Always define as __builtin_alloca.
3315 1997-04-22 Richard Stallman <rms@gnu.org>
3318 [__hpux]: Include alloca.h (right for HPUX 10)
3319 instead of declaring alloca (right for HPUX 9).
3321 * src/bison.s1 (__yy_memcpy):
3322 Declare arg `count' as unsigned int.
3323 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3325 1997-04-22 Richard Stallman <rms@gnu.org>
3328 [__hpux]: Include alloca.h (right for HPUX 10)
3329 instead of declaring alloca (right for HPUX 9).
3331 * bison.simple (__yy_memcpy):
3332 Declare arg `count' as unsigned int.
3333 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3335 1997-01-03 Richard Stallman <rms@gnu.org>
3337 * src/allocate.c: [__STDC__ or _MSC_VER]:
3338 Declare calloc and realloc to return void *.
3340 1997-01-02 Richard Stallman <rms@gnu.org>
3343 [_MSC_VER]: Include stdlib.h and process.h.
3344 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
3346 * src/main.c (main): Return FAILURE as a value.
3347 (printable_version): Declare arg as int, not char.
3349 1997-01-02 Richard Stallman <rms@gnu.org>
3351 * Makefile.in (dist):
3352 Explicitly check for symlinks, and copy them.
3354 1996-12-19 Richard Stallman <rms@gnu.org>
3357 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
3359 1996-12-18 Paul Eggert <eggert@gnu.org>
3361 * src/bison.s1 (yyparse):
3362 If __GNUC__ and YYPARSE_PARAM are both defined,
3363 declare yyparse to have a void * argument.
3365 1996-12-18 Paul Eggert <eggert@gnu.org>
3367 * bison.simple (yyparse):
3368 If __GNUC__ and YYPARSE_PARAM are both defined,
3369 declare yyparse to have a void * argument.
3371 1996-12-17 Richard Stallman <rms@gnu.org>
3373 * src/reduce.c (nbits): Add some casts.
3375 1996-08-12 Richard Stallman <rms@gnu.org>
3377 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
3379 1996-08-12 Richard Stallman <rms@gnu.org>
3381 * bison.simple: Test _MSDOS as well as _MSDOS_.
3383 1996-07-31 Richard Stallman <rms@gnu.org>
3386 [__sun && __i386]: Include alloca.h.
3388 1996-07-31 Richard Stallman <rms@gnu.org>
3391 [__sun && __i386]: Include alloca.h.
3393 1996-07-30 Richard Stallman <rms@gnu.org>
3395 * src/bison.s1: Comment change.
3397 * src/bison.s1: Test _MSDOS_, not MSDOS.
3399 1996-07-30 Richard Stallman <rms@gnu.org>
3401 * bison.simple: Comment change.
3403 * bison.simple: Test _MSDOS_, not MSDOS.
3405 1996-06-01 Richard Stallman <rms@gnu.org>
3407 * 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:
3408 Insert `_' macro around many string constants.
3411 Insert `_' macro around many string constants.
3413 (main): Call setlocale, bindtextdomain and textdomain.
3415 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
3416 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
3417 [ENABLE_NLS]: Include libintl.h.
3418 [ENABLE_NLS] (gettext): Define.
3419 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
3420 (N_, PACKAGE, LOCALEDIR): New macros.
3422 1996-06-01 Richard Stallman <rms@gnu.org>
3424 * POTFILES.in: New file.
3426 * Makefile.in (allocate.o):
3427 Define target explicitly.
3429 * Makefile.in (CFLAGS): Set to @CFLAGS@.
3430 (LDFLAGS): Set to @LDFLAGS@.
3431 (configure): Run autoconf only if preceding `cd' succeeds.
3432 (bison.s1): Redirect output to temporary file then move the
3433 temporary to the target, rather than redirecting directly to bison.s1.
3434 (clean): Remove config.status and config.log.
3435 (distclean): Don't remove config.status here.
3437 1996-05-12 Richard Stallman <rms@gnu.org>
3440 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3442 1996-05-12 Richard Stallman <rms@gnu.org>
3445 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3447 1996-05-11 Richard Stallman <rms@gnu.org>
3449 * src/bison.s1 (__yy_memcpy):
3450 Really reorder the args, as was supposedly done on Feb 14 1995.
3451 (yyparse): Calls changed accordingly.
3453 1996-05-11 Richard Stallman <rms@gnu.org>
3455 * Makefile.in (dist): Don't use $(srcdir).
3457 * bison.simple (__yy_memcpy):
3458 Really reorder the args, as was supposedly done on Feb 14 1995.
3459 (yyparse): Calls changed accordingly.
3461 1996-01-27 Richard Stallman <rms@gnu.org>
3463 * src/output.c (output_rule_data):
3464 Test YYERROR_VERBOSE in the conditional
3465 around the definition of ttyname.
3467 1995-12-29 Richard Stallman <rms@gnu.org>
3470 Fix line numbers in #line commands.
3472 1995-12-29 Richard Stallman <rms@gnu.org>
3475 Fix line numbers in #line commands.
3477 1995-12-27 Richard Stallman <rms@gnu.org>
3479 * src/bison.s1 (YYPARSE_PARAM_DECL):
3480 In C++, make it always null.
3481 (YYPARSE_PARAM_ARG): New macro.
3482 (yyparse): Use YYPARSE_PARAM_ARG.
3484 1995-12-27 Richard Stallman <rms@gnu.org>
3486 * bison.simple (YYPARSE_PARAM_DECL):
3487 In C++, make it always null.
3488 (YYPARSE_PARAM_ARG): New macro.
3489 (yyparse): Use YYPARSE_PARAM_ARG.
3491 1995-11-29 Richard Stallman <rms@gnu.org>
3493 * doc/bison.texinfo:
3494 Describe literal string tokens, %raw, %no_lines, %token_table.
3496 1995-11-29 Daniel Hagerty <hag@gnu.org>
3498 * doc/bison.texinfo: Fixed update date
3500 1995-10-16 Richard Stallman <rms@gnu.org>
3502 * src/version.c: Version 1.25.
3504 1995-10-16 Richard Stallman <rms@gnu.org>
3506 * NEWS: *** empty log message ***
3508 1995-10-16 Richard Stallman <rms@gnu.org>
3510 * doc/bison.1, doc/bison.rnh:
3513 1995-10-15 Richard Stallman <rms@gnu.org>
3515 * src/vmsgetargs.c, src/getargs.c:
3516 Added -n, -k, and -raw switches.
3517 (noparserflag, toknumflag, rawtoknumflag): New variables.
3519 * src/symtab.h (SALIAS):
3520 New #define for adding aliases to %token.
3521 (struct bucket): Added `alias' field.
3523 * src/reduce.c (reduce_grammar):
3524 Revise error message.
3525 (print_notices): Remove final `.' from error message.
3527 * src/reader.c (reader_output_yylsp):
3529 (readgram): Use `#if 0' around code that accepted %command
3530 inside grammar rules: The documentation doesn't allow it,
3531 and it will fail since the %command processors scan for the next %.
3532 (parse_token_decl): Extended the %token
3533 declaration to allow a multi-character symbol as an alias.
3534 (parse_thong_decl): New function.
3535 (read_declarations): Added %thong declarations.
3536 (read_declarations): Handle NOOP to deal with allowing
3537 % declarations as another means to specify the flags.
3538 (readgram): Allow %prec prior to semantics embedded in a rule.
3539 (skip_to_char, read_declarations, copy_definition)
3540 (parse_token_decl, parse_start_decl, parse_type_decl)
3541 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
3542 (get_type_name, copy_guard, copy_action, readgram)
3543 (get_type, packsymbols): Revised most error messages.
3544 Changed `fatal' to `warnxxx' to avoid aborting for error.
3545 Revised and use multiple warnxxx functions to avoid using VARARGS1.
3546 (read_declarations): Improve the error message for
3547 an invalid character. Do not abort.
3548 (read_declarations, copy_guard, copy_action): Use
3549 printable_version to avoid unprintable characters in printed output.
3550 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
3551 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
3552 Allow the type of a non-terminal can be given
3553 more than once, as long as all specifications give the same type.
3556 (output_headers, output_trailers, output, output_gram)
3557 (output_rule_data): Implement noparserflag variable.
3558 Implement toknumflag variable.
3559 (output): Call reader_output_yylsp to output LTYPESTR.
3561 * src/main.c (main):
3562 If reader sees an error, don't process the grammar.
3563 (fatals): Updated to not use VARARGS1.
3564 (printable_version, int_to_string, warn, warni, warns, warnss)
3565 (warnsss): New error reporting functions. Avoid abort for error.
3568 Added THONG and NOOP for alias processing.
3569 Added SETOPT for the new code that allows setting options with %flags.
3572 Include getopt.h. Add some extern decls.
3573 (safegetc): New function to deal with EOF gracefully.
3574 (literalchar); new function to deal with reading \ escapes.
3575 (lex): Use literalchar.
3576 (lex): Implemented "..." tokens.
3577 (literalchar, lex, parse_percent_token): Made tokenbuffer
3578 always contain the token. This includes growing the token
3579 buffer while reading an integer.
3580 (parse_percent_token): Replaced if-else statement with percent_table.
3581 (parse_percent_token): Added % declarations as another
3582 way to specify the flags -n, -l, and -r. Also added hooks for
3583 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
3584 major changes to files.c.
3585 (lex) Retain in the incoming stream a character following
3587 (skip_white_space, lex): Revised most error messages
3588 and changed fatal to warn to avoid aborting.
3589 (percent_table): Added %thong declarations.
3591 * src/gram.h: Comment changes.
3593 * src/files.c (openfiles, open_extra_files, done):
3595 and actfile file. Handle noparserflag. Both for -n switch.
3597 * src/conflicts.c (resolve_sr_conflict):
3598 Remove use of alloca.
3600 1995-06-01 Jim Meyering <meyering@gnu.org>
3602 * doc/bison.texinfo: *** empty log message ***
3604 1995-05-06 Richard Stallman <rms@gnu.org>
3606 * src/bison.s1: Comment change.
3608 1995-05-06 Richard Stallman <rms@gnu.org>
3610 * bison.simple: Comment change.
3612 1995-05-03 Richard Stallman <rms@gnu.org>
3614 * src/version.c: Version now 1.24.
3616 * src/bison.s1: Change distribution terms.
3618 * src/version.c: Version now 1.23.
3620 1995-05-03 Richard Stallman <rms@gnu.org>
3622 * doc/bison.texinfo:
3623 Rewrite "Conditions for Using Bison".
3624 Update version to 1.24.
3626 1995-05-03 Richard Stallman <rms@gnu.org>
3628 * bison.simple: Change distribution terms.
3630 1995-02-23 Richard Stallman <rms@gnu.org>
3632 * src/files.c: Test __VMS_POSIX as well as VMS.
3634 1995-02-14 Jim Meyering <meyering@gnu.org>
3636 * src/bison.s1 (__yy_memcpy):
3637 Renamed from __yy_bcopy to avoid
3638 confusion. Reverse FROM and TO arguments to be consistent with
3641 1995-02-14 Jim Meyering <meyering@gnu.org>
3643 * bison.simple (__yy_memcpy):
3644 Renamed from __yy_bcopy to avoid
3645 confusion. Reverse FROM and TO arguments to be consistent with
3648 1994-11-10 David J. MacKenzie <djm@gnu.org>
3654 * Makefile.in (DISTFILES): Include NEWS.
3656 * Makefile.in (DISTFILES):
3657 Include install-sh, not install.sh.
3659 * configure.in: Update to Autoconf v2 macro names.
3661 1994-10-05 David J. MacKenzie <djm@gnu.org>
3663 * Makefile.in: fix typo
3665 * Makefile.in (prefix, exec_prefix):
3666 Let configure set them.
3668 1994-09-28 David J. MacKenzie <djm@gnu.org>
3670 * Makefile.in: Set datadir to $(prefix)/share.
3672 1994-09-15 Richard Stallman <rms@gnu.org>
3675 Update copyright notice and GPL version.
3677 1994-09-15 Richard Stallman <rms@gnu.org>
3680 Update copyright notice and GPL version.
3682 1994-07-12 Richard Stallman <rms@gnu.org>
3684 * src/reduce.c, src/reader.c:
3687 1994-05-05 David J. MacKenzie <djm@gnu.org>
3689 * Makefile.in: entered into RCS
3691 1994-03-26 Richard Stallman <rms@gnu.org>
3693 * src/bison.s1: entered into RCS
3695 1994-03-26 Richard Stallman <rms@gnu.org>
3697 * bison.simple: entered into RCS
3699 1994-03-25 Richard Stallman <rms@gnu.org>
3701 * src/main.c: entered into RCS
3703 1994-03-24 Richard Stallman <rms@gnu.org>
3705 * src/conflicts.c: entered into RCS
3707 1994-01-02 Richard Stallman <rms@gnu.org>
3709 * Makefile.in: *** empty log message ***
3711 1993-11-21 Richard Stallman <rms@gnu.org>
3713 * src/bison.s1: *** empty log message ***
3715 1993-11-21 Richard Stallman <rms@gnu.org>
3717 * doc/bison.texinfo: entered into RCS
3719 * doc/bison.texinfo: *** empty log message ***
3721 1993-11-21 Richard Stallman <rms@gnu.org>
3723 * bison.simple: *** empty log message ***
3725 1993-10-25 David J. MacKenzie <djm@gnu.org>
3727 * doc/bison.texinfo: *** empty log message ***
3729 1993-10-19 Richard Stallman <rms@gnu.org>
3731 * src/bison.s1: *** empty log message ***
3733 1993-10-19 Richard Stallman <rms@gnu.org>
3735 * bison.simple: *** empty log message ***
3737 1993-10-14 Richard Stallman <rms@gnu.org>
3739 * src/bison.s1: *** empty log message ***
3741 1993-10-14 Richard Stallman <rms@gnu.org>
3743 * bison.simple: *** empty log message ***
3745 1993-09-14 David J. MacKenzie <djm@gnu.org>
3747 * doc/bison.texinfo: *** empty log message ***
3749 1993-09-13 Noah Friedman <friedman@gnu.org>
3751 * Makefile.in: *** empty log message ***
3753 1993-09-10 Richard Stallman <rms@gnu.org>
3755 * src/conflicts.c: *** empty log message ***
3757 * src/system.h: entered into RCS
3759 1993-09-10 Richard Stallman <rms@gnu.org>
3761 * doc/bison.1: entered into RCS
3763 1993-09-06 Noah Friedman <friedman@gnu.org>
3765 * src/version.c: entered into RCS
3767 1993-09-06 Noah Friedman <friedman@gnu.org>
3769 * Makefile.in: *** empty log message ***
3771 1993-07-30 David J. MacKenzie <djm@gnu.org>
3773 * Makefile.in: *** empty log message ***
3775 1993-07-24 Richard Stallman <rms@gnu.org>
3777 * src/bison.s1: *** empty log message ***
3779 1993-07-24 Richard Stallman <rms@gnu.org>
3781 * bison.simple: *** empty log message ***
3783 1993-07-08 David J. MacKenzie <djm@gnu.org>
3785 * Makefile.in: *** empty log message ***
3787 1993-07-04 Richard Stallman <rms@gnu.org>
3789 * src/bison.s1: *** empty log message ***
3791 1993-07-04 Richard Stallman <rms@gnu.org>
3793 * bison.simple: *** empty log message ***
3795 1993-06-26 David J. MacKenzie <djm@gnu.org>
3797 * src/getargs.c: entered into RCS
3799 1993-06-26 David J. MacKenzie <djm@gnu.org>
3801 * doc/bison.texinfo: *** empty log message ***
3803 * doc/bison.1: New file.
3805 1993-06-25 Richard Stallman <rms@gnu.org>
3807 * src/getargs.c: New file.
3809 1993-06-16 Richard Stallman <rms@gnu.org>
3811 * src/bison.s1: *** empty log message ***
3813 1993-06-16 Richard Stallman <rms@gnu.org>
3815 * bison.simple: *** empty log message ***
3817 1993-06-03 Richard Stallman <rms@gnu.org>
3819 * src/bison.s1: New file.
3821 1993-06-03 Richard Stallman <rms@gnu.org>
3823 * doc/bison.texinfo: *** empty log message ***
3825 1993-06-03 Richard Stallman <rms@gnu.org>
3827 * bison.simple: New file.
3829 1993-05-19 Richard Stallman <rms@gnu.org>
3831 * doc/bison.texinfo: New file.
3833 1993-05-07 Noah Friedman <friedman@gnu.org>
3835 * Makefile.in: *** empty log message ***
3837 1993-04-28 Noah Friedman <friedman@gnu.org>
3839 * src/reader.c: *** empty log message ***
3841 1993-04-23 Noah Friedman <friedman@gnu.org>
3843 * src/alloc.h: entered into RCS
3845 1993-04-20 David J. MacKenzie <djm@gnu.org>
3847 * src/version.c: *** empty log message ***
3849 * src/files.c, src/allocate.c:
3852 * src/reader.c: *** empty log message ***
3854 * src/lex.c: entered into RCS
3856 * src/conflicts.c: New file.
3858 * src/symtab.c: entered into RCS
3860 * src/alloc.h: New file.
3862 * src/LR0.c: entered into RCS
3864 1993-04-18 Noah Friedman <friedman@gnu.org>
3866 * src/reader.c: New file.
3868 * src/version.c: *** empty log message ***
3870 1993-04-18 Noah Friedman <friedman@gnu.org>
3872 * Makefile.in: *** empty log message ***
3874 1993-04-17 Noah Friedman <friedman@gnu.org>
3876 * Makefile.in: *** empty log message ***
3878 1993-04-15 Richard Stallman <rms@gnu.org>
3880 * src/main.c, src/files.c:
3883 1993-04-15 Noah Friedman <friedman@gnu.org>
3885 * configure.in: entered into RCS
3887 * configure.in: *** empty log message ***
3889 * configure.in: New file.
3891 1993-04-14 Richard Stallman <rms@gnu.org>
3893 * Makefile.in: New file.
3895 1993-04-13 Richard Stallman <rms@gnu.org>
3897 * src/version.c: New file.
3899 1993-03-25 Richard Stallman <rms@gnu.org>
3901 * src/output.c: entered into RCS
3903 1992-09-25 Richard Stallman <rms@gnu.org>
3905 * configure.bat: entered into RCS
3907 1992-06-22 Richard Stallman <rms@gnu.org>
3909 * src/vmsgetargs.c: entered into RCS
3911 1992-06-22 Richard Stallman <rms@gnu.org>
3913 * doc/bison.rnh: entered into RCS
3915 1992-04-20 David J. MacKenzie <djm@gnu.org>
3917 * README: entered into RCS
3919 1992-01-22 Richard Stallman <rms@gnu.org>
3921 * src/machine.h: entered into RCS
3923 1991-12-21 Richard Stallman <rms@gnu.org>
3925 * src/lalr.c, src/closure.c:
3928 1991-12-20 Richard Stallman <rms@gnu.org>
3930 * src/state.h: entered into RCS
3932 1991-12-18 Richard Stallman <rms@gnu.org>
3934 * src/print.c, src/nullable.c, src/derives.c:
3937 1991-11-03 David J. MacKenzie <djm@gnu.org>
3939 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
3942 1988-09-09 Richard Stallman <rms@gnu.org>
3944 * src/bison.hairy: entered into RCS
3946 1987-12-16 Richard Stallman <rms@gnu.org>
3948 * REFERENCES: entered into RCS