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