]> git.saurik.com Git - bison.git/blob - ChangeLog
* src/lalr.c (set_goto_map): Remove a wrong but benign loop
[bison.git] / ChangeLog
1 2001-12-27 Akim Demaille <akim@epita.fr>
2
3 * src/lalr.c (set_goto_map): Remove a wrong but benign loop
4 duplication.
5
6
7 2001-12-27 Akim Demaille <akim@epita.fr>
8
9 * src/reader.c (packgram): Catch nitems overflows.
10
11
12 2001-12-27 Akim Demaille <akim@epita.fr>
13
14 * src/files.c, src/files.h (guard_obstack): Remove.
15 * src/output.c (output): Adjust.
16 * src/reader.c (parse_braces): New, factoring...
17 (copy_action, copy_guard): these two which are renamed as...
18 (parse_action, parse_guard): these.
19 As a voluntary consequence, using braces around guards is now
20 mandatory.
21
22
23 2001-12-27 Akim Demaille <akim@epita.fr>
24
25 * src/gram.h (rule_t): `guard' and `guard_line' are new members.
26 * src/reader.c (symbol_list): `guard' and `guard_line' are new
27 members.
28 (symbol_list_new): Adjust.
29 (copy_action): action_line is the first line, not the last.
30 (copy_guard): Just as for actions, store the `action' only, not
31 the switch/case/break flesh.
32 Don't parse the user action that might follow the guard, let...
33 (readgram): do it, i.e., now, there can be an action after a
34 guard.
35 In other words the guard is just explicitly optional.
36 (packgram): Adjust.
37 * src/output.c (guards_output): New.
38 (output_parser): Call it when needed.
39 (output): Also free the guard and attrs obstacks.
40 * src/files.c, src/files.h (obstack_save): Remove.
41 (output_files): Remove.
42 As a result, if one needs the former `.act' file, using an
43 appropriate skeleton which requires actions and guards is now
44 required.
45 * src/main.c (main): Adjust.
46 * tests/semantic.at: New.
47 * tests/regression.at: Use `input.y' as input file name.
48 Avoid 8+3 problems by requiring input.c when the test needs the
49 parser.
50
51 2001-12-27 Akim Demaille <akim@epita.fr>
52
53 * src/reader.c (symbol_list_new): Be sure to initialize all the
54 fields.
55
56 2001-12-27 Akim Demaille <akim@epita.fr>
57
58 All the hacks using a final pseudo state are now useless.
59
60 * src/LR0.c (set_state_table): state_table holds exactly nstates.
61 * src/lalr.c (nLA): New.
62 (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it
63 instead of lookaheadsp from the pseudo state (nstate + 1).
64
65 2001-12-27 Akim Demaille <akim@epita.fr>
66
67 * src/output.c (action_row, token_actions): Use a state_t instead
68 of a integer, and nlookaheads instead of the following state's
69 lookaheadsp.
70
71
72 2001-12-27 Akim Demaille <akim@epita.fr>
73
74 * src/conflicts.c (log_resolution, flush_shift)
75 (resolve_sr_conflict, set_conflicts, solve_conflicts)
76 (count_sr_conflicts, count_rr_conflicts, conflicts_output)
77 (conflicts_print, print_reductions): Use a state_t instead of an
78 integer when referring to a state.
79 As much as possible, depend upon nlookaheads, instead of the
80 `lookaheadsp' member of the following state (since lookaheads of
81 successive states are successive, the difference between state n + 1
82 and n served as the number of lookaheads for state n).
83 * src/lalr.c (add_lookback_edge): Likewise.
84 * src/print.c (print_core, print_actions, print_state)
85 (print_results): Likewise.
86 * src/print_graph.c (print_core, print_actions, print_state)
87 (print_graph): Likewise.
88 * src/conflicts.h: Adjust.
89
90 2001-12-27 Akim Demaille <akim@epita.fr>
91
92 * src/bison.hairy: Formatting/comment changes.
93 ANSIfy.
94 Remove `register' indications.
95 Add plenty of `static'.
96
97 2001-12-27 Akim Demaille <akim@epita.fr>
98
99 * src/output.c (prepare): Drop the muscle `ntbase' which
100 duplicates ntokens.
101 * src/bison.simple: Formatting/comment changes.
102 Use YYNTOKENS only, which is documented, but not YYNTBASE, which
103 is an undocumented synonym.
104
105
106 2001-12-22 Akim Demaille <akim@epita.fr>
107
108 * src/output.c (output_table_data): Change the prototype to use
109 `int' for array ranges: some invocations do pass an int, not a
110 short.
111 Reported by Wayne Green.
112
113 2001-12-22 Akim Demaille <akim@epita.fr>
114
115 Some actions of web2c.y are improperly triggered.
116 Reported by Mike Castle.
117
118 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
119 * tests/regression.at (Web2c): Rename as...
120 (Web2c Report): this.
121 (Web2c Actions): New.
122
123 2001-12-22 Akim Demaille <akim@epita.fr>
124
125 Reductions in web2c.y are improperly reported.
126 Reported by Mike Castle.
127
128 * src/conflicts.c (print_reductions): Fix.
129 * tests/regression.at (Web2c): New.
130
131 2001-12-18 Akim Demaille <akim@epita.fr>
132
133 Some host fail on `assert (!"foo")', which expands to
134 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
135 Reported by Nelson Beebee.
136
137 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
138 `#define it_succeeded 0' and `assert (it_succeeded)'.
139
140 2001-12-17 Marc Autret <autret_m@epita.fr>
141
142 * src/bison.simple: Don't hard code the skeleton line and filename.
143 * src/output.c (output_parser): Rename 'line' as 'output_line'.
144 New line counter 'skeleton_line' (skeleton-line muscle).
145
146 2001-12-17 Paul Eggert <eggert@twinsun.com>
147
148 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that
149 YYDEBUG must be defined to a nonzero value.
150
151 * src/bison.simple (yytname): Do not assume that the user defines
152 YYDEBUG to a properly parenthesized expression.
153
154 2001-12-17 Akim Demaille <akim@epita.fr>
155
156 * src/state.h (state_t): Rename lookaheads as lookaheadsp.
157 nlookaheads is a new member.
158 Adjust all users.
159 * src/lalr.h (nlookaheads): Remove this orphan declaration.
160 * src/lalr.c (initialize_lookaheads): Set nlookaheads for each
161 state.
162
163 2001-12-17 Akim Demaille <akim@epita.fr>
164
165 * src/files.h, src/files.c (open_files, close_files): Remove.
166 * src/main.c (main): Don't open/close files, nor invoke lex_free,
167 let...
168 * src/reader.c (reader): Do it.
169
170 2001-12-17 Akim Demaille <akim@epita.fr>
171
172 * src/conflicts.c (print_reductions): Formatting changes.
173
174 2001-12-17 Akim Demaille <akim@epita.fr>
175
176 * src/conflicts.c (flush_shift): Also adjust lookaheadset.
177 (flush_reduce): New.
178 (resolve_sr_conflict): Adjust.
179
180 2001-12-17 Akim Demaille <akim@epita.fr>
181
182 * src/output.c (output_obstack): Be static and rename as...
183 (format_obstack): this, to avoid any confusion with files.c's
184 output_obstack.
185 * src/reader.h (muscle_obstack): Move to...
186 * src/output.h: here, since it's defined in output.c.
187
188 2001-12-17 Akim Demaille <akim@epita.fr>
189
190 * src/output.c (action_row, save_column, default_goto)
191 (sort_actions, matching_state, pack_vector): Better variable
192 locality.
193
194 2001-12-17 Akim Demaille <akim@epita.fr>
195
196 * src/output.c: Various formatting changes.
197
198 2001-12-17 Akim Demaille <akim@epita.fr>
199
200 * src/files.c (output_files): Free the output_obstack.
201 * src/main.c (main): Call print and print_graph conditionally.
202 * src/print.c (print): Work unconditionally.
203 * src/print_graph.c (print_graph): Work unconditionally.
204 * src/conflicts.c (log_resolution): Output only if verbose_flag.
205
206 2001-12-16 Marc Autret <autret_m@epita.fr>
207
208 * src/output.c (actions_output): Fix. When we use %no-lines,
209 there is one less line per action.
210
211 2001-12-16 Marc Autret <autret_m@epita.fr>
212
213 * src/bison.simple: Remove a useless #line directive.
214 s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'.
215 * src/output.c (get_lines_number): New.
216 (output_parser): Adjust, now takes care about the lines of a
217 output muscles.
218 Fix line numbering.
219 (actions_output): Computes the number of lines taken by actions.
220 (output_master_parser): Insert new skeleton which is the name of
221 the output parser file name.
222
223 2001-12-15 Marc Autret <autret_m@epita.fr>
224
225 * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility.
226
227 2001-12-15 Marc Autret <autret_m@epita.fr>
228
229 * src/output.c (output_gram): Keep track of the hairy one.
230
231 2001-12-15 Akim Demaille <akim@epita.fr>
232
233 Make `make distcheck' work.
234
235 * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses
236 system.h which uses libgettext.h.
237
238 2001-12-15 Akim Demaille <akim@epita.fr>
239
240 * src/nullable.c (set_nullable): Useless rules must be skipped,
241 otherwise, since we range over their symbols, we might look at a
242 nonterminal which no longer ``exists'', i.e., it is not counted in
243 `nvars', hence we overflow our arrays.
244
245 2001-12-15 Akim Demaille <akim@epita.fr>
246
247 The header can also be produced directly, without any obstack!
248 Yahoo!
249
250 * src/files.c, src/files.h (defines_obstack): Remove.
251 (compute_header_macro): Global.
252 (defines_obstack_save): Remove.
253 * src/reader.c (parse_union_decl): No longer output to
254 defines_obstack: its content can be found in the `stype' muscle
255 anyway.
256 (output_token_translations): Merge into...
257 (symbols_output): this.
258 Rename as...
259 (symbols_save): this.
260 (reader): Adjust.
261 * src/output.c (header_output): New.
262 (output): Call it.
263
264 2001-12-15 Akim Demaille <akim@epita.fr>
265
266 * src/reader.c (parse_union_decl): Instead of handling two obstack
267 simultaneously, use one to define the `stype' muscle, and use the
268 value of the latter to fill defines_obstack.
269 (copy_comment): Remove.
270 (copy_comment2): Work for a single obstack.
271 Rename as...
272 (copy_comment): this.
273
274 2001-12-15 Akim Demaille <akim@epita.fr>
275
276 * src/lex.c, src/lex.h (xgetc): No longer static.
277 * src/reader.c (parse_union_decl): Revamp.
278
279 2001-12-15 Akim Demaille <akim@epita.fr>
280
281 Still making progress in separating Bison into (i) input, (ii)
282 process, (iii) output: now we can directly output the parser file
283 without using table_obstack at all.
284
285 * src/files.c, src/files.h (table_obstack): Bye bye.
286 (parser_file_name): New.
287 * src/files.c (compute_output_file_names): Compute it.
288 * src/output.c (actions_output, output_parser)
289 (output_master_parser): To a file instead of an obstack.
290
291 2001-12-15 Akim Demaille <akim@epita.fr>
292
293 Attach actions to rules, instead of pre-outputting them to
294 actions_obstack.
295
296 * src/gram.h (rule_t): action and action_line are new members.
297 * src/reader.c (symbol_list): Likewise.
298 (copy_action): Save the actions within the rule.
299 (packgram): Save them in rule_table.
300 * src/output.c (actions_output): New.
301 (output_parser): Use it on `%%actions'.
302 (output_rule_data): Don't free rule_table.
303 (output): Do it.
304 (prepare): Don't save the `action' muscle.
305 * src/bison.simple: s/%%action/%%actions/.
306
307 2001-12-15 Akim Demaille <akim@epita.fr>
308
309 * src/reader.c (copy_action): When --yacc, don't append a `;'
310 to the user action: let it fail if lacking.
311 Suggested by Arnold Robbins and Tom Tromey.
312
313 2001-12-14 Akim Demaille <akim@epita.fr>
314
315 * src/lex.c (literalchar): Simply return the char you decoded, non
316 longer mess around with obstacks and int pointers.
317 Adjust all callers.
318
319 2001-12-14 Akim Demaille <akim@epita.fr>
320
321 * src/lex.c (literalchar): Don't escape the special characters,
322 just decode them, and keep them as char (before, eol was output as
323 the 2 char string `\n' etc.).
324 * src/output.c (output_rule_data): Use quotearg to output the
325 token strings.
326
327 2001-12-13 Paul Eggert <eggert@twinsun.com>
328
329 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
330 Do not infringe on the global user namespace when using C++.
331 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
332 All uses of `fprintf' and `stderr' changed.
333
334 * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR.
335
336 2001-12-13 Akim Demaille <akim@epita.fr>
337
338 The computation of nullable is broken: it doesn't handle empty
339 RHS's properly.
340
341 * tests/torture.at (GNU AWK Grammar): New.
342 * tests/sets.at (Nullable): New.
343 * src/nullable.c (set_nullable): Instead of blindly looping over
344 `ritems', loop over the rules, and then over their rhs's.
345
346 Work around Autotest bugs.
347
348 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
349 frame, because Autotest understand lines starting with a `+' as
350 traces from the shell. Then, they are not processed properly.
351 Admittedly an Autotest bug, but we don't have time to wait for
352 Autotest to catch up.
353 * tests/regression.at (Broken Closure): Adjust to the new table
354 frames.
355 Move to...
356 * tests/sets.at: here.
357
358 2001-12-13 Akim Demaille <akim@epita.fr>
359
360 * src/closure.c (closure): Use nrules instead of playing tricks
361 with BITS_PER_WORD.
362
363 2001-12-13 Akim Demaille <akim@epita.fr>
364
365 * src/print.c (print_actions): Output the handling of `$' as the
366 traces do: shifting the token EOF. Before EOF was treated as a
367 nonterminal.
368 * tests/regression.at: Adjust some tests.
369 * src/print_graph.c (print_core): Complete the set of items via
370 closure. The next-to-final and final states are still unsatisfying,
371 but that's to be addressed elsewhere.
372 No longer output the rule numbers, but do output the state number.
373 A single loop for the shifts + gotos is enough, but picked a
374 distinct color for each.
375 (print_graph): Initialize and finalize closure.
376
377 2001-12-13 Akim Demaille <akim@epita.fr>
378
379 * src/reader.c (readgram): Remove dead code, an strip useless
380 braces.
381 (get_type): Remove, unused.
382
383 2001-12-12 Akim Demaille <akim@epita.fr>
384
385 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
386 on that of lib/error.c.
387
388 2001-12-12 Akim Demaille <akim@epita.fr>
389
390 Some hosts don't like `/' in includes.
391
392 * src/system.h: Include libgettext.h without qualifying the path.
393 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
394 $(top_srcdir).
395
396 2001-12-11 Marc Autret <autret_m@epita.fr>
397
398 * src/output.c (output_parser): Remove useless muscle.
399
400 2001-12-11 Marc Autret <autret_m@epita.fr>
401
402 * src/bison.simple: Remove #line just before %%epilogue. It
403 is now handled in ...
404 * src/reader.c (read_additionnal_code): Add the output of a
405 #line for the epilogue.
406
407 2001-12-10 Marc Autret <autret_m@epita.fr>
408
409 * src/reader.c (copy_definition): Re-use CPP-outed code which
410 replace precedent remove.
411 * src/bison.simple: Remove #line before %%prologue because
412 %%input-line is wrong at this time.
413
414 2001-12-10 Marc Autret <autret_m@epita.fr>
415
416 * src/reader.c (symbols_output): Clean up.
417 * src/output.c (output_gram, output): Clean up.
418
419 2001-12-10 Akim Demaille <akim@epita.fr>
420
421 * src/lalr.c (initialize_lookaheads): New. Extracted from...
422 * src/LR0.c (set_state_table): here.
423 * src/lalr.c (lalr): Call it.
424
425 2001-12-10 Akim Demaille <akim@epita.fr>
426
427 * src/state.h (shifts): Remove the `number' member: shifts are
428 attached to state, hence no longer need to be labelled with a
429 state number.
430
431 2001-12-10 Akim Demaille <akim@epita.fr>
432
433 Now that states have a complete set of members, the linked list of
434 shifts is useless: just fill directly the state's shifts member.
435
436 * src/state.h (shifts): Remove the `next' member.
437 * src/LR0.c (first_state, last_state): Remove.
438 Adjust the callers.
439 (augment_automaton): Don't look for the shifts that must be added
440 a shift on EOF: it is those of the state we looked for! But now,
441 since shifts are attached, it is no longer needed to looking
442 merely by its id: its number.
443
444 2001-12-10 Akim Demaille <akim@epita.fr>
445
446 * src/LR0.c (augment_automaton): Better variable locality.
447 Remove an impossible branch: if there is a state corresponding to
448 the start symbol being shifted, then there is shift for the start
449 symbol from the initial state.
450
451 2001-12-10 Akim Demaille <akim@epita.fr>
452
453 * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state'
454 only when appropriate: when insert_start_shifting_state' is not
455 invoked.
456 * tests/regression.at (Rule Line Numbers): Adjust.
457
458 2001-12-10 Akim Demaille <akim@epita.fr>
459
460 * src/LR0.c (augment_automaton): Now that all states have shifts,
461 merge the two cases addition shifts to the initial state.
462
463 2001-12-10 Akim Demaille <akim@epita.fr>
464
465 * src/lalr.c (set_state_table): Move to...
466 * src/LR0.c: here.
467 * src/lalr.c (lalr): Don't call it...
468 * src/LR0.c (generate_states): do it.
469 * src/LR0.h (first_state): Remove, only the table is used.
470
471 2001-12-10 Akim Demaille <akim@epita.fr>
472
473 * src/LR0.h (first_shift, first_reduction): Remove.
474 * src/lalr.c: Don't use first_shift: find shifts through the
475 states.
476
477 2001-12-10 Akim Demaille <akim@epita.fr>
478
479 * src/LR0.c: Attach shifts to states as soon as they are
480 computed.
481 * src/lalr.c (set_state_table): Instead of assigning shifts to
482 state, just assert that the mapping was properly done.
483
484 2001-12-10 Akim Demaille <akim@epita.fr>
485
486 * src/LR0.c (insert_start_shift): Rename as...
487 (insert_start_shifting_state): this.
488 (insert_eof_shifting_state, insert_accepting_state): New.
489 (augment_automaton): Adjust.
490 Better locality of the variables.
491 When looking if the start_symbol is shifted from the initial
492 state, using `while (... symbol != start_symbol ...)' sounds
493 better than `while (... symbol < start_symbol ...)': If fail
494 to see how the order between symbols could be relevant!
495
496 2001-12-10 Akim Demaille <akim@epita.fr>
497
498 * src/getargs.h: Don't declare `spec_name_prefix' and
499 `spec_file_prefix', declared by src/files.h.
500 * src/files.c, src/files.h: Default for spec_name_prefix is "yy".
501 * src/muscle_tab.c (muscle_init): Default prefix to NULL.
502 * src/output.c (prepare): Adjust.
503 * src/reader.c (symbols_output): Likewise.
504 * src/vmsgetargs.c: Vaguely adjust, but who cares?
505
506 2001-12-10 Akim Demaille <akim@epita.fr>
507
508 * src/muscle_tab.c (muscle_init): NULL is a better default than
509 `"0"'.
510
511 2001-12-10 Akim Demaille <akim@epita.fr>
512
513 * src/reader.c (reader): Calling symbols_output once is enough.
514
515 2001-12-10 Akim Demaille <akim@epita.fr>
516
517 Now that states have a complete set of members, the linked list of
518 reductions is useless: just fill directly the state's reductions
519 member.
520
521 * src/state.h (struct reductions): Remove member `number' and
522 `next'.
523 * src/LR0.c (first_reduction, last_reduction): Remove.
524 (save_reductions): Don't link the new reductions, store them in
525 this_state.
526 * src/lalr.c (set_state_table): No need to attach reductions to
527 states, it's already done.
528 * src/output.c (output_actions): No longer free the shifts, then
529 the reductions, then the states: free all the states and their
530 members.
531
532 2001-12-10 Akim Demaille <akim@epita.fr>
533
534 * src/options.c (OPTN, DRTV, BOTH): New.
535 (option_table): Use them.
536
537 * src/muscle_tab.c: Don't include xalloc.h and string.h: that's
538 the job of system.h.
539 * src/options.c: Don't include stdio.h and xalloc.h for the same
540 reasons.
541
542 2001-12-10 Akim Demaille <akim@epita.fr>
543
544 * src/output.c (output, prepare): Make sure the values of the
545 muscles `action' and `prologue' are 0-terminated.
546
547 2001-12-10 Akim Demaille <akim@epita.fr>
548
549 Clean up GCC warnings.
550
551 * src/reader.c (copy_action): `buf' is not used.
552 (parse_skel_decl): Be static.
553 * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'.
554 * src/options.h (create_long_option_table): Have a real prototype.
555 * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete)
556 (hash_delete_at): Return const void *.
557 Adjust casts to preserve the const.
558
559 2001-12-10 Akim Demaille <akim@epita.fr>
560
561 * configure.in: Require 2.52g.
562 M4 is not needed, but AUTOM4TE is.
563 * m4/m4.m4: Remove.
564 * tests/Makefile.am: Adjust.
565
566 2001-12-10 Akim Demaille <akim@epita.fr>
567
568 One structure for states is enough, even though theoretically
569 there are LR(0) states and LALR(1) states.
570
571 * src/lalr.h (state_t): Remove.
572 (state_table): Be state_t **, not state_t *.
573 * src/state.h (core, CORE_ALLOC): Rename as...
574 (state_t, STATE_ALLOC): this.
575 Add the LALR(1) members: shifts, reductions, errs.
576 * src/LR0.c (state_table): Rename as...
577 (state_hash): this, to avoid name clashes with the global
578 `state_table'.
579 * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c
580 * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust.
581
582 2001-12-10 Akim Demaille <akim@epita.fr>
583
584 Bison dumps core on bash.y.
585 Reported by Pascal Bart.
586
587 * src/warshall.c (bitmatrix_print): New.
588 (TC): Use it.
589 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
590 j must be the outer loop.
591 * tests/regression.at (Broken Closure): New.
592
593 2001-12-05 Akim Demaille <akim@epita.fr>
594
595 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
596 its argument.
597 Reported by Peter Hámorský.
598
599 2001-12-05 Akim Demaille <akim@epita.fr>
600
601 * src/conflicts.c (err_table): Remove.
602 (resolve_sr_conflict): Adjust.
603 * src/lalr.h (state_t.reduction_table, state_t.shift_table):
604 Rename as...
605 (state_t.reductions, state_t.shifts): this.
606
607 2001-12-05 Akim Demaille <akim@epita.fr>
608
609 * src/reduce.c (reduce_grammar_tables): No longer disable the
610 removal of useless rules via CPP but via `if (0)', so that the
611 compiler still check the code is valid.
612 For instance, it should have noticed `rline' no longer exists: use
613 the `line' member of rule_t.
614 * src/gram.c (dummy, rline): Remove, unused.
615
616 2001-12-05 Akim Demaille <akim@epita.fr>
617
618 * src/output.c (pack_vector): Use assert, not berror.
619 * src/main.c (berror): Remove, unused.
620
621 2001-12-05 Akim Demaille <akim@epita.fr>
622
623 New experimental feature: if --verbose --trace output all the
624 items of a state, not only its kernel.
625
626 * src/print.c (print_core): If `trace_flag', then invoke closure
627 before outputting the items of the state (print_core is no longer
628 a correct name them).
629 (print_results): Invoke new_closure/free_closure if needed.
630
631 2001-12-05 Akim Demaille <akim@epita.fr>
632
633 * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount.
634 * src/closure.c, src/closure.h (itemsetsize): Rename as...
635 (nitemset): for consistency with the rest of the project.
636
637 2001-12-05 Akim Demaille <akim@epita.fr>
638
639 * src/closure.c (print_closure): Improve.
640 (closure): Use it for printing input and output.
641
642 2001-12-05 Akim Demaille <akim@epita.fr>
643
644 * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are
645 indexed by nonterminals.
646
647 2001-12-05 Akim Demaille <akim@epita.fr>
648
649 * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of
650 what it was!).
651 * src/warshall.h: Remove accidental duplication of the content.
652
653 2001-12-05 Akim Demaille <akim@epita.fr>
654
655 * src/closure.c (set_fderives): De-obfuscate.
656
657 2001-12-05 Akim Demaille <akim@epita.fr>
658
659 * src/closure.c (print_firsts, print_fderives): De-obfuscate.
660
661 2001-12-05 Akim Demaille <akim@epita.fr>
662
663 * src/closure.c (set_firsts): De-obfuscate.
664
665 2001-12-05 Akim Demaille <akim@epita.fr>
666
667 * src/output.c (action_row): De-obfuscate
668 using the good o' techniques: arrays not pointers, variable
669 locality, BITISSET, RESETBIT etc.
670
671 2001-12-05 Akim Demaille <akim@epita.fr>
672
673 Pessimize the code to simplify it: from now on, all the states
674 have a valid SHIFTS, which NSHIFTS is possibly 0.
675
676 * src/LR0.c (shifts_new): Be global and move to..
677 * src/state.c, src/state.h: here.
678 * src/conflicts, src/lalr.c, src/output.c, src/print.c,
679 * src/print_graph: Adjust.
680
681 2001-12-05 Akim Demaille <akim@epita.fr>
682
683 * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New.
684 * src/conflicts.c: Use it.
685 Restore a few missing `if (!SHIFT_IS_DISABLED)' which were
686 incorrectly ``simplified''.
687
688 2001-12-05 Akim Demaille <akim@epita.fr>
689
690 * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate
691 using the good o' techniques: arrays not pointers, variable
692 locality, BITISSET, RESETBIT etc.
693
694 2001-12-05 Akim Demaille <akim@epita.fr>
695
696 * src/state.h (SHIFT_SYMBOL): New.
697 * src/conflicts.c: Use it to deobfuscate.
698
699 2001-12-05 Akim Demaille <akim@epita.fr>
700
701 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts)
702 (print_reductions): De-obfuscate using the good o' techniques:
703 arrays not pointers, variable locality, BITISSET.
704
705 2001-12-05 Akim Demaille <akim@epita.fr>
706
707 * src/conflicts.c (print_reductions): Arrays, not pointers.
708 Use BITISSET.
709
710 2001-12-05 Akim Demaille <akim@epita.fr>
711
712 * src/conflicts.c (print_reductions): Pessimize, but clarify.
713
714 2001-12-05 Akim Demaille <akim@epita.fr>
715
716 * src/conflicts.c (print_reductions): Improve variable locality.
717
718 2001-12-05 Akim Demaille <akim@epita.fr>
719
720 * src/conflicts.c (print_reductions): Pessimize, but clarify.
721
722 2001-12-05 Akim Demaille <akim@epita.fr>
723
724 * src/conflicts.c (print_reductions): Improve variable locality.
725
726 2001-12-05 Akim Demaille <akim@epita.fr>
727
728 * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New.
729 * src/lalr.c: Use them.
730
731 2001-12-05 Akim Demaille <akim@epita.fr>
732
733 * src/LR0.c (augment_automaton): Formatting changes.
734 Better variable locality.
735
736 2001-12-05 Akim Demaille <akim@epita.fr>
737
738 * src/lalr.c (matrix_print): New.
739 (transpose): Use it.
740 Use arrays instead of pointers.
741
742 2001-12-05 Akim Demaille <akim@epita.fr>
743
744 * src/lalr.c (maxrhs): Move to...
745 * src/gram.c, src/gram.h (ritem_longest_rhs): here.
746 * src/lalr.c (build_relations): Adjust.
747
748 2001-12-05 Akim Demaille <akim@epita.fr>
749
750 * src/lalr.c (transpose): Free the memory allocated to the
751 argument, as it is replaced by the results by the unique caller.
752 (build_relations): Merely invoke transpose: it handles the memory
753 deallocation.
754 Improve variable locality.
755 Avoid variables used as mere abbreviations.
756 (compute_lookaheads): Use arrays instead of pointers.
757
758 2001-12-05 Akim Demaille <akim@epita.fr>
759
760 * src/lalr.c (initialize_F): Improve variable locality.
761 Avoid variables used as mere abbreviations.
762
763 2001-12-05 Akim Demaille <akim@epita.fr>
764
765 * src/derives.c (print_derives): Display the ruleno.
766 * src/lalr.c (initialize_F, transpose): Better variable locality
767 to improve readability.
768 Avoid variables used as mere abbreviations.
769
770 2001-12-05 Akim Demaille <akim@epita.fr>
771
772 * src/lalr.c (traverse): Use arrays instead of pointers.
773
774 2001-12-05 Akim Demaille <akim@epita.fr>
775
776 * src/nullable.c (set_nullable): Use a for loop to de-obfuscate
777 the handling of squeue.
778 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
779
780 2001-12-05 Akim Demaille <akim@epita.fr>
781
782 Because useless nonterminals are now kept alive (instead of being
783 `destroyed'), we now sometimes examine them, and store information
784 related to them. Hence we need to know their number, and adjust
785 memory allocations.
786
787 * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer
788 static.
789 * src/LR0.c (allocate_itemsets): The memory allocated to
790 `symbol_count' was used for two different purpose: once to count
791 the number of occurrences of each symbol, and later reassigned to
792 `shift_symbol', containing the symbol that can be shifted from a
793 given state.
794 Deobfuscate, i.e., allocate, use and free `symbol_count' here
795 only, and...
796 (new_itemsets): Allocate `shift_symbol' here.
797 (allocate_itemsets): symbol_count includes useless nonterminals.
798 Make room for them.
799 (free_storage): Use `free', not `XFREE', for pointers that cannot
800 be null.
801
802 2001-12-05 Akim Demaille <akim@epita.fr>
803
804 * src/nullable.c (set_nullable): Deobfuscate the handling of
805 ritem.
806 `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'.
807
808 2001-12-05 Akim Demaille <akim@epita.fr>
809
810 * src/gram.c, src/gram.h (ritem_print): New.
811 * src/gram.c (dummy): Remove, now there is actual code in gram.c.
812 (This useless function was defined only to work around VMS linkers
813 that can't handle compilation units with variables only).
814 * src/reduce.c (dump_grammar): Use it to trace the construction of
815 ritem.
816
817 2001-12-04 Paul Eggert <eggert@twinsun.com>
818
819 * src/bison.simple (union yyalloc): Change member names
820 to be the same as the stack names.
821 (yyparse): yyptr is now union yyalloc *, not char *.
822 (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning,
823 and may generate better code on some machines.
824 (yystpcpy): Use prototype if __STDC__ is defined, not just
825 if __cplusplus is defined.
826
827 2001-11-30 Akim Demaille <akim@epita.fr>
828
829 * configure.in (WARNING_CFLAGS): Add -Werror when possible.
830 (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU
831 Gettext doesn't compile cleanly, and dies with -Werror.
832 * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS):
833 Include WARNING_CFLAGS here.
834 * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared
835 before being defined.
836
837 2001-11-27 Paul Eggert <eggert@twinsun.com>
838
839 * lib/quotearg.h (quotearg_n, quotearg_n_style):
840 First arg is int, not unsigned.
841 * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
842 (SIZE_MAX, UINT_MAX): New macros.
843 (quotearg_n_options): Abort if N is negative.
844 Avoid overflow check on hosts where size_t is 64 bits and int
845 is 32 bits, as overflow is impossible there.
846 Fix off-by-one typo that caused unnecessary reallocation.
847
848 2001-11-29 Paul Eggert <eggert@twinsun.com>
849
850 Name space cleanup in generated parser.
851
852 * doc/bison.texinfo (Bison Parser): Discuss system headers
853 and their effect on the user name space.
854
855 * src/bison.simple:
856 (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
857 YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
858 i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
859
860 (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing
861 on user names when possible.
862
863 (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
864 Simplify test for whather <alloca.h> exists.
865
866 (<stdlib.h>): Include if we will use malloc, and if standard C or C++.
867
868 (<stdio.h>): Include if YYDEBUG.
869
870 (yymemcpy): Renamed from __yy_memcpy. Do not define unless
871 ! defined (yyoverflow) && ! defined (yymemcpy).
872
873 (yymemcpy, yyparse): Rename local variables as needed so that
874 they all begin with 'yy'.
875
876 (yystrlen, yystpcpy): New functions.
877
878 (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
879 All uses changed.
880
881 (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy
882 instead of relying on string.h functions. Use YYSTACK_ALLOC
883 and YYSTACK_FREE instead of malloc and free.
884
885 2001-11-30 Akim Demaille <akim@epita.fr>
886
887 * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions
888 before their first uses.
889 (YYBISON, YYPURE): Move to the top of the output.
890
891 2001-11-30 Akim Demaille <akim@epita.fr>
892
893 * tests/reduce.at (Useless Nonterminals): Fix.
894
895 2001-11-30 Akim Demaille <akim@epita.fr>
896
897 * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty
898 if body instead of `;' to pacify GCC's warnings.
899
900 2001-11-30 Akim Demaille <akim@epita.fr>
901
902 Instead of mapping the LHS of unused rules to -1, keep the LHS
903 valid, but flag the rules as invalid.
904
905 * src/gram.h (rule_t): `useful' is a new member.
906 * src/print.c (print_grammar): Adjust.
907 * src/derives.c (set_derives): Likewise.
908 * src/reader.c (packgram, reduce_output): Likewise.
909 * src/reduce.c (reduce_grammar_tables): Likewise.
910 * tests/reduce.at (Underivable Rules, Useless Rules): New.
911
912 2001-11-30 Akim Demaille <akim@epita.fr>
913
914 * src/reduce.c (reduce_output): Formatting changes.
915 * src/print.c (print_results, print_grammar): Likewise.
916 * tests/regression.at (Rule Line Numbers)
917 (Solved SR Conflicts, Unresolved SR Conflicts): Adjust.
918
919 2001-11-30 Akim Demaille <akim@epita.fr>
920
921 * src/reduce.c (nonterminals_reduce): Instead of throwing away
922 useless nonterminals, move them at the end of the symbol arrays.
923 (reduce_output): Adjust.
924 * tests/reduce.at (Useless Nonterminals): Adjust.
925
926 2001-11-30 Akim Demaille <akim@epita.fr>
927
928 * src/reduce.c: Various comment/formatting changes.
929 (nonterminals_reduce): New, extracted from...
930 (reduce_grammar_tables): here.
931 (reduce_grammar): Call nonterminals_reduce.
932
933 2001-11-29 Paul Eggert <eggert@twinsun.com>
934
935 * src/bison.simple (YYSTACK_REALLOC): Remove.
936 (YYSTACK_ALLOC): Resurrect this macro, with its old meaning.
937 (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE):
938 New macros.
939 (union yyalloc): New type.
940 (__yy_memcpy): Last arg is size_t, not unsigned int, to remove
941 an arbitrary restriction on hosts where size_t is wider than int.
942
943 (yyparse): Don't dump core if alloca or malloc fails; instead, report
944 a parser stack overflow. Allocate just one block of memory for all
945 three stacks, instead of allocating three blocks; this typically is
946 faster and reduces fragmentation.
947
948 Do not limit the number of items in the stack to a value that fits
949 in 'int', as this is an arbitrary limit on hosts with 64-bit
950 size_t and 32-bit int.
951
952 2001-11-29 Marc Autret <autret_m@epita.fr>
953
954 * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead
955 of defining YYERROR_VERBOSE.
956 [AT_DATA]: $4 is now out of C declarations in the prologue.
957
958 2001-11-28 Marc Autret <autret_m@epita.fr>
959
960 * src/reader.c (parse_dquoted_param): New.
961 (parse_skel_decl): Use it.
962 * src/lex.h: Add its prototype.
963 * src/lex.c (literalchar): Become not static.
964
965 2001-11-28 Marc Autret <autret_m@epita.fr>
966
967 * src/output.h: And put its extern declaration here.
968 * src/output.c (error_verbose): Define here.
969 (prepare): Echo name modification.
970 * src/getargs.h: Clean its extern declaration.
971 * src/getargs.c (error_verbose_flag): Remove.
972 (getargs): Remove case 'e'.
973 * src/options.c (option_table): 'error-verbose' is now seen as simple
974 percent option.
975 Include output.h.
976
977 * src/reader.c (read_declarations): Remove case tok_include.
978 (parse_include_decl): Remove.
979 * src/lex.h (token_t): Remove tok_include.
980 * src/options.c (option_table): 'include' is now a simple command line
981 option.
982
983 2001-11-28 Marc Autret <autret_m@epita.fr>
984
985 * src/bison.simple: Adjust muscle names.
986 * src/muscle_tab.c (muscle_init): Also rename the muscles.
987 * src/output.c (prepare): s/_/-/ for the muscles names.
988 (output_parser): When scanning for a muscle, allow '-' instead of '_'.
989
990 2001-11-28 Marc Autret <autret_m@epita.fr>
991
992 * src/bison.simple: Fix debug.
993 [YYERROR_VERBOSE]: Re-integrate as an internal macro.
994
995 2001-11-28 Akim Demaille <akim@epita.fr>
996
997 * src/LR0.c (shifts_new): New.
998 (save_shifts, insert_start_shift, augment_automaton): Use it.
999
1000 2001-11-28 Akim Demaille <akim@epita.fr>
1001
1002 * src/closure.c (closure): `b' and `ruleno' denote the same value:
1003 keep ruleno only.
1004
1005 2001-11-28 Akim Demaille <akim@epita.fr>
1006
1007 * src/closure.c (closure): Instead of looping over word in array
1008 then bits in words, loop over bits in array.
1009
1010 2001-11-28 Akim Demaille <akim@epita.fr>
1011
1012 * src/closure.c (closure): No longer optimize the special case
1013 where all the bits of `ruleset[r]' are set to 0, to make the code
1014 clearer.
1015
1016 2001-11-28 Akim Demaille <akim@epita.fr>
1017
1018 * src/closure.c (closure): `r' and `c' are new variables, used to
1019 de-obfuscate accesses to RULESET and CORE.
1020
1021 2001-11-28 Akim Demaille <akim@epita.fr>
1022
1023 * src/reduce.c (reduce_print): Use ngettext.
1024 (dump_grammar): Improve the trace accuracy.
1025
1026 2001-11-28 Akim Demaille <akim@epita.fr>
1027
1028 * src/reduce.c (dump_grammar): Don't translate trace messages.
1029
1030 2001-11-28 Akim Demaille <akim@epita.fr>
1031
1032 * tests/reduce.at (Useless Terminals, Useless Nonterminals): New.
1033 * src/reduce.c (reduce_grammar_tables): Do not free useless tags,
1034 as all tags are free'ed afterwards.
1035 From Enrico Scholz.
1036
1037 2001-11-27 Paul Eggert <eggert@twinsun.com>
1038
1039 * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to
1040 use alloca when we didn't want to, and vice versa.
1041
1042 2001-11-27 Marc Autret <autret_m@epita.fr>
1043
1044 * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle
1045 initialization.
1046 * src/output.c (prepare): Remove its update.
1047
1048 2001-11-27 Marc Autret <autret_m@epita.fr>
1049
1050 * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition.
1051 Use %error-verbose.
1052
1053 2001-11-27 Marc Autret <autret_m@epita.fr>
1054
1055 * src/bison.simple: Remove YYERROR_VERBOSE using.
1056 Use %%error_verbose.
1057 (yyparse): Likewise.
1058 * src/output.c (prepare): Give its final value.
1059 * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'.
1060 * src/getargs.h: Add its extern declaration.
1061 * src/getargs.c (error_verbose_flag): New int.
1062 (getargs): Update to catch new case.
1063 * src/options.c (option_table): 'error-verbose' is a new option.
1064 (shortopts): Update.
1065
1066 2001-11-27 Akim Demaille <akim@epita.fr>
1067
1068 * src/system.h: Use intl/libgettext.h.
1069 * src/Makefile.am (INCLUDES): Add -I $(top_srcdir).
1070
1071 2001-11-27 Akim Demaille <akim@epita.fr>
1072
1073 * tests/torture.at (Exploding the Stack Size with Malloc):
1074 s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/.
1075
1076 2001-11-27 Akim Demaille <akim@epita.fr>
1077
1078 * src/files.c: Include error.h.
1079 Reported by Hans Aberg.
1080
1081 2001-11-26 Marc Autret <autret_m@epita.fr>
1082
1083 * src/reader.c (parse_include_decl): New, not yet implemented.
1084 (read_declarations): Add case tok_include.
1085 * src/getargs.h (include): Add its extern definition.
1086 * src/getargs.c (include): New const char *.
1087 (getargs): Add case '-I'.
1088 * src/options.c (option_table): Add include as command line and
1089 percent option.
1090 * src/lex.h (token_t): Add tok_include.
1091
1092 2001-11-26 Akim Demaille <akim@epita.fr>
1093
1094 * src/reader.c (readgram): Make sure rules for mid-rule actions
1095 have a lineno equal to that of their host rule.
1096 Reported by Hans Aberg.
1097 * tests/regression.at (Rule Line Numbers): New.
1098
1099 2001-11-26 Akim Demaille <akim@epita.fr>
1100
1101 * src/LR0.c (allocate_itemsets): kernel_size contains ints, not
1102 size_ts.
1103
1104 2001-11-26 Akim Demaille <akim@epita.fr>
1105
1106 * src/complain.c, src/complain.h (error): Remove, provided by
1107 lib/error.[ch].
1108
1109 2001-11-26 Akim Demaille <akim@epita.fr>
1110
1111 * src/reader.c (read_declarations): Don't abort on tok_illegal,
1112 issue an error message.
1113 * tests/regression.at (Invalid %directive): New.
1114 Reported by Hans Aberg.
1115
1116 2001-11-26 Akim Demaille <akim@epita.fr>
1117
1118 * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE.
1119 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
1120
1121 2001-11-26 Akim Demaille <akim@epita.fr>
1122
1123 * src/conflicts.c (conflicts_print): Don't complain at all when
1124 there are no reduce/reduce conflicts, and as many shift/reduce
1125 conflicts as expected.
1126 * tests/regression.at (%expect right): Adjust.
1127
1128 2001-11-23 Akim Demaille <akim@epita.fr>
1129
1130 * lib/alloca.c: Update, from fileutils.
1131
1132 2001-11-23 Akim Demaille <akim@epita.fr>
1133
1134 * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@.
1135
1136 2001-11-23 Akim Demaille <akim@epita.fr>
1137
1138 * src/system.h: Include alloca.h.
1139 * src/main.c (main) [C_ALLOCA]: Call alloca (0).
1140
1141 2001-11-23 Akim Demaille <akim@epita.fr>
1142
1143 * src/print_graph.c (print_actions): Remove `rule', unused.
1144 * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to
1145 pacify GCC's signed < unsigned warnings.
1146 * src/closure.c (itemsetsize): Likewise.
1147 * src/reader.c (symbol_list_new): Static.
1148
1149 2001-11-23 Akim Demaille <akim@epita.fr>
1150
1151 Attaching lineno to buckets is stupid, since only one copy of each
1152 symbol is kept, only the line of the first occurrence is kept too.
1153
1154 * src/symtab.h, src/symtab.c (bucket): Remove the line member.
1155 * src/reader.c (rline_allocated): Remove, unused.
1156 (symbol_list): Have a `line' member.
1157 (symbol_list_new): New.
1158 (readgram): Use it.
1159 * src/print.c (print_grammar): Output the rule line numbers.
1160 * tests/regression.at (Solved SR Conflicts)
1161 (Unresolved SR Conflicts): Adjust.
1162 Reported by Hans Aberg.
1163
1164 2001-11-22 Marc Autret <autret_m@epita.fr>
1165
1166 * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0.
1167
1168 2001-11-22 Marc Autret <autret_m@epita.fr>
1169
1170 * src/muscle_tab.c (muscle_init): Remove initialization of
1171 skeleton muscle.
1172 * src/output.c (output_master_parser): Do it here.
1173
1174 2001-11-20 Akim Demaille <akim@epita.fr>
1175
1176 * po/sv.po: New.
1177 * configure.in (ALL_LINGUAS): Adjust.
1178 * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no
1179 longer contains strings to translate.
1180
1181 2001-11-19 Akim Demaille <akim@epita.fr>
1182
1183 * src/conflicts.c (conflicts_print): Add a missing \n.
1184
1185 2001-11-19 Akim Demaille <akim@epita.fr>
1186
1187 * src/nullable.c (nullable_print): New.
1188 (set_nullable): Call it when tracing.
1189 Better locality of variables.
1190
1191 2001-11-19 Akim Demaille <akim@epita.fr>
1192
1193 * src/print.c (print_actions): Better locality of variables.
1194
1195 2001-11-19 Akim Demaille <akim@epita.fr>
1196
1197 * src/derives.c (print_derives): Fix and enrich.
1198 * src/closure.c (print_fderives): Likewise.
1199
1200 2001-11-19 Akim Demaille <akim@epita.fr>
1201
1202 * src/closure.c (itemsetend): Remove, replaced with...
1203 (itemsetsize): new.
1204
1205 2001-11-19 Akim Demaille <akim@epita.fr>
1206
1207 * src/LR0.c (kernel_end): Remove, replaced with...
1208 (kernel_size): new.
1209
1210 2001-11-19 Akim Demaille <akim@epita.fr>
1211
1212 * src/conflicts.c (set_conflicts): Use arrays instead of pointers
1213 to clarify.
1214
1215 2001-11-19 Akim Demaille <akim@epita.fr>
1216
1217 * src/closure.c (closure): Use arrays instead of pointers to clarify.
1218
1219 2001-11-19 Akim Demaille <akim@epita.fr>
1220
1221 * src/closure.c, src/derives.c, src/nullable.c: Adjust various
1222 trace messages.
1223 * src/LR0.c: Likewise.
1224 (allocate_itemsets): Use arrays instead of pointers to clarify.
1225
1226 2001-11-19 Akim Demaille <akim@epita.fr>
1227
1228 * src/getargs.c (statistics_flag): Replace with...
1229 (trace_flag): New.
1230 (longopts): Accept --trace instead of --statistics.
1231 * src/getargs.h, src/options.c: Adjust.
1232 * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c,
1233 * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE.
1234
1235 2001-11-19 Akim Demaille <akim@epita.fr>
1236
1237 * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer
1238 pointers to clarify the code.
1239 (save_reductions, save_shifts): Factor common parts of alternatives.
1240
1241 2001-11-19 Akim Demaille <akim@epita.fr>
1242
1243 * src/LR0.c (new_state, get_state): Complete TRACE code.
1244 * src/closure.c: Include `reader.h' to get `tags', needed by the
1245 trace code.
1246 Rename the conditional DEBUG as TRACE.
1247 Output consistently TRACEs to stderr, not stdout.
1248 * src/derives.c: Likewise.
1249 * src/reduce.c: (inaccessable_symbols): Using if is better style
1250 than goto.
1251 Use `#if TRACE' instead of `#if 0' for tracing code.
1252
1253 2001-11-19 Akim Demaille <akim@epita.fr>
1254
1255 * src/system.h (LIST_FREE, shortcpy): New.
1256 * src/LR0.c: Use them.
1257 * src/output.c (free_itemsets, free_reductions, free_shifts):
1258 Remove, replaced by LIST_FREE.
1259
1260 2001-11-19 Akim Demaille <akim@epita.fr>
1261
1262 * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC)
1263 (REDUCTIONS_ALLOC): New.
1264 * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory
1265 allocation.
1266
1267 2001-11-19 Akim Demaille <akim@epita.fr>
1268
1269 * src/LR0.c (new_state): Complete trace code.
1270 * src/nullable.c (set_nullable): Don't translate traces.
1271
1272 2001-11-19 Akim Demaille <akim@epita.fr>
1273
1274 * src/print_graph.c (print_core): Better locality of variables.
1275 * src/print.c (print_core): Likewise.
1276
1277 2001-11-19 Akim Demaille <akim@epita.fr>
1278
1279 * src/vcg.c: You do the output, so you are responsible of the
1280 handling of VCG syntax, in particular: use quotearg.
1281 * src/print_graph.c: Don't.
1282 (print_actions): Don't output the actions as part of the nodes,
1283 since that's the job of the edges.
1284 (print_state): Don't output by hand: fill the node description,
1285 and ask for its output.
1286
1287 2001-11-19 Akim Demaille <akim@epita.fr>
1288
1289 * src/bison.simple (yyparse): When verbosely reporting an error,
1290 no longer put additional quotes around token names.
1291 * tests/calc.at: Adjust.
1292
1293 2001-11-19 Akim Demaille <akim@epita.fr>
1294
1295 * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'.
1296 * src/reader.c (record_rule_lines, rline, rline_allocated): Remove.
1297 * src/output.c: Adjust.
1298
1299 2001-11-19 Akim Demaille <akim@epita.fr>
1300
1301 * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of...
1302 (rule_t): this.
1303 * src/conflicts.c, src/reader.c, src/reduce.c: Adjust.
1304
1305 2001-11-19 Akim Demaille <akim@epita.fr>
1306
1307 * src/gram.h (rule_t): New.
1308 (rule_table): New.
1309 (rrhs, rlhs): Remove, part of state_t.
1310 * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c,
1311 * src/lalr.c, src/nullable.c, src/output.c, src/print.c,
1312 * src/reader.c, src/reduce.c: Adjust.
1313
1314 2001-11-19 Akim Demaille <akim@epita.fr>
1315
1316 * src/reader.c (symbols_output): New, extracted from...
1317 (packsymbols): Here.
1318 (reader): Call it.
1319
1320 2001-11-19 Akim Demaille <akim@epita.fr>
1321
1322 * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with...
1323 (maxrhs): this new function.
1324
1325 2001-11-19 Akim Demaille <akim@epita.fr>
1326
1327 * src/lalr.c (F): New macro to access the variable F.
1328 Adjust.
1329
1330 2001-11-19 Akim Demaille <akim@epita.fr>
1331
1332 * src/lalr.h (LA): New macro to access the variable LA.
1333 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1334 * src/lalr.c: Adjust.
1335
1336 2001-11-19 Akim Demaille <akim@epita.fr>
1337
1338 * src/lalr.c (initialize_LA): Only initialize LA. Let...
1339 (set_state_table): handle the `lookaheads' members.
1340
1341 2001-11-19 Akim Demaille <akim@epita.fr>
1342
1343 * src/lalr.h (lookaheads): Removed array, whose contents is now
1344 a member of...
1345 (state_t): this structure.
1346 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1347 Adjust.
1348
1349 2001-11-19 Akim Demaille <akim@epita.fr>
1350
1351 * src/lalr.h (consistent): Removed array, whose contents is now
1352 a member of...
1353 (state_t): this structure.
1354 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1355 Adjust.
1356
1357 2001-11-19 Akim Demaille <akim@epita.fr>
1358
1359 * src/lalr.h (reduction_table, shift_table): Removed arrays, whose
1360 contents are now members of...
1361 (state_t): this structure.
1362 * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c:
1363 Adjust.
1364
1365 2001-11-19 Akim Demaille <akim@epita.fr>
1366
1367 * src/lalr.h (state_t): New.
1368 (state_table): Be a state_t * instead of a core **.
1369 (accessing_symbol): Remove, part of state_t.
1370 * src/lalr.c: Adjust.
1371 (set_accessing_symbol): Merge into...
1372 (set_state_table): this.
1373 * src/print_graph.c, src/conflicts.c: Adjust.
1374
1375 2001-11-14 Akim Demaille <akim@epita.fr>
1376
1377 * tests/calc.at, tests/output.at, tests/regression.at,
1378 * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g:
1379 now the tests are run in private dirs, therefore AC_CLEANUP and
1380 family can be simplified to 0-ary.
1381 * tests/atlocal.in: Now that we run `elsewhere' than in tests/,
1382 use abs. path to find config.h.
1383 * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's
1384 stderr, there can be way too much random noise.
1385 Instead pass -Werror to GCC and rely on the exit status.
1386 Reported by Wolfram Wagner.
1387
1388 2001-11-14 Akim Demaille <akim@epita.fr>
1389
1390 * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be
1391 defined only if yyoverflow is defined, to avoid `warning: unused
1392 variable `yyvs1''.
1393 Reported by The Test Suite.
1394
1395 2001-11-14 Akim Demaille <akim@epita.fr>
1396
1397 * src/print.c: Include reduce.h.
1398 Reported by Hans Aberg.
1399
1400 2001-11-14 Akim Demaille <akim@epita.fr>
1401
1402 * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer):
1403 Revert a previous patch: these are really const.
1404 * src/conflicts.c (conflict_report): Additional useless pair of
1405 braces to pacify GCC's warnings for `if () if () {} else {}'.
1406 * src/lex.c (parse_percent_token): Replace equal_offset with
1407 arg_offset.
1408 arg is const.
1409 Be sure to strdup `arg' when used, since there is no reason for
1410 token_buffer not to change.
1411
1412 2001-11-14 Akim Demaille <akim@epita.fr>
1413
1414 * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper
1415 definition.
1416 * src/main.c (main): Use them.
1417 Suggested by Hans Aberg.
1418
1419 2001-11-12 Akim Demaille <akim@epita.fr>
1420
1421 * src/system.h (ngettext): Now that we use ngettext, be sure to
1422 provide a default definition when NLS are not used.
1423
1424 2001-11-12 Akim Demaille <akim@epita.fr>
1425
1426 * doc/bison.texinfo: Use `$' as shell prompt, not `%'.
1427 Use @kbd to denote user input.
1428 (Language and Grammar): ANSIfy the example.
1429 Adjust its layout for info/notinfo.
1430 (Location Tracking Calc): Output error messages to stderr.
1431 Output locations in a more GNUtically correct way.
1432 Fix a couple of Englishos.
1433 Adjust @group/@end group pairs.
1434
1435 2001-11-12 Akim Demaille <akim@epita.fr>
1436
1437 %expext was not functioning at all.
1438
1439 * src/conflicts.c (expected_conflicts): Set to -1.
1440 (conflict_report): Use ngettext.
1441 (conflicts_print): Check %expect and make its violation an error.
1442 * doc/bison.texinfo (Expect Decl): Adjust.
1443 * configure.in (AM_GNU_GETTEXT): Ask for ngettext.
1444 * tests/regression.at (%expect not enough, %expect right)
1445 (%expect too much): New.
1446
1447 2001-11-12 Akim Demaille <akim@epita.fr>
1448
1449 * tests/regression.at (Conflicts): Rename as...
1450 (Unresolved SR Conflicts): this.
1451 (Solved SR Conflicts): New.
1452
1453 2001-11-12 Akim Demaille <akim@epita.fr>
1454
1455 * src/reduce.c (print_results): Rename as...
1456 (reduce_output): This.
1457 Output to OUT, passed as argument, instead of output_obstack.
1458 (dump_grammar): Likewise.
1459 (reduce_free): New.
1460 Also free V1.
1461 (reduce_grammar): No longer call reduce_output, since...
1462 * src/print.c (print_results): do it.
1463 * src/main.c (main): Call reduce_free;
1464
1465 2001-11-12 Akim Demaille <akim@epita.fr>
1466
1467 * src/conflicts.c (print_reductions): Accept OUT as argument.
1468 Output to it, not to output_obstack.
1469 * src/print.c (print_actions): Adjust.
1470
1471 2001-11-12 Akim Demaille <akim@epita.fr>
1472
1473 * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return
1474 the result instead of using...
1475 (src_total, rrc_total, src_count, rrc_count): Remove.
1476 (any_conflicts): Remove.
1477 (print_conflicts): Split into...
1478 (conflicts_print, conflicts_output): New.
1479 * src/conflicts.h: Adjust.
1480 * src/main.c (main): Invoke both conflicts_output and conflicts_print.
1481 * src/print.c (print_grammar): Issue `\n' between two rules.
1482 * tests/regression.at (Conflicts): New.
1483 Reported by Tom Lane.
1484
1485 2001-11-12 Akim Demaille <akim@epita.fr>
1486
1487 * tests/regression.at (Invalid input): Remove, duplicate with
1488 ``Invalid input: 1''.
1489
1490 2001-11-12 Akim Demaille <akim@epita.fr>
1491
1492 * tests/torture.at (AT_DATA_STACK_TORTURE)
1493 (Exploding the Stack Size with Alloca)
1494 (Exploding the Stack Size with Malloc): New.
1495
1496 2001-11-12 Akim Demaille <akim@epita.fr>
1497
1498 * src/bison.simple (YYSTACK_REALLOC): New.
1499 (yyparse) [!yyoverflow]: Use it and free the old stack.
1500 Reported by Per Allansson.
1501
1502 2001-11-12 Pascal Bart <pascal.bart@epita.fr>
1503
1504 * src/bison.simple: Define type yystype instead of YYSTYPE, and
1505 define CPP macro, which substitute YYSTYPE by yystype.
1506 * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do
1507 with yyltype/YYLTYPE. This allows inclusion of the generated
1508 header within the parser if the compiler, such as GGC, accepts
1509 multiple equivalent #defines.
1510 From Akim.
1511
1512 2001-11-05 Akim Demaille <akim@epita.fr>
1513
1514 * src/reader.c (symbols_output): New, extracted from...
1515 (packsymbols): here.
1516 (reader): Adjust.
1517
1518 2001-11-05 Akim Demaille <akim@epita.fr>
1519
1520 * src/lex.c (parse_percent_token): s/quotearg/quote/.
1521
1522 2001-11-05 Akim Demaille <akim@epita.fr>
1523
1524 * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up
1525 pattern.
1526
1527 2001-11-05 Akim Demaille <akim@epita.fr>
1528
1529 * src/options.h (struct option_table_struct): set_flags is void*.
1530 * src/options.c (longopts): Support `--output' and `%output'.
1531 (usage): Adjust.
1532 * src/lex.h (tok_setopt): Remove, replaced with...
1533 (tok_intopt, tok_stropt): these new guys.
1534 * src/lex.c (getopt.h): Not needed.
1535 (token_buffer, unlexed_token_buffer): Not const.
1536 (percent_table): Promote `-' over `_' in directive names.
1537 Active `%name-prefix', `file-prefix', and `output'.
1538 (parse_percent_token): Accept possible arguments to directives.
1539 Promote `-' over `_' in directive names.
1540
1541 2001-11-04 Akim Demaille <akim@epita.fr>
1542
1543 * doc/bison.texinfo (Decl Summary): Split the list into
1544 `directives for grammars' and `directives for bison'.
1545 Sort'em.
1546 Add description of `%name-prefix', `file-prefix', and `output'.
1547 Promote `-' over `_' in directive names.
1548 (Bison Options): s/%locactions/%locations/. Nice Freudian slip.
1549 Simplify the description of `--name-prefix'.
1550 Promote `-' over `_' in directive names.
1551 Promote `--output' over `--output-file'.
1552 Fix the description of `--defines'.
1553 * tests/output.at: Exercise %file-prefix and %output.
1554
1555 2001-11-02 Akim Demaille <akim@epita.fr>
1556
1557 * doc/refcard.tex: Update.
1558
1559 2001-11-02 Akim Demaille <akim@epita.fr>
1560
1561 * src/symtab.h (SUNDEF): New.
1562 * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to
1563 stand for `uninitialized', instead of 0.
1564 * src/reader.c (packsymbols, parse_thong_decl): Adjust.
1565 * src/lex.c (lex): Adjust.
1566
1567 * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF.
1568 Number it 0.
1569 Let yylex return it instead of a plain 0.
1570 Reported by Dick Streefland.
1571
1572 2001-11-02 Akim Demaille <akim@epita.fr>
1573
1574 * tests/regression.at (Mixing %token styles): New test.
1575
1576 2001-11-02 Akim Demaille <akim@epita.fr>
1577
1578 * src/reader.c (parse_thong_decl): Formatting changes.
1579 (token_translations_init): New, extracted from...
1580 (packsymbols): Here.
1581 Adjust.
1582
1583 2001-11-01 Akim Demaille <akim@epita.fr>
1584
1585 * tests/regression.at (AT_TEST_CPP_GUARD_H): New.
1586 Check that `9foo.y' produces correct cpp guards.
1587 * src/files.c (compute_header_macro): Prepend `BISON_' to CPP
1588 guards.
1589 Reported by Wwp.
1590
1591 2001-11-01 Akim Demaille <akim@epita.fr>
1592
1593 * tests/regression.at (Invalid input: 2): New.
1594 * src/lex.c (unlexed_token_buffer): New.
1595 (lex, unlex): Adjust: when unlexing, be sure to save token_buffer
1596 too.
1597 Reported by Wwp.
1598
1599 2001-11-01 Akim Demaille <akim@epita.fr>
1600
1601 * tests/calc.at: Catch up with 1.30.
1602 * configure.in: Bump to 1.49a.
1603 Adjust to newer Autotest.
1604
1605 2001-10-19 Pascal Bart <pascal.bart@epita.fr>
1606
1607 * src/conflicts.c: Move global variables rrc_total and src_total ...
1608 (print_conflicts): here.
1609 * src/output.c (output): Free global variable user_toknums.
1610 * src/lex.c (token_obstack): Become static.
1611
1612 2001-10-18 Akim Demaille <akim@epita.fr>
1613
1614 * tests/atlocal.in (GCC): Add.
1615 * tests/calc.at: s/m4_match/m4_bmatch/.
1616 s/m4_patsubst/m4_bpatsubst/.
1617 (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC.
1618 * configure.in: AC_SUBST(GCC).
1619
1620 2001-10-14 Marc Autret <autret_m@epita.fr>
1621
1622 * src/options.c (create_long_option_table): Fix.
1623
1624 2001-10-10 Akim Demaille <akim@epita.fr>
1625
1626 * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA.
1627
1628 2001-10-04 Akim Demaille <akim@epita.fr>
1629
1630 * src/reader.c (parse_union_decl): Push the caracters in
1631 union_obstack, not attrs_obstack.
1632
1633 2001-10-04 Akim Demaille <akim@epita.fr>
1634
1635 Merge in the branch 1.29.
1636
1637 * src/reader.c (packsymbols): Use a temporary obstack for
1638 `%%tokendef', since output_stack is already used elsewhere.
1639
1640 2001-10-02 Akim Demaille <akim@epita.fr>
1641
1642 Bump 1.29d.
1643
1644 2001-10-02 Akim Demaille <akim@epita.fr>
1645
1646 Version 1.29c.
1647
1648 2001-10-02 Akim Demaille <akim@epita.fr>
1649
1650 * tests/regression.at (Invalid CPP headers): New.
1651 From Alexander Belopolsky.
1652 * src/files.c (compute_header_macro): Map non alnum chars to `_'.
1653
1654 2001-10-02 Akim Demaille <akim@epita.fr>
1655
1656 * tests/regression.at (Invalid input): New.
1657 * src/lex.c (lex): Be sure to set `token_buffer' in any case.
1658 Reported by Shura.
1659
1660 2001-10-02 Akim Demaille <akim@epita.fr>
1661
1662 * tests/calc.at: Now that --debug works, the tests must be adjusted.
1663
1664 2001-10-02 Akim Demaille <akim@epita.fr>
1665
1666 * src/output.c (output_parser): Assert `skeleton'.
1667 * src/files.c (skeleton_find): Look harder for skeletons on DOSish
1668 systems.
1669 From Shura.
1670
1671 2001-10-01 Marc Autret <autret_m@epita.fr>
1672
1673 * src/lex.h: Echo modifications.
1674 * src/lex.c (unlex): Parameter is now token_t.
1675 From Hans Aberg.
1676
1677 2001-10-01 Marc Autret <autret_m@epita.fr>
1678
1679 * src/main.c: Include lex.h.
1680 From Hans Aberg.
1681
1682 2001-09-29 Akim Demaille <akim@epita.fr>
1683
1684 * src/getargs.c (longopts): `--debug' is `-t', not `-d'.
1685
1686 2001-09-28 Akim Demaille <akim@epita.fr>
1687
1688 * tests/testsuite.at: Update to newer Autotest.
1689 * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped.
1690
1691 2001-09-27 Akim Demaille <akim@epita.fr>
1692
1693 Position independent wrapper.
1694
1695 * tests/bison: Remove.
1696 * tests/bison.in: New.
1697 * configure.in: Adjust.
1698
1699 2001-09-27 Paul Eggert <eggert@twinsun.com>
1700
1701 Port quotearg fixes from tar 1.13.24.
1702
1703 * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
1704 tm to be declared.
1705 (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
1706 (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
1707
1708 * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4.
1709 * m4/mbrtowc.m4: New file.
1710 * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h.
1711 Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc).
1712
1713 2001-09-27 Akim Demaille <akim@epita.fr>
1714
1715 Bump to 1.29c.
1716
1717 2001-09-27 Akim Demaille <akim@epita.fr>
1718
1719 Version 1.29b.
1720
1721 2001-09-25 Akim Demaille <akim@epita.fr>
1722
1723 * src/system.h: Include `xalloc.h'.
1724 Remove it from the C files.
1725 * src/files.c (output_files): Free the obstacks.
1726 * src/lex.c (init_lex): Rename as...
1727 (lex_init): this.
1728 (lex_free): New.
1729 * src/main.c (main): Use it.
1730
1731 2001-09-24 Marc Autret <autret_m@epita.fr>
1732
1733 * src/vcg.c (open_edge, close_edge, open_node, close_node): Change
1734 to output informations in fout (FILE*).
1735 (open_graph, close_graph): Likewise.
1736 (output_graph, output_edge, output_node): Likewise.
1737 * src/vcg.h: Update function prototypes.
1738 * src/print_graph.c (print_graph): Open output graph file.
1739 (print_actions): Adjust.
1740 * src/files.h: Remove extern declaration.
1741 * src/files.c: Remove graph_obstack declaration.
1742 (open_files): Remove graph_obstack initialization.
1743 (output_files): Remove graph_obstack saving.
1744
1745 2001-09-24 Marc Autret <autret_m@epita.fr>
1746
1747 * src/files.c (compute_output_file_names): Fix.
1748
1749 2001-09-24 Marc Autret <autret_m@epita.fr>,
1750 Akim Demaille <akim@epita.fr>
1751
1752 * src/reader.c (reader): Remove call to free_symtab ().
1753 * src/main.c (main): Call it here.
1754 Include symtab.h.
1755 * src/conflicts.c (initialize_conflicts): Rename as...
1756 (solve_conflicts): this.
1757 * src/print.c (print_core, print_actions, print_state)
1758 (print_grammar): Dump to a file instead a `output_obstack'.
1759 (print_results): Dump `output_obstack', and then proceed with the
1760 FILE *.
1761 * src/files.c (compute_output_file_names, close_files): New.
1762 (output_files): Adjust.
1763 * src/main.c (main): Adjust.
1764
1765 2001-09-23 Marc Autret <autret_m@epita.fr>
1766
1767 * src/files.c (compute_header_macro): Computes header macro name
1768 from spec_defines_file when given.
1769
1770 2001-09-23 Marc Autret <autret_m@epita.fr>
1771
1772 * src/files.c (output_files): Add default extensions.
1773
1774 2001-09-22 Akim Demaille <akim@epita.fr>
1775
1776 * src/conflicts.c (finalize_conflicts): Rename as...
1777 (free_conflicts): this.
1778
1779 2001-09-22 Akim Demaille <akim@epita.fr>
1780
1781 * src/gram.c (gram_free): Rename back as...
1782 (dummy): this.
1783 (output_token_translations): Free `token_translations'.
1784 * src/symtab.c (free_symtab): Free the tag field.
1785
1786 2001-09-22 Akim Demaille <akim@epita.fr>
1787
1788 Remove `translations' as it is always set to true.
1789
1790 * src/gram.h: Adjust.
1791 * src/reader.c (packsymbols, parse_token_decl): Adjust
1792 * src/print.c (print_grammar): Adjust.
1793 * src/output.c (output_token_translations): Adjust.
1794 * src/lex.c (lex): Adjust.
1795 * src/gram.c: Be sure the set pointers to NULL.
1796 (dummy): Rename as...
1797 (gram_free): this.
1798
1799 2001-09-22 Akim Demaille <akim@epita.fr>
1800
1801 * configure.in: Invoke AM_LIB_DMALLOC.
1802 * src/system.h: Use dmalloc.
1803 * src/LR0.c: Be sure to have pointers initialized to NULL.
1804 (allocate_itemsets): Allocate kernel_items only if needed.
1805
1806 2001-09-22 Akim Demaille <akim@epita.fr>
1807
1808 * configure.in: Bump to 1.29b.
1809 * tests/Makefile.am (DISTCLEANFILES): Add package.m4.
1810 * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't
1811 need xmalloc.c in calc.y.
1812 From Pascal Bart.
1813
1814 2001-09-21 Akim Demaille <akim@epita.fr>
1815
1816 Version 1.29a.
1817 * Makefile.maint, config/config.guess, config/config.sub,
1818 * config/missing: Update from masters.
1819 * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend
1820 upon package.m4.
1821 * configure.in (ALL_LINGUAS): Add `tr'.
1822
1823 2001-09-21 Akim Demaille <akim@epita.fr>
1824
1825 * tests/Makefile.am (package.m4): Move to...
1826 ($(srcdir)/$(TESTSUITE)): here.
1827
1828 2001-09-20 Akim Demaille <akim@epita.fr>
1829
1830 * src/complain.c: No longer try to be standalone: use system.h.
1831 Don't assume __STDC__ is defined to 1. Just test if it is defined.
1832 * src/complain.h: Likewise.
1833 * src/reduce.c (useless_nonterminals, inaccessable_symbols):
1834 Remove the unused variable `n'.
1835 From Albert Chin-A-Young.
1836
1837 2001-09-18 Marc Autret <autret_m@epita.fr>
1838
1839 * doc/bison.1: Update.
1840 * doc/bison.texinfo (Bison Options): Update --defines and --graph
1841 descriptions.
1842 (Option Cross Key): Update.
1843 Add --graph.
1844
1845 2001-09-18 Marc Autret <autret_m@epita.fr>
1846
1847 * tests/regression.at: New test (comment in %union).
1848
1849 2001-09-18 Marc Autret <autret_m@epita.fr>
1850
1851 * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment
1852 do that.
1853 Reported by Keith Browne.
1854
1855 2001-09-18 Marc Autret <autret_m@epita.fr>
1856
1857 * tests/output.at: Add tests for --defines and --graph.
1858
1859 2001-09-18 Marc Autret <autret_m@epita.fr>
1860
1861 * tests/output.at: Removes tests of %{header,src}_extension features.
1862
1863 2001-09-18 Akim Demaille <akim@epita.fr>
1864
1865 * tests/Makefile.am (package.m4): New.
1866 * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'.
1867 (_AT_CHECK_CALC_ERROR): Likewise.
1868 Factor the `, ' part of verbose error messages.
1869
1870 2001-09-18 Marc Autret <autret_m@epita.fr>
1871
1872 * src/getargs.c (longopts): Declare --defines and --graph as options
1873 with optional arguments.
1874 * src/files.h: Add extern declarations.
1875 * src/files.c (spec_graph_file, spec_defines_file): New.
1876 (output_files): Update.
1877 Remove CPP-outed code.
1878
1879 2001-09-18 Marc Autret <autret_m@epita.fr>
1880
1881 Turn off %{source,header}_extension feature.
1882
1883 * src/files.c (compute_exts_from_gf): Update.
1884 (compute_exts_from_src): Update.
1885 (output_files): CPP-out useless code.
1886 * src/files.h: Remove {header,source}_extension extern declarations.
1887 * src/reader.c (parse_dquoted_param): CPP-out.
1888 (parse_header_extension_decl): Remove.
1889 (parse_source_extension_decl): Remove.
1890 (read_declarations): Remove cases tok_{hdrext,srcext}.
1891 * src/lex.c (percent_table): Remove {header,source}_extension entries.
1892 * src/lex.h (token_t): Remove tok_hdrext and tok_srcext.
1893
1894 2001-09-10 Akim Demaille <akim@epita.fr>
1895
1896 * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT):
1897 (AT_CHECK_BISON_PERCENT_FLAGS): Merge into...
1898 (AT_CHECK_OUTPUT): this.
1899 Merely check ls' exit status, its output is useless.
1900
1901 2001-09-10 Akim Demaille <akim@epita.fr>
1902
1903 * tests/calc.at: Use m4_match.
1904 (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'.
1905
1906 2001-09-10 Marc Autret <autret_m@epita.fr>,
1907 Akim Demaille <akim@epita.fr>
1908
1909 * src/vcg.h (graph_s): color, textcolor, bordercolor are now
1910 enum color_e.
1911 * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm
1912 to `normal'.
1913 * src/reader.c (parse_token_decl): Initialize token with tok_eof.
1914 * src/lex.h: Adjust prototype.
1915 (token_t): Add `tok_undef'.
1916 * src/lex.c (struct percent_table_struct): Retval is now a token_t.
1917 (parse_percent_token): Now returns token_t.
1918 Add default statement in switch.
1919 (lex): Separate `c' as an input variable, from the token_t result
1920 part.
1921 (unlexed): Is a token_t.
1922
1923 2001-09-10 Akim Demaille <akim@epita.fr>
1924
1925 * configure.in: Bump to 1.29a.
1926
1927 2001-09-07 Akim Demaille <akim@epita.fr>
1928
1929 Version 1.29.
1930
1931 2001-08-30 Akim Demaille <akim@epita.fr>
1932
1933 * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove.
1934 * m4/atconfig.m4: Remove.
1935 * tests/testsuite.at, tests/atlocal.in, tests/output.at,
1936 * tests/bison: New.
1937 * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER,
1938 m4_if, m4_patsubst, and m4_regexp.
1939 * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an
1940 `input' file instead of echo.
1941
1942 2001-08-29 Akim Demaille <akim@epita.fr>
1943
1944 Bump to 1.28e.
1945
1946 2001-08-29 Akim Demaille <akim@epita.fr>
1947
1948 Version 1.28d.
1949
1950 2001-08-29 Paul Eggert <eggert@twinsun.com>
1951
1952 * src/bison.simple (yyparse): Don't take the address of an
1953 item before the start of an array, as that doesn't conform to
1954 the C Standard.
1955
1956 2001-08-29 Robert Anisko <anisko_r@epita.fr>
1957
1958 * doc/bison.texinfo (Location Tracking Calc): New node.
1959
1960 2001-08-29 Paul Eggert <eggert@twinsun.com>
1961
1962 * src/output.c (output): Do not define const, as this now
1963 causes more problems than it cures.
1964
1965 2001-08-29 Akim Demaille <akim@epita.fr>
1966
1967 * doc/bison.texinfo: Modernize `@node' and `@top' use: just name
1968 the nodes.
1969 Be sure to tag the `detailmenu'.
1970
1971 2001-08-29 Akim Demaille <akim@epita.fr>
1972
1973 * Makefile.maint (do-po-update): Wget refuses to overwrite files:
1974 download in a tmp dir.
1975
1976 2001-08-28 Marc Autret <autret_m@epita.fr>
1977
1978 * config/depcomp: New file.
1979
1980 2001-08-28 Marc Autret <autret_m@epita.fr>
1981
1982 * doc/bison.1 (mandoc): Adjust.
1983 From Juan Manuel Guerrero.
1984
1985 2001-08-28 Marc Autret <autret_m@epita.fr>
1986
1987 * src/print_graph.c (print_state): Fix.
1988
1989 2001-08-27 Marc Autret <autret_m@epita.fr>
1990
1991 * src/vcg.h (classname_s, infoname_s, node_s): Constify the
1992 char * members.
1993 Echo modifications to the functions prototypes.
1994 * src/vcg.c (add_classname, add_infoname): Adjust arguments.
1995
1996 2001-08-27 Marc Autret <autret_m@epita.fr>
1997
1998 * src/vcg.c: Include `xalloc.h'.
1999 (add_colorentry): New.
2000 (add_classname): New.
2001 (add_infoname): New.
2002 * src/vcg.h: Add new prototypes.
2003
2004 2001-08-27 Akim Demaille <akim@epita.fr>
2005
2006 * Makefile.maint: Sync. again with CVS Autoconf.
2007
2008 2001-08-27 Akim Demaille <akim@epita.fr>
2009
2010 * Makefile.maint: Formatting changes.
2011 (po-update, cvs-update, update): New targets.
2012 (AMTAR): Remove.
2013
2014 2001-08-27 Akim Demaille <akim@epita.fr>
2015
2016 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
2017 * Makefile.maint: Sync. with CVS Autoconf.
2018
2019 2001-08-27 Marc Autret <autret_m@epita.fr>
2020
2021 * src/vcg.h (struct infoname_s): New.
2022 (struct colorentry_s): New.
2023 (graph_s): New fields {vertical,horizontal}_order in structure.
2024 Add `infoname' field.
2025 Add `colorentry' field;
2026 * src/vcg_defaults.h (G_VERTICAL_ORDER): New.
2027 (G_HORIZONTAL_ORDER): New.
2028 (G_INFONAME): New.
2029 (G_COLORENTRY): New.
2030 * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order.
2031 Add output of `infoname'.
2032 Add output of `colorentry'.
2033
2034 2001-08-27 Marc Autret <autret_m@epita.fr>
2035
2036 * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'.
2037 This one shadowed a global parameter.
2038
2039 2001-08-24 Marc Autret <autret_m@epita.fr>
2040
2041 * src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
2042 instead of `unsigned'.
2043 (print_state): Do not call obstack_object_size () in obstack_grow ()
2044 to avoid macro variables shadowing.
2045
2046 2001-08-23 Marc Autret <autret_m@epita.fr>
2047
2048 * src/lex.c (percent_table): Typo: s/naem/name/.
2049 Add graph option.
2050 Normalize new options declarations.
2051
2052 2001-08-20 Pascal Bart <pascal.bart@epita.fr>
2053
2054 * tests/suite.at: Exercise %header_extension and %source_extension.
2055
2056 2001-08-16 Marc Autret <autret_m@epita.fr>
2057
2058 * src/reader.c (parse_dquoted_param): New.
2059 (parse_header_extension_decl): Use it.
2060 (parse_source_extension_decl): Likewise.
2061
2062 2001-08-16 Marc Autret <autret_m@epita.fr>
2063
2064 * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'.
2065 (get_xxxx_str): Use assert () instead of complain ().
2066 Remove return invokations in default cases.
2067 (get_decision_str): Modify default behaviour. Remove second argument.
2068 Echo modifications on calls.
2069 (output_graph): Fix.
2070
2071 2001-08-16 Marc Autret <autret_m@epita.fr>
2072
2073 * src/getargs.c (usage): Update with ``-g, --graph''.
2074
2075 2001-08-16 Marc Autret <autret_m@epita.fr>
2076
2077 * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'.
2078 (Option Cross Key): Likewise.
2079 * doc/bison.1: Update.
2080
2081 2001-09-25 Pascal Bart <pascal.bart@epita.fr>
2082
2083 * src/output.c (output_master_parser): Don't finish action_obstack.
2084 (output_parser): Don't care about the muscle action, here.
2085 (prepare): Copy the action_obstack in the action muscle.
2086 (output): Free action_obstack.
2087
2088 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
2089
2090 * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which
2091 will contain `%union' declaration.
2092 (parse_union_decl): Delete #line directive output.
2093 (parse_union_decl): Substitute /attrs_obstack/union_obstack for all
2094 informations about %union.
2095 (parse_union_decl): Copy the union_obstack in the muscle stype.
2096 * src/bison.simple: Add new #line directive.
2097 Add typdef %%stype YYSTYPE.
2098
2099 2001-09-23 Pascal Bart <pascal.bart@epita.fr>
2100
2101 * src/bison.simple: Add new `#line' directive.
2102
2103 2001-09-22 Pascal Bart <pascal.bart@epita.fr>
2104
2105 * src/bison.simple: New `#line' directive.
2106 * src/output.c (output_parser): Support new dynamic muscle input_line.
2107
2108 2001-09-22 Marc Autret <autret_m@epita.fr>
2109
2110 * src/output.c (output_master_parser): New.
2111 (output_parser): Be more re-entrant.
2112
2113 2001-09-21 Marc Autret <autret_m@epita.fr>
2114
2115 * src/reader.c (copy_definition, parse_union_decl): Update and use
2116 `linef' muscle.
2117 (copy_action): Likewise.
2118 Use obstack_1grow ().
2119 * src/muscle_tab.c (muscle_init): Add muscle `linef'.
2120
2121 2001-09-21 Marc Autret <autret_m@epita.fr>
2122
2123 * src/options.c (option_table): Adjust.
2124 * src/lex.c (parse_percent_token): Fix.
2125
2126 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
2127
2128 * src/options.c (symtab.h): Include it, need by lex.h.
2129
2130 2001-09-20 Pascal Bart <pascal.bart@epita.fr>
2131
2132 * src/lex.c (parse_percent_token): Change type of variable `tx', which
2133 is now an option_table_struct*.
2134 (option_strcmp): New function option_strcmp.
2135 (parse_percent_token): Call option_strcmp.
2136 * src/getargs.c (xalloc.h, options.h): Include it.
2137 (getargs): Call create_long_option_table.
2138 (getargs): Free longopts at the end of the function.
2139 (shortopts): Move in options.c.
2140 * src/options.c (create_long_option_table): New function. Convert
2141 information from option_table to option structure.
2142 * src/reader.c (options.h): Include it.
2143
2144 * src/Makefile.am: Adjust.
2145 * src/options.c (option_table): Create from longopts and percent_table.
2146 * src/getargs.c (longopts): Delete.
2147 * src/lex.c (struct percent_table_struct): Delete.
2148 (percent_table): Delete.
2149 (options.h): Include it.
2150 * src/options.c: Create.
2151 * src/options.h: Create.
2152 Declare enum opt_access_e.
2153 Define struct option_table_struct.
2154
2155 2001-09-20 Marc Autret <autret_m@epita.fr>
2156
2157 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
2158 sections of Bison.
2159
2160 2001-09-19 Pascal Bart <pascal.bart@epita.fr>
2161
2162 * src/bison.simple: s/%%filename/%%skeleton.
2163 * src/muscle_tab.c (getargs.h): Include it.
2164 (muscle_init): Insert new muscle skeleton.
2165
2166 2001-09-18 Pascal Bart <pascal.bart@epita.fr>
2167
2168 * src/output.c (output_parser): Delete unused variable actions_dumped.
2169
2170 2001-09-07 Pascal Bart <pascal.bart@epita.fr>
2171
2172 * src/output.c (output): Delete call to reader_output_yylsp.
2173 * src/reader.c (reader): Likewise.
2174 * src/reader.h: Delete declaration of reader_output_yylsp.
2175
2176 2001-09-02 Marc Autret <autret_m@epita.fr>
2177
2178 * src/reader.c: Include muscle_tab.h.
2179 (parse_union_decl): Update.
2180 (parse_macro_decl): Rename parse_muscle_decl.
2181 Update to use renamed functions and variable.
2182 (read_declarations, copy_action, read_additionnal_code, : Updated
2183 with correct variables and functions names.
2184 (packsymbols, reader): Likewise.
2185
2186 * src/reader.h (muscle_obstack): Extern declaration update.
2187
2188 * src/output.c: Include muscle_tab.h
2189 In all functions using macro_insert, change by using muscle_insert ().
2190 (macro_obstack): Rename muscle_obstack.
2191 Echo modifications in the whole file.
2192 (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT.
2193 (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING.
2194 (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX.
2195
2196 * src/muscle_tab.h: Update double inclusion macros.
2197 (macro_entry_s): Rename muscle_entry_s.
2198 Update prototypes.
2199
2200 * src/muscle_tab.c: Include muscle_tab.h.
2201 Rename macro_tabble to muscle_table.
2202 (mhash1, mhash2, mcmp): Use muscle_entry.
2203 (macro_init): Rename muscle_init. Update.
2204 (macro_insert): Rename muscle_insert. Update.
2205 (macro_find): Rename muscle_find. Update.
2206
2207 * src/main.c: Include muscle_tab.h.
2208 (main): Call muscle_init ().
2209 * src/Makefile.am (bison_SOURCES): Echo modifications.
2210
2211 2001-09-02 Marc Autret <autret_m@epita.fr>
2212
2213 Now the files macro_tab.[ch] are named muscle_tab.[ch].
2214
2215 * src/muscle_tab.c, src/muscle_tab.h: Add files.
2216
2217 2001-09-02 Marc Autret <autret_m@epita.fr>
2218
2219 * src/macrotab.c, src/macrotab.h: Remove.
2220
2221 2001-09-01 Pascal Bart <pascal.bart@epita.fr>
2222
2223 * src/reader.c (copy_guard): Use muscle to specify the `#line'
2224 filename.
2225
2226 2001-09-01 Marc Autret <autret_m@epita.fr>
2227
2228 * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set
2229 to an explicit value to activate the feature. We do it here.
2230
2231 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2232
2233 * src/output.c (prepare): Delete the `filename' muscule insertion.
2234 * src/reader.c (copy_action): Use `filename' muscule with `#line'.
2235 (parse_union_decl): Likewise.
2236 * src/macrotab.c (macro_init): Initialize filename by infile.
2237
2238 2001-08-31 Marc Autret <autret_m@epita.fr>
2239
2240 * src/bison.simple (YYLSP_NEEDED): New definition.
2241 * src/output.c (prepare): Add macro insertion of `locations_flag'
2242
2243 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2244
2245 * src/output.c (prepare): Delete insertion of previous muscles,
2246 and insert the `prefix' muscles.
2247 * src/macrotab.c (macro_init): Likewise.
2248 (macro_init): Initialization prefix directive by `yy'.
2249 * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval,
2250 %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar,
2251 yylval, yydebug, yyerror, yynerrs and yyparse.
2252 New directive `#define' to substitute yydebug, ... with option
2253 name_prefix.
2254
2255 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2256
2257 * src/main.c (main): Standardize.
2258 * src/output.c (output_table_data, output_parser): Likewise.
2259 * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise.
2260
2261 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr>
2262
2263 * src/reader.c (read_additionnal_code): Rename %%user_code to
2264 %%epilogue.
2265 * src/output.c (output): Rename %%declarations to %%prologue.
2266 * src/bison.simple: Echo modifications.
2267
2268 2001-08-31 Marc Autret <autret_m@epita.fr>
2269
2270 * src/reader.c (readgram): CleanUp.
2271 (output_token_defines): Likewise.
2272 (packsymbols): Likewise.
2273 (reader): Likewise.
2274 * src/output.c (output): CPP-out useless code.
2275
2276 2001-08-31 Pascal Bart <pascal.bart@epita.fr>
2277
2278 * src/reader.c (reader): Delete obsolete call to function
2279 output_trailers and output_headers.
2280 * src/output.h: Remove obsolete functions prototypes of output_headers
2281 and output_trailers.
2282
2283 2001-08-30 Pascal Bart <pascal.bart@epita.fr>
2284
2285 * src/main.c: Include macrotab.h.
2286 * src/macrotab.h (macro_entry_s): Constify fields.
2287 Adjust functions prototypes.
2288 * src/macrotab.c (macro_insert): Constify key and value.
2289 (macro_find): Constify key.
2290 (macro_insert): Include 'xalloc.h'
2291 (macro_insert): Use XMALLOC.
2292 (macro_find): Constify return value.
2293 * src/output.c (output_table_data): Rename table to table_data.
2294 (output_parser): Constify macro_key, macro_value.
2295
2296 2001-08-30 Marc Autret <autret_m@epita.fr>
2297
2298 * src/reader.c (parse_skel_decl): New.
2299 (read_declarations): Add case `tok_skel', call parse_skel_decl ().
2300 * src/lex.h (token_t): New token `tok_skel'.
2301 * src/lex.c (percent_table): Add skeleton option entry.
2302 Standardize.
2303
2304 2001-08-29 Marc Autret <autret_m@epita.fr>
2305
2306 * src/bison.simple: Add %%user_code directive at the end.
2307 * src/reader.c (read_additionnal_code): New.
2308 (reader): Use it.
2309 * src/output.c (output_program): Remove.
2310 (output): Update.
2311
2312 2001-08-28 Marc Autret <autret_m@epita.fr>
2313
2314 * src/output.c (output_actions): Clean up.
2315 (output_gram): CPP-out useless code.
2316 * src/reader.c (reader): Clean up, CPP-out useless code.
2317
2318 2001-08-28 Pascal Bart <pascal.bart@epita.fr>
2319
2320 * src/output.c (output): Copy attrs_obstack in the '%%definitions'
2321 directive.
2322 * src/bison.simple: Add `%%definitions'.
2323
2324 2001-08-28 Marc Autret <autret_m@epita.fr>
2325
2326 * config/depcomp: New file.
2327
2328 2001-08-27 Paul Eggert <eggert@twinsun.com>
2329
2330 * src/bison.simple (yyparse): Don't take the address of an
2331 item before the start of an array, as that doesn't conform to
2332 the C Standard.
2333
2334 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2335
2336 * src/output.c (output): Remove the initialization of the macro
2337 obstack. It was done too late here.
2338
2339 * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was
2340 completely wrong.
2341 (reader): Initialize the macro obstack here, since we need it to grow
2342 '%define' directives.
2343
2344 * src/reader.h: Declare the macro obstack as extern.
2345
2346 2001-08-27 Robert Anisko <robert.anisko@epita.fr>
2347
2348 * src/output.c (output_parser): Fix. Store single '%' characters in
2349 the output obstack instead of throwing them away.
2350
2351 2001-08-27 Akim Demaille <akim@epita.fr>
2352
2353 * Makefile.am (AUTOMAKE_OPTIONS): 1.5.
2354
2355 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2356
2357 * lib/Makefile.am: Adjust.
2358
2359 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2360
2361 * src/bison.simple: Update and add '%%' directives.
2362
2363 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2364
2365 * src/reader.c (reader): Remove calls to 'output_headers' and
2366 'output_trailers'. Remove some C output.
2367 (readgram): Disable a piece of code that was writing a default
2368 definition for 'YYSTYPE'.
2369 (reader_output_yylsp): Remove.
2370 (packsymbols): Output token defintions to a macro.
2371 (copy_definition): Disable C output.
2372
2373 * src/reader.c (parse_macro_decl): New function used to parse macro
2374 declarations.
2375 (copy_string2): Put the body of copy_string into this new function.
2376 Add a parameter to let the caller choose whether he wants to copy the
2377 string delimiters or not.
2378 (copy_string): Be a simple call to copy_string2 with the last argument
2379 bound to true.
2380 (read_declarations): Add case for macro definition.
2381 (copy_identifier): New.
2382 (parse_macro_decl): Read macro identifiers using copy_identifier
2383 rather than lex.
2384
2385 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2386
2387 * src/output.c (prepare): Add prefixed names.
2388 (output_parser): Output semantic actions.
2389 (output_parser): Fix bug on '%%line' directives.
2390
2391 * src/output.c (output_headers): Remove. The C code printed by this
2392 function should now be in the skeletons.
2393 (output_trailers): Remove.
2394 (output): Disable call to 'reader_output_yylsp'.
2395 (output_rule_data): Do not output tables to the table obstack.
2396
2397 * src/output.c: Remove some C dedicated output.
2398 Improve the use of macro and output obstacks.
2399 (output_defines): Remove.
2400
2401 * src/output.c (output_token_translations): Associate 'translate'
2402 table with a macro. No output to the table obstack.
2403 (output_gram): Same for 'rhs' and 'prhs'.
2404 (output_stos): Same for 'stos'.
2405 (output_rule_data): Same for 'r1' and 'r2'.
2406 (token_actions): Same for 'defact'.
2407 (goto_actions): Same for 'defgoto'.
2408 (output_base): Same for 'pact' and 'pgoto'.
2409 (output_table): Same for 'table'.
2410 (output_check): Same for 'check'.
2411
2412 * src/output.c (output_table_data): New function.
2413 (output_short_table): Remove.
2414 (output_short_or_char_table): Remove.
2415
2416 * src/output.c (output_parser): Replace most of the skeleton copy code
2417 with something new. Skeletons are now processed character by character
2418 rather than line by line, and Bison looks for '%%' macros. This is the
2419 first step in making Bison's output process (a lot) more flexible.
2420 (output_parser): Use the macro table.
2421
2422 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2423
2424 * src/main.c (main): Initialize the macro table.
2425
2426 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2427
2428 * src/lex.c (percent_table): Add tok_define.
2429 * src/lex.h: Add tok_define.
2430
2431 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2432
2433 * src/macrotab.c: New file.
2434 * src/macrotab.h: New file.
2435 * src/Makefile.am: Update.
2436
2437 2001-08-25 Robert Anisko <robert.anisko@epita.fr>
2438
2439 * lib/hash.c: New file.
2440 * lib/hash.h: New file.
2441 * lib/Makefile.am: Update.
2442
2443 2001-08-15 Akim Demaille <akim@epita.fr>
2444
2445 Version 1.28c.
2446
2447 2001-08-15 Marc Autret <autret_m@epita.fr>
2448
2449 * src/reader.c (readgram): Indent output macro YYSTYPE.
2450 (packsymbols): Likewise.
2451 (output_token_defines): Likewise.
2452 * src/files.c: Standardize.
2453 (compute_header_macro): New.
2454 (defines_obstack_save): New. Use compute_header_macro.
2455 (output_files): Update. Use defines_obstack_save.
2456
2457 2001-08-15 Akim Demaille <akim@epita.fr>
2458
2459 * doc/bison.texinfo (Table of Symbols): Document
2460 YYSTACK_USE_ALLOCA.
2461
2462 2001-08-15 Akim Demaille <akim@epita.fr>
2463
2464 * missing: Update from CVS Automake.
2465 * config/config.guess, config/config.sub, config/texinfo.tex:
2466 Update from gnu.org.
2467
2468 2001-08-15 Akim Demaille <akim@epita.fr>
2469
2470 * Makefile.maint: Sync with CVS Autoconf.
2471
2472 2001-08-14 Pascal Bart <pascal.bart@epita.fr>
2473
2474 * doc/bison.texinfo: Include GNU Free Documentation License from
2475 `fdl.texi'.
2476 * doc/fdl.texi: Add to package.
2477
2478 2001-08-14 Marc Autret <autret_m@epita.fr>
2479
2480 Turn on %{source,header}_extension features.
2481
2482 * src/lex.c (percent_table): Un-CPP out header_extension and
2483 source_extension.
2484 * src/files.c (compute_exts_from_gf): Compare pointers with NULL.
2485 (compute_exts_from_src): Remove conditions. It restores priorities
2486 between options.
2487
2488 2001-08-14 Marc Autret <autret_m@epita.fr>
2489
2490 * src/files.c (compute_base_names): Add extensions computing when
2491 `--file-prefix' used.
2492 Standardize function calls.
2493
2494 2001-08-13 Marc Autret <autret_m@epita.fr>
2495
2496 * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users
2497 defining it (defined but null disables alloca).
2498
2499 2001-08-13 Marc Autret <autret_m@epita.fr>
2500
2501 * src/bison.simple (_yy_memcpy): CPP reformat.
2502
2503 2001-08-13 Pascal Bart <pascal.bart@epita.fr>
2504
2505 * tests/atconfig.in (CPPFLAGS): Fix.
2506
2507 2001-08-10 Pascal Bart <pascal.bart@epita.fr>
2508
2509 * doc/bison.texinfo: Include GNU General Public License from
2510 `gpl.texi'.
2511 * doc/gpl.texi: Add to package.
2512
2513 2001-08-10 Marc Autret <autret_m@epita.fr>
2514
2515 * src/print_graph.h: Fix.
2516 * src/reader.c (read_declarations): Use parse_header_extension_decl ().
2517
2518 2001-08-10 Akim Demaille <akim@epita.fr>
2519
2520 * src/system.h: Provide default declarations for stpcpy, strndup,
2521 and strnlen.
2522
2523 2001-08-10 Robert Anisko <anisko_r@epita.fr>
2524
2525 * doc/bison.texinfo (Locations): Update @$ stuff.
2526
2527 2001-08-09 Robert Anisko <anisko_r@epita.fr>
2528
2529 * src/bison.simple (YYLLOC_DEFAULT): Update.
2530 (yyparse): Adjust.
2531
2532 2001-08-08 Marc Autret <autret_m@epita.fr>
2533
2534 * doc/bison.texinfo: Change @samp{$<@dots{}>} to
2535 @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule.
2536 Reported by Fabrice Bauzac.
2537
2538 2001-08-08 Marc Autret <autret_m@epita.fr>
2539
2540 * src/vcg_default.h: Use NULL instead of 0 to initialize pointers.
2541 * src/vcg.c (output_node): Fix.
2542 * src/vcg.h: Cleanup.
2543 * src/print_graph.c: Add comments.
2544 (node_output_size): New global variable. Simplify the formatting of
2545 the VCG graph output.
2546 (print_actions): Unused code is now used. It notifies the final state
2547 and no action states in the VCG graph. It also give the reduce actions.
2548 The `shift and goto' edges are red and the `go to state' edges are
2549 blue.
2550 Get the current node name and node_obstack by argument.
2551 (node_obstack): New variable.
2552 (print_state): Manage node_obstack.
2553 (print_core): Use node_obstack given by argument.
2554 A node is not only computed here but in print_actions also.
2555 (print_graph): CPP out useless code instead of commenting it.
2556
2557 2001-08-07 Pascal Bart <pascal.bart@epita.fr>
2558
2559 * tests/atconfig.in (CPPFLAGS): Fix.
2560
2561 2001-08-07 Akim Demaille <akim@epita.fr>
2562
2563 * src/print_graph.c (quote): New.
2564 (print_core): Use it.
2565
2566 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr>
2567
2568 * src/vcg.c (complain.h): Include it.
2569 Unepitaize `return' invocations.
2570 [NDEBUG] (main): Remove.
2571 * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members.
2572 * src/files.c (open_files): Initialize graph_obstack.
2573 * src/print_graph.c (print_actions): CPP out useless code.
2574 (print_core): Don't output the last `\n' in labels.
2575 Use `quote'.
2576 * src/files.c (output_files): Output the VCG file.
2577 * src/main.c (main): Invoke print_graph ();
2578
2579 2001-08-06 Marc Autret <autret_m@epita.fr>
2580
2581 Automaton VCG graph output.
2582 Using option ``-g'' or long option ``--graph'', you can generate
2583 a gram_filename.vcg file containing a VCG description of the LALR (1)
2584 automaton of your grammar.
2585
2586 * src/main.c: Call to print_graph() function.
2587 * src/getargs.h: Update.
2588 * src/getargs.c (options): Update to catch `-g' and `--graph' options.
2589 (graph_flag): New flag.
2590 (longopts): Update.
2591 (getargs): Add case `g'.
2592 * src/files.c (graph_obstack): New obstack struct.
2593 (open_files): Initialize new obstack.
2594 (output_files): Saves graph_obstack if required.
2595 * src/files.h (graph_obstack): New extern declaration.
2596 * src/Makefile.am: Add new source files.
2597
2598 2001-08-06 Marc Autret <autret_m@epita.fr>
2599
2600 * src/print_graph.c, src/print_graph.h (graph): New.
2601 * src/vcg.h: New file.
2602 * src/vcg.c: New file, VCG graph handling.
2603
2604 2001-08-06 Marc Autret <autret_m@epita.fr>
2605
2606 Add of %source_extension and %header_extension which specify
2607 the source or/and the header output file extension.
2608
2609 * src/files.c (compute_base_names): Remove initialisation of
2610 src_extension and header_extension.
2611 (compute_exts_from_gf): Update.
2612 (compute_exts_from_src): Update.
2613 (output_files): Update.
2614 * src/reader.c (parse_header_extension_decl): New.
2615 (parse_source_extension_decl): New.
2616 (read_declarations): New case statements for the new tokens.
2617 * src/lex.c (percent_table): Add entries for %source_extension
2618 and %header_extension.
2619 * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext.
2620
2621 2001-08-06 Marc Autret <autret_m@epita.fr>
2622
2623 * configure.in: Bump to 1.28c.
2624 * doc/bison.texinfo: Texinfo thingies.
2625
2626 2001-08-04 Pascal Bart <pascal.bart@epita.fr>
2627
2628 * tests/atconfig.in (CPPFLAGS): Add.
2629 * tests/calc.at (AT_CHECK): Use CPPFLAGS.
2630
2631 2001-08-03 Akim Demaille <akim@epita.fr>
2632
2633 Version 1.28b.
2634
2635 2001-08-03 Akim Demaille <akim@epita.fr>
2636
2637 * tests/Makefile.am (check-local): Ship testsuite.
2638 * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions.
2639 Include `string.h'.
2640
2641 2001-08-03 Akim Demaille <akim@epita.fr>
2642
2643 * configure.in: Try using -Wformat when compiling.
2644
2645 2001-08-03 Akim Demaille <akim@epita.fr>
2646
2647 * configure.in: Bump to 1.28b.
2648
2649 2001-08-03 Akim Demaille <akim@epita.fr>
2650
2651 * src/complain.c: Adjust strerror_r portability issues.
2652
2653 2001-08-03 Akim Demaille <akim@epita.fr>
2654
2655 Version 1.28a.
2656
2657 2001-08-03 Akim Demaille <akim@epita.fr>
2658
2659 * src/getargs.c, src/getarg.h (skeleton)): Constify.
2660 * src/lex.c (literalchar): Avoid name clashes on `buf'.
2661 * src/getargs.c: Include complain.h.
2662 * src/files.c, src/files.h (skeleton_find): Avoid name clashes.
2663 * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1.
2664
2665 2001-08-03 Akim Demaille <akim@epita.fr>
2666
2667 * src/reader.c (readgram): Display hidden chars in error messages.
2668
2669 2001-08-03 Akim Demaille <akim@epita.fr>
2670
2671 Update to gettext 0.10.39.
2672
2673 2001-08-03 Akim Demaille <akim@epita.fr>
2674
2675 * lib/strspn.c: New.
2676
2677 2001-08-01 Marc Autret <autret_m@epita.fr>
2678
2679 * doc/bison.texinfo: Update.
2680 * doc/bison.1 (mandoc): Update.
2681 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h.
2682 * src/files.c: Support output files extensions computing.
2683 (src_extension): New static variable.
2684 (header_extension): New static variable.
2685 (tr): New function.
2686 (get_extension_index): New function, gets the index of an extension
2687 filename in a string.
2688 (compute_exts_from_gf): New function, computes extensions from the
2689 grammar file extension.
2690 (compute_exts_from_src): New functions, computes extensions from the
2691 C source file extension, file given by ``-o'' option.
2692 (compute_base_names): Update.
2693 (output_files): Update.
2694
2695 2001-08-01 Robert Anisko <anisko_r@epita.fr>
2696
2697 * doc/bison.texi: Document @$.
2698 (Locations): New section.
2699
2700 2001-07-18 Akim Demaille <akim@epita.fr>
2701
2702 * Makefile.maint, GNUmakefile: New, from Autoconf 2.52.
2703 * config/prev-version.txt, config/move-if-change: New.
2704 * Makefile.am: Adjust.
2705
2706 2001-07-08 Pascal Bart <pascal.bart@epita.fr>
2707
2708 * src/bison.simple (yyparse): Suppress warning `comparaison
2709 between signed and unsigned'.
2710
2711 2001-07-05 Pascal Bart <pascal.bart@epita.fr>
2712
2713 * src/getargs.h (raw_flag): Remove.
2714 * src/getargs.c: Die on `-r'/`--raw'.
2715 * src/lex.c (parse_percent_token): Die on `%raw'.
2716 * src/reader.c (output_token_defines): Suppress call to `raw_flag'.
2717 * tests/calc.at: Suppress test with option `--raw'.
2718
2719 2001-07-14 Akim Demaille <akim@epita.fr>
2720
2721 * config/: New.
2722 * configure.in: Require Autoconf 2.50.
2723 Update to gettext 0.10.38.
2724
2725 2001-03-16 Akim Demaille <akim@epita.fr>
2726
2727 * doc/bison.texinfo: ANSIfy the examples.
2728
2729 2001-03-16 Akim Demaille <akim@epita.fr>
2730
2731 * getargs.c (skeleton): New variable.
2732 (longopts): --skeleton is a new option.
2733 (shortopts, getargs): -S is a new option.
2734 * getargs.h: Declare skeleton.
2735 * output.c (output_parser): Use it.
2736
2737 2001-03-16 Akim Demaille <akim@epita.fr>
2738
2739 * m4/strerror_r.m4: New.
2740 * m4/error.m4: Run AC_FUNC_STRERROR_R.
2741 * lib/error.h, lib/error.c: Update.
2742
2743 2001-03-16 Akim Demaille <akim@epita.fr>
2744
2745 * src/getargs.c (longopts): Clean up.
2746
2747 2001-02-21 Akim Demaille <akim@epita.fr>
2748
2749 * src/reader.c (gensym): `gensym_count' is your own.
2750 Use a static buf to create the symbol name, as token_buffer is no
2751 longer a buffer.
2752
2753 2001-02-08 Akim Demaille <akim@epita.fr>
2754
2755 * src/conflicts.c (conflict_report): Be sure not to append to res
2756 between two calls, which could happen if both first sprintf were
2757 skipped, but not the first cp += strlen.
2758
2759 2001-02-08 Akim Demaille <akim@epita.fr>
2760
2761 * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c:
2762 New, from fileutils 4.0.37.
2763 * configure.in: Require Autoconf 2.49c. I took some time before
2764 making this decision. This is the only way out for portability
2765 issues in Bison, it would mean way too much duplicate effort to
2766 import in Bison features implemented in 2.49c since 2.13.
2767 AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above.
2768
2769 2001-02-02 Akim Demaille <akim@epita.fr>
2770
2771 * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37.
2772 * lib/xalloc.h, lib/xmalloc.c: Update.
2773
2774 2001-01-19 Akim Demaille <akim@epita.fr>
2775
2776 Get rid of the ad hoc handling of token_buffer in the scanner: use
2777 the obstacks.
2778
2779 * src/lex.c (token_obstack): New.
2780 (init_lex): Initialize it. No longer call...
2781 (grow_token_buffer): this. Remove it.
2782 Adjust all the places which used it to use the obstack.
2783
2784 2001-01-19 Akim Demaille <akim@epita.fr>
2785
2786 * src/lex.h: Rename all the tokens:
2787 s/\bENDFILE\b/tok_eof/g;
2788 s/\bIDENTIFIER\b/tok_identifier/g;
2789 etc.
2790 Let them be enums, not #define, to ease debugging.
2791 Adjust all the code.
2792
2793 2001-01-18 Akim Demaille <akim@epita.fr>
2794
2795 * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private.
2796 * src/lex.c (maxtoken, grow_token_buffer): Static.
2797
2798 2001-01-18 Akim Demaille <akim@epita.fr>
2799
2800 Since we now use obstacks, more % directives can be enabled.
2801
2802 * src/lex.c (percent_table): Also accept `%yacc',
2803 `%fixed_output_files', `%defines', `%no_parser', `%verbose', and
2804 `%debug'.
2805 Handle the actions for `%semantic_parser' and `%pure_parser' here,
2806 instead of returning a token.
2807 * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused.
2808 * src/reader.c (read_declarations): Adjust.
2809 * src/files.c (open_files): Don't call `compute_base_names', don't
2810 compute `attrsfile' since they depend upon data which might be
2811 *in* the input file now.
2812 (output_files): Do it here.
2813 * src/output.c (output_headers): Document the fact that this patch
2814 introduces a guaranteed SEGV for semantic parsers.
2815 * doc/bison.texinfo: Document them.
2816 * tests/suite.at: Exercise these %options.
2817
2818 2000-12-20 Akim Demaille <akim@epita.fr>
2819
2820 Also handle the output file (--verbose) with obstacks.
2821
2822 * files.c (foutput): Remove.
2823 (output_obstack): New.
2824 Adjust all dependencies.
2825 * src/conflicts.c: Return a string.
2826 * src/system.h (obstack_grow_string): Rename as...
2827 (obstack_sgrow): this. Be ready to work with non literals.
2828 (obstack_fgrow4): New.
2829
2830 2000-12-20 Akim Demaille <akim@epita.fr>
2831
2832 * src/files.c (open_files): Fix the computation of short_base_name
2833 in the case of `-o foo.tab.c'.
2834
2835 2000-12-20 Akim Demaille <akim@epita.fr>
2836
2837 * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at)
2838 (copy_dollar): Now that everything uses obstacks, get rid of the
2839 FILE * parameters.
2840
2841 2000-12-20 Akim Demaille <akim@epita.fr>
2842
2843 * src/files.c (open_files): Actually the `.output' file is based
2844 on the short_base_name, not base_name.
2845 * tests/suite.at (Checking output file names): Adjust.
2846
2847 2000-12-20 Akim Demaille <akim@epita.fr>
2848
2849 * src/bison.s1: Remove, we now use directly...
2850 * src/bison.simple: this.
2851 * src/Makefile.am: Use pkgdata instead of data.
2852
2853 2000-12-20 Akim Demaille <akim@epita.fr>
2854
2855 * src/files.c (guard_obstack): New.
2856 (open_files): Initialize it.
2857 (output_files): Dump it...
2858 * src/files.h: Export it.
2859 * src/reader.c (copy_guard): Use it.
2860
2861 2000-12-19 Akim Demaille <akim@epita.fr>
2862
2863 * src/files.c (outfile, defsfile, actfile): Removed as global
2864 vars.
2865 (open_files): Don't compute them.
2866 (output_files): Adjust.
2867 (base_name, short_base_name): Be global.
2868 Adjust dependencies.
2869
2870 2000-12-19 Akim Demaille <akim@epita.fr>
2871
2872 * src/files.c (strsuffix): New.
2873 (stringappend): Be just like strcat but allocate.
2874 (base_names): Eve out from open_files.
2875 Try to simplify the rather hairy computation of base_name and
2876 short_base_name.
2877 (open_files): Use it.
2878 * tests/suite.at (Checking output file names): New test.
2879
2880 2000-12-19 Akim Demaille <akim@epita.fr>
2881
2882 * src/system.h (obstack_grow_literal_string): Rename as...
2883 (obstack_grow_string): this.
2884 * src/output.c (output_parser): Recognize `%% actions' instead of
2885 `$'.
2886 * src/bison.s1: s/$/%% actions/.
2887 * src/bison.hairy: Likewise.
2888
2889 2000-12-19 Akim Demaille <akim@epita.fr>
2890
2891 * src/output.c (output_parser): Compute the `#line' lines when
2892 there are.
2893 * src/Makefile.am (bison.simple): Be a simple copy of bison.s1.
2894 Suggested by Hans Aberg.
2895
2896 2000-12-19 Akim Demaille <akim@epita.fr>
2897
2898 Let the handling of the skeleton files be local to the procedures
2899 that use it.
2900
2901 * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No
2902 longer static.
2903 (fparser, open_extra_files): Remove.
2904 (open_files, output_files): Don't take care of fparser.
2905 * src/files.h: Adjust.
2906 * src/output.c (output_parser): Open and close the file to the
2907 skeleton.
2908 * src/reader.c (read_declarations): When %semantic_parser, open
2909 fguard.
2910
2911 2000-12-19 Akim Demaille <akim@epita.fr>
2912
2913 * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here...
2914 * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here.
2915
2916 2000-12-19 Akim Demaille <akim@epita.fr>
2917
2918 * src/files.c (open_files): Yipee! We no longer need all the code
2919 looking for `/tmp' since we have no tmp file.
2920
2921 2000-12-19 Akim Demaille <akim@epita.fr>
2922
2923 * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C):
2924 New macros.
2925 * src/files.c (open_files): Less dependency on MSDOS etc.
2926
2927 2000-12-14 Akim Demaille <akim@epita.fr>
2928
2929 * src/bison.s1 (YYLLOC_DEFAULT): New macro.
2930 Provide a default definition.
2931 Use it when executing the default @ action.
2932 * src/reader.c (reader_output_yylsp): No longer include
2933 `timestamp' and `text' in the default YYLTYPE.
2934
2935 2000-12-12 Akim Demaille <akim@epita.fr>
2936
2937 * src/reader.c (copy_definition, parse_union_decl, copy_action)
2938 (copy_guard): Quote the file names.
2939 Reported by Laurent Mascherpa.
2940
2941 2000-12-12 Akim Demaille <akim@epita.fr>
2942
2943 * src/output.c (output_headers, output_program, output): Be sure
2944 to escape special characters when outputting filenames.
2945 (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove.
2946 (output_headers): Don't depend on them, Use ACTSTR.
2947
2948 2000-11-17 Akim Demaille <akim@epita.fr>
2949
2950 * lib/obstack.h: Formatting changes.
2951 (obstack_grow, obstack_grow0): Don't cast WHERE at all: it
2952 prevents type checking.
2953 (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
2954 cast the value to (void *): assigning a `foo *' to a `void *'
2955 variable is valid.
2956 (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
2957 * src/reader.c (parse_union_decl): Typo: use obstack_1grow to
2958 append characters.
2959
2960 2000-11-17 Akim Demaille <akim@epita.fr>
2961
2962 * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename
2963 as...
2964 (suite.m4, regression.m4, calc.m4): these.
2965 * tests/atgeneral.m4: Update from CVS Autoconf.
2966
2967 2000-11-17 Akim Demaille <akim@epita.fr>
2968
2969 * tests/regression.m4 (%union and --defines): New test,
2970 demonstrating a current bug in the obstack implementation.
2971
2972 2000-11-17 Akim Demaille <akim@epita.fr>
2973
2974 * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New
2975 macros.
2976 Use them to declare the variables which are global or local to
2977 `yyparse'.
2978
2979 2000-11-17 Akim Demaille <akim@epita.fr>
2980
2981 * acconfig.h: Remove, no longer used.
2982
2983 2000-11-07 Akim Demaille <akim@epita.fr>
2984
2985 * src: s/Copyright (C)/Copyright/g.
2986
2987 2000-11-07 Akim Demaille <akim@epita.fr>
2988
2989 * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
2990 defining.
2991 * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
2992
2993 2000-11-07 Akim Demaille <akim@epita.fr>
2994
2995 * src/bison.s1 (YYLEX): Use #if instead of #ifdef.
2996 Merge in a single CPP if/else.
2997
2998 2000-11-07 Akim Demaille <akim@epita.fr>
2999
3000 * src/output.c (output): Remove useless variables.
3001 * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second
3002 argument `data' for consistency with the prototypes.
3003 Qualify it `const'.
3004 (obstack_copy, obstack_copy0): Rename the second argument as
3005 `address' for consistency. Qualify it `const'.
3006 * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow)
3007 (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify
3008 `const' their input argument (`data' or `address').
3009 Adjust the corresponding macros to include `const' in casts.
3010
3011 2000-11-03 Akim Demaille <akim@epita.fr>
3012
3013 * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/.
3014 s/PFILE1/BISON_HAIRY/.
3015 Adjust dependencies.
3016
3017 2000-11-03 Akim Demaille <akim@epita.fr>
3018
3019 For some reason, this was not applied.
3020
3021 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
3022 `unlink': it's no longer used.
3023
3024 2000-11-03 Akim Demaille <akim@epita.fr>
3025
3026 * src/files.c (skeleton_find): New function, eved out of...
3027 (open_files, open_extra_files): here.
3028
3029 2000-11-03 Akim Demaille <akim@epita.fr>
3030
3031 Don't use `atexit'.
3032
3033 * src/files.c (obstack_save): New function.
3034 (done): Rename as...
3035 (output_files): this.
3036 Use `obstack_save'.
3037 * src/main.c (main): Don't use `atexit' to register `done', since
3038 it no longer has to remove tmp files, just call `output_files'
3039 when there are no errors.
3040
3041 2000-11-02 Akim Demaille <akim@epita.fr>
3042
3043 * src/files.c [VMS]: No longer include `ssdef.h', no longer define
3044 `unlink': it's no longer used.
3045 * src/files.h: Formatting changes.
3046
3047 2000-11-02 Akim Demaille <akim@epita.fr>
3048
3049 Remove the last uses of mktemp and unlink/delete.
3050
3051 * src/files.c (fdefines, ftable): Removed.
3052 (defines_ostack, table_obstack): New.
3053 Adjust dependencies of the former into uses of the latter.
3054 * src/output.c (output_short_or_char_table, output_short_table):
3055 Convert to using obstacks.
3056 * src/reader.c (copy_comment2): Accept one FILE * and two
3057 obstacks.
3058 (output_token_defines, reader_output_yylsp): Use obstacks.
3059 * src/system.h (obstack_fgrow3): New.
3060
3061 2000-11-01 Akim Demaille <akim@epita.fr>
3062
3063 Change each use of `fattrs' into a use of `attrs_obstack'.
3064
3065 * src/reader.c (copy_at): Typo: s/yylloc/yyloc/.
3066 * src/files.c (fattrs): Remove.
3067 (attrs_obstack): New.
3068 Adjust all dependencies.
3069 (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile.
3070
3071 2000-11-01 Akim Demaille <akim@epita.fr>
3072
3073 Introduce obstacks.
3074 Change each use of `faction' into a use of `action_obstack'.
3075
3076 * lib/obstack.h, lib/obstack.c: New files.
3077 * src/files.c (faction): Remove.
3078 (action_obstack): New.
3079 Adjust all dependencies.
3080
3081 2000-10-20 Akim Demaille <akim@epita.fr>
3082
3083 * lib/quote.h (PARAMS): New macro. Use it.
3084
3085 2000-10-16 Akim Demaille <akim@epita.fr>
3086
3087 * src/output.c (output_short_or_char_table): New function.
3088 (output_short_table, output_token_translations): Use it.
3089 (goto_actions): Use output_short_table.
3090
3091 2000-10-16 Akim Demaille <akim@epita.fr>
3092
3093 * src/symtab.c (bucket_new): New function.
3094 (getsym): Use it.
3095
3096 * src/output.c (output_short_table): New argument to display the
3097 comment associated with the table.
3098 Adjust dependencies.
3099 (output_gram): Use it.
3100 (output_rule_data): Nicer output layout for YYTNAME.
3101
3102 2000-10-16 Akim Demaille <akim@epita.fr>
3103
3104 * src/lex.c (read_typename): New function.
3105 (lex): Use it.
3106 * src/reader.c (copy_dollar): Likewise.
3107
3108 2000-10-16 Akim Demaille <akim@epita.fr>
3109
3110 * src/reader.c (copy_comment2): Expect the input stream to be on
3111 the `/' which is suspected to open a comment, instead of being
3112 called after `//' or `/*' was read.
3113 (copy_comment, copy_definition, parse_union_decl, copy_action)
3114 (copy_guard): Adjust.
3115
3116 2000-10-16 Akim Demaille <akim@epita.fr>
3117
3118 * src/reader.c (parse_expect_decl): Use `skip_white_space' and
3119 `read_signed_integer'.
3120
3121 2000-10-16 Akim Demaille <akim@epita.fr>
3122
3123 * src/reader.c (copy_dollar): New function.
3124 (copy_guard, copy_action): Use it.
3125
3126 2000-10-16 Akim Demaille <akim@epita.fr>
3127
3128 * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c:
3129 * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4:
3130 New files, from Fileutils 4.0.27.
3131 * src/main.c (printable_version): Remove.
3132 * src/lex.c, src/reader.c: Use `quote'.
3133
3134 2000-10-04 Akim Demaille <akim@epita.fr>
3135
3136 * lib/error.c, lib/error.h: New files, needed by xmalloc.c.
3137
3138 2000-10-04 Akim Demaille <akim@epita.fr>
3139
3140 * doc/bison.texinfo: Various typos spotted by Neil Booth.
3141
3142 2000-10-04 Akim Demaille <akim@epita.fr>
3143
3144 When a literal string is used to define two different tokens,
3145 `bison -v' segfaults.
3146 Reported by Piotr Gackiewicz, and fixed by Neil Booth.
3147
3148 * tests/regression.m4: New file.
3149 Include the core of the sample provided by Piotr Gackiewicz.
3150 * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed
3151 properly.
3152
3153 2000-10-04 Akim Demaille <akim@epita.fr>
3154
3155 * src/reader.c (parse_expect_decl): Keep `count' within the size
3156 of `buffer'.
3157 From Neil Booth.
3158
3159 2000-10-02 Paul Eggert <eggert@twinsun.com>
3160
3161 * bison.s1 (yyparse): Assign the default value
3162 unconditionally, to avoid a GCC warning and make the parser a
3163 tad smaller.
3164
3165 2000-10-02 Akim Demaille <akim@epita.fr>
3166
3167 * src/getargs.c (getargs): Don't dump `--help' on unrecognized
3168 options.
3169
3170 2000-10-02 Akim Demaille <akim@epita.fr>
3171
3172 * src/derives.c, src/print.c, src/reduce.c: To ease the
3173 translation, move some `\n' out of the translated strings.
3174
3175 2000-10-02 Akim Demaille <akim@epita.fr>
3176
3177 The location tracking mechanism is precious for parse error
3178 messages. Nevertheless, it is enabled only when `@n' is used in
3179 the grammar, which is a different issue (you can use it in error
3180 message, but not in the grammar per se). Therefore, there should
3181 be another means to enable it.
3182
3183 * src/getargs.c (getargs): Support `--locations'.
3184 (usage): Report it.
3185 * src/getargs.h (locationsflag): Export it.
3186 * src/lex.c (percent_table): Support `%locations'.
3187 * src/reader.c (yylsp_needed): Remove this variable, now replaced
3188 with `locationsflag'.
3189 * doc/bison.texinfo: Document `--locations' and `%locations'.
3190 Sort the options.
3191 * tests/calc.m4: Test it.
3192
3193 For regularity of the names, replace each
3194 (nolineflag, toknumflag, rawtokenumflag, noparserflag): with...
3195 (no_lineflag, token_tableflag, rawflag, no_parserflag): this.
3196 In addition replace each `flag' with `_flag'.
3197
3198 2000-10-02 Akim Demaille <akim@epita.fr>
3199
3200 Also test parse error messages, including with YYERROR_VERBOSE.
3201
3202 * tests/calc.m4 (calc.y): Add support for `exp = exp' (non
3203 associative).
3204 Use it to check the computations.
3205 Use it to check `nonassoc' is honored.
3206 (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed
3207 `--yyerror-verbose'.
3208 (_AT_CHECK_CALC): Adjust to this option.
3209 (_AT_CHECK_CALC_ERROR): New macro to check parse error messages.
3210
3211 2000-10-02 Akim Demaille <akim@epita.fr>
3212
3213 Test also `--verbose', `--defines' and `--name-prefix'. Testing
3214 the latter demonstrates a flaw in the handling of non debugging
3215 parsers introduced by myself on 2000-03-16: `#define yydebug 0'
3216 was used in order to simplify:
3217
3218 #if YYDEBUG
3219 if (yydebug)
3220 {
3221 ...
3222 }
3223 #endif
3224
3225 into
3226
3227 if (yydebug)
3228 {
3229 ...
3230 }
3231
3232 unfortunately this leads to a CPP conflict when
3233 `--name-prefix=foo' is used since it produces `#define yydebug
3234 foodebug'.
3235
3236 * src/bison.s1 [!YYDEBUG]: Do not define yydebug.
3237 (YYDPRINTF): New macro.
3238 Spread its use.
3239 * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from
3240 the bison options.
3241 Also test `--verbose', `--defines' and `--name-prefix'.
3242
3243 2000-10-02 Akim Demaille <akim@epita.fr>
3244
3245 Improve the readability of the produced parsers.
3246
3247 * src/bison.s1: Formatting changes.
3248 Improve the comment related to the `$' mark.
3249 (yydefault): Don't fall through to `yyresume': `goto' there.
3250 * src/output.c (output_parser): When the `$' is met, skip the end
3251 of its line.
3252 New variable, `number_of_dollar_signs', to check there's exactly
3253 one `$' in the parser skeleton.
3254
3255 2000-10-02 Akim Demaille <akim@epita.fr>
3256
3257 * lib/xstrdup.c: New file, from the fileutils.
3258 * src/reader.c (parse_token_decl, get_type_name, parse_type_decl)
3259 (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup'
3260 instead of strlen + xmalloc + strcpy.
3261 * src/symtab.c (copys): Remove, use xstrdup instead.
3262
3263 2000-10-02 Akim Demaille <akim@epita.fr>
3264
3265 * src/gram.h (associativity): New enum type which replaces the
3266 former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with
3267 `right_assoc', `left_assoc' and `non_assoc'.
3268 Adjust all dependencies.
3269 * src/reader.c: Formatting changes.
3270 (LTYPESTR): Don't define it, use it as a literal in
3271 `reader_output_yylsp'.
3272 * src/symtab.h (symbol_class): New enum type which replaces the
3273 former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with
3274 `sunknown', `stoken and `snterm'.
3275
3276 2000-10-02 Akim Demaille <akim@epita.fr>
3277
3278 * src/getargs.c (fixed_outfiles): Rename as...
3279 (yaccflag): for consistency and accuracy.
3280 Adjust dependencies.
3281
3282 2000-10-02 Akim Demaille <akim@epita.fr>
3283
3284 Use the more standard files `xalloc.h' and `xmalloc.c' instead of
3285 Bison's `allocate.c' and `alloc.h'. This patch was surprisingly
3286 difficult and introduced a lot of core dump. It turns out that
3287 Bison used an implementation of `xmalloc' based on `calloc', and
3288 at various places it does depend upon the initialization to 0. I
3289 have not tried to isolate the pertinent places, and all the former
3290 calls to Bison's `xmalloc' are now using `XCALLOC'. Someday,
3291 someone should address this issue.
3292
3293 * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove.
3294 * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New
3295 files.
3296 Adjust dependencies.
3297 * src/warshall.h: New file.
3298 Propagate.
3299
3300 2000-10-02 Akim Demaille <akim@epita.fr>
3301
3302 Various anti-`extern in *.c' changes.
3303
3304 * src/system.h: Include `assert.h'.
3305
3306 2000-10-02 Akim Demaille <akim@epita.fr>
3307
3308 * src/state.h (nstates, final_state, first_state, first_shift)
3309 (first_reduction): Move their exportation from here...
3310 * src/LR0.h: to here.
3311 Adjust dependencies.
3312 * src/getargs.c (statisticsflag): New variable.
3313 Add support for `--statistics'.
3314 Adjust dependencies.
3315
3316 Remove a lot of now useless `extern' statements in most files.
3317
3318 2000-10-02 Akim Demaille <akim@epita.fr>
3319
3320 * src/LR0.h: New file.
3321 Propagate its use.
3322
3323 2000-10-02 Akim Demaille <akim@epita.fr>
3324
3325 * src/print.h: New file.
3326 Propagate its use.
3327 * src/print.c: Formatting and ordering changes.
3328 (verbose, terse): Replace with...
3329 (print_results): this new function.
3330 Adjust dependencies.
3331
3332 2000-10-02 Akim Demaille <akim@epita.fr>
3333
3334 * src/conflicts.c (conflict_report): New function.
3335 (conflict_log, verbose_conflict_log): Replace with...
3336 (print_conflicts): this function.
3337 Adjust dependencies.
3338 * src/conflicts.h: New file.
3339 Propagate its inclusion.
3340
3341 2000-10-02 Akim Demaille <akim@epita.fr>
3342
3343 * src/nullable.h: New file.
3344 Propagate its inclusion.
3345 * src/nullable.c: Formatting changes.
3346
3347 2000-10-02 Akim Demaille <akim@epita.fr>
3348
3349 * src/reduce.h: New file.
3350 Propagate its inclusion.
3351 * src/reduce.c: Topological sort and other formatting changes.
3352 (bool, TRUE, FALSE): Move their definition to...
3353 * src/system.h: here.
3354
3355 2000-10-02 Akim Demaille <akim@epita.fr>
3356
3357 * src/files.c: Formatting changes.
3358 (tryopen, tryclose, openfiles): Rename as...
3359 (xfopen, xfclose, open_files): this.
3360 (stringappend): static.
3361 * src/files.h: Complete the list of exported symbols.
3362 Propagate its use.
3363
3364 2000-10-02 Akim Demaille <akim@epita.fr>
3365
3366 * src/reader.h: New file.
3367 Propagate its use instead of tedious list of `extern' and
3368 prototypes.
3369 * src/reader.c: Formatting changes, topological sort,
3370 s/register//.
3371
3372 2000-10-02 Akim Demaille <akim@epita.fr>
3373
3374 * src/lex.h: Prototype `lex.c' exported functions.
3375 * src/reader.c: Adjust.
3376 * src/lex.c: Formatting changes.
3377 (safegetc): Rename as...
3378 (xgetc): this.
3379
3380 2000-10-02 Akim Demaille <akim@epita.fr>
3381
3382 * src/lalr.h: New file.
3383 Propagate its inclusion instead of prototypes and `extern'.
3384 * src/lalr.c: Formatting changes, topological sorting etc.
3385
3386 2000-10-02 Akim Demaille <akim@epita.fr>
3387
3388 * src/output.c (token_actions): Introduce a temporary array,
3389 YYDEFACT, that makes it possible for this function to use
3390 output_short_table.
3391
3392 2000-10-02 Akim Demaille <akim@epita.fr>
3393
3394 `user_toknums' is output as a `short[]' in `output.c', while it is
3395 defined as a `int[]' in `reader.c'. For consistency with the
3396 other output tables, `user_toknums' is now defined as a table of
3397 shorts.
3398
3399 * src/reader.c (user_toknums): Be a short table instead of an int
3400 table.
3401 Adjust dependencies.
3402
3403 Factor the short table outputs.
3404
3405 * src/output.c (output_short_table): New function.
3406 * src/output.c (output_gram, output_stos, output_rule_data)
3407 (output_base, output_table, output_check): Use it.
3408
3409 2000-10-02 Akim Demaille <akim@epita.fr>
3410
3411 * src/output.c (output): Topological sort of the functions, in
3412 order to get rid of the `static' prototypes.
3413 No longer use `register'.
3414 * src/output.h: New file.
3415 Propagate its inclusion in files explicitly prototyping functions
3416 from output.c.
3417
3418 2000-09-21 Akim Demaille <akim@epita.fr>
3419
3420 * src/atgeneral.m4: Update from Autoconf.
3421
3422 2000-09-21 Akim Demaille <akim@epita.fr>
3423
3424 * src/closure.h: New file.
3425 * src/closure.c: Formatting changes, topological sort over the
3426 functions, use of closure.h.
3427 (initialize_closure, finalize_closure): Rename as...
3428 (new_closure, free_closure): these. Adjust dependencies.
3429 * src/LR0.c: Formatting changes, topological sort, use of
3430 cloture.h.
3431 (initialize_states): Rename as...
3432 (new_states): this.
3433 * src/Makefile.am (noinst_HEADERS): Adjust.
3434
3435 2000-09-20 Akim Demaille <akim@epita.fr>
3436
3437 * src/acconfig.h: Don't protect config.h against multiple
3438 inclusion.
3439 Don't define PARAMS.
3440 * src/system.h: Define PARAMS.
3441 Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the
3442 purpose of config.h. system.h must not try to fix wrong
3443 definitions in config.h.
3444
3445 2000-09-20 Akim Demaille <akim@epita.fr>
3446
3447 * src/derives.h: New file.
3448 * src/main.c, src/derives.h: Use it.
3449 Formatting changes.
3450 * src/Makefile.am (noinst_HEADERS): Adjust.
3451
3452 2000-09-20 Akim Demaille <akim@epita.fr>
3453
3454 * tests/atgeneral.m4: Update from Autoconf.
3455 * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC)
3456 (AT_CHECK_CALC): New macros.
3457 Use these macros to test bison with options `', `--raw',
3458 `--debug', `--yacc', `--yacc --debug'.
3459
3460 2000-09-19 Akim Demaille <akim@epita.fr>
3461
3462 * src/output.c: Formatting changes.
3463 * src/machine.h: Remove, leaving its contents in...
3464 * src/system.h: here.
3465 Include stdio.h.
3466 Adjust all dependencies on stdio.h and machine.h.
3467 * src/getargs.h: New file.
3468 Let all `extern' declarations about getargs.c be replaced with
3469 inclusion of `getargs.h'.
3470 * src/Makefile.am (noinst_HEADERS): Adjust.
3471
3472 * tests/calc.m4 (yyin): Be initialized in main, not on the global
3473 scope.
3474 (yyerror): Returns void, not int.
3475 * doc/bison.texinfo: Formatting changes.
3476
3477 2000-09-19 Akim Demaille <akim@epita.fr>
3478
3479 * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not
3480 portable.
3481
3482 2000-09-18 Akim Demaille <akim@epita.fr>
3483
3484 * configure.in: Append WARNING_CFLAGS to CFLAGS.
3485 * src/Makefile.am (INCLUDES): Don't.
3486 Be ready to fetch headers in lib/.
3487
3488 2000-09-18 Akim Demaille <akim@epita.fr>
3489
3490 * doc/bison.texinfo: Update the copyright.
3491 ANSIfy and GNUify the examples.
3492 Remove the old menu.
3493
3494 2000-09-18 Akim Demaille <akim@epita.fr>
3495
3496 First set of tests: use the `calc' example from the documentation.
3497
3498 * src/bison.s1 (yyparse): Condition the code using `yytname' which
3499 is defined only when YYDEBUG is.
3500 * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13.
3501 * src/files.c (tryopen, tryclose): Formatting changes.
3502 Move to the top and be static.
3503 * src/reader.c (read_signed_integer): Likewise.
3504 * tests/calc.m4: New file.
3505 * Makefile.am, suite.m4: Adjust.
3506 * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY.
3507
3508 2000-09-18 Akim Demaille <akim@epita.fr>
3509
3510 Add support for an Autotest test suite for Bison.
3511
3512 * m4/m4.m4, m4/atconfig.m4: New files.
3513 * m4/Makefile.am (EXTRA_DIST): Adjust.
3514 * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New
3515 files.
3516 * src/getargs.c: Display a more standard --version message.
3517 * src/reader.c (reader): Formatting changes.
3518 No longer depend upon VERSION_STRING.
3519 * configure.in: No longer use `dnl'.
3520 Set up the test suite and the new directory `tests/.
3521 (VERSION_STRING): Remove.
3522
3523 2000-04-14 Akim Demaille <akim@epita.fr>
3524
3525 * src/reader.c (copy_comment2): New function, same as former
3526 `copy_comment', but outputs into two FILE *.
3527 (copy_comment): Use it.
3528 (parse_union_decl): Use it.
3529 (get_type, parse_start_decl): Use the same `invalid' message.
3530 (parse_start_decl, parse_union_decl): Use the same `multiple'
3531 message.
3532 (parse_union_decl, copy_guard, copy_action): Use the same
3533 `unmatched' message.
3534 * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'.
3535
3536 2000-03-31 Akim Demaille <akim@epita.fr>
3537
3538 * src/files.c (tryopen, tryclose): Move to the top.
3539 Be static.
3540
3541 2000-03-31 Akim Demaille <akim@epita.fr>
3542
3543 * src/main.c (main): Don't call `done', exit does it.
3544
3545 2000-03-31 Akim Demaille <akim@epita.fr>
3546
3547 * allocate.c: s/return (foo)/return foo/.
3548 * lalr.c: Likewise.
3549 * LR0.c: Likewise.
3550 * output.c: Likewise.
3551 * reader.c: Likewise.
3552 * symtab.c: Likewise.
3553 * vmsgetargs.c: Likewise.
3554
3555 2000-03-31 Akim Demaille <akim@epita.fr>
3556
3557 Clean up the error reporting functions.
3558
3559 * src/report.c: New file.
3560 * src/report.h: Likewise.
3561 * src/Makefile.am: Adjust.
3562 * m4/error.m4: New file.
3563 * m4/Makefile.am: Adjust.
3564 * configure.in (jm_PREREQ_ERROR): Call it.
3565 * src/main.c (int_to_string, banner, fatal_banner, warn_banner):
3566 Remove.
3567 (fatal, fatals): Remove. All callers use complain.c::fatal.
3568 (warn, warni, warns, warnss, warnss): Remove. All callers use
3569 complain.c::complain.
3570 (toomany): Remove, use fatal instead.
3571 * src/files.c (done): No argument, use complain_message_count.
3572 * src/main.c (main): Register `done' to `atexit'.
3573
3574 * src/getargs.c (usage): More `fputs', less `fprintf'.
3575
3576 2000-03-28 Akim Demaille <akim@epita.fr>
3577
3578 * lib/: New directory.
3579 * Makefile.am (SUBDIRS): Adjust.
3580 * configure.in: Adjust.
3581 (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's
3582 useless.
3583 * src/alloca.c: Moved to lib/.
3584 * src/getopt.c: Likewise.
3585 * src/getopt1.c: Likewise.
3586 * src/getopt.h: Likewise.
3587 * src/ansi2knr.c: Likewise.
3588 * src/ansi2knr.1: Likewise.
3589 * src/Makefile.am: Adjust.
3590 * lib/Makefile.am: New file.
3591
3592 2000-03-28 Akim Demaille <akim@epita.fr>
3593
3594 * src/getargs.c (usage): Refresh the help message.
3595
3596 2000-03-17 Akim Demaille <akim@epita.fr>
3597
3598 * src/getopt1.c: Updated from textutils 2.0e
3599 * src/getopt.c: Likewise.
3600 * src/getopt.h: Likewise.
3601
3602 2000-03-17 Akim Demaille <akim@epita.fr>
3603
3604 * src/Makefile.am (bison.simple): Fix the awk program: quote only
3605 the file name, not the whole `#line LINE FILE'.
3606
3607 2000-03-17 Akim Demaille <akim@epita.fr>
3608
3609 On syntax errors, report the token on which we choked.
3610
3611 * src/bison.s1 (yyparse): In the label yyerrlab, when
3612 YYERROR_VERBOSE, add yychar in msg.
3613
3614 2000-03-17 Akim Demaille <akim@epita.fr>
3615
3616 * src/reader.c (copy_at): New function.
3617 (copy_guard): Use it.
3618 (copy_action): Use it.
3619
3620 2000-03-17 Akim Demaille <akim@epita.fr>
3621
3622 Be kind to translators, save some useless translations.
3623
3624 * src/main.c (banner): New function.
3625 (fatal_banner): Use it.
3626 (warn_banner): Use it.
3627
3628 2000-03-17 Akim Demaille <akim@epita.fr>
3629
3630 * src/reader.c (copy_definition): Use copy_string and
3631 copy_comment. Removed now unused `match', `ended',
3632 `cplus_comment'.
3633 (copy_comment, copy_string): Moved, to be visible from
3634 copy_definition.
3635
3636 2000-03-17 Akim Demaille <akim@epita.fr>
3637
3638 * src/reader.c (copy_string): Declare `static inline'. No
3639 problems with inline, since it is checked by configure.
3640 (copy_comment): Likewise.
3641
3642 2000-03-17 Akim Demaille <akim@epita.fr>
3643
3644 * src/reader.c (packsymbols): Formatting changes.
3645
3646 2000-03-17 Akim Demaille <akim@epita.fr>
3647
3648 * src/reader.c (copy_comment): New function, factored out from:
3649 (copy_action): Use it. Removed now unused `match', `ended',
3650 `cplus_comment'.
3651 (copy_guard): Likewise.
3652
3653 2000-03-17 Akim Demaille <akim@epita.fr>
3654
3655 * src/reader.c (copy_string): New function, factored out from:
3656 (copy_action): Use it.
3657 (copy_guard): Likewise.
3658
3659 2000-03-17 Akim Demaille <akim@epita.fr>
3660
3661 Change the handling of @s so that they behave exactly like $s.
3662 There is now a pseudo variable @$ (readble and writable), location
3663 of the lhs of the rule (by default ranging from the location of
3664 the first symbol of the rhs, to the location of the last symbol,
3665 or, if the rhs is empty, YYLLOC).
3666
3667 * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of
3668 yyval.
3669 (yyparse): When providing a default semantic action, provide a
3670 default location action.
3671 (after the $): No longer change `*YYLSP', just stack YYLOC the
3672 same way you stack YYVAL.
3673 * src/reader.c (read_declarations): Use warns.
3674 (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'.
3675 (copy_action, case '@'): Likewise.
3676 Use a standard error message, to save useless work from
3677 translators.
3678
3679 2000-03-17 Akim Demaille <akim@epita.fr>
3680
3681 * src/bison.s1: Formatting and cosmetics changes.
3682 * src/reader.c: Likewise.
3683 Update the Copyright notice.
3684
3685 2000-03-17 Akim Demaille <akim@epita.fr>
3686
3687 * src/bison.s1 (#line): All set to `#line' only, since the
3688 Makefile now handles them.
3689
3690 2000-03-16 Akim Demaille <akim@epita.fr>
3691
3692 * src/output.c (output_rule_data): Output the documentation of
3693 some of the tables.
3694 (Copyright notice): Update.
3695 Formatting changes.
3696
3697 2000-03-16 Akim Demaille <akim@epita.fr>
3698
3699 * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to
3700 remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough.
3701 One `#if YYDEBUG' remains, since it uses variables which are
3702 defined only if `YYDEBUG != 0'.
3703
3704 2000-03-16 Akim Demaille <akim@epita.fr>
3705
3706 * src/bison.s1 (yyparse): Reorganize the definitions of the stacks
3707 and related variables so that the similarities are highlighted.
3708
3709 2000-03-16 Akim Demaille <akim@epita.fr>
3710
3711 * src/bison.s1: Properly indent CPP directives.
3712
3713 2000-03-16 Akim Demaille <akim@epita.fr>
3714
3715 * src/bison.s1: Properly indent the `alloca' CPP section.
3716
3717 2000-03-16 Akim Demaille <akim@epita.fr>
3718
3719 Do not hard code values of directories in `configure.in'.
3720 Update the `configure' tool chain.
3721
3722 * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by
3723 src/makefile.am.
3724 (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED.
3725 (AC_OUTPUT): Add m4/Makefile.
3726 Bump to bison 1.28a, 1.29 has never been released.
3727 * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are
3728 handled via src/Makefile.am.
3729 (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS,
3730 HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by
3731 autoheader.
3732 * Makefile.am (SUBDIRS): Add m4.
3733 (ACLOCAL_AM_FLAGS): New variable.
3734 (AUTOMAKE_OPTIONS): Add check-news.
3735 * src/Makefile.am (bison.simple): Use awk to replace #line lines with
3736 the proper line number and file name.
3737 (DEFS): Propagate the location of bison library files and of the
3738 locale files.
3739 (INCLUDES): Added `-I ..' so that one can compile with srcdir !=
3740 builddir.
3741 * acinclude.m4: Remove, replaced by the directory m4.
3742 * m4/Makefile.am (EXTRA_DIST): New variable.
3743 * m4/gettext.m4: New file, from the fileutils.
3744 * m4/lcmessage.m4: Likewise
3745 * m4/progtest.m4: Likewise.
3746 * m4/bison-decl.m4: New file, extracted from former acinclude.m4.
3747
3748 2000-03-10 Akim Demaille <akim@epita.fr>
3749
3750 * src/closure.c:
3751 Formatting changes of various comments.
3752 Respect the GNU coding standards at various places.
3753 Don't use `_()' when no translation is needed.
3754
3755 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3756
3757 * src/files.c:
3758 OS/2 honors TMPDIR environment variable.
3759
3760 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3761
3762 * doc/bison.texinfo: Tweaked spelling and grammar.
3763 Updated ISBN.
3764 Removed reference to price of printed copy.
3765 Mention BISON_SIMPLE and BISON_HAIRY.
3766
3767 1999-12-13 Jesse Thilo <jthilo@gnu.org>
3768
3769 * configure.in, NEWS:
3770 Bison 1.29 released.
3771
3772 1999-10-27 Jesse Thilo <jthilo@gnu.org>
3773
3774 * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex:
3775 Added reference card.
3776
3777 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3778
3779 * po/ru.po: Added Russian translation.
3780
3781 1999-07-26 Jesse Thilo <jthilo@gnu.org>
3782
3783 * configure.in: Added Russian translation.
3784
3785 1999-07-06 Jesse Thilo <jthilo@gnu.org>
3786
3787 * configure.in, NEWS, README:
3788 Released version 1.28.
3789
3790 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3791
3792 * src/system.h:
3793 Squashed redefinition warning on some systems.
3794
3795 * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c:
3796 Have configure build version string instead of relying on ANSI string
3797 concatentation.
3798
3799 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3800
3801 * po/POTFILES.in: Got rid of version.c.
3802
3803 1999-06-14 Jesse Thilo <jthilo@gnu.org>
3804
3805 * acconfig.h, configure.in:
3806 Have configure build version string instead of relying on ANSI string
3807 concatentation.
3808
3809 1999-06-08 Jesse Thilo <jthilo@gnu.org>
3810
3811 * doc/bison.1:
3812 Dropped mention of `+' for long-named options.
3813
3814 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3815
3816 * src/files.c: Added <unistd.h> for unlink().
3817
3818 * src/Makefile.am, src/system.h:
3819 I18n fixes.
3820
3821 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3822
3823 * README: Added a FAQ list.
3824
3825 * configure.in, acconfig.h:
3826 I18n fixes.
3827
3828 1999-05-30 Jesse Thilo <jthilo@gnu.org>
3829
3830 * doc/FAQ, doc/Makefile.am:
3831 Added a FAQ list.
3832
3833 1999-05-19 Jesse Thilo <jthilo@gnu.org>
3834
3835 * src/alloc.h, src/symtab.h, src/version.c:
3836 Protected inclusion of "config.h" with HAVE_CONFIG_H.
3837
3838 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3839
3840 * src/.cvsignore, src/Makefile.am:
3841 Reorganized: sources in `src', documentation in `doc'.
3842
3843 * src/lex.c (literalchar):
3844 fixed the code for escaping double quotes (thanks
3845 Jonathan Czisny.)
3846
3847 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3848
3849 * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in:
3850 Adjusted paths to reflect directory reorganization.
3851
3852 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3853
3854 * doc/.cvsignore, doc/Makefile.am:
3855 Reorganized: sources in `src', documentation in `doc'.
3856
3857 1999-04-18 Jesse Thilo <jthilo@gnu.org>
3858
3859 * configure.in:
3860 Updated AC_INIT file to reflect directory reorganization.
3861
3862 * configure.in, .cvsignore, Makefile.am, POTFILES.in:
3863 Reorganized: sources in `src', documentation in `doc'.
3864
3865 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3866
3867 * src/allocate.c:
3868 Don't declare calloc() and realloc() if not necessary.
3869
3870 1999-04-13 Jesse Thilo <jthilo@gnu.org>
3871
3872 * configure.in, acconfig.h, acinclude.m4:
3873 Don't declare calloc() and realloc() if not necessary.
3874
3875 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3876
3877 * po/.cvsignore: Added i18n support.
3878
3879 1999-03-23 Jesse Thilo <jthilo@gnu.org>
3880
3881 * acconfig.h, configure.in, Makefile.am:
3882 Added i18n support.
3883
3884 1999-03-22 Jesse Thilo <jthilo@gnu.org>
3885
3886 * src/bison.s1: Fixed #line numbers.
3887
3888 1999-03-15 Jesse Thilo <jthilo@gnu.org>
3889
3890 * po/es.po, po/fr.po, po/nl.po, po/de.po:
3891 Added PO files from Translation Project.
3892
3893 1999-03-03 Jesse Thilo <jthilo@gnu.org>
3894
3895 * Makefile.am:
3896 Added support for non-ANSI compilers (ansi2knr).
3897
3898 1999-02-16 Jesse Thilo <jthilo@gnu.org>
3899
3900 * configure.in: Bumped version number to 1.27.
3901
3902 * Makefile.am:
3903 Added `bison.simple' to list of files removed by `make distclean'.
3904
3905 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3906
3907 * src/files.c, src/files.h:
3908 Defined locations of parser files in config.h instead of Makefile.
3909
3910 1999-02-12 Jesse Thilo <jthilo@gnu.org>
3911
3912 * acconfig.h, acinclude.m4, configure.in, Makefile.am:
3913 Defined locations of parser files in config.h instead of Makefile.
3914
3915 1999-02-09 Jesse Thilo <jthilo@gnu.org>
3916
3917 * Makefile.am:
3918 Removed inappropriate use of $< macro.
3919
3920 1999-02-05 Jesse Thilo <jthilo@gnu.org>
3921
3922 * po/Makefile.in.in, po/POTFILES.in:
3923 Add `po' directory skeleton.
3924
3925 1999-01-27 Jesse Thilo <jthilo@gnu.org>
3926
3927 * README: Document help-bison list.
3928
3929 * configure.in: Add check for mkstemp().
3930
3931 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3932
3933 * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c:
3934 Hush a few compiler warnings.
3935
3936 * src/files.c:
3937 Add tryclose(), which verifies that fclose was successful.
3938 Hush a couple of compiler warnings.
3939
3940 1999-01-20 Jesse Thilo <jthilo@gnu.org>
3941
3942 * Makefile.am, OChangeLog:
3943 ChangeLog is now automatically generated. Include the old version as
3944 OChangeLog.
3945
3946 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3947
3948 * 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:
3949 Update FSF address.
3950
3951 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3952
3953 * doc/bison.texinfo: Fix formatting glitch.
3954
3955 * doc/bison.texinfo: Update FSF address.
3956
3957 1999-01-14 Jesse Thilo <jthilo@gnu.org>
3958
3959 * acconfig.h: Update FSF address.
3960
3961 1999-01-08 Jesse Thilo <jthilo@gnu.org>
3962
3963 * src/system.h:
3964 Don't define PACKAGE here, since config.h defines it.
3965
3966 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3967
3968 * src/reader.c: Update copyright date.
3969
3970 * src/main.c:
3971 Ditch sprintf to statically-sized buffers in fatal/warn functions in
3972 favor of output directly to stderr (avoids buffer overruns).
3973
3974 * src/reader.c: Some checks for premature EOF.
3975
3976 * 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:
3977 Use prototypes if the compiler understands them.
3978
3979 * src/files.c: Honor TMPDIR on Unix hosts.
3980 Use prototypes if the compiler understands them.
3981
3982 * src/reader.c:
3983 Fix a couple of buffer overrun bugs.
3984 Use prototypes if the compiler understands them.
3985
3986 * src/system.h: Include unistd.h and ctype.h.
3987 Use #ifdef instead of #if for NLS symbols.
3988
3989 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3990
3991 * doc/bison.texinfo:
3992 Delete comment "consider using @set for edition number, etc..." since
3993 we now are doing so.
3994
3995 1998-12-30 Jesse Thilo <jthilo@gnu.org>
3996
3997 * configure.in:
3998 Use prototypes if the compiler understands them.
3999
4000 * NEWS: Document 1.26 highlights.
4001
4002 * Makefile.am: Require Automake 1.3 or later.
4003
4004 * acconfig.h:
4005 Use prototypes if the compiler understands them.
4006
4007 1998-12-29 Jesse Thilo <jthilo@gnu.org>
4008
4009 * src/version.c:
4010 Use VERSION symbol from automake for version number.
4011
4012 1998-12-29 Jesse Thilo <jthilo@gnu.org>
4013
4014 * acconfig.h, configure.in, version.cin:
4015 Use VERSION symbol from automake for version number.
4016
4017 1998-11-28 Jesse Thilo <jthilo@gnu.org>
4018
4019 * Makefile.am:
4020 Distribute original version of simple parser (bison.s1), not built
4021 version (bison.simple).
4022
4023 1998-11-28 Jesse Thilo <jthilo@gnu.org>
4024
4025 * doc/bison.texinfo: Add info dir entry.
4026
4027 * doc/bison.texinfo:
4028 Let automake put version number into documentation.
4029
4030 1998-11-26 Jesse Thilo <jthilo@gnu.org>
4031
4032 * src/bison.cld, src/build.com, src/vmshlp.mar:
4033 Add non-RCS files from /gd/gnu/bison.
4034
4035 1998-11-26 Jesse Thilo <jthilo@gnu.org>
4036
4037 * doc/bison.1:
4038 Document the BISON_HAIRY and BISON_SIMPLE variables.
4039
4040 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4041
4042 * src/version.c: Build version.c automatically.
4043
4044 * src/reader.c:
4045 Fix token numbering (used to start at 258, not 257).
4046
4047 * src/system.h: Include config.h.
4048
4049 * src/getargs.c: Update bug report address.
4050
4051 * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h:
4052 Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org.
4053
4054 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4055
4056 * Makefile.am:
4057 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
4058
4059 * configure.in, version.cin:
4060 Build version.c automatically.
4061
4062 * AUTHORS: Add AUTHORS file.
4063
4064 * README: Update bug report address.
4065
4066 * bison.simple:
4067 Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1).
4068
4069 * configure.in, Makefile.am, Makefile.in, stamp-h.in:
4070 Add automake stuff.
4071
4072 1998-11-25 Jesse Thilo <jthilo@gnu.org>
4073
4074 * doc/bison.texinfo: Clean up some formatting.
4075
4076 1998-05-05 Richard Stallman <rms@gnu.org>
4077
4078 * doc/bison.texinfo:
4079 Explain better why to make a pure parser.
4080
4081 1998-01-05 Richard Stallman <rms@gnu.org>
4082
4083 * src/files.c (openfiles):
4084 [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to
4085 find a temporary directory, if possible. Do not unlink files while
4086 they are open.
4087
4088 1997-08-25 Richard Stallman <rms@gnu.org>
4089
4090 * src/reader.c (stack_offset;):
4091 Change some warni to warns.
4092
4093 * src/lex.c (literalchar): Use warns, not warni.
4094
4095 1997-06-28 Richard Stallman <rms@gnu.org>
4096
4097 * src/bison.s1: Add a Bison version comment.
4098
4099 * src/main.c (fatal, warn, berror):
4100 Use program_name.
4101
4102 1997-06-28 Richard Stallman <rms@gnu.org>
4103
4104 * Makefile.in (bison_version): New variable.
4105 (dist): Use that variable.
4106 (bison.s1): Substitute the Bison version into bison.simple.
4107
4108 * bison.simple: Add a Bison version comment.
4109
4110 1997-06-18 Richard Stallman <rms@gnu.org>
4111
4112 * src/main.c (fatal, warn, berror):
4113 Make error messages standard.
4114 (toomany): Improve error message text.
4115
4116 * 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:
4117 new.h renamed to alloc.h.
4118
4119 1997-06-18 Richard Stallman <rms@gnu.org>
4120
4121 * Makefile.in: new.h renamed to alloc.h.
4122
4123 1997-05-24 Richard Stallman <rms@gnu.org>
4124
4125 * src/lex.c (literalchar):
4126 Fix the code for escaping \, " and '.
4127
4128 (lex): Avoid trouble when there are many chars
4129 to discard in a char literal with just several chars in it.
4130
4131 1997-05-17 Richard Stallman <rms@gnu.org>
4132
4133 * src/bison.s1:
4134 Use malloc, if using alloca is troublesome.
4135 (YYSTACK_USE_ALLOCA): New flag macro.
4136 Define it for some systems and compilers.
4137 (YYSTACK_ALLOC): New macro.
4138 (yyparse): Use YYSTACK_ALLOC to allocate stack.
4139 If it was malloc'd, free it.
4140
4141 1997-05-17 Richard Stallman <rms@gnu.org>
4142
4143 * bison.simple:
4144 Use malloc, if using alloca is troublesome.
4145 (YYSTACK_USE_ALLOCA): New flag macro.
4146 Define it for some systems and compilers.
4147 (YYSTACK_ALLOC): New macro.
4148 (yyparse): Use YYSTACK_ALLOC to allocate stack.
4149 If it was malloc'd, free it.
4150
4151 1997-04-23 Richard Stallman <rms@gnu.org>
4152
4153 * src/bison.s1:
4154 (alloca) [__hpux]: Always define as __builtin_alloca.
4155
4156 1997-04-23 Richard Stallman <rms@gnu.org>
4157
4158 * bison.simple:
4159 (alloca) [__hpux]: Always define as __builtin_alloca.
4160
4161 1997-04-22 Richard Stallman <rms@gnu.org>
4162
4163 * src/bison.s1:
4164 [__hpux]: Include alloca.h (right for HPUX 10)
4165 instead of declaring alloca (right for HPUX 9).
4166
4167 * src/bison.s1 (__yy_memcpy):
4168 Declare arg `count' as unsigned int.
4169 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
4170
4171 1997-04-22 Richard Stallman <rms@gnu.org>
4172
4173 * bison.simple:
4174 [__hpux]: Include alloca.h (right for HPUX 10)
4175 instead of declaring alloca (right for HPUX 9).
4176
4177 * bison.simple (__yy_memcpy):
4178 Declare arg `count' as unsigned int.
4179 (yyparse): Cast third arg to __yy_memcpy to unsigned int.
4180
4181 1997-01-03 Richard Stallman <rms@gnu.org>
4182
4183 * src/allocate.c: [__STDC__ or _MSC_VER]:
4184 Declare calloc and realloc to return void *.
4185
4186 1997-01-02 Richard Stallman <rms@gnu.org>
4187
4188 * src/system.h:
4189 [_MSC_VER]: Include stdlib.h and process.h.
4190 [_MSC_VER] (getpid): Define as macro--translate it to _getpid.
4191
4192 * src/main.c (main): Return FAILURE as a value.
4193 (printable_version): Declare arg as int, not char.
4194
4195 1997-01-02 Richard Stallman <rms@gnu.org>
4196
4197 * Makefile.in (dist):
4198 Explicitly check for symlinks, and copy them.
4199
4200 1996-12-19 Richard Stallman <rms@gnu.org>
4201
4202 * src/files.c:
4203 [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined.
4204
4205 1996-12-18 Paul Eggert <eggert@gnu.org>
4206
4207 * src/bison.s1 (yyparse):
4208 If __GNUC__ and YYPARSE_PARAM are both defined,
4209 declare yyparse to have a void * argument.
4210
4211 1996-12-18 Paul Eggert <eggert@gnu.org>
4212
4213 * bison.simple (yyparse):
4214 If __GNUC__ and YYPARSE_PARAM are both defined,
4215 declare yyparse to have a void * argument.
4216
4217 1996-12-17 Richard Stallman <rms@gnu.org>
4218
4219 * src/reduce.c (nbits): Add some casts.
4220
4221 1996-08-12 Richard Stallman <rms@gnu.org>
4222
4223 * src/bison.s1: Test _MSDOS as well as _MSDOS_.
4224
4225 1996-08-12 Richard Stallman <rms@gnu.org>
4226
4227 * bison.simple: Test _MSDOS as well as _MSDOS_.
4228
4229 1996-07-31 Richard Stallman <rms@gnu.org>
4230
4231 * src/bison.s1:
4232 [__sun && __i386]: Include alloca.h.
4233
4234 1996-07-31 Richard Stallman <rms@gnu.org>
4235
4236 * bison.simple:
4237 [__sun && __i386]: Include alloca.h.
4238
4239 1996-07-30 Richard Stallman <rms@gnu.org>
4240
4241 * src/bison.s1: Comment change.
4242
4243 * src/bison.s1: Test _MSDOS_, not MSDOS.
4244
4245 1996-07-30 Richard Stallman <rms@gnu.org>
4246
4247 * bison.simple: Comment change.
4248
4249 * bison.simple: Test _MSDOS_, not MSDOS.
4250
4251 1996-06-01 Richard Stallman <rms@gnu.org>
4252
4253 * 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:
4254 Insert `_' macro around many string constants.
4255
4256 * src/main.c:
4257 Insert `_' macro around many string constants.
4258
4259 (main): Call setlocale, bindtextdomain and textdomain.
4260
4261 * src/system.h: [HAVE_LOCALE_H]: Include locale.h.
4262 [! HAVE_LOCALE_H] (setlocale): Define as no-op.
4263 [ENABLE_NLS]: Include libintl.h.
4264 [ENABLE_NLS] (gettext): Define.
4265 [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions.
4266 (N_, PACKAGE, LOCALEDIR): New macros.
4267
4268 1996-06-01 Richard Stallman <rms@gnu.org>
4269
4270 * POTFILES.in: New file.
4271
4272 * Makefile.in (allocate.o):
4273 Define target explicitly.
4274
4275 * Makefile.in (CFLAGS): Set to @CFLAGS@.
4276 (LDFLAGS): Set to @LDFLAGS@.
4277 (configure): Run autoconf only if preceding `cd' succeeds.
4278 (bison.s1): Redirect output to temporary file then move the
4279 temporary to the target, rather than redirecting directly to bison.s1.
4280 (clean): Remove config.status and config.log.
4281 (distclean): Don't remove config.status here.
4282
4283 1996-05-12 Richard Stallman <rms@gnu.org>
4284
4285 * src/bison.s1:
4286 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4287
4288 1996-05-12 Richard Stallman <rms@gnu.org>
4289
4290 * bison.simple:
4291 (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t.
4292
4293 1996-05-11 Richard Stallman <rms@gnu.org>
4294
4295 * src/bison.s1 (__yy_memcpy):
4296 Really reorder the args, as was supposedly done on Feb 14 1995.
4297 (yyparse): Calls changed accordingly.
4298
4299 1996-05-11 Richard Stallman <rms@gnu.org>
4300
4301 * Makefile.in (dist): Don't use $(srcdir).
4302
4303 * bison.simple (__yy_memcpy):
4304 Really reorder the args, as was supposedly done on Feb 14 1995.
4305 (yyparse): Calls changed accordingly.
4306
4307 1996-01-27 Richard Stallman <rms@gnu.org>
4308
4309 * src/output.c (output_rule_data):
4310 Test YYERROR_VERBOSE in the conditional
4311 around the definition of ttyname.
4312
4313 1995-12-29 Richard Stallman <rms@gnu.org>
4314
4315 * src/bison.s1:
4316 Fix line numbers in #line commands.
4317
4318 1995-12-29 Richard Stallman <rms@gnu.org>
4319
4320 * bison.simple:
4321 Fix line numbers in #line commands.
4322
4323 1995-12-27 Richard Stallman <rms@gnu.org>
4324
4325 * src/bison.s1 (YYPARSE_PARAM_DECL):
4326 In C++, make it always null.
4327 (YYPARSE_PARAM_ARG): New macro.
4328 (yyparse): Use YYPARSE_PARAM_ARG.
4329
4330 1995-12-27 Richard Stallman <rms@gnu.org>
4331
4332 * bison.simple (YYPARSE_PARAM_DECL):
4333 In C++, make it always null.
4334 (YYPARSE_PARAM_ARG): New macro.
4335 (yyparse): Use YYPARSE_PARAM_ARG.
4336
4337 1995-11-29 Richard Stallman <rms@gnu.org>
4338
4339 * doc/bison.texinfo:
4340 Describe literal string tokens, %raw, %no_lines, %token_table.
4341
4342 1995-11-29 Daniel Hagerty <hag@gnu.org>
4343
4344 * doc/bison.texinfo: Fixed update date
4345
4346 1995-10-16 Richard Stallman <rms@gnu.org>
4347
4348 * src/version.c: Version 1.25.
4349
4350 1995-10-16 Richard Stallman <rms@gnu.org>
4351
4352 * NEWS: *** empty log message ***
4353
4354 1995-10-16 Richard Stallman <rms@gnu.org>
4355
4356 * doc/bison.1, doc/bison.rnh:
4357 Add new options.
4358
4359 1995-10-15 Richard Stallman <rms@gnu.org>
4360
4361 * src/vmsgetargs.c, src/getargs.c:
4362 Added -n, -k, and -raw switches.
4363 (noparserflag, toknumflag, rawtoknumflag): New variables.
4364
4365 * src/symtab.h (SALIAS):
4366 New #define for adding aliases to %token.
4367 (struct bucket): Added `alias' field.
4368
4369 * src/reduce.c (reduce_grammar):
4370 Revise error message.
4371 (print_notices): Remove final `.' from error message.
4372
4373 * src/reader.c (reader_output_yylsp):
4374 New function.
4375 (readgram): Use `#if 0' around code that accepted %command
4376 inside grammar rules: The documentation doesn't allow it,
4377 and it will fail since the %command processors scan for the next %.
4378 (parse_token_decl): Extended the %token
4379 declaration to allow a multi-character symbol as an alias.
4380 (parse_thong_decl): New function.
4381 (read_declarations): Added %thong declarations.
4382 (read_declarations): Handle NOOP to deal with allowing
4383 % declarations as another means to specify the flags.
4384 (readgram): Allow %prec prior to semantics embedded in a rule.
4385 (skip_to_char, read_declarations, copy_definition)
4386 (parse_token_decl, parse_start_decl, parse_type_decl)
4387 (parse_assoc_decl, parse_union_decl, parse_expect_decl)
4388 (get_type_name, copy_guard, copy_action, readgram)
4389 (get_type, packsymbols): Revised most error messages.
4390 Changed `fatal' to `warnxxx' to avoid aborting for error.
4391 Revised and use multiple warnxxx functions to avoid using VARARGS1.
4392 (read_declarations): Improve the error message for
4393 an invalid character. Do not abort.
4394 (read_declarations, copy_guard, copy_action): Use
4395 printable_version to avoid unprintable characters in printed output.
4396 (parse_expect_decl): Error if argument to %expect exceeds 10 digits.
4397 (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type):
4398 Allow the type of a non-terminal can be given
4399 more than once, as long as all specifications give the same type.
4400
4401 * src/output.c:
4402 (output_headers, output_trailers, output, output_gram)
4403 (output_rule_data): Implement noparserflag variable.
4404 Implement toknumflag variable.
4405 (output): Call reader_output_yylsp to output LTYPESTR.
4406
4407 * src/main.c (main):
4408 If reader sees an error, don't process the grammar.
4409 (fatals): Updated to not use VARARGS1.
4410 (printable_version, int_to_string, warn, warni, warns, warnss)
4411 (warnsss): New error reporting functions. Avoid abort for error.
4412
4413 * src/lex.h:
4414 Added THONG and NOOP for alias processing.
4415 Added SETOPT for the new code that allows setting options with %flags.
4416
4417 * src/lex.c:
4418 Include getopt.h. Add some extern decls.
4419 (safegetc): New function to deal with EOF gracefully.
4420 (literalchar); new function to deal with reading \ escapes.
4421 (lex): Use literalchar.
4422 (lex): Implemented "..." tokens.
4423 (literalchar, lex, parse_percent_token): Made tokenbuffer
4424 always contain the token. This includes growing the token
4425 buffer while reading an integer.
4426 (parse_percent_token): Replaced if-else statement with percent_table.
4427 (parse_percent_token): Added % declarations as another
4428 way to specify the flags -n, -l, and -r. Also added hooks for
4429 -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires
4430 major changes to files.c.
4431 (lex) Retain in the incoming stream a character following
4432 an incorrect '/'.
4433 (skip_white_space, lex): Revised most error messages
4434 and changed fatal to warn to avoid aborting.
4435 (percent_table): Added %thong declarations.
4436
4437 * src/gram.h: Comment changes.
4438
4439 * src/files.c (openfiles, open_extra_files, done):
4440 Add faction flag
4441 and actfile file. Handle noparserflag. Both for -n switch.
4442
4443 * src/conflicts.c (resolve_sr_conflict):
4444 Remove use of alloca.
4445
4446 1995-06-01 Jim Meyering <meyering@gnu.org>
4447
4448 * doc/bison.texinfo: *** empty log message ***
4449
4450 1995-05-06 Richard Stallman <rms@gnu.org>
4451
4452 * src/bison.s1: Comment change.
4453
4454 1995-05-06 Richard Stallman <rms@gnu.org>
4455
4456 * bison.simple: Comment change.
4457
4458 1995-05-03 Richard Stallman <rms@gnu.org>
4459
4460 * src/version.c: Version now 1.24.
4461
4462 * src/bison.s1: Change distribution terms.
4463
4464 * src/version.c: Version now 1.23.
4465
4466 1995-05-03 Richard Stallman <rms@gnu.org>
4467
4468 * doc/bison.texinfo:
4469 Rewrite "Conditions for Using Bison".
4470 Update version to 1.24.
4471
4472 1995-05-03 Richard Stallman <rms@gnu.org>
4473
4474 * bison.simple: Change distribution terms.
4475
4476 1995-02-23 Richard Stallman <rms@gnu.org>
4477
4478 * src/files.c: Test __VMS_POSIX as well as VMS.
4479
4480 1995-02-14 Jim Meyering <meyering@gnu.org>
4481
4482 * src/bison.s1 (__yy_memcpy):
4483 Renamed from __yy_bcopy to avoid
4484 confusion. Reverse FROM and TO arguments to be consistent with
4485 those of memcpy.
4486
4487 1995-02-14 Jim Meyering <meyering@gnu.org>
4488
4489 * bison.simple (__yy_memcpy):
4490 Renamed from __yy_bcopy to avoid
4491 confusion. Reverse FROM and TO arguments to be consistent with
4492 those of memcpy.
4493
4494 1994-11-10 David J. MacKenzie <djm@gnu.org>
4495
4496 * NEWS: reformat
4497
4498 * NEWS: New file.
4499
4500 * Makefile.in (DISTFILES): Include NEWS.
4501
4502 * Makefile.in (DISTFILES):
4503 Include install-sh, not install.sh.
4504
4505 * configure.in: Update to Autoconf v2 macro names.
4506
4507 1994-10-05 David J. MacKenzie <djm@gnu.org>
4508
4509 * Makefile.in: fix typo
4510
4511 * Makefile.in (prefix, exec_prefix):
4512 Let configure set them.
4513
4514 1994-09-28 David J. MacKenzie <djm@gnu.org>
4515
4516 * Makefile.in: Set datadir to $(prefix)/share.
4517
4518 1994-09-15 Richard Stallman <rms@gnu.org>
4519
4520 * src/bison.s1:
4521 Update copyright notice and GPL version.
4522
4523 1994-09-15 Richard Stallman <rms@gnu.org>
4524
4525 * bison.simple:
4526 Update copyright notice and GPL version.
4527
4528 1994-07-12 Richard Stallman <rms@gnu.org>
4529
4530 * src/reduce.c, src/reader.c:
4531 entered into RCS
4532
4533 1994-05-05 David J. MacKenzie <djm@gnu.org>
4534
4535 * Makefile.in: entered into RCS
4536
4537 1994-03-26 Richard Stallman <rms@gnu.org>
4538
4539 * src/bison.s1: entered into RCS
4540
4541 1994-03-26 Richard Stallman <rms@gnu.org>
4542
4543 * bison.simple: entered into RCS
4544
4545 1994-03-25 Richard Stallman <rms@gnu.org>
4546
4547 * src/main.c: entered into RCS
4548
4549 1994-03-24 Richard Stallman <rms@gnu.org>
4550
4551 * src/conflicts.c: entered into RCS
4552
4553 1994-01-02 Richard Stallman <rms@gnu.org>
4554
4555 * Makefile.in: *** empty log message ***
4556
4557 1993-11-21 Richard Stallman <rms@gnu.org>
4558
4559 * src/bison.s1: *** empty log message ***
4560
4561 1993-11-21 Richard Stallman <rms@gnu.org>
4562
4563 * doc/bison.texinfo: entered into RCS
4564
4565 * doc/bison.texinfo: *** empty log message ***
4566
4567 1993-11-21 Richard Stallman <rms@gnu.org>
4568
4569 * bison.simple: *** empty log message ***
4570
4571 1993-10-25 David J. MacKenzie <djm@gnu.org>
4572
4573 * doc/bison.texinfo: *** empty log message ***
4574
4575 1993-10-19 Richard Stallman <rms@gnu.org>
4576
4577 * src/bison.s1: *** empty log message ***
4578
4579 1993-10-19 Richard Stallman <rms@gnu.org>
4580
4581 * bison.simple: *** empty log message ***
4582
4583 1993-10-14 Richard Stallman <rms@gnu.org>
4584
4585 * src/bison.s1: *** empty log message ***
4586
4587 1993-10-14 Richard Stallman <rms@gnu.org>
4588
4589 * bison.simple: *** empty log message ***
4590
4591 1993-09-14 David J. MacKenzie <djm@gnu.org>
4592
4593 * doc/bison.texinfo: *** empty log message ***
4594
4595 1993-09-13 Noah Friedman <friedman@gnu.org>
4596
4597 * Makefile.in: *** empty log message ***
4598
4599 1993-09-10 Richard Stallman <rms@gnu.org>
4600
4601 * src/conflicts.c: *** empty log message ***
4602
4603 * src/system.h: entered into RCS
4604
4605 1993-09-10 Richard Stallman <rms@gnu.org>
4606
4607 * doc/bison.1: entered into RCS
4608
4609 1993-09-06 Noah Friedman <friedman@gnu.org>
4610
4611 * src/version.c: entered into RCS
4612
4613 1993-09-06 Noah Friedman <friedman@gnu.org>
4614
4615 * Makefile.in: *** empty log message ***
4616
4617 1993-07-30 David J. MacKenzie <djm@gnu.org>
4618
4619 * Makefile.in: *** empty log message ***
4620
4621 1993-07-24 Richard Stallman <rms@gnu.org>
4622
4623 * src/bison.s1: *** empty log message ***
4624
4625 1993-07-24 Richard Stallman <rms@gnu.org>
4626
4627 * bison.simple: *** empty log message ***
4628
4629 1993-07-08 David J. MacKenzie <djm@gnu.org>
4630
4631 * Makefile.in: *** empty log message ***
4632
4633 1993-07-04 Richard Stallman <rms@gnu.org>
4634
4635 * src/bison.s1: *** empty log message ***
4636
4637 1993-07-04 Richard Stallman <rms@gnu.org>
4638
4639 * bison.simple: *** empty log message ***
4640
4641 1993-06-26 David J. MacKenzie <djm@gnu.org>
4642
4643 * src/getargs.c: entered into RCS
4644
4645 1993-06-26 David J. MacKenzie <djm@gnu.org>
4646
4647 * doc/bison.texinfo: *** empty log message ***
4648
4649 * doc/bison.1: New file.
4650
4651 1993-06-25 Richard Stallman <rms@gnu.org>
4652
4653 * src/getargs.c: New file.
4654
4655 1993-06-16 Richard Stallman <rms@gnu.org>
4656
4657 * src/bison.s1: *** empty log message ***
4658
4659 1993-06-16 Richard Stallman <rms@gnu.org>
4660
4661 * bison.simple: *** empty log message ***
4662
4663 1993-06-03 Richard Stallman <rms@gnu.org>
4664
4665 * src/bison.s1: New file.
4666
4667 1993-06-03 Richard Stallman <rms@gnu.org>
4668
4669 * doc/bison.texinfo: *** empty log message ***
4670
4671 1993-06-03 Richard Stallman <rms@gnu.org>
4672
4673 * bison.simple: New file.
4674
4675 1993-05-19 Richard Stallman <rms@gnu.org>
4676
4677 * doc/bison.texinfo: New file.
4678
4679 1993-05-07 Noah Friedman <friedman@gnu.org>
4680
4681 * Makefile.in: *** empty log message ***
4682
4683 1993-04-28 Noah Friedman <friedman@gnu.org>
4684
4685 * src/reader.c: *** empty log message ***
4686
4687 1993-04-23 Noah Friedman <friedman@gnu.org>
4688
4689 * src/alloc.h: entered into RCS
4690
4691 1993-04-20 David J. MacKenzie <djm@gnu.org>
4692
4693 * src/version.c: *** empty log message ***
4694
4695 * src/files.c, src/allocate.c:
4696 entered into RCS
4697
4698 * src/reader.c: *** empty log message ***
4699
4700 * src/lex.c: entered into RCS
4701
4702 * src/conflicts.c: New file.
4703
4704 * src/symtab.c: entered into RCS
4705
4706 * src/alloc.h: New file.
4707
4708 * src/LR0.c: entered into RCS
4709
4710 1993-04-18 Noah Friedman <friedman@gnu.org>
4711
4712 * src/reader.c: New file.
4713
4714 * src/version.c: *** empty log message ***
4715
4716 1993-04-18 Noah Friedman <friedman@gnu.org>
4717
4718 * Makefile.in: *** empty log message ***
4719
4720 1993-04-17 Noah Friedman <friedman@gnu.org>
4721
4722 * Makefile.in: *** empty log message ***
4723
4724 1993-04-15 Richard Stallman <rms@gnu.org>
4725
4726 * src/main.c, src/files.c:
4727 New file.
4728
4729 1993-04-15 Noah Friedman <friedman@gnu.org>
4730
4731 * configure.in: entered into RCS
4732
4733 * configure.in: *** empty log message ***
4734
4735 * configure.in: New file.
4736
4737 1993-04-14 Richard Stallman <rms@gnu.org>
4738
4739 * Makefile.in: New file.
4740
4741 1993-04-13 Richard Stallman <rms@gnu.org>
4742
4743 * src/version.c: New file.
4744
4745 1993-03-25 Richard Stallman <rms@gnu.org>
4746
4747 * src/output.c: entered into RCS
4748
4749 1992-09-25 Richard Stallman <rms@gnu.org>
4750
4751 * configure.bat: entered into RCS
4752
4753 1992-06-22 Richard Stallman <rms@gnu.org>
4754
4755 * src/vmsgetargs.c: entered into RCS
4756
4757 1992-06-22 Richard Stallman <rms@gnu.org>
4758
4759 * doc/bison.rnh: entered into RCS
4760
4761 1992-04-20 David J. MacKenzie <djm@gnu.org>
4762
4763 * README: entered into RCS
4764
4765 1992-01-22 Richard Stallman <rms@gnu.org>
4766
4767 * src/machine.h: entered into RCS
4768
4769 1991-12-21 Richard Stallman <rms@gnu.org>
4770
4771 * src/lalr.c, src/closure.c:
4772 entered into RCS
4773
4774 1991-12-20 Richard Stallman <rms@gnu.org>
4775
4776 * src/state.h: entered into RCS
4777
4778 1991-12-18 Richard Stallman <rms@gnu.org>
4779
4780 * src/print.c, src/nullable.c, src/derives.c:
4781 entered into RCS
4782
4783 1991-11-03 David J. MacKenzie <djm@gnu.org>
4784
4785 * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h:
4786 entered into RCS
4787
4788 1988-09-09 Richard Stallman <rms@gnu.org>
4789
4790 * src/bison.hairy: entered into RCS
4791
4792 1987-12-16 Richard Stallman <rms@gnu.org>
4793
4794 * REFERENCES: entered into RCS