]> git.saurik.com Git - bison.git/blob - ChangeLog
* data/bison.simple (YYCOPY): Fix [] quoting problem in the non-GCC case.
[bison.git] / ChangeLog
1 2002-04-26 Paul Eggert <eggert@twinsun.com>
2
3 * data/bison.simple (YYSTYPE_IS_TRIVIAL, YYLTYPE_IS_TRIVIAL):
4 Define if we define YYSTYPE and YYLTYPE, respectively.
5 (YYCOPY): Fix [] quoting problem in the non-GCC case.
6
7 2002-04-25 Robert Anisko <robert@lrde.epita.fr>
8
9 * src/scan-skel.l: Postprocess quadrigraphs.
10
11 * src/reader.c (copy_character): New function, used to output
12 single characters while replacing `[' and `]' with quadrigraphs, to
13 avoid troubles with M4 quotes.
14 (copy_comment): Output characters with copy_character.
15 (read_additionnal_code): Likewise.
16 (copy_string2): Likewise.
17 (copy_definition): Likewise.
18
19 * tests/calc.at: Exercise M4 quoting.
20
21 2002-04-25 Akim Demaille <akim@epita.fr>
22
23 * tests/sets.at (AT_EXTRACT_SETS): Sed portability issue: no space
24 between `!' and the command.
25 Reported by Paul Eggert.
26
27 2002-04-24 Robert Anisko <robert@lrde.epita.fr>
28
29 * tests/calc.at: Exercise prologue splitting.
30
31 * data/bison.simple, data/bison.c++: Use `b4_pre_prologue' and
32 `b4_post_prologue' instead of `b4_prologue'.
33
34 * src/output.c (prepare): Add the `pre_prologue' and `post_prologue'
35 muscles.
36 (output): Free pre_prologue_obstack and post_prologue_obstack.
37 * src/files.h, src/files.c (attrs_obstack): Remove.
38 (pre_prologue_obstack, post_prologue_obstack): New.
39 * src/reader.c (copy_definition): Add a parameter to specify the
40 obstack to fill, instead of using attrs_obstack unconditionally.
41 (read_declarations): Pass pre_prologue_obstack to copy_definition if
42 `%union' has not yet been seen, pass post_prologue_obstack otherwise.
43
44 2002-04-23 Paul Eggert <eggert@twinsun.com>
45
46 * data/bison.simple: Remove unnecessary commentary and white
47 space differences from 1_29-branch.
48 Depend on YYERROR_VERBOSE, not defined (YYERROR_VERBOSE).
49
50 (union yyalloc, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYCOPY,
51 YYSTACK_RELOCATE): Do not define if yyoverflow is defined, or
52 if this is a C++ parser and YYSTYPE or YYLTYPE has nontrivial
53 constructors or destructors.
54
55 (yyparse) [! defined YYSTACK_RELOCATE]: Do not relocate the stack.
56
57 2002-04-23 Akim Demaille <akim@epita.fr>
58
59 * tests/sets.at (AT_EXTRACT_SETS): Don't use 8 char long sed labels.
60 * tests/synclines.at (AT_TEST_SYNCLINE): Be robust to GCC's
61 location with columns.
62 * tests/conflicts.at (%nonassoc and eof): Don't use `error.h'.
63 All reported by Paul Eggert.
64
65 2002-04-22 Akim Demaille <akim@epita.fr>
66
67 * src/reduce.c (dump_grammar): Move to...
68 * src/gram.h, src/gram.c (grammar_dump): here.
69 Be sure to separate long item numbers.
70 Don't read the members of a rule's prec if its nil.
71
72 2002-04-22 Akim Demaille <akim@epita.fr>
73
74 * src/output.c (table_size, table_grow): New.
75 (MAXTABLE): Remove, replace uses with table_size.
76 (pack_vector): Instead of dying when the table is too big, grow it.
77
78 2002-04-22 Akim Demaille <akim@epita.fr>
79
80 * data/bison.simple (yyr1): Its type is that of a token number.
81 * data/bison.c++ (r1_): Likewise.
82 * tests/regression.at (Web2c Actions): Adjust.
83
84 2002-04-22 Akim Demaille <akim@epita.fr>
85
86 * src/reader.c (token_translations_init): 256 is now the default
87 value for the error token, i.e., it will be assigned another
88 number if the user assigned 256 to one of her tokens.
89 (reader): Don't force 256 to error.
90 * doc/bison.texinfo (Symbols): Adjust.
91 * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR)
92 (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3
93 etc. instead of 10, 20, 30 (which was used to `jump' over error
94 (256) and undefined (2)).
95
96 2002-04-22 Akim Demaille <akim@epita.fr>
97
98 Propagate more token_number_t.
99
100 * src/gram.h (token_number_as_item_number)
101 (item_number_as_token_number): New.
102 * src/output.c (GENERATE_OUTPUT_TABLE): New.
103 Use it to create output_item_number_table and
104 output_token_number_table.
105 * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c,
106 * src/lex.c, src/nullable.c, src/output.c, src/print.c,
107 * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h,
108 * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts.
109
110 2002-04-22 Akim Demaille <akim@epita.fr>
111
112 * src/output.h, src/output.c (get_lines_number): Remove.
113
114 2002-04-19 Akim Demaille <akim@epita.fr>
115
116 * doc/bison.texinfo (Actions): Make clear that `|' is not the same
117 as Lex/Flex'.
118 (Debugging): More details about enabling the debugging features.
119 (Table of Symbols): Describe $$, $n, @$, and @n.
120 Suggested by Tim Josling.
121
122 2002-04-19 Akim Demaille <akim@epita.fr>
123
124 * doc/bison.texinfo: Remove the uses of the obsolete @refill.
125
126 2002-04-10 Akim Demaille <akim@epita.fr>
127
128 * src/system.h: Rely on HAVE_LIMITS_H.
129 Suggested by Paul Eggert.
130
131 2002-04-09 Akim Demaille <akim@epita.fr>
132
133 * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the
134 full stderr, and strip it according to the bison options, instead
135 of composing the error message from different bits.
136 This makes it easier to check for several error messages.
137 Adjust all the invocations.
138 Add an invocation exercising the error token.
139 Add an invocation demonstrating a stupid error message.
140 (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0.
141 Adjust the tests.
142 Error message are for stderr, not stdout.
143
144 2002-04-09 Akim Demaille <akim@epita.fr>
145
146 * src/gram.h, src/gram.c (error_token_number): Remove, use
147 errtoken->number.
148 * src/reader.c (reader): Don't specify the user token number (2)
149 for $undefined, as it uselessly prevents using it.
150 * src/gram.h (token_number_t): Move to...
151 * src/symtab.h: here.
152 (state_t.number): Is a token_number_t.
153 * src/print.c, src/reader.c: Use undeftoken->number instead of
154 hard coded 2.
155 (Even though this 2 is not the same as above: the number of the
156 undeftoken remains being 2, it is its user token number which
157 might not be 2).
158 * src/output.c (prepare_tokens): Rename the `maxtok' muscle with
159 `user_token_number_max'.
160 Output `undef_token_number'.
161 * data/bison.simple, data/bison.c++: Use them.
162 Be sure to map invalid yylex return values to
163 `undef_token_number'. This saves us from gratuitous SEGV.
164
165 * tests/conflicts.at (Solved SR Conflicts)
166 (Unresolved SR Conflicts): Adjust.
167 * tests/regression.at (Web2c Actions): Adjust.
168
169 2002-04-08 Akim Demaille <akim@epita.fr>
170
171 * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/.
172 Adding #line.
173 Remove the duplicate `typedefs'.
174 (RhsNumberType): Fix the declaration and various other typos.
175 Use __ofile__.
176 * data/bison.simple: Use __ofile__.
177 * src/scan-skel.l: Handle __ofile__.
178
179 2002-04-08 Akim Demaille <akim@epita.fr>
180
181 * src/gram.h (item_number_t): New, the type of item numbers in
182 RITEM. Note that it must be able to code symbol numbers as
183 positive number, and the negation of rule numbers as negative
184 numbers.
185 Adjust all dependencies (pretty many).
186 * src/reduce.c (rule): Remove this `short *' pointer: use
187 item_number_t.
188 * src/system.h (MINSHORT, MAXSHORT): Remove.
189 Include `limits.h'.
190 Adjust dependencies to using SHRT_MAX and SHRT_MIN.
191 (shortcpy): Remove.
192 (MAXTABLE): Move to...
193 * src/output.c (MAXTABLE): here.
194 (prepare_rules): Use output_int_table to output rhs.
195 * data/bison.simple, data/bison.c++: Adjust.
196 * tests/torture.at (Big triangle): Move the limit from 254 to
197 500.
198 * tests/regression.at (Web2c Actions): Ajust.
199
200 Trying with bigger grammars shows various phenomena: at 3000 (28Mb
201 of grammar file) bison is killed by my system, at 2000 (12Mb) bison
202 passes, but produces negative #line number, once fixed, GCC is
203 killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of
204 C), it passes.
205 * src/state.h (state_h): Code input lines on ints, not shorts.
206
207 2002-04-08 Akim Demaille <akim@epita.fr>
208
209 * src/reduce.c (reduce_grammar): First reduce the nonterminals,
210 and then the grammar.
211
212 2002-04-08 Akim Demaille <akim@epita.fr>
213
214 * src/system.h: No longer using strndup.
215
216 2002-04-07 Akim Demaille <akim@epita.fr>
217
218 * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New.
219 * src/output.c (output_table_data): Return the longest number.
220 (prepare_tokens): Output `token_number_max').
221 * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type):
222 New.
223 Use them to define yy_token_number_type/TokenNumberType.
224 Use this type for yytranslate.
225 * tests/torture.at (Big triangle): Push the limit from 124 to
226 253.
227 * tests/regression.at (Web2c Actions): Adjust.
228
229 2002-04-07 Akim Demaille <akim@epita.fr>
230
231 * tests/torture.at (Big triangle): New.
232 (GNU AWK Grammar, GNU Cim Grammar): Move to...
233 * tests/existing.at: here.
234
235 2002-04-07 Akim Demaille <akim@epita.fr>
236
237 * src/gram.h, src/gram.c (nitems): Remove, it is an alias of
238 nritems.
239 Adjust dependencies.
240
241 2002-04-07 Akim Demaille <akim@epita.fr>
242
243 * src/reader.c: Normalize increments to prefix form.
244
245 2002-04-07 Akim Demaille <akim@epita.fr>
246
247 * src/reader.c, symtab.c: Remove debugging code.
248
249 2002-04-07 Akim Demaille <akim@epita.fr>
250
251 Rename all the `bucket's as `symbol_t'.
252
253 * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c,
254 * src/reader.c, src/reader.h, src/reduce.c, src/state.h,
255 * src/symtab.c, src/symtab.h (bucket): Rename as...
256 (symbol_t): this.
257 (symbol_list_new, bucket_check_defined, bucket_make_alias)
258 (bucket_check_alias_consistence, bucket_pack, bucket_translation)
259 (bucket_new, bucket_free, hash_compare_bucket, hash_bucket)
260 (buckets_new, buckets_free, buckets_do): Rename as...
261 (symbol_list_new, symbol_check_defined, symbol_make_alias)
262 (symbol_check_alias_consistence, symbol_pack, symbol_translation)
263 (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t)
264 (symbols_new, symbols_free, symbols_do): these.
265
266 2002-04-07 Akim Demaille <akim@epita.fr>
267
268 Use lib/hash for the symbol table.
269
270 * src/gram.c (ntokens): Initialize to 1, to reserve a slot for
271 EOF.
272 * src/lex.c (lex): Set the `number' member of new terminals.
273 * src/reader.c (bucket_check_defined, bucket_make_alias)
274 (bucket_check_alias_consistence, bucket_translation): New.
275 (reader, grammar_free, readgram, token_translations_init)
276 (packsymbols): Adjust.
277 (reader): Number the predefined tokens.
278 * src/reduce.c (inaccessable_symbols): Just use hard coded numbers
279 for predefined tokens.
280 * src/symtab.h (bucket): Remove all the hash table related
281 members.
282 * src/symtab.c (symtab): Replace by...
283 (bucket_table): this.
284 (bucket_new, bucket_free, hash_compare_bucket, hash_bucket)
285 (buckets_new, buckets_do): New.
286
287 2002-04-07 Akim Demaille <akim@epita.fr>
288
289 * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems)
290 (start_symbol, max_user_token_number, semantic_parser)
291 (error_token_number): Initialize.
292 * src/reader.c (grammar, start_flag, startval, typed, lastprec):
293 Initialize.
294 (reader): Don't.
295 (errtoken, eoftoken, undeftoken, axiom): Extern.
296
297 2002-04-07 Akim Demaille <akim@epita.fr>
298
299 * src/gram.h (rule_s): prec and precsym are now pointers
300 to the bucket giving the priority/associativity.
301 Member `associativity' removed: useless.
302 * src/reduce.c, src/conflicts.c: Adjust.
303
304 2002-04-07 Akim Demaille <akim@epita.fr>
305
306 * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c:
307 Properly escape the symbols' TAG when outputting them.
308
309 2002-04-07 Akim Demaille <akim@epita.fr>
310
311 * src/lalr.h (LA): Is a bitsetv, not bitset*.
312
313 2002-04-07 Akim Demaille <akim@epita.fr>
314
315 * src/lalr.h, src/lalr.c (LAruleno): Replace with...
316 (LArule): this, which is an array to rule_t*.
317 * src/print.c, src/conflicts.c: Adjust.
318
319 2002-04-07 Akim Demaille <akim@epita.fr>
320
321 * src/gram.h (rule_t): Rename `number' as `user_number'.
322 `number' is a new member.
323 Adjust dependencies.
324 * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number.
325
326 2002-04-07 Akim Demaille <akim@epita.fr>
327
328 As a result of the previous patch, it is no longer needed
329 to reorder ritem itself.
330
331 * src/reduce.c (reduce_grammar_tables): Don't sort RITEM.
332
333 2002-04-07 Akim Demaille <akim@epita.fr>
334
335 Be sure never to walk through RITEMS, but use only data related to
336 the rules themselves. RITEMS should be banished.
337
338 * src/output.c (output_token_translations): Rename as...
339 (prepare_tokens): this.
340 In addition to `translate', prepare the muscles `tname' and
341 `toknum', which were handled by...
342 (output_rule_data): this.
343 Remove, and move the remainder of its outputs into...
344 (prepare_rules): this new routines, which also merges content from
345 (output_gram): this.
346 (prepare_rules): Be sure never to walk through RITEMS.
347 (output_stos): Rename as...
348 (prepare_stos): this.
349 (output): Always invoke prepare_states, after all, just don't use it
350 in the output if you don't need it.
351
352 2002-04-07 Akim Demaille <akim@epita.fr>
353
354 * src/LR0.c (new_state): Display `nstates' as the name of the
355 newly created state.
356 Adjust to initialize first_state and last_state if needed.
357 Be sure to distinguish the initial from the final state.
358 (new_states): Create the itemset of the initial state, and use
359 new_state.
360 * src/closure.c (closure): Now that the initial state has its
361 items properly set, there is no need for a special case when
362 creating `ruleset'.
363
364 As a result, now the rule 0, reducing to $axiom, is visible in the
365 outputs. Adjust the test suite.
366
367 * tests/conflicts.at (Solved SR Conflicts)
368 (Unresolved SR Conflicts): Adjust.
369 * tests/regression.at (Web2c Report, Rule Line Numbers): Idem.
370 * tests/conflicts.at (S/R in initial): New.
371
372 2002-04-07 Akim Demaille <akim@epita.fr>
373
374 * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over
375 the RHS of the rules.
376 * src/output.c (output_gram): Likewise.
377
378 2002-04-07 Akim Demaille <akim@epita.fr>
379
380 * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's
381 bucket.
382 Adjust all dependencies.
383 * src/reduce.c (nonterminals_reduce): Don't forget to renumber the
384 `number' of the buckets too.
385 * src/gram.h: Include `symtab.h'.
386 (associativity): Move to...
387 * src/symtab.h: here.
388 No longer include `gram.h'.
389
390 2002-04-07 Akim Demaille <akim@epita.fr>
391
392 * src/gram.h, src/gram.c (rules_rhs_length): New.
393 (ritem_longest_rhs): Use it.
394 * src/gram.h (rule_t): `number' is a new member.
395 * src/reader.c (packgram): Set it.
396 * src/reduce.c (reduce_grammar_tables): Move the useless rules at
397 the end of `rules', and count them out of `nrules'.
398 (reduce_output, dump_grammar): Adjust.
399 * src/print.c (print_grammar): It is no longer needed to check for
400 the usefulness of a rule, as useless rules are beyond `nrules + 1'.
401 * tests/reduce.at (Reduced Automaton): New test.
402
403 2002-04-07 Akim Demaille <akim@epita.fr>
404
405 * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a
406 lacking `+ 1' to nrules, Bison reported as useless a token if it
407 was used solely to set the precedence of the last rule...
408
409 2002-04-07 Akim Demaille <akim@epita.fr>
410
411 * data/bison.c++, data/bison.simple: Don't output the current file
412 name in #line, to avoid useless diffs between two identical
413 outputs under different names.
414
415 2002-04-07 Akim Demaille <akim@epita.fr>
416
417 * src/closure.c, src/print.c, src/reader.c, src/reduce.c:
418 Normalize loops to using `< nrules + 1', not `<= nrules'.
419
420 2002-04-07 Akim Demaille <akim@epita.fr>
421
422 * TODO: Update.
423
424 2002-04-07 Akim Demaille <akim@epita.fr>
425
426 * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename
427 bucket.value as bucket.number.
428
429 2002-04-07 Akim Demaille <akim@epita.fr>
430
431 * src/closure.c, src/derives.c, src/gram.h, src/lalr.c,
432 * src/nullable.c, src/output.c, src/print.c, src/print_graph.c,
433 * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the
434 RHS, instead of being an index in RITEMS.
435
436 2002-04-04 Paul Eggert <eggert@twinsun.com>
437
438 * doc/bison.texinfo: Update copyright date.
439 (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII.
440 (Symbols): Warn about running Bison in one character set,
441 but compiling and/or running in an incompatible one.
442 Warn about character code 256, too.
443
444 2002-04-03 Paul Eggert <eggert@twinsun.com>
445
446 * src/bison.data (YYSTACK_ALLOC): Depend on whether
447 YYERROR_VERBOSE is nonzero, not whether it is defined.
448
449 Merge changes from bison-1_29-branch.
450
451 2002-03-20 Paul Eggert <eggert@twinsun.com>
452
453 Merge fixes from Debian bison_1.34-1.diff.
454
455 * configure.in (AC_PREREQ): 2.53.
456
457 2002-03-20 Akim Demaille <akim@epita.fr>
458
459 * src/conflicts.c (log_resolution): Argument `resolution' is const.
460
461 2002-03-19 Paul Eggert <eggert@twinsun.com>
462
463 * src/bison.simple (YYCOPY): New macro.
464 (YYSTACK_RELOCATE): Use it.
465 Remove Type arg; no longer needed. All callers changed.
466 (yymemcpy): Remove; no longer needed.
467
468 * Makefile.am (AUTOMAKE_OPTIONS): 1.6.
469 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove.
470
471 2002-03-19 Akim Demaille <akim@epita.fr>
472
473 Test and fix the #line outputs.
474
475 * tests/atlocal.at (GCC): New.
476 * tests/synclines.at (AT_TEST_SYNCLINE): New macro.
477 (Prologue synch line, ,%union synch line, Postprologue synch line)
478 (Action synch line, Epilogue synch line): New tests.
479 * src/reader.c (parse_union_decl): Define the muscle stype_line.
480 * data/bison.simple, data/bison.c++: Use it.
481
482 2002-03-19 Akim Demaille <akim@epita.fr>
483
484 * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts)
485 (Solved SR Conflicts, %expect not enough, %expect right)
486 (%expect too much): Move to...
487 * tests/conflicts.at: this new file.
488
489 2002-03-19 Akim Demaille <akim@epita.fr>
490
491 * data/m4sugar/m4sugar.m4: Update from CVS Autoconf.
492 * data/bison.simple, data/bison.c++: Handle the `#define' part, so
493 that we can move to enums for instance.
494 * src/output.c (token_definitions_output): Output a list of
495 `token-name, token-number' instead of the #define.
496 (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'.
497
498 2002-03-14 Akim Demaille <akim@epita.fr>
499
500 Use Gettext 0.11.1.
501
502 2002-03-09 Robert Anisko <robert@lrde.epita.fr>
503
504 * data/bison.c++: Make the user able to add members to the generated
505 parser by subclassing.
506
507 2002-03-05 Robert Anisko <robert@lrde.epita.fr>
508
509 * src/reader.c (read_additionnal_code): `c' should be an integer, not
510 a character.
511 Reported by Nicolas Tisserand and Nicolas Burrus.
512
513 2002-03-04 Robert Anisko <robert@lrde.epita.fr>
514
515 * src/reader.c: Warn about lacking semi-colons, do not complain.
516
517 2002-03-04 Robert Anisko <robert@lrde.epita.fr>
518
519 * data/bison.c++: Remove a debug line.
520
521 2002-03-04 Robert Anisko <robert@lrde.epita.fr>
522
523 * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge
524 location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and
525 provide a default implementation.
526
527 2002-03-04 Akim Demaille <akim@epita.fr>
528
529 * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'.
530 * tests/output.at (AT_CHECK_OUTPUT): Likewise.
531 * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto.
532 * tests/semantic.at (Parsing Guards): Similarly.
533 * src/reader.at (readgram): Complain if the last rule is not ended
534 with a semi-colon.
535
536 2002-03-04 Akim Demaille <akim@epita.fr>
537
538 * src/warshall.h, src/warshall.c (bitmatrix_print): Move to...
539 * src/closure.c: here.
540 (set_firsts): Use bitsetv_reflexive_transitive_closure instead of
541 RTC.
542 * src/warshall.h, src/warshall.c: Remove.
543 * tests/sets.at (Broken Closure): Adjust.
544
545 2002-03-04 Akim Demaille <akim@epita.fr>
546
547 * src/output.c (output_skeleton): tempdir is const.
548 bytes_read is unused.
549
550 2002-03-04 Akim Demaille <akim@epita.fr>
551
552 * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c,
553 * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c:
554 Update.
555 From Michael Hayes.
556
557 2002-03-04 Akim Demaille <akim@epita.fr>
558
559 * src/closure.c (closure): `r' is unused.
560
561 2002-03-04 Akim Demaille <akim@epita.fr>
562
563 * tests/sets.at (Broken Closure): Add the ending `;'.
564 * src/reader.at (readgram): Complain if a rule is not ended with a
565 semi-colon.
566
567 2002-03-04 Akim Demaille <akim@epita.fr>
568
569 * src/conflicts.c (set_conflicts): Use bitset_disjoint_p.
570 (count_sr_conflicts): Use bitset_count.
571 * src/reduce.c (inaccessable_symbols): Ditto.
572 (bits_size): Remove.
573 * src/warshall.h, src/warshall.c: Convert to bitsetv.
574
575 2002-03-04 Akim Demaille <akim@epita.fr>
576
577 * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c,
578 * src/reduce.c: Remove the `bitset_zero's following the
579 `bitset_create's, as now it is performed by the latter.
580
581 2002-03-04 Akim Demaille <akim@epita.fr>
582
583 * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h,
584 * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h,
585 * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the
586 latest sources from Michael.
587
588 2002-03-04 Akim Demaille <akim@epita.fr>
589
590 * src/output.c (output): Don't free the grammar.
591 * src/reader.c (grammar_free): New.
592 * src/main.c (main): Call it and don't free symtab here.
593
594 2002-03-04 Akim Demaille <akim@epita.fr>
595
596 * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer
597 before returning.
598 Reported by Benoit Perrot.
599
600 2002-03-04 Akim Demaille <akim@epita.fr>
601
602 Use bitset operations when possible, not loops over bits.
603
604 * src/conflicts.c (set_conflicts, count_sr_conflicts): Use
605 bitset_or.
606 * src/print.c (print_reductions): Use bitset_and, bitset_andn.
607 * src/reduce.c (useless_nonterminals): Formatting changes.
608 * src/warshall.c (TC): Use bitset_or.
609
610 2002-03-04 Akim Demaille <akim@epita.fr>
611
612 * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused.
613 * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET):
614 Ditto.
615
616 2002-03-04 Akim Demaille <akim@epita.fr>
617
618 * src/lalr.c (F): Now a bitset*.
619 Adjust all dependencies.
620
621 2002-03-04 Akim Demaille <akim@epita.fr>
622
623 * src/conflicts.c (shiftset, lookaheadset): Now bitset.
624 Adjust all dependencies.
625
626 2002-03-04 Akim Demaille <akim@epita.fr>
627
628 * src/L0.c, src/LR0.h (nstates): Be size_t.
629 Adjust comparisons (signed vs unsigned).
630 * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a
631 bitset*.
632 Adjust all dependencies.
633
634 2002-03-04 Akim Demaille <akim@epita.fr>
635
636 * src/closure.c (firsts): Now, also a bitset.
637 Adjust all dependencies.
638 (varsetsize): Remove, now unused.
639 * src/warshall.h, src/warshall.c: Now work on arrays of bitsets.
640
641 2002-03-04 Akim Demaille <akim@epita.fr>
642
643 * src/print.c: Convert to use bitset.h, not hand coded iterations
644 over ints.
645
646 2002-03-04 Akim Demaille <akim@epita.fr>
647
648 * src/reduce.c: Convert to use bitset.h, not hand coded BSet.
649
650 2002-03-04 Akim Demaille <akim@epita.fr>
651
652 * src/closure.c (ruleset): Be a bitset.
653 (rulesetsize): Remove.
654
655 2002-03-04 Akim Demaille <akim@epita.fr>
656
657 * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c,
658 * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c,
659 * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New.
660 * src/closure.c (fderives): Be an array of bitsets.
661
662 2002-02-28 Robert Anisko <robert@lrde.epita.fr>
663
664 * data/bison.c++: Merge the two generated headers. Insert a copyright
665 notice in each output file.
666
667 2002-02-28 Akim Demaille <akim@epita.fr>
668
669 * data/bison.c++: Copy the prologue of bison.simple to fetch
670 useful M4 definitions, such as b4_header_guard.
671
672 2002-02-25 Akim Demaille <akim@epita.fr>
673
674 * src/getargs.c (version): Give the name of the authors, and use a
675 translator friendly scheme for the bgr
676 copyright notice.
677
678 2002-02-25 Akim Demaille <akim@epita.fr>
679
680 * src/output.c (header_output): Remove, now handled completely via
681 M4.
682
683 2002-02-25 Akim Demaille <akim@epita.fr>
684
685 * m4/m4.m4: New, from CVS Autoconf.
686 * configure.in: Invoke it.
687 * src/output.c (output_skeleton): Use its result instead of the
688 hard coded name.
689
690 2002-02-25 Akim Demaille <akim@epita.fr>
691
692 * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from
693 Fileutils 4.1.5.
694 * configure.in: Invoke UTILS_FUNC_MKSTEMP.
695 * src/output.c (output_skeleton): Use mkstemp to create a real
696 temporary file.
697 Move the filling of `skeleton' and its muscle to...
698 (prepare): here.
699 (output): Move the definition of the prologue muscle to...
700 (prepare): here.
701 * src/system.h (DEFAULT_TMPDIR): New.
702
703 2002-02-14 Paul Eggert <eggert@twinsun.com>
704
705 Remove the support for C++ namespace cleanliness; it was
706 causing more problems than it was curing, since it didn't work
707 properly on some nonstandard C++ compilers. This can wait
708 for a proper C++ parser.
709
710 * NEWS: Document this.
711 * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention
712 of C++, as it's treated like C now.
713 * src/bison.simple (YYSTD): Remove.
714 (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL):
715 Treat C++ just like Standard C instead of trying to support
716 namespace cleanliness.
717
718 2002-02-14 Akim Demaille <akim@epita.fr>
719
720 * tests/regression.at (else): Adjust to Andreas' change.
721
722 2002-02-14 Akim Demaille <akim@epita.fr>
723
724 * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c.
725
726 2002-02-13 Andreas Schwab <schwab@suse.de>
727
728 * src/output.c (output_rule_data): Don't output NULL, it might
729 not be defined yet.
730
731 2002-02-11 Robert Anisko <robert@lrde.epita.fr>
732
733 * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue.
734 (Copyright notice): Update.
735
736 2002-02-11 Akim Demaille <akim@epita.fr>
737
738 * tests/regression.at (%nonassoc and eof): Don't include
739 nonportable headers.
740
741 2002-02-08 Robert Anisko <robert@lrde.epita.fr>
742
743 * data/bison.c++: Correct error recovery. Make the user able to
744 initialize the starting location.
745
746 2002-02-07 Akim Demaille <akim@epita.fr>
747
748 * tests/input.at: New.
749
750 2002-02-07 Robert Anisko <robert@lrde.epita.fr>
751
752 * data/bison.c++: Replace some direct m4 expansions by constants. Be
753 more consistent when naming methods and variables. Put preprocessor
754 directives around tables only needed for debugging.
755
756 2002-02-07 Robert Anisko <robert@lrde.epita.fr>
757
758 * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in
759 C++ parsers.
760 (yy::b4_name::parse): Use print_.
761
762 2002-02-07 Robert Anisko <robert@lrde.epita.fr>
763
764 * data/bison.c++ (yy::b4_name::parse): Error recovery is back.
765
766 2002-02-07 Robert Anisko <robert@lrde.epita.fr>
767
768 * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in
769 C++ parsers.
770 (yy::b4_name::parse): Build verbose error messages, and use error_.
771
772 2002-02-06 Robert Anisko <robert@lrde.epita.fr>
773
774 * data/bison.c++: Fix m4 quoting in comments.
775
776 2002-02-06 Robert Anisko <robert@lrde.epita.fr>
777
778 * data/bison.c++: Adjust the parser code. Fix some muscles that were
779 not expanded by m4.
780
781 2002-02-05 Akim Demaille <akim@epita.fr>
782
783 * data/bison.c++: Adjust to the M4 back end.
784 More is certainly needed.
785
786 2002-02-05 Akim Demaille <akim@epita.fr>
787
788 Give a try to M4 as a back end.
789
790 * lib/readpipe.c: New, from wdiff.
791 * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and
792 BISON_HAIRY.
793 * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS
794 specific values. Now it is m4 that performs the lookup.
795 * src/parse-skel.y: Remove.
796 * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New.
797 * src/output.c (actions_output, guards_output)
798 (token_definitions_output): No longer keeps track of the output
799 line number, hence remove the second argument.
800 (guards_output): Check against the guard member of a rule, not the
801 action member.
802 Adjust callers.
803 (output_skeleton): Don't look for the skeleton location, let m4 do
804 that.
805 Create `/tmp/muscles.m4'. This is temporary, a proper temporary
806 file will be used.
807 Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton.
808 (prepare): Given that for the time being changesyntax is not
809 usable in M4, rename the muscles using `-' to `_'.
810 Define `defines_flag', `output_parser_name' and `output_header_name'.
811 * src/output.h (actions_output, guards_output)
812 (token_definitions_output): Adjust prototypes.
813 * src/scan-skel.l: Instead of scanning the skeletons, it now
814 processes the output of m4: `__oline__' and `#output'.
815 * data/bison.simple: Adjust to be used by M4(sugar).
816 * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up
817 to date.
818 * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR'
819 instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'.
820 * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New,
821 shamelessly stolen from CVS Autoconf.
822
823 2002-02-05 Akim Demaille <akim@epita.fr>
824
825 * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version.
826 * configure.in: Check for the declarations of free and malloc.
827 * src/muscle_tab.c: Adjust.
828
829 2002-02-05 Akim Demaille <akim@epita.fr>
830
831 * src/muscle_tab.c (muscle_init): Don't default to NULL muscle
832 which have no values.
833
834 2002-02-05 Akim Demaille <akim@epita.fr>
835
836 * src/bison.simple, src/bison.hairy, src/bison.c++: Move to...
837 * data/: here.
838
839 2002-01-29 Paul Eggert <eggert@twinsun.com>
840
841 * src/bison.simple (YYSIZE_T): Do not define merely because
842 YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined.
843 On some platforms, <alloca.h> does not declare YYSTD (size_t).
844
845 2002-01-27 Akim Demaille <akim@epita.fr>
846
847 Fix `%nonassoc and eof'.
848
849 * src/state.c (errs_dup): Aaaah! The failure was due to bytes
850 which were not properly copied! Replace
851 memcpy (res->errs, src->errs, src->nerrs);
852 with
853 memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0]));
854 !!!
855 * tests/regression.at (%nonassoc and eof): Adjust to newest
856 Autotest: `.' is not in the PATH.
857
858 2002-01-27 Akim Demaille <akim@epita.fr>
859
860 * tests/sets.at (AT_EXTRACT_SETS): New.
861 (Nullable): Use it.
862 (Firsts): New.
863
864 2002-01-26 Akim Demaille <akim@epita.fr>
865
866 * tests/actions.at, tests/calc.at, tests/headers.at,
867 * tests/torture.at: Adjust to the newest Autotest which no longer
868 forces `.' in the PATH.
869
870 2002-01-25 Akim Demaille <akim@epita.fr>
871
872 * tests/regression.at (%nonassoc and eof): New.
873 Suggested by Robert Anisko.
874
875 2002-01-24 Akim Demaille <akim@epita.fr>
876
877 Bison dumps core when trying to complain about broken input files.
878 Reported by Cris van Pelt.
879
880 * src/lex.c (parse_percent_token): Be sure to set token_buffer.
881 * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge
882 into...
883 (Invalid inputs): Strengthen: exercise parse_percent_token.
884
885 2002-01-24 Robert Anisko <robert.anisko@epita.fr>
886
887 * src/Makefile.am: Add bison.c++.
888 * src/bison.c++: New skeleton.
889
890 2002-01-21 Paolo Bonzini <bonzini@gnu.org>
891
892 * po/it.po: New.
893
894 2002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net>
895
896 * src/files.c (skeleton_find) [MSDOS]: Fix cp definition.
897
898 2002-01-20 Marc Autret <marc@gnu.org>
899
900 * src/files.c (compute_output_file_names): Fix
901
902 2002-01-20 Marc Autret <marc@gnu.org>
903
904 * tests/output.at: New test.
905 * src/files.c (compute_base_names): Don't map extensions when
906 the YACC flag is set, use defaults.
907 Reported by Evgeny Stambulchik.
908
909 2002-01-20 Marc Autret <marc@gnu.org>
910
911 * src/system.h: Need to define __attribute__ away for non-GCC
912 compilers as well (i.e. the vendor C compiler).
913 Suggested by Albert Chin-A-Young.
914
915 2002-01-11 Tim Van Holder <tim.van.holder@pandora.be>
916
917 * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the
918 canonical definition.
919 * src/system.h: Use the canonical definition for PARAMS (avoids
920 a conflict with the macro from lib/hash.h).
921
922 2002-01-11 Akim Demaille <akim@epita.fr>
923
924 * configure.in: Use AC_FUNC_STRNLEN.
925 Fixes the failures observed on AIX 4.3 by H.Merijn Brand.
926
927 2002-01-09 Akim Demaille <akim@epita.fr>
928
929 * src/files.c, src/files.h (output_infix): New.
930 (tab_extension): Remove.
931 (compute_base_names): Compute the former, drop the latter.
932 * src/output.c (prepare): Insert the muscles `output-infix', and
933 `output-suffix'.
934 * src/parse-skel.y (string, string.1): New.
935 (section.header): Use it.
936 (section.yacc): Remove.
937 (prefix): Remove too.
938 * src/scan-skel.l: Adjust.
939 * src/bison.simple, src/bison.hairy: Adjust.
940
941 2002-01-09 Akim Demaille <akim@epita.fr>
942
943 * configure.in (WERROR_CFLAGS): Compute it.
944 * src/Makefile.am (CFLAGS): Pass it.
945 * tests/atlocal.in (CFLAGS): Idem.
946 * src/files.c: Fix a few warnings.
947 (get_extension_index): Remove, unused.
948
949 2002-01-08 Akim Demaille <akim@epita.fr>
950
951 * src/getargs.c (AS_FILE_NAME): New.
952 (getargs): Use it to convert DOSish file names.
953 * src/files.c (base_name): Rename as full_base_name to avoid
954 clashes with `base_name ()'.
955 (filename_split): New.
956 (compute_base_names): N-th rewrite, using filename_split.
957
958 2002-01-08 Akim Demaille <akim@epita.fr>
959
960 * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c:
961 New, stolen from the Fileutils 4.1.
962 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
963 * configure.in: Check for the presence of memrchr, and of its
964 prototype.
965
966 2002-01-07 Tim Van Holder <tim.van.holder@pandora.be>
967
968 * lib/hash.h (__P): Added definition for this macro.
969 * src/Makefile.am: Add parse-skel.c and scan-skel.c to
970 BUILT_SOURCES, to ensure they are generated first.
971 * src/parse-skel.y: Use YYERROR_VERBOSE instead of
972 %error-verbose to allow bootstrapping with bison 1.30x.
973
974 2002-01-06 Akim Demaille <akim@epita.fr>
975
976 * src/reader.c (parse_braces): Don't fetch the next char, the
977 convention is to fetch on entry.
978 * tests/torture.at (GNU Cim Grammar): Reintroduce their weird
979 'switch' without a following semicolon.
980 * tests/regression.at (braces parsing): New.
981
982 2002-01-06 Akim Demaille <akim@epita.fr>
983
984 Bison is dead wrong in its RR conflict reports.
985
986 * tests/torture.at (GNU Cim Grammar): New.
987 * src/conflicts.c (count_rr_conflicts): Fix.
988
989 2002-01-06 Akim Demaille <akim@epita.fr>
990
991 Creating package.m4 from configure.ac causes too many problems.
992
993 * tests/Makefile.am (package.m4): Create it by hand,
994 AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf.
995
996 2002-01-06 Akim Demaille <akim@epita.fr>
997
998 * src/Makefile.am (bison_SOURCES): Add parse-skel.h and
999 skeleton.h.
1000
1001 2002-01-04 Paul Eggert <eggert@twinsun.com>
1002
1003 * doc/bison.texinfo (Debugging):
1004 Remove YYSTDERR; it's no longer defined or used.
1005 Also, s/cstdio.h/cstdio/.
1006
1007 2002-01-03 Akim Demaille <akim@epita.fr>
1008
1009 * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf.
1010
1011 2002-01-03 Akim Demaille <akim@epita.fr>
1012
1013 * src/parse-skel.y (process_skeleton): Don't bind the parser's
1014 tracing code to --trace, wait for a better --trace option, with
1015 args.
1016
1017 2002-01-03 Akim Demaille <akim@epita.fr>
1018
1019 * src/bison.simple (YYSTDERR): Remove, replace `stderr'.
1020 The ISO C++ standard is extremely clear about it: stderr is
1021 considered a macro, not a regular symbol (see table 94 `Header
1022 <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files).
1023 Therefore std:: does not apply to it. It still does with fprintf.
1024 Also, s/cstdio.h/cstdio/.
1025
1026 2002-01-03 Akim Demaille <akim@epita.fr>
1027
1028 * lib/quotearg.c: Use `#include "..."' instead of `#include <...>'
1029 for non system headers.
1030
1031 2002-01-02 Akim Demaille <akim@epita.fr>
1032
1033 Equip the skeleton chain with location tracking, runtime trace,
1034 pure parser and scanner.
1035
1036 * src/parse-skel.y: Request a pure parser, locations, and prefix
1037 renaming.
1038 (%union): Having several members with the same type does not help
1039 type mismatches, simplify.
1040 (YYPRINT, yyprint): New.
1041 (yyerror): ``Rename'' (there is a #define yyerror skel_error) as...
1042 (skel_error): this.
1043 Handle locations.
1044 * src/scan-skel.l: Adjust to these changes.
1045 * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP)
1046 (LOCATION_PRINT, skel_control_t): New.
1047
1048 2001-12-30 Akim Demaille <akim@epita.fr>
1049
1050 * src/parse-skel.y: Get rid of the shift/reduce conflict:
1051 replace `gb' with BLANKS.
1052 * src/scan-skel.l: Adjust.
1053
1054 2001-12-30 Akim Demaille <akim@epita.fr>
1055
1056 * src/system.h: We don't need nor want bcopy.
1057 Throw away MS-DOS crap: we don't need getpid.
1058 * configure.in: We don't need strndup. It was even causing
1059 problems: because Flex includes the headers *before* us,
1060 _GNU_SOURCE is not defined by config.h, and therefore strndup was
1061 not visible.
1062 * lib/xstrndup.c: New.
1063 * src/scan-skel.l: Use it.
1064 Be sure to initialize yylval.muscle member when scanning a MUSCLE.
1065 * src/parse-skel.y: Use %directives instead of #defines.
1066
1067 2001-12-30 Akim Demaille <akim@epita.fr>
1068
1069 * src/skeleton.h: New.
1070 * src/output.c (output_parser, output_master_parser): Remove, dead
1071 code.
1072 * src/output.h (get_lines_number, actions_output, guards_output)
1073 (token_definitions_output): Prototype them.
1074 * src/parse-skel.y: Add the license notice.
1075 Include output.h and skeleton.h.
1076 (process_skeleton): Returns void, and takes a single parameter.
1077 * src/scan-skel.l: Add the license notice.
1078 Include skeleton.h.
1079 Don't use %option yylineno: it seems that then Flex imagines
1080 REJECT has been used, and therefore it won't reallocate its
1081 buffers (which makes no other sense to me than a bug). It results
1082 in warnings for `unused: yy_flex_realloc'.
1083
1084 2001-12-30 Robert Anisko <robert.anisko@epita.fr>
1085
1086 * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING)
1087 (MUSCLE_INSERT_PREFIX): ...to there.
1088 * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING)
1089 (MUSCLE_INSERT_PREFIX): Move from here...
1090
1091 * src/bison.hairy: Add a section directive. Put braces around muscle
1092 names. This parser skeleton is still broken, but Bison should not
1093 choke on a bad muscle 'syntax'.
1094 * src/bison.simple: Add a section directive. Put braces around muscle
1095 names.
1096
1097 * src/files.h (strsuffix, stringappend): Add declarations.
1098 (tab_extension): Add declaration.
1099 (short_base_name): Add declaration.
1100
1101 * src/files.c (strsuffix, stringappend): No longer static. These
1102 functions are used in the skeleton parser.
1103 (tab_extension): New.
1104 (compute_base_names): Use the computations done in this function
1105 to guess if the generated parsers should have '.tab' in their
1106 names.
1107 (short_base_name): No longer static.
1108
1109 * src/output.c (output_skeleton): New.
1110 (output): Disable call to output_master_parser, and give a try to
1111 a new skeleton handling system.
1112 (guards_output, actions_output): No longer static.
1113 (token_definitions_output, get_lines_number): No longer static.
1114
1115 * configure.in: Use AM_PROG_LEX and AC_PROG_YACC.
1116
1117 * src/Makefile.am (bison_SOURCES): Add scan-skel.l and
1118 parse-skel.y.
1119
1120 * src/parse-skel.y: New file.
1121 * src/scan-skel.l: New file.
1122
1123 2001-12-29 Akim Demaille <akim@epita.fr>
1124
1125 %name-prefix is broken.
1126
1127 * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy".
1128 Adjust all dependencies.
1129 * tests/headers.at (export YYLTYPE): Strengthen this test: use
1130 %name-prefix.
1131
1132 Renaming yylval but not yylloc is not consistent. Now we do.
1133
1134 * src/bison.simple: Prefix yylloc if used.
1135 * doc/bison.texinfo (Decl Summary): Document that.
1136
1137 2001-12-29 Akim Demaille <akim@epita.fr>
1138
1139 * doc/bison.texinfo: Promote `%long-directive' over
1140 `%long_directive'.
1141 Remove all references to fixed-output-files, yacc is enough.
1142
1143 2001-12-29 Akim Demaille <akim@epita.fr>
1144
1145 * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the
1146 user prologue. These are defaults.
1147 * tests/actions.at (Mid-rule actions): Make sure the user can
1148 define YYDEBUG and YYERROR_VERBOSE.
1149
1150 2001-12-29 Akim Demaille <akim@epita.fr>
1151
1152 * src/output.c (header_output): Don't forget to export YYLTYPE and
1153 yylloc.
1154 * tests/headers.at (export YYLTYPE): New, make sure it does.
1155 * tests/regression.at (%union and --defines, Invalid CPP headers):
1156 Move to...
1157 * tests/headers.at: here.
1158
1159 2001-12-29 Akim Demaille <akim@epita.fr>
1160
1161 * src/gram.h (rule_s): Member `assoc' is of type `associativity'.
1162
1163 2001-12-29 Akim Demaille <akim@epita.fr>
1164
1165 * tests/actions.at (Mid-rule actions): Output on a single line
1166 instead of several.
1167
1168 2001-12-29 Akim Demaille <akim@epita.fr>
1169
1170 * doc/bison.texinfo: Formatting changes.
1171
1172 2001-12-29 Akim Demaille <akim@epita.fr>
1173
1174 Don't store the token defs in a muscle, just be ready to output it
1175 on command. Now possible via `symbols'. Fixes a memory leak.
1176
1177 * src/output.c (token_definitions_output): New.
1178 (output_parser, header_output): Use it.
1179 * src/reader.c (symbols_save): Remove.
1180
1181 2001-12-29 Akim Demaille <akim@epita.fr>
1182
1183 * src/bison.simple: Do not provide a default for YYSTYPE and
1184 YYLTYPE before the user's prologue. Otherwise it's hardly... a
1185 default.
1186
1187 2001-12-29 Akim Demaille <akim@epita.fr>
1188
1189 Mid-rule actions are simply... ignored!
1190
1191 * src/reader.c (readgram): Be sure to attach mid-rule actions to
1192 the empty-rule associated to the dummy symbol, not to the host
1193 rule.
1194 * tests/actions.at (Mid-rule actions): New.
1195
1196 2001-12-29 Akim Demaille <akim@epita.fr>
1197
1198 Memory leak.
1199
1200 * src/reader.c (reader): Free grammar.
1201
1202 2001-12-29 Akim Demaille <akim@epita.fr>
1203
1204 Memory leak.
1205
1206 * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here,
1207 since it allocates it for each state, although only one is needed.
1208 (allocate_storage): Do it here.
1209
1210 2001-12-29 Akim Demaille <akim@epita.fr>
1211
1212 * src/options.h, src/options.c (create_long_option_table): Rename
1213 as...
1214 (long_option_table_new): this, with a clearer prototype.
1215 (percent_table): Remove, unused,
1216 * src/getargs.c (getargs): Adjust.
1217
1218 2001-12-29 Akim Demaille <akim@epita.fr>
1219
1220 * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c
1221 * src/print.c, src/print_graph.c, src/state.h: Rename state_table
1222 as states.
1223
1224 2001-12-29 Akim Demaille <akim@epita.fr>
1225
1226 * src/lalr.c (build_relations): Rename `states' as `states1'.
1227 Sorry, I don't understand exactly what it is, no better name...
1228
1229 2001-12-29 Akim Demaille <akim@epita.fr>
1230
1231 * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c
1232 * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c
1233 * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table
1234 as rules.
1235
1236 2001-12-29 Akim Demaille <akim@epita.fr>
1237
1238 * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long
1239 ago.
1240
1241 2001-12-29 Akim Demaille <akim@epita.fr>
1242
1243 * src/reader.c, src/reader.h (user_toknums): Remove.
1244 Adjust all users to use symbols[i]->user_token_number.
1245
1246 2001-12-29 Akim Demaille <akim@epita.fr>
1247
1248 * src/gram.c, src/gram.h (sprec, sassoc): Remove.
1249 Adjust all users to use symbols[i]->prec or ->assoc.
1250
1251 2001-12-29 Akim Demaille <akim@epita.fr>
1252
1253 * src/reader.c, src/reader.h (tags): Remove.
1254 Adjust all users to use symbols[i]->tag.
1255
1256 2001-12-29 Akim Demaille <akim@epita.fr>
1257
1258 * src/gram.h, src/gram.c (symbols): New, similar to state_table
1259 and rule_table.
1260 * src/reader.c (packsymbols): Fill this table.
1261 Drop sprec.
1262 * src/conflicts.c (resolve_sr_conflict): Adjust.
1263 * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a
1264 single table.
1265 Use symbols[i]->tag instead of tags[i].
1266
1267 2001-12-29 Akim Demaille <akim@epita.fr>
1268
1269 * tests/calc.at (_AT_DATA_CALC_Y): Also use %union.
1270 In addition, put a comment in there, to replace...
1271 * tests/regression.at (%union and C comments): Remove.
1272
1273 2001-12-29 Akim Demaille <akim@epita.fr>
1274
1275 * tests/regression.at (Web2c Actions): Blindly move the actual
1276 output as expected output. The contents *seem* right to me, but I
1277 can't pretend reading perfectly parser tables... Nonetheless, all
1278 the other tests pass correctly, the table look OK, even though the
1279 presence of `$axiom' is to be noted: AFAICS it is useless (but
1280 harmless).
1281
1282 2001-12-29 Akim Demaille <akim@epita.fr>
1283
1284 * src/reader.c (readgram): Don't add the rule 0 if there were no
1285 rules read. In other words, add it _after_ having performed
1286 grammar sanity checks.
1287 Fixes the `tests/regression.at (Invalid input: 1)' Failure.
1288
1289 2001-12-29 Akim Demaille <akim@epita.fr>
1290
1291 * tests/regression.at (Web2c Report): Catch up: the rule 0 is now
1292 visible, and some states have now a different number.
1293
1294 2001-12-29 Akim Demaille <akim@epita.fr>
1295
1296 * src/reader.c (readgram): Bind the initial rule's lineno to that
1297 of the first rule.
1298 * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts):
1299 (Solved SR Conflicts): Adjust rule 0's line number.
1300
1301 2001-12-29 Akim Demaille <akim@epita.fr>
1302
1303 Fix the `GAWK Grammar' failure.
1304
1305 * src/LR0.c (final_state): Initialize to -1 so that we do compute
1306 the reductions of the first state which was mistakenly confused
1307 with the final state because precisely final_state was initialized
1308 to 0.
1309 * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads,
1310 now noticed by Bison.
1311 * tests/regression.at (Rule Line Numbers): Adjust: state 0 does
1312 have a reduction on $default.
1313
1314 2001-12-29 Akim Demaille <akim@epita.fr>
1315
1316 * src/gram.c (ritem_print): Be sure to subtract 1 when displaying
1317 rule line numbers.
1318 * src/closure.c (print_closure): Likewise.
1319 * src/derives.c (print_derives): Likewise.
1320 * tests/sets.at (Nullable): Adjust: the rule numbers are correct
1321 now.
1322
1323 2001-12-29 Akim Demaille <akim@epita.fr>
1324
1325 * src/lalr.c (lookaheads_print): New.
1326 (lalr): Call it when --trace-flag.
1327 * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads
1328 are dumped.
1329
1330 2001-12-29 Akim Demaille <akim@epita.fr>
1331
1332 * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0',
1333 when walking through ritem, even via rule->rhs.
1334 * src/reduce.c (dump_grammar, useful_production, reduce_output)
1335 (useful_production, useless_nonterminals): Likewise.
1336 (reduce_grammar_tables): Likewise, plus update nritems.
1337 * src/nullable.c (set_nullable): Likewise.
1338 * src/lalr.c (build_relations): Likewise.
1339 * tests/sets.at (Nullable): Adjust.
1340 Fortunately, now, the $axiom is no longer nullable.
1341
1342 2001-12-29 Akim Demaille <akim@epita.fr>
1343
1344 * src/LR0.c (generate_states): Use nritems, not nitems, nor using
1345 the 0-sentinel.
1346 * src/gram.c (ritem_longest_rhs): Likewise.
1347 * src/reduce.c (nonterminals_reduce): Likewise.
1348 * src/print_graph.c (print_graph): Likewise.
1349 * src/output.c (output_rule_data): Likewise.
1350 * src/nullable.c (set_nullable): Likewise.
1351
1352 2001-12-29 Akim Demaille <akim@epita.fr>
1353
1354 * src/output.c: Comment changes.
1355
1356 2001-12-27 Paul Eggert <eggert@twinsun.com>
1357
1358 * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special
1359 cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and
1360 Sparc, as they were causing more porting problems than the
1361 (minor) performance improvement was worth.
1362
1363 Also, catch up with 1.31's YYSTD.
1364
1365 2001-12-27 Akim Demaille <akim@epita.fr>
1366
1367 * src/output.c (output_gram): Rely on nritems, not the
1368 0-sentinel. See below.
1369 Use -1 as separator, not 0.
1370 * src/bison.simple (yyparse): Subtract 1 to the rule numbers.
1371 Rely on -1 as separator in yyrhs, instead of 0.
1372 * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue
1373 twice `Now at end of input', therefore there are two lines less to
1374 expect.
1375
1376 2001-12-27 Akim Demaille <akim@epita.fr>
1377
1378 * tests/regression.at (Unresolved SR Conflicts):
1379 (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes
1380 below.
1381
1382 2001-12-27 Akim Demaille <akim@epita.fr>
1383
1384 * src/LR0.c (new_state): Recognize the final state by the fact it
1385 is reached by eoftoken.
1386 (insert_start_shifting_state, insert_eof_shifting_state)
1387 (insert_accepting_state, augment_automaton): Remove, since now
1388 these states are automatically computed from the initial state.
1389 (generate_states): Adjust.
1390 * src/print.c: When reporting a rule number to the user, substract
1391 1, so that the axiom rule is rule 0, and the first user rule is 1.
1392 * src/reduce.c: Likewise.
1393 * src/print_graph.c (print_core): For the time being, just as for
1394 the report, depend upon --trace-flags to dump the full set of
1395 items.
1396 * src/reader.c (readgram): Once the grammar read, insert the rule
1397 0: `$axiom: START-SYMBOL $'.
1398 * tests/set.at: Adjust: rule 0 is now displayed, and since the
1399 number of the states has changed (the final state is no longer
1400 necessarily the last), catch up.
1401
1402 2001-12-27 Akim Demaille <akim@epita.fr>
1403
1404 Try to make the use of the eoftoken valid. Given that its value
1405 is 0 which was also used as a sentinel in ritem, (i) make sure >= 0
1406 is used instead of > 0 where appropriate, (ii), depend upon nritems
1407 instead of the 0-sentinel.
1408
1409 * src/gram.h, src/gram.c (nritems): New.
1410 Expected to be duplication of nitems, but for the time being...
1411 * src/reader.c (packgram): Assert nritems and nitems are equal.
1412 * src/LR0.c (allocate_itemsets, new_itemsets): Adjust.
1413 * src/closure.c (print_closure, print_fderives): Likewise.
1414 * src/gram.c (ritem_print): Likewise.
1415 * src/print.c (print_core, print_grammar): Likewise.
1416 * src/print_graph.c: Likewise.
1417
1418 2001-12-27 Akim Demaille <akim@epita.fr>
1419
1420 * src/main.c (main): If there are complains after grammar
1421 reductions, then output the report anyway if requested, then die.
1422 * src/symtab.c (bucket_new): Initialize `value' to -1, not 0.
1423 * src/reader.c (eoftoken): New.
1424 (parse_token_decl): If the token being defined has value `0', it
1425 is the eoftoken.
1426 (packsymbols): No longer hack `tags' to insert `$' by hand.
1427 Be sure to preserve the value of the eoftoken.
1428 (reader): Make sure eoftoken is defined.
1429 Initialize nsyms to 0: now eoftoken is created just like the others.
1430 * src/print.c (print_grammar): Don't special case the eof token.
1431 * src/regression.at: Adjust: `$' has value 0, not -1, which was a
1432 lie anyway, albeit pleasant.
1433 * tests/calc.at: Exercise error messages with eoftoken.
1434 Change the grammar so that empty input is invalid.
1435 Adjust expectations.
1436 When yyungeting, be sure to use a valid yylloc: use last_yylloc.
1437
1438 2001-12-27 Akim Demaille <akim@epita.fr>
1439
1440 * configure.in: Check the protos of strchr ans strspn.
1441 Replace strchr if needed.
1442 * src/system.h: Provide the protos of strchr, strspn and memchr if
1443 missing.
1444 * lib/strchr.c: New.
1445 * src/reader.c (symbols_save): Use strchr.
1446
1447 2001-12-27 Akim Demaille <akim@epita.fr>
1448
1449 * src/print.c, src/print_graph.c (escape): New.
1450 Use it to quote the TAGS outputs.
1451 * src/print_graph.c (print_state): Now errors are in red, and
1452 reductions in green.
1453 Prefer high to wide: output the state number on a line of its own.
1454
1455 2001-12-27 Akim Demaille <akim@epita.fr>
1456
1457 * src/state.h, src/state.c (reductions_new): New.
1458 * src/LR0.c (set_state_table): Let all the states have a
1459 `reductions', even if reduced to 0.
1460 (save_reductions): Adjust.
1461 * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust.
1462 * src/print.c (print_reductions, print_actions): Adjust.
1463 * src/output.c (action_row): Adjust.
1464
1465 2001-12-27 Akim Demaille <akim@epita.fr>
1466
1467 * src/state.h, src/state.c (errs_new, errs_dup): New.
1468 * src/LR0.c (set_state_table): Let all the states have an errs,
1469 even if reduced to 0.
1470 * src/print.c (print_errs, print_reductions): Adjust.
1471 * src/output.c (output_actions, action_row): Adjust.
1472 * src/conflicts.c (resolve_sr_conflict): Adjust.
1473
1474 2001-12-27 Akim Demaille <akim@epita.fr>
1475
1476 * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL.
1477
1478 2001-12-27 Akim Demaille <akim@epita.fr>
1479
1480 * src/conflicts.c, src/conflicts.h (print_reductions): Move to...
1481 * src/print.c: here.
1482 (lookaheadset, shiftset): New, used as additional storage by
1483 print_reductions.
1484 (print_results): Adjust.
1485 (print_shifts, print_gotos, print_errs): New, extracted from...
1486 (print_actions): here.
1487 * src/print_graph.c (print_actions): Remove dead code.
1488
1489 2001-12-27 Akim Demaille <akim@epita.fr>
1490
1491 * src/reader.c (copy_dollar, copy_at): Better checking of `n' in
1492 `$n' and `@n'.
1493
1494 2001-12-27 Akim Demaille <akim@epita.fr>
1495
1496 * src/lalr.c (add_lookback_edge): Use state_t instead of ints.
1497 (build_relations): Adjust.
1498
1499 2001-12-27 Akim Demaille <akim@epita.fr>
1500
1501 * src/lalr.c (set_goto_map): Remove a wrong but benign loop
1502 duplication.
1503
1504 2001-12-27 Akim Demaille <akim@epita.fr>
1505
1506 * src/reader.c (packgram): Catch nitems overflows.
1507
1508 2001-12-27 Akim Demaille <akim@epita.fr>
1509
1510 * src/files.c, src/files.h (guard_obstack): Remove.
1511 * src/output.c (output): Adjust.
1512 * src/reader.c (parse_braces): New, factoring...
1513 (copy_action, copy_guard): these two which are renamed as...
1514 (parse_action, parse_guard): these.
1515 As a voluntary consequence, using braces around guards is now
1516 mandatory.
1517
1518 2001-12-27 Akim Demaille <akim@epita.fr>
1519
1520 * src/gram.h (rule_t): `guard' and `guard_line' are new members.
1521 * src/reader.c (symbol_list): `guard' and `guard_line' are new
1522 members.
1523 (symbol_list_new): Adjust.
1524 (copy_action): action_line is the first line, not the last.
1525 (copy_guard): Just as for actions, store the `action' only, not
1526 the switch/case/break flesh.
1527 Don't parse the user action that might follow the guard, let...
1528 (readgram): do it, i.e., now, there can be an action after a
1529 guard.
1530 In other words the guard is just explicitly optional.
1531 (packgram): Adjust.
1532 * src/output.c (guards_output): New.
1533 (output_parser): Call it when needed.
1534 (output): Also free the guard and attrs obstacks.
1535 * src/files.c, src/files.h (obstack_save): Remove.
1536 (output_files): Remove.
1537 As a result, if one needs the former `.act' file, using an
1538 appropriate skeleton which requires actions and guards is now
1539 required.
1540 * src/main.c (main): Adjust.
1541 * tests/semantic.at: New.
1542 * tests/regression.at: Use `input.y' as input file name.
1543 Avoid 8+3 problems by requiring input.c when the test needs the
1544 parser.
1545
1546 2001-12-27 Akim Demaille <akim@epita.fr>
1547
1548 * src/reader.c (symbol_list_new): Be sure to initialize all the
1549 fields.
1550
1551 2001-12-27 Akim Demaille <akim@epita.fr>
1552
1553 All the hacks using a final pseudo state are now useless.
1554
1555 * src/LR0.c (set_state_table): state_table holds exactly nstates.
1556 * src/lalr.c (nLA): New.
1557 (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it
1558 instead of lookaheadsp from the pseudo state (nstate + 1).
1559
1560 2001-12-27 Akim Demaille <akim@epita.fr>
1561
1562 * src/output.c (action_row, token_actions): Use a state_t instead
1563 of a integer, and nlookaheads instead of the following state's
1564 lookaheadsp.
1565
1566 2001-12-27 Akim Demaille <akim@epita.fr>
1567
1568 * src/conflicts.c (log_resolution, flush_shift)
1569 (resolve_sr_conflict, set_conflicts, solve_conflicts)
1570 (count_sr_conflicts, count_rr_conflicts, conflicts_output)
1571 (conflicts_print, print_reductions): Use a state_t instead of an
1572 integer when referring to a state.
1573 As much as possible, depend upon nlookaheads, instead of the
1574 `lookaheadsp' member of the following state (since lookaheads of
1575 successive states are successive, the difference between state n + 1
1576 and n served as the number of lookaheads for state n).
1577 * src/lalr.c (add_lookback_edge): Likewise.
1578 * src/print.c (print_core, print_actions, print_state)
1579 (print_results): Likewise.
1580 * src/print_graph.c (print_core, print_actions, print_state)
1581 (print_graph): Likewise.
1582 * src/conflicts.h: Adjust.
1583
1584 2001-12-27 Akim Demaille <akim@epita.fr>
1585
1586 * src/bison.hairy: Formatting/comment changes.
1587 ANSIfy.
1588 Remove `register' indications.
1589 Add plenty of `static'.
1590
1591 2001-12-27 Akim Demaille <akim@epita.fr>
1592
1593 * src/output.c (prepare): Drop the muscle `ntbase' which
1594 duplicates ntokens.
1595 * src/bison.simple: Formatting/comment changes.
1596 Use YYNTOKENS only, which is documented, but not YYNTBASE, which
1597 is an undocumented synonym.
1598
1599 2001-12-22 Akim Demaille <akim@epita.fr>
1600
1601 * src/output.c (output_table_data): Change the prototype to use
1602 `int' for array ranges: some invocations do pass an int, not a
1603 short.
1604 Reported by Wayne Green.
1605
1606 2001-12-22 Akim Demaille <akim@epita.fr>
1607
1608 Some actions of web2c.y are improperly triggered.
1609 Reported by Mike Castle.
1610
1611 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
1612 * tests/regression.at (Web2c): Rename as...
1613 (Web2c Report): this.
1614 (Web2c Actions): New.
1615
1616 2001-12-22 Akim Demaille <akim@epita.fr>
1617
1618 Reductions in web2c.y are improperly reported.
1619 Reported by Mike Castle.
1620
1621 * src/conflicts.c (print_reductions): Fix.
1622 * tests/regression.at (Web2c): New.
1623
1624 2001-12-18 Akim Demaille <akim@epita.fr>
1625
1626 Some host fail on `assert (!"foo")', which expands to
1627 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
1628 Reported by Nelson Beebee.
1629
1630 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
1631 `#define it_succeeded 0' and `assert (it_succeeded)'.
1632
1633 2001-12-17 Marc Autret <autret_m@epita.fr>
1634
1635 * src/bison.simple: Don't hard code the skeleton line and filename.
1636 * src/output.c (output_parser): Rename 'line' as 'output_line'.
1637 New line counter 'skeleton_line' (skeleton-line muscle).
1638
1639 2001-12-17 Paul Eggert <eggert@twinsun.com>
1640
1641 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that
1642 YYDEBUG must be defined to a nonzero value.
1643
1644 * src/bison.simple (yytname): Do not assume that the user defines
1645 YYDEBUG to a properly parenthesized expression.
1646
1647 2001-12-17 Akim Demaille <akim@epita.fr>
1648
1649 * src/state.h (state_t): Rename lookaheads as lookaheadsp.
1650 nlookaheads is a new member.
1651 Adjust all users.
1652 * src/lalr.h (nlookaheads): Remove this orphan declaration.
1653 * src/lalr.c (initialize_lookaheads): Set nlookaheads for each
1654 state.
1655
1656 2001-12-17 Akim Demaille <akim@epita.fr>
1657
1658 * src/files.h, src/files.c (open_files, close_files): Remove.
1659 * src/main.c (main): Don't open/close files, nor invoke lex_free,
1660 let...
1661 * src/reader.c (reader): Do it.
1662
1663 2001-12-17 Akim Demaille <akim@epita.fr>
1664
1665 * src/conflicts.c (print_reductions): Formatting changes.
1666
1667 2001-12-17 Akim Demaille <akim@epita.fr>
1668
1669 * src/conflicts.c (flush_shift): Also adjust lookaheadset.
1670 (flush_reduce): New.
1671 (resolve_sr_conflict): Adjust.
1672
1673 2001-12-17 Akim Demaille <akim@epita.fr>
1674
1675 * src/output.c (output_obstack): Be static and rename as...
1676 (format_obstack): this, to avoid any confusion with files.c's
1677 output_obstack.
1678 * src/reader.h (muscle_obstack): Move to...
1679 * src/output.h: here, since it's defined in output.c.
1680
1681 2001-12-17 Akim Demaille <akim@epita.fr>
1682
1683 * src/output.c (action_row, save_column, default_goto)
1684 (sort_actions, matching_state, pack_vector): Better variable
1685 locality.
1686
1687 2001-12-17 Akim Demaille <akim@epita.fr>
1688
1689 * src/output.c: Various formatting changes.
1690
1691 2001-12-17 Akim Demaille <akim@epita.fr>
1692
1693 * src/files.c (output_files): Free the output_obstack.
1694 * src/main.c (main): Call print and print_graph conditionally.
1695 * src/print.c (print): Work unconditionally.
1696 * src/print_graph.c (print_graph): Work unconditionally.
1697 * src/conflicts.c (log_resolution): Output only if verbose_flag.
1698
1699 2001-12-16 Marc Autret <autret_m@epita.fr>
1700
1701 * src/output.c (actions_output): Fix. When we use %no-lines,
1702 there is one less line per action.
1703
1704 2001-12-16 Marc Autret <autret_m@epita.fr>
1705
1706 * src/bison.simple: Remove a useless #line directive.
1707 s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'.
1708 * src/output.c (get_lines_number): New.
1709 (output_parser): Adjust, now takes care about the lines of a
1710 output muscles.
1711 Fix line numbering.
1712 (actions_output): Computes the number of lines taken by actions.
1713 (output_master_parser): Insert new skeleton which is the name of
1714 the output parser file name.
1715
1716 2001-12-15 Marc Autret <autret_m@epita.fr>
1717
1718 * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility.
1719
1720 2001-12-15 Marc Autret <autret_m@epita.fr>
1721
1722 * src/output.c (output_gram): Keep track of the hairy one.
1723
1724 2001-12-15 Akim Demaille <akim@epita.fr>
1725
1726 Make `make distcheck' work.
1727
1728 * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses
1729 system.h which uses libgettext.h.
1730
1731 2001-12-15 Akim Demaille <akim@epita.fr>
1732
1733 * src/nullable.c (set_nullable): Useless rules must be skipped,
1734 otherwise, since we range over their symbols, we might look at a
1735 nonterminal which no longer ``exists'', i.e., it is not counted in
1736 `nvars', hence we overflow our arrays.
1737
1738 2001-12-15 Akim Demaille <akim@epita.fr>
1739
1740 The header can also be produced directly, without any obstack!
1741 Yahoo!
1742
1743 * src/files.c, src/files.h (defines_obstack): Remove.
1744 (compute_header_macro): Global.
1745 (defines_obstack_save): Remove.
1746 * src/reader.c (parse_union_decl): No longer output to
1747 defines_obstack: its content can be found in the `stype' muscle
1748 anyway.
1749 (output_token_translations): Merge into...
1750 (symbols_output): this.
1751 Rename as...
1752 (symbols_save): this.
1753 (reader): Adjust.
1754 * src/output.c (header_output): New.
1755 (output): Call it.
1756
1757 2001-12-15 Akim Demaille <akim@epita.fr>
1758
1759 * src/reader.c (parse_union_decl): Instead of handling two obstack
1760 simultaneously, use one to define the `stype' muscle, and use the
1761 value of the latter to fill defines_obstack.
1762 (copy_comment): Remove.
1763 (copy_comment2): Work for a single obstack.
1764 Rename as...
1765 (copy_comment): this.
1766
1767 2001-12-15 Akim Demaille <akim@epita.fr>
1768
1769 * src/lex.c, src/lex.h (xgetc): No longer static.
1770 * src/reader.c (parse_union_decl): Revamp.
1771
1772 2001-12-15 Akim Demaille <akim@epita.fr>
1773
1774 Still making progress in separating Bison into (i) input, (ii)
1775 process, (iii) output: now we can directly output the parser file
1776 without using table_obstack at all.
1777
1778 * src/files.c, src/files.h (table_obstack): Bye bye.
1779 (parser_file_name): New.
1780 * src/files.c (compute_output_file_names): Compute it.
1781 * src/output.c (actions_output, output_parser)
1782 (output_master_parser): To a file instead of an obstack.
1783
1784 2001-12-15 Akim Demaille <akim@epita.fr>
1785
1786 Attach actions to rules, instead of pre-outputting them to
1787 actions_obstack.
1788
1789 * src/gram.h (rule_t): action and action_line are new members.
1790 * src/reader.c (symbol_list): Likewise.
1791 (copy_action): Save the actions within the rule.
1792 (packgram): Save them in rule_table.
1793 * src/output.c (actions_output): New.
1794 (output_parser): Use it on `%%actions'.
1795 (output_rule_data): Don't free rule_table.
1796 (output): Do it.
1797 (prepare): Don't save the `action' muscle.
1798 * src/bison.simple: s/%%action/%%actions/.
1799
1800 2001-12-15 Akim Demaille <akim@epita.fr>
1801
1802 * src/reader.c (copy_action): When --yacc, don't append a `;'
1803 to the user action: let it fail if lacking.
1804 Suggested by Arnold Robbins and Tom Tromey.
1805
1806 2001-12-14 Akim Demaille <akim@epita.fr>
1807
1808 * src/lex.c (literalchar): Simply return the char you decoded, non
1809 longer mess around with obstacks and int pointers.
1810 Adjust all callers.
1811
1812 2001-12-14 Akim Demaille <akim@epita.fr>
1813
1814 * src/lex.c (literalchar): Don't escape the special characters,
1815 just decode them, and keep them as char (before, eol was output as
1816 the 2 char string `\n' etc.).
1817 * src/output.c (output_rule_data): Use quotearg to output the
1818 token strings.
1819
1820 2001-12-13 Paul Eggert <eggert@twinsun.com>
1821
1822 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
1823 Do not infringe on the global user namespace when using C++.
1824 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
1825 All uses of `fprintf' and `stderr' changed.
1826
1827 * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR.
1828
1829 2001-12-13 Akim Demaille <akim@epita.fr>
1830
1831 The computation of nullable is broken: it doesn't handle empty
1832 RHS's properly.
1833
1834 * tests/torture.at (GNU AWK Grammar): New.
1835 * tests/sets.at (Nullable): New.
1836 * src/nullable.c (set_nullable): Instead of blindly looping over
1837 `ritems', loop over the rules, and then over their rhs's.
1838
1839 Work around Autotest bugs.
1840
1841 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
1842 frame, because Autotest understand lines starting with a `+' as
1843 traces from the shell. Then, they are not processed properly.
1844 Admittedly an Autotest bug, but we don't have time to wait for
1845 Autotest to catch up.
1846 * tests/regression.at (Broken Closure): Adjust to the new table
1847 frames.
1848 Move to...
1849 * tests/sets.at: here.
1850
1851 2001-12-13 Akim Demaille <akim@epita.fr>
1852
1853 * src/closure.c (closure): Use nrules instead of playing tricks
1854 with BITS_PER_WORD.
1855
1856 2001-12-13 Akim Demaille <akim@epita.fr>
1857
1858 * src/print.c (print_actions): Output the handling of `$' as the
1859 traces do: shifting the token EOF. Before EOF was treated as a
1860 nonterminal.
1861 * tests/regression.at: Adjust some tests.
1862 * src/print_graph.c (print_core): Complete the set of items via
1863 closure. The next-to-final and final states are still unsatisfying,
1864 but that's to be addressed elsewhere.
1865 No longer output the rule numbers, but do output the state number.
1866 A single loop for the shifts + gotos is enough, but picked a
1867 distinct color for each.
1868 (print_graph): Initialize and finalize closure.
1869
1870 2001-12-13 Akim Demaille <akim@epita.fr>
1871
1872 * src/reader.c (readgram): Remove dead code, an strip useless
1873 braces.
1874 (get_type): Remove, unused.
1875
1876 2001-12-12 Akim Demaille <akim@epita.fr>
1877
1878 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
1879 on that of lib/error.c.
1880
1881 2001-12-12 Akim Demaille <akim@epita.fr>
1882
1883 Some hosts don't like `/' in includes.
1884
1885 * src/system.h: Include libgettext.h without qualifying the path.
1886 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
1887 $(top_srcdir).
1888
1889 2001-12-11 Marc Autret <autret_m@epita.fr>
1890
1891 * src/output.c (output_parser): Remove useless muscle.
1892
1893 2001-12-11 Marc Autret <autret_m@epita.fr>
1894
1895 * src/bison.simple: Remove #line just before %%epilogue. It
1896 is now handled in ...
1897 * src/reader.c (read_additionnal_code): Add the output of a
1898 #line for the epilogue.
1899
1900 2001-12-10 Marc Autret <autret_m@epita.fr>
1901
1902 * src/reader.c (copy_definition): Re-use CPP-outed code which
1903 replace precedent remove.
1904 * src/bison.simple: Remove #line before %%prologue because
1905 %%input-line is wrong at this time.
1906
1907 2001-12-10 Marc Autret <autret_m@epita.fr>
1908
1909 * src/reader.c (symbols_output): Clean up.
1910 * src/output.c (output_gram, output): Clean up.
1911
1912 2001-12-10 Akim Demaille <akim@epita.fr>
1913
1914 * src/lalr.c (initialize_lookaheads): New. Extracted from...
1915 * src/LR0.c (set_state_table): here.
1916 * src/lalr.c (lalr): Call it.
1917
1918 2001-12-10 Akim Demaille <akim@epita.fr>
1919
1920 * src/state.h (shifts): Remove the `number' member: shifts are
1921 attached to state, hence no longer need to be labelled with a
1922 state number.
1923
1924 2001-12-10 Akim Demaille <akim@epita.fr>
1925
1926 Now that states have a complete set of members, the linked list of
1927 shifts is useless: just fill directly the state's shifts member.
1928
1929 * src/state.h (shifts): Remove the `next' member.
1930 * src/LR0.c (first_state, last_state): Remove.
1931 Adjust the callers.
1932 (augment_automaton): Don't look for the shifts that must be added
1933 a shift on EOF: it is those of the state we looked for! But now,
1934 since shifts are attached, it is no longer needed to looking
1935 merely by its id: its number.
1936
1937 2001-12-10 Akim Demaille <akim@epita.fr>
1938
1939 * src/LR0.c (augment_automaton): Better variable locality.
1940 Remove an impossible branch: if there is a state corresponding to
1941 the start symbol being shifted, then there is shift for the start
1942 symbol from the initial state.
1943
1944 2001-12-10 Akim Demaille <akim@epita.fr>
1945
1946 * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state'
1947 only when appropriate: when insert_start_shifting_state' is not
1948 invoked.
1949 * tests/regression.at (Rule Line Numbers): Adjust.
1950
1951 2001-12-10 Akim Demaille <akim@epita.fr>
1952
1953 * src/LR0.c (augment_automaton): Now that all states have shifts,
1954 merge the two cases addition shifts to the initial state.
1955
1956 2001-12-10 Akim Demaille <akim@epita.fr>
1957
1958 * src/lalr.c (set_state_table): Move to...
1959 * src/LR0.c: here.
1960 * src/lalr.c (lalr): Don't call it...
1961 * src/LR0.c (generate_states): do it.
1962 * src/LR0.h (first_state): Remove, only the table is used.
1963
1964 2001-12-10 Akim Demaille <akim@epita.fr>
1965
1966 * src/LR0.h (first_shift, first_reduction): Remove.
1967 * src/lalr.c: Don't use first_shift: find shifts through the
1968 states.
1969
1970 2001-12-10 Akim Demaille <akim@epita.fr>
1971
1972 * src/LR0.c: Attach shifts to states as soon as they are
1973 computed.
1974 * src/lalr.c (set_state_table): Instead of assigning shifts to
1975 state, just assert that the mapping was properly done.
1976
1977 2001-12-10 Akim Demaille <akim@epita.fr>
1978
1979 * src/LR0.c (insert_start_shift): Rename as...
1980 (insert_start_shifting_state): this.
1981 (insert_eof_shifting_state, insert_accepting_state): New.
1982 (augment_automaton): Adjust.
1983 Better locality of the variables.
1984 When looking if the start_symbol is shifted from the initial
1985 state, using `while (... symbol != start_symbol ...)' sounds
1986 better than `while (... symbol < start_symbol ...)': If fail
1987 to see how the order between symbols could be relevant!
1988
1989 2001-12-10 Akim Demaille <akim@epita.fr>
1990
1991 * src/getargs.h: Don't declare `spec_name_prefix' and
1992 `spec_file_prefix', declared by src/files.h.
1993 * src/files.c, src/files.h: Default for spec_name_prefix is "yy".
1994 * src/muscle_tab.c (muscle_init): Default prefix to NULL.
1995 * src/output.c (prepare): Adjust.
1996 * src/reader.c (symbols_output): Likewise.
1997 * src/vmsgetargs.c: Vaguely adjust, but who cares?
1998
1999 2001-12-10 Akim Demaille <akim@epita.fr>
2000
2001 * src/muscle_tab.c (muscle_init): NULL is a better default than
2002 `"0"'.
2003
2004 2001-12-10 Akim Demaille <akim@epita.fr>
2005
2006 * src/reader.c (reader): Calling symbols_output once is enough.
2007
2008 2001-12-10 Akim Demaille <akim@epita.fr>
2009
2010 Now that states have a complete set of members, the linked list of
2011 reductions is useless: just fill directly the state's reductions
2012 member.
2013
2014 * src/state.h (struct reductions): Remove member `number' and
2015 `next'.
2016 * src/LR0.c (first_reduction, last_reduction): Remove.
2017 (save_reductions): Don't link the new reductions, store them in
2018 this_state.
2019 * src/lalr.c (set_state_table): No need to attach reductions to
2020 states, it's already done.
2021 * src/output.c (output_actions): No longer free the shifts, then
2022 the reductions, then the states: free all the states and their
2023 members.
2024
2025 2001-12-10 Akim Demaille <akim@epita.fr>
2026
2027 * src/options.c (OPTN, DRTV, BOTH): New.
2028 (option_table): Use them.
2029
2030 * src/muscle_tab.c: Don't include xalloc.h and string.h: that's
2031 the job of system.h.
2032 * src/options.c: Don't include stdio.h and xalloc.h for the same
2033 reasons.
2034
2035 2001-12-10 Akim Demaille <akim@epita.fr>
2036
2037 * src/output.c (output, prepare): Make sure the values of the
2038 muscles `action' and `prologue' are 0-terminated.
2039
2040 2001-12-10 Akim Demaille <akim@epita.fr>
2041
2042 Clean up GCC warnings.
2043
2044 * src/reader.c (copy_action): `buf' is not used.
2045 (parse_skel_decl): Be static.
2046 * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'.
2047 * src/options.h (create_long_option_table): Have a real prototype.
2048 * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete)
2049 (hash_delete_at): Return const void *.
2050 Adjust casts to preserve the const.
2051
2052 2001-12-10 Akim Demaille <akim@epita.fr>
2053
2054 * configure.in: Require 2.52g.
2055 M4 is not needed, but AUTOM4TE is.
2056 * m4/m4.m4: Remove.
2057 * tests/Makefile.am: Adjust.
2058
2059 2001-12-10 Akim Demaille <akim@epita.fr>
2060
2061 One structure for states is enough, even though theoretically
2062 there are LR(0) states and LALR(1) states.
2063
2064 * src/lalr.h (state_t): Remove.
2065 (state_table): Be state_t **, not state_t *.
2066 * src/state.h (core, CORE_ALLOC): Rename as...
2067 (state_t, STATE_ALLOC): this.
2068 Add the LALR(1) members: shifts, reductions, errs.
2069 * src/LR0.c (state_table): Rename as...
2070 (state_hash): this, to avoid name clashes with the global
2071 `state_table'.
2072 * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c
2073 * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust.
2074
2075 2001-12-10 Akim Demaille <akim@epita.fr>
2076
2077 Bison dumps core on bash.y.
2078 Reported by Pascal Bart.
2079
2080 * src/warshall.c (bitmatrix_print): New.
2081 (TC): Use it.
2082 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
2083 j must be the outer loop.
2084 * tests/regression.at (Broken Closure): New.
2085
2086 2001-12-05 Akim Demaille <akim@epita.fr>
2087
2088 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
2089 its argument.
2090 Reported by Peter Hámorský.
2091
2092 2001-12-05 Akim Demaille <akim@epita.fr>
2093
2094 * src/conflicts.c (err_table): Remove.
2095 (resolve_sr_conflict): Adjust.
2096 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
2097 Rename as...
2098 (state_t.reductions, state_t.shifts): this.
2099
2100 2001-12-05 Akim Demaille <akim@epita.fr>
2101
2102 * src/reduce.c (reduce_grammar_tables): No longer disable the
2103 removal of useless rules via CPP but via `if (0)', so that the
2104 compiler still check the code is valid.
2105 For instance, it should have noticed `rline' no longer exists: use
2106 the `line' member of rule_t.
2107 * src/gram.c (dummy, rline): Remove, unused.
2108
2109 2001-12-05 Akim Demaille <akim@epita.fr>
2110
2111 * src/output.c (pack_vector): Use assert, not berror.
2112 * src/main.c (berror): Remove, unused.
2113
2114 2001-12-05 Akim Demaille <akim@epita.fr>
2115
2116 New experimental feature: if --verbose --trace output all the
2117 items of a state, not only its kernel.
2118
2119 * src/print.c (print_core): If `trace_flag', then invoke closure
2120 before outputting the items of the state (print_core is no longer
2121 a correct name them).
2122 (print_results): Invoke new_closure/free_closure if needed.
2123
2124 2001-12-05 Akim Demaille <akim@epita.fr>
2125
2126 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
2127 * src/closure.c, src/closure.h (itemsetsize): Rename as...
2128 (nitemset): for consistency with the rest of the project.
2129
2130 2001-12-05 Akim Demaille <akim@epita.fr>
2131
2132 * src/closure.c (print_closure): Improve.
2133 (closure): Use it for printing input and output.
2134
2135 2001-12-05 Akim Demaille <akim@epita.fr>
2136
2137 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
2138 indexed by nonterminals.
2139
2140 2001-12-05 Akim Demaille <akim@epita.fr>
2141
2142 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
2143 what it was!).
2144 * src/warshall.h: Remove accidental duplication of the content.
2145
2146 2001-12-05 Akim Demaille <akim@epita.fr>
2147
2148 * src/closure.c (set_fderives): De-obfuscate.
2149
2150 2001-12-05 Akim Demaille <akim@epita.fr>
2151
2152 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
2153
2154 2001-12-05 Akim Demaille <akim@epita.fr>
2155
2156 * src/closure.c (set_firsts): De-obfuscate.
2157
2158 2001-12-05 Akim Demaille <akim@epita.fr>
2159
2160 * src/output.c (action_row): De-obfuscate
2161 using the good o' techniques: arrays not pointers, variable
2162 locality, BITISSET, RESETBIT etc.
2163
2164 2001-12-05 Akim Demaille <akim@epita.fr>
2165
2166 Pessimize the code to simplify it: from now on, all the states
2167 have a valid SHIFTS, which NSHIFTS is possibly 0.
2168
2169 * src/LR0.c (shifts_new): Be global and move to..
2170 * src/state.c, src/state.h: here.
2171 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
2172 * src/print_graph: Adjust.
2173
2174 2001-12-05 Akim Demaille <akim@epita.fr>
2175
2176 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
2177 * src/conflicts.c: Use it.
2178 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
2179 incorrectly ``simplified''.
2180
2181 2001-12-05 Akim Demaille <akim@epita.fr>
2182
2183 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
2184 using the good o' techniques: arrays not pointers, variable
2185 locality, BITISSET, RESETBIT etc.
2186
2187 2001-12-05 Akim Demaille <akim@epita.fr>
2188
2189 * src/state.h (SHIFT_SYMBOL): New.
2190 * src/conflicts.c: Use it to deobfuscate.
2191
2192 2001-12-05 Akim Demaille <akim@epita.fr>
2193
2194 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
2195 (print_reductions): De-obfuscate using the good o' techniques:
2196 arrays not pointers, variable locality, BITISSET.
2197
2198 2001-12-05 Akim Demaille <akim@epita.fr>
2199
2200 * src/conflicts.c (print_reductions): Arrays, not pointers.
2201 Use BITISSET.
2202
2203 2001-12-05 Akim Demaille <akim@epita.fr>
2204
2205 * src/conflicts.c (print_reductions): Pessimize, but clarify.
2206
2207 2001-12-05 Akim Demaille <akim@epita.fr>
2208
2209 * src/conflicts.c (print_reductions): Improve variable locality.
2210
2211 2001-12-05 Akim Demaille <akim@epita.fr>
2212
2213 * src/conflicts.c (print_reductions): Pessimize, but clarify.
2214
2215 2001-12-05 Akim Demaille <akim@epita.fr>
2216
2217 * src/conflicts.c (print_reductions): Improve variable locality.
2218
2219 2001-12-05 Akim Demaille <akim@epita.fr>
2220
2221 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
2222 * src/lalr.c: Use them.
2223
2224 2001-12-05 Akim Demaille <akim@epita.fr>
2225
2226 * src/LR0.c (augment_automaton): Formatting changes.
2227 Better variable locality.
2228
2229 2001-12-05 Akim Demaille <akim@epita.fr>
2230
2231 * src/lalr.c (matrix_print): New.
2232 (transpose): Use it.
2233 Use arrays instead of pointers.
2234
2235 2001-12-05 Akim Demaille <akim@epita.fr>
2236
2237 * src/lalr.c (maxrhs): Move to...
2238 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
2239 * src/lalr.c (build_relations): Adjust.
2240
2241 2001-12-05 Akim Demaille <akim@epita.fr>
2242
2243 * src/lalr.c (transpose): Free the memory allocated to the
2244 argument, as it is replaced by the results by the unique caller.
2245 (build_relations): Merely invoke transpose: it handles the memory
2246 deallocation.
2247 Improve variable locality.
2248 Avoid variables used as mere abbreviations.
2249 (compute_lookaheads): Use arrays instead of pointers.
2250
2251 2001-12-05 Akim Demaille <akim@epita.fr>
2252
2253 * src/lalr.c (initialize_F): Improve variable locality.
2254 Avoid variables used as mere abbreviations.
2255
2256 2001-12-05 Akim Demaille <akim@epita.fr>
2257
2258 * src/derives.c (print_derives): Display the ruleno.
2259 * src/lalr.c (initialize_F, transpose): Better variable locality
2260 to improve readability.
2261 Avoid variables used as mere abbreviations.
2262
2263 2001-12-05 Akim Demaille <akim@epita.fr>
2264
2265 * src/lalr.c (traverse): Use arrays instead of pointers.
2266
2267 2001-12-05 Akim Demaille <akim@epita.fr>
2268
2269 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
2270 the handling of squeue.
2271 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
2272
2273 2001-12-05 Akim Demaille <akim@epita.fr>
2274
2275 Because useless nonterminals are now kept alive (instead of being
2276 `destroyed'), we now sometimes examine them, and store information
2277 related to them. Hence we need to know their number, and adjust
2278 memory allocations.
2279
2280 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
2281 static.
2282 * src/LR0.c (allocate_itemsets): The memory allocated to
2283 `symbol_count' was used for two different purpose: once to count
2284 the number of occurrences of each symbol, and later reassigned to
2285 `shift_symbol', containing the symbol that can be shifted from a
2286 given state.
2287 Deobfuscate, i.e., allocate, use and free `symbol_count' here
2288 only, and...
2289 (new_itemsets): Allocate `shift_symbol' here.
2290 (allocate_itemsets): symbol_count includes useless nonterminals.
2291 Make room for them.
2292 (free_storage): Use `free', not `XFREE', for pointers that cannot
2293 be null.
2294
2295 2001-12-05 Akim Demaille <akim@epita.fr>
2296
2297 * src/nullable.c (set_nullable): Deobfuscate the handling of
2298 ritem.
2299 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
2300
2301 2001-12-05 Akim Demaille <akim@epita.fr>
2302
2303 * src/gram.c, src/gram.h (ritem_print): New.
2304 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
2305 (This useless function was defined only to work around VMS linkers
2306 that can't handle compilation units with variables only).
2307 * src/reduce.c (dump_grammar): Use it to trace the construction of
2308 ritem.
2309
2310 2001-12-04 Paul Eggert <eggert@twinsun.com>
2311
2312 * src/bison.simple (union yyalloc): Change member names
2313 to be the same as the stack names.
2314 (yyparse): yyptr is now union yyalloc *, not char *.
2315 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
2316 and may generate better code on some machines.
2317 (yystpcpy): Use prototype if __STDC__ is defined, not just
2318 if __cplusplus is defined.
2319
2320 2001-11-30 Akim Demaille <akim@epita.fr>
2321
2322 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
2323 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
2324 Gettext doesn't compile cleanly, and dies with -Werror.
2325 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
2326 Include WARNING_CFLAGS here.
2327 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
2328 before being defined.
2329
2330 2001-11-27 Paul Eggert <eggert@twinsun.com>
2331
2332 * lib/quotearg.h (quotearg_n, quotearg_n_style):
2333 First arg is int, not unsigned.
2334 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
2335 (SIZE_MAX, UINT_MAX): New macros.
2336 (quotearg_n_options): Abort if N is negative.
2337 Avoid overflow check on hosts where size_t is 64 bits and int
2338 is 32 bits, as overflow is impossible there.
2339 Fix off-by-one typo that caused unnecessary reallocation.
2340
2341 2001-11-29 Paul Eggert <eggert@twinsun.com>
2342
2343 Name space cleanup in generated parser.
2344
2345 * doc/bison.texinfo (Bison Parser): Discuss system headers
2346 and their effect on the user name space.
2347
2348 * src/bison.simple:
2349 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
2350 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
2351 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
2352
2353 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
2354 on user names when possible.
2355
2356 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
2357 Simplify test for whather <alloca.h> exists.
2358
2359 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
2360
2361 (<stdio.h>): Include if YYDEBUG.
2362
2363 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
2364 ! defined (yyoverflow) && ! defined (yymemcpy).
2365
2366 (yymemcpy, yyparse): Rename local variables as needed so that
2367 they all begin with 'yy'.
2368
2369 (yystrlen, yystpcpy): New functions.
2370
2371 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
2372 All uses changed.
2373
2374 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
2375 instead of relying on string.h functions. Use YYSTACK_ALLOC
2376 and YYSTACK_FREE instead of malloc and free.
2377
2378 2001-11-30 Akim Demaille <akim@epita.fr>
2379
2380 * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions
2381 before their first uses.
2382 (YYBISON, YYPURE): Move to the top of the output.
2383
2384 2001-11-30 Akim Demaille <akim@epita.fr>
2385
2386 * tests/reduce.at (Useless Nonterminals): Fix.
2387
2388 2001-11-30 Akim Demaille <akim@epita.fr>
2389
2390 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
2391 if body instead of `;' to pacify GCC's warnings.
2392
2393 2001-11-30 Akim Demaille <akim@epita.fr>
2394
2395 Instead of mapping the LHS of unused rules to -1, keep the LHS
2396 valid, but flag the rules as invalid.
2397
2398 * src/gram.h (rule_t): `useful' is a new member.
2399 * src/print.c (print_grammar): Adjust.
2400 * src/derives.c (set_derives): Likewise.
2401 * src/reader.c (packgram, reduce_output): Likewise.
2402 * src/reduce.c (reduce_grammar_tables): Likewise.
2403 * tests/reduce.at (Underivable Rules, Useless Rules): New.
2404
2405 2001-11-30 Akim Demaille <akim@epita.fr>
2406
2407 * src/reduce.c (reduce_output): Formatting changes.
2408 * src/print.c (print_results, print_grammar): Likewise.
2409 * tests/regression.at (Rule Line Numbers)
2410 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
2411
2412 2001-11-30 Akim Demaille <akim@epita.fr>
2413
2414 * src/reduce.c (nonterminals_reduce): Instead of throwing away
2415 useless nonterminals, move them at the end of the symbol arrays.
2416 (reduce_output): Adjust.
2417 * tests/reduce.at (Useless Nonterminals): Adjust.
2418
2419 2001-11-30 Akim Demaille <akim@epita.fr>
2420
2421 * src/reduce.c: Various comment/formatting changes.
2422 (nonterminals_reduce): New, extracted from...
2423 (reduce_grammar_tables): here.
2424 (reduce_grammar): Call nonterminals_reduce.
2425
2426 2001-11-29 Paul Eggert <eggert@twinsun.com>
2427
2428 * src/bison.simple (YYSTACK_REALLOC): Remove.
2429 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
2430 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
2431 New macros.
2432 (union yyalloc): New type.
2433 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
2434 an arbitrary restriction on hosts where size_t is wider than int.
2435
2436 (yyparse): Don't dump core if alloca or malloc fails; instead, report
2437 a parser stack overflow. Allocate just one block of memory for all
2438 three stacks, instead of allocating three blocks; this typically is
2439 faster and reduces fragmentation.
2440
2441 Do not limit the number of items in the stack to a value that fits
2442 in 'int', as this is an arbitrary limit on hosts with 64-bit
2443 size_t and 32-bit int.
2444
2445 2001-11-29 Marc Autret <autret_m@epita.fr>
2446
2447 * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead
2448 of defining YYERROR_VERBOSE.
2449 [AT_DATA]: $4 is now out of C declarations in the prologue.
2450
2451 2001-11-28 Marc Autret <autret_m@epita.fr>
2452
2453 * src/reader.c (parse_dquoted_param): New.
2454 (parse_skel_decl): Use it.
2455 * src/lex.h: Add its prototype.
2456 * src/lex.c (literalchar): Become not static.
2457
2458 2001-11-28 Marc Autret <autret_m@epita.fr>
2459
2460 * src/output.h: And put its extern declaration here.
2461 * src/output.c (error_verbose): Define here.
2462 (prepare): Echo name modification.
2463 * src/getargs.h: Clean its extern declaration.
2464 * src/getargs.c (error_verbose_flag): Remove.
2465 (getargs): Remove case 'e'.
2466 * src/options.c (option_table): 'error-verbose' is now seen as simple
2467 percent option.
2468 Include output.h.
2469
2470 * src/reader.c (read_declarations): Remove case tok_include.
2471 (parse_include_decl): Remove.
2472 * src/lex.h (token_t): Remove tok_include.
2473 * src/options.c (option_table): 'include' is now a simple command line
2474 option.
2475
2476 2001-11-28 Marc Autret <autret_m@epita.fr>
2477
2478 * src/bison.simple: Adjust muscle names.
2479 * src/muscle_tab.c (muscle_init): Also rename the muscles.
2480 * src/output.c (prepare): s/_/-/ for the muscles names.
2481 (output_parser): When scanning for a muscle, allow '-' instead of '_'.
2482
2483 2001-11-28 Marc Autret <autret_m@epita.fr>
2484
2485 * src/bison.simple: Fix debug.
2486 [YYERROR_VERBOSE]: Re-integrate as an internal macro.
2487
2488 2001-11-28 Akim Demaille <akim@epita.fr>
2489
2490 * src/LR0.c (shifts_new): New.
2491 (save_shifts, insert_start_shift, augment_automaton): Use it.
2492
2493 2001-11-28 Akim Demaille <akim@epita.fr>
2494
2495 * src/closure.c (closure): `b' and `ruleno' denote the same value:
2496 keep ruleno only.
2497
2498 2001-11-28 Akim Demaille <akim@epita.fr>
2499
2500 * src/closure.c (closure): Instead of looping over word in array
2501 then bits in words, loop over bits in array.
2502
2503 2001-11-28 Akim Demaille <akim@epita.fr>
2504
2505 * src/closure.c (closure): No longer optimize the special case
2506 where all the bits of `ruleset[r]' are set to 0, to make the code
2507 clearer.
2508
2509 2001-11-28 Akim Demaille <akim@epita.fr>
2510
2511 * src/closure.c (closure): `r' and `c' are new variables, used to
2512 de-obfuscate accesses to RULESET and CORE.
2513
2514 2001-11-28 Akim Demaille <akim@epita.fr>
2515
2516 * src/reduce.c (reduce_print): Use ngettext.
2517 (dump_grammar): Improve the trace accuracy.
2518
2519 2001-11-28 Akim Demaille <akim@epita.fr>
2520
2521 * src/reduce.c (dump_grammar): Don't translate trace messages.
2522
2523 2001-11-28 Akim Demaille <akim@epita.fr>
2524
2525 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
2526 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
2527 as all tags are free'ed afterwards.
2528 From Enrico Scholz.
2529
2530 2001-11-27 Paul Eggert <eggert@twinsun.com>
2531
2532 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
2533 use alloca when we didn't want to, and vice versa.
2534
2535 2001-11-27 Marc Autret <autret_m@epita.fr>
2536
2537 * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle
2538 initialization.
2539 * src/output.c (prepare): Remove its update.
2540
2541 2001-11-27 Marc Autret <autret_m@epita.fr>
2542
2543 * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition.
2544 Use %error-verbose.
2545
2546 2001-11-27 Marc Autret <autret_m@epita.fr>
2547
2548 * src/bison.simple: Remove YYERROR_VERBOSE using.
2549 Use %%error_verbose.
2550 (yyparse): Likewise.
2551 * src/output.c (prepare): Give its final value.
2552 * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'.
2553 * src/getargs.h: Add its extern declaration.
2554 * src/getargs.c (error_verbose_flag): New int.
2555 (getargs): Update to catch new case.
2556 * src/options.c (option_table): 'error-verbose' is a new option.
2557 (shortopts): Update.
2558
2559 2001-11-27 Akim Demaille <akim@epita.fr>
2560
2561 * src/system.h: Use intl/libgettext.h.
2562 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
2563
2564 2001-11-27 Akim Demaille <akim@epita.fr>
2565
2566 * tests/torture.at (Exploding the Stack Size with Malloc):
2567 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
2568
2569 2001-11-27 Akim Demaille <akim@epita.fr>
2570
2571 * src/files.c: Include error.h.
2572 Reported by Hans Aberg.
2573
2574 2001-11-26 Marc Autret <autret_m@epita.fr>
2575
2576 * src/reader.c (parse_include_decl): New, not yet implemented.
2577 (read_declarations): Add case tok_include.
2578 * src/getargs.h (include): Add its extern definition.
2579 * src/getargs.c (include): New const char *.
2580 (getargs): Add case '-I'.
2581 * src/options.c (option_table): Add include as command line and
2582 percent option.
2583 * src/lex.h (token_t): Add tok_include.
2584
2585 2001-11-26 Akim Demaille <akim@epita.fr>
2586
2587 * src/reader.c (readgram): Make sure rules for mid-rule actions
2588 have a lineno equal to that of their host rule.
2589 Reported by Hans Aberg.
2590 * tests/regression.at (Rule Line Numbers): New.
2591
2592 2001-11-26 Akim Demaille <akim@epita.fr>
2593
2594 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
2595 size_ts.
2596
2597 2001-11-26 Akim Demaille <akim@epita.fr>
2598
2599 * src/complain.c, src/complain.h (error): Remove, provided by
2600 lib/error.[ch].
2601
2602 2001-11-26 Akim Demaille <akim@epita.fr>
2603
2604 * src/reader.c (read_declarations): Don't abort on tok_illegal,
2605 issue an error message.
2606 * tests/regression.at (Invalid %directive): New.
2607 Reported by Hans Aberg.
2608
2609 2001-11-26 Akim Demaille <akim@epita.fr>
2610
2611 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
2612 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
2613
2614 2001-11-26 Akim Demaille <akim@epita.fr>
2615
2616 * src/conflicts.c (conflicts_print): Don't complain at all when
2617 there are no reduce/reduce conflicts, and as many shift/reduce
2618 conflicts as expected.
2619 * tests/regression.at (%expect right): Adjust.
2620
2621 2001-11-23 Akim Demaille <akim@epita.fr>
2622
2623 * lib/alloca.c: Update, from fileutils.
2624
2625 2001-11-23 Akim Demaille <akim@epita.fr>
2626
2627 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
2628
2629 2001-11-23 Akim Demaille <akim@epita.fr>
2630
2631 * src/system.h: Include alloca.h.
2632 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
2633
2634 2001-11-23 Akim Demaille <akim@epita.fr>
2635
2636 * src/print_graph.c (print_actions): Remove `rule', unused.
2637 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
2638 pacify GCC's signed < unsigned warnings.
2639 * src/closure.c (itemsetsize): Likewise.
2640 * src/reader.c (symbol_list_new): Static.
2641
2642 2001-11-23 Akim Demaille <akim@epita.fr>
2643
2644 Attaching lineno to buckets is stupid, since only one copy of each
2645 symbol is kept, only the line of the first occurrence is kept too.
2646
2647 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
2648 * src/reader.c (rline_allocated): Remove, unused.
2649 (symbol_list): Have a `line' member.
2650 (symbol_list_new): New.
2651 (readgram): Use it.
2652 * src/print.c (print_grammar): Output the rule line numbers.
2653 * tests/regression.at (Solved SR Conflicts)
2654 (Unresolved SR Conflicts): Adjust.
2655 Reported by Hans Aberg.
2656
2657 2001-11-22 Marc Autret <autret_m@epita.fr>
2658
2659 * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0.
2660
2661 2001-11-22 Marc Autret <autret_m@epita.fr>
2662
2663 * src/muscle_tab.c (muscle_init): Remove initialization of
2664 skeleton muscle.
2665 * src/output.c (output_master_parser): Do it here.
2666
2667 2001-11-20 Akim Demaille <akim@epita.fr>
2668
2669 * po/sv.po: New.
2670 * configure.in (ALL_LINGUAS): Adjust.
2671 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
2672 longer contains strings to translate.
2673
2674 2001-11-19 Akim Demaille <akim@epita.fr>
2675
2676 * src/conflicts.c (conflicts_print): Add a missing \n.
2677
2678 2001-11-19 Akim Demaille <akim@epita.fr>
2679
2680 * src/nullable.c (nullable_print): New.
2681 (set_nullable): Call it when tracing.
2682 Better locality of variables.
2683
2684 2001-11-19 Akim Demaille <akim@epita.fr>
2685
2686 * src/print.c (print_actions): Better locality of variables.
2687
2688 2001-11-19 Akim Demaille <akim@epita.fr>
2689
2690 * src/derives.c (print_derives): Fix and enrich.
2691 * src/closure.c (print_fderives): Likewise.
2692
2693 2001-11-19 Akim Demaille <akim@epita.fr>
2694
2695 * src/closure.c (itemsetend): Remove, replaced with...
2696 (itemsetsize): new.
2697
2698 2001-11-19 Akim Demaille <akim@epita.fr>
2699
2700 * src/LR0.c (kernel_end): Remove, replaced with...
2701 (kernel_size): new.
2702
2703 2001-11-19 Akim Demaille <akim@epita.fr>
2704
2705 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
2706 to clarify.
2707
2708 2001-11-19 Akim Demaille <akim@epita.fr>
2709
2710 * src/closure.c (closure): Use arrays instead of pointers to clarify.
2711
2712 2001-11-19 Akim Demaille <akim@epita.fr>
2713
2714 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
2715 trace messages.
2716 * src/LR0.c: Likewise.
2717 (allocate_itemsets): Use arrays instead of pointers to clarify.
2718
2719 2001-11-19 Akim Demaille <akim@epita.fr>
2720
2721 * src/getargs.c (statistics_flag): Replace with...
2722 (trace_flag): New.
2723 (longopts): Accept --trace instead of --statistics.
2724 * src/getargs.h, src/options.c: Adjust.
2725 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
2726 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
2727
2728 2001-11-19 Akim Demaille <akim@epita.fr>
2729
2730 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
2731 pointers to clarify the code.
2732 (save_reductions, save_shifts): Factor common parts of alternatives.
2733
2734 2001-11-19 Akim Demaille <akim@epita.fr>
2735
2736 * src/LR0.c (new_state, get_state): Complete TRACE code.
2737 * src/closure.c: Include `reader.h' to get `tags', needed by the
2738 trace code.
2739 Rename the conditional DEBUG as TRACE.
2740 Output consistently TRACEs to stderr, not stdout.
2741 * src/derives.c: Likewise.
2742 * src/reduce.c: (inaccessable_symbols): Using if is better style
2743 than goto.
2744 Use `#if TRACE' instead of `#if 0' for tracing code.
2745
2746 2001-11-19 Akim Demaille <akim@epita.fr>
2747
2748 * src/system.h (LIST_FREE, shortcpy): New.
2749 * src/LR0.c: Use them.
2750 * src/output.c (free_itemsets, free_reductions, free_shifts):
2751 Remove, replaced by LIST_FREE.
2752
2753 2001-11-19 Akim Demaille <akim@epita.fr>
2754
2755 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
2756 (REDUCTIONS_ALLOC): New.
2757 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
2758 allocation.
2759
2760 2001-11-19 Akim Demaille <akim@epita.fr>
2761
2762 * src/LR0.c (new_state): Complete trace code.
2763 * src/nullable.c (set_nullable): Don't translate traces.
2764
2765 2001-11-19 Akim Demaille <akim@epita.fr>
2766
2767 * src/print_graph.c (print_core): Better locality of variables.
2768 * src/print.c (print_core): Likewise.
2769
2770 2001-11-19 Akim Demaille <akim@epita.fr>
2771
2772 * src/vcg.c: You do the output, so you are responsible of the
2773 handling of VCG syntax, in particular: use quotearg.
2774 * src/print_graph.c: Don't.
2775 (print_actions): Don't output the actions as part of the nodes,
2776 since that's the job of the edges.
2777 (print_state): Don't output by hand: fill the node description,
2778 and ask for its output.
2779
2780 2001-11-19 Akim Demaille <akim@epita.fr>
2781
2782 * src/bison.simple (yyparse): When verbosely reporting an error,
2783 no longer put additional quotes around token names.
2784 * tests/calc.at: Adjust.
2785
2786 2001-11-19 Akim Demaille <akim@epita.fr>
2787
2788 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
2789 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
2790 * src/output.c: Adjust.
2791
2792 2001-11-19 Akim Demaille <akim@epita.fr>
2793
2794 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
2795 (rule_t): this.
2796 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
2797
2798 2001-11-19 Akim Demaille <akim@epita.fr>
2799
2800 * src/gram.h (rule_t): New.
2801 (rule_table): New.
2802 (rrhs, rlhs): Remove, part of state_t.
2803 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
2804 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
2805 * src/reader.c, src/reduce.c: Adjust.
2806
2807 2001-11-19 Akim Demaille <akim@epita.fr>
2808
2809 * src/reader.c (symbols_output): New, extracted from...
2810 (packsymbols): Here.
2811 (reader): Call it.
2812
2813 2001-11-19 Akim Demaille <akim@epita.fr>
2814
2815 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
2816 (maxrhs): this new function.
2817
2818 2001-11-19 Akim Demaille <akim@epita.fr>
2819
2820 * src/lalr.c (F): New macro to access the variable F.
2821 Adjust.
2822
2823 2001-11-19 Akim Demaille <akim@epita.fr>
2824
2825 * src/lalr.h (LA): New macro to access the variable LA.
2826 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
2827 * src/lalr.c: Adjust.
2828
2829 2001-11-19 Akim Demaille <akim@epita.fr>
2830
2831 * src/lalr.c (initialize_LA): Only initialize LA. Let...
2832 (set_state_table): handle the `lookaheads' members.
2833
2834 2001-11-19 Akim Demaille <akim@epita.fr>
2835
2836 * src/lalr.h (lookaheads): Removed array, whose contents is now
2837 a member of...
2838 (state_t): this structure.
2839 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
2840 Adjust.
2841
2842 2001-11-19 Akim Demaille <akim@epita.fr>
2843
2844 * src/lalr.h (consistent): Removed array, whose contents is now
2845 a member of...
2846 (state_t): this structure.
2847 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
2848 Adjust.
2849
2850 2001-11-19 Akim Demaille <akim@epita.fr>
2851
2852 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
2853 contents are now members of...
2854 (state_t): this structure.
2855 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
2856 Adjust.
2857
2858 2001-11-19 Akim Demaille <akim@epita.fr>
2859
2860 * src/lalr.h (state_t): New.
2861 (state_table): Be a state_t * instead of a core **.
2862 (accessing_symbol): Remove, part of state_t.
2863 * src/lalr.c: Adjust.
2864 (set_accessing_symbol): Merge into...
2865 (set_state_table): this.
2866 * src/print_graph.c, src/conflicts.c: Adjust.
2867
2868 2001-11-14 Akim Demaille <akim@epita.fr>
2869
2870 * tests/calc.at, tests/output.at, tests/regression.at,
2871 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
2872 now the tests are run in private dirs, therefore AC_CLEANUP and
2873 family can be simplified to 0-ary.
2874 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
2875 use abs. path to find config.h.
2876 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
2877 stderr, there can be way too much random noise.
2878 Instead pass -Werror to GCC and rely on the exit status.
2879 Reported by Wolfram Wagner.
2880
2881 2001-11-14 Akim Demaille <akim@epita.fr>
2882
2883 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
2884 defined only if yyoverflow is defined, to avoid `warning: unused
2885 variable `yyvs1''.
2886 Reported by The Test Suite.
2887
2888 2001-11-14 Akim Demaille <akim@epita.fr>
2889
2890 * src/print.c: Include reduce.h.
2891 Reported by Hans Aberg.
2892
2893 2001-11-14 Akim Demaille <akim@epita.fr>
2894
2895 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
2896 Revert a previous patch: these are really const.
2897 * src/conflicts.c (conflict_report): Additional useless pair of
2898 braces to pacify GCC's warnings for `if () if () {} else {}'.
2899 * src/lex.c (parse_percent_token): Replace equal_offset with
2900 arg_offset.
2901 arg is const.
2902 Be sure to strdup `arg' when used, since there is no reason for
2903 token_buffer not to change.
2904
2905 2001-11-14 Akim Demaille <akim@epita.fr>
2906
2907 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
2908 definition.
2909 * src/main.c (main): Use them.
2910 Suggested by Hans Aberg.
2911
2912 2001-11-12 Akim Demaille <akim@epita.fr>
2913
2914 * src/system.h (ngettext): Now that we use ngettext, be sure to
2915 provide a default definition when NLS are not used.
2916
2917 2001-11-12 Akim Demaille <akim@epita.fr>
2918
2919 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
2920 Use @kbd to denote user input.
2921 (Language and Grammar): ANSIfy the example.
2922 Adjust its layout for info/notinfo.
2923 (Location Tracking Calc): Output error messages to stderr.
2924 Output locations in a more GNUtically correct way.
2925 Fix a couple of Englishos.
2926 Adjust @group/@end group pairs.
2927
2928 2001-11-12 Akim Demaille <akim@epita.fr>
2929
2930 %expext was not functioning at all.
2931
2932 * src/conflicts.c (expected_conflicts): Set to -1.
2933 (conflict_report): Use ngettext.
2934 (conflicts_print): Check %expect and make its violation an error.
2935 * doc/bison.texinfo (Expect Decl): Adjust.
2936 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
2937 * tests/regression.at (%expect not enough, %expect right)
2938 (%expect too much): New.
2939
2940 2001-11-12 Akim Demaille <akim@epita.fr>
2941
2942 * tests/regression.at (Conflicts): Rename as...
2943 (Unresolved SR Conflicts): this.
2944 (Solved SR Conflicts): New.
2945
2946 2001-11-12 Akim Demaille <akim@epita.fr>
2947
2948 * src/reduce.c (print_results): Rename as...
2949 (reduce_output): This.
2950 Output to OUT, passed as argument, instead of output_obstack.
2951 (dump_grammar): Likewise.
2952 (reduce_free): New.
2953 Also free V1.
2954 (reduce_grammar): No longer call reduce_output, since...
2955 * src/print.c (print_results): do it.
2956 * src/main.c (main): Call reduce_free;
2957
2958 2001-11-12 Akim Demaille <akim@epita.fr>
2959
2960 * src/conflicts.c (print_reductions): Accept OUT as argument.
2961 Output to it, not to output_obstack.
2962 * src/print.c (print_actions): Adjust.
2963
2964 2001-11-12 Akim Demaille <akim@epita.fr>
2965
2966 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
2967 the result instead of using...
2968 (src_total, rrc_total, src_count, rrc_count): Remove.
2969 (any_conflicts): Remove.
2970 (print_conflicts): Split into...
2971 (conflicts_print, conflicts_output): New.
2972 * src/conflicts.h: Adjust.
2973 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
2974 * src/print.c (print_grammar): Issue `\n' between two rules.
2975 * tests/regression.at (Conflicts): New.
2976 Reported by Tom Lane.
2977
2978 2001-11-12 Akim Demaille <akim@epita.fr>
2979
2980 * tests/regression.at (Invalid input): Remove, duplicate with
2981 ``Invalid input: 1''.
2982
2983 2001-11-12 Akim Demaille <akim@epita.fr>
2984
2985 * tests/torture.at (AT_DATA_STACK_TORTURE)
2986 (Exploding the Stack Size with Alloca)
2987 (Exploding the Stack Size with Malloc): New.
2988
2989 2001-11-12 Akim Demaille <akim@epita.fr>
2990
2991 * src/bison.simple (YYSTACK_REALLOC): New.
2992 (yyparse) [!yyoverflow]: Use it and free the old stack.
2993 Reported by Per Allansson.
2994
2995 2001-11-12 Pascal Bart <pascal.bart@epita.fr>
2996
2997 * src/bison.simple: Define type yystype instead of YYSTYPE, and
2998 define CPP macro, which substitute YYSTYPE by yystype.
2999 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
3000 with yyltype/YYLTYPE. This allows inclusion of the generated
3001 header within the parser if the compiler, such as GGC, accepts
3002 multiple equivalent #defines.
3003 From Akim.
3004
3005 2001-11-05 Akim Demaille <akim@epita.fr>
3006
3007 * src/reader.c (symbols_output): New, extracted from...
3008 (packsymbols): here.
3009 (reader): Adjust.
3010
3011 2001-11-05 Akim Demaille <akim@epita.fr>
3012
3013 * src/lex.c (parse_percent_token): s/quotearg/quote/.
3014
3015 2001-11-05 Akim Demaille <akim@epita.fr>
3016
3017 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
3018 pattern.
3019
3020 2001-11-05 Akim Demaille <akim@epita.fr>
3021
3022 * src/options.h (struct option_table_struct): set_flags is void*.
3023 * src/options.c (longopts): Support `--output' and `%output'.
3024 (usage): Adjust.
3025 * src/lex.h (tok_setopt): Remove, replaced with...
3026 (tok_intopt, tok_stropt): these new guys.
3027 * src/lex.c (getopt.h): Not needed.
3028 (token_buffer, unlexed_token_buffer): Not const.
3029 (percent_table): Promote `-' over `_' in directive names.
3030 Active `%name-prefix', `file-prefix', and `output'.
3031 (parse_percent_token): Accept possible arguments to directives.
3032 Promote `-' over `_' in directive names.
3033
3034 2001-11-04 Akim Demaille <akim@epita.fr>
3035
3036 * doc/bison.texinfo (Decl Summary): Split the list into
3037 `directives for grammars' and `directives for bison'.
3038 Sort'em.
3039 Add description of `%name-prefix', `file-prefix', and `output'.
3040 Promote `-' over `_' in directive names.
3041 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
3042 Simplify the description of `--name-prefix'.
3043 Promote `-' over `_' in directive names.
3044 Promote `--output' over `--output-file'.
3045 Fix the description of `--defines'.
3046 * tests/output.at: Exercise %file-prefix and %output.
3047
3048 2001-11-02 Akim Demaille <akim@epita.fr>
3049
3050 * doc/refcard.tex: Update.
3051
3052 2001-11-02 Akim Demaille <akim@epita.fr>
3053
3054 * src/symtab.h (SUNDEF): New.
3055 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
3056 stand for `uninitialized', instead of 0.
3057 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
3058 * src/lex.c (lex): Adjust.
3059
3060 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
3061 Number it 0.
3062 Let yylex return it instead of a plain 0.
3063 Reported by Dick Streefland.
3064
3065 2001-11-02 Akim Demaille <akim@epita.fr>
3066
3067 * tests/regression.at (Mixing %token styles): New test.
3068
3069 2001-11-02 Akim Demaille <akim@epita.fr>
3070
3071 * src/reader.c (parse_thong_decl): Formatting changes.
3072 (token_translations_init): New, extracted from...
3073 (packsymbols): Here.
3074 Adjust.
3075
3076 2001-11-01 Akim Demaille <akim@epita.fr>
3077
3078 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
3079 Check that `9foo.y' produces correct cpp guards.
3080 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
3081 guards.
3082 Reported by Wwp.
3083
3084 2001-11-01 Akim Demaille <akim@epita.fr>
3085
3086 * tests/regression.at (Invalid input: 2): New.
3087 * src/lex.c (unlexed_token_buffer): New.
3088 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
3089 too.
3090 Reported by Wwp.
3091
3092 2001-11-01 Akim Demaille <akim@epita.fr>
3093
3094 * tests/calc.at: Catch up with 1.30.
3095 * configure.in: Bump to 1.49a.
3096 Adjust to newer Autotest.
3097
3098 2001-10-19 Pascal Bart <pascal.bart@epita.fr>
3099
3100 * src/conflicts.c: Move global variables rrc_total and src_total ...
3101 (print_conflicts): here.
3102 * src/output.c (output): Free global variable user_toknums.
3103 * src/lex.c (token_obstack): Become static.
3104
3105 2001-10-18 Akim Demaille <akim@epita.fr>
3106
3107 * tests/atlocal.in (GCC): Add.
3108 * tests/calc.at: s/m4_match/m4_bmatch/.
3109 s/m4_patsubst/m4_bpatsubst/.
3110 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
3111 * configure.in: AC_SUBST(GCC).
3112
3113 2001-10-14 Marc Autret <autret_m@epita.fr>
3114
3115 * src/options.c (create_long_option_table): Fix.
3116
3117 2001-10-10 Akim Demaille <akim@epita.fr>
3118
3119 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
3120
3121 2001-10-04 Akim Demaille <akim@epita.fr>
3122
3123 * src/reader.c (parse_union_decl): Push the caracters in
3124 union_obstack, not attrs_obstack.
3125
3126 2001-10-04 Akim Demaille <akim@epita.fr>
3127
3128 Merge in the branch 1.29.
3129
3130 * src/reader.c (packsymbols): Use a temporary obstack for
3131 `%%tokendef', since output_stack is already used elsewhere.
3132
3133 2001-10-02 Akim Demaille <akim@epita.fr>
3134
3135 Bump 1.29d.
3136
3137 2001-10-02 Akim Demaille <akim@epita.fr>
3138
3139 Version 1.29c.
3140
3141 2001-10-02 Akim Demaille <akim@epita.fr>
3142
3143 * tests/regression.at (Invalid CPP headers): New.
3144 From Alexander Belopolsky.
3145 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
3146
3147 2001-10-02 Akim Demaille <akim@epita.fr>
3148
3149 * tests/regression.at (Invalid input): New.
3150 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
3151 Reported by Shura.
3152
3153 2001-10-02 Akim Demaille <akim@epita.fr>
3154
3155 * tests/calc.at: Now that --debug works, the tests must be adjusted.
3156
3157 2001-10-02 Akim Demaille <akim@epita.fr>
3158
3159 * src/output.c (output_parser): Assert `skeleton'.
3160 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
3161 systems.
3162 From Shura.
3163
3164 2001-10-01 Marc Autret <autret_m@epita.fr>
3165
3166 * src/lex.h: Echo modifications.
3167 * src/lex.c (unlex): Parameter is now token_t.
3168 From Hans Aberg.
3169
3170 2001-10-01 Marc Autret <autret_m@epita.fr>
3171
3172 * src/main.c: Include lex.h.
3173 From Hans Aberg.
3174
3175 2001-09-29 Akim Demaille <akim@epita.fr>
3176
3177 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
3178
3179 2001-09-28 Akim Demaille <akim@epita.fr>
3180
3181 * tests/testsuite.at: Update to newer Autotest.
3182 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
3183
3184 2001-09-27 Akim Demaille <akim@epita.fr>
3185
3186 Position independent wrapper.
3187
3188 * tests/bison: Remove.
3189 * tests/bison.in: New.
3190 * configure.in: Adjust.
3191
3192 2001-09-27 Paul Eggert <eggert@twinsun.com>
3193
3194 Port quotearg fixes from tar 1.13.24.
3195
3196 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
3197 tm to be declared.
3198 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
3199 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
3200
3201 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
3202 * m4/mbrtowc.m4: New file.
3203 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
3204 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
3205
3206 2001-09-27 Akim Demaille <akim@epita.fr>
3207
3208 Bump to 1.29c.
3209
3210 2001-09-27 Akim Demaille <akim@epita.fr>
3211
3212 Version 1.29b.
3213
3214 2001-09-25 Akim Demaille <akim@epita.fr>
3215
3216 * src/system.h: Include `xalloc.h'.
3217 Remove it from the C files.
3218 * src/files.c (output_files): Free the obstacks.
3219 * src/lex.c (init_lex): Rename as...
3220 (lex_init): this.
3221 (lex_free): New.
3222 * src/main.c (main): Use it.
3223
3224 2001-09-24 Marc Autret <autret_m@epita.fr>
3225
3226 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
3227 to output informations in fout (FILE*).
3228 (open_graph, close_graph): Likewise.
3229 (output_graph, output_edge, output_node): Likewise.
3230 * src/vcg.h: Update function prototypes.
3231 * src/print_graph.c (print_graph): Open output graph file.
3232 (print_actions): Adjust.
3233 * src/files.h: Remove extern declaration.
3234 * src/files.c: Remove graph_obstack declaration.
3235 (open_files): Remove graph_obstack initialization.
3236 (output_files): Remove graph_obstack saving.
3237
3238 2001-09-24 Marc Autret <autret_m@epita.fr>
3239
3240 * src/files.c (compute_output_file_names): Fix.
3241
3242 2001-09-24 Marc Autret <autret_m@epita.fr>,
3243 Akim Demaille <akim@epita.fr>
3244
3245 * src/reader.c (reader): Remove call to free_symtab ().
3246 * src/main.c (main): Call it here.
3247 Include symtab.h.
3248 * src/conflicts.c (initialize_conflicts): Rename as...
3249 (solve_conflicts): this.
3250 * src/print.c (print_core, print_actions, print_state)
3251 (print_grammar): Dump to a file instead a `output_obstack'.
3252 (print_results): Dump `output_obstack', and then proceed with the
3253 FILE *.
3254 * src/files.c (compute_output_file_names, close_files): New.
3255 (output_files): Adjust.
3256 * src/main.c (main): Adjust.
3257
3258 2001-09-23 Marc Autret <autret_m@epita.fr>
3259
3260 * src/files.c (compute_header_macro): Computes header macro name
3261 from spec_defines_file when given.
3262
3263 2001-09-23 Marc Autret <autret_m@epita.fr>
3264
3265 * src/files.c (output_files): Add default extensions.
3266
3267 2001-09-22 Akim Demaille <akim@epita.fr>
3268
3269 * src/conflicts.c (finalize_conflicts): Rename as...
3270 (free_conflicts): this.
3271
3272 2001-09-22 Akim Demaille <akim@epita.fr>
3273
3274 * src/gram.c (gram_free): Rename back as...
3275 (dummy): this.
3276 (output_token_translations): Free `token_translations'.
3277 * src/symtab.c (free_symtab): Free the tag field.
3278
3279 2001-09-22 Akim Demaille <akim@epita.fr>
3280
3281 Remove `translations' as it is always set to true.
3282
3283 * src/gram.h: Adjust.
3284 * src/reader.c (packsymbols, parse_token_decl): Adjust
3285 * src/print.c (print_grammar): Adjust.
3286 * src/output.c (output_token_translations): Adjust.
3287 * src/lex.c (lex): Adjust.
3288 * src/gram.c: Be sure the set pointers to NULL.
3289 (dummy): Rename as...
3290 (gram_free): this.
3291
3292 2001-09-22 Akim Demaille <akim@epita.fr>
3293
3294 * configure.in: Invoke AM_LIB_DMALLOC.
3295 * src/system.h: Use dmalloc.
3296 * src/LR0.c: Be sure to have pointers initialized to NULL.
3297 (allocate_itemsets): Allocate kernel_items only if needed.
3298
3299 2001-09-22 Akim Demaille <akim@epita.fr>
3300
3301 * configure.in: Bump to 1.29b.
3302 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
3303 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
3304 need xmalloc.c in calc.y.
3305 From Pascal Bart.
3306
3307 2001-09-21 Akim Demaille <akim@epita.fr>
3308
3309 Version 1.29a.
3310 * Makefile.maint, config/config.guess, config/config.sub,
3311 * config/missing: Update from masters.
3312 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
3313 upon package.m4.
3314 * configure.in (ALL_LINGUAS): Add `tr'.
3315
3316 2001-09-21 Akim Demaille <akim@epita.fr>
3317
3318 * tests/Makefile.am (package.m4): Move to...
3319 ($(srcdir)/$(TESTSUITE)): here.
3320
3321 2001-09-20 Akim Demaille <akim@epita.fr>
3322
3323 * src/complain.c: No longer try to be standalone: use system.h.
3324 Don't assume __STDC__ is defined to 1. Just test if it is defined.
3325 * src/complain.h: Likewise.
3326 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
3327 Remove the unused variable `n'.
3328 From Albert Chin-A-Young.
3329
3330 2001-09-18 Marc Autret <autret_m@epita.fr>
3331
3332 * doc/bison.1: Update.
3333 * doc/bison.texinfo (Bison Options): Update --defines and --graph
3334 descriptions.
3335 (Option Cross Key): Update.
3336 Add --graph.
3337
3338 2001-09-18 Marc Autret <autret_m@epita.fr>
3339
3340 * tests/regression.at: New test (comment in %union).
3341
3342 2001-09-18 Marc Autret <autret_m@epita.fr>
3343
3344 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
3345 do that.
3346 Reported by Keith Browne.
3347
3348 2001-09-18 Marc Autret <autret_m@epita.fr>
3349
3350 * tests/output.at: Add tests for --defines and --graph.
3351
3352 2001-09-18 Marc Autret <autret_m@epita.fr>
3353
3354 * tests/output.at: Removes tests of %{header,src}_extension features.
3355
3356 2001-09-18 Akim Demaille <akim@epita.fr>
3357
3358 * tests/Makefile.am (package.m4): New.
3359 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
3360 (_AT_CHECK_CALC_ERROR): Likewise.
3361 Factor the `, ' part of verbose error messages.
3362
3363 2001-09-18 Marc Autret <autret_m@epita.fr>
3364
3365 * src/getargs.c (longopts): Declare --defines and --graph as options
3366 with optional arguments.
3367 * src/files.h: Add extern declarations.
3368 * src/files.c (spec_graph_file, spec_defines_file): New.
3369 (output_files): Update.
3370 Remove CPP-outed code.
3371
3372 2001-09-18 Marc Autret <autret_m@epita.fr>
3373
3374 Turn off %{source,header}_extension feature.
3375
3376 * src/files.c (compute_exts_from_gf): Update.
3377 (compute_exts_from_src): Update.
3378 (output_files): CPP-out useless code.
3379 * src/files.h: Remove {header,source}_extension extern declarations.
3380 * src/reader.c (parse_dquoted_param): CPP-out.
3381 (parse_header_extension_decl): Remove.
3382 (parse_source_extension_decl): Remove.
3383 (read_declarations): Remove cases tok_{hdrext,srcext}.
3384 * src/lex.c (percent_table): Remove {header,source}_extension entries.
3385 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
3386
3387 2001-09-10 Akim Demaille <akim@epita.fr>
3388
3389 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
3390 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
3391 (AT_CHECK_OUTPUT): this.
3392 Merely check ls' exit status, its output is useless.
3393
3394 2001-09-10 Akim Demaille <akim@epita.fr>
3395
3396 * tests/calc.at: Use m4_match.
3397 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
3398
3399 2001-09-10 Marc Autret <autret_m@epita.fr>,
3400 Akim Demaille <akim@epita.fr>
3401
3402 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
3403 enum color_e.
3404 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
3405 to `normal'.
3406 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
3407 * src/lex.h: Adjust prototype.
3408 (token_t): Add `tok_undef'.
3409 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
3410 (parse_percent_token): Now returns token_t.
3411 Add default statement in switch.
3412 (lex): Separate `c' as an input variable, from the token_t result
3413 part.
3414 (unlexed): Is a token_t.
3415
3416 2001-09-10 Akim Demaille <akim@epita.fr>
3417
3418 * configure.in: Bump to 1.29a.
3419
3420 2001-09-07 Akim Demaille <akim@epita.fr>
3421
3422 Version 1.29.
3423
3424 2001-08-30 Akim Demaille <akim@epita.fr>
3425
3426 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
3427 * m4/atconfig.m4: Remove.
3428 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
3429 * tests/bison: New.
3430 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
3431 m4_if, m4_patsubst, and m4_regexp.
3432 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
3433 `input' file instead of echo.
3434
3435 2001-08-29 Akim Demaille <akim@epita.fr>
3436
3437 Bump to 1.28e.
3438
3439 2001-08-29 Akim Demaille <akim@epita.fr>
3440
3441 Version 1.28d.
3442
3443 2001-08-29 Paul Eggert <eggert@twinsun.com>
3444
3445 * src/bison.simple (yyparse): Don't take the address of an
3446 item before the start of an array, as that doesn't conform to
3447 the C Standard.
3448
3449 2001-08-29 Robert Anisko <anisko_r@epita.fr>
3450
3451 * doc/bison.texinfo (Location Tracking Calc): New node.
3452
3453 2001-08-29 Paul Eggert <eggert@twinsun.com>
3454
3455 * src/output.c (output): Do not define const, as this now
3456 causes more problems than it cures.
3457
3458 2001-08-29 Akim Demaille <akim@epita.fr>
3459
3460 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
3461 the nodes.
3462 Be sure to tag the `detailmenu'.
3463
3464 2001-08-29 Akim Demaille <akim@epita.fr>
3465
3466 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
3467 download in a tmp dir.
3468
3469 2001-08-28 Marc Autret <autret_m@epita.fr>
3470
3471 * config/depcomp: New file.
3472
3473 2001-08-28 Marc Autret <autret_m@epita.fr>
3474
3475 * doc/bison.1 (mandoc): Adjust.
3476 From Juan Manuel Guerrero.
3477
3478 2001-08-28 Marc Autret <autret_m@epita.fr>
3479
3480 * src/print_graph.c (print_state): Fix.
3481
3482 2001-08-27 Marc Autret <autret_m@epita.fr>
3483
3484 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
3485 char * members.
3486 Echo modifications to the functions prototypes.
3487 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
3488
3489 2001-08-27 Marc Autret <autret_m@epita.fr>
3490
3491 * src/vcg.c: Include `xalloc.h'.
3492 (add_colorentry): New.
3493 (add_classname): New.
3494 (add_infoname): New.
3495 * src/vcg.h: Add new prototypes.
3496
3497 2001-08-27 Akim Demaille <akim@epita.fr>
3498
3499 * Makefile.maint: Sync. again with CVS Autoconf.
3500
3501 2001-08-27 Akim Demaille <akim@epita.fr>
3502
3503 * Makefile.maint: Formatting changes.
3504 (po-update, cvs-update, update): New targets.
3505 (AMTAR): Remove.
3506
3507 2001-08-27 Akim Demaille <akim@epita.fr>
3508
3509 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
3510 * Makefile.maint: Sync. with CVS Autoconf.
3511
3512 2001-08-27 Marc Autret <autret_m@epita.fr>
3513
3514 * src/vcg.h (struct infoname_s): New.
3515 (struct colorentry_s): New.
3516 (graph_s): New fields {vertical,horizontal}_order in structure.
3517 Add `infoname' field.
3518 Add `colorentry' field;
3519 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
3520 (G_HORIZONTAL_ORDER): New.
3521 (G_INFONAME): New.
3522 (G_COLORENTRY): New.
3523 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
3524 Add output of `infoname'.
3525 Add output of `colorentry'.
3526
3527 2001-08-27 Marc Autret <autret_m@epita.fr>
3528
3529 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
3530 This one shadowed a global parameter.
3531
3532 2001-08-24 Marc Autret <autret_m@epita.fr>
3533
3534 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
3535 instead of `unsigned'.
3536 (print_state): Do not call obstack_object_size () in obstack_grow ()
3537 to avoid macro variables shadowing.
3538
3539 2001-08-23 Marc Autret <autret_m@epita.fr>
3540
3541 * src/lex.c (percent_table): Typo: s/naem/name/.
3542 Add graph option.
3543 Normalize new options declarations.
3544
3545 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
3546
3547 * tests/suite.at: Exercise %header_extension and %source_extension.
3548
3549 2001-08-16 Marc Autret <autret_m@epita.fr>
3550
3551 * src/reader.c (parse_dquoted_param): New.
3552 (parse_header_extension_decl): Use it.
3553 (parse_source_extension_decl): Likewise.
3554
3555 2001-08-16 Marc Autret <autret_m@epita.fr>
3556
3557 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
3558 (get_xxxx_str): Use assert () instead of complain ().
3559 Remove return invokations in default cases.
3560 (get_decision_str): Modify default behaviour. Remove second argument.
3561 Echo modifications on calls.
3562 (output_graph): Fix.
3563
3564 2001-08-16 Marc Autret <autret_m@epita.fr>
3565
3566 * src/getargs.c (usage): Update with ``-g, --graph''.
3567
3568 2001-08-16 Marc Autret <autret_m@epita.fr>
3569
3570 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
3571 (Option Cross Key): Likewise.
3572 * doc/bison.1: Update.
3573
3574 2001-09-25 Pascal Bart <pascal.bart@epita.fr>
3575
3576 * src/output.c (output_master_parser): Don't finish action_obstack.
3577 (output_parser): Don't care about the muscle action, here.
3578 (prepare): Copy the action_obstack in the action muscle.
3579 (output): Free action_obstack.
3580
3581 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
3582
3583 * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which
3584 will contain `%union' declaration.
3585 (parse_union_decl): Delete #line directive output.
3586 (parse_union_decl): Substitute /attrs_obstack/union_obstack for all
3587 informations about %union.
3588 (parse_union_decl): Copy the union_obstack in the muscle stype.
3589 * src/bison.simple: Add new #line directive.
3590 Add typdef %%stype YYSTYPE.
3591
3592 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
3593
3594 * src/bison.simple: Add new `#line' directive.
3595
3596 2001-09-22 Pascal Bart <pascal.bart@epita.fr>
3597
3598 * src/bison.simple: New `#line' directive.
3599 * src/output.c (output_parser): Support new dynamic muscle input_line.
3600
3601 2001-09-22 Marc Autret <autret_m@epita.fr>
3602
3603 * src/output.c (output_master_parser): New.
3604 (output_parser): Be more re-entrant.
3605
3606 2001-09-21 Marc Autret <autret_m@epita.fr>
3607
3608 * src/reader.c (copy_definition, parse_union_decl): Update and use
3609 `linef' muscle.
3610 (copy_action): Likewise.
3611 Use obstack_1grow ().
3612 * src/muscle_tab.c (muscle_init): Add muscle `linef'.
3613
3614 2001-09-21 Marc Autret <autret_m@epita.fr>
3615
3616 * src/options.c (option_table): Adjust.
3617 * src/lex.c (parse_percent_token): Fix.
3618
3619 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
3620
3621 * src/options.c (symtab.h): Include it, need by lex.h.
3622
3623 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
3624
3625 * src/lex.c (parse_percent_token): Change type of variable `tx', which
3626 is now an option_table_struct*.
3627 (option_strcmp): New function option_strcmp.
3628 (parse_percent_token): Call option_strcmp.
3629 * src/getargs.c (xalloc.h, options.h): Include it.
3630 (getargs): Call create_long_option_table.
3631 (getargs): Free longopts at the end of the function.
3632 (shortopts): Move in options.c.
3633 * src/options.c (create_long_option_table): New function. Convert
3634 information from option_table to option structure.
3635 * src/reader.c (options.h): Include it.
3636
3637 * src/Makefile.am: Adjust.
3638 * src/options.c (option_table): Create from longopts and percent_table.
3639 * src/getargs.c (longopts): Delete.
3640 * src/lex.c (struct percent_table_struct): Delete.
3641 (percent_table): Delete.
3642 (options.h): Include it.
3643 * src/options.c: Create.
3644 * src/options.h: Create.
3645 Declare enum opt_access_e.
3646 Define struct option_table_struct.
3647
3648 2001-09-20 Marc Autret <autret_m@epita.fr>
3649
3650 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
3651 sections of Bison.
3652
3653 2001-09-19 Pascal Bart <pascal.bart@epita.fr>
3654
3655 * src/bison.simple: s/%%filename/%%skeleton.
3656 * src/muscle_tab.c (getargs.h): Include it.
3657 (muscle_init): Insert new muscle skeleton.
3658
3659 2001-09-18 Pascal Bart <pascal.bart@epita.fr>
3660
3661 * src/output.c (output_parser): Delete unused variable actions_dumped.
3662
3663 2001-09-07 Pascal Bart <pascal.bart@epita.fr>
3664
3665 * src/output.c (output): Delete call to reader_output_yylsp.
3666 * src/reader.c (reader): Likewise.
3667 * src/reader.h: Delete declaration of reader_output_yylsp.
3668
3669 2001-09-02 Marc Autret <autret_m@epita.fr>
3670
3671 * src/reader.c: Include muscle_tab.h.
3672 (parse_union_decl): Update.
3673 (parse_macro_decl): Rename parse_muscle_decl.
3674 Update to use renamed functions and variable.
3675 (read_declarations, copy_action, read_additionnal_code, : Updated
3676 with correct variables and functions names.
3677 (packsymbols, reader): Likewise.
3678
3679 * src/reader.h (muscle_obstack): Extern declaration update.
3680
3681 * src/output.c: Include muscle_tab.h
3682 In all functions using macro_insert, change by using muscle_insert ().
3683 (macro_obstack): Rename muscle_obstack.
3684 Echo modifications in the whole file.
3685 (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT.
3686 (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING.
3687 (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX.
3688
3689 * src/muscle_tab.h: Update double inclusion macros.
3690 (macro_entry_s): Rename muscle_entry_s.
3691 Update prototypes.
3692
3693 * src/muscle_tab.c: Include muscle_tab.h.
3694 Rename macro_tabble to muscle_table.
3695 (mhash1, mhash2, mcmp): Use muscle_entry.
3696 (macro_init): Rename muscle_init. Update.
3697 (macro_insert): Rename muscle_insert. Update.
3698 (macro_find): Rename muscle_find. Update.
3699
3700 * src/main.c: Include muscle_tab.h.
3701 (main): Call muscle_init ().
3702 * src/Makefile.am (bison_SOURCES): Echo modifications.
3703
3704 2001-09-02 Marc Autret <autret_m@epita.fr>
3705
3706 Now the files macro_tab.[ch] are named muscle_tab.[ch].
3707
3708 * src/muscle_tab.c, src/muscle_tab.h: Add files.
3709
3710 2001-09-02 Marc Autret <autret_m@epita.fr>
3711
3712 * src/macrotab.c, src/macrotab.h: Remove.
3713
3714 2001-09-01 Pascal Bart <pascal.bart@epita.fr>
3715
3716 * src/reader.c (copy_guard): Use muscle to specify the `#line'
3717 filename.
3718
3719 2001-09-01 Marc Autret <autret_m@epita.fr>
3720
3721 * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set
3722 to an explicit value to activate the feature. We do it here.
3723
3724 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
3725
3726 * src/output.c (prepare): Delete the `filename' muscule insertion.
3727 * src/reader.c (copy_action): Use `filename' muscule with `#line'.
3728 (parse_union_decl): Likewise.
3729 * src/macrotab.c (macro_init): Initialize filename by infile.
3730
3731 2001-08-31 Marc Autret <autret_m@epita.fr>
3732
3733 * src/bison.simple (YYLSP_NEEDED): New definition.
3734 * src/output.c (prepare): Add macro insertion of `locations_flag'
3735
3736 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
3737
3738 * src/output.c (prepare): Delete insertion of previous muscles,
3739 and insert the `prefix' muscles.
3740 * src/macrotab.c (macro_init): Likewise.
3741 (macro_init): Initialization prefix directive by `yy'.
3742 * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval,
3743 %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar,
3744 yylval, yydebug, yyerror, yynerrs and yyparse.
3745 New directive `#define' to substitute yydebug, ... with option
3746 name_prefix.
3747
3748 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
3749
3750 * src/main.c (main): Standardize.
3751 * src/output.c (output_table_data, output_parser): Likewise.
3752 * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise.
3753
3754 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr>
3755
3756 * src/reader.c (read_additionnal_code): Rename %%user_code to
3757 %%epilogue.
3758 * src/output.c (output): Rename %%declarations to %%prologue.
3759 * src/bison.simple: Echo modifications.
3760
3761 2001-08-31 Marc Autret <autret_m@epita.fr>
3762
3763 * src/reader.c (readgram): CleanUp.
3764 (output_token_defines): Likewise.
3765 (packsymbols): Likewise.
3766 (reader): Likewise.
3767 * src/output.c (output): CPP-out useless code.
3768
3769 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
3770
3771 * src/reader.c (reader): Delete obsolete call to function
3772 output_trailers and output_headers.
3773 * src/output.h: Remove obsolete functions prototypes of output_headers
3774 and output_trailers.
3775
3776 2001-08-30 Pascal Bart <pascal.bart@epita.fr>
3777
3778 * src/main.c: Include macrotab.h.
3779 * src/macrotab.h (macro_entry_s): Constify fields.
3780 Adjust functions prototypes.
3781 * src/macrotab.c (macro_insert): Constify key and value.
3782 (macro_find): Constify key.
3783 (macro_insert): Include 'xalloc.h'
3784 (macro_insert): Use XMALLOC.
3785 (macro_find): Constify return value.
3786 * src/output.c (output_table_data): Rename table to table_data.
3787 (output_parser): Constify macro_key, macro_value.
3788
3789 2001-08-30 Marc Autret <autret_m@epita.fr>
3790
3791 * src/reader.c (parse_skel_decl): New.
3792 (read_declarations): Add case `tok_skel', call parse_skel_decl ().
3793 * src/lex.h (token_t): New token `tok_skel'.
3794 * src/lex.c (percent_table): Add skeleton option entry.
3795 Standardize.
3796
3797 2001-08-29 Marc Autret <autret_m@epita.fr>
3798
3799 * src/bison.simple: Add %%user_code directive at the end.
3800 * src/reader.c (read_additionnal_code): New.
3801 (reader): Use it.
3802 * src/output.c (output_program): Remove.
3803 (output): Update.
3804
3805 2001-08-28 Marc Autret <autret_m@epita.fr>
3806
3807 * src/output.c (output_actions): Clean up.
3808 (output_gram): CPP-out useless code.
3809 * src/reader.c (reader): Clean up, CPP-out useless code.
3810
3811 2001-08-28 Pascal Bart <pascal.bart@epita.fr>
3812
3813 * src/output.c (output): Copy attrs_obstack in the '%%definitions'
3814 directive.
3815 * src/bison.simple: Add `%%definitions'.
3816
3817 2001-08-28 Marc Autret <autret_m@epita.fr>
3818
3819 * config/depcomp: New file.
3820
3821 2001-08-27 Paul Eggert <eggert@twinsun.com>
3822
3823 * src/bison.simple (yyparse): Don't take the address of an
3824 item before the start of an array, as that doesn't conform to
3825 the C Standard.
3826
3827 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
3828
3829 * src/output.c (output): Remove the initialization of the macro
3830 obstack. It was done too late here.
3831
3832 * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was
3833 completely wrong.
3834 (reader): Initialize the macro obstack here, since we need it to grow
3835 '%define' directives.
3836
3837 * src/reader.h: Declare the macro obstack as extern.
3838
3839 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
3840
3841 * src/output.c (output_parser): Fix. Store single '%' characters in
3842 the output obstack instead of throwing them away.
3843
3844 2001-08-27 Akim Demaille <akim@epita.fr>
3845
3846 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
3847
3848 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3849
3850 * lib/Makefile.am: Adjust.
3851
3852 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3853
3854 * src/bison.simple: Update and add '%%' directives.
3855
3856 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3857
3858 * src/reader.c (reader): Remove calls to 'output_headers' and
3859 'output_trailers'. Remove some C output.
3860 (readgram): Disable a piece of code that was writing a default
3861 definition for 'YYSTYPE'.
3862 (reader_output_yylsp): Remove.
3863 (packsymbols): Output token defintions to a macro.
3864 (copy_definition): Disable C output.
3865
3866 * src/reader.c (parse_macro_decl): New function used to parse macro
3867 declarations.
3868 (copy_string2): Put the body of copy_string into this new function.
3869 Add a parameter to let the caller choose whether he wants to copy the
3870 string delimiters or not.
3871 (copy_string): Be a simple call to copy_string2 with the last argument
3872 bound to true.
3873 (read_declarations): Add case for macro definition.
3874 (copy_identifier): New.
3875 (parse_macro_decl): Read macro identifiers using copy_identifier
3876 rather than lex.
3877
3878 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3879
3880 * src/output.c (prepare): Add prefixed names.
3881 (output_parser): Output semantic actions.
3882 (output_parser): Fix bug on '%%line' directives.
3883
3884 * src/output.c (output_headers): Remove. The C code printed by this
3885 function should now be in the skeletons.
3886 (output_trailers): Remove.
3887 (output): Disable call to 'reader_output_yylsp'.
3888 (output_rule_data): Do not output tables to the table obstack.
3889
3890 * src/output.c: Remove some C dedicated output.
3891 Improve the use of macro and output obstacks.
3892 (output_defines): Remove.
3893
3894 * src/output.c (output_token_translations): Associate 'translate'
3895 table with a macro. No output to the table obstack.
3896 (output_gram): Same for 'rhs' and 'prhs'.
3897 (output_stos): Same for 'stos'.
3898 (output_rule_data): Same for 'r1' and 'r2'.
3899 (token_actions): Same for 'defact'.
3900 (goto_actions): Same for 'defgoto'.
3901 (output_base): Same for 'pact' and 'pgoto'.
3902 (output_table): Same for 'table'.
3903 (output_check): Same for 'check'.
3904
3905 * src/output.c (output_table_data): New function.
3906 (output_short_table): Remove.
3907 (output_short_or_char_table): Remove.
3908
3909 * src/output.c (output_parser): Replace most of the skeleton copy code
3910 with something new. Skeletons are now processed character by character
3911 rather than line by line, and Bison looks for '%%' macros. This is the
3912 first step in making Bison's output process (a lot) more flexible.
3913 (output_parser): Use the macro table.
3914
3915 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3916
3917 * src/main.c (main): Initialize the macro table.
3918
3919 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3920
3921 * src/lex.c (percent_table): Add tok_define.
3922 * src/lex.h: Add tok_define.
3923
3924 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3925
3926 * src/macrotab.c: New file.
3927 * src/macrotab.h: New file.
3928 * src/Makefile.am: Update.
3929
3930 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
3931
3932 * lib/hash.c: New file.
3933 * lib/hash.h: New file.
3934 * lib/Makefile.am: Update.
3935
3936 2001-08-15 Akim Demaille <akim@epita.fr>
3937
3938 Version 1.28c.
3939
3940 2001-08-15 Marc Autret <autret_m@epita.fr>
3941
3942 * src/reader.c (readgram): Indent output macro YYSTYPE.
3943 (packsymbols): Likewise.
3944 (output_token_defines): Likewise.
3945 * src/files.c: Standardize.
3946 (compute_header_macro): New.
3947 (defines_obstack_save): New. Use compute_header_macro.
3948 (output_files): Update. Use defines_obstack_save.
3949
3950 2001-08-15 Akim Demaille <akim@epita.fr>
3951
3952 * doc/bison.texinfo (Table of Symbols): Document
3953 YYSTACK_USE_ALLOCA.
3954
3955 2001-08-15 Akim Demaille <akim@epita.fr>
3956
3957 * missing: Update from CVS Automake.
3958 * config/config.guess, config/config.sub, config/texinfo.tex:
3959 Update from gnu.org.
3960
3961 2001-08-15 Akim Demaille <akim@epita.fr>
3962
3963 * Makefile.maint: Sync with CVS Autoconf.
3964
3965 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
3966
3967 * doc/bison.texinfo: Include GNU Free Documentation License from
3968 `fdl.texi'.
3969 * doc/fdl.texi: Add to package.
3970
3971 2001-08-14 Marc Autret <autret_m@epita.fr>
3972
3973 Turn on %{source,header}_extension features.
3974
3975 * src/lex.c (percent_table): Un-CPP out header_extension and
3976 source_extension.
3977 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
3978 (compute_exts_from_src): Remove conditions. It restores priorities
3979 between options.
3980
3981 2001-08-14 Marc Autret <autret_m@epita.fr>
3982
3983 * src/files.c (compute_base_names): Add extensions computing when
3984 `--file-prefix' used.
3985 Standardize function calls.
3986
3987 2001-08-13 Marc Autret <autret_m@epita.fr>
3988
3989 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
3990 defining it (defined but null disables alloca).
3991
3992 2001-08-13 Marc Autret <autret_m@epita.fr>
3993
3994 * src/bison.simple (_yy_memcpy): CPP reformat.
3995
3996 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
3997
3998 * tests/atconfig.in (CPPFLAGS): Fix.
3999
4000 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
4001
4002 * doc/bison.texinfo: Include GNU General Public License from
4003 `gpl.texi'.
4004 * doc/gpl.texi: Add to package.
4005
4006 2001-08-10 Marc Autret <autret_m@epita.fr>
4007
4008 * src/print_graph.h: Fix.
4009 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
4010
4011 2001-08-10 Akim Demaille <akim@epita.fr>
4012
4013 * src/system.h: Provide default declarations for stpcpy, strndup,
4014 and strnlen.
4015
4016 2001-08-10 Robert Anisko <anisko_r@epita.fr>
4017
4018 * doc/bison.texinfo (Locations): Update @$ stuff.
4019
4020 2001-08-09 Robert Anisko <anisko_r@epita.fr>
4021
4022 * src/bison.simple (YYLLOC_DEFAULT): Update.
4023 (yyparse): Adjust.
4024
4025 2001-08-08 Marc Autret <autret_m@epita.fr>
4026
4027 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
4028 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
4029 Reported by Fabrice Bauzac.
4030
4031 2001-08-08 Marc Autret <autret_m@epita.fr>
4032
4033 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
4034 * src/vcg.c (output_node): Fix.
4035 * src/vcg.h: Cleanup.
4036 * src/print_graph.c: Add comments.
4037 (node_output_size): New global variable. Simplify the formatting of
4038 the VCG graph output.
4039 (print_actions): Unused code is now used. It notifies the final state
4040 and no action states in the VCG graph. It also give the reduce actions.
4041 The `shift and goto' edges are red and the `go to state' edges are
4042 blue.
4043 Get the current node name and node_obstack by argument.
4044 (node_obstack): New variable.
4045 (print_state): Manage node_obstack.
4046 (print_core): Use node_obstack given by argument.
4047 A node is not only computed here but in print_actions also.
4048 (print_graph): CPP out useless code instead of commenting it.
4049
4050 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
4051
4052 * tests/atconfig.in (CPPFLAGS): Fix.
4053
4054 2001-08-07 Akim Demaille <akim@epita.fr>
4055
4056 * src/print_graph.c (quote): New.
4057 (print_core): Use it.
4058
4059 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
4060
4061 * src/vcg.c (complain.h): Include it.
4062 Unepitaize `return' invocations.
4063 [NDEBUG] (main): Remove.
4064 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
4065 * src/files.c (open_files): Initialize graph_obstack.
4066 * src/print_graph.c (print_actions): CPP out useless code.
4067 (print_core): Don't output the last `\n' in labels.
4068 Use `quote'.
4069 * src/files.c (output_files): Output the VCG file.
4070 * src/main.c (main): Invoke print_graph ();
4071
4072 2001-08-06 Marc Autret <autret_m@epita.fr>
4073
4074 Automaton VCG graph output.
4075 Using option ``-g'' or long option ``--graph'', you can generate
4076 a gram_filename.vcg file containing a VCG description of the LALR (1)
4077 automaton of your grammar.
4078
4079 * src/main.c: Call to print_graph() function.
4080 * src/getargs.h: Update.
4081 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
4082 (graph_flag): New flag.
4083 (longopts): Update.
4084 (getargs): Add case `g'.
4085 * src/files.c (graph_obstack): New obstack struct.
4086 (open_files): Initialize new obstack.
4087 (output_files): Saves graph_obstack if required.
4088 * src/files.h (graph_obstack): New extern declaration.
4089 * src/Makefile.am: Add new source files.
4090
4091 2001-08-06 Marc Autret <autret_m@epita.fr>
4092
4093 * src/print_graph.c, src/print_graph.h (graph): New.
4094 * src/vcg.h: New file.
4095 * src/vcg.c: New file, VCG graph handling.
4096
4097 2001-08-06 Marc Autret <autret_m@epita.fr>
4098
4099 Add of %source_extension and %header_extension which specify
4100 the source or/and the header output file extension.
4101
4102 * src/files.c (compute_base_names): Remove initialisation of
4103 src_extension and header_extension.
4104 (compute_exts_from_gf): Update.
4105 (compute_exts_from_src): Update.
4106 (output_files): Update.
4107 * src/reader.c (parse_header_extension_decl): New.
4108 (parse_source_extension_decl): New.
4109 (read_declarations): New case statements for the new tokens.
4110 * src/lex.c (percent_table): Add entries for %source_extension
4111 and %header_extension.
4112 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
4113
4114 2001-08-06 Marc Autret <autret_m@epita.fr>
4115
4116 * configure.in: Bump to 1.28c.
4117 * doc/bison.texinfo: Texinfo thingies.
4118
4119 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
4120
4121 * tests/atconfig.in (CPPFLAGS): Add.
4122 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
4123
4124 2001-08-03 Akim Demaille <akim@epita.fr>
4125
4126 Version 1.28b.
4127
4128 2001-08-03 Akim Demaille <akim@epita.fr>
4129
4130 * tests/Makefile.am (check-local): Ship testsuite.
4131 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
4132 Include `string.h'.
4133
4134 2001-08-03 Akim Demaille <akim@epita.fr>
4135
4136 * configure.in: Try using -Wformat when compiling.
4137
4138 2001-08-03 Akim Demaille <akim@epita.fr>
4139
4140 * configure.in: Bump to 1.28b.
4141
4142 2001-08-03 Akim Demaille <akim@epita.fr>
4143
4144 * src/complain.c: Adjust strerror_r portability issues.
4145
4146 2001-08-03 Akim Demaille <akim@epita.fr>
4147
4148 Version 1.28a.
4149
4150 2001-08-03 Akim Demaille <akim@epita.fr>
4151
4152 * src/getargs.c, src/getarg.h (skeleton)): Constify.
4153 * src/lex.c (literalchar): Avoid name clashes on `buf'.
4154 * src/getargs.c: Include complain.h.
4155 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
4156 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
4157
4158 2001-08-03 Akim Demaille <akim@epita.fr>
4159
4160 * src/reader.c (readgram): Display hidden chars in error messages.
4161
4162 2001-08-03 Akim Demaille <akim@epita.fr>
4163
4164 Update to gettext 0.10.39.
4165
4166 2001-08-03 Akim Demaille <akim@epita.fr>
4167
4168 * lib/strspn.c: New.
4169
4170 2001-08-01 Marc Autret <autret_m@epita.fr>
4171
4172 * doc/bison.texinfo: Update.
4173 * doc/bison.1 (mandoc): Update.
4174 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
4175 * src/files.c: Support output files extensions computing.
4176 (src_extension): New static variable.
4177 (header_extension): New static variable.
4178 (tr): New function.
4179 (get_extension_index): New function, gets the index of an extension
4180 filename in a string.
4181 (compute_exts_from_gf): New function, computes extensions from the
4182 grammar file extension.
4183 (compute_exts_from_src): New functions, computes extensions from the
4184 C source file extension, file given by ``-o'' option.
4185 (compute_base_names): Update.
4186 (output_files): Update.
4187
4188 2001-08-01 Robert Anisko <anisko_r@epita.fr>
4189
4190 * doc/bison.texi: Document @$.
4191 (Locations): New section.
4192
4193 2001-07-18 Akim Demaille <akim@epita.fr>
4194
4195 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
4196 * config/prev-version.txt, config/move-if-change: New.
4197 * Makefile.am: Adjust.
4198
4199 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
4200
4201 * src/bison.simple (yyparse): Suppress warning `comparaison
4202 between signed and unsigned'.
4203
4204 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
4205
4206 * src/getargs.h (raw_flag): Remove.
4207 * src/getargs.c: Die on `-r'/`--raw'.
4208 * src/lex.c (parse_percent_token): Die on `%raw'.
4209 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
4210 * tests/calc.at: Suppress test with option `--raw'.
4211
4212 2001-07-14 Akim Demaille <akim@epita.fr>
4213
4214 * config/: New.
4215 * configure.in: Require Autoconf 2.50.
4216 Update to gettext 0.10.38.
4217
4218 2001-03-16 Akim Demaille <akim@epita.fr>
4219
4220 * doc/bison.texinfo: ANSIfy the examples.
4221
4222 2001-03-16 Akim Demaille <akim@epita.fr>
4223
4224 * getargs.c (skeleton): New variable.
4225 (longopts): --skeleton is a new option.
4226 (shortopts, getargs): -S is a new option.
4227 * getargs.h: Declare skeleton.
4228 * output.c (output_parser): Use it.
4229
4230 2001-03-16 Akim Demaille <akim@epita.fr>
4231
4232 * m4/strerror_r.m4: New.
4233 * m4/error.m4: Run AC_FUNC_STRERROR_R.
4234 * lib/error.h, lib/error.c: Update.
4235
4236 2001-03-16 Akim Demaille <akim@epita.fr>
4237
4238 * src/getargs.c (longopts): Clean up.
4239
4240 2001-02-21 Akim Demaille <akim@epita.fr>
4241
4242 * src/reader.c (gensym): `gensym_count' is your own.
4243 Use a static buf to create the symbol name, as token_buffer is no
4244 longer a buffer.
4245
4246 2001-02-08 Akim Demaille <akim@epita.fr>
4247
4248 * src/conflicts.c (conflict_report): Be sure not to append to res
4249 between two calls, which could happen if both first sprintf were
4250 skipped, but not the first cp += strlen.
4251
4252 2001-02-08 Akim Demaille <akim@epita.fr>
4253
4254 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
4255 New, from fileutils 4.0.37.
4256 * configure.in: Require Autoconf 2.49c. I took some time before
4257 making this decision. This is the only way out for portability
4258 issues in Bison, it would mean way too much duplicate effort to
4259 import in Bison features implemented in 2.49c since 2.13.
4260 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
4261
4262 2001-02-02 Akim Demaille <akim@epita.fr>
4263
4264 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
4265 * lib/xalloc.h, lib/xmalloc.c: Update.
4266
4267 2001-01-19 Akim Demaille <akim@epita.fr>
4268
4269 Get rid of the ad hoc handling of token_buffer in the scanner: use
4270 the obstacks.
4271
4272 * src/lex.c (token_obstack): New.
4273 (init_lex): Initialize it. No longer call...
4274 (grow_token_buffer): this. Remove it.
4275 Adjust all the places which used it to use the obstack.
4276
4277 2001-01-19 Akim Demaille <akim@epita.fr>
4278
4279 * src/lex.h: Rename all the tokens:
4280 s/\bENDFILE\b/tok_eof/g;
4281 s/\bIDENTIFIER\b/tok_identifier/g;
4282 etc.
4283 Let them be enums, not #define, to ease debugging.
4284 Adjust all the code.
4285
4286 2001-01-18 Akim Demaille <akim@epita.fr>
4287
4288 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
4289 * src/lex.c (maxtoken, grow_token_buffer): Static.
4290
4291 2001-01-18 Akim Demaille <akim@epita.fr>
4292
4293 Since we now use obstacks, more % directives can be enabled.
4294
4295 * src/lex.c (percent_table): Also accept `%yacc',
4296 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
4297 `%debug'.
4298 Handle the actions for `%semantic_parser' and `%pure_parser' here,
4299 instead of returning a token.
4300 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
4301 * src/reader.c (read_declarations): Adjust.
4302 * src/files.c (open_files): Don't call `compute_base_names', don't
4303 compute `attrsfile' since they depend upon data which might be
4304 *in* the input file now.
4305 (output_files): Do it here.
4306 * src/output.c (output_headers): Document the fact that this patch
4307 introduces a guaranteed SEGV for semantic parsers.
4308 * doc/bison.texinfo: Document them.
4309 * tests/suite.at: Exercise these %options.
4310
4311 2000-12-20 Akim Demaille <akim@epita.fr>
4312
4313 Also handle the output file (--verbose) with obstacks.
4314
4315 * files.c (foutput): Remove.
4316 (output_obstack): New.
4317 Adjust all dependencies.
4318 * src/conflicts.c: Return a string.
4319 * src/system.h (obstack_grow_string): Rename as...
4320 (obstack_sgrow): this. Be ready to work with non literals.
4321 (obstack_fgrow4): New.
4322
4323 2000-12-20 Akim Demaille <akim@epita.fr>
4324
4325 * src/files.c (open_files): Fix the computation of short_base_name
4326 in the case of `-o foo.tab.c'.
4327
4328 2000-12-20 Akim Demaille <akim@epita.fr>
4329
4330 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
4331 (copy_dollar): Now that everything uses obstacks, get rid of the
4332 FILE * parameters.
4333
4334 2000-12-20 Akim Demaille <akim@epita.fr>
4335
4336 * src/files.c (open_files): Actually the `.output' file is based
4337 on the short_base_name, not base_name.
4338 * tests/suite.at (Checking output file names): Adjust.
4339
4340 2000-12-20 Akim Demaille <akim@epita.fr>
4341
4342 * src/bison.s1: Remove, we now use directly...
4343 * src/bison.simple: this.
4344 * src/Makefile.am: Use pkgdata instead of data.
4345
4346 2000-12-20 Akim Demaille <akim@epita.fr>
4347
4348 * src/files.c (guard_obstack): New.
4349 (open_files): Initialize it.
4350 (output_files): Dump it...
4351 * src/files.h: Export it.
4352 * src/reader.c (copy_guard): Use it.
4353
4354 2000-12-19 Akim Demaille <akim@epita.fr>
4355
4356 * src/files.c (outfile, defsfile, actfile): Removed as global
4357 vars.
4358 (open_files): Don't compute them.
4359 (output_files): Adjust.
4360 (base_name, short_base_name): Be global.
4361 Adjust dependencies.
4362
4363 2000-12-19 Akim Demaille <akim@epita.fr>
4364
4365 * src/files.c (strsuffix): New.
4366 (stringappend): Be just like strcat but allocate.
4367 (base_names): Eve out from open_files.
4368 Try to simplify the rather hairy computation of base_name and
4369 short_base_name.
4370 (open_files): Use it.
4371 * tests/suite.at (Checking output file names): New test.
4372
4373 2000-12-19 Akim Demaille <akim@epita.fr>
4374
4375 * src/system.h (obstack_grow_literal_string): Rename as...
4376 (obstack_grow_string): this.
4377 * src/output.c (output_parser): Recognize `%% actions' instead of
4378 `$'.
4379 * src/bison.s1: s/$/%% actions/.
4380 * src/bison.hairy: Likewise.
4381
4382 2000-12-19 Akim Demaille <akim@epita.fr>
4383
4384 * src/output.c (output_parser): Compute the `#line' lines when
4385 there are.
4386 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
4387 Suggested by Hans Aberg.
4388
4389 2000-12-19 Akim Demaille <akim@epita.fr>
4390
4391 Let the handling of the skeleton files be local to the procedures
4392 that use it.
4393
4394 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
4395 longer static.
4396 (fparser, open_extra_files): Remove.
4397 (open_files, output_files): Don't take care of fparser.
4398 * src/files.h: Adjust.
4399 * src/output.c (output_parser): Open and close the file to the
4400 skeleton.
4401 * src/reader.c (read_declarations): When %semantic_parser, open
4402 fguard.
4403
4404 2000-12-19 Akim Demaille <akim@epita.fr>
4405
4406 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
4407 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
4408
4409 2000-12-19 Akim Demaille <akim@epita.fr>
4410
4411 * src/files.c (open_files): Yipee! We no longer need all the code
4412 looking for `/tmp' since we have no tmp file.
4413
4414 2000-12-19 Akim Demaille <akim@epita.fr>
4415
4416 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
4417 New macros.
4418 * src/files.c (open_files): Less dependency on MSDOS etc.
4419
4420 2000-12-14 Akim Demaille <akim@epita.fr>
4421
4422 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
4423 Provide a default definition.
4424 Use it when executing the default @ action.
4425 * src/reader.c (reader_output_yylsp): No longer include
4426 `timestamp' and `text' in the default YYLTYPE.
4427
4428 2000-12-12 Akim Demaille <akim@epita.fr>
4429
4430 * src/reader.c (copy_definition, parse_union_decl, copy_action)
4431 (copy_guard): Quote the file names.
4432 Reported by Laurent Mascherpa.
4433
4434 2000-12-12 Akim Demaille <akim@epita.fr>
4435
4436 * src/output.c (output_headers, output_program, output): Be sure
4437 to escape special characters when outputting filenames.
4438 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
4439 (output_headers): Don't depend on them, Use ACTSTR.
4440
4441 2000-11-17 Akim Demaille <akim@epita.fr>
4442
4443 * lib/obstack.h: Formatting changes.
4444 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
4445 prevents type checking.
4446 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
4447 cast the value to (void *): assigning a `foo *' to a `void *'
4448 variable is valid.
4449 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
4450 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
4451 append characters.
4452
4453 2000-11-17 Akim Demaille <akim@epita.fr>
4454
4455 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
4456 as...
4457 (suite.m4, regression.m4, calc.m4): these.
4458 * tests/atgeneral.m4: Update from CVS Autoconf.
4459
4460 2000-11-17 Akim Demaille <akim@epita.fr>
4461
4462 * tests/regression.m4 (%union and --defines): New test,
4463 demonstrating a current bug in the obstack implementation.
4464
4465 2000-11-17 Akim Demaille <akim@epita.fr>
4466
4467 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
4468 macros.
4469 Use them to declare the variables which are global or local to
4470 `yyparse'.
4471
4472 2000-11-17 Akim Demaille <akim@epita.fr>
4473
4474 * acconfig.h: Remove, no longer used.
4475
4476 2000-11-07 Akim Demaille <akim@epita.fr>
4477
4478 * src: s/Copyright (C)/Copyright/g.
4479
4480 2000-11-07 Akim Demaille <akim@epita.fr>
4481
4482 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
4483 defining.
4484 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
4485
4486 2000-11-07 Akim Demaille <akim@epita.fr>
4487
4488 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
4489 Merge in a single CPP if/else.
4490
4491 2000-11-07 Akim Demaille <akim@epita.fr>
4492
4493 * src/output.c (output): Remove useless variables.
4494 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
4495 argument `data' for consistency with the prototypes.
4496 Qualify it `const'.
4497 (obstack_copy, obstack_copy0): Rename the second argument as
4498 `address' for consistency. Qualify it `const'.
4499 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
4500 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
4501 `const' their input argument (`data' or `address').
4502 Adjust the corresponding macros to include `const' in casts.
4503
4504 2000-11-03 Akim Demaille <akim@epita.fr>
4505
4506 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
4507 s/PFILE1/BISON_HAIRY/.
4508 Adjust dependencies.
4509
4510 2000-11-03 Akim Demaille <akim@epita.fr>
4511
4512 For some reason, this was not applied.
4513
4514 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
4515 `unlink': it's no longer used.
4516
4517 2000-11-03 Akim Demaille <akim@epita.fr>
4518
4519 * src/files.c (skeleton_find): New function, eved out of...
4520 (open_files, open_extra_files): here.
4521
4522 2000-11-03 Akim Demaille <akim@epita.fr>
4523
4524 Don't use `atexit'.
4525
4526 * src/files.c (obstack_save): New function.
4527 (done): Rename as...
4528 (output_files): this.
4529 Use `obstack_save'.
4530 * src/main.c (main): Don't use `atexit' to register `done', since
4531 it no longer has to remove tmp files, just call `output_files'
4532 when there are no errors.
4533
4534 2000-11-02 Akim Demaille <akim@epita.fr>
4535
4536 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
4537 `unlink': it's no longer used.
4538 * src/files.h: Formatting changes.
4539
4540 2000-11-02 Akim Demaille <akim@epita.fr>
4541
4542 Remove the last uses of mktemp and unlink/delete.
4543
4544 * src/files.c (fdefines, ftable): Removed.
4545 (defines_ostack, table_obstack): New.
4546 Adjust dependencies of the former into uses of the latter.
4547 * src/output.c (output_short_or_char_table, output_short_table):
4548 Convert to using obstacks.
4549 * src/reader.c (copy_comment2): Accept one FILE * and two
4550 obstacks.
4551 (output_token_defines, reader_output_yylsp): Use obstacks.
4552 * src/system.h (obstack_fgrow3): New.
4553
4554 2000-11-01 Akim Demaille <akim@epita.fr>
4555
4556 Change each use of `fattrs' into a use of `attrs_obstack'.
4557
4558 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
4559 * src/files.c (fattrs): Remove.
4560 (attrs_obstack): New.
4561 Adjust all dependencies.
4562 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
4563
4564 2000-11-01 Akim Demaille <akim@epita.fr>
4565
4566 Introduce obstacks.
4567 Change each use of `faction' into a use of `action_obstack'.
4568
4569 * lib/obstack.h, lib/obstack.c: New files.
4570 * src/files.c (faction): Remove.
4571 (action_obstack): New.
4572 Adjust all dependencies.
4573
4574 2000-10-20 Akim Demaille <akim@epita.fr>
4575
4576 * lib/quote.h (PARAMS): New macro. Use it.
4577
4578 2000-10-16 Akim Demaille <akim@epita.fr>
4579
4580 * src/output.c (output_short_or_char_table): New function.
4581 (output_short_table, output_token_translations): Use it.
4582 (goto_actions): Use output_short_table.
4583
4584 2000-10-16 Akim Demaille <akim@epita.fr>
4585
4586 * src/symtab.c (bucket_new): New function.
4587 (getsym): Use it.
4588
4589 * src/output.c (output_short_table): New argument to display the
4590 comment associated with the table.
4591 Adjust dependencies.
4592 (output_gram): Use it.
4593 (output_rule_data): Nicer output layout for YYTNAME.
4594
4595 2000-10-16 Akim Demaille <akim@epita.fr>
4596
4597 * src/lex.c (read_typename): New function.
4598 (lex): Use it.
4599 * src/reader.c (copy_dollar): Likewise.
4600
4601 2000-10-16 Akim Demaille <akim@epita.fr>
4602
4603 * src/reader.c (copy_comment2): Expect the input stream to be on
4604 the `/' which is suspected to open a comment, instead of being
4605 called after `//' or `/*' was read.
4606 (copy_comment, copy_definition, parse_union_decl, copy_action)
4607 (copy_guard): Adjust.
4608
4609 2000-10-16 Akim Demaille <akim@epita.fr>
4610
4611 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
4612 `read_signed_integer'.
4613
4614 2000-10-16 Akim Demaille <akim@epita.fr>
4615
4616 * src/reader.c (copy_dollar): New function.
4617 (copy_guard, copy_action): Use it.
4618
4619 2000-10-16 Akim Demaille <akim@epita.fr>
4620
4621 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
4622 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
4623 New files, from Fileutils 4.0.27.
4624 * src/main.c (printable_version): Remove.
4625 * src/lex.c, src/reader.c: Use `quote'.
4626
4627 2000-10-04 Akim Demaille <akim@epita.fr>
4628
4629 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
4630
4631 2000-10-04 Akim Demaille <akim@epita.fr>
4632
4633 * doc/bison.texinfo: Various typos spotted by Neil Booth.
4634
4635 2000-10-04 Akim Demaille <akim@epita.fr>
4636
4637 When a literal string is used to define two different tokens,
4638 `bison -v' segfaults.
4639 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
4640
4641 * tests/regression.m4: New file.
4642 Include the core of the sample provided by Piotr Gackiewicz.
4643 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
4644 properly.
4645
4646 2000-10-04 Akim Demaille <akim@epita.fr>
4647
4648 * src/reader.c (parse_expect_decl): Keep `count' within the size
4649 of `buffer'.
4650 From Neil Booth.
4651
4652 2000-10-02 Paul Eggert <eggert@twinsun.com>
4653
4654 * bison.s1 (yyparse): Assign the default value
4655 unconditionally, to avoid a GCC warning and make the parser a
4656 tad smaller.
4657
4658 2000-10-02 Akim Demaille <akim@epita.fr>
4659
4660 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
4661 options.
4662
4663 2000-10-02 Akim Demaille <akim@epita.fr>
4664
4665 * src/derives.c, src/print.c, src/reduce.c: To ease the
4666 translation, move some `\n' out of the translated strings.
4667
4668 2000-10-02 Akim Demaille <akim@epita.fr>
4669
4670 The location tracking mechanism is precious for parse error
4671 messages. Nevertheless, it is enabled only when `@n' is used in
4672 the grammar, which is a different issue (you can use it in error
4673 message, but not in the grammar per se). Therefore, there should
4674 be another means to enable it.
4675
4676 * src/getargs.c (getargs): Support `--locations'.
4677 (usage): Report it.
4678 * src/getargs.h (locationsflag): Export it.
4679 * src/lex.c (percent_table): Support `%locations'.
4680 * src/reader.c (yylsp_needed): Remove this variable, now replaced
4681 with `locationsflag'.
4682 * doc/bison.texinfo: Document `--locations' and `%locations'.
4683 Sort the options.
4684 * tests/calc.m4: Test it.
4685
4686 For regularity of the names, replace each
4687 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
4688 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
4689 In addition replace each `flag' with `_flag'.
4690
4691 2000-10-02 Akim Demaille <akim@epita.fr>
4692
4693 Also test parse error messages, including with YYERROR_VERBOSE.
4694
4695 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
4696 associative).
4697 Use it to check the computations.
4698 Use it to check `nonassoc' is honored.
4699 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
4700 `--yyerror-verbose'.
4701 (_AT_CHECK_CALC): Adjust to this option.
4702 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
4703
4704 2000-10-02 Akim Demaille <akim@epita.fr>
4705
4706 Test also `--verbose', `--defines' and `--name-prefix'. Testing
4707 the latter demonstrates a flaw in the handling of non debugging
4708 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
4709 was used in order to simplify:
4710
4711 #if YYDEBUG
4712 if (yydebug)
4713 {
4714 ...
4715 }
4716 #endif
4717
4718 into
4719
4720 if (yydebug)
4721 {
4722 ...
4723 }
4724
4725 unfortunately this leads to a CPP conflict when
4726 `--name-prefix=foo' is used since it produces `#define yydebug
4727 foodebug'.
4728
4729 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
4730 (YYDPRINTF): New macro.
4731 Spread its use.
4732 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
4733 the bison options.
4734 Also test `--verbose', `--defines' and `--name-prefix'.
4735
4736 2000-10-02 Akim Demaille <akim@epita.fr>
4737
4738 Improve the readability of the produced parsers.
4739
4740 * src/bison.s1: Formatting changes.
4741 Improve the comment related to the `$' mark.
4742 (yydefault): Don't fall through to `yyresume': `goto' there.
4743 * src/output.c (output_parser): When the `$' is met, skip the end
4744 of its line.
4745 New variable, `number_of_dollar_signs', to check there's exactly
4746 one `$' in the parser skeleton.
4747
4748 2000-10-02 Akim Demaille <akim@epita.fr>
4749
4750 * lib/xstrdup.c: New file, from the fileutils.
4751 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
4752 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
4753 instead of strlen + xmalloc + strcpy.
4754 * src/symtab.c (copys): Remove, use xstrdup instead.
4755
4756 2000-10-02 Akim Demaille <akim@epita.fr>
4757
4758 * src/gram.h (associativity): New enum type which replaces the
4759 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
4760 `right_assoc', `left_assoc' and `non_assoc'.
4761 Adjust all dependencies.
4762 * src/reader.c: Formatting changes.
4763 (LTYPESTR): Don't define it, use it as a literal in
4764 `reader_output_yylsp'.
4765 * src/symtab.h (symbol_class): New enum type which replaces the
4766 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
4767 `sunknown', `stoken and `snterm'.
4768
4769 2000-10-02 Akim Demaille <akim@epita.fr>
4770
4771 * src/getargs.c (fixed_outfiles): Rename as...
4772 (yaccflag): for consistency and accuracy.
4773 Adjust dependencies.
4774
4775 2000-10-02 Akim Demaille <akim@epita.fr>
4776
4777 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
4778 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
4779 difficult and introduced a lot of core dump. It turns out that
4780 Bison used an implementation of `xmalloc' based on `calloc', and
4781 at various places it does depend upon the initialization to 0. I
4782 have not tried to isolate the pertinent places, and all the former
4783 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
4784 someone should address this issue.
4785
4786 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
4787 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
4788 files.
4789 Adjust dependencies.
4790 * src/warshall.h: New file.
4791 Propagate.
4792
4793 2000-10-02 Akim Demaille <akim@epita.fr>
4794
4795 Various anti-`extern in *.c' changes.
4796
4797 * src/system.h: Include `assert.h'.
4798
4799 2000-10-02 Akim Demaille <akim@epita.fr>
4800
4801 * src/state.h (nstates, final_state, first_state, first_shift)
4802 (first_reduction): Move their exportation from here...
4803 * src/LR0.h: to here.
4804 Adjust dependencies.
4805 * src/getargs.c (statisticsflag): New variable.
4806 Add support for `--statistics'.
4807 Adjust dependencies.
4808
4809 Remove a lot of now useless `extern' statements in most files.
4810
4811 2000-10-02 Akim Demaille <akim@epita.fr>
4812
4813 * src/LR0.h: New file.
4814 Propagate its use.
4815
4816 2000-10-02 Akim Demaille <akim@epita.fr>
4817
4818 * src/print.h: New file.
4819 Propagate its use.
4820 * src/print.c: Formatting and ordering changes.
4821 (verbose, terse): Replace with...
4822 (print_results): this new function.
4823 Adjust dependencies.
4824
4825 2000-10-02 Akim Demaille <akim@epita.fr>
4826
4827 * src/conflicts.c (conflict_report): New function.
4828 (conflict_log, verbose_conflict_log): Replace with...
4829 (print_conflicts): this function.
4830 Adjust dependencies.
4831 * src/conflicts.h: New file.
4832 Propagate its inclusion.
4833
4834 2000-10-02 Akim Demaille <akim@epita.fr>
4835
4836 * src/nullable.h: New file.
4837 Propagate its inclusion.
4838 * src/nullable.c: Formatting changes.
4839
4840 2000-10-02 Akim Demaille <akim@epita.fr>
4841
4842 * src/reduce.h: New file.
4843 Propagate its inclusion.
4844 * src/reduce.c: Topological sort and other formatting changes.
4845 (bool, TRUE, FALSE): Move their definition to...
4846 * src/system.h: here.
4847
4848 2000-10-02 Akim Demaille <akim@epita.fr>
4849
4850 * src/files.c: Formatting changes.
4851 (tryopen, tryclose, openfiles): Rename as...
4852 (xfopen, xfclose, open_files): this.
4853 (stringappend): static.
4854 * src/files.h: Complete the list of exported symbols.
4855 Propagate its use.
4856
4857 2000-10-02 Akim Demaille <akim@epita.fr>
4858
4859 * src/reader.h: New file.
4860 Propagate its use instead of tedious list of `extern' and
4861 prototypes.
4862 * src/reader.c: Formatting changes, topological sort,
4863 s/register//.
4864
4865 2000-10-02 Akim Demaille <akim@epita.fr>
4866
4867 * src/lex.h: Prototype `lex.c' exported functions.
4868 * src/reader.c: Adjust.
4869 * src/lex.c: Formatting changes.
4870 (safegetc): Rename as...
4871 (xgetc): this.
4872
4873 2000-10-02 Akim Demaille <akim@epita.fr>
4874
4875 * src/lalr.h: New file.
4876 Propagate its inclusion instead of prototypes and `extern'.
4877 * src/lalr.c: Formatting changes, topological sorting etc.
4878
4879 2000-10-02 Akim Demaille <akim@epita.fr>
4880
4881 * src/output.c (token_actions): Introduce a temporary array,
4882 YYDEFACT, that makes it possible for this function to use
4883 output_short_table.
4884
4885 2000-10-02 Akim Demaille <akim@epita.fr>
4886
4887 `user_toknums' is output as a `short[]' in `output.c', while it is
4888 defined as a `int[]' in `reader.c'. For consistency with the
4889 other output tables, `user_toknums' is now defined as a table of
4890 shorts.
4891
4892 * src/reader.c (user_toknums): Be a short table instead of an int
4893 table.
4894 Adjust dependencies.
4895
4896 Factor the short table outputs.
4897
4898 * src/output.c (output_short_table): New function.
4899 * src/output.c (output_gram, output_stos, output_rule_data)
4900 (output_base, output_table, output_check): Use it.
4901
4902 2000-10-02 Akim Demaille <akim@epita.fr>
4903
4904 * src/output.c (output): Topological sort of the functions, in
4905 order to get rid of the `static' prototypes.
4906 No longer use `register'.
4907 * src/output.h: New file.
4908 Propagate its inclusion in files explicitly prototyping functions
4909 from output.c.
4910
4911 2000-09-21 Akim Demaille <akim@epita.fr>
4912
4913 * src/atgeneral.m4: Update from Autoconf.
4914
4915 2000-09-21 Akim Demaille <akim@epita.fr>
4916
4917 * src/closure.h: New file.
4918 * src/closure.c: Formatting changes, topological sort over the
4919 functions, use of closure.h.
4920 (initialize_closure, finalize_closure): Rename as...
4921 (new_closure, free_closure): these. Adjust dependencies.
4922 * src/LR0.c: Formatting changes, topological sort, use of
4923 cloture.h.
4924 (initialize_states): Rename as...
4925 (new_states): this.
4926 * src/Makefile.am (noinst_HEADERS): Adjust.
4927
4928 2000-09-20 Akim Demaille <akim@epita.fr>
4929
4930 * src/acconfig.h: Don't protect config.h against multiple
4931 inclusion.
4932 Don't define PARAMS.
4933 * src/system.h: Define PARAMS.
4934 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
4935 purpose of config.h. system.h must not try to fix wrong
4936 definitions in config.h.
4937
4938 2000-09-20 Akim Demaille <akim@epita.fr>
4939
4940 * src/derives.h: New file.
4941 * src/main.c, src/derives.h: Use it.
4942 Formatting changes.
4943 * src/Makefile.am (noinst_HEADERS): Adjust.
4944
4945 2000-09-20 Akim Demaille <akim@epita.fr>
4946
4947 * tests/atgeneral.m4: Update from Autoconf.
4948 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
4949 (AT_CHECK_CALC): New macros.
4950 Use these macros to test bison with options `', `--raw',
4951 `--debug', `--yacc', `--yacc --debug'.
4952
4953 2000-09-19 Akim Demaille <akim@epita.fr>
4954
4955 * src/output.c: Formatting changes.
4956 * src/machine.h: Remove, leaving its contents in...
4957 * src/system.h: here.
4958 Include stdio.h.
4959 Adjust all dependencies on stdio.h and machine.h.
4960 * src/getargs.h: New file.
4961 Let all `extern' declarations about getargs.c be replaced with
4962 inclusion of `getargs.h'.
4963 * src/Makefile.am (noinst_HEADERS): Adjust.
4964
4965 * tests/calc.m4 (yyin): Be initialized in main, not on the global
4966 scope.
4967 (yyerror): Returns void, not int.
4968 * doc/bison.texinfo: Formatting changes.
4969
4970 2000-09-19 Akim Demaille <akim@epita.fr>
4971
4972 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
4973 portable.
4974
4975 2000-09-18 Akim Demaille <akim@epita.fr>
4976
4977 * configure.in: Append WARNING_CFLAGS to CFLAGS.
4978 * src/Makefile.am (INCLUDES): Don't.
4979 Be ready to fetch headers in lib/.
4980
4981 2000-09-18 Akim Demaille <akim@epita.fr>
4982
4983 * doc/bison.texinfo: Update the copyright.
4984 ANSIfy and GNUify the examples.
4985 Remove the old menu.
4986
4987 2000-09-18 Akim Demaille <akim@epita.fr>
4988
4989 First set of tests: use the `calc' example from the documentation.
4990
4991 * src/bison.s1 (yyparse): Condition the code using `yytname' which
4992 is defined only when YYDEBUG is.
4993 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
4994 * src/files.c (tryopen, tryclose): Formatting changes.
4995 Move to the top and be static.
4996 * src/reader.c (read_signed_integer): Likewise.
4997 * tests/calc.m4: New file.
4998 * Makefile.am, suite.m4: Adjust.
4999 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
5000
5001 2000-09-18 Akim Demaille <akim@epita.fr>
5002
5003 Add support for an Autotest test suite for Bison.
5004
5005 * m4/m4.m4, m4/atconfig.m4: New files.
5006 * m4/Makefile.am (EXTRA_DIST): Adjust.
5007 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
5008 files.
5009 * src/getargs.c: Display a more standard --version message.
5010 * src/reader.c (reader): Formatting changes.
5011 No longer depend upon VERSION_STRING.
5012 * configure.in: No longer use `dnl'.
5013 Set up the test suite and the new directory `tests/.
5014 (VERSION_STRING): Remove.
5015
5016 2000-04-14 Akim Demaille <akim@epita.fr>
5017
5018 * src/reader.c (copy_comment2): New function, same as former
5019 `copy_comment', but outputs into two FILE *.
5020 (copy_comment): Use it.
5021 (parse_union_decl): Use it.
5022 (get_type, parse_start_decl): Use the same `invalid' message.
5023 (parse_start_decl, parse_union_decl): Use the same `multiple'
5024 message.
5025 (parse_union_decl, copy_guard, copy_action): Use the same
5026 `unmatched' message.
5027 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
5028
5029 2000-03-31 Akim Demaille <akim@epita.fr>
5030
5031 * src/files.c (tryopen, tryclose): Move to the top.
5032 Be static.
5033
5034 2000-03-31 Akim Demaille <akim@epita.fr>
5035
5036 * src/main.c (main): Don't call `done', exit does it.
5037
5038 2000-03-31 Akim Demaille <akim@epita.fr>
5039
5040 * allocate.c: s/return (foo)/return foo/.
5041 * lalr.c: Likewise.
5042 * LR0.c: Likewise.
5043 * output.c: Likewise.
5044 * reader.c: Likewise.
5045 * symtab.c: Likewise.
5046 * vmsgetargs.c: Likewise.
5047
5048 2000-03-31 Akim Demaille <akim@epita.fr>
5049
5050 Clean up the error reporting functions.
5051
5052 * src/report.c: New file.
5053 * src/report.h: Likewise.
5054 * src/Makefile.am: Adjust.
5055 * m4/error.m4: New file.
5056 * m4/Makefile.am: Adjust.
5057 * configure.in (jm_PREREQ_ERROR): Call it.
5058 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
5059 Remove.
5060 (fatal, fatals): Remove. All callers use complain.c::fatal.
5061 (warn, warni, warns, warnss, warnss): Remove. All callers use
5062 complain.c::complain.
5063 (toomany): Remove, use fatal instead.
5064 * src/files.c (done): No argument, use complain_message_count.
5065 * src/main.c (main): Register `done' to `atexit'.
5066
5067 * src/getargs.c (usage): More `fputs', less `fprintf'.
5068
5069 2000-03-28 Akim Demaille <akim@epita.fr>
5070
5071 * lib/: New directory.
5072 * Makefile.am (SUBDIRS): Adjust.
5073 * configure.in: Adjust.
5074 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
5075 useless.
5076 * src/alloca.c: Moved to lib/.
5077 * src/getopt.c: Likewise.
5078 * src/getopt1.c: Likewise.
5079 * src/getopt.h: Likewise.
5080 * src/ansi2knr.c: Likewise.
5081 * src/ansi2knr.1: Likewise.
5082 * src/Makefile.am: Adjust.
5083 * lib/Makefile.am: New file.
5084
5085 2000-03-28 Akim Demaille <akim@epita.fr>
5086
5087 * src/getargs.c (usage): Refresh the help message.
5088
5089 2000-03-17 Akim Demaille <akim@epita.fr>
5090
5091 * src/getopt1.c: Updated from textutils 2.0e
5092 * src/getopt.c: Likewise.
5093 * src/getopt.h: Likewise.
5094
5095 2000-03-17 Akim Demaille <akim@epita.fr>
5096
5097 * src/Makefile.am (bison.simple): Fix the awk program: quote only
5098 the file name, not the whole `#line LINE FILE'.
5099
5100 2000-03-17 Akim Demaille <akim@epita.fr>
5101
5102 On syntax errors, report the token on which we choked.
5103
5104 * src/bison.s1 (yyparse): In the label yyerrlab, when
5105 YYERROR_VERBOSE, add yychar in msg.
5106
5107 2000-03-17 Akim Demaille <akim@epita.fr>
5108
5109 * src/reader.c (copy_at): New function.
5110 (copy_guard): Use it.
5111 (copy_action): Use it.
5112
5113 2000-03-17 Akim Demaille <akim@epita.fr>
5114
5115 Be kind to translators, save some useless translations.
5116
5117 * src/main.c (banner): New function.
5118 (fatal_banner): Use it.
5119 (warn_banner): Use it.
5120
5121 2000-03-17 Akim Demaille <akim@epita.fr>
5122
5123 * src/reader.c (copy_definition): Use copy_string and
5124 copy_comment. Removed now unused `match', `ended',
5125 `cplus_comment'.
5126 (copy_comment, copy_string): Moved, to be visible from
5127 copy_definition.
5128
5129 2000-03-17 Akim Demaille <akim@epita.fr>
5130
5131 * src/reader.c (copy_string): Declare `static inline'. No
5132 problems with inline, since it is checked by configure.
5133 (copy_comment): Likewise.
5134
5135 2000-03-17 Akim Demaille <akim@epita.fr>
5136
5137 * src/reader.c (packsymbols): Formatting changes.
5138
5139 2000-03-17 Akim Demaille <akim@epita.fr>
5140
5141 * src/reader.c (copy_comment): New function, factored out from:
5142 (copy_action): Use it. Removed now unused `match', `ended',
5143 `cplus_comment'.
5144 (copy_guard): Likewise.
5145
5146 2000-03-17 Akim Demaille <akim@epita.fr>
5147
5148 * src/reader.c (copy_string): New function, factored out from:
5149 (copy_action): Use it.
5150 (copy_guard): Likewise.
5151
5152 2000-03-17 Akim Demaille <akim@epita.fr>
5153
5154 Change the handling of @s so that they behave exactly like $s.
5155 There is now a pseudo variable @$ (readble and writable), location
5156 of the lhs of the rule (by default ranging from the location of
5157 the first symbol of the rhs, to the location of the last symbol,
5158 or, if the rhs is empty, YYLLOC).
5159
5160 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
5161 yyval.
5162 (yyparse): When providing a default semantic action, provide a
5163 default location action.
5164 (after the $): No longer change `*YYLSP', just stack YYLOC the
5165 same way you stack YYVAL.
5166 * src/reader.c (read_declarations): Use warns.
5167 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
5168 (copy_action, case '@'): Likewise.
5169 Use a standard error message, to save useless work from
5170 translators.
5171
5172 2000-03-17 Akim Demaille <akim@epita.fr>
5173
5174 * src/bison.s1: Formatting and cosmetics changes.
5175 * src/reader.c: Likewise.
5176 Update the Copyright notice.
5177
5178 2000-03-17 Akim Demaille <akim@epita.fr>
5179
5180 * src/bison.s1 (#line): All set to `#line' only, since the
5181 Makefile now handles them.
5182
5183 2000-03-16 Akim Demaille <akim@epita.fr>
5184
5185 * src/output.c (output_rule_data): Output the documentation of
5186 some of the tables.
5187 (Copyright notice): Update.
5188 Formatting changes.
5189
5190 2000-03-16 Akim Demaille <akim@epita.fr>
5191
5192 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
5193 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
5194 One `#if YYDEBUG' remains, since it uses variables which are
5195 defined only if `YYDEBUG != 0'.
5196
5197 2000-03-16 Akim Demaille <akim@epita.fr>
5198
5199 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
5200 and related variables so that the similarities are highlighted.
5201
5202 2000-03-16 Akim Demaille <akim@epita.fr>
5203
5204 * src/bison.s1: Properly indent CPP directives.
5205
5206 2000-03-16 Akim Demaille <akim@epita.fr>
5207
5208 * src/bison.s1: Properly indent the `alloca' CPP section.
5209
5210 2000-03-16 Akim Demaille <akim@epita.fr>
5211
5212 Do not hard code values of directories in `configure.in'.
5213 Update the `configure' tool chain.
5214
5215 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
5216 src/makefile.am.
5217 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
5218 (AC_OUTPUT): Add m4/Makefile.
5219 Bump to bison 1.28a, 1.29 has never been released.
5220 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
5221 handled via src/Makefile.am.
5222 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
5223 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
5224 autoheader.
5225 * Makefile.am (SUBDIRS): Add m4.
5226 (ACLOCAL_AM_FLAGS): New variable.
5227 (AUTOMAKE_OPTIONS): Add check-news.
5228 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
5229 the proper line number and file name.
5230 (DEFS): Propagate the location of bison library files and of the
5231 locale files.
5232 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
5233 builddir.
5234 * acinclude.m4: Remove, replaced by the directory m4.
5235 * m4/Makefile.am (EXTRA_DIST): New variable.
5236 * m4/gettext.m4: New file, from the fileutils.
5237 * m4/lcmessage.m4: Likewise
5238 * m4/progtest.m4: Likewise.
5239 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
5240
5241 2000-03-10 Akim Demaille <akim@epita.fr>
5242
5243 * src/closure.c:
5244 Formatting changes of various comments.
5245 Respect the GNU coding standards at various places.
5246 Don't use `_()' when no translation is needed.
5247
5248 1999-12-13 Jesse Thilo <jthilo@gnu.org>
5249
5250 * src/files.c:
5251 OS/2 honors TMPDIR environment variable.
5252
5253 1999-12-13 Jesse Thilo <jthilo@gnu.org>
5254
5255 * doc/bison.texinfo: Tweaked spelling and grammar.
5256 Updated ISBN.
5257 Removed reference to price of printed copy.
5258 Mention BISON_SIMPLE and BISON_HAIRY.
5259
5260 1999-12-13 Jesse Thilo <jthilo@gnu.org>
5261
5262 * configure.in, NEWS:
5263 Bison 1.29 released.
5264
5265 1999-10-27 Jesse Thilo <jthilo@gnu.org>
5266
5267 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
5268 Added reference card.
5269
5270 1999-07-26 Jesse Thilo <jthilo@gnu.org>
5271
5272 * po/ru.po: Added Russian translation.
5273
5274 1999-07-26 Jesse Thilo <jthilo@gnu.org>
5275
5276 * configure.in: Added Russian translation.
5277
5278 1999-07-06 Jesse Thilo <jthilo@gnu.org>
5279
5280 * configure.in, NEWS, README:
5281 Released version 1.28.
5282
5283 1999-06-14 Jesse Thilo <jthilo@gnu.org>
5284
5285 * src/system.h:
5286 Squashed redefinition warning on some systems.
5287
5288 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
5289 Have configure build version string instead of relying on ANSI string
5290 concatentation.
5291
5292 1999-06-14 Jesse Thilo <jthilo@gnu.org>
5293
5294 * po/POTFILES.in: Got rid of version.c.
5295
5296 1999-06-14 Jesse Thilo <jthilo@gnu.org>
5297
5298 * acconfig.h, configure.in:
5299 Have configure build version string instead of relying on ANSI string
5300 concatentation.
5301
5302 1999-06-08 Jesse Thilo <jthilo@gnu.org>
5303
5304 * doc/bison.1:
5305 Dropped mention of `+' for long-named options.
5306
5307 1999-05-30 Jesse Thilo <jthilo@gnu.org>
5308
5309 * src/files.c: Added <unistd.h> for unlink().
5310
5311 * src/Makefile.am, src/system.h:
5312 I18n fixes.
5313
5314 1999-05-30 Jesse Thilo <jthilo@gnu.org>
5315
5316 * README: Added a FAQ list.
5317
5318 * configure.in, acconfig.h:
5319 I18n fixes.
5320
5321 1999-05-30 Jesse Thilo <jthilo@gnu.org>
5322
5323 * doc/FAQ, doc/Makefile.am:
5324 Added a FAQ list.
5325
5326 1999-05-19 Jesse Thilo <jthilo@gnu.org>
5327
5328 * src/alloc.h, src/symtab.h, src/version.c:
5329 Protected inclusion of "config.h" with HAVE_CONFIG_H.
5330
5331 1999-04-18 Jesse Thilo <jthilo@gnu.org>
5332
5333 * src/.cvsignore, src/Makefile.am:
5334 Reorganized: sources in `src', documentation in `doc'.
5335
5336 * src/lex.c (literalchar):
5337 fixed the code for escaping double quotes (thanks
5338 Jonathan Czisny.)
5339
5340 1999-04-18 Jesse Thilo <jthilo@gnu.org>
5341
5342 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
5343 Adjusted paths to reflect directory reorganization.
5344
5345 1999-04-18 Jesse Thilo <jthilo@gnu.org>
5346
5347 * doc/.cvsignore, doc/Makefile.am:
5348 Reorganized: sources in `src', documentation in `doc'.
5349
5350 1999-04-18 Jesse Thilo <jthilo@gnu.org>
5351
5352 * configure.in:
5353 Updated AC_INIT file to reflect directory reorganization.
5354
5355 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
5356 Reorganized: sources in `src', documentation in `doc'.
5357
5358 1999-04-13 Jesse Thilo <jthilo@gnu.org>
5359
5360 * src/allocate.c:
5361 Don't declare calloc() and realloc() if not necessary.
5362
5363 1999-04-13 Jesse Thilo <jthilo@gnu.org>
5364
5365 * configure.in, acconfig.h, acinclude.m4:
5366 Don't declare calloc() and realloc() if not necessary.
5367
5368 1999-03-23 Jesse Thilo <jthilo@gnu.org>
5369
5370 * po/.cvsignore: Added i18n support.
5371
5372 1999-03-23 Jesse Thilo <jthilo@gnu.org>
5373
5374 * acconfig.h, configure.in, Makefile.am:
5375 Added i18n support.
5376
5377 1999-03-22 Jesse Thilo <jthilo@gnu.org>
5378
5379 * src/bison.s1: Fixed #line numbers.
5380
5381 1999-03-15 Jesse Thilo <jthilo@gnu.org>
5382
5383 * po/es.po, po/fr.po, po/nl.po, po/de.po:
5384 Added PO files from Translation Project.
5385
5386 1999-03-03 Jesse Thilo <jthilo@gnu.org>
5387
5388 * Makefile.am:
5389 Added support for non-ANSI compilers (ansi2knr).
5390
5391 1999-02-16 Jesse Thilo <jthilo@gnu.org>
5392
5393 * configure.in: Bumped version number to 1.27.
5394
5395 * Makefile.am:
5396 Added `bison.simple' to list of files removed by `make distclean'.
5397
5398 1999-02-12 Jesse Thilo <jthilo@gnu.org>
5399
5400 * src/files.c, src/files.h:
5401 Defined locations of parser files in config.h instead of Makefile.
5402
5403 1999-02-12 Jesse Thilo <jthilo@gnu.org>
5404
5405 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
5406 Defined locations of parser files in config.h instead of Makefile.
5407
5408 1999-02-09 Jesse Thilo <jthilo@gnu.org>
5409
5410 * Makefile.am:
5411 Removed inappropriate use of $< macro.
5412
5413 1999-02-05 Jesse Thilo <jthilo@gnu.org>
5414
5415 * po/Makefile.in.in, po/POTFILES.in:
5416 Add `po' directory skeleton.
5417
5418 1999-01-27 Jesse Thilo <jthilo@gnu.org>
5419
5420 * README: Document help-bison list.
5421
5422 * configure.in: Add check for mkstemp().
5423
5424 1999-01-20 Jesse Thilo <jthilo@gnu.org>
5425
5426 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
5427 Hush a few compiler warnings.
5428
5429 * src/files.c:
5430 Add tryclose(), which verifies that fclose was successful.
5431 Hush a couple of compiler warnings.
5432
5433 1999-01-20 Jesse Thilo <jthilo@gnu.org>
5434
5435 * Makefile.am, OChangeLog:
5436 ChangeLog is now automatically generated. Include the old version as
5437 OChangeLog.
5438
5439 1999-01-14 Jesse Thilo <jthilo@gnu.org>
5440
5441 * 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:
5442 Update FSF address.
5443
5444 1999-01-14 Jesse Thilo <jthilo@gnu.org>
5445
5446 * doc/bison.texinfo: Fix formatting glitch.
5447
5448 * doc/bison.texinfo: Update FSF address.
5449
5450 1999-01-14 Jesse Thilo <jthilo@gnu.org>
5451
5452 * acconfig.h: Update FSF address.
5453
5454 1999-01-08 Jesse Thilo <jthilo@gnu.org>
5455
5456 * src/system.h:
5457 Don't define PACKAGE here, since config.h defines it.
5458
5459 1998-12-30 Jesse Thilo <jthilo@gnu.org>
5460
5461 * src/reader.c: Update copyright date.
5462
5463 * src/main.c:
5464 Ditch sprintf to statically-sized buffers in fatal/warn functions in
5465 favor of output directly to stderr (avoids buffer overruns).
5466
5467 * src/reader.c: Some checks for premature EOF.
5468
5469 * 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:
5470 Use prototypes if the compiler understands them.
5471
5472 * src/files.c: Honor TMPDIR on Unix hosts.
5473 Use prototypes if the compiler understands them.
5474
5475 * src/reader.c:
5476 Fix a couple of buffer overrun bugs.
5477 Use prototypes if the compiler understands them.
5478
5479 * src/system.h: Include unistd.h and ctype.h.
5480 Use #ifdef instead of #if for NLS symbols.
5481
5482 1998-12-30 Jesse Thilo <jthilo@gnu.org>
5483
5484 * doc/bison.texinfo:
5485 Delete comment "consider using @set for edition number, etc..." since
5486 we now are doing so.
5487
5488 1998-12-30 Jesse Thilo <jthilo@gnu.org>
5489
5490 * configure.in:
5491 Use prototypes if the compiler understands them.
5492
5493 * NEWS: Document 1.26 highlights.
5494
5495 * Makefile.am: Require Automake 1.3 or later.
5496
5497 * acconfig.h:
5498 Use prototypes if the compiler understands them.
5499
5500 1998-12-29 Jesse Thilo <jthilo@gnu.org>
5501
5502 * src/version.c:
5503 Use VERSION symbol from automake for version number.
5504
5505 1998-12-29 Jesse Thilo <jthilo@gnu.org>
5506
5507 * acconfig.h, configure.in, version.cin:
5508 Use VERSION symbol from automake for version number.
5509
5510 1998-11-28 Jesse Thilo <jthilo@gnu.org>
5511
5512 * Makefile.am:
5513 Distribute original version of simple parser (bison.s1), not built
5514 version (bison.simple).
5515
5516 1998-11-28 Jesse Thilo <jthilo@gnu.org>
5517
5518 * doc/bison.texinfo: Add info dir entry.
5519
5520 * doc/bison.texinfo:
5521 Let automake put version number into documentation.
5522
5523 1998-11-26 Jesse Thilo <jthilo@gnu.org>
5524
5525 * src/bison.cld, src/build.com, src/vmshlp.mar:
5526 Add non-RCS files from /gd/gnu/bison.
5527
5528 1998-11-26 Jesse Thilo <jthilo@gnu.org>
5529
5530 * doc/bison.1:
5531 Document the BISON_HAIRY and BISON_SIMPLE variables.
5532
5533 1998-11-25 Jesse Thilo <jthilo@gnu.org>
5534
5535 * src/version.c: Build version.c automatically.
5536
5537 * src/reader.c:
5538 Fix token numbering (used to start at 258, not 257).
5539
5540 * src/system.h: Include config.h.
5541
5542 * src/getargs.c: Update bug report address.
5543
5544 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
5545 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
5546
5547 1998-11-25 Jesse Thilo <jthilo@gnu.org>
5548
5549 * Makefile.am:
5550 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
5551
5552 * configure.in, version.cin:
5553 Build version.c automatically.
5554
5555 * AUTHORS: Add AUTHORS file.
5556
5557 * README: Update bug report address.
5558
5559 * bison.simple:
5560 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
5561
5562 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
5563 Add automake stuff.
5564
5565 1998-11-25 Jesse Thilo <jthilo@gnu.org>
5566
5567 * doc/bison.texinfo: Clean up some formatting.
5568
5569 1998-05-05 Richard Stallman <rms@gnu.org>
5570
5571 * doc/bison.texinfo:
5572 Explain better why to make a pure parser.
5573
5574 1998-01-05 Richard Stallman <rms@gnu.org>
5575
5576 * src/files.c (openfiles):
5577 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
5578 find a temporary directory, if possible. Do not unlink files while
5579 they are open.
5580
5581 1997-08-25 Richard Stallman <rms@gnu.org>
5582
5583 * src/reader.c (stack_offset;):
5584 Change some warni to warns.
5585
5586 * src/lex.c (literalchar): Use warns, not warni.
5587
5588 1997-06-28 Richard Stallman <rms@gnu.org>
5589
5590 * src/bison.s1: Add a Bison version comment.
5591
5592 * src/main.c (fatal, warn, berror):
5593 Use program_name.
5594
5595 1997-06-28 Richard Stallman <rms@gnu.org>
5596
5597 * Makefile.in (bison_version): New variable.
5598 (dist): Use that variable.
5599 (bison.s1): Substitute the Bison version into bison.simple.
5600
5601 * bison.simple: Add a Bison version comment.
5602
5603 1997-06-18 Richard Stallman <rms@gnu.org>
5604
5605 * src/main.c (fatal, warn, berror):
5606 Make error messages standard.
5607 (toomany): Improve error message text.
5608
5609 * 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:
5610 new.h renamed to alloc.h.
5611
5612 1997-06-18 Richard Stallman <rms@gnu.org>
5613
5614 * Makefile.in: new.h renamed to alloc.h.
5615
5616 1997-05-24 Richard Stallman <rms@gnu.org>
5617
5618 * src/lex.c (literalchar):
5619 Fix the code for escaping \, " and '.
5620
5621 (lex): Avoid trouble when there are many chars
5622 to discard in a char literal with just several chars in it.
5623
5624 1997-05-17 Richard Stallman <rms@gnu.org>
5625
5626 * src/bison.s1:
5627 Use malloc, if using alloca is troublesome.
5628 (YYSTACK_USE_ALLOCA): New flag macro.
5629 Define it for some systems and compilers.
5630 (YYSTACK_ALLOC): New macro.
5631 (yyparse): Use YYSTACK_ALLOC to allocate stack.
5632 If it was malloc'd, free it.
5633
5634 1997-05-17 Richard Stallman <rms@gnu.org>
5635
5636 * bison.simple:
5637 Use malloc, if using alloca is troublesome.
5638 (YYSTACK_USE_ALLOCA): New flag macro.
5639 Define it for some systems and compilers.
5640 (YYSTACK_ALLOC): New macro.
5641 (yyparse): Use YYSTACK_ALLOC to allocate stack.
5642 If it was malloc'd, free it.
5643
5644 1997-04-23 Richard Stallman <rms@gnu.org>
5645
5646 * src/bison.s1:
5647 (alloca) [__hpux]: Always define as __builtin_alloca.
5648
5649 1997-04-23 Richard Stallman <rms@gnu.org>
5650
5651 * bison.simple:
5652 (alloca) [__hpux]: Always define as __builtin_alloca.
5653
5654 1997-04-22 Richard Stallman <rms@gnu.org>
5655
5656 * src/bison.s1:
5657 [__hpux]: Include alloca.h (right for HPUX 10)
5658 instead of declaring alloca (right for HPUX 9).
5659
5660 * src/bison.s1 (__yy_memcpy):
5661 Declare arg `count' as unsigned int.
5662 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
5663
5664 1997-04-22 Richard Stallman <rms@gnu.org>
5665
5666 * bison.simple:
5667 [__hpux]: Include alloca.h (right for HPUX 10)
5668 instead of declaring alloca (right for HPUX 9).
5669
5670 * bison.simple (__yy_memcpy):
5671 Declare arg `count' as unsigned int.
5672 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
5673
5674 1997-01-03 Richard Stallman <rms@gnu.org>
5675
5676 * src/allocate.c: [__STDC__ or _MSC_VER]:
5677 Declare calloc and realloc to return void *.
5678
5679 1997-01-02 Richard Stallman <rms@gnu.org>
5680
5681 * src/system.h:
5682 [_MSC_VER]: Include stdlib.h and process.h.
5683 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
5684
5685 * src/main.c (main): Return FAILURE as a value.
5686 (printable_version): Declare arg as int, not char.
5687
5688 1997-01-02 Richard Stallman <rms@gnu.org>
5689
5690 * Makefile.in (dist):
5691 Explicitly check for symlinks, and copy them.
5692
5693 1996-12-19 Richard Stallman <rms@gnu.org>
5694
5695 * src/files.c:
5696 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
5697
5698 1996-12-18 Paul Eggert <eggert@gnu.org>
5699
5700 * src/bison.s1 (yyparse):
5701 If __GNUC__ and YYPARSE_PARAM are both defined,
5702 declare yyparse to have a void * argument.
5703
5704 1996-12-18 Paul Eggert <eggert@gnu.org>
5705
5706 * bison.simple (yyparse):
5707 If __GNUC__ and YYPARSE_PARAM are both defined,
5708 declare yyparse to have a void * argument.
5709
5710 1996-12-17 Richard Stallman <rms@gnu.org>
5711
5712 * src/reduce.c (nbits): Add some casts.
5713
5714 1996-08-12 Richard Stallman <rms@gnu.org>
5715
5716 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
5717
5718 1996-08-12 Richard Stallman <rms@gnu.org>
5719
5720 * bison.simple: Test _MSDOS as well as _MSDOS_.
5721
5722 1996-07-31 Richard Stallman <rms@gnu.org>
5723
5724 * src/bison.s1:
5725 [__sun && __i386]: Include alloca.h.
5726
5727 1996-07-31 Richard Stallman <rms@gnu.org>
5728
5729 * bison.simple:
5730 [__sun && __i386]: Include alloca.h.
5731
5732 1996-07-30 Richard Stallman <rms@gnu.org>
5733
5734 * src/bison.s1: Comment change.
5735
5736 * src/bison.s1: Test _MSDOS_, not MSDOS.
5737
5738 1996-07-30 Richard Stallman <rms@gnu.org>
5739
5740 * bison.simple: Comment change.
5741
5742 * bison.simple: Test _MSDOS_, not MSDOS.
5743
5744 1996-06-01 Richard Stallman <rms@gnu.org>
5745
5746 * 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:
5747 Insert `_' macro around many string constants.
5748
5749 * src/main.c:
5750 Insert `_' macro around many string constants.
5751
5752 (main): Call setlocale, bindtextdomain and textdomain.
5753
5754 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
5755 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
5756 [ENABLE_NLS]: Include libintl.h.
5757 [ENABLE_NLS] (gettext): Define.
5758 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
5759 (N_, PACKAGE, LOCALEDIR): New macros.
5760
5761 1996-06-01 Richard Stallman <rms@gnu.org>
5762
5763 * POTFILES.in: New file.
5764
5765 * Makefile.in (allocate.o):
5766 Define target explicitly.
5767
5768 * Makefile.in (CFLAGS): Set to @CFLAGS@.
5769 (LDFLAGS): Set to @LDFLAGS@.
5770 (configure): Run autoconf only if preceding `cd' succeeds.
5771 (bison.s1): Redirect output to temporary file then move the
5772 temporary to the target, rather than redirecting directly to bison.s1.
5773 (clean): Remove config.status and config.log.
5774 (distclean): Don't remove config.status here.
5775
5776 1996-05-12 Richard Stallman <rms@gnu.org>
5777
5778 * src/bison.s1:
5779 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
5780
5781 1996-05-12 Richard Stallman <rms@gnu.org>
5782
5783 * bison.simple:
5784 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
5785
5786 1996-05-11 Richard Stallman <rms@gnu.org>
5787
5788 * src/bison.s1 (__yy_memcpy):
5789 Really reorder the args, as was supposedly done on Feb 14 1995.
5790 (yyparse): Calls changed accordingly.
5791
5792 1996-05-11 Richard Stallman <rms@gnu.org>
5793
5794 * Makefile.in (dist): Don't use $(srcdir).
5795
5796 * bison.simple (__yy_memcpy):
5797 Really reorder the args, as was supposedly done on Feb 14 1995.
5798 (yyparse): Calls changed accordingly.
5799
5800 1996-01-27 Richard Stallman <rms@gnu.org>
5801
5802 * src/output.c (output_rule_data):
5803 Test YYERROR_VERBOSE in the conditional
5804 around the definition of ttyname.
5805
5806 1995-12-29 Richard Stallman <rms@gnu.org>
5807
5808 * src/bison.s1:
5809 Fix line numbers in #line commands.
5810
5811 1995-12-29 Richard Stallman <rms@gnu.org>
5812
5813 * bison.simple:
5814 Fix line numbers in #line commands.
5815
5816 1995-12-27 Richard Stallman <rms@gnu.org>
5817
5818 * src/bison.s1 (YYPARSE_PARAM_DECL):
5819 In C++, make it always null.
5820 (YYPARSE_PARAM_ARG): New macro.
5821 (yyparse): Use YYPARSE_PARAM_ARG.
5822
5823 1995-12-27 Richard Stallman <rms@gnu.org>
5824
5825 * bison.simple (YYPARSE_PARAM_DECL):
5826 In C++, make it always null.
5827 (YYPARSE_PARAM_ARG): New macro.
5828 (yyparse): Use YYPARSE_PARAM_ARG.
5829
5830 1995-11-29 Richard Stallman <rms@gnu.org>
5831
5832 * doc/bison.texinfo:
5833 Describe literal string tokens, %raw, %no_lines, %token_table.
5834
5835 1995-11-29 Daniel Hagerty <hag@gnu.org>
5836
5837 * doc/bison.texinfo: Fixed update date
5838
5839 1995-10-16 Richard Stallman <rms@gnu.org>
5840
5841 * src/version.c: Version 1.25.
5842
5843 1995-10-16 Richard Stallman <rms@gnu.org>
5844
5845 * NEWS: *** empty log message ***
5846
5847 1995-10-16 Richard Stallman <rms@gnu.org>
5848
5849 * doc/bison.1, doc/bison.rnh:
5850 Add new options.
5851
5852 1995-10-15 Richard Stallman <rms@gnu.org>
5853
5854 * src/vmsgetargs.c, src/getargs.c:
5855 Added -n, -k, and -raw switches.
5856 (noparserflag, toknumflag, rawtoknumflag): New variables.
5857
5858 * src/symtab.h (SALIAS):
5859 New #define for adding aliases to %token.
5860 (struct bucket): Added `alias' field.
5861
5862 * src/reduce.c (reduce_grammar):
5863 Revise error message.
5864 (print_notices): Remove final `.' from error message.
5865
5866 * src/reader.c (reader_output_yylsp):
5867 New function.
5868 (readgram): Use `#if 0' around code that accepted %command
5869 inside grammar rules: The documentation doesn't allow it,
5870 and it will fail since the %command processors scan for the next %.
5871 (parse_token_decl): Extended the %token
5872 declaration to allow a multi-character symbol as an alias.
5873 (parse_thong_decl): New function.
5874 (read_declarations): Added %thong declarations.
5875 (read_declarations): Handle NOOP to deal with allowing
5876 % declarations as another means to specify the flags.
5877 (readgram): Allow %prec prior to semantics embedded in a rule.
5878 (skip_to_char, read_declarations, copy_definition)
5879 (parse_token_decl, parse_start_decl, parse_type_decl)
5880 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
5881 (get_type_name, copy_guard, copy_action, readgram)
5882 (get_type, packsymbols): Revised most error messages.
5883 Changed `fatal' to `warnxxx' to avoid aborting for error.
5884 Revised and use multiple warnxxx functions to avoid using VARARGS1.
5885 (read_declarations): Improve the error message for
5886 an invalid character. Do not abort.
5887 (read_declarations, copy_guard, copy_action): Use
5888 printable_version to avoid unprintable characters in printed output.
5889 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
5890 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
5891 Allow the type of a non-terminal can be given
5892 more than once, as long as all specifications give the same type.
5893
5894 * src/output.c:
5895 (output_headers, output_trailers, output, output_gram)
5896 (output_rule_data): Implement noparserflag variable.
5897 Implement toknumflag variable.
5898 (output): Call reader_output_yylsp to output LTYPESTR.
5899
5900 * src/main.c (main):
5901 If reader sees an error, don't process the grammar.
5902 (fatals): Updated to not use VARARGS1.
5903 (printable_version, int_to_string, warn, warni, warns, warnss)
5904 (warnsss): New error reporting functions. Avoid abort for error.
5905
5906 * src/lex.h:
5907 Added THONG and NOOP for alias processing.
5908 Added SETOPT for the new code that allows setting options with %flags.
5909
5910 * src/lex.c:
5911 Include getopt.h. Add some extern decls.
5912 (safegetc): New function to deal with EOF gracefully.
5913 (literalchar); new function to deal with reading \ escapes.
5914 (lex): Use literalchar.
5915 (lex): Implemented "..." tokens.
5916 (literalchar, lex, parse_percent_token): Made tokenbuffer
5917 always contain the token. This includes growing the token
5918 buffer while reading an integer.
5919 (parse_percent_token): Replaced if-else statement with percent_table.
5920 (parse_percent_token): Added % declarations as another
5921 way to specify the flags -n, -l, and -r. Also added hooks for
5922 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
5923 major changes to files.c.
5924 (lex) Retain in the incoming stream a character following
5925 an incorrect '/'.
5926 (skip_white_space, lex): Revised most error messages
5927 and changed fatal to warn to avoid aborting.
5928 (percent_table): Added %thong declarations.
5929
5930 * src/gram.h: Comment changes.
5931
5932 * src/files.c (openfiles, open_extra_files, done):
5933 Add faction flag
5934 and actfile file. Handle noparserflag. Both for -n switch.
5935
5936 * src/conflicts.c (resolve_sr_conflict):
5937 Remove use of alloca.
5938
5939 1995-06-01 Jim Meyering <meyering@gnu.org>
5940
5941 * doc/bison.texinfo: *** empty log message ***
5942
5943 1995-05-06 Richard Stallman <rms@gnu.org>
5944
5945 * src/bison.s1: Comment change.
5946
5947 1995-05-06 Richard Stallman <rms@gnu.org>
5948
5949 * bison.simple: Comment change.
5950
5951 1995-05-03 Richard Stallman <rms@gnu.org>
5952
5953 * src/version.c: Version now 1.24.
5954
5955 * src/bison.s1: Change distribution terms.
5956
5957 * src/version.c: Version now 1.23.
5958
5959 1995-05-03 Richard Stallman <rms@gnu.org>
5960
5961 * doc/bison.texinfo:
5962 Rewrite "Conditions for Using Bison".
5963 Update version to 1.24.
5964
5965 1995-05-03 Richard Stallman <rms@gnu.org>
5966
5967 * bison.simple: Change distribution terms.
5968
5969 1995-02-23 Richard Stallman <rms@gnu.org>
5970
5971 * src/files.c: Test __VMS_POSIX as well as VMS.
5972
5973 1995-02-14 Jim Meyering <meyering@gnu.org>
5974
5975 * src/bison.s1 (__yy_memcpy):
5976 Renamed from __yy_bcopy to avoid
5977 confusion. Reverse FROM and TO arguments to be consistent with
5978 those of memcpy.
5979
5980 1995-02-14 Jim Meyering <meyering@gnu.org>
5981
5982 * bison.simple (__yy_memcpy):
5983 Renamed from __yy_bcopy to avoid
5984 confusion. Reverse FROM and TO arguments to be consistent with
5985 those of memcpy.
5986
5987 1994-11-10 David J. MacKenzie <djm@gnu.org>
5988
5989 * NEWS: reformat
5990
5991 * NEWS: New file.
5992
5993 * Makefile.in (DISTFILES): Include NEWS.
5994
5995 * Makefile.in (DISTFILES):
5996 Include install-sh, not install.sh.
5997
5998 * configure.in: Update to Autoconf v2 macro names.
5999
6000 1994-10-05 David J. MacKenzie <djm@gnu.org>
6001
6002 * Makefile.in: fix typo
6003
6004 * Makefile.in (prefix, exec_prefix):
6005 Let configure set them.
6006
6007 1994-09-28 David J. MacKenzie <djm@gnu.org>
6008
6009 * Makefile.in: Set datadir to $(prefix)/share.
6010
6011 1994-09-15 Richard Stallman <rms@gnu.org>
6012
6013 * src/bison.s1:
6014 Update copyright notice and GPL version.
6015
6016 1994-09-15 Richard Stallman <rms@gnu.org>
6017
6018 * bison.simple:
6019 Update copyright notice and GPL version.
6020
6021 1994-07-12 Richard Stallman <rms@gnu.org>
6022
6023 * src/reduce.c, src/reader.c:
6024 entered into RCS
6025
6026 1994-05-05 David J. MacKenzie <djm@gnu.org>
6027
6028 * Makefile.in: entered into RCS
6029
6030 1994-03-26 Richard Stallman <rms@gnu.org>
6031
6032 * src/bison.s1: entered into RCS
6033
6034 1994-03-26 Richard Stallman <rms@gnu.org>
6035
6036 * bison.simple: entered into RCS
6037
6038 1994-03-25 Richard Stallman <rms@gnu.org>
6039
6040 * src/main.c: entered into RCS
6041
6042 1994-03-24 Richard Stallman <rms@gnu.org>
6043
6044 * src/conflicts.c: entered into RCS
6045
6046 1994-01-02 Richard Stallman <rms@gnu.org>
6047
6048 * Makefile.in: *** empty log message ***
6049
6050 1993-11-21 Richard Stallman <rms@gnu.org>
6051
6052 * src/bison.s1: *** empty log message ***
6053
6054 1993-11-21 Richard Stallman <rms@gnu.org>
6055
6056 * doc/bison.texinfo: entered into RCS
6057
6058 * doc/bison.texinfo: *** empty log message ***
6059
6060 1993-11-21 Richard Stallman <rms@gnu.org>
6061
6062 * bison.simple: *** empty log message ***
6063
6064 1993-10-25 David J. MacKenzie <djm@gnu.org>
6065
6066 * doc/bison.texinfo: *** empty log message ***
6067
6068 1993-10-19 Richard Stallman <rms@gnu.org>
6069
6070 * src/bison.s1: *** empty log message ***
6071
6072 1993-10-19 Richard Stallman <rms@gnu.org>
6073
6074 * bison.simple: *** empty log message ***
6075
6076 1993-10-14 Richard Stallman <rms@gnu.org>
6077
6078 * src/bison.s1: *** empty log message ***
6079
6080 1993-10-14 Richard Stallman <rms@gnu.org>
6081
6082 * bison.simple: *** empty log message ***
6083
6084 1993-09-14 David J. MacKenzie <djm@gnu.org>
6085
6086 * doc/bison.texinfo: *** empty log message ***
6087
6088 1993-09-13 Noah Friedman <friedman@gnu.org>
6089
6090 * Makefile.in: *** empty log message ***
6091
6092 1993-09-10 Richard Stallman <rms@gnu.org>
6093
6094 * src/conflicts.c: *** empty log message ***
6095
6096 * src/system.h: entered into RCS
6097
6098 1993-09-10 Richard Stallman <rms@gnu.org>
6099
6100 * doc/bison.1: entered into RCS
6101
6102 1993-09-06 Noah Friedman <friedman@gnu.org>
6103
6104 * src/version.c: entered into RCS
6105
6106 1993-09-06 Noah Friedman <friedman@gnu.org>
6107
6108 * Makefile.in: *** empty log message ***
6109
6110 1993-07-30 David J. MacKenzie <djm@gnu.org>
6111
6112 * Makefile.in: *** empty log message ***
6113
6114 1993-07-24 Richard Stallman <rms@gnu.org>
6115
6116 * src/bison.s1: *** empty log message ***
6117
6118 1993-07-24 Richard Stallman <rms@gnu.org>
6119
6120 * bison.simple: *** empty log message ***
6121
6122 1993-07-08 David J. MacKenzie <djm@gnu.org>
6123
6124 * Makefile.in: *** empty log message ***
6125
6126 1993-07-04 Richard Stallman <rms@gnu.org>
6127
6128 * src/bison.s1: *** empty log message ***
6129
6130 1993-07-04 Richard Stallman <rms@gnu.org>
6131
6132 * bison.simple: *** empty log message ***
6133
6134 1993-06-26 David J. MacKenzie <djm@gnu.org>
6135
6136 * src/getargs.c: entered into RCS
6137
6138 1993-06-26 David J. MacKenzie <djm@gnu.org>
6139
6140 * doc/bison.texinfo: *** empty log message ***
6141
6142 * doc/bison.1: New file.
6143
6144 1993-06-25 Richard Stallman <rms@gnu.org>
6145
6146 * src/getargs.c: New file.
6147
6148 1993-06-16 Richard Stallman <rms@gnu.org>
6149
6150 * src/bison.s1: *** empty log message ***
6151
6152 1993-06-16 Richard Stallman <rms@gnu.org>
6153
6154 * bison.simple: *** empty log message ***
6155
6156 1993-06-03 Richard Stallman <rms@gnu.org>
6157
6158 * src/bison.s1: New file.
6159
6160 1993-06-03 Richard Stallman <rms@gnu.org>
6161
6162 * doc/bison.texinfo: *** empty log message ***
6163
6164 1993-06-03 Richard Stallman <rms@gnu.org>
6165
6166 * bison.simple: New file.
6167
6168 1993-05-19 Richard Stallman <rms@gnu.org>
6169
6170 * doc/bison.texinfo: New file.
6171
6172 1993-05-07 Noah Friedman <friedman@gnu.org>
6173
6174 * Makefile.in: *** empty log message ***
6175
6176 1993-04-28 Noah Friedman <friedman@gnu.org>
6177
6178 * src/reader.c: *** empty log message ***
6179
6180 1993-04-23 Noah Friedman <friedman@gnu.org>
6181
6182 * src/alloc.h: entered into RCS
6183
6184 1993-04-20 David J. MacKenzie <djm@gnu.org>
6185
6186 * src/version.c: *** empty log message ***
6187
6188 * src/files.c, src/allocate.c:
6189 entered into RCS
6190
6191 * src/reader.c: *** empty log message ***
6192
6193 * src/lex.c: entered into RCS
6194
6195 * src/conflicts.c: New file.
6196
6197 * src/symtab.c: entered into RCS
6198
6199 * src/alloc.h: New file.
6200
6201 * src/LR0.c: entered into RCS
6202
6203 1993-04-18 Noah Friedman <friedman@gnu.org>
6204
6205 * src/reader.c: New file.
6206
6207 * src/version.c: *** empty log message ***
6208
6209 1993-04-18 Noah Friedman <friedman@gnu.org>
6210
6211 * Makefile.in: *** empty log message ***
6212
6213 1993-04-17 Noah Friedman <friedman@gnu.org>
6214
6215 * Makefile.in: *** empty log message ***
6216
6217 1993-04-15 Richard Stallman <rms@gnu.org>
6218
6219 * src/main.c, src/files.c:
6220 New file.
6221
6222 1993-04-15 Noah Friedman <friedman@gnu.org>
6223
6224 * configure.in: entered into RCS
6225
6226 * configure.in: *** empty log message ***
6227
6228 * configure.in: New file.
6229
6230 1993-04-14 Richard Stallman <rms@gnu.org>
6231
6232 * Makefile.in: New file.
6233
6234 1993-04-13 Richard Stallman <rms@gnu.org>
6235
6236 * src/version.c: New file.
6237
6238 1993-03-25 Richard Stallman <rms@gnu.org>
6239
6240 * src/output.c: entered into RCS
6241
6242 1992-09-25 Richard Stallman <rms@gnu.org>
6243
6244 * configure.bat: entered into RCS
6245
6246 1992-06-22 Richard Stallman <rms@gnu.org>
6247
6248 * src/vmsgetargs.c: entered into RCS
6249
6250 1992-06-22 Richard Stallman <rms@gnu.org>
6251
6252 * doc/bison.rnh: entered into RCS
6253
6254 1992-04-20 David J. MacKenzie <djm@gnu.org>
6255
6256 * README: entered into RCS
6257
6258 1992-01-22 Richard Stallman <rms@gnu.org>
6259
6260 * src/machine.h: entered into RCS
6261
6262 1991-12-21 Richard Stallman <rms@gnu.org>
6263
6264 * src/lalr.c, src/closure.c:
6265 entered into RCS
6266
6267 1991-12-20 Richard Stallman <rms@gnu.org>
6268
6269 * src/state.h: entered into RCS
6270
6271 1991-12-18 Richard Stallman <rms@gnu.org>
6272
6273 * src/print.c, src/nullable.c, src/derives.c:
6274 entered into RCS
6275
6276 1991-11-03 David J. MacKenzie <djm@gnu.org>
6277
6278 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
6279 entered into RCS
6280
6281 1988-09-09 Richard Stallman <rms@gnu.org>
6282
6283 * src/bison.hairy: entered into RCS
6284
6285 1987-12-16 Richard Stallman <rms@gnu.org>
6286
6287 * REFERENCES: entered into RCS
6288 -----
6289
6290 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
6291
6292 This file is part of GNU Autoconf.
6293
6294 GNU Autoconf is free software; you can redistribute it and/or modify
6295 it under the terms of the GNU General Public License as published by
6296 the Free Software Foundation; either version 2, or (at your option)
6297 any later version.
6298
6299 GNU Autoconf is distributed in the hope that it will be useful,
6300 but WITHOUT ANY WARRANTY; without even the implied warranty of
6301 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6302 GNU General Public License for more details.
6303
6304 You should have received a copy of the GNU General Public License
6305 along with autoconf; see the file COPYING. If not, write to
6306 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
6307 Boston, MA 02111-1307, USA.