]> git.saurik.com Git - bison.git/blame - ChangeLog
* data/bison.simple, data/bison.c++: Be sure to restore the
[bison.git] / ChangeLog
CommitLineData
e96c9728
AD
12002-06-14 Akim Demaille <akim@epita.fr>
2
3 * data/bison.simple, data/bison.c++: Be sure to restore the
4 current #line when returning to the skeleton contents after having
5 exposed the input file's #line.
6
75d1fe16
AD
72002-06-12 Akim Demaille <akim@epita.fr>
8
9 * src/scan-gram.l (SC_BRACED_CODE): Don't use `<.*>', it is too
10 eager.
11 * tests/actions.at (Exotic Dollars): New.
12
6c35d22c
AD
132002-06-12 Akim Demaille <akim@epita.fr>
14
15 * src/scan-gram.l (SC_PROLOGUE): Don't eat characters amongst
16 ['"/] too eagerly.
17 * tests/input.at (Torturing the Scanner): New.
18
1d6412ad
AD
192002-06-11 Akim Demaille <akim@epita.fr>
20
21 * src/scan-gram.l (YY_OBS_INIT): Remove, replace with...
22 [SC_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE,SC_PROLOGUE]
23 [SC_EPILOGUE]: Output the quadrigraphs only when not in a comment.
24 * src/reader.h, src/scan-gram.l (scanner_initialize): this.
25 * src/reader.c (reader): Use it.
26
4cdb01db
AD
272002-06-11 Akim Demaille <akim@epita.fr>
28
29 * src/scan-gram.l (YY_OBS_FINISH): Don't set yylval.
30 Adjust all callers.
31 (scanner_last_string_free): New.
32
44995b2e
AD
332002-06-11 Akim Demaille <akim@epita.fr>
34
35 * src/scan-gram.l (YY_INIT, YY_GROW, YY_FINISH): Rename as...
36 (YY_OBS_INIT, YY_OBS_GROW, YY_OBS_FINISH): these.
37 (last_string, YY_OBS_FREE): New.
38 Use them when returning an ID.
39
e9955c83
AD
402002-06-11 Akim Demaille <akim@epita.fr>
41
42 Have Bison grammars parsed by a Bison grammar.
43
44 * src/reader.c, src/reader.h (prologue_augment): New.
45 * src/reader.c (copy_definition): Remove.
46
47 * src/reader.h, src/reader.c (gram_start_symbol_set, prologue_augment)
48 (grammar_symbol_append, grammar_rule_begin, grammar_midrule_action)
49 (grammar_current_rule_prec_set, grammar_current_rule_check)
50 (grammar_current_rule_symbol_append)
51 (grammar_current_rule_action_append): Export.
52 * src/parse-gram.y (symbol_list_new, symbol_list_symbol_append_
53 (symbol_list_action_append): Remove.
54 Hook the routines from reader.
55 * src/scan-gram.l: In INITIAL, characters and strings are tokens.
56 * src/system.h (ATTRIBUTE_NORETURN, ATTRIBUTE_UNUSED): Now.
57
58 * src/reader.c (read_declarations): Remove, unused.
59
60 * src/parse-gram.y: Handle the epilogue.
61 * src/reader.h, src/reader.c (gram_start_symbol_set): Rename as...
62 (grammar_start_symbol_set): this.
63 * src/scan-gram.l: Be sure to ``use'' yycontrol to keep GCC quiet.
64 * src/reader.c (readgram): Remove, unused.
65 (reader): Adjust to insert eoftoken and axiom where appropriate.
66
67 * src/reader.c (copy_dollar): Replace with...
68 * src/scan-gram.h (handle_dollar): this.
69 * src/parse-gram.y: Remove `%thong'.
70
71 * src/reader.c (copy_at): Replace with...
72 * src/scan-gram.h (handle_at): this.
73
74 * src/complain.h, src/complain.c (warn_at, complain_at, fatal_at):
75 New.
76
77 * src/scan-gram.l (YY_LINES): Keep lineno synchronized for the
78 time being.
79
80 * src/reader.h, src/reader.c (grammar_rule_end): New.
81
82 * src/parse.y (current_type, current_class): New.
83 Implement `%nterm', `%token' support.
84 Merge `%term' into `%token'.
85 (string_as_id): New.
86 * src/symtab.h, src/symtab.c (symbol_make_alias): Don't pass the
87 type name.
88
89 * src/parse-gram.y: Be sure to handle properly the beginning of
90 rules.
91
92 * src/parse-gram.y: Handle %type.
93 * src/reader.c (grammar_rule_end): Call grammar_current_rule_check.
94
95 * src/parse-gram.y: More directives support.
96 * src/options.c: No longer handle source directives.
97
98 * src/parse-gram.y: Fix %output.
99
100 * src/parse-gram.y: Handle %union.
101 Use the prologue locations.
102 * src/reader.c (parse_union_decl): Remove.
103
104 * src/reader.h, src/reader.c (epilogue_set): New.
105 * src/parse-gram.y: Use it.
106
107 * data/bison.simple, data/bison.c++: b4_stype is now either not
108 defined, then default to int, or to the contents of %union,
109 without `union' itself.
110 Adjust.
111 * src/muscle_tab.c (muscle_init): Don't predefine `stype'.
112
113 * src/output.c (actions_output): Don't output braces, as they are
114 already handled by the scanner.
115
116 * src/scan-gram.l (SC_CHARACTER): Set the user_token_number of
117 characters to themselves.
118
119 * tests/reduce.at (Reduced Automaton): End the grammars with %% so
120 that the epilogue has a proper #line.
121
122 * src/parse-gram.y: Handle precedence/associativity.
123
124 * src/symtab.c (symbol_precedence_set): Requires the symbol to be
125 a terminal.
126 * src/scan-gram.l (SC_BRACED_CODE): Catch strings and characters.
127 * tests/calc.at: Do not use `%token "foo"' as it makes not sense
128 at all to define terminals that cannot be emitted.
129
130 * src/scan-gram.l: Escape M4 characters.
131
132 * src/scan-gram.l: Working properly with escapes in user
133 strings/characters.
134
135 * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR)
136 (AT_DATA_HORIZONTAL_GRAMMAR): Respect the `%token ID NUM STRING'
137 grammar.
138 Use more modest sizes, as for the time being the parser does not
139 release memory, and therefore the process swallows a huge amount
140 of memory.
141
142 * tests/torture.at (AT_DATA_LOOKAHEADS_GRAMMAR): Adjust to the
143 stricter %token grammar.
144
145 * src/symtab.h (associativity): Add `undef_assoc'.
146 (symbol_precedence_set): Do nothing when passed an undef_assoc.
147 * src/symtab.c (symbol_check_alias_consistence): Adjust.
148
149 * tests/regression.at (Invalid %directive): Remove, as it is now
150 meaningless.
151 (Invalid inputs): Adjust to the new error messages.
152 (Token definitions): The new grammar doesn't allow too many
153 eccentricities.
154
155 * src/lex.h, src/lex.c: Remove.
156 * src/reader.c (lastprec, skip_to_char, read_signed_integer)
157 (copy_character, copy_string2, copy_string, copy_identifier)
158 (copy_comment, parse_token_decl, parse_type_decl, parse_assoc_decl)
159 (parse_muscle_decl, parse_dquoted_param, parse_skel_decl)
160 (parse_action): Remove.
161 * po/POTFILES.in: Adjust.
162
2e047461
AD
1632002-06-11 Akim Demaille <akim@epita.fr>
164
165 * src/reader.c (parse_action): Don't store directly into the
166 rule's action member: return the action as a string.
167 Don't require `rule_length' as an argument: compute it.
168 (grammar_current_rule_symbol_append)
169 (grammar_current_rule_action_append): New, eved out from
170 (readgram): here.
171 Remove `action_flag', `rulelength', unused now.
172
9af3fbce
AD
1732002-06-11 Akim Demaille <akim@epita.fr>
174
175 * src/reader.c (grammar_current_rule_prec_set).
176 (grammar_current_rule_check): New, eved out from...
177 (readgram): here.
178 Remove `xaction', `first_rhs': useless.
179 * tests/input.at (Type clashes): New.
180 * tests/existing.at (GNU Cim Grammar): Adjust.
181
1485e106
AD
1822002-06-11 Akim Demaille <akim@epita.fr>
183
184 * src/reader.c (grammar_midrule_action): New, Eved out from
185 (readgram): here.
186
da4160c3
AD
1872002-06-11 Akim Demaille <akim@epita.fr>
188
189 * src/reader.c (grammar_rule_begin, previous_rule, current_rule):
190 New.
191 (readgram): Use them as replacement of inlined code, crule and
192 crule1.
193
f6d0f937
AD
1942002-06-11 Akim Demaille <akim@epita.fr>
195
196 * src/reader.c (grammar_end, grammar_symbol_append): New.
197 (readgram): Use them.
198 Make the use of `p' as local as possible.
199
69078d4b
AD
2002002-06-10 Akim Demaille <akim@epita.fr>
201
202 GCJ's parser requires the tokens to be defined before the prologue.
203
204 * data/bison.simple: Output the token definition before the user's
205 prologue.
206 * tests/regression.at (Braces parsing, Duplicate string)
207 (Mixing %token styles): Check the output from bison.
208 (Early token definitions): New.
209
5e424082
AD
2102002-06-10 Akim Demaille <akim@epita.fr>
211
212 * src/symtab.c (symbol_user_token_number_set): Don't complain when
213 assigning twice the same user number to a token, so that we can
214 use it in...
215 * src/lex.c (lex): here.
216 Also use `symbol_class_set' instead of hand written code.
217 * src/reader.c (parse_assoc_decl): Likewise.
218
44536b35
AD
2192002-06-10 Akim Demaille <akim@epita.fr>
220
221 * src/symtab.c, src/symtab.c (symbol_class_set)
222 (symbol_user_token_number_set): New.
223 * src/reader.c (parse_token_decl): Use them.
224 Use a switch instead of ifs.
225 Use a single argument.
226
8b9f2372
AD
2272002-06-10 Akim Demaille <akim@epita.fr>
228
229 Remove `%thong' support as it is undocumented, unused, duplicates
230 `%token's job, and creates useless e-mail traffic with people who
231 want to know what it is, why it is undocumented, unused, and
232 duplicates `%token's job.
233
234 * src/reader.c (parse_thong_decl): Remove.
235 * src/options.c (option_table): Remove "thong".
236 * src/lex.h (tok_thong): Remove.
237
3ae2b51f
AD
2382002-06-10 Akim Demaille <akim@epita.fr>
239
240 * src/symtab.c, src/symtab.c (symbol_type_set)
241 (symbol_precedence_set): New.
242 * src/reader.c (parse_type_decl, parse_assoc_decl): Use them.
243 (value_components_used): Remove, unused.
244
2f1afb73
AD
2452002-06-09 Akim Demaille <akim@epita.fr>
246
247 Move symbols handling code out of the reader.
248
249 * src/reader.h, src/reader.c (errtoken, undeftoken, eoftoken)
250 (axiom): Move to...
251 * src/symtab.h, src/symtab.c: here.
252
253 * src/gram.c (start_symbol): Remove: use startsymbol->number.
254 * src/reader.c (startval): Rename as...
255 * src/symtab.h, src/symtab.c (startsymbol): this.
256 * src/reader.c: Adjust.
257
258 * src/reader.c (symbol_check_defined, symbol_make_alias)
259 (symbol_check_alias_consistence, symbol_pack, symbol_translation)
260 (token_translations_init)
261 Move to...
262 * src/symtab.c: here.
263 * src/reader.c (packsymbols): Move to...
264 * src/symtab.h, src/symtab.c (symbols_pack): here.
265 * src/symtab.h, src/symtab.c (symbol_make_alias): Takes SYMVAL as
266 argument.
267
e9bca3ad
AD
2682002-06-03 Akim Demaille <akim@epita.fr>
269
270 * src/muscle_tab.c (muscle_insert, muscle_find): Declarations,
271 then statements.
272
86eff183
AD
2732002-06-03 Akim Demaille <akim@epita.fr>
274
275 * src/muscle_tab.c (muscle_find, muscle_insert): Don't initialize
276 structs with non literals.
277 * src/scan-skel.l: never-interactive.
278 * src/conflicts.c (enum conflict_resolution_e): No trailing
279 comma.
280 * src/getargs.c (usage): Split long literal strings.
281 Reported by Hans Aberg.
282
717be197
AD
2832002-05-28 Akim Demaille <akim@epita.fr>
284
285 * data/bison.c++: Use C++ ostreams.
286 (cdebug_): New member.
287
670ddffd
AD
2882002-05-28 Akim Demaille <akim@epita.fr>
289
290 * src/output.c (output_skeleton): Be sure to allocate enough room
291 for `/' _and_ for `\0' in full_skeleton.
292
769b430f
AD
2932002-05-28 Akim Demaille <akim@epita.fr>
294
295 * data/bison.c++: Catch up with bison.simple:
296 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
297 and Paul Eggert <eggert@twinsun.com>: `error' handing.
298 2002-05-26 Akim Demaille <akim@epita.fr>: stos_, token_number_,
299 and popping traces.
300
7067cb36
PH
3012002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
302
303 * src/output.c (output_skeleton): Put an explicit path in front of
304 the skeleton file name, rather than relying on the -I directory,
305 to partially alleviate effects of having a skeleton file lying around
306 in the current directory.
769b430f 307
4a713ec2
PH
3082002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
309
769b430f 310 * src/conflicts.c (log_resolution): Correct typo:
4a713ec2
PH
311 obstack_printf should be obstack_fgrow1.
312
b408954b
AD
3132002-05-26 Akim Demaille <akim@epita.fr>
314
315 * src/state.h (state_t): `solved_conflicts' is a new member.
316 * src/LR0.c (new_state): Set it to 0.
317 * src/conflicts.h, src/conflicts.c (print_conflicts)
318 (free_conflicts, solve_conflicts): Rename as...
319 (conflicts_print, conflicts_free, conflicts_solve): these.
320 Adjust callers.
321 * src/conflicts.c (enum conflict_resolution_e)
322 (solved_conflicts_obstack): New, used by...
323 (log_resolution): this.
324 Adjust to attach the conflict resolution to each state.
325 Complete the description with the precedence/associativity
326 information.
327 (resolve_sr_conflict): Adjust.
328 * src/print.c (print_state): Output its solved_conflicts.
329 * tests/conflicts.at (Unresolved SR Conflicts)
330 (Solved SR Conflicts): Exercise --report=all.
331
a49aecd5
AD
3322002-05-26 Akim Demaille <akim@epita.fr>
333
334 * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c,
335 * src/nullable.c, src/output.c, src/print.c, src/print_graph.c,
336 * src/reader.c, src/reduce.c, src/state.h, src/symtab.h
337 (token_number_t, item_number_as_token_number)
338 (token_number_as_item_number, muscle_insert_token_number_table):
339 Rename as...
340 (symbol_number_t, item_number_as_symbol_number)
341 (symbol_number_as_item_number, muscle_insert_symbol_number_table):
342 these, since it is more appropriate.
343
5504898e
AD
3442002-05-26 Akim Demaille <akim@epita.fr>
345
346 * tests/calc.at (AT_CHECK_CALC): Adjust: there are now additional
347 `Error:' lines.
348 * data/bison.simple (yystos) [YYDEBUG]: New.
349 (yyparse) [YYDEBUG]: Display the symbols which are popped during
350 error recovery.
351 * tests/regression.at (Web2c Actions): Adjust: yystos is output now.
352
ec3bc396
AD
3532002-05-25 Akim Demaille <akim@epita.fr>
354
355 * doc/bison.texinfo (Debugging): Split into...
356 (Tracing): this new section, its former contents, and...
357 (Understanding): this new section.
358 * src/getargs.h, src/getargs.c (verbose_flag): Remove, replaced
359 by...
360 (report_flag): this.
361 Adjust all dependencies.
362 (report_args, report_types, report_argmatch): New.
363 (usage, getargs): Report/support -r, --report.
364 * src/options.h
365 (struct option_table_struct): Rename as..,
366 (struct option_table_s): this.
367 Rename the `set_flag' member to `flag' to match with getopt_long's
368 struct.
369 * src/options.c (option_table): Split verbose into an entry for
370 %verbose, and another for --verbose.
371 Support --report/-r, so remove -r from the obsolete --raw.
372 * src/print.c: Attach full item sets and lookaheads reports to
373 report_flag instead of trace_flag.
374 * lib/argmatch.h, lib/argmatch.c: New, from Fileutils 4.1.
375
78df8250
PE
3762002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
377 and Paul Eggert <eggert@twinsun.com>
769b430f 378
78df8250
PE
379 * data/bison.simple (yyparse): Correct error handling to conform to
380 POSIX and yacc. Specifically, after syntax error is discovered,
381 do not reduce further before shifting the error token.
382 Clean up the code a bit by removing the labels yyerrdefault,
383 yyerrhandle, yyerrpop.
384 * NEWS: Document the above.
385
c0c9ea05
PH
3862002-05-20 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
387
388 * data/bison.simple (yyr1): Don't use yy_token_number_type as element
389 type; it isn't always big enough, since it doesn't necessarily
390 include non-terminals.
769b430f 391 (yytranslate): Expand definition of yy_token_number_type, so that
c0c9ea05
PH
392 the latter can be removed.
393 (yy_token_number_type): Remove, only one use.
394 * data/bison.c++ (r1_): Parallel change to yyr1 in bison.simple---
395 don't use TokenNumberType as element type.
769b430f 396
c0c9ea05
PH
397 * tests/regression.at: Modify expected output to agree with change
398 to yyr1 and yytranslate.
769b430f 399
6390a83f
FK
4002002-05-13 Florian Krohm <florian@edamail.fishkill.ibm.com>
401
402 * src/reader.c (parse_action): Use copy_character instead of
403 obstack_1grow.
404
db7c8e9a
AD
4052002-05-13 Akim Demaille <akim@epita.fr>
406
407 * tests/regression.at (Token definitions): Prototype yylex and
408 yyerror.
409
fcc61800
PH
4102002-05-12 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU>
411
158c687b 412 * src/scan-skel.l: Correct off-by-one error in handling of __oline__.
fcc61800
PH
413 * data/bison.simple (b4_sint_type, b4_uint_type): Correct to reflect
414 32-bit arithmetic.
415 * data/bison.c++ (b4_sint_type, b4_uint_type): Ditto.
416
5683e9b2
AD
4172002-05-07 Akim Demaille <akim@epita.fr>
418
419 * tests/synclines.at: Be sure to prototype yylex and yyerror to
420 avoid GCC warnings.
421
0c2d3f4c
AD
4222002-05-07 Akim Demaille <akim@epita.fr>
423
424 Kill GCC warnings.
425
426 * src/reduce.c (nonterminals_reduce): Don't loop over RITEM: loop
427 over the RHS of each rule.
428 * src/gram.h, src/gram.c (nritems): Is `unsigned int', not int.
429 * src/state.h (state_t): Member `nitems' is unsigned short.
430 * src/LR0.c (get_state): Adjust.
431 * src/reader.c (packgram): Likewise.
432 * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): `max' is of type
433 `Type'.
434 (muscle_insert_int_table): Remove, unused.
435 (prepare_rules): Remove `max'.
436
1565b720
AD
4372002-05-06 Akim Demaille <akim@epita.fr>
438
439 * src/closure.c (print_firsts): Display of the symbol tags.
440 (bitmatrix_print): Move to...
441 * lib/bitsetv-print.h, lib/bitsetv-print.c (bitsetv_matrix_dump):
442 here.
443 * tests/sets.at (Nullable, Broken Closure, Firsts): Adjust.
444
cfaee611
AD
4452002-05-06 Akim Demaille <akim@epita.fr>
446
447 * src/muscle_tab.c (muscle_m4_output): Must return TRUE for
448 hash_do_for_each.
449
458be8e0
AD
4502002-05-06 Akim Demaille <akim@epita.fr>
451
452 * src/LR0.c (new_state, get_state): Instead of using the global
453 `kernel_size' and `kernel_base', have two new arguments:
454 `core_size' and `core'.
455 Adjust callers.
456
a900a624
AD
4572002-05-06 Akim Demaille <akim@epita.fr>
458
459 * src/reader.c (packgram): No longer end `ritem' with a 0
460 sentinel: it is not used.
461
d4e7d3a1
AD
4622002-05-05 Akim Demaille <akim@epita.fr>
463
464 New experimental feature: display the lookaheads in the report and
465 graph.
466
467 * src/print (print_core): When --trace-flag, display the rules
468 lookaheads.
469 * src/print_graph.c (print_core): Likewise.
470 Swap the arguments.
471 Adjust caller.
472
39ceb25b
AD
4732002-05-05 Akim Demaille <akim@epita.fr>
474
475 * tests/torture.at (Many lookaheads): New test.
476
5372019f
AD
4772002-05-05 Akim Demaille <akim@epita.fr>
478
479 * src/output.c (GENERATE_OUTPUT_TABLE): Replace with...
480 (GENERATE_MUSCLE_INSERT_TABLE): this.
481 (output_int_table, output_unsigned_int_table, output_short_table)
482 (output_token_number_table, output_item_number_table): Replace with...
483 (muscle_insert_int_table, muscle_insert_unsigned_int_table)
484 (muscle_insert_short_table, muscle_insert_token_number_table)
485 (muscle_insert_item_number_table): these.
486 Adjust all callers.
487 (prepare_tokens): Don't free `translations', since...
488 * src/reader.h, src/reader.c (grammar_free): do it.
489 Move to...
490 * src/gram.h, src/gram.c (grammar_free): here.
491 * data/bison.simple, data/bison.c++: b4_token_number_max is now
492 b4_translate_max.
493
5df5f6d5
AD
4942002-05-05 Akim Demaille <akim@epita.fr>
495
496 * src/output.c (output_unsigned_int_table): New.
497 (prepare_rules): `i' is unsigned.
498 `prhs', `rline', `r2' are unsigned int.
499 Rename muscle `rhs_number_max' as `rhs_max'.
500 Output muscles `prhs_max', `rline_max', and `r2_max'.
501 Free rline and r1.
502 * data/bison.simple, data/bison.c++: Adjust to use these muscles
503 to compute types instead of constant types.
504 * tests/regression.at (Web2c Actions): Adjust.
505
b87f8b21
AD
5062002-05-04 Akim Demaille <akim@epita.fr>
507
508 * src/symtab.h (SALIAS, SUNDEF): Rename as...
509 (USER_NUMBER_ALIAS, USER_NUMBER_UNDEFINED): these.
510 Adjust dependencies.
511 * src/output.c (token_definitions_output): Be sure not to output a
512 `#define 'a'' when fed with `%token 'a' "a"'.
513 * tests/regression.at (Token definitions): New.
514
8bb936e4
PE
5152002-05-03 Paul Eggert <eggert@twinsun.com>
516
517 * data/bison.simple (b4_token_defines): Also define YYTOKENTYPE
518 for K&R C.
519
5202002-05-03 gettextize <bug-gnu-gettext@gnu.org>
521
522 * Makefile.am (SUBDIRS): Remove intl.
523 (EXTRA_DIST): Add config/config.rpath.
524
53c71a12
AD
5252002-05-03 Akim Demaille <akim@epita.fr>
526
527 * data/bison.simple (m4_if): Don't output empty enums.
528 And actually, output valid enum definitions :(.
529
289dd0cf
AD
5302002-05-03 Akim Demaille <akim@epita.fr>
531
532 * configure.bat: Remove, completely obsolete.
533 * Makefile.am (EXTRA_DIST): Adjust.
534 Don't distribute config.rpath...
535 * config/Makefile.am (EXTRA_DIST): Do it.
536
db85e524
AD
5372002-05-03 Akim Demaille <akim@epita.fr>
538
539 * configure.in (GETTEXT_VERSION): New.
540 Suggested by Bruno Haible for the forthcoming Gettext 0.10.3.
541
83ccf991
AD
5422002-05-03 Akim Demaille <akim@epita.fr>
543
544 * data/bison.simple (b4_token_enum): New.
545 (b4_token_defines): Use it to output tokens both as #define and
546 enums.
547 Suggested by Paul Eggert.
548 * src/output.c (token_definitions_output): Don't output spurious
549 white spaces.
550
1f418995
AD
5512002-05-03 Akim Demaille <akim@epita.fr>
552
553 * data/m4sugar/m4sugar.m4: Update from CVS Autoconf.
554
45119f04
RA
5552002-05-02 Robert Anisko <robert@lrde.epita.fr>
556
557 * data/bison.c++: Adapt expansion of $s and @s to the C++ parser.
558 Update the stack class, give a try to deque as the default container.
559
b2d52318
AD
5602002-05-02 Akim Demaille <akim@epita.fr>
561
562 * data/bison.simple (yyparse): Do not implement @$ = @1.
563 (YYLLOC_DEFAULT): Adjust to do it.
564 * doc/bison.texinfo (Location Default Action): Fix.
565
3a8b4109
AD
5662002-05-02 Akim Demaille <akim@epita.fr>
567
568 * src/reader.c (parse_braces): Merge into...
569 (parse_action): this.
570
84614e13
AD
5712002-05-02 Akim Demaille <akim@epita.fr>
572
573 * configure.in (ALL_LINGUAS): Remove.
574 * po/LINGUAS, hr.po: New.
575
fdbcd8e2
AD
5762002-05-02 Akim Demaille <akim@epita.fr>
577
578 Remove the so called hairy (semantic) parsers.
579
580 * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove.
581 * src/gram.h, src/gram.c (semantic_parser): Remove.
582 (rule_t): Remove the guard and guard_line members.
583 * src/lex.h (token_t): remove tok_guard.
584 * src/options.c (option_table): Remove %guard and %semantic_parser
585 support.
586 * src/output.c, src/output.h (guards_output): Remove.
587 (prepare): Adjust.
588 (token_definitions_output): Don't output the `T'
589 tokens (???).
590 (output_skeleton): Don't output the guards.
591 * src/files.c, src/files.c (attrsfile): Remove.
592 * src/reader.c (symbol_list): Remove the guard and guard_line
593 members.
594 Adjust dependencies.
595 (parse_guard): Remove.
596 * data/bison.hairy: Remove.
597 * doc/bison.texinfo (Environment Variables): Remove occurrences of
598 BISON_HAIRY.
599
82b6cb3f
AD
6002002-05-02 Akim Demaille <akim@epita.fr>
601
602 * src/reader.c (copy_at, copy_dollarm parse_braces, parse_action)
603 (parse_guard): Rename the formal argument `stack_offset' as
604 `rule_length', which is more readable.
605 Adjust callers.
606 (copy_at, copy_dollar): Instead of outputting the hard coded
607 values of $$, $n and so forth, output invocation to b4_lhs_value,
608 b4_lhs_location, b4_rhs_value, and b4_rhs_location.
900c877b
AD
609 Note: this patch partially drops `semantic-parser' support: it
610 always does `rule_length - n', where semantic parsers ought to
611 always use `-n'.
82b6cb3f
AD
612 * data/bison.simple, data/bison.c++ (b4_lhs_value)
613 (b4_lhs_location, b4_rhs_value, and b4_rhs_location: New.
614
6cbfbcc5
AD
6152002-05-02 Akim Demaille <akim@epita.fr>
616
617 * configure.in (AC_INIT): Bump to 1.49b.
618 (AM_INIT_AUTOMAKE): Short invocation.
619
b8548114
AD
6202002-05-02 Akim Demaille <akim@epita.fr>
621
622 Version 1.49a.
623
c20cd1fa
AD
6242002-05-01 Akim Demaille <akim@epita.fr>
625
626 * src/skeleton.h: Remove.
627
8a9566d4
AD
6282002-05-01 Akim Demaille <akim@epita.fr>
629
630 * src/skeleton.h: Fix the #endif.
631 Reported by Magnus Fromreide.
632
8c6d399a
PE
6332002-04-26 Paul Eggert <eggert@twinsun.com>
634
635 * data/bison.simple (YYSTYPE_IS_TRIVIAL, YYLTYPE_IS_TRIVIAL):
636 Define if we define YYSTYPE and YYLTYPE, respectively.
b756bb75 637 (YYCOPY): Fix [] quoting problem in the non-GCC case.
8a9566d4 638
2b7ed18a
RA
6392002-04-25 Robert Anisko <robert@lrde.epita.fr>
640
641 * src/scan-skel.l: Postprocess quadrigraphs.
642
643 * src/reader.c (copy_character): New function, used to output
644 single characters while replacing `[' and `]' with quadrigraphs, to
645 avoid troubles with M4 quotes.
646 (copy_comment): Output characters with copy_character.
647 (read_additionnal_code): Likewise.
648 (copy_string2): Likewise.
649 (copy_definition): Likewise.
650
651 * tests/calc.at: Exercise M4 quoting.
652
34a89c50
AD
6532002-04-25 Akim Demaille <akim@epita.fr>
654
655 * tests/sets.at (AT_EXTRACT_SETS): Sed portability issue: no space
656 between `!' and the command.
657 Reported by Paul Eggert.
658
0dd1580a
RA
6592002-04-24 Robert Anisko <robert@lrde.epita.fr>
660
661 * tests/calc.at: Exercise prologue splitting.
662
663 * data/bison.simple, data/bison.c++: Use `b4_pre_prologue' and
664 `b4_post_prologue' instead of `b4_prologue'.
665
666 * src/output.c (prepare): Add the `pre_prologue' and `post_prologue'
667 muscles.
668 (output): Free pre_prologue_obstack and post_prologue_obstack.
669 * src/files.h, src/files.c (attrs_obstack): Remove.
670 (pre_prologue_obstack, post_prologue_obstack): New.
671 * src/reader.c (copy_definition): Add a parameter to specify the
672 obstack to fill, instead of using attrs_obstack unconditionally.
673 (read_declarations): Pass pre_prologue_obstack to copy_definition if
674 `%union' has not yet been seen, pass post_prologue_obstack otherwise.
675
83c1796f
PE
6762002-04-23 Paul Eggert <eggert@twinsun.com>
677
678 * data/bison.simple: Remove unnecessary commentary and white
679 space differences from 1_29-branch.
680 Depend on YYERROR_VERBOSE, not defined (YYERROR_VERBOSE).
681
682 (union yyalloc, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYCOPY,
683 YYSTACK_RELOCATE): Do not define if yyoverflow is defined, or
684 if this is a C++ parser and YYSTYPE or YYLTYPE has nontrivial
685 constructors or destructors.
686
687 (yyparse) [! defined YYSTACK_RELOCATE]: Do not relocate the stack.
688
1207eeac
AD
6892002-04-23 Akim Demaille <akim@epita.fr>
690
691 * tests/sets.at (AT_EXTRACT_SETS): Don't use 8 char long sed labels.
692 * tests/synclines.at (AT_TEST_SYNCLINE): Be robust to GCC's
693 location with columns.
694 * tests/conflicts.at (%nonassoc and eof): Don't use `error.h'.
695 All reported by Paul Eggert.
696
78ab8f67
AD
6972002-04-22 Akim Demaille <akim@epita.fr>
698
699 * src/reduce.c (dump_grammar): Move to...
700 * src/gram.h, src/gram.c (grammar_dump): here.
701 Be sure to separate long item numbers.
702 Don't read the members of a rule's prec if its nil.
703
133c20e2
AD
7042002-04-22 Akim Demaille <akim@epita.fr>
705
706 * src/output.c (table_size, table_grow): New.
707 (MAXTABLE): Remove, replace uses with table_size.
708 (pack_vector): Instead of dying when the table is too big, grow it.
709
9515e8a7
AD
7102002-04-22 Akim Demaille <akim@epita.fr>
711
712 * data/bison.simple (yyr1): Its type is that of a token number.
713 * data/bison.c++ (r1_): Likewise.
714 * tests/regression.at (Web2c Actions): Adjust.
715
23c5a174
AD
7162002-04-22 Akim Demaille <akim@epita.fr>
717
718 * src/reader.c (token_translations_init): 256 is now the default
719 value for the error token, i.e., it will be assigned another
720 number if the user assigned 256 to one of her tokens.
721 (reader): Don't force 256 to error.
722 * doc/bison.texinfo (Symbols): Adjust.
723 * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR)
724 (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3
725 etc. instead of 10, 20, 30 (which was used to `jump' over error
726 (256) and undefined (2)).
727
5fbb0954
AD
7282002-04-22 Akim Demaille <akim@epita.fr>
729
730 Propagate more token_number_t.
731
732 * src/gram.h (token_number_as_item_number)
733 (item_number_as_token_number): New.
734 * src/output.c (GENERATE_OUTPUT_TABLE): New.
735 Use it to create output_item_number_table and
736 output_token_number_table.
737 * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c,
738 * src/lex.c, src/nullable.c, src/output.c, src/print.c,
739 * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h,
740 * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts.
741
4f940944
AD
7422002-04-22 Akim Demaille <akim@epita.fr>
743
744 * src/output.h, src/output.c (get_lines_number): Remove.
745
3ded9a63
AD
7462002-04-19 Akim Demaille <akim@epita.fr>
747
748 * doc/bison.texinfo (Actions): Make clear that `|' is not the same
749 as Lex/Flex'.
750 (Debugging): More details about enabling the debugging features.
751 (Table of Symbols): Describe $$, $n, @$, and @n.
752 Suggested by Tim Josling.
753
e0c471a9
AD
7542002-04-19 Akim Demaille <akim@epita.fr>
755
756 * doc/bison.texinfo: Remove the uses of the obsolete @refill.
757
fecc10cd
AD
7582002-04-10 Akim Demaille <akim@epita.fr>
759
760 * src/system.h: Rely on HAVE_LIMITS_H.
761 Suggested by Paul Eggert.
762
51dec47b
AD
7632002-04-09 Akim Demaille <akim@epita.fr>
764
765 * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the
766 full stderr, and strip it according to the bison options, instead
767 of composing the error message from different bits.
768 This makes it easier to check for several error messages.
769 Adjust all the invocations.
770 Add an invocation exercising the error token.
771 Add an invocation demonstrating a stupid error message.
772 (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0.
773 Adjust the tests.
774 Error message are for stderr, not stdout.
775
007a50a4
AD
7762002-04-09 Akim Demaille <akim@epita.fr>
777
778 * src/gram.h, src/gram.c (error_token_number): Remove, use
779 errtoken->number.
780 * src/reader.c (reader): Don't specify the user token number (2)
781 for $undefined, as it uselessly prevents using it.
782 * src/gram.h (token_number_t): Move to...
783 * src/symtab.h: here.
784 (state_t.number): Is a token_number_t.
785 * src/print.c, src/reader.c: Use undeftoken->number instead of
786 hard coded 2.
787 (Even though this 2 is not the same as above: the number of the
788 undeftoken remains being 2, it is its user token number which
789 might not be 2).
790 * src/output.c (prepare_tokens): Rename the `maxtok' muscle with
791 `user_token_number_max'.
792 Output `undef_token_number'.
793 * data/bison.simple, data/bison.c++: Use them.
794 Be sure to map invalid yylex return values to
795 `undef_token_number'. This saves us from gratuitous SEGV.
796
797 * tests/conflicts.at (Solved SR Conflicts)
798 (Unresolved SR Conflicts): Adjust.
799 * tests/regression.at (Web2c Actions): Adjust.
800
06446ccf
AD
8012002-04-08 Akim Demaille <akim@epita.fr>
802
803 * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/.
804 Adding #line.
805 Remove the duplicate `typedefs'.
806 (RhsNumberType): Fix the declaration and various other typos.
807 Use __ofile__.
808 * data/bison.simple: Use __ofile__.
809 * src/scan-skel.l: Handle __ofile__.
810
62a3e4f0
AD
8112002-04-08 Akim Demaille <akim@epita.fr>
812
813 * src/gram.h (item_number_t): New, the type of item numbers in
814 RITEM. Note that it must be able to code symbol numbers as
815 positive number, and the negation of rule numbers as negative
816 numbers.
817 Adjust all dependencies (pretty many).
818 * src/reduce.c (rule): Remove this `short *' pointer: use
819 item_number_t.
820 * src/system.h (MINSHORT, MAXSHORT): Remove.
821 Include `limits.h'.
822 Adjust dependencies to using SHRT_MAX and SHRT_MIN.
823 (shortcpy): Remove.
824 (MAXTABLE): Move to...
825 * src/output.c (MAXTABLE): here.
826 (prepare_rules): Use output_int_table to output rhs.
827 * data/bison.simple, data/bison.c++: Adjust.
828 * tests/torture.at (Big triangle): Move the limit from 254 to
829 500.
830 * tests/regression.at (Web2c Actions): Ajust.
831
832 Trying with bigger grammars shows various phenomena: at 3000 (28Mb
833 of grammar file) bison is killed by my system, at 2000 (12Mb) bison
834 passes, but produces negative #line number, once fixed, GCC is
835 killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of
836 C), it passes.
837 * src/state.h (state_h): Code input lines on ints, not shorts.
838
bb88b0fc
AD
8392002-04-08 Akim Demaille <akim@epita.fr>
840
841 * src/reduce.c (reduce_grammar): First reduce the nonterminals,
842 and then the grammar.
843
9a636f47
AD
8442002-04-08 Akim Demaille <akim@epita.fr>
845
846 * src/system.h: No longer using strndup.
847
680e8701
AD
8482002-04-07 Akim Demaille <akim@epita.fr>
849
850 * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New.
851 * src/output.c (output_table_data): Return the longest number.
852 (prepare_tokens): Output `token_number_max').
853 * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type):
854 New.
855 Use them to define yy_token_number_type/TokenNumberType.
856 Use this type for yytranslate.
857 * tests/torture.at (Big triangle): Push the limit from 124 to
858 253.
859 * tests/regression.at (Web2c Actions): Adjust.
860
817e9f41
AD
8612002-04-07 Akim Demaille <akim@epita.fr>
862
863 * tests/torture.at (Big triangle): New.
864 (GNU AWK Grammar, GNU Cim Grammar): Move to...
865 * tests/existing.at: here.
866
5123689b
AD
8672002-04-07 Akim Demaille <akim@epita.fr>
868
869 * src/gram.h, src/gram.c (nitems): Remove, it is an alias of
870 nritems.
871 Adjust dependencies.
872
f3849179
AD
8732002-04-07 Akim Demaille <akim@epita.fr>
874
875 * src/reader.c: Normalize increments to prefix form.
876
bd02036a
AD
8772002-04-07 Akim Demaille <akim@epita.fr>
878
879 * src/reader.c, symtab.c: Remove debugging code.
880
db8837cb
AD
8812002-04-07 Akim Demaille <akim@epita.fr>
882
883 Rename all the `bucket's as `symbol_t'.
884
885 * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c,
886 * src/reader.c, src/reader.h, src/reduce.c, src/state.h,
887 * src/symtab.c, src/symtab.h (bucket): Rename as...
888 (symbol_t): this.
889 (symbol_list_new, bucket_check_defined, bucket_make_alias)
890 (bucket_check_alias_consistence, bucket_pack, bucket_translation)
891 (bucket_new, bucket_free, hash_compare_bucket, hash_bucket)
892 (buckets_new, buckets_free, buckets_do): Rename as...
893 (symbol_list_new, symbol_check_defined, symbol_make_alias)
894 (symbol_check_alias_consistence, symbol_pack, symbol_translation)
895 (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t)
896 (symbols_new, symbols_free, symbols_do): these.
897
72a23c97
AD
8982002-04-07 Akim Demaille <akim@epita.fr>
899
900 Use lib/hash for the symbol table.
901
902 * src/gram.c (ntokens): Initialize to 1, to reserve a slot for
903 EOF.
904 * src/lex.c (lex): Set the `number' member of new terminals.
905 * src/reader.c (bucket_check_defined, bucket_make_alias)
906 (bucket_check_alias_consistence, bucket_translation): New.
907 (reader, grammar_free, readgram, token_translations_init)
908 (packsymbols): Adjust.
909 (reader): Number the predefined tokens.
910 * src/reduce.c (inaccessable_symbols): Just use hard coded numbers
911 for predefined tokens.
912 * src/symtab.h (bucket): Remove all the hash table related
913 members.
914 * src/symtab.c (symtab): Replace by...
915 (bucket_table): this.
916 (bucket_new, bucket_free, hash_compare_bucket, hash_bucket)
917 (buckets_new, buckets_do): New.
918
280a38c3
AD
9192002-04-07 Akim Demaille <akim@epita.fr>
920
921 * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems)
922 (start_symbol, max_user_token_number, semantic_parser)
923 (error_token_number): Initialize.
924 * src/reader.c (grammar, start_flag, startval, typed, lastprec):
925 Initialize.
926 (reader): Don't.
927 (errtoken, eoftoken, undeftoken, axiom): Extern.
928
03b31c0c
AD
9292002-04-07 Akim Demaille <akim@epita.fr>
930
931 * src/gram.h (rule_s): prec and precsym are now pointers
932 to the bucket giving the priority/associativity.
933 Member `associativity' removed: useless.
934 * src/reduce.c, src/conflicts.c: Adjust.
935
8b3df748
AD
9362002-04-07 Akim Demaille <akim@epita.fr>
937
938 * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c:
939 Properly escape the symbols' TAG when outputting them.
940
e601aa1d
AD
9412002-04-07 Akim Demaille <akim@epita.fr>
942
943 * src/lalr.h (LA): Is a bitsetv, not bitset*.
944
b0299a2e
AD
9452002-04-07 Akim Demaille <akim@epita.fr>
946
947 * src/lalr.h, src/lalr.c (LAruleno): Replace with...
948 (LArule): this, which is an array to rule_t*.
949 * src/print.c, src/conflicts.c: Adjust.
950
d7e1f00c
AD
9512002-04-07 Akim Demaille <akim@epita.fr>
952
953 * src/gram.h (rule_t): Rename `number' as `user_number'.
954 `number' is a new member.
955 Adjust dependencies.
956 * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number.
957
cc9305dd
AD
9582002-04-07 Akim Demaille <akim@epita.fr>
959
960 As a result of the previous patch, it is no longer needed
961 to reorder ritem itself.
962
963 * src/reduce.c (reduce_grammar_tables): Don't sort RITEM.
964
b0940840
AD
9652002-04-07 Akim Demaille <akim@epita.fr>
966
967 Be sure never to walk through RITEMS, but use only data related to
968 the rules themselves. RITEMS should be banished.
969
970 * src/output.c (output_token_translations): Rename as...
971 (prepare_tokens): this.
972 In addition to `translate', prepare the muscles `tname' and
973 `toknum', which were handled by...
974 (output_rule_data): this.
975 Remove, and move the remainder of its outputs into...
976 (prepare_rules): this new routines, which also merges content from
977 (output_gram): this.
978 (prepare_rules): Be sure never to walk through RITEMS.
979 (output_stos): Rename as...
980 (prepare_stos): this.
981 (output): Always invoke prepare_states, after all, just don't use it
982 in the output if you don't need it.
983
643a5994
AD
9842002-04-07 Akim Demaille <akim@epita.fr>
985
986 * src/LR0.c (new_state): Display `nstates' as the name of the
987 newly created state.
988 Adjust to initialize first_state and last_state if needed.
989 Be sure to distinguish the initial from the final state.
990 (new_states): Create the itemset of the initial state, and use
991 new_state.
992 * src/closure.c (closure): Now that the initial state has its
993 items properly set, there is no need for a special case when
994 creating `ruleset'.
995
996 As a result, now the rule 0, reducing to $axiom, is visible in the
997 outputs. Adjust the test suite.
998
999 * tests/conflicts.at (Solved SR Conflicts)
1000 (Unresolved SR Conflicts): Adjust.
1001 * tests/regression.at (Web2c Report, Rule Line Numbers): Idem.
1002 * tests/conflicts.at (S/R in initial): New.
1003
b4c4ccc2
AD
10042002-04-07 Akim Demaille <akim@epita.fr>
1005
1006 * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over
1007 the RHS of the rules.
1008 * src/output.c (output_gram): Likewise.
1009
bba97eb2
AD
10102002-04-07 Akim Demaille <akim@epita.fr>
1011
1012 * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's
1013 bucket.
1014 Adjust all dependencies.
1015 * src/reduce.c (nonterminals_reduce): Don't forget to renumber the
1016 `number' of the buckets too.
1017 * src/gram.h: Include `symtab.h'.
1018 (associativity): Move to...
1019 * src/symtab.h: here.
1020 No longer include `gram.h'.
1021
c3b407f4
AD
10222002-04-07 Akim Demaille <akim@epita.fr>
1023
1024 * src/gram.h, src/gram.c (rules_rhs_length): New.
1025 (ritem_longest_rhs): Use it.
1026 * src/gram.h (rule_t): `number' is a new member.
1027 * src/reader.c (packgram): Set it.
1028 * src/reduce.c (reduce_grammar_tables): Move the useless rules at
1029 the end of `rules', and count them out of `nrules'.
1030 (reduce_output, dump_grammar): Adjust.
1031 * src/print.c (print_grammar): It is no longer needed to check for
1032 the usefulness of a rule, as useless rules are beyond `nrules + 1'.
1033 * tests/reduce.at (Reduced Automaton): New test.
1034
11652ab3
AD
10352002-04-07 Akim Demaille <akim@epita.fr>
1036
1037 * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a
1038 lacking `+ 1' to nrules, Bison reported as useless a token if it
1039 was used solely to set the precedence of the last rule...
1040
26b23c1a
AD
10412002-04-07 Akim Demaille <akim@epita.fr>
1042
1043 * data/bison.c++, data/bison.simple: Don't output the current file
1044 name in #line, to avoid useless diffs between two identical
1045 outputs under different names.
1046
18bcecb0
AD
10472002-04-07 Akim Demaille <akim@epita.fr>
1048
1049 * src/closure.c, src/print.c, src/reader.c, src/reduce.c:
1050 Normalize loops to using `< nrules + 1', not `<= nrules'.
1051
fa770c86
AD
10522002-04-07 Akim Demaille <akim@epita.fr>
1053
1054 * TODO: Update.
1055
d9b739c3
AD
10562002-04-07 Akim Demaille <akim@epita.fr>
1057
1058 * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename
1059 bucket.value as bucket.number.
1060
99013900
AD
10612002-04-07 Akim Demaille <akim@epita.fr>
1062
1063 * src/closure.c, src/derives.c, src/gram.h, src/lalr.c,
1064 * src/nullable.c, src/output.c, src/print.c, src/print_graph.c,
1065 * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the
1066 RHS, instead of being an index in RITEMS.
1067
e966383b
PE
10682002-04-04 Paul Eggert <eggert@twinsun.com>
1069
1070 * doc/bison.texinfo: Update copyright date.
1071 (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII.
1072 (Symbols): Warn about running Bison in one character set,
1073 but compiling and/or running in an incompatible one.
1074 Warn about character code 256, too.
1075
10762002-04-03 Paul Eggert <eggert@twinsun.com>
1077
1078 * src/bison.data (YYSTACK_ALLOC): Depend on whether
1079 YYERROR_VERBOSE is nonzero, not whether it is defined.
1080
1081 Merge changes from bison-1_29-branch.
c307773e 1082
8d6c48b9
PE
10832002-03-20 Paul Eggert <eggert@twinsun.com>
1084
1085 Merge fixes from Debian bison_1.34-1.diff.
1086
1087 * configure.in (AC_PREREQ): 2.53.
1088
e53c6322
AD
10892002-03-20 Akim Demaille <akim@epita.fr>
1090
1091 * src/conflicts.c (log_resolution): Argument `resolution' is const.
1092
9ffbeca7
PE
10932002-03-19 Paul Eggert <eggert@twinsun.com>
1094
21db0b2a
PE
1095 * src/bison.simple (YYCOPY): New macro.
1096 (YYSTACK_RELOCATE): Use it.
1097 Remove Type arg; no longer needed. All callers changed.
1098 (yymemcpy): Remove; no longer needed.
1099
9ffbeca7
PE
1100 * Makefile.am (AUTOMAKE_OPTIONS): 1.6.
1101 * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove.
1102
642cb8f8
AD
11032002-03-19 Akim Demaille <akim@epita.fr>
1104
1105 Test and fix the #line outputs.
1106
1107 * tests/atlocal.at (GCC): New.
1108 * tests/synclines.at (AT_TEST_SYNCLINE): New macro.
1109 (Prologue synch line, ,%union synch line, Postprologue synch line)
1110 (Action synch line, Epilogue synch line): New tests.
1111 * src/reader.c (parse_union_decl): Define the muscle stype_line.
1112 * data/bison.simple, data/bison.c++: Use it.
1113
3c31a486
AD
11142002-03-19 Akim Demaille <akim@epita.fr>
1115
1116 * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts)
1117 (Solved SR Conflicts, %expect not enough, %expect right)
1118 (%expect too much): Move to...
1119 * tests/conflicts.at: this new file.
1120
0d8bed56
AD
11212002-03-19 Akim Demaille <akim@epita.fr>
1122
1123 * data/m4sugar/m4sugar.m4: Update from CVS Autoconf.
1124 * data/bison.simple, data/bison.c++: Handle the `#define' part, so
1125 that we can move to enums for instance.
1126 * src/output.c (token_definitions_output): Output a list of
1127 `token-name, token-number' instead of the #define.
1128 (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'.
1129
9208d17f
AD
11302002-03-14 Akim Demaille <akim@epita.fr>
1131
1132 Use Gettext 0.11.1.
1133
af27eacb
RA
11342002-03-09 Robert Anisko <robert@lrde.epita.fr>
1135
1136 * data/bison.c++: Make the user able to add members to the generated
1137 parser by subclassing.
1138
9101a310
RA
11392002-03-05 Robert Anisko <robert@lrde.epita.fr>
1140
1141 * src/reader.c (read_additionnal_code): `c' should be an integer, not
1142 a character.
1143 Reported by Nicolas Tisserand and Nicolas Burrus.
1144
fff9bf0b
RA
11452002-03-04 Robert Anisko <robert@lrde.epita.fr>
1146
1147 * src/reader.c: Warn about lacking semi-colons, do not complain.
1148
64dba31e
RA
11492002-03-04 Robert Anisko <robert@lrde.epita.fr>
1150
1151 * data/bison.c++: Remove a debug line.
1152
374f5a14
RA
11532002-03-04 Robert Anisko <robert@lrde.epita.fr>
1154
1155 * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge
1156 location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and
1157 provide a default implementation.
1158
bfcf1f3a
AD
11592002-03-04 Akim Demaille <akim@epita.fr>
1160
1161 * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'.
1162 * tests/output.at (AT_CHECK_OUTPUT): Likewise.
1163 * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto.
1164 * tests/semantic.at (Parsing Guards): Similarly.
1165 * src/reader.at (readgram): Complain if the last rule is not ended
1166 with a semi-colon.
1167
65ccf9fc
AD
11682002-03-04 Akim Demaille <akim@epita.fr>
1169
1170 * src/warshall.h, src/warshall.c (bitmatrix_print): Move to...
1171 * src/closure.c: here.
1172 (set_firsts): Use bitsetv_reflexive_transitive_closure instead of
1173 RTC.
1174 * src/warshall.h, src/warshall.c: Remove.
1175 * tests/sets.at (Broken Closure): Adjust.
1176
d0039cbc
AD
11772002-03-04 Akim Demaille <akim@epita.fr>
1178
1179 * src/output.c (output_skeleton): tempdir is const.
1180 bytes_read is unused.
1181
345cea78
AD
11822002-03-04 Akim Demaille <akim@epita.fr>
1183
1184 * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c,
1185 * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c:
1186 Update.
1187 From Michael Hayes.
1188
564801f7
AD
11892002-03-04 Akim Demaille <akim@epita.fr>
1190
1191 * src/closure.c (closure): `r' is unused.
1192
e5352bc7
AD
11932002-03-04 Akim Demaille <akim@epita.fr>
1194
1195 * tests/sets.at (Broken Closure): Add the ending `;'.
1196 * src/reader.at (readgram): Complain if a rule is not ended with a
1197 semi-colon.
1198
914feea9
AD
11992002-03-04 Akim Demaille <akim@epita.fr>
1200
1201 * src/conflicts.c (set_conflicts): Use bitset_disjoint_p.
1202 (count_sr_conflicts): Use bitset_count.
1203 * src/reduce.c (inaccessable_symbols): Ditto.
1204 (bits_size): Remove.
1205 * src/warshall.h, src/warshall.c: Convert to bitsetv.
1206
f0250de6
AD
12072002-03-04 Akim Demaille <akim@epita.fr>
1208
1209 * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c,
1210 * src/reduce.c: Remove the `bitset_zero's following the
1211 `bitset_create's, as now it is performed by the latter.
1212
ef017502
AD
12132002-03-04 Akim Demaille <akim@epita.fr>
1214
1215 * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h,
1216 * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h,
1217 * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the
1218 latest sources from Michael.
1219
76514394
AD
12202002-03-04 Akim Demaille <akim@epita.fr>
1221
1222 * src/output.c (output): Don't free the grammar.
1223 * src/reader.c (grammar_free): New.
1224 * src/main.c (main): Call it and don't free symtab here.
1225
55024580
AD
12262002-03-04 Akim Demaille <akim@epita.fr>
1227
1228 * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer
1229 before returning.
1230 Reported by Benoit Perrot.
1231
f9abaa2c
AD
12322002-03-04 Akim Demaille <akim@epita.fr>
1233
1234 Use bitset operations when possible, not loops over bits.
1235
1236 * src/conflicts.c (set_conflicts, count_sr_conflicts): Use
1237 bitset_or.
1238 * src/print.c (print_reductions): Use bitset_and, bitset_andn.
1239 * src/reduce.c (useless_nonterminals): Formatting changes.
1240 * src/warshall.c (TC): Use bitset_or.
1241
0e721e75
AD
12422002-03-04 Akim Demaille <akim@epita.fr>
1243
1244 * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused.
1245 * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET):
1246 Ditto.
1247
0fb1ffb1
AD
12482002-03-04 Akim Demaille <akim@epita.fr>
1249
1250 * src/lalr.c (F): Now a bitset*.
1251 Adjust all dependencies.
1252
b86796bf
AD
12532002-03-04 Akim Demaille <akim@epita.fr>
1254
1255 * src/conflicts.c (shiftset, lookaheadset): Now bitset.
1256 Adjust all dependencies.
1257
602bbf31
AD
12582002-03-04 Akim Demaille <akim@epita.fr>
1259
1260 * src/L0.c, src/LR0.h (nstates): Be size_t.
1261 Adjust comparisons (signed vs unsigned).
1262 * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a
1263 bitset*.
1264 Adjust all dependencies.
1265
d8a0245c
AD
12662002-03-04 Akim Demaille <akim@epita.fr>
1267
1268 * src/closure.c (firsts): Now, also a bitset.
1269 Adjust all dependencies.
1270 (varsetsize): Remove, now unused.
1271 * src/warshall.h, src/warshall.c: Now work on arrays of bitsets.
1272
34ba9743
AD
12732002-03-04 Akim Demaille <akim@epita.fr>
1274
1275 * src/print.c: Convert to use bitset.h, not hand coded iterations
1276 over ints.
1277
ed86e78c
AD
12782002-03-04 Akim Demaille <akim@epita.fr>
1279
1280 * src/reduce.c: Convert to use bitset.h, not hand coded BSet.
1281
dfdb1797
AD
12822002-03-04 Akim Demaille <akim@epita.fr>
1283
1284 * src/closure.c (ruleset): Be a bitset.
1285 (rulesetsize): Remove.
1286
7086e707
AD
12872002-03-04 Akim Demaille <akim@epita.fr>
1288
1289 * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c,
1290 * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c,
1291 * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New.
1292 * src/closure.c (fderives): Be an array of bitsets.
1293
98254360
RA
12942002-02-28 Robert Anisko <robert@lrde.epita.fr>
1295
1296 * data/bison.c++: Merge the two generated headers. Insert a copyright
1297 notice in each output file.
1298
a75c057f
AD
12992002-02-28 Akim Demaille <akim@epita.fr>
1300
1301 * data/bison.c++: Copy the prologue of bison.simple to fetch
1302 useful M4 definitions, such as b4_header_guard.
1303
06b00abc
AD
13042002-02-25 Akim Demaille <akim@epita.fr>
1305
1306 * src/getargs.c (version): Give the name of the authors, and use a
a75c057f
AD
1307 translator friendly scheme for the bgr
1308 copyright notice.
06b00abc 1309
70e7d534
AD
13102002-02-25 Akim Demaille <akim@epita.fr>
1311
1312 * src/output.c (header_output): Remove, now handled completely via
1313 M4.
1314
abe017f6
AD
13152002-02-25 Akim Demaille <akim@epita.fr>
1316
1317 * m4/m4.m4: New, from CVS Autoconf.
1318 * configure.in: Invoke it.
1319 * src/output.c (output_skeleton): Use its result instead of the
1320 hard coded name.
1321
381fb12e
AD
13222002-02-25 Akim Demaille <akim@epita.fr>
1323
1324 * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from
1325 Fileutils 4.1.5.
1326 * configure.in: Invoke UTILS_FUNC_MKSTEMP.
1327 * src/output.c (output_skeleton): Use mkstemp to create a real
1328 temporary file.
1329 Move the filling of `skeleton' and its muscle to...
1330 (prepare): here.
1331 (output): Move the definition of the prologue muscle to...
1332 (prepare): here.
1333 * src/system.h (DEFAULT_TMPDIR): New.
1334
6f38107f
PE
13352002-02-14 Paul Eggert <eggert@twinsun.com>
1336
1337 Remove the support for C++ namespace cleanliness; it was
1338 causing more problems than it was curing, since it didn't work
1339 properly on some nonstandard C++ compilers. This can wait
1340 for a proper C++ parser.
1341
1342 * NEWS: Document this.
1343 * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention
1344 of C++, as it's treated like C now.
1345 * src/bison.simple (YYSTD): Remove.
1346 (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL):
1347 Treat C++ just like Standard C instead of trying to support
1348 namespace cleanliness.
1349
80cce3da
AD
13502002-02-14 Akim Demaille <akim@epita.fr>
1351
1352 * tests/regression.at (else): Adjust to Andreas' change.
1353
842e8679
AD
13542002-02-14 Akim Demaille <akim@epita.fr>
1355
1356 * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c.
1357
4bda3f10
AD
13582002-02-13 Andreas Schwab <schwab@suse.de>
1359
1360 * src/output.c (output_rule_data): Don't output NULL, it might
1361 not be defined yet.
1362
4162fa07 13632002-02-11 Robert Anisko <robert@lrde.epita.fr>
b418ecd8 1364
4162fa07
RA
1365 * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue.
1366 (Copyright notice): Update.
b418ecd8 1367
bd16a5dc
AD
13682002-02-11 Akim Demaille <akim@epita.fr>
1369
1370 * tests/regression.at (%nonassoc and eof): Don't include
1371 nonportable headers.
1372
8d69a1a3
RA
13732002-02-08 Robert Anisko <robert@lrde.epita.fr>
1374
1375 * data/bison.c++: Correct error recovery. Make the user able to
1376 initialize the starting location.
1377
9b2d0677
AD
13782002-02-07 Akim Demaille <akim@epita.fr>
1379
1380 * tests/input.at: New.
1381
69e2658b
RA
13822002-02-07 Robert Anisko <robert@lrde.epita.fr>
1383
1384 * data/bison.c++: Replace some direct m4 expansions by constants. Be
9b2d0677 1385 more consistent when naming methods and variables. Put preprocessor
69e2658b
RA
1386 directives around tables only needed for debugging.
1387
4aacc3a7
RA
13882002-02-07 Robert Anisko <robert@lrde.epita.fr>
1389
1390 * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in
1391 C++ parsers.
1392 (yy::b4_name::parse): Use print_.
1393
762a801e
RA
13942002-02-07 Robert Anisko <robert@lrde.epita.fr>
1395
1396 * data/bison.c++ (yy::b4_name::parse): Error recovery is back.
1397
4bb2bc3f
RA
13982002-02-07 Robert Anisko <robert@lrde.epita.fr>
1399
1400 * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in
1401 C++ parsers.
1402 (yy::b4_name::parse): Build verbose error messages, and use error_.
1403
6b45a3ca
RA
14042002-02-06 Robert Anisko <robert@lrde.epita.fr>
1405
1406 * data/bison.c++: Fix m4 quoting in comments.
1407
50997c6e
RA
14082002-02-06 Robert Anisko <robert@lrde.epita.fr>
1409
1410 * data/bison.c++: Adjust the parser code. Fix some muscles that were
1411 not expanded by m4.
1412
3f3eed27
AD
14132002-02-05 Akim Demaille <akim@epita.fr>
1414
1415 * data/bison.c++: Adjust to the M4 back end.
1416 More is certainly needed.
1417
be2a1a68
AD
14182002-02-05 Akim Demaille <akim@epita.fr>
1419
1420 Give a try to M4 as a back end.
1421
1422 * lib/readpipe.c: New, from wdiff.
1423 * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and
1424 BISON_HAIRY.
1425 * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS
1426 specific values. Now it is m4 that performs the lookup.
1427 * src/parse-skel.y: Remove.
1428 * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New.
1429 * src/output.c (actions_output, guards_output)
1430 (token_definitions_output): No longer keeps track of the output
1431 line number, hence remove the second argument.
1432 (guards_output): Check against the guard member of a rule, not the
1433 action member.
1434 Adjust callers.
1435 (output_skeleton): Don't look for the skeleton location, let m4 do
1436 that.
1437 Create `/tmp/muscles.m4'. This is temporary, a proper temporary
1438 file will be used.
1439 Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton.
1440 (prepare): Given that for the time being changesyntax is not
1441 usable in M4, rename the muscles using `-' to `_'.
1442 Define `defines_flag', `output_parser_name' and `output_header_name'.
1443 * src/output.h (actions_output, guards_output)
1444 (token_definitions_output): Adjust prototypes.
1445 * src/scan-skel.l: Instead of scanning the skeletons, it now
1446 processes the output of m4: `__oline__' and `#output'.
1447 * data/bison.simple: Adjust to be used by M4(sugar).
1448 * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up
1449 to date.
1450 * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR'
1451 instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'.
1452 * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New,
1453 shamelessly stolen from CVS Autoconf.
1454
beda758b
AD
14552002-02-05 Akim Demaille <akim@epita.fr>
1456
1457 * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version.
1458 * configure.in: Check for the declarations of free and malloc.
1459 * src/muscle_tab.c: Adjust.
1460
5ece6d43
AD
14612002-02-05 Akim Demaille <akim@epita.fr>
1462
1463 * src/muscle_tab.c (muscle_init): Don't default to NULL muscle
1464 which have no values.
1465
5bb18f9a
AD
14662002-02-05 Akim Demaille <akim@epita.fr>
1467
1468 * src/bison.simple, src/bison.hairy, src/bison.c++: Move to...
1469 * data/: here.
1470
894dd62e
PE
14712002-01-29 Paul Eggert <eggert@twinsun.com>
1472
1473 * src/bison.simple (YYSIZE_T): Do not define merely because
1474 YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined.
1475 On some platforms, <alloca.h> does not declare YYSTD (size_t).
1476
82841af7
AD
14772002-01-27 Akim Demaille <akim@epita.fr>
1478
1479 Fix `%nonassoc and eof'.
1480
1481 * src/state.c (errs_dup): Aaaah! The failure was due to bytes
1482 which were not properly copied! Replace
1483 memcpy (res->errs, src->errs, src->nerrs);
1484 with
1485 memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0]));
1486 !!!
1487 * tests/regression.at (%nonassoc and eof): Adjust to newest
1488 Autotest: `.' is not in the PATH.
1489
318b76e9
AD
14902002-01-27 Akim Demaille <akim@epita.fr>
1491
1492 * tests/sets.at (AT_EXTRACT_SETS): New.
1493 (Nullable): Use it.
1494 (Firsts): New.
1495
30d2f3d5
AD
14962002-01-26 Akim Demaille <akim@epita.fr>
1497
1498 * tests/actions.at, tests/calc.at, tests/headers.at,
1499 * tests/torture.at: Adjust to the newest Autotest which no longer
1500 forces `.' in the PATH.
1501
30f8c395
AD
15022002-01-25 Akim Demaille <akim@epita.fr>
1503
1504 * tests/regression.at (%nonassoc and eof): New.
1505 Suggested by Robert Anisko.
1506
29ae55f1
AD
15072002-01-24 Akim Demaille <akim@epita.fr>
1508
1509 Bison dumps core when trying to complain about broken input files.
1510 Reported by Cris van Pelt.
1511
1512 * src/lex.c (parse_percent_token): Be sure to set token_buffer.
1513 * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge
1514 into...
1515 (Invalid inputs): Strengthen: exercise parse_percent_token.
1516
2b548aa6
RA
15172002-01-24 Robert Anisko <robert.anisko@epita.fr>
1518
1519 * src/Makefile.am: Add bison.c++.
1520 * src/bison.c++: New skeleton.
1521
bb0146c2
AD
15222002-01-21 Paolo Bonzini <bonzini@gnu.org>
1523
1524 * po/it.po: New.
1525
bec30531
AD
15262002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net>
1527
1528 * src/files.c (skeleton_find) [MSDOS]: Fix cp definition.
1529
fc6edc45
MA
15302002-01-20 Marc Autret <marc@gnu.org>
1531
1532 * src/files.c (compute_output_file_names): Fix
1533
5e5d5415
MA
15342002-01-20 Marc Autret <marc@gnu.org>
1535
1536 * tests/output.at: New test.
1537 * src/files.c (compute_base_names): Don't map extensions when
1538 the YACC flag is set, use defaults.
1539 Reported by Evgeny Stambulchik.
1540
44ea3fbd
MA
15412002-01-20 Marc Autret <marc@gnu.org>
1542
bb0146c2 1543 * src/system.h: Need to define __attribute__ away for non-GCC
44ea3fbd
MA
1544 compilers as well (i.e. the vendor C compiler).
1545 Suggested by Albert Chin-A-Young.
1546
338963d1
TVH
15472002-01-11 Tim Van Holder <tim.van.holder@pandora.be>
1548
1549 * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the
1550 canonical definition.
1551 * src/system.h: Use the canonical definition for PARAMS (avoids
1552 a conflict with the macro from lib/hash.h).
1553
c57b2479
AD
15542002-01-11 Akim Demaille <akim@epita.fr>
1555
1556 * configure.in: Use AC_FUNC_STRNLEN.
d9e9746c 1557 Fixes the failures observed on AIX 4.3 by H.Merijn Brand.
c57b2479 1558
b85810ae
AD
15592002-01-09 Akim Demaille <akim@epita.fr>
1560
1561 * src/files.c, src/files.h (output_infix): New.
1562 (tab_extension): Remove.
1563 (compute_base_names): Compute the former, drop the latter.
1564 * src/output.c (prepare): Insert the muscles `output-infix', and
1565 `output-suffix'.
1566 * src/parse-skel.y (string, string.1): New.
1567 (section.header): Use it.
1568 (section.yacc): Remove.
1569 (prefix): Remove too.
1570 * src/scan-skel.l: Adjust.
1571 * src/bison.simple, src/bison.hairy: Adjust.
1572
cae60122
AD
15732002-01-09 Akim Demaille <akim@epita.fr>
1574
1575 * configure.in (WERROR_CFLAGS): Compute it.
1576 * src/Makefile.am (CFLAGS): Pass it.
1577 * tests/atlocal.in (CFLAGS): Idem.
1578 * src/files.c: Fix a few warnings.
1579 (get_extension_index): Remove, unused.
1580
ae404801
AD
15812002-01-08 Akim Demaille <akim@epita.fr>
1582
1583 * src/getargs.c (AS_FILE_NAME): New.
1584 (getargs): Use it to convert DOSish file names.
1585 * src/files.c (base_name): Rename as full_base_name to avoid
1586 clashes with `base_name ()'.
1587 (filename_split): New.
1588 (compute_base_names): N-th rewrite, using filename_split.
1589
22312b71
AD
15902002-01-08 Akim Demaille <akim@epita.fr>
1591
1592 * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c:
1593 New, stolen from the Fileutils 4.1.
1594 * lib/Makefile.am (libbison_a_SOURCES): Adjust.
1595 * configure.in: Check for the presence of memrchr, and of its
1596 prototype.
1597
a67cef01
TVH
15982002-01-07 Tim Van Holder <tim.van.holder@pandora.be>
1599
1600 * lib/hash.h (__P): Added definition for this macro.
1601 * src/Makefile.am: Add parse-skel.c and scan-skel.c to
1602 BUILT_SOURCES, to ensure they are generated first.
1603 * src/parse-skel.y: Use YYERROR_VERBOSE instead of
1604 %error-verbose to allow bootstrapping with bison 1.30x.
1605
2b25d624
AD
16062002-01-06 Akim Demaille <akim@epita.fr>
1607
1608 * src/reader.c (parse_braces): Don't fetch the next char, the
1609 convention is to fetch on entry.
1610 * tests/torture.at (GNU Cim Grammar): Reintroduce their weird
1611 'switch' without a following semicolon.
1612 * tests/regression.at (braces parsing): New.
1613
3460813b
AD
16142002-01-06 Akim Demaille <akim@epita.fr>
1615
1616 Bison is dead wrong in its RR conflict reports.
1617
1618 * tests/torture.at (GNU Cim Grammar): New.
1619 * src/conflicts.c (count_rr_conflicts): Fix.
1620
73784c64
AD
16212002-01-06 Akim Demaille <akim@epita.fr>
1622
1623 Creating package.m4 from configure.ac causes too many problems.
1624
1625 * tests/Makefile.am (package.m4): Create it by hand,
1626 AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf.
1627
25d81090
AD
16282002-01-06 Akim Demaille <akim@epita.fr>
1629
1630 * src/Makefile.am (bison_SOURCES): Add parse-skel.h and
1631 skeleton.h.
1632
a9b8959e
PE
16332002-01-04 Paul Eggert <eggert@twinsun.com>
1634
1635 * doc/bison.texinfo (Debugging):
1636 Remove YYSTDERR; it's no longer defined or used.
1637 Also, s/cstdio.h/cstdio/.
1638
25d81090
AD
16392002-01-03 Akim Demaille <akim@epita.fr>
1640
1641 * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf.
1642
1109455c
AD
16432002-01-03 Akim Demaille <akim@epita.fr>
1644
1645 * src/parse-skel.y (process_skeleton): Don't bind the parser's
1646 tracing code to --trace, wait for a better --trace option, with
1647 args.
1648
7ea5e977
AD
16492002-01-03 Akim Demaille <akim@epita.fr>
1650
1651 * src/bison.simple (YYSTDERR): Remove, replace `stderr'.
1652 The ISO C++ standard is extremely clear about it: stderr is
1653 considered a macro, not a regular symbol (see table 94 `Header
1654 <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files).
1655 Therefore std:: does not apply to it. It still does with fprintf.
1656 Also, s/cstdio.h/cstdio/.
1657
fab5b110
AD
16582002-01-03 Akim Demaille <akim@epita.fr>
1659
1660 * lib/quotearg.c: Use `#include "..."' instead of `#include <...>'
1661 for non system headers.
1662
aed7fd9b
AD
16632002-01-02 Akim Demaille <akim@epita.fr>
1664
1665 Equip the skeleton chain with location tracking, runtime trace,
1666 pure parser and scanner.
1667
1668 * src/parse-skel.y: Request a pure parser, locations, and prefix
1669 renaming.
1670 (%union): Having several members with the same type does not help
1671 type mismatches, simplify.
1672 (YYPRINT, yyprint): New.
1673 (yyerror): ``Rename'' (there is a #define yyerror skel_error) as...
1674 (skel_error): this.
1675 Handle locations.
1676 * src/scan-skel.l: Adjust to these changes.
1677 * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP)
1678 (LOCATION_PRINT, skel_control_t): New.
1679
24fad99e
AD
16802001-12-30 Akim Demaille <akim@epita.fr>
1681
1682 * src/parse-skel.y: Get rid of the shift/reduce conflict:
1683 replace `gb' with BLANKS.
1684 * src/scan-skel.l: Adjust.
1685
a4b36db4
AD
16862001-12-30 Akim Demaille <akim@epita.fr>
1687
1688 * src/system.h: We don't need nor want bcopy.
1689 Throw away MS-DOS crap: we don't need getpid.
1690 * configure.in: We don't need strndup. It was even causing
1691 problems: because Flex includes the headers *before* us,
1692 _GNU_SOURCE is not defined by config.h, and therefore strndup was
1693 not visible.
1694 * lib/xstrndup.c: New.
1695 * src/scan-skel.l: Use it.
1696 Be sure to initialize yylval.muscle member when scanning a MUSCLE.
1697 * src/parse-skel.y: Use %directives instead of #defines.
1698
1239777d
AD
16992001-12-30 Akim Demaille <akim@epita.fr>
1700
1701 * src/skeleton.h: New.
1702 * src/output.c (output_parser, output_master_parser): Remove, dead
1703 code.
1704 * src/output.h (get_lines_number, actions_output, guards_output)
1705 (token_definitions_output): Prototype them.
1706 * src/parse-skel.y: Add the license notice.
1707 Include output.h and skeleton.h.
1708 (process_skeleton): Returns void, and takes a single parameter.
1709 * src/scan-skel.l: Add the license notice.
1710 Include skeleton.h.
1711 Don't use %option yylineno: it seems that then Flex imagines
1712 REJECT has been used, and therefore it won't reallocate its
1713 buffers (which makes no other sense to me than a bug). It results
1714 in warnings for `unused: yy_flex_realloc'.
1715
9b3add5b
RA
17162001-12-30 Robert Anisko <robert.anisko@epita.fr>
1717
1718 * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING)
1719 (MUSCLE_INSERT_PREFIX): ...to there.
1720 * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING)
1721 (MUSCLE_INSERT_PREFIX): Move from here...
1722
1723 * src/bison.hairy: Add a section directive. Put braces around muscle
1724 names. This parser skeleton is still broken, but Bison should not
1725 choke on a bad muscle 'syntax'.
1726 * src/bison.simple: Add a section directive. Put braces around muscle
1727 names.
1728
1729 * src/files.h (strsuffix, stringappend): Add declarations.
1730 (tab_extension): Add declaration.
1731 (short_base_name): Add declaration.
1732
1733 * src/files.c (strsuffix, stringappend): No longer static. These
1734 functions are used in the skeleton parser.
1735 (tab_extension): New.
1736 (compute_base_names): Use the computations done in this function
fab5b110 1737 to guess if the generated parsers should have '.tab' in their
9b3add5b
RA
1738 names.
1739 (short_base_name): No longer static.
1740
1741 * src/output.c (output_skeleton): New.
1742 (output): Disable call to output_master_parser, and give a try to
1743 a new skeleton handling system.
1744 (guards_output, actions_output): No longer static.
1745 (token_definitions_output, get_lines_number): No longer static.
1746
1747 * configure.in: Use AM_PROG_LEX and AC_PROG_YACC.
1748
fab5b110 1749 * src/Makefile.am (bison_SOURCES): Add scan-skel.l and
9b3add5b
RA
1750 parse-skel.y.
1751
1752 * src/parse-skel.y: New file.
1753 * src/scan-skel.l: New file.
1754
b5b61c61
AD
17552001-12-29 Akim Demaille <akim@epita.fr>
1756
1757 %name-prefix is broken.
1758
1759 * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy".
1760 Adjust all dependencies.
1761 * tests/headers.at (export YYLTYPE): Strengthen this test: use
1762 %name-prefix.
1763
1764 Renaming yylval but not yylloc is not consistent. Now we do.
1765
1766 * src/bison.simple: Prefix yylloc if used.
1767 * doc/bison.texinfo (Decl Summary): Document that.
1768
8c9a50be
AD
17692001-12-29 Akim Demaille <akim@epita.fr>
1770
1771 * doc/bison.texinfo: Promote `%long-directive' over
1772 `%long_directive'.
1773 Remove all references to fixed-output-files, yacc is enough.
1774
d99361e6
AD
17752001-12-29 Akim Demaille <akim@epita.fr>
1776
1777 * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the
1778 user prologue. These are defaults.
1779 * tests/actions.at (Mid-rule actions): Make sure the user can
1780 define YYDEBUG and YYERROR_VERBOSE.
1781
b9cecb91
AD
17822001-12-29 Akim Demaille <akim@epita.fr>
1783
1784 * src/output.c (header_output): Don't forget to export YYLTYPE and
1785 yylloc.
1786 * tests/headers.at (export YYLTYPE): New, make sure it does.
1787 * tests/regression.at (%union and --defines, Invalid CPP headers):
1788 Move to...
1789 * tests/headers.at: here.
1790
aea13e97
AD
17912001-12-29 Akim Demaille <akim@epita.fr>
1792
1793 * src/gram.h (rule_s): Member `assoc' is of type `associativity'.
1794
931394cb
AD
17952001-12-29 Akim Demaille <akim@epita.fr>
1796
1797 * tests/actions.at (Mid-rule actions): Output on a single line
1798 instead of several.
1799
704a47c4
AD
18002001-12-29 Akim Demaille <akim@epita.fr>
1801
1802 * doc/bison.texinfo: Formatting changes.
1803
091e20bb
AD
18042001-12-29 Akim Demaille <akim@epita.fr>
1805
1806 Don't store the token defs in a muscle, just be ready to output it
1807 on command. Now possible via `symbols'. Fixes a memory leak.
1808
1809 * src/output.c (token_definitions_output): New.
1810 (output_parser, header_output): Use it.
1811 * src/reader.c (symbols_save): Remove.
1812
cce71710
AD
18132001-12-29 Akim Demaille <akim@epita.fr>
1814
1815 * src/bison.simple: Do not provide a default for YYSTYPE and
1816 YYLTYPE before the user's prologue. Otherwise it's hardly... a
1817 default.
1818
82c035a8
AD
18192001-12-29 Akim Demaille <akim@epita.fr>
1820
1821 Mid-rule actions are simply... ignored!
1822
1823 * src/reader.c (readgram): Be sure to attach mid-rule actions to
1824 the empty-rule associated to the dummy symbol, not to the host
1825 rule.
1826 * tests/actions.at (Mid-rule actions): New.
1827
8419d367
AD
18282001-12-29 Akim Demaille <akim@epita.fr>
1829
1830 Memory leak.
1831
1832 * src/reader.c (reader): Free grammar.
1833
375d5806
AD
18342001-12-29 Akim Demaille <akim@epita.fr>
1835
1836 Memory leak.
1837
1838 * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here,
1839 since it allocates it for each state, although only one is needed.
1840 (allocate_storage): Do it here.
1841
f51cb8ff
AD
18422001-12-29 Akim Demaille <akim@epita.fr>
1843
1844 * src/options.h, src/options.c (create_long_option_table): Rename
1845 as...
1846 (long_option_table_new): this, with a clearer prototype.
1847 (percent_table): Remove, unused,
1848 * src/getargs.c (getargs): Adjust.
1849
29e88316
AD
18502001-12-29 Akim Demaille <akim@epita.fr>
1851
1852 * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c
1853 * src/print.c, src/print_graph.c, src/state.h: Rename state_table
1854 as states.
1855
b9f71f19
AD
18562001-12-29 Akim Demaille <akim@epita.fr>
1857
1858 * src/lalr.c (build_relations): Rename `states' as `states1'.
1859 Sorry, I don't understand exactly what it is, no better name...
1860
1a2b5d37
AD
18612001-12-29 Akim Demaille <akim@epita.fr>
1862
1863 * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c
1864 * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c
1865 * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table
1866 as rules.
1867
1cca533e
AD
18682001-12-29 Akim Demaille <akim@epita.fr>
1869
1870 * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long
1871 ago.
1872
c03ae966
AD
18732001-12-29 Akim Demaille <akim@epita.fr>
1874
1875 * src/reader.c, src/reader.h (user_toknums): Remove.
1876 Adjust all users to use symbols[i]->user_token_number.
1877
5a670b1e
AD
18782001-12-29 Akim Demaille <akim@epita.fr>
1879
1880 * src/gram.c, src/gram.h (sprec, sassoc): Remove.
1881 Adjust all users to use symbols[i]->prec or ->assoc.
1882
ad949da9
AD
18832001-12-29 Akim Demaille <akim@epita.fr>
1884
1885 * src/reader.c, src/reader.h (tags): Remove.
1886 Adjust all users to use symbols[i]->tag.
1887
0e78e603
AD
18882001-12-29 Akim Demaille <akim@epita.fr>
1889
1890 * src/gram.h, src/gram.c (symbols): New, similar to state_table
1891 and rule_table.
1892 * src/reader.c (packsymbols): Fill this table.
1893 Drop sprec.
1894 * src/conflicts.c (resolve_sr_conflict): Adjust.
1895 * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a
1896 single table.
1897 Use symbols[i]->tag instead of tags[i].
1898
213e640e
AD
18992001-12-29 Akim Demaille <akim@epita.fr>
1900
1901 * tests/calc.at (_AT_DATA_CALC_Y): Also use %union.
1902 In addition, put a comment in there, to replace...
1903 * tests/regression.at (%union and C comments): Remove.
1904
e7b8bef1
AD
19052001-12-29 Akim Demaille <akim@epita.fr>
1906
1907 * tests/regression.at (Web2c Actions): Blindly move the actual
1908 output as expected output. The contents *seem* right to me, but I
1909 can't pretend reading perfectly parser tables... Nonetheless, all
1910 the other tests pass correctly, the table look OK, even though the
1911 presence of `$axiom' is to be noted: AFAICS it is useless (but
1912 harmless).
1913
b68e7744
AD
19142001-12-29 Akim Demaille <akim@epita.fr>
1915
1916 * src/reader.c (readgram): Don't add the rule 0 if there were no
1917 rules read. In other words, add it _after_ having performed
1918 grammar sanity checks.
1919 Fixes the `tests/regression.at (Invalid input: 1)' Failure.
1920
78d5bae9
AD
19212001-12-29 Akim Demaille <akim@epita.fr>
1922
1923 * tests/regression.at (Web2c Report): Catch up: the rule 0 is now
1924 visible, and some states have now a different number.
1925
ff442794
AD
19262001-12-29 Akim Demaille <akim@epita.fr>
1927
1928 * src/reader.c (readgram): Bind the initial rule's lineno to that
1929 of the first rule.
1930 * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts):
1931 (Solved SR Conflicts): Adjust rule 0's line number.
1932
610ab194
AD
19332001-12-29 Akim Demaille <akim@epita.fr>
1934
1935 Fix the `GAWK Grammar' failure.
1936
1937 * src/LR0.c (final_state): Initialize to -1 so that we do compute
1938 the reductions of the first state which was mistakenly confused
1939 with the final state because precisely final_state was initialized
1940 to 0.
1941 * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads,
1942 now noticed by Bison.
1943 * tests/regression.at (Rule Line Numbers): Adjust: state 0 does
1944 have a reduction on $default.
1945
29d29c8f
AD
19462001-12-29 Akim Demaille <akim@epita.fr>
1947
1948 * src/gram.c (ritem_print): Be sure to subtract 1 when displaying
1949 rule line numbers.
1950 * src/closure.c (print_closure): Likewise.
1951 * src/derives.c (print_derives): Likewise.
1952 * tests/sets.at (Nullable): Adjust: the rule numbers are correct
1953 now.
1954
7c6b64d0
AD
19552001-12-29 Akim Demaille <akim@epita.fr>
1956
1957 * src/lalr.c (lookaheads_print): New.
1958 (lalr): Call it when --trace-flag.
1959 * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads
1960 are dumped.
1961
3d4daee3
AD
19622001-12-29 Akim Demaille <akim@epita.fr>
1963
1964 * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0',
1965 when walking through ritem, even via rule->rhs.
1966 * src/reduce.c (dump_grammar, useful_production, reduce_output)
1967 (useful_production, useless_nonterminals): Likewise.
1968 (reduce_grammar_tables): Likewise, plus update nritems.
1969 * src/nullable.c (set_nullable): Likewise.
1970 * src/lalr.c (build_relations): Likewise.
1971 * tests/sets.at (Nullable): Adjust.
1972 Fortunately, now, the $axiom is no longer nullable.
1973
9e7f6bbd
AD
19742001-12-29 Akim Demaille <akim@epita.fr>
1975
1976 * src/LR0.c (generate_states): Use nritems, not nitems, nor using
1977 the 0-sentinel.
1978 * src/gram.c (ritem_longest_rhs): Likewise.
1979 * src/reduce.c (nonterminals_reduce): Likewise.
1980 * src/print_graph.c (print_graph): Likewise.
1981 * src/output.c (output_rule_data): Likewise.
1982 * src/nullable.c (set_nullable): Likewise.
1983
255ef638
AD
19842001-12-29 Akim Demaille <akim@epita.fr>
1985
1986 * src/output.c: Comment changes.
1987
0d8a7363
AD
19882001-12-27 Paul Eggert <eggert@twinsun.com>
1989
1990 * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special
1991 cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and
1992 Sparc, as they were causing more porting problems than the
1993 (minor) performance improvement was worth.
1994
1995 Also, catch up with 1.31's YYSTD.
1996
3db472b9
AD
19972001-12-27 Akim Demaille <akim@epita.fr>
1998
1999 * src/output.c (output_gram): Rely on nritems, not the
2000 0-sentinel. See below.
2001 Use -1 as separator, not 0.
2002 * src/bison.simple (yyparse): Subtract 1 to the rule numbers.
2003 Rely on -1 as separator in yyrhs, instead of 0.
2004 * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue
2005 twice `Now at end of input', therefore there are two lines less to
2006 expect.
2007
b365aa05
AD
20082001-12-27 Akim Demaille <akim@epita.fr>
2009
2010 * tests/regression.at (Unresolved SR Conflicts):
2011 (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes
2012 below.
2013
30171f79
AD
20142001-12-27 Akim Demaille <akim@epita.fr>
2015
2016 * src/LR0.c (new_state): Recognize the final state by the fact it
2017 is reached by eoftoken.
2018 (insert_start_shifting_state, insert_eof_shifting_state)
2019 (insert_accepting_state, augment_automaton): Remove, since now
2020 these states are automatically computed from the initial state.
2021 (generate_states): Adjust.
2022 * src/print.c: When reporting a rule number to the user, substract
2023 1, so that the axiom rule is rule 0, and the first user rule is 1.
2024 * src/reduce.c: Likewise.
2025 * src/print_graph.c (print_core): For the time being, just as for
2026 the report, depend upon --trace-flags to dump the full set of
2027 items.
2028 * src/reader.c (readgram): Once the grammar read, insert the rule
2029 0: `$axiom: START-SYMBOL $'.
2030 * tests/set.at: Adjust: rule 0 is now displayed, and since the
2031 number of the states has changed (the final state is no longer
2032 necessarily the last), catch up.
2033
75142d45
AD
20342001-12-27 Akim Demaille <akim@epita.fr>
2035
2036 Try to make the use of the eoftoken valid. Given that its value
2037 is 0 which was also used as a sentinel in ritem, (i) make sure >= 0
2038 is used instead of > 0 where appropriate, (ii), depend upon nritems
2039 instead of the 0-sentinel.
2040
2041 * src/gram.h, src/gram.c (nritems): New.
2042 Expected to be duplication of nitems, but for the time being...
2043 * src/reader.c (packgram): Assert nritems and nitems are equal.
2044 * src/LR0.c (allocate_itemsets, new_itemsets): Adjust.
2045 * src/closure.c (print_closure, print_fderives): Likewise.
2046 * src/gram.c (ritem_print): Likewise.
2047 * src/print.c (print_core, print_grammar): Likewise.
2048 * src/print_graph.c: Likewise.
2049
b7c49edf
AD
20502001-12-27 Akim Demaille <akim@epita.fr>
2051
2052 * src/main.c (main): If there are complains after grammar
2053 reductions, then output the report anyway if requested, then die.
2054 * src/symtab.c (bucket_new): Initialize `value' to -1, not 0.
2055 * src/reader.c (eoftoken): New.
2056 (parse_token_decl): If the token being defined has value `0', it
2057 is the eoftoken.
2058 (packsymbols): No longer hack `tags' to insert `$' by hand.
2059 Be sure to preserve the value of the eoftoken.
2060 (reader): Make sure eoftoken is defined.
2061 Initialize nsyms to 0: now eoftoken is created just like the others.
2062 * src/print.c (print_grammar): Don't special case the eof token.
2063 * src/regression.at: Adjust: `$' has value 0, not -1, which was a
2064 lie anyway, albeit pleasant.
2065 * tests/calc.at: Exercise error messages with eoftoken.
2066 Change the grammar so that empty input is invalid.
2067 Adjust expectations.
2068 When yyungeting, be sure to use a valid yylloc: use last_yylloc.
2069
ec2da99f
AD
20702001-12-27 Akim Demaille <akim@epita.fr>
2071
2072 * configure.in: Check the protos of strchr ans strspn.
2073 Replace strchr if needed.
2074 * src/system.h: Provide the protos of strchr, strspn and memchr if
2075 missing.
2076 * lib/strchr.c: New.
2077 * src/reader.c (symbols_save): Use strchr.
2078
8adfa272
AD
20792001-12-27 Akim Demaille <akim@epita.fr>
2080
2081 * src/print.c, src/print_graph.c (escape): New.
2082 Use it to quote the TAGS outputs.
2083 * src/print_graph.c (print_state): Now errors are in red, and
2084 reductions in green.
2085 Prefer high to wide: output the state number on a line of its own.
2086
80dac38c
AD
20872001-12-27 Akim Demaille <akim@epita.fr>
2088
2089 * src/state.h, src/state.c (reductions_new): New.
2090 * src/LR0.c (set_state_table): Let all the states have a
2091 `reductions', even if reduced to 0.
2092 (save_reductions): Adjust.
2093 * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust.
2094 * src/print.c (print_reductions, print_actions): Adjust.
2095 * src/output.c (action_row): Adjust.
2096
2cec70b9
AD
20972001-12-27 Akim Demaille <akim@epita.fr>
2098
2099 * src/state.h, src/state.c (errs_new, errs_dup): New.
2100 * src/LR0.c (set_state_table): Let all the states have an errs,
2101 even if reduced to 0.
2102 * src/print.c (print_errs, print_reductions): Adjust.
2103 * src/output.c (output_actions, action_row): Adjust.
2104 * src/conflicts.c (resolve_sr_conflict): Adjust.
2105
13ca549a
AD
21062001-12-27 Akim Demaille <akim@epita.fr>
2107
2108 * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL.
2109
5092aba5
AD
21102001-12-27 Akim Demaille <akim@epita.fr>
2111
2112 * src/conflicts.c, src/conflicts.h (print_reductions): Move to...
2113 * src/print.c: here.
2114 (lookaheadset, shiftset): New, used as additional storage by
2115 print_reductions.
2116 (print_results): Adjust.
2117 (print_shifts, print_gotos, print_errs): New, extracted from...
2118 (print_actions): here.
2119 * src/print_graph.c (print_actions): Remove dead code.
2120
11e2beca
AD
21212001-12-27 Akim Demaille <akim@epita.fr>
2122
2123 * src/reader.c (copy_dollar, copy_at): Better checking of `n' in
2124 `$n' and `@n'.
2125
dac3c910
AD
21262001-12-27 Akim Demaille <akim@epita.fr>
2127
2128 * src/lalr.c (add_lookback_edge): Use state_t instead of ints.
2129 (build_relations): Adjust.
2130
d0b0fefa
AD
21312001-12-27 Akim Demaille <akim@epita.fr>
2132
2133 * src/lalr.c (set_goto_map): Remove a wrong but benign loop
2134 duplication.
2135
adc8c848
AD
21362001-12-27 Akim Demaille <akim@epita.fr>
2137
2138 * src/reader.c (packgram): Catch nitems overflows.
2139
14d293ac
AD
21402001-12-27 Akim Demaille <akim@epita.fr>
2141
2142 * src/files.c, src/files.h (guard_obstack): Remove.
2143 * src/output.c (output): Adjust.
2144 * src/reader.c (parse_braces): New, factoring...
2145 (copy_action, copy_guard): these two which are renamed as...
2146 (parse_action, parse_guard): these.
2147 As a voluntary consequence, using braces around guards is now
2148 mandatory.
2149
f499b062
AD
21502001-12-27 Akim Demaille <akim@epita.fr>
2151
2152 * src/gram.h (rule_t): `guard' and `guard_line' are new members.
2153 * src/reader.c (symbol_list): `guard' and `guard_line' are new
2154 members.
2155 (symbol_list_new): Adjust.
2156 (copy_action): action_line is the first line, not the last.
2157 (copy_guard): Just as for actions, store the `action' only, not
2158 the switch/case/break flesh.
2159 Don't parse the user action that might follow the guard, let...
2160 (readgram): do it, i.e., now, there can be an action after a
2161 guard.
2162 In other words the guard is just explicitly optional.
2163 (packgram): Adjust.
2164 * src/output.c (guards_output): New.
2165 (output_parser): Call it when needed.
2166 (output): Also free the guard and attrs obstacks.
2167 * src/files.c, src/files.h (obstack_save): Remove.
2168 (output_files): Remove.
2169 As a result, if one needs the former `.act' file, using an
2170 appropriate skeleton which requires actions and guards is now
2171 required.
2172 * src/main.c (main): Adjust.
2173 * tests/semantic.at: New.
2174 * tests/regression.at: Use `input.y' as input file name.
2175 Avoid 8+3 problems by requiring input.c when the test needs the
2176 parser.
2177
d945f5cd
AD
21782001-12-27 Akim Demaille <akim@epita.fr>
2179
2180 * src/reader.c (symbol_list_new): Be sure to initialize all the
2181 fields.
2182
d200e455
AD
21832001-12-27 Akim Demaille <akim@epita.fr>
2184
2185 All the hacks using a final pseudo state are now useless.
2186
2187 * src/LR0.c (set_state_table): state_table holds exactly nstates.
2188 * src/lalr.c (nLA): New.
2189 (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it
2190 instead of lookaheadsp from the pseudo state (nstate + 1).
2191
f9507c28
AD
21922001-12-27 Akim Demaille <akim@epita.fr>
2193
2194 * src/output.c (action_row, token_actions): Use a state_t instead
2195 of a integer, and nlookaheads instead of the following state's
2196 lookaheadsp.
2197
065fbd27
AD
21982001-12-27 Akim Demaille <akim@epita.fr>
2199
2200 * src/conflicts.c (log_resolution, flush_shift)
2201 (resolve_sr_conflict, set_conflicts, solve_conflicts)
2202 (count_sr_conflicts, count_rr_conflicts, conflicts_output)
2203 (conflicts_print, print_reductions): Use a state_t instead of an
2204 integer when referring to a state.
2205 As much as possible, depend upon nlookaheads, instead of the
2206 `lookaheadsp' member of the following state (since lookaheads of
2207 successive states are successive, the difference between state n + 1
2208 and n served as the number of lookaheads for state n).
2209 * src/lalr.c (add_lookback_edge): Likewise.
2210 * src/print.c (print_core, print_actions, print_state)
2211 (print_results): Likewise.
2212 * src/print_graph.c (print_core, print_actions, print_state)
2213 (print_graph): Likewise.
2214 * src/conflicts.h: Adjust.
2215
1b177bd7
AD
22162001-12-27 Akim Demaille <akim@epita.fr>
2217
2218 * src/bison.hairy: Formatting/comment changes.
2219 ANSIfy.
2220 Remove `register' indications.
2221 Add plenty of `static'.
2222
7742ddeb
AD
22232001-12-27 Akim Demaille <akim@epita.fr>
2224
2225 * src/output.c (prepare): Drop the muscle `ntbase' which
2226 duplicates ntokens.
2227 * src/bison.simple: Formatting/comment changes.
2228 Use YYNTOKENS only, which is documented, but not YYNTBASE, which
2229 is an undocumented synonym.
2230
1fa14068
AD
22312001-12-22 Akim Demaille <akim@epita.fr>
2232
2233 * src/output.c (output_table_data): Change the prototype to use
2234 `int' for array ranges: some invocations do pass an int, not a
2235 short.
2236 Reported by Wayne Green.
2237
b9752825
AD
22382001-12-22 Akim Demaille <akim@epita.fr>
2239
2240 Some actions of web2c.y are improperly triggered.
2241 Reported by Mike Castle.
2242
2243 * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/.
2244 * tests/regression.at (Web2c): Rename as...
2245 (Web2c Report): this.
2246 (Web2c Actions): New.
2247
776209d6
AD
22482001-12-22 Akim Demaille <akim@epita.fr>
2249
2250 Reductions in web2c.y are improperly reported.
2251 Reported by Mike Castle.
2252
2253 * src/conflicts.c (print_reductions): Fix.
2254 * tests/regression.at (Web2c): New.
2255
275fc3ad
AD
22562001-12-18 Akim Demaille <akim@epita.fr>
2257
2258 Some host fail on `assert (!"foo")', which expands to
2259 ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__))
2260 Reported by Nelson Beebee.
2261
2262 * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with
2263 `#define it_succeeded 0' and `assert (it_succeeded)'.
2264
897668ee
MA
22652001-12-17 Marc Autret <autret_m@epita.fr>
2266
2267 * src/bison.simple: Don't hard code the skeleton line and filename.
2268 * src/output.c (output_parser): Rename 'line' as 'output_line'.
2269 New line counter 'skeleton_line' (skeleton-line muscle).
2270
ab3399e0
PE
22712001-12-17 Paul Eggert <eggert@twinsun.com>
2272
2273 * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that
2274 YYDEBUG must be defined to a nonzero value.
2275
2276 * src/bison.simple (yytname): Do not assume that the user defines
2277 YYDEBUG to a properly parenthesized expression.
2278
3877f72b
AD
22792001-12-17 Akim Demaille <akim@epita.fr>
2280
2281 * src/state.h (state_t): Rename lookaheads as lookaheadsp.
2282 nlookaheads is a new member.
2283 Adjust all users.
2284 * src/lalr.h (nlookaheads): Remove this orphan declaration.
2285 * src/lalr.c (initialize_lookaheads): Set nlookaheads for each
2286 state.
776209d6 2287
331dbc1b
AD
22882001-12-17 Akim Demaille <akim@epita.fr>
2289
2290 * src/files.h, src/files.c (open_files, close_files): Remove.
2291 * src/main.c (main): Don't open/close files, nor invoke lex_free,
2292 let...
2293 * src/reader.c (reader): Do it.
776209d6 2294
be750e4c
AD
22952001-12-17 Akim Demaille <akim@epita.fr>
2296
2297 * src/conflicts.c (print_reductions): Formatting changes.
776209d6 2298
709ae8c6
AD
22992001-12-17 Akim Demaille <akim@epita.fr>
2300
2301 * src/conflicts.c (flush_shift): Also adjust lookaheadset.
2302 (flush_reduce): New.
2303 (resolve_sr_conflict): Adjust.
776209d6 2304
f87685c3
AD
23052001-12-17 Akim Demaille <akim@epita.fr>
2306
2307 * src/output.c (output_obstack): Be static and rename as...
2308 (format_obstack): this, to avoid any confusion with files.c's
2309 output_obstack.
2310 * src/reader.h (muscle_obstack): Move to...
2311 * src/output.h: here, since it's defined in output.c.
2312
837491d8
AD
23132001-12-17 Akim Demaille <akim@epita.fr>
2314
2315 * src/output.c (action_row, save_column, default_goto)
2316 (sort_actions, matching_state, pack_vector): Better variable
2317 locality.
2318
796d61fb
AD
23192001-12-17 Akim Demaille <akim@epita.fr>
2320
2321 * src/output.c: Various formatting changes.
776209d6 2322
64d15509
AD
23232001-12-17 Akim Demaille <akim@epita.fr>
2324
2325 * src/files.c (output_files): Free the output_obstack.
2326 * src/main.c (main): Call print and print_graph conditionally.
2327 * src/print.c (print): Work unconditionally.
2328 * src/print_graph.c (print_graph): Work unconditionally.
2329 * src/conflicts.c (log_resolution): Output only if verbose_flag.
2330
fbc8ecb7
MA
23312001-12-16 Marc Autret <autret_m@epita.fr>
2332
2333 * src/output.c (actions_output): Fix. When we use %no-lines,
2334 there is one less line per action.
2335
f0440388
MA
23362001-12-16 Marc Autret <autret_m@epita.fr>
2337
2338 * src/bison.simple: Remove a useless #line directive.
2339 s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'.
2340 * src/output.c (get_lines_number): New.
776209d6 2341 (output_parser): Adjust, now takes care about the lines of a
f0440388
MA
2342 output muscles.
2343 Fix line numbering.
2344 (actions_output): Computes the number of lines taken by actions.
2345 (output_master_parser): Insert new skeleton which is the name of
2346 the output parser file name.
2347
a79986b8
MA
23482001-12-15 Marc Autret <autret_m@epita.fr>
2349
2350 * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility.
2351
4ec8e00f
MA
23522001-12-15 Marc Autret <autret_m@epita.fr>
2353
2354 * src/output.c (output_gram): Keep track of the hairy one.
2355
1a4648ff
AD
23562001-12-15 Akim Demaille <akim@epita.fr>
2357
2358 Make `make distcheck' work.
2359
2360 * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses
2361 system.h which uses libgettext.h.
2362
9c2c67e6
AD
23632001-12-15 Akim Demaille <akim@epita.fr>
2364
2365 * src/nullable.c (set_nullable): Useless rules must be skipped,
2366 otherwise, since we range over their symbols, we might look at a
2367 nonterminal which no longer ``exists'', i.e., it is not counted in
2368 `nvars', hence we overflow our arrays.
2369
93ede233
AD
23702001-12-15 Akim Demaille <akim@epita.fr>
2371
2372 The header can also be produced directly, without any obstack!
2373 Yahoo!
2374
2375 * src/files.c, src/files.h (defines_obstack): Remove.
2376 (compute_header_macro): Global.
2377 (defines_obstack_save): Remove.
2378 * src/reader.c (parse_union_decl): No longer output to
2379 defines_obstack: its content can be found in the `stype' muscle
2380 anyway.
2381 (output_token_translations): Merge into...
2382 (symbols_output): this.
2383 Rename as...
2384 (symbols_save): this.
2385 (reader): Adjust.
2386 * src/output.c (header_output): New.
2387 (output): Call it.
2388
2666f928
AD
23892001-12-15 Akim Demaille <akim@epita.fr>
2390
2391 * src/reader.c (parse_union_decl): Instead of handling two obstack
2392 simultaneously, use one to define the `stype' muscle, and use the
2393 value of the latter to fill defines_obstack.
2394 (copy_comment): Remove.
2395 (copy_comment2): Work for a single obstack.
2396 Rename as...
2397 (copy_comment): this.
2398
428046f8
AD
23992001-12-15 Akim Demaille <akim@epita.fr>
2400
2401 * src/lex.c, src/lex.h (xgetc): No longer static.
2402 * src/reader.c (parse_union_decl): Revamp.
2403
ea52d706
AD
24042001-12-15 Akim Demaille <akim@epita.fr>
2405
2406 Still making progress in separating Bison into (i) input, (ii)
2407 process, (iii) output: now we can directly output the parser file
2408 without using table_obstack at all.
2409
2410 * src/files.c, src/files.h (table_obstack): Bye bye.
2411 (parser_file_name): New.
2412 * src/files.c (compute_output_file_names): Compute it.
2413 * src/output.c (actions_output, output_parser)
2414 (output_master_parser): To a file instead of an obstack.
2415
3f96f4dc
AD
24162001-12-15 Akim Demaille <akim@epita.fr>
2417
2418 Attach actions to rules, instead of pre-outputting them to
2419 actions_obstack.
2420
2421 * src/gram.h (rule_t): action and action_line are new members.
2422 * src/reader.c (symbol_list): Likewise.
2423 (copy_action): Save the actions within the rule.
2424 (packgram): Save them in rule_table.
2425 * src/output.c (actions_output): New.
2426 (output_parser): Use it on `%%actions'.
2427 (output_rule_data): Don't free rule_table.
2428 (output): Do it.
2429 (prepare): Don't save the `action' muscle.
2430 * src/bison.simple: s/%%action/%%actions/.
2431
51576fb3
AD
24322001-12-15 Akim Demaille <akim@epita.fr>
2433
2434 * src/reader.c (copy_action): When --yacc, don't append a `;'
2435 to the user action: let it fail if lacking.
dee049eb 2436 Suggested by Arnold Robbins and Tom Tromey.
51576fb3 2437
2648a72d
AD
24382001-12-14 Akim Demaille <akim@epita.fr>
2439
2440 * src/lex.c (literalchar): Simply return the char you decoded, non
2441 longer mess around with obstacks and int pointers.
2442 Adjust all callers.
2443
92790e5b
AD
24442001-12-14 Akim Demaille <akim@epita.fr>
2445
2446 * src/lex.c (literalchar): Don't escape the special characters,
2447 just decode them, and keep them as char (before, eol was output as
2448 the 2 char string `\n' etc.).
2449 * src/output.c (output_rule_data): Use quotearg to output the
2450 token strings.
2451
927c1557
PE
24522001-12-13 Paul Eggert <eggert@twinsun.com>
2453
2454 * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE):
2455 Do not infringe on the global user namespace when using C++.
2456 (YYFPRINTF, YYSTDERR): New macros, needed for the above.
2457 All uses of `fprintf' and `stderr' changed.
2458
2459 * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR.
2460
ed8e1f68
AD
24612001-12-13 Akim Demaille <akim@epita.fr>
2462
2463 The computation of nullable is broken: it doesn't handle empty
2464 RHS's properly.
2465
2466 * tests/torture.at (GNU AWK Grammar): New.
2467 * tests/sets.at (Nullable): New.
2468 * src/nullable.c (set_nullable): Instead of blindly looping over
2469 `ritems', loop over the rules, and then over their rhs's.
2470
2471 Work around Autotest bugs.
2472
2473 * src/warshall.c (bitmatrix_print): Don't use `+--+' as table
2474 frame, because Autotest understand lines starting with a `+' as
2475 traces from the shell. Then, they are not processed properly.
2476 Admittedly an Autotest bug, but we don't have time to wait for
2477 Autotest to catch up.
2478 * tests/regression.at (Broken Closure): Adjust to the new table
2479 frames.
2480 Move to...
2481 * tests/sets.at: here.
2482
cb581495
AD
24832001-12-13 Akim Demaille <akim@epita.fr>
2484
2485 * src/closure.c (closure): Use nrules instead of playing tricks
2486 with BITS_PER_WORD.
2487
2e729273
AD
24882001-12-13 Akim Demaille <akim@epita.fr>
2489
2490 * src/print.c (print_actions): Output the handling of `$' as the
2491 traces do: shifting the token EOF. Before EOF was treated as a
2492 nonterminal.
2493 * tests/regression.at: Adjust some tests.
2494 * src/print_graph.c (print_core): Complete the set of items via
2495 closure. The next-to-final and final states are still unsatisfying,
2496 but that's to be addressed elsewhere.
2497 No longer output the rule numbers, but do output the state number.
2498 A single loop for the shifts + gotos is enough, but picked a
2499 distinct color for each.
2500 (print_graph): Initialize and finalize closure.
2501
107f7dfb
AD
25022001-12-13 Akim Demaille <akim@epita.fr>
2503
2504 * src/reader.c (readgram): Remove dead code, an strip useless
2505 braces.
2506 (get_type): Remove, unused.
2507
9b53a24f
AD
25082001-12-12 Akim Demaille <akim@epita.fr>
2509
2510 * src/complain.h, src/complain.c: Remove error_one_per_line, rely
2511 on that of lib/error.c.
2512
dbfb6dcd
AD
25132001-12-12 Akim Demaille <akim@epita.fr>
2514
2515 Some hosts don't like `/' in includes.
2516
2517 * src/system.h: Include libgettext.h without qualifying the path.
2518 * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove
2519 $(top_srcdir).
2520
c25fb648
MA
25212001-12-11 Marc Autret <autret_m@epita.fr>
2522
2523 * src/output.c (output_parser): Remove useless muscle.
2524
710ddc4f
MA
25252001-12-11 Marc Autret <autret_m@epita.fr>
2526
2527 * src/bison.simple: Remove #line just before %%epilogue. It
2528 is now handled in ...
2529 * src/reader.c (read_additionnal_code): Add the output of a
2530 #line for the epilogue.
2531
e83d80b8
MA
25322001-12-10 Marc Autret <autret_m@epita.fr>
2533
927c1557 2534 * src/reader.c (copy_definition): Re-use CPP-outed code which
e83d80b8
MA
2535 replace precedent remove.
2536 * src/bison.simple: Remove #line before %%prologue because
2537 %%input-line is wrong at this time.
2538
971d5158
MA
25392001-12-10 Marc Autret <autret_m@epita.fr>
2540
2541 * src/reader.c (symbols_output): Clean up.
927c1557 2542 * src/output.c (output_gram, output): Clean up.
971d5158 2543
5edafffd
AD
25442001-12-10 Akim Demaille <akim@epita.fr>
2545
2546 * src/lalr.c (initialize_lookaheads): New. Extracted from...
2547 * src/LR0.c (set_state_table): here.
2548 * src/lalr.c (lalr): Call it.
2549
0279f8e9
AD
25502001-12-10 Akim Demaille <akim@epita.fr>
2551
2552 * src/state.h (shifts): Remove the `number' member: shifts are
2553 attached to state, hence no longer need to be labelled with a
2554 state number.
2555
190c4f5f
AD
25562001-12-10 Akim Demaille <akim@epita.fr>
2557
2558 Now that states have a complete set of members, the linked list of
2559 shifts is useless: just fill directly the state's shifts member.
2560
2561 * src/state.h (shifts): Remove the `next' member.
2562 * src/LR0.c (first_state, last_state): Remove.
2563 Adjust the callers.
2564 (augment_automaton): Don't look for the shifts that must be added
2565 a shift on EOF: it is those of the state we looked for! But now,
2566 since shifts are attached, it is no longer needed to looking
2567 merely by its id: its number.
2568
2a73b93d
AD
25692001-12-10 Akim Demaille <akim@epita.fr>
2570
2571 * src/LR0.c (augment_automaton): Better variable locality.
2572 Remove an impossible branch: if there is a state corresponding to
2573 the start symbol being shifted, then there is shift for the start
2574 symbol from the initial state.
2575
74392f6a
AD
25762001-12-10 Akim Demaille <akim@epita.fr>
2577
2578 * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state'
2579 only when appropriate: when insert_start_shifting_state' is not
2580 invoked.
2581 * tests/regression.at (Rule Line Numbers): Adjust.
2582
37c82725
AD
25832001-12-10 Akim Demaille <akim@epita.fr>
2584
2585 * src/LR0.c (augment_automaton): Now that all states have shifts,
2586 merge the two cases addition shifts to the initial state.
2587
6a164e0c
AD
25882001-12-10 Akim Demaille <akim@epita.fr>
2589
2590 * src/lalr.c (set_state_table): Move to...
2591 * src/LR0.c: here.
2592 * src/lalr.c (lalr): Don't call it...
2593 * src/LR0.c (generate_states): do it.
2594 * src/LR0.h (first_state): Remove, only the table is used.
2595
7215de24
AD
25962001-12-10 Akim Demaille <akim@epita.fr>
2597
2598 * src/LR0.h (first_shift, first_reduction): Remove.
2599 * src/lalr.c: Don't use first_shift: find shifts through the
2600 states.
2601
80e25d4d
AD
26022001-12-10 Akim Demaille <akim@epita.fr>
2603
2604 * src/LR0.c: Attach shifts to states as soon as they are
2605 computed.
2606 * src/lalr.c (set_state_table): Instead of assigning shifts to
2607 state, just assert that the mapping was properly done.
2608
0ab3728b
AD
26092001-12-10 Akim Demaille <akim@epita.fr>
2610
2611 * src/LR0.c (insert_start_shift): Rename as...
2612 (insert_start_shifting_state): this.
2613 (insert_eof_shifting_state, insert_accepting_state): New.
2614 (augment_automaton): Adjust.
2615 Better locality of the variables.
2616 When looking if the start_symbol is shifted from the initial
2617 state, using `while (... symbol != start_symbol ...)' sounds
2618 better than `while (... symbol < start_symbol ...)': If fail
2619 to see how the order between symbols could be relevant!
2620
78af9bbc
AD
26212001-12-10 Akim Demaille <akim@epita.fr>
2622
2623 * src/getargs.h: Don't declare `spec_name_prefix' and
2624 `spec_file_prefix', declared by src/files.h.
2625 * src/files.c, src/files.h: Default for spec_name_prefix is "yy".
2626 * src/muscle_tab.c (muscle_init): Default prefix to NULL.
2627 * src/output.c (prepare): Adjust.
2628 * src/reader.c (symbols_output): Likewise.
2629 * src/vmsgetargs.c: Vaguely adjust, but who cares?
2630
bdef2a41
AD
26312001-12-10 Akim Demaille <akim@epita.fr>
2632
2633 * src/muscle_tab.c (muscle_init): NULL is a better default than
2634 `"0"'.
2635
3735969c
AD
26362001-12-10 Akim Demaille <akim@epita.fr>
2637
2638 * src/reader.c (reader): Calling symbols_output once is enough.
2639
49701457
AD
26402001-12-10 Akim Demaille <akim@epita.fr>
2641
2642 Now that states have a complete set of members, the linked list of
2643 reductions is useless: just fill directly the state's reductions
2644 member.
2645
2646 * src/state.h (struct reductions): Remove member `number' and
2647 `next'.
2648 * src/LR0.c (first_reduction, last_reduction): Remove.
2649 (save_reductions): Don't link the new reductions, store them in
2650 this_state.
2651 * src/lalr.c (set_state_table): No need to attach reductions to
2652 states, it's already done.
2653 * src/output.c (output_actions): No longer free the shifts, then
2654 the reductions, then the states: free all the states and their
2655 members.
2656
0edad749
AD
26572001-12-10 Akim Demaille <akim@epita.fr>
2658
2659 * src/options.c (OPTN, DRTV, BOTH): New.
2660 (option_table): Use them.
2661
0edad749
AD
2662 * src/muscle_tab.c: Don't include xalloc.h and string.h: that's
2663 the job of system.h.
2664 * src/options.c: Don't include stdio.h and xalloc.h for the same
2665 reasons.
2666
5449dd0f
AD
26672001-12-10 Akim Demaille <akim@epita.fr>
2668
2669 * src/output.c (output, prepare): Make sure the values of the
2670 muscles `action' and `prologue' are 0-terminated.
2671
a870c567
AD
26722001-12-10 Akim Demaille <akim@epita.fr>
2673
2674 Clean up GCC warnings.
2675
2676 * src/reader.c (copy_action): `buf' is not used.
2677 (parse_skel_decl): Be static.
2678 * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'.
2679 * src/options.h (create_long_option_table): Have a real prototype.
2680 * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete)
2681 (hash_delete_at): Return const void *.
2682 Adjust casts to preserve the const.
2683
80df8768
AD
26842001-12-10 Akim Demaille <akim@epita.fr>
2685
2686 * configure.in: Require 2.52g.
2687 M4 is not needed, but AUTOM4TE is.
2688 * m4/m4.m4: Remove.
2689 * tests/Makefile.am: Adjust.
2690
f693ad14
AD
26912001-12-10 Akim Demaille <akim@epita.fr>
2692
2693 One structure for states is enough, even though theoretically
2694 there are LR(0) states and LALR(1) states.
2695
2696 * src/lalr.h (state_t): Remove.
2697 (state_table): Be state_t **, not state_t *.
2698 * src/state.h (core, CORE_ALLOC): Rename as...
2699 (state_t, STATE_ALLOC): this.
2700 Add the LALR(1) members: shifts, reductions, errs.
2701 * src/LR0.c (state_table): Rename as...
2702 (state_hash): this, to avoid name clashes with the global
2703 `state_table'.
2704 * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c
2705 * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust.
2706
74ffbcb6
AD
27072001-12-10 Akim Demaille <akim@epita.fr>
2708
2709 Bison dumps core on bash.y.
2710 Reported by Pascal Bart.
2711
2712 * src/warshall.c (bitmatrix_print): New.
2713 (TC): Use it.
2714 When performing a transitive closure R(i, j) && R(j, k) => R(i, k),
2715 j must be the outer loop.
2716 * tests/regression.at (Broken Closure): New.
2717
07708e19
AD
27182001-12-05 Akim Demaille <akim@epita.fr>
2719
2720 * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and
2721 its argument.
2722