]>
Commit | Line | Data |
---|---|---|
1 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
2 | ||
3 | * src/reader.c (token_translations_init): 256 is now the default | |
4 | value for the error token, i.e., it will be assigned another | |
5 | number if the user assigned 256 to one of her tokens. | |
6 | (reader): Don't force 256 to error. | |
7 | * doc/bison.texinfo (Symbols): Adjust. | |
8 | * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR) | |
9 | (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3 | |
10 | etc. instead of 10, 20, 30 (which was used to `jump' over error | |
11 | (256) and undefined (2)). | |
12 | ||
13 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
14 | ||
15 | Propagate more token_number_t. | |
16 | ||
17 | * src/gram.h (token_number_as_item_number) | |
18 | (item_number_as_token_number): New. | |
19 | * src/output.c (GENERATE_OUTPUT_TABLE): New. | |
20 | Use it to create output_item_number_table and | |
21 | output_token_number_table. | |
22 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
23 | * src/lex.c, src/nullable.c, src/output.c, src/print.c, | |
24 | * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h, | |
25 | * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts. | |
26 | ||
27 | ||
28 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
29 | ||
30 | * src/output.h, src/output.c (get_lines_number): Remove. | |
31 | ||
32 | 2002-04-19 Akim Demaille <akim@epita.fr> | |
33 | ||
34 | * doc/bison.texinfo (Actions): Make clear that `|' is not the same | |
35 | as Lex/Flex'. | |
36 | (Debugging): More details about enabling the debugging features. | |
37 | (Table of Symbols): Describe $$, $n, @$, and @n. | |
38 | Suggested by Tim Josling. | |
39 | ||
40 | 2002-04-19 Akim Demaille <akim@epita.fr> | |
41 | ||
42 | * doc/bison.texinfo: Remove the uses of the obsolete @refill. | |
43 | ||
44 | 2002-04-10 Akim Demaille <akim@epita.fr> | |
45 | ||
46 | * src/system.h: Rely on HAVE_LIMITS_H. | |
47 | Suggested by Paul Eggert. | |
48 | ||
49 | 2002-04-09 Akim Demaille <akim@epita.fr> | |
50 | ||
51 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the | |
52 | full stderr, and strip it according to the bison options, instead | |
53 | of composing the error message from different bits. | |
54 | This makes it easier to check for several error messages. | |
55 | Adjust all the invocations. | |
56 | Add an invocation exercising the error token. | |
57 | Add an invocation demonstrating a stupid error message. | |
58 | (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0. | |
59 | Adjust the tests. | |
60 | Error message are for stderr, not stdout. | |
61 | ||
62 | 2002-04-09 Akim Demaille <akim@epita.fr> | |
63 | ||
64 | * src/gram.h, src/gram.c (error_token_number): Remove, use | |
65 | errtoken->number. | |
66 | * src/reader.c (reader): Don't specify the user token number (2) | |
67 | for $undefined, as it uselessly prevents using it. | |
68 | * src/gram.h (token_number_t): Move to... | |
69 | * src/symtab.h: here. | |
70 | (state_t.number): Is a token_number_t. | |
71 | * src/print.c, src/reader.c: Use undeftoken->number instead of | |
72 | hard coded 2. | |
73 | (Even though this 2 is not the same as above: the number of the | |
74 | undeftoken remains being 2, it is its user token number which | |
75 | might not be 2). | |
76 | * src/output.c (prepare_tokens): Rename the `maxtok' muscle with | |
77 | `user_token_number_max'. | |
78 | Output `undef_token_number'. | |
79 | * data/bison.simple, data/bison.c++: Use them. | |
80 | Be sure to map invalid yylex return values to | |
81 | `undef_token_number'. This saves us from gratuitous SEGV. | |
82 | ||
83 | * tests/conflicts.at (Solved SR Conflicts) | |
84 | (Unresolved SR Conflicts): Adjust. | |
85 | * tests/regression.at (Web2c Actions): Adjust. | |
86 | ||
87 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
88 | ||
89 | * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/. | |
90 | Adding #line. | |
91 | Remove the duplicate `typedefs'. | |
92 | (RhsNumberType): Fix the declaration and various other typos. | |
93 | Use __ofile__. | |
94 | * data/bison.simple: Use __ofile__. | |
95 | * src/scan-skel.l: Handle __ofile__. | |
96 | ||
97 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
98 | ||
99 | * src/gram.h (item_number_t): New, the type of item numbers in | |
100 | RITEM. Note that it must be able to code symbol numbers as | |
101 | positive number, and the negation of rule numbers as negative | |
102 | numbers. | |
103 | Adjust all dependencies (pretty many). | |
104 | * src/reduce.c (rule): Remove this `short *' pointer: use | |
105 | item_number_t. | |
106 | * src/system.h (MINSHORT, MAXSHORT): Remove. | |
107 | Include `limits.h'. | |
108 | Adjust dependencies to using SHRT_MAX and SHRT_MIN. | |
109 | (shortcpy): Remove. | |
110 | (MAXTABLE): Move to... | |
111 | * src/output.c (MAXTABLE): here. | |
112 | (prepare_rules): Use output_int_table to output rhs. | |
113 | * data/bison.simple, data/bison.c++: Adjust. | |
114 | * tests/torture.at (Big triangle): Move the limit from 254 to | |
115 | 500. | |
116 | * tests/regression.at (Web2c Actions): Ajust. | |
117 | ||
118 | Trying with bigger grammars shows various phenomena: at 3000 (28Mb | |
119 | of grammar file) bison is killed by my system, at 2000 (12Mb) bison | |
120 | passes, but produces negative #line number, once fixed, GCC is | |
121 | killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of | |
122 | C), it passes. | |
123 | * src/state.h (state_h): Code input lines on ints, not shorts. | |
124 | ||
125 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
126 | ||
127 | * src/reduce.c (reduce_grammar): First reduce the nonterminals, | |
128 | and then the grammar. | |
129 | ||
130 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
131 | ||
132 | * src/system.h: No longer using strndup. | |
133 | ||
134 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
135 | ||
136 | * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New. | |
137 | * src/output.c (output_table_data): Return the longest number. | |
138 | (prepare_tokens): Output `token_number_max'). | |
139 | * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type): | |
140 | New. | |
141 | Use them to define yy_token_number_type/TokenNumberType. | |
142 | Use this type for yytranslate. | |
143 | * tests/torture.at (Big triangle): Push the limit from 124 to | |
144 | 253. | |
145 | * tests/regression.at (Web2c Actions): Adjust. | |
146 | ||
147 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
148 | ||
149 | * tests/torture.at (Big triangle): New. | |
150 | (GNU AWK Grammar, GNU Cim Grammar): Move to... | |
151 | * tests/existing.at: here. | |
152 | ||
153 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
154 | ||
155 | * src/gram.h, src/gram.c (nitems): Remove, it is an alias of | |
156 | nritems. | |
157 | Adjust dependencies. | |
158 | ||
159 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
160 | ||
161 | * src/reader.c: Normalize increments to prefix form. | |
162 | ||
163 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
164 | ||
165 | * src/reader.c, symtab.c: Remove debugging code. | |
166 | ||
167 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
168 | ||
169 | Rename all the `bucket's as `symbol_t'. | |
170 | ||
171 | * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c, | |
172 | * src/reader.c, src/reader.h, src/reduce.c, src/state.h, | |
173 | * src/symtab.c, src/symtab.h (bucket): Rename as... | |
174 | (symbol_t): this. | |
175 | (symbol_list_new, bucket_check_defined, bucket_make_alias) | |
176 | (bucket_check_alias_consistence, bucket_pack, bucket_translation) | |
177 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
178 | (buckets_new, buckets_free, buckets_do): Rename as... | |
179 | (symbol_list_new, symbol_check_defined, symbol_make_alias) | |
180 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
181 | (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t) | |
182 | (symbols_new, symbols_free, symbols_do): these. | |
183 | ||
184 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
185 | ||
186 | Use lib/hash for the symbol table. | |
187 | ||
188 | * src/gram.c (ntokens): Initialize to 1, to reserve a slot for | |
189 | EOF. | |
190 | * src/lex.c (lex): Set the `number' member of new terminals. | |
191 | * src/reader.c (bucket_check_defined, bucket_make_alias) | |
192 | (bucket_check_alias_consistence, bucket_translation): New. | |
193 | (reader, grammar_free, readgram, token_translations_init) | |
194 | (packsymbols): Adjust. | |
195 | (reader): Number the predefined tokens. | |
196 | * src/reduce.c (inaccessable_symbols): Just use hard coded numbers | |
197 | for predefined tokens. | |
198 | * src/symtab.h (bucket): Remove all the hash table related | |
199 | members. | |
200 | * src/symtab.c (symtab): Replace by... | |
201 | (bucket_table): this. | |
202 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
203 | (buckets_new, buckets_do): New. | |
204 | ||
205 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
206 | ||
207 | * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems) | |
208 | (start_symbol, max_user_token_number, semantic_parser) | |
209 | (error_token_number): Initialize. | |
210 | * src/reader.c (grammar, start_flag, startval, typed, lastprec): | |
211 | Initialize. | |
212 | (reader): Don't. | |
213 | (errtoken, eoftoken, undeftoken, axiom): Extern. | |
214 | ||
215 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
216 | ||
217 | * src/gram.h (rule_s): prec and precsym are now pointers | |
218 | to the bucket giving the priority/associativity. | |
219 | Member `associativity' removed: useless. | |
220 | * src/reduce.c, src/conflicts.c: Adjust. | |
221 | ||
222 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
223 | ||
224 | * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c: | |
225 | Properly escape the symbols' TAG when outputting them. | |
226 | ||
227 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
228 | ||
229 | * src/lalr.h (LA): Is a bitsetv, not bitset*. | |
230 | ||
231 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
232 | ||
233 | * src/lalr.h, src/lalr.c (LAruleno): Replace with... | |
234 | (LArule): this, which is an array to rule_t*. | |
235 | * src/print.c, src/conflicts.c: Adjust. | |
236 | ||
237 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
238 | ||
239 | * src/gram.h (rule_t): Rename `number' as `user_number'. | |
240 | `number' is a new member. | |
241 | Adjust dependencies. | |
242 | * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number. | |
243 | ||
244 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
245 | ||
246 | As a result of the previous patch, it is no longer needed | |
247 | to reorder ritem itself. | |
248 | ||
249 | * src/reduce.c (reduce_grammar_tables): Don't sort RITEM. | |
250 | ||
251 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
252 | ||
253 | Be sure never to walk through RITEMS, but use only data related to | |
254 | the rules themselves. RITEMS should be banished. | |
255 | ||
256 | * src/output.c (output_token_translations): Rename as... | |
257 | (prepare_tokens): this. | |
258 | In addition to `translate', prepare the muscles `tname' and | |
259 | `toknum', which were handled by... | |
260 | (output_rule_data): this. | |
261 | Remove, and move the remainder of its outputs into... | |
262 | (prepare_rules): this new routines, which also merges content from | |
263 | (output_gram): this. | |
264 | (prepare_rules): Be sure never to walk through RITEMS. | |
265 | (output_stos): Rename as... | |
266 | (prepare_stos): this. | |
267 | (output): Always invoke prepare_states, after all, just don't use it | |
268 | in the output if you don't need it. | |
269 | ||
270 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
271 | ||
272 | * src/LR0.c (new_state): Display `nstates' as the name of the | |
273 | newly created state. | |
274 | Adjust to initialize first_state and last_state if needed. | |
275 | Be sure to distinguish the initial from the final state. | |
276 | (new_states): Create the itemset of the initial state, and use | |
277 | new_state. | |
278 | * src/closure.c (closure): Now that the initial state has its | |
279 | items properly set, there is no need for a special case when | |
280 | creating `ruleset'. | |
281 | ||
282 | As a result, now the rule 0, reducing to $axiom, is visible in the | |
283 | outputs. Adjust the test suite. | |
284 | ||
285 | * tests/conflicts.at (Solved SR Conflicts) | |
286 | (Unresolved SR Conflicts): Adjust. | |
287 | * tests/regression.at (Web2c Report, Rule Line Numbers): Idem. | |
288 | * tests/conflicts.at (S/R in initial): New. | |
289 | ||
290 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
291 | ||
292 | * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over | |
293 | the RHS of the rules. | |
294 | * src/output.c (output_gram): Likewise. | |
295 | ||
296 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
297 | ||
298 | * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's | |
299 | bucket. | |
300 | Adjust all dependencies. | |
301 | * src/reduce.c (nonterminals_reduce): Don't forget to renumber the | |
302 | `number' of the buckets too. | |
303 | * src/gram.h: Include `symtab.h'. | |
304 | (associativity): Move to... | |
305 | * src/symtab.h: here. | |
306 | No longer include `gram.h'. | |
307 | ||
308 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
309 | ||
310 | * src/gram.h, src/gram.c (rules_rhs_length): New. | |
311 | (ritem_longest_rhs): Use it. | |
312 | * src/gram.h (rule_t): `number' is a new member. | |
313 | * src/reader.c (packgram): Set it. | |
314 | * src/reduce.c (reduce_grammar_tables): Move the useless rules at | |
315 | the end of `rules', and count them out of `nrules'. | |
316 | (reduce_output, dump_grammar): Adjust. | |
317 | * src/print.c (print_grammar): It is no longer needed to check for | |
318 | the usefulness of a rule, as useless rules are beyond `nrules + 1'. | |
319 | * tests/reduce.at (Reduced Automaton): New test. | |
320 | ||
321 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
322 | ||
323 | * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a | |
324 | lacking `+ 1' to nrules, Bison reported as useless a token if it | |
325 | was used solely to set the precedence of the last rule... | |
326 | ||
327 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
328 | ||
329 | * data/bison.c++, data/bison.simple: Don't output the current file | |
330 | name in #line, to avoid useless diffs between two identical | |
331 | outputs under different names. | |
332 | ||
333 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
334 | ||
335 | * src/closure.c, src/print.c, src/reader.c, src/reduce.c: | |
336 | Normalize loops to using `< nrules + 1', not `<= nrules'. | |
337 | ||
338 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
339 | ||
340 | * TODO: Update. | |
341 | ||
342 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
343 | ||
344 | * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename | |
345 | bucket.value as bucket.number. | |
346 | ||
347 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
348 | ||
349 | * src/closure.c, src/derives.c, src/gram.h, src/lalr.c, | |
350 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
351 | * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the | |
352 | RHS, instead of being an index in RITEMS. | |
353 | ||
354 | 2002-04-04 Paul Eggert <eggert@twinsun.com> | |
355 | ||
356 | * doc/bison.texinfo: Update copyright date. | |
357 | (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII. | |
358 | (Symbols): Warn about running Bison in one character set, | |
359 | but compiling and/or running in an incompatible one. | |
360 | Warn about character code 256, too. | |
361 | ||
362 | 2002-04-03 Paul Eggert <eggert@twinsun.com> | |
363 | ||
364 | * src/bison.data (YYSTACK_ALLOC): Depend on whether | |
365 | YYERROR_VERBOSE is nonzero, not whether it is defined. | |
366 | ||
367 | Merge changes from bison-1_29-branch. | |
368 | ||
369 | 2002-03-20 Paul Eggert <eggert@twinsun.com> | |
370 | ||
371 | Merge fixes from Debian bison_1.34-1.diff. | |
372 | ||
373 | * configure.in (AC_PREREQ): 2.53. | |
374 | ||
375 | 2002-03-20 Akim Demaille <akim@epita.fr> | |
376 | ||
377 | * src/conflicts.c (log_resolution): Argument `resolution' is const. | |
378 | ||
379 | 2002-03-19 Paul Eggert <eggert@twinsun.com> | |
380 | ||
381 | * src/bison.simple (YYCOPY): New macro. | |
382 | (YYSTACK_RELOCATE): Use it. | |
383 | Remove Type arg; no longer needed. All callers changed. | |
384 | (yymemcpy): Remove; no longer needed. | |
385 | ||
386 | * Makefile.am (AUTOMAKE_OPTIONS): 1.6. | |
387 | * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
388 | ||
389 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
390 | ||
391 | Test and fix the #line outputs. | |
392 | ||
393 | * tests/atlocal.at (GCC): New. | |
394 | * tests/synclines.at (AT_TEST_SYNCLINE): New macro. | |
395 | (Prologue synch line, ,%union synch line, Postprologue synch line) | |
396 | (Action synch line, Epilogue synch line): New tests. | |
397 | * src/reader.c (parse_union_decl): Define the muscle stype_line. | |
398 | * data/bison.simple, data/bison.c++: Use it. | |
399 | ||
400 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
401 | ||
402 | * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts) | |
403 | (Solved SR Conflicts, %expect not enough, %expect right) | |
404 | (%expect too much): Move to... | |
405 | * tests/conflicts.at: this new file. | |
406 | ||
407 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
408 | ||
409 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
410 | * data/bison.simple, data/bison.c++: Handle the `#define' part, so | |
411 | that we can move to enums for instance. | |
412 | * src/output.c (token_definitions_output): Output a list of | |
413 | `token-name, token-number' instead of the #define. | |
414 | (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'. | |
415 | ||
416 | 2002-03-14 Akim Demaille <akim@epita.fr> | |
417 | ||
418 | Use Gettext 0.11.1. | |
419 | ||
420 | 2002-03-09 Robert Anisko <robert@lrde.epita.fr> | |
421 | ||
422 | * data/bison.c++: Make the user able to add members to the generated | |
423 | parser by subclassing. | |
424 | ||
425 | 2002-03-05 Robert Anisko <robert@lrde.epita.fr> | |
426 | ||
427 | * src/reader.c (read_additionnal_code): `c' should be an integer, not | |
428 | a character. | |
429 | Reported by Nicolas Tisserand and Nicolas Burrus. | |
430 | ||
431 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
432 | ||
433 | * src/reader.c: Warn about lacking semi-colons, do not complain. | |
434 | ||
435 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
436 | ||
437 | * data/bison.c++: Remove a debug line. | |
438 | ||
439 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
440 | ||
441 | * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge | |
442 | location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and | |
443 | provide a default implementation. | |
444 | ||
445 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
446 | ||
447 | * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'. | |
448 | * tests/output.at (AT_CHECK_OUTPUT): Likewise. | |
449 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto. | |
450 | * tests/semantic.at (Parsing Guards): Similarly. | |
451 | * src/reader.at (readgram): Complain if the last rule is not ended | |
452 | with a semi-colon. | |
453 | ||
454 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
455 | ||
456 | * src/warshall.h, src/warshall.c (bitmatrix_print): Move to... | |
457 | * src/closure.c: here. | |
458 | (set_firsts): Use bitsetv_reflexive_transitive_closure instead of | |
459 | RTC. | |
460 | * src/warshall.h, src/warshall.c: Remove. | |
461 | * tests/sets.at (Broken Closure): Adjust. | |
462 | ||
463 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
464 | ||
465 | * src/output.c (output_skeleton): tempdir is const. | |
466 | bytes_read is unused. | |
467 | ||
468 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
469 | ||
470 | * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
471 | * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c: | |
472 | Update. | |
473 | From Michael Hayes. | |
474 | ||
475 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
476 | ||
477 | * src/closure.c (closure): `r' is unused. | |
478 | ||
479 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
480 | ||
481 | * tests/sets.at (Broken Closure): Add the ending `;'. | |
482 | * src/reader.at (readgram): Complain if a rule is not ended with a | |
483 | semi-colon. | |
484 | ||
485 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
486 | ||
487 | * src/conflicts.c (set_conflicts): Use bitset_disjoint_p. | |
488 | (count_sr_conflicts): Use bitset_count. | |
489 | * src/reduce.c (inaccessable_symbols): Ditto. | |
490 | (bits_size): Remove. | |
491 | * src/warshall.h, src/warshall.c: Convert to bitsetv. | |
492 | ||
493 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
494 | ||
495 | * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c, | |
496 | * src/reduce.c: Remove the `bitset_zero's following the | |
497 | `bitset_create's, as now it is performed by the latter. | |
498 | ||
499 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
500 | ||
501 | * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h, | |
502 | * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h, | |
503 | * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the | |
504 | latest sources from Michael. | |
505 | ||
506 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
507 | ||
508 | * src/output.c (output): Don't free the grammar. | |
509 | * src/reader.c (grammar_free): New. | |
510 | * src/main.c (main): Call it and don't free symtab here. | |
511 | ||
512 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
513 | ||
514 | * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer | |
515 | before returning. | |
516 | Reported by Benoit Perrot. | |
517 | ||
518 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
519 | ||
520 | Use bitset operations when possible, not loops over bits. | |
521 | ||
522 | * src/conflicts.c (set_conflicts, count_sr_conflicts): Use | |
523 | bitset_or. | |
524 | * src/print.c (print_reductions): Use bitset_and, bitset_andn. | |
525 | * src/reduce.c (useless_nonterminals): Formatting changes. | |
526 | * src/warshall.c (TC): Use bitset_or. | |
527 | ||
528 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
529 | ||
530 | * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused. | |
531 | * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET): | |
532 | Ditto. | |
533 | ||
534 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
535 | ||
536 | * src/lalr.c (F): Now a bitset*. | |
537 | Adjust all dependencies. | |
538 | ||
539 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
540 | ||
541 | * src/conflicts.c (shiftset, lookaheadset): Now bitset. | |
542 | Adjust all dependencies. | |
543 | ||
544 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
545 | ||
546 | * src/L0.c, src/LR0.h (nstates): Be size_t. | |
547 | Adjust comparisons (signed vs unsigned). | |
548 | * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a | |
549 | bitset*. | |
550 | Adjust all dependencies. | |
551 | ||
552 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
553 | ||
554 | * src/closure.c (firsts): Now, also a bitset. | |
555 | Adjust all dependencies. | |
556 | (varsetsize): Remove, now unused. | |
557 | * src/warshall.h, src/warshall.c: Now work on arrays of bitsets. | |
558 | ||
559 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
560 | ||
561 | * src/print.c: Convert to use bitset.h, not hand coded iterations | |
562 | over ints. | |
563 | ||
564 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
565 | ||
566 | * src/reduce.c: Convert to use bitset.h, not hand coded BSet. | |
567 | ||
568 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
569 | ||
570 | * src/closure.c (ruleset): Be a bitset. | |
571 | (rulesetsize): Remove. | |
572 | ||
573 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
574 | ||
575 | * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
576 | * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, | |
577 | * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New. | |
578 | * src/closure.c (fderives): Be an array of bitsets. | |
579 | ||
580 | 2002-02-28 Robert Anisko <robert@lrde.epita.fr> | |
581 | ||
582 | * data/bison.c++: Merge the two generated headers. Insert a copyright | |
583 | notice in each output file. | |
584 | ||
585 | 2002-02-28 Akim Demaille <akim@epita.fr> | |
586 | ||
587 | * data/bison.c++: Copy the prologue of bison.simple to fetch | |
588 | useful M4 definitions, such as b4_header_guard. | |
589 | ||
590 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
591 | ||
592 | * src/getargs.c (version): Give the name of the authors, and use a | |
593 | translator friendly scheme for the bgr | |
594 | copyright notice. | |
595 | ||
596 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
597 | ||
598 | * src/output.c (header_output): Remove, now handled completely via | |
599 | M4. | |
600 | ||
601 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
602 | ||
603 | * m4/m4.m4: New, from CVS Autoconf. | |
604 | * configure.in: Invoke it. | |
605 | * src/output.c (output_skeleton): Use its result instead of the | |
606 | hard coded name. | |
607 | ||
608 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
609 | ||
610 | * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from | |
611 | Fileutils 4.1.5. | |
612 | * configure.in: Invoke UTILS_FUNC_MKSTEMP. | |
613 | * src/output.c (output_skeleton): Use mkstemp to create a real | |
614 | temporary file. | |
615 | Move the filling of `skeleton' and its muscle to... | |
616 | (prepare): here. | |
617 | (output): Move the definition of the prologue muscle to... | |
618 | (prepare): here. | |
619 | * src/system.h (DEFAULT_TMPDIR): New. | |
620 | ||
621 | 2002-02-14 Paul Eggert <eggert@twinsun.com> | |
622 | ||
623 | Remove the support for C++ namespace cleanliness; it was | |
624 | causing more problems than it was curing, since it didn't work | |
625 | properly on some nonstandard C++ compilers. This can wait | |
626 | for a proper C++ parser. | |
627 | ||
628 | * NEWS: Document this. | |
629 | * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention | |
630 | of C++, as it's treated like C now. | |
631 | * src/bison.simple (YYSTD): Remove. | |
632 | (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL): | |
633 | Treat C++ just like Standard C instead of trying to support | |
634 | namespace cleanliness. | |
635 | ||
636 | 2002-02-14 Akim Demaille <akim@epita.fr> | |
637 | ||
638 | * tests/regression.at (else): Adjust to Andreas' change. | |
639 | ||
640 | 2002-02-14 Akim Demaille <akim@epita.fr> | |
641 | ||
642 | * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c. | |
643 | ||
644 | 2002-02-13 Andreas Schwab <schwab@suse.de> | |
645 | ||
646 | * src/output.c (output_rule_data): Don't output NULL, it might | |
647 | not be defined yet. | |
648 | ||
649 | 2002-02-11 Robert Anisko <robert@lrde.epita.fr> | |
650 | ||
651 | * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue. | |
652 | (Copyright notice): Update. | |
653 | ||
654 | 2002-02-11 Akim Demaille <akim@epita.fr> | |
655 | ||
656 | * tests/regression.at (%nonassoc and eof): Don't include | |
657 | nonportable headers. | |
658 | ||
659 | 2002-02-08 Robert Anisko <robert@lrde.epita.fr> | |
660 | ||
661 | * data/bison.c++: Correct error recovery. Make the user able to | |
662 | initialize the starting location. | |
663 | ||
664 | 2002-02-07 Akim Demaille <akim@epita.fr> | |
665 | ||
666 | * tests/input.at: New. | |
667 | ||
668 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
669 | ||
670 | * data/bison.c++: Replace some direct m4 expansions by constants. Be | |
671 | more consistent when naming methods and variables. Put preprocessor | |
672 | directives around tables only needed for debugging. | |
673 | ||
674 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
675 | ||
676 | * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in | |
677 | C++ parsers. | |
678 | (yy::b4_name::parse): Use print_. | |
679 | ||
680 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
681 | ||
682 | * data/bison.c++ (yy::b4_name::parse): Error recovery is back. | |
683 | ||
684 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
685 | ||
686 | * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in | |
687 | C++ parsers. | |
688 | (yy::b4_name::parse): Build verbose error messages, and use error_. | |
689 | ||
690 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> | |
691 | ||
692 | * data/bison.c++: Fix m4 quoting in comments. | |
693 | ||
694 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> | |
695 | ||
696 | * data/bison.c++: Adjust the parser code. Fix some muscles that were | |
697 | not expanded by m4. | |
698 | ||
699 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
700 | ||
701 | * data/bison.c++: Adjust to the M4 back end. | |
702 | More is certainly needed. | |
703 | ||
704 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
705 | ||
706 | Give a try to M4 as a back end. | |
707 | ||
708 | * lib/readpipe.c: New, from wdiff. | |
709 | * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and | |
710 | BISON_HAIRY. | |
711 | * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS | |
712 | specific values. Now it is m4 that performs the lookup. | |
713 | * src/parse-skel.y: Remove. | |
714 | * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New. | |
715 | * src/output.c (actions_output, guards_output) | |
716 | (token_definitions_output): No longer keeps track of the output | |
717 | line number, hence remove the second argument. | |
718 | (guards_output): Check against the guard member of a rule, not the | |
719 | action member. | |
720 | Adjust callers. | |
721 | (output_skeleton): Don't look for the skeleton location, let m4 do | |
722 | that. | |
723 | Create `/tmp/muscles.m4'. This is temporary, a proper temporary | |
724 | file will be used. | |
725 | Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton. | |
726 | (prepare): Given that for the time being changesyntax is not | |
727 | usable in M4, rename the muscles using `-' to `_'. | |
728 | Define `defines_flag', `output_parser_name' and `output_header_name'. | |
729 | * src/output.h (actions_output, guards_output) | |
730 | (token_definitions_output): Adjust prototypes. | |
731 | * src/scan-skel.l: Instead of scanning the skeletons, it now | |
732 | processes the output of m4: `__oline__' and `#output'. | |
733 | * data/bison.simple: Adjust to be used by M4(sugar). | |
734 | * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up | |
735 | to date. | |
736 | * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR' | |
737 | instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'. | |
738 | * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New, | |
739 | shamelessly stolen from CVS Autoconf. | |
740 | ||
741 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
742 | ||
743 | * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version. | |
744 | * configure.in: Check for the declarations of free and malloc. | |
745 | * src/muscle_tab.c: Adjust. | |
746 | ||
747 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
748 | ||
749 | * src/muscle_tab.c (muscle_init): Don't default to NULL muscle | |
750 | which have no values. | |
751 | ||
752 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
753 | ||
754 | * src/bison.simple, src/bison.hairy, src/bison.c++: Move to... | |
755 | * data/: here. | |
756 | ||
757 | 2002-01-29 Paul Eggert <eggert@twinsun.com> | |
758 | ||
759 | * src/bison.simple (YYSIZE_T): Do not define merely because | |
760 | YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined. | |
761 | On some platforms, <alloca.h> does not declare YYSTD (size_t). | |
762 | ||
763 | 2002-01-27 Akim Demaille <akim@epita.fr> | |
764 | ||
765 | Fix `%nonassoc and eof'. | |
766 | ||
767 | * src/state.c (errs_dup): Aaaah! The failure was due to bytes | |
768 | which were not properly copied! Replace | |
769 | memcpy (res->errs, src->errs, src->nerrs); | |
770 | with | |
771 | memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0])); | |
772 | !!! | |
773 | * tests/regression.at (%nonassoc and eof): Adjust to newest | |
774 | Autotest: `.' is not in the PATH. | |
775 | ||
776 | 2002-01-27 Akim Demaille <akim@epita.fr> | |
777 | ||
778 | * tests/sets.at (AT_EXTRACT_SETS): New. | |
779 | (Nullable): Use it. | |
780 | (Firsts): New. | |
781 | ||
782 | 2002-01-26 Akim Demaille <akim@epita.fr> | |
783 | ||
784 | * tests/actions.at, tests/calc.at, tests/headers.at, | |
785 | * tests/torture.at: Adjust to the newest Autotest which no longer | |
786 | forces `.' in the PATH. | |
787 | ||
788 | 2002-01-25 Akim Demaille <akim@epita.fr> | |
789 | ||
790 | * tests/regression.at (%nonassoc and eof): New. | |
791 | Suggested by Robert Anisko. | |
792 | ||
793 | 2002-01-24 Akim Demaille <akim@epita.fr> | |
794 | ||
795 | Bison dumps core when trying to complain about broken input files. | |
796 | Reported by Cris van Pelt. | |
797 | ||
798 | * src/lex.c (parse_percent_token): Be sure to set token_buffer. | |
799 | * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge | |
800 | into... | |
801 | (Invalid inputs): Strengthen: exercise parse_percent_token. | |
802 | ||
803 | 2002-01-24 Robert Anisko <robert.anisko@epita.fr> | |
804 | ||
805 | * src/Makefile.am: Add bison.c++. | |
806 | * src/bison.c++: New skeleton. | |
807 | ||
808 | 2002-01-21 Paolo Bonzini <bonzini@gnu.org> | |
809 | ||
810 | * po/it.po: New. | |
811 | ||
812 | 2002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net> | |
813 | ||
814 | * src/files.c (skeleton_find) [MSDOS]: Fix cp definition. | |
815 | ||
816 | 2002-01-20 Marc Autret <marc@gnu.org> | |
817 | ||
818 | * src/files.c (compute_output_file_names): Fix | |
819 | ||
820 | 2002-01-20 Marc Autret <marc@gnu.org> | |
821 | ||
822 | * tests/output.at: New test. | |
823 | * src/files.c (compute_base_names): Don't map extensions when | |
824 | the YACC flag is set, use defaults. | |
825 | Reported by Evgeny Stambulchik. | |
826 | ||
827 | 2002-01-20 Marc Autret <marc@gnu.org> | |
828 | ||
829 | * src/system.h: Need to define __attribute__ away for non-GCC | |
830 | compilers as well (i.e. the vendor C compiler). | |
831 | Suggested by Albert Chin-A-Young. | |
832 | ||
833 | 2002-01-11 Tim Van Holder <tim.van.holder@pandora.be> | |
834 | ||
835 | * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the | |
836 | canonical definition. | |
837 | * src/system.h: Use the canonical definition for PARAMS (avoids | |
838 | a conflict with the macro from lib/hash.h). | |
839 | ||
840 | 2002-01-11 Akim Demaille <akim@epita.fr> | |
841 | ||
842 | * configure.in: Use AC_FUNC_STRNLEN. | |
843 | Fixes the failures observed on AIX 4.3 by H.Merijn Brand. | |
844 | ||
845 | 2002-01-09 Akim Demaille <akim@epita.fr> | |
846 | ||
847 | * src/files.c, src/files.h (output_infix): New. | |
848 | (tab_extension): Remove. | |
849 | (compute_base_names): Compute the former, drop the latter. | |
850 | * src/output.c (prepare): Insert the muscles `output-infix', and | |
851 | `output-suffix'. | |
852 | * src/parse-skel.y (string, string.1): New. | |
853 | (section.header): Use it. | |
854 | (section.yacc): Remove. | |
855 | (prefix): Remove too. | |
856 | * src/scan-skel.l: Adjust. | |
857 | * src/bison.simple, src/bison.hairy: Adjust. | |
858 | ||
859 | 2002-01-09 Akim Demaille <akim@epita.fr> | |
860 | ||
861 | * configure.in (WERROR_CFLAGS): Compute it. | |
862 | * src/Makefile.am (CFLAGS): Pass it. | |
863 | * tests/atlocal.in (CFLAGS): Idem. | |
864 | * src/files.c: Fix a few warnings. | |
865 | (get_extension_index): Remove, unused. | |
866 | ||
867 | 2002-01-08 Akim Demaille <akim@epita.fr> | |
868 | ||
869 | * src/getargs.c (AS_FILE_NAME): New. | |
870 | (getargs): Use it to convert DOSish file names. | |
871 | * src/files.c (base_name): Rename as full_base_name to avoid | |
872 | clashes with `base_name ()'. | |
873 | (filename_split): New. | |
874 | (compute_base_names): N-th rewrite, using filename_split. | |
875 | ||
876 | 2002-01-08 Akim Demaille <akim@epita.fr> | |
877 | ||
878 | * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c: | |
879 | New, stolen from the Fileutils 4.1. | |
880 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
881 | * configure.in: Check for the presence of memrchr, and of its | |
882 | prototype. | |
883 | ||
884 | 2002-01-07 Tim Van Holder <tim.van.holder@pandora.be> | |
885 | ||
886 | * lib/hash.h (__P): Added definition for this macro. | |
887 | * src/Makefile.am: Add parse-skel.c and scan-skel.c to | |
888 | BUILT_SOURCES, to ensure they are generated first. | |
889 | * src/parse-skel.y: Use YYERROR_VERBOSE instead of | |
890 | %error-verbose to allow bootstrapping with bison 1.30x. | |
891 | ||
892 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
893 | ||
894 | * src/reader.c (parse_braces): Don't fetch the next char, the | |
895 | convention is to fetch on entry. | |
896 | * tests/torture.at (GNU Cim Grammar): Reintroduce their weird | |
897 | 'switch' without a following semicolon. | |
898 | * tests/regression.at (braces parsing): New. | |
899 | ||
900 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
901 | ||
902 | Bison is dead wrong in its RR conflict reports. | |
903 | ||
904 | * tests/torture.at (GNU Cim Grammar): New. | |
905 | * src/conflicts.c (count_rr_conflicts): Fix. | |
906 | ||
907 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
908 | ||
909 | Creating package.m4 from configure.ac causes too many problems. | |
910 | ||
911 | * tests/Makefile.am (package.m4): Create it by hand, | |
912 | AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf. | |
913 | ||
914 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
915 | ||
916 | * src/Makefile.am (bison_SOURCES): Add parse-skel.h and | |
917 | skeleton.h. | |
918 | ||
919 | 2002-01-04 Paul Eggert <eggert@twinsun.com> | |
920 | ||
921 | * doc/bison.texinfo (Debugging): | |
922 | Remove YYSTDERR; it's no longer defined or used. | |
923 | Also, s/cstdio.h/cstdio/. | |
924 | ||
925 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
926 | ||
927 | * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf. | |
928 | ||
929 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
930 | ||
931 | * src/parse-skel.y (process_skeleton): Don't bind the parser's | |
932 | tracing code to --trace, wait for a better --trace option, with | |
933 | args. | |
934 | ||
935 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
936 | ||
937 | * src/bison.simple (YYSTDERR): Remove, replace `stderr'. | |
938 | The ISO C++ standard is extremely clear about it: stderr is | |
939 | considered a macro, not a regular symbol (see table 94 `Header | |
940 | <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files). | |
941 | Therefore std:: does not apply to it. It still does with fprintf. | |
942 | Also, s/cstdio.h/cstdio/. | |
943 | ||
944 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
945 | ||
946 | * lib/quotearg.c: Use `#include "..."' instead of `#include <...>' | |
947 | for non system headers. | |
948 | ||
949 | 2002-01-02 Akim Demaille <akim@epita.fr> | |
950 | ||
951 | Equip the skeleton chain with location tracking, runtime trace, | |
952 | pure parser and scanner. | |
953 | ||
954 | * src/parse-skel.y: Request a pure parser, locations, and prefix | |
955 | renaming. | |
956 | (%union): Having several members with the same type does not help | |
957 | type mismatches, simplify. | |
958 | (YYPRINT, yyprint): New. | |
959 | (yyerror): ``Rename'' (there is a #define yyerror skel_error) as... | |
960 | (skel_error): this. | |
961 | Handle locations. | |
962 | * src/scan-skel.l: Adjust to these changes. | |
963 | * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP) | |
964 | (LOCATION_PRINT, skel_control_t): New. | |
965 | ||
966 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
967 | ||
968 | * src/parse-skel.y: Get rid of the shift/reduce conflict: | |
969 | replace `gb' with BLANKS. | |
970 | * src/scan-skel.l: Adjust. | |
971 | ||
972 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
973 | ||
974 | * src/system.h: We don't need nor want bcopy. | |
975 | Throw away MS-DOS crap: we don't need getpid. | |
976 | * configure.in: We don't need strndup. It was even causing | |
977 | problems: because Flex includes the headers *before* us, | |
978 | _GNU_SOURCE is not defined by config.h, and therefore strndup was | |
979 | not visible. | |
980 | * lib/xstrndup.c: New. | |
981 | * src/scan-skel.l: Use it. | |
982 | Be sure to initialize yylval.muscle member when scanning a MUSCLE. | |
983 | * src/parse-skel.y: Use %directives instead of #defines. | |
984 | ||
985 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
986 | ||
987 | * src/skeleton.h: New. | |
988 | * src/output.c (output_parser, output_master_parser): Remove, dead | |
989 | code. | |
990 | * src/output.h (get_lines_number, actions_output, guards_output) | |
991 | (token_definitions_output): Prototype them. | |
992 | * src/parse-skel.y: Add the license notice. | |
993 | Include output.h and skeleton.h. | |
994 | (process_skeleton): Returns void, and takes a single parameter. | |
995 | * src/scan-skel.l: Add the license notice. | |
996 | Include skeleton.h. | |
997 | Don't use %option yylineno: it seems that then Flex imagines | |
998 | REJECT has been used, and therefore it won't reallocate its | |
999 | buffers (which makes no other sense to me than a bug). It results | |
1000 | in warnings for `unused: yy_flex_realloc'. | |
1001 | ||
1002 | 2001-12-30 Robert Anisko <robert.anisko@epita.fr> | |
1003 | ||
1004 | * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
1005 | (MUSCLE_INSERT_PREFIX): ...to there. | |
1006 | * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
1007 | (MUSCLE_INSERT_PREFIX): Move from here... | |
1008 | ||
1009 | * src/bison.hairy: Add a section directive. Put braces around muscle | |
1010 | names. This parser skeleton is still broken, but Bison should not | |
1011 | choke on a bad muscle 'syntax'. | |
1012 | * src/bison.simple: Add a section directive. Put braces around muscle | |
1013 | names. | |
1014 | ||
1015 | * src/files.h (strsuffix, stringappend): Add declarations. | |
1016 | (tab_extension): Add declaration. | |
1017 | (short_base_name): Add declaration. | |
1018 | ||
1019 | * src/files.c (strsuffix, stringappend): No longer static. These | |
1020 | functions are used in the skeleton parser. | |
1021 | (tab_extension): New. | |
1022 | (compute_base_names): Use the computations done in this function | |
1023 | to guess if the generated parsers should have '.tab' in their | |
1024 | names. | |
1025 | (short_base_name): No longer static. | |
1026 | ||
1027 | * src/output.c (output_skeleton): New. | |
1028 | (output): Disable call to output_master_parser, and give a try to | |
1029 | a new skeleton handling system. | |
1030 | (guards_output, actions_output): No longer static. | |
1031 | (token_definitions_output, get_lines_number): No longer static. | |
1032 | ||
1033 | * configure.in: Use AM_PROG_LEX and AC_PROG_YACC. | |
1034 | ||
1035 | * src/Makefile.am (bison_SOURCES): Add scan-skel.l and | |
1036 | parse-skel.y. | |
1037 | ||
1038 | * src/parse-skel.y: New file. | |
1039 | * src/scan-skel.l: New file. | |
1040 | ||
1041 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1042 | ||
1043 | %name-prefix is broken. | |
1044 | ||
1045 | * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy". | |
1046 | Adjust all dependencies. | |
1047 | * tests/headers.at (export YYLTYPE): Strengthen this test: use | |
1048 | %name-prefix. | |
1049 | ||
1050 | Renaming yylval but not yylloc is not consistent. Now we do. | |
1051 | ||
1052 | * src/bison.simple: Prefix yylloc if used. | |
1053 | * doc/bison.texinfo (Decl Summary): Document that. | |
1054 | ||
1055 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1056 | ||
1057 | * doc/bison.texinfo: Promote `%long-directive' over | |
1058 | `%long_directive'. | |
1059 | Remove all references to fixed-output-files, yacc is enough. | |
1060 | ||
1061 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1062 | ||
1063 | * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the | |
1064 | user prologue. These are defaults. | |
1065 | * tests/actions.at (Mid-rule actions): Make sure the user can | |
1066 | define YYDEBUG and YYERROR_VERBOSE. | |
1067 | ||
1068 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1069 | ||
1070 | * src/output.c (header_output): Don't forget to export YYLTYPE and | |
1071 | yylloc. | |
1072 | * tests/headers.at (export YYLTYPE): New, make sure it does. | |
1073 | * tests/regression.at (%union and --defines, Invalid CPP headers): | |
1074 | Move to... | |
1075 | * tests/headers.at: here. | |
1076 | ||
1077 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1078 | ||
1079 | * src/gram.h (rule_s): Member `assoc' is of type `associativity'. | |
1080 | ||
1081 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1082 | ||
1083 | * tests/actions.at (Mid-rule actions): Output on a single line | |
1084 | instead of several. | |
1085 | ||
1086 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1087 | ||
1088 | * doc/bison.texinfo: Formatting changes. | |
1089 | ||
1090 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1091 | ||
1092 | Don't store the token defs in a muscle, just be ready to output it | |
1093 | on command. Now possible via `symbols'. Fixes a memory leak. | |
1094 | ||
1095 | * src/output.c (token_definitions_output): New. | |
1096 | (output_parser, header_output): Use it. | |
1097 | * src/reader.c (symbols_save): Remove. | |
1098 | ||
1099 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1100 | ||
1101 | * src/bison.simple: Do not provide a default for YYSTYPE and | |
1102 | YYLTYPE before the user's prologue. Otherwise it's hardly... a | |
1103 | default. | |
1104 | ||
1105 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1106 | ||
1107 | Mid-rule actions are simply... ignored! | |
1108 | ||
1109 | * src/reader.c (readgram): Be sure to attach mid-rule actions to | |
1110 | the empty-rule associated to the dummy symbol, not to the host | |
1111 | rule. | |
1112 | * tests/actions.at (Mid-rule actions): New. | |
1113 | ||
1114 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1115 | ||
1116 | Memory leak. | |
1117 | ||
1118 | * src/reader.c (reader): Free grammar. | |
1119 | ||
1120 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1121 | ||
1122 | Memory leak. | |
1123 | ||
1124 | * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here, | |
1125 | since it allocates it for each state, although only one is needed. | |
1126 | (allocate_storage): Do it here. | |
1127 | ||
1128 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1129 | ||
1130 | * src/options.h, src/options.c (create_long_option_table): Rename | |
1131 | as... | |
1132 | (long_option_table_new): this, with a clearer prototype. | |
1133 | (percent_table): Remove, unused, | |
1134 | * src/getargs.c (getargs): Adjust. | |
1135 | ||
1136 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1137 | ||
1138 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c | |
1139 | * src/print.c, src/print_graph.c, src/state.h: Rename state_table | |
1140 | as states. | |
1141 | ||
1142 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1143 | ||
1144 | * src/lalr.c (build_relations): Rename `states' as `states1'. | |
1145 | Sorry, I don't understand exactly what it is, no better name... | |
1146 | ||
1147 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1148 | ||
1149 | * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c | |
1150 | * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c | |
1151 | * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table | |
1152 | as rules. | |
1153 | ||
1154 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1155 | ||
1156 | * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long | |
1157 | ago. | |
1158 | ||
1159 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1160 | ||
1161 | * src/reader.c, src/reader.h (user_toknums): Remove. | |
1162 | Adjust all users to use symbols[i]->user_token_number. | |
1163 | ||
1164 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1165 | ||
1166 | * src/gram.c, src/gram.h (sprec, sassoc): Remove. | |
1167 | Adjust all users to use symbols[i]->prec or ->assoc. | |
1168 | ||
1169 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1170 | ||
1171 | * src/reader.c, src/reader.h (tags): Remove. | |
1172 | Adjust all users to use symbols[i]->tag. | |
1173 | ||
1174 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1175 | ||
1176 | * src/gram.h, src/gram.c (symbols): New, similar to state_table | |
1177 | and rule_table. | |
1178 | * src/reader.c (packsymbols): Fill this table. | |
1179 | Drop sprec. | |
1180 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
1181 | * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a | |
1182 | single table. | |
1183 | Use symbols[i]->tag instead of tags[i]. | |
1184 | ||
1185 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1186 | ||
1187 | * tests/calc.at (_AT_DATA_CALC_Y): Also use %union. | |
1188 | In addition, put a comment in there, to replace... | |
1189 | * tests/regression.at (%union and C comments): Remove. | |
1190 | ||
1191 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1192 | ||
1193 | * tests/regression.at (Web2c Actions): Blindly move the actual | |
1194 | output as expected output. The contents *seem* right to me, but I | |
1195 | can't pretend reading perfectly parser tables... Nonetheless, all | |
1196 | the other tests pass correctly, the table look OK, even though the | |
1197 | presence of `$axiom' is to be noted: AFAICS it is useless (but | |
1198 | harmless). | |
1199 | ||
1200 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1201 | ||
1202 | * src/reader.c (readgram): Don't add the rule 0 if there were no | |
1203 | rules read. In other words, add it _after_ having performed | |
1204 | grammar sanity checks. | |
1205 | Fixes the `tests/regression.at (Invalid input: 1)' Failure. | |
1206 | ||
1207 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1208 | ||
1209 | * tests/regression.at (Web2c Report): Catch up: the rule 0 is now | |
1210 | visible, and some states have now a different number. | |
1211 | ||
1212 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1213 | ||
1214 | * src/reader.c (readgram): Bind the initial rule's lineno to that | |
1215 | of the first rule. | |
1216 | * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts): | |
1217 | (Solved SR Conflicts): Adjust rule 0's line number. | |
1218 | ||
1219 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1220 | ||
1221 | Fix the `GAWK Grammar' failure. | |
1222 | ||
1223 | * src/LR0.c (final_state): Initialize to -1 so that we do compute | |
1224 | the reductions of the first state which was mistakenly confused | |
1225 | with the final state because precisely final_state was initialized | |
1226 | to 0. | |
1227 | * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads, | |
1228 | now noticed by Bison. | |
1229 | * tests/regression.at (Rule Line Numbers): Adjust: state 0 does | |
1230 | have a reduction on $default. | |
1231 | ||
1232 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1233 | ||
1234 | * src/gram.c (ritem_print): Be sure to subtract 1 when displaying | |
1235 | rule line numbers. | |
1236 | * src/closure.c (print_closure): Likewise. | |
1237 | * src/derives.c (print_derives): Likewise. | |
1238 | * tests/sets.at (Nullable): Adjust: the rule numbers are correct | |
1239 | now. | |
1240 | ||
1241 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1242 | ||
1243 | * src/lalr.c (lookaheads_print): New. | |
1244 | (lalr): Call it when --trace-flag. | |
1245 | * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads | |
1246 | are dumped. | |
1247 | ||
1248 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1249 | ||
1250 | * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0', | |
1251 | when walking through ritem, even via rule->rhs. | |
1252 | * src/reduce.c (dump_grammar, useful_production, reduce_output) | |
1253 | (useful_production, useless_nonterminals): Likewise. | |
1254 | (reduce_grammar_tables): Likewise, plus update nritems. | |
1255 | * src/nullable.c (set_nullable): Likewise. | |
1256 | * src/lalr.c (build_relations): Likewise. | |
1257 | * tests/sets.at (Nullable): Adjust. | |
1258 | Fortunately, now, the $axiom is no longer nullable. | |
1259 | ||
1260 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1261 | ||
1262 | * src/LR0.c (generate_states): Use nritems, not nitems, nor using | |
1263 | the 0-sentinel. | |
1264 | * src/gram.c (ritem_longest_rhs): Likewise. | |
1265 | * src/reduce.c (nonterminals_reduce): Likewise. | |
1266 | * src/print_graph.c (print_graph): Likewise. | |
1267 | * src/output.c (output_rule_data): Likewise. | |
1268 | * src/nullable.c (set_nullable): Likewise. | |
1269 | ||
1270 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
1271 | ||
1272 | * src/output.c: Comment changes. | |
1273 | ||
1274 | 2001-12-27 Paul Eggert <eggert@twinsun.com> | |
1275 | ||
1276 | * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special | |
1277 | cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and | |
1278 | Sparc, as they were causing more porting problems than the | |
1279 | (minor) performance improvement was worth. | |
1280 | ||
1281 | Also, catch up with 1.31's YYSTD. | |
1282 | ||
1283 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1284 | ||
1285 | * src/output.c (output_gram): Rely on nritems, not the | |
1286 | 0-sentinel. See below. | |
1287 | Use -1 as separator, not 0. | |
1288 | * src/bison.simple (yyparse): Subtract 1 to the rule numbers. | |
1289 | Rely on -1 as separator in yyrhs, instead of 0. | |
1290 | * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue | |
1291 | twice `Now at end of input', therefore there are two lines less to | |
1292 | expect. | |
1293 | ||
1294 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1295 | ||
1296 | * tests/regression.at (Unresolved SR Conflicts): | |
1297 | (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes | |
1298 | below. | |
1299 | ||
1300 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1301 | ||
1302 | * src/LR0.c (new_state): Recognize the final state by the fact it | |
1303 | is reached by eoftoken. | |
1304 | (insert_start_shifting_state, insert_eof_shifting_state) | |
1305 | (insert_accepting_state, augment_automaton): Remove, since now | |
1306 | these states are automatically computed from the initial state. | |
1307 | (generate_states): Adjust. | |
1308 | * src/print.c: When reporting a rule number to the user, substract | |
1309 | 1, so that the axiom rule is rule 0, and the first user rule is 1. | |
1310 | * src/reduce.c: Likewise. | |
1311 | * src/print_graph.c (print_core): For the time being, just as for | |
1312 | the report, depend upon --trace-flags to dump the full set of | |
1313 | items. | |
1314 | * src/reader.c (readgram): Once the grammar read, insert the rule | |
1315 | 0: `$axiom: START-SYMBOL $'. | |
1316 | * tests/set.at: Adjust: rule 0 is now displayed, and since the | |
1317 | number of the states has changed (the final state is no longer | |
1318 | necessarily the last), catch up. | |
1319 | ||
1320 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1321 | ||
1322 | Try to make the use of the eoftoken valid. Given that its value | |
1323 | is 0 which was also used as a sentinel in ritem, (i) make sure >= 0 | |
1324 | is used instead of > 0 where appropriate, (ii), depend upon nritems | |
1325 | instead of the 0-sentinel. | |
1326 | ||
1327 | * src/gram.h, src/gram.c (nritems): New. | |
1328 | Expected to be duplication of nitems, but for the time being... | |
1329 | * src/reader.c (packgram): Assert nritems and nitems are equal. | |
1330 | * src/LR0.c (allocate_itemsets, new_itemsets): Adjust. | |
1331 | * src/closure.c (print_closure, print_fderives): Likewise. | |
1332 | * src/gram.c (ritem_print): Likewise. | |
1333 | * src/print.c (print_core, print_grammar): Likewise. | |
1334 | * src/print_graph.c: Likewise. | |
1335 | ||
1336 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1337 | ||
1338 | * src/main.c (main): If there are complains after grammar | |
1339 | reductions, then output the report anyway if requested, then die. | |
1340 | * src/symtab.c (bucket_new): Initialize `value' to -1, not 0. | |
1341 | * src/reader.c (eoftoken): New. | |
1342 | (parse_token_decl): If the token being defined has value `0', it | |
1343 | is the eoftoken. | |
1344 | (packsymbols): No longer hack `tags' to insert `$' by hand. | |
1345 | Be sure to preserve the value of the eoftoken. | |
1346 | (reader): Make sure eoftoken is defined. | |
1347 | Initialize nsyms to 0: now eoftoken is created just like the others. | |
1348 | * src/print.c (print_grammar): Don't special case the eof token. | |
1349 | * src/regression.at: Adjust: `$' has value 0, not -1, which was a | |
1350 | lie anyway, albeit pleasant. | |
1351 | * tests/calc.at: Exercise error messages with eoftoken. | |
1352 | Change the grammar so that empty input is invalid. | |
1353 | Adjust expectations. | |
1354 | When yyungeting, be sure to use a valid yylloc: use last_yylloc. | |
1355 | ||
1356 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1357 | ||
1358 | * configure.in: Check the protos of strchr ans strspn. | |
1359 | Replace strchr if needed. | |
1360 | * src/system.h: Provide the protos of strchr, strspn and memchr if | |
1361 | missing. | |
1362 | * lib/strchr.c: New. | |
1363 | * src/reader.c (symbols_save): Use strchr. | |
1364 | ||
1365 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1366 | ||
1367 | * src/print.c, src/print_graph.c (escape): New. | |
1368 | Use it to quote the TAGS outputs. | |
1369 | * src/print_graph.c (print_state): Now errors are in red, and | |
1370 | reductions in green. | |
1371 | Prefer high to wide: output the state number on a line of its own. | |
1372 | ||
1373 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1374 | ||
1375 | * src/state.h, src/state.c (reductions_new): New. | |
1376 | * src/LR0.c (set_state_table): Let all the states have a | |
1377 | `reductions', even if reduced to 0. | |
1378 | (save_reductions): Adjust. | |
1379 | * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust. | |
1380 | * src/print.c (print_reductions, print_actions): Adjust. | |
1381 | * src/output.c (action_row): Adjust. | |
1382 | ||
1383 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1384 | ||
1385 | * src/state.h, src/state.c (errs_new, errs_dup): New. | |
1386 | * src/LR0.c (set_state_table): Let all the states have an errs, | |
1387 | even if reduced to 0. | |
1388 | * src/print.c (print_errs, print_reductions): Adjust. | |
1389 | * src/output.c (output_actions, action_row): Adjust. | |
1390 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
1391 | ||
1392 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1393 | ||
1394 | * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL. | |
1395 | ||
1396 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1397 | ||
1398 | * src/conflicts.c, src/conflicts.h (print_reductions): Move to... | |
1399 | * src/print.c: here. | |
1400 | (lookaheadset, shiftset): New, used as additional storage by | |
1401 | print_reductions. | |
1402 | (print_results): Adjust. | |
1403 | (print_shifts, print_gotos, print_errs): New, extracted from... | |
1404 | (print_actions): here. | |
1405 | * src/print_graph.c (print_actions): Remove dead code. | |
1406 | ||
1407 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1408 | ||
1409 | * src/reader.c (copy_dollar, copy_at): Better checking of `n' in | |
1410 | `$n' and `@n'. | |
1411 | ||
1412 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1413 | ||
1414 | * src/lalr.c (add_lookback_edge): Use state_t instead of ints. | |
1415 | (build_relations): Adjust. | |
1416 | ||
1417 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1418 | ||
1419 | * src/lalr.c (set_goto_map): Remove a wrong but benign loop | |
1420 | duplication. | |
1421 | ||
1422 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1423 | ||
1424 | * src/reader.c (packgram): Catch nitems overflows. | |
1425 | ||
1426 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1427 | ||
1428 | * src/files.c, src/files.h (guard_obstack): Remove. | |
1429 | * src/output.c (output): Adjust. | |
1430 | * src/reader.c (parse_braces): New, factoring... | |
1431 | (copy_action, copy_guard): these two which are renamed as... | |
1432 | (parse_action, parse_guard): these. | |
1433 | As a voluntary consequence, using braces around guards is now | |
1434 | mandatory. | |
1435 | ||
1436 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1437 | ||
1438 | * src/gram.h (rule_t): `guard' and `guard_line' are new members. | |
1439 | * src/reader.c (symbol_list): `guard' and `guard_line' are new | |
1440 | members. | |
1441 | (symbol_list_new): Adjust. | |
1442 | (copy_action): action_line is the first line, not the last. | |
1443 | (copy_guard): Just as for actions, store the `action' only, not | |
1444 | the switch/case/break flesh. | |
1445 | Don't parse the user action that might follow the guard, let... | |
1446 | (readgram): do it, i.e., now, there can be an action after a | |
1447 | guard. | |
1448 | In other words the guard is just explicitly optional. | |
1449 | (packgram): Adjust. | |
1450 | * src/output.c (guards_output): New. | |
1451 | (output_parser): Call it when needed. | |
1452 | (output): Also free the guard and attrs obstacks. | |
1453 | * src/files.c, src/files.h (obstack_save): Remove. | |
1454 | (output_files): Remove. | |
1455 | As a result, if one needs the former `.act' file, using an | |
1456 | appropriate skeleton which requires actions and guards is now | |
1457 | required. | |
1458 | * src/main.c (main): Adjust. | |
1459 | * tests/semantic.at: New. | |
1460 | * tests/regression.at: Use `input.y' as input file name. | |
1461 | Avoid 8+3 problems by requiring input.c when the test needs the | |
1462 | parser. | |
1463 | ||
1464 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1465 | ||
1466 | * src/reader.c (symbol_list_new): Be sure to initialize all the | |
1467 | fields. | |
1468 | ||
1469 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1470 | ||
1471 | All the hacks using a final pseudo state are now useless. | |
1472 | ||
1473 | * src/LR0.c (set_state_table): state_table holds exactly nstates. | |
1474 | * src/lalr.c (nLA): New. | |
1475 | (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it | |
1476 | instead of lookaheadsp from the pseudo state (nstate + 1). | |
1477 | ||
1478 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1479 | ||
1480 | * src/output.c (action_row, token_actions): Use a state_t instead | |
1481 | of a integer, and nlookaheads instead of the following state's | |
1482 | lookaheadsp. | |
1483 | ||
1484 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1485 | ||
1486 | * src/conflicts.c (log_resolution, flush_shift) | |
1487 | (resolve_sr_conflict, set_conflicts, solve_conflicts) | |
1488 | (count_sr_conflicts, count_rr_conflicts, conflicts_output) | |
1489 | (conflicts_print, print_reductions): Use a state_t instead of an | |
1490 | integer when referring to a state. | |
1491 | As much as possible, depend upon nlookaheads, instead of the | |
1492 | `lookaheadsp' member of the following state (since lookaheads of | |
1493 | successive states are successive, the difference between state n + 1 | |
1494 | and n served as the number of lookaheads for state n). | |
1495 | * src/lalr.c (add_lookback_edge): Likewise. | |
1496 | * src/print.c (print_core, print_actions, print_state) | |
1497 | (print_results): Likewise. | |
1498 | * src/print_graph.c (print_core, print_actions, print_state) | |
1499 | (print_graph): Likewise. | |
1500 | * src/conflicts.h: Adjust. | |
1501 | ||
1502 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1503 | ||
1504 | * src/bison.hairy: Formatting/comment changes. | |
1505 | ANSIfy. | |
1506 | Remove `register' indications. | |
1507 | Add plenty of `static'. | |
1508 | ||
1509 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
1510 | ||
1511 | * src/output.c (prepare): Drop the muscle `ntbase' which | |
1512 | duplicates ntokens. | |
1513 | * src/bison.simple: Formatting/comment changes. | |
1514 | Use YYNTOKENS only, which is documented, but not YYNTBASE, which | |
1515 | is an undocumented synonym. | |
1516 | ||
1517 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
1518 | ||
1519 | * src/output.c (output_table_data): Change the prototype to use | |
1520 | `int' for array ranges: some invocations do pass an int, not a | |
1521 | short. | |
1522 | Reported by Wayne Green. | |
1523 | ||
1524 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
1525 | ||
1526 | Some actions of web2c.y are improperly triggered. | |
1527 | Reported by Mike Castle. | |
1528 | ||
1529 | * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/. | |
1530 | * tests/regression.at (Web2c): Rename as... | |
1531 | (Web2c Report): this. | |
1532 | (Web2c Actions): New. | |
1533 | ||
1534 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
1535 | ||
1536 | Reductions in web2c.y are improperly reported. | |
1537 | Reported by Mike Castle. | |
1538 | ||
1539 | * src/conflicts.c (print_reductions): Fix. | |
1540 | * tests/regression.at (Web2c): New. | |
1541 | ||
1542 | 2001-12-18 Akim Demaille <akim@epita.fr> | |
1543 | ||
1544 | Some host fail on `assert (!"foo")', which expands to | |
1545 | ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__)) | |
1546 | Reported by Nelson Beebee. | |
1547 | ||
1548 | * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with | |
1549 | `#define it_succeeded 0' and `assert (it_succeeded)'. | |
1550 | ||
1551 | 2001-12-17 Marc Autret <autret_m@epita.fr> | |
1552 | ||
1553 | * src/bison.simple: Don't hard code the skeleton line and filename. | |
1554 | * src/output.c (output_parser): Rename 'line' as 'output_line'. | |
1555 | New line counter 'skeleton_line' (skeleton-line muscle). | |
1556 | ||
1557 | 2001-12-17 Paul Eggert <eggert@twinsun.com> | |
1558 | ||
1559 | * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that | |
1560 | YYDEBUG must be defined to a nonzero value. | |
1561 | ||
1562 | * src/bison.simple (yytname): Do not assume that the user defines | |
1563 | YYDEBUG to a properly parenthesized expression. | |
1564 | ||
1565 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1566 | ||
1567 | * src/state.h (state_t): Rename lookaheads as lookaheadsp. | |
1568 | nlookaheads is a new member. | |
1569 | Adjust all users. | |
1570 | * src/lalr.h (nlookaheads): Remove this orphan declaration. | |
1571 | * src/lalr.c (initialize_lookaheads): Set nlookaheads for each | |
1572 | state. | |
1573 | ||
1574 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1575 | ||
1576 | * src/files.h, src/files.c (open_files, close_files): Remove. | |
1577 | * src/main.c (main): Don't open/close files, nor invoke lex_free, | |
1578 | let... | |
1579 | * src/reader.c (reader): Do it. | |
1580 | ||
1581 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1582 | ||
1583 | * src/conflicts.c (print_reductions): Formatting changes. | |
1584 | ||
1585 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1586 | ||
1587 | * src/conflicts.c (flush_shift): Also adjust lookaheadset. | |
1588 | (flush_reduce): New. | |
1589 | (resolve_sr_conflict): Adjust. | |
1590 | ||
1591 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1592 | ||
1593 | * src/output.c (output_obstack): Be static and rename as... | |
1594 | (format_obstack): this, to avoid any confusion with files.c's | |
1595 | output_obstack. | |
1596 | * src/reader.h (muscle_obstack): Move to... | |
1597 | * src/output.h: here, since it's defined in output.c. | |
1598 | ||
1599 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1600 | ||
1601 | * src/output.c (action_row, save_column, default_goto) | |
1602 | (sort_actions, matching_state, pack_vector): Better variable | |
1603 | locality. | |
1604 | ||
1605 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1606 | ||
1607 | * src/output.c: Various formatting changes. | |
1608 | ||
1609 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
1610 | ||
1611 | * src/files.c (output_files): Free the output_obstack. | |
1612 | * src/main.c (main): Call print and print_graph conditionally. | |
1613 | * src/print.c (print): Work unconditionally. | |
1614 | * src/print_graph.c (print_graph): Work unconditionally. | |
1615 | * src/conflicts.c (log_resolution): Output only if verbose_flag. | |
1616 | ||
1617 | 2001-12-16 Marc Autret <autret_m@epita.fr> | |
1618 | ||
1619 | * src/output.c (actions_output): Fix. When we use %no-lines, | |
1620 | there is one less line per action. | |
1621 | ||
1622 | 2001-12-16 Marc Autret <autret_m@epita.fr> | |
1623 | ||
1624 | * src/bison.simple: Remove a useless #line directive. | |
1625 | s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'. | |
1626 | * src/output.c (get_lines_number): New. | |
1627 | (output_parser): Adjust, now takes care about the lines of a | |
1628 | output muscles. | |
1629 | Fix line numbering. | |
1630 | (actions_output): Computes the number of lines taken by actions. | |
1631 | (output_master_parser): Insert new skeleton which is the name of | |
1632 | the output parser file name. | |
1633 | ||
1634 | 2001-12-15 Marc Autret <autret_m@epita.fr> | |
1635 | ||
1636 | * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility. | |
1637 | ||
1638 | 2001-12-15 Marc Autret <autret_m@epita.fr> | |
1639 | ||
1640 | * src/output.c (output_gram): Keep track of the hairy one. | |
1641 | ||
1642 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1643 | ||
1644 | Make `make distcheck' work. | |
1645 | ||
1646 | * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses | |
1647 | system.h which uses libgettext.h. | |
1648 | ||
1649 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1650 | ||
1651 | * src/nullable.c (set_nullable): Useless rules must be skipped, | |
1652 | otherwise, since we range over their symbols, we might look at a | |
1653 | nonterminal which no longer ``exists'', i.e., it is not counted in | |
1654 | `nvars', hence we overflow our arrays. | |
1655 | ||
1656 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1657 | ||
1658 | The header can also be produced directly, without any obstack! | |
1659 | Yahoo! | |
1660 | ||
1661 | * src/files.c, src/files.h (defines_obstack): Remove. | |
1662 | (compute_header_macro): Global. | |
1663 | (defines_obstack_save): Remove. | |
1664 | * src/reader.c (parse_union_decl): No longer output to | |
1665 | defines_obstack: its content can be found in the `stype' muscle | |
1666 | anyway. | |
1667 | (output_token_translations): Merge into... | |
1668 | (symbols_output): this. | |
1669 | Rename as... | |
1670 | (symbols_save): this. | |
1671 | (reader): Adjust. | |
1672 | * src/output.c (header_output): New. | |
1673 | (output): Call it. | |
1674 | ||
1675 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1676 | ||
1677 | * src/reader.c (parse_union_decl): Instead of handling two obstack | |
1678 | simultaneously, use one to define the `stype' muscle, and use the | |
1679 | value of the latter to fill defines_obstack. | |
1680 | (copy_comment): Remove. | |
1681 | (copy_comment2): Work for a single obstack. | |
1682 | Rename as... | |
1683 | (copy_comment): this. | |
1684 | ||
1685 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1686 | ||
1687 | * src/lex.c, src/lex.h (xgetc): No longer static. | |
1688 | * src/reader.c (parse_union_decl): Revamp. | |
1689 | ||
1690 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1691 | ||
1692 | Still making progress in separating Bison into (i) input, (ii) | |
1693 | process, (iii) output: now we can directly output the parser file | |
1694 | without using table_obstack at all. | |
1695 | ||
1696 | * src/files.c, src/files.h (table_obstack): Bye bye. | |
1697 | (parser_file_name): New. | |
1698 | * src/files.c (compute_output_file_names): Compute it. | |
1699 | * src/output.c (actions_output, output_parser) | |
1700 | (output_master_parser): To a file instead of an obstack. | |
1701 | ||
1702 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1703 | ||
1704 | Attach actions to rules, instead of pre-outputting them to | |
1705 | actions_obstack. | |
1706 | ||
1707 | * src/gram.h (rule_t): action and action_line are new members. | |
1708 | * src/reader.c (symbol_list): Likewise. | |
1709 | (copy_action): Save the actions within the rule. | |
1710 | (packgram): Save them in rule_table. | |
1711 | * src/output.c (actions_output): New. | |
1712 | (output_parser): Use it on `%%actions'. | |
1713 | (output_rule_data): Don't free rule_table. | |
1714 | (output): Do it. | |
1715 | (prepare): Don't save the `action' muscle. | |
1716 | * src/bison.simple: s/%%action/%%actions/. | |
1717 | ||
1718 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
1719 | ||
1720 | * src/reader.c (copy_action): When --yacc, don't append a `;' | |
1721 | to the user action: let it fail if lacking. | |
1722 | Suggested by Arnold Robbins and Tom Tromey. | |
1723 | ||
1724 | 2001-12-14 Akim Demaille <akim@epita.fr> | |
1725 | ||
1726 | * src/lex.c (literalchar): Simply return the char you decoded, non | |
1727 | longer mess around with obstacks and int pointers. | |
1728 | Adjust all callers. | |
1729 | ||
1730 | 2001-12-14 Akim Demaille <akim@epita.fr> | |
1731 | ||
1732 | * src/lex.c (literalchar): Don't escape the special characters, | |
1733 | just decode them, and keep them as char (before, eol was output as | |
1734 | the 2 char string `\n' etc.). | |
1735 | * src/output.c (output_rule_data): Use quotearg to output the | |
1736 | token strings. | |
1737 | ||
1738 | 2001-12-13 Paul Eggert <eggert@twinsun.com> | |
1739 | ||
1740 | * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE): | |
1741 | Do not infringe on the global user namespace when using C++. | |
1742 | (YYFPRINTF, YYSTDERR): New macros, needed for the above. | |
1743 | All uses of `fprintf' and `stderr' changed. | |
1744 | ||
1745 | * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR. | |
1746 | ||
1747 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
1748 | ||
1749 | The computation of nullable is broken: it doesn't handle empty | |
1750 | RHS's properly. | |
1751 | ||
1752 | * tests/torture.at (GNU AWK Grammar): New. | |
1753 | * tests/sets.at (Nullable): New. | |
1754 | * src/nullable.c (set_nullable): Instead of blindly looping over | |
1755 | `ritems', loop over the rules, and then over their rhs's. | |
1756 | ||
1757 | Work around Autotest bugs. | |
1758 | ||
1759 | * src/warshall.c (bitmatrix_print): Don't use `+--+' as table | |
1760 | frame, because Autotest understand lines starting with a `+' as | |
1761 | traces from the shell. Then, they are not processed properly. | |
1762 | Admittedly an Autotest bug, but we don't have time to wait for | |
1763 | Autotest to catch up. | |
1764 | * tests/regression.at (Broken Closure): Adjust to the new table | |
1765 | frames. | |
1766 | Move to... | |
1767 | * tests/sets.at: here. | |
1768 | ||
1769 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
1770 | ||
1771 | * src/closure.c (closure): Use nrules instead of playing tricks | |
1772 | with BITS_PER_WORD. | |
1773 | ||
1774 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
1775 | ||
1776 | * src/print.c (print_actions): Output the handling of `$' as the | |
1777 | traces do: shifting the token EOF. Before EOF was treated as a | |
1778 | nonterminal. | |
1779 | * tests/regression.at: Adjust some tests. | |
1780 | * src/print_graph.c (print_core): Complete the set of items via | |
1781 | closure. The next-to-final and final states are still unsatisfying, | |
1782 | but that's to be addressed elsewhere. | |
1783 | No longer output the rule numbers, but do output the state number. | |
1784 | A single loop for the shifts + gotos is enough, but picked a | |
1785 | distinct color for each. | |
1786 | (print_graph): Initialize and finalize closure. | |
1787 | ||
1788 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
1789 | ||
1790 | * src/reader.c (readgram): Remove dead code, an strip useless | |
1791 | braces. | |
1792 | (get_type): Remove, unused. | |
1793 | ||
1794 | 2001-12-12 Akim Demaille <akim@epita.fr> | |
1795 | ||
1796 | * src/complain.h, src/complain.c: Remove error_one_per_line, rely | |
1797 | on that of lib/error.c. | |
1798 | ||
1799 | 2001-12-12 Akim Demaille <akim@epita.fr> | |
1800 | ||
1801 | Some hosts don't like `/' in includes. | |
1802 | ||
1803 | * src/system.h: Include libgettext.h without qualifying the path. | |
1804 | * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove | |
1805 | $(top_srcdir). | |
1806 | ||
1807 | 2001-12-11 Marc Autret <autret_m@epita.fr> | |
1808 | ||
1809 | * src/output.c (output_parser): Remove useless muscle. | |
1810 | ||
1811 | 2001-12-11 Marc Autret <autret_m@epita.fr> | |
1812 | ||
1813 | * src/bison.simple: Remove #line just before %%epilogue. It | |
1814 | is now handled in ... | |
1815 | * src/reader.c (read_additionnal_code): Add the output of a | |
1816 | #line for the epilogue. | |
1817 | ||
1818 | 2001-12-10 Marc Autret <autret_m@epita.fr> | |
1819 | ||
1820 | * src/reader.c (copy_definition): Re-use CPP-outed code which | |
1821 | replace precedent remove. | |
1822 | * src/bison.simple: Remove #line before %%prologue because | |
1823 | %%input-line is wrong at this time. | |
1824 | ||
1825 | 2001-12-10 Marc Autret <autret_m@epita.fr> | |
1826 | ||
1827 | * src/reader.c (symbols_output): Clean up. | |
1828 | * src/output.c (output_gram, output): Clean up. | |
1829 | ||
1830 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1831 | ||
1832 | * src/lalr.c (initialize_lookaheads): New. Extracted from... | |
1833 | * src/LR0.c (set_state_table): here. | |
1834 | * src/lalr.c (lalr): Call it. | |
1835 | ||
1836 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1837 | ||
1838 | * src/state.h (shifts): Remove the `number' member: shifts are | |
1839 | attached to state, hence no longer need to be labelled with a | |
1840 | state number. | |
1841 | ||
1842 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1843 | ||
1844 | Now that states have a complete set of members, the linked list of | |
1845 | shifts is useless: just fill directly the state's shifts member. | |
1846 | ||
1847 | * src/state.h (shifts): Remove the `next' member. | |
1848 | * src/LR0.c (first_state, last_state): Remove. | |
1849 | Adjust the callers. | |
1850 | (augment_automaton): Don't look for the shifts that must be added | |
1851 | a shift on EOF: it is those of the state we looked for! But now, | |
1852 | since shifts are attached, it is no longer needed to looking | |
1853 | merely by its id: its number. | |
1854 | ||
1855 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1856 | ||
1857 | * src/LR0.c (augment_automaton): Better variable locality. | |
1858 | Remove an impossible branch: if there is a state corresponding to | |
1859 | the start symbol being shifted, then there is shift for the start | |
1860 | symbol from the initial state. | |
1861 | ||
1862 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1863 | ||
1864 | * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state' | |
1865 | only when appropriate: when insert_start_shifting_state' is not | |
1866 | invoked. | |
1867 | * tests/regression.at (Rule Line Numbers): Adjust. | |
1868 | ||
1869 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1870 | ||
1871 | * src/LR0.c (augment_automaton): Now that all states have shifts, | |
1872 | merge the two cases addition shifts to the initial state. | |
1873 | ||
1874 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1875 | ||
1876 | * src/lalr.c (set_state_table): Move to... | |
1877 | * src/LR0.c: here. | |
1878 | * src/lalr.c (lalr): Don't call it... | |
1879 | * src/LR0.c (generate_states): do it. | |
1880 | * src/LR0.h (first_state): Remove, only the table is used. | |
1881 | ||
1882 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1883 | ||
1884 | * src/LR0.h (first_shift, first_reduction): Remove. | |
1885 | * src/lalr.c: Don't use first_shift: find shifts through the | |
1886 | states. | |
1887 | ||
1888 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1889 | ||
1890 | * src/LR0.c: Attach shifts to states as soon as they are | |
1891 | computed. | |
1892 | * src/lalr.c (set_state_table): Instead of assigning shifts to | |
1893 | state, just assert that the mapping was properly done. | |
1894 | ||
1895 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1896 | ||
1897 | * src/LR0.c (insert_start_shift): Rename as... | |
1898 | (insert_start_shifting_state): this. | |
1899 | (insert_eof_shifting_state, insert_accepting_state): New. | |
1900 | (augment_automaton): Adjust. | |
1901 | Better locality of the variables. | |
1902 | When looking if the start_symbol is shifted from the initial | |
1903 | state, using `while (... symbol != start_symbol ...)' sounds | |
1904 | better than `while (... symbol < start_symbol ...)': If fail | |
1905 | to see how the order between symbols could be relevant! | |
1906 | ||
1907 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1908 | ||
1909 | * src/getargs.h: Don't declare `spec_name_prefix' and | |
1910 | `spec_file_prefix', declared by src/files.h. | |
1911 | * src/files.c, src/files.h: Default for spec_name_prefix is "yy". | |
1912 | * src/muscle_tab.c (muscle_init): Default prefix to NULL. | |
1913 | * src/output.c (prepare): Adjust. | |
1914 | * src/reader.c (symbols_output): Likewise. | |
1915 | * src/vmsgetargs.c: Vaguely adjust, but who cares? | |
1916 | ||
1917 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1918 | ||
1919 | * src/muscle_tab.c (muscle_init): NULL is a better default than | |
1920 | `"0"'. | |
1921 | ||
1922 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1923 | ||
1924 | * src/reader.c (reader): Calling symbols_output once is enough. | |
1925 | ||
1926 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1927 | ||
1928 | Now that states have a complete set of members, the linked list of | |
1929 | reductions is useless: just fill directly the state's reductions | |
1930 | member. | |
1931 | ||
1932 | * src/state.h (struct reductions): Remove member `number' and | |
1933 | `next'. | |
1934 | * src/LR0.c (first_reduction, last_reduction): Remove. | |
1935 | (save_reductions): Don't link the new reductions, store them in | |
1936 | this_state. | |
1937 | * src/lalr.c (set_state_table): No need to attach reductions to | |
1938 | states, it's already done. | |
1939 | * src/output.c (output_actions): No longer free the shifts, then | |
1940 | the reductions, then the states: free all the states and their | |
1941 | members. | |
1942 | ||
1943 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1944 | ||
1945 | * src/options.c (OPTN, DRTV, BOTH): New. | |
1946 | (option_table): Use them. | |
1947 | ||
1948 | * src/muscle_tab.c: Don't include xalloc.h and string.h: that's | |
1949 | the job of system.h. | |
1950 | * src/options.c: Don't include stdio.h and xalloc.h for the same | |
1951 | reasons. | |
1952 | ||
1953 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1954 | ||
1955 | * src/output.c (output, prepare): Make sure the values of the | |
1956 | muscles `action' and `prologue' are 0-terminated. | |
1957 | ||
1958 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1959 | ||
1960 | Clean up GCC warnings. | |
1961 | ||
1962 | * src/reader.c (copy_action): `buf' is not used. | |
1963 | (parse_skel_decl): Be static. | |
1964 | * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'. | |
1965 | * src/options.h (create_long_option_table): Have a real prototype. | |
1966 | * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete) | |
1967 | (hash_delete_at): Return const void *. | |
1968 | Adjust casts to preserve the const. | |
1969 | ||
1970 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1971 | ||
1972 | * configure.in: Require 2.52g. | |
1973 | M4 is not needed, but AUTOM4TE is. | |
1974 | * m4/m4.m4: Remove. | |
1975 | * tests/Makefile.am: Adjust. | |
1976 | ||
1977 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1978 | ||
1979 | One structure for states is enough, even though theoretically | |
1980 | there are LR(0) states and LALR(1) states. | |
1981 | ||
1982 | * src/lalr.h (state_t): Remove. | |
1983 | (state_table): Be state_t **, not state_t *. | |
1984 | * src/state.h (core, CORE_ALLOC): Rename as... | |
1985 | (state_t, STATE_ALLOC): this. | |
1986 | Add the LALR(1) members: shifts, reductions, errs. | |
1987 | * src/LR0.c (state_table): Rename as... | |
1988 | (state_hash): this, to avoid name clashes with the global | |
1989 | `state_table'. | |
1990 | * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c | |
1991 | * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust. | |
1992 | ||
1993 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
1994 | ||
1995 | Bison dumps core on bash.y. | |
1996 | Reported by Pascal Bart. | |
1997 | ||
1998 | * src/warshall.c (bitmatrix_print): New. | |
1999 | (TC): Use it. | |
2000 | When performing a transitive closure R(i, j) && R(j, k) => R(i, k), | |
2001 | j must be the outer loop. | |
2002 | * tests/regression.at (Broken Closure): New. | |
2003 | ||
2004 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
2005 | ||
2006 | * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and | |
2007 | its argument. | |
2008 |