1 2001-12-05 Akim Demaille <akim@epita.fr>
3 * src/lalr.c (traverse): Use arrays instead of pointers.
5 2001-12-05 Akim Demaille <akim@epita.fr>
7 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
8 the handling of squeue.
9 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
12 2001-12-05 Akim Demaille <akim@epita.fr>
14 Because useless nonterminals are now kept alive (instead of being
15 `destroyed'), we now sometimes examine them, and store information
16 related to them. Hence we need to know their number, and adjust
19 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
21 * src/LR0.c (allocate_itemsets): The memory allocated to
22 `symbol_count' was used for two different purpose: once to count
23 the number of occurrences of each symbol, and later reassigned to
24 `shift_symbol', containing the symbol that can be shifted from a
26 Deobfuscate, i.e., allocate, use and free `symbol_count' here
28 (new_itemsets): Allocate `shift_symbol' here.
29 (allocate_itemsets): symbol_count includes useless nonterminals.
31 (free_storage): Use `free', not `XFREE', for pointers that cannot
35 2001-12-05 Akim Demaille <akim@epita.fr>
37 * src/nullable.c (set_nullable): Deobfuscate the handling of
39 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
42 2001-12-05 Akim Demaille <akim@epita.fr>
44 * src/gram.c, src/gram.h (ritem_print): New.
45 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
46 (This useless function was defined only to work around VMS linkers
47 that can't handle compilation units with variables only).
48 * src/reduce.c (dump_grammar): Use it to trace the construction of
51 2001-12-04 Paul Eggert <eggert@twinsun.com>
53 * src/bison.simple (union yyalloc): Change member names
54 to be the same as the stack names.
55 (yyparse): yyptr is now union yyalloc *, not char *.
56 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
57 and may generate better code on some machines.
58 (yystpcpy): Use prototype if __STDC__ is defined, not just
59 if __cplusplus is defined.
61 2001-11-30 Akim Demaille <akim@epita.fr>
63 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
64 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
65 Gettext doesn't compile cleanly, and dies with -Werror.
66 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
67 Include WARNING_CFLAGS here.
68 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
71 2001-11-27 Paul Eggert <eggert@twinsun.com>
73 * lib/quotearg.h (quotearg_n, quotearg_n_style):
74 First arg is int, not unsigned.
75 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
76 (SIZE_MAX, UINT_MAX): New macros.
77 (quotearg_n_options): Abort if N is negative.
78 Avoid overflow check on hosts where size_t is 64 bits and int
79 is 32 bits, as overflow is impossible there.
80 Fix off-by-one typo that caused unnecessary reallocation.
82 2001-11-29 Paul Eggert <eggert@twinsun.com>
84 Name space cleanup in generated parser.
86 * doc/bison.texinfo (Bison Parser): Discuss system headers
87 and their effect on the user name space.
90 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
91 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
92 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
94 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
95 on user names when possible.
97 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
98 Simplify test for whather <alloca.h> exists.
100 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
102 (<stdio.h>): Include if YYDEBUG.
104 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
105 ! defined (yyoverflow) && ! defined (yymemcpy).
107 (yymemcpy, yyparse): Rename local variables as needed so that
108 they all begin with 'yy'.
110 (yystrlen, yystpcpy): New functions.
112 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
115 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
116 instead of relying on string.h functions. Use YYSTACK_ALLOC
117 and YYSTACK_FREE instead of malloc and free.
119 2001-11-30 Akim Demaille <akim@epita.fr>
121 * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions
122 before their first uses.
123 (YYBISON, YYPURE): Move to the top of the output.
125 2001-11-30 Akim Demaille <akim@epita.fr>
127 * tests/reduce.at (Useless Nonterminals): Fix.
129 2001-11-30 Akim Demaille <akim@epita.fr>
131 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
132 if body instead of `;' to pacify GCC's warnings.
134 2001-11-30 Akim Demaille <akim@epita.fr>
136 Instead of mapping the LHS of unused rules to -1, keep the LHS
137 valid, but flag the rules as invalid.
139 * src/gram.h (rule_t): `useful' is a new member.
140 * src/print.c (print_grammar): Adjust.
141 * src/derives.c (set_derives): Likewise.
142 * src/reader.c (packgram, reduce_output): Likewise.
143 * src/reduce.c (reduce_grammar_tables): Likewise.
144 * tests/reduce.at (Underivable Rules, Useless Rules): New.
146 2001-11-30 Akim Demaille <akim@epita.fr>
148 * src/reduce.c (reduce_output): Formatting changes.
149 * src/print.c (print_results, print_grammar): Likewise.
150 * tests/regression.at (Rule Line Numbers)
151 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
153 2001-11-30 Akim Demaille <akim@epita.fr>
155 * src/reduce.c (nonterminals_reduce): Instead of throwing away
156 useless nonterminals, move them at the end of the symbol arrays.
157 (reduce_output): Adjust.
158 * tests/reduce.at (Useless Nonterminals): Adjust.
160 2001-11-30 Akim Demaille <akim@epita.fr>
162 * src/reduce.c: Various comment/formatting changes.
163 (nonterminals_reduce): New, extracted from...
164 (reduce_grammar_tables): here.
165 (reduce_grammar): Call nonterminals_reduce.
167 2001-11-29 Paul Eggert <eggert@twinsun.com>
169 * src/bison.simple (YYSTACK_REALLOC): Remove.
170 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
171 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
173 (union yyalloc): New type.
174 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
175 an arbitrary restriction on hosts where size_t is wider than int.
177 (yyparse): Don't dump core if alloca or malloc fails; instead, report
178 a parser stack overflow. Allocate just one block of memory for all
179 three stacks, instead of allocating three blocks; this typically is
180 faster and reduces fragmentation.
182 Do not limit the number of items in the stack to a value that fits
183 in 'int', as this is an arbitrary limit on hosts with 64-bit
184 size_t and 32-bit int.
186 2001-11-29 Marc Autret <autret_m@epita.fr>
188 * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead
189 of defining YYERROR_VERBOSE.
190 [AT_DATA]: $4 is now out of C declarations in the prologue.
192 2001-11-28 Marc Autret <autret_m@epita.fr>
194 * src/reader.c (parse_dquoted_param): New.
195 (parse_skel_decl): Use it.
196 * src/lex.h: Add its prototype.
197 * src/lex.c (literalchar): Become not static.
199 2001-11-28 Marc Autret <autret_m@epita.fr>
201 * src/output.h: And put its extern declaration here.
202 * src/output.c (error_verbose): Define here.
203 (prepare): Echo name modification.
204 * src/getargs.h: Clean its extern declaration.
205 * src/getargs.c (error_verbose_flag): Remove.
206 (getargs): Remove case 'e'.
207 * src/options.c (option_table): 'error-verbose' is now seen as simple
211 * src/reader.c (read_declarations): Remove case tok_include.
212 (parse_include_decl): Remove.
213 * src/lex.h (token_t): Remove tok_include.
214 * src/options.c (option_table): 'include' is now a simple command line
217 2001-11-28 Marc Autret <autret_m@epita.fr>
219 * src/bison.simple: Adjust muscle names.
220 * src/muscle_tab.c (muscle_init): Also rename the muscles.
221 * src/output.c (prepare): s/_/-/ for the muscles names.
222 (output_parser): When scanning for a muscle, allow '-' instead of '_'.
224 2001-11-28 Marc Autret <autret_m@epita.fr>
226 * src/bison.simple: Fix debug.
227 [YYERROR_VERBOSE]: Re-integrate as an internal macro.
229 2001-11-28 Akim Demaille <akim@epita.fr>
231 * src/LR0.c (shifts_new): New.
232 (save_shifts, insert_start_shift, augment_automaton): Use it.
234 2001-11-28 Akim Demaille <akim@epita.fr>
236 * src/closure.c (closure): `b' and `ruleno' denote the same value:
239 2001-11-28 Akim Demaille <akim@epita.fr>
241 * src/closure.c (closure): Instead of looping over word in array
242 then bits in words, loop over bits in array.
244 2001-11-28 Akim Demaille <akim@epita.fr>
246 * src/closure.c (closure): No longer optimize the special case
247 where all the bits of `ruleset[r]' are set to 0, to make the code
250 2001-11-28 Akim Demaille <akim@epita.fr>
252 * src/closure.c (closure): `r' and `c' are new variables, used to
253 de-obfuscate accesses to RULESET and CORE.
255 2001-11-28 Akim Demaille <akim@epita.fr>
257 * src/reduce.c (reduce_print): Use ngettext.
258 (dump_grammar): Improve the trace accuracy.
260 2001-11-28 Akim Demaille <akim@epita.fr>
262 * src/reduce.c (dump_grammar): Don't translate trace messages.
264 2001-11-28 Akim Demaille <akim@epita.fr>
266 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
267 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
268 as all tags are free'ed afterwards.
271 2001-11-27 Paul Eggert <eggert@twinsun.com>
273 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
274 use alloca when we didn't want to, and vice versa.
276 2001-11-27 Marc Autret <autret_m@epita.fr>
278 * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle
280 * src/output.c (prepare): Remove its update.
282 2001-11-27 Marc Autret <autret_m@epita.fr>
284 * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition.
287 2001-11-27 Marc Autret <autret_m@epita.fr>
289 * src/bison.simple: Remove YYERROR_VERBOSE using.
292 * src/output.c (prepare): Give its final value.
293 * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'.
294 * src/getargs.h: Add its extern declaration.
295 * src/getargs.c (error_verbose_flag): New int.
296 (getargs): Update to catch new case.
297 * src/options.c (option_table): 'error-verbose' is a new option.
300 2001-11-27 Akim Demaille <akim@epita.fr>
302 * src/system.h: Use intl/libgettext.h.
303 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
305 2001-11-27 Akim Demaille <akim@epita.fr>
307 * tests/torture.at (Exploding the Stack Size with Malloc):
308 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
310 2001-11-27 Akim Demaille <akim@epita.fr>
312 * src/files.c: Include error.h.
313 Reported by Hans Aberg.
315 2001-11-26 Marc Autret <autret_m@epita.fr>
317 * src/reader.c (parse_include_decl): New, not yet implemented.
318 (read_declarations): Add case tok_include.
319 * src/getargs.h (include): Add its extern definition.
320 * src/getargs.c (include): New const char *.
321 (getargs): Add case '-I'.
322 * src/options.c (option_table): Add include as command line and
324 * src/lex.h (token_t): Add tok_include.
326 2001-11-26 Akim Demaille <akim@epita.fr>
328 * src/reader.c (readgram): Make sure rules for mid-rule actions
329 have a lineno equal to that of their host rule.
330 Reported by Hans Aberg.
331 * tests/regression.at (Rule Line Numbers): New.
333 2001-11-26 Akim Demaille <akim@epita.fr>
335 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
338 2001-11-26 Akim Demaille <akim@epita.fr>
340 * src/complain.c, src/complain.h (error): Remove, provided by
343 2001-11-26 Akim Demaille <akim@epita.fr>
345 * src/reader.c (read_declarations): Don't abort on tok_illegal,
346 issue an error message.
347 * tests/regression.at (Invalid %directive): New.
348 Reported by Hans Aberg.
350 2001-11-26 Akim Demaille <akim@epita.fr>
352 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
353 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
355 2001-11-26 Akim Demaille <akim@epita.fr>
357 * src/conflicts.c (conflicts_print): Don't complain at all when
358 there are no reduce/reduce conflicts, and as many shift/reduce
359 conflicts as expected.
360 * tests/regression.at (%expect right): Adjust.
362 2001-11-23 Akim Demaille <akim@epita.fr>
364 * lib/alloca.c: Update, from fileutils.
366 2001-11-23 Akim Demaille <akim@epita.fr>
368 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
370 2001-11-23 Akim Demaille <akim@epita.fr>
372 * src/system.h: Include alloca.h.
373 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
375 2001-11-23 Akim Demaille <akim@epita.fr>
377 * src/print_graph.c (print_actions): Remove `rule', unused.
378 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
379 pacify GCC's signed < unsigned warnings.
380 * src/closure.c (itemsetsize): Likewise.
381 * src/reader.c (symbol_list_new): Static.
383 2001-11-23 Akim Demaille <akim@epita.fr>
385 Attaching lineno to buckets is stupid, since only one copy of each
386 symbol is kept, only the line of the first occurrence is kept too.
388 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
389 * src/reader.c (rline_allocated): Remove, unused.
390 (symbol_list): Have a `line' member.
391 (symbol_list_new): New.
393 * src/print.c (print_grammar): Output the rule line numbers.
394 * tests/regression.at (Solved SR Conflicts)
395 (Unresolved SR Conflicts): Adjust.
396 Reported by Hans Aberg.
398 2001-11-22 Marc Autret <autret_m@epita.fr>
400 * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0.
402 2001-11-22 Marc Autret <autret_m@epita.fr>
404 * src/muscle_tab.c (muscle_init): Remove initialization of
406 * src/output.c (output_master_parser): Do it here.
408 2001-11-20 Akim Demaille <akim@epita.fr>
411 * configure.in (ALL_LINGUAS): Adjust.
412 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
413 longer contains strings to translate.
415 2001-11-19 Akim Demaille <akim@epita.fr>
417 * src/conflicts.c (conflicts_print): Add a missing \n.
419 2001-11-19 Akim Demaille <akim@epita.fr>
421 * src/nullable.c (nullable_print): New.
422 (set_nullable): Call it when tracing.
423 Better locality of variables.
425 2001-11-19 Akim Demaille <akim@epita.fr>
427 * src/print.c (print_actions): Better locality of variables.
429 2001-11-19 Akim Demaille <akim@epita.fr>
431 * src/derives.c (print_derives): Fix and enrich.
432 * src/closure.c (print_fderives): Likewise.
434 2001-11-19 Akim Demaille <akim@epita.fr>
436 * src/closure.c (itemsetend): Remove, replaced with...
439 2001-11-19 Akim Demaille <akim@epita.fr>
441 * src/LR0.c (kernel_end): Remove, replaced with...
444 2001-11-19 Akim Demaille <akim@epita.fr>
446 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
449 2001-11-19 Akim Demaille <akim@epita.fr>
451 * src/closure.c (closure): Use arrays instead of pointers to clarify.
453 2001-11-19 Akim Demaille <akim@epita.fr>
455 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
457 * src/LR0.c: Likewise.
458 (allocate_itemsets): Use arrays instead of pointers to clarify.
460 2001-11-19 Akim Demaille <akim@epita.fr>
462 * src/getargs.c (statistics_flag): Replace with...
464 (longopts): Accept --trace instead of --statistics.
465 * src/getargs.h, src/options.c: Adjust.
466 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
467 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
469 2001-11-19 Akim Demaille <akim@epita.fr>
471 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
472 pointers to clarify the code.
473 (save_reductions, save_shifts): Factor common parts of alternatives.
475 2001-11-19 Akim Demaille <akim@epita.fr>
477 * src/LR0.c (new_state, get_state): Complete TRACE code.
478 * src/closure.c: Include `reader.h' to get `tags', needed by the
480 Rename the conditional DEBUG as TRACE.
481 Output consistently TRACEs to stderr, not stdout.
482 * src/derives.c: Likewise.
483 * src/reduce.c: (inaccessable_symbols): Using if is better style
485 Use `#if TRACE' instead of `#if 0' for tracing code.
487 2001-11-19 Akim Demaille <akim@epita.fr>
489 * src/system.h (LIST_FREE, shortcpy): New.
490 * src/LR0.c: Use them.
491 * src/output.c (free_itemsets, free_reductions, free_shifts):
492 Remove, replaced by LIST_FREE.
494 2001-11-19 Akim Demaille <akim@epita.fr>
496 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
497 (REDUCTIONS_ALLOC): New.
498 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
501 2001-11-19 Akim Demaille <akim@epita.fr>
503 * src/LR0.c (new_state): Complete trace code.
504 * src/nullable.c (set_nullable): Don't translate traces.
506 2001-11-19 Akim Demaille <akim@epita.fr>
508 * src/print_graph.c (print_core): Better locality of variables.
509 * src/print.c (print_core): Likewise.
511 2001-11-19 Akim Demaille <akim@epita.fr>
513 * src/vcg.c: You do the output, so you are responsible of the
514 handling of VCG syntax, in particular: use quotearg.
515 * src/print_graph.c: Don't.
516 (print_actions): Don't output the actions as part of the nodes,
517 since that's the job of the edges.
518 (print_state): Don't output by hand: fill the node description,
519 and ask for its output.
521 2001-11-19 Akim Demaille <akim@epita.fr>
523 * src/bison.simple (yyparse): When verbosely reporting an error,
524 no longer put additional quotes around token names.
525 * tests/calc.at: Adjust.
527 2001-11-19 Akim Demaille <akim@epita.fr>
529 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
530 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
531 * src/output.c: Adjust.
533 2001-11-19 Akim Demaille <akim@epita.fr>
535 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
537 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
539 2001-11-19 Akim Demaille <akim@epita.fr>
541 * src/gram.h (rule_t): New.
543 (rrhs, rlhs): Remove, part of state_t.
544 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
545 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
546 * src/reader.c, src/reduce.c: Adjust.
548 2001-11-19 Akim Demaille <akim@epita.fr>
550 * src/reader.c (symbols_output): New, extracted from...
554 2001-11-19 Akim Demaille <akim@epita.fr>
556 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
557 (maxrhs): this new function.
559 2001-11-19 Akim Demaille <akim@epita.fr>
561 * src/lalr.c (F): New macro to access the variable F.
564 2001-11-19 Akim Demaille <akim@epita.fr>
566 * src/lalr.h (LA): New macro to access the variable LA.
567 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
568 * src/lalr.c: Adjust.
570 2001-11-19 Akim Demaille <akim@epita.fr>
572 * src/lalr.c (initialize_LA): Only initialize LA. Let...
573 (set_state_table): handle the `lookaheads' members.
575 2001-11-19 Akim Demaille <akim@epita.fr>
577 * src/lalr.h (lookaheads): Removed array, whose contents is now
579 (state_t): this structure.
580 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
583 2001-11-19 Akim Demaille <akim@epita.fr>
585 * src/lalr.h (consistent): Removed array, whose contents is now
587 (state_t): this structure.
588 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
591 2001-11-19 Akim Demaille <akim@epita.fr>
593 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
594 contents are now members of...
595 (state_t): this structure.
596 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
599 2001-11-19 Akim Demaille <akim@epita.fr>
601 * src/lalr.h (state_t): New.
602 (state_table): Be a state_t * instead of a core **.
603 (accessing_symbol): Remove, part of state_t.
604 * src/lalr.c: Adjust.
605 (set_accessing_symbol): Merge into...
606 (set_state_table): this.
607 * src/print_graph.c, src/conflicts.c: Adjust.
609 2001-11-14 Akim Demaille <akim@epita.fr>
611 * tests/calc.at, tests/output.at, tests/regression.at,
612 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
613 now the tests are run in private dirs, therefore AC_CLEANUP and
614 family can be simplified to 0-ary.
615 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
616 use abs. path to find config.h.
617 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
618 stderr, there can be way too much random noise.
619 Instead pass -Werror to GCC and rely on the exit status.
620 Reported by Wolfram Wagner.
622 2001-11-14 Akim Demaille <akim@epita.fr>
624 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
625 defined only if yyoverflow is defined, to avoid `warning: unused
627 Reported by The Test Suite.
629 2001-11-14 Akim Demaille <akim@epita.fr>
631 * src/print.c: Include reduce.h.
632 Reported by Hans Aberg.
634 2001-11-14 Akim Demaille <akim@epita.fr>
636 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
637 Revert a previous patch: these are really const.
638 * src/conflicts.c (conflict_report): Additional useless pair of
639 braces to pacify GCC's warnings for `if () if () {} else {}'.
640 * src/lex.c (parse_percent_token): Replace equal_offset with
643 Be sure to strdup `arg' when used, since there is no reason for
644 token_buffer not to change.
646 2001-11-14 Akim Demaille <akim@epita.fr>
648 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
650 * src/main.c (main): Use them.
651 Suggested by Hans Aberg.
653 2001-11-12 Akim Demaille <akim@epita.fr>
655 * src/system.h (ngettext): Now that we use ngettext, be sure to
656 provide a default definition when NLS are not used.
658 2001-11-12 Akim Demaille <akim@epita.fr>
660 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
661 Use @kbd to denote user input.
662 (Language and Grammar): ANSIfy the example.
663 Adjust its layout for info/notinfo.
664 (Location Tracking Calc): Output error messages to stderr.
665 Output locations in a more GNUtically correct way.
666 Fix a couple of Englishos.
667 Adjust @group/@end group pairs.
669 2001-11-12 Akim Demaille <akim@epita.fr>
671 %expext was not functioning at all.
673 * src/conflicts.c (expected_conflicts): Set to -1.
674 (conflict_report): Use ngettext.
675 (conflicts_print): Check %expect and make its violation an error.
676 * doc/bison.texinfo (Expect Decl): Adjust.
677 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
678 * tests/regression.at (%expect not enough, %expect right)
679 (%expect too much): New.
681 2001-11-12 Akim Demaille <akim@epita.fr>
683 * tests/regression.at (Conflicts): Rename as...
684 (Unresolved SR Conflicts): this.
685 (Solved SR Conflicts): New.
687 2001-11-12 Akim Demaille <akim@epita.fr>
689 * src/reduce.c (print_results): Rename as...
690 (reduce_output): This.
691 Output to OUT, passed as argument, instead of output_obstack.
692 (dump_grammar): Likewise.
695 (reduce_grammar): No longer call reduce_output, since...
696 * src/print.c (print_results): do it.
697 * src/main.c (main): Call reduce_free;
699 2001-11-12 Akim Demaille <akim@epita.fr>
701 * src/conflicts.c (print_reductions): Accept OUT as argument.
702 Output to it, not to output_obstack.
703 * src/print.c (print_actions): Adjust.
705 2001-11-12 Akim Demaille <akim@epita.fr>
707 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
708 the result instead of using...
709 (src_total, rrc_total, src_count, rrc_count): Remove.
710 (any_conflicts): Remove.
711 (print_conflicts): Split into...
712 (conflicts_print, conflicts_output): New.
713 * src/conflicts.h: Adjust.
714 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
715 * src/print.c (print_grammar): Issue `\n' between two rules.
716 * tests/regression.at (Conflicts): New.
717 Reported by Tom Lane.
719 2001-11-12 Akim Demaille <akim@epita.fr>
721 * tests/regression.at (Invalid input): Remove, duplicate with
722 ``Invalid input: 1''.
724 2001-11-12 Akim Demaille <akim@epita.fr>
726 * tests/torture.at (AT_DATA_STACK_TORTURE)
727 (Exploding the Stack Size with Alloca)
728 (Exploding the Stack Size with Malloc): New.
730 2001-11-12 Akim Demaille <akim@epita.fr>
732 * src/bison.simple (YYSTACK_REALLOC): New.
733 (yyparse) [!yyoverflow]: Use it and free the old stack.
734 Reported by Per Allansson.
736 2001-11-12 Pascal Bart <pascal.bart@epita.fr>
738 * src/bison.simple: Define type yystype instead of YYSTYPE, and
739 define CPP macro, which substitute YYSTYPE by yystype.
740 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
741 with yyltype/YYLTYPE. This allows inclusion of the generated
742 header within the parser if the compiler, such as GGC, accepts
743 multiple equivalent #defines.
746 2001-11-05 Akim Demaille <akim@epita.fr>
748 * src/reader.c (symbols_output): New, extracted from...
752 2001-11-05 Akim Demaille <akim@epita.fr>
754 * src/lex.c (parse_percent_token): s/quotearg/quote/.
756 2001-11-05 Akim Demaille <akim@epita.fr>
758 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
761 2001-11-05 Akim Demaille <akim@epita.fr>
763 * src/options.h (struct option_table_struct): set_flags is void*.
764 * src/options.c (longopts): Support `--output' and `%output'.
766 * src/lex.h (tok_setopt): Remove, replaced with...
767 (tok_intopt, tok_stropt): these new guys.
768 * src/lex.c (getopt.h): Not needed.
769 (token_buffer, unlexed_token_buffer): Not const.
770 (percent_table): Promote `-' over `_' in directive names.
771 Active `%name-prefix', `file-prefix', and `output'.
772 (parse_percent_token): Accept possible arguments to directives.
773 Promote `-' over `_' in directive names.
775 2001-11-04 Akim Demaille <akim@epita.fr>
777 * doc/bison.texinfo (Decl Summary): Split the list into
778 `directives for grammars' and `directives for bison'.
780 Add description of `%name-prefix', `file-prefix', and `output'.
781 Promote `-' over `_' in directive names.
782 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
783 Simplify the description of `--name-prefix'.
784 Promote `-' over `_' in directive names.
785 Promote `--output' over `--output-file'.
786 Fix the description of `--defines'.
787 * tests/output.at: Exercise %file-prefix and %output.
789 2001-11-02 Akim Demaille <akim@epita.fr>
791 * doc/refcard.tex: Update.
793 2001-11-02 Akim Demaille <akim@epita.fr>
795 * src/symtab.h (SUNDEF): New.
796 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
797 stand for `uninitialized', instead of 0.
798 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
799 * src/lex.c (lex): Adjust.
801 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
803 Let yylex return it instead of a plain 0.
804 Reported by Dick Streefland.
806 2001-11-02 Akim Demaille <akim@epita.fr>
808 * tests/regression.at (Mixing %token styles): New test.
810 2001-11-02 Akim Demaille <akim@epita.fr>
812 * src/reader.c (parse_thong_decl): Formatting changes.
813 (token_translations_init): New, extracted from...
817 2001-11-01 Akim Demaille <akim@epita.fr>
819 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
820 Check that `9foo.y' produces correct cpp guards.
821 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
825 2001-11-01 Akim Demaille <akim@epita.fr>
827 * tests/regression.at (Invalid input: 2): New.
828 * src/lex.c (unlexed_token_buffer): New.
829 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
833 2001-11-01 Akim Demaille <akim@epita.fr>
835 * tests/calc.at: Catch up with 1.30.
836 * configure.in: Bump to 1.49a.
837 Adjust to newer Autotest.
839 2001-10-19 Pascal Bart <pascal.bart@epita.fr>
841 * src/conflicts.c: Move global variables rrc_total and src_total ...
842 (print_conflicts): here.
843 * src/output.c (output): Free global variable user_toknums.
844 * src/lex.c (token_obstack): Become static.
846 2001-10-18 Akim Demaille <akim@epita.fr>
848 * tests/atlocal.in (GCC): Add.
849 * tests/calc.at: s/m4_match/m4_bmatch/.
850 s/m4_patsubst/m4_bpatsubst/.
851 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
852 * configure.in: AC_SUBST(GCC).
854 2001-10-14 Marc Autret <autret_m@epita.fr>
856 * src/options.c (create_long_option_table): Fix.
858 2001-10-10 Akim Demaille <akim@epita.fr>
860 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
862 2001-10-04 Akim Demaille <akim@epita.fr>
864 * src/reader.c (parse_union_decl): Push the caracters in
865 union_obstack, not attrs_obstack.
867 2001-10-04 Akim Demaille <akim@epita.fr>
869 Merge in the branch 1.29.
871 * src/reader.c (packsymbols): Use a temporary obstack for
872 `%%tokendef', since output_stack is already used elsewhere.
874 2001-10-02 Akim Demaille <akim@epita.fr>
878 2001-10-02 Akim Demaille <akim@epita.fr>
882 2001-10-02 Akim Demaille <akim@epita.fr>
884 * tests/regression.at (Invalid CPP headers): New.
885 From Alexander Belopolsky.
886 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
888 2001-10-02 Akim Demaille <akim@epita.fr>
890 * tests/regression.at (Invalid input): New.
891 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
894 2001-10-02 Akim Demaille <akim@epita.fr>
896 * tests/calc.at: Now that --debug works, the tests must be adjusted.
898 2001-10-02 Akim Demaille <akim@epita.fr>
900 * src/output.c (output_parser): Assert `skeleton'.
901 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
905 2001-10-01 Marc Autret <autret_m@epita.fr>
907 * src/lex.h: Echo modifications.
908 * src/lex.c (unlex): Parameter is now token_t.
911 2001-10-01 Marc Autret <autret_m@epita.fr>
913 * src/main.c: Include lex.h.
916 2001-09-29 Akim Demaille <akim@epita.fr>
918 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
920 2001-09-28 Akim Demaille <akim@epita.fr>
922 * tests/testsuite.at: Update to newer Autotest.
923 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
925 2001-09-27 Akim Demaille <akim@epita.fr>
927 Position independent wrapper.
929 * tests/bison: Remove.
930 * tests/bison.in: New.
931 * configure.in: Adjust.
933 2001-09-27 Paul Eggert <eggert@twinsun.com>
935 Port quotearg fixes from tar 1.13.24.
937 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
939 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
940 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
942 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
943 * m4/mbrtowc.m4: New file.
944 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
945 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
947 2001-09-27 Akim Demaille <akim@epita.fr>
951 2001-09-27 Akim Demaille <akim@epita.fr>
955 2001-09-25 Akim Demaille <akim@epita.fr>
957 * src/system.h: Include `xalloc.h'.
958 Remove it from the C files.
959 * src/files.c (output_files): Free the obstacks.
960 * src/lex.c (init_lex): Rename as...
963 * src/main.c (main): Use it.
965 2001-09-24 Marc Autret <autret_m@epita.fr>
967 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
968 to output informations in fout (FILE*).
969 (open_graph, close_graph): Likewise.
970 (output_graph, output_edge, output_node): Likewise.
971 * src/vcg.h: Update function prototypes.
972 * src/print_graph.c (print_graph): Open output graph file.
973 (print_actions): Adjust.
974 * src/files.h: Remove extern declaration.
975 * src/files.c: Remove graph_obstack declaration.
976 (open_files): Remove graph_obstack initialization.
977 (output_files): Remove graph_obstack saving.
979 2001-09-24 Marc Autret <autret_m@epita.fr>
981 * src/files.c (compute_output_file_names): Fix.
983 2001-09-24 Marc Autret <autret_m@epita.fr>,
984 Akim Demaille <akim@epita.fr>
986 * src/reader.c (reader): Remove call to free_symtab ().
987 * src/main.c (main): Call it here.
989 * src/conflicts.c (initialize_conflicts): Rename as...
990 (solve_conflicts): this.
991 * src/print.c (print_core, print_actions, print_state)
992 (print_grammar): Dump to a file instead a `output_obstack'.
993 (print_results): Dump `output_obstack', and then proceed with the
995 * src/files.c (compute_output_file_names, close_files): New.
996 (output_files): Adjust.
997 * src/main.c (main): Adjust.
999 2001-09-23 Marc Autret <autret_m@epita.fr>
1001 * src/files.c (compute_header_macro): Computes header macro name
1002 from spec_defines_file when given.
1004 2001-09-23 Marc Autret <autret_m@epita.fr>
1006 * src/files.c (output_files): Add default extensions.
1008 2001-09-22 Akim Demaille <akim@epita.fr>
1010 * src/conflicts.c (finalize_conflicts): Rename as...
1011 (free_conflicts): this.
1013 2001-09-22 Akim Demaille <akim@epita.fr>
1015 * src/gram.c (gram_free): Rename back as...
1017 (output_token_translations): Free `token_translations'.
1018 * src/symtab.c (free_symtab): Free the tag field.
1020 2001-09-22 Akim Demaille <akim@epita.fr>
1022 Remove `translations' as it is always set to true.
1024 * src/gram.h: Adjust.
1025 * src/reader.c (packsymbols, parse_token_decl): Adjust
1026 * src/print.c (print_grammar): Adjust.
1027 * src/output.c (output_token_translations): Adjust.
1028 * src/lex.c (lex): Adjust.
1029 * src/gram.c: Be sure the set pointers to NULL.
1030 (dummy): Rename as...
1033 2001-09-22 Akim Demaille <akim@epita.fr>
1035 * configure.in: Invoke AM_LIB_DMALLOC.
1036 * src/system.h: Use dmalloc.
1037 * src/LR0.c: Be sure to have pointers initialized to NULL.
1038 (allocate_itemsets): Allocate kernel_items only if needed.
1040 2001-09-22 Akim Demaille <akim@epita.fr>
1042 * configure.in: Bump to 1.29b.
1043 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
1044 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
1045 need xmalloc.c in calc.y.
1048 2001-09-21 Akim Demaille <akim@epita.fr>
1051 * Makefile.maint, config/config.guess, config/config.sub,
1052 * config/missing: Update from masters.
1053 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
1055 * configure.in (ALL_LINGUAS): Add `tr'.
1057 2001-09-21 Akim Demaille <akim@epita.fr>
1059 * tests/Makefile.am (package.m4): Move to...
1060 ($(srcdir)/$(TESTSUITE)): here.
1062 2001-09-20 Akim Demaille <akim@epita.fr>
1064 * src/complain.c: No longer try to be standalone: use system.h.
1065 Don't assume __STDC__ is defined to 1. Just test if it is defined.
1066 * src/complain.h: Likewise.
1067 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
1068 Remove the unused variable `n'.
1069 From Albert Chin-A-Young.
1071 2001-09-18 Marc Autret <autret_m@epita.fr>
1073 * doc/bison.1: Update.
1074 * doc/bison.texinfo (Bison Options): Update --defines and --graph
1076 (Option Cross Key): Update.
1079 2001-09-18 Marc Autret <autret_m@epita.fr>
1081 * tests/regression.at: New test (comment in %union).
1083 2001-09-18 Marc Autret <autret_m@epita.fr>
1085 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
1087 Reported by Keith Browne.
1089 2001-09-18 Marc Autret <autret_m@epita.fr>
1091 * tests/output.at: Add tests for --defines and --graph.
1093 2001-09-18 Marc Autret <autret_m@epita.fr>
1095 * tests/output.at: Removes tests of %{header,src}_extension features.
1097 2001-09-18 Akim Demaille <akim@epita.fr>
1099 * tests/Makefile.am (package.m4): New.
1100 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
1101 (_AT_CHECK_CALC_ERROR): Likewise.
1102 Factor the `, ' part of verbose error messages.
1104 2001-09-18 Marc Autret <autret_m@epita.fr>
1106 * src/getargs.c (longopts): Declare --defines and --graph as options
1107 with optional arguments.
1108 * src/files.h: Add extern declarations.
1109 * src/files.c (spec_graph_file, spec_defines_file): New.
1110 (output_files): Update.
1111 Remove CPP-outed code.
1113 2001-09-18 Marc Autret <autret_m@epita.fr>
1115 Turn off %{source,header}_extension feature.
1117 * src/files.c (compute_exts_from_gf): Update.
1118 (compute_exts_from_src): Update.
1119 (output_files): CPP-out useless code.
1120 * src/files.h: Remove {header,source}_extension extern declarations.
1121 * src/reader.c (parse_dquoted_param): CPP-out.
1122 (parse_header_extension_decl): Remove.
1123 (parse_source_extension_decl): Remove.
1124 (read_declarations): Remove cases tok_{hdrext,srcext}.
1125 * src/lex.c (percent_table): Remove {header,source}_extension entries.
1126 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
1128 2001-09-10 Akim Demaille <akim@epita.fr>
1130 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
1131 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
1132 (AT_CHECK_OUTPUT): this.
1133 Merely check ls' exit status, its output is useless.
1135 2001-09-10 Akim Demaille <akim@epita.fr>
1137 * tests/calc.at: Use m4_match.
1138 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
1140 2001-09-10 Marc Autret <autret_m@epita.fr>,
1141 Akim Demaille <akim@epita.fr>
1143 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
1145 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
1147 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
1148 * src/lex.h: Adjust prototype.
1149 (token_t): Add `tok_undef'.
1150 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
1151 (parse_percent_token): Now returns token_t.
1152 Add default statement in switch.
1153 (lex): Separate `c' as an input variable, from the token_t result
1155 (unlexed): Is a token_t.
1157 2001-09-10 Akim Demaille <akim@epita.fr>
1159 * configure.in: Bump to 1.29a.
1161 2001-09-07 Akim Demaille <akim@epita.fr>
1165 2001-08-30 Akim Demaille <akim@epita.fr>
1167 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
1168 * m4/atconfig.m4: Remove.
1169 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
1171 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
1172 m4_if, m4_patsubst, and m4_regexp.
1173 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
1174 `input' file instead of echo.
1176 2001-08-29 Akim Demaille <akim@epita.fr>
1180 2001-08-29 Akim Demaille <akim@epita.fr>
1184 2001-08-29 Paul Eggert <eggert@twinsun.com>
1186 * src/bison.simple (yyparse): Don't take the address of an
1187 item before the start of an array, as that doesn't conform to
1190 2001-08-29 Robert Anisko <anisko_r@epita.fr>
1192 * doc/bison.texinfo (Location Tracking Calc): New node.
1194 2001-08-29 Paul Eggert <eggert@twinsun.com>
1196 * src/output.c (output): Do not define const, as this now
1197 causes more problems than it cures.
1199 2001-08-29 Akim Demaille <akim@epita.fr>
1201 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
1203 Be sure to tag the `detailmenu'.
1205 2001-08-29 Akim Demaille <akim@epita.fr>
1207 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
1208 download in a tmp dir.
1210 2001-08-28 Marc Autret <autret_m@epita.fr>
1212 * config/depcomp: New file.
1214 2001-08-28 Marc Autret <autret_m@epita.fr>
1216 * doc/bison.1 (mandoc): Adjust.
1217 From Juan Manuel Guerrero.
1219 2001-08-28 Marc Autret <autret_m@epita.fr>
1221 * src/print_graph.c (print_state): Fix.
1223 2001-08-27 Marc Autret <autret_m@epita.fr>
1225 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
1227 Echo modifications to the functions prototypes.
1228 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
1230 2001-08-27 Marc Autret <autret_m@epita.fr>
1232 * src/vcg.c: Include `xalloc.h'.
1233 (add_colorentry): New.
1234 (add_classname): New.
1235 (add_infoname): New.
1236 * src/vcg.h: Add new prototypes.
1238 2001-08-27 Akim Demaille <akim@epita.fr>
1240 * Makefile.maint: Sync. again with CVS Autoconf.
1242 2001-08-27 Akim Demaille <akim@epita.fr>
1244 * Makefile.maint: Formatting changes.
1245 (po-update, cvs-update, update): New targets.
1248 2001-08-27 Akim Demaille <akim@epita.fr>
1250 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
1251 * Makefile.maint: Sync. with CVS Autoconf.
1253 2001-08-27 Marc Autret <autret_m@epita.fr>
1255 * src/vcg.h (struct infoname_s): New.
1256 (struct colorentry_s): New.
1257 (graph_s): New fields {vertical,horizontal}_order in structure.
1258 Add `infoname' field.
1259 Add `colorentry' field;
1260 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
1261 (G_HORIZONTAL_ORDER): New.
1263 (G_COLORENTRY): New.
1264 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
1265 Add output of `infoname'.
1266 Add output of `colorentry'.
1268 2001-08-27 Marc Autret <autret_m@epita.fr>
1270 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
1271 This one shadowed a global parameter.
1273 2001-08-24 Marc Autret <autret_m@epita.fr>
1275 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
1276 instead of `unsigned'.
1277 (print_state): Do not call obstack_object_size () in obstack_grow ()
1278 to avoid macro variables shadowing.
1280 2001-08-23 Marc Autret <autret_m@epita.fr>
1282 * src/lex.c (percent_table): Typo: s/naem/name/.
1284 Normalize new options declarations.
1286 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
1288 * tests/suite.at: Exercise %header_extension and %source_extension.
1290 2001-08-16 Marc Autret <autret_m@epita.fr>
1292 * src/reader.c (parse_dquoted_param): New.
1293 (parse_header_extension_decl): Use it.
1294 (parse_source_extension_decl): Likewise.
1296 2001-08-16 Marc Autret <autret_m@epita.fr>
1298 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
1299 (get_xxxx_str): Use assert () instead of complain ().
1300 Remove return invokations in default cases.
1301 (get_decision_str): Modify default behaviour. Remove second argument.
1302 Echo modifications on calls.
1303 (output_graph): Fix.
1305 2001-08-16 Marc Autret <autret_m@epita.fr>
1307 * src/getargs.c (usage): Update with ``-g, --graph''.
1309 2001-08-16 Marc Autret <autret_m@epita.fr>
1311 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
1312 (Option Cross Key): Likewise.
1313 * doc/bison.1: Update.
1315 2001-09-25 Pascal Bart <pascal.bart@epita.fr>
1317 * src/output.c (output_master_parser): Don't finish action_obstack.
1318 (output_parser): Don't care about the muscle action, here.
1319 (prepare): Copy the action_obstack in the action muscle.
1320 (output): Free action_obstack.
1322 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
1324 * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which
1325 will contain `%union' declaration.
1326 (parse_union_decl): Delete #line directive output.
1327 (parse_union_decl): Substitute /attrs_obstack/union_obstack for all
1328 informations about %union.
1329 (parse_union_decl): Copy the union_obstack in the muscle stype.
1330 * src/bison.simple: Add new #line directive.
1331 Add typdef %%stype YYSTYPE.
1333 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
1335 * src/bison.simple: Add new `#line' directive.
1337 2001-09-22 Pascal Bart <pascal.bart@epita.fr>
1339 * src/bison.simple: New `#line' directive.
1340 * src/output.c (output_parser): Support new dynamic muscle input_line.
1342 2001-09-22 Marc Autret <autret_m@epita.fr>
1344 * src/output.c (output_master_parser): New.
1345 (output_parser): Be more re-entrant.
1347 2001-09-21 Marc Autret <autret_m@epita.fr>
1349 * src/reader.c (copy_definition, parse_union_decl): Update and use
1351 (copy_action): Likewise.
1352 Use obstack_1grow ().
1353 * src/muscle_tab.c (muscle_init): Add muscle `linef'.
1355 2001-09-21 Marc Autret <autret_m@epita.fr>
1357 * src/options.c (option_table): Adjust.
1358 * src/lex.c (parse_percent_token): Fix.
1360 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
1362 * src/options.c (symtab.h): Include it, need by lex.h.
1364 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
1366 * src/lex.c (parse_percent_token): Change type of variable `tx', which
1367 is now an option_table_struct*.
1368 (option_strcmp): New function option_strcmp.
1369 (parse_percent_token): Call option_strcmp.
1370 * src/getargs.c (xalloc.h, options.h): Include it.
1371 (getargs): Call create_long_option_table.
1372 (getargs): Free longopts at the end of the function.
1373 (shortopts): Move in options.c.
1374 * src/options.c (create_long_option_table): New function. Convert
1375 information from option_table to option structure.
1376 * src/reader.c (options.h): Include it.
1378 * src/Makefile.am: Adjust.
1379 * src/options.c (option_table): Create from longopts and percent_table.
1380 * src/getargs.c (longopts): Delete.
1381 * src/lex.c (struct percent_table_struct): Delete.
1382 (percent_table): Delete.
1383 (options.h): Include it.
1384 * src/options.c: Create.
1385 * src/options.h: Create.
1386 Declare enum opt_access_e.
1387 Define struct option_table_struct.
1389 2001-09-20 Marc Autret <autret_m@epita.fr>
1391 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
1394 2001-09-19 Pascal Bart <pascal.bart@epita.fr>
1396 * src/bison.simple: s/%%filename/%%skeleton.
1397 * src/muscle_tab.c (getargs.h): Include it.
1398 (muscle_init): Insert new muscle skeleton.
1400 2001-09-18 Pascal Bart <pascal.bart@epita.fr>
1402 * src/output.c (output_parser): Delete unused variable actions_dumped.
1404 2001-09-07 Pascal Bart <pascal.bart@epita.fr>
1406 * src/output.c (output): Delete call to reader_output_yylsp.
1407 * src/reader.c (reader): Likewise.
1408 * src/reader.h: Delete declaration of reader_output_yylsp.
1410 2001-09-02 Marc Autret <autret_m@epita.fr>
1412 * src/reader.c: Include muscle_tab.h.
1413 (parse_union_decl): Update.
1414 (parse_macro_decl): Rename parse_muscle_decl.
1415 Update to use renamed functions and variable.
1416 (read_declarations, copy_action, read_additionnal_code, : Updated
1417 with correct variables and functions names.
1418 (packsymbols, reader): Likewise.
1420 * src/reader.h (muscle_obstack): Extern declaration update.
1422 * src/output.c: Include muscle_tab.h
1423 In all functions using macro_insert, change by using muscle_insert ().
1424 (macro_obstack): Rename muscle_obstack.
1425 Echo modifications in the whole file.
1426 (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT.
1427 (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING.
1428 (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX.
1430 * src/muscle_tab.h: Update double inclusion macros.
1431 (macro_entry_s): Rename muscle_entry_s.
1434 * src/muscle_tab.c: Include muscle_tab.h.
1435 Rename macro_tabble to muscle_table.
1436 (mhash1, mhash2, mcmp): Use muscle_entry.
1437 (macro_init): Rename muscle_init. Update.
1438 (macro_insert): Rename muscle_insert. Update.
1439 (macro_find): Rename muscle_find. Update.
1441 * src/main.c: Include muscle_tab.h.
1442 (main): Call muscle_init ().
1443 * src/Makefile.am (bison_SOURCES): Echo modifications.
1445 2001-09-02 Marc Autret <autret_m@epita.fr>
1447 Now the files macro_tab.[ch] are named muscle_tab.[ch].
1449 * src/muscle_tab.c, src/muscle_tab.h: Add files.
1451 2001-09-02 Marc Autret <autret_m@epita.fr>
1453 * src/macrotab.c, src/macrotab.h: Remove.
1455 2001-09-01 Pascal Bart <pascal.bart@epita.fr>
1457 * src/reader.c (copy_guard): Use muscle to specify the `#line'
1460 2001-09-01 Marc Autret <autret_m@epita.fr>
1462 * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set
1463 to an explicit value to activate the feature. We do it here.
1465 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
1467 * src/output.c (prepare): Delete the `filename' muscule insertion.
1468 * src/reader.c (copy_action): Use `filename' muscule with `#line'.
1469 (parse_union_decl): Likewise.
1470 * src/macrotab.c (macro_init): Initialize filename by infile.
1472 2001-08-31 Marc Autret <autret_m@epita.fr>
1474 * src/bison.simple (YYLSP_NEEDED): New definition.
1475 * src/output.c (prepare): Add macro insertion of `locations_flag'
1477 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
1479 * src/output.c (prepare): Delete insertion of previous muscles,
1480 and insert the `prefix' muscles.
1481 * src/macrotab.c (macro_init): Likewise.
1482 (macro_init): Initialization prefix directive by `yy'.
1483 * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval,
1484 %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar,
1485 yylval, yydebug, yyerror, yynerrs and yyparse.
1486 New directive `#define' to substitute yydebug, ... with option
1489 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
1491 * src/main.c (main): Standardize.
1492 * src/output.c (output_table_data, output_parser): Likewise.
1493 * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise.
1495 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr>
1497 * src/reader.c (read_additionnal_code): Rename %%user_code to
1499 * src/output.c (output): Rename %%declarations to %%prologue.
1500 * src/bison.simple: Echo modifications.
1502 2001-08-31 Marc Autret <autret_m@epita.fr>
1504 * src/reader.c (readgram): CleanUp.
1505 (output_token_defines): Likewise.
1506 (packsymbols): Likewise.
1508 * src/output.c (output): CPP-out useless code.
1510 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
1512 * src/reader.c (reader): Delete obsolete call to function
1513 output_trailers and output_headers.
1514 * src/output.h: Remove obsolete functions prototypes of output_headers
1515 and output_trailers.
1517 2001-08-30 Pascal Bart <pascal.bart@epita.fr>
1519 * src/main.c: Include macrotab.h.
1520 * src/macrotab.h (macro_entry_s): Constify fields.
1521 Adjust functions prototypes.
1522 * src/macrotab.c (macro_insert): Constify key and value.
1523 (macro_find): Constify key.
1524 (macro_insert): Include 'xalloc.h'
1525 (macro_insert): Use XMALLOC.
1526 (macro_find): Constify return value.
1527 * src/output.c (output_table_data): Rename table to table_data.
1528 (output_parser): Constify macro_key, macro_value.
1530 2001-08-30 Marc Autret <autret_m@epita.fr>
1532 * src/reader.c (parse_skel_decl): New.
1533 (read_declarations): Add case `tok_skel', call parse_skel_decl ().
1534 * src/lex.h (token_t): New token `tok_skel'.
1535 * src/lex.c (percent_table): Add skeleton option entry.
1538 2001-08-29 Marc Autret <autret_m@epita.fr>
1540 * src/bison.simple: Add %%user_code directive at the end.
1541 * src/reader.c (read_additionnal_code): New.
1543 * src/output.c (output_program): Remove.
1546 2001-08-28 Marc Autret <autret_m@epita.fr>
1548 * src/output.c (output_actions): Clean up.
1549 (output_gram): CPP-out useless code.
1550 * src/reader.c (reader): Clean up, CPP-out useless code.
1552 2001-08-28 Pascal Bart <pascal.bart@epita.fr>
1554 * src/output.c (output): Copy attrs_obstack in the '%%definitions'
1556 * src/bison.simple: Add `%%definitions'.
1558 2001-08-28 Marc Autret <autret_m@epita.fr>
1560 * config/depcomp: New file.
1562 2001-08-27 Paul Eggert <eggert@twinsun.com>
1564 * src/bison.simple (yyparse): Don't take the address of an
1565 item before the start of an array, as that doesn't conform to
1568 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
1570 * src/output.c (output): Remove the initialization of the macro
1571 obstack. It was done too late here.
1573 * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was
1575 (reader): Initialize the macro obstack here, since we need it to grow
1576 '%define' directives.
1578 * src/reader.h: Declare the macro obstack as extern.
1580 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
1582 * src/output.c (output_parser): Fix. Store single '%' characters in
1583 the output obstack instead of throwing them away.
1585 2001-08-27 Akim Demaille <akim@epita.fr>
1587 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
1589 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1591 * lib/Makefile.am: Adjust.
1593 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1595 * src/bison.simple: Update and add '%%' directives.
1597 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1599 * src/reader.c (reader): Remove calls to 'output_headers' and
1600 'output_trailers'. Remove some C output.
1601 (readgram): Disable a piece of code that was writing a default
1602 definition for 'YYSTYPE'.
1603 (reader_output_yylsp): Remove.
1604 (packsymbols): Output token defintions to a macro.
1605 (copy_definition): Disable C output.
1607 * src/reader.c (parse_macro_decl): New function used to parse macro
1609 (copy_string2): Put the body of copy_string into this new function.
1610 Add a parameter to let the caller choose whether he wants to copy the
1611 string delimiters or not.
1612 (copy_string): Be a simple call to copy_string2 with the last argument
1614 (read_declarations): Add case for macro definition.
1615 (copy_identifier): New.
1616 (parse_macro_decl): Read macro identifiers using copy_identifier
1619 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1621 * src/output.c (prepare): Add prefixed names.
1622 (output_parser): Output semantic actions.
1623 (output_parser): Fix bug on '%%line' directives.
1625 * src/output.c (output_headers): Remove. The C code printed by this
1626 function should now be in the skeletons.
1627 (output_trailers): Remove.
1628 (output): Disable call to 'reader_output_yylsp'.
1629 (output_rule_data): Do not output tables to the table obstack.
1631 * src/output.c: Remove some C dedicated output.
1632 Improve the use of macro and output obstacks.
1633 (output_defines): Remove.
1635 * src/output.c (output_token_translations): Associate 'translate'
1636 table with a macro. No output to the table obstack.
1637 (output_gram): Same for 'rhs' and 'prhs'.
1638 (output_stos): Same for 'stos'.
1639 (output_rule_data): Same for 'r1' and 'r2'.
1640 (token_actions): Same for 'defact'.
1641 (goto_actions): Same for 'defgoto'.
1642 (output_base): Same for 'pact' and 'pgoto'.
1643 (output_table): Same for 'table'.
1644 (output_check): Same for 'check'.
1646 * src/output.c (output_table_data): New function.
1647 (output_short_table): Remove.
1648 (output_short_or_char_table): Remove.
1650 * src/output.c (output_parser): Replace most of the skeleton copy code
1651 with something new. Skeletons are now processed character by character
1652 rather than line by line, and Bison looks for '%%' macros. This is the
1653 first step in making Bison's output process (a lot) more flexible.
1654 (output_parser): Use the macro table.
1656 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1658 * src/main.c (main): Initialize the macro table.
1660 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1662 * src/lex.c (percent_table): Add tok_define.
1663 * src/lex.h: Add tok_define.
1665 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1667 * src/macrotab.c: New file.
1668 * src/macrotab.h: New file.
1669 * src/Makefile.am: Update.
1671 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
1673 * lib/hash.c: New file.
1674 * lib/hash.h: New file.
1675 * lib/Makefile.am: Update.
1677 2001-08-15 Akim Demaille <akim@epita.fr>
1681 2001-08-15 Marc Autret <autret_m@epita.fr>
1683 * src/reader.c (readgram): Indent output macro YYSTYPE.
1684 (packsymbols): Likewise.
1685 (output_token_defines): Likewise.
1686 * src/files.c: Standardize.
1687 (compute_header_macro): New.
1688 (defines_obstack_save): New. Use compute_header_macro.
1689 (output_files): Update. Use defines_obstack_save.
1691 2001-08-15 Akim Demaille <akim@epita.fr>
1693 * doc/bison.texinfo (Table of Symbols): Document
1696 2001-08-15 Akim Demaille <akim@epita.fr>
1698 * missing: Update from CVS Automake.
1699 * config/config.guess, config/config.sub, config/texinfo.tex:
1700 Update from gnu.org.
1702 2001-08-15 Akim Demaille <akim@epita.fr>
1704 * Makefile.maint: Sync with CVS Autoconf.
1706 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
1708 * doc/bison.texinfo: Include GNU Free Documentation License from
1710 * doc/fdl.texi: Add to package.
1712 2001-08-14 Marc Autret <autret_m@epita.fr>
1714 Turn on %{source,header}_extension features.
1716 * src/lex.c (percent_table): Un-CPP out header_extension and
1718 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
1719 (compute_exts_from_src): Remove conditions. It restores priorities
1722 2001-08-14 Marc Autret <autret_m@epita.fr>
1724 * src/files.c (compute_base_names): Add extensions computing when
1725 `--file-prefix' used.
1726 Standardize function calls.
1728 2001-08-13 Marc Autret <autret_m@epita.fr>
1730 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
1731 defining it (defined but null disables alloca).
1733 2001-08-13 Marc Autret <autret_m@epita.fr>
1735 * src/bison.simple (_yy_memcpy): CPP reformat.
1737 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
1739 * tests/atconfig.in (CPPFLAGS): Fix.
1741 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
1743 * doc/bison.texinfo: Include GNU General Public License from
1745 * doc/gpl.texi: Add to package.
1747 2001-08-10 Marc Autret <autret_m@epita.fr>
1749 * src/print_graph.h: Fix.
1750 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
1752 2001-08-10 Akim Demaille <akim@epita.fr>
1754 * src/system.h: Provide default declarations for stpcpy, strndup,
1757 2001-08-10 Robert Anisko <anisko_r@epita.fr>
1759 * doc/bison.texinfo (Locations): Update @$ stuff.
1761 2001-08-09 Robert Anisko <anisko_r@epita.fr>
1763 * src/bison.simple (YYLLOC_DEFAULT): Update.
1766 2001-08-08 Marc Autret <autret_m@epita.fr>
1768 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
1769 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
1770 Reported by Fabrice Bauzac.
1772 2001-08-08 Marc Autret <autret_m@epita.fr>
1774 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
1775 * src/vcg.c (output_node): Fix.
1776 * src/vcg.h: Cleanup.
1777 * src/print_graph.c: Add comments.
1778 (node_output_size): New global variable. Simplify the formatting of
1779 the VCG graph output.
1780 (print_actions): Unused code is now used. It notifies the final state
1781 and no action states in the VCG graph. It also give the reduce actions.
1782 The `shift and goto' edges are red and the `go to state' edges are
1784 Get the current node name and node_obstack by argument.
1785 (node_obstack): New variable.
1786 (print_state): Manage node_obstack.
1787 (print_core): Use node_obstack given by argument.
1788 A node is not only computed here but in print_actions also.
1789 (print_graph): CPP out useless code instead of commenting it.
1791 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
1793 * tests/atconfig.in (CPPFLAGS): Fix.
1795 2001-08-07 Akim Demaille <akim@epita.fr>
1797 * src/print_graph.c (quote): New.
1798 (print_core): Use it.
1800 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
1802 * src/vcg.c (complain.h): Include it.
1803 Unepitaize `return' invocations.
1804 [NDEBUG] (main): Remove.
1805 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
1806 * src/files.c (open_files): Initialize graph_obstack.
1807 * src/print_graph.c (print_actions): CPP out useless code.
1808 (print_core): Don't output the last `\n' in labels.
1810 * src/files.c (output_files): Output the VCG file.
1811 * src/main.c (main): Invoke print_graph ();
1813 2001-08-06 Marc Autret <autret_m@epita.fr>
1815 Automaton VCG graph output.
1816 Using option ``-g'' or long option ``--graph'', you can generate
1817 a gram_filename.vcg file containing a VCG description of the LALR (1)
1818 automaton of your grammar.
1820 * src/main.c: Call to print_graph() function.
1821 * src/getargs.h: Update.
1822 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
1823 (graph_flag): New flag.
1825 (getargs): Add case `g'.
1826 * src/files.c (graph_obstack): New obstack struct.
1827 (open_files): Initialize new obstack.
1828 (output_files): Saves graph_obstack if required.
1829 * src/files.h (graph_obstack): New extern declaration.
1830 * src/Makefile.am: Add new source files.
1832 2001-08-06 Marc Autret <autret_m@epita.fr>
1834 * src/print_graph.c, src/print_graph.h (graph): New.
1835 * src/vcg.h: New file.
1836 * src/vcg.c: New file, VCG graph handling.
1838 2001-08-06 Marc Autret <autret_m@epita.fr>
1840 Add of %source_extension and %header_extension which specify
1841 the source or/and the header output file extension.
1843 * src/files.c (compute_base_names): Remove initialisation of
1844 src_extension and header_extension.
1845 (compute_exts_from_gf): Update.
1846 (compute_exts_from_src): Update.
1847 (output_files): Update.
1848 * src/reader.c (parse_header_extension_decl): New.
1849 (parse_source_extension_decl): New.
1850 (read_declarations): New case statements for the new tokens.
1851 * src/lex.c (percent_table): Add entries for %source_extension
1852 and %header_extension.
1853 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
1855 2001-08-06 Marc Autret <autret_m@epita.fr>
1857 * configure.in: Bump to 1.28c.
1858 * doc/bison.texinfo: Texinfo thingies.
1860 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
1862 * tests/atconfig.in (CPPFLAGS): Add.
1863 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
1865 2001-08-03 Akim Demaille <akim@epita.fr>
1869 2001-08-03 Akim Demaille <akim@epita.fr>
1871 * tests/Makefile.am (check-local): Ship testsuite.
1872 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
1875 2001-08-03 Akim Demaille <akim@epita.fr>
1877 * configure.in: Try using -Wformat when compiling.
1879 2001-08-03 Akim Demaille <akim@epita.fr>
1881 * configure.in: Bump to 1.28b.
1883 2001-08-03 Akim Demaille <akim@epita.fr>
1885 * src/complain.c: Adjust strerror_r portability issues.
1887 2001-08-03 Akim Demaille <akim@epita.fr>
1891 2001-08-03 Akim Demaille <akim@epita.fr>
1893 * src/getargs.c, src/getarg.h (skeleton)): Constify.
1894 * src/lex.c (literalchar): Avoid name clashes on `buf'.
1895 * src/getargs.c: Include complain.h.
1896 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
1897 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
1899 2001-08-03 Akim Demaille <akim@epita.fr>
1901 * src/reader.c (readgram): Display hidden chars in error messages.
1903 2001-08-03 Akim Demaille <akim@epita.fr>
1905 Update to gettext 0.10.39.
1907 2001-08-03 Akim Demaille <akim@epita.fr>
1909 * lib/strspn.c: New.
1911 2001-08-01 Marc Autret <autret_m@epita.fr>
1913 * doc/bison.texinfo: Update.
1914 * doc/bison.1 (mandoc): Update.
1915 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
1916 * src/files.c: Support output files extensions computing.
1917 (src_extension): New static variable.
1918 (header_extension): New static variable.
1920 (get_extension_index): New function, gets the index of an extension
1921 filename in a string.
1922 (compute_exts_from_gf): New function, computes extensions from the
1923 grammar file extension.
1924 (compute_exts_from_src): New functions, computes extensions from the
1925 C source file extension, file given by ``-o'' option.
1926 (compute_base_names): Update.
1927 (output_files): Update.
1929 2001-08-01 Robert Anisko <anisko_r@epita.fr>
1931 * doc/bison.texi: Document @$.
1932 (Locations): New section.
1934 2001-07-18 Akim Demaille <akim@epita.fr>
1936 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
1937 * config/prev-version.txt, config/move-if-change: New.
1938 * Makefile.am: Adjust.
1940 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
1942 * src/bison.simple (yyparse): Suppress warning `comparaison
1943 between signed and unsigned'.
1945 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
1947 * src/getargs.h (raw_flag): Remove.
1948 * src/getargs.c: Die on `-r'/`--raw'.
1949 * src/lex.c (parse_percent_token): Die on `%raw'.
1950 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
1951 * tests/calc.at: Suppress test with option `--raw'.
1953 2001-07-14 Akim Demaille <akim@epita.fr>
1956 * configure.in: Require Autoconf 2.50.
1957 Update to gettext 0.10.38.
1959 2001-03-16 Akim Demaille <akim@epita.fr>
1961 * doc/bison.texinfo: ANSIfy the examples.
1963 2001-03-16 Akim Demaille <akim@epita.fr>
1965 * getargs.c (skeleton): New variable.
1966 (longopts): --skeleton is a new option.
1967 (shortopts, getargs): -S is a new option.
1968 * getargs.h: Declare skeleton.
1969 * output.c (output_parser): Use it.
1971 2001-03-16 Akim Demaille <akim@epita.fr>
1973 * m4/strerror_r.m4: New.
1974 * m4/error.m4: Run AC_FUNC_STRERROR_R.
1975 * lib/error.h, lib/error.c: Update.
1977 2001-03-16 Akim Demaille <akim@epita.fr>
1979 * src/getargs.c (longopts): Clean up.
1981 2001-02-21 Akim Demaille <akim@epita.fr>
1983 * src/reader.c (gensym): `gensym_count' is your own.
1984 Use a static buf to create the symbol name, as token_buffer is no
1987 2001-02-08 Akim Demaille <akim@epita.fr>
1989 * src/conflicts.c (conflict_report): Be sure not to append to res
1990 between two calls, which could happen if both first sprintf were
1991 skipped, but not the first cp += strlen.
1993 2001-02-08 Akim Demaille <akim@epita.fr>
1995 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
1996 New, from fileutils 4.0.37.
1997 * configure.in: Require Autoconf 2.49c. I took some time before
1998 making this decision. This is the only way out for portability
1999 issues in Bison, it would mean way too much duplicate effort to
2000 import in Bison features implemented in 2.49c since 2.13.
2001 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
2003 2001-02-02 Akim Demaille <akim@epita.fr>
2005 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
2006 * lib/xalloc.h, lib/xmalloc.c: Update.
2008 2001-01-19 Akim Demaille <akim@epita.fr>
2010 Get rid of the ad hoc handling of token_buffer in the scanner: use
2013 * src/lex.c (token_obstack): New.
2014 (init_lex): Initialize it. No longer call...
2015 (grow_token_buffer): this. Remove it.
2016 Adjust all the places which used it to use the obstack.
2018 2001-01-19 Akim Demaille <akim@epita.fr>
2020 * src/lex.h: Rename all the tokens:
2021 s/\bENDFILE\b/tok_eof/g;
2022 s/\bIDENTIFIER\b/tok_identifier/g;
2024 Let them be enums, not #define, to ease debugging.
2025 Adjust all the code.
2027 2001-01-18 Akim Demaille <akim@epita.fr>
2029 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
2030 * src/lex.c (maxtoken, grow_token_buffer): Static.
2032 2001-01-18 Akim Demaille <akim@epita.fr>
2034 Since we now use obstacks, more % directives can be enabled.
2036 * src/lex.c (percent_table): Also accept `%yacc',
2037 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
2039 Handle the actions for `%semantic_parser' and `%pure_parser' here,
2040 instead of returning a token.
2041 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
2042 * src/reader.c (read_declarations): Adjust.
2043 * src/files.c (open_files): Don't call `compute_base_names', don't
2044 compute `attrsfile' since they depend upon data which might be
2045 *in* the input file now.
2046 (output_files): Do it here.
2047 * src/output.c (output_headers): Document the fact that this patch
2048 introduces a guaranteed SEGV for semantic parsers.
2049 * doc/bison.texinfo: Document them.
2050 * tests/suite.at: Exercise these %options.
2052 2000-12-20 Akim Demaille <akim@epita.fr>
2054 Also handle the output file (--verbose) with obstacks.
2056 * files.c (foutput): Remove.
2057 (output_obstack): New.
2058 Adjust all dependencies.
2059 * src/conflicts.c: Return a string.
2060 * src/system.h (obstack_grow_string): Rename as...
2061 (obstack_sgrow): this. Be ready to work with non literals.
2062 (obstack_fgrow4): New.
2064 2000-12-20 Akim Demaille <akim@epita.fr>
2066 * src/files.c (open_files): Fix the computation of short_base_name
2067 in the case of `-o foo.tab.c'.
2069 2000-12-20 Akim Demaille <akim@epita.fr>
2071 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
2072 (copy_dollar): Now that everything uses obstacks, get rid of the
2075 2000-12-20 Akim Demaille <akim@epita.fr>
2077 * src/files.c (open_files): Actually the `.output' file is based
2078 on the short_base_name, not base_name.
2079 * tests/suite.at (Checking output file names): Adjust.
2081 2000-12-20 Akim Demaille <akim@epita.fr>
2083 * src/bison.s1: Remove, we now use directly...
2084 * src/bison.simple: this.
2085 * src/Makefile.am: Use pkgdata instead of data.
2087 2000-12-20 Akim Demaille <akim@epita.fr>
2089 * src/files.c (guard_obstack): New.
2090 (open_files): Initialize it.
2091 (output_files): Dump it...
2092 * src/files.h: Export it.
2093 * src/reader.c (copy_guard): Use it.
2095 2000-12-19 Akim Demaille <akim@epita.fr>
2097 * src/files.c (outfile, defsfile, actfile): Removed as global
2099 (open_files): Don't compute them.
2100 (output_files): Adjust.
2101 (base_name, short_base_name): Be global.
2102 Adjust dependencies.
2104 2000-12-19 Akim Demaille <akim@epita.fr>
2106 * src/files.c (strsuffix): New.
2107 (stringappend): Be just like strcat but allocate.
2108 (base_names): Eve out from open_files.
2109 Try to simplify the rather hairy computation of base_name and
2111 (open_files): Use it.
2112 * tests/suite.at (Checking output file names): New test.
2114 2000-12-19 Akim Demaille <akim@epita.fr>
2116 * src/system.h (obstack_grow_literal_string): Rename as...
2117 (obstack_grow_string): this.
2118 * src/output.c (output_parser): Recognize `%% actions' instead of
2120 * src/bison.s1: s/$/%% actions/.
2121 * src/bison.hairy: Likewise.
2123 2000-12-19 Akim Demaille <akim@epita.fr>
2125 * src/output.c (output_parser): Compute the `#line' lines when
2127 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
2128 Suggested by Hans Aberg.
2130 2000-12-19 Akim Demaille <akim@epita.fr>
2132 Let the handling of the skeleton files be local to the procedures
2135 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
2137 (fparser, open_extra_files): Remove.
2138 (open_files, output_files): Don't take care of fparser.
2139 * src/files.h: Adjust.
2140 * src/output.c (output_parser): Open and close the file to the
2142 * src/reader.c (read_declarations): When %semantic_parser, open
2145 2000-12-19 Akim Demaille <akim@epita.fr>
2147 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
2148 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
2150 2000-12-19 Akim Demaille <akim@epita.fr>
2152 * src/files.c (open_files): Yipee! We no longer need all the code
2153 looking for `/tmp' since we have no tmp file.
2155 2000-12-19 Akim Demaille <akim@epita.fr>
2157 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
2159 * src/files.c (open_files): Less dependency on MSDOS etc.
2161 2000-12-14 Akim Demaille <akim@epita.fr>
2163 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
2164 Provide a default definition.
2165 Use it when executing the default @ action.
2166 * src/reader.c (reader_output_yylsp): No longer include
2167 `timestamp' and `text' in the default YYLTYPE.
2169 2000-12-12 Akim Demaille <akim@epita.fr>
2171 * src/reader.c (copy_definition, parse_union_decl, copy_action)
2172 (copy_guard): Quote the file names.
2173 Reported by Laurent Mascherpa.
2175 2000-12-12 Akim Demaille <akim@epita.fr>
2177 * src/output.c (output_headers, output_program, output): Be sure
2178 to escape special characters when outputting filenames.
2179 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
2180 (output_headers): Don't depend on them, Use ACTSTR.
2182 2000-11-17 Akim Demaille <akim@epita.fr>
2184 * lib/obstack.h: Formatting changes.
2185 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
2186 prevents type checking.
2187 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
2188 cast the value to (void *): assigning a `foo *' to a `void *'
2190 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
2191 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
2194 2000-11-17 Akim Demaille <akim@epita.fr>
2196 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
2198 (suite.m4, regression.m4, calc.m4): these.
2199 * tests/atgeneral.m4: Update from CVS Autoconf.
2201 2000-11-17 Akim Demaille <akim@epita.fr>
2203 * tests/regression.m4 (%union and --defines): New test,
2204 demonstrating a current bug in the obstack implementation.
2206 2000-11-17 Akim Demaille <akim@epita.fr>
2208 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
2210 Use them to declare the variables which are global or local to
2213 2000-11-17 Akim Demaille <akim@epita.fr>
2215 * acconfig.h: Remove, no longer used.
2217 2000-11-07 Akim Demaille <akim@epita.fr>
2219 * src: s/Copyright (C)/Copyright/g.
2221 2000-11-07 Akim Demaille <akim@epita.fr>
2223 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
2225 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
2227 2000-11-07 Akim Demaille <akim@epita.fr>
2229 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
2230 Merge in a single CPP if/else.
2232 2000-11-07 Akim Demaille <akim@epita.fr>
2234 * src/output.c (output): Remove useless variables.
2235 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
2236 argument `data' for consistency with the prototypes.
2238 (obstack_copy, obstack_copy0): Rename the second argument as
2239 `address' for consistency. Qualify it `const'.
2240 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
2241 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
2242 `const' their input argument (`data' or `address').
2243 Adjust the corresponding macros to include `const' in casts.
2245 2000-11-03 Akim Demaille <akim@epita.fr>
2247 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
2248 s/PFILE1/BISON_HAIRY/.
2249 Adjust dependencies.
2251 2000-11-03 Akim Demaille <akim@epita.fr>
2253 For some reason, this was not applied.
2255 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2256 `unlink': it's no longer used.
2258 2000-11-03 Akim Demaille <akim@epita.fr>
2260 * src/files.c (skeleton_find): New function, eved out of...
2261 (open_files, open_extra_files): here.
2263 2000-11-03 Akim Demaille <akim@epita.fr>
2267 * src/files.c (obstack_save): New function.
2268 (done): Rename as...
2269 (output_files): this.
2271 * src/main.c (main): Don't use `atexit' to register `done', since
2272 it no longer has to remove tmp files, just call `output_files'
2273 when there are no errors.
2275 2000-11-02 Akim Demaille <akim@epita.fr>
2277 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
2278 `unlink': it's no longer used.
2279 * src/files.h: Formatting changes.
2281 2000-11-02 Akim Demaille <akim@epita.fr>
2283 Remove the last uses of mktemp and unlink/delete.
2285 * src/files.c (fdefines, ftable): Removed.
2286 (defines_ostack, table_obstack): New.
2287 Adjust dependencies of the former into uses of the latter.
2288 * src/output.c (output_short_or_char_table, output_short_table):
2289 Convert to using obstacks.
2290 * src/reader.c (copy_comment2): Accept one FILE * and two
2292 (output_token_defines, reader_output_yylsp): Use obstacks.
2293 * src/system.h (obstack_fgrow3): New.
2295 2000-11-01 Akim Demaille <akim@epita.fr>
2297 Change each use of `fattrs' into a use of `attrs_obstack'.
2299 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
2300 * src/files.c (fattrs): Remove.
2301 (attrs_obstack): New.
2302 Adjust all dependencies.
2303 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
2305 2000-11-01 Akim Demaille <akim@epita.fr>
2308 Change each use of `faction' into a use of `action_obstack'.
2310 * lib/obstack.h, lib/obstack.c: New files.
2311 * src/files.c (faction): Remove.
2312 (action_obstack): New.
2313 Adjust all dependencies.
2315 2000-10-20 Akim Demaille <akim@epita.fr>
2317 * lib/quote.h (PARAMS): New macro. Use it.
2319 2000-10-16 Akim Demaille <akim@epita.fr>
2321 * src/output.c (output_short_or_char_table): New function.
2322 (output_short_table, output_token_translations): Use it.
2323 (goto_actions): Use output_short_table.
2325 2000-10-16 Akim Demaille <akim@epita.fr>
2327 * src/symtab.c (bucket_new): New function.
2330 * src/output.c (output_short_table): New argument to display the
2331 comment associated with the table.
2332 Adjust dependencies.
2333 (output_gram): Use it.
2334 (output_rule_data): Nicer output layout for YYTNAME.
2336 2000-10-16 Akim Demaille <akim@epita.fr>
2338 * src/lex.c (read_typename): New function.
2340 * src/reader.c (copy_dollar): Likewise.
2342 2000-10-16 Akim Demaille <akim@epita.fr>
2344 * src/reader.c (copy_comment2): Expect the input stream to be on
2345 the `/' which is suspected to open a comment, instead of being
2346 called after `//' or `/*' was read.
2347 (copy_comment, copy_definition, parse_union_decl, copy_action)
2348 (copy_guard): Adjust.
2350 2000-10-16 Akim Demaille <akim@epita.fr>
2352 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
2353 `read_signed_integer'.
2355 2000-10-16 Akim Demaille <akim@epita.fr>
2357 * src/reader.c (copy_dollar): New function.
2358 (copy_guard, copy_action): Use it.
2360 2000-10-16 Akim Demaille <akim@epita.fr>
2362 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
2363 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
2364 New files, from Fileutils 4.0.27.
2365 * src/main.c (printable_version): Remove.
2366 * src/lex.c, src/reader.c: Use `quote'.
2368 2000-10-04 Akim Demaille <akim@epita.fr>
2370 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
2372 2000-10-04 Akim Demaille <akim@epita.fr>
2374 * doc/bison.texinfo: Various typos spotted by Neil Booth.
2376 2000-10-04 Akim Demaille <akim@epita.fr>
2378 When a literal string is used to define two different tokens,
2379 `bison -v' segfaults.
2380 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
2382 * tests/regression.m4: New file.
2383 Include the core of the sample provided by Piotr Gackiewicz.
2384 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
2387 2000-10-04 Akim Demaille <akim@epita.fr>
2389 * src/reader.c (parse_expect_decl): Keep `count' within the size
2393 2000-10-02 Paul Eggert <eggert@twinsun.com>
2395 * bison.s1 (yyparse): Assign the default value
2396 unconditionally, to avoid a GCC warning and make the parser a
2399 2000-10-02 Akim Demaille <akim@epita.fr>
2401 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
2404 2000-10-02 Akim Demaille <akim@epita.fr>
2406 * src/derives.c, src/print.c, src/reduce.c: To ease the
2407 translation, move some `\n' out of the translated strings.
2409 2000-10-02 Akim Demaille <akim@epita.fr>
2411 The location tracking mechanism is precious for parse error
2412 messages. Nevertheless, it is enabled only when `@n' is used in
2413 the grammar, which is a different issue (you can use it in error
2414 message, but not in the grammar per se). Therefore, there should
2415 be another means to enable it.
2417 * src/getargs.c (getargs): Support `--locations'.
2419 * src/getargs.h (locationsflag): Export it.
2420 * src/lex.c (percent_table): Support `%locations'.
2421 * src/reader.c (yylsp_needed): Remove this variable, now replaced
2422 with `locationsflag'.
2423 * doc/bison.texinfo: Document `--locations' and `%locations'.
2425 * tests/calc.m4: Test it.
2427 For regularity of the names, replace each
2428 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
2429 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
2430 In addition replace each `flag' with `_flag'.
2432 2000-10-02 Akim Demaille <akim@epita.fr>
2434 Also test parse error messages, including with YYERROR_VERBOSE.
2436 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
2438 Use it to check the computations.
2439 Use it to check `nonassoc' is honored.
2440 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
2441 `--yyerror-verbose'.
2442 (_AT_CHECK_CALC): Adjust to this option.
2443 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
2445 2000-10-02 Akim Demaille <akim@epita.fr>
2447 Test also `--verbose', `--defines' and `--name-prefix'. Testing
2448 the latter demonstrates a flaw in the handling of non debugging
2449 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
2450 was used in order to simplify:
2466 unfortunately this leads to a CPP conflict when
2467 `--name-prefix=foo' is used since it produces `#define yydebug
2470 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
2471 (YYDPRINTF): New macro.
2473 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
2475 Also test `--verbose', `--defines' and `--name-prefix'.
2477 2000-10-02 Akim Demaille <akim@epita.fr>
2479 Improve the readability of the produced parsers.
2481 * src/bison.s1: Formatting changes.
2482 Improve the comment related to the `$' mark.
2483 (yydefault): Don't fall through to `yyresume': `goto' there.
2484 * src/output.c (output_parser): When the `$' is met, skip the end
2486 New variable, `number_of_dollar_signs', to check there's exactly
2487 one `$' in the parser skeleton.
2489 2000-10-02 Akim Demaille <akim@epita.fr>
2491 * lib/xstrdup.c: New file, from the fileutils.
2492 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
2493 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
2494 instead of strlen + xmalloc + strcpy.
2495 * src/symtab.c (copys): Remove, use xstrdup instead.
2497 2000-10-02 Akim Demaille <akim@epita.fr>
2499 * src/gram.h (associativity): New enum type which replaces the
2500 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
2501 `right_assoc', `left_assoc' and `non_assoc'.
2502 Adjust all dependencies.
2503 * src/reader.c: Formatting changes.
2504 (LTYPESTR): Don't define it, use it as a literal in
2505 `reader_output_yylsp'.
2506 * src/symtab.h (symbol_class): New enum type which replaces the
2507 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
2508 `sunknown', `stoken and `snterm'.
2510 2000-10-02 Akim Demaille <akim@epita.fr>
2512 * src/getargs.c (fixed_outfiles): Rename as...
2513 (yaccflag): for consistency and accuracy.
2514 Adjust dependencies.
2516 2000-10-02 Akim Demaille <akim@epita.fr>
2518 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
2519 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
2520 difficult and introduced a lot of core dump. It turns out that
2521 Bison used an implementation of `xmalloc' based on `calloc', and
2522 at various places it does depend upon the initialization to 0. I
2523 have not tried to isolate the pertinent places, and all the former
2524 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
2525 someone should address this issue.
2527 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
2528 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
2530 Adjust dependencies.
2531 * src/warshall.h: New file.
2534 2000-10-02 Akim Demaille <akim@epita.fr>
2536 Various anti-`extern in *.c' changes.
2538 * src/system.h: Include `assert.h'.
2540 2000-10-02 Akim Demaille <akim@epita.fr>
2542 * src/state.h (nstates, final_state, first_state, first_shift)
2543 (first_reduction): Move their exportation from here...
2544 * src/LR0.h: to here.
2545 Adjust dependencies.
2546 * src/getargs.c (statisticsflag): New variable.
2547 Add support for `--statistics'.
2548 Adjust dependencies.
2550 Remove a lot of now useless `extern' statements in most files.
2552 2000-10-02 Akim Demaille <akim@epita.fr>
2554 * src/LR0.h: New file.
2557 2000-10-02 Akim Demaille <akim@epita.fr>
2559 * src/print.h: New file.
2561 * src/print.c: Formatting and ordering changes.
2562 (verbose, terse): Replace with...
2563 (print_results): this new function.
2564 Adjust dependencies.
2566 2000-10-02 Akim Demaille <akim@epita.fr>
2568 * src/conflicts.c (conflict_report): New function.
2569 (conflict_log, verbose_conflict_log): Replace with...
2570 (print_conflicts): this function.
2571 Adjust dependencies.
2572 * src/conflicts.h: New file.
2573 Propagate its inclusion.
2575 2000-10-02 Akim Demaille <akim@epita.fr>
2577 * src/nullable.h: New file.
2578 Propagate its inclusion.
2579 * src/nullable.c: Formatting changes.
2581 2000-10-02 Akim Demaille <akim@epita.fr>
2583 * src/reduce.h: New file.
2584 Propagate its inclusion.
2585 * src/reduce.c: Topological sort and other formatting changes.
2586 (bool, TRUE, FALSE): Move their definition to...
2587 * src/system.h: here.
2589 2000-10-02 Akim Demaille <akim@epita.fr>
2591 * src/files.c: Formatting changes.
2592 (tryopen, tryclose, openfiles): Rename as...
2593 (xfopen, xfclose, open_files): this.
2594 (stringappend): static.
2595 * src/files.h: Complete the list of exported symbols.
2598 2000-10-02 Akim Demaille <akim@epita.fr>
2600 * src/reader.h: New file.
2601 Propagate its use instead of tedious list of `extern' and
2603 * src/reader.c: Formatting changes, topological sort,
2606 2000-10-02 Akim Demaille <akim@epita.fr>
2608 * src/lex.h: Prototype `lex.c' exported functions.
2609 * src/reader.c: Adjust.
2610 * src/lex.c: Formatting changes.
2611 (safegetc): Rename as...
2614 2000-10-02 Akim Demaille <akim@epita.fr>
2616 * src/lalr.h: New file.
2617 Propagate its inclusion instead of prototypes and `extern'.
2618 * src/lalr.c: Formatting changes, topological sorting etc.
2620 2000-10-02 Akim Demaille <akim@epita.fr>
2622 * src/output.c (token_actions): Introduce a temporary array,
2623 YYDEFACT, that makes it possible for this function to use
2626 2000-10-02 Akim Demaille <akim@epita.fr>
2628 `user_toknums' is output as a `short[]' in `output.c', while it is
2629 defined as a `int[]' in `reader.c'. For consistency with the
2630 other output tables, `user_toknums' is now defined as a table of
2633 * src/reader.c (user_toknums): Be a short table instead of an int
2635 Adjust dependencies.
2637 Factor the short table outputs.
2639 * src/output.c (output_short_table): New function.
2640 * src/output.c (output_gram, output_stos, output_rule_data)
2641 (output_base, output_table, output_check): Use it.
2643 2000-10-02 Akim Demaille <akim@epita.fr>
2645 * src/output.c (output): Topological sort of the functions, in
2646 order to get rid of the `static' prototypes.
2647 No longer use `register'.
2648 * src/output.h: New file.
2649 Propagate its inclusion in files explicitly prototyping functions
2652 2000-09-21 Akim Demaille <akim@epita.fr>
2654 * src/atgeneral.m4: Update from Autoconf.
2656 2000-09-21 Akim Demaille <akim@epita.fr>
2658 * src/closure.h: New file.
2659 * src/closure.c: Formatting changes, topological sort over the
2660 functions, use of closure.h.
2661 (initialize_closure, finalize_closure): Rename as...
2662 (new_closure, free_closure): these. Adjust dependencies.
2663 * src/LR0.c: Formatting changes, topological sort, use of
2665 (initialize_states): Rename as...
2667 * src/Makefile.am (noinst_HEADERS): Adjust.
2669 2000-09-20 Akim Demaille <akim@epita.fr>
2671 * src/acconfig.h: Don't protect config.h against multiple
2673 Don't define PARAMS.
2674 * src/system.h: Define PARAMS.
2675 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
2676 purpose of config.h. system.h must not try to fix wrong
2677 definitions in config.h.
2679 2000-09-20 Akim Demaille <akim@epita.fr>
2681 * src/derives.h: New file.
2682 * src/main.c, src/derives.h: Use it.
2684 * src/Makefile.am (noinst_HEADERS): Adjust.
2686 2000-09-20 Akim Demaille <akim@epita.fr>
2688 * tests/atgeneral.m4: Update from Autoconf.
2689 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
2690 (AT_CHECK_CALC): New macros.
2691 Use these macros to test bison with options `', `--raw',
2692 `--debug', `--yacc', `--yacc --debug'.
2694 2000-09-19 Akim Demaille <akim@epita.fr>
2696 * src/output.c: Formatting changes.
2697 * src/machine.h: Remove, leaving its contents in...
2698 * src/system.h: here.
2700 Adjust all dependencies on stdio.h and machine.h.
2701 * src/getargs.h: New file.
2702 Let all `extern' declarations about getargs.c be replaced with
2703 inclusion of `getargs.h'.
2704 * src/Makefile.am (noinst_HEADERS): Adjust.
2706 * tests/calc.m4 (yyin): Be initialized in main, not on the global
2708 (yyerror): Returns void, not int.
2709 * doc/bison.texinfo: Formatting changes.
2711 2000-09-19 Akim Demaille <akim@epita.fr>
2713 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
2716 2000-09-18 Akim Demaille <akim@epita.fr>
2718 * configure.in: Append WARNING_CFLAGS to CFLAGS.
2719 * src/Makefile.am (INCLUDES): Don't.
2720 Be ready to fetch headers in lib/.
2722 2000-09-18 Akim Demaille <akim@epita.fr>
2724 * doc/bison.texinfo: Update the copyright.
2725 ANSIfy and GNUify the examples.
2726 Remove the old menu.
2728 2000-09-18 Akim Demaille <akim@epita.fr>
2730 First set of tests: use the `calc' example from the documentation.
2732 * src/bison.s1 (yyparse): Condition the code using `yytname' which
2733 is defined only when YYDEBUG is.
2734 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
2735 * src/files.c (tryopen, tryclose): Formatting changes.
2736 Move to the top and be static.
2737 * src/reader.c (read_signed_integer): Likewise.
2738 * tests/calc.m4: New file.
2739 * Makefile.am, suite.m4: Adjust.
2740 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
2742 2000-09-18 Akim Demaille <akim@epita.fr>
2744 Add support for an Autotest test suite for Bison.
2746 * m4/m4.m4, m4/atconfig.m4: New files.
2747 * m4/Makefile.am (EXTRA_DIST): Adjust.
2748 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
2750 * src/getargs.c: Display a more standard --version message.
2751 * src/reader.c (reader): Formatting changes.
2752 No longer depend upon VERSION_STRING.
2753 * configure.in: No longer use `dnl'.
2754 Set up the test suite and the new directory `tests/.
2755 (VERSION_STRING): Remove.
2757 2000-04-14 Akim Demaille <akim@epita.fr>
2759 * src/reader.c (copy_comment2): New function, same as former
2760 `copy_comment', but outputs into two FILE *.
2761 (copy_comment): Use it.
2762 (parse_union_decl): Use it.
2763 (get_type, parse_start_decl): Use the same `invalid' message.
2764 (parse_start_decl, parse_union_decl): Use the same `multiple'
2766 (parse_union_decl, copy_guard, copy_action): Use the same
2767 `unmatched' message.
2768 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
2770 2000-03-31 Akim Demaille <akim@epita.fr>
2772 * src/files.c (tryopen, tryclose): Move to the top.
2775 2000-03-31 Akim Demaille <akim@epita.fr>
2777 * src/main.c (main): Don't call `done', exit does it.
2779 2000-03-31 Akim Demaille <akim@epita.fr>
2781 * allocate.c: s/return (foo)/return foo/.
2784 * output.c: Likewise.
2785 * reader.c: Likewise.
2786 * symtab.c: Likewise.
2787 * vmsgetargs.c: Likewise.
2789 2000-03-31 Akim Demaille <akim@epita.fr>
2791 Clean up the error reporting functions.
2793 * src/report.c: New file.
2794 * src/report.h: Likewise.
2795 * src/Makefile.am: Adjust.
2796 * m4/error.m4: New file.
2797 * m4/Makefile.am: Adjust.
2798 * configure.in (jm_PREREQ_ERROR): Call it.
2799 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
2801 (fatal, fatals): Remove. All callers use complain.c::fatal.
2802 (warn, warni, warns, warnss, warnss): Remove. All callers use
2803 complain.c::complain.
2804 (toomany): Remove, use fatal instead.
2805 * src/files.c (done): No argument, use complain_message_count.
2806 * src/main.c (main): Register `done' to `atexit'.
2808 * src/getargs.c (usage): More `fputs', less `fprintf'.
2810 2000-03-28 Akim Demaille <akim@epita.fr>
2812 * lib/: New directory.
2813 * Makefile.am (SUBDIRS): Adjust.
2814 * configure.in: Adjust.
2815 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
2817 * src/alloca.c: Moved to lib/.
2818 * src/getopt.c: Likewise.
2819 * src/getopt1.c: Likewise.
2820 * src/getopt.h: Likewise.
2821 * src/ansi2knr.c: Likewise.
2822 * src/ansi2knr.1: Likewise.
2823 * src/Makefile.am: Adjust.
2824 * lib/Makefile.am: New file.
2826 2000-03-28 Akim Demaille <akim@epita.fr>
2828 * src/getargs.c (usage): Refresh the help message.
2830 2000-03-17 Akim Demaille <akim@epita.fr>
2832 * src/getopt1.c: Updated from textutils 2.0e
2833 * src/getopt.c: Likewise.
2834 * src/getopt.h: Likewise.
2836 2000-03-17 Akim Demaille <akim@epita.fr>
2838 * src/Makefile.am (bison.simple): Fix the awk program: quote only
2839 the file name, not the whole `#line LINE FILE'.
2841 2000-03-17 Akim Demaille <akim@epita.fr>
2843 On syntax errors, report the token on which we choked.
2845 * src/bison.s1 (yyparse): In the label yyerrlab, when
2846 YYERROR_VERBOSE, add yychar in msg.
2848 2000-03-17 Akim Demaille <akim@epita.fr>
2850 * src/reader.c (copy_at): New function.
2851 (copy_guard): Use it.
2852 (copy_action): Use it.
2854 2000-03-17 Akim Demaille <akim@epita.fr>
2856 Be kind to translators, save some useless translations.
2858 * src/main.c (banner): New function.
2859 (fatal_banner): Use it.
2860 (warn_banner): Use it.
2862 2000-03-17 Akim Demaille <akim@epita.fr>
2864 * src/reader.c (copy_definition): Use copy_string and
2865 copy_comment. Removed now unused `match', `ended',
2867 (copy_comment, copy_string): Moved, to be visible from
2870 2000-03-17 Akim Demaille <akim@epita.fr>
2872 * src/reader.c (copy_string): Declare `static inline'. No
2873 problems with inline, since it is checked by configure.
2874 (copy_comment): Likewise.
2876 2000-03-17 Akim Demaille <akim@epita.fr>
2878 * src/reader.c (packsymbols): Formatting changes.
2880 2000-03-17 Akim Demaille <akim@epita.fr>
2882 * src/reader.c (copy_comment): New function, factored out from:
2883 (copy_action): Use it. Removed now unused `match', `ended',
2885 (copy_guard): Likewise.
2887 2000-03-17 Akim Demaille <akim@epita.fr>
2889 * src/reader.c (copy_string): New function, factored out from:
2890 (copy_action): Use it.
2891 (copy_guard): Likewise.
2893 2000-03-17 Akim Demaille <akim@epita.fr>
2895 Change the handling of @s so that they behave exactly like $s.
2896 There is now a pseudo variable @$ (readble and writable), location
2897 of the lhs of the rule (by default ranging from the location of
2898 the first symbol of the rhs, to the location of the last symbol,
2899 or, if the rhs is empty, YYLLOC).
2901 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
2903 (yyparse): When providing a default semantic action, provide a
2904 default location action.
2905 (after the $): No longer change `*YYLSP', just stack YYLOC the
2906 same way you stack YYVAL.
2907 * src/reader.c (read_declarations): Use warns.
2908 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
2909 (copy_action, case '@'): Likewise.
2910 Use a standard error message, to save useless work from
2913 2000-03-17 Akim Demaille <akim@epita.fr>
2915 * src/bison.s1: Formatting and cosmetics changes.
2916 * src/reader.c: Likewise.
2917 Update the Copyright notice.
2919 2000-03-17 Akim Demaille <akim@epita.fr>
2921 * src/bison.s1 (#line): All set to `#line' only, since the
2922 Makefile now handles them.
2924 2000-03-16 Akim Demaille <akim@epita.fr>
2926 * src/output.c (output_rule_data): Output the documentation of
2928 (Copyright notice): Update.
2931 2000-03-16 Akim Demaille <akim@epita.fr>
2933 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
2934 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
2935 One `#if YYDEBUG' remains, since it uses variables which are
2936 defined only if `YYDEBUG != 0'.
2938 2000-03-16 Akim Demaille <akim@epita.fr>
2940 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
2941 and related variables so that the similarities are highlighted.
2943 2000-03-16 Akim Demaille <akim@epita.fr>
2945 * src/bison.s1: Properly indent CPP directives.
2947 2000-03-16 Akim Demaille <akim@epita.fr>
2949 * src/bison.s1: Properly indent the `alloca' CPP section.
2951 2000-03-16 Akim Demaille <akim@epita.fr>
2953 Do not hard code values of directories in `configure.in'.
2954 Update the `configure' tool chain.
2956 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
2958 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
2959 (AC_OUTPUT): Add m4/Makefile.
2960 Bump to bison 1.28a, 1.29 has never been released.
2961 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
2962 handled via src/Makefile.am.
2963 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
2964 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
2966 * Makefile.am (SUBDIRS): Add m4.
2967 (ACLOCAL_AM_FLAGS): New variable.
2968 (AUTOMAKE_OPTIONS): Add check-news.
2969 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
2970 the proper line number and file name.
2971 (DEFS): Propagate the location of bison library files and of the
2973 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
2975 * acinclude.m4: Remove, replaced by the directory m4.
2976 * m4/Makefile.am (EXTRA_DIST): New variable.
2977 * m4/gettext.m4: New file, from the fileutils.
2978 * m4/lcmessage.m4: Likewise
2979 * m4/progtest.m4: Likewise.
2980 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
2982 2000-03-10 Akim Demaille <akim@epita.fr>
2985 Formatting changes of various comments.
2986 Respect the GNU coding standards at various places.
2987 Don't use `_()' when no translation is needed.
2989 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2992 OS/2 honors TMPDIR environment variable.
2994 1999-12-13 Jesse Thilo <jthilo@gnu.org>
2996 * doc/bison.texinfo: Tweaked spelling and grammar.
2998 Removed reference to price of printed copy.
2999 Mention BISON_SIMPLE and BISON_HAIRY.
3001 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3003 * configure.in, NEWS:
3004 Bison 1.29 released.
3006 1999-10-27 Jesse Thilo <jthilo@gnu.org>
3008 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
3009 Added reference card.
3011 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3013 * po/ru.po: Added Russian translation.
3015 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3017 * configure.in: Added Russian translation.
3019 1999-07-06 Jesse Thilo <jthilo@gnu.org>
3021 * configure.in, NEWS, README:
3022 Released version 1.28.
3024 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3027 Squashed redefinition warning on some systems.
3029 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
3030 Have configure build version string instead of relying on ANSI string
3033 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3035 * po/POTFILES.in: Got rid of version.c.
3037 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3039 * acconfig.h, configure.in:
3040 Have configure build version string instead of relying on ANSI string
3043 1999-06-08 Jesse Thilo <jthilo@gnu.org>
3046 Dropped mention of `+' for long-named options.
3048 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3050 * src/files.c: Added <unistd.h> for unlink().
3052 * src/Makefile.am, src/system.h:
3055 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3057 * README: Added a FAQ list.
3059 * configure.in, acconfig.h:
3062 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3064 * doc/FAQ, doc/Makefile.am:
3067 1999-05-19 Jesse Thilo <jthilo@gnu.org>
3069 * src/alloc.h, src/symtab.h, src/version.c:
3070 Protected inclusion of "config.h" with HAVE_CONFIG_H.
3072 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3074 * src/.cvsignore, src/Makefile.am:
3075 Reorganized: sources in `src', documentation in `doc'.
3077 * src/lex.c (literalchar):
3078 fixed the code for escaping double quotes (thanks
3081 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3083 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
3084 Adjusted paths to reflect directory reorganization.
3086 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3088 * doc/.cvsignore, doc/Makefile.am:
3089 Reorganized: sources in `src', documentation in `doc'.
3091 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3094 Updated AC_INIT file to reflect directory reorganization.
3096 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
3097 Reorganized: sources in `src', documentation in `doc'.
3099 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3102 Don't declare calloc() and realloc() if not necessary.
3104 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3106 * configure.in, acconfig.h, acinclude.m4:
3107 Don't declare calloc() and realloc() if not necessary.
3109 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3111 * po/.cvsignore: Added i18n support.
3113 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3115 * acconfig.h, configure.in, Makefile.am:
3118 1999-03-22 Jesse Thilo <jthilo@gnu.org>
3120 * src/bison.s1: Fixed #line numbers.
3122 1999-03-15 Jesse Thilo <jthilo@gnu.org>
3124 * po/es.po, po/fr.po, po/nl.po, po/de.po:
3125 Added PO files from Translation Project.
3127 1999-03-03 Jesse Thilo <jthilo@gnu.org>
3130 Added support for non-ANSI compilers (ansi2knr).
3132 1999-02-16 Jesse Thilo <jthilo@gnu.org>
3134 * configure.in: Bumped version number to 1.27.
3137 Added `bison.simple' to list of files removed by `make distclean'.
3139 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3141 * src/files.c, src/files.h:
3142 Defined locations of parser files in config.h instead of Makefile.
3144 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3146 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
3147 Defined locations of parser files in config.h instead of Makefile.
3149 1999-02-09 Jesse Thilo <jthilo@gnu.org>
3152 Removed inappropriate use of $< macro.
3154 1999-02-05 Jesse Thilo <jthilo@gnu.org>
3156 * po/Makefile.in.in, po/POTFILES.in:
3157 Add `po' directory skeleton.
3159 1999-01-27 Jesse Thilo <jthilo@gnu.org>
3161 * README: Document help-bison list.
3163 * configure.in: Add check for mkstemp().
3165 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3167 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
3168 Hush a few compiler warnings.
3171 Add tryclose(), which verifies that fclose was successful.
3172 Hush a couple of compiler warnings.
3174 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3176 * Makefile.am, OChangeLog:
3177 ChangeLog is now automatically generated. Include the old version as
3180 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3182 * 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:
3185 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3187 * doc/bison.texinfo: Fix formatting glitch.
3189 * doc/bison.texinfo: Update FSF address.
3191 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3193 * acconfig.h: Update FSF address.
3195 1999-01-08 Jesse Thilo <jthilo@gnu.org>
3198 Don't define PACKAGE here, since config.h defines it.
3200 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3202 * src/reader.c: Update copyright date.
3205 Ditch sprintf to statically-sized buffers in fatal/warn functions in
3206 favor of output directly to stderr (avoids buffer overruns).
3208 * src/reader.c: Some checks for premature EOF.
3210 * 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:
3211 Use prototypes if the compiler understands them.
3213 * src/files.c: Honor TMPDIR on Unix hosts.
3214 Use prototypes if the compiler understands them.
3217 Fix a couple of buffer overrun bugs.
3218 Use prototypes if the compiler understands them.
3220 * src/system.h: Include unistd.h and ctype.h.
3221 Use #ifdef instead of #if for NLS symbols.
3223 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3225 * doc/bison.texinfo:
3226 Delete comment "consider using @set for edition number, etc..." since
3227 we now are doing so.
3229 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3232 Use prototypes if the compiler understands them.
3234 * NEWS: Document 1.26 highlights.
3236 * Makefile.am: Require Automake 1.3 or later.
3239 Use prototypes if the compiler understands them.
3241 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3244 Use VERSION symbol from automake for version number.
3246 1998-12-29 Jesse Thilo <jthilo@gnu.org>
3248 * acconfig.h, configure.in, version.cin:
3249 Use VERSION symbol from automake for version number.
3251 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3254 Distribute original version of simple parser (bison.s1), not built
3255 version (bison.simple).
3257 1998-11-28 Jesse Thilo <jthilo@gnu.org>
3259 * doc/bison.texinfo: Add info dir entry.
3261 * doc/bison.texinfo:
3262 Let automake put version number into documentation.
3264 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3266 * src/bison.cld, src/build.com, src/vmshlp.mar:
3267 Add non-RCS files from /gd/gnu/bison.
3269 1998-11-26 Jesse Thilo <jthilo@gnu.org>
3272 Document the BISON_HAIRY and BISON_SIMPLE variables.
3274 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3276 * src/version.c: Build version.c automatically.
3279 Fix token numbering (used to start at 258, not 257).
3281 * src/system.h: Include config.h.
3283 * src/getargs.c: Update bug report address.
3285 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
3286 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
3288 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3291 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3293 * configure.in, version.cin:
3294 Build version.c automatically.
3296 * AUTHORS: Add AUTHORS file.
3298 * README: Update bug report address.
3301 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
3303 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
3306 1998-11-25 Jesse Thilo <jthilo@gnu.org>
3308 * doc/bison.texinfo: Clean up some formatting.
3310 1998-05-05 Richard Stallman <rms@gnu.org>
3312 * doc/bison.texinfo:
3313 Explain better why to make a pure parser.
3315 1998-01-05 Richard Stallman <rms@gnu.org>
3317 * src/files.c (openfiles):
3318 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
3319 find a temporary directory, if possible. Do not unlink files while
3322 1997-08-25 Richard Stallman <rms@gnu.org>
3324 * src/reader.c (stack_offset;):
3325 Change some warni to warns.
3327 * src/lex.c (literalchar): Use warns, not warni.
3329 1997-06-28 Richard Stallman <rms@gnu.org>
3331 * src/bison.s1: Add a Bison version comment.
3333 * src/main.c (fatal, warn, berror):
3336 1997-06-28 Richard Stallman <rms@gnu.org>
3338 * Makefile.in (bison_version): New variable.
3339 (dist): Use that variable.
3340 (bison.s1): Substitute the Bison version into bison.simple.
3342 * bison.simple: Add a Bison version comment.
3344 1997-06-18 Richard Stallman <rms@gnu.org>
3346 * src/main.c (fatal, warn, berror):
3347 Make error messages standard.
3348 (toomany): Improve error message text.
3350 * 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:
3351 new.h renamed to alloc.h.
3353 1997-06-18 Richard Stallman <rms@gnu.org>
3355 * Makefile.in: new.h renamed to alloc.h.
3357 1997-05-24 Richard Stallman <rms@gnu.org>
3359 * src/lex.c (literalchar):
3360 Fix the code for escaping \, " and '.
3362 (lex): Avoid trouble when there are many chars
3363 to discard in a char literal with just several chars in it.
3365 1997-05-17 Richard Stallman <rms@gnu.org>
3368 Use malloc, if using alloca is troublesome.
3369 (YYSTACK_USE_ALLOCA): New flag macro.
3370 Define it for some systems and compilers.
3371 (YYSTACK_ALLOC): New macro.
3372 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3373 If it was malloc'd, free it.
3375 1997-05-17 Richard Stallman <rms@gnu.org>
3378 Use malloc, if using alloca is troublesome.
3379 (YYSTACK_USE_ALLOCA): New flag macro.
3380 Define it for some systems and compilers.
3381 (YYSTACK_ALLOC): New macro.
3382 (yyparse): Use YYSTACK_ALLOC to allocate stack.
3383 If it was malloc'd, free it.
3385 1997-04-23 Richard Stallman <rms@gnu.org>
3388 (alloca) [__hpux]: Always define as __builtin_alloca.
3390 1997-04-23 Richard Stallman <rms@gnu.org>
3393 (alloca) [__hpux]: Always define as __builtin_alloca.
3395 1997-04-22 Richard Stallman <rms@gnu.org>
3398 [__hpux]: Include alloca.h (right for HPUX 10)
3399 instead of declaring alloca (right for HPUX 9).
3401 * src/bison.s1 (__yy_memcpy):
3402 Declare arg `count' as unsigned int.
3403 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3405 1997-04-22 Richard Stallman <rms@gnu.org>
3408 [__hpux]: Include alloca.h (right for HPUX 10)
3409 instead of declaring alloca (right for HPUX 9).
3411 * bison.simple (__yy_memcpy):
3412 Declare arg `count' as unsigned int.
3413 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
3415 1997-01-03 Richard Stallman <rms@gnu.org>
3417 * src/allocate.c: [__STDC__ or _MSC_VER]:
3418 Declare calloc and realloc to return void *.
3420 1997-01-02 Richard Stallman <rms@gnu.org>
3423 [_MSC_VER]: Include stdlib.h and process.h.
3424 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
3426 * src/main.c (main): Return FAILURE as a value.
3427 (printable_version): Declare arg as int, not char.
3429 1997-01-02 Richard Stallman <rms@gnu.org>
3431 * Makefile.in (dist):
3432 Explicitly check for symlinks, and copy them.
3434 1996-12-19 Richard Stallman <rms@gnu.org>
3437 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
3439 1996-12-18 Paul Eggert <eggert@gnu.org>
3441 * src/bison.s1 (yyparse):
3442 If __GNUC__ and YYPARSE_PARAM are both defined,
3443 declare yyparse to have a void * argument.
3445 1996-12-18 Paul Eggert <eggert@gnu.org>
3447 * bison.simple (yyparse):
3448 If __GNUC__ and YYPARSE_PARAM are both defined,
3449 declare yyparse to have a void * argument.
3451 1996-12-17 Richard Stallman <rms@gnu.org>
3453 * src/reduce.c (nbits): Add some casts.
3455 1996-08-12 Richard Stallman <rms@gnu.org>
3457 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
3459 1996-08-12 Richard Stallman <rms@gnu.org>
3461 * bison.simple: Test _MSDOS as well as _MSDOS_.
3463 1996-07-31 Richard Stallman <rms@gnu.org>
3466 [__sun && __i386]: Include alloca.h.
3468 1996-07-31 Richard Stallman <rms@gnu.org>
3471 [__sun && __i386]: Include alloca.h.
3473 1996-07-30 Richard Stallman <rms@gnu.org>
3475 * src/bison.s1: Comment change.
3477 * src/bison.s1: Test _MSDOS_, not MSDOS.
3479 1996-07-30 Richard Stallman <rms@gnu.org>
3481 * bison.simple: Comment change.
3483 * bison.simple: Test _MSDOS_, not MSDOS.
3485 1996-06-01 Richard Stallman <rms@gnu.org>
3487 * 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:
3488 Insert `_' macro around many string constants.
3491 Insert `_' macro around many string constants.
3493 (main): Call setlocale, bindtextdomain and textdomain.
3495 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
3496 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
3497 [ENABLE_NLS]: Include libintl.h.
3498 [ENABLE_NLS] (gettext): Define.
3499 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
3500 (N_, PACKAGE, LOCALEDIR): New macros.
3502 1996-06-01 Richard Stallman <rms@gnu.org>
3504 * POTFILES.in: New file.
3506 * Makefile.in (allocate.o):
3507 Define target explicitly.
3509 * Makefile.in (CFLAGS): Set to @CFLAGS@.
3510 (LDFLAGS): Set to @LDFLAGS@.
3511 (configure): Run autoconf only if preceding `cd' succeeds.
3512 (bison.s1): Redirect output to temporary file then move the
3513 temporary to the target, rather than redirecting directly to bison.s1.
3514 (clean): Remove config.status and config.log.
3515 (distclean): Don't remove config.status here.
3517 1996-05-12 Richard Stallman <rms@gnu.org>
3520 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3522 1996-05-12 Richard Stallman <rms@gnu.org>
3525 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
3527 1996-05-11 Richard Stallman <rms@gnu.org>
3529 * src/bison.s1 (__yy_memcpy):
3530 Really reorder the args, as was supposedly done on Feb 14 1995.
3531 (yyparse): Calls changed accordingly.
3533 1996-05-11 Richard Stallman <rms@gnu.org>
3535 * Makefile.in (dist): Don't use $(srcdir).
3537 * bison.simple (__yy_memcpy):
3538 Really reorder the args, as was supposedly done on Feb 14 1995.
3539 (yyparse): Calls changed accordingly.
3541 1996-01-27 Richard Stallman <rms@gnu.org>
3543 * src/output.c (output_rule_data):
3544 Test YYERROR_VERBOSE in the conditional
3545 around the definition of ttyname.
3547 1995-12-29 Richard Stallman <rms@gnu.org>
3550 Fix line numbers in #line commands.
3552 1995-12-29 Richard Stallman <rms@gnu.org>
3555 Fix line numbers in #line commands.
3557 1995-12-27 Richard Stallman <rms@gnu.org>
3559 * src/bison.s1 (YYPARSE_PARAM_DECL):
3560 In C++, make it always null.
3561 (YYPARSE_PARAM_ARG): New macro.
3562 (yyparse): Use YYPARSE_PARAM_ARG.
3564 1995-12-27 Richard Stallman <rms@gnu.org>
3566 * bison.simple (YYPARSE_PARAM_DECL):
3567 In C++, make it always null.
3568 (YYPARSE_PARAM_ARG): New macro.
3569 (yyparse): Use YYPARSE_PARAM_ARG.
3571 1995-11-29 Richard Stallman <rms@gnu.org>
3573 * doc/bison.texinfo:
3574 Describe literal string tokens, %raw, %no_lines, %token_table.
3576 1995-11-29 Daniel Hagerty <hag@gnu.org>
3578 * doc/bison.texinfo: Fixed update date
3580 1995-10-16 Richard Stallman <rms@gnu.org>
3582 * src/version.c: Version 1.25.
3584 1995-10-16 Richard Stallman <rms@gnu.org>
3586 * NEWS: *** empty log message ***
3588 1995-10-16 Richard Stallman <rms@gnu.org>
3590 * doc/bison.1, doc/bison.rnh:
3593 1995-10-15 Richard Stallman <rms@gnu.org>
3595 * src/vmsgetargs.c, src/getargs.c:
3596 Added -n, -k, and -raw switches.
3597 (noparserflag, toknumflag, rawtoknumflag): New variables.
3599 * src/symtab.h (SALIAS):
3600 New #define for adding aliases to %token.
3601 (struct bucket): Added `alias' field.
3603 * src/reduce.c (reduce_grammar):
3604 Revise error message.
3605 (print_notices): Remove final `.' from error message.
3607 * src/reader.c (reader_output_yylsp):
3609 (readgram): Use `#if 0' around code that accepted %command
3610 inside grammar rules: The documentation doesn't allow it,
3611 and it will fail since the %command processors scan for the next %.
3612 (parse_token_decl): Extended the %token
3613 declaration to allow a multi-character symbol as an alias.
3614 (parse_thong_decl): New function.
3615 (read_declarations): Added %thong declarations.
3616 (read_declarations): Handle NOOP to deal with allowing
3617 % declarations as another means to specify the flags.
3618 (readgram): Allow %prec prior to semantics embedded in a rule.
3619 (skip_to_char, read_declarations, copy_definition)
3620 (parse_token_decl, parse_start_decl, parse_type_decl)
3621 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
3622 (get_type_name, copy_guard, copy_action, readgram)
3623 (get_type, packsymbols): Revised most error messages.
3624 Changed `fatal' to `warnxxx' to avoid aborting for error.
3625 Revised and use multiple warnxxx functions to avoid using VARARGS1.
3626 (read_declarations): Improve the error message for
3627 an invalid character. Do not abort.
3628 (read_declarations, copy_guard, copy_action): Use
3629 printable_version to avoid unprintable characters in printed output.
3630 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
3631 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
3632 Allow the type of a non-terminal can be given
3633 more than once, as long as all specifications give the same type.
3636 (output_headers, output_trailers, output, output_gram)
3637 (output_rule_data): Implement noparserflag variable.
3638 Implement toknumflag variable.
3639 (output): Call reader_output_yylsp to output LTYPESTR.
3641 * src/main.c (main):
3642 If reader sees an error, don't process the grammar.
3643 (fatals): Updated to not use VARARGS1.
3644 (printable_version, int_to_string, warn, warni, warns, warnss)
3645 (warnsss): New error reporting functions. Avoid abort for error.
3648 Added THONG and NOOP for alias processing.
3649 Added SETOPT for the new code that allows setting options with %flags.
3652 Include getopt.h. Add some extern decls.
3653 (safegetc): New function to deal with EOF gracefully.
3654 (literalchar); new function to deal with reading \ escapes.
3655 (lex): Use literalchar.
3656 (lex): Implemented "..." tokens.
3657 (literalchar, lex, parse_percent_token): Made tokenbuffer
3658 always contain the token. This includes growing the token
3659 buffer while reading an integer.
3660 (parse_percent_token): Replaced if-else statement with percent_table.
3661 (parse_percent_token): Added % declarations as another
3662 way to specify the flags -n, -l, and -r. Also added hooks for
3663 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
3664 major changes to files.c.
3665 (lex) Retain in the incoming stream a character following
3667 (skip_white_space, lex): Revised most error messages
3668 and changed fatal to warn to avoid aborting.
3669 (percent_table): Added %thong declarations.
3671 * src/gram.h: Comment changes.
3673 * src/files.c (openfiles, open_extra_files, done):
3675 and actfile file. Handle noparserflag. Both for -n switch.
3677 * src/conflicts.c (resolve_sr_conflict):
3678 Remove use of alloca.
3680 1995-06-01 Jim Meyering <meyering@gnu.org>
3682 * doc/bison.texinfo: *** empty log message ***
3684 1995-05-06 Richard Stallman <rms@gnu.org>
3686 * src/bison.s1: Comment change.
3688 1995-05-06 Richard Stallman <rms@gnu.org>
3690 * bison.simple: Comment change.
3692 1995-05-03 Richard Stallman <rms@gnu.org>
3694 * src/version.c: Version now 1.24.
3696 * src/bison.s1: Change distribution terms.
3698 * src/version.c: Version now 1.23.
3700 1995-05-03 Richard Stallman <rms@gnu.org>
3702 * doc/bison.texinfo:
3703 Rewrite "Conditions for Using Bison".
3704 Update version to 1.24.
3706 1995-05-03 Richard Stallman <rms@gnu.org>
3708 * bison.simple: Change distribution terms.
3710 1995-02-23 Richard Stallman <rms@gnu.org>
3712 * src/files.c: Test __VMS_POSIX as well as VMS.
3714 1995-02-14 Jim Meyering <meyering@gnu.org>
3716 * src/bison.s1 (__yy_memcpy):
3717 Renamed from __yy_bcopy to avoid
3718 confusion. Reverse FROM and TO arguments to be consistent with
3721 1995-02-14 Jim Meyering <meyering@gnu.org>
3723 * bison.simple (__yy_memcpy):
3724 Renamed from __yy_bcopy to avoid
3725 confusion. Reverse FROM and TO arguments to be consistent with
3728 1994-11-10 David J. MacKenzie <djm@gnu.org>
3734 * Makefile.in (DISTFILES): Include NEWS.
3736 * Makefile.in (DISTFILES):
3737 Include install-sh, not install.sh.
3739 * configure.in: Update to Autoconf v2 macro names.
3741 1994-10-05 David J. MacKenzie <djm@gnu.org>
3743 * Makefile.in: fix typo
3745 * Makefile.in (prefix, exec_prefix):
3746 Let configure set them.
3748 1994-09-28 David J. MacKenzie <djm@gnu.org>
3750 * Makefile.in: Set datadir to $(prefix)/share.
3752 1994-09-15 Richard Stallman <rms@gnu.org>
3755 Update copyright notice and GPL version.
3757 1994-09-15 Richard Stallman <rms@gnu.org>
3760 Update copyright notice and GPL version.
3762 1994-07-12 Richard Stallman <rms@gnu.org>
3764 * src/reduce.c, src/reader.c:
3767 1994-05-05 David J. MacKenzie <djm@gnu.org>
3769 * Makefile.in: entered into RCS
3771 1994-03-26 Richard Stallman <rms@gnu.org>
3773 * src/bison.s1: entered into RCS
3775 1994-03-26 Richard Stallman <rms@gnu.org>
3777 * bison.simple: entered into RCS
3779 1994-03-25 Richard Stallman <rms@gnu.org>
3781 * src/main.c: entered into RCS
3783 1994-03-24 Richard Stallman <rms@gnu.org>
3785 * src/conflicts.c: entered into RCS
3787 1994-01-02 Richard Stallman <rms@gnu.org>
3789 * Makefile.in: *** empty log message ***
3791 1993-11-21 Richard Stallman <rms@gnu.org>
3793 * src/bison.s1: *** empty log message ***
3795 1993-11-21 Richard Stallman <rms@gnu.org>
3797 * doc/bison.texinfo: entered into RCS
3799 * doc/bison.texinfo: *** empty log message ***
3801 1993-11-21 Richard Stallman <rms@gnu.org>
3803 * bison.simple: *** empty log message ***
3805 1993-10-25 David J. MacKenzie <djm@gnu.org>
3807 * doc/bison.texinfo: *** empty log message ***
3809 1993-10-19 Richard Stallman <rms@gnu.org>
3811 * src/bison.s1: *** empty log message ***
3813 1993-10-19 Richard Stallman <rms@gnu.org>
3815 * bison.simple: *** empty log message ***
3817 1993-10-14 Richard Stallman <rms@gnu.org>
3819 * src/bison.s1: *** empty log message ***
3821 1993-10-14 Richard Stallman <rms@gnu.org>
3823 * bison.simple: *** empty log message ***
3825 1993-09-14 David J. MacKenzie <djm@gnu.org>
3827 * doc/bison.texinfo: *** empty log message ***
3829 1993-09-13 Noah Friedman <friedman@gnu.org>
3831 * Makefile.in: *** empty log message ***
3833 1993-09-10 Richard Stallman <rms@gnu.org>
3835 * src/conflicts.c: *** empty log message ***
3837 * src/system.h: entered into RCS
3839 1993-09-10 Richard Stallman <rms@gnu.org>
3841 * doc/bison.1: entered into RCS
3843 1993-09-06 Noah Friedman <friedman@gnu.org>
3845 * src/version.c: entered into RCS
3847 1993-09-06 Noah Friedman <friedman@gnu.org>
3849 * Makefile.in: *** empty log message ***
3851 1993-07-30 David J. MacKenzie <djm@gnu.org>
3853 * Makefile.in: *** empty log message ***
3855 1993-07-24 Richard Stallman <rms@gnu.org>
3857 * src/bison.s1: *** empty log message ***
3859 1993-07-24 Richard Stallman <rms@gnu.org>
3861 * bison.simple: *** empty log message ***
3863 1993-07-08 David J. MacKenzie <djm@gnu.org>
3865 * Makefile.in: *** empty log message ***
3867 1993-07-04 Richard Stallman <rms@gnu.org>
3869 * src/bison.s1: *** empty log message ***
3871 1993-07-04 Richard Stallman <rms@gnu.org>
3873 * bison.simple: *** empty log message ***
3875 1993-06-26 David J. MacKenzie <djm@gnu.org>
3877 * src/getargs.c: entered into RCS
3879 1993-06-26 David J. MacKenzie <djm@gnu.org>
3881 * doc/bison.texinfo: *** empty log message ***
3883 * doc/bison.1: New file.
3885 1993-06-25 Richard Stallman <rms@gnu.org>
3887 * src/getargs.c: New file.
3889 1993-06-16 Richard Stallman <rms@gnu.org>
3891 * src/bison.s1: *** empty log message ***
3893 1993-06-16 Richard Stallman <rms@gnu.org>
3895 * bison.simple: *** empty log message ***
3897 1993-06-03 Richard Stallman <rms@gnu.org>
3899 * src/bison.s1: New file.
3901 1993-06-03 Richard Stallman <rms@gnu.org>
3903 * doc/bison.texinfo: *** empty log message ***
3905 1993-06-03 Richard Stallman <rms@gnu.org>
3907 * bison.simple: New file.
3909 1993-05-19 Richard Stallman <rms@gnu.org>
3911 * doc/bison.texinfo: New file.
3913 1993-05-07 Noah Friedman <friedman@gnu.org>
3915 * Makefile.in: *** empty log message ***
3917 1993-04-28 Noah Friedman <friedman@gnu.org>
3919 * src/reader.c: *** empty log message ***
3921 1993-04-23 Noah Friedman <friedman@gnu.org>
3923 * src/alloc.h: entered into RCS
3925 1993-04-20 David J. MacKenzie <djm@gnu.org>
3927 * src/version.c: *** empty log message ***
3929 * src/files.c, src/allocate.c:
3932 * src/reader.c: *** empty log message ***
3934 * src/lex.c: entered into RCS
3936 * src/conflicts.c: New file.
3938 * src/symtab.c: entered into RCS
3940 * src/alloc.h: New file.
3942 * src/LR0.c: entered into RCS
3944 1993-04-18 Noah Friedman <friedman@gnu.org>
3946 * src/reader.c: New file.
3948 * src/version.c: *** empty log message ***
3950 1993-04-18 Noah Friedman <friedman@gnu.org>
3952 * Makefile.in: *** empty log message ***
3954 1993-04-17 Noah Friedman <friedman@gnu.org>
3956 * Makefile.in: *** empty log message ***
3958 1993-04-15 Richard Stallman <rms@gnu.org>
3960 * src/main.c, src/files.c:
3963 1993-04-15 Noah Friedman <friedman@gnu.org>
3965 * configure.in: entered into RCS
3967 * configure.in: *** empty log message ***
3969 * configure.in: New file.
3971 1993-04-14 Richard Stallman <rms@gnu.org>
3973 * Makefile.in: New file.
3975 1993-04-13 Richard Stallman <rms@gnu.org>
3977 * src/version.c: New file.
3979 1993-03-25 Richard Stallman <rms@gnu.org>
3981 * src/output.c: entered into RCS
3983 1992-09-25 Richard Stallman <rms@gnu.org>
3985 * configure.bat: entered into RCS
3987 1992-06-22 Richard Stallman <rms@gnu.org>
3989 * src/vmsgetargs.c: entered into RCS
3991 1992-06-22 Richard Stallman <rms@gnu.org>
3993 * doc/bison.rnh: entered into RCS
3995 1992-04-20 David J. MacKenzie <djm@gnu.org>
3997 * README: entered into RCS
3999 1992-01-22 Richard Stallman <rms@gnu.org>
4001 * src/machine.h: entered into RCS
4003 1991-12-21 Richard Stallman <rms@gnu.org>
4005 * src/lalr.c, src/closure.c:
4008 1991-12-20 Richard Stallman <rms@gnu.org>
4010 * src/state.h: entered into RCS
4012 1991-12-18 Richard Stallman <rms@gnu.org>
4014 * src/print.c, src/nullable.c, src/derives.c:
4017 1991-11-03 David J. MacKenzie <djm@gnu.org>
4019 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
4022 1988-09-09 Richard Stallman <rms@gnu.org>
4024 * src/bison.hairy: entered into RCS
4026 1987-12-16 Richard Stallman <rms@gnu.org>
4028 * REFERENCES: entered into RCS