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