]>
Commit | Line | Data |
---|---|---|
8901f32e AD |
1 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
2 | ||
3 | The single-stack C++ parser is now the standard one. | |
4 | * data/lalr1.cc: Rename as... | |
5 | * data/lalr1-split.cc: this. | |
6 | * data/lalr1-fusion.cc: Rename as... | |
7 | * data/lalr1.cc: this. | |
8 | * etc/bench.pl.in: Adjust. | |
9 | ||
8cdabf02 AD |
10 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
11 | ||
12 | Avoid empty-if warnings. | |
13 | Reported by Quentin Hocquet. | |
14 | ||
15 | * data/lalr1-fusion.cc (YY_SYMBOL_PRINT, YY_REDUCE_PRINT) | |
16 | (YY_STACK_PRINT): Provide some contents even when !YYDEBUG. | |
17 | ||
5a893c2b AD |
18 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
19 | ||
20 | Pass command line location to skeleton_arg and language_argmatch. | |
21 | * src/getargs.h, src/getargs.c (skeleton_arg, language_argmatch): | |
22 | The location argument is now mandatory. | |
23 | Adjust all dependencies. | |
24 | (getargs): Use command_line_location. | |
25 | ||
58697c6d AD |
26 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
27 | ||
28 | -D, --define. | |
29 | * src/getargs.c (usage): Document -D. | |
30 | Fix help string for --locations. | |
31 | (command_line_location): New. | |
32 | (short_options, long_options, getargs): Support -D, --define. | |
33 | (getargs): Move -d support at the right place. | |
34 | * doc/bison.texinfo (Bison Options): Update. | |
35 | * tests/input.at (%define, --define): New. | |
36 | ||
9fe5a457 AD |
37 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
38 | ||
39 | Initialize the muscle table before parsing the command line. | |
40 | * src/getargs.c (quotearg.h, muscle_tab.h): Include. | |
41 | (getargs): Define file_name. | |
42 | * src/main.c (main): Initialize muscle_tab before calling | |
43 | getargs. | |
44 | * src/muscle_tab.c (muscle_init): No longer define file_name, as | |
45 | its value is not available yet. | |
46 | ||
56c5eca9 AD |
47 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
48 | ||
49 | Locations without columns for command line arguments. | |
50 | * src/location.c (location_print): Don't display negative columns. | |
51 | * src/location.h: Document this. | |
52 | ||
9b9e0a7d AD |
53 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
54 | ||
55 | Fix --help. | |
56 | * src/getargs.c (usage): Fix help string for -W. | |
57 | ||
74eae918 AD |
58 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
59 | ||
60 | Handle more general types of option arguments. | |
61 | * build-aux/cross-options.pl: The argument ends at the first | |
62 | space, not the first non-symbol character. | |
63 | Use @var for each word appearing the argument description. | |
64 | ||
a3d4c6fb AD |
65 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
66 | ||
67 | Destroy the variants that remain on the stack in case of error. | |
68 | * data/lalr1-fusion.cc (yydestruct_): Invoke the variant's | |
69 | destructor. | |
70 | Display the value only if yymsg is nonnull. | |
71 | (yyreduce): Invoke yydestruct_ when popping lhs symbols. | |
72 | ||
2d32fc9f AD |
73 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
74 | ||
75 | Add "%define assert" to variants. | |
76 | This is used to help the user catch cases where some value gets | |
77 | ovewritten by a new one. This should not happen, as this will | |
78 | probably leak. | |
79 | ||
80 | Unfortunately this uncovered a bug in the C++ parser itself: the | |
81 | lookahead value was not destroyed between two calls to yylex. For | |
82 | instance if the previous lookahead was a std::string, and then an int, | |
83 | then the value of the std::string was correctly taken (i.e., the | |
84 | lookahead was now an empty string), but std::string structure itself | |
85 | was not reclaimed. | |
86 | ||
87 | This is now done in variant::build(other&) (which is used to take the | |
88 | value of the lookahead): other is not only stolen from its value, it | |
89 | is also destroyed. This incurs a new performance penalty of a few | |
90 | percent, and union becomes faster again. | |
91 | ||
92 | * data/lalr1-fusion.cc (variant::build(other&)): Destroy other. | |
93 | (b4_variant_if): New. | |
94 | (variant::built): New. | |
95 | Use it whereever the status of the variant changes. | |
96 | * etc/bench.pl.in: Check the penalty of %define assert. | |
97 | ||
f6038cb8 AD |
98 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
99 | ||
100 | Use "%define variant" in bench.pl. | |
101 | * etc/bench.pl.in: No longer use the pseudo directive %variants, | |
102 | just use %define variants. | |
103 | ||
ccde1f98 AD |
104 | 2008-11-07 Akim Demaille <demaille@gostai.com> |
105 | ||
106 | Regen. | |
107 | * src/parse-gram.h, src/parse-gram.c: Regen. | |
108 | ||
58bd33b7 JD |
109 | 2008-11-04 Joel E. Denny <jdenny@ces.clemson.edu> |
110 | ||
111 | Fix user actions without a trailing semicolon. | |
112 | Reported by Sergei Steshenko at | |
113 | <http://lists.gnu.org/archive/html/bug-bison/2008-11/msg00001.html>. | |
114 | * THANKS (Sergei Steshenko): Add. | |
115 | * src/scan-code.l (SC_RULE_ACTION): Fix it. | |
116 | * tests/regression.at (Fix user actions without a trailing semicolon): | |
117 | New test case. | |
118 | ||
639867b5 AD |
119 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
120 | ||
121 | Use b4_copyright_years. | |
122 | * data/yacc.c (b4_copyright_years): New. | |
123 | Fix its value according to the comments in the file. | |
124 | Use it and undefine it. | |
125 | ||
3c262606 AD |
126 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
127 | ||
128 | Formatting changes. | |
129 | * data/lalr1-fusion.cc, src/parse-gram.y: here. | |
130 | ||
a2b93d52 AD |
131 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
132 | ||
133 | Formatting changes. | |
134 | * data/lalr1-fusion.cc: here. | |
135 | ||
3a2803df AD |
136 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
137 | ||
138 | Use strict on bench.pl. | |
139 | * etc/bench.pl.in (&run, &generate_grammar): New. | |
140 | Rename the grammar generating functions for consistency. | |
141 | Change the interface so that the list of benches to run is passed | |
142 | as (optionless) arguments. | |
143 | (&compile): Use &run. | |
144 | ||
a0d4650a AD |
145 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
146 | ||
147 | Remove spurious initial empty lines. | |
148 | * data/glr.c, data/glr.cc, data/lalr1.cc, data/lalr1.java, | |
149 | * data/yacc.c: End the @output lines with an @. | |
150 | ||
cac9e09b AD |
151 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
152 | ||
153 | Improve the display of sizes. | |
154 | * etc/bench.p.in: Higher precision. | |
155 | Sort by decreasing size. | |
156 | ||
4af4348a AD |
157 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
158 | ||
159 | Don't memcpy C++ structures. | |
160 | * data/lalr1-fusion.cc (b4_symbol_variant): Adjust additional | |
161 | arguments. | |
162 | (variant::build): New overload for | |
163 | copy-construction-that-destroys. | |
164 | (variant::swap): New. | |
165 | (parser::yypush_): Use it in variant mode. | |
166 | ||
ef05c4d6 AD |
167 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
168 | ||
169 | Better defaults for bench.pl. | |
170 | * etc/bench.pl.in ($verbose, $cflags, $iterations): Change the | |
171 | default values. | |
172 | Adjust &verbose uses. | |
173 | (-q, --quiet): New. | |
174 | ||
9718cfa9 AD |
175 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
176 | ||
177 | Make variant.yy more complex. | |
178 | std::list cannot be copied via memcpy, they are more demanding than | |
179 | std::string. Use one std::list to strengthen the test. | |
180 | ||
181 | * examples/variant.yy: Use lalr1-fusion.cc, not lalr1.cc. | |
182 | Adjust. | |
183 | Create a list of strings, instead of a single large string. | |
184 | ||
a6df593d AD |
185 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
186 | ||
187 | bench.pl --bench. | |
188 | * etc/bench.pl.in (--bench, $bench): New. | |
189 | ||
006a0303 AD |
190 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
191 | ||
192 | Sort methods. | |
193 | * data/lalr1-fusion.cc (destroy): Use as() in its definition. | |
194 | Define it after as(). | |
195 | ||
faef3466 AD |
196 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
197 | ||
198 | Useless parens. | |
199 | * data/lalr1-fusion.cc (b4_rhs_location): Remove useless parens. | |
200 | ||
2141aded AD |
201 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
202 | ||
203 | Issue missing synclines after user actions. | |
204 | * data/c.m4 (b4_case): Issue synclines on the output file. | |
205 | ||
e426d17b AD |
206 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
207 | ||
208 | Remove trailing empty line. | |
209 | * data/lalr1-fusion.cc: Don't add an empty line after the user's | |
210 | epilogue. | |
211 | ||
a9ce3f54 AD |
212 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
213 | ||
214 | Fix output of copyright years. | |
215 | * data/bison.m4 (b4_copyright): Fix the indentation of the | |
216 | copyright year paragraph. | |
217 | Use b4_copyright_years when no years are given. | |
218 | * data/lalr1.cc, data/lalr1-fusion.cc, data/location.cc | |
219 | (b4_copyright_years): New. | |
220 | Use it. | |
221 | ||
59c544c2 AD |
222 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
223 | ||
224 | Avoid the spurious initial empty line. | |
225 | * data/lalr1-fusion.cc, data/location.cc: Put a trailing "@" at | |
226 | the end of @output request to suppress the empty line that | |
227 | results. | |
228 | ||
96b15448 AD |
229 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
230 | ||
231 | Remove parser::rhs_number_type. | |
232 | * data/lalr1-fusion.cc (rhs_number_type): No longer define it. | |
233 | (yyrhs_): Use b4_table_define. | |
234 | ||
f0633174 AD |
235 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
236 | ||
237 | Fix iteration type. | |
238 | * data/lalr1-fusion.cc: Use an int to iterate up to an int. | |
239 | ||
417b8004 AD |
240 | 2008-11-04 Akim Demaille <demaille@gostai.com> |
241 | ||
242 | Factor the declaration of the integer tables. | |
243 | * data/lalr1-fusion.cc (b4_table_define): New. | |
244 | Use it. | |
245 | ||
1a5246c6 AD |
246 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
247 | ||
248 | Fix indentation of tables in lalr1.cc | |
249 | * data/lalr1-fusion.cc: Fix the indentation. | |
250 | ||
f8a95c9c AD |
251 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
252 | ||
253 | Destroy the lhs symbols after reduction. | |
254 | * data/lalr1-fusion.cc (parse): After the user action, when in | |
255 | variant mode, destroy the lhs symbols. | |
256 | ||
d7f4d823 AD |
257 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
258 | ||
259 | Simplify yysyntax_error_ use. | |
260 | * data/lalr1-fusion.cc (yysyntax_error_): Always pass it the token | |
261 | type, but make it unnamed in the declaration when it is not used. | |
262 | ||
8b9c89fb AD |
263 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
264 | ||
265 | Let yy::variant::build return an lvalue. | |
266 | * data/lalr1-fusion.cc (variant::build): Return a reference to the | |
267 | object. | |
268 | ||
83243c24 AD |
269 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
270 | ||
271 | Define yy::variant only when needed. | |
272 | * data/lalr1-fusion.cc (yy::variant): Define only if variants are | |
273 | used. | |
274 | ||
429b4848 AD |
275 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
276 | ||
277 | Bench the three-stack lalr1.cc. | |
278 | * etc/bench.pl.in: Bench the three-stack lalr1.cc vs. the | |
279 | one-stack one. | |
280 | ||
414c76a4 AD |
281 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
282 | ||
283 | Fail on parse error in calc++. | |
284 | * doc/bison.texinfo (calc++.cc): Propagate failures to the exit | |
285 | status. | |
286 | * examples/calc++/test ($me, $number, $exit, run): New. | |
287 | Use them to propagate errors to the exit status. | |
288 | ||
8a5783fd AD |
289 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
290 | ||
291 | Don't specify the skeleton twice in the example. | |
292 | * examples/calc++/Makefile.am: Don't pass -S to Bison, the grammar | |
293 | file does what is needed. | |
294 | ||
0cc5bead AD |
295 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
296 | ||
297 | bench: Improve output. | |
298 | * etc/bench.pl.in (bench_grammar): Tune the printf format. | |
299 | ||
5b421a4e AD |
300 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
301 | ||
302 | bench: check impact of %debug on variants. | |
303 | * etc/bench.pl.in (variant_grammar): Fix the computation of | |
304 | $variant. | |
305 | Generate a grammar file that can work with or without %debug. | |
306 | Do use the @directive. | |
307 | (bench_variant_parser): Check impact of %debug. | |
308 | (@directives): Rename all the occurrences to... | |
309 | (@directive): this, for consistency. | |
310 | ||
d11ee647 AD |
311 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
312 | ||
313 | bench: report the size too. | |
314 | * etc/bench.pl.in ($iterations): Defaults to -3. | |
315 | (&bench_grammar): Require hireswallclock. | |
316 | Compute and display the size of the result. | |
317 | More comments. | |
318 | ||
e1b74b92 AD |
319 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
320 | ||
321 | bench: More use of the verbosity level. | |
322 | * etc/bench.pl.in ($verbose, &verbose): New. | |
323 | Use them. | |
324 | More POD documentation. | |
325 | ||
7e5f9c54 AD |
326 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
327 | ||
328 | bench.pl: a command line interface | |
329 | * etc/bench.pl.in: More doc. | |
330 | Some fixes in the documentation. | |
331 | ($cflags, $iterations, &help, &getopt): New. | |
332 | Use them. | |
333 | (&variant_grammar): Let the number of stages be 10 times what is | |
334 | specified. | |
335 | ||
7109a18d AD |
336 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
337 | ||
338 | Bench the use of Boost.Variants. | |
339 | * etc/bench.pl.in ($cxx, &variant_grammar, &bench_variant_parser): | |
340 | New. | |
341 | (&compile): Be ready to compile C++ parsers. | |
342 | (&bench_push_parser): Move debug information to the outermost | |
343 | level. | |
344 | * THANKS: Add Michiel De Wilde. | |
345 | ||
922730fe AD |
346 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
347 | ||
348 | bench.pl: Pass directives as a list instead of as a string. | |
349 | * etc/bench.pl.in (&directives): New. | |
350 | (&triangular_grammar, &calc_grammar): Use it to format the Bison | |
351 | directives. | |
352 | (&triangular_grammar): Do use the directives (were ignored). | |
353 | (&bench_grammar, &bench_push_parser): Adjust to pass lists of | |
354 | directives. | |
355 | ||
7484f1d4 AD |
356 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
357 | ||
358 | Improve genericity of bench.pl. | |
359 | * etc/bench.pl.in (&bench_grammar): Take the set of benches as | |
360 | argument. | |
361 | (&bench_push_parser): New. | |
362 | Call it. | |
363 | ||
15129f25 AD |
364 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
365 | ||
366 | Add documentation to bench.pl. | |
367 | * etc/bench.pl.in: Comment changes. | |
368 | ||
0e0ed236 AD |
369 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
370 | ||
371 | Fuse the three stacks into a single one. | |
372 | In order to make it easy to perform benchmarks to ensure that there are no | |
373 | performance loss, lalr1.cc is forked into lalr1-fusion.cc. Eventually, | |
374 | lalr1-fusion.cc will replace lalr1.cc. | |
375 | ||
376 | Meanwhile, to make sure that lalr1-fusion.cc is correctly exercized by the | |
377 | test suite, the user must install a symbolic link from lalr1.cc to it. | |
378 | ||
379 | Instead of having three stacks (state, value, location), use a stack | |
380 | of triples. This considerably simplifies the code (and it will be | |
381 | easier not to require locations as currently does the C++ parser), | |
382 | and also gives a 10% speedup according to etc/bench (probably mainly since | |
383 | memory allocation is done once instead of three times). | |
384 | ||
385 | Another motivation is to make it easier to destruct properly | |
386 | semantic values: now that they are bound to their state (hence | |
387 | symbol type) it will be easier to call the appropriate destructor. | |
388 | ||
389 | These changes should probably benefit the C parser too. | |
390 | ||
391 | * data/lalr1.cc: Copy as... * data/lalr1-fusion.cc: this new | |
392 | file. | |
393 | (b4_rhs_value, b4_rhs_location): New definitions overriding those | |
394 | from c++.m4. | |
395 | (state_stack_type, semantic_stack_type, location_stack_type) | |
396 | (yystate_stack_, yysemantic_stack_, yylocation_stack_): Remove. | |
397 | (data_type, stack_type, yystack_): New. | |
398 | (YYLLOC_DEFAULT, yypush_): Adjust. | |
399 | (yyerror_range): Now based on data_type, not location_type. | |
400 | ||
7dedf26e AD |
401 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
402 | ||
403 | Push the state, value, and location at the same time. | |
404 | This is needed to prepare a forthcoming patch that fuses the three | |
405 | stacks into one. | |
406 | ||
407 | * data/lalr1.cc (parser::yypush_): New. | |
408 | (parser::yynewstate): Change the semantics: instead of arriving to | |
409 | this label when value and location have been pushed, but yystate | |
410 | is to be pushed on the state stack, now the three of them must | |
411 | have been pushed before. yystate still must be the new state. | |
412 | This allows to use yypush_ everywhere instead of individual | |
413 | handling of the stacks. | |
414 | ||
c4585f1e AD |
415 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
416 | ||
417 | Prefer references to pointers. | |
418 | * data/lalr1.cc (b4_symbol_actions): New, overrides the default C | |
419 | definition to use references instead of pointers. | |
420 | (yy_symbol_value_print_, yy_symbol_print_, yydestruct_): | |
421 | Take the value and location as references. | |
422 | Adjust callers. | |
423 | ||
56017c17 AD |
424 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
425 | ||
426 | stack::size instead of stack::height. | |
427 | * data/lalr1.cc (stack::height): Rename as... | |
428 | (stack::size): this. | |
429 | Fix the output type. | |
430 | Comment changes. | |
431 | ||
5ab8c47b AD |
432 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
433 | ||
434 | Use variants to support objects as semantic values. | |
435 | This patch was inspired by work by Michiel De Wilde. But he used Boost | |
436 | variants which (i) requires Boost on the user side, (ii) is slow, and | |
437 | (iii) has useless overhead (the parser knows the type of the semantic value | |
438 | there is no reason to duplicate this information as Boost.Variants do). | |
439 | ||
440 | This implementation reserves a buffer large enough to store the largest | |
441 | objects. yy::variant implements this buffer. It was implemented with | |
442 | Quentin Hocquet. | |
443 | ||
444 | * src/output.c (type_names_output): New. | |
445 | (output_skeleton): Invoke it. | |
446 | * data/c++.m4 (b4_variant_if): New. | |
447 | (b4_symbol_value): If needed, provide a definition for variants. | |
448 | * data/lalr1.cc (b4_symbol_value, b4_symbol_action_) | |
449 | (b4_symbol_variant, _b4_char_sizeof_counter, _b4_char_sizeof_dummy) | |
450 | (b4_char_sizeof, yy::variant): New. | |
451 | (parser::parse): If variants are requested, define | |
452 | parser::union_type, parser::variant, change the definition of | |
453 | semantic_type, construct $$ before running the user action instead | |
454 | of performing a default $$ = $1. | |
455 | * examples/variant.yy: New. | |
456 | Based on an example by Michiel De Wilde. | |
457 | ||
1fa5d8bb AD |
458 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
459 | ||
460 | Parameterize the extraction of semantic values. | |
461 | To make future changes easier, no longer rely on ".TYPE" being the | |
462 | way to get a semantic value. | |
463 | ||
464 | * data/c.m4 (b4_symbol_value): New. | |
465 | Use it. | |
466 | * data/c++.m4, data/yacc.c: Use it. | |
467 | * data/glr.c: Use b4_symbol_value. | |
468 | (b4_rhs_data): New. | |
469 | Use it. | |
470 | ||
91ba8a55 AD |
471 | 2008-11-03 Akim Demaille <demaille@gostai.com> |
472 | ||
473 | Prepare easier M4 changes. | |
474 | * data/lalr1.cc: Use escaped [] instead of literals to prepare | |
475 | future changes. | |
476 | ||
c9ba9e59 JD |
477 | 2008-11-02 Joel E. Denny <jdenny@ces.clemson.edu> |
478 | ||
479 | Initiate further development. | |
480 | * NEWS: Create an empty section for new entries. | |
481 | * gnulib: Update submodule to HEAD. | |
482 | ||
bfb40910 JD |
483 | 2008-11-02 Joel E. Denny <jdenny@ces.clemson.edu> |
484 | ||
485 | * NEWS: Version 2.4. | |
486 | ||
241fda7a JD |
487 | 2008-11-02 Joel E. Denny <jdenny@ces.clemson.edu> |
488 | ||
489 | Prepare for next release. | |
490 | * NEWS: Briefly mention changes since 2.3b. | |
491 | * README: Say GNU m4 1.4.6, which we've been requiring in release | |
492 | announcements already, not 1.4.3, which breaks the build. | |
493 | ||
ed4d67dc JD |
494 | 2008-11-02 Joel E. Denny <jdenny@ces.clemson.edu> |
495 | ||
496 | Say %language is experimental. | |
497 | We're thinking of extending it's effect on output file naming. See the | |
498 | thread at | |
499 | <http://lists.gnu.org/archive/html/bison-patches/2008-10/msg00003.html>. | |
500 | * NEWS: Say it's experimental. | |
501 | * doc/bison.texinfo (Decl Summary): Say it's experimental, and so don't | |
502 | recommend it over %skeleton for now. | |
503 | (Bison Options): Likewise. | |
504 | (C++ Bison Interface): Use %skeleton not %language. | |
505 | (Calc++ Parser): Use %skeleton not %language. | |
506 | * src/getargs.c (usage): Say it's experimental. | |
507 | ||
e254a580 DJ |
508 | 2008-11-01 Di-an Jan <dianj@freeshell.org> |
509 | Paolo Bonzini <bonzini@gnu.org> | |
510 | ||
511 | Support all Java parser class modifiers. | |
512 | * data/java.m4 (b4_percent_define_get3): New. | |
513 | (b4_final_if, b4_strictfp_if): New. | |
514 | * data/lalr1.java (final, strictfp, extends, implements): Support. | |
515 | * doc/bison.texinfo (final, strictfp, extends, implements): Add | |
516 | documentation. | |
517 | * tests/java.at (AT_CHECK_JAVA_MINIMAL): New. | |
518 | (AT_CHECK_JAVA_MINIMAL_W_LEXER): New. | |
519 | (AT_CHECK_JAVA_GREP): New. | |
520 | (Java parser class modifiers): New test. | |
521 | (Java parser class extends and implements): New test. | |
522 | ||
523 | Model exception propagation better with throws and lex_throws. | |
524 | * data/java.m4 (b4_list2): New. | |
525 | (throws): Change default. | |
526 | * data/lalr1.java (yyaction): Add throws. | |
527 | (parse): Add lex_throws in addition to throws. | |
528 | * doc/bison.texinfo (throws, lex_throws): Add documentation. | |
529 | * tests/java.at (Java throws specifications): New test. | |
530 | ||
531 | Improve documentation for Java parsers. | |
532 | * doc/bison.texinfo (Java Parsers): Add subsections. | |
533 | Don't quote first argument of %define. | |
534 | (Java Bison Interface): Document output files. Move documentation | |
535 | of parser class and merge into Java Parser Interface. Document | |
536 | features that error out. Document directives with no effect. | |
537 | Move note about Javadoc higher. | |
538 | (Java Semantic Values): Explicitly mention stype. | |
539 | Document that generic types cannot be used. | |
540 | (Java Location Values): Use @deftypeivar. Document constructors. | |
541 | Correct return value for toString. | |
542 | (Java Parser Interface): List undocumented constants/fields. | |
543 | Move documentation of fields added by %parse-param closer to list | |
544 | of members. Document that token names are added as fields. | |
545 | Document constructors accurately. Remove error method. | |
546 | (Java Scanner Interface): Move note on %pure-parser to Java Bison | |
547 | Interface. Describe %code lexer and yylex accutately. | |
548 | Remove documentation that does not match the code. | |
549 | (Java Action Features): New. | |
550 | (Java Differences): Add reference. Add item on semantic values. | |
551 | Add note about @{ ... @}. Clarify %% epilogue placement. | |
552 | (Java Declarations Summary): New. | |
553 | ||
554 | Fix Java skeleton. | |
555 | * data/java.m4 (b4_prefix): Correct quoting for m4_define_default. | |
556 | (b4_remove_comma): Quote test argument. | |
557 | (b4_identification): Remove "bison" field. | |
558 | * tests/java.at (Java parser class and package names): New test. | |
559 | (Java %parse-param and %lex-param): New test. | |
560 | (Java stype, position_class and location_class): New test. | |
561 | ||
f259e4e6 PB |
562 | 2008-10-31 Di-an Jan <dianj@freeshell.org> |
563 | ||
564 | * data/lalr1.jave: Update copyright years. | |
565 | (YYParser): Correct name of "generated from" file in Javadoc: | |
566 | use b4_file_name instead of @ofile@. | |
567 | (Location constructor): Correct Javadoc parameter name. | |
568 | (yylloc): Add missing opening m4 quote after b4_location_if. | |
569 | This removes a stray [ in the Javadoc of Lexer.getStartPos. | |
570 | (Lexer.yyerror): Fix incorrect m4 and Javadoc. | |
571 | (YYParser constructor): Correct Javadoc parameter name. | |
572 | ||
cae5057f JD |
573 | 2008-10-30 Joel E. Denny <jdenny@ces.clemson.edu> |
574 | ||
575 | Always put auxiliary code files in the same dir as other output files. | |
576 | * src/files.c (compute_file_name_parts): When the user specifies | |
577 | --output but not --file-prefix, extract the directory prefix from the | |
578 | file prefix not from the grammar file name. This affects the location | |
579 | of files like location.hh generated by the C++ skeleton. The includes | |
580 | in the other output files require this fix. | |
581 | * tests/output.at (AT_CHECK_OUTPUT): Automatically create directories | |
582 | for expected output files. | |
583 | (Output files): Add a test for the above. | |
584 | ||
4af432ba JD |
585 | 2008-10-29 Joel E. Denny <jdenny@ces.clemson.edu> |
586 | ||
587 | * gnulib: Update submodule to HEAD. | |
588 | ||
e26d4e43 JD |
589 | 2008-10-28 Joel E. Denny <jdenny@ces.clemson.edu> |
590 | ||
591 | Update copyright year. | |
592 | * src/files.c: Here. | |
593 | ||
c0ee9e21 DJ |
594 | 2008-10-28 Di-an Jan <dianj@freeshell.org> (tiny change) |
595 | ||
596 | Don't overwrite the input file. | |
597 | * src/files.c (output_file_name_check): Fatal error if using input file | |
598 | for output. | |
599 | * tests/output.at: (AT_CHECK_CONFLICTING_OUTPUT): Add return status | |
600 | argument. | |
601 | (Conflicting output files): Add test. | |
602 | ||
482dc52f AD |
603 | 2008-10-28 Akim Demaille <demaille@gostai.com> |
604 | ||
605 | Space changes. | |
606 | * data/lalr1.cc: Formatting changes. | |
607 | ||
52cbbe84 AD |
608 | 2008-10-28 Akim Demaille <demaille@gostai.com> |
609 | ||
610 | Don't define debugging functions when !YYDEBUG. | |
611 | * data/lalr1.cc (debug_stream, set_debug_stream) | |
612 | (debug_level_type, debug_level, set_debug_level): Don't | |
613 | declare them when YYDEBUG is not defined. | |
614 | The implementation are already YYDEBUG-aware. | |
615 | ||
0925d5bf AD |
616 | 2008-10-28 Akim Demaille <demaille@gostai.com> |
617 | ||
618 | Prefer "continue" for empty loop bodies. | |
619 | * etc/bench.pl.in: Use "continue" instead of {}. | |
620 | ||
cf98343c AD |
621 | 2008-10-28 Akim Demaille <demaille@gostai.com> |
622 | ||
623 | Space and comments changes. | |
624 | * data/c++.m4, data/glr.c, data/lalr1.cc: Copyright year changes. | |
625 | * data/c.m4, data/lalr1.cc: Space changes. | |
626 | ||
9f467b7d AD |
627 | 2008-10-28 Akim Demaille <demaille@gostai.com> |
628 | ||
629 | Make gnulib a submodule. | |
630 | * gnulib: New. | |
631 | * .gitmodules (gnulib): New. | |
632 | ||
0f0e1ace JD |
633 | 2008-10-18 Joel E. Denny <jdenny@ces.clemson.edu> |
634 | ||
635 | Fix yyerror_range for user-defined location type in C++. Reported by | |
636 | Georg Sauthoff at | |
637 | <http://lists.gnu.org/archive/html/bug-bison/2008-08/msg00008.html>. | |
638 | * data/lalr1.cc (parse): Change type of yyerror_range to location_type. | |
639 | * THANKS (Georg Sauthoff): Add. | |
640 | ||
548e2104 JD |
641 | 2008-10-18 Joel E. Denny <jdenny@ces.clemson.edu> |
642 | ||
643 | Update several administrative files mainly to facilitate releasing. | |
644 | * HACKING (Administrivia): Make the git-merge-changelog notes more | |
645 | helpful. | |
646 | (Test suite): Don't say lalr1.cc is not exercised in the test suite. | |
647 | (Release Procedure): Update for git and add numerous details that were | |
648 | previously missing. | |
649 | * Makefile.am (EXTRA_DIST): Remove Makefile.cfg and Makefile.maint. | |
650 | * maint.mk (announcement): Don't list bison as a bootstrap tool so | |
651 | that announcements don't claim we bootstrapped with whatever bison | |
652 | happened to be in PATH. Add flex as a bootstrap tool. | |
653 | * Makefile.maint: Remove, previously replaced by maint.mk. | |
654 | * Makefile.cfg: Remove, and migrate settings to... | |
655 | * cfg.mk: ... here for the sake of `make announcement'. | |
656 | * bootstrap.conf (gnulib_modules): Add announce-gen. | |
657 | * README: Say GNU Bison instead of just Bison. Suggested by Karl | |
658 | Berry. | |
659 | ||
ddf17a6e PB |
660 | 2008-10-08 Di-an Jan <dianj@freeshell.org> (tiny change) |
661 | ||
662 | Small but important bugfixes for the Java skeleton. | |
663 | * data/lalr1.java (yyerror): Change Location to b4_location_type. | |
664 | (yy_symbol_print): Call toString on yyvaluep. | |
665 | ||
e1145ad8 AD |
666 | 2008-08-29 Akim Demaille <demaille@gostai.com> |
667 | ||
668 | Clarify UPDATED use. | |
669 | * doc/bison.texinfo: It refers to the last edition of this file, | |
670 | not to the release date of Bison. | |
671 | Reported by Joel E. Denny. | |
672 | ||
0df72d78 AD |
673 | 2008-08-29 Akim Demaille <demaille@gostai.com> |
674 | ||
675 | * README: Update FAQ pointer. | |
676 | Reported by Joel E. Denny. | |
677 | ||
9a90b6bb EB |
678 | 2008-08-27 Eric Blake <ebb9@byu.net> |
679 | ||
680 | Resync m4sugar from autoconf. | |
681 | * data/m4sugar/m4sugar.m4 (m4_defn, m4_popdef, m4_undefine) | |
682 | (m4_init): Adjust to latest m4.git changes. | |
683 | (m4_mapall_sep, _m4_list_cmp, m4_version_compare): Reduce side | |
684 | effects. | |
685 | * data/m4sugar/foreach.m4 (_m4_shiftn): Fix off-by-one bug. | |
686 | (_m4_list_cmp): Reduce side effects. | |
687 | ||
65015668 AD |
688 | 2008-08-27 Akim Demaille <demaille@gostai.com> |
689 | ||
690 | Check yyerrok in calc.at. | |
691 | * tests/calc.at (calc.y): Use yyerrok on "( error )". | |
692 | (AT_CHECK_CALC): Add a check that ensures that yyerrok works as | |
693 | expected. | |
694 | ||
98e26a92 AD |
695 | 2008-08-27 Akim Demaille <demaille@gostai.com> |
696 | ||
697 | Support yyerrok in lalr1.cc. | |
698 | YYBACKUP is still to import back into lalr1.cc. | |
699 | * data/lalr1.cc (yyerrork, yyclearin, YYRECOVERING): Define. | |
700 | ||
86c0e784 JD |
701 | 2008-08-26 Joel E. Denny <jdenny@ces.clemson.edu> |
702 | ||
703 | For maintainer-check*, don't recompile for a $(VERSION) update. | |
704 | * cfg.mk: New file. | |
705 | (_is-dist-target): Override the one in GNUmakefile. | |
706 | * Makefile.am (EXTRA_DIST): Add cfg.mk. | |
707 | ||
88511166 JD |
708 | 2008-08-26 Joel E. Denny <jdenny@ces.clemson.edu> |
709 | ||
710 | Update for recent change to gnulib. | |
711 | * src/parse-gram.y: Don't include strverscmp.h. It comes from | |
712 | string.h now. | |
713 | ||
6bbb2ed5 EB |
714 | 2008-08-15 Eric Blake <ebb9@byu.net> |
715 | ||
d67c52e8 EB |
716 | Remaining m4sugar merge from autoconf. |
717 | * data/m4sugar/m4sugar.m4: Copy entire file from autoconf. | |
718 | * data/m4sugar/foreach.m4: New file, copied from autoconf. | |
719 | * data/Makefile.am (dist_m4sugar_DATA): Distribute it. | |
720 | * src/output.c (output_skeleton): Tell m4 how to find it. | |
721 | ||
6bbb2ed5 EB |
722 | Partial m4sugar merge from autoconf: m4_map. |
723 | * data/m4sugar/m4sugar.m4 (m4_fst): Delete. | |
724 | (m4_map, m4_map_sep, _m4_map): Rewrite more efficiently. | |
725 | (m4_apply, _m4_apply, m4_mapall, m4_mapall_sep): New macros. | |
726 | * data/java.m4 (b4_token_enums): Use more efficient short-circuit | |
727 | for empty list. | |
728 | * data/c.m4 (b4_token_defines, b4_token_enums, b4_c_ansi_formals): | |
729 | Likewise. | |
730 | (b4_parse_param_for): Avoid m4_fst, now that autoconf no longer | |
731 | declares it. | |
732 | ||
8dce3875 JD |
733 | 2008-08-07 Joel E. Denny <jdenny@ces.clemson.edu> |
734 | ||
735 | Keep .version and PACKAGE_VERSION in sync. | |
736 | * Makefile.am ($(top_srcdir)/.version): Declare configure as a | |
737 | dependency, and add comments justifying this in more detail. Discussed | |
738 | starting at | |
739 | <http://lists.gnu.org/archive/html/bison-patches/2008-07/msg00022.html>. | |
740 | ||
882a1fbf EB |
741 | 2008-08-06 Eric Blake <ebb9@byu.net> |
742 | ||
a3764451 EB |
743 | Partial m4sugar merge from autoconf: m4_shiftn. |
744 | * data/m4sugar/m4sugar.m4 (m4_shiftn): Faster implementation. | |
745 | (m4_shift2, m4_shift3): New macros. | |
746 | (m4_case, m4_bmatch, m4_bpatsubsts, m4_join): Adjust clients. | |
747 | * data/c.m4 (b4_c_function_def, b4_c_ansi_function_def) | |
748 | (b4_c_ansi_function_decl, b4_c_function_call): Likewise. | |
749 | * data/java.m4 (b4_remove_comma): Likewise. | |
750 | ||
882a1fbf EB |
751 | Partial m4sugar merge from autoconf: m4_wrap vs. m4 1.6. |
752 | * data/m4sugar/m4sugar.m4 (m4_unquote, m4_wrap_lifo): New macros. | |
753 | (m4_wrap): Guarantee FIFO order, in spite of m4 1.6. | |
754 | (m4_init): Consolidate wrapped text into single m4_wrap. | |
755 | * data/bison.m4 (b4_check_user_names_wrap): Stick with LIFO order | |
756 | in wrapped text. | |
757 | ||
a30e920d EB |
758 | 2008-08-05 Eric Blake <ebb9@byu.net> |
759 | ||
dfcc5959 EB |
760 | Partial m4sugar merge from autoconf: builtins, version.m4. |
761 | * data/m4sugar/m4sugar.m4 (changeword): Nuke. | |
762 | (m4_prepend): Remove, as it is unused and inherently quadratic, | |
763 | whereas m4_append is linear in newer m4. | |
764 | (m4_mkstemp): New builtin. | |
765 | (m4_symbols): Make rename conditional. | |
766 | (m4_version_prereq): Ensure fatal error if used in bison, which | |
767 | intentionally lacks version.m4. | |
768 | ||
a30e920d EB |
769 | Fix comments in m4sugar. |
770 | * data/m4sugar/m4sugar.m4: Comment changes, borrowed from autoconf. | |
771 | ||
445b7470 JD |
772 | 2008-08-02 Joel E. Denny <jdenny@ces.clemson.edu> |
773 | ||
774 | Update for recent .gitignore fix in Gnulib. | |
775 | * bootstrap: Back out 2008-07-18 hack now that gnulib-tool creates | |
776 | anchored .gitignore entries. | |
777 | ||
a1e50014 JD |
778 | 2008-08-02 Joel E. Denny <jdenny@ces.clemson.edu> |
779 | ||
780 | Set gnu or gnits strictness. | |
781 | * configure.ac (AM_INIT_AUTOMAKE): Set gnu strictness during | |
782 | development and gnits strictness for releases. Based on Eric Blake's | |
783 | suggestion at | |
784 | <http://lists.gnu.org/archive/html/bug-bison/2008-07/msg00019.html>. | |
785 | ||
d43f77e7 PB |
786 | 2008-07-31 Paolo Bonzini <bonzini@gnu.org> |
787 | ||
788 | * NEWS: Clarify documentation of %language. | |
789 | ||
fee2ed87 PB |
790 | 2008-07-31 Paolo Bonzini <bonzini@gnu.org> |
791 | ||
792 | Support usage of git-merge-changelog. | |
793 | * .gitattributes: New. | |
794 | * HACKING: Document usage of git-merge-changelog. | |
795 | * bootstrap: Install git-merge-changelog entries in .git/config | |
796 | if appropriate. | |
797 | ||
78029cd5 JD |
798 | 2008-07-27 Joel E. Denny <jdenny@ces.clemson.edu> |
799 | ||
800 | Remove remaining dependence on CVS Id keyword. | |
801 | * ChangeLog: For the sake of people still using CVS, don't use dollars | |
802 | when mentioning Id. | |
803 | * data/xslt/bison.xsl: Remove Id from header comments, where it was | |
804 | unusual anyway. | |
805 | * data/xslt/xml2dot.xsl: Likewise. | |
806 | * data/xslt/xml2text.xsl: Likewise. | |
807 | * data/xslt/xml2xhtml.xsl: Likewise. | |
808 | * doc/Doxyfile.in (PROJECT_NUMBER): Don't use ID. | |
809 | * doc/Makefile.am (neutralize): Remove, no longer needed. | |
810 | (.x.1): Don't use neutralize. | |
811 | (edit): Don't substitute for ID. | |
812 | (Doxyfile): Don't define Id, and thus don't depend on ChangeLog. | |
813 | ||
c53d18b1 JD |
814 | 2008-07-27 Joel E. Denny <jdenny@ces.clemson.edu> |
815 | ||
816 | Fix dependence on computed configure variables. | |
817 | * doc/Makefile.am (common_dep): Depend on $(top_srcdir)/configure not | |
818 | $(top_srcdir)/configure.ac so that changes to computed variables, such | |
819 | as PACKAGE_VERSION, are seen. | |
820 | * tests/Makefile.am ($(srcdir)/package.m4): Likewise. | |
821 | ||
5523ac79 JD |
822 | 2008-07-20 Joel E. Denny <jdenny@ces.clemson.edu> |
823 | ||
824 | Update copyright dates for recent changes. | |
825 | * Makefile.am: Here. | |
826 | * src/Makefile.am: Here. | |
827 | * src/reduce.c: Here. | |
828 | * tests/reduce.at: Here. | |
829 | ||
8fa36911 JD |
830 | 2008-07-18 Joel E. Denny <jdenny@ces.clemson.edu> |
831 | ||
832 | Use git-version-gen for version names between releases. | |
833 | * .cvsignore (.tarball-version, GNUmakefile, *~): Add. | |
834 | * .gitignore (/.tarball-version, /GNUmakefile, /*~): Add. | |
835 | * .prev-version: New. | |
836 | * .version.in: Remove. | |
78029cd5 | 837 | * ChangeLog: Remove the Id previously used for capturing the CVS |
8fa36911 JD |
838 | revision. |
839 | * GNUmakefile: Remove, now copied from Gnulib. | |
840 | * Makefile.am: Add code suggested by comments in | |
841 | build-aux/git-version-gen. | |
842 | (EXTRA_DIST): Remove GNUmakefile, handled by Gnulib. Add maint.mk, | |
843 | .prev-version, and .version. | |
844 | * NEWS (2.3b+): Rename to... | |
845 | (?.?): ... this because we're dropping the "+" version naming scheme, | |
846 | but, in general, we still can't be sure of our next release name. | |
847 | * bootstrap: Add a quick hack to remove from .gitignore the | |
848 | GNUmakefile entry that gnulib adds. We already have a /GNUmakefile | |
849 | entry. This should really be fixed in gnulib instead. | |
850 | * bootstrap.conf (gnulib_modules): Add gnumakefile. | |
851 | * configure.ac (AC_INIT): Set version name by invoking | |
852 | build-aux/git-version-gen. | |
853 | (AC_CONFIG_FILES): Remove .version, now generated by | |
854 | build-aux/git-version-gen. | |
855 | * maint.mk: New, copied from coreutils. | |
856 | * doc/.cvsignore (bison.1): Add. | |
857 | * doc/.gitignore (/bison.1): Add. | |
858 | * doc/bison.1: Remove, generated. | |
859 | * src/.cvsignore (revision.c): Remove. | |
860 | * src/.gitignore (/revision.c): Remove. | |
861 | * src/Makefile.am (bison_SOURCES): Remove revision.c and revision.h. | |
862 | (BUILT_SOURCES): Remove revision.c. | |
863 | (revision.c): Remove. | |
864 | * src/getargs.c (version): Don't print revision after the VERSION. | |
865 | * src/revision.h: Remove. | |
866 | ||
bcf07cb7 JD |
867 | 2008-07-16 Joel E. Denny <jdenny@ces.clemson.edu> |
868 | ||
869 | Fix untranslatable composition of sentences. Reported by Goran | |
870 | Uddeborg at | |
871 | <http://lists.gnu.org/archive/html/bug-bison/2008-06/msg00000.html>. | |
872 | * THANKS (Goran Uddeborg): Add. | |
873 | * src/reduce.c (reduce_print): Report the number of nonterminals and | |
874 | rules useless in the grammar in separate sentences. | |
875 | * tests/reduce.at (Useless Rules): Update output. | |
876 | (Reduced Automaton): Likewise. | |
877 | (Underivable Rules): Likewise. | |
878 | (Empty Language): Likewise. | |
879 | ||
9aacab9a JD |
880 | 2008-07-15 Joel E. Denny <jdenny@ces.clemson.edu> |
881 | ||
882 | Fix some .gitignore and .cvsignore problems. | |
883 | * bootstrap (insert_sorted_if_absent): Replace all uses with... | |
884 | (insert_vc_ignore): ... this new function, which prepends `/' to all | |
885 | .gitignore entries before passing them to insert_sorted_if_absent. | |
886 | * bootstrap.conf (vc_ignore): Set to '.cvsignore .gitignore' so that | |
887 | .cvsignore files are maintained even though Bison developers run | |
888 | bootstrap while using Git. | |
889 | * .cvsignore (*.patch *.log log patches applied): Remove, apparently | |
890 | unneeded by Bison. | |
891 | (gnulib): Add. | |
892 | * .gitignore (/*.patch *.log log patches applied): Remove, broken and | |
893 | unneeded. Reported by Eric Blake. | |
894 | * lib/.gitignore (/*~): Add. | |
895 | * po/.cvsignore, runtime-po/.cvsignore: Sync with .gitignore. | |
896 | * examples/calc++/.gitignore (/calc++.exe): Add. Reported by Eric | |
897 | Blake. | |
898 | * src/.gitignore (/bison.exe): Add. Reported by Eric Blake. | |
899 | ||
a9fc7990 JD |
900 | 2008-07-15 Joel E. Denny <jdenny@ces.clemson.edu> |
901 | ||
902 | Improve forward-compatibility with GNU M4. Reported by Eric Blake at | |
903 | <http://lists.gnu.org/archive/html/bug-bison/2008-07/msg00000.html>. | |
904 | * bootstrap.conf (gnulib_modules): Add unsetenv. | |
905 | * lib/.gitignore, lib/.cvsignore (/unsetenv.c): Add. | |
906 | * m4/.gitignore, m4/.cvsignore (/environ.m4): Add. | |
907 | (/setenv.m4): Add. | |
908 | * src/output.c (output_skeleton): For the m4 invocation, pass -dV as | |
909 | the first argument because it may become position-dependent, and unset | |
910 | POSIXLY_CORRECT so Bison's skeletons have access to GNU M4 extensions. | |
911 | Add comments explaining these issues in more detail. | |
912 | ||
0f1d6f10 JD |
913 | 2008-07-14 Joel E. Denny <jdenny@ces.clemson.edu> |
914 | ||
915 | Add .gitignore everywhere based on .cvsignore. | |
916 | * .gitignore: New. | |
917 | * build-aux/.gitignore: New. | |
918 | * data/.gitignore: New. | |
919 | * doc/.gitignore: New. | |
920 | * etc/.gitignore: New. | |
921 | * examples/.gitignore: New. | |
922 | * examples/calc++/.gitignore: New. | |
923 | * lib/.gitignore: New. | |
924 | * m4/.gitignore: New. | |
925 | * po/.gitignore: New. | |
926 | * runtime-po/.gitignore: New. | |
927 | * src/.gitignore: New. | |
928 | * tests/.gitignore: New. | |
929 | ||
7bd1665a JD |
930 | 2008-05-27 Joel E. Denny <jdenny@ces.clemson.edu> |
931 | ||
932 | * NEWS (2.3b+): New section, empty for now. | |
933 | * configure.ac (AC_INIT): 2.3b -> 2.3b+. | |
934 | ||
72c5b982 JD |
935 | 2008-05-27 Joel E. Denny <jdenny@ces.clemson.edu> |
936 | ||
937 | * NEWS (2.3b): Update release date since there has been a delay in | |
938 | getting the announcements and tarballs out. | |
939 | ||
bd02cd5d JD |
940 | 2008-05-23 Joel E. Denny <jdenny@ces.clemson.edu> |
941 | ||
942 | * NEWS: Version 2.3b. | |
943 | * configure.ac (AC_INIT): Likewise. | |
944 | (PACKAGE_COPYRIGHT_YEAR): Update to 2008. | |
945 | ||
9126263e JD |
946 | 2008-05-23 Joel E. Denny <jdenny@ces.clemson.edu> |
947 | ||
948 | * HACKING: Don't say don't mention HACKING in the ChangeLog. We've | |
949 | been doing it for years. | |
950 | (Test suite): Mention maintainer-push-check and maintainer-xml-check. | |
951 | (Release Procedure): Add FIXME about make alpha being unmaintained. | |
952 | ||
fa6aa7b3 JD |
953 | 2008-05-13 Joel E. Denny <jdenny@ces.clemson.edu> |
954 | ||
955 | * data/yacc.c: Reformat m4 a little for readability. | |
956 | * src/lalr.c (build_relations): Correct comment. | |
957 | ||
d30b312d JMG |
958 | 2008-05-12 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
959 | ||
960 | DJGPP specific issue. | |
961 | * djgpp/config.sed: Fixes required to run configure scripts generated | |
962 | by autoconf 2.62. | |
963 | ||
138d4cd9 JD |
964 | 2008-05-07 Joel E. Denny <jdenny@ces.clemson.edu> |
965 | ||
966 | * HACKING (Release Procedure): translation@iro.umontreal.ca is now | |
967 | coordinator@translationproject.org. | |
968 | ||
8f7e2e1f JD |
969 | 2008-05-06 Joel E. Denny <jdenny@ces.clemson.edu> |
970 | ||
971 | * THANKS: Add Eric Blake. | |
972 | ||
f55efa38 JD |
973 | 2008-04-23 Eric Blake <ebb9@byu.net> |
974 | ||
975 | Revert prior patch, by working around autoconf regression. | |
976 | * tests/output.at (m4_expand): Add workaround for autoconf 2.62. | |
977 | ("Output file name: ("): Uncomment test. | |
978 | ("Output file name: )"): Likewise. | |
979 | Based on an idea from Noah Misch. | |
980 | ||
096c9f9d JD |
981 | 2008-04-21 Joel E. Denny <jdenny@ces.clemson.edu> |
982 | ||
983 | Work-around an Autoconf 2.62 AT_SETUP bug that was not present in | |
984 | 2.61. Reported by Juan Manuel Guerrero at | |
985 | <http://lists.gnu.org/archive/html/bug-bison/2008-04/msg00011.html>. | |
986 | * tests/output.at ("Output file name: ("): Comment out test case for | |
987 | now. | |
988 | ("Output file name: )"): Likewise. | |
989 | ||
0f664b89 JD |
990 | 2008-04-21 Joel E. Denny <jdenny@ces.clemson.edu> |
991 | ||
992 | * GNUmakefile: Update git-version-gen invocation so make dist | |
993 | succeeds. | |
994 | ||
1cfe6375 JD |
995 | 2008-04-21 Joel E. Denny <jdenny@ces.clemson.edu> |
996 | ||
997 | Update to the current gnulib CVS repository, and fix trigraph handling | |
998 | in Bison. | |
999 | * bootstrap: Update gnulib CVS repository URL. | |
1000 | (symlink_to_dir): Encapsulate the code that guarantees the destination | |
1001 | directory exists into... | |
1002 | (check_dst_dir): ... this new function, and... | |
1003 | (cp_mark_as_generated): ... reuse it here so that bootstrap doesn't | |
1004 | fail when copying files into lib/uniwidth/. | |
1005 | * src/output.c (prepare_symbols): When writing yytname muscles, where | |
1006 | symbol names will be encoded in C-string literals, tell quotearg to | |
1007 | escape trigraphs. This used to be the default in gnulib. | |
1008 | * tests/regression.at (Token definitions): Because of the change in | |
1009 | gnulib's quotearg behavior, string_as_id in parse-gram.y no longer | |
1010 | escapes trigraphs in symbol names. Thus, yytname no longer has | |
1011 | trigraphs unnecessarily doubly escaped. Update test case output. | |
1012 | Extend test case to be sure Bison's own error messages will no longer | |
1013 | have trigraphs in symbol names unnecessarily escaped once. | |
1014 | ||
74c52fc8 JD |
1015 | 2008-04-20 Joel E. Denny <jdenny@ces.clemson.edu> |
1016 | ||
1017 | Fix make dist infinite loop reported by Juan Manuel Guerrero at | |
1018 | <http://lists.gnu.org/archive/html/bug-bison/2008-01/msg00009.html>. | |
1019 | * .cvsignore: Add .version. | |
1020 | * .version.in: New. | |
1021 | * bootstrap.conf (gnulib_modules): Add git-version-gen. | |
1022 | * configure.ac (AC_CONFIG_FILES): Add .version. | |
1023 | * build-aux/.cvsignore: Add git-version-gen. | |
1024 | ||
8e55b3aa JD |
1025 | 2008-03-08 Joel E. Denny <jdenny@ces.clemson.edu> |
1026 | ||
1027 | * NEWS (2.3a+): Mention that -g now takes an argument. | |
1028 | * doc/bison.texinfo (Bison Options): Reword -W entry a little for | |
1029 | consistency. Update the -g and -x entries now that they take | |
1030 | arguments. Use brackets to indicate optional arguments. | |
1031 | * src/getargs.c (usage): Explain the relationship between arguments of | |
1032 | long and short options more completely. Document --defines and -d | |
1033 | separately since the former takes an argument but, for POSIX Yacc, the | |
1034 | latter does not. | |
1035 | (short_options): Let -W take an optional argument like --warnings. | |
8452fdd9 | 1036 | (getargs): Sort cases. |
8e55b3aa | 1037 | |
59c5ac72 AD |
1038 | 2008-02-28 Akim Demaille <demaille@gostai.com> |
1039 | ||
1040 | * doc/bison.texinfo: Fix a few typos. | |
1041 | ||
118d4978 AD |
1042 | 2008-02-28 Akim Demaille <akim@epita.fr> |
1043 | ||
1044 | * doc/bison.texinfo (Bison Options): Document -W. | |
1045 | Based on Joel E. Denny's NEWS entry, and Automake's documentation. | |
1046 | ||
7020f1e9 AD |
1047 | 2008-02-28 Akim Demaille <akim@epita.fr> |
1048 | ||
1049 | * src/getargs.c (short_options): Split and sort for readability. | |
1050 | -g and -x take optional arguments, just like their long options. | |
1051 | * build-aux/cross-options.pl: Use /x to make the regexp easier to | |
1052 | understand. | |
1053 | Fix the handling of $opt which resulted in all the argument to be | |
1054 | considered as optional. | |
1055 | ||
59da312b JD |
1056 | 2008-02-22 Joel E. Denny <jdenny@ces.clemson.edu> |
1057 | ||
1058 | * NEWS (2.3a+): Don't say %language is experimental. Mention Java and | |
1059 | say its interface is experimental. | |
1060 | * doc/bison.texinfo (Decl Summary): In the %language entry, mention | |
1061 | Java. | |
1062 | (Bison Options): In the -L and --language entry, mention Java. | |
1063 | (Java Bison Interface): Say the interface is experimental. | |
1064 | * src/getargs.c (usage): Mention -L and --language. | |
1065 | ||
1066 | * NEWS (2.3a+): Say the push parsing interface is experimental. | |
1067 | * doc/bison.texinfo (Push Decl): Likewise. | |
1068 | (Decl Summary): Likewise in the "%define api.push_pull" entry. | |
1069 | (Push Parser Function): Likewise. | |
1070 | (Pull Parser Function): Likewise. | |
1071 | (Parser Create Function): Likewise. | |
1072 | (Parser Delete Function): Likewise. | |
1073 | (Table of Symbols): Likewise in the yypstate_delete, yypstate_new, | |
1074 | yypull_parse, and yypush_parse entries. | |
1075 | ||
1076 | * NEWS (2.3a+): Mention XML support, and say the schema is | |
1077 | experimental. | |
1078 | * doc/bison.texinfo (Bison Options): Mention -x and --xml. | |
1079 | * src/getargs.c (usage): Say the XML schema is experimental. | |
1080 | ||
1081 | * NEWS (2.3a+): Say option instead of flag. | |
1082 | ||
2bb3ebec WP |
1083 | 2008-02-21 Wojciech Polak <polak@gnu.org> |
1084 | ||
1085 | * data/xslt/xml2xhtml.xsl (xsl:template match="/"): Change footer | |
1086 | text. | |
1087 | ||
333e670c JD |
1088 | 2008-02-20 Joel E. Denny <jdenny@ces.clemson.edu> |
1089 | ||
1090 | Fix impure push parser compile error reported by Bob Rossi at | |
1091 | <http://lists.gnu.org/archive/html/help-bison/2008-02/msg00023.html>. | |
1092 | * data/yacc.c: Clean up whitespace in the output a little. | |
1093 | (yypstate_allocated): Define for impure push parsers regardless of | |
1094 | whether the pull interface is also requested. | |
1095 | * tests/push.at (Push Parsing: Multiple impure instances): Extend to | |
1096 | check impure push parsers without the pull interface. | |
1097 | ||
1098 | * data/yacc.c (yypstate_new): Don't try to invoke yyerror since | |
1099 | yyerror takes arguments specified by %parse-param while yypstate_new | |
1100 | does not. | |
1101 | * doc/bison.texinfo (Parser Create Function): Document that | |
1102 | yypstate_new returns 0 for multiple impure parser instances. | |
1103 | * tests/push.at (Push Parsing: Multiple impure instances): Update | |
1104 | expected stderr output. | |
1105 | ||
798096e1 JD |
1106 | 2008-02-19 Joel E. Denny <jdenny@ces.clemson.edu> |
1107 | ||
1108 | * runtime-po/POTFILES.in (push.c): Remove. | |
1109 | ||
9ca7f077 JD |
1110 | 2008-02-17 Joel E. Denny <jdenny@ces.clemson.edu> |
1111 | ||
1112 | * data/Makefile.am (dist_pkgdata_DATA): Remove push.c. | |
1113 | * data/push.c: Rename to... | |
1114 | * data/yacc.c: ... this, overwriting it. | |
1115 | * etc/bench.pl.in (bench_grammar): `%pure-parser'-> `%define api.pure'. | |
1116 | `%push-pull-parser' -> `%define api.push_pull "both"'. | |
1117 | Remove old yacc.c tests, and update push.c tests to yacc.c. | |
1118 | ||
42ee26bb JD |
1119 | 2008-02-17 Joel E. Denny <jdenny@ces.clemson.edu> |
1120 | ||
1121 | * data/bison.m4 (b4_percent_code_get): Output %code block comments like | |
1122 | `"%code top" blocks' instead of `%code "top" blocks'. | |
1123 | * data/push.c: Import yacc.c changes from 2008-01-09 and 2007-08-03. | |
1124 | Clean up whitespace in the output a little. | |
1125 | ||
b1cc23c4 JD |
1126 | 2008-02-16 Joel E. Denny <jdenny@ces.clemson.edu> |
1127 | ||
1128 | Fix documentation problems reported by Tim Josling at | |
1129 | <http://lists.gnu.org/archive/html/bug-bison/2008-01/msg00013.html>. | |
1130 | * NEWS (2.3a+): Mention removal of --no-parser, -n, and %no-parser. | |
1131 | * doc/bison.texinfo (Token Decl): Token numbers are *nonnegative* | |
1132 | integers. Explain the effect of literal string aliases on error | |
1133 | messages. Copy token 0 documentation from the C++ skeleton | |
1134 | documentation. | |
1135 | ||
ab7f29f8 JD |
1136 | 2008-02-16 Joel E. Denny <jdenny@ces.clemson.edu> |
1137 | ||
1138 | Accept a token number in a %left, %right, or %nonassoc for POSIX | |
1139 | conformance. Reported by Tim Josling at | |
1140 | <http://lists.gnu.org/archive/html/bug-bison/2008-01/msg00010.html>. | |
1141 | * NEWS (2.3a+): Mention. | |
1142 | * doc/bison.texinfo (Precedence Decl): Describe how literal strings | |
1143 | and code numbers are treated by precedence declarations. | |
1144 | * src/parse-gram.y (precedence_declaration): Use symbols.prec instead | |
1145 | of symbols.1. | |
1146 | (symbols.prec): New, just like symbols.1 but uses symbol.prec instead | |
1147 | of symbol. | |
1148 | (symbol.prec): New, just like symbol but allows INT. | |
1149 | * src/symtab.c (symbol_user_token_number_set): Remove an aver that no | |
1150 | longer holds. | |
1151 | * tests/regression.at (Token number in precedence declaration): New | |
1152 | test case. | |
1153 | ||
a924ef36 JMG |
1154 | 2008-02-06 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
1155 | ||
1156 | DJGPP specific issues. | |
1157 | * djgpp/config.bat: Add filenames that are not 8.3 clean and that must | |
1158 | be changed. Copyright timestamp adjusted. | |
1159 | * djgpp/config.sed: Add filenames that are not 8.3 clean and that must | |
1160 | be changed. Copyright timestamp adjusted. | |
1161 | * djgpp/config.site: Copyright timestamp adjusted. | |
1162 | * djgpp/config_h.sed: Copyright timestamp adjusted. | |
1163 | * djgpp/djunpack.bat: Copyright timestamp adjusted. | |
1164 | * djgpp/fnchnage.lst: Add filenames that are not 8.3 clean to the | |
1165 | filename translation list. | |
1166 | * djgpp/subpipe.c (init_subpipe): Check the environment variables | |
1167 | TMPDIR, TMP and TEMP, in that order, to determinate where the temp | |
1168 | files shall be created. Before trying to use the temp dir where the | |
1169 | environment variable points to check that the dir really exists. If | |
1170 | not default to the cwd as temp dir. Copyright timestamp adjusted. | |
1171 | * djgpp/subpipe.h: Copyright timestamp adjusted. | |
1172 | * djgpp/testsuite.sed: Copyright timestamp adjusted. | |
1173 | ||
389c8cfd PE |
1174 | 2008-01-30 Paul Eggert <eggert@cs.ucla.edu> |
1175 | ||
1176 | * doc/bison.texinfo: Update Back-Cover text to reflect new GNU wording. | |
1177 | ||
5d1cfef4 PE |
1178 | 2008-01-09 Paul Eggert <eggert@cs.ucla.edu> |
1179 | ||
1180 | * data/yacc.c (yyparse): Correct the comment when locations aren't used. | |
1181 | Problem reported by Claudio Saavedra in | |
1182 | <http://lists.gnu.org/archive/html/bug-bison/2008-01/msg00003.html>. | |
1183 | ||
e2dcf996 WP |
1184 | 2008-01-05 Wojciech Polak <polak@gnu.org> |
1185 | ||
1186 | * data/xslt/xml2xhtml.xsl (xsl:template match="/"): Precede an XHTML | |
1187 | document's title with the input grammar file name. | |
1188 | ||
da730230 JD |
1189 | 2007-12-22 Joel E. Denny <jdenny@ces.clemson.edu> |
1190 | ||
1191 | Automate regression testing of the XML/XSLT implementation. Discussed | |
1192 | starting at | |
1193 | <http://lists.gnu.org/archive/html/bison-patches/2007-11/msg00021.html>. | |
1194 | * configure.ac (XSLTPROC): New substitution. | |
1195 | * Makefile.am (maintainer-xml-check): New phony target invoking... | |
1196 | * tests/Makefile.am (maintainer-xml-check): ... this new phony target | |
1197 | invoking make maintainer-check with BISON_TEST_XML=1. | |
1198 | * tests/atlocal.in (XSLTPROC): New. | |
1199 | * tests/local.at (AT_BISON_CHECK): New macro to (1) instruct Valgrind | |
1200 | not to report reachable memory when Bison is expected to have a | |
1201 | non-zero exit status and (2) to compare XML/XSLT output with --graph | |
1202 | and --report=all output for every working grammar when | |
1203 | BISON_TEST_XML=1. | |
1204 | (AT_BISON_CHECK_NO_XML): Likewise, but skip XML checks. | |
1205 | (AT_BISON_CHECK_XML): New. | |
1206 | (AT_QUELL_VALGRIND): New. | |
1207 | * tests/testsuite.at (ORIGINAL_AT_CHECK): Remove this and... | |
1208 | (AT_CHECK): ... don't redefine this since this was the old way to | |
1209 | quell Valgrind. | |
1210 | * tests/actions.at: Rewrite all AT_CHECK invocations for bison as | |
1211 | AT_BISON_CHECK invocations. | |
1212 | * tests/c++.at: Likewise. | |
1213 | * tests/calc.at: Likewise. | |
1214 | * tests/conflicts.at: Likewise. | |
1215 | * tests/cxx-type.at: Likewise. | |
1216 | * tests/existing.at: Likewise. | |
1217 | * tests/glr-regression.at: Likewise. | |
1218 | * tests/headers.at: Likewise. | |
1219 | * tests/input.at: Likewise. | |
1220 | * tests/java.at: Likewise. | |
1221 | * tests/output.at: Likewise. | |
1222 | * tests/push.at: Likewise. | |
1223 | * tests/reduce.at: Likewise. | |
1224 | * tests/regression.at: Likewise. | |
1225 | * tests/sets.at: Likewise. | |
1226 | * tests/skeletons.at: Likewise. | |
1227 | * tests/synclines.at: Likewise. | |
1228 | * tests/torture.at: Likewise. | |
1229 | (Big triangle): Use AT_BISON_CHECK_NO_XML instead since this grammar | |
1230 | tends to hang xsltproc. | |
1231 | (Big horizontal): Likewise. | |
1232 | ||
408476bc JD |
1233 | 2007-12-08 Joel E. Denny <jdenny@ces.clemson.edu> |
1234 | ||
1235 | In XML output, remove redundant class attribute on symbol element. | |
1236 | * data/xslt/bison.xsl (xsl:key name="bison:symbolByName"): New. | |
1237 | * data/xslt/xml2xhtml.xsl (xsl:template match="symbol"): Use it to | |
1238 | look up a symbol to determine whether it's a nonterminal or terminal. | |
1239 | * src/gram.c (rule_rhs_print_xml): Remove class attribute. | |
1240 | * src/state.c (state_rule_lookahead_tokens_print_xml): Likewise. | |
1241 | ||
1242 | Add prec/assoc information to XML output. | |
1243 | * src/gram.c (grammar_rules_print_xml): For each rule that has a | |
1244 | %prec, add a percent_prec attribute. | |
1245 | * src/print-xml.c (print_grammar): For each terminal that has a | |
1246 | precedence or associativity, add a prec or assoc attribute. | |
1247 | (xml_indent): New. | |
1248 | (xml_puts): Use xml_indent. | |
1249 | (xml_printf): Use xml_indent. | |
1250 | * src/print-xml.h (xml_indent): Prototype. | |
1251 | ||
1252 | * tests/existing.at (GNU pic Grammar): Fix a rule miscopied from | |
1253 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00026.html>. | |
1254 | ||
d4a26c48 JD |
1255 | 2007-12-08 Joel E. Denny <jdenny@ces.clemson.edu> |
1256 | ||
1257 | * data/xslt/bison.xsl (bison:ruleNumber): Rename to... | |
1258 | (bison:ruleByNumber): ... this for clarity. | |
1259 | * data/xslt/xml2dot.xsl (xsl:template match="item"): Update. | |
1260 | * data/xslt/xml2text.xsl (xsl:template match="item"): Update. | |
1261 | (xsl:template match="reduction"): Update. | |
1262 | (xsl:template match="item"): Update. | |
1263 | (xsl:template match="reduction"): Update. | |
1264 | ||
1265 | In the XML output, don't print the list of rules where symbols appear. | |
1266 | Compute it in XSLT instead. Discussed at | |
1267 | <http://lists.gnu.org/archive/html/bison-patches/2007-09/msg00024.html>. | |
1268 | * data/xslt/bison.xsl (bison:ruleByLhs): New. | |
1269 | (bison:ruleByRhs): New. | |
1270 | * data/xslt/xml2text.xsl (xsl:template match="terminal"): Use | |
1271 | bison:ruleByRhs. | |
1272 | (xsl:template match="terminal/rule"): Remove. | |
1273 | (xsl:template match="nonterminal"): Use bison:ruleByLhs and | |
1274 | bison:ruleByRhs. | |
1275 | (xsl:template match="nonterminal/left/rule|nonterminal/right/rule"): | |
1276 | Remove. | |
1277 | * data/xslt/xml2xhtml.xsl (xsl:template match="terminal"): Use | |
1278 | bison:ruleByRhs and mode="number-link" for rule template. | |
1279 | (xsl:template match="terminal/rule"): Remove. | |
1280 | (xsl:template match="nonterminal"): Use bison:ruleByLhs and | |
1281 | bison:ruleByRhs and mode="number-link" for rule template. | |
1282 | (xsl:template match="nonterminal/left/rule|nonterminal/right/rule"): | |
1283 | Rewrite as... | |
1284 | (xsl:template match="rule" mode="number-link"): ... this. | |
1285 | * src/print-xml.c (print_grammar): Don't print the list of rules. | |
1286 | ||
ef1b4273 JD |
1287 | 2007-12-01 Joel E. Denny <jdenny@ces.clemson.edu> |
1288 | ||
1289 | Don't let --report affect XML output; always print all information. | |
1290 | Discussed at | |
1291 | <http://lists.gnu.org/archive/html/bison-patches/2007-09/msg00020.html>. | |
1292 | * src/conflicts.c (log_resolution): Implement. | |
1293 | * src/print-xml.c (print_core): Implement. | |
1294 | (print_state): Implement. | |
1295 | (print_xml): Implement. | |
1296 | ||
1297 | * NEWS (2.3a+): Fix quotes. | |
1298 | * src/parse-gram.y (prologue_declaration): For consistency with -v, | |
1299 | don't let %verbose clear the list specified by --report. | |
1300 | ||
0f6cd9e3 AD |
1301 | 2007-11-26 Akim Demaille <akim@epita.fr> |
1302 | ||
1303 | * data/Makefile.am (dist_pkgdata_DATA): Ship and install bison.xsl. | |
1304 | ||
d80fb37a JD |
1305 | 2007-11-24 Joel E. Denny <jdenny@ces.clemson.edu> |
1306 | ||
1307 | In the XML output, list useless and unused symbols and rules with the | |
1308 | useful ones and add a "usefulness" attribute. Discussed starting at | |
1309 | <http://lists.gnu.org/archive/html/bison-patches/2007-09/msg00017.html>. | |
1310 | * src/gram.c (grammar_rules_partial_print_xml): Remove. | |
1311 | (grammar_rules_print_xml): Print all rules instead of just those | |
1312 | useful in the grammar, and add a "usefulness" attribute. | |
1313 | * src/gram.h (grammar_rules_partial_print_xml): Remove prototype. | |
1314 | * src/print-xml.c (print_rules_useless_in_parser): Remove. | |
1315 | (print_grammar): Print all nonterminals instead of just useful ones, | |
1316 | and add a "usefulness" attribute to nonterminals and terminals. | |
1317 | (print_xml): Don't print a separate "reductions" or | |
1318 | "rules-useless-in-parser" element. | |
1319 | * src/reduce.c (reduce_output): Use reduce_token_unused_in_grammar. | |
1320 | (reduce_xml): Remove. | |
1321 | (reduce_token_unused_in_grammar): New. | |
1322 | (reduce_nonterminal_useless_in_grammar): New. | |
1323 | * src/reduce.h (reduce_xml): Remove prototype. | |
1324 | (reduce_token_unused_in_grammar): Add prototype. | |
1325 | (reduce_nonterminal_useless_in_grammar): Add prototype. | |
1326 | * data/xslt/xml2text.xsl: Update for XML changes. | |
1327 | * data/xslt/xml2xhtml.xsl: Update for XML changes. | |
1328 | * tests/reduce.at (Useless Terminals): Update output. | |
1329 | (Useless Rules): Update output. | |
1330 | (Reduced Automaton): Update output. | |
1331 | ||
1332 | Say "Terminals unused in grammar" instead of "Unused terminals". | |
1333 | * NEWS (2.3a+): Update. | |
1334 | * doc/bison.texinfo (Understanding): Update example output. | |
1335 | * src/reduce.c (reduce_output): Implement. | |
1336 | * data/xslt/xml2text.xsl: Implement. | |
1337 | * data/xslt/xml2xhtml.xsl: Implement. | |
1338 | ||
1bb2bd75 JD |
1339 | 2007-11-18 Joel E. Denny <jdenny@ces.clemson.edu> |
1340 | ||
1341 | Accept --report-file=FILE to override the default `.output' filename. | |
1342 | * NEWS (2.3a+): Mention. | |
1343 | * doc/bison.texinfo (Bison Options): Add an entry. | |
1344 | * src/files.c (compute_output_file_names): Don't override | |
1345 | spec_verbose_file if already set. | |
1346 | * src/getargs.c (usage): Document --report-file. | |
1347 | (REPORT_FILE_OPTION): New anonymous enum member. | |
1348 | (long_options): Add entry for it. | |
1349 | (getargs): Add case for it setting spec_verbose_file. | |
1350 | ||
1351 | * build-aux/cross-options.pl: Don't record a short option just because | |
1352 | there's an arg. | |
1353 | * doc/.cvsignore: Add yacc.1. | |
1354 | ||
a005a9c4 AD |
1355 | 2007-11-14 Akim Demaille <akim@epita.fr> |
1356 | ||
1357 | * doc/yacc.1.in: New. | |
1358 | * configure.ac, doc/Makefile.am: Adjust. | |
1359 | * configure.ac (PACKAGE_COPYRIGHT_YEAR): New substitution, and new | |
1360 | config.h symbol. | |
1361 | Use AC_SUBST for assignments too. | |
1362 | * src/getargs.c (version): Use PACKAGE_COPYRIGHT_YEAR. | |
1363 | ||
cff03fb2 JD |
1364 | 2007-11-10 Joel E. Denny <jdenny@ces.clemson.edu> |
1365 | ||
1366 | * src/gram.c: Remove comments that duplicate comments in gram.h. | |
1367 | ||
1368 | When reporting useless rules and nonterminals, say "useless in grammar" | |
1369 | instead of "useless", and say "useless in parser" instead of "never | |
1370 | reduced". Discussed starting at | |
1371 | <http://lists.gnu.org/archive/html/bison-patches/2007-10/msg00033.html>. | |
1372 | * NEWS (2.3a+): Mention this change. | |
1373 | * data/xslt/xml2text.xsl: Update output text and expected input XML | |
1374 | element names to match changes below. | |
1375 | * data/xslt/xml2xhtml.xsl: Likewise. | |
1376 | (xsl:template match="bison-xml-report"): Add missing entry in Table of | |
1377 | Contents: "Rules useless in parser due to conflicts". | |
1378 | * doc/bison.texinfo (Decl Summary): Reword a little. | |
1379 | (Understanding): Update example output for changes below. | |
1380 | * src/gram.c: (rule_useful_p): Rename to... | |
1381 | (rule_useful_in_grammar_p): ... this. | |
1382 | (rule_useless_p): Rename to... | |
1383 | (rule_useless_in_grammar_p): ... this. | |
1384 | (rule_never_reduced_p): Rename to... | |
1385 | (rule_useless_in_parser_p): ... this. | |
1386 | (grammar_rules_print): Update for renames. | |
1387 | (grammar_rules_print_xml): Update for renames. | |
1388 | (grammar_rules_never_reduced_report): Rename to... | |
1389 | (grammar_rules_useless_report): ... this since it is used for either | |
1390 | kind of useless rule. | |
1391 | * src/gram.h: Reword comments and update function names in prototypes. | |
1392 | * src/main.c (main): Say "rule useless in parser due to conflicts". | |
1393 | * src/print-xml.c (print_rules_never_reduced): Rename to... | |
1394 | (print_rules_useless_in_parser): ... this, and rename output XML | |
1395 | element "rules-never-reduced" to "rules-useless-in-parser". | |
1396 | (print_xml): Update for rename. | |
1397 | * src/print.c (print_results): Say "Rules useless in parser due to | |
1398 | conflicts". | |
1399 | * src/reduce.c (reduce_grammar_tables): Say "rule useless in grammar". | |
1400 | (nonterminals_reduce): Say "nonterminal useless in grammar". | |
1401 | (reduce_output): Say "Nonterminals useless in grammar". | |
1402 | Say "Rules useless in grammar". | |
1403 | (reduce_xml): Rename output XML element "useless" to | |
1404 | "useless-in-grammar". | |
1405 | (reduce_print): Don't report the count of grammatically useless rules | |
1406 | as "rules never reduced" just because %yacc is specified. | |
1407 | In the correct report of this count, say nonterminal(s) and rule(s) | |
1408 | "useless in grammar". | |
1409 | * tests/conflicts.at (S/R in initial): Update expected output. | |
1410 | (Defaulted Conflicted Reduction): Likewise. | |
1411 | (Unreachable States After Conflict Resolution): Likewise. | |
1412 | * tests/existing.at (GNU pic Grammar): Likewise. | |
1413 | * tests/reduce.at (Useless Nonterminals): Likewise. | |
1414 | (Useless Rules): Likewise. | |
1415 | (Reduced Automaton): Likewise. | |
1416 | (Underivable Rules): Likewise. | |
1417 | (Empty Language): Likewise. | |
1418 | ||
66f0441d JD |
1419 | 2007-11-09 Joel E. Denny <jdenny@ces.clemson.edu> |
1420 | ||
1421 | * data/bison.m4 (b4_cat): Put a newline after the end delimiter of the | |
1422 | here document and before the EOF so that BSD's implementation of Bourne | |
1423 | shell doesn't parse the delimiter as part of the here document. | |
1424 | * doc/.cvsignore: Add cross-options.texi. | |
1425 | * src/getargs.c (usage): Add a blank line after the warning categories. | |
1426 | ||
d0ee4105 PB |
1427 | 2007-11-08 Paolo Bonzini <bonzini@gnu.org> |
1428 | ||
1429 | * data/lalr1.java (Lexer): Remove usage of b4_pure_if. | |
1430 | ||
e8b1fb9b AD |
1431 | 2007-11-05 Akim Demaille <akim@epita.fr> |
1432 | ||
1433 | Remove Id: from bison.1. | |
1434 | * doc/Makefile.am (remove_time_stamp): Include the sed invocation. | |
1435 | (perl -0777 -pi -e 's/\.PP\nId): New. | |
1436 | (.x.1): Use it to ignore the version control revision. | |
1437 | ||
2f7a96b5 AD |
1438 | 2007-11-05 Akim Demaille <demaille@gostai.com> |
1439 | ||
1440 | * build-aux/Makefile.am: Ship cross-options.pl. | |
1441 | * doc/Makefile.am: Always refer to cross-options.texi with | |
1442 | $(srcdir). | |
1443 | (MAINTAINERCLEANFILES): Add it. | |
1444 | ||
f4101aa6 AD |
1445 | 2007-11-04 Akim Demaille <demaille@gostai.com> |
1446 | ||
1447 | Generate the long/short option cross-table. | |
1448 | * build-aux/cross-options.pl: New. | |
1449 | * doc/Makefile.am (cross-options.texi): New. | |
1450 | * doc/bison.texinfo: Use it. | |
1451 | ||
727a1401 AD |
1452 | 2007-11-04 Akim Demaille <demaille@gostai.com> |
1453 | ||
1454 | Generate bison.1 using help2man. | |
1455 | * doc/common.x, doc/bison.x: New. | |
1456 | * doc/Makefile.am (bison.1, .x.1): New. | |
1457 | The code is taken from autoconf-2.61/man/Makefile.am. | |
1458 | * configure.ac: Look for help2man. | |
1459 | ||
6aeb9c57 AD |
1460 | 2007-11-04 Akim Demaille <demaille@gostai.com> |
1461 | ||
1462 | Complete --help. | |
1463 | * src/getargs.c (usage): Document -W, make it clear that -d, | |
1464 | -g and -x have optional arguments. | |
1465 | ||
d7be4085 AD |
1466 | 2007-11-04 Akim Demaille <demaille@gostai.com> |
1467 | ||
1468 | Find sha1sum when named gsha1sum. | |
1469 | * bootstrap (find_tool): New. | |
1470 | ($SHA1SUM): New. | |
1471 | ||
d9df47b6 JD |
1472 | 2007-10-28 Joel E. Denny <jdenny@ces.clemson.edu> |
1473 | ||
1474 | Deprecate %pure-parser and add `%define api.pure'. Discussed starting | |
1475 | at | |
1476 | <http://lists.gnu.org/archive/html/bison-patches/2007-09/msg00006.html>. | |
1477 | * NEWS (2.3a+): Mention. | |
1478 | * data/bison.m4 (b4_pure_if): Don't define it here. | |
1479 | * data/c.m4 (b4_identification): Depend on individual skeletons to | |
1480 | define b4_pure_flag, b4_push_flag, or b4_pull_flag if they use the | |
1481 | values of the %define variables api.pure or api.push_pull. Define | |
1482 | YYPURE, YYPUSH, and YYPULL accordingly. | |
1483 | * data/glr.c: Define b4_pure_if based on `%define api.pure' unless | |
1484 | glr.cc has already defined b4_pure_flag. | |
1485 | * data/push.c: Define b4_pure_if based on `%define api.pure'. | |
1486 | Remove YYPUSH and YYPULL since they're back in b4_identification again. | |
42ee26bb | 1487 | * data/yacc.c: Define b4_pure_if based on `%define api.pure'. |
d9df47b6 JD |
1488 | * doc/bison.texinfo (Pure Decl): Update. |
1489 | (Push Decl): Update. | |
1490 | (Decl Summary): Add api.pure to %define entry. | |
1491 | In %pure-parser entry, say it's deprecated and reference %define. | |
1492 | (Pure Calling): Update. | |
1493 | (Error Reporting): Update. | |
1494 | (C++ Scanner Interface): Update. | |
1495 | (How Can I Reset the Parser): Update. | |
1496 | (Table of Symbols): In %pure-parser entry, say it's deprecated and | |
1497 | reference %define. | |
1498 | * src/getargs.c (pure_parser): Remove global variable. | |
1499 | * src/getargs.h (pure_parser): Remove extern. | |
1500 | * src/output.c (prepare): Don't define pure_flag muscle. | |
1501 | * src/parse-gram.y (prologue_declaration): Implement %pure-parser as a | |
1502 | wrapper around `%define api.pure'. | |
1503 | * tests/calc.at (Simple LALR Calculator): Update. | |
1504 | (Simple GLR Calculator): Update. | |
1505 | * tests/cxx-type.at (GLR: Resolve ambiguity, pure, no locations): | |
1506 | Update. | |
1507 | (GLR: Resolve ambiguity, pure, locations): Update. | |
1508 | (GLR: Merge conflicting parses, pure, no locations): Update. | |
1509 | (GLR: Merge conflicting parses, pure, locations): Update. | |
1510 | * tests/glr-regression.at (Uninitialized location when reporting | |
1511 | ambiguity): Update | |
1512 | * tests/input.at (Unused %define api.pure): New test case. | |
1513 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Update definition for | |
1514 | AT_PURE_IF and AT_PURE_AND_LOC_IF. | |
1515 | * tests/push.at (Push Parsing: Memory Leak for Early Deletion): Update. | |
1516 | ||
c373bf8b JD |
1517 | 2007-10-28 Joel E. Denny <jdenny@ces.clemson.edu> |
1518 | ||
1519 | %define push_pull -> %define api.push_pull. Discussed starting at | |
1520 | <http://lists.gnu.org/archive/html/bison-patches/2007-09/msg00005.html>. | |
1521 | * data/push.c: Expect the new name. | |
1522 | * data/yacc.c: Likewise. | |
1523 | * doc/bison.texinfo (Push Decl): Update. | |
1524 | (Decl Summary): Update %define entry. | |
1525 | (Push Parser Function): Update. | |
1526 | (Pull Parser Function): Update. | |
1527 | (Parser Create Function): Update. | |
1528 | (Parser Delete Function): Update. | |
1529 | * tests/calc.at (Simple LALR Calculator): Update. | |
1530 | * tests/input.at (%define enum variables): Update. | |
1531 | * tests/push.at (Push Parsing: Memory Leak for Early Deletion): Update. | |
1532 | (Push Parsing: Multiple impure instances): Update. | |
1533 | (Push Parsing: Unsupported Skeletons): Update. | |
1534 | * tests/torture.at (Exploding the Stack Size with Alloca): Update. | |
1535 | (Exploding the Stack Size with Malloc): Update. | |
1536 | ||
1537 | * NEWS (2.3a+): Add an entry for the push parser, and clean up the | |
1538 | other entries some. | |
1539 | ||
32f19b6b JD |
1540 | 2007-10-27 Joel E. Denny <jdenny@ces.clemson.edu> |
1541 | ||
1542 | For the XML output's terminal element, rename @number to @token-number, | |
1543 | and add @symbol-number. In the nonterminal element, rename @number to | |
1544 | @symbol-number. Discussed starting at | |
1545 | <http://lists.gnu.org/archive/html/bison-patches/2007-10/msg00040.html>. | |
1546 | * data/xslt/xml2text.xsl (xsl:template match="terminal"): Update for | |
1547 | renames. | |
1548 | (xsl:template match="nonterminal"): Likewise. | |
1549 | * data/xslt/xml2xhtml.xsl (xsl:template match="terminal"): Likewise. | |
1550 | (xsl:template match="nonterminal"): Likewise. | |
1551 | * src/print-xml.c (print_grammar): Implement. | |
1552 | ||
255a6b90 JD |
1553 | 2007-10-21 Joel E. Denny <jdenny@ces.clemson.edu> |
1554 | ||
1555 | * data/xslt/xml2dot.xsl (xsl:template match="automaton/state"): After | |
1556 | 2007-10-11 change, the child elements here are items not rules. | |
408476bc | 1557 | (xsl:template match="item"): New. |
255a6b90 JD |
1558 | (xsl:template match="rule"): Update for new reduced itemset. |
1559 | (xsl:template match="point"): Remove. | |
1560 | (xsl:template match="empty"): For consistency with --graph, don't | |
1561 | output "/* empty */". | |
1562 | * data/xslt/xml2text.xsl (xsl:template match="terminal"): When invoking | |
1563 | line-wrap, don't pass a negative value as first-line-length since this | |
1564 | won't work with the following changes. | |
1565 | (xsl:template name="line-wrap"): Simplify slightly. | |
1566 | (xsl:template name="ws-search"): Eliminate recursion. | |
1567 | * src/print_graph.c (print_core): Don't print a reduction's lookahead | |
1568 | set next to an item whose dot is not at the end of the RHS even if it | |
1569 | happens to be associated with the same rule. | |
1570 | ||
88c78747 JD |
1571 | 2007-10-19 Joel E. Denny <jdenny@ces.clemson.edu> |
1572 | ||
31984206 JD |
1573 | Add %define lr.keep_unreachable_states. |
1574 | * NEWS (2.3a+): Mention it in the entry for unreachable state removal. | |
1575 | * doc/bison.texinfo (Decl Summary): Mention it in the %define entry. | |
1576 | * src/main.c (main): Implement it. | |
1577 | * tests/conflicts.at (Unreachable States After Conflict Resolution): | |
1578 | Extend to test it, and fix a typo. | |
1579 | ||
1580 | 2007-10-19 Joel E. Denny <jdenny@ces.clemson.edu> | |
1581 | ||
1582 | * NEWS (2.3a+): Add entry for recent .output file lookahead set fix. | |
88c78747 JD |
1583 | * doc/bison.texinfo (Understanding): Remove a bogus lookahead set in |
1584 | the example .output text. | |
1585 | * tests/regression.at (Extra lookahead sets in report): Improve wording | |
1586 | of comments. | |
1587 | ||
b7a70162 WP |
1588 | 2007-10-17 Wojciech Polak <polak@gnu.org> |
1589 | ||
1590 | * src/print-xml.c (print_grammar): Renamed | |
1591 | <terminal> and <nonterminal> attributes: | |
1592 | "type" to "number" and "symbol" to "name". | |
1593 | * data/xslt/xml2text.xsl (xsl:template match="terminal"): | |
1594 | Use new attribute names. | |
1595 | (xsl:template match="nonterminal"): Likewise. | |
1596 | * data/xslt/xml2xhtml.xsl: Likewise. | |
1597 | ||
a0de5091 JD |
1598 | 2007-10-17 Joel E. Denny <jdenny@ces.clemson.edu> |
1599 | ||
1600 | * doc/bison.texinfo (Bison Options): Add entry for --print-datadir. | |
1601 | (Option Cross Key): Likewise. | |
1602 | ||
1603 | * src/print-xml.c (print_core): Don't print a reduction's lookahead set | |
1604 | next to an item whose dot is not at the end of the RHS even if it | |
1605 | happens to be associated with the same rule. | |
1606 | * src/print.c (print_core): Likewise. | |
1607 | * tests/conflicts.at (Unresolved SR Conflicts): Update output. | |
1608 | (Resolved SR Conflicts): Update output. | |
1609 | * tests/regression.at (Extra lookahead sets in report): New test case. | |
1610 | ||
4c20d18d WP |
1611 | 2007-10-11 Wojciech Polak <polak@gnu.org> |
1612 | ||
1613 | * src/print-xml.c (print_core): Remove item set | |
1614 | redundancy. | |
1615 | * data/xslt/bison.xsl (bison:ruleNumber): New key. | |
1616 | Improve processing time. Suggested by Joel E. Denny. | |
1617 | * data/xslt/xml2dot.xsl (xsl:template name="escape"): | |
1618 | Write xsl:param "required" attribute as comment. | |
1619 | * data/xslt/xml2text.xsl (xsl:template match="item"): New. | |
1620 | (xsl:template match="rule"): Support new reduced itemset. | |
1621 | (xsl:template match="point"): Remove. | |
1622 | * data/xslt/xml2xhtml.xsl: Likewise. | |
1623 | ||
f506ad1c JD |
1624 | 2007-10-09 Joel E. Denny <jdenny@ces.clemson.edu> |
1625 | ||
1626 | * src/getargs.c (version): Update copyright year. | |
1627 | ||
21f1b063 JD |
1628 | 2007-10-09 Joel E. Denny <jdenny@ces.clemson.edu> |
1629 | ||
1630 | Make xml2dot.xsl and --graph produce the same output. | |
1631 | * data/xslt/xml2dot.xsl (xsl:template match="rule"): Use a ` ' | |
1632 | instead of a `\n'. That is, don't add escapes yet or they'll be doubly | |
1633 | escaped later. | |
1634 | (xsl:template name="output-node"): Use the new escape template instead | |
1635 | of the string-replace template directly. | |
1636 | (xsl:template name="output-edge"): Likewise. | |
1637 | (xsl:template name="escape"): New, escapes backslashes and newlines in | |
1638 | addition to quotation marks. | |
1639 | * src/graphviz.c (start_graph, output_node, output_edge): Add | |
1640 | whitespace to output for legibility. | |
1641 | ||
1642 | Make xml2text.xsl and --report produce the same output, and remove the | |
1643 | XML "conflicts" element since a conflict summary is easily extracted | |
1644 | from the automaton. | |
1645 | * data/xslt/bison.xsl: New. | |
1646 | (xsl:template match="state" mode="bison:count-conflicts): New. | |
1647 | * data/xslt/xml2text.xsl: Import bison.xsl. | |
1648 | (xsl:template match="bison-xml-report"): Instead of styling the | |
1649 | "conflicts" element, style the "automaton" element with mode | |
1650 | "conflicts". Unlike the former, the latter lists S/R and R/R | |
1651 | conflicts for a state on the same line. | |
1652 | (xsl:template match="conflicts"): Remove. | |
1653 | (xsl:template match="conflict"): Remove. | |
1654 | (xsl:template match="terminal"): Line-wrap the list of rules in which | |
1655 | the terminal is used. | |
1656 | (xsl:template match="nonterminal"): Likewise for nonterminals. | |
1657 | (xsl:template match="automaton" mode="conflicts"): New. | |
1658 | (xsl:template match="state" mode="conflicts"): New. | |
1659 | (xsl:template name="line-wrap"): New. | |
1660 | (xsl:template name="ws-search"): New. | |
1661 | * data/xslt/xml2xhtml.xsl: Import bison.xsl. | |
1662 | (xsl:template match="bison-xml-report"): Instead of styling the | |
1663 | "conflicts" element, style the "automaton" element with mode | |
1664 | "conflicts." | |
1665 | (xsl:template match="conflicts"): Remove. | |
1666 | (xsl:template match="conflict"): Remove. | |
1667 | (xsl:template match="automaton" mode="conflicts"): New. | |
1668 | (xsl:template match="state" mode="conflicts): New. | |
1669 | * src/conflicts.c (conflicts_output_xml): Remove. | |
1670 | * src/conflicts.h (conflicts_output_xml): Remove prototype. | |
1671 | * src/print-xml.c (print_xml): Don't invoke conflicts_output_xml. | |
1672 | * src/print.c (print_grammar): Consistently wrap at the 66th column so | |
1673 | the corresponding XSLT is easier. Also, never wrap between a word and | |
1674 | the comma that follows it. | |
1675 | ||
793fbca5 JD |
1676 | 2007-10-08 Joel E. Denny <jdenny@ces.clemson.edu> |
1677 | ||
1678 | Improve C++ namespace support. Discussed starting at | |
1679 | <http://lists.gnu.org/archive/html/help-bison/2007-09/msg00016.html>. | |
1680 | * data/c++.m4: (b4_namespace_ref, b4_namespace_open, | |
1681 | b4_namespace_close): New macros that interpret the %define variable | |
1682 | "namespace" so its value can contain "::" to indicate nested | |
1683 | namespaces. | |
1684 | * data/glr.cc (b4_namespace): Don't define, and replace all uses with | |
1685 | the above macros. | |
1686 | * data/lalr1.cc (b4_namespace): Likewise. | |
1687 | * data/location.cc (b4_namespace): Likewise. | |
1688 | * doc/bison.texinfo (Decl Summary): Move `%define push_pull' entry | |
1689 | inside a new table in the general %define entry. Document `%define | |
1690 | namespace' there as well. Point the %name-prefix entry to it since it | |
1691 | explains it more completely in the case of C++. | |
1692 | (C++ Bison Interface): Mention `%define namespace' instead of | |
1693 | %name-prefix. | |
1694 | (Table of Symbols): Remove the `%define push_pull' entry. The %define | |
1695 | entry suffices. | |
1696 | * tests/c++.at (Relative namespace references): New test case. | |
1697 | (Absolute namespace references): New test case. | |
1698 | (Syntactically invalid namespace references): New test case. | |
1699 | * tests/input.at (C++ namespace reference errors): New test case. | |
1700 | ||
35b8730d JD |
1701 | 2007-10-08 Joel E. Denny <jdenny@ces.clemson.edu> |
1702 | ||
1703 | Add syncline support and location accessor to internal %define | |
1704 | interfaces. | |
1705 | * data/bison.m4 (b4_percent_define_get_loc): New. | |
1706 | (b4_percent_define_get_syncline): New. | |
1707 | (b4_percent_define_flag_if): Use b4_percent_define_get_loc. | |
1708 | (b4_percent_define_default): Record defining location as line 1 rather | |
1709 | than 0 for the sake of synchronizing #line's, and define | |
1710 | b4_percent_define_syncline(VARIABLE). | |
1711 | (b4_percent_define_check_values): Use b4_percent_define_get_loc. | |
1712 | * src/muscle_tab.c (muscle_syncline_grow): New. | |
1713 | (muscle_code_grow): Use muscle_syncline_grow. | |
1714 | (muscle_percent_define_insert): Use muscle_percent_define_get_loc, and | |
1715 | define b4_percent_define_syncline(VARIABLE). | |
1716 | (muscle_percent_define_get_loc): New. | |
1717 | (muscle_percent_define_get_syncline): New. | |
1718 | (muscle_percent_define_flag_if): Use muscle_percent_define_get_loc, and | |
1719 | remove some unused variables. | |
1720 | (muscle_percent_define_default): Record defining location as line 1 | |
1721 | rather than 0 for the sake of synchronizing #line's, and define | |
1722 | b4_percent_define_syncline(VARIABLE). | |
1723 | (muscle_percent_define_check_values): Use | |
1724 | muscle_percent_define_get_loc. | |
1725 | * src/muscle_tab.h (muscle_percent_define_get_loc): Prototype. | |
1726 | (muscle_percent_define_get_syncline): Prototype. | |
1727 | * tests/skeletons.at (%define Boolean variables: invalid skeleton | |
1728 | defaults): Update output for location change. | |
1729 | (Complaining during macro argument expansion): Extend to test | |
1730 | b4_percent_define_get_loc and b4_percent_define_get_syncline errors. | |
1731 | ||
7dc4a694 JD |
1732 | 2007-10-07 Joel E. Denny <jdenny@ces.clemson.edu> |
1733 | ||
1734 | Fix some error-reporting macro bugs. | |
1735 | * data/bison.m4 (b4_cat): New. | |
1736 | (b4_error, b4_error_at): Use b4_cat to send error directives directly | |
1737 | to stdout so they don't become arguments to other macros. Update | |
1738 | comments and add examples. | |
1739 | (b4_warn, b4_warn_at, b4_complain, b4_complain_at): Update comments and | |
1740 | add examples. | |
1741 | (b4_fatal, b4_fatal_at): Likewise, and invoke m4_exit(1) immediately | |
1742 | after printing the error directive so that M4 doesn't report subsequent | |
1743 | problems that are induced by this problem. | |
1744 | * src/scan-skel.l: Recognize @` digraph outside of directive arguments | |
1745 | instead of just in them. Recognize @\n in both places. Both expand to | |
1746 | the empty string. Needed by b4_cat. | |
1747 | * tests/skeletons.at (Complaining during macro argument expansion): | |
1748 | New test case. | |
1749 | (Fatal errors make M4 exit immediately): New test case. | |
1750 | ||
d4bd2295 JD |
1751 | 2007-10-04 Joel E. Denny <jdenny@ces.clemson.edu> |
1752 | ||
1753 | Implement --print-datadir. | |
1754 | * src/getargs.c (usage): Mention. | |
1755 | (PRINT_DATADIR_OPTION): New anonymous enum member. | |
1756 | (long_options): Add entry for it. | |
1757 | (getargs): Add case for it calling compute_pkgdatadir. | |
1758 | * src/output.c (output_skeleton): Encapsulate data directory | |
1759 | computation from here... | |
1760 | (prepare): ... and from here... | |
1761 | (compute_pkgdatadir): ... into this new function. | |
1762 | * src/output.h (compute_pkgdatadir): Prototype. | |
1763 | ||
34cdeddf JD |
1764 | 2007-09-29 Joel E. Denny <jdenny@ces.clemson.edu> |
1765 | ||
1766 | * src/print-xml.c (escape_bufs): New static global variable | |
1767 | replacing... | |
1768 | (xml_escape_n): ... the static local variable buf here. | |
1769 | (print_xml): Free memory for escape_bufs. | |
1770 | * src/reduce.c (reduce_xml): XML-escape terminal symbol tags. | |
1771 | ||
d782395d JD |
1772 | 2007-09-25 Joel E. Denny <jdenny@ces.clemson.edu> |
1773 | ||
1774 | Replace `%push-parser' and `%push-pull-parser' with | |
1775 | `%define push_pull "push"' and `%define push_pull "both"'. | |
1776 | `%define push_pull "pull"' is the default. | |
1777 | * doc/bison.texinfo (Push Decl, Push Parser Function, | |
1778 | Pull Parser Function, Parser Create Function, Parser Delete Function): | |
1779 | Update declarations. | |
1780 | (Decl Summary, Table of Symbols): Replace %push-parser and | |
1781 | %push-pull-parser entries with a %define push_pull entry. | |
1782 | * data/bison.m4 (b4_percent_define_check_values): New macro. | |
1783 | (b4_pull_if, b4_push_if, b4_use_push_for_pull_if): Move these | |
1784 | definitions... | |
1785 | * data/c.m4 (b4_identification): ... and the YYPUSH and YYPULL cpp | |
1786 | definitions... | |
1787 | * data/push.c: ... to here and compute them from the value of the | |
1788 | %define variable push_pull. | |
1789 | * data/c-skel.m4: Instead of choosing the push.c skeleton for push | |
1790 | parsing requests here... | |
1791 | * data/yacc.c: ... hack this to switch to push.c any time | |
1792 | b4_use_push_pull_flag or the %define variable push_pull is set. This | |
1793 | will go away when we mv push.c yacc.c. | |
1794 | * data/c++-skel.m4, data/glr.c, data/java-skel.m4: Don't report that | |
1795 | push parsing is not supported since unused %define variables are | |
1796 | reported anyway. | |
1797 | * src/getargs.c, src/getargs.h (pull_parser, push_parser): Remove. | |
1798 | * src/muscle_tab.h (muscle_percent_define_check_values): Update | |
1799 | comments for consistency with b4_percent_define_check_values. | |
1800 | * src/output.c (prepare): Don't insert b4_pull_flag and b4_push_flag | |
1801 | muscles. | |
1802 | * src/parse-gram.y (PERCENT_PUSH_PARSER, PERCENT_PUSH_PULL_PARSER): | |
1803 | Remove. | |
1804 | (prologue_declaration): Remove %push-parser and %push-pull-parser | |
1805 | rules. | |
1806 | * src/scan-gram.l (%push-parser, %push-pull-parser): Remove rules. | |
1807 | * tests/calc.at: Update declarations. | |
1808 | * tests/input.at (%define enum variables): New test case. | |
1809 | * tests/push.at (Push Parsing: Memory Leak for Early Deletion): Update | |
1810 | declaration. | |
1811 | (Push Parsing: Multiple impure instances): Update declaration. | |
1812 | (Push Parsing: Unsupported Skeletons): New test case. | |
1813 | * tests/torture.at (Exploding the Stack Size with Alloca): Update | |
1814 | declaration. | |
1815 | (Exploding the Stack Size with Malloc): Update declaration. | |
1816 | ||
3f999f78 WP |
1817 | 2007-09-24 Wojciech Polak <polak@gnu.org> |
1818 | ||
1819 | Add XSLT transformations. | |
1820 | ||
1821 | * data/xslt/xml2dot.xsl: Transform XML into DOT. | |
1822 | * data/xslt/xml2text.xsl: Transform XML into plain text. | |
1823 | * data/xslt/xml2xhtml.xsl: Transform XML into XHTML. | |
1824 | * data/Makefile.am (xsltdir): New variable. | |
1825 | (dist_xslt_DATA): Add xslt/*.xsl files. | |
1826 | ||
a4f75309 PE |
1827 | 2007-09-23 Paul Eggert <eggert@cs.ucla.edu> |
1828 | ||
1829 | * src/conflicts.c (log_resolution): Fix indenting bugs I introduced. | |
1830 | Problem reported by Wojciech Polak. | |
1831 | * src/print-xml.c (xml_puts): Work even if LEVEL exceeds INT_MAX/2. | |
1832 | (xml_printf): Undo change I made on 21 September; that is, | |
1833 | indent 2 spaces, not 1. | |
1834 | ||
ad5feac4 JD |
1835 | 2007-09-23 Joel E. Denny <jdenny@ces.clemson.edu> |
1836 | ||
1837 | Pacify ./configure --enable-gcc-warnings. | |
1838 | * src/print-xml.c, src/print-xml.h (xml_puts): Make third argument | |
1839 | `char const *' instead of `char *'. | |
1840 | * src/state.c (state_rule_lookahead_tokens_print_xml): Remove unused | |
1841 | local variable `sep'. | |
1842 | ||
41d7a5f2 PE |
1843 | 2007-09-21 Paul Eggert <eggert@cs.ucla.edu> |
1844 | ||
1845 | * src/gram.c (rule_rhs_print_xml): Now static, since it isn't used | |
1846 | elsewhere. | |
1847 | * src/print-xml.c: Prefer "const" after types; that's more consistent. | |
1848 | (xml_printf): Indent just 1 space for level. | |
1849 | (e_char, xlate_char): Remove. | |
1850 | (xml_escape_string): Rewrite to avoid undefined behavior (used | |
1851 | storage that was freed from the stack). | |
1852 | (xml_escape_n): Don't bother checking for subscript error. | |
1853 | ||
3f999f78 WP |
1854 | 2007-09-21 Wojciech Polak <polak@gnu.org> |
1855 | ||
1856 | Add Bison XML Automaton Report. | |
41d7a5f2 PE |
1857 | |
1858 | Add support for an -x option to generate an XML report. | |
1859 | It is not documented yet. | |
1860 | * src/print-xml.c: New file. | |
1861 | * src/print-xml.h: Likewise. | |
1862 | * lib/timevar.def (TV_XML): New var. | |
1863 | * src/Makefile.am (bison_SOURCES): Add print-xml.c, print-xml.h. | |
1864 | * src/conflicts.c: Include print-xml.h. | |
1865 | (solved_conflicts_xml_obstack): New var. | |
1866 | (log_resolution, conflicts_solve, conflicts_free): | |
1867 | Add support for XML report. | |
1868 | (conflicts_output_val): New function. | |
1869 | * src/conflicts.h (conflicts_output_val): New decl. | |
1870 | * src/files.c (spec_xml_file): New var. | |
1871 | (compute_output_file_names, output_file_names_free): Add XML support. | |
1872 | * src/files.h (spec_xml_file): New decl. | |
1873 | * src/getargs.c (xml_flag): New var. | |
1874 | (usage, short_options, long_options, getargs): Add XML support. | |
1875 | * src/getargs.h (xml_flag): New decl. | |
1876 | * src/gram.c: Include print-xml.h. | |
1877 | (rule_lhs_print_xml, rule_rhs_print_xml): | |
1878 | (grammar_rules_partial_print_xml, grammar_rules_print_xml): | |
1879 | New functions. | |
1880 | * src/gram.h: Declare external ones. | |
1881 | * src/main.c: Include print-xml.h. | |
1882 | (main): Add XML support. | |
1883 | * src/reduce.c: Include print-xml.h. | |
1884 | (reduce_xml): New function. | |
1885 | * src/reduce.h: Declare it. | |
1886 | * src/state.c: Include print-xml.h. | |
1887 | (state_new): Add XML support. | |
1888 | (state_rule_lookahead_tokens_print_xml): New function. | |
1889 | * src/state.h: Declare it. | |
1890 | (struct state): New member solved_conflicts_xml. | |
1891 | * src/symtab.c (symbol_class_get_string): New function. | |
1892 | * src/symtab.h: Declare it. | |
1893 | ||
6d8e724d PE |
1894 | 2007-09-21 Paul Eggert <eggert@cs.ucla.edu> |
1895 | ||
1896 | * GNUmakefile: Switch to coreutils's version. | |
1897 | * bootstrap: Likewise. | |
1898 | * Makefile.cfg: Adjust to new GNUmakefile. | |
1899 | * README-hacking: Likewise. | |
1900 | ||
1901 | Import from gnulib: | |
1902 | ||
1903 | 2006-08-18 Paul Eggert <eggert@cs.ucla.edu> | |
1904 | Bruno Haible <bruno@clisp.org> | |
1905 | ||
1906 | * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists | |
1907 | and is a script that invokes bison. Tighten the code. Add comments. | |
1908 | ||
922bdd7f JD |
1909 | 2007-08-28 Joel E. Denny <jdenny@ces.clemson.edu> |
1910 | ||
1911 | Spell "boolean" as "Boolean". Reported by Akim Demaille. | |
1912 | * data/bison.m4 (b4_percent_define_flag_if): Fix complaint. | |
1913 | * doc/bison.texinfo (Decl Summary): Fix. | |
1914 | * src/muscle_tab.c (muscle_percent_define_flag_if): Fix complaint. | |
1915 | * tests/input.at (Boolean %define variables): Update output. | |
1916 | * tests/skeletons.at (%define boolean variables: invalid skeleton | |
1917 | defaults): Rename to... | |
1918 | (%define Boolean variables: invalid skeleton defaults): ... this and | |
1919 | update output. | |
1920 | ||
1b17b01d JD |
1921 | 2007-08-17 Joel E. Denny <jdenny@ces.clemson.edu> |
1922 | ||
1923 | In impure push mode, don't allow more than one yypstate to be allocated | |
1924 | since multiple impure parsers would corrupt yynerrs. | |
1925 | * data/push.c (yypstate_allocated): New static global variable | |
1926 | initialized to 0. | |
1927 | (yypull_parse): If yypstate_new returns 0, don't report it as memory | |
1928 | exhaustion if yypstate_allocated is 1, but still return 2. | |
1929 | (yypstate_new): Invoke yyerror and return 0 if yypstate_allocated is | |
1930 | already 1. Otherwise, set it to 1. | |
1931 | (yypstate_delete): Set it to 0. | |
1932 | * tests/push.at (Push Parsing: Multiple impure instances): New test | |
1933 | case. | |
1934 | ||
9987d1b3 JD |
1935 | 2007-08-17 Bob Rossi <bob@brasko.net> |
1936 | ||
1937 | * doc/bison.texinfo (Push Decl): Document the push parser. | |
1938 | (Table of Symbols): Ditto. | |
1939 | (Pure Decl): Ditto. | |
1940 | (Decl Summary): Ditto. | |
1941 | (Multiple Parsers, Push Parser Function, Pull Parser Function, | |
1942 | Parser Create Function, Parser Delete Function): | |
1943 | Add new push parser symbols. | |
1944 | (Table of Symbols): Document push-parser, push-pull-parser, | |
1945 | yypush_parse, yypull_parse, yypstate_new and yypstate_delete. | |
1946 | ||
f16b0819 PE |
1947 | 2007-08-15 Paul Eggert <eggert@cs.ucla.edu> |
1948 | ||
1949 | Update to GPLv3. | |
1950 | * doc/gpl-3.0.texi: New file. | |
1951 | * doc/gpl.texi: Remove. | |
1952 | * COPYING, GNUmakefile, HACKING, Makefile.am, Makefile.cfg: | |
1953 | * Makefile.maint, NEWS, PACKAGING, README, README-alpha: | |
1954 | * README-hacking, TODO, bootstrap, bootstrap.conf: | |
1955 | * configure.ac, data/Makefile.am, data/README, data/bison.m4: | |
1956 | * data/c++-skel.m4, data/c++.m4, data/c-skel.m4, data/c.m4: | |
1957 | * data/glr.c, data/glr.cc, data/java-skel.m4, data/java.m4: | |
1958 | * data/lalr1.cc, data/lalr1.java, data/location.cc: | |
1959 | * data/push.c, data/yacc.c, data/m4sugar/m4sugar.m4: | |
1960 | * djgpp/Makefile.maint, djgpp/README.in, djgpp/config.bat: | |
1961 | * djgpp/config.sed, djgpp/config.site, djgpp/config_h.sed: | |
1962 | * djgpp/djunpack.bat, djgpp/subpipe.c, djgpp/subpipe.h: | |
1963 | * djgpp/testsuite.sed, doc/Makefile.am, doc/bison.texinfo: | |
1964 | * doc/fdl.texi, doc/refcard.tex, etc/Makefile.am, etc/README: | |
1965 | * etc/bench.pl.in, examples/Makefile.am, examples/extexi: | |
1966 | * examples/calc++/Makefile.am, lib/Makefile.am, lib/abitset.c: | |
1967 | * lib/abitset.h, lib/bbitset.h, lib/bitset.c, lib/bitset.h: | |
1968 | * lib/bitset_stats.c, lib/bitset_stats.h, lib/bitsetv-print.c: | |
1969 | * lib/bitsetv-print.h, lib/bitsetv.c, lib/bitsetv.h: | |
1970 | * lib/ebitset.c, lib/ebitset.h, lib/get-errno.c: | |
1971 | * lib/get-errno.h, lib/lbitset.c, lib/lbitset.h: | |
1972 | * lib/libiberty.h, lib/main.c, lib/subpipe.c, lib/subpipe.h: | |
1973 | * lib/timevar.c, lib/timevar.def, lib/timevar.h: | |
1974 | * lib/vbitset.c, lib/vbitset.h, lib/yyerror.c: | |
1975 | * m4/c-working.m4, m4/cxx.m4, m4/m4.m4, m4/subpipe.m4: | |
1976 | * m4/timevar.m4, src/LR0.c, src/LR0.h, src/Makefile.am: | |
1977 | * src/assoc.c, src/assoc.h, src/closure.c, src/closure.h: | |
1978 | * src/complain.c, src/complain.h, src/conflicts.c: | |
1979 | * src/conflicts.h, src/derives.c, src/derives.h, src/files.c: | |
1980 | * src/files.h, src/flex-scanner.h, src/getargs.c: | |
1981 | * src/getargs.h, src/gram.c, src/gram.h, src/graphviz.c: | |
1982 | * src/lalr.c, src/lalr.h, src/location.c, src/location.h: | |
1983 | * src/main.c, src/muscle_tab.c, src/muscle_tab.h: | |
1984 | * src/nullable.c, src/nullable.h, src/output.c, src/output.h: | |
1985 | * src/parse-gram.c, src/parse-gram.h, src/parse-gram.y: | |
1986 | * src/print.c, src/print.h, src/print_graph.c: | |
1987 | * src/print_graph.h, src/reader.c, src/reader.h, src/reduce.c: | |
1988 | * src/reduce.h, src/relation.c, src/relation.h: | |
1989 | * src/revision.h, src/scan-code.h, src/scan-code.l: | |
1990 | * src/scan-gram.h, src/scan-gram.l, src/scan-skel.h: | |
1991 | * src/scan-skel.l, src/state.c, src/state.h, src/symlist.c: | |
1992 | * src/symlist.h, src/symtab.c, src/symtab.h, src/system.h: | |
1993 | * src/tables.c, src/tables.h, src/uniqstr.c, src/uniqstr.h: | |
1994 | * tests/Makefile.am, tests/actions.at, tests/c++.at: | |
1995 | * tests/calc.at, tests/conflicts.at, tests/cxx-type.at: | |
1996 | * tests/existing.at, tests/glr-regression.at: | |
1997 | * tests/headers.at, tests/input.at, tests/java.at: | |
1998 | * tests/local.at, tests/output.at, tests/push.at: | |
1999 | * tests/reduce.at, tests/regression.at, tests/sets.at: | |
2000 | * tests/skeletons.at, tests/synclines.at, tests/testsuite.at: | |
2001 | * tests/torture.at: | |
2002 | Update to GPLv3. | |
2003 | ||
728c4be2 JD |
2004 | 2007-08-11 Joel E. Denny <jdenny@ces.clemson.edu> |
2005 | ||
2006 | Get rid of broken %no-parser, -n, and --no-parser implementation and | |
2007 | documentation. | |
2008 | * TODO: Don't mention them. | |
2009 | * doc/bison.1: Likewise. | |
2010 | * doc/bison.texinfo (Decl Summary): Likewise. | |
2011 | (Bison Options): Likewise. | |
2012 | (Option Cross Key): Likewise. | |
2013 | * src/getargs.c (no_parser_flag): Remove global variable. | |
2014 | (usage): Don't print description of -n and --no-parser. | |
2015 | (long_options): Remove --no-parser entry here. | |
2016 | (getargs): Remove -n case in the switch here. | |
2017 | * src/getargs.h (no_parser_flag): Remove extern. | |
2018 | * tests/regression.at (Web2c Actions): Remove comment that mentions | |
2019 | --no-parser. | |
2020 | ||
5d31a216 JD |
2021 | 2007-08-11 Joel E. Denny <jdenny@ces.clemson.edu> |
2022 | ||
2023 | * tests/push.at (Push Parsing: Memory Leak for Early Deletion): Do not | |
2024 | name user variables starting with `yy'. Just pass NULL instead of a | |
2025 | dummy local &yylval to yypush_parse. | |
2026 | * tests/torture.at (AT_DATA_STACK_TORTURE): Do not name user variables | |
2027 | starting with `yy'. | |
2028 | ||
a2ea208d JD |
2029 | 2007-08-03 Joel E. Denny <jdenny@ces.clemson.edu> |
2030 | ||
2031 | * data/yacc.c (yyexhaustedlab): Define it when YYERROR_VERBOSE is | |
2032 | true since it's then always used regardless of whether yyoverflow is | |
2033 | defined. Reported by Christian Burger at | |
2034 | <http://lists.gnu.org/archive/html/bug-bison/2007-07/msg00031.html>. | |
2035 | * THANKS: Add Christian Burger. | |
2036 | ||
91661ebb JD |
2037 | * ChangeLog: For changes in doc/bison.texinfo, consistently reference |
2038 | node names: say "Decl Summary" not "Bison Declaration Summary". | |
2039 | ||
cbd50549 JD |
2040 | 2007-07-28 Joel E. Denny <jdenny@ces.clemson.edu> |
2041 | ||
2042 | * src/muscle_tab.c (muscle_percent_define_flag_if): In order to | |
2043 | determine whether this function has already complained about an invalid | |
2044 | value for a %define boolean variable, don't check whether Bison has | |
2045 | ever examined the value. As written, the check was a tautology. | |
2046 | Instead, record and check for this complaint using a separate muscle. | |
2047 | ||
eb1b0740 JD |
2048 | 2007-07-27 Joel E. Denny <jdenny@ces.clemson.edu> |
2049 | ||
2050 | Fix push parsing memory leak reported by Brandon Lucia at | |
2051 | <http://lists.gnu.org/archive/html/bug-bison/2007-07/msg00032.html>. | |
2052 | * THANKS: Add Brandon Lucia. | |
2053 | * data/push.c (yypstate_delete): Free the stack if it was reallocated | |
2054 | but the parse never completed and thus freed it. | |
2055 | * tests/Makefile.am (TESTSUITE_AT): Add push.at. | |
2056 | * tests/testsuite.at: Include push.at. | |
2057 | * test/push.at: New. | |
2058 | (Push Parsing: Memory Leak for Early Deletion): New test case. | |
2059 | ||
9d774aff JD |
2060 | 2007-07-17 Joel E. Denny <jdenny@ces.clemson.edu> |
2061 | ||
2062 | Improve handling of multiple S/R conflicts in the same state and of S/R | |
2063 | conflicts involving multiple reductions. | |
2064 | * src/conflicts.c (resolve_sr_conflict): Don't assign the error action | |
2065 | set for a state here or Bison will abort if it is reassigned on a | |
2066 | later conflicted reduction in the same state. | |
2067 | Similarly, don't finalize and assign the solved conflicts report here | |
2068 | or it will be lost if it is reassigned on a later conflicted reduction | |
2069 | in the same state. | |
2070 | (set_conflicts): Instead, assign them both here after all S/R conflicts | |
2071 | in the state have been fully examined. | |
2072 | * src/print.c (shift_set): Rename to... | |
2073 | (no_reduce_set): ... this. | |
2074 | (print_reductions): Update for rename, and add %nonassoc error action | |
2075 | tokens to no_reduce_set so that, when printing the first remaining | |
2076 | reduction on an error action token, the reduction is enclosed in | |
2077 | brackets. | |
2078 | (print_results): Update for rename. | |
2079 | * tests/conflicts.at (Solved conflicts report for multiple reductions | |
2080 | in a state): New test case. | |
2081 | (%nonassoc error actions for multiple reductions in a state): New test | |
2082 | case. | |
2083 | ||
2084 | * src/main.c (main): Don't depend on C99 features. | |
2085 | ||
10159d2a JD |
2086 | 2007-07-16 Joel E. Denny <jdenny@ces.clemson.edu> |
2087 | ||
2088 | * build-aux/.cvsignore: Add compile. | |
b541ffdf JD |
2089 | * lib/.cvsignore: Add charset.alias, ref-add.sed, ref-del.sed, and |
2090 | uniwidth. | |
10159d2a | 2091 | |
953b3935 JD |
2092 | 2007-07-10 Joel E. Denny <jdenny@ces.clemson.edu> |
2093 | ||
2094 | * bootstrap (slurp): Create target directories that don't exist. | |
2095 | Specifically, we need lib/uniwidth/ because of recent Gnulib changes. | |
2096 | ||
6ce2d93a JD |
2097 | 2007-07-09 Joel E. Denny <jdenny@ces.clemson.edu> |
2098 | ||
2099 | * LR0.c (new_itemsets): Fix wording in comments: say item index rather | |
2100 | than item number. | |
2101 | * closure.c (closure): Likewise. | |
2102 | * state.h (reductions): Comment sorting of rules. | |
2103 | (state): Comment sorting of items. | |
2104 | ||
ce3448d5 JD |
2105 | 2007-07-02 Joel E. Denny <jdenny@ces.clemson.edu> |
2106 | ||
2107 | Fix C++ test cases after recent Gnulib changes. Discussed starting at | |
2108 | <http://lists.gnu.org/archive/html/bug-bison/2007-07/msg00000.html>. | |
2109 | * examples/calc++/Makefile.am (DEFAULT_INCLUDES): Override Automake's | |
2110 | definition in order to avoid Gnulib headers since we don't use config.h | |
2111 | here. | |
2112 | * tests/output.at (AT_CHECK_OUTPUT_FILE_NAME): Use AT_DATA_GRAMMAR | |
2113 | rather than AT_DATA so that config.h is included. | |
2114 | ||
8a86eef0 JD |
2115 | 2007-07-01 Joel E. Denny <jdenny@ces.clemson.edu> |
2116 | ||
2117 | * data/glr.c (yy_yypstack, yypstates, yypdumpstack): Use YYFPRINTF | |
2118 | instead of fprintf. Guard these functions with #if YYDEBUG instead of | |
2119 | #ifdef YYDEBUG for consistency with all other uses of YYDEBUG in Bison | |
2120 | and so that YYFPRINTF is guaranteed to be defined here. | |
2121 | ||
b1a81613 JD |
2122 | 2007-05-29 Joel E. Denny <jdenny@ces.clemson.edu> |
2123 | ||
2124 | * src/muscle_tab.c (muscle_percent_define_invalid_value): Replace | |
2125 | with... | |
2126 | (muscle_percent_define_check_values): ... this more helpful function. | |
2127 | Again, it's not used yet, but it will be. | |
2128 | * src/muscle_tab.h: Likewise. | |
2129 | ||
71b61d4d JD |
2130 | Improve some comments in parser table construction. |
2131 | * src/LR0.c (new_itemsets): Explain sorting of itemset and kernel_base. | |
2132 | (generate_states): Don't mention ruleset, which is internal to closure. | |
2133 | * src/closure.c (closure): Explain sorting of core and itemset, which | |
2134 | is required for this function to behave correctly. | |
2135 | * src/closure.h (closure): Mention sorting. | |
2136 | ||
2a6b783d JD |
2137 | 2007-05-28 Joel E. Denny <jdenny@ces.clemson.edu> |
2138 | ||
2139 | * src/lalr.c (state_lookahead_tokens_count): For code readability, | |
2140 | move the check for disabled transitions to an aver since conflict | |
2141 | resolution hasn't happened yet. | |
2142 | ||
2143 | * src/lalr.c (state_lookahead_tokens_count): Remove the check that | |
2144 | labels a state as inconsistent just because it has error transitions. | |
2145 | The original form of this check appeared in revision 1.1 of lalr.c, | |
2146 | which was committed on 1991-12-21. Now (at least), changing the | |
2147 | consistency label on such a state appears to have no useful effect in | |
2148 | any of the places it is examined, which I enumerate below. The key | |
2149 | point to understanding each item in this enumeration is that a state | |
2150 | with an error transition is labelled consistent in the first place only | |
2151 | if it has no rules, so the check cannot matter for states that have | |
2152 | rules. (1) Labelling a state as inconsistent will cause set_conflicts | |
2153 | to try to identify its conflicts, and a state must have *rules* to have | |
2154 | conflicts. (2) Labelling a state as inconsistent will affect how | |
2155 | action_row sets the default *rule* for the state. (3) Labelling a | |
2156 | state as inconsistent will cause build_relations to add lookback edges | |
2157 | to *rules* in that state. | |
2158 | * src/state.h (struct state): Word the comment for member consistent | |
2159 | more carefully. | |
2160 | ||
14462c2b JD |
2161 | 2007-05-27 Joel E. Denny <jdenny@ces.clemson.edu> |
2162 | ||
2163 | Don't depend on C99 features. | |
2164 | * src/conflicts.c (conflicts_update_state_numbers): Fix for-loop. | |
2165 | * src/lalr.c (lalr_update_state_numbers): Fix for-loop. | |
2166 | * src/reader.c (check_and_convert_grammar): Fix for-loop. | |
2167 | * src/state.c (state_mark_reachable_states): Fix for-loop. | |
2168 | (state_remove_unreachable_states): Fix for-loop. | |
2169 | ||
2170 | Don't widen struct state with member reachable just to temporarily | |
2171 | record reachability. Instead, use a local bitset. | |
2172 | * src/state.h (struct state): Remove member. | |
2173 | * src/state.c (state_new): Don't initialize it. | |
2174 | (state_mark_reachable_states): Rename to... | |
2175 | (state_record_reachable_states): ... this, and use bitset. | |
2176 | (state_remove_unreachable_states): Use bitset. | |
2177 | ||
5a43d418 JD |
2178 | 2007-05-26 Joel E. Denny <jdenny@ces.clemson.edu> |
2179 | ||
2180 | * src/Makefile.am (yacc): Quote target action commands properly so | |
2181 | that the yacc script isn't corrupt. Reported by Hans Aberg at | |
2182 | <http://lists.gnu.org/archive/html/bug-bison/2007-05/msg00003.html>. | |
2183 | ||
0c650a20 JD |
2184 | * data/glr.c (yylval): As in yacc.c, don't extern in the header for |
2185 | the case of pure parsers. Reported by Frans Englich at | |
2186 | <http://lists.gnu.org/archive/html/help-bison/2007-05/msg00018.html>. | |
2187 | * THANKS: Add Frans Englich. | |
2188 | ||
61fee93e JD |
2189 | * NEWS (2.3a+): In the %code entry, reference section `Bison |
2190 | Declaration Summary' from the manual now since the %code summary has | |
2191 | moved there. | |
2192 | * doc/bison.texinfo (Prologue Alternatives): Mention that directives | |
2193 | in the rules section must be terminated by semicolons. | |
2194 | ||
f124d423 JD |
2195 | 2007-05-20 Joel E. Denny <jdenny@ces.clemson.edu> |
2196 | ||
2197 | Extend the front-end API for %define variables to more completely | |
2198 | mirror the back-end. This will be useful in the future. | |
2199 | * data/bison.m4 (b4_percent_define_get, b4_percent_define_ifdef): | |
2200 | Update comments to mention the new front-end counterparts of these | |
2201 | macros. | |
2202 | * src/muscle_tab.c (MUSCLE_COMMON_DECODE): New macro with common code | |
2203 | for muscle_string_decode and muscle_location_decode. | |
2204 | (muscle_string_decode): New static function. | |
2205 | (muscle_location_decode): Use MUSCLE_COMMON_DECODE. | |
2206 | (muscle_percent_define_get, muscle_percent_define_ifdef): New | |
2207 | functions. | |
2208 | (muscle_percent_define_flag_if): Use muscle_percent_define_ifdef and | |
2209 | muscle_percent_define_get to mimic the b4_percent_define_flag_if | |
2210 | implementation more closely. | |
2211 | (muscle_percent_define_invalid_value): New function. | |
2212 | * src/muscle_tab.h (muscle_percent_define_get, | |
2213 | muscle_percent_define_ifdef, muscle_percent_define_invalid_value): | |
2214 | Prototype. | |
2215 | ||
75ad86ee JD |
2216 | 2007-05-07 Joel E. Denny <jdenny@ces.clemson.edu> |
2217 | ||
2218 | * NEWS (2.3a+): Mention yesterday's state-removal change. | |
2219 | (2.3a): Remove the %language entry, which was added after 2.3a. | |
2220 | * src/LR0.c, src/closure.c, src/closure.h, src/conflicts.c, | |
2221 | src/conflicts.h, src/lalr.c, src/lalr.h, src/print.c, | |
2222 | src/print_graph.c, src/state.c, src/state.h, tests/conflicts.at, | |
2223 | tests/existing.at: Update copyright date. | |
2224 | ||
5967f0cf JD |
2225 | 2007-05-06 Joel E. Denny <jdenny@ces.clemson.edu> |
2226 | ||
2227 | If conflict resolution makes states unreachable, remove those states, | |
2228 | report rules that are then unused, and don't report conflicts in those | |
2229 | states. | |
2230 | * src/conflicts.c, src/conflicts.h (conflicts_update_state_numbers): | |
2231 | New global function. | |
2232 | * src/lalr.c, src/lalr.h (lalr_update_state_numbers): New global | |
2233 | function. | |
2234 | * src/main.c (main): After conflict resolution, remove the unreachable | |
2235 | states and update all data structures that reference states by number. | |
2236 | * src/state.c (state_new): Initialize each state's reachable member to | |
2237 | false. | |
2238 | (state_mark_reachable_states): New static function. | |
2239 | (state_remove_unreachable_states): New global function. | |
2240 | * src/state.h (struct state): Add member bool reachable. | |
2241 | (state_remove_unreachable_states): Prototype. | |
2242 | * tests/conflicts.at (Unreachable States After Conflict Resolution): | |
2243 | New test case. | |
2244 | * tests/existing.at (GNU pic Grammar): Update test case output now that | |
2245 | an unused rule is discovered. | |
2246 | ||
b09f4f48 JD |
2247 | 2007-05-06 Joel E. Denny <jdenny@ces.clemson.edu> |
2248 | ||
2249 | Minor code cleanup in parser table construction. | |
2250 | * src/LR0.c (new_itemsets): Use item_number_is_symbol_number. | |
2251 | (new_itemsets, save_reductions): Update for rename to nitemset. | |
2252 | * src/closure.c (nritemset): Rename to... | |
2253 | (nitemset): ... this since the "r" appears to meaningless and isn't | |
2254 | used in the comments. | |
2255 | (closure): Update for rename. | |
2256 | * src/closure.h (nritemset): Update extern to... | |
2257 | (nitemset): ... this. | |
2258 | * src/lalr.c (LA): Fix a typo in comments. | |
2259 | * src/print.c (print_core): Update for rename to nitemset. | |
2260 | * src/print_graph.c (print_graph): Likewise. | |
2261 | * src/state.h: Fix some typos in header comments. | |
2262 | ||
bbb44d83 PE |
2263 | 2007-04-04 Paul Eggert <eggert@cs.ucla.edu> |
2264 | ||
9b33de72 PE |
2265 | * THANKS: Use ASCII for Sebastien Fricker's name. Bison source |
2266 | still sticks to ASCII. Sorry! | |
2267 | ||
bbb44d83 PE |
2268 | * README-hacking: New file, taken mostly from coreutils, with changes |
2269 | for Bison. Contains much of the contents of: | |
2270 | * README-cvs: Remove. | |
2271 | * bootstrap: Sync from gnulib. | |
2272 | * build-aux/.cvsignore: Remove *.t, mkinstalldirs. | |
2273 | * lib/.cvsignore: Add wchar.h, wctype.h. Remove exit.h. | |
2274 | ||
29553547 JD |
2275 | 2007-03-10 Joel E. Denny <jdenny@ces.clemson.edu> |
2276 | ||
2277 | * doc/bison.texinfo (Destructor Decl): Fix typo reported by Sebastian | |
2278 | Setzer. | |
2279 | (Java Differences): Fix some typos. | |
2280 | * THANKS: Add Sebastian Setzer. | |
2281 | ||
01b477c6 PB |
2282 | 2007-03-07 Paolo Bonzini <bonzini@gnu.org> |
2283 | ||
730739e4 AD |
2284 | * data/java.m4 (b4_single_class_if): Remove. |
2285 | (b4_abstract_if): Look at "%define abstract". | |
2286 | (b4_lexer_if): New. | |
2287 | (b4_union_name): Rename... | |
2288 | (b4_yystype): ... to this. Map to "%define stype". | |
2289 | (b4_rhs_value, b4_parse_param_decl, b4_lex_param_decl, | |
2290 | b4_maybe_throws): Fix quoting. | |
2291 | (b4_lex_param_call): Move below to keep b4_*_param_decl close. | |
2292 | * data/lalr1.java (Lexer interface): Always define. | |
2293 | (Lexer interface within parser class): Remove. | |
2294 | (YYLexer class): New, used when "%code lexer" is present. | |
2295 | (constructor): When "%code lexer" is used, pass %lex-param | |
2296 | to the lexer constructor. | |
2297 | (yylex, yyparse): Remove %lex-param from method invocations | |
2298 | (YYStack, yyaction, yyparse): Rename b4_union_name to b4_yystype. | |
2299 | ||
2300 | * doc/bison.texinfo (Java Bison Interface): Mention "%define | |
2301 | abstract". Rename "%define union_name" to "%define stype". | |
2302 | Rename method names according to previous patch. | |
2303 | (Java Scanner Interface): Describe "%code lexer" instead of | |
2304 | "%pure-parser" and "%define single_class". | |
2305 | (Java Differences): Mention "%code lexer". | |
2306 | ||
2307 | * tests/java.at (_AT_DATA_JAVA_CALC_Y): Remove final argument. | |
2308 | Include scanner here, using macros from tests/local.at. | |
2309 | (AT_DATA_CALC_Y): Remove final argument. | |
2310 | (_AT_CHECK_JAVA_CALC): Likewise. | |
2311 | (AT_CHECK_JAVA_CALC): Likewise. Test all four combinations | |
2312 | of %locations and %error-verbose. | |
2313 | (main): Test with and without %lex-param. | |
2314 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Push AT_LEXPARAM_IF. | |
2315 | (AT_BISON_OPTION_POPDEFS): Pop it. | |
01b477c6 | 2316 | |
122bea3a JMG |
2317 | 2007-03-07 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
2318 | ||
2319 | DJGPP spefic issue. Inhibit the use of disallowed characters for | |
2320 | file name genertion on Win98, WinXP, etc. These are |<>":?*\ | |
2321 | and concern testsuite case 46. | |
2322 | * Makefile.am: djgpp/testsuite.sed added to EXTRA_DIST | |
2323 | * djgpp/testsuite.sed: Inhibit the use of disallowed characters. | |
2324 | * djgpp/config.bat: Inhibit the use of disallowed characters. | |
2325 | ||
9611cfa2 JD |
2326 | 2007-03-02 Joel E. Denny <jdenny@ces.clemson.edu> |
2327 | ||
2328 | Miscellaneous %define and %code cleanup. | |
2329 | * data/bison.m4 (b4_percent_define_flag_if): Correct comments on how | |
2330 | values are interpreted. | |
2331 | * doc/bison.texinfo (Decl Summary): Clean up and extend %define | |
2332 | documentation a little more. | |
2333 | * src/muscle_tab.c (MUSCLE_USER_NAME_CONVERT, | |
2334 | muscle_percent_define_insert, muscle_percent_code_grow): New | |
2335 | functions/macros. | |
2336 | * src/muscle_tab.h (muscle_percent_define_insert, | |
2337 | muscle_percent_code_grow): Prototype. | |
2338 | * src/parse-gram.y (prologue_declaration): Use | |
2339 | muscle_percent_define_insert and muscle_percent_code_grow when parsing | |
2340 | %define and %code directives. | |
2341 | ||
2342 | Make it easy to share %define boolean variables between the front-end | |
2343 | and back-end. Though not used yet, this will be useful in the future. | |
2344 | * data/bison.m4 (b4_check_user_names): Rewrite comments to talk about | |
2345 | Bison uses of names rather than just skeleton uses of names. | |
2346 | (b4_percent_define_get, b4_percent_define_ifdef): Rename | |
2347 | b4_percent_define_skeleton_variables(VARIABLE) to | |
2348 | b4_percent_define_bison_variables(VARIABLE). | |
2349 | (b4_percent_code_get, b4_percent_code_ifdef): Rename | |
2350 | b4_percent_code_skeleton_qualifiers(QUALIFIER) to | |
2351 | b4_percent_code_bison_qualifiers(QUALIFIER). | |
2352 | (b4_check_user_names_wrap): Update for renames. | |
2353 | * src/muscle_tab.c, src/muscle_tab.h (muscle_percent_define_flag_if, | |
2354 | muscle_percent_define_default): New functions mimicking | |
2355 | b4_percent_define_flag_if and b4_percent_define_default. | |
2356 | ||
2357 | For %define variables, report locations for invalid values and | |
bbb44d83 | 2358 | redefinitions. |
9611cfa2 JD |
2359 | * data/bison.m4 (b4_percent_define_flag_if): Read |
2360 | b4_percent_define_loc(VARIABLE) to report the location of an invalid | |
2361 | value for VARIABLE. | |
2362 | (b4_percent_define_default): Save a special location in | |
2363 | b4_percent_define_loc(VARIABLE) in case the default value for VARIABLE | |
2364 | must later be reported as invalid. | |
2365 | * src/muscle_tab.c (muscle_location_grow, muscle_location_decode): New | |
2366 | functions. | |
2367 | (muscle_percent_define_insert): Record the location of VARIABLE in | |
2368 | muscle percent_define_loc(VARIABLE), and use it to report the previous | |
2369 | location for a redefinition. | |
2370 | (muscle_percent_define_flag_if): Update like b4_percent_define_flag_if. | |
2371 | (muscle_percent_define_default): Update like b4_percent_define_default. | |
2372 | (muscle_grow_user_name_list): Rename to... | |
2373 | (muscle_user_name_list_grow): ... this for consistency and use | |
2374 | muscle_location_grow. | |
2375 | * src/muscle_tab.h (muscle_location_grow): Prototype. | |
2376 | * tests/input.at (%define errors): Update expected output. | |
2377 | * tests/skeletons.at (%define boolean variables: invalid skeleton | |
2378 | defaults): New test case. | |
2379 | ||
0bf92491 JD |
2380 | 2007-02-28 Joel E. Denny <jdenny@ces.clemson.edu> |
2381 | ||
2382 | * src/print.c (lookahead_set, state_default_rule): Remove. | |
2383 | (print_reductions): Replace state_default_rule invocation with | |
2384 | equivalent use of yydefact, which was computed in token_actions in | |
2385 | tables.c. | |
2386 | (print_results): Don't allocate lookahead_set. | |
2387 | ||
d3b12988 PB |
2388 | 2007-02-27 Paolo Bonzini <bonzini@gnu.org> |
2389 | ||
2390 | * data/lalr1.java: Prefix all private members with yy. | |
2391 | ||
f57a7536 JD |
2392 | 2007-02-24 Joel E. Denny <jdenny@ces.clemson.edu> |
2393 | ||
2394 | Use YYFPRINTF instead of fprintf where appropriate. Reported by | |
9b33de72 | 2395 | Sebastien Fricker at |
f57a7536 | 2396 | <http://lists.gnu.org/archive/html/bug-bison/2007-02/msg00035.html>. |
9b33de72 | 2397 | * THANKS: Add Sebastien Fricker. |
f57a7536 JD |
2398 | * data/glr.c, data/push.c, data/yacc.c (yy_reduce_print): Implement. |
2399 | * doc/bison.texinfo (Tracing): Make it clearer that YYFPRINTF must | |
2400 | accept a variable number of arguments. | |
2401 | ||
6404a5bf JD |
2402 | 2007-02-19 Joel E. Denny <jdenny@ces.clemson.edu> |
2403 | ||
2404 | * bootstrap: Remove occurrences of .#bootmp from lib/Makefile. | |
2405 | ||
e4e09639 JMG |
2406 | 2007-02-13 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
2407 | ||
2408 | * djgpp/config.bat: Adjustments concerning the use of autoconf 2.61. | |
2409 | * djgpp/config.sed: Adjustments concerning the use of autoconf 2.61. | |
2410 | * djgpp/config.site: Adjustments concerning the use of autoconf 2.61. | |
2411 | ||
d7e0a1a7 PE |
2412 | 2007-02-11 Paul Eggert <eggert@cs.ucla.edu> |
2413 | ||
2414 | Undo my 2007-02-07 change, switching back to the c-strcase module | |
2415 | introduced in the 2007-02-03 change. Bruno Haible reported that | |
2416 | the 2007-02-07 change would be dangerous in Turkish if we add a | |
2417 | language whose name contains "i", since "i" is not lowercase "I" | |
2418 | in Turkish. | |
2419 | * bootstrap.conf (gnulib_modules): Add c-strcase. Remove strcase. | |
2420 | * lib/.cvsignore: Add c-ctype.c, c-ctype.h, c-strcase.h, | |
2421 | c-strcasecomp.c, c-strncasecmp.c. Remove strcasecmp.c, strncasecmp.c. | |
2422 | * m4/.cvsignore: Remove strcase.m4. | |
2423 | * src/getargs.c: Revert 2007-02-07 change, as follows. | |
2424 | Include c-strcase.h. | |
2425 | (language_argmatch): Use c_strcasecmp rather than strcasecmp. | |
2426 | ||
deee93a1 JD |
2427 | 2007-02-11 Bruno Haible <bruno@clisp.org> |
2428 | ||
2429 | Enable the Java related testsuite tests when the only Java compiler | |
2430 | found is a gcj < 4.3. Discussed at | |
2431 | <http://lists.gnu.org/archive/html/bug-bison/2007-02/msg00016.html>. | |
2432 | * configure.ac (gt_JAVACOMP): Don't specify a target_version. | |
2433 | ||
574add85 JD |
2434 | 2007-02-11 Joel E. Denny <jdenny@ces.clemson.edu> |
2435 | ||
2436 | * data/Makefile.am: Update copyright date. | |
2437 | * data/push.c (yypull_parse): Report memory exhaustion and return 2 if | |
2438 | yypstate_new returns NULL. | |
2439 | (yypstate_new): Return NULL if malloc does. | |
2440 | * src/reader.c (packgram): Move translation of rule actions from the | |
2441 | beginning of packgram to... | |
2442 | (check_and_convert_grammar): ... here right before packgram is invoked | |
2443 | so it's easier to write more complete comments, and remove redundant | |
2444 | code. | |
2445 | ||
e785ccf7 JD |
2446 | 2007-02-10 Joel E. Denny <jdenny@ces.clemson.edu> |
2447 | ||
2448 | As in semantic actions, make @$ in %initial-action, %destructor, and | |
2449 | %printer imply %locations. | |
2450 | * src/scan-code.l (SC_SYMBOL_ACTION): Set locations_flag = true when | |
2451 | scanning @$. | |
2452 | * tests/actions.at (AT_CHECK_ACTION_LOCATIONS): New macro supporting... | |
2453 | (@$ in %initial-action implies %locations, | |
2454 | @$ in %destructor implies %locations, | |
2455 | @$ in %printer implies %locations): ... these new test cases. | |
2456 | ||
1cfe1ed7 PE |
2457 | 2007-02-07 Paul Eggert <eggert@cs.ucla.edu> |
2458 | ||
2459 | Undo most of the 2007-02-03 change, switching to the strcase module | |
2460 | now that gnulib strcase has been fixed. | |
2461 | * bootstrap.conf (gnulib_modules): Remove c-strcase. Add strcase. | |
2462 | * lib/.cvsignore: Remove c-ctype.c, c-ctype.h, c-strcase.h, | |
2463 | c-strcasecomp.c, c-strncasecmp.c. Add strcasecmp.c, strncasecmp.c | |
2464 | * m4/.cvsignore: Add strcase.m4. | |
2465 | * src/getargs.c: Revert 2007-02-03 change, as follows. | |
2466 | Don't include c-strcase.h. | |
2467 | (language_argmatch): Use strcasecmp rather than c_strcasecmp. | |
2468 | strcasecmp has "unspecified behavior" outside the POSIX locale, | |
2469 | but it works fine in practice if at least one argument is ASCII, | |
2470 | as is the case in Bison. | |
2471 | ||
0049ec86 PB |
2472 | 2007-02-07 Paolo Bonzini <bonzini@gnu.org> |
2473 | ||
2474 | * tests/java.at: Skip tests if only one of javac/java is present. | |
2475 | Reported by Joel E. Denny. | |
2476 | * tests/atlocal.in: Adjust copyright years. | |
2477 | ||
2478 | 2007-02-05 Paolo Bonzini <bonzini@gnu.org> | |
2479 | ||
2480 | * data/lalr1.java (Stack): Work around old verifiers that disallow | |
2481 | access to the private fields of an inner class, from the outer class. | |
2482 | We can make Stack's fields public because user code doesn't have access | |
2483 | to the instance of Stack used by parse(). Reported by Paul Eggert. | |
2484 | ||
2c2b7220 PE |
2485 | 2007-02-03 Paul Eggert <eggert@cs.ucla.edu> |
2486 | ||
2487 | * .cvsignore: Add javacomp.sh, javaexec.sh. Is this really | |
2488 | the right spot for these files? | |
2489 | * bootstrap.conf (gnulib_modules): Add c-strcase. | |
2490 | * lib/.cvsignore: Add c-ctype.c c-ctype.h, c-strcasecomp.c, | |
2491 | c-strncasecmp.c. | |
2492 | * src/getargs.c: Include c-strcase.h. | |
2493 | (language_argmatch): Use c_strcasecmp rather than strcasecmp, | |
2494 | to avoid unspecified behavior. | |
2495 | ||
b2b81dae JD |
2496 | 2007-02-01 Joel E. Denny <jdenny@ces.clemson.edu> |
2497 | ||
2498 | * doc/bison.texinfo (Decl Summary): Correct typo. | |
2499 | ||
c1d19e10 PB |
2500 | 2007-01-30 Paolo Bonzini <bonzini@gnu.org> |
2501 | ||
2502 | * data/bison.m4 (b4_percent_define_flag_if): Don't treat 0 as false. | |
2503 | Complain if the value does not match empty, "true" or "false". | |
2504 | * data/c++.m4: Adjust default definitions of %define variables. | |
2505 | * data/java.m4: Adjust default definitions of %define variables. | |
2506 | * doc/bison.texinfo (Decl Summary): Adjust the %define entry according | |
2507 | to above behavior. | |
2508 | * tests/input.at (Boolean %define variables): Test new behavior. | |
2509 | ||
8405b70c PB |
2510 | 2007-01-29 Paolo Bonzini <bonzini@gnu.org> |
2511 | ||
2512 | * NEWS: Mention java. | |
2513 | * TODO: Remove things that are done. | |
2514 | * bootstrap.conf: Add javacomp-script and javaexec-script. | |
2515 | * configure.ac: Invoke gt_JAVACOMP and gt_JAVAEXEC. | |
2516 | ||
2517 | * data/Makefile.am: Add new files. | |
2518 | * data/java-skel.m4: New. | |
2519 | * data/java.m4: New. | |
2520 | * data/lalr1.java: New. | |
2521 | ||
2522 | * doc/bison.texinfo: Put "A Complete C++ Example" under | |
2523 | C++ Parsers. Add Java Parsers. Put C++ Parsers and Java Parsers | |
2524 | under Other Languages. | |
2525 | ||
2526 | * src/getargs.c (valid_languages): Add Java. | |
2527 | * src/getargs.h (struct bison_language): Update size of string fields. | |
2528 | ||
2529 | * tests/Makefile.am: Add java.at. | |
2530 | * tests/atlocal.in: Add CONF_JAVA and CONF_JAVAC. | |
2531 | * tests/java.at: New. | |
2532 | * tests/testsuite.at: Include it. | |
2533 | ||
3eb82471 JD |
2534 | 2007-01-28 Joel E. Denny <jdenny@ces.clemson.edu> |
2535 | ||
2536 | Clean up. | |
2537 | * src/scan-skel.l (at_directive_perform): Add at_directive_argc and | |
2538 | at_directive_argv arguments so these no longer have to be global | |
2539 | variables. Also, update the implementation for the following changes. | |
2540 | (fail_for_at_directive_too_many_args, | |
2541 | fail_for_at_directive_too_few_args): Add at_directive_name argument. | |
2542 | (at_directive_name): Remove as at_directive_argv[0] will be used for | |
2543 | this now. | |
2544 | (AT_DIRECTIVE_ARGC_MAX): Increment to make space in at_directive_argv | |
2545 | for the directive name. | |
2546 | (at_directive_argc, at_directive_argv): Make these local within | |
2547 | skel_lex instead of global. | |
2548 | (INITIAL): Update directive start action for above changes. | |
2549 | (SC_AT_DIRECTIVE_ARG): Rename to... | |
2550 | (SC_AT_DIRECTIVE_ARGS): ... this, and update for above changes. | |
2551 | (SC_AT_DIRECTIVE_SKIP_WS): Update. | |
2552 | (scan_skel): Move yylex_destroy to... | |
2553 | (skel_scanner_free): ... here. | |
2554 | * tests/skeletons.at (installed skeleton file name): Rename to... | |
2555 | (installed skeleton file names): ... this. | |
2556 | ||
148d66d8 JD |
2557 | 2007-01-27 Joel E. Denny <jdenny@ces.clemson.edu> |
2558 | ||
2559 | * ChangeLog: For changes in doc/bison.texinfo, consistently reference | |
2560 | node names: say "Table of Symbols" not "Bison Symbols", and say "Decl | |
2561 | Summary" not "Directives". | |
2562 | * doc/bison.texinfo (Decl Summary, Calc++ Parser): Cross-reference the | |
2563 | %code entry in "Decl Summary" rather than the one in "Table of Symbols" | |
2564 | since the former is now the more complete one. | |
2565 | (Prologue Alternatives): Likewise and do the same for %defines. | |
2566 | (Table of Symbols): Add summary of %code, add summary of %define, and | |
2567 | move full %code documentation to... | |
2568 | (Decl Summary): ... here for consistency with other entries in these | |
2569 | sections. | |
2570 | Move %define entry in order to keep this list alphabetized. | |
2571 | Reword %define entry a little to put less emphasis on the skeleton | |
2572 | concept, which most users shouldn't have to think about. | |
2573 | ||
665f0c24 PE |
2574 | 2007-01-26 Paul Eggert <eggert@cs.ucla.edu> |
2575 | ||
2576 | Adjust to recent gnulib changes. | |
2577 | * lib/.cvsignore: Remove stpcpy.h, strndup.h, strnlen.h. | |
2578 | Add string.h, string_.h, unistd_.h, wchar_.h. | |
2579 | * m4/.cvsignore: Add gnulib-common.m4, string_h.m4, wchar.m4. | |
2580 | * src/system.h: Don't include <stpcpy.h>; this is now done by | |
2581 | <string.h>. | |
2582 | ||
592d0b1e PB |
2583 | 2007-01-23 Paolo Bonzini <bonzini@gnu.org> |
2584 | ||
2585 | Simplify implementation of unqualified %code, implement macros for | |
2586 | uniform treatment of boolean %define flags. Document %define. | |
2587 | * data/bison.m4 (b4_percent_define_ifdef, b4_percent_define_flag_if, | |
2588 | b4_percent_code_ifdef): New. | |
2589 | (b4_percent_code_get): Map unqualified %code to b4_percent_code(). | |
2590 | * data/c++.m4: Define default value for global_tokens_and_yystype. | |
2591 | * data/glr.cc: Likewise. | |
2592 | * data/location.cc: Use b4_percent_define_flag_if. | |
2593 | ||
148d66d8 | 2594 | * doc/bison.texinfo (Decl Summary): Document %define. |
592d0b1e PB |
2595 | |
2596 | * src/parse-gram.y (Unqualified %code): Change muscle name to | |
2597 | b4_percent_code(). | |
2598 | (content.opt): Default to empty. | |
2599 | ||
a7867f53 JD |
2600 | 2007-01-17 Joel E. Denny <jdenny@ces.clemson.edu> |
2601 | ||
2602 | Implement support for relative and absolute skeleton file names. | |
2603 | Discussed starting at | |
2604 | <http://lists.gnu.org/archive/html/bison-patches/2006-12/msg00071.html>. | |
2605 | * doc/bison.texinfo (Decl Summary): Document in %skeleton entry. | |
2606 | (Bison Options): Document in --skeleton entry. | |
2607 | * src/output.c (output_skeleton): Use strncpy rather than strcpy since | |
2608 | full_skeleton can't necessarily hold all of pkgdatadir. | |
2609 | If the specified skeleton file name contains a `/', don't prepend | |
2610 | pkgdatadir. | |
2611 | * src/parse-gram.y (prologue_declaration): If the specified skeleton | |
2612 | file name contains a `/', prepend the grammar file directory. | |
2613 | * tests/Makefile.am (TESTSUITE_AT): Add skeletons.at. | |
2614 | * skeletons.at: New file. | |
2615 | (relative skeleton file names): New test case. | |
2616 | (installed skeleton file names): New test case. | |
2617 | * tests/testsuite.at: Include skeletons.at. | |
2618 | ||
2619 | * bootstrap: Update copyright to 2007. | |
2620 | ||
830c9b18 PB |
2621 | 2007-01-17 Paolo Bonzini <bonzini@gnu.org> |
2622 | ||
2623 | * bootstrap: Remove occurrences of .#bootmp from the files. | |
2624 | ||
a8c2e813 AD |
2625 | 2007-01-17 Akim Demaille <akim@epita.fr> |
2626 | ||
2627 | * doc/bison.texinfo (Calc++ Parser): Don't try to alias | |
2628 | nonterminals. | |
2629 | Use per-type %printer. | |
2630 | ||
279cabb6 JD |
2631 | 2007-01-17 Joel E. Denny <jdenny@ces.clemson.edu> |
2632 | ||
2633 | * NEWS, data/c++-skel.m4, data/c++.m4, data/c-skel.m4, data/c.m4, | |
2634 | data/glr.c, data/glr.cc, data/lalr1.cc, data/location.cc, | |
2635 | djgpp/config.site, src/files.c, src/files.h, src/main.c, | |
2636 | src/muscle_tab.c, src/muscle_tab.h, src/parse-gram.y, src/reader.h, | |
2637 | src/scan-skel.h, src/scan-skel.l, tests/actions.at, tests/calc.at, | |
2638 | tests/glr-regression.at, tests/input.at, tests/local.at, | |
2639 | tests/output.at, tests/torture.at: Update copyright to 2007. | |
2640 | ||
bb32f4f2 AD |
2641 | 2007-01-16 Akim Demaille <akim@epita.fr> |
2642 | ||
2643 | * doc/bison.texinfo (Calc++ Parsing Driver): Let "parse" return an | |
2644 | error code. | |
2645 | (Calc++ Scanner): Exit with failure if we can't open the input | |
2646 | file. | |
2647 | Accept "-" standing for stdin. | |
2648 | (Calc++ Top Level): Print the result only if the parsing was | |
2649 | successful. | |
2650 | ||
7cff04b5 AD |
2651 | 2007-01-16 Akim Demaille <akim@epita.fr> |
2652 | ||
2653 | * data/lalr1.cc (yy_reduce_print_): Add a missing end-of-line. | |
2654 | ||
a4e25e1d JD |
2655 | 2007-01-15 Paolo Bonzini <bonzini@gnu.org> |
2656 | and Joel E. Denny <jdenny@ces.clemson.edu> | |
2657 | ||
2658 | Clean up %define and %code implementation in M4 some. Most | |
2659 | importantly, rename all related macros to be in the b4_percent_define | |
2660 | and b4_percent_code namespaces. Also, complete support for `.' in | |
2661 | %define variable names and %code qualifiers. | |
2662 | * data/bison.m4 (b4_check_user_names): Check for special | |
2663 | "SKELETON-NAMESPACE(name)" macros instead of using two nested | |
2664 | m4_foreach loops. | |
2665 | (b4_get_percent_define, b4_get_percent_code): Rename to... | |
2666 | (b4_percent_define_get, b4_percent_code_get): ... these. | |
2667 | Extend documentation with examples. | |
2668 | For SKELETON-NAMESPACE (as documented for b4_check_user_names), use | |
2669 | b4_percent_define_skeleton_variables and | |
2670 | b4_percent_code_skeleton_qualifiers. | |
2671 | Expect any value for the %define variable `foo' to be stored in the | |
2672 | macro named `b4_percent_define(foo)'; expect any %code blocks for the | |
2673 | qualifier `foo' to be stored in a macro named `b4_percent_code(foo)'; | |
2674 | expect any unqualified %code blocks to be stored in a macro named | |
2675 | `b4_percent_code_unqualified'. | |
2676 | Use m4_indir so that %define variable names and %code qualifiers can | |
2677 | contain `.', which is allowed by the grammar parser. | |
2678 | (b4_percent_define_default): New macro to set a default value for a | |
2679 | %define variable. | |
2680 | (m4_wrap): Update wrapped code, and fix some underquoting. | |
2681 | (b4_check_user_names_wrap): Update and define outside the m4_wrap. | |
2682 | Expect grammar uses of %define variables and %code qualifiers to be | |
2683 | defined in b4_percent_define_user_variables and | |
2684 | b4_percent_code_user_qualifiers. | |
2685 | * data/c++.m4: Use b4_percent_define_default rather than | |
2686 | m4_define_default. Fix some underquoting. Skeleton usage of %define | |
2687 | variable define_location_comparison now implies skeleton usage of | |
2688 | %define variable filename_type. | |
2689 | * data/glr.c, data/glr.cc, data/lalr1.cc, data/location.cc, | |
2690 | data/push.c, data/yacc.c: Update macro names. | |
2691 | * src/parse-gram.y (prologue_declaration, grammar_declaration): Update | |
2692 | muscle names. | |
2693 | ||
e37c665c JMG |
2694 | 2007-01-14 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
2695 | ||
2696 | DJGPP specific issues. | |
2697 | ||
2698 | * djgpp/config.site: Set ac_cv_path_mkdir to a sane DJGPP specific | |
2699 | default. Set gl_cv_absolute_wctype_h to a sane DJGPP specific default. | |
2700 | ||
7d2d521f JD |
2701 | 2007-01-09 Joel E. Denny <jdenny@ces.clemson.edu> |
2702 | ||
2703 | * tests/glr-regression.at: Use AT_PARSER_CHECK rather than AT_CHECK to | |
2704 | run parsers in all tests so that Valgrind is invoked during | |
2705 | maintainer-check-valgrind. | |
2706 | (Duplicate representation of merged trees): Free all semantic values. | |
2707 | (Duplicated user destructor for lookahead): Likewise. | |
2708 | ||
e0ac9b4b JD |
2709 | 2007-01-09 Joel E. Denny <jdenny@ces.clemson.edu> |
2710 | ||
2711 | * tests/local.at (AT_PARSER_CHECK): Add a PRE argument to specify a | |
2712 | command-line prefix. | |
2713 | * tests/torture.at (Exploding the Stack Size with Alloca): Stderr is | |
2714 | ignored, so use that PRE to set --log-fd=1 in VALGRIND_OPTS so we don't | |
2715 | miss Valgrind messages. | |
2716 | (Exploding the Stack Size with Malloc): Likewise. | |
2717 | ||
78143faa JD |
2718 | 2007-01-09 Joel E. Denny <jdenny@ces.clemson.edu> |
2719 | ||
2720 | Ignore YYSTACK_USE_ALLOCA for push parsers since the stacks can't be | |
2721 | locals. Reported by Juan Manuel Guerrero at | |
2722 | <http://lists.gnu.org/archive/html/bug-bison/2007-01/msg00000.html>. | |
2723 | * data/push.c: Enclose the #ifdef YYSTACK_USE_ALLOCA in b4_push_if. | |
2724 | Fix some indentation also. | |
2725 | * tests/torture.at (Exploding the Stack Size with Alloca): Add comment | |
2726 | explaining this issue. | |
2727 | ||
7ecec4dd JD |
2728 | 2007-01-09 Paolo Bonzini <bonzini@gnu.org> |
2729 | and Joel E. Denny <jdenny@ces.clemson.edu> | |
2730 | ||
2731 | Simplify union and prologue handling, and escape union and lex/parse | |
2732 | params with digraphs. | |
2733 | * data/bison.m4 (b4_pre_prologue, b4_post_prologue): Set their default | |
2734 | values to the empty string since these are no longer guaranteed | |
2735 | initialized by the front-end. | |
2736 | * data/glr.c, data/glr.cc, data/lalr1.cc, data/push.c, data/yacc.c: Add | |
2737 | braces around b4_user_stype since this is no longer done by the | |
2738 | front-end. | |
2739 | * src/files.c, src/files.h (pre_prologue_obstack, | |
2740 | post_prologue_obstack): Remove. | |
2741 | * src/muscle_tab.c (muscle_pair_list_grow): Don't duplicate header | |
2742 | comments here. Use MUSCLE_OBSTACK_SGROW so that values are escaped | |
2743 | with digraphs. This fixes lex params and parse params. | |
2744 | * src/muscle_tab.h (muscle_pair_list_grow): Update comments. | |
2745 | * src/output.c (prepare): Remove muscle insertion of the prologues. | |
2746 | (output): Remove freeing of pre_prologue_obstack and | |
2747 | post_prologue_obstack. | |
2748 | * src/parse-gram.y (prologue_declaration): Use muscle_code_grow rather | |
2749 | than prologue_augment for prologue parsing so you don't need prologue | |
2750 | obstacks. | |
5c80250c JD |
2751 | (grammar_declaration): For %union RHS, use `braceless' instead of |
2752 | "{...}" so that braces are already stripped and code is escaped with | |
2753 | digraphs. | |
7ecec4dd JD |
2754 | * src/reader.c (prologue_augment): Remove. |
2755 | (reader): Remove initialization of pre_prologue_obstack and | |
2756 | post_prologue_obstack. | |
2757 | * src/reader.h (prologue_augment): Remove. | |
2758 | ||
2759 | * data/c.m4: Remove stray parenthesis. | |
2760 | ||
16dc6a9e JD |
2761 | 2007-01-08 Joel E. Denny <jdenny@ces.clemson.edu> |
2762 | ||
2763 | Remove quotes from variables names in %define directives and from | |
2764 | qualifiers in %code directives, and restrict the characters that are | |
2765 | allowed in them to M4-friendly ones. For %define, continue to support | |
2766 | the quoted form as a deprecated feature. Discussed starting at | |
2767 | <http://lists.gnu.org/archive/html/bison-patches/2007-01/msg00023.html>. | |
2768 | * NEWS (2.3a+): Add entry for the change to %define. Update entry for | |
2769 | %code. | |
2770 | * doc/bison.texinfo (Prologue Alternatives): Update. | |
91661ebb JD |
2771 | (Decl Summary): In %defines entry, update mention of `%code requires' |
2772 | and `%code provides'. | |
16dc6a9e JD |
2773 | (C++ Location Values): Update %define uses. |
2774 | (Calc++ Parser Interface): Likewise. | |
2775 | (Calc++ Parser): Likewise, and update `%code requires' uses. | |
148d66d8 | 2776 | (Table of Symbols): Update %code documentation. |
16dc6a9e JD |
2777 | * src/parse-gram.y (prologue_declaration): For %define variables, use |
2778 | `variable' instead of `STRING'. | |
2779 | (grammar_declaration): For %code qualifiers, use `ID' instead of | |
2780 | `STRING'. | |
2781 | (variable): New nonterminal that takes an `ID' or a `STRING'. | |
2782 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Update %code | |
2783 | and %define uses. | |
2784 | * tests/calc.at (_AT_DATA_CALC_Y): Update %define use. | |
2785 | * tests/input.at (Reject unused %code qualifiers): Update %code uses. | |
2786 | (%define errors): Update %define uses. | |
2787 | ||
e9813cd4 JD |
2788 | 2007-01-08 Joel E. Denny <jdenny@ces.clemson.edu> |
2789 | ||
2790 | * src/parse-gram.y (prologue_declaration): Use MUSCLE_INSERT_STRING | |
2791 | instead of muscle_insert for %define values so that M4-special | |
2792 | characters are replaced with digraphs. | |
2793 | * tests/input.at (%define errors): Extend to check weird values. | |
2794 | ||
6afc30cc JD |
2795 | 2007-01-08 Joel E. Denny <jdenny@ces.clemson.edu> |
2796 | ||
2797 | Instead of having skeletons declare all valid %define variables and | |
2798 | %code qualifiers, provide macros that retrieve the associated values | |
2799 | and build these lists automatically. Thus Bison will now warn when a | |
2800 | variable or qualifier is not used by the skeleton in the current | |
2801 | invocation regardless of whether it might sometimes be used by that | |
2802 | skeleton in other invocations. Also, move all %define value macros to | |
2803 | the b4_percent_define_ namespace, and remove the %define "NAME" {CODE} | |
2804 | form, which is replaced by %code. | |
2805 | * data/bison.m4 (b4_check_for_unrecognized_names): Rename to... | |
2806 | (b4_check_user_names): ... this, and change the series of valid name | |
2807 | arguments to a single list argument for names used in the skeleton | |
2808 | similar to the existing list argument for names used in the grammar. | |
2809 | Warn instead of complaining. | |
2810 | (b4_get_percent_define, b4_get_percent_code): New to retrieve %define | |
2811 | values and %code code, to format %code code properly, and to build | |
2812 | lists of all %define variables and %code qualifiers used in the | |
2813 | skeleton: b4_skeleton_percent_define_variables and | |
2814 | b4_skeleton_percent_code_qualifiers. | |
2815 | (b4_check_percent_define_variables, b4_check_percent_code_qualifiers): | |
2816 | Remove, and... | |
2817 | (m4_wrap): ... m4_wrap b4_check_user_names invocations instead so that | |
2818 | the skeleton names lists can finish building first. In place of | |
2819 | b4_used_percent_define_variables and b4_used_percent_code_qualifiers, | |
2820 | expect the lists b4_user_percent_define_variables and | |
2821 | b4_user_percent_code_qualifiers. | |
2822 | * data/c++.m4: Where setting default values for b4_parser_class_name, | |
2823 | b4_location_type, b4_filename_type, b4_namespace, and | |
2824 | b4_define_location_comparison, update their names to the | |
2825 | b4_percent_define_ namespace. | |
2826 | * data/glr.c: Don't use b4_check_percent_define_variables and | |
2827 | b4_check_percent_code_qualifiers. Use b4_get_percent_code. | |
2828 | * data/glr.cc, data/lalr1.cc: Likewise, and use b4_get_percent_define. | |
2829 | (b4_parser_class_name, b4_namespace): Define these using | |
a4e25e1d | 2830 | b4_get_percent_define for parser_class_name and namespace. |
6afc30cc JD |
2831 | * data/location.cc: Use b4_get_percent_define. |
2832 | * data/push.c: Don't use b4_check_percent_define_variables and | |
2833 | b4_check_percent_code_qualifiers. Use b4_get_percent_code. | |
2834 | * data/yacc.c: Likewise, and don't call m4_exit in | |
2835 | b4_use_push_for_pull_if or m4_wrap code will never execute. | |
2836 | * src/muscle_tab.c, src/muscle_tab.h (muscle_grow_used_name_list): | |
2837 | Rename to... | |
2838 | (muscle_grow_user_name_list): ... this for consistency with the | |
2839 | terminology used in bison.m4. | |
2840 | * src/parse-gram.y (prologue_declaration): Prepend "percent_define_" to | |
2841 | %define variable names, and rename muscle used_percent_define_variables | |
2842 | to user_percent_define_variables. | |
2843 | (grammar_declaration): Rename muscle used_percent_code_qualifiers to | |
2844 | user_percent_code_qualifiers. | |
2845 | (content): Remove. | |
2846 | (content.opt): Replace content RHS with STRING RHS so %define "NAME" | |
2847 | {CODE} form is no longer accepted. | |
2848 | * tests/input.at (Reject bad %code qualifiers): Rename to... | |
2849 | (Reject unused %code qualifiers): ... this, and update test output. | |
2850 | (%define error): Update test output. | |
2851 | ||
7eb8a0bc JD |
2852 | 2007-01-07 Joel E. Denny <jdenny@ces.clemson.edu> |
2853 | ||
2854 | Check for unrecognized %define variables similar to checking for | |
2855 | unrecognized %code qualifiers. Check for redefined %define variables. | |
2856 | * data/bison.m4 (b4_check_for_unrecognized_names): New macro that | |
2857 | generalizes... | |
2858 | (b4_check_percent_code_qualifiers): ... this, which now wraps it. | |
2859 | (b4_check_percent_define_variables): New, also wraps it. | |
2860 | * data/glr.c: Unless glr.cc is wrapping glr.c, declare no valid %define | |
2861 | variables using b4_check_percent_define_variables. | |
2862 | * data/glr.cc, data/lalr1.cc: Declare the valid %define variables as | |
2863 | all those exercised in the test suite and all those listed in the | |
2864 | `Default values' section of c++.m4. Are there others? | |
2865 | * data/push.c, data/yacc.c: Declare no valid %define variables. | |
2866 | * src/muscle_tab.c, src/muscle_tab.h (muscle_find_const): New function, | |
2867 | similar to muscle_find, but it works even when the muscle stores a | |
2868 | const value. | |
2869 | (muscle_grow_used_name_list): New function for constructing the used | |
2870 | name list muscles that b4_check_for_unrecognized_names requires. | |
2871 | * src/parse-gram.y (prologue_declaration): Warn if a variable is | |
2872 | %define'd more than once. Define the b4_used_percent_define_variables | |
2873 | muscle with muscle_grow_used_name_list. | |
2874 | (grammar_declaration): Abbreviate %code code with | |
2875 | muscle_grow_used_name_list. | |
2876 | * tests/input.at (%define errors): New. | |
2877 | ||
3fc65ead JD |
2878 | 2007-01-06 Joel E. Denny <jdenny@ces.clemson.edu> |
2879 | ||
2880 | Provide warn_at, complain_at, and fatal_at function callbacks to the | |
2881 | skeletons, and use this for %code qualifier complaints. | |
2882 | * data/bison.m4 (b4_error_at): New, invoked by... | |
2883 | (b4_warn_at, b4_complain_at, b4_fatal_at): ... these new macros to wrap | |
2884 | the skeleton scanner's new @warn_at(...@), @complain_at(...@), and | |
2885 | @fatal_at(...@) directives. | |
2886 | (b4_check_percent_code_qualifiers): Rewrite to expect locations for | |
2887 | qualifiers in b4_used_percent_code_qualifiers and to use | |
2888 | b4_complain_at. | |
2889 | * src/location.c, src/location.h (boundary_set_from_string): New global | |
2890 | function. | |
2891 | * src/muscle_tab.c, src/muscle_tab.h (muscle_boundary_grow): New global | |
2892 | function. | |
2893 | * src/parse-gram.y (grammar_declaration): Add locations for qualifiers | |
2894 | to b4_used_percent_code_qualifiers. | |
2895 | * src/scan-skel.l (fail_for_at_directive_too_few_args): New static | |
2896 | function. | |
2897 | (AT_DIRECTIVE_ARGC_MAX): Increase for boundary arguments. | |
2898 | (lineno): Rename to... | |
2899 | (out_lineno): ... this so I don't misunderstand it again. | |
2900 | (SC_AT_DIRECTIVE_SKIP_WS): Don't increment out_lineno for newlines | |
2901 | here; these newlines are in the input but not the output file. | |
2902 | (SC_AT_DIRECTIVE_ARG): Likewise. Extract directive execution to... | |
2903 | (at_directive_perform): ... this new static function, and add handling | |
2904 | of new @warn_at(...@), @complain_at(...@), and @fatal_at(...@) | |
2905 | directives. | |
2906 | * tests/input.at (Reject bad %code qualifiers): Update test output with | |
2907 | locations and extend. | |
2908 | ||
2909 | * tests/output.at (Output file name: [, Output file name: ]): Remove | |
2910 | bogus comment about these tests failing. | |
2911 | ||
1c7b7e1d JD |
2912 | 2007-01-06 Joel E. Denny <jdenny@ces.clemson.edu> |
2913 | ||
2914 | Clean up b4_check_percent_code_qualifiers a little. | |
2915 | * data/bison.m4 (b4_check_percent_code_qualifiers): Expect qualifiers | |
2916 | in b4_used_percent_code_qualifiers to be double-M4-quoted. Rewrite | |
2917 | documentation and add examples. | |
2918 | * src/parse-gram.y (grammar_declaration): Double-M4-quote those | |
2919 | qualifiers here. | |
2920 | ||
08af01c2 JD |
2921 | 2007-01-05 Joel E. Denny <jdenny@ces.clemson.edu> |
2922 | ||
2923 | Don't use m4_divert since it makes m4_divert_push and m4_divert_pop | |
2924 | unreliable -- especially when they're hidden inside another macro. | |
2925 | * data/bison.m4, data/c++-skel.m4, data/c++.m4, data/c-skel.m4, | |
2926 | data/c.m4: Remove m4_divert(-1). | |
2927 | * data/glr.c, data/glr.cc, data/lalr1.cc, data/location.cc, | |
2928 | data/push.c, data/yacc.c: Likewise, and replace m4_divert(0) with | |
2929 | m4_divert_push(0) and m4_divert_pop(0). | |
279cabb6 | 2930 | * src/output.c (output_skeleton): Don't add an m4_divert_push(0) and |
08af01c2 JD |
2931 | an m4_wrap([m4_divert_pop(0)]) to the M4. Diversion -1, which is |
2932 | pushed and popped by m4sugar, should be first on the stack. | |
2933 | ||
2934 | Provide warn, complain, and fatal function callbacks to the skeletons. | |
2935 | This provides more flexibility than m4_fatal, improves the error | |
2936 | message format, and captures messages for translation. Discussed | |
2937 | starting at | |
2938 | <http://lists.gnu.org/archive/html/bison-patches/2006-12/msg00063.html>. | |
2939 | * data/bison.m4 (b4_error): New, invoked by... | |
2940 | (b4_warn, b4_complain, b4_fatal): ... these new macros to wrap the | |
2941 | skeleton scanner's new @warn(...@), @complain(...@), and @fatal(...@) | |
2942 | directives. Because these M4 macros might be called when the current | |
2943 | diversion is -1 or 0, m4_divert_push and m4_divert_pop is used; thus | |
2944 | the previous removal of uses of m4_divert, which caused trouble. | |
2945 | (b4_check_percent_code_qualifiers): Use b4_complain instead of | |
2946 | m4_fatal to report unrecognized %code qualifiers. | |
2947 | * data/c++-skel.m4: Use b4_complain instead of m4_fatal to report C++ | |
2948 | push parser requests. | |
2949 | * data/glr.c: Use b4_complain instead of m4_fatal to report | |
2950 | non-deterministic push parser requests. | |
2951 | Update @output usage to @output(...@) form. | |
2952 | * data/glr.cc, data/lalr1.cc: Use b4_fatal instead of m4_fatal to | |
2953 | report missing %defines. Update @output usage to @output(...@) form. | |
2954 | * data/location.cc, data/push.c, data/yacc.c: Update @output usage to | |
2955 | @output(...@) form. | |
2956 | * src/main.c (main): Invoke skel_scanner_free. | |
2957 | * src/scan-skel.h (skel_scanner_free): Prototype new function. | |
2958 | * src/scan-skel.l (FLEX_NO_OBSTACK): Don't define; we now need the | |
2959 | obstack_for_string from flex-scanner.h. | |
2960 | (YY_DECL): Use to declare skel_lex static. | |
2961 | (decode_at_digraphs): Remove; now handled in the new | |
2962 | SC_AT_DIRECTIVE_ARG start condition. | |
2963 | (fail_for_at_directive_too_many_args, fail_for_invalid_at): New static | |
2964 | functions. | |
2965 | (at_directive_name, AT_DIRECTIVE_ARGC_MAX, at_directive_argc, | |
2966 | at_directive_argv): New static globals. | |
2967 | (INITIAL): Use fail_for_invalid_at. | |
2968 | Don't parse `@output file_name\n' or `@basename(...@)'. Instead, | |
2969 | recognize the start of a generalized `@directive(...@)' form and | |
2970 | start... | |
2971 | (SC_AT_DIRECTIVE_ARG): ... this new start condition to parse the | |
2972 | directive args (using the new obstack_for_string), to decode the | |
2973 | contained @ diagraphs, and to perform the directive. It recognizes | |
2974 | @basename(...@), @warn(...@), @complain(...@), @fatal(...@), and | |
2975 | @output(...@). | |
2976 | (SC_AT_DIRECTIVE_SKIP_WS): New start condition started by | |
2977 | SC_AT_DIRECTIVE_ARG to skip whitespace after the argument delimiter, | |
2978 | `@,'. | |
2979 | (scan_skel): Initialize obstack_for_string on the first call. | |
2980 | (skel_scanner_free): New function to free obstack_for_string. | |
2981 | * tests/input.at (Reject bad %code qualifiers): Update test output. | |
2982 | ||
8e0a5e9e JD |
2983 | 2007-01-04 Joel E. Denny <jdenny@ces.clemson.edu> |
2984 | ||
2985 | Consolidate the 4 prologue alternative directives (%code, %requires, | |
2986 | %provides, and %code-top) into a single %code directive with an | |
2987 | optional qualifier field. Discussed at | |
2988 | <http://lists.gnu.org/archive/html/bison-patches/2007-01/msg00012.html>. | |
2989 | * NEWS (2.3a+): Rewrite the existing entry for the prologue | |
2990 | alternatives. | |
2991 | * doc/bison.texinfo (Prologue Alternatives): Update. | |
2992 | (Decl Summary): Update to %code "requires" and %code "provides". | |
2993 | (Calc++ Parser): Update to %code "requires". | |
148d66d8 | 2994 | (Table of Symbols): Remove entries for %requires, %provides, and |
8e0a5e9e JD |
2995 | %code-top. Rewrite %code entry, and add a %code "QUALIFIER" entry. |
2996 | * data/bison.m4 (b4_user_provides, b4_user_requires): Remove as these | |
2997 | are replaced by b4_percent_code_provides and b4_percent_code_requires, | |
2998 | which are skeleton-specific. | |
2999 | (b4_check_percent_code_qualifiers): New. A skeleton can use this to | |
3000 | declare what %code qualifiers it supports and to complain if any other | |
3001 | qualifiers were used in the grammar. | |
3002 | * data/glr.cc: Update to use b4_user_code([b4_percent_code_requires]) | |
3003 | and b4_user_code([b4_percent_code_provides]) in place of | |
3004 | b4_user_requires and b4_user_provides. | |
3005 | * data/glr.c, data/lalr1.cc, data/push.c, data/yacc.c: Likewise. | |
3006 | Add b4_user_code([b4_percent_code_top]) and | |
3007 | b4_user_code([b4_percent_code]). | |
3008 | Invoke b4_check_percent_code_qualifiers. | |
3009 | * src/parse-gram.y (PERCENT_CODE_TOP, PERCENT_PROVIDES, | |
3010 | PERCENT_REQUIRES): Remove. | |
3011 | (grammar_declaration): Remove RHS's for %code-top, %provides, and | |
3012 | %requires. Rewrite the %code RHS as the unqualified form defining the | |
3013 | muscle b4_percent_code. Add another RHS for the qualified %code form, | |
3014 | which defines muscles of the form b4_percent_code_QUALIFIER and the | |
3015 | b4_used_percent_code_qualifiers muscle. | |
3016 | * src/scan-gram.l (PERCENT_CODE_TOP, PERCENT_PROVIDES, | |
3017 | PERCENT_REQUIRES): Remove. | |
3018 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Update to use | |
3019 | %code "requires" and %code "provides". | |
3020 | * tests/input.at (Reject bad %code qualifiers): New. | |
3021 | ||
95021767 JD |
3022 | 2007-01-03 Joel E. Denny <jdenny@ces.clemson.edu> |
3023 | ||
3024 | Use the new code_props interface for destructors and printers. | |
3025 | * src/symtab.h (symbol, semantic_type): Remove destructor_location and | |
3026 | printer_location members, and change the type of the destructor and | |
3027 | printer members to code_props. | |
3028 | (symbol_destructor_set, symbol_destructor_get, symbol_printer_set, | |
3029 | symbol_printer_get, semantic_type_destructor_set, | |
3030 | semantic_type_printer_set, default_tagged_destructor_set, | |
3031 | default_tagless_destructor_set, default_tagged_printer_set, | |
3032 | default_tagless_printer_set): Use code_props in arguments and return | |
3033 | types in place of char const * and location. | |
3034 | (symbol_destructor_location_get, symbol_printer_location_get): Remove | |
3035 | since the locations are now contained in the return of | |
3036 | symbol_destructor_get and symbol_printer_get. | |
3037 | * src/output.c (symbol_destructors_output, symbol_printers_output): | |
3038 | Replace with... | |
3039 | (symbol_code_props_output): ... this to eliminate duplicate code. | |
3040 | (output_skeleton): Update to use symbol_code_props_output. | |
3041 | * src/reader.c (symbol_should_be_used): Update use of | |
3042 | symbol_destructor_get. | |
3043 | * src/symlist.c (symbol_list_destructor_set, symbol_list_printer_set): | |
3044 | Update uses of the various _destructor_set and _printer_set functions. | |
3045 | * src/symtab.c: (default_tagged_destructor_location, | |
3046 | default_tagless_destructor_location, default_tagged_printer_location, | |
3047 | default_tagless_printer_location): Remove since we... | |
3048 | (default_tagged_destructor, default_tagless_destructor, | |
3049 | default_tagged_printer, default_tagless_printer): ... change the type | |
3050 | of these to code_props. | |
3051 | (symbol_new, semantic_type_new, symbol_destructor_set, | |
3052 | semantic_type_destructor_set, symbol_destructor_get, | |
3053 | symbol_printer_set, semantic_type_printer_set, symbol_printer_get, | |
3054 | symbol_check_alias_consistency, default_tagged_destructor_set, | |
3055 | default_tagless_destructor_set, default_tagged_printer_set, | |
3056 | default_tagless_printer_set): Update. | |
3057 | (symbol_destructor_location_get, symbol_printer_location_get): Remove. | |
3058 | (SYMBOL_CODE_PRINT): New similar to SYMBOL_ATTR_PRINT but for | |
3059 | code_props members. | |
3060 | (symbol_print): Use SYMBOL_CODE_PRINT. | |
3061 | ||
f6857bbf JD |
3062 | 2007-01-03 Joel E. Denny <jdenny@ces.clemson.edu> |
3063 | ||
3064 | Use the new code_props interface for rule actions. | |
3065 | * src/symlist.h (symbol_list): Replace action, action_location, and | |
3066 | used members with a code_props action_props member. | |
3067 | * src/reader.c (symbol_should_be_used, grammar_rule_check, | |
3068 | grammar_midrule_action, grammar_current_rule_merge_set, | |
3069 | grammar_current_rule_symbol_append, packgram): Update. | |
3070 | * src/scan-code.h (translate_rule_action): Remove, no longer used. | |
3071 | * src/scan-code.l (handle_action_dollar): Update. | |
3072 | (translate_rule_action): Remove, no longer used. | |
3073 | * src/symlist.c (symbol_list_sym_new, symbol_list_syms_print): Update. | |
3074 | ||
7c0c6181 JD |
3075 | 2007-01-02 Joel E. Denny <jdenny@ces.clemson.edu> |
3076 | ||
3077 | Use the new code_props interface in parse-gram.y. | |
3078 | * src/parse-gram.y (prologue_declaration, braceless, epilogue.opt): | |
3079 | Update all uses of translate_* functions to use the new code_props | |
3080 | interface and to use gram_scanner_last_string_free and | |
3081 | code_scanner_last_string_free where possible. | |
3082 | (grammar_declaration): symbol_list_destructor_set and | |
3083 | symbol_list_printer_set now perform the translation, so don't do it | |
3084 | here. Use gram_scanner_last_string_free where possible. | |
3085 | * src/scan-code.h, src/scan-code.l (translate_symbol_action, | |
3086 | translate_code): Remove, no longer used. | |
3087 | * src/symlist.h, src/symlist.c (symbol_list_destructor_set, | |
3088 | symbol_list_printer_set): Perform code translation here rather than | |
3089 | depending on the caller to do so. | |
3090 | ||
3091 | * src/symlist.h (struct symbol_list): Correct some documentation typos. | |
3092 | * src/scan-gram.h (gram_last_string): Remove declaration. | |
3093 | * src/scan-gram.l (last_string): Declare it static. | |
3094 | ||
28e52c0d JD |
3095 | 2007-01-02 Joel E. Denny <jdenny@ces.clemson.edu> |
3096 | ||
3097 | Encapsulate code properties and related functionality for the various | |
3098 | destructors, printers, and actions into a code_props structure and | |
3099 | interface. This patch merely implements code_props in scan-code.h and | |
3100 | scan-code.l. Future patches will rewrite other modules to use it. | |
3101 | Discussed starting at | |
3102 | <http://lists.gnu.org/archive/html/bison-patches/2006-11/msg00020.html>. | |
3103 | * src/location.h (EMPTY_LOCATION_INIT): Define so that it's easier to | |
3104 | consistently initialize const structs that have an empty location | |
3105 | field. | |
3106 | * src/location.c (empty_location): Initialize with EMPTY_LOCATION_INIT | |
3107 | to ensure consistency. | |
3108 | * src/scan-code.h (code_props): New structure. | |
3109 | (code_props_none_init, CODE_PROPS_NONE_INIT, code_props_none): New | |
3110 | function, macro, and const global variable for initializing a | |
3111 | code_props with no code. | |
3112 | (code_props_plain_init, code_props_symbol_action_init, | |
3113 | code_props_rule_action_init, code_props_translate_code): The rest of | |
3114 | the new code_props functional interface. Among other things, the init | |
3115 | functions set the code_props kind field so that | |
3116 | code_props_translate_code will know whether to behave like | |
3117 | translate_symbol_action, translate_rule_action, or translate_code. | |
3118 | These old translate functions must remain until all other modules are | |
3119 | updated to use the new code_props interface. | |
3120 | (code_scanner_last_string_free): New function similar to | |
3121 | gram_scanner_last_string_free. | |
3122 | (code_scanner_free): Add documentation. | |
3123 | * src/scan-code.l: Implement the new interface. | |
3124 | (code_lex): Make it static, add a code_props* argument, and remove the | |
3125 | rule argument. | |
3126 | (last_string): New static global similar to the one in scan-gram.l. | |
3127 | (SC_RULE_ACTION): Update to use the code_props* argument to code_lex | |
3128 | instead of rule. | |
3129 | (SC_SYMBOL_ACTION): For $$, set the is_value_used member of the | |
3130 | code_props since Bison may one day use this information for destructors | |
3131 | and printers. | |
3132 | (<*><<EOF>>): Use STRING_FINISH so that last_string is set. | |
3133 | (handle_action_dollar): Use symbol_list_n_get and set used flag | |
3134 | directly since symbol_list_n_used_set is removed. | |
3135 | (translate_action): Add a code_props* argument and remove the rule, | |
3136 | action, and location arguments. Pass the code_props* on to code_lex. | |
3137 | (translate_rule_action, translate_symbol_action, translate_code): | |
3138 | Rewrite as wrappers around the new code_props interface. | |
3139 | * src/symlist.h, src/symlist.c (symbol_list_n_used_set): Remove since | |
3140 | it would eventually need to break the encapsulation of code_props. | |
3141 | ||
96034983 JD |
3142 | 2007-01-01 Joel E. Denny <jdenny@ces.clemson.edu> |
3143 | ||
3144 | * etc/.cvsignore: New. | |
3145 | ||
945e396c JD |
3146 | 2007-01-01 Joel E. Denny <jdenny@ces.clemson.edu> |
3147 | ||
3148 | Add maintainer-push-check to run maintainer-check using push parsing in | |
3149 | place of pull parsing where available. | |
3150 | * Makefile.am (maintainer-push-check): New. | |
3151 | * data/bison.m4 (b4_use_push_for_pull_if): New. | |
3152 | * data/push.c: Redefine b4_push_if and b4_use_push_for_pull_if | |
3153 | appropriately based on their existing values. | |
3154 | (yypush_parse): Don't print push-parser-specific diagnostics if push | |
3155 | parsing is being used in place of pull parsing. | |
3156 | * data/yacc.c: If push parsing should replace pull parsing, redirect to | |
3157 | push.c. | |
3158 | * src/output.c (prepare): Check BISON_USE_PUSH_FOR_PULL environment | |
3159 | variable, and insert b4_use_push_for_pull_flag into muscles. | |
3160 | * tests/Makefile.am (maintainer-push-check): New. | |
3161 | ||
7d596384 JD |
3162 | 2006-12-31 Joel E. Denny <jdenny@ces.clemson.edu> |
3163 | ||
3164 | * data/push.c (yypush_parse): Set yynew = 1 at the end of a parse | |
3165 | (whether successful or failed) so that yypush_parse can be invoked | |
3166 | again to start a new parse using the same yypstate. | |
3167 | * tests/torture.at (AT_DATA_STACK_TORTURE): For push mode, extend to | |
3168 | check multiple yypull_parse invocations on the same yypstate. For pull | |
3169 | mode, extend to check multiple yyparse invocations. | |
3170 | (Exploding the Stack Size with Alloca): Extend to try with | |
3171 | %push-pull-parser. | |
3172 | (Exploding the Stack Size with Malloc): Likewise. | |
3173 | ||
3174 | * tests/calc.at (Simple LALR Calculator): Don't specify | |
3175 | %skeleton "push.c" since %push-pull-parser implies that now. | |
3176 | * tests/headers.at (export YYLTYPE): Don't check for the push | |
3177 | declarations. Otherwise, this test case can't be used to see if push | |
3178 | mode can truly emulate pull mode. | |
3179 | * tests/input.at (Torturing the Scanner): Likewise. | |
3180 | * tests/local.at (AT_YACC_OR_PUSH_IF, AT_PUSH_IF): Remove. | |
3181 | (AT_YYERROR_SEES_LOC_IF): Rather than AT_YACC_OR_PUSH_IF, use | |
3182 | AT_YACC_IF, which now includes the case of push mode since %skeleton | |
3183 | need not be used for push mode. This will be more intuitive once | |
3184 | push.c is renamed to yacc.c. | |
3185 | ||
7172e23e JD |
3186 | 2006-12-31 Joel E. Denny <jdenny@ces.clemson.edu> |
3187 | ||
3188 | For push mode, convert yyparse from a macro to a function, invoke yylex | |
3189 | instead of passing a yylexp argument to yypull_parse, and don't | |
3190 | generate yypull_parse or yyparse unless %push-pull-parser is declared. | |
3191 | Discussed starting at | |
3192 | <http://lists.gnu.org/archive/html/bison-patches/2006-12/msg00163.html>. | |
3193 | * data/bison.m4 (b4_pull_if): New. | |
3194 | * data/c.m4 (b4_identification): Define YYPULL similar to YYPUSH. | |
3195 | * data/push.c: Improve M4 quoting a little. | |
3196 | (b4_generate_macro_args, b4_parenthesize): Remove. | |
3197 | (yyparse): If there's a b4_prefix, #define this to b4_prefix[parse] | |
3198 | any time a pull parser is requested. | |
3199 | Don't #define this as a wrapper around yypull_parse. Instead, when | |
3200 | both push and pull are requested, make it a function that does that | |
3201 | same thing. | |
3202 | (yypull_parse): If there's a b4_prefix, #define this to | |
3203 | b4_prefix[pull_parse] when both push and pull are requested. | |
3204 | Don't define this as a function unless both push and pull are | |
3205 | requested. | |
3206 | Remove the yylexp argument and hard-code yylex invocation instead. | |
3207 | * etc/bench.pl.in (bench_grammar): Use %push-pull-parser instead of | |
3208 | %push-parser. | |
3209 | * src/getargs.c (pull_parser): New global initialized to true. | |
3210 | * getargs.h (pull_parser): extern it. | |
3211 | * src/output.c (prepare): Insert pull_flag muscle. | |
3212 | * src/parse-gram.y (PERCENT_PUSH_PULL_PARSER): New token. | |
3213 | (prologue_declaration): Set both push_parser and pull_parser = true for | |
3214 | %push-pull-parser. Set push_parser = true and pull_parser = false for | |
3215 | %push-parser. | |
3216 | * src/scan-gram.l: Don't accept %push_parser as an alternative to | |
3217 | %push-parser since there's no backward-compatibility concern here. | |
3218 | Scan %push-pull-parser. | |
3219 | * tests/calc.at (Simple LALR(1) Calculator): Use %push-pull-parser | |
3220 | instead of %push-parser. | |
3221 | * tests/headers.at (export YYLTYPE): Make yylex static, and don't | |
3222 | prototype it in the module that calls yyparse. | |
3223 | * tests/input.at (Torturing the Scanner): Likewise. | |
3224 | * tests/local.at (AT_PUSH_IF): Check for %push-pull-parser as well. | |
3225 | ||
2e7944cb JD |
3226 | 2006-12-26 Joel E. Denny <jdenny@ces.clemson.edu> |
3227 | ||
3228 | Update etc/bench.pl. Optimize push mode a little (the yyn change | |
3229 | deserves most of the credit). | |
3230 | * Makefile.am (SUBDIRS): Add etc subdirectory. | |
3231 | * configure.ac (AC_CONFIG_FILES): Add etc/bench.pl and etc/Makefile. | |
3232 | * data/push.c (b4_declare_parser_state_variables): Move yyn, yyresult, | |
3233 | yytoken, yyval, and yyloc declarations to... | |
3234 | (yyparse or yypush_parse): ... here to improve performance. For | |
3235 | yypush_parse invocations after the first, be sure to assign yyn its old | |
3236 | value again. | |
3237 | (yypstate_new): Don't bother initializing the yyresult field since the | |
3238 | initial value isn't used. | |
3239 | (yyn, yyresult, yytoken, yyval, yyloc): For each NAME in this list, | |
3240 | remove the #define that, in push mode, set it to yyps->NAME. | |
3241 | * etc/Makefile.am: New. | |
3242 | * etc/bench.pl: Remove and build it instead from... | |
3243 | * etc/bench.pl.in: ... this new file. Use @abs_top_builddir@ to invoke | |
3244 | "tests/bison" from the build directory by default rather than just | |
3245 | invoking "bison" from $PATH. | |
3246 | (calc_grammar): Update push parser code: don't declare yylval globally, | |
3247 | don't define yyparse_wrapper, and don't #define yyparse. | |
3248 | (bench_grammar): Update to check all working combinations of yacc.c, | |
3249 | push.c, impure, pure, pull, and push. | |
3250 | ||
c3d50342 JD |
3251 | 2006-12-25 Joel E. Denny <jdenny@ces.clemson.edu> |
3252 | ||
3253 | For push mode, add pull wrappers around yypush_parse. | |
3254 | * data/push.c: (b4_generate_macro_args, b4_parenthesize): New macros. | |
3255 | (yypull_parse): New function wrapping yypush_parse. | |
3256 | (yyparse): New #define wrapping yypull_parse. | |
3257 | * tests/calc.at (_AT_DATA_CALC_Y): Call yyparse even when %push-parser | |
3258 | is declared. | |
3259 | * tests/headers.at (export YYLTYPE): Make yylex global. For push mode, | |
3260 | prototype yylex in the module that calls yyparse, and don't prototype | |
3261 | yyparse there. Otherwise, the yyparse expansion won't compile. | |
3262 | * tests/input.at (Torturing the Scanner): Likewise. | |
3263 | ||
94ebeba5 JD |
3264 | 2006-12-25 Joel E. Denny <jdenny@ces.clemson.edu> |
3265 | ||
3266 | Enable push parsers to operate in impure mode. Thus, %push-parser no | |
3267 | longer implies %pure-parser. The point of this change is to move | |
3268 | towards being able to test the push parser code by running the entire | |
3269 | test suite as if %push-parser had been declared. | |
3270 | * data/push.c (yypush_parse): For impure mode, remove the | |
3271 | yypushed_char, yypushed_val, and yypushed_loc arguments. | |
3272 | Instead, declare these as local variables initialized to the global | |
3273 | yychar, yylval, and yylloc. | |
3274 | For the first yypush_parse invocation only, restore the initial values | |
3275 | of these global variables when it's time to read a token since they | |
3276 | have been overwritten. | |
3277 | * src/parse-gram.y (prologue_declaration): Don't set pure_parser for | |
3278 | %push-parser. | |
3279 | * tests/calc.at (Simple LALR(1) Calculator): Always declare | |
3280 | %pure-parser along with %push-parser since this test case was designed | |
3281 | for pure push parsers. | |
3282 | * tests/local.at (AT_PURE_OR_PUSH_IF): Remove unused. | |
3283 | (AT_YACC_OR_PUSH_IF): New. | |
3284 | (AT_YYERROR_SEES_LOC_IF): Fix enough that the test suite passes, but | |
3285 | add a note that it's still wrong for some cases (as it has been for a | |
3286 | while). | |
3287 | (AT_PURE_LEX_IF): Use AT_PURE_IF instead of AT_PURE_OR_PUSH_IF since | |
3288 | %push-parser no longer implies %pure-parser. | |
3289 | ||
a0633178 JD |
3290 | 2006-12-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3291 | ||
3292 | Remove some unnecessary differences between the pull parser code and | |
3293 | the push parser code. This patch enables yynerrs in push mode. | |
3294 | * data/push.c: Reformat M4 a little. | |
3295 | (b4_yyerror_range): Remove and convert all uses to just yyerror_range. | |
3296 | (b4_declare_scanner_communication_variables): Don't omit yynerrs just | |
3297 | because push mode is on. Instead, if pure mode is on, move yynerrs | |
3298 | to... | |
3299 | (b4_declare_parser_state_variables): ... here. | |
3300 | (yynerrs, yyerror_range): For push mode, #define each NAME in this list | |
3301 | to yyps->NAME so it can be used in yypush_parse. | |
3302 | (yypush_parse): Don't omit uses of yynerrs in push mode. | |
3303 | ||
8646b6a3 JD |
3304 | 2006-12-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3305 | ||
3306 | Fix bug such that the first pushed token's value and location are | |
3307 | sometimes overwritten (sometimes by %initial-action) before being used. | |
3308 | * data/push.c (yypush_parse): Rename arguments yynchar, yynlval, and | |
3309 | yynlloc to yypushed_char, yypushed_val, and yypushed_loc for clarity. | |
3310 | For the first yypush_parse invocation, initialize yychar to YYEMPTY to | |
3311 | more closely mimic the pull parser logic. | |
3312 | Don't copy the pushed token to yychar, yylval, and yylloc until it's | |
3313 | time to read a token, which is after any initialization of yylval and | |
3314 | yylloc. | |
3315 | (gottoken): Rename label to... | |
3316 | (yyread_pushed_token): ... for clarity and to avoid infringing on the | |
3317 | user namespace. | |
3318 | ||
9baf4d74 JD |
3319 | 2006-12-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3320 | ||
3321 | Rearrange initialization of the parser state variables so that the | |
3322 | skeleton doesn't have to have a copy for pull mode and another for push | |
3323 | mode. This patch also fixes at least a bug such that yylloc was not | |
3324 | initialized (with b4_location_initial_line and | |
3325 | b4_location_initial_column) upon calling yypush_parse. However, that | |
3326 | initialization now overwrites the first token's location; | |
3327 | %initial-action assigning @$ already did the same thing, and both bugs | |
3328 | will be fixed in a later patch. | |
3329 | * data/push.c (b4_yyssa): Remove and convert all uses to just yyssa. | |
3330 | (b4_declare_parser_state_variables): Remove initialization of yytoken, | |
3331 | yyss, yyvs, yyls, and yystacksize. | |
3332 | (yypstate_new): Remove initialization of some yypstate fields: yystate, | |
3333 | yyerrstatus, yytoken, yyss, yyvs, yyls, yystacksize, yyssp, yyvsp, and | |
3334 | yylsp. | |
3335 | (yyssa, yyvsa, yylsa): For push mode, #define each NAME in this list to | |
3336 | yyps->NAME so it can be used in yypush_parse. | |
3337 | (yyparse or yypush_parse): For yypush_parse, don't print the | |
3338 | "Starting parse" diagnostic for invocations after the first. | |
3339 | Add initialization of yytoken, yyss, yyvs, yyls, and yystacksize; for | |
3340 | yypush_parse, only do it for the first invocation. | |
3341 | Allow yystate, yyerrstatus, yyssp, yyvsp, yylsp, and yylloc | |
3342 | initialization to occur in yypush_parse but only on the first | |
3343 | invocation. | |
3344 | ||
23522164 JD |
3345 | 2006-12-19 Joel E. Denny <jdenny@ces.clemson.edu> |
3346 | ||
3347 | * data/push.c: Add CPP guards around push parser declarations in both | |
3348 | the header and the code file. | |
3349 | In the code file, move the push parser declarations to the same place | |
3350 | they appear in the header file. | |
3351 | Clean up the M4 some, especially the inconsistent underquoting in | |
3352 | some b4_c_function_def and b4_c_function_decl uses. | |
3353 | ||
bb010fe5 JD |
3354 | 2006-12-19 Joel E. Denny <jdenny@ces.clemson.edu> |
3355 | ||
3356 | Encapsulate the push parser state variables into an M4 macro so the | |
3357 | push skeleton doesn't have to list them again for pull mode's yyparse. | |
3358 | For push mode, remove yypush_parse's local equivalents of these | |
3359 | variables to eliminate unnecessary copying between the two sets at | |
3360 | run-time. This patch also fixes at least a bug related to multiple | |
3361 | %initial-action invocations in push mode. | |
3362 | * data/push.c (b4_declare_parser_variables): Rename to... | |
3363 | (b4_declare_scanner_communication_variables): ... this for clarity and | |
3364 | update both uses. | |
3365 | (b4_declare_yyparse_variables): Remove and move its contents to the one | |
3366 | spot where it was invoked. | |
3367 | (b4_declare_parser_state_variables): New macro containing the parser | |
3368 | state variables required by push mode. | |
3369 | (struct yypstate): Replace all fields but yynew with | |
3370 | b4_declare_parser_state_variables. | |
3371 | (yystate, yyn, yyresult, yyerrstatus, yytoken, yyss, yyssp, yyvs, | |
3372 | yyvsp, yyls, yylsp, yystacksize, yyval, yyloc): For push mode, #define | |
3373 | each NAME in this list to yyps->NAME so it can be used in yypush_parse. | |
3374 | (yyparse or yypush_parse): For yyparse in pull mode, replace local | |
3375 | parser state variable declarations with | |
3376 | b4_declare_parser_state_variables. | |
3377 | Don't initialize parser state variables when calling yypush_parse since | |
3378 | yypstate_new already does that. | |
3379 | Invoke the user's initial action only upon the first yypush_parse | |
3380 | invocation. | |
3381 | Remove all code that copies between the local parser state variables | |
3382 | and the yypstate. | |
3383 | ||
2d212f8c JD |
3384 | 2006-12-19 Joel E. Denny <jdenny@ces.clemson.edu> |
3385 | ||
3386 | * data/push.c (union yyalloc): Rename yyss, yyvs, and yyls fields to | |
3387 | prevent a name collision in a future patch where these names will | |
3388 | sometimes be #define'd. | |
3389 | (YYSTACK_RELOCATE): Add an argument to select a union yyalloc field | |
3390 | since it no longer has the same name as the existing argument. | |
3391 | (yyparse or yypush_parse): Update all uses of YYSTACK_RELOCATE. | |
3392 | ||
e6e704dc JD |
3393 | 2006-12-19 Paolo Bonzini <bonzini@gnu.org> |
3394 | and Joel E. Denny <jdenny@ces.clemson.edu> | |
3395 | ||
3396 | * doc/bison.texinfo (Decl Summary): In the %language entry, mention | |
3397 | that the argument is case-insensitive, and there's no `=' here. | |
3398 | For the %skeleton entry, mention that %language is better. | |
3399 | (Bison Options): Likewise for --language and --skeleton. Move the | |
3400 | --skeleton entry so that the `Tuning the parser' section is sorted | |
3401 | alphabetically on long options. | |
3402 | (C++ Bison Interface): Don't use the word skeleton. Don't explain the | |
3403 | %language directive in detail here; cross-reference the %language | |
3404 | documentation instead. | |
3405 | (Calc++ Parser): Use `%require "@value{VERSION}"' rather than | |
3406 | `%require "2.3b"' so that the example is always up-to-date. | |
148d66d8 | 3407 | (Table of Symbols): Add entries for %language and %skeleton. |
e6e704dc JD |
3408 | * examples/extexi (normalize): Instead of replacing every %require |
3409 | argument with the current Bison version, just substitute for | |
3410 | `@value{VERSION}'. This guarantees that we're testing what actually | |
3411 | appears in the documentation. | |
3412 | * examples/calc++/Makefile.am ($(calc_extracted)): Use `$(VERSION)' | |
3413 | rather than `@VERSION@'. | |
3414 | ||
0e021770 PE |
3415 | 2006-12-18 Paul Eggert <eggert@cs.ucla.edu> |
3416 | ||
fd575f05 PE |
3417 | * NEWS: Reword the %language news a bit, and put it earlier. |
3418 | ||
0e021770 PE |
3419 | * src/getargs.c (skeleton_arg): Last arg is now location const *. |
3420 | Rewrite to simplify the logic. | |
3421 | (language_argmatch): Likewise. | |
fd575f05 PE |
3422 | (program_name): We now own this var. |
3423 | * src/getargs.h (struct bison_language): Use char[] rather than | |
3424 | const char *. | |
0e021770 PE |
3425 | |
3426 | * doc/bison.texinfo (Decl Summary, Bison Options): Don't claim | |
3427 | Java is supported. | |
3428 | * src/complain.c (program_name): Remove decl; no longer needed. | |
3429 | * src/main.c (program_name): Remove; now belongs to getargs. | |
3430 | ||
3431 | 2006-12-18 Paolo Bonzini <bonzini@gnu.org> | |
3432 | ||
3433 | * NEWS: Document %language. | |
3434 | ||
3435 | * data/Makefile.am (dist_pkgdata_DATA): Add c-skel.m4, c++-skel.m4. | |
3436 | ||
3437 | * data/c-skel.m4, data/c++-skel.m4: New files. | |
3438 | * data/glr.c: Complain on push parsers. | |
3439 | ||
3440 | * doc/bison.texinfo (C++ Parser Interface): Prefer %language | |
3441 | over %skeleton. | |
148d66d8 | 3442 | (Decl Summary): Document %language and %skeleton. |
0e021770 PE |
3443 | (Command line): Document -L. |
3444 | ||
3445 | * examples/extexi: Rewrite %require directive. | |
3446 | * examples/calc++/Makefile.am: Pass VERSION to extexi. | |
3447 | ||
3448 | * src/files.c (compute_exts_from_gc): Look in language structure | |
3449 | for .y extension. | |
3450 | (compute_file_name_parts): Check whether .tab should be added. | |
3451 | * src/getargs.c (valid_languages, skeleton_prio, language_prio): | |
3452 | (language, skeleton_arg, language_argmatch): New. | |
3453 | (long_options): Add --language. | |
3454 | (getargs): Use skeleton_arg, add -L/--language. | |
3455 | * src/getargs.h: Include location.h. | |
3456 | (struct bison_language, language, skeleton_arg, language_argmatch): New. | |
3457 | * src/output.c (prepare): Pick default skeleton from struct language. | |
3458 | Don't dispatch C skeletons here. | |
3459 | * src/parse-gram.y (PERCENT_LANGUAGE): New. | |
3460 | (prologue_declaration): Add "%language" rule, use skeleton_arg. | |
3461 | * src/scan-gram.l ("%language"): New rule. | |
3462 | ||
3463 | * tests/calc.at: Test %skeleton and %language. | |
3464 | * tests/local.at (AT_SKEL_CC_IF): Look for %language. | |
3465 | (AT_GLR_IF): Look for %skeleton "glr.cc". | |
3466 | (AT_LALR1_CC_IF, AT_GLR_CC_IF): Rewrite. | |
3467 | (AT_YACC_IF): Reject %language. | |
3468 | ||
5691bf57 PE |
3469 | 2006-12-18 Paul Eggert <eggert@cs.ucla.edu> |
3470 | ||
db06f0ce PE |
3471 | * src/symtab.h (struct semantic_type): Remove the tag 'semantic_type', |
3472 | since it wasn't used; only the typedef name 'semantic_type' is needed. | |
3473 | Also, omit trailing white space. | |
3474 | ||
5691bf57 PE |
3475 | * bootstrap: Sync from coreutils. |
3476 | (gnulib_extra_files): Add build-aux/announce.gen. | |
3477 | (slurp): Adjust .gitignore files like .cvsignore files. | |
3478 | * build-aux/announce-gen: Remove from CVS, since bootstrap | |
3479 | now creates this. | |
3480 | ||
791934e4 JD |
3481 | 2006-12-16 Joel E. Denny <jdenny@ces.clemson.edu> |
3482 | ||
3483 | Make %push-parser imply %pure-parser. This fixes several bugs; see | |
3484 | <http://lists.gnu.org/archive/html/bison-patches/2006-12/msg00148.html>. | |
3485 | * src/parse-gram.y (prologue_declaration): For %push-parser, also set | |
3486 | pure_parser = true. | |
3487 | * data/push.c: Don't bother testing b4_push_if when deciding whether | |
3488 | to expand b4_declare_parser_variables globally. | |
3489 | (yypush_parse): Likewise in here. | |
3490 | ||
3491 | * data/push.c (yypush_parse): Add b4_parse_param to arguments. | |
3492 | (yy_reduce_print): Reformat M4 for readability. | |
3493 | ||
ee5abb37 JD |
3494 | 2006-12-15 Bob Rossi <bob@brasko.net> |
3495 | and Joel Denny <jdenny@ces.clemson.edu> | |
3496 | ||
3497 | * data/push.c (yypstate): Add typedef, and update all uses of | |
3498 | struct yypstate to just yypstate. | |
3499 | * tests/calc.at (_AT_DATA_CALC_Y): Update here as well. | |
3500 | ||
16ca01f9 JD |
3501 | 2006-12-14 Bob Rossi <bob@brasko.net> |
3502 | ||
3503 | * data/push.c (yypush_parse): Declare prototype regardless of | |
3504 | %locations option. | |
3505 | ||
ab8e7e1a JD |
3506 | 2006-12-14 Bob Rossi <bob@brasko.net> |
3507 | ||
3508 | * data/push.c (yyparse): Remove the prototype and the #define when in | |
3509 | push-parser mode. | |
3510 | ||
9bf32be3 JD |
3511 | 2006-12-13 Bob Rossi <bob@brasko.net> |
3512 | ||
3513 | * data/push.c (yypstate_init): Rename to... | |
3514 | (yypstate_new): ... this and use b4_c_function_def. | |
3515 | (yypstate_delete): New. | |
3516 | (yypush_parse): Change parameters yynval and yynlloc to be const. | |
3517 | * tests/calc.at (_AT_DATA_CALC_Y): Use new yypstate_new and | |
3518 | yypstate_delete functions. | |
3519 | ||
f02e2948 JD |
3520 | 2006-12-13 Joel E. Denny <jdenny@ces.clemson.edu> |
3521 | ||
3522 | * configure.ac (AC_PREREQ): Require Autoconf 2.61 because of our | |
3523 | strange test case titles. Reported by Bob Rossi. | |
3524 | ||
38eb7751 PE |
3525 | 2006-12-13 Paul Eggert <eggert@cs.ucla.edu> |
3526 | ||
3527 | * TODO: Add pointer to Sylvain Schmitz's work on static detection | |
3528 | of potential ambiguities in GLR grammers. | |
3529 | ||
bd9d212b JD |
3530 | 2006-12-12 Joel E. Denny <jdenny@ces.clemson.edu> |
3531 | ||
3532 | * tests/testsuite.at (AT_CHECK): When checking if $1 starts with | |
3533 | `bison ', use m4_index instead of m4_substr since chopping up a string | |
3534 | containing M4-special characters causes problems here. | |
3535 | ||
3536 | Fix a couple of bugs related to special characters in user-specified | |
3537 | file names, and make it easier for skeletons to compute output file | |
3538 | names with the same file name prefix as Bison-computed output file | |
3539 | names. | |
3540 | * data/glr.cc, data/push.c, data/yacc.c: In @output, use | |
3541 | b4_parser_file_name and b4_spec_defines_file instead of | |
3542 | @output_parser_name@ and @output_header_name@, which are now redundant. | |
3543 | * data/glr.c, data/lalr1.cc: Likewise. Also, in header #include's, use | |
3544 | b4_parser_file_name, b4_spec_defines_file, and the new | |
3545 | @basename(FILENAME@) instead of @output_parser_name@ and | |
3546 | @output_header_name@, which inappropriately escaped the file names as | |
3547 | C string literals. | |
3548 | * src/files.c (all_but_ext): Remove static qualifier. | |
3549 | (compute_output_file_names): Move `free (all_but_ext)' to... | |
3550 | (output_file_names_free): ... here since all_but_ext is needed later. | |
3551 | * src/files.h (all_but_ext): Extern. | |
3552 | * src/muscle_tab.h (MUSCLE_INSERT_STRING_RAW): New macro that does | |
3553 | exactly what MUSCLE_INSERT_STRING used to do. | |
3554 | (MUSCLE_INSERT_STRING): Use MUSCLE_OBSTACK_SGROW so that M4-special | |
3555 | characters are escaped properly. | |
3556 | * src/output.c (prepare): Define muscle file_name_all_but_ext as | |
3557 | all_but_ext. | |
3558 | For pkgdatadir muscle, maintain previous functionality by using | |
3559 | MUSCLE_INSERT_STRING_RAW instead of MUSCLE_INSERT_STRING. The problem | |
3560 | is that b4_pkgdatadir is used inside m4_include in the skeletons, so | |
3561 | digraphs would never be expanded. Hopefully no one has M4-special | |
3562 | characters in his Bison installation path. | |
3563 | * src/scan-skel.l: Don't parse @output_header_name@ and | |
3564 | @output_parser_name@ anymore since they're now redundant. | |
3565 | In @output, use decode_at_digraphs. | |
3566 | Parse a new @basename command that invokes last_component. | |
3567 | (decode_at_digraphs): New. | |
3568 | (BASE_QPUTS): Remove unused. | |
3569 | * tests/output.at (AT_CHECK_OUTPUT_FILE_NAME): New macro. | |
3570 | (Output file name): New tests. | |
3571 | ||
3f7ca628 JD |
3572 | 2006-12-09 Joel E. Denny <jdenny@ces.clemson.edu> |
3573 | ||
3574 | Warn about output files that are generated by the skeletons and that | |
3575 | conflict with other output files. | |
3576 | * data/glr.c: Don't generate the header file here when glr.cc does. | |
3577 | * src/files.c (file_names, file_names_count): New static globals. | |
3578 | (compute_output_file_names): Invoke output_file_name_check for files | |
3579 | not generated by the skeletons and remove existing checks. | |
3580 | (output_file_name_check): New function that warns about conflicting | |
3581 | output file names. | |
3582 | (output_file_names_free): Free file_names. | |
3583 | * src/files.h (output_file_name_check): Declare. | |
3584 | * src/scan-skel.l: Invoke output_file_name_check for files generated by | |
3585 | the skeletons. | |
3586 | * tests/output.at (AT_CHECK_CONFLICTING_OUTPUT): New. | |
3587 | (Conflicting output files): New tests. | |
3588 | ||
178e123e PE |
3589 | 2006-12-09 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> |
3590 | ||
3591 | * doc/bison.texinfo: Fix a couple of typos. | |
3592 | ||
3593 | 2006-12-08 Bob Rossi <bob@brasko.net> | |
8def5cd0 JD |
3594 | |
3595 | * data/push.c: (yypvarsinit, yypvars, struct yypvars, yypushparse): | |
3596 | Rename to... | |
3597 | (yypstate_init, yypstate, struct yypstate, yypush_parse): ... these and | |
3598 | update all uses. | |
3599 | (b4_yyssa, b4_yyerror_range, yypstate_init): Rename pv to yyps. | |
3600 | (yypush_parse): Rename yypvars argument to yyps and remove redundant | |
3601 | local pv. | |
3602 | (yypstate_init, yypush_parse): Declare in Bison-generated header file. | |
3603 | * tests/calc.at (_AT_DATA_CALC_Y): Use newly named functions. | |
3604 | ||
ea17f233 JD |
3605 | 2006-12-07 Bob Rossi <bob@brasko.net> |
3606 | and Joel Denny <jdenny@ces.clemson.edu> | |
3607 | ||
3608 | * data/push.c (yypvarsinit): Change return type from void* to struct | |
3609 | yypvars*. No longer cast to void* on return. | |
3610 | (struct yypvars): Remove yylen since it need not be remembered between | |
3611 | yypushparse invocations. | |
3612 | (yypushparse): Don't copy between yylen and pv->yylen. | |
3613 | ||
55a30bda JD |
3614 | 2006-12-05 Bob Rossi <bob@brasko.net> |
3615 | ||
3616 | * data/push.c (yychar_set, yylval_set, yylloc_set): Delete. | |
3617 | (yypushparse): Add yynchar, yynlval, yynlloc parameters. | |
3618 | (b4_declare_parser_variables): Do not declare yynerrs for push mode. | |
3619 | (struct yypvars): Remove b4_declare_parser_variables. | |
3620 | (yypvarsinit): Remove init code for removed variables. | |
3621 | (global scope): Do not declare b4_declare_parser_variables if | |
3622 | push or pure mode. | |
3623 | (yypushparse): Add b4_declare_parser_variables. | |
3624 | Init new local variables, and remove init code for removed | |
3625 | yypvars variables. | |
3626 | (yyparse): Delete. | |
3627 | * tests/calc.at (_AT_DATA_CALC_Y): Call yypushparse for push mode | |
3628 | and yyparse for other modes. | |
3629 | (AT_CHECK_CALC_LALR): Added '%skeleton "push.c"' for push tests. | |
3630 | * tests/local.at (AT_PUSH_IF, AT_PURE_OR_PUSH_IF): Added. | |
3631 | (AT_YYERROR_SEES_LOC_IF): push-parser makes this false. | |
3632 | (AT_PURE_LEX_IF): True if pure or push parser. | |
3633 | ||
85894313 JD |
3634 | 2006-12-05 Joel E. Denny <jdenny@ces.clemson.edu> |
3635 | ||
3636 | Document Yacc prologue alternatives and default %destructor's and | |
3637 | %printer's as experimental. Don't mention Java yet. Discussed at | |
3638 | <http://lists.gnu.org/archive/html/bison-patches/2006-12/msg00002.html>. | |
3639 | * NEWS (2.3a+): Say they're experimental. Remove any mention of Java. | |
3640 | (2.3a): Annotate this entry to say the old forms of these features were | |
3641 | also experimental. | |
3642 | * doc/bison.texinfo (Prologue Alternatives, Freeing Discarded Symbols, | |
148d66d8 | 3643 | Table of Symbols): Say they're experimental. Comment out any mention |
85894313 JD |
3644 | of Java (we'll want this back eventually). |
3645 | ||
02975b9a JD |
3646 | 2006-12-01 Joel E. Denny <jdenny@ces.clemson.edu> |
3647 | ||
3648 | Support a file name argument to %defines. Deprecate `=' in | |
3649 | %file-prefix, %name-prefix, and %output. Discussed at | |
3650 | <http://lists.gnu.org/archive/html/help-bison/2006-09/msg00001.html>. | |
3651 | * NEWS (2.3a+): Mention. | |
148d66d8 | 3652 | * doc/bison.texinfo (Decl Summary, Table of Symbols): Add entry for new |
02975b9a JD |
3653 | form of %defines, and remove `=' from entries for %file-prefix, |
3654 | %name-prefix, and %output. | |
3655 | * src/parse-gram.y (prologue_declaration): Implement. | |
3656 | * tests/calc.at (Simple LALR Calculator, Simple GLR Calculator, Simple | |
3657 | LALR1 C++ Calculator, Simple GLR C++ Calculator): Remove the `=' from | |
3658 | all but one occurrence of %name-prefix. | |
3659 | * tests/headers.at (export YYLTYPE): Remove the `=' from %name-prefix. | |
3660 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Likewise. | |
3661 | * tests/output.at (AT_CHECK_OUTPUT): Remove the `=' from all but one | |
3662 | occurrence of each of %file-prefix and %output. Add check for %defines | |
3663 | with argument. | |
3664 | * tests/reduce.at (Useless Terminals, Useless Nonterminals, | |
3665 | Useless Rules, Reduced Automaton, Underivable Rules, Empty Language): | |
3666 | Remove the `=' from %output. | |
3667 | ||
287b314e JD |
3668 | 2006-11-21 Joel E. Denny <jdenny@ces.clemson.edu> |
3669 | ||
3670 | Don't escape $ in test case titles since Autoconf 2.61 now does that | |
3671 | correctly. | |
3672 | * tests/actions.at (Default %printer and %destructor are not for error | |
3673 | or $undefined): Here. | |
3674 | (Default %printer and %destructor are not for $accept): Here. | |
3675 | * tests/input.at (Invalid $n and @n): Here. | |
3676 | ||
3ebecc24 JD |
3677 | 2006-11-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3678 | ||
3679 | Rename <!> to <>. Discussed starting at | |
3680 | <http://lists.gnu.org/archive/html/bison-patches/2006-11/msg00039.html>. | |
3681 | * NEWS (2.3a+): Update. | |
148d66d8 | 3682 | * doc/bison.texinfo (Freeing Discarded Symbols, Table of Symbols): |
3ebecc24 JD |
3683 | Update. |
3684 | * src/parse-gram.y (TYPE_TAG_NONE, generic_symlist_item): Implement. | |
3685 | * src/scan-gram.l (INITIAL): Implement. | |
3686 | * src/symlist.c (symbol_list_default_tagless_new): Update comment. | |
3687 | * src/symlist.h (symbol_list, symbol_list_default_tagless_new): Update | |
3688 | comment. | |
3689 | * tests/actions.at (Default tagless %printer and %destructor, | |
3690 | Default tagged and per-type %printer and %destructor, | |
3691 | Default %printer and %destructor are not for error or $undefined, | |
3692 | Default %printer and %destructor are not for $accept, | |
3693 | Default %printer and %destructor for mid-rule values): Update. | |
3694 | * tests/input.at (Default %printer and %destructor redeclared, | |
3695 | Unused values with default %destructor): Update. | |
3696 | ||
26b8a438 JD |
3697 | 2006-11-17 Joel E. Denny <jdenny@ces.clemson.edu> |
3698 | ||
3699 | Don't let %prec take a nonterminal. | |
3700 | * src/reader.c (grammar_current_rule_prec_set): Make the %prec symbol a | |
3701 | token. | |
3702 | * tests/input.at (%prec takes a token): New test checking that %prec | |
3703 | won't take a nonterminal. | |
3704 | ||
07c39ae9 JD |
3705 | 2006-11-10 Joel E. Denny <jdenny@ces.clemson.edu> |
3706 | ||
405d53b7 JD |
3707 | * tests/testsuite.at (AT_CHECK): Don't miss an exit value of 0 because |
3708 | it was double-quoted. | |
07c39ae9 JD |
3709 | * src/Makefile.am (YACC): Use --warnings=all,error so that Bison's own |
3710 | grammar is maintained with Bison's highest standards. | |
3711 | * src/getargs.c: Fix some typos in Doxygen comments. | |
3712 | ||
580b8926 JD |
3713 | 2006-11-10 Joel E. Denny <jdenny@ces.clemson.edu> |
3714 | ||
3715 | Fix memory leaks in scanners generated by at least Flex 2.5.9 and | |
3716 | later. Reported by Paul Eggert in | |
3717 | <http://lists.gnu.org/archive/html/bison-patches/2006-11/msg00014.html>. | |
3718 | * src/flex-scanner.h (yylex_destroy): Define for Flex before 2.5.9. | |
3719 | * src/scan-code.l (translate_action): Don't bother invoking | |
3720 | yy_delete_buffer (YY_CURRENT_BUFFER) before creating the first buffer. | |
3721 | (code_scanner_free): Instead of invoking | |
3722 | yy_delete_buffer (YY_CURRENT_BUFFER) directly, invoke yylex_destroy, | |
3723 | which frees more. | |
3724 | * src/scan-gram.l (gram_scanner_free): Likewise. | |
3725 | * src/scan-skel.l (scan_skel): Likewise. | |
3726 | ||
4502eadc JD |
3727 | 2006-11-09 Joel E. Denny <jdenny@ces.clemson.edu> |
3728 | ||
3729 | * src/files.c (tr): Change return type to void. | |
3730 | * src/muscle_tab.c (muscle_insert): Free storage in case muscle_grow | |
3731 | has been called previously for the same key. | |
3732 | (muscle_find): Return storage instead of value so that | |
3733 | --enable-gcc-warnings doesn't produce warnings that the return discards | |
3734 | const. aver that the value and storage are the same since storage | |
3735 | could potentially be NULL when value is not. | |
3736 | * tests/testsuite.at (AT_CHECK): Treat an unspecified exit value the | |
3737 | same as 0. | |
3738 | ||
7746c8f6 PE |
3739 | 2006-11-08 Paul Eggert <eggert@cs.ucla.edu> |
3740 | ||
3741 | * bootstrap.conf (excluded_files): Exclude m4/codeset.m4 (undoing | |
3742 | the earlier change today), m4/intl.m4, m4/intldir.m4. This gives | |
3743 | us a slightly cleaner distribution, and also works. | |
3744 | * m4/.cvsignore: Add inline.m4, wint_t.m4 to accommodate recent | |
3745 | gnulib changes. | |
3746 | ||
eb095650 PE |
3747 | 2006-11-08 Joel E. Denny <jdenny@ces.clemson.edu> |
3748 | and Paul Eggert <eggert@cs.ucla.edu> | |
3749 | ||
3750 | Don't let Bison leak memory except when it complains. | |
3751 | * src/files.h (parser_file_name, spec_verbose_file, spec_graph_file): | |
3752 | (spec_defines_file, dir_prefix): Now char *, not const char *, | |
3753 | since they are freed. | |
3754 | * src/files.c: Likewise. | |
3755 | (all_but_ext, all_but_tab_ext, src_extension, header_extension): | |
3756 | Likewise. | |
3757 | (tr): Now operates in-place. All uses changed. | |
3758 | (compute_exts_from_gf, compute_exts_from_src): Don't leak temporary | |
3759 | values. | |
3760 | (compute_file_name_parts, compute_output_file_names): Don't store | |
3761 | read-only data in variables that will be freed. | |
3762 | (compute_output_file_names): Free all_but_ext, all_but_tab_ext, | |
3763 | src_extension, and header_extension. | |
3764 | (output_file_names_free): New public function to free | |
3765 | spec_verbose_file, spec_graph_file, spec_defines_file, | |
3766 | parser_file_name, and dir_prefix. | |
3767 | * src/getargs.c (getargs): Don't store read-only data in variables that | |
3768 | will be freed. | |
3769 | * src/main.c (main): Invoke output_file_names_free, code_scanner_free | |
3770 | (which previously existed but was unused), and quotearg_free. | |
3771 | * src/muscle_tab.h (muscle_insert): value arg is now a `char const *'. | |
3772 | * src/muscle_tab.c: Likewise. | |
3773 | (muscle_entry): Make the value char const *, | |
3774 | and add a new storage member that is char * and can be freed. | |
3775 | (muscle_entry_free): New private function. | |
3776 | (muscle_init): Use it instead of free. | |
3777 | (muscle_insert, muscle_grow): Update and use new storage member. | |
3778 | (muscle_code_grow): Free the string passed to muscle_grow | |
3779 | since it's not needed anymore. | |
3780 | * src/parse-gram.y (%union): Make `chars' member a `char const *', and | |
3781 | add a new `char *code' member. | |
3782 | ("{...}"): Declare semantic type as code. | |
3783 | * src/scan-code.h (translate_rule_action): | |
3784 | (translate_symbol_action, translate_code, translate_action): Return | |
3785 | `char const *' rather than `char *' since external code should not free | |
3786 | these strings. | |
3787 | * src/scan-code.l: Likewise. | |
3788 | * src/scan-gram.l (<SC_BRACED_CODE>): Use val->code for BRACED_CODE, | |
3789 | which is "{...}" in the parser. | |
3790 | * tests/Makefile.am (maintainer-check-valgrind): Set | |
3791 | VALGRIND_OPTS='--leak-check=full --show-reacheable=yes' before invoking | |
3792 | Valgrind. | |
3793 | * tests/calc.at (_AT_DATA_CALC_Y): fclose the FILE* so Valgrind doesn't | |
3794 | complain. | |
3795 | * tests/testsuite.at (AT_CHECK): Redefine so that running Bison and | |
3796 | expecting a non-zero exit status sets --leak-check=summary and | |
3797 | --show-reachable=no for Valgrind. Bison unabashedly leaks memory in | |
3798 | this case, and we don't want to hear about it. | |
3799 | ||
ac564be4 PE |
3800 | 2006-11-08 Paul Eggert <eggert@cs.ucla.edu> |
3801 | ||
3802 | * bootstrap (runtime-po/Makevars): Derive from po/Makevars | |
3803 | instead of from the template, to simplify configuration a bit. | |
3804 | * bootstrap.conf (excluded_files): Don't exclude m4/codeset.m4 | |
3805 | and m4/wint_t.m4, as they are needed with the latest gnulib. | |
3806 | ||
17bd8a73 JD |
3807 | 2006-10-31 Joel E. Denny <jdenny@ces.clemson.edu> |
3808 | ||
3809 | Disable unset/unused mid-rule value warnings by default, and recognize | |
3810 | --warnings=midrule-values to enable them. Discussed starting at | |
3811 | <http://lists.gnu.org/archive/html/help-bison/2006-10/msg00030.html>. | |
3812 | * NEWS (2.3a+): Mention. | |
3813 | * src/getargs.c, src/getargs.h (warnings_args, warnings_types, enum | |
3814 | warnings): Add entry for midrule-values subargument. | |
3815 | * src/reader.c (symbol_should_be_used): Don't return true just because | |
3816 | the value is a set/used mid-rule value unless | |
3817 | --warnings=midrule-values was specified. | |
3818 | * tests/input.at (Unused values, Unused values before symbol | |
3819 | declarations): Run tests with and without --warnings=midrule-values. | |
3820 | ||
3821 | * src/reader.c (check_and_convert_grammar): Use symbol_list_free rather | |
3822 | than LIST_FREE directly. | |
3823 | ||
89eb3c76 JD |
3824 | 2006-10-31 Joel E. Denny <jdenny@ces.clemson.edu> |
3825 | ||
3826 | Finish implementing --warnings=error, which should not be implied by | |
3827 | --warnings=all (or by its synonyms -W and --warnings without | |
3828 | subarguments). | |
3829 | * src/complain.c (set_warning_issued): New function to report that | |
3830 | warnings are being treated as errors and to record an error if so. | |
3831 | Invoke... | |
3832 | (warn_at, warn): ... here. | |
3833 | * src/getargs.c (warnings_args, warnings_types): Reorder so that | |
3834 | "error - warnings are errors" does not appear above "all - all of the | |
3835 | above". | |
3836 | (getargs): For -W and --warnings without subarguments, don't let | |
3837 | FLAGS_ARGMATCH set warnings_error in warnings_flag. | |
3838 | * src/getargs.h (enum warnings): Unset warnings_error in warnings_all. | |
3839 | ||
ba7560e2 JD |
3840 | 2006-10-31 Joel E. Denny <jdenny@ces.clemson.edu> |
3841 | ||
3842 | * src/getargs.c (flags_argmatch): Don't cause segmentation fault for | |
3843 | empty subargument list. For example: `bison --warnings= parser.y'. | |
3844 | ||
31283fc3 JD |
3845 | 2006-10-21 Joel E. Denny <jdenny@ces.clemson.edu> |
3846 | ||
3847 | * data/push.c, data/yacc.c: Make sure there's a newline at the end of | |
3848 | the parser header file so that gcc doesn't warn. | |
3849 | ||
12e35840 JD |
3850 | 2006-10-21 Joel E. Denny <jdenny@ces.clemson.edu> |
3851 | ||
3852 | Split the default %destructor/%printer into two kinds: <*> and <!>. | |
3853 | Discussed starting at | |
3854 | <http://lists.gnu.org/archive/html/bison-patches/2006-09/msg00060.html>. | |
3855 | * NEWS (2.3a+): Mention. | |
3856 | * doc/bison.texinfo (Freeing Discarded Symbols): Document this and the | |
3857 | previous change today related to mid-rules. | |
148d66d8 | 3858 | (Table of Symbols): Remove %symbol-default and add <*> and <!>. |
3ebecc24 | 3859 | * src/parse-gram.y (PERCENT_SYMBOL_DEFAULT): Remove. |
12e35840 JD |
3860 | (TYPE_TAG_ANY): Add as <*>. |
3861 | (TYPE_TAG_NONE): Add as <!>. | |
3862 | (generic_symlist_item): Remove RHS for %symbol-default and add RHS's | |
3863 | for <*> and <!>. | |
3864 | * src/scan-gram.l (PERCENT_SYMBOL_DEFAULT): Remove. | |
3865 | (TYPE_TAG_ANY, TYPE_TAG_NONE): Add. | |
3866 | * src/symlist.c (symbol_list_default_new): Split into tagged and | |
3867 | tagless versions. | |
3868 | (symbol_list_destructor_set, symbol_list_printer_set): Split | |
3869 | SYMLIST_DEFAULT case into SYMLIST_DEFAULT_TAGGED and | |
3870 | SYMLIST_DEFAULT_TAGLESS. | |
3871 | * src/symlist.h: Update symbol_list_default*_new prototypes. | |
3872 | (symbol_list.content_type): Split enum value SYMLIST_DEFAULT into | |
3873 | SYMLIST_DEFAULT_TAGGED and SYMLIST_DEFAULT_TAGLESS. | |
3874 | * src/symtab.c (default_destructor, default_destructor_location, | |
3875 | default_printer, default_printer_location): Split each into tagged and | |
3876 | tagless versions. | |
3877 | (symbol_destructor_get, symbol_destructor_location_get, | |
3878 | symbol_printer_get, symbol_printer_location_get): Implement tagged | |
3879 | default and tagless default cases. | |
3880 | (default_destructor_set, default_printer_set): Split each into tagged | |
3881 | and tagless versions. | |
3882 | * src/symtab.h: Update prototypes. | |
3883 | * tests/actions.at (Default %printer and %destructor): Rename to... | |
3884 | (Default tagless %printer and %destructor): ... this, and extend. | |
3885 | (Per-type %printer and %destructor): Rename to... | |
3886 | (Default tagged and per-type %printer and %destructor): ... this, and | |
3887 | extend. | |
3888 | (Default %printer and %destructor for user-defined end token): Extend. | |
3889 | (Default %printer and %destructor are not for error or $undefined): | |
3890 | Update. | |
3891 | (Default %printer and %destructor are not for $accept): Update. | |
3892 | (Default %printer and %destructor for mid-rule values): Extend. | |
3893 | * tests/input.at (Default %printer and %destructor redeclared): Extend. | |
3894 | (Unused values with default %destructor): Extend. | |
3895 | ||
f91b1629 JD |
3896 | 2006-10-21 Joel E. Denny <jdenny@ces.clemson.edu> |
3897 | ||
3898 | Don't apply the default %destructor/%printer to an unreferenced midrule | |
3899 | value. Mentioned at | |
3900 | <http://lists.gnu.org/archive/html/bison-patches/2006-09/msg00104.html>. | |
3901 | * src/symtab.c (dummy_symbol_get): Name all dummy symbols initially | |
3902 | like $@n instead of just @n so that the default %destructor/%printer | |
3903 | logic doesn't see them as user-defined symbols. | |
3904 | (symbol_is_dummy): Check for both forms of the name. | |
3905 | * src/reader.c (packgram): Remove the `$' from each midrule symbol | |
3906 | name for which the midrule value is referenced in any action. | |
3907 | * tests/actions.at (Default %printer and %destructor for mid-rule | |
3908 | values): New test. | |
3909 | * tests/regression.at (Rule Line Numbers, Web2c Report): Update output | |
3910 | for change to dummy symbol names. | |
3911 | ||
519d0004 JD |
3912 | 2006-10-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3913 | ||
3914 | Warn about unset midrule $$ if the corresponding $n is used. | |
3915 | * src/reader.c (symbol_should_be_used): Check midrule parent rule for | |
3916 | $n usage. | |
3917 | (packgram): Before invoking grammar_rule_check on any rule, make sure | |
3918 | all actions have already been scanned in order to set `used' flags. | |
3919 | Otherwise, checking that a midrule's $$ is set will not always work | |
3920 | properly because the midrule check must forward-reference the midrule's | |
3921 | parent rule. | |
3922 | * tests/input.at (AT_CHECK_UNUSED_VALUES): Extend to check the new | |
3923 | warning. | |
3924 | ||
a501eca9 JD |
3925 | 2006-10-20 Joel E. Denny <jdenny@ces.clemson.edu> |
3926 | ||
3927 | More improvements to the documentation of the prologue alternatives: | |
3928 | * NEWS (2.3a+): Mention the new `Prologue Alternatives' section in the | |
3929 | Bison manual. | |
3930 | * doc/bison.texinfo (Prologue Alternatives): Correct some errors. Add | |
3931 | some text to clarify the relative importance of the new directives and | |
3932 | to show how these directives may be viewed as code labels. | |
3933 | ||
2cbe6b7f JD |
3934 | 2006-10-16 Joel E. Denny <jdenny@ces.clemson.edu> |
3935 | ||
3936 | Similar to the recently removed %before-header, add %code-top as the | |
3937 | alternative to the pre-prologue. Mentioned at | |
3938 | <http://lists.gnu.org/archive/html/bison-patches/2006-10/msg00063.html>. | |
3939 | Also, let the prologue alternatives appear in the grammar section. | |
3940 | * src/parse-gram.y (PERCENT_CODE_TOP): New token. | |
3941 | (prologue_declaration): Move the existing prologue alternatives to... | |
3942 | (grammar_declaration): ... here and add %code-top. | |
3943 | * src/scan-gram.l (PERCENT_CODE_TOP): New token. | |
3944 | ||
3945 | Clean up and extend documentation for the prologue alternatives. | |
3946 | * NEWS (2.3a+): Describe prologue alternatives. | |
3947 | * doc/bison.texinfo (Prologue): Move discussion of prologue | |
3948 | alternatives to... | |
3949 | (Prologue Alternatives): ... this new section, and extend it to discuss | |
3950 | all 4 directives in detail. | |
148d66d8 JD |
3951 | (Table of Symbols): Clean up discussion of prologue alternatives and |
3952 | add %code-top. | |
2cbe6b7f | 3953 | |
e557d3ea JMG |
3954 | 2006-10-16 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
3955 | ||
3956 | DJGPP specific issues. | |
3957 | ||
3958 | * djgpp/config.bat: config.hin has been moved to lib. Adjust | |
3959 | config.bat accordingly. | |
3960 | * djgpp/config.sed: Adjust config.sed for the use of autoconf 2.60. | |
3961 | * djgpp/config.site: Likewise. | |
3962 | ||
136a0f76 PB |
3963 | 2006-10-16 Paolo Bonzini <bonzini@gnu.org> |
3964 | ||
27bd5d67 PB |
3965 | Replace %*-header with %provides, %requires, %code. See discussion at |
3966 | http://lists.gnu.org/archive/html/bison-patches/2006-10/msg00002.html | |
3967 | ||
136a0f76 PB |
3968 | * data/bison.m4 (b4_user_requires, b4_user_provides): New. |
3969 | (b4_user_start_header): Remove. | |
3970 | * data/glr.c: Use new macros instead of b4_*start_header | |
3971 | and b4_*end_header. | |
3972 | * data/glr.cc: Likewise. | |
3973 | * data/lalr1.cc: Likewise. | |
3974 | * data/push.c: Likewise. | |
3975 | * data/yacc.c: Likewise. | |
3976 | ||
3977 | * doc/bison.texinfo: Remove %before-header, rename | |
3978 | %{start,end,after}-header to %requires, %provides, %code. | |
3979 | ||
3980 | * src/parse-gram.y: Likewise (also rename token names accordingly). | |
3981 | * src/scan-gram.l: Likewise. | |
3982 | * tests/actions.at: Likewise. | |
3983 | ||
10f429ef PE |
3984 | 2006-10-14 Paul Eggert <eggert@cs.ucla.edu> |
3985 | ||
3986 | * lib/Makefile.am (AM_CFLAGS): Remove $(WERROR_CFLAGS). | |
3987 | Problem reported by Joel E. Denny. | |
3988 | ||
3989 | 2006-10-14 Jim Meyering <jim@meyering.net> | |
3990 | ||
3991 | (Sync from coreutils.) | |
3992 | Work also when the working directory (with e.g. coreutils sources) | |
3993 | is version controlled with git, rather than CVS. | |
3994 | * bootstrap (CVS_only_file): Test for the existence of README-cvs, | |
3995 | rather than CVS. | |
3996 | In messages and comments, say e.g., "checked-out sources", | |
3997 | rather than "CVS sources". | |
3998 | (version_controlled_file): New function. Work for git as well as | |
3999 | for CVS. Don't use grep's -q option. | |
4000 | (slurp): Call it here, in place of CVS-specific code. | |
4001 | ||
c4bd5bf7 JD |
4002 | 2006-10-14 Joel E. Denny <jdenny@ces.clemson.edu> |
4003 | ||
4004 | Fix testsuite for ./configure --enable-gcc-warnings: | |
4005 | * configure.ac (gcc-warnings): Move -Wall before -Wno-sign-compare. | |
4006 | Otherwise, gcc 4.1.0 (at least) warns about sign comparisons in | |
4007 | __AT_CHECK_PRINTER_AND_DESTRUCTOR in tests/actions.at. | |
4008 | * test/input.at (Torturing the Scanner): #include <stdlib.h> for abort. | |
4009 | * test/regression.at (Diagnostic that expects two alternatives): | |
4010 | Likewise. | |
4011 | ||
46356ea4 PE |
4012 | 2006-10-12 Paul Eggert <eggert@cs.ucla.edu> |
4013 | ||
231ed89a PE |
4014 | * bootstrap.conf (gnulib_modules): Add config-h. |
4015 | * djgpp/subpipe.c: Include <config.h> unconditionally; don't | |
4016 | worry about HAVE_CONFIG_H. | |
4017 | * lib/abitset.c: Likewise. | |
4018 | * lib/bitset.c: Likewise. | |
4019 | * lib/bitset_stats.c: Likewise. | |
4020 | * lib/bitsetv-print.c: Likewise. | |
4021 | * lib/bitsetv.c: Likewise. | |
4022 | * lib/ebitset.c: Likewise. | |
4023 | * lib/get-errno.c: Likewise. | |
4024 | * lib/lbitset.c: Likewise. | |
4025 | * lib/subpipe.c: Likewise. | |
4026 | * lib/timevar.c: Likewise. | |
4027 | * lib/vbitset.c: Likewise. | |
4028 | * lib/bitset.c: Include "bitset.h" first, to test interface. | |
4029 | * lib/bitset_stats.c: Include "bitset_stats.h" first. | |
4030 | * lib/bitsetv-print.c: Include "bitsetv-print.h" first. | |
4031 | * lib/bitsetv.c: Include "bitsetv.h" first. | |
4032 | * lib/get-errno.c: Include "get-errno.h" first. | |
4033 | * m4/.cvsignore: Add config-h.m4. | |
4034 | * tests/actions.at (Default %printer and %destructor for ...): | |
4035 | Adjust expected line numbers in output to reflect removal of #if | |
4036 | HAVE_CONFIG_H lines. | |
4037 | * tests/glr-regression.at (Missed %merge type warnings when ...): | |
4038 | Likewise. | |
4039 | * tests/regression.at (Braced code in declaration in rules section): | |
4040 | Likewise. | |
4041 | * tests/atlocal.in (CPPFLAGS): Don't define HAVE_CONFIG_H. | |
4042 | * tests/local.at (AT_DATA_GRAMMAR_PROLOGUE): | |
4043 | Include <config.h> unconditionally. | |
4044 | ||
46356ea4 PE |
4045 | * bootstrap: Sync from coreutils, as follows: |
4046 | ||
4047 | 2006-10-11 Paul Eggert <eggert@cs.ucla.edu> | |
4048 | ||
4049 | * bootstrap (symlink_to_gnulib): Fix bug: the dot_dots shell | |
4050 | variable was sometimes used without being initialized. This | |
4051 | messed up the installation of the INSTALL file in some cases. | |
4052 | ||
4053 | 2006-10-09 Paul Eggert <eggert@cs.ucla.edu> | |
4054 | ||
4055 | * bootstrap (usage, main program, symlink_to_gnulib): Add option | |
4056 | --copy. Inspired by a suggestion from Bruno Haible. | |
4057 | ||
4058 | 2006-10-03 Jim Meyering <jim@meyering.net> | |
4059 | ||
4060 | * bootstrap: Undo last change to this file, since now gnulib-tool | |
4061 | sticks with the automake default in generating dependencies. | |
4062 | ||
dd4bf078 PE |
4063 | 2006-10-12 Paul Eggert <eggert@cs.ucla.edu> |
4064 | ||
cf2a5f7c PE |
4065 | * configure.ac: Use AC_PROG_CC_STDC; this is more modern than |
4066 | the old AC_PROG_CC / AM_PROG_CC_STDC combination. | |
4067 | ||
4068 | * doc/bison.1: Add copyright notice. | |
4069 | ||
4070 | * data/glr.c: Don't include <stdarg.h>; not used. | |
4071 | ||
35fe0834 PE |
4072 | * NEWS: The -g and --graph options now output graphs in Graphviz |
4073 | DOT format, not VCG format. | |
4074 | * doc/bison.1: Likewise. | |
4075 | * doc/bison.texinfo (Understanding, Bison Options): Likewise. | |
fcab4a2e PE |
4076 | * THANKS: Add Satya Kiran Popuri, who proposed the initial version |
4077 | of this change in | |
4078 | <http://lists.gnu.org/archive/html/bison-patches/2006-09/msg00158.html>. | |
35fe0834 PE |
4079 | * TODO: Remove Graphviz entry. |
4080 | * src/Makefile.am (bison_SOURCES): Add graphviz.c and graphviz.h; | |
4081 | remove vcg.c, vcg.h, vcg_defaults.h. | |
4082 | * src/vcg.c, src/vcg.h, src/vcg_defaults.h: Remove. | |
4083 | * src/graphviz.c, src/graphviz.h: New files. | |
4084 | * src/files.c (compute_output_file_names): Output .dot, not .vcg. | |
4085 | * src/files.h: Make comment more generic. | |
4086 | * src/main.c (main): Likewise. | |
4087 | * src/print_graph.h: Likewise. | |
4088 | * src/getargs.c (usage): Make usage description more generic. | |
4089 | * src/print_graph.c: Include graphviz.h rather than vcg.h. | |
4090 | (static_graph, fgraph): Remove. All uses changed to pass | |
4091 | arguments instead of sharing a static var. | |
4092 | (print_core, print_actions, print_state, print_graph): | |
4093 | Output graphviz format rather than VCG format. | |
4094 | * tests/.cvsignore: Remove *.vcg; add *.dot. | |
4095 | * tests/output.at: Expect *.dot files, not *.vcg files. | |
4096 | ||
dd4bf078 PE |
4097 | * data/Makefile.am (dist_pkgdata_DATA): Add bison.m4; this |
4098 | accommodates the 2006-10-08 change. | |
4099 | ||
efdd7421 PE |
4100 | 2006-10-11 Bob Rossi <bob@brasko.net> |
4101 | ||
4102 | * data/push.c (yypushparse, yypvarsinit, yypvars): Wrap in b4_push_if. | |
4103 | (b4_yyssa, b4_yyerror_range): New macros. | |
4104 | (struct yypvars): Remove yyssa_ptr and yyerror_range_ptr fields. | |
4105 | (yypvarsinit): Remove init of removed fields. | |
4106 | (yypushparse): Remove use of removed fields; use new macros instead. | |
4107 | ||
96a1981a PE |
4108 | 2006-10-11 Paul Eggert <eggert@cs.ucla.edu> |
4109 | ||
4110 | * data/push.c (yypushparse): Fix memory leak if yymsg is malloced | |
4111 | in a push parser. Reindent slightly to match yacc.c better. | |
4112 | ||
4113 | 2006-10-11 Bob Rossi <bob@brasko.net> | |
4114 | ||
46356ea4 PE |
4115 | * data/push.c (struct yypvars): Remove yymsgbuf, yymsgbuf_ptr, yymsg, |
4116 | yymsg_alloc fields. | |
4117 | (yypvarsinit, yypushparse): Remove init of removed fields. | |
4118 | (yypushparse): Use yymsgbuf instead of yymsgbuf_ptr. | |
96a1981a | 4119 | |
c1630a8b PE |
4120 | 2006-10-09 Paul Eggert <eggert@cs.ucla.edu> |
4121 | ||
4122 | * THANKS: Add Paolo Bonzini and Bob Rossi. | |
4123 | ||
90b9908d PB |
4124 | 2006-10-08 Paolo Bonzini <bonzini@gnu.org> |
4125 | ||
4126 | * data/c.m4 (b4_copyright, b4_epilogue, b4_location_initial_column, | |
4127 | b4_location_initial_line, p4_parse_param, b4_ints_in, b4_flag_if, | |
4128 | b4_define_flag_if and uses, b4_basename, b4_syncline, b4_user_code, | |
4129 | b4_define_user_cde and uses): Remove. | |
4130 | (b4_comment, b4_prefix, b4_sync_start): New. | |
4131 | * data/bison.m4: New file, with most of the content removed from c.m4. | |
4132 | * src/muscle_tab.h: Use "do {...} while(0)" throughout. | |
4133 | * src/output.c (output_skeleton): Pass bison.m4. | |
4134 | (prepare): Pass glr_flag and nondeterministic_flag. Pass prefix | |
4135 | only if specified. | |
4136 | ||
cf806753 PE |
4137 | 2006-10-05 Paul Eggert <eggert@cs.ucla.edu> |
4138 | ||
4139 | Fix test failure reported by Tom Lane in | |
4140 | <http://lists.gnu.org/archive/html/bug-bison/2006-10/msg00000.html> | |
4141 | and try to make such failures easier to catch in the future. | |
4142 | * data/glr.c (YYTRANSLATE): Don't check for nonpositive arg; | |
4143 | that's now the caller's responsibility. | |
4144 | (yyprocessOneStack, yyrecoverSyntaxError, yyparse): | |
4145 | Set yychar = YYEOF if it's negative. | |
4146 | * tests/actions.at (yylex): Abort if asked to read past EOF. | |
4147 | * tests/conflicts.at (yylex): Likewise. | |
4148 | * tests/cxx-type.at (yylex): Likewise. | |
4149 | * tests/glr-regression.at (yylex): Likewise. | |
4150 | * tests/input.at (yylex): Likewise. | |
4151 | * tests/regression.at (yylex): Likewise. | |
4152 | * tests/torture.at (yylex): Likewise. | |
4153 | ||
0e2f006a PE |
4154 | 2006-10-01 Paul Eggert <eggert@cs.ucla.edu> |
4155 | ||
4156 | Fix problems with translating English-language diagnostics. | |
4157 | * bootstrap: Fix bug introduced in recent bootstrap changes, with | |
4158 | respect to bison-runtime pot generation. The YY_ stuff | |
4159 | wasn't being captured. | |
4160 | * bootstrap.conf (XGETTEXT_OPTIONS_RUNTIME): New var. | |
4161 | * po/POTFILES.in: Add src/location.c, src/scan-code.l. | |
4162 | * runtime-po/POTFILES.in: Add data/push.c. | |
4163 | ||
e3ddc1e3 PE |
4164 | 2006-09-29 Paul Eggert <eggert@cs.ucla.edu> |
4165 | ||
4166 | Merge bootstrap changes from coreutils. | |
4167 | ||
4168 | 2006-09-28 Jim Meyering <jim@meyering.net> | |
4169 | ||
4170 | Automatically generated dependencies are important even | |
4171 | when all of the sources in a directory come from gnulib. | |
4172 | * bootstrap (gnulib_tool): Remove the "no-dependencies" automake | |
4173 | option that gnulib-tool adds to what becomes our lib/gnulib.mk. | |
4174 | ||
4175 | 2006-09-23 Jim Meyering <jim@meyering.net> | |
4176 | ||
4177 | * bootstrap (gnulib_tool_options): Add "--local-dir gl". | |
4178 | ||
4179 | 2006-09-20 Paul Eggert <eggert@cs.ucla.edu> | |
4180 | ||
4181 | * bootstrap: Add support for --force. | |
4182 | (usage): New function. Describe usage less tersely. | |
4183 | (CVS_only_file): New var. | |
4184 | ||
01e972b3 PE |
4185 | 2006-09-21 Paul Eggert <eggert@cs.ucla.edu> |
4186 | ||
4187 | * data/push.c (YYPUSH_MORE): Make it an enum instead. | |
4188 | (yypushparse): Use YYPUSH_MORE instead of the mystery constant. | |
4189 | Adjust white space and comments to match GNU style better. | |
4190 | ||
c63d3e90 PE |
4191 | 2006-09-20 Bob Rossi <bob@brasko.net> |
4192 | ||
4193 | * data/push.c (yyresult_get): Remove function. | |
4194 | (YYPUSH_MORE): Add #define. | |
4195 | (yypushparse): Modify return value. | |
4196 | ||
e70f46d1 PE |
4197 | 2006-09-20 Paul Eggert <eggert@cs.ucla.edu> |
4198 | ||
4199 | * stamp-h.in: Remove; no longer needed. | |
4200 | * .cvsignore: Replace autom4te.cache and config.cache with *.cache. | |
4201 | Remove config.h, config.hin, intl (no longer created). | |
4202 | * lib/.cvsignore: Add config.h, config.hin, configmake.h, inttypes.h, | |
4203 | stamp-h1. | |
4204 | ||
4205 | Sync bootstrap from coreutils, as follows: | |
4206 | ||
4207 | 2006-09-18 Paul Eggert <eggert@cs.ucla.edu> | |
4208 | ||
4209 | * bootstrap (symlink_to_gnulib): New function. | |
4210 | (cp_mark_as_generated): Use it, to prefer symlinks-to-gnulib | |
4211 | to copies-of-gnulib. | |
4212 | (cp_mark_as_generated, slurp, gnulib_files): | |
4213 | Avoid making a copy if it's the same as the old version. | |
4214 | (gnulib_files): Add support for this variable (used by Bison). | |
4215 | ||
a92be413 PE |
4216 | 2006-09-20 Paul Eggert <eggert@cs.ucla.edu> |
4217 | ||
4218 | * src/getargs.c (usage): Rework to use conventions similar to | |
4219 | coreutils, to make translation a bit easier and the code a bit | |
4220 | smaller. Problem reported by Tim Van Holder. | |
4221 | ||
4f82b42a PE |
4222 | 2006-09-15 Paul Eggert <eggert@cs.ucla.edu> |
4223 | ||
3b2942e6 PE |
4224 | Use some of gnulib's new modules, taken from coreutils. |
4225 | ||
4226 | * bootstrap: Sync from coreutils, except add support for gnulib_files. | |
4227 | * bootstrap.conf: New file. | |
4228 | (gnulib_modules): Add configmake, inttypes, unistd. | |
4229 | (XGETTEXT_OPTIONS): Add complain, complain_at, | |
4230 | fatal, fatal_at, warn, warn_at, unexpected_end. | |
4231 | * configure.ac (AC_CONFIG_HEADERS): config.h is now in lib, not here. | |
4232 | (gl_USE_SYSTEM_EXTENSIONS): Remove; gl_EARLY now does this. | |
4233 | (gl_EARLY): Add. | |
4234 | (AM_STDBOOL_H): Remove; gl_INIT now dows this. | |
4235 | (gl_INIT): Add | |
4236 | (GNULIB_AUTOCONF_SNIPPET): Remove. | |
4237 | (AM_GNU_GETTEXT): Add; require formatstring macros since that's | |
4238 | the pickiest. | |
4239 | * lib/.cvsignore: Add inttypes_.h. | |
4240 | * lib/Makefile.am: Include gnulib.mk first so we can append to it. | |
4241 | (AM_CFLAGS): Add WERROR_CFLAGS, to be more like coreutils. | |
4242 | (BUILT_SOURCES, EXTRA_DIST, MOSTLYCLEANFILES): Remove | |
4243 | no-longer-necessary initializations. | |
4244 | (lib_SOURCES): Remove, replacing by libbison_a_SOURCES. | |
4245 | * lib/subpipe.c: Include <unistd.h> unconditionally, now that we | |
4246 | use the unistd module. | |
4247 | * src/system.h: Likewise. | |
4248 | * m4/.cvsignore: Remove *_gl.m4, gnulib.m4, inttypes_h.m4, uintmax_t.m4, | |
4249 | ulonglong.m4. Add gettext.m4, gnulib-cache.m4, gnulib-comp.m4, | |
4250 | gnulib-tool.m4, inttypes-h.m4, inttypes-pri.m4, inttypes.m4. | |
4251 | * src/Makefile.am (DEFS): Remove, since configmake does this for us. | |
4252 | (AM_CPPFLAGS): Remove -I../lib, since Automake does that for us. | |
4253 | * src/system.h: Include inttypes.h unconditionally, now that we | |
4254 | use the inttypes module. Don't bother to include stdint.h, since | |
4255 | inttypes.h now does that for us. | |
4256 | (LOCALEDIR): Remove, now that we use the configmake module. | |
4257 | * src/getargs.c: Include configmake.h. | |
4258 | * src/main.c: Likewise. | |
4259 | * src/output.c: Likewise. | |
4260 | * tests/atlocal.in (CPPFLAGS): Include from $abs_top_builddir/lib, | |
4261 | not from $abs_top_builddir, since config.h moved. | |
4262 | ||
4263 | ||
4f82b42a PE |
4264 | Port to GCC 2.95. First two problems reported by Michael Deutschmann in |
4265 | <http://lists.gnu.org/archive/html/bug-bison/2006-09/msg00018.html>. | |
4266 | ||
4267 | * src/parse-gram.y (symbol_declaration): Don't put statements | |
4268 | before declarations; it's not portable to C89. | |
4269 | * src/scan-code.l (handle_action_at): Likewise. | |
4270 | ||
4271 | * src/scan-code.l: Always initialize braces_level; the old code | |
4272 | left it uninitialized and therefore had undefined behavior. | |
4273 | ||
4274 | Don't attempt to redefine 'assert', since it runs afoul of | |
4275 | systems where standard headers (mistakenly) include <assert.h>. | |
4276 | Instead, define and use our own alternative, called 'aver'. | |
4277 | * src/reader.c: Don't include assert.h, since we no longer | |
4278 | use assert. | |
4279 | * src/scan-code.l: Likewise. | |
4280 | * src/system.h (assert): Remove, replacing with.... | |
4281 | (aver): New function, taking a bool arg. All uses changed. | |
4282 | * src/tables.c (pack_vector): Ensure that aver arg is bool, | |
4283 | not merely an integer. | |
4284 | ||
31c10e38 PE |
4285 | 2006-09-15 Bob Rossi <bob@brasko.net> |
4286 | ||
4287 | * data/Makefile.am (dist_pkgdata_DATA): Add push.c. | |
4288 | * data/c.m4 (YYPUSH): New. | |
4289 | (b4_push_if): New macro. Use it instead of #ifdef YYPUSH. | |
4290 | * src/getargs.c (push_parser): New var. | |
4291 | * src/getargs.h (push_parser): New declaration. | |
4292 | * src/output.c (prepare): Add macro insertion of `push_flag'. | |
4293 | * src/parse-gram.y (PERCENT_PUSH_PARSER): New token. | |
4294 | (prologue_declaration): Parse %push-parser. | |
4295 | * src/scan-gram.l: Scan new PERCENT_PUSH_PARSER token. | |
4296 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Add "Return" and "Now" to | |
4297 | list of removed lines from the traces observed. | |
4298 | (AT_CHECK_CALC_LALR): Added push parser tests. | |
4299 | ||
fa7b79c0 PE |
4300 | 2006-09-13 Paul Eggert <eggert@cs.ucla.edu> |
4301 | ||
21fe08ca PE |
4302 | * NEWS: Version 2.3a. |
4303 | * configure.ac (AC_INIT): Likewise. | |
4304 | ||
e8ec4d9b PE |
4305 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Remove |
4306 | "#define YYSTYPE int" that caused "make maintainer-check" to fail | |
4307 | due to header ordering dependencies. I don't know why the #define | |
4308 | was there. | |
4309 | ||
fa7b79c0 PE |
4310 | Fix glr.cc and lalr1.cc's use of YYDEBUG so that there's zero |
4311 | runtime cost when YYDEBUG is not defined, and so that some tests | |
4312 | that used to fail now work. Problem and initial suggestion by | |
4313 | Paolo Bonzini. | |
4314 | * data/c++.m4 (b4_parse_param_cons): Omit leading ','. | |
4315 | * data/glr.cc (b4_parser_class_name): | |
4316 | Initialize yycdebug_ only if YYDEBUG. Also, initialize yydebug_. | |
4317 | (debug_level, set_debug_level): Affect yydebug_, not ::yydebug. | |
4318 | (yydebug_) [YYDEBUG]: New member. | |
4319 | (yycdebug_): Now defined only if YYDEBUG. | |
4320 | * data/lalr1.cc (yydebug_, yycdebug_): Now defined only if YYDEBUG. | |
4321 | (YYCDEBUG) [!YYDEBUG]: Don't use yydebug_ and yycdebug_. | |
4322 | (b4_parser_class_name): Initialize yydebug_ and yycdebug_ only | |
4323 | if YYYDEBUG. | |
4324 | (debug_stream, set_debug_stream, debug_level, set_debug_level): | |
4325 | Define only if YYDEBUG. | |
4326 | * tests/calc.at (_AT_DATA_CALC_Y) [!YYDEBUG]: Omit call to | |
4327 | set_debug_level. | |
4328 | * tests/regression.at (_AT_DATA_DANCER_Y) [!YYDEBUG]: Likewise. | |
4329 | * tests/calc.at (AT_CHECK_CALC_GLR_CC): Uncomment calls to | |
4330 | AT_CHECK_CALC_GLR_CC that are working now. | |
4331 | ||
4ec13d60 PE |
4332 | 2006-09-12 Paul Eggert <eggert@cs.ucla.edu> |
4333 | ||
4334 | * data/glr.cc (YYERROR_VERBOSE, YYTOKEN_TABLE): Remove. | |
4335 | We don't need them in glr.cc, and glr.c defines them. | |
4336 | Defining YYERROR_VERBOSE to 0 here breaks glr.c, since glr.c | |
4337 | assumes that defining it to anything is the same as defining | |
4338 | it to 1. Problem reported by Paolo Bonzini. | |
4339 | ||
8e1687ae PE |
4340 | 2006-09-12 Paolo Bonzini <bonzini@gnu.org> (tiny change) |
4341 | ||
4342 | * data/c.m4 (b4_null, b4_case): Define. | |
4343 | * src/output.c (prepare_symbols): Use b4_null. | |
4344 | (user_actions_output): Use b4_case. | |
4345 | ||
3dc5e96b PE |
4346 | 2006-09-11 Paul Eggert <eggert@cs.ucla.edu> |
4347 | ||
aef3da86 PE |
4348 | * data/glr.c (b4_shared_declarations): Put start-header first, |
4349 | before any #includes that we generate, so that feature-test | |
4350 | macros work. Problem reported by Michael Deutschmann in | |
4351 | <http://lists.gnu.org/archive/html/bug-bison/2006-09/msg00004.html>. | |
4352 | * data/lalr1.cc: Likewise. | |
4353 | * doc/bison.texinfo (Prologue): Document that feature-test macros | |
4354 | should be defined before any Bison declarations. | |
4355 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Put defns | |
4356 | that depend on location.hh after, not before, Bison decls, since | |
4357 | we now include location.hh after the first user prologue. | |
4358 | ||
3dc5e96b PE |
4359 | * doc/bison.texinfo (Calc++ Parser): Fix memory leak reported by |
4360 | Sander Brandenburg in | |
4361 | <http://lists.gnu.org/archive/html/bug-bison/2006-09/msg00002.html>. | |
4362 | Also, fix minor white space and comment issues. | |
aef3da86 PE |
4363 | (Prologue): Mention that it's better to define feature-test macros |
4364 | before Bison declarations. Problem reported by Michael Deutschmann. | |
4365 | ||
4366 | * README-cvs: Fix typo: "&" should be "&&". Problem reported | |
4367 | by Jim Meyering. | |
4368 | * m4/.cvsignore: Add argmatch.m4. Remove obstack.m4, strerror_r.m4. | |
4369 | This adjusts to recent gnulib changes. | |
3dc5e96b | 4370 | |
b2a0b7ca JD |
4371 | 2006-09-04 Joel E. Denny <jdenny@ces.clemson.edu> |
4372 | ||
4373 | Finish implementation of per-type %destructor/%printer. Discussed | |
4374 | starting at | |
4375 | <http://lists.gnu.org/archive/html/bison-patches/2006-02/msg00064.html> | |
4376 | and | |
4377 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00091.html>. | |
4378 | * NEWS (2.3+): Add a description of this feature to the default | |
4379 | %destructor/%printer description. | |
4380 | * doc/bison.texinfo (Freeing Discarded Symbols): Likewise. | |
4381 | * src/symlist.c (symbol_list_destructor_set, symbol_list_printer_set): | |
4382 | Invoke semantic_type_destructor_set or semantic_type_printer_set when a | |
4383 | list node contains a semantic type. | |
4384 | * src/symtab.c, src/symtab.h: Extend with a table that associates | |
4385 | semantic types with their %destructor's and %printer's. | |
4386 | (semantic_type_from_uniqstr, semantic_type_get, | |
4387 | semantic_type_destructor_set, semantic_type_printer_set): New functions | |
4388 | composing the public interface of that table. | |
4389 | (symbol_destructor_get, symbol_destructor_location_get, | |
4390 | symbol_printer_get, symbol_printer_location_get): If there's no | |
4391 | per-symbol %destructor/%printer, look up the per-type before trying | |
4392 | the default. | |
4393 | * tests/actions.at (Per-type %printer and %destructor): New test case. | |
4394 | * tests/input.at (Default %printer and %destructor redeclared): | |
4395 | Extend to check that multiple occurrences of %symbol-default in a | |
4396 | single %destructor/%printer declaration is an error. | |
4397 | (Per-type %printer and %destructor redeclared, Unused values with | |
4398 | per-type %destructor): New test cases. | |
4399 | ||
3be03b13 JD |
4400 | 2006-09-04 Joel E. Denny <jdenny@ces.clemson.edu> |
4401 | ||
4402 | Require default %destructor/%printer to be declared using | |
4403 | %symbol-default instead of an empty symbol list, and start working on | |
4404 | new per-type %destructor/%printer. Discussed at | |
4405 | <http://lists.gnu.org/archive/html/bison-patches/2006-09/msg00007.html>. | |
4406 | * NEWS (2.3+): Add %symbol-default to example. | |
4407 | * bison.texinfo (Freeing Discarded Symbols): Likewise. | |
148d66d8 | 4408 | (Table of Symbols): Add entry for %symbol-default. |
3be03b13 JD |
4409 | * src/parse-gram.y (PERCENT_SYMBOL_DEFAULT): New token. |
4410 | (generic_symlist, generic_symlist_item): New nonterminals for creating | |
4411 | a list in which each item is a symbol, semantic type, or | |
4412 | %symbol-default. | |
4413 | (grammar_declaration): Use generic_symlist in %destructor and %printer | |
4414 | declarations instead of symbols.1 or an empty list. | |
4415 | (symbol_declaration, precedence_declaration, symbols.1): Update actions | |
4416 | for changes to symbol_list. | |
4417 | * src/reader.c: Update for changes to symbol_list. | |
4418 | * src/scan-code.l: Likewise. | |
4419 | * src/scan-gram.l: Scan new PERCENT_SYMBOL_DEFAULT token. | |
4420 | * src/symlist.c, src/symlist.h: Extend such that a list node may | |
4421 | represent a semantic type or a %symbol-default in addition to just an | |
4422 | ordinary symbol. Add switched functions for setting %destructor's and | |
4423 | %printer's. | |
4424 | * tests/actions.at, tests/input.at: Add %symbol-default to all default | |
4425 | %destructor/%printer declarations. | |
4426 | ||
3508ce36 JD |
4427 | 2006-08-23 Joel E. Denny <jdenny@ces.clemson.edu> |
4428 | ||
4429 | Whether the default %destructor/%printer applies to a particular symbol | |
4430 | isn't a question of whether the user *declares* that symbol (in %token, | |
4431 | for example). It's a question of whether the user by any means | |
4432 | *defines* the symbol at all (by simply using a char token, for | |
4433 | example). $end is defined by Bison whereas any other token with token | |
4434 | number 0 is defined by the user. The error token is always defined by | |
4435 | Bison regardless of whether the user declares it with %token, but we | |
4436 | may one day let the user define error as a nonterminal instead. | |
4437 | * NEWS (2.3+): Say "user-defined" instead of "user-declared". | |
4438 | * doc/bison.texinfo (Freeing Discarded Symbols): Likewise, and document | |
4439 | the meaning of "user-defined". | |
4440 | * tests/actions.at (Default %printer and %destructor for user-declared | |
4441 | end token): Rename to... | |
4442 | (Default %printer and %destructor for user-defined end token): ... | |
4443 | this. | |
4444 | ||
4445 | * src/symtab.c (symbol_destructor_get, symbol_printer_get): In the | |
4446 | computation of whether to apply the default, don't maintain a list of | |
4447 | every Bison-defined symbol. Instead, just check for a first character | |
4448 | of '$', which a user symbol cannot have, and check for the error token. | |
4449 | ||
9350499c JD |
4450 | 2006-08-21 Joel E. Denny <jdenny@ces.clemson.edu> |
4451 | ||
4452 | Don't apply the default %destructor or %printer to the error token, | |
4453 | $undefined, or $accept. This change fits the general rule that the | |
4454 | default %destructor and %printer are only for user-declared symbols, | |
4455 | and it solves several difficulties that are described in the new test | |
4456 | cases listed below. | |
4457 | * src/symtab.c (symbol_destructor_get, symbol_printer_get): Implement. | |
4458 | * tests/actions.at (Default %printer and %destructor are not for error | |
4459 | or $undefined, Default %printer and %destructor are not for $accept): | |
4460 | New test cases. | |
4461 | ||
4d7370cb JD |
4462 | 2006-08-19 Joel E. Denny <jdenny@ces.clemson.edu> |
4463 | ||
4464 | Allow %start after the first rule. | |
4465 | * src/reader.c (grammar_current_rule_begin): Don't set the start symbol | |
4466 | when parsing the first rule. | |
4467 | (check_and_convert_grammar): Search for it here after all grammar | |
4468 | declarations have been parsed. Skip midrules, which have dummy LHS | |
4469 | nonterminals. | |
4470 | * src/symtab.c (symbol_is_dummy): New function. | |
4471 | * src/symtab.h (symbol_is_dummy): Declare it. | |
4472 | * tests/input.at (%start after first rule): New test. | |
4473 | ||
6d0ef4ec JD |
4474 | 2006-08-18 Joel E. Denny <jdenny@ces.clemson.edu> |
4475 | ||
4476 | Redo some of the previous commit: add back the ability to use | |
4477 | non-aliased/undeclared string literals since it might be useful to | |
4478 | those declaring %token-table. | |
4479 | * src/reader.c (check_and_convert_grammar): Undo changes in previous | |
4480 | commit: don't worry about complaints from symbols_pack. | |
4481 | * src/symtab.c (symbol_new, symbol_class_set, | |
4482 | symbol_check_alias_consistency): Undo changes in previous commit: count | |
4483 | each string literal as a new symbol and token, assign it a symbol | |
4484 | number, and don't complain about non-aliased string literals. | |
4485 | (symbols_pack): Since symbol_make_alias still does not decrement symbol | |
4486 | and token counts but does still set aliased tokens to the same number, | |
4487 | symbol_pack_processor now leaves empty slots in the symbols array. | |
4488 | Remove those slots. | |
4489 | * tests/regression.at (Undeclared string literal): Remove test case | |
4490 | added in previous commit since non-aliased string literals are allowed | |
4491 | again. | |
4492 | (Characters Escapes, Web2c Actions): Undo changes in previous commit: | |
4493 | remove unnecessary string literal declarations. | |
4494 | * tests/sets.at (Firsts): Likewise. | |
4495 | ||
965537bc JD |
4496 | 2006-08-18 Joel E. Denny <jdenny@ces.clemson.edu> |
4497 | ||
4498 | Don't allow an undeclared string literal, but allow a string literal to | |
4499 | be used before its declaration. | |
4500 | * src/reader.c (check_and_convert_grammar): Don't invoke packgram if | |
4501 | symbols_pack complained. | |
4502 | * src/symtab.c (symbol_new): Don't count a string literal as a new | |
4503 | symbol. | |
4504 | (symbol_class_set): Don't count a string literal as a new token, and | |
4505 | don't assign it a symbol number since symbol_make_alias does that. | |
4506 | (symbol_make_alias): It's not necessary to decrement the symbol and | |
4507 | token counts anymore. Don't assume that an alias declaration occurs | |
4508 | before any uses of the identifier or string, and thus don't assert that | |
4509 | one of them has the highest symbol number so far. | |
4510 | (symbol_check_alias_consistency): Complain if there's a string literal | |
4511 | that wasn't declared as an alias. | |
4512 | (symbols_pack): Bail if symbol_check_alias_consistency failed since | |
4513 | symbol_pack asserts that every token has been assigned a symbol number | |
4514 | although undeclared string literals have not. | |
4515 | * tests/regression.at (String alias declared after use, Undeclared | |
6d0ef4ec | 4516 | string literal): New test cases. |
965537bc JD |
4517 | (Characters Escapes, Web2c Actions): Declare string literals as |
4518 | aliases. | |
4519 | * tests/sets.at (Firsts): Likewise. | |
4520 | ||
47aee066 JD |
4521 | 2006-08-14 Joel E. Denny <jdenny@ces.clemson.edu> |
4522 | ||
4523 | In the grammar scanner, STRING_FINISH unclosed constructs and return | |
4524 | them to the parser in order to improve error messages. | |
4525 | * src/scan-gram.l (SC_ESCAPED_STRING, SC_ESCAPED_CHARACTER, | |
4526 | SC_BRACED_CODE, SC_PROLOGUE): Implement. | |
4527 | * tests/input.at (Unclosed constructs): New test case. | |
4528 | * tests/regression.at (Invalid inputs): Update now that unclosed %{ is | |
4529 | seen. | |
4530 | ||
4531 | * src/scan-gram.h, src/scan-gram.l (gram_last_braced_code_loc): Remove | |
4532 | unused global. | |
4533 | ||
1f6b3679 JD |
4534 | 2006-08-13 Joel E. Denny <jdenny@ces.clemson.edu> |
4535 | ||
4536 | Handle string aliases for character tokens correctly. | |
4537 | * src/symtab.c (symbol_user_token_number_set): If the token has an | |
4538 | alias, check and set its alias's user token number instead of its own, | |
4539 | which is set to indicate the alias. Previously, every occurrence of | |
4540 | the character token in the grammar overwrote that alias indicator with | |
4541 | the character code. | |
4542 | * tests/input.at (String aliases for character tokens): New test. | |
4543 | ||
219741d8 JD |
4544 | 2006-08-12 Joel E. Denny <jdenny@ces.clemson.edu> |
4545 | ||
4546 | * src/parse-gram.y: Add `%expect 0' so we don't overlook conflicts. | |
4547 | ||
11daa4e7 PE |
4548 | 2006-08-11 Paul Eggert <eggert@cs.ucla.edu> |
4549 | ||
4550 | * bootstrap: Put in need-ngettext argument to AM_GNU_GETTEXT, | |
4551 | to prevent failures when building on older platforms. | |
4552 | Check for autopoint failure. | |
4553 | Set XGETTEXT_OPTIONS to values that check for C format strings, | |
4554 | so that translators are warned about them (this also helps | |
4555 | prevent core dumps). | |
4556 | ||
4557 | * lib/subpipe.c (create_subpipe): Use new gnulib pipe_safer | |
4558 | function, since it simplifies our code a bit. | |
4559 | ||
4560 | * configure.ac (AC_ARG_ENABLE): Use -Wextra -Wno-sign-compare | |
4561 | rather than -W, so we don't get bogus warnings about sign comparisons. | |
4562 | Add -Wpointer-arith, since that warning is useful (it reports code | |
4563 | that does not conform to C89 and that some compilers reject). | |
4564 | * data/c.m4, data/glr.c, data/lalr1.cc, data/yacc.c: Undo latest change, | |
4565 | since it's no longer needed. | |
4566 | ||
f9bfc42a JD |
4567 | 2006-08-10 Joel E. Denny <jdenny@ces.clemson.edu> |
4568 | ||
4569 | Clean up scanners a bit. | |
4570 | * src/flex-scanner.h (FLEX_NO_OBSTACK): New macro that blocks obstack | |
4571 | definitions so gcc won't warn when obstack_for_string is unused. | |
4572 | * src/scan-code.l: config.h and system.h are already #include'd by | |
4573 | scan-code-c.c, so get rid of them here. | |
4574 | * src/scan-gram.l: Likewise. | |
4575 | * src/scan-skel.l: Likewise, and use flex-scanner.h without obstack | |
4576 | definitions rather than duplicating the rest of it. | |
4577 | * src/scan-gram-c.c, scan-skel-c.c: #include "system.h". | |
4578 | ||
06e8700a JD |
4579 | 2006-08-09 Joel E. Denny <jdenny@ces.clemson.edu> |
4580 | ||
4581 | Suppress signed/unsigned comparison warnings for yycheck. | |
4582 | * data/c.m4 (b4_safest_int_type): New macro. | |
4583 | * data/glr.c, data/lalr1.cc: Wherever you compare yycheck[i] against | |
4584 | a signed int type, cast it to b4_safest_int_type first. | |
4585 | * data/yacc.c: Likewise. | |
4586 | (b4_safest_int_type): Overwrite the one from c.m4 since b4_int_type is | |
4587 | also overwritten. | |
4588 | ||
9c437126 PE |
4589 | 2006-08-09 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> (tiny change) |
4590 | ||
4591 | * doc/bison.texinfo: Fix some typos. | |
4592 | ||
284d8a13 PE |
4593 | 2006-08-02 Paul Eggert <eggert@cs.ucla.edu> |
4594 | ||
4595 | * m4/.cvsignore: Add inttypes_h.m4,lib-ld.m4, lib-prefix.m4, | |
4596 | po.m4, stdint_h.m4, uintmax_t.m4, ulonglong.m4, warning.m4. | |
4597 | ||
4598 | * bootstrap (gnulib_tool): Stop using --assume-autoconf; | |
4599 | the latest gnulib does this a different way. | |
4600 | (get_translations): Sharuzzaman Ahmat Raslan reported that the ms | |
4601 | translation was patched, so stop omitting it. | |
4602 | ||
ec5479ce JD |
4603 | 2006-07-29 Joel E. Denny <jdenny@ces.clemson.edu> |
4604 | ||
4605 | Enable declaration of default %printer/%destructor. Make the parser | |
4606 | use these for all user-declared grammar symbols for which the user does | |
4607 | not declare a specific %printer/%destructor. Thus, the parser uses it | |
4608 | for token 0 if the user declares it but not if Bison generates it as | |
4609 | $end. Discussed starting at | |
4610 | <http://lists.gnu.org/archive/html/bison-patches/2006-02/msg00064.html>, | |
4611 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00091.html>, | |
4612 | and | |
4613 | <http://lists.gnu.org/archive/html/bison-patches/2006-07/msg00019.html>. | |
4614 | * NEWS (2.3+): Mention. | |
4615 | * doc/bison.texinfo (Actions in Mid-Rule): It's no longer impossible to | |
4616 | declare a %destructor for a mid-rule's semantic value. It's just | |
4617 | impossible to declare one specific to it. | |
4618 | (Freeing Discarded Symbols): Mention that @$ can be used in %destructor | |
4619 | code. Describe default %destructor form. | |
4620 | * src/parse-gram.y (grammar_declaration): Parse default | |
4621 | %printer/%destructor declarations. | |
4622 | * src/output.c (symbol_destructors_output): Use symbol_destructor_get | |
4623 | and symbol_destructor_location_get rather than accessing the destructor | |
4624 | and destructor_location members of struct symbol. | |
4625 | (symbol_printers_output): Likewise but for %printer's. | |
4626 | * src/reader.c (symbol_should_be_used): Likewise but for %destructor's | |
4627 | again. | |
4628 | * src/symtab.c (default_destructor, default_destructor_location, | |
4629 | default_printer, default_printer_location): New static global | |
4630 | variables to record the default %destructor and %printer. | |
4631 | (symbol_destructor_get, symbol_destructor_location_get, | |
4632 | symbol_printer_get, symbol_printer_location_get): New functions to | |
4633 | compute the appropriate %destructor and %printer for a symbol. | |
4634 | (default_destructor_set, default_printer_set): New functions to set the | |
4635 | default %destructor and %printer. | |
4636 | * src/symtab.h: Prototype all those new functions. | |
4637 | * tests/actions.at (Default %printer and %destructor): New test to | |
4638 | check that the right %printer and %destructor are called, that they're | |
4639 | not called for $end, and that $$ and @$ work correctly. | |
4640 | (Default %printer and %destructor for user-declared end token): New | |
4641 | test to check that the default %printer and %destructor are called for | |
4642 | a user-declared end token. | |
4643 | * tests/input.at (Default %printer and %destructor redeclared, Unused | |
4644 | values with default %destructor): New tests to check related grammar | |
4645 | warnings and errors. | |
4646 | ||
868d2d96 JD |
4647 | 2006-07-29 Joel E. Denny <jdenny@ces.clemson.edu> |
4648 | ||
4649 | Clean up handling of %destructor for the end token (token 0). | |
4650 | Discussed starting at | |
4651 | <http://lists.gnu.org/archive/html/bison-patches/2006-07/msg00019.html> | |
4652 | and | |
4653 | <http://lists.gnu.org/archive/html/help-bison/2006-07/msg00013.html>. | |
4654 | ||
4655 | Make the skeletons consistent in how they pop the end token and invoke | |
4656 | its %destructor. | |
4657 | * data/glr.c (yyrecoverSyntaxError, yyparse): Don't pop the start | |
4658 | state, which has token number 0, since this would invoke the | |
4659 | %destructor for the end token. | |
4660 | * data/lalr1.cc (yy::parser::parse): Don't check for the final state | |
4661 | until after shifting the end token, or else it won't be popped. | |
4662 | * data/yacc.c (yyparse): Likewise. | |
4663 | ||
4664 | * data/glr.c (yyparse): Clear the lookahead after shifting it even when | |
4665 | it's the end token. Upon termination, destroy an unshifted lookahead | |
4666 | even when it's the end token. | |
4667 | * data/lalr1.cc (yy::parser::parse): Likewise. | |
4668 | * data/yacc.c (yyparse): Likewise. | |
4669 | ||
4670 | * src/reader.c (packgram): Don't check rule 0. This suppresses unused | |
4671 | value warnings for the end token when the user gives the end token a | |
4672 | %destructor. | |
4673 | ||
4674 | * tests/actions.at (Printers and Destructors): Test all the above. | |
4675 | ||
62a9592d PE |
4676 | 2006-07-24 Paul Eggert <eggert@cs.ucla.edu> |
4677 | ||
4678 | Update to latest gnulib and gettext versions. | |
4679 | * bootstrap (gnulib-modules): Remove hard-locale, stdio-safer. | |
4680 | Add fopen-safer. | |
4681 | (gnulib_files): Add m4/warning.m4. Don't worry about files | |
4682 | overwritten by autopoint. | |
4683 | Replace gt_INTL_SUBDIR_CORE with an empty body in m4/gettext_gl.m4. | |
4684 | Suppress "id", "ms", "tr" translations for now, since gettext 0.15 | |
4685 | rejects them. | |
4686 | Don't use autoreconf; instead, invoke autopoint etc. by hand, | |
4687 | so that we can remove the intl files at a better time. | |
4688 | (intl_files_to_remove): Remove aclocal.m4, since it gets | |
4689 | rebuilt anyway. Remove m4/inttypes_h.m4, m4/inttypes.m4, | |
4690 | m4/isc-posix.m4, m4/lib-ld.m4, m4/lib-prefix.m4, m4/po.m4, | |
4691 | m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4. | |
4692 | Add m4/inttypes-h.m4, m4/lock.m4, m4/visibility.m4. | |
4693 | Remove datarootdir hack; no longer needed. | |
4694 | * configure.ac: Use gl_WARNING_CFLAGS rather than BISON_WARNING. | |
4695 | (AM_GNU_GETTEXT_VERSION): Bump from 0.12 to 0.15. | |
4696 | * lib/.cvsignore: Remove hard-locale.c, hard-locale.h, strdup.c, | |
4697 | strdup.h. | |
4698 | * m4/.cvsignore: Remove hard-locale.m4, strdup.m4. | |
4699 | * m4/warning.m4: Remove from CVS, since we now use gnulib's version. | |
4700 | ||
10d6970f PE |
4701 | 2006-07-20 Paul Eggert <eggert@cs.ucla.edu> |
4702 | ||
4703 | * bootstrap: Adjust to today's change to gnulib-tool by invoking | |
4704 | it with --assume-autoconf='latest-stable'. | |
4705 | ||
50a33993 JD |
4706 | 2006-07-13 Joel E. Denny <jdenny@ces.clemson.edu> |
4707 | ||
4708 | * src/parse-gram.y (grammar_declaration): Don't confuse Doxygen (at | |
4709 | least 1.4.7 and 1.4.4) by putting a #line between `typedef union | |
4710 | YYSTYPE' and `{'. | |
4711 | * src/muscle_tab.h (muscle_grow): Replace the header comments with | |
4712 | those from muscle_tab.c since the old ones are misleading. | |
4713 | ||
2ce4ed68 AD |
4714 | 2006-07-13 Akim Demaille <akim@epita.fr> |
4715 | ||
4716 | Support %define "KEY" {VALUE}. | |
4717 | * src/scan-code.h, src/scan-code.l (translate_action) | |
4718 | (translate_rule_action, translate_symbol_action, translate_code): | |
4719 | Return char *, not const char *. | |
4720 | * src/parse-gram.y (declaration): Rename as... | |
4721 | (prologue_declaration): this. | |
4722 | (string_content): Remove this nonterminal, use STRING. | |
4723 | (braceless, content, content.opt): New nonterminal. | |
4724 | Use them. | |
4725 | (%define): Now accept content.opt, i.e., accept also BRACED_CODE | |
4726 | as value. | |
4727 | * src/scan-gram.l (getargs.h): Don't include it. | |
4728 | ||
db7e5eb5 PE |
4729 | 2006-07-12 Paul Eggert <eggert@cs.ucla.edu> |
4730 | ||
4731 | * data/lalr1.cc (YYCDEBUG): Use 'if (yydebug_) (*yycdebug_)' | |
4732 | rather than a for-loop that declares a local bool variable. This | |
4733 | should work around a compatibility problem with a Cray x1e C++ | |
4734 | compiler reported by Hung Nguyen in | |
4735 | <http://lists.gnu.org/archive/html/help-bison/2006-07/msg00022.html>. | |
4736 | The for-loop was introduced in the 2004-11-17 change but I don't | |
4737 | know why it was needed. | |
4738 | ||
a5d80ba5 AD |
4739 | 2006-07-12 Akim Demaille <akim@epita.fr> |
4740 | ||
4741 | * data/c.m4: Comment changes. | |
4742 | ||
23eb2a69 AD |
4743 | 2006-07-10 Akim Demaille <akim@lrde.epita.fr> |
4744 | ||
4745 | * src/complain.c (error_message, ERROR_MESSAGE): New. | |
4746 | To factor... | |
4747 | (fatal_at, fatal, warn_at, warn, complain_at, complain): these. | |
4748 | * src/complain.h, src/complain.c (warning_issued): Remove, unused. | |
4749 | ||
ddc8ede1 PE |
4750 | 2006-07-09 Paul Eggert <eggert@cs.ucla.edu> |
4751 | ||
4752 | * NEWS: Instead of %union, you can define and use your own union type | |
4753 | YYSTYPE if your grammar contains at least one <type> tag. | |
4754 | Your YYSTYPE need not be a macro; it can be a typedef. | |
4755 | * doc/bison.texinfo (Value Type, Multiple Types, Location Type): | |
4756 | (Union Decl, Decl Summary): Document this. | |
4757 | * data/glr.c (YYSTYPE): Implement this. | |
4758 | * data/glr.cc (YYSTYPE): Likewise. | |
4759 | * data/lalr1.cc (YYSTYPE): Likewise. | |
4760 | * data/yacc.c (YYSTYPE): Likewise. | |
4761 | * src/output.c (prepare): Output tag_seen_flag. | |
4762 | * src/parse-gram.y (declaration, grammar_declaration): | |
4763 | Use 'union_seen' rather than 'typed' to determine whether | |
4764 | %union has been seen, since grammars can now be typed without | |
4765 | %union. | |
4766 | (symbol_declaration, type.opt, symbol_def): | |
4767 | Keep track of whether a tag has been seen. | |
4768 | * src/reader.c (union_seen, tag_seen): New vars. | |
4769 | (typed): remove. | |
4770 | * src/reader.h (union_seen, tag_seen, typed): Likewise. | |
4771 | * src/scan-code.l (untyped_var_seen): New variable. | |
4772 | (handle_action_dollar): Adjust to above changes. | |
4773 | (handle_action_dollar, handle_action_at): | |
4774 | Improve overflow checking for outlandish numbers. | |
4775 | * tests/input.at (AT_CHECK_UNUSED_VALUES): Redo test to | |
4776 | avoid new diagnostics generated by above changes. | |
4777 | * tests/regression.at (YYSTYPE typedef): Add test to check | |
4778 | for type tags without %union. | |
4779 | ||
4780 | * src/symlist.c (symbol_list_length): Return int, not unsigned | |
4781 | int, since callers expect int. This may need to get revisited | |
4782 | once we have proper integer overflow checking. | |
4783 | ||
4784 | * src/scan-gram.h (gram_scanner_cursor): Remove decl, since this | |
4785 | object is now static. | |
4786 | ||
4787 | * src/getargs.c (flags_argmatch): Return void, not int, | |
4788 | to pacify ./configure --enable-gcc-warnings. | |
4789 | ||
4790 | * src/flex-scanner.h (STRING_FREE): Don't use FLEX_PREFIX (last_string) | |
4791 | since last_string is already defined to FLEX_PREFIX (last_string). | |
4792 | ||
7b42569e AD |
4793 | 2006-07-09 Akim Demaille <akim@lrde.epita.fr> |
4794 | ||
4795 | Implement --warnings/-W. | |
4796 | * src/getargs.c (report_argmatch, trace_argmatch): Remove, | |
4797 | replaced by... | |
4798 | (flags_argmatch, FLAGS_ARGMATCH): this new function and macro. | |
4799 | Adjust callers. | |
4800 | * src/getargs.h, src/getargs.c (warnings, warnings_flags) | |
4801 | (warnings_args, warnings_types): New. | |
4802 | (getargs, short_options, long_options): Accept -W/--warnings. | |
4803 | Sort the options by alphabetical order, upper case letter right | |
4804 | before its lower case. | |
4805 | ||
3b452f4e JD |
4806 | 2006-07-09 Joel E. Denny <jdenny@ces.clemson.edu> |
4807 | ||
4808 | Change %merge result type clash warnings to errors. Discussed at | |
4809 | <http://lists.gnu.org/archive/html/bison-patches/2006-07/msg00026.html>. | |
4810 | * src/reader.c (record_merge_function_type): Use complain_at. | |
4811 | * tests/glr-regression.at (Missed %merge type warnings when LHS type is | |
4812 | declared later): Update test case results. | |
4813 | ||
b8a41559 AD |
4814 | 2006-07-09 Akim Demaille <akim@lrde.epita.fr> |
4815 | ||
4816 | * src/getargs.h, src/getargs.c: Swap --report and --trace handling | |
4817 | to be in alphabetical order. | |
4818 | (trace_args): Spelling fixes. | |
4819 | ||
cd9e1ba2 PE |
4820 | 2006-07-09 Paul Eggert <eggert@cs.ucla.edu> |
4821 | ||
4822 | * data/yacc.c (YYID, yy_stack_print): Prefix local vars with "yy" | |
4823 | so they don't collide with user-defined macros. | |
4824 | (yy_stack_print): Don't assume that yytype_int16 promotes to int; | |
4825 | this was never guaranteed, and now that we're using gnulib stdint, | |
4826 | which defines int_fast16_t to long int, the problem is exposed. | |
4827 | ||
cb48f191 PE |
4828 | 2006-07-08 Paul Eggert <eggert@cs.ucla.edu> |
4829 | ||
b8445a15 PE |
4830 | * data/c.m4 (b4_basename): Simplify a bit, since we don't |
4831 | need the full POSIX semantics (and weren't implementing them | |
4832 | anyway). | |
4833 | ||
cb48f191 PE |
4834 | Adjust to Autoconf 2.60 and today's gnulib. |
4835 | * bootstrap (gnulib_modules): Add stdint. | |
4836 | Remove special case for m4/onceonly_2_57.m4, since gnulib-tool | |
4837 | no longer copies it. | |
4838 | (intl_files_to_remove): Remove m4/longlong.m4 and m4/wchar_t.m4, | |
4839 | since stdint needs the former and wcwidth (which is now required | |
4840 | by mbswidth) needs the latter. | |
4841 | Append 'datarootdir = @datarootdir@' to po/Makefile.in.in, to | |
4842 | work around a compatibility glitch between gettext 0.14.6 and | |
4843 | Autoconf 2.60. | |
4844 | * configure.ac (AC_PREREQ): Require Autoconf 2.60. | |
4845 | Do not check for uintptr_t, since new stdint module does the right | |
4846 | thing. | |
4847 | * lib/.cvsignore: Remove alloca.c, alloca.h, alloca_.h. | |
4848 | Add stdint.h, stdint_.h, wcwidth.h. | |
4849 | * m4/.cvsignore: Remove alloca.m4, onceonly.m4. | |
4850 | Add absolute-header.m4, double-slash-root.m4, longlong.m4, | |
4851 | stdint.m4, wchar_t.m4, wcwidth.m4. | |
4852 | * src/files.c: Include <dirname.h> and <stdio-safer.h> in the | |
4853 | usual order for ../lib/*.h files. | |
4854 | (file_name_split): Use last_component, not base_name, to adjust | |
4855 | to gnulib changes. | |
4856 | * src/parse-gram.h: Include <strverscmp.h> in the usual order | |
4857 | for ../lib/*.h files. | |
4858 | (YYTYPE_INT16, YYTYPE_INT8, YYTYPE_UINT16, YYTYPE_UINT8): | |
4859 | Define unconditionally, since we now assume the stdint module. | |
4860 | * src/scan-skel.l: Include <dirname.h>. | |
4861 | (BASE_QPUTS): Use last_component, not base_name. | |
4862 | * src/system.h: Include <unlocked-io.h> in the usual order | |
4863 | for ../lib/*.h files. Include <stdint.h> unconditionally, | |
4864 | since we now use the stdint module. | |
4865 | (uintptr_t): Declare if UINTPTR_MAX is not defined, not | |
4866 | HAVE_UINTPTR_T, since we now use the stdint module. | |
4867 | (base_name): Remove decl, since files now include <dirname.h> | |
4868 | to get the decl. | |
4869 | ||
cd48d21d AD |
4870 | 2006-07-08 Akim Demaille <akim@lrde.epita.fr> |
4871 | ||
4872 | * data/c.m4 (b4_location_initial_column, b4_location_initial_line): | |
4873 | New, default to 1. | |
4874 | * data/yacc.c, data/glr.c, data/location.cc: Use them. | |
4875 | * NEWS, doc/bison.texinfo: The initial column and line are 1 by | |
4876 | default. | |
4877 | * tests/calc.at: Adjust. | |
4878 | ||
8ec0a172 AD |
4879 | 2006-07-08 Akim Demaille <akim@lrde.epita.fr> |
4880 | ||
b8445a15 | 4881 | * data/c.m4 (b4_basename): New. |
8ec0a172 AD |
4882 | (b4_syncline): Also output the location of its invocation (from |
4883 | the skeleton). | |
4884 | (b4_user_action, b4_define_user_action, b4_user_actions) | |
4885 | (b4_user_initial_action, b4_user_post_prologue, b4_user_start_header) | |
4886 | (b4_user_stype): New. | |
4887 | * data/yacc.c, data/glr.c, data/lalr1.cc, data/glr.cc: Use them. | |
4888 | ||
4a678af8 JD |
4889 | 2006-07-07 Joel E. Denny <jdenny@ces.clemson.edu> |
4890 | ||
4891 | In the grammar file, the first column is 1 not 0 on the first line as | |
4892 | on every other line. | |
4893 | * src/parse-gram.y (%initial-action): Initialize @$ correctly. | |
4894 | * tests/input.at (Torturing the Scanner): Update output. | |
4895 | ||
4896 | * src/scan-gram.l (scanner_cursor): Declare it static. | |
4897 | ||
dd60572a JD |
4898 | 2006-07-07 Joel E. Denny <jdenny@ces.clemson.edu> |
4899 | ||
4900 | In warnings, say "previous declaration" rather than "first | |
4901 | declaration". | |
4902 | * src/symtab.c (redeclaration): Do that here. | |
4903 | * src/reader.c (record_merge_function_type): In the case of a result | |
4904 | type clash, report the previous declaration rather than the very first | |
4905 | one in the grammar file. | |
4906 | * tests/glr-regression.at (Missed %merge type warnings when LHS type is | |
4907 | declared later): Add a third declaration to check this behavior. | |
4908 | * tests/input.at (Incompatible Aliases): Update output. | |
4909 | ||
2073e1b6 AD |
4910 | 2006-06-27 Akim Demaille <akim@epita.fr> |
4911 | ||
4912 | * doc/Doxyfile.in: New. | |
4913 | * doc/Makefile.am: Use it. | |
4914 | * src/lalr.h, src/symtab.h: Initial doxygenation. | |
4915 | ||
8ee5b538 JD |
4916 | 2006-06-26 Joel E. Denny <jdenny@ces.clemson.edu> |
4917 | ||
4918 | Don't miss %merge result type warnings just because the LHS types are | |
fab044e6 JD |
4919 | declared after the %merge. This continues the effort of the previous |
4920 | patch. | |
8ee5b538 JD |
4921 | * src/reader.c (get_merge_function): Don't set the merger type yet. |
4922 | (record_merge_function_type): New function for setting the merger type | |
4923 | and checking for clashes. | |
4924 | (grammar_current_rule_merge_set): Set the location of the %merge for | |
4925 | the current rule. | |
4926 | (packgram): Invoke record_merge_function_type for each rule now that | |
4927 | all symbol type declarations have been parsed. | |
4928 | * src/reader.h (merger_list.type_declaration_location): New member | |
4929 | storing the location of the first %merge from which the type for this | |
4930 | merging function was derived. | |
4931 | * src/symlist.h (symbol_list.merger_declaration_location): New member | |
4932 | storing the location of a rule's %merge, if any. | |
4933 | * tests/glr-regression.at (Missed %merge type warnings when LHS type is | |
4934 | declared later): New test to catch the error fixed by the above patch. | |
4935 | ||
ffa4ba3a JD |
4936 | 2006-06-26 Joel E. Denny <jdenny@ces.clemson.edu> |
4937 | ||
4938 | Get action warnings (grammar_rule_check) right even when symbol | |
fab044e6 JD |
4939 | declarations appear after the rules. Discussed at |
4940 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00108.html> | |
4941 | and | |
4942 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00151.html>. | |
4943 | Don't mistake the type of $$ in a midrule to be that of its parent | |
4944 | rule's $$. | |
ffa4ba3a JD |
4945 | * src/reader.c (grammar_current_rule_end): Don't invoke |
4946 | grammar_rule_check yet since not all symbol declarations may have been | |
4947 | parsed yet. | |
4948 | (grammar_midrule_action): Likewise. | |
4949 | Don't record whether the midrule's $$ has been used yet since actions | |
4950 | haven't been translated yet. | |
4951 | Record the midrule's parent rule and its RHS index within the parent | |
4952 | rule. | |
4953 | (grammar_current_rule_action_append): Don't translate the action yet | |
4954 | since not all symbol declarations may have been parsed yet and, thus, | |
4955 | warnings about types for $$, $n, @$, and @n can't be reported yet. | |
4956 | (packgram): Translate the action and invoke grammar_rule_check now that | |
4957 | all symbol declarations have been parsed. | |
4958 | * src/scan-code.l (handle_action_dollar): Now that this is invoked | |
4959 | after parsing the entire grammar file, the symbol list here in the case | |
4960 | of a midrule is actually the midrule's empty RHS, so reference its | |
4961 | parent rule's RHS where necessary. | |
4962 | On the other hand, now that you can already know it's a midrule, you | |
4963 | aren't forced to think $$ has the same type as its parent rule's $$. | |
4964 | (handle_action_at): In the case of a midrule, reference the parent rule | |
4965 | where necessary. | |
4966 | * src/symlist.c (symbol_list_new): Initialize new midrule-related | |
4967 | members. | |
4968 | (symbol_list_length): Now that this is invoked after all rules have | |
4969 | been parsed, a NULL symbol (rather than a NULL symbol list node) | |
4970 | terminates a rule. symbol_list_print already does this correctly. | |
4971 | * src/symlist.h (symbol_list.midrule_parent_rule, | |
4972 | symbol_list.midrule_parent_rhs_index): New members so that midrules can | |
4973 | remember their relationships with their parents. | |
4974 | * tests/input.at (Type Clashes): Extend to catch the midrule $$ error | |
4975 | fixed by the above patch. | |
4976 | (_AT_UNUSED_VALUES_DECLARATIONS, AT_CHECK_UNUSED_VALUES): New m4 macros | |
4977 | implementing... | |
4978 | (Unused values): ... this old test case and... | |
4979 | (Unused values before symbol declarations): ... this new test case. | |
4980 | This one is the same as `Unused values' except that all symbol | |
4981 | declarations appear after the rules in order to catch the rest of the | |
4982 | errors fixed by the above patch. | |
4983 | ||
e256e17f JD |
4984 | 2006-06-26 Joel E. Denny <jdenny@ces.clemson.edu> |
4985 | ||
300a1930 JD |
4986 | More cleanup. |
4987 | * src/reader.c (current_rule): Declare it static since it's no longer | |
4988 | used outside this file. | |
4989 | (grammar_current_rule_action_append): Remove redundant arguments from | |
4990 | translate_rule_action invocation. | |
4991 | * src/reader.h (current_rule): Remove this unused extern. | |
4992 | * src/scan-code.h (translate_rule_action): Remove redundant arguments. | |
4993 | * src/scan-code.l (translate_rule_action): Likewise. | |
e256e17f | 4994 | |
381ecb06 JD |
4995 | 2006-06-25 Joel E. Denny <jdenny@ces.clemson.edu> |
4996 | ||
4997 | Clean up yesterday's patch. | |
4998 | * parse-gram.y (rhs): Move grammar_midrule_action invocation from here | |
4999 | to... | |
5000 | * src/reader.c (grammar_current_rule_action_append): ... here for | |
5001 | consistency with grammar_current_rule_symbol_append. | |
5002 | * tests/regression.at (Braced code in declaration in rules section): | |
5003 | Make yyerror and yylex static as usual. | |
5004 | ||
4210cd0b JD |
5005 | 2006-06-24 Joel E. Denny <jdenny@ces.clemson.edu> |
5006 | ||
5007 | Fix bug that mistakes braced code in a declaration in the rules section | |
5008 | to be a rule action. Mentioned at | |
5009 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00105.html>. | |
5010 | * src/scan-gram.l: Move midrule action detection from the start of the | |
5011 | scanning of any braced code to... | |
5012 | * src/parse-gram.y (rhs): ... the parsing of braced code as a rule | |
5013 | action. For readability, use $2 and @2 rather than the equivalent | |
5014 | global variables. | |
5015 | * tests/regression.at (Braced code in declaration in rules section): | |
5016 | New test to catch the error fixed by the above patch. | |
5017 | ||
5018 | Work on code readability some. | |
5019 | * src/scan-code.l (current_rule): Get rid of this misleading and | |
5020 | redundant declaration: it's actually extern'ed in reader.h. | |
5021 | (YY_DECL, code_lex, handle_action_dollar, handle_action_at, | |
5022 | translate_action): Add a rule argument and use it instead of the global | |
5023 | current_rule. | |
5024 | (translate_rule_action): This already receives current_rule through an | |
5025 | argument, so pass it on to translate_action instead of assigning | |
5026 | current_rule to current_rule. | |
5027 | (translate_symbol_action, translate_code): Pass rule = NULL to | |
5028 | translate_action. | |
5029 | ||
34f98f46 JD |
5030 | 2006-06-23 Joel E. Denny <jdenny@ces.clemson.edu> |
5031 | ||
5032 | Rename %before-definitions to %start-header and %after-definitions to | |
5033 | %end-header. Don't use these declarations to separate pre-prologue | |
5034 | blocks from post-prologue blocks. Add new order-independent | |
5035 | declarations %before-header and %after-header as alternatives to the | |
5036 | traditional Yacc pre-prologue and post-prologue blocks. Discussed at | |
5037 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00110.html>. | |
5038 | * NEWS (2.3+): Update for these changes. | |
5039 | * data/glr.c (b4_before_definitions): Update to... | |
5040 | (b4_start_header): ... this. | |
5041 | (b4_after_definitions): Update to... | |
5042 | (b4_end_header): ... this. | |
5043 | * data/glr.cc: Likewise. | |
5044 | * data/lalr1.cc: Likewise. | |
5045 | * data/yacc.c: Likewise. | |
5046 | * doc/bison.texinfo (The prologue): Update names, and replace remaining | |
5047 | prologue blocks with %*-header declarations. | |
5048 | (Calc++ Parser): Likewise. | |
91661ebb | 5049 | (Decl Summary): Update names. |
148d66d8 | 5050 | (Table of Symbols): Update description. |
34f98f46 JD |
5051 | * src/parse-gram.y (PERCENT_AFTER_DEFINITIONS): Update to... |
5052 | (PERCENT_END_HEADER): ... this. | |
5053 | (PERCENT_BEFORE_DEFINITIONS): Update to... | |
5054 | (PERCENT_START_HEADER): ... this. | |
5055 | (PERCENT_AFTER_HEADER, PERCENT_BEFORE_HEADER): New tokens. | |
5056 | (declaration): Update token names and m4 macro names. | |
5057 | When parsing %end-header and %start-header, invoke translate_code | |
5058 | before muscle_code_grow, and no longer set global booleans to remember | |
5059 | whether these declarations have been seen. | |
5060 | Parse new %after-header and %before-header. | |
5061 | * src/reader.c (before_definitions, after_definitions): Remove. | |
5062 | (prologue_augment): Accept a new bool argument to specify whether to | |
5063 | augment the pre-prologue or post-prologue. | |
5064 | * src/reader.h (before_definitions, after_definitions): Remove these | |
5065 | extern's. | |
5066 | (prologue_augment): Add new bool argument. | |
5067 | * src/scan-gram.l (PERCENT_AFTER_DEFINITIONS): Update to... | |
5068 | (PERCENT_END_HEADER): ... this. | |
5069 | (PERCENT_BEFORE_DEFINITIONS): Update to... | |
5070 | (PERCENT_START_HEADER): ... this. | |
5071 | (PERCENT_AFTER_HEADER, PERCENT_BEFORE_HEADER): New tokens. | |
5072 | * tests/actions.at (Printers and Destructors): Update names. | |
5073 | ||
31b2b07e JD |
5074 | 2006-06-22 Joel E. Denny <jdenny@ces.clemson.edu> |
5075 | ||
5076 | Add comparison operators for C++ location classes. Discussed at | |
5077 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00092.html>. | |
5078 | * data/c++.m4 (b4_define_location_comparison): New boolean %define | |
5079 | declaration indicating whether filename_type has an operator==. If | |
5080 | filename_type is `std::string', it defaults to `1', `0' otherwise. | |
5081 | * data/location.cc: Iff b4_define_location_comparison is `1', add | |
5082 | operator== and operator!= for class position and for class location. | |
5083 | ||
5084 | Some minor fixes. | |
5085 | * src/scan-action.l: Remove unused file. | |
5086 | * src/symtab.c (symbol_printer_set): Use printer_location not | |
5087 | destructor_location. | |
5088 | * src/symtab.h (struct symbol): Replace incorrect source comment for | |
5089 | printer members. | |
5090 | * tests/input.at (Incompatible Aliases): Update output with correct | |
5091 | printer location. | |
5092 | ||
9bc0dd67 JD |
5093 | 2006-06-20 Joel E. Denny <jdenny@ces.clemson.edu> |
5094 | ||
5095 | Don't put the pre-prologue in the header file. For the yacc.c code | |
5096 | file and the glr.c header and code files, move the pre-prologue before | |
5097 | the token definitions. Add new %before-definitions and | |
5098 | %after-definitions to declare code that will go in both the header file | |
5099 | and code file. Discussed at | |
5100 | <http://lists.gnu.org/archive/html/bison-patches/2005-12/msg00000.html>, | |
5101 | <http://lists.gnu.org/archive/html/bison-patches/2006-01/msg00016.html>, | |
5102 | and | |
5103 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00055.html>. | |
5104 | * NEWS (2.3+): Describe these changes. | |
5105 | * data/glr.c (b4_pre_prologue): Move from within to before... | |
5106 | (b4_shared_declarations): ... this. | |
5107 | Add new b4_before_definitions before b4_token_enums. | |
5108 | Add new b4_after_definitions at the end. | |
5109 | * data/glr.cc (b4_pre_prologue): Replace with... | |
5110 | (b4_before_definitions): ... this in the header file. | |
5111 | (b4_after_definitions): New near the end of the header file. | |
5112 | * data/lalr1.cc (b4_pre_prologue): Move from the header file to the | |
5113 | code file right before including the header file. | |
5114 | (b4_before_definitions): New in the previous position of | |
5115 | b4_pre_prologue in the header file. | |
5116 | (b4_after_definitions): New near the end of the header file. | |
5117 | * data/yacc.c: Clean up some m4 quoting especially in the header file. | |
5118 | (b4_token_enums_defines): In the code file, move to right before | |
5119 | YYSTYPE for consistency with the header file. | |
5120 | (b4_before_definitions): New right before b4_token_enums_defines in | |
5121 | both the header and code file. | |
5122 | (b4_after_definitions): New right after YYLTYPE and yylloc in both the | |
5123 | header and code file. | |
5124 | * doc/bison.texinfo (Prologue): Show use of %before-definitions instead | |
5125 | of prologues for %union dependencies. | |
91661ebb JD |
5126 | (Decl Summary): In %defines description, mention the effect of |
5127 | %before-definitions and %after-definitions on the header file. | |
9bc0dd67 JD |
5128 | (Calc++ Parser): Forward declare driver in a %before-definitions rather |
5129 | than in the pre-prologue so that make check succeeds. | |
148d66d8 | 5130 | (Table of Symbols): Add entries for %before-definitions and |
9bc0dd67 JD |
5131 | %after-definitions. |
5132 | * src/parse-gram.y (PERCENT_BEFORE_DEFINITIONS): New token for | |
5133 | %before-definitions. | |
5134 | (PERCENT_AFTER_DEFINITIONS): New token for %after-definitions. | |
5135 | (declaration): Parse those declarations and append to | |
5136 | b4_before_definitions and b4_after_definitions, respectively. | |
5137 | * src/reader.c (before_definitions, after_definitions): New bools to | |
5138 | track whether those declarations have been seen. | |
5139 | (prologue_augment): Add to the post-prologue if %union, | |
5140 | %before-definitions, or %after-definitions has been seen. | |
5141 | * src/reader.h (before_definitions, after_definitions): New extern's. | |
5142 | * src/scan-gram.l: Scan the new declarations. | |
5143 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Place the second | |
5144 | prologue block in a %before-definitions or a %after-definitions based | |
5145 | on whether the %union is declared. | |
5146 | * tests/regression.at (Early token definitions with --yacc, Early token | |
5147 | definitions without --yacc): Move tests for token definitions into the | |
5148 | post-prologue since token names are no longer defined in the | |
5149 | pre-prologue. | |
5150 | ||
203b9274 AD |
5151 | 2006-06-20 Akim Demaille <akim@epita.fr> |
5152 | ||
5153 | * src/symtab.h, src/symtab.c (symbol_from_uniqstr): New. | |
5154 | (symbol_get): Use it. | |
5155 | * src/parse-gram.y: Use it. | |
5156 | ||
a7ee59cf JD |
5157 | 2006-06-19 Joel E. Denny <jdenny@ces.clemson.edu> |
5158 | ||
5159 | * src/scan-gram.l: Remove unused declaration of last_string_1 so the | |
5160 | build succeeds when configured with --enable-gcc-warnings. | |
5161 | ||
5a2baae7 PE |
5162 | 2006-06-19 Paul Eggert <eggert@cs.ucla.edu> |
5163 | ||
33ad1a9c PE |
5164 | * src/parse-gram.y (char_name): New function. |
5165 | (CHAR, STRING, string_content): For %printer, properly escape. | |
5166 | (ID): Prefer fputs to fprintf. | |
5167 | (id): Reindent to be consistent with other rules. | |
5168 | Properly quote char. | |
5169 | ||
5a2baae7 PE |
5170 | The Translation Project changed its way of publishing translations |
5171 | to maintainers. I haven't received any responses to my request | |
5172 | for supporting the old way, or for documenting the new way. I | |
5173 | have modified 'bootstrap' to use screen scraping | |
5174 | (in this case, HTML scraping). This is unreliable and inelegant, | |
5175 | but I don't see any better way. Yuck. | |
5176 | * bootstrap (TP_URL, WGET_COMMAND): New vars. | |
5177 | (get_translations): New function, which uses HTML scraping to | |
5178 | deduce locations of latest translations. | |
5179 | Use this function to grab both bison and bison-runtime .po files. | |
5180 | Don't bother priming the pump for the runtime-po domain any more, | |
5181 | as it's now translated better than bison is. | |
5182 | ||
58d7a1a1 AD |
5183 | 2006-06-19 Akim Demaille <akim@epita.fr> |
5184 | ||
5185 | * src/scan-gram.l: No longer "parse" things after `%union' until | |
5186 | `{'. Rather, return a single "%union" token. | |
5187 | No longer make symbols: return strings, and leave the conversion | |
5188 | to symbols to the parser. | |
5189 | (SC_PRE_CODE, token_type): Remove. | |
5190 | * src/parse-gram.y (%union): New field `character'. | |
5191 | Sort tokens. | |
5192 | (CHAR): New token. | |
5193 | (ID, ID_COLON): Now that the scanner no longer makes them | |
5194 | identifiers, adjust all uses to invoke symbol_get. | |
5195 | (id_colon): New, wraps the conversion from string to symbol. | |
5196 | (%union): Accept a possible union_name. | |
5197 | (symbol): Now can be a char. | |
5198 | * data/c.m4 (b4_union_name): Leave a default value. | |
5199 | * data/glr.c, data/yacc.c: Use it. | |
5200 | ||
b931235e JD |
5201 | 2006-06-11 Joel E. Denny <jdenny@ces.clemson.edu> |
5202 | ||
5203 | For associating token numbers with token names for "yacc.c", don't use | |
5204 | #define statements unless `--yacc' is specified; always use enum | |
5205 | yytokentype. Most important discussions start at: | |
5206 | <http://lists.gnu.org/archive/html/bison-patches/2005-09/msg00053.html>, | |
5207 | <http://lists.gnu.org/archive/html/bison-patches/2005-12/msg00052.html>, | |
5208 | and | |
5209 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00043.html>. | |
5210 | * NEWS (2.3+): Mention. | |
5211 | * data/c.m4 (b4_yacc_if): New. | |
5212 | (b4_token_enums_defines): Use b4_yacc_if to decide whether to add the | |
5213 | token #define's. | |
5214 | * doc/bison.texinfo (Bison Options): Describe the effect of `--yacc' | |
5215 | on token name definitions. | |
5216 | * src/getargs.c (usage): Capitalize `Yacc' in English. | |
5217 | * src/output.c (prepare): Define b4_yacc_flag. | |
5218 | * tests/regression.at (Early token definitions): Test that tokens names | |
5219 | are defined before the pre-prologue not just before the post-prologue. | |
5220 | Remove this test case and copy to... | |
5221 | (Early token definitions with --yacc): ... this to test #define's. | |
5222 | (Early token definitions without --yacc): ... and this to test enums. | |
5223 | ||
9e6e7ed2 PE |
5224 | 2006-06-11 Paul Eggert <eggert@cs.ucla.edu> |
5225 | ||
5226 | * NEWS: Reword the post-2.3 change to not be so optimistic about | |
5227 | removing the old "look-ahead" spelling. | |
5228 | Update previous look-ahead/lookahead change reports. | |
5229 | * REFERENCES: look-ahead -> lookahead (since that's | |
5230 | what he actually wrote). | |
5231 | * doc/refcard.tex: look ahead -> lookahead, | |
5232 | look-ahead -> lookahead | |
5233 | ||
742e4900 JD |
5234 | 2006-06-09 Joel E. Denny <jdenny@ces.clemson.edu> |
5235 | ||
5236 | For consistency, use `lookahead' instead of `look-ahead' or | |
5237 | `look_ahead'. Discussed starting at | |
5238 | <http://lists.gnu.org/archive/html/bison-patches/2006-01/msg00049.html> | |
5239 | and then at | |
5240 | <http://lists.gnu.org/archive/html/bison-patches/2006-06/msg00017.html>. | |
5241 | * NEWS: For the next release, note the change to `--report'. | |
5242 | * TODO, doc/bison.1: Update English. | |
5243 | * doc/bison.texinfo: Update English. | |
5244 | (Understanding Your Parser, Bison Options): Document as | |
5245 | `--report=lookahead' rather than `--report=look-ahead'. | |
5246 | * src/conflicts.c: Update English in comments. | |
5247 | (lookahead_set): Rename from look_ahead_set. | |
5248 | (flush_reduce): Rename argument look_ahead_tokens to lookahead_tokens. | |
5249 | (resolve_sr_conflict): Rename local look_ahead_tokens to | |
5250 | lookahead_tokens, and update other uses. | |
5251 | (flush_shift, set_conflicts, conflicts_solve, count_sr_conflicts, | |
5252 | count_rr_conflicts, conflicts_free): Update uses. | |
5253 | * src/getargs.c (report_args): Move "lookahead" before alternate | |
5254 | spellings. | |
5255 | (report_types): Update uses. | |
5256 | (usage): For `--report' usage description, state `lookahead' spelling | |
5257 | rather than `look-ahead'. | |
5258 | * src/getargs.h (report.report_lookahead_tokens): Rename from | |
5259 | report_look_ahead_tokens. | |
5260 | * src/lalr.c: Update English in comments. | |
5261 | (compute_lookahead_tokens): Rename from compute_look_ahead_tokens. | |
5262 | (state_lookahead_tokens_count): Rename from | |
5263 | state_look_ahead_tokens_count. | |
5264 | Rename local n_look_ahead_tokens to n_lookahead_tokens. | |
5265 | (lookahead_tokens_print): Rename from look_ahead_tokens_print. | |
5266 | Rename local n_look_ahead_tokens to n_lookahead_tokens. | |
5267 | Update other uses. | |
5268 | Update English in output. | |
5269 | (add_lookback_edge, initialize_LA, lalr, lalr_free): Update uses. | |
5270 | * src/print.c: Update English in comments. | |
5271 | (lookahead_set): Rename from look_ahead_set. | |
5272 | (print_reduction): Rename argument lookahead_token from | |
5273 | look_ahead_token. | |
5274 | (print_core, state_default_rule, print_reductions, print_results): | |
5275 | Update uses. | |
5276 | * src/print_graph.c: Update English in comments. | |
5277 | (print_core): Update uses. | |
5278 | * src/state.c: Update English in comments. | |
5279 | (reductions_new): Update uses. | |
5280 | (state_rule_lookahead_tokens_print): Rename from | |
5281 | state_rule_look_ahead_tokens_print, and update other uses. | |
5282 | * src/state.h: Update English in comments. | |
5283 | (reductions.lookahead_tokens): Rename from look_ahead_tokens. | |
5284 | (state_rule_lookahead_tokens_print): Rename from | |
5285 | state_rule_look_ahead_tokens_print. | |
5286 | * src/tables.c: Update English in comments. | |
5287 | (conflict_row, action_row): Update uses. | |
5288 | * tests/glr-regression.at | |
5289 | (Incorrect lookahead during deterministic GLR, | |
5290 | Incorrect lookahead during nondeterministic GLR): Rename | |
5291 | print_look_ahead to print_lookahead. | |
5292 | * tests/torture.at: Update English in comments. | |
5293 | (AT_DATA_LOOKAHEAD_TOKENS_GRAMMAR): Rename from | |
5294 | AT_DATA_LOOK_AHEAD_TOKENS_GRAMMAR. | |
5295 | (Many lookahead tokens): Update uses. | |
5296 | * data/glr.c: Update English in comments. | |
5297 | * lalr1.cc: Likewise. | |
5298 | * yacc.c: Likewise. | |
5299 | * src/conflicts.h: Likewise. | |
5300 | * src/lalr.h: Likewise. | |
5301 | * src/main.c: Likewise. | |
5302 | * src/output.c: Likewise. | |
5303 | * src/parse-gram.c: Likewise. | |
5304 | * src/tables.h: Likewise. | |
5305 | * tests/calc.at: Likewise. | |
5306 | ||
3c40d0b5 JD |
5307 | 2006-06-08 Joel E. Denny <jdenny@ces.clemson.edu> |
5308 | ||
5309 | * src/flex-scanner.h (yytext): Remove stray `*/' in #define. | |
5310 | ||
5d278082 PE |
5311 | 2006-06-07 Paul Eggert <eggert@cs.ucla.edu> |
5312 | ||
5313 | * TODO: Add request from Nelson H. F. Beebe to be able to install | |
5314 | Bison without installing the yacc script. | |
5315 | ||
9e668899 JD |
5316 | 2006-06-07 Joel E. Denny <jdenny@ces.clemson.edu> |
5317 | ||
5318 | * src/flex-scanner.h: For the sake of Flex 2.5.4, don't #define yyleng | |
5319 | and yytext if they're already #define'd. | |
5320 | * src/flex-scanner.h, src/location.h: Move #include "system.h" to... | |
5321 | * src/scan-code-c.c: ... here. | |
5322 | * src/scan-code.l, src/scan-gram.l: ... and here. Also #include | |
5323 | <config.h>. | |
5324 | ||
0c8e079f JD |
5325 | 2006-06-07 Joel E. Denny <jdenny@ces.clemson.edu> |
5326 | ||
5327 | Get Bison to build again when configured with --enable-gcc-warnings. | |
5328 | * src/location.c, src/location.h, src/main.c, src/scan-code.l: Add some | |
5329 | missing #include's. | |
5330 | * src/scan-code.l (handle_action_dollar, handle_action_at): Rename | |
5331 | loc argument as it shadows a global. | |
5332 | * src/scan-gram.l: Remove stray comma that prevents boundary_set | |
5333 | invocation. | |
5334 | ||
5335 | * src/.cvsignore: Add scan-code.c. | |
5336 | ||
2346344a AD |
5337 | 2006-06-07 Akim Demaille <akim@epita.fr> |
5338 | ||
5339 | * src/scan-gram.l: Move the "add a trailing ; to actions" code | |
5340 | to... | |
5341 | * src/scan-code.l: here. | |
5342 | * tests/input.at (Torturing the Scanner): Fix another location | |
5343 | error. | |
5344 | ||
4862bdfd AD |
5345 | 2006-06-07 Akim Demaille <akim@epita.fr> |
5346 | ||
5347 | * src/Makefile.am (BUILT_SOURCES): Fix the trailing backslash. | |
5348 | ||
e9071366 AD |
5349 | 2006-06-06 Akim Demaille <akim@epita.fr> |
5350 | ||
5351 | Extract the parsing of user actions from the grammar scanner. | |
5352 | As a consequence, the relation between the grammar scanner and | |
5353 | parser is much simpler. We can also split "composite tokens" back | |
5354 | into simple tokens. | |
5355 | * src/gram.h (ITEM_NUMBER_MAX, RULE_NUMBER_MAX): New. | |
5356 | * src/scan-gram.l (add_column_width, adjust_location): Move to and | |
5357 | rename as... | |
5358 | * src/location.h, src/location.c (add_column_width) | |
5359 | (location_compute): these. | |
5360 | Fix the column count: the initial column is 0. | |
5361 | (location_print): Be robust to ending column being 0. | |
5362 | * src/location.h (boundary_set): New. | |
5363 | * src/main.c: Adjust to scanner_free being renamed as | |
5364 | gram_scanner_free. | |
5365 | * src/output.c: Include scan-code.h. | |
5366 | * src/parse-gram.y: Include scan-gram.h and scan-code.h. | |
5367 | Use boundary_set. | |
5368 | (PERCENT_DESTRUCTOR, PERCENT_PRINTER, PERCENT_INITIAL_ACTION) | |
5369 | (PERCENT_LEX_PARAM, PERCENT_PARSE_PARAM): Remove the {...} part, | |
5370 | which is now, again, a separate token. | |
5371 | Adjust all dependencies. | |
5372 | Whereever actions with $ and @ are used, use translate_code. | |
5373 | (action): Remove this nonterminal which is now useless. | |
5374 | * src/reader.c: Include assert.h, scan-gram.h and scan-code.h. | |
5375 | (grammar_current_rule_action_append): Use translate_code. | |
5376 | (packgram): Bound check ruleno, itemno, and rule_length. | |
5377 | * src/reader.h (gram_in, gram__flex_debug, scanner_cursor) | |
5378 | (last_string, last_braced_code_loc, max_left_semantic_context) | |
5379 | (scanner_initialize, scanner_free, scanner_last_string_free) | |
5380 | (gram_out, gram_lineno, YY_DECL_): Move to... | |
5381 | * src/scan-gram.h: this new file. | |
5382 | (YY_DECL): Rename as... | |
5383 | (GRAM_DECL): this. | |
5384 | * src/scan-code.h, src/scan-code.l, src/scan-code-c.c: New. | |
5385 | * src/scan-gram.l (gram_get_lineno, gram_get_in, gram_get_out): | |
5386 | (gram_get_leng, gram_get_text, gram_set_lineno, gram_set_in): | |
5387 | (gram_set_out, gram_get_debug, gram_set_debug, gram_lex_destroy): | |
5388 | Move these declarations, and... | |
5389 | (obstack_for_string, STRING_GROW, STRING_FINISH, STRING_FREE): | |
5390 | these to... | |
5391 | * src/flex-scanner.h: this new file. | |
5392 | * src/scan-gram.l (rule_length, rule_length_overflow) | |
5393 | (increment_rule_length): Remove. | |
5394 | (last_braced_code_loc): Rename as... | |
5395 | (gram_last_braced_code_loc): this. | |
5396 | Adjust to the changes of the parser. | |
5397 | Move all the handling of $ and @ into... | |
5398 | * src/scan-code.l: here. | |
5399 | * src/scan-gram.l (handle_dollar, handle_at): Remove. | |
5400 | (handle_action_dollar, handle_action_at): Move to... | |
5401 | * src/scan-code.l: here. | |
5402 | * src/Makefile.am (bison_SOURCES): Add flex-scanner.h, | |
5403 | scan-code.h, scan-code-c.c, scan-gram.h. | |
5404 | (EXTRA_bison_SOURCES): Add scan-code.l. | |
5405 | (BUILT_SOURCES): Add scan-code.c. | |
5406 | (yacc): Be robust to white spaces. | |
5407 | ||
5408 | * tests/conflicts.at, tests/input.at, tests/reduce.at, | |
5409 | * tests/regression.at: Adjust the column numbers. | |
5410 | * tests/regression.at: Adjust the error message. | |
7891a7c4 | 5411 | |
184e42f0 JD |
5412 | 2006-06-06 Joel E. Denny <jdenny@ces.clemson.edu> |
5413 | ||
5414 | * src/getargs.c (usage): Mention GLR not just LALR(1) in --help output. | |
5415 | Use Akim's wording from | |
5416 | <http://lists.gnu.org/archive/html/bison-patches/2006-05/msg00056.html>. | |
5417 | ||
7891a7c4 JD |
5418 | 2006-06-06 Joel E. Denny <jdenny@ces.clemson.edu> |
5419 | ||
5420 | Between Bison releases, manually append `+' to the previous Bison | |
5421 | release number, and use that as a signal to automatically print the | |
5422 | ChangeLog's CVS Id keyword from --version. Discussed starting at | |
5423 | <http://lists.gnu.org/archive/html/bison-patches/2006-05/msg00028.html>. | |
5424 | * ChangeLog: Add Id header. | |
5425 | * configure.ac (AC_INIT): Append `+' to `2.3'. | |
5426 | * src/.cvsignore: Add revision.c. | |
5427 | * src/Makefile.am (bison_SOURCES): Add revision.c and revision.h. | |
5428 | (BUILT_SOURCES): Add revision.c. | |
5429 | (revision.c): New target rule. This file defines a new global variable | |
5430 | named revision. It initializes it with either the Id from ChangeLog | |
5431 | or, if VERSION doesn't contain `+', with the empty string. | |
5432 | * src/getargs.c (version): Print the value of revision. | |
5433 | * src/revision.h: Extern revision. | |
5434 | ||
4ad3ed84 PE |
5435 | 2006-06-05 Paul Eggert <eggert@cs.ucla.edu> |
5436 | ||
5437 | * NEWS: Version 2.3. | |
5438 | * configure.ac (AC_INIT): Likewise. | |
5439 | ||
02103984 PE |
5440 | 2006-05-30 Paul Eggert <eggert@cs.ucla.edu> |
5441 | ||
5442 | * data/glr.c (YYRECOVERING): Define to be a function-like macro | |
5443 | with no arguments, not as an object-like macro. This is for | |
5444 | compatibility with data/yacc.c. Problem reported by John P. Hartmann in | |
5445 | <http://lists.gnu.org/archive/html/bug-bison/2006-05/msg00059.html>. | |
5446 | * doc/bison.texinfo (Action Features, Error Recovery, Table of Symbols): | |
5447 | Document this. | |
5448 | ||
2c08afa5 JD |
5449 | 2006-05-30 Joel E. Denny <jdenny@ces.clemson.edu> |
5450 | ||
5451 | * src/getargs.c (usage): Back out yesterday's modification of the | |
5452 | --help output so that we don't have to wait for translation before | |
5453 | releasing 2.3. | |
5454 | ||
6077da58 PE |
5455 | 2006-05-29 Paul Eggert <eggert@cs.ucla.edu> |
5456 | ||
5457 | * doc/bison.texinfo (Introduction): Don't say "GLR grammar". | |
5458 | Problem reported by Akim Demaille. | |
5459 | ||
2a26b6c2 JD |
5460 | 2006-05-29 Joel E. Denny <jdenny@ces.clemson.edu> |
5461 | ||
5462 | * src/getargs.c (usage): Mention GLR not just LALR(1) in --help output. | |
5463 | ||
aefef0d6 PE |
5464 | 2006-05-26 Paul Eggert <eggert@cs.ucla.edu> |
5465 | ||
5466 | * data/yacc.c (yy_reduce_print): Omit trailing white space in | |
5467 | generated source code. Problem reported by Frans Englich in | |
5468 | <http://lists.gnu.org/archive/html/bug-bison/2006-05/msg00049.html>. | |
5469 | ||
fcd8e201 PE |
5470 | 2006-05-22 Paul Eggert <eggert@cs.ucla.edu> |
5471 | ||
5472 | * Makefile.maint (gzip_rsyncable, GZIP_ENV): Compute within the | |
5473 | shell, not within 'make', so that 'make' by an ordinary builder | |
5474 | (using GNU make) does not worry about configuring gzip. This also | |
5475 | works around a bug reported independently by Keith Thompson and by | |
5476 | Georg Schwarz, whereby gzip 1.2.4 --help would output usage on | |
5477 | stderr rather than stdout, messing up the build logs. | |
5478 | ||
7b5cdcbd JD |
5479 | 2006-05-21 Joel E. Denny <jdenny@ces.clemson.edu> |
5480 | ||
5481 | * data/yacc.c (yyparse): Wrap the final return from yyparse inside YYID | |
5482 | to make sure that YYID will never be unused. This fixes a 'make | |
5483 | maintainer-check' failure caused by the recent changes to the 'Trivial | |
5484 | grammars' test case, which caused g++ 4.1.0 to complain that YYID was | |
5485 | not used. | |
5486 | * data/glr.c (yyparse): Wrap yyparse's return inside YYID just in case. | |
5487 | ||
5ad0a449 JD |
5488 | 2006-05-21 Joel E. Denny <jdenny@ces.clemson.edu> |
5489 | ||
5490 | * data/glr.c (yyresolveLocations): Remove bogus YYASSERT that the | |
5491 | state before an empty RHS is always resolved here. Only the location | |
5492 | of that state is guaranteed to be resolved, and that's enough. This | |
5493 | fixes the remaining bug reported by Derek M. Jones in | |
5494 | <http://lists.gnu.org/archive/html/bug-bison/2006-05/msg00027.html>. | |
5495 | * tests/glr-regression.at (Uninitialized location when reporting | |
5496 | ambiguity): Test the above case. | |
5497 | Also, the embedded comments in this test case claim it checks the case | |
5498 | of an empty RHS that has inherited the initial location. However, the | |
5499 | corresponding LHS was already resolved, so yyresolveLocations didn't | |
5500 | actually have reason to modify it. Fix this by forcing | |
5501 | nondeterministic operation at the beginning of the parse. | |
5502 | ||
50cce58e PE |
5503 | 2006-05-20 Paul Eggert <eggert@cs.ucla.edu> |
5504 | ||
5505 | * data/c.m4 (b4_yy_symbol_print_generate): | |
5506 | (b4_yy_symbol_print_generate): Use 'YYSTYPE const' rather than | |
5507 | 'const YYSTYPE', and similarly for YYLTYPE. This fixes one | |
5508 | of the bugs reported today by Derek M Jones in | |
5509 | <http://lists.gnu.org/archive/html/bug-bison/2006-05/msg00027.html>. | |
5510 | * doc/bison.texinfo (Value Type): Document that YYSTYPE must be | |
5511 | defined to be a type name without parens or brackets. | |
5512 | (Location Type): Similarly for YYLTYPE. | |
5513 | * tests/regression.at (Trivial grammars): Put in a test for this | |
5514 | bug that will be caught by 'make maintainer-check' (though not, | |
5515 | alas, by 'make check' unless your compiler is picky). | |
5516 | ||
ab8d9dc5 PE |
5517 | 2006-05-19 Paul Eggert <eggert@cs.ucla.edu> |
5518 | ||
0d2c8934 | 5519 | * NEWS: Version 2.2. |
ab8d9dc5 PE |
5520 | * configure.ac (AC_INIT): Likewise. |
5521 | ||
9138c575 JD |
5522 | 2006-05-17 Joel E. Denny <jdenny@ces.clemson.edu> |
5523 | ||
5524 | * data/glr.c (yyreportTree): Make room in yystates for the state | |
5525 | preceding the RHS. This fixes the segmentation fault reported by Derek | |
5526 | M. Jones in | |
5527 | <http://lists.gnu.org/archive/html/help-bison/2006-05/msg00035.html>. | |
5528 | (yyreportTree, yypdumpstack): Subtract 1 from yyrule before printing | |
5529 | to the user. Reported for yyreportTree by Derek M. Jones later in the | |
5530 | same thread. | |
5531 | * THANKS: Add Derek M. Jones. | |
5532 | Update my email address. | |
5533 | Fix typo in Steve Murphy's name. | |
5534 | ||
276f48df PE |
5535 | 2006-05-14 Paul Eggert <eggert@cs.ucla.edu> |
5536 | ||
d6645148 PE |
5537 | * data/glr.c (yyreportSyntaxError): Fix off-by-one error in |
5538 | checking against YYLAST that caused the parser to miss a potential | |
5539 | alternative in its diagnostic. | |
5540 | Problem reported by Maria Jose Moron Fernandez in | |
5541 | <http://lists.gnu.org/archive/html/bug-bison/2006-05/msg00024.html>. | |
5542 | * data/lalr1.cc (yysyntax_error_): Likewise. | |
5543 | * data/yacc.c (yysyntax_error): Likewise. | |
5544 | * tests/regression.at (_AT_DATA_DANCER_Y): Use static array for | |
5545 | tokens, in case we run into an older C compiler. | |
5546 | (_AT_DATA_EXPECT2_Y, AT_CHECK_EXPECT2): New macros. | |
5547 | Use them to check for the off-by-one error fixed above. | |
5548 | ||
276f48df PE |
5549 | * data/yacc.c (yytnamerr): Fix typo: local var should be of type |
5550 | YYSIZE_T, not size_t. | |
5551 | * tests/regression.at (Trivial grammars): New test, to catch | |
5552 | the error fixed by the above patch. | |
5553 | ||
cd8b5791 AD |
5554 | 2006-05-14 Akim Demaille <akim@lrde.epita.fr> |
5555 | ||
5556 | * doc/bison.texinfo (C++ Bison Interface): Clarify the naming | |
5557 | scheme. | |
5558 | Reported by Steve Murphy. | |
5559 | ||
34376418 AD |
5560 | 2006-05-14 Akim Demaille <akim@lrde.epita.fr> |
5561 | ||
5562 | * data/glr.cc, data/lalr1.cc: Using %defines is mandatory. | |
5563 | * data/glr.cc: b4_location_flag is now b4_locations_flag. | |
5564 | ||
327afc7c AD |
5565 | 2006-05-14 Akim Demaille <akim@lrde.epita.fr> |
5566 | ||
5567 | Implement --trace=m4. | |
5568 | * src/getargs.c (trace_types, trace_args): Accept trace_m4. | |
5569 | * src/output.c (output_skeleton): When set, pass -dV to m4. | |
5570 | ||
5571 | Factor the handling of flags in m4. | |
5572 | * src/output.c (prepare): Rename the muscle names debug, defines, | |
5573 | error_verbose to debug_flag, defines_flag, error_verbose_flag. | |
5574 | * data/c.m4: Adjust. | |
5575 | (_b4_define_flag_if, b4_define_flag_if, b4_defines_if): New. | |
5576 | Use b4_define_flag_if to define other b4_FLAG_if macros. | |
5577 | (b4_location_if): As a consequence, rename as... | |
5578 | (b4_locations_if): this, for consistency. | |
5579 | Adjust all the skeletons. | |
5580 | ||
ba9ecd19 AD |
5581 | 2006-05-14 Akim Demaille <akim@lrde.epita.fr> |
5582 | ||
5583 | * etc/bench.pm: Shorten bench names. | |
5584 | ||
4e83ea15 AD |
5585 | 2006-05-14 Akim Demaille <akim@lrde.epita.fr> |
5586 | ||
5587 | * src/output.h, src/output.c (error_verbose): Move to... | |
5588 | * src/getargs.h, src/getargs.c: here. | |
5589 | Sort the flags. | |
5590 | Adjust dependencies. | |
5591 | ||
6e93d810 PE |
5592 | 2006-05-13 Paul Eggert <eggert@cs.ucla.edu> |
5593 | ||
5594 | * data/c.m4 (b4_copyright): Put the special exception for Bison | |
5595 | skeletons here, so we don't have to put it in each skeleton. All | |
b15296ff PE |
5596 | uses changed. Suggested by Akim Demaille. Also, wrap the |
5597 | copyright notice, in case it is longer than 80 columns. Replace | |
5598 | comma by newline after title. | |
6e93d810 | 5599 | |
eaea13f5 PE |
5600 | 2006-05-11 Paul Eggert <eggert@cs.ucla.edu> |
5601 | ||
5602 | * doc/bison.texinfo (Calc++ Scanner): The flex behavior is an | |
5603 | incompatibility, not a bug. Mention that it wasn't fixed as of | |
5604 | flex 2.5.33. | |
5605 | ||
3cf084ec AD |
5606 | 2006-05-11 Akim Demaille <akim@lrde.epita.fr> |
5607 | ||
5608 | * examples/extexi: Enforce the precedence of concatenation over | |
5609 | >>. | |
0a9f1c7d | 5610 | Reported by Tommy Nordgren. |
3cf084ec | 5611 | |
32c96bd7 AD |
5612 | 2006-05-11 Akim Demaille <akim@lrde.epita.fr> |
5613 | ||
5614 | * data/lalr1.cc (yytranslate_): Rename token as t to avoid clashes | |
5615 | with the member "token". | |
f94705b2 | 5616 | Reported by Martin Nylin. |
32c96bd7 | 5617 | |
eaea13f5 PE |
5618 | 2006-05-08 Paul Eggert <eggert@cs.ucla.edu> |
5619 | ||
5620 | * data/glr.c: Switch to Bison 2.2 special-exception language in | |
5621 | the copyright notice. Use more-regular format for titles and | |
5622 | copyright notices. | |
5623 | * data/glr.cc: Likewise. | |
5624 | * data/location.cc: Likewise. | |
5625 | * data/yacc.cc: Likewise. | |
5626 | * doc/bison.texinfo (Conditions): Document this. | |
5627 | * NEWS: likewise. Upgrade version to 2.2. | |
5628 | ||
6e2d1146 AD |
5629 | 2006-04-27 Akim Demaille <akim@lrde.epita.fr> |
5630 | ||
5631 | * data/glr.cc: Remove dead code. | |
5632 | ||
47671055 PE |
5633 | 2006-04-25 Paul Eggert <eggert@cs.ucla.edu> |
5634 | ||
5635 | * bootstrap: Comment out the AM_CPPFLAGS line, since we don't use | |
5636 | that variable and the line breaks the bootstrap. Problem reported | |
5637 | by Juan M. Guerrero. | |
5638 | ||
ed2e6384 AD |
5639 | 2006-04-24 Akim Demaille <akim@lrde.epita.fr> |
5640 | ||
5641 | * doc/bison.texinfo (Multiple start-symbols): New. | |
5642 | ||
3cedc2dc AD |
5643 | 2006-04-24 Akim Demaille <akim@lrde.epita.fr> |
5644 | ||
5645 | * etc/README, etc/bench.pl: New. | |
5646 | ||
b2ddc3f3 AD |
5647 | 2006-04-03 Akim Demaille <akim@lrde.epita.fr> |
5648 | ||
5649 | * src/scan-gram.l: Be robust to BRACED_CODE appearing before any | |
5650 | rule. | |
5651 | Reported by Mickael Labau. | |
5652 | * tests/input.at (Torturing the Scanner): Test it. | |
5653 | ||
91e3ac9a PE |
5654 | 2006-03-16 Paul Eggert <eggert@cs.ucla.edu> |
5655 | ||
5656 | * doc/bison.texinfo (Decl Summary): Don't mention yylloc twice. | |
5657 | Problem reported by Bob Rossi. | |
5658 | ||
5659 | 2006-03-13 Paul Eggert <eggert@cs.ucla.edu> | |
5660 | ||
5661 | * doc/bison.texinfo: Remove @shorttitlepage stuff; it wasn't used | |
5662 | and didn't really work. | |
5663 | For the index, use @ifnotinfo, not @iftex. | |
5664 | Minor cleanups of spacing and terminology. | |
5665 | ||
5cf61e93 AD |
5666 | 2006-03-12 Akim Demaille <akim@lrde.epita.fr> |
5667 | ||
5668 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Fix the definition | |
5669 | of AT_NAME_PREFIX when %name-prefix is not used. | |
5670 | ||
aa08666d AD |
5671 | 2006-03-12 Akim Demaille <akim@lrde.epita.fr> |
5672 | ||
5673 | Apply --prefix to C++ skeletons too: they change the namespace. | |
5674 | The test suite already exercize these cases. | |
5675 | * data/c++.m4 (b4_namespace): New. | |
5676 | * data/lalr1.cc, data/glr.cc, data/location.cc: Use it instead of `yy'. | |
5677 | * data/lalr1.cc (yytnameerr_): Move its definition into the namespace. | |
5678 | * data/yacc.c, data/glr.c: Remove a useless `[]'. | |
5679 | * doc/bison.texinfo: Document it. | |
5680 | (Option Cross Key): Use @multitable in all formats. It looks | |
5681 | nicer, even in TeX outputs. | |
5682 | (Rules): Use the same code whatever the output type is. | |
5683 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS) | |
5684 | (_AT_BISON_OPTION_POPDEFS): Support AT_NAME_PREFIX. | |
5685 | * tests/calc.at: Use it, instead of hard coding `yy'. | |
91e3ac9a | 5686 | |
45567173 AD |
5687 | 2006-03-10 Akim Demaille <akim@lrde.epita.fr> |
5688 | ||
5689 | * TODO: Remove dead items. | |
5690 | ||
e9d8f881 | 5691 | 2006-03-10 Akim Demaille <akim@lrde.epita.fr> |
55ba27be AD |
5692 | |
5693 | * doc/FAQ: Remove, merged into... | |
5694 | * doc/bison.texinfo (FAQ): this. | |
5695 | * doc/Makefile.am (EXTRA_DIST): Adjust. | |
5696 | ||
c095d689 AD |
5697 | 2006-03-10 Akim Demaille <akim@lrde.epita.fr> |
5698 | ||
5699 | * data/c.m4 (b4_token_enum): Always define the enum of tokens, | |
5700 | even if empty. | |
5701 | * data/lalrl1.cc, data/glr.cc (parser::token_type): New. | |
5702 | * doc/bison.texinfo (Calc++ Scanner): Use it. | |
5703 | ||
6e0f8287 PE |
5704 | 2006-03-09 Paul Eggert <eggert@cs.ucla.edu> |
5705 | ||
5706 | Fix two nits reported by twlevo, plus one more that I discovered. | |
5707 | ||
5708 | * src/assoc.h (assoc_to_string): Give a name to the arg, as | |
5709 | this is the usual Bison style. | |
5710 | * src/location.h (location_print): Likewise. | |
5711 | ||
5712 | * src/reader.h (token_name): Likewise. | |
5713 | ||
d6b771c3 PE |
5714 | 2006-03-08 Paul Eggert <eggert@cs.ucla.edu> |
5715 | ||
5716 | Fix some nits reported by twlevo. | |
5717 | * doc/FAQ: Remove ancient Y2K FAQ, replacing it with "secure" | |
5718 | and "POSIX". Use more-modern syntax for URLs. Mention C++ | |
5719 | and ask for Java. Don't hardwire OS version numbers. Add | |
5720 | copyright notice. | |
5721 | * m4/.cvsignore: Add unistd_h.m4, for latest gnulib. | |
5722 | * src/conflicts.c (solved_conflicts_obstack): Now static. | |
5723 | ||
1e137b71 JD |
5724 | 2006-03-08 Joel E. Denny <jdenny@ces.clemson.edu> |
5725 | ||
5726 | * doc/bison.texinfo (Introduction): Mention GLR and C++ as on the web | |
5727 | page. Say "you can use it" not "you may use it" as on the web page; | |
5728 | we're describing capabilities not granting permission. | |
5729 | ||
73f2e47e PE |
5730 | 2006-03-06 Paul Eggert <eggert@cs.ucla.edu> |
5731 | ||
6d05403d PE |
5732 | * data/glr.c (yyresolveLocations): Rename local variables to avoid |
5733 | shadowing warnings. Use usual patter for iterating through RHS. | |
5734 | * tests/glr-regression.at | |
5735 | (Uninitialized location when reporting ambiguity): | |
5736 | Modify yylex so that it uses its argument, rather than trying | |
5737 | to rely on ARGSUSED (which doesn't work for gcc with warnings). | |
5738 | const char -> char const. | |
5739 | ||
73f2e47e PE |
5740 | * tests/Makefile.am ($(srcdir)/package.m4, maintainer-check-valgrind): |
5741 | Don't use tabs inside commands; it messes up 'ps'. | |
5742 | Problem reported by twlevo. | |
5743 | ||
8710fc41 JD |
5744 | 2006-03-06 Joel E. Denny <jdenny@ces.clemson.edu> |
5745 | ||
5746 | * tests/glr-regression.at (Uninitialized location when reporting | |
5747 | ambiguity): New test case. | |
5748 | * data/glr.c (yyresolveLocations): New function, which uses | |
5749 | YYLLOC_DEFAULT. | |
5750 | (yyresolveValue): Invoke yyresolveLocations before reporting an | |
5751 | ambiguity. | |
5752 | * doc/bison.texinfo (Default Action for Locations): Note | |
5753 | YYLLOC_DEFAULT's usage for ambiguity locations. | |
5754 | (GLR Semantic Actions): Cross-reference those notes. | |
5755 | ||
ae952af2 JD |
5756 | 2006-03-04 Joel E. Denny <jdenny@ces.clemson.edu> |
5757 | ||
5758 | * tests/glr-regression.at (Leaked semantic values when reporting | |
5759 | ambiguity): Remove unnecessary union and type declarations. | |
5760 | (Leaked lookahead after nondeterministic parse syntax error): New test | |
5761 | case. | |
5762 | * data/glr.c (yyparse): Check for zero stacks remaining before | |
5763 | attempting to shift the lookahead so that you don't lose it. | |
5764 | ||
35ee866a JD |
5765 | 2006-03-02 Joel E. Denny <jdenny@ces.clemson.edu> |
5766 | ||
5767 | Avoid memory leaks by not invoking longjmp in yyreportAmbiguity. | |
5768 | * tests/glr-regression.at (Leaked semantic values when reporting | |
5769 | ambiguity): New test case. | |
5770 | * data/glr.c (yyreportAmbiguity): Invoke yyyerror directly and return | |
5771 | yyabort rather than invoking yyFail, which invokes longjmp. Remove the | |
5772 | now unnecessary yystackp parameter. | |
5773 | (yyresolveValue): Return yyreportAmbiguity's result. Now the necessary | |
5774 | destructors can be called. | |
5775 | ||
5776 | * tests/glr-regression.at: Don't invoke bison with `-t' unnecessarily | |
5777 | in existing testcases. | |
5778 | ||
520181ab JD |
5779 | 2006-03-02 Joel E. Denny <jdenny@ces.clemson.edu> |
5780 | ||
5781 | Don't leak semantic values for parent RHS when a user action cuts the | |
5782 | parser, and clean up related code a bit. | |
5783 | * tests/glr-regression.at (Leaked merged semantic value if user action | |
35ee866a JD |
5784 | cuts parse): Rename to... |
5785 | (Leaked semantic values if user action cuts parse): ... this. Add check | |
520181ab JD |
5786 | for leaked parent RHS values. |
5787 | * data/glr.c (yydestroyGLRState): In debugging output, distinguish | |
5788 | between an unresolved state (non-empty chain of semantic options) and | |
5789 | an incomplete one (signaled by an empty chain). | |
ae952af2 | 5790 | (yyresolveStates): Document the interface. Move all manipulation of a |
520181ab JD |
5791 | successfully or unsuccessfully resolved yyGLRState to... |
5792 | (yyresolveValue): ... here so that yyresolveValue always leaves a | |
5793 | yyGLRState with consistent data and thus is easier to understand. | |
5794 | Remove the yyvalp and yylocp parameters since they are always just | |
5795 | taken from the yys parameter. When reporting a discarded merged value | |
5796 | in debugging output, note that it is incompletely merged. Document the | |
5797 | interface. | |
5798 | (yyresolveAction): If resolving any of the RHS states fails, destroy | |
5799 | them all rather than leaking them. Thus, as long as user actions are | |
5800 | written to clean up the RHS correctly, yyresolveAction always cleans up | |
5801 | the RHS of a semantic option. Document the interface. | |
5802 | ||
18d9185c PE |
5803 | 2006-02-27 Paul Eggert <eggert@cs.ucla.edu> |
5804 | ||
5805 | * data/glr.c (yyexpandGLRStack): Catch an off-by-one error that | |
5806 | led to a segmentation fault in GNU Pascal. Problem reported | |
5807 | by Waldek Hebisch. | |
5808 | ||
841a7737 JD |
5809 | 2006-02-21 Joel E. Denny <jdenny@ces.clemson.edu> |
5810 | ||
5811 | * doc/bison.texinfo (Mid-Rule Actions): Explain how to bury a | |
5812 | mid-rule action inside a nonterminal symbol in order to declare a | |
5813 | destructor for its semantic value. | |
5814 | ||
fc3f467f PE |
5815 | 2006-02-16 Paul Eggert <eggert@cs.ucla.edu> |
5816 | ||
5817 | * data/yacc.c [(! defined yyoverflow || YYERROR_VERBOSE) && ! | |
5818 | YYSTACK_USE_ALLOCA && ! defined YYSTACK_ALLOC && defined | |
5819 | __cplusplus && ! defined _STDLIB_H && ! | |
5820 | ((defined YYMALLOC || defined malloc) && (defined YYFREE || | |
5821 | defined free))]: Include <stdlib.h> rather than rolling our own | |
5822 | declarations of malloc and free, to avoid problems with | |
5823 | incompatible declarations (using 'throw') C++'s stdlib.h. This | |
5824 | should fix Debian bug 340012 | |
5825 | <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=340012>, | |
5826 | reported by Guillaume Melquiond. | |
5827 | ||
a3af26dd PE |
5828 | 2006-02-13 Paul Eggert <eggert@cs.ucla.edu> |
5829 | ||
4d7bc38c PE |
5830 | * NEWS: Clarify symbols versus types in unused-value warnings. |
5831 | ||
a3af26dd PE |
5832 | * configure.ac (AC_INIT): Bump version number. |
5833 | ||
4e26c69e PE |
5834 | 2006-02-13 Paul Eggert <eggert@cs.ucla.edu> |
5835 | ||
5836 | * NEWS: Version 2.1a. | |
5837 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Declare yyerror and yylex, | |
5838 | since C99 requires this. | |
5839 | ||
498e897c PE |
5840 | 2006-02-11 Paul Eggert <eggert@cs.ucla.edu> |
5841 | ||
5842 | * m4/c-working.m4: New file. | |
5843 | * configure.ac (BISON_TEST_FOR_WORKING_C_COMPILER): Use it. | |
5844 | ||
57bb17ca PE |
5845 | 2006-02-10 Paul Eggert <eggert@cs.ucla.edu> |
5846 | ||
5847 | * Makefile.maint: Merge from coreutils. | |
5848 | ||
0be105dc PE |
5849 | 2006-02-09 Paul Eggert <eggert@cs.ucla.edu> |
5850 | ||
5851 | More portability fixes for problems summarized by Nelson H. F. Beebe. | |
5852 | ||
5853 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Catch a | |
5854 | configuration screwup "./configure CC=/opt/SUNWspro/bin/c89 | |
5855 | CFLAGS="-xarch=generic64" CXX=/opt/SUNWspro/bin/CC | |
5856 | LDFLAGS="-xarch=generic64" with Sun C 5.7 on Solaris 10; this | |
5857 | messes up because C++ code is compiled in 32-bit mode but linked | |
5858 | in 64-bit mode. | |
5859 | ||
6fc0c024 PE |
5860 | 2006-02-08 Paul Eggert <eggert@cs.ucla.edu> |
5861 | ||
5862 | More portability fixes for problems summarized by Nelson H. F. Beebe. | |
5863 | ||
7870f699 PE |
5864 | * doc/bison.texinfo (Calc++ Scanner): Work around a bug in flex |
5865 | 2.5.31. This resembles the 2005-10-10 patch to src/scan-skel.l. | |
5866 | ||
6fc0c024 PE |
5867 | * examples/calc++/Makefile.am (check_PROGRAMS): Renamed from |
5868 | nodist_PROGRAMS, since we don't need to actually compile the | |
5869 | example if we're just doing a plain 'make'. This avoids bothering | |
5870 | the installer unnecessarily about problems due to weird C++ | |
5871 | compilers. | |
5872 | ||
fe6c2fde PE |
5873 | 2006-02-06 Paul Eggert <eggert@cs.ucla.edu> |
5874 | ||
5875 | More portability fixes for problems summarized by Nelson H. F. Beebe. | |
5876 | ||
5877 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Use #include <...> rather | |
5878 | than #include "...", and compile with -I'.'. The old method was | |
5879 | not portable, according to Posix and the C standard, and it does | |
5880 | not work with Sun C 5.7, where previous #line directives affect | |
5881 | the working directory used in later #include "..." directives. | |
5882 | ||
927b425b JMG |
5883 | 2006-02-06 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
5884 | ||
5885 | Various DJGGP specific issues in /djgpp | |
5886 | ||
d9735e9e PE |
5887 | 2006-02-02 Paul Eggert <eggert@cs.ucla.edu> |
5888 | ||
5889 | More portability fixes for problems summarized by Nelson H. F. Beebe. | |
5890 | ||
5891 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Check that | |
5892 | '#include <map>' works and that you can apply ++ to iterators. | |
5893 | ||
5a6755af PE |
5894 | 2006-02-01 Paul Eggert <eggert@cs.ucla.edu> |
5895 | ||
67a0dc4f PE |
5896 | Work around portability problems summarized by Nelson H. F. Beebe in |
5897 | <http://lists.gnu.org/archive/html/bug-bison/2005-09/msg00021.html>. | |
5898 | ||
8c86f0ef PE |
5899 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Check |
5900 | that '#include <string>' works. | |
5901 | ||
de35dd59 PE |
5902 | * data/lalr1.cc (yytranslate_): No longer inline, to work around a |
5903 | porting problem to g++ 3.4.3 on Darwin 7.9.0, where g++ complained | |
5904 | "warning: sorry: semantics of inline function static data `const | |
5905 | unsigned char translate_table[262]' are wrong (you'll wind up with | |
5906 | multiple copies)". | |
5907 | ||
67a0dc4f PE |
5908 | * lib/bbitset.h (struct bitset_vtable): Rename members not, and, |
5909 | or, xor to not_, and_, or_, and xor_, respectively. This works | |
5910 | around a bug in GCC 3.4.3 on Irix 6.5, which apparently has a | |
5911 | random system header somewhere that includes the equivalent of | |
5912 | <iso646.h>. | |
5913 | ||
5a6755af PE |
5914 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Don't assume that "$CC |
5915 | -E" works; it apparently doesn't work with PathScale EKO Compiler | |
67a0dc4f | 5916 | Suite Version 2.0. |
5a6755af | 5917 | |
3f001415 JD |
5918 | 2006-01-30 Joel E. Denny <jdenny@ces.clemson.edu> |
5919 | ||
5920 | During deterministic GLR operation, user actions should be able to | |
5921 | influence the parse by changing yychar. To make this easier to fix and | |
5922 | to make glr.c easier to evolve in general, don't maintain yytoken in | |
5923 | parallel with yychar; just compute yytoken when needed. | |
5924 | * tests/glr-regression.at (Incorrect lookahead during deterministic | |
5925 | GLR): Check that setting yychar in a user action has the intended | |
5926 | effect. | |
5927 | * data/glr.c (yyGLRStack): Remove yytokenp member. | |
5928 | (yyclearin): Don't set *yytokenp. | |
5929 | (yyprocessOneStack, yyreportSyntaxError, yyrecoverSyntaxError): Examine | |
5930 | yychar rather than *yytokenp to determine the current lookahead. | |
5931 | Compute yytoken locally when needed. | |
5932 | (yyparse): Likewise. Remove the local yytoken that yytokenp used to | |
5933 | point to. | |
5934 | ||
5935 | * doc/bison.texinfo (Bison Options): Remove stray sentence fragment | |
5936 | after `--report' documentation. | |
5937 | ||
e2a8c0f5 PE |
5938 | 2006-01-30 Paul Eggert <eggert@cs.ucla.edu> |
5939 | ||
5940 | * src/parse-gram.y (grammar_declaration): Location of printer | |
5941 | symbol is @1, not list->location. Bug reported by twlevo. | |
5942 | * tests/input.at (Incompatible Aliases): Adjust to above change. | |
5943 | ||
6b702268 PE |
5944 | 2006-01-29 Paul Eggert <eggert@cs.ucla.edu> |
5945 | ||
27622431 PE |
5946 | * tests/input.at (AT_CHECK_UNUSED_VALUES): Remove. Instead, do |
5947 | all the test at once. This makes the output easier to read in the | |
5948 | normal case. | |
5949 | ||
6b702268 PE |
5950 | Fix a longstanding bug uncovered by bro-0.9a9/src/parse.y, which I |
5951 | got from <http://bro-ids.org/download.html>. The bug is that | |
5952 | when two actions appeared in succession, the second one was | |
5953 | scanned before the first one was added to the grammar rule | |
5954 | as a midrule action. Bison then output the incorrect warning | |
5955 | "parse.y:905.17-906.36: warning: unused value: $3". | |
5956 | * src/parse-gram.y (BRACED_CODE, action): These are no longer | |
5957 | associated with a value. | |
5958 | (rhs): Don't invoke grammar_current_rule_action_append. | |
5959 | (action): Invoke it here instead. | |
5960 | * src/reader.c (grammar_midrule_action): Now extern. | |
5961 | (grammar_current_rule_action_append): Don't invoke | |
5962 | grammar_midrule_action; that is now the scanner's job. | |
5963 | * src/reader.h (last_string, last_braced_code_loc): | |
5964 | (grammar_midrule_action): New decls. | |
5965 | * src/scan-gram.l (last_string): Now extern, sigh. | |
5966 | (last_braced_code_loc): New extern variable. | |
5967 | (<INITIAL>"{"): Invoke grammar_midrule_action if the current | |
5968 | rule already has an action. | |
5969 | (<SC_BRACED_CODE>"}"): Set last_braced_code_loc before returning. | |
5970 | * tests/input.at (AT_CHECK_UNUSED_VALUES): | |
5971 | Add some tests to check that the above changes fixed the bug. | |
5972 | ||
d40ba6c2 PE |
5973 | 2006-01-27 Paul Eggert <eggert@cs.ucla.edu> |
5974 | ||
5975 | * src/reader.c (symbol_should_be_used): Renamed from symbol_typed_p. | |
5976 | All used changed. Check whether the symbol has a destructor, | |
5977 | not whether it is typed. | |
5978 | * tests/input.at (AT_CHECK_UNUSED_VALUES): Add a destructor, so | |
5979 | that the values are still reported as unused. All line numbers | |
5980 | adjusted. | |
5981 | ||
401aace6 PE |
5982 | 2006-01-23 Paul Eggert <eggert@cs.ucla.edu> |
5983 | ||
5984 | Work around a bug in bro 0.8, which underparenthesizes its | |
5985 | definition of YYLLOC_DEFAULT. | |
5986 | * data/glr.c: Change all uses of YYLLOC_DEFAULT to parenthesize | |
5987 | their arguments. | |
5988 | * data/lalr1.cc: Likewise. | |
5989 | * data/yacc.cc: Likewise. | |
5990 | ||
06f01bc4 PE |
5991 | 2006-01-22 Paul Eggert <eggert@cs.ucla.edu> |
5992 | ||
401aace6 PE |
5993 | Work around a bug in Pike 7.0, and give the Pike folks a |
5994 | better way to override the usual int widths. | |
5995 | * data/yacc.c (b4_int_type): Use yytype_uint8, etc., so that the | |
5996 | user can override the types. | |
5997 | (short): #undef, to work around a bug in Pike 7.0. | |
5998 | (yytype_uint8, yytype_int8, yytype_uint16, yytype_int16): New types. | |
5999 | (union yyalloc.yyss): Use yytype_int16 rather than short. | |
6000 | All uses changed. | |
6001 | (yysigned_char): Remove. | |
6002 | * src/parse-gram.y (YYTYPE_UINT8, YYTYPE_INT8, YYTYPE_UINT16): | |
6003 | (YYTYPE_INT16): New macros, to test the new facility in yacc.c. | |
6004 | * tests/regression.at (Web2c Actions): Adjust to above changes. | |
6005 | ||
6006 | * src/reader.c (check_and_convert_grammar): New function. | |
6007 | (reader): Close the input file even if something went wrong during | |
6008 | parsing. Minor file descriptor leak reported by twlevo. | |
6009 | ||
06f01bc4 PE |
6010 | * src/assoc.c (assoc_to_string): Use a default: abort (); case |
6011 | to pacify gcc -Wswitch-default. | |
6012 | * src/scan-gram.l (adjust_location): Use a default: break; case | |
6013 | to pacify gcc -Wswitch-default. | |
6014 | * src/scan-skel.h (skel_get_lineno, skel_get_in, skel_get_out): | |
6015 | (skel_get_leng, skel_get_text, skel_set_lineno, skel_set_in): | |
6016 | (skel_set_out, skel_get_debug, skel_set_debug, skel_lex_destroy): | |
6017 | Move these decls to scan-skel.l, since they don't need to be | |
6018 | visible elsewhere. | |
6019 | * src/scan-skel.l: Accept the above decls. | |
6020 | (skel_lex): New decl, to pacify GCC when unpatched flex 2.5.31 | |
6021 | is used. | |
6022 | ||
02650b7f PE |
6023 | 2006-01-21 Paul Eggert <eggert@cs.ucla.edu> |
6024 | ||
6025 | * Makefile.cfg (local-checks-to-skip): Add changelog-check, | |
6026 | since we don't want to insist on a version number at the start | |
6027 | of the changelog every time. | |
6028 | * Makefile.maint: Sync from coreutils a bit better. | |
6029 | (sc_trailing_blank): Renamed from sc_trailing_space. | |
6030 | All uses changed. | |
6031 | (sc_no_if_have_config_h, sc_require_config_h): | |
6032 | (sc_prohibit_assert_without_use): New rules. | |
6033 | (sc_obsolete_symbols): Don't catch Makefile.maint itself. | |
6034 | (sc_dd_max_sym_length): Fix leading spaces in rule. | |
6035 | (sc_system_h_headers): Prefix with @. | |
6036 | (sc_useless_cpp_parens, m4-check): Output line numbers. | |
6037 | (changelog-check): Allow version only in head. | |
6038 | * data/c.m4: Use "defined FOO" instead of "defined (FOO)", to | |
6039 | satisfy new Makefile.maint rule. | |
6040 | * data/glr.c: Likewise. | |
6041 | * data/glr.cc: Likewise. | |
6042 | * data/lalr1.cc: Likewise. | |
6043 | * data/yacc.c: Likewise. | |
6044 | * lib/ebitsetv.c: Likewise. | |
6045 | * lib/lbitset.c: Likewise. | |
6046 | * lib/subpipe.c: Likewise. | |
6047 | * lib/timevar.c: Likewise. | |
6048 | * src/system.h: Likewise. | |
6049 | * data/yacc.c (YYSTYPE): Don't generate trailing spaces in output. | |
6050 | * djgpp/Makefile.maint: Add copyright notice. | |
6051 | * djgpp/README.in: Likewise. | |
6052 | * djgpp/config.bat: Likewise. | |
6053 | * djgpp/config.site: Likewise. | |
6054 | * djgpp/config_h.sed: Likewise. | |
6055 | * djgpp/djunpack.bat: Likewise. | |
6056 | * djgpp/config.sed: Fix copyright notice to match standard format. | |
6057 | * djgpp/subpipe.h: Likewise. | |
6058 | * lib/bitsetv-print.c: Likewise. | |
6059 | * lib/bitsetv.c: Likewise. | |
6060 | * lib/subpipe.h: Likewise. | |
6061 | * lib/timevar.c: Likewise. | |
6062 | * lib/timevar.h: Likewise. | |
6063 | * djgpp/subpipe.c: Use standard recipe for config.h. | |
6064 | * lib/abitset.c: Likewise. | |
6065 | * lib/bitset.c: Likewise. | |
6066 | * lib/bitset_stats.c: Likewise. | |
6067 | * lib/bitsetv-print.c: Likewise. | |
6068 | * lib/bitsetv.c: Likewise. | |
6069 | * lib/ebitsetv.c: Likewise. | |
6070 | * lib/get-errno.c: Likewise. | |
6071 | * lib/lbitset.c: Likewise. | |
6072 | * lib/subpipe.c: Likewise. | |
6073 | * lib/timevar.c: Likewise. | |
6074 | * lib/vbitset.c: Likewise. | |
6075 | * tests/local.at: Likewise. | |
6076 | * src/scan-gram.l: Don't include verify.h, since system.h does | |
6077 | that for us. | |
6078 | * .x-sc_require_config_h: New file. | |
6079 | * .x-sc_unmarked_diagnostics: New file. | |
6080 | ||
287c78f6 PE |
6081 | 2006-01-20 Paul Eggert <eggert@cs.ucla.edu> |
6082 | ||
287c78f6 PE |
6083 | Be a bit more systematic about using 'abort'. |
6084 | * lib/abitset.c (abitset_test): Remove ATTRIBUTE_UNUSED; not needed. | |
6085 | * lib/bitset.c (bitset_bytes, bitset_init, bitset_op4_cmp): | |
6086 | Put 'default: abort ();' before some other case, to satisfy older | |
6087 | pedantic compilers. | |
6088 | * lib/bitset_stats.c (bitset_stats_init): Likewise. | |
6089 | * lib/ebitset.c (ebitset_elt_find, ebitset_op3_cmp): Likewise. | |
6090 | * lib/lbitset.c (lbitset_elt_find, lbitset_op3_cmp): Likewise. | |
6091 | * src/conflicts.c (resolve_sr_conflict): Likewise. | |
68cae94e PE |
6092 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str): |
6093 | (get_decision_str, get_orientation_str, get_node_alignment_str): | |
6094 | (get_arrow_mode_str, get_crossing_type_str, get_view_str): | |
6095 | (get_linestyle_str, get_arrowstyle_str): Likewise. | |
6096 | * src/conflicts.c (resolve_sr_conflict): | |
6097 | Use a default case rather than one for the one remaining enum | |
6098 | value, to catch invalid enum values as well. | |
6099 | * src/lalr.c (set_goto_map, map_goto): | |
6100 | Prefer "assert (FOO);" to "if (!FOO) abort ();". | |
6101 | * src/nullable.c (nullable_compute, token_definitions_output): | |
6102 | Likewise. | |
6103 | * src/reader.c (packgram, reader): Likewise. | |
6104 | * src/state.c (transitions_to, state_new, state_reduction_find): | |
6105 | Likewise. | |
6106 | * src/symtab.c (symbol_user_token_number_set, symbol_make_alias): | |
6107 | (symbol_pack): Likewise. | |
6108 | * src/tables.c (conflict_row, pack_vector): Likewise. | |
287c78f6 PE |
6109 | * src/scan-skel.l (QPUTS): Remove unnecessary parens. |
6110 | (BASE_QPUTS, "@output ".*\n): Remove unnecessary asserts. | |
68cae94e PE |
6111 | * src/system.h: Don't include <assert.h>. |
6112 | (assert): New macro. | |
6113 | ||
6114 | * doc/bison.texinfo (Prologue, Rules, Actions, Union Decl, Action Decl): | |
6115 | (Destructor Decl, Parser Function, Pure Calling): | |
6116 | Describe rules for braces inside C code more carefully. | |
287c78f6 | 6117 | |
c66dfadd PE |
6118 | 2006-01-19 Paul Eggert <eggert@cs.ucla.edu> |
6119 | ||
c21493b8 PE |
6120 | Fix some porting glitches found by Nelson H. F. Beebe. |
6121 | * lib/abitset.c (abitset_resize): Rewrite to avoid warnings from | |
6122 | compilers that don't understand that abort () does not return. | |
6123 | * src/state.c (transitions_to): Likewise. | |
6124 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Check | |
6125 | that '#include <cstdlib>' works. | |
6126 | * src/system.h (INT8_MIN, INT16_MIN, INT32_MIN, INT8_MAX): | |
6127 | (INT16_MAX, UINT8_MAX, INT32_MAX, UINT16_MAX, UINT32_MAX): | |
6128 | #undef if ! defined __STDC_VERSION__ || __STDC_VERSION__ < 199901, | |
6129 | for the benefit of some pre-C99 compilers. | |
6130 | ||
b6e3facf PE |
6131 | * bootstrap: Undo changes to gnulib files that autoreconf made. |
6132 | ||
c66dfadd PE |
6133 | Minor fixups to get 'make maintainer-check' to work. |
6134 | * configure.ac: Don't use -Wnested-externs, as it's incompatible | |
6135 | with the new verify.h implementation. | |
6136 | * data/c.m4 (b4_yy_symbol_print_generate): YYUSE (yyoutput). | |
6137 | * data/glr.c (YYUSE): Depend on __GNUC__ as well. | |
6138 | * data/yacc.c (YYUSE): Likewise. | |
6139 | * data/lalr1.cc (yysyntax_error_): YYUSE (yystate). | |
6140 | * lib/subpipe.c (end_of_output_subpipe): The args are unused. | |
6141 | * src/parse-gram.y (declaration): Don't pass a string constant | |
6142 | to a function that expects char *, since GCC might complain | |
6143 | about the constant value. | |
6144 | * src/reader.c (symbol_typed_p): Add parens to pacify GCC. | |
6145 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): #undef yylloc and yylval | |
6146 | before #defining them. | |
6147 | * tests/glr-regression.at | |
6148 | (Incorrectly initialized location for empty right-hand side in GLR): | |
6149 | In yyerror, use the msg arg. | |
6150 | (Corrupted semantic options if user action cuts parse): | |
6151 | (Incorrect lookahead during deterministic GLR): | |
6152 | (Incorrect lookahead during nondeterministic GLR): | |
6153 | Don't name a local var 'index'; it shadows string.h's 'index'. | |
6154 | ||
ed94ef2a AD |
6155 | 2006-01-19 Akim Demaille <akim@epita.fr> |
6156 | ||
6157 | * tests/calc.at (_AT_DATA_CALC_Y): Initialize the whole initial | |
6158 | location, not just parts of it. | |
6159 | ||
e9ad4aec PE |
6160 | 2006-01-18 Paul Eggert <eggert@cs.ucla.edu> |
6161 | ||
d6ca7905 PE |
6162 | * NEWS: Document the fact that multiple %unions are now allowed. |
6163 | * doc/bison.texinfo (Union Decl): Likewise. | |
51cbef6f PE |
6164 | * TODO: This feature is now implemented, so remove it from |
6165 | the wishlist. | |
d6ca7905 | 6166 | |
ef1b70e0 PE |
6167 | * Makefile.maint: Merge with coreutils Makefile.maint. |
6168 | (CVS_LIST): Use build-aux version if available. | |
6169 | (VERSION_REGEXP): New macro. | |
6170 | (syntax-check-rules): Add sc_no_if_have_config_h, | |
6171 | sc_prohibit_assert_without_use, sc_require_config_h, | |
6172 | sc_useless_cpp_parens. | |
6173 | (sc_obsolete_symbols): Check for O_NDELAY. | |
6174 | (sc_dd_max_sym_length): Track coreutils. | |
6175 | (sc_unmarked_diagnostics): Look in all files, not just *.c. | |
6176 | (sc_useless_cpp_parens): New rule. | |
6177 | (news-date-check): Look for version or today's date. | |
6178 | (changelog-check): Don't require version number near head. | |
6179 | (copyright-check): Use current year instead of hardwiring 2005. | |
6180 | (my-distcheck): Depend on $(release_archive_dir)/$(prev-tgz). | |
6181 | (announcement): Add --gpg-key-ID. | |
6182 | ||
6183 | * djgpp/config.sed: Add copyright notice, and replace "filesystem" | |
6184 | with "file system". | |
6185 | ||
2073ce56 | 6186 | Avoid undefined behavior that addressed just before the start of an |
e9ad4aec PE |
6187 | array. Problem reported by twlevo. |
6188 | * src/reader.c (packgram): Prepend a new sentinel before ritem. | |
6189 | * src/lalr.c (build_relations): Rely on new sentinel. | |
6190 | * src/gram.c (gram_free): Adjust to new sentinel. | |
6191 | ||
b7691f15 JD |
6192 | 2006-01-12 Joel E. Denny <jdenny@ces.clemson.edu> |
6193 | ||
6194 | * data/glr.c (yyGLRStateSet): Rename yylookaheadStatuses to | |
6195 | yylookaheadNeeds. All uses updated. | |
6196 | (yysplitStack): Rename local yynewLookaheadStatuses to | |
6197 | yynewLookaheadNeeds. | |
6198 | * data/glr-regression.at (Incorrect lookahead during nondeterministic | |
6199 | GLR): In comments, change `lookahead status' to `lookahead need'. | |
6200 | ||
ddee1b06 PH |
6201 | 2006-01-11 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
6202 | ||
6203 | * data/glr.c (yysplitStack): A little stylistic rewrite. | |
6204 | ||
12f4614d PH |
6205 | 2006-01-11 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
6206 | ||
6207 | * data/glr.c (yyaddDeferredAction): Flesh out the comment. | |
6208 | ||
32c29292 JD |
6209 | 2006-01-11 Joel E. Denny <jdenny@ces.clemson.edu> |
6210 | ||
6211 | * doc/bison.texinfo: Fix some typos. | |
6212 | (GLR Semantic Actions): New subsection discussing special | |
6213 | considerations because GLR semantic actions might be deferred. | |
6214 | (Actions): Mention look-ahead usage of yylval. | |
6215 | (Actions and Locations): Mention look-ahead usage of yylloc. | |
6216 | (Special Features for Use in Actions): Add YYEOF entry and mention it | |
6217 | in the yychar entry. | |
6218 | In the yychar entry, remove mention of the local yychar case (pure | |
6219 | parser) since this is irrelevant information when writing semantic | |
148d66d8 | 6220 | actions and since it's already discussed in `Table of Symbols' where |
32c29292 JD |
6221 | yychar is otherwise described as an external variable. |
6222 | In the yychar entry, don't call it the `current' look-ahead since it | |
6223 | isn't when semantic actions are deferred. | |
6224 | In the yychar and yyclearin entries, add note about deferred semantic | |
6225 | actions. | |
6226 | Add yylloc and yylval entries discussing look-ahead usage. | |
6227 | (Look-Ahead Tokens): When discussing yychar, don't call it the | |
6228 | `current' look-ahead, and do mention yylval and yylloc. | |
6229 | (Error Recovery): Cross-reference `Action Features' when mentioning | |
6230 | yyclearin. | |
148d66d8 | 6231 | (Table of Symbols): In the yychar entry, don't call it the `current' |
32c29292 JD |
6232 | look-ahead. |
6233 | In the yylloc and yylval entries, mention look-ahead usage. | |
6234 | ||
de366a2f | 6235 | 2006-01-08 Joel E. Denny <jdenny@ces.clemson.edu> |
2781dbd1 JD |
6236 | |
6237 | * tests/glr-regression.at: Update copyright year to 2006. | |
6238 | ||
bf70fa87 JD |
6239 | 2006-01-06 Joel E. Denny <jdenny@ces.clemson.edu> |
6240 | ||
6241 | * data/glr.c (yyGLRStateSet): Add yybool* yylookaheadStatuses member to | |
6242 | use during nondeterministic operation to track which stacks have | |
6243 | actually needed the current lookahead. | |
6244 | (yyinitStateSet, yyfreeStateSet, yyremoveDeletes, yysplitStack): | |
6245 | Allocate, deallocate, resize, and otherwise shuffle space for | |
6246 | yylookaheadStatuses in parallel with yystates member of yyGLRStateSet. | |
6247 | (yysplitStack, yyprocessOneStack, yyparse): Set lookahead status | |
6248 | appropriately during nondeterministic operation. | |
6249 | (yySemanticOption): Add int yyrawchar, YYSTYPE yyval, and YYLTYPE yyloc | |
6250 | members to store the current lookahead to be used by the deferred | |
6251 | user action. | |
6252 | (yyaddDeferredAction): Add size_t yyk parameter specifying the stack | |
6253 | from which the RHS is taken. Set the lookahead members of the new | |
6254 | yySemanticOption according to the lookahead status for stack yyk. | |
6255 | (yyglrShiftDefer, yyglrReduce): Pass yyk parameter on to | |
6256 | yyaddDeferredAction. | |
6257 | (yyresolveAction): Set yychar, yylval, and yylloc to the lookahead | |
6258 | members of yySemanticOption before invoking yyuserAction, and then set | |
6259 | them back to their current values afterward. | |
6260 | (yyparse): Set yychar = YYEMPTY where yytoken = YYEMPTY. | |
6261 | (yyreportAmbiguity): Add /*ARGSUSED*/ to pacify lint. | |
6262 | * tests/glr-regression.at: Remove `.' from the ends of recent test case | |
6263 | titles for consistency. | |
6264 | (Leaked merged semantic value if user action cuts parse): In order to | |
6265 | suppress lint warnings, use arguments in merge function, and assign | |
6266 | char value < 128 in main. | |
6267 | (Incorrect lookahead during deterministic GLR): New test case. | |
6268 | (Incorrect lookahead during nondeterministic GLR): New test case. | |
6269 | ||
05449a2c JD |
6270 | 2006-01-06 Joel E. Denny <jdenny@ces.clemson.edu> |
6271 | ||
de366a2f | 6272 | * data/c.m4 (b4_yy_symbol_print_generate): In yy_symbol_print, accept |
05449a2c JD |
6273 | !yyvaluep as signal that no semantic value is available to print. |
6274 | * data/glr.c (yydestroyGLRState): If state is not resolved, don't try | |
6275 | to print a semantic value. | |
6276 | ||
4158e0a1 | 6277 | 2006-01-06 Joel E. Denny <jdenny@ces.clemson.edu> |
fd2493f7 | 6278 | |
4158e0a1 JD |
6279 | * tests/glr-regression.at: For consistency with my newer test cases, |
6280 | don't thank myself. | |
6281 | ||
d659304d JD |
6282 | 2006-01-05 Joel E. Denny <jdenny@ces.clemson.edu> |
6283 | ||
6284 | * data/glr.c (yyresolveValue): When merging semantic options, if at | |
6285 | least one user action succeeds but a later one cuts the parse, then | |
6286 | destroy the semantic value before returning rather than leaking it. | |
6287 | (yyresolveStates): If a user action cuts the parse and thus | |
6288 | yyresolveValue fails, ignore the (unset) semantic value rather than | |
6289 | corrupting the yyGLRState, and empty the semantic options list since | |
6290 | the user actions should have called all necessary destructors. | |
6291 | Simplify code with YYCHK. | |
6292 | * tests/glr-regression.at (Corrupted semantic options if user action | |
6293 | cuts parse): New test case. | |
6294 | (Undesirable destructors if user action cuts parse): New test case. | |
6295 | Before applying any of this patch, this test case never actually failed | |
6296 | for me... but only because the corrupted semantic options usually | |
6297 | masked this bug. | |
6298 | (Leaked merged semantic value if user action cuts parse): New test | |
6299 | case. | |
6300 | ||
6ec2c0f2 AD |
6301 | 2006-01-05 Akim Demaille <akim@epita.fr> |
6302 | ||
6303 | * src/reader.c, src/symlist.h, src/symlist.c: s/mid_rule/midrule/. | |
6304 | ||
1b9c21fb PE |
6305 | 2006-01-04 Paul Eggert <eggert@cs.ucla.edu> |
6306 | ||
6307 | * data/c.m4 (b4_c_modern): New macro, with a new provision for | |
6308 | _MSC_VER. Problem reported by Cenzato Marco. | |
6309 | (b4_c_function_def): Use it. | |
6310 | * data/yacc.c (YYMODERN_C): Remove. All uses replaced by | |
6311 | b4_c_modern. | |
6312 | (yystrlen, yystpcpy, yyparse): Use b4_c_function... macros rather | |
6313 | than rolling our own. | |
6314 | ||
84866159 AD |
6315 | 2006-01-04 Akim Demaille <akim@epita.fr> |
6316 | ||
6317 | Also warn about non-used mid-rule values. | |
6318 | * src/symlist.h, src/symlist.c (symbol_list): Add a mid_rule | |
6319 | member. | |
6320 | (symbol_list_new): Adjust. | |
6321 | * src/reader.c (symbol_typed_p): New. | |
6322 | (grammar_rule_check): Use it. | |
6323 | (grammar_midrule_action): Bind a mid-rule LHS to its rule. | |
6324 | Check its rule. | |
6325 | * tests/input.at (AT_CHECK_UNUSED_VALUES): New. | |
6326 | Use it. | |
6327 | * tests/actions.at (Exotic Dollars): Adjust. | |
6328 | ||
378f4bd8 AD |
6329 | 2006-01-04 Akim Demaille <akim@epita.fr> |
6330 | ||
6331 | * src/reader.c (grammar_midrule_action): If $$ is set in a | |
6332 | mid-rule, move the `used' bit to its lhs. | |
6333 | * tests/input.at (Unused values): New. | |
6334 | * tests/actions.at (Exotic Dollars): Adjust: exp is not typed. | |
6335 | ||
e2a21b6f PE |
6336 | 2006-01-03 Paul Eggert <eggert@cs.ucla.edu> |
6337 | ||
54662697 PE |
6338 | * doc/bison.texinfo (Bison Options): Say more accurately what |
6339 | --yacc does. | |
6340 | * src/parse-gram.y (rules_or_grammar_declaration): Don't complain | |
6341 | about declarations in the grammar when in Yacc mode, as POSIX does | |
6342 | not require a diagnostic when the grammar uses extensions. | |
6343 | ||
6344 | * src/reduce.c (reduce_grammar): Remove unnecessary cast to bool. | |
6345 | ||
073f9288 PE |
6346 | Warn about dubious constructions like "%token T T". |
6347 | Reported by twlevo. | |
6348 | * src/symtab.h (struct symbol.declared): New member. | |
6349 | * src/symtab.c (symbol_new): Initialize it to false. | |
6350 | (symbol_class_set): New arg DECLARING, specifying whether | |
6351 | this is a declaration that we want to warn about, if there | |
6352 | is more than one of them. All uses changed. | |
6353 | ||
1221b78a PE |
6354 | * data/glr.c, data/glr.cc, data/lalr1.cc, data/yacc.c: |
6355 | Allow multiple %union directives, whose contents concatenate. | |
6356 | * src/parse-gram.y (grammar_declaration): Likewise. | |
6357 | Use muscle_code_grow, so that we don't need stype_line any more. | |
6358 | All uses changed. | |
6359 | ||
6360 | * src/muscle_tab.c (muscle_grow): Fix comment. | |
6361 | ||
e2a21b6f PE |
6362 | * ChangeLog, data/c.m4, data/glr.c, data/glr.cc, data/location.cc: |
6363 | * data/yacc.c, src/getargs.c, src/output.c, tests/cxx-type.at: | |
6364 | Update copyright year to 2006. | |
6365 | ||
8f7e3cf9 AD |
6366 | 2006-01-03 Akim Demaille <akim@epita.fr> |
6367 | ||
6368 | Have glr.cc pass (some of) the calc.at tests. | |
6369 | * data/glr.cc (b4_parse_param_orig): New. | |
6370 | (b4_parse_param): Improve its definition, and bound it more | |
6371 | clearly in the skeleton. | |
6372 | (b4_epilogue): Append, instead of prepending, in order to keep | |
6373 | #line consistency. | |
6374 | Simplify the generation of auxiliary functions: locations and | |
6375 | purity are mandated. | |
6376 | (b4_global_tokens_and_yystype): Honor it. | |
6377 | * data/location.cc (c++.m4): Don't include it. | |
6378 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Define AT_GLR_CC_IF | |
6379 | and AT_SKEL_CC_IF. | |
6380 | * tests/calc.at (AT_CHECK_CALC): Rely on AT_SKEL_CC_IF instead of | |
6381 | AT_LALR1_CC_IF. | |
6382 | Be sure to initialize the first position's filename. | |
6383 | (AT_CHECK_CALC_LALR1_CC): Add %location and %defines, they are | |
6384 | mandated anyway. | |
6385 | (AT_CHECK_CALC_GLR_CC): New. | |
6386 | Use it to exercise glr.cc as a lalr1.cc drop-in replacement. | |
6387 | ||
3953ed88 AD |
6388 | 2006-01-02 Akim Demaille <akim@epita.fr> |
6389 | ||
6390 | * src/output.c (output_skeleton): Don't hard wire the inclusion of | |
6391 | c.m4. | |
0a96ba81 | 6392 | * data/c++.m4, data/glr.c, data/yacc.c: Include c.m4. |
3953ed88 AD |
6393 | * data/glr.cc: Do not include stack.hh. |
6394 | ||
9ecafbbf AD |
6395 | 2006-01-02 Joel E. Denny <jdenny@ces.clemson.edu> |
6396 | ||
6397 | * data/glr.c: Reformat whitespace with tabs. | |
6398 | (b4_lpure_formals): Remove this unused m4 macro. | |
6399 | * tests/cxx-type.at: Reformat whitespace with tabs. | |
6400 | (_AT_TEST_GLR_CXXTYPES): In union Node, rename node_info to nodeInfo | |
6401 | since it's a member. Rename type to isNterm for clarity. | |
6402 | ||
c4d497a0 AD |
6403 | 2005-12-29 Akim <akim@sulaco.local> |
6404 | ||
6405 | Let glr.cc catch up with symbol_value_print. | |
6406 | * data/glr.cc (b4_yysymprint_generate): Replace by... | |
6407 | (b4_yy_symbol_print_generate): this. | |
6408 | (yy_symbol_print, yy_symbol_value_print): Declare them. | |
6409 | ||
4517da37 PE |
6410 | 2005-12-28 Paul Eggert <eggert@cs.ucla.edu> |
6411 | ||
6412 | * src/location.h (boundary): Note that a line or column equal | |
6413 | to INT_MAX indicates an overflow. | |
6414 | * src/scan-gram.l: Include verify.h. Don't include get-errno.h. | |
6415 | (rule_length_overflow, increment_rule_length, add_column_width): | |
6416 | New functions. | |
6417 | (<INITIAL>{id}, <SC_ESCAPED_STRING>"\"", <SC_ESCAPED_CHARACTER>"'"): | |
6418 | (<SC_BRACED_CODE>"}"): | |
6419 | Use increment_rule_length rather than incrementing it by hand. | |
6420 | (adjust_location, handle_syncline): Diagnose overflow. | |
6421 | (handle_action_dollar, handle_action_at): | |
6422 | Fix bug with monstrosities like $-2147483648. | |
6423 | Remove now-unnecessary checks. | |
6424 | (scan_integer): Verify assumptions and remove now-unnecessary checks. | |
6425 | (convert_ucn_to_byte): Verify assumptions. | |
6426 | (handle_syncline): New arg LOC. All callers changed. | |
6427 | Don't store through a value derived from char const * pointer. | |
6428 | ||
6429 | * src/reader.c (grammar_rule_check): Rewrite slightly to avoid | |
6430 | GCC warnings. | |
6431 | ||
e3233bf6 PE |
6432 | 2005-12-27 Paul Eggert <eggert@cs.ucla.edu> |
6433 | ||
6434 | * src/reader.c (grammar_midrule_action, grammar_symbol_append): | |
6435 | Remove unnecessary forward static decls. | |
6436 | ||
8f3596a6 AD |
6437 | 2005-12-27 Akim Demaille <akim@epita.fr> |
6438 | ||
6439 | * src/reader.c (grammar_current_rule_check): Also check that $$ | |
6440 | is used. | |
6441 | Take the rule to check as argument, hence rename as... | |
6442 | (grammar_rule_check): this. | |
6443 | * src/reader.h, src/reader.c (grammar_rule_begin, grammar_rule_end): | |
6444 | Rename as... | |
6445 | (grammar_rule_begin, grammar_rule_end): these, for consistency. | |
6446 | (grammar_midrule_action, grammar_symbol_append): Now static. | |
6447 | * tests/torture.at (input): Don't rely on the default action | |
6448 | being always performed. | |
6449 | * tests/calc.at: "Set" $$ even when the action is "cut" with | |
6450 | YYERROR or other. | |
6451 | * tests/actions.at (Exotic Dollars): Instead of using unused | |
6452 | values, check that the warning is issued. | |
6453 | ||
721be13c PE |
6454 | 2005-12-22 Paul Eggert <eggert@cs.ucla.edu> |
6455 | ||
6456 | * NEWS: Improve wording for unused-value warnings. | |
6457 | ||
a0af42fc AD |
6458 | 2005-12-22 Akim Demaille <akim@epita.fr> |
6459 | ||
6460 | * data/lalr1.cc, data/yacc.c, data/glr.c, data/c.m4 | |
6461 | (b4_yysymprint_generate): Rename as... | |
6462 | (b4_yy_symbol_print_generate): this. | |
6463 | Generate yy_symbol_print instead of yysymprint. | |
6464 | Generate also yy_symbol_value_print, and use it. | |
6465 | ||
affac613 AD |
6466 | 2005-12-22 Akim Demaille <akim@epita.fr> |
6467 | ||
721be13c | 6468 | * NEWS: Warn about unused values. |
affac613 AD |
6469 | * src/symlist.h, src/symlist.c (symbol_list, symbol_list_new): Add |
6470 | a `used' member. | |
6471 | (symbol_list_n_get, symbol_list_n_used_set): New. | |
6472 | (symbol_list_n_type_name_get): Use symbol_list_n_get. | |
6473 | * src/scan-gram.l (handle_action_dollar): Flag used symbols. | |
6474 | * src/reader.c (grammar_current_rule_check): Check that values are | |
6475 | used. | |
6476 | * src/symtab.c (symbol_print): Accept 0. | |
6477 | * tests/existing.at: Remove the type information. | |
6478 | Empty the actions. | |
6479 | Remove useless actions (beware of mid-rule actions: perl -000 | |
6480 | -pi -e 's/\s*\{\}(?=[\n\s]*[|;])//g'). | |
6481 | * tests/actions.at (Exotic Dollars): Use unused values. | |
6482 | * tests/calc.at: Likewise. | |
6483 | * tests/glr-regression.at (No users destructors if stack 0 deleted): | |
6484 | Likewise. | |
6485 | ||
6486 | * src/gram.c (rule_useful_p, rule_never_reduced_p): Use | |
6487 | rule_useful_p. | |
6488 | ||
9d9b8b70 PE |
6489 | 2005-12-21 Paul Eggert <eggert@cs.ucla.edu> |
6490 | ||
8bb4c753 PE |
6491 | Undo 2005-12-01 tentative license wording change. The wording is |
6492 | still being reviewed by the lawyers, and we don't want to wait for | |
6493 | them before publishing a test release. For now, revert to the | |
6494 | previous wording. | |
6495 | * NEWS: Undo 2005-12-01 change. | |
6496 | * data/glr.c: Revert to previous license wording. | |
6497 | * data/glr.cc: Likewise. | |
6498 | * data/lalr1.cc: Likewise. | |
6499 | * data/location.cc: Likewise. | |
6500 | * data/yacc.c: Likewise. | |
6501 | ||
9d9b8b70 PE |
6502 | * NEWS: Reword %destructor vs YYABORT etc. |
6503 | * data/glr.c: Use American spacing, for consistency. | |
6504 | * data/glr.cc: Likewise. | |
6505 | * data/lalr1.cc: Likewise. | |
6506 | * data/yacc.c: Likewise. | |
6507 | * data/yacc.c: Reformat comments slightly. | |
6508 | * doc/bison.texinfo: Replace "non-" with "non" when that makes sense, | |
6509 | for consistency. Fix some spelling errors and reword recently-included | |
6510 | text slightly. | |
6511 | * tests/cxx-type.at: Cast results of malloc, for C++. | |
6512 | ||
2c3b392a AD |
6513 | 2005-12-21 Joel E. Denny <address@hidden> |
6514 | ||
6515 | * tests/cxx-type.at: Construct a tree, count the parents of shared | |
6516 | nodes, and free each node once and only once. Previously, the memory | |
6517 | for semantic values was leaked instead. | |
6518 | ||
d6cff4dc AD |
6519 | 2005-12-21 Joel E. Denny <address@hidden> |
6520 | ||
6521 | * data/glr.c (struct yyGLRStack): If pure, add yyval and yyloc members. | |
6522 | (yylval, yylloc): If pure, #define to yystackp->yyval and | |
6523 | yystackp->yyloc similar to yychar and yynerrs. | |
6524 | (yyparse): If pure, remove local yylval and yylloc. Add local | |
6525 | yystackp to accommodate pure definitions of yylval and yylloc. | |
6526 | (b4_lex_param, b4_lyyerror_args, b4_lpure_args): If pure, change | |
6527 | yylvalp and yyllocp to &yylval and &yylloc. | |
6528 | (nerrs, char, lval, lloc): If pure, add #define's for b4_prefix[] | |
6529 | namespace. Previously, nerrs and char were missing, but lval and lloc | |
6530 | weren't necessary. | |
6531 | (yyprocessOneStack, yyreportSyntaxError, yyrecoverSyntaxError): Remove | |
6532 | yylvalp and yyllocp parameters since, if pure, these are now always | |
6533 | accessible through yystackp. If not pure, they are still accessible | |
6534 | globally. | |
6535 | * data/glr.c, data/yacc.c (YYLLOC_DEFAULT): Change `if (N)' to | |
6536 | `if (YYID (N))' to pacify lint. | |
6537 | ||
a85284cf AD |
6538 | 2005-12-21 Akim Demaille <akim@epita.fr> |
6539 | ||
6540 | YYACCEPT, YYERROR, and YYABORT, as user actions, should not | |
6541 | destroy the RHS symbols of a rule. | |
6542 | * data/yacc.c (yylen): Initialize to 0. | |
6543 | Keep its value to the number of items to possibly shift. | |
6544 | In particular, a regular successful parse that ends on YYFINAL by | |
6545 | a (internal) YYACCEPT must not have yylen != 0. | |
6546 | (yyerrorlab, yyreturn): Pop the RHS. | |
6547 | Reorder a bit to emphasize the `shifting' bits of code. | |
6548 | (YYPOPSTACK): Now accept a number of items to pop. | |
6549 | * data/lalr1.cc: Likewise. | |
6550 | * data/glr.c: Formatting changes. | |
6551 | Use goto instead of fall through. | |
6552 | * doc/bison.texinfo (Destructor Decl): Complete. | |
6553 | ||
d508c281 JMG |
6554 | 2005-12-20 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
6555 | ||
6556 | * Makefile.am: DJGPP specific files added to EXTRA_DIST. | |
6557 | * djgpp/Makefile.maint: Fix PACKAGE variable computation. | |
6558 | * djgpp/config.bat: Replace every occurence of the file name | |
6559 | scan-gram-c.c with c-scan-gram.c. The same for scan-skel-c.c with | |
6560 | c-scan-skel.c to conform with the 8.3 file name restriction on MSDOS. | |
6561 | * djgpp/config.sed: Replace every occurence of the file name | |
6562 | scan-gram-c.c with c-scan-gram.c. The same for scan-skel-c.c with | |
6563 | c-scan-skel.c to conform with the 8.3 file name restriction on MSDOS. | |
6564 | * djgpp/djunpack.bat: DJGPP specific file. | |
6565 | * djgpp/fnchange.lst: DJGPP specific file. | |
6566 | * djgpp/README.in: Add new information about how to unpack the bison | |
6567 | source on MSDOS and other systems which have 8.3 file name restrictions | |
6568 | using djunpack.bat and fnchange.lst. | |
6569 | ||
3e7a2cd9 PE |
6570 | 2005-12-12 Paul Eggert <eggert@cs.ucla.edu> |
6571 | ||
6572 | * bootstrap (build_cvs_prefix): Remove; unused. | |
6573 | (CVS_PREFIX): Adjust to yesterday's Savannah reorganization | |
6574 | when getting gnulib. | |
6575 | ||
6576 | 2005-12-12 "Joel E. Denny" <jdenny@ces.clemson.edu> | |
6577 | ||
6578 | * data/glr.c: Reorder typedef declarations for structs to match order | |
6579 | of struct declarations. | |
6580 | Rename yystack everywhere to yystackp except in yyparse where it's not | |
6581 | a pointer. | |
6582 | (yyglrShift): Change parameter YYSTYPE yysval to YYSTYPE* yyvalp for | |
6583 | consistency. | |
6584 | (yyis_table_ninf): Change 0 to YYID (0) to pacify lint. | |
6585 | (yyreportSyntaxError): Add /*ARGSUSED*/ to pacify lint. | |
6586 | (yyparse): Change while (yytrue) to while ( YYID (yytrue)) to pacify | |
6587 | lint. | |
6588 | ||
877519f8 PE |
6589 | 2005-12-09 Paul Eggert <eggert@cs.ucla.edu> |
6590 | ||
0eca5a39 PE |
6591 | * tests/sets.at (Accept): Fix typos in regular expression used to |
6592 | sed out the final state number. | |
6593 | ||
2cec9080 PE |
6594 | Work around portability problem on Solaris 10: flex-generated |
6595 | files include <stdio.h> before <config.h>, which messes up | |
6596 | because the latter defines __EXTENSIONS__. Address the problem | |
6597 | by creating two new little files that include <config.h> first, | |
6598 | then include the flex-generated files. Rewrite everyone else | |
6599 | to include <config.h> first, as well. | |
6600 | * lib/timevar.c: Always include "config.h". | |
6601 | * src/Makefile.am (bison_SOURCES): Replace scan-gram.l with | |
6602 | scan-gram-c.c, and scan-skel.l with scan-skel-c.c. | |
6603 | (EXTRA_bison_SOURCES): New macro. | |
6604 | * src/scan-gram-c.c, src/scan-skel-c.c: New files. | |
6605 | * src/system.h: Don't include config.h. | |
6606 | * src/LR0.c: Include <config.h> first. | |
6607 | * src/assoc.c: Likewise. | |
6608 | * src/closure.c: Likewise. | |
6609 | * src/complain.c: Likewise. | |
6610 | * src/conflicts.c: Likewise. | |
6611 | * src/derives.c: Likewise. | |
6612 | * src/files.c: Likewise. | |
6613 | * src/getargs.c: Likewise. | |
6614 | * src/gram.c: Likewise. | |
6615 | * src/lalr.c: Likewise. | |
6616 | * src/location.c: Likewise. | |
6617 | * src/main.c: Likewise. | |
6618 | * src/muscle_tab.c: Likewise. | |
6619 | * src/nullable.c: Likewise. | |
6620 | * src/output.c: Likewise. | |
6621 | * src/parse-gram.y: Likewise. | |
6622 | * src/print.c: Likewise. | |
6623 | * src/print_graph.c: Likewise. | |
6624 | * src/reader.c: Likewise. | |
6625 | * src/reduce.c: Likewise. | |
6626 | * src/relation.c: Likewise. | |
6627 | * src/state.c: Likewise. | |
6628 | * src/symlist.c: Likewise. | |
6629 | * src/symtab.c: Likewise. | |
6630 | * src/tables.c: Likewise. | |
6631 | * src/uniqstr.c: Likewise. | |
6632 | * src/vcg.c: Likewise. | |
6633 | ||
877519f8 PE |
6634 | * src/parse-gram.y: Fix minor problems uncovered by lint. |
6635 | (current_lhs, current_lhs_location): Now static. | |
6636 | (current_assoc): Remove unused variable. | |
6637 | ||
6638 | Cleanups so that Bison-generated parsers have less lint. | |
6639 | * data/c.m4 (b4_yydestruct_generate, b4_yysymprint_generate): | |
6640 | Prepend /*ARGSUSED*/, for lint's sake. | |
6641 | * data/glr.c (YYUSE): Properly parenthesize, and use an alternate | |
6642 | definition if 'lint' is defined. | |
6643 | (YYID): New macro (or function, if lint). | |
6644 | All uses of /*CONSTCOND*/0 replaced by YYID(0). | |
6645 | * data/yacc.c: Likewise. | |
6646 | * data/glr.c (yyuserAction, yyuserMerge, yy_reduce_print): | |
6647 | (yyrecoverSyntaxError): Prepend /*ARGSUSED*/. | |
6648 | * data/glr.cc (YYLLOC_DEFAULT): Omit /*CONSTCOND*/ since this code | |
6649 | is C++ only. | |
6650 | * data/lalr1.cc (YYUSE): Just use a cast, since this code is C++ only. | |
6651 | * data/yacc.c (YYSTACK_FREE) [defined YYSTACK_ALLOC]: | |
6652 | Use YYID(0) rather than 0, for lint. | |
6653 | (yystrlen): Rewrite to avoid lint warning about ptrdiff_t overflow. | |
6654 | (yysyntax_error): Rewrite to avoid lint warnings about parenthesization. | |
6655 | ||
f5228370 PE |
6656 | 2005-12-07 Paul Eggert <eggert@cs.ucla.edu> |
6657 | ||
6658 | * tests/glr-regression.at | |
6659 | (Improper handling of embedded actions and dollar(-N) in GLR parsers): | |
6660 | Close memory leak reported by twlevo. | |
6661 | ||
69ce078b PE |
6662 | 2005-12-06 "Joel E. Denny" <jdenny@ces.clemson.edu> |
6663 | ||
6ff99711 PE |
6664 | * data/glr.c (yyprocessOneStack, yyparse): Synchronize the shift for |
6665 | all stacks. | |
6666 | (yyparse): Iterate another stack in order to call user destructors. | |
69ce078b PE |
6667 | * tests/glr-regression.at (No users destructors if stack 0 deleted): |
6668 | New test case. | |
6669 | (Duplicated user destructor for lookahead): This test now is expected | |
6670 | to succeed. | |
6671 | ||
af3412cd PE |
6672 | 2005-12-01 Paul Eggert <eggert@cs.ucla.edu> |
6673 | ||
32b5b719 | 6674 | * NEWS: Document the following change. |
af3412cd PE |
6675 | * data/yacc.c: Say "parser skeleton" rather than "file", since |
6676 | it's no longer just a file. | |
6677 | * data/glr.c: Grant a special exception for C GLR parsers, that | |
6678 | reads like the already-existing exception for C LALR(1) parsers. | |
6679 | * data/glr.cc: Likewise. | |
6680 | * data/lalr1.cc: Likewise. | |
6681 | * data/location.cc: Likewise. | |
6682 | * data/yacc.c: Reword the "written by" statement to clarify that | |
6683 | it was the parser skeleton, not the entire output file. | |
6684 | * data/glr.c: Written by Paul Hilfinger. | |
6685 | * data/glr.cc: Written by Akim Demaille. | |
6686 | * data/lalr1.cc: Likewise. | |
6687 | ||
035aa4a0 PE |
6688 | 2005-11-18 Paul Eggert <eggert@cs.ucla.edu> |
6689 | ||
d9963c85 PE |
6690 | * data/yacc.c (yy_reduce_print, YY_REDUCE_PRINT): |
6691 | Fix typos in previous change that broke 'make check'. | |
6692 | YY_REDUCE_PRINT cannot be a pseudo-varargs macro; that isn't | |
6693 | supported in C. | |
6694 | * tests/calc.at (_AT_CHECK_CALC,_AT_CHECK_CALC_ERROR): | |
6695 | Don't check NUM-STDERR-LINES, since the output format is fluctuating. | |
6696 | We can revert this once things settle down. | |
6697 | ||
035aa4a0 PE |
6698 | * src/conflicts.c (conflicts_print): Don't print file name twice |
6699 | when %expect fails because there were no conflicts. | |
6700 | * doc/bison.texinfo (Expect Decl): Tighten up wording in previous | |
6701 | change. | |
6702 | * tests/conflicts.at (%expect not enough, %expect too much): | |
6703 | (%expect with reduce conflicts): Adjust to new behavior. | |
6704 | ||
6705 | 2005-11-18 Akim Demaille <akim@epita.fr> | |
6706 | ||
6707 | * src/conflicts.c (conflicts_print): Unsatisfied %expectation are | |
6708 | errors. | |
6709 | * NEWS: Document this. | |
6710 | * doc/bison.texinfo (Expect Decl): Likewise. | |
6711 | ||
d1ff7a7c AD |
6712 | 2005-11-16 Akim Demaille <akim@epita.fr> |
6713 | ||
6714 | Generalize the display of semantic values and locations in traces. | |
6715 | * data/glr.c (yy_reduce_print): Fix indices (again). | |
6716 | * data/c++.m4 (b4_rhs_value, b4_rhs_location): Don't expect | |
6717 | literal integers. | |
6718 | * data/lalr1.cc (yyreduce_print): Rename as... | |
6719 | (yy_reduce_print): this. | |
6720 | Display values and locations. | |
6721 | * data/yacc.c (yy_reduce_print): Likewise. | |
6722 | (YY_REDUCE_PRINT): Adjust to pass the required arguments. | |
6723 | (yysymprint): Move higher to be visible from yy_reduce_print). | |
6724 | (yyparse): Adjust. | |
6725 | * tests/calc.at: Adjust the expected length of the traces. | |
6726 | ||
6de5398d AD |
6727 | 2005-11-14 Akim Demaille <akim@epita.fr> |
6728 | ||
6729 | * data/glr.c (yy_reduce_print): The loop was quite wrong: type are | |
6730 | from 1 to N, while values and location start at 0. | |
6731 | (b4_rhs_location, b4_rhs_value): Add parens around $1 and $2. | |
6732 | ||
a1373f55 AD |
6733 | 2005-11-14 Akim Demaille <akim@epita.fr> |
6734 | ||
6735 | * data/glr.c (yy_reduce_print): Fix the $ number. | |
6736 | ||
613d8952 AD |
6737 | 2005-11-14 Akim Demaille <akim@epita.fr> |
6738 | ||
6739 | "Use" parse parameters. | |
6740 | * data/c.m4 (b4_parse_param_for, b4_parse_param_use): New. | |
6741 | * data/glr.c, data/glr.cc: Use them. | |
6742 | * data/glr.c (YYUSE): Have a C++ definition that supports | |
6743 | non-pointer types. | |
6744 | ||
b2741627 AD |
6745 | 2005-11-14 Akim Demaille <akim@epita.fr> |
6746 | ||
6747 | * data/glr.c (yyexpandGLRStack): Declare only if defined. | |
6748 | ||
5059b5c8 AD |
6749 | 2005-11-14 Akim Demaille <akim@epita.fr> |
6750 | ||
42249483 AD |
6751 | * data/glr.cc: New. |
6752 | * data/m4sugar/m4sugar.m4 (m4_prepend): New. | |
5059b5c8 | 6753 | |
4626a15d AD |
6754 | 2005-11-12 Akim Demaille <akim@epita.fr> |
6755 | ||
6756 | Let position and location be PODs. | |
6757 | * data/location.cc (position::initialize, location::initialize): New. | |
6758 | (position::position, location::location): Define only if | |
6759 | b4_location_constructors is defined. | |
6760 | * data/lalr1.cc (b4_location_constructors): Define it for backward | |
6761 | compatibility. | |
6762 | * doc/bison.texinfo (Initial Action Decl): Use initialize. | |
6763 | ||
6764 | 2005-11-12 Akim Demaille <akim@epita.fr> | |
98ae9643 AD |
6765 | |
6766 | * data/lalr1.cc: Move the body of the ctor and dtor into the | |
6767 | parser file (instead of the header). | |
6768 | Wrap the implementations in a "namespace yy". | |
6769 | ||
6770 | 2005-11-12 Akim Demaille <akim@epita.fr> | |
6771 | ||
6772 | Have glr.c include its header file when created. | |
6773 | * data/glr.c (b4_shared_declarations): New. | |
6774 | Output them verbatim in the parser if !%defines, otherwise | |
6775 | output then in the header file, and include it instead. | |
6776 | ||
1989d947 AD |
6777 | 2005-11-11 Akim Demaille <akim@epita.fr> |
6778 | ||
6779 | * data/glr.c: Comment changes. | |
6780 | ||
6781 | 2005-11-11 Akim Demaille <akim@epita.fr> | |
62b08cfc AD |
6782 | |
6783 | When yydebug, report semantic and location values for reductions. | |
6784 | * data/glr.c (yy_reduce_print): Report the semantic values and the | |
6785 | locations. | |
6786 | (YY_REDUCE_PRINT): Adjust. | |
6787 | (yyglrReduce): Use them. | |
6788 | (b4_rhs_value, b4_rhs_location): Remove m4_eval invocations. | |
6789 | * data/c.m4 (b4_yysymprint_generate): Specify the const arguments. | |
6790 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Remove the reduction | |
6791 | traces. | |
6792 | ||
02998094 AD |
6793 | 2005-11-10 Akim Demaille <akim@epita.fr> |
6794 | ||
6795 | * data/glr.c (yynewGLRStackItem, YY_RESERVE_GLRSTACK): New. | |
6796 | (yyaddDeferredAction, yyglrShift, yyglrShiftDefer): Use them. | |
6797 | (yyexpandGLRStack, YYRELOC): Define only when YYSTACKEXPANDABLE. | |
6798 | ||
5210672f PE |
6799 | 2005-11-09 Albert Chin-A-Young <china@thewrittenword.com> |
6800 | ||
6801 | * m4/cxx.m4, examples/Makefile.am: Don't build | |
6802 | examples/calc++ if no C++ compiler is available. (trivial change) | |
6803 | ||
a8991a1d AD |
6804 | 2005-11-09 Akim Demaille <akim@epita.fr> |
6805 | ||
6806 | * src/scan-skel.l: Use a couple of asserts. | |
6807 | ||
36b5e963 AD |
6808 | 2005-11-03 Akim Demaille <akim@epita.fr> |
6809 | ||
6810 | In some (weird) cases, the final state number is incorrect. | |
6811 | Reported by Alexandre Duret-Lutz. | |
6812 | * src/LR0.c (state_list_append): Remove the computation of | |
6813 | final_state. | |
6814 | (save_reductions): Do it here. | |
6815 | (get_state): Alpha conversion. | |
6816 | (generate_states): Use a for loop. | |
6817 | * src/gram.h (item_number_is_rule_number) | |
6818 | (item_number_is_symbol_number): New. | |
6819 | * src/state.c: Use assert. | |
6820 | * src/system.h: Include assert.h. | |
6821 | * tests/sets.at (Accept): New. | |
6822 | ||
44e7ead1 PH |
6823 | 2005-10-30 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
6824 | ||
6825 | * data/glr.c (yyfill): Adjust comment. | |
36b5e963 | 6826 | (yyresolveAction): Initialize default location properly |
44e7ead1 PH |
6827 | for empty right-hand sides. |
6828 | (yydoAction): Ditto. | |
6829 | Add comment explaining apparently dead code. | |
36b5e963 AD |
6830 | * tests/glr-regression.at |
6831 | (Incorrectly initialized location for empty right-hand side in GLR): | |
44e7ead1 | 6832 | New test. |
36b5e963 | 6833 | |
e10a80ee PE |
6834 | 2005-10-30 Paul Eggert <eggert@cs.ucla.edu> |
6835 | ||
6836 | * bootstrap (cleanup_gnulib): New function. Use it to clean up | |
6837 | gnulib when interrupted. This fixes some race conditions and | |
6838 | works around some portability problems (one noted by Paul | |
6839 | Hilfinger). | |
6840 | ||
067b32ee AD |
6841 | 2005-10-22 Akim <akim@epita.fr> |
6842 | ||
6843 | * Makefile.cfg: Adjust to config -> build-aux. | |
6844 | Reported by twledo. | |
6845 | ||
4b367315 AD |
6846 | 2005-10-21 Akim Demaille <akim@epita.fr> |
6847 | ||
6848 | * data/c.m4 (b4_yydestruct_generate, b4_yysymprint_generate): Pass | |
6849 | the %parse-params. | |
6850 | * data/glr.c (YY_SYMBOL_PRINT, yydestroyGLRState): Adjust. | |
6851 | * data/yacc.c (b4_Pure_if): Rename as... | |
6852 | (b4_yacc_pure_if): this. | |
6853 | (YY_SYMBOL_PRINT, yyparse): Adjust. | |
6854 | * doc/bison.texinfo: Formatting changes. | |
6855 | ||
24cc23d9 AD |
6856 | 2005-10-21 Akim Demaille <akim@epita.fr> |
6857 | ||
6858 | Finish the transition config -> build-aux. | |
6859 | * configure.ac, Makefile.am: Use build-aux. | |
6860 | * config/prev-version, config/announce-gen, config/Makefile.am: | |
6861 | Move to... | |
6862 | * build-aux/prev-version, build-aux/announce-gen, | |
6863 | * build-aux/Makefile.am: here. | |
6864 | ||
d4476375 AD |
6865 | 2005-10-14 Akim Demaille <akim@epita.fr> |
6866 | ||
6867 | * examples/calc++/test: Use set -x only when VERBOSE. | |
6868 | ||
302c0aee PE |
6869 | 2005-10-13 Paul Eggert <eggert@cs.ucla.edu> |
6870 | ||
6871 | * NEWS: Bison now warns if it finds a stray `$' or `@' in an action. | |
6872 | * src/scan-gram.l (<SC_BRACED_CODE>[$@]): Implement this. | |
6873 | ||
7625ec2c AD |
6874 | 2005-10-13 Akim Demaille <akim@epita.fr> |
6875 | ||
6876 | * src/scan-skel.l: Output the base name parts of the parser and | |
6877 | header file names. | |
302c0aee | 6878 | * tests/output.at (AT_CHECK_OUTPUT): Support subdirectories, and |
7625ec2c AD |
6879 | additional checks. |
6880 | Use this to exercise C++ outputs in subdirs. | |
6881 | Reported by Oleg Smolsky. | |
6882 | ||
ba0fe3c7 PE |
6883 | 2005-10-12 Paul Eggert <eggert@cs.ucla.edu> |
6884 | ||
6885 | * data/c.m4 (b4_c_function_def): Look at __C99_FUNC__, not at | |
6886 | __STDC_VERSION__, as IBM cc 7.0 doesn't define the latter either. | |
6887 | Problem reported by John P. Hartmann. | |
6888 | * data/yacc.c (YYMODERN_C): Likewise. Don't define if the user has | |
6889 | already defined it. | |
6890 | ||
9b8a5ce0 AD |
6891 | 2005-10-12 Akim Demaille <akim@epita.fr> |
6892 | ||
6893 | * src/parse-gram.y (version_check): Exit 63 to please missing | |
6894 | (stands for "version mismatch). | |
6895 | * tests/input.at, doc/bison.texinfo: Adjust. | |
6896 | ||
4f6e011e PE |
6897 | 2005-10-10 Paul Eggert <eggert@cs.ucla.edu> |
6898 | ||
6899 | Work around portability problems with Visual Age C compiler | |
6900 | (xlc and xlC_r) reported by John P. Hartmann. | |
6901 | * data/location.cc (initial_column, initial_line): Remove. | |
6902 | All uses replaced by 0 and 1. | |
6903 | * src/scan-gram.l (gram_wrap): Redefine to avoid bug in flex 2.5.31 | |
6904 | that xlc complains about. | |
6905 | * src/scan-skel.l (skel_wrap): Likewise. | |
4d7aa45e | 6906 | * data/c.m4 (b4_c_function_def): Look at __STDC_VERSION__ as well |
ba0fe3c7 | 6907 | as __STDC__. |
4d7aa45e PE |
6908 | * data/yacc.c (YYMODERN_C): New macro, which also looks at |
6909 | __STDC_VERSION__. Use it everywhere instead of looking at | |
6910 | __STDC__ and __cplusplus. | |
4f6e011e | 6911 | |
a1b3bf8c AD |
6912 | 2005-10-10 Akim Demaille <akim@epita.fr> |
6913 | ||
6914 | * examples/calc++/test: Be quiet unless VERBOSE. | |
6915 | ||
412e44aa PE |
6916 | 2005-10-05 Paul Eggert <eggert@cs.ucla.edu> |
6917 | ||
2a4647a3 PE |
6918 | * data/c.m4 (yydestruct, yysymprint): |
6919 | Use YYUSE instead of casting to void. | |
6920 | * data/glr.c (YYUSE): New macro. | |
6921 | (yyuserMerge, yyreportAmbiguity, yyreportSyntaxError): | |
6922 | Use it instead of rolling our own. | |
6923 | (YYLLOC_DEFAULT, YYCHK, YYDPRINTF, YY_SYMBOL_PRINT, YY_REDUCE_PRINT): | |
6924 | (YYCHK1): | |
6925 | Use /*CONSTCOND*/ to suppress lint warnings. | |
6926 | * data/lalr1.cc (YYLLOC_DEFAULT, YY_SYMBOL_PRINT, YY_REDUCE_PRINT): | |
6927 | (YY_STACK_PRINT): Use 'false' not '0'. | |
6928 | (YYUSE): New macro. | |
6929 | (yysymprint_, yydestruct_): Use it instead of rolling our own. | |
6930 | * data/yacc.c (YYUSE): New macro. | |
6931 | (YYCOPY, YYSTACK_RELOCATE, YYBACKUP, YYLLOC_DEFAULT): | |
6932 | (YYDPRINTF, YY_SYMBOL_PRINT, YY_STACK_PRINT, YY_REDUCE_PRINT): | |
6933 | (yyerrorlab): Use /*CONSTCOND*/ to suppress lint warnings. | |
6934 | ||
6935 | ||
412e44aa PE |
6936 | * data/m4sugar/m4sugar.m4 (_m4_map): New macro. |
6937 | (m4_map, m4_map_sep): Use it. Handle the empty list correctly. | |
6938 | ||
88c6637f PE |
6939 | 2005-10-04 Paul Eggert <eggert@cs.ucla.edu> |
6940 | ||
2f4f028d PE |
6941 | Undo the parts of the unlocked-I/O change that substituted |
6942 | putc or puts for printf. This might hurt performance a bit, | |
6943 | but some people prefer the printf style. | |
6944 | * data/c.m4 (yysymprint): Prefer printf to puts and putc. | |
6945 | * data/glr.c (YYFPUTC, YYFPUTS, YYDPUTS): Remove. | |
6946 | All uses replaced by YYFPRINTF and YYDPRINTF. | |
6947 | * data/yacc.c: Likewise. | |
6948 | * lib/bitset.c (bitset_print): Likewise. | |
6949 | * lib/bitsetv.c (bitsetv_dump, debug-bitsetv): Prefer printf to | |
6950 | putc and puts. | |
6951 | * lib/lbitset.c (debug_lbitset): Likewise. | |
6952 | * src/closure.c (print_firsts, print_fderives): Likewise. | |
6953 | * src/gram.c (grammar_dump): Likewise. | |
6954 | * src/lalr.c (look_ahead_tokens_print): Likewise. | |
6955 | * src/output.c (escaped_output): Likewise. | |
6956 | (user_actions_output): Break apart two printfs. | |
6957 | * src/parse-gram.y (%printer): Prefer printf to putc and puts. | |
6958 | * src/reduce.c (reduce_print): Likewise. | |
6959 | * src/state.c (state_rule_look_ahead_tokens_print): Likewise. | |
6960 | * src/system.h: Include unlocked-io.h rathe than stdio.h. | |
6961 | ||
88c6637f PE |
6962 | * data/glr.c (yyuserMerge, yyreportAmbiguity, yyreportSyntaxError): |
6963 | Use assignments rather than casts-to-void to suppress | |
6964 | unused-variable warnings. This pacifies 'lint'. | |
6965 | * data/lalr1.cc (yysymprint_, yydestruct_): Use a call to suppress | |
6966 | unused-variable warnings. | |
6967 | ||
fb32e373 JMG |
6968 | 2005-10-03 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
6969 | ||
6970 | * Makefile.am: DJGPP specific files added to EXTRA_DIST. | |
6971 | ||
edb8f44f PE |
6972 | 2005-10-02 Paul Eggert <eggert@cs.ucla.edu> |
6973 | ||
fb9c0b33 PE |
6974 | Use unlocked I/O for a minor performance improvement on hosts like |
6975 | GNU/Linux and Solaris that support unlocked I/O. The basic idea | |
6976 | is to use the gnlib unlocked-io module, and to prefer putc and | |
6977 | puts to printf when either will work (since the latter doesn't | |
6978 | come in an unlocked flavor). | |
6979 | * bootstrap (gnulib_modules): Add unlocked-io. | |
6980 | * data/c.m4 (yysymprint): Prefer puts and putc to printf. | |
6981 | * data/glr.c (YYFPUTC, YYFPUTS, YYDPUTS): New macros. | |
6982 | Prefer them to YYFPRINTF and YYDPRINTF if either will do, | |
6983 | and similarly for puts and putc and printf. | |
6984 | * data/yacc.c: Likewise. | |
6985 | * lib/bitset.c (bitset_print): Likewise. | |
6986 | * lib/bitset.h [USE_UNLOCKED_IO]: Include unlocked-io.h. | |
6987 | * lib/bitsetv.c (bitsetv_dump, debug-bitsetv): Prefer putc and puts | |
6988 | to printf. | |
6989 | * lib/lbitset.c (debug_lbitset): Likewise. | |
6990 | * src/closure.c (print_firsts, print_fderives): Likewise. | |
6991 | * src/gram.c (grammar_dump): Likewise. | |
6992 | * src/lalr.c (look_ahead_tokens_print): Likewise. | |
6993 | * src/output.c (escaped_output): Likewise. | |
6994 | (user_actions_output): Coalesce two printfs. | |
2f4f028d | 6995 | * src/parse-gram.y (%printer): Prefer putc and puts to printf. |
fb9c0b33 PE |
6996 | * src/reduce.c (reduce_print): Likewise. |
6997 | * src/state.c (state_rule_look_ahead_tokens_print): Likewise. | |
2f4f028d | 6998 | * src/system.h: Include unlocked-io.h rather than stdio.h. |
fb9c0b33 | 6999 | |
edb8f44f PE |
7000 | * data/lalr1.cc: Don't put an unmatched ' in a dnl comment, as |
7001 | this confuses xgettext. | |
7002 | ||
b50d2359 AD |
7003 | 2005-10-02 Akim Demaille <akim@epita.fr> |
7004 | ||
7005 | * bootstrap (gnulib_modules): Add strverscmp. | |
7006 | * lib/.cvsignore: Add strverscmp.c, strverscmp.h. | |
7007 | * m4/.cvsignore: Add strverscmp.m4. | |
7008 | * src/parse-gram.y (%require): New token, new rule. | |
7009 | (version_check): New. | |
7010 | * src/scan-gram.l (%require): Adjust. | |
7011 | * tests/input.at (AT_REQUIRE): New. | |
7012 | Use it. | |
7013 | * doc/bison.texinfo (Require Decl): New. | |
7014 | (Calc++ Parser): Use %require. | |
7015 | ||
21667f64 AD |
7016 | 2005-10-02 Akim Demaille <akim@epita.fr> |
7017 | ||
7018 | * data/location.cc: New. | |
7019 | ||
2b81e969 AD |
7020 | 2005-10-02 Paul Eggert <eggert@cs.ucla.edu>, |
7021 | Akim Demaille <akim@epita.fr> | |
7022 | ||
7023 | Make sure -odir/foo.cc creates dir/location.hh etc. | |
7024 | * src/files.h (spec_outfile, parser_file_name, spec_name_prefix) | |
7025 | (spec_file_prefix, spec_verbose_file, spec_graph_file) | |
7026 | (spec_defines_file): Now const. | |
7027 | (dir_prefix): New. | |
7028 | (short_base_name): Remove. | |
7029 | * src/files.c: Adjust. | |
7030 | (dirname.h): Include. | |
7031 | (base_name): Don't prototype it. | |
7032 | (finput): Remove, duplicates gram_in. | |
7033 | (full_base_name, short_base_name): Replace by... | |
7034 | (all_but_ext, all_but_tab_ext): these. | |
7035 | (compute_base_names): Rename as... | |
7036 | (compute_file_name_parts): this. | |
7037 | Update to compute the new variables, including dir_prefix. | |
7038 | Adjust dependencies. | |
7039 | * src/output.c (prepare): Output them. | |
7040 | * src/reader.c: Adjust to use gram_in, not finput. | |
7041 | * src/scan-skel.l (@dir_prefix@): New. | |
7042 | ||
ad6a9b97 JMG |
7043 | 2005-10-02 Juan Manuel Guerrero <juan.guerrero@gmx.de> |
7044 | ||
7045 | * lib/subpipe.c: New function end_of_output_subpipe() added | |
7046 | to allow support for non-posix systems. This is a no-op function | |
7047 | for posix systems. | |
7048 | ||
7049 | * lib/subpipe.h: New function end_of_output_subpipe() added | |
7050 | to allow support for non-posix systems. This is a no-op function | |
7051 | for posix systems. | |
7052 | ||
7053 | * src/output.c (output_skeleton): Use end_of_output_subpipe() to | |
7054 | handle the lack of pipe/fork functionality on non-posix systems. | |
7055 | ||
7056 | * djgpp/Makefile.maint: DJGPP specific file. | |
7057 | ||
7058 | * djgpp/README.in: DJGPP specific file. | |
7059 | ||
7060 | * djgpp/config.bat: DJGPP specific configuration file. | |
7061 | ||
7062 | * djgpp/config.sed: DJGPP specific configuration file. | |
7063 | ||
7064 | * djgpp/config.site: DJGPP specific configuration file. | |
7065 | ||
7066 | * djgpp/config_h.sed: DJGPP specific configuration file. | |
7067 | ||
7068 | * djgpp/subpipe.c: DJGPP specific replacement file for lib/subpipe.c. | |
7069 | ||
7070 | * djgpp/subpipe.h: DJGPP specific replacement file for lib/subpipe.h. | |
7071 | ||
fc695704 AD |
7072 | 2005-10-02 Akim Demaille <akim@epita.fr> |
7073 | ||
7074 | * data/location.cc: New, extract from... | |
7075 | * data/lalr1.cc: here. | |
7076 | (location.hh): Include it after the user prologue, in case the | |
7077 | filename type is defined by the user. | |
7078 | Forward declation location and position before the pre-prologue. | |
7079 | (yyresult_): Rename as... | |
7080 | (yyresult): this, it's a local variable, not an attribute. | |
7081 | * data/Makefile.am (dist_pkgdata_DATA): Adjust. | |
7082 | ||
7083 | 2005-10-01 Akim Demaille <akim@epita.fr> | |
5215c87f AD |
7084 | |
7085 | * examples/extexi: Restore the #line generation. | |
7086 | ||
fb9712a9 AD |
7087 | 2005-09-30 Akim Demaille <akim@epita.fr>, |
7088 | Alexandre Duret-Lutz <adl@gnu.org> | |
7089 | ||
7090 | Move the token type and YYSTYPE in the parser class. | |
7091 | * data/lalr1.cc (stack.hh, location.hh): Include earlier. | |
7092 | (parser::token): New, from the moved free definition of tokens. | |
7093 | (parser::semantic_value): Now a full definition instead of an | |
7094 | indirection to YYSTYPE. | |
7095 | (b4_post_prologue): No longer included in the header file, but | |
7096 | in the implementation file. | |
7097 | * doc/bison.texi (C+ Language Interface): Update. | |
7098 | * src/parse-gram.y: Support unary %define. | |
7099 | * tests/actions.at: Define global_tokens_and_yystype for backward | |
7100 | compatibility until we update the tests. | |
7101 | * tests/calc.at: Idem. | |
7102 | (first_line, first_column, last_line, last_column): Define for lalr1.cc | |
7103 | to simplify the code. | |
7104 | ||
55f0c7b1 PE |
7105 | 2005-09-29 Paul Eggert <eggert@cs.ucla.edu> |
7106 | ||
7107 | Port to SunOS 4.1.4, which lacks strtoul and strerror. | |
7108 | Ah, the good old days! Problem reported by Peter Klein. | |
7109 | * bootstrap (gnulib_modules): Add strerror, strtoul. | |
7110 | * lib/.cvsignore: Add strerror.c, strtol.c, strtoul.c | |
7111 | * m4/.cvsignore: Add strerror.m4, strtol.m4, strtoul.m4. | |
7112 | ||
fb9712a9 | 7113 | 2005-09-29 Akim Demaille <akim@epita.fr> |
d4fb5e3c AD |
7114 | |
7115 | * data/c.m4 (b4_error_verbose_if): New. | |
7116 | * data/lalr1.cc: Use it. | |
7117 | (YYERROR_VERBOSE_IF): Remove. | |
7118 | (yyn_, yylen_, yystate_, yynerrs_, yyerrstatus_): Remove as | |
7119 | parser members, replaced by... | |
7120 | (yyn, yylen, yystate, yynerss, yyerrstatus): these parser::parse | |
7121 | local variables. | |
7122 | (yysyntax_error_): Takes the state number as argument. | |
7123 | (yyreduce_print_): Use the argument yyrule, not the former | |
7124 | attribute yyn_. | |
7125 | ||
8a6f72f3 PE |
7126 | 2005-09-26 Paul Eggert <eggert@cs.ucla.edu> |
7127 | ||
7128 | * bootstrap (gnulib_modules): Add verify. | |
7129 | * lib/.cvsignore: Add verify.h. | |
7130 | * src/getargs.c: Use ARGMATCH_VERIFY rather than verify. | |
7131 | * src/system.h (verify): Remove. | |
7132 | Include verify.h instead. | |
7133 | * src/tables.c (tables_generate): Use new API for 'verify'. | |
7134 | ||
0d50976f PE |
7135 | 2005-09-21 Paul Eggert <eggert@cs.ucla.edu> |
7136 | ||
ebc3737e PE |
7137 | * tests/local.at (_AT_BISON_OPTION_PUSHDEFS): Do not use |
7138 | local variables whose names begin with 'yy'. | |
7139 | * tests/calc.at (_AT_DATA_CALC_Y): Likewise. | |
7140 | Trivial changes from Joel E. Denny. | |
7141 | ||
0d50976f PE |
7142 | * bootstrap (gnulib_modules): Remove alloca. Bison doesn't need |
7143 | it itself. | |
7144 | * src/main.c (main) [C_ALLOCA]: Don't flush alloca'ed memory; we | |
7145 | don't use alloca any more. | |
7146 | ||
7147 | * data/yacc.c [YYSTACK_USE_ALLOCA && !defined __GNUC__ && ! defined | |
7148 | __BUILTIN_VA_ARG_INCR && ! defined _AIX && ! defined _MSC_VER && | |
62c4328e | 7149 | defined _ALLOCA_H]: Don't include <stdlib.h>; not needed in this case. |
0d50976f PE |
7150 | * tests/torture.at (Exploding the Stack Size with Alloca): Adjust |
7151 | to match yacc.c, to test more hosts. | |
7152 | ||
a05b79df PE |
7153 | 2005-09-20 Paul Eggert <eggert@cs.ucla.edu> |
7154 | ||
55289366 PE |
7155 | * data/yacc.c (YYSIZE_T): Reindent to make it clearer. This |
7156 | doesn't affect behavior. | |
7157 | (YYSTACK_ALLOC) [YYSTACK_USE_ALLOCA]: Improve support for | |
7158 | Solaris, AIX, MSC. | |
7159 | (_STDLIB_H): Renamed from YYINCLUDED_STDLIB_H. All uses changed. | |
7160 | This works a bit better with glibc, if user code has already included | |
7161 | stdlib.h. | |
7162 | * doc/bison.texinfo (Bison Parser): Document that users can't | |
7163 | arbitrarily use malloc and free for other purposes. Document | |
7164 | that <alloca.h> and <malloc.h> might be included. | |
7165 | (Table of Symbols): Under YYSTACK_USE_ALLOCA, Don't claim that the | |
7166 | user must declare alloca. | |
7167 | ||
a05b79df PE |
7168 | * HACKING (release): Forwarn the Translation Project about |
7169 | stable releses. | |
7170 | ||
3ab2ca22 AD |
7171 | 2005-09-20 Akim Demaille <akim@epita.fr> |
7172 | ||
7173 | * data/glr.c: Use b4_token_enums, not b4_token_enums_defines. | |
7174 | ||
a9739e7c PE |
7175 | 2005-09-19 Paul Eggert <eggert@cs.ucla.edu> |
7176 | ||
a702593e PE |
7177 | * data/yacc.c (YYSIZE_MAXIMUM): New macro. |
7178 | (YYSTACK_ALLOC_MAXIMUM): Use it. | |
7179 | (yysyntax_error): New function. | |
7180 | (yyparse) [YYERROR_VERBOSE]: Don't leak memory indefinitely if | |
7181 | multiple syntax errors are reported, and alloca is being used. | |
7182 | Instead, reallocate buffers twice as big each time, so that | |
7183 | we waste at most half the allocated memory. Start with a small | |
7184 | (128-byte) buffer that will suffice in most cases anyway. | |
7185 | Use yysyntax_error to do most of the work. | |
7186 | ||
7187 | * doc/bison.texinfo (Error Reporting, Table of Symbols): | |
7188 | yynerrs is the number of errors reported, not the number of | |
7189 | errors encountered. | |
7190 | ||
a9739e7c PE |
7191 | * tests/glr-regression.at (Duplicated user destructor for lookahead): |
7192 | Mark it as expected to fail. | |
7193 | Cast result of malloc; problem reported by twlevo@xs4all.nl. | |
7194 | * tests/actions.at, tests/calc.at, tests/glr-regression.at: | |
7195 | Don't start user-code symbols with "yy", to avoid name space problems. | |
7196 | ||
f479c6c6 AD |
7197 | 2005-09-19 Akim Demaille <akim@epita.fr> |
7198 | ||
7199 | Remove the traits, failed experiment. | |
7200 | It never proved useful, and anyway because of the current | |
7201 | definition, it was not possible to have several specialization of | |
7202 | this traits, making it useless. | |
7203 | * data/lalr1.cc (yy:traits): Remove. | |
7204 | Inline its definitions in the parser class. | |
7205 | ||
e2586f82 AD |
7206 | 2005-09-19 Akim Demaille <akim@epita.fr> |
7207 | ||
7208 | * tests/atlocal.in (LIBS): Pass INTLLIBS to address failures on at | |
7209 | least Mac OSX with a /usr/local install of gettext. | |
7210 | ||
2e8cf949 AD |
7211 | 2005-09-19 Akim Demaille <akim@epita.fr> |
7212 | ||
7213 | * data/lalr1.cc (yyparse): Rename yylooka and yyilooka as yychar | |
7214 | and yytoken for similarity with the other skeletons. | |
7215 | ||
c7fb0b90 AD |
7216 | 2005-09-19 Akim Demaille <akim@epita.fr> |
7217 | ||
4e26c69e | 7218 | * NEWS, configure.ac: update version number to 2.1a. |
c7fb0b90 | 7219 | |
1bd0deda PE |
7220 | 2005-09-16 Paul Eggert <eggert@cs.ucla.edu> |
7221 | ||
7222 | * NEWS: Version 2.1. | |
7223 | ||
7224 | * NEWS: Remove notice of yytname change, since it was never in an | |
7225 | official release. | |
7226 | * data/glr.c (yydestroyGLRState): Rename local var to avoid shadowing | |
7227 | diagnostic. | |
7228 | * src/output.c (prepare): Likewise. | |
7229 | * data/lalr1.cc (YYERROR_VERBOSE_IF): New macro. | |
7230 | (yysyntax_error_): Use it to avoid GCC warning when YYERROR_VERBOSE | |
7231 | is not defined. This is an awful hack, but it's enough for now. | |
7232 | All callers changed. | |
7233 | * tests/glr-regression-at (make_value): Args are const pointers now, | |
7234 | to avoid GCC warning. | |
7235 | (Duplicated user destructor for lookahead): New test. Currently | |
7236 | skipped. It fails on my host but I'm not sure it'll always fail. | |
7237 | ||
7238 | 2005-09-16 Akim Demaille <akim@epita.fr> | |
c1432f65 AD |
7239 | |
7240 | * src/symtab.h (struct symbol): Declare the printer and destructor | |
7241 | as const, to avoid accidental calls to free. | |
7242 | (symbol_destructor_set, symbol_printer_set): Adjust. | |
7243 | * src/symtab.c: Adjust. | |
7244 | ||
1bd0deda | 7245 | 2005-09-16 Akim Demaille <akim@epita.fr> |
cf147260 AD |
7246 | |
7247 | * data/c.m4 (b4_token_enums): New. | |
7248 | (b4_token_defines): Rename as... | |
7249 | (b4_token_enums_defines): this. | |
7250 | (b4_token_defines): New, output only the #defines. | |
7251 | * data/yacc.c, data/glr.c: Adjust. | |
7252 | * data/lalr1.cc: Use b4_token_enums instead of b4_token_enums_defines. | |
7253 | * data/c.m4 (b4_yydestruct_generate, b4_yysymprint_generate): Define | |
7254 | as default values. | |
7255 | ||
dbcdae2d AD |
7256 | 2005-09-16 Akim Demaille <akim@epita.fr> |
7257 | ||
7258 | * data/lalr1.cc (yylex_): Remove, inline its code. | |
7259 | (yyreport_syntax_error_): Remove, replaced by... | |
7260 | (yysyntax_error_): this which returns a string and leaves to the | |
7261 | caller the call to the users' error function. | |
7262 | (yylooka_, yyilooka_, yylval, yylloc, yyerror_range_, yyval, yyloc): | |
7263 | Move from members of the parser object... | |
7264 | (yylooka, yyilooka, yylval, yylloc, yyerror_range, yyval, yyloc): | |
7265 | to local variables of the parse function. | |
7266 | ||
70d8f291 AD |
7267 | 2005-09-16 Akim Demaille <akim@epita.fr> |
7268 | ||
7269 | * doc/bison.texinfo (Calc++ Parser): Don't promote defining YYEOF | |
7270 | since it's in Bison's name space. | |
7271 | ||
b47dbebe PE |
7272 | 2005-09-15 Paul Eggert <eggert@cs.ucla.edu> |
7273 | ||
ae199bf1 PE |
7274 | * data/glr.c (yyresolveValue): Add default case to pacify |
7275 | gcc -Wswitch-default. Problem reported by twlevo@xs4all.nl. | |
7276 | ||
b47dbebe PE |
7277 | * NEWS: Document when yyparse started to return 2. |
7278 | * doc/bison.texinfo (Parser Function): Document when yyparse | |
7279 | returns 2. | |
7280 | ||
7281 | * data/lalr1.cc: Revert part of previous change, as it's incompatible. | |
7282 | (b4_filename_type): Renamed back from b4_file_name_type. All uses | |
7283 | changed. | |
7284 | (class position): file_name -> filename (reverting). All uses changed. | |
7285 | ||
7286 | 2005-09-14 Paul Eggert <eggert@cs.ucla.edu> | |
7287 | ||
7288 | * examples/calc++/Makefile.am ($(calc_sources_generated)): Don't | |
7289 | do anything if $@ exists. This reverts part of the 2005-07-07 | |
7290 | patch. | |
7291 | ||
00292f66 PE |
7292 | 2005-09-11 Paul Eggert <eggert@cs.ucla.edu> |
7293 | ||
7294 | * Makefile.am (EXTRA_DIST): Do not distribute REFERENCES; it | |
7295 | contains obsolete information and isn't worth distributing as a | |
7296 | separate file anyway. | |
7297 | * data/glr.c [defined YYSETJMP]: Don't include <setjmp.h>. | |
7298 | (YYJMP_BUF, YYSETJMP, YYLONGJMP) [!defined YYSETJMP]: New macros. | |
7299 | All uses of jmp_buf, setjmp, longjmp changed to use these instead. | |
7300 | (yyparse): Abort if user code uses longjmp to throw an unexpected | |
7301 | value. | |
7302 | ||
a420f962 PE |
7303 | 2005-09-09 Paul Eggert <eggert@cs.ucla.edu> |
7304 | ||
00292f66 PE |
7305 | * data/c.m4 (b4_identification): Define YYBISON_VERSION. |
7306 | Suggested by twlevo@xs4all.nl. | |
7307 | ||
127287e9 PE |
7308 | * data/glr.c (YYCHK1): Do not assume YYE is in range. |
7309 | This avoids a diagnostic from gcc -Wswitch-enum. | |
7310 | Problem reported by twlevo@xs4all.nl. | |
7311 | ||
a420f962 PE |
7312 | * doc/bison.texinfo: Don't use "filename", as per GNU coding |
7313 | standards. Use "file name" or "file" or "name", depending on | |
7314 | the context. | |
7315 | (Invocation): The output of "bison hack/foo.y" goes to foo.tab.c, | |
7316 | not to hack/foo.tab.c. | |
7317 | (Calc++ Top Level): 2nd arg of main is not const. | |
48b16bbc PE |
7318 | * data/glr.c: b4_filename -> b4_file_name. |
7319 | * data/lalr1.cc: Likewise. Also, b4_filename_type -> b4_file_name_type. | |
7320 | All uses changed. | |
7321 | (class position): filename -> file_name. All uses changed. | |
7322 | * data/yacc.c: b4_filename -> b4_file_name. | |
7323 | * lib/bitset.h: filename -> file_name in local vars. | |
7324 | * lib/bitset_stats.c: Likewise. | |
7325 | * src/files.c: Likewise. | |
7326 | * src/scan-skel.l ("@output ".*\n): Likewise. | |
7327 | * src/files.c (file_name_split): Renamed from filename_split. | |
7328 | * src/muscle_tab.c (muscle_init): Output b4_file_name, not b4_filename. | |
a420f962 PE |
7329 | |
7330 | 2005-09-08 Paul Eggert <eggert@cs.ucla.edu> | |
7331 | ||
7332 | * lib/.cvsignore: Add pipe-safer.c, stdio--.h, unistd--.h, | |
7333 | to accommodate latest gnulib. | |
7334 | ||
7335 | * tests/glr-regression.at (Duplicate representation of merged trees): | |
7336 | Add casts to pacify g++. Problem reported by twlevo@xs4all.nl. | |
7337 | ||
7338 | * bootstrap: Add comment as to why the AM_LANGINFO_CODESET hack is | |
7339 | needed. | |
7340 | ||
42a6501d PE |
7341 | 2005-08-26 Paul Eggert <eggert@cs.ucla.edu> |
7342 | ||
7343 | * data/glr.c (yydestroyGLRState): Renamed from yydestroyStackItem. | |
7344 | All uses changed. Invoke user destructor after an error during a | |
7345 | split parse (trivial change from Joel E. Denny). | |
7346 | ||
7347 | * tests/glr-regression.at | |
7348 | (User destructor after an error during a split parse): New test case. | |
7349 | Problem reported by Joel E. Denny in: | |
7350 | http://lists.gnu.org/archive/html/bison-patches/2005-08/msg00029.html | |
7351 | ||
ef9a1faf PE |
7352 | 2005-08-25 Paul Eggert <eggert@cs.ucla.edu> |
7353 | ||
5b4aaf78 PE |
7354 | * README-cvs: Give URLs for recommended tools. |
7355 | Mention Gzip version problem, and bootstrapping issues. | |
7356 | Remove troubleshooting section, as it's somewhat obsolete. | |
7357 | ||
b5240ba5 PE |
7358 | * bootstrap (no_cache): New var, to accommodate different wget |
7359 | variants. Use it instead of '-C off'. Problem reported by | |
7360 | twlevo@xs4all.nl. | |
7361 | ||
ef9a1faf PE |
7362 | * data/glr.c (yydestroyStackItem): New function. |
7363 | (yyrecoverSyntaxError, yyreturn): Use it to improve quality of | |
7364 | debugging information. Problem reported by Joel E. Denny. | |
7365 | ||
e6efa9da AD |
7366 | 2005-08-25 Akim Demaille <akim@epita.fr> |
7367 | ||
7368 | * tests/local.at (AT_COMPILE_CXX): Pass $LINKS too. | |
7369 | ||
adc90f13 PE |
7370 | 2005-08-24 Paul Eggert <eggert@cs.ucla.edu> |
7371 | ||
7372 | * data/glr.c (yyrecoverSyntaxError, yyreturn): | |
7373 | Don't invoke destructor on unresolved entries. | |
7374 | * tests/glr-regression.at | |
7375 | (User destructor for unresolved GLR semantic value): New test case. | |
7376 | Problem reported by Joel E. Denny in: | |
7377 | http://lists.gnu.org/archive/html/bison-patches/2005-08/msg00016.html | |
7378 | ||
f9315de5 PE |
7379 | 2005-08-21 Paul Eggert <eggert@cs.ucla.edu> |
7380 | ||
15d29c1f PE |
7381 | * lib/.cvsignore: Remove realloc.c, strncasecmp.c, xstrdup.c. |
7382 | Add strnlen.c. | |
7383 | * m4/.cvsignore: Remove codeset.m4, gettext.m4, lib-ld.m4, | |
7384 | lib-prefix.m4, po.m4. | |
7385 | ||
dd5f2af2 PE |
7386 | * data/glr.c (yyreturn): Use "Cleanup:" rather than "Error:" |
7387 | in yydestruct diagnostic, since it might not be an error. | |
7388 | Problem reported by Joel Denny near end of | |
7389 | <http://lists.gnu.org/archive/html/help-bison/2005-07/msg00040.html>. | |
6250acbd | 7390 | * data/lalr1.cc (yyerturn): Likewise. |
dd5f2af2 PE |
7391 | * data/yacc.c (yyreturn): Likewise. |
7392 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Adjust to the above change. | |
7393 | ||
7394 | * src/files.c: Remove obsolete FIXME comment. | |
7395 | ||
7396 | * data/glr.c (YY_SYMBOL_PRINT): Append a newline, for consistency | |
7397 | with the other templates, and to fix bogus run-on messages such | |
7398 | as the one reported at the end of | |
7399 | <http://lists.gnu.org/archive/html/help-bison/2005-07/msg00040.html>. | |
7400 | All callers changed to avoid the newline. | |
7401 | (yyprocessOneStack): Output two lines rather than one, to accommodate | |
7402 | the above change. This changes the debug output format slightly. | |
7403 | ||
f9315de5 PE |
7404 | * data/glr.c (yyresolveValue): Fix redundant parse tree problem |
7405 | reported by Joel E. Denny in | |
7406 | <http://lists.gnu.org/archive/html/bison-patches/2005-08/msg00004.html> | |
7407 | (trivial change). | |
7408 | * tests/glr-regression.at (Duplicate representation of merged trees): | |
7409 | New test, from Joel E. Denny in: | |
7410 | <http://lists.gnu.org/archive/html/help-bison/2005-07/msg00013.html>. | |
7411 | * THANKS: Add Joel E. Denny. | |
7412 | ||
7413 | * configure.ac (AC_INIT): Bump to 2.0c. | |
7414 | ||
04098407 PE |
7415 | 2005-07-24 Paul Eggert <eggert@cs.ucla.edu> |
7416 | ||
7417 | * NEWS: Version 2.0b. | |
7418 | ||
ca5d2013 PE |
7419 | * Makefile.am (SUBDIRS): Put examples before tests, so that |
7420 | "make check" doesn't finish with "All 1 tests passed". | |
7421 | ||
3d54b576 PE |
7422 | * tests/regression.at (Token definitions): Don't rely on |
7423 | AT_PARSER_CHECK for data that contains backslashes. It currently | |
7424 | uses 'echo', and 'echo' isn't portable if its argument contains | |
7425 | backslashes. Problem found on OpenBSD 3.4. Also, do not assume | |
7426 | that the byte '\0xff' is not printable in the C locale; it is, | |
7427 | under OpenBSD 3.4 (!). Luckily, '\0x80' through '\0x9e' are | |
7428 | not printable, so use '\0x81' to test. | |
7429 | ||
d53ae497 PE |
7430 | * data/glr.c (YYOPTIONAL_LOC): Define even if it's not a recent |
7431 | version of GCC, since the macro is used with non-GCC compilers. | |
7432 | ||
fc01665e PE |
7433 | Fix core dump reported by Pablo De Napoli in |
7434 | <http://lists.gnu.org/archive/html/bug-bison/2005-07/msg00053.html>. | |
7435 | * tests/regression.at (Invalid inputs with {}): New test. | |
7436 | * src/parse-gram.y (token_name): Translate type before using | |
7437 | it as an index. | |
7438 | ||
04098407 PE |
7439 | * data/glr.c (ATTRIBUTE_UNUSED): Remove, since it infringes on |
7440 | the user's name space. All uses changed to __attribute__ | |
7441 | ((__unused__)). | |
7442 | (yyFail, yyMemoryExhausted, yyreportAmbiguity): | |
7443 | Add __attribute__ ((__noreturn__)). | |
7444 | ||
7445 | * etc/clcommit: Remove. We weren't using it, and it failed | |
7446 | "make maintainer-distcheck". | |
7447 | * Makefile.maint: Merge from coreutils. | |
7448 | (CVS_LIST, CVS_LIST_EXCEPT): New macros. | |
7449 | (syntax-check-rules): Change list of rules as described below. | |
7450 | (sc_cast_of_alloca_return_value, sc_dd_max_sym_length): | |
7451 | (sc_file_system, sc_obsolete_symbols, sc_prohibit_atoi_atof): | |
7452 | (sc_prohibit_jm_in_m4, sc_root_tests, sc_tight_scope): | |
7453 | (sc_trailing_space): New rules. | |
7454 | (sc_xalloc_h_in_src): Remove. | |
7455 | (sc_cast_of_argument_to_free, sc_cast_of_x_alloc_return_value): | |
7456 | (sc_space_tab, sc_error_exit_success, sc_changelog): | |
7457 | (sc_system_h_headers, sc_sun_os_names, sc_unmarked_diagnostics): | |
7458 | (makefile-check, po-check, author_mark_check): | |
7459 | (makefile_path_separator_check, copyright-check): | |
7460 | Use grep -n, to make it easier to find violations. | |
7461 | Use CVS_LIST and CVS_LIST_EXCEPT. | |
7462 | (header_regexp, h_re): Remove. | |
7463 | (dd_c): New macro. | |
7464 | (sc_dd_max_sym_length, .re-list, news-date-check): New rules. | |
7465 | (my-distcheck): Use more-modern GCC flags. | |
7466 | (signatures, %.asc): Remove. | |
7467 | (rel-files, announcement): Remove signatures. | |
7468 | Restore old updating code, even though we don't use it, so | |
7469 | that we're the same as coreutils. | |
7470 | (alpha, beta, major): Depend on news-date-check. | |
7471 | Make the upload commands. | |
7472 | ||
7473 | * data/c.m4, data/lalr1.cc, data/yacc.c: Normalize white space. | |
7474 | * lib/abitset.h, lib/bbitset.h, lib/bitset.h: Likewise. | |
7475 | * lib/bitset_stats.c, lib/ebitset.h, lib/lbitset.c: Likewise. | |
7476 | * lib/libitset.h, lib/timevar.c, lib/vbitset.h: Likewise. | |
7477 | * src/Makefile.am, src/gram.c, src/muscle_tab.h: Likewise. | |
7478 | * src/parse-gram.y, src/system.h, src/tables.c, src/vcg.c: Likewise. | |
7479 | * src/vcg_defaults.h, tests/cxx-type.at, tests/existing.at: Likewise. | |
7480 | * tests/sets.at: Likewise. | |
7481 | ||
7482 | * data/m4sugar/m4sugar.m4: Sync from Autoconf, except that | |
7483 | we comment out the Autoconf version number. | |
7484 | * doc/bison.texinfo (Calc++ Scanner): Don't use atoi, as | |
7485 | it's error-prone and "make maintainer-distcheck" rejects it. | |
7486 | ||
7487 | * lib/subpipe.c: Include <fcntl.h> without checking for HAVE_FCNTL_H. | |
7488 | Indent calls to "error" to pacify "make maintainer-distcheck", | |
7489 | when the calls are not intended to be translated. | |
7490 | * m4/subpipe.m4 (BISON_PREREQ_SUBPIPE): Don't check for fcntl.h. | |
7491 | ||
7492 | * src/Makefile.am (DEFS): Use +=, to pacify | |
7493 | "make maintainer-distcheck". | |
7494 | (bison_SOURCES): Add scan-skel.h. | |
7495 | (sc_tight_scope): New rule, from coreutils. | |
7496 | ||
7497 | * src/files.c (src_extension, header_extension): | |
7498 | Now static, not extern. | |
7499 | * src/getargs.c (short_options): Likewise. | |
7500 | * src/muscle_tab.c (muscle_table): Likewise. | |
7501 | * src/parse-gram.y (current_class, current_type, current_prec): | |
7502 | Likewise. | |
7503 | * src/reader.c (grammar_end, previous_rule_end): Likewise. | |
7504 | * src/getargs.h: Redo comments to pacify "make maintainer-distcheck". | |
7505 | * src/main.c (main): Cast bindtextdomain and textdomain calls to | |
7506 | void, to avoid warning when NLS is disabled. | |
7507 | * src/output.c: Include scan-skel.h. | |
7508 | (scan_skel): Remove decl, since scan-skel.h does this. | |
7509 | (output_skeleton): | |
7510 | Indent calls to "error" to pacify "make maintainer-distcheck". | |
7511 | * src/print_graph.c: Don't include <obstack.h>, as system.h does this. | |
7512 | * src/reader.h (gram_end, gram_lineno): New decls to pacify | |
7513 | "make maintainer-distcheck". | |
7514 | * src/scan-skel.l (skel_lex, skel_get_lineno, skel_get_in): | |
7515 | (skel_get_out, skel_get_leng, skel_get_text, skel_set_lineno): | |
7516 | (skel_set_in, skel_set_out, skel_get_debug, skel_set_debug): | |
7517 | (skel_lex_destroy, scan_skel): Move these decls to... | |
7518 | * src/scan-skel.h: New file. | |
7519 | * src/uniqstr.c (uniqstr_assert): | |
7520 | Indent calls to "error" to pacify "make maintainer-distcheck". | |
7521 | ||
7522 | * tests/Makefile.am ($(srcdir)/package.m4): Use $(VAR), | |
7523 | not @VAR@. | |
7524 | ||
7525 | * tests/torture.at: Revamp to avoid misuse of atoi that | |
7526 | "make maintainer-distcheck" complained about. | |
7527 | ||
7528 | * examples/extexi (message): Don't print a message more than once, | |
7529 | and omit line-number decoration that makes Emacs compile think | |
7530 | that informative messages are worth worrying about. | |
7531 | ||
7532 | 2005-07-22 Paul Eggert <eggert@cs.ucla.edu> | |
7533 | ||
7534 | * configure.ac: Update version number. | |
7535 | ||
7536 | * Makefile.am (SUBDIRS): Add examples; somehow this got removed | |
7537 | accidentally. | |
7538 | * examples/calc++/calc++-parser.yy: Remove from CVS, as it's | |
7539 | autogenerated by the maintainer. | |
7540 | * examples/calc++/.cvsignore: Add *.yy. | |
7541 | ||
7542 | * lib/bitset.c (bitset_alloc): Don't cast xcalloc result. | |
7543 | * lib/bitset_stats.c (bitset_stats_init): Likewise. | |
7544 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
7545 | ||
7546 | * po/POTFILES.in: Add lib/xalloc-die.c; remove lib/xmalloc.c. | |
7547 | ||
7548 | * src/relation.c (relation_transpose): Rewrite to avoid bogus complaint | |
7549 | from maintainer-distcheck about casting the argument of 'free'. | |
7550 | ||
7551 | * NEWS: Mention recent yytname changes. | |
7552 | * THANKS: Add Anthony Heading, twlevo@xs4all.nl. | |
7553 | ||
7554 | * bootstrap: For translations that have not yet been upgraded to | |
7555 | the new runtime-po domain, prime the pump by extracting the | |
7556 | relevant strings from the obsolete translations. This code can be | |
7557 | removed once the bison-runtime domain has been translated by each | |
7558 | team. | |
7559 | ||
7560 | * src/scan-gram.l (<SC_PRE_CODE>.): Don't double-quote token names, | |
7561 | now that token names are already quoted. | |
7562 | ||
7563 | Fix problem reported by Anthony Heading. | |
7564 | * data/glr.c (YYTOKEN_TABLE): New macro. | |
7565 | (yytname): Define if YYTOKEN_TABLE. | |
7566 | * data/yacc.c (YYTOKEN_TABLE, yytname): Likewise. | |
7567 | * data/lalr1.cc (YYTOKEN_TABLE, yytname_): Likewise. | |
7568 | (YYERROR_VERBOSE): Define the same way the other skeletons do. | |
7569 | * src/output.c (prepare_symbols): Output token_table_flag. | |
7570 | ||
0ffda363 PE |
7571 | 2005-07-21 Paul Eggert <eggert@cs.ucla.edu> |
7572 | ||
7573 | * data/glr.c (yyinitGLRStack, yyreturn): Don't call malloc | |
7574 | again if the first call fails. | |
7575 | ||
7576 | * data/glr.c (yytnamerr): New function. | |
7577 | (yyreportSyntaxError): Use it to dequote most string literals. | |
7578 | * data/lalr1.c (yytname_): Renamed from yyname_, for compatibility | |
7579 | with other skeletons. All uses changed. | |
7580 | (yytnameerr_): New function. | |
7581 | (yyreport_syntax_error): Use it to dequote most string literals. | |
7582 | * data/yacc.c (yytnamerr): New function. | |
7583 | (yyerrlab): Use it to decode most string literals. | |
7584 | * doc/bison.texinfo (Decl Summary, Calling Convention): | |
7585 | Clarify quoting convention of yytname. | |
7586 | * src/output.c (prepare_symbols): Quote all names. This undoes | |
7587 | the 2005-04-17 change, which is now accomplished (mostly) via | |
7588 | changes in the parsers as described above. | |
7589 | * tests/regression.at (Token definitions, Web2c Actions): | |
7590 | Undo most 2005-04-17 change here, too. | |
7591 | ||
7592 | 2005-07-20 Paul Eggert <eggert@cs.ucla.edu> | |
7593 | ||
7594 | Fix more problems reported by twlevo@xs4all.nl. | |
7595 | * tests/cxx-type.at: Don't pipe output of ./types through sed to | |
7596 | remove trailing spaces. This loses the exit status of ./types, | |
7597 | and isn't needed since ./types shouldn't be emitting trailing | |
7598 | spaces. | |
7599 | * data/glr.c (yyreturn): Don't pop stack if yyinitStateSet failed, | |
7600 | as the stack isn't valid in that case. | |
7601 | ||
7602 | * src/scan-gram.l (gram_get_lineno, gram_get_in, gram_get_out): | |
7603 | (gram_get_leng, gram_get_text, gram_set_lineno, gram_set_in): | |
7604 | (gram_set_out, gram_get_debug, gram_set_debug, gram_lex_destroy): | |
7605 | Add declarations to pacify "gcc -Wmissing-prototypes" when flex 2.5.31 | |
7606 | is used. | |
7607 | * src/scan-skel.l (skel_get_lineno, skel_get_in, skel_get_out): | |
7608 | (skel_get_leng, skel_get_text, skel_set_lineno, skel_set_in): | |
7609 | (skel_set_out, skel_get_debug, skel_set_debug, skel_lex_destroy): | |
7610 | Likewise. | |
7611 | ||
7612 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Work even with | |
7613 | overly-picky compilers that reject 'char *foo = "bar";'. | |
7614 | ||
7615 | * src/symtab.c (SYMBOL_ATTR_PRINT, symbol_print): Direct output | |
7616 | to FILE * parameter, not to stderr. This fixes a typo introduced | |
7617 | in the 2005-07-12 change. | |
7618 | ||
7619 | * lib/subpipe.c (create_subpipe): Rewrite slightly to avoid | |
7620 | warnings from GCC 4. | |
7621 | ||
7622 | * data/glr.c (yyexpandGLRStack, yyaddDeferredAction, yyexpandGLRStack): | |
7623 | (yyglrShiftDefer, yysplitStack): | |
7624 | Remove unused parameters b4_pure_formals. All uses changed. | |
7625 | (yyglrShift): Remove unused parameters b4_user_formals. | |
7626 | All uses changed. | |
7627 | (yyglrReduce): Removed unused parameter yylocp. All uses changed. | |
7628 | ||
6100a9aa PE |
7629 | 2005-07-18 Paul Eggert <eggert@cs.ucla.edu> |
7630 | ||
258b75ca PE |
7631 | Destructor cleanups and regularization among the three skeletons. |
7632 | * NEWS: Document the behavior changes. | |
7633 | * data/glr.c (yyrecoverSyntaxError): Don't bother to pop the | |
7634 | stack before failing, as the cleanup code will do it for us now. | |
7635 | * data/lalr1.cc (yyerrlab): Likewise. | |
7636 | * data/glr.c (yyparse): Pop everything off the stack before | |
7637 | freeing it, so that destructors get called properly. | |
7638 | * data/lalr1.cc (yyreturn): Likewise. | |
7639 | * data/yacc.c (yyreturn): Pop and destroy the start symbol, too. | |
7640 | This is more consistent. | |
7641 | * doc/bison.texinfo (Destructor Decl): Mention more reasons | |
7642 | why destructors might be called. 1.875 -> 2.1. | |
7643 | (Destructor Decl, Decl Summary, Table of Symbols): | |
7644 | Some English-language cleanups for %destructor. | |
7645 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
7646 | Add output line for destructor of start symbol. | |
7647 | * tests/calc.at (AT_CHECK_CALC): Add one to line counts, | |
7648 | because of that same extra output line. | |
7649 | ||
1a059451 PE |
7650 | * NEWS: Document minor wording changes in diagnostics of |
7651 | Bison-generated parsers. | |
7652 | * data/glr.c (yyMemoryExhausted): Renamed from yyStackOverflow. | |
7653 | Remove unused formals. All uses changed. | |
7654 | (yyreportAmbiguity): "ambiguity detected" -> "syntax is ambiguous". | |
7655 | (yyparse): Rename yyoverflowlab to yyexhaustedlab. | |
7656 | * data/yacc.c (yyparse): "parser stack overflow" -> "memory exhausted". | |
7657 | Rename yyoverflowab to yyexhaustedlab. | |
7658 | When memory exhaustion occurs during syntax-error reporting, | |
7659 | report it separately rather than in a single diagnostic; this | |
7660 | eases translation. | |
7661 | * doc/bison.texinfo (Memory Management): Renamed from Stack Overflow. | |
7662 | (Memory Exhausted): Renamed from Parser Stack Overflow. | |
7663 | Revamp wording slightly to prefer "memory exhaustion". | |
7664 | * tests/actions.at: "parser stack overflow" -> "memory exhausted". | |
7665 | ||
97460c78 PE |
7666 | * data/c.m4 (b4_yysymprint_generate): Use YYFPRINTF, not fprintf. |
7667 | ||
30757c8c PE |
7668 | Add i18n support to the GLR skeleton. Partially fix the C++ |
7669 | skeleton; a C++ expert needs to finish this. Remove debugging | |
7670 | msgids; there's little point to having them translated, since they | |
7671 | can be understood only by someone who can read the | |
7672 | (English-language) source code. | |
7673 | ||
7674 | Generate runtime-po/bison-runtime.pot automatically, so that we | |
7675 | don't have to worry about garbage getting in that file. We'll | |
7676 | make sure after the next official release that old msgids don't | |
7677 | get lost. See | |
7678 | <http://lists.gnu.org/archive/html/bison-patches/2005-07/msg00119.html>. | |
7679 | ||
7680 | * runtime-po/Makefile.in.in, runtime-po/bison-runtime.pot: Remove. | |
7681 | Now auto-generated. | |
7682 | * PACKAGING: Don't claim that Gawk, GCC, Perl use this method yet. | |
7683 | Fix typos in explanations of the runtime file. | |
7684 | * bootstrap: Change gettext keyword from YYI18N to YY_. | |
7685 | Use standard Makefile.in.in in runtime-po, since we'll arrange | |
7686 | for backward-compatible bison-runtime.po files in a different way. | |
7687 | * data/glr.c (YY_): New macro, from yacc.c. | |
7688 | (yyuserAction, yyreportAmbiguity, yyreportSyntaxError, yyparse): | |
7689 | Translate messages intended for users. | |
7690 | (yyreportSyntaxError): Change "virtual memory" to "memory" to match | |
7691 | the wording in the other skeletons. We don't know that the memory | |
7692 | is virtual. | |
7693 | * data/lalr1.cc (YY_): Renamed from _. All uses changed. | |
7694 | Use same method that yacc.c uses. | |
7695 | Don't translate debugging messages. | |
7696 | (yy::yyreport_syntax_error): Put in a FIXME for the i18n stuff; | |
7697 | it doesn't work (yet), and requires C++ expertise to fix. | |
7698 | * data/yacc.c (YY_): Renamed from YY18N. All uses changed. | |
7699 | Move defn to a more logical place, to be consistent with other | |
7700 | skeletons. | |
7701 | Don't translate debugging messages. | |
7702 | Don't assume line numbers fit in unsigned int; use unsigned long fmts. | |
7703 | * doc/bison.texinfo: Mention <libintl.h>. Change glibc cross reference | |
7704 | to gettext cross reference. Add indexing terms. Mention YYENABLE_NLS. | |
7705 | * runtime-po/POTFILES.in: Add data/glr.c, data/lalr1.cc. | |
7706 | ||
ac8c5689 PE |
7707 | Fix yyerror / yylex test glitches noted by twlevo@xs4all.nl. |
7708 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Have yyerror return | |
7709 | void, not int. | |
7710 | * tests/glr-regression.at (Badly Collapsed GLR States): | |
7711 | Likewise. | |
7712 | (Improper handling of embedded actions and dollar(-N) in GLR parsers): | |
7713 | yylex should return 0 at EOF rather than aborting. | |
7714 | ||
6100a9aa PE |
7715 | Improve tests for stack overflow in GLR parser. |
7716 | Problem reported by twlevo@xs4all.nl. | |
7717 | * data/glr.c (struct yyGLRStack): Remove yyerrflag member. | |
7718 | All uses removed. | |
7719 | (yyStackOverflow): Just longjmp, but with value 2 so that caller | |
7720 | can handle the problem. | |
7721 | (YYCHK1): Use goto (a la yacc.c) rather than setting a flag. | |
7722 | (yyparse): New local variable yyresult to record the result. | |
7723 | Use result of setjmp to set it, rather than storing itinto | |
7724 | struct. | |
7725 | (yyDone): Remove label. | |
7726 | (yyacceptlab, yyabortlab, yyoverflowlab, yyreturn): New labels, | |
7727 | to mimic yacc.c. Do not discard lookahead if it's EOF (possible | |
7728 | if YYABORT is used). | |
7729 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Exit with | |
7730 | yyparse status; put status > 1 into diagnostic. | |
7731 | Check that status==2 works. | |
7732 | * tests/calc.at, tests/cxx-type.at, tests/glr-regression.at: | |
7733 | Use exit status 3 for failure to open (which shouldn't happen). | |
7734 | ||
15f40952 PE |
7735 | 2005-07-17 Paul Eggert <eggert@cs.ucla.edu> |
7736 | ||
67fd79c4 PE |
7737 | * tests/conflicts.at (%nonassoc and eof): Don't exit with status |
7738 | 1 on syntax error; just let yyparse do its thing. | |
7739 | * tests/glr-regression.at (Badly Collapsed GLR States): Likewise. | |
7740 | * tests/torture.at (AT_DATA_STACK_TORTURE): Likewise. | |
7741 | (Exploding the Stack Size with Alloca): | |
7742 | (Exploding the Stack Size with Malloc): | |
7743 | Expect exit status 2, not 1, since the parser is supposed to blow | |
7744 | its stack. Problem reported by twlevo@xs4all.nl. | |
7745 | ||
15f40952 PE |
7746 | * data/glr.c (yyparse): Don't assume that the initial calls |
7747 | to YYMALLOC succeed; in that case, yyparse incorrectly returned 0. | |
7748 | Print a stack-overflow message and fail instead. | |
7749 | Initialize the line-number information before creating the stack, | |
7750 | so that the stack-overflow message can report line zero safely. | |
7751 | ||
f32c66b5 PE |
7752 | 2005-07-14 Paul Eggert <eggert@cs.ucla.edu> |
7753 | ||
a22ff96f | 7754 | Fix problems reported by twlevo@xs4all.nl. |
e2688cd9 PE |
7755 | * data/glr.c (YYSTACKEXPANDABLE): Don't define if already defined. |
7756 | (yyuserMerge): Provide a default case if b4_mergers is empty. | |
7757 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Define YYSTACKEXPANDABLE. | |
7758 | * tests/glr-regression.at | |
7759 | (Improper handling of embedded actions and dollar(-N) in GLR parsers): | |
c70fdfcd | 7760 | Add casts to pacify C++ compilers. |
1beb0b24 PE |
7761 | * tests/glr-regression.at (Improper merging of GLR delayed action |
7762 | sets): Declare yylex before using it. | |
f32c66b5 | 7763 | * tests/Makefile.am (maintainer-check-g++): Fix a stray |
a22ff96f PE |
7764 | $(GXX) that escaped the renaming of GXX to CXX. Remove bogus |
7765 | test for valgrind; valgrind is independent of g++. | |
7766 | (maintainer-check-posix): Add _POSIX2_VERSION=200112, to check | |
7767 | for compatibility with POSIX 1003.1-2001 (if running coreutils). | |
7768 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Port to stricter C++. | |
7769 | Use a destructor, so that we can expand the stack. Change | |
7770 | YYSTYPE to char * so that we can free it. Cast result of malloc. | |
f32c66b5 | 7771 | |
d741bd1b PE |
7772 | 2005-07-13 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> |
7773 | ||
7774 | * data/glr.c (yyuserAction): Fix uninitialized variable that caused | |
7775 | a valgrind failure. Problem reported by twlevo@xs4all.nl. | |
7776 | ||
0410a6e0 PE |
7777 | 2005-07-13 Paul Eggert <eggert@cs.ucla.edu> |
7778 | ||
7779 | * PACKAGING: New file, suggested by Bruno Haible and taken from | |
7780 | similar wording in gettext's PACKAGING file. | |
7781 | * NEWS: Mention PACKAGING. | |
7782 | * Makefile.am (EXTRA_DIST): Add PACKAGING. | |
7783 | ||
f7ab6a50 PE |
7784 | 2005-07-12 Paul Eggert <eggert@cs.ucla.edu> |
7785 | ||
baf785db | 7786 | * NEWS: Document recent i18n improvements. |
f7ab6a50 PE |
7787 | * bootstrap: Get runtime translations into runtime-po. |
7788 | Create runtime-po files automatically, if possible. | |
7789 | * configure.ac: Invoke BISON_I18N, so that we eat our own dog food. | |
7790 | * data/yacc.c: Rewrite inclusion of <libintl.h> so that ENABLE_NLS | |
7791 | does not infringe on the user's name space. | |
7792 | (YYENABLE_NLS): Renamed from ENABLE_BISON_NLS. | |
7793 | * doc/bison.texinfo (Internationalization): Revamp the English | |
7794 | and Texinfo syntax a bit, to try to make it clearer. | |
7795 | (Bison Options, Option Cross Key): Mention --print-localedir. | |
7796 | * m4/bison-i18n.m4 (BISON_I18N): Rename ENABLE_BISON_NLS to | |
7797 | YYENABLE_NLS. Quote a bit more. | |
7798 | * runtime-po/.cvsignore: New file. | |
7799 | * runtime-po/Makefile.in.in (mostlyclean): Remove *.old.pot. | |
7800 | * runtime-po/Rules-quot: Remove; now created by bootstrap. | |
7801 | * runtime-po/quot.sed: Likewise. | |
7802 | * runtime-po/boldquot.sed: Likewise. | |
7803 | * runtime-po/en@quot.header: Likewise. | |
7804 | * runtime-po/en@boldquot.header: Likewise. | |
7805 | * runtime-po/insert-header.sin: Likewise. | |
7806 | * runtime-po/remove-potcdate.sin: Likewise. | |
7807 | * runtime-po/Makevars: Likewise. | |
7808 | * runtime-po/LINGUAS: Likewise. | |
7809 | * runtime-po/de.po: Likewise; we will rely on the translation project | |
7810 | to maintain this, so "bootstrap" should get it. | |
0410a6e0 | 7811 | * src/getarg.c (PRINT_LOCALEDIR_OPTION): Let the C compiler determine |
f7ab6a50 PE |
7812 | its value. |
7813 | * src/main.c (main): Bind the bison-runtime domain, too. | |
7814 | ||
7815 | 2005-07-12 Bruno Haible <bruno@clisp.org> | |
7816 | ||
7817 | * data/yacc.c: Include <libintl.h> when NLS is enabled. | |
7818 | (YYI18N): Renamed from _. Use dgettext when NLS is enabled. | |
7819 | * po/POTFILES.in: Remove autogenerated file src/parse-gram.c. | |
7820 | * runtime-po: New directory. | |
7821 | * runtime-po/Makefile.in.in: New file, copied from po/, with modified | |
7822 | $(DOMAIN).pot-update rule, so that old messages are never dropped. | |
7823 | * runtime-po/Rules-quot: New file, copied from po/. | |
7824 | * runtime-po/quot.sed: Likewise. | |
7825 | * runtime-po/boldquot.sed: Likewise. | |
7826 | * runtime-po/en@quot.header: Likewise. | |
7827 | * runtime-po/en@boldquot.header: Likewise. | |
7828 | * runtime-po/insert-header.sin: Likewise. | |
7829 | * runtime-po/remove-potcdate.sin: Likewise. | |
7830 | * runtime-po/Makevars: New file. | |
7831 | * runtime-po/POTFILES.in: New file. | |
7832 | * runtime-po/LINGUAS: New file. | |
7833 | * runtime-po/bison-runtime.pot: New file. | |
7834 | * runtime-po/de.po: New file. | |
7835 | * m4/bison.m4: New file. | |
7836 | * Makefile.am (SUBDIRS): Add runtime-po. | |
7837 | (aclocaldir, aclocal_DATA): New variables. | |
7838 | * configure.ac: Add AC_CONFIG_FILES of runtime-po/Makefile.in. | |
7839 | Define aclocaldir. | |
7840 | * src/getargs.c (usage): Document --print-localedir option. | |
7841 | (PRINT_LOCALEDIR_OPTION): New enum item. | |
7842 | (long_options): Add --print-localedir option. | |
7843 | (getargs): Handle --print-localedir option. | |
7844 | * doc/bison.texinfo (Bison Parser): Remove paragraph about _(). | |
7845 | (Internationalization): New section. | |
7846 | ||
22dda0f0 AD |
7847 | 2005-07-12 Akim Demaille <akim@epita.fr> |
7848 | ||
7849 | * src/symtab.h, src/symtab.c (symbol_print): Swap the arguments, | |
7850 | for consistency with the rest of the code. | |
7851 | * src/symlist.h, src/symlist.c (symbol_list_print): Ditto. | |
7852 | Add separators. | |
7853 | ||
82b248ad AD |
7854 | 2005-07-12 Akim Demaille <akim@epita.fr> |
7855 | ||
7856 | * src/parse-gram.y: Use %printer instead of YYPRINT. | |
7857 | ||
fa0e9314 AD |
7858 | 2005-07-12 Akim Demaille <akim@epita.fr> |
7859 | ||
867a3e00 AD |
7860 | * src/symtab.h, src/symtab.c (symbol_print): New. |
7861 | * src/symlist.h, src/symlist.c (symbol_list_print): New. | |
7862 | * src/symlist.c (symbol_list_n_type_name_get): Report the culprit. | |
7863 | ||
7864 | 2005-07-12 Akim Demaille <akim@epita.fr> | |
7865 | ||
7866 | * data/glr.c (b4_syncline): Fix (swap) the definitions of | |
fa0e9314 AD |
7867 | b4_at_dollar and b4_dollar_dollar. |
7868 | ||
e054b190 PE |
7869 | 2005-07-11 Paul Eggert <eggert@cs.ucla.edu> |
7870 | ||
7871 | * doc/bison.texinfo (Mystery Conflicts): Add reference to DeRemer | |
7872 | and Pennello's paper. | |
7873 | ||
34160ec4 PE |
7874 | 2005-07-09 Paul Eggert <eggert@cs.ucla.edu> |
7875 | ||
407d4a75 PE |
7876 | * data/yacc.c (yyparse): Undo previous patch. Instead, |
7877 | set yylsp[0] and yyvsp[0] only if the initial action | |
7878 | sets yylloc and yylval, respectively. | |
7879 | ||
34160ec4 PE |
7880 | * data/yacc.c (yyparse): In the initial action, set |
7881 | yylsp[0] and yyvsp[0] rather than yylloc and yylval. | |
7882 | This avoids the use of undefined variables if the initial | |
7883 | action does not set yylloc and/or yylval. | |
7884 | ||
c3d5a4a7 PE |
7885 | 2005-07-07 Paul Eggert <eggert@cs.ucla.edu> |
7886 | ||
b34d96c1 PE |
7887 | * examples/calc++/calc++-driver.cc, examples/calc++/calc++-driver.hh: |
7888 | * examples/calc++/calc++-scanner.ll, examples/calc++/calc++.cc: | |
7889 | Remove from CVS. These files are automatically generated. | |
7890 | * examples/extexi: Clarify that this file is now part of Bison, | |
7891 | not GNU M4, and that it works with any POSIX-compatible Awk. | |
7892 | * examples/calc++/Makefile.am (run_extexi): Remove; not used. | |
7893 | ($(calc_extracted)): Renamed from $(calc_sources_extracted), | |
7894 | so that we also get calc++-parser.yy. Geneate it. | |
7895 | Use $(AWK), not gawk, since any conforming Awk will do. | |
7896 | Put comment before action, since older 'make' can't handle comment | |
7897 | in action. | |
7898 | $(BUILT_SOURCES): List all built sources, not just some of them. | |
7899 | $(MAINTAINERCLEANFILES): Remove *.stamp, and all built sources. | |
7900 | $($(srcdir)/calc++-parser.stamp): Work even if POSIXLY_CORRECT. | |
7901 | $($(calc_sources_generated)): Remove unnecessary test for existence | |
7902 | of target. (This had a shell syntax error anyway; a stray "x".) | |
7903 | (calc_extracted): List $(srcdir)/calc++-parser.yy, not | |
7904 | calc++-parser.yy. | |
7905 | * examples/.cvsignore, examples/calc++/.cvsignore: New files. | |
7906 | ||
c3d5a4a7 PE |
7907 | * bootstrap (gnulib_modules): Add gettext, now that it's no longer |
7908 | implied by the other modules. | |
7909 | ||
828c373b AD |
7910 | 2005-07-06 Akim Demaille <akim@epita.fr> |
7911 | ||
7912 | Bind examples/calc++ to the package. | |
7913 | * examples/calc++/Makefile: Remove, replaced by... | |
7914 | * examples/calc++/Makefile.am: ... this new file. | |
7915 | * examples/calc++/test: Remove input. | |
7916 | * examples/calc++/compile: Remove. | |
7917 | * examples/Makefile.am: New. | |
7918 | * configure.ac, Makefile.am: Adjust. | |
7919 | * doc/Makefile.am (clean-local): New, for more recent texi2dvis. | |
7920 | ||
63cb01d6 PE |
7921 | 2005-07-05 Paul Eggert <eggert@cs.ucla.edu> |
7922 | ||
fd2df2ed PE |
7923 | * data/glr.c (yyFail): Drastically simplify; since the format argument |
7924 | never had any % directives, we can simply pass it to yyerror. | |
7925 | (yyparse): Use "t a; a=b;" rather than "t a = b;" when a will | |
7926 | be modified later, as that is the usual style in glr.c. | |
7927 | Problems reported by Paul Hilfinger. | |
7928 | ||
63cb01d6 PE |
7929 | Rewrite GLR parser to catch more buffer overrun, storage exhaustion, |
7930 | and size overflow errors. | |
7931 | * data/glr.c: Include <stdio.h> etc. after user prolog, not before, | |
7932 | in case the user prolog sets feature-test macros like _GNU_SOURCE. | |
7933 | (YYSIZEMAX): New macro. | |
7934 | (yystpcpy): New function, taken from yacc.c. | |
7935 | (struct yyGLRStack.yyspaceLeft): Now size_t, not int. | |
7936 | (yyinitGLRStack, yyfreeGLRstack): Remove unnecessary forward decls, | |
7937 | so that we don't have to maintain their signatures. | |
7938 | (yyFail): Check for buffer overflow, by using vsnprintf rather | |
7939 | than vsprintf. Allocate a bigger buffer if possible. | |
7940 | Report an error if buffer allocation fails. | |
7941 | (yyStackOverflow): New function. | |
7942 | (yyinitStateSet, yyinitGLRStack): Return a boolean indicating whether | |
7943 | the initialization was successful. It might fail if storage was | |
7944 | exhausted. | |
7945 | (yyexpandGLRStack): Add more checks for storage allocation failure. | |
7946 | Use yyStackOverflow to report failures. | |
7947 | (yymarkStackDeleted, yyglrShift, yyglrShiftDefer, yydoAction): | |
7948 | (yysplitStack, yyprocessOneStack, yyparse, yypstack): | |
7949 | Don't assume stack number fits in int. | |
7950 | (yysplitStack): Check for storage allocation failure. | |
7951 | (yysplitStack, yyprocessOneStack): Add pure_formals, so that we | |
7952 | can print diagnostics on storage allocation failure. All callers | |
7953 | changed. | |
7954 | (yyresolveValue): Use yybool for boolean. | |
7955 | (yyreportSyntaxError): Check for size-calculation overflow. | |
7956 | This code is taken from yacc.c. | |
7957 | (yyparse): Check for storage allocation errors when allocating | |
7958 | the initial stack. | |
7959 | ||
1c59e0a1 AD |
7960 | 2005-07-05 Akim Demaille <akim@epita.fr> |
7961 | ||
7962 | Extract calc++ from the documentation. | |
7963 | * doc/bison.texinfo (Calc++): Add the extraction marks. | |
7964 | * examples/extexi: New, from the aborted GNU Programming 2E. | |
7965 | Separate the different paragraph of a file with empty lines. | |
7966 | * examples/Makefile: Use it to extract the whole calc++ example. | |
7967 | ||
8a0adb01 AD |
7968 | 2005-06-24 Akim Demaille <akim@epita.fr> |
7969 | ||
7970 | * doc/bison.texinfo (C++ Parser Interface): Use defcv to define | |
7971 | class typedefs. | |
7972 | ||
12545799 AD |
7973 | 2005-06-22 Akim Demaille <akim@epita.fr> |
7974 | ||
7975 | * doc/bison.texinfo (C++ Language Interface): First stab. | |
7976 | (C++ Parsers): Remove. | |
7977 | ||
99be0235 AD |
7978 | 2005-06-22 Akim Demaille <akim@epita.fr> |
7979 | ||
7980 | * data/lalr1.cc (yylex_): Honor %lex-param. | |
7981 | ||
0ffd4fd1 AD |
7982 | 2005-06-22 Akim Demaille <akim@epita.fr> |
7983 | ||
7984 | Start a set of simple examples. | |
7985 | * examples/calc++/Makefile, examples/calc++/calc++-driver.cc, | |
7986 | * examples/calc++/calc++-driver.hh, | |
7987 | * examples/calc++/calc++-parser.yy, | |
7988 | * examples/calc++/calc++-scanner.ll, examples/calc++/calc++.cc, | |
7989 | * examples/calc++/compile, examples/calc++/test: New. | |
7990 | ||
0925ebb4 PE |
7991 | 2005-06-09 Paul Eggert <eggert@cs.ucla.edu> |
7992 | ||
7993 | * data/yacc.c (malloc, free) [defined __cplusplus]: Wrap inside | |
7994 | extern "C" {}. This fixes a problem reported by Paul Hilfinger, | |
7995 | which stems from the 2005-05-27 patch. | |
7996 | ||
43d3b664 PH |
7997 | 2005-06-06 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
7998 | ||
7999 | * data/glr.c: Modify treatment of unused parameters to permit use | |
8000 | of g++ (which doesn't allow __attribute__ ((unused)) for parameters). | |
8001 | ||
3062864d PE |
8002 | 2005-05-30 Paul Eggert <eggert@cs.ucla.edu> |
8003 | ||
8004 | Fix infringement on user name space reported by Janos Zoltan Szabo. | |
8005 | * data/yacc.c (yyparse): strlen -> yystrlen. | |
8006 | ||
989b5b8e AD |
8007 | 2005-05-30 Akim Demaille <akim@epita.fr> |
8008 | ||
8009 | * data/lalr1.cc (_): New. | |
8010 | Translate the various messages. | |
8011 | ||
bedf57f5 PE |
8012 | 2005-05-27 Paul Eggert <eggert@cs.ucla.edu> |
8013 | ||
8014 | Fix infringement on user name space reported by Bruno Haible. | |
8015 | * data/yacc.c (YYSIZE_T): Define first, so that later decls can use it. | |
8016 | Prefer GCC's __SIZE_TYPE__ if available, so that we don't infringe on | |
8017 | the user's name space. | |
8018 | (alloca): Include <stdlib.h> to get it, if it's not built in. | |
8019 | (YYMALLOC, YYFREE): Define only if needed. | |
8020 | (malloc, free): Declare, but only if needed, as this infringes on | |
8021 | the user name space. | |
8022 | ||
4d1801f1 PE |
8023 | 2005-05-25 Paul Eggert <eggert@cs.ucla.edu> |
8024 | ||
8025 | Fix BeOS, FreeBSD, MacOS porting problems reported by Bruno Haible. | |
8026 | * lib/bitset.c (bitset_print): Don't assume size_t can be printed | |
8027 | with %d format. | |
8028 | * lib/ebitset.c (min, max): Undef before defining. | |
8029 | * lib/vbitset.c (min, max): Likewise. | |
8030 | * lib/subpipe.c (create_subpipe): Save local variables in case | |
8031 | vfork clobbers them. | |
8032 | ||
8033 | 2005-05-24 Bruno Haible <bruno@clisp.org> | |
8034 | ||
8035 | * tests/synclines.at (AT_SYNCLINES_COMPILE): Add support for the | |
8036 | error message syntax used by gcc-4.0. | |
8037 | ||
b94a9e1e PE |
8038 | 2005-05-23 Paul Eggert <eggert@cs.ucla.edu> |
8039 | ||
85ac3861 PE |
8040 | * README: Mention m4 1.4.3. Remove obsolete advice about |
8041 | Sun Forte Developer 6 update 2, VMS, and MS-DOS. | |
8042 | ||
b94a9e1e PE |
8043 | * bootstrap: Remove workaround for problem I encountered with |
8044 | gettext 0.14.1; it seems to be fixed now. | |
8045 | ||
51c30d21 PE |
8046 | 2005-05-22 Paul Eggert <eggert@cs.ucla.edu> |
8047 | ||
009ce67d PE |
8048 | * NEWS: Version 2.0a. |
8049 | ||
f2a97c62 PE |
8050 | * src/files.c: Include "stdio-safer.h"; this fixes a typo in |
8051 | the previous change. | |
8052 | ||
c8775f93 PE |
8053 | Various maintainer cleanups. |
8054 | * .cvsignore: Add a.exe, a.out, b.out,, conf[0-9]*, confdefs*, | |
8055 | conftest*, for benefit of CVS commands run at the same time as | |
8056 | "configure". Add build-aux, since "bootstrap" now creates it and | |
8057 | its subfiles. | |
8058 | * Makefile.cfg (move_if_change): Remove. | |
8059 | * Makefile.maint: Remove the update stuff; we now use "bootstrap". | |
8060 | (ftp-gnu, www-gnu, move_if_change, local_updates, update): | |
8061 | (po_repo, do-po-update, po-update, wget_files, get-targets): | |
8062 | (config.guess-url_prefix, config.sub-url_prefix): | |
8063 | (ansi2knr.c-url_prefix, texinfo.tex-url_prefix): | |
8064 | (standards.texi-url_prefix, make-stds.texi-url_prefix, taget, url): | |
8065 | ($(get-targets), cvs-files, automake_repo, wget-update, cvs-update): | |
8066 | Remove. | |
8067 | * configure.ac (AC_CONFIG_AUX_DIR): Change from config to build-aux; | |
8068 | this is now the recommended name. | |
8069 | * config/.cvsignore: Remove config.guess, config.rpath, config.sub, | |
8070 | depcomp, install-sh, mdate-sh, missing, mkinstalldirs, texinfo.tex, | |
8071 | ylwrap. These files now go into build-aux. | |
8072 | * config/move-if-change: Remove. | |
8073 | * config/prev-version.txt: Bump from 1.75 to 2.0. | |
8074 | ||
3ea5f0ec PE |
8075 | * bootstrap: Add stdio-safer, unistd-safer modules. |
8076 | Remove m4/glibc2.m4 (introduced by latest gnulib, but | |
8077 | we don't need it). | |
8078 | * lib/.cvsignore: Add dup-safer.c, fd-safer.c, | |
8079 | fopen-safer.c, stdio-safer.h, unistd-safer.h. | |
8080 | * lib/subpipe.c: Include "unistd-safer.h". | |
8081 | (create_subpipe): Make sure all the newly-created | |
8082 | file descriptors are > 2, so that diagnostics don't | |
8083 | get sent down them (which might cause Bison to hang, in theory). | |
8084 | * m4/.cvsignore: Add stdio-safer.m4, unistd-safer.m4. | |
8085 | * src/files.c (xfopen): Use fopen_safer, not fopen. | |
8086 | ||
51c30d21 PE |
8087 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Port |
8088 | yesterday's yacc.c fix. | |
8089 | ||
cea1469d PE |
8090 | 2005-05-21 Paul Eggert <eggert@cs.ucla.edu> |
8091 | ||
3ea5f0ec PE |
8092 | * data/glr.c, data/lalr1.cc: Update copyright date. |
8093 | ||
cea1469d PE |
8094 | Fix a destructor bug reported by Wolfgang Spraul in |
8095 | <http://lists.gnu.org/archive/html/bug-bison/2005-05/msg00042.html>. | |
8096 | * data/yacc.c (yyabortlab): Don't call destructor, and | |
8097 | don't set yychar to EMPTY. | |
8098 | (yyoverflowlab): Don't call destructor. | |
8099 | (yyreturn): Call destructor, if yychar is neither YYEOF nor YYEMPTY. | |
8100 | * tests/calc.at (AT_CHECK_CALC): Expect one fewer output lines, | |
8101 | since we no longer output the message "discarding lookahead token | |
8102 | end of input ()". | |
8103 | ||
5e6f62f2 PH |
8104 | 2005-05-20 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> |
8105 | ||
8106 | * data/glr.c (YY_SYMBOL_PRINT): Don't print newline at end to | |
8107 | fix a small glitch in debugging output. | |
8108 | (yyprocessOneStack, yyrecoverSyntaxError, yyparse): Print newline | |
8109 | after YY_SYMBOL_PRINT where needed. | |
8110 | ||
8111 | (struct yyGLRState): Add some comments. | |
8112 | (struct yySemanticOption): Add some comments. | |
8113 | (union yyGLRStackItem): Add comment. | |
8114 | ||
8115 | (yymergeOptionSets): Correct this to properly perform the union, | |
8116 | avoiding infinite reported by Michael Rosien. | |
8117 | Update comment. | |
8118 | ||
8119 | * tests/glr-regression.at: Add test for GLR merging error reported | |
8120 | by M. Rosien. | |
cea1469d | 8121 | |
0fb669f9 PE |
8122 | 2005-05-13 Paul Eggert <eggert@cs.ucla.edu> |
8123 | ||
8124 | * COPYING, ChangeLog, GNUmakefile, HACKING, Makefile.am, | |
8125 | Makefile.cfg, Makefile.maint, NEWS, README, README-alpha, | |
8126 | README-cvs, TODO, bootstrap, configure.ac, data/Makefile.am, | |
8127 | data/README, data/c.m4, data/glr.c, data/lalr1.cc, data/yacc.c, | |
8128 | data/m4sugar/m4sugar.m4, doc/Makefile.am, doc/bison.texinfo, | |
8129 | doc/fdl.texi, doc/gpl.texi, doc/refcard.tex, lib/Makefile.am, | |
8130 | lib/abitset.c, lib/abitset.h, lib/bbitset.h, lib/bitset.c, | |
8131 | lib/bitset.h, lib/bitset_stats.c, lib/bitset_stats.h, | |
8132 | lib/bitsetv-print.c, lib/bitsetv-print.h, lib/bitsetv.c, | |
8133 | lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/get-errno.c, | |
8134 | lib/get-errno.h, lib/lbitset.c, lib/lbitset.h, lib/libiberty.h, | |
8135 | lib/main.c, lib/subpipe.c, lib/subpipe.h, lib/timevar.c, | |
8136 | lib/timevar.def, lib/timevar.h, lib/vbitset.c, lib/vbitset.h, | |
8137 | lib/yyerror.c, m4/cxx.m4, m4/m4.m4, m4/subpipe.m4, m4/timevar.m4, | |
8138 | m4/warning.m4, src/LR0.c, src/LR0.h, src/Makefile.am, src/assoc.c, | |
8139 | src/assoc.h, src/closure.c, src/closure.h, src/complain.c, | |
8140 | src/complain.h, src/conflicts.c, src/conflicts.h, src/derives.c, | |
8141 | src/derives.h, src/files.c, src/files.h, src/getargs.c, | |
8142 | src/getargs.h, src/gram.c, src/gram.h, src/lalr.c, src/lalr.h, | |
8143 | src/location.c, src/location.h, src/main.c, src/muscle_tab.c, | |
8144 | src/muscle_tab.h, src/nullable.c, src/nullable.h, src/output.c, | |
8145 | src/output.h, src/parse-gram.c, src/parse-gram.h, | |
8146 | src/parse-gram.y, src/print.c, src/print.h, src/print_graph.c, | |
8147 | src/print_graph.h, src/reader.c, src/reader.h, src/reduce.c, | |
8148 | src/reduce.h, src/relation.c, src/relation.h, src/scan-gram.l, | |
8149 | src/scan-skel.l, src/state.c, src/state.h, src/symlist.c, | |
8150 | src/symlist.h, src/symtab.c, src/symtab.h, src/system.h, | |
8151 | src/tables.c, src/tables.h, src/uniqstr.c, src/uniqstr.h, | |
8152 | src/vcg.c, src/vcg.h, src/vcg_defaults.h, tests/Makefile.am, | |
8153 | tests/actions.at, tests/c++.at, tests/calc.at, tests/conflicts.at, | |
8154 | tests/cxx-type.at, tests/existing.at, tests/glr-regression.at, | |
8155 | tests/headers.at, tests/input.at, tests/local.at, tests/output.at, | |
8156 | tests/reduce.at, tests/regression.at, tests/sets.at, | |
8157 | tests/synclines.at, tests/testsuite.at, tests/torture.at: | |
8158 | Update FSF postal mail address. | |
8159 | ||
51f4735e PE |
8160 | 2005-05-11 Paul Eggert <eggert@cs.ucla.edu> |
8161 | ||
8162 | * tests/local.at (AT_COMPILE_CXX): Treat LDFLAGS like AT_COMPILE does. | |
8163 | Problem reported by Ralf Menzel. | |
8164 | ||
80ce3401 PE |
8165 | 2005-05-01 Paul Eggert <eggert@cs.ucla.edu> |
8166 | ||
8167 | * tests/actions.at: Test that stack overflow invokes destructors. | |
8168 | From Marcus Holland-Moritz. | |
8169 | * data/yacc.c (yyerrlab): Move the code that destroys the stack | |
8170 | from here.... | |
8171 | (yyreturn): to here. That way, destructors are called properly | |
8172 | even if the stack overflows, or the user calls YYACCEPT or | |
8173 | YYABORT. Stack-overflow problem reported by Marcus Holland-Moritz. | |
8174 | (yyoverflowlab): Destroy the lookahead. | |
8175 | ||
8176 | 2005-04-24 Paul Eggert <eggert@cs.ucla.edu> | |
8177 | ||
8178 | * data/yacc.c (YYSTACK_ALLOC_MAXIMUM): Add more-descriptive comment. | |
8179 | ||
72f000b0 PE |
8180 | 2005-04-17 Paul Eggert <eggert@cs.ucla.edu> |
8181 | ||
8182 | * NEWS: Bison-generated C parsers no longer quote literal strings | |
8183 | associated with tokens. | |
8184 | * src/output.c (prepare_symbols): Don't escape strings, | |
8185 | since users don't want to see C escapes. | |
8186 | * tests/calc.at (AT_CHECK_CALC): Adjust to lack of quotes | |
8187 | in diagnostics. | |
c19683bb | 8188 | * tests/input.at (Torturing the Scanner): Likewise. |
72f000b0 PE |
8189 | * tests/regression.at (Token definitions, Web2c Actions): Likewise. |
8190 | ||
1094323f PE |
8191 | 2005-04-16 Paul Eggert <eggert@cs.ucla.edu> |
8192 | ||
8193 | * tests/torture.at (AT_INCREASE_DATA_SIZE): Skip the test if | |
8194 | the data size is known to be too small and we can't increase it. | |
8195 | This works around an HP-UX 11.00 glitch reported by Andrew Benham. | |
8196 | ||
ca407bdf PE |
8197 | 2005-04-15 Paul Eggert <eggert@cs.ucla.edu> |
8198 | ||
8199 | * src/parse-gram.y: Include quotearg.h. | |
8200 | (string_as_id): Quote $1 before using it as a key, since the | |
8201 | lexer no longer quotes it for us. | |
8202 | (string_content): Don't strip quotes, since lexer no longer | |
8203 | quotes it for us. | |
8204 | * src/scan-gram.l: Include quotearg.h. | |
8205 | ("\""): Omit quote. | |
8206 | ("'"<SC_ESCAPED_CHARACTER>): Quote symbol before using it as | |
8207 | a key, since the rest of the lexer doesn't quote it. | |
8208 | * src/symtab.c (symbol_get): Don't quote symbol; caller does it now. | |
8209 | * tests/regression.at (Token definitions): Check for backslashes | |
8210 | in token strings. | |
8211 | ||
8212 | * data/yacc.c (YYSTACK_ALLOC_MAXIMUM): New macro. | |
8213 | (YYSIZE_T): Define to unsigned long int when using an older compiler. | |
8214 | (yyparse): Revamp code to generate long syntax error message, to | |
8215 | make it easier to translate, and to avoid problems with arithmetic | |
8216 | overflow. Change "virtual memory" to "memory" in diagnostic, since | |
8217 | we don't know whether the memory is virtual. | |
8218 | ||
1ce59070 PE |
8219 | 2005-04-13 Paul Eggert <eggert@cs.ucla.edu> |
8220 | ||
8221 | * NEWS: Bison-generated C parsers now use the _ macro to | |
8222 | translate strings. | |
8223 | * data/yacc.c (_) [!defined _]: New macro. | |
8224 | All English strings wrapped inside this macro. | |
8225 | * doc/bison.texinfo (Bison Parser): Document _. | |
8226 | * po/POTFILES.in: Include src/parse-gram.c, since it now | |
8227 | includes translateable strings that parse-gram.y doesn't. | |
8228 | ||
a749a695 PE |
8229 | 2005-04-12 Paul Eggert <eggert@cs.ucla.edu> |
8230 | ||
8231 | * src/symtab.c (symbol_make_alias): Call symbol_type_set, | |
8232 | reverting the 2004-10-11 change to this function. | |
8233 | (symbol_check_alias_consistency): Don't call symbol_type_set | |
8234 | if the type name is already correct. | |
8235 | * tests/input.at (Typed symbol aliases): New test, from Tim Van Holder. | |
8236 | ||
8fb1053b PE |
8237 | 2005-03-25 Paul Eggert <eggert@cs.ucla.edu> |
8238 | ||
8239 | * tests/regression.at (Token definitions): Don't use a token named | |
8240 | c, as that generates a "#define c ..." that runs afoul of buggy | |
8241 | stdlib.h that uses the identifier c as a member of struct | |
8242 | drand48_data. Problem reported by Horst Wente. | |
8243 | ||
ff498c4a PE |
8244 | 2005-03-21 Paul Eggert <eggert@cs.ucla.edu> |
8245 | ||
8246 | * bootstrap: Change translation URL from | |
8247 | http://www2.iro.umontreal.ca/~gnutra/po/maint/bison/ to | |
8248 | http://www.iro.umontreal.ca/translation/maint/bison/ to avoid | |
8249 | redirection glitches. Problem reported by twlevo@xs4all.nl. | |
8250 | ||
65211d70 PE |
8251 | 2005-03-20 Paul Eggert <eggert@cs.ucla.edu> |
8252 | ||
8253 | * tests/local.at (AT_COMPILE, AT_COMPILE_CXX): Don't put options | |
8254 | after operands; POSIX says this isn't portable for the c99 command. | |
8255 | ||
9577fb1f PE |
8256 | 2005-03-18 Paul Eggert <eggert@cs.ucla.edu> |
8257 | ||
8258 | * tests/glr-regression.at (glr-regr2a.y): Try to dump core | |
8259 | immediately if a data overrun has occurred; this may help us track | |
8260 | down what may be a spurious failure on MacOS. | |
8261 | ||
78b178f7 PE |
8262 | 2005-03-17 Paul Eggert <eggert@cs.ucla.edu> |
8263 | ||
a2599d0f PE |
8264 | Respond to problems reported by twlevo@xs4all.nl. |
8265 | ||
8266 | * bootstrap: Use "trap - 0" rather than the unportable "trap 0". | |
8267 | ||
78b178f7 PE |
8268 | * src/vcg.h: Comment fix. |
8269 | * src/vcg_defaults.h: Parenthesize macro bodies to make them safe. | |
8270 | (G_CMAX): Change to -1 instead of INT_MAX. | |
8271 | ||
8272 | * data/yacc.c (yyparse): Omit spaces before #line. | |
78b178f7 | 8273 | |
7296e729 PE |
8274 | 2005-03-15 Paul Eggert <eggert@cs.ucla.edu> |
8275 | ||
8276 | * src/tables.c (state_number_to_vector_number): Put it inside an | |
8277 | "#if 0", since it's not currently used. Problem reported by | |
8278 | Roland McGrath. | |
8279 | ||
05ac60f3 PE |
8280 | 2005-03-06 Paul Eggert <eggert@cs.ucla.edu> |
8281 | ||
8282 | * src/output.c (escaped_output): Renamed from | |
8283 | escaped_file_name_output, since we now use it for symbol tags as | |
8284 | well. All uses changed. | |
8285 | (symbol_destructors_output, symbol_printers_output): | |
8286 | Escape symbol tags too. | |
8287 | Problem reported by Matyas Forstner in | |
8288 | <http://lists.gnu.org/archive/html/bug-bison/2005-03/msg00009.html>. | |
8289 | ||
8290 | * src/muscle_tab.c (muscle_code_grow): Don't quote numbers; it's | |
8291 | not needed. | |
8292 | * src/output.c (user_actions_output, token_definitions_output, | |
8293 | symbol_destructors_output, symbol_printers_output): Likewise. | |
8294 | * src/reader.c (prologue_augment): Likewise. | |
8295 | * src/scan-gram.l (handle_action_dollar, handle_action_at): Likewise. | |
8296 | ||
8297 | * src/vcg.c (output_edge): Don't quote linestyle arg. | |
8298 | Problem reported by twlevo@xs4all.nl. | |
8299 | ||
7eb453ac PE |
8300 | 2005-02-28 Paul Eggert <eggert@cs.ucla.edu> |
8301 | ||
8302 | * doc/bison.texinfo (Semantic Tokens): Fix scoping problem in | |
8303 | example, reported by Derek M Jones. Also, make the example even | |
8304 | more outrageous, to better illustrate how bad the problem is. | |
8305 | ||
4c04c52a PE |
8306 | 2005-02-24 Paul Eggert <eggert@cs.ucla.edu> |
8307 | ||
8308 | * doc/bison.texinfo (Mfcalc Symtab): Correct the prototype for | |
8309 | putsym. Typo reported by Sebastian Piping. | |
8310 | ||
a61e1620 PE |
8311 | 2005-02-23 Paul Eggert <eggert@cs.ucla.edu> |
8312 | ||
8313 | * doc/bison.texinfo (Language and Grammar): some -> same | |
8314 | (Epilogue): int he -> in the | |
8315 | Typos reported by Sebastian Piping via Justin Pence. | |
8316 | ||
9ec93868 PE |
8317 | 2005-02-07 Paul Eggert <eggert@cs.ucla.edu> |
8318 | ||
8319 | * tests/glr-regression.at (Improper handling of embedded actions | |
8320 | and dollar(-N) in GLR parsers): Renamed from "Improper handling of | |
8321 | embedded actions and $-N in GLR parsers", work around an Autoconf bug | |
8322 | with dollar signs in test names. | |
8323 | * tests/input.at (Invalid dollar-n): Renamed from "Invalid \$n", | |
8324 | for a similar reason. | |
8325 | ||
73ce7e7e PE |
8326 | 2005-01-28 Paul Eggert <eggert@cs.ucla.edu> |
8327 | ||
8328 | * src/vcg.c (output_graph): G_VIEW -> normal_view in case someone | |
8329 | wants to redefine G_VIEW. | |
8330 | ||
2e72b98e PE |
8331 | 2005-01-27 Paul Eggert <eggert@cs.ucla.edu> |
8332 | ||
8333 | * src/vcg.c (get_view_str): Remove case for normal_view. | |
8334 | Problem reported by twlevo@xs4all.nl. | |
8335 | ||
e0d634e5 PE |
8336 | 2005-01-24 Paul Eggert <eggert@cs.ucla.edu> |
8337 | ||
ccf830a4 PE |
8338 | * configure.ac (O0CFLAGS, O0CXXFLAGS): Fix quoting bug. |
8339 | Problem reported by twlevo@xs4all.nl. | |
8340 | ||
e0d634e5 PE |
8341 | * doc/bison.texinfo: Change @dircategory from "GNU programming |
8342 | tools" to "Software development". Requested by Richard Stallman | |
8343 | via Karl Berry. | |
8344 | ||
7bbc8cb0 PE |
8345 | 2005-01-23 Paul Eggert <eggert@cs.ucla.edu> |
8346 | ||
8347 | * tests/c++.at (AT_CHECK_DOXYGEN): Don't use options after operands. | |
8348 | Problem reported by twlevo@xs4all.nl. | |
8349 | ||
08b770bc PE |
8350 | 2005-01-21 Paul Eggert <eggert@cs.ucla.edu> |
8351 | ||
8352 | * data/yacc.c (YYCOPY, yystpcpy, yyparse): Remove "register" | |
8353 | keyword; it's not needed with modern compilers, and it doesn't | |
8354 | affect correctness with older compilers. Suggested by | |
8355 | twlevo@xs4all.nl. | |
8356 | ||
95f22ad2 PE |
8357 | 2005-01-17 Paul Eggert <eggert@cs.ucla.edu> |
8358 | ||
8359 | * data/glr.c (yyuserAction): Add "default: break;" case to pacify | |
8360 | gcc -Wswitch-default. | |
8361 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Likewise. | |
8362 | * data/yacc.c (yyparse): Likewise. | |
8363 | ||
d229d15c PE |
8364 | 2005-01-12 Paul Eggert <eggert@cs.ucla.edu> |
8365 | ||
8366 | * src/system.h (OUTPUT_EXT, TAB_EXT): Define only if not defined | |
8367 | already. Let config.h define any nonstandard values. | |
8368 | ||
ecadd90f PE |
8369 | 2005-01-10 Paul Eggert <eggert@cs.ucla.edu> |
8370 | ||
8371 | * tests/calc.at (_AT_DATA_CALC_Y): Use alarm (100), not alarm (10), | |
8372 | for the benefit of slower hosts. Problem reported by | |
8373 | Nelson H. F. Beebe. | |
8374 | ||
213744b5 PE |
8375 | 2005-01-07 Paul Eggert <eggert@cs.ucla.edu> |
8376 | ||
8377 | * data/yacc.c (yyparse): Pacify non-GCC compilers about yyerrorlab | |
8378 | being defined and not used. | |
8379 | * data/lalr1.cc (yyparse): Likewise. | |
8380 | Use "if (false)" rather than "if (0)". | |
8381 | ||
249d3236 PE |
8382 | 2005-01-05 Paul Eggert <eggert@cs.ucla.edu> |
8383 | ||
8384 | * TODO: Mention that we should allow NUL bytes in tokens. | |
8385 | ||
987cc1fb PE |
8386 | 2005-01-02 Paul Eggert <eggert@cs.ucla.edu> |
8387 | ||
8388 | * src/scan-skel.l (<<EOF>>): Don't close standard output. | |
8389 | Problem reported by Hans Aberg. | |
8390 | ||
08fe02d9 PE |
8391 | 2005-01-01 Paul Eggert <eggert@cs.ucla.edu> |
8392 | ||
8393 | * src/getargs.c (version): Happy new year; update overall | |
8394 | program copyright date from 2004 to 2005. | |
8395 | ||
8396 | * src/scan-skel.l ("@output ".*\n): Don't close standard output. | |
8397 | Problem reported by Hans Aberg. | |
8398 | * tests/output.at (AT_CHECK_OUTPUT): New arg SHELLIO. | |
8399 | (Output file names.): Add a test for the case when standard output | |
8400 | is closed. | |
8401 | ||
010c0266 PE |
8402 | 2004-12-26 Paul Eggert <eggert@cs.ucla.edu> |
8403 | ||
8404 | * doc/bison.texinfo (@copying): Update FDL version number to 1.2, | |
8405 | to fix an oversight in the Bison 2.0 manual. | |
8406 | ||
da12206a PE |
8407 | 2004-12-25 Paul Eggert <eggert@cs.ucla.edu> |
8408 | ||
8409 | * NEWS: Version 2.0. Reformat the existing news items since | |
8410 | 1.875, so that related items are grouped together. | |
3a4734aa | 8411 | * configure.ac (AC_INIT): Bump version to 2.0. |
da12206a PE |
8412 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 2.0. |
8413 | ||
c935d934 PE |
8414 | * tests/torture.at (Exploding the Stack Size with Alloca): Set |
8415 | YYSTACK_USE_ALLOCA to 1 if __GNUC__ or alloca are defined; | |
8416 | otherwise, we're not testing alloca. Unfortunately there's no | |
8417 | simple way to consult HAVE_ALLOCA here. | |
8418 | ||
da12206a PE |
8419 | * data/lalr1.cc (yydestruct_): Pacify unused variable warning |
8420 | for yymsg, too. | |
8421 | ||
8422 | * src/LR0.c (new_itemsets): Use memset rather than zeroing by | |
8423 | hand. This avoids a warning about comparing int to size_t when | |
8424 | GCC warnings are enabled. | |
8425 | ||
0a2c5137 PE |
8426 | 2004-12-22 Paul Eggert <eggert@cs.ucla.edu> |
8427 | ||
d7e14fc0 PE |
8428 | * NEWS: Bison-generated parsers no longer default to using the |
8429 | alloca function (when available) to extend the parser stack, due | |
8430 | to widespread problems in unchecked stack-overflow detection. | |
8431 | * data/glr.c (YYMAXDEPTH): Remove undef when zero. It's the user's | |
8432 | responsibility to set it to a positive value. This lets the user | |
8433 | specify a value that is not a preprocessor constant. | |
8434 | * data/yacc.c (YYMAXDEPTH): Likewise. | |
8435 | (YYSTACK_ALLOC): Define only if YYSTACK_USE_ALLOCA is nonzero. | |
8436 | * doc/bison.texinfo (Stack Overflow): YYMAXDEPTH no longer needs | |
8437 | to be a compile-time constant. However, explain the constraints on it. | |
8438 | Also, explain the constraints on YYINITDEPTH. | |
8439 | (Table of Symbols): Explain that alloca is no longer the default. | |
8440 | Explain the user's responsibility if they define YYSTACK_USE_ALLOCA | |
8441 | to 1. | |
8442 | ||
0a2c5137 PE |
8443 | * doc/bison.texinfo (Location Default Action): Mention that n must |
8444 | be zero when k is zero. Suggested by Frank Heckenbach. | |
8445 | ||
e019c247 AD |
8446 | 2004-12-22 Akim Demaille <akim@epita.fr> |
8447 | ||
8448 | * data/lalr1.cc (parser::token_number_type, parser::rhs_number_type) | |
8449 | (parser::state_type, parser::semantic_type, parser::location_type): | |
8450 | Private, not public. | |
8451 | (parser::parse): Return ints, not bool. | |
8452 | Returning a bool introduces a problem: 0 corresponds to false, and | |
8453 | it seems weird to return false on success. Returning true changes | |
8454 | the conventions for yyparse. | |
8455 | Alternatively we could return void and send an exception. | |
8456 | There is no clear consensus (yet?). | |
8457 | (state_stack, semantic_stack, location_stack): Rename as... | |
8458 | (state_stack_type, semantic_stack_type, location_stack_type): these. | |
8459 | Private, not public. | |
8460 | * tests/c++.at: New. | |
8461 | * tests/testsuite.at, tests/Makefile.am: Adjust. | |
8462 | ||
72731bb7 AD |
8463 | 2004-12-21 Akim Demaille <akim@epita.fr> |
8464 | ||
8465 | * data/lalr1.cc (parser::parse): Return a bool instead of an int. | |
8466 | ||
9a0d8bec AD |
8467 | 2004-12-21 Akim Demaille <akim@epita.fr> |
8468 | ||
8469 | Don't impose std::string for filenames. | |
8470 | ||
8471 | * data/lalr1.cc (b4_filename_type): New. | |
8472 | (position::filename): Use it. | |
8473 | (parser.hh): Move the inclusion of stack.hh and location.hh below | |
8474 | the user code, so that needed headers for the filename type can be | |
8475 | included first. | |
72731bb7 AD |
8476 | Forward declare them before the user code. |
8477 | * tests/Makefile.am (check-local, installcheck-local): Pass | |
8478 | TESTSUITEFLAGS to the TESTSUITE. | |
9a0d8bec | 8479 | |
99880de5 AD |
8480 | 2004-12-20 Akim Demaille <akim@epita.fr> |
8481 | ||
8482 | Use more STL like names: my_class instead of MyClass. | |
8483 | ||
8484 | * data/lalr1.cc (LocationStack, LocationType, RhsNumberType) | |
8485 | (SemanticStack, SemanticType, StateStack, StateType) | |
8486 | (TokenNumberType, Stack, Slice, Traits, Parser::location) | |
8487 | (Parser::value): Rename as... | |
8488 | (location_stack, location_type, rhs_number_type, semantic_stack) | |
8489 | (semantic_type, state_stack, state_type, token_number_type, stack) | |
8490 | (slice, traits, parser::yylloc, parser::yylval): these. | |
8491 | ||
8492 | * tests/calc.at, tests/regression.at, tests/actions.at: Adjust. | |
8493 | ||
9bec482e PE |
8494 | 2004-12-19 Paul Eggert <eggert@cs.ucla.edu> |
8495 | ||
8496 | * data/glr.c (YYLLOC_DEFAULT): Use GNU spacing conventions. | |
8497 | * data/yacc.c (YYLLOC_DEFAULT): Likewise. | |
8498 | ||
f6fbd3da PE |
8499 | 2004-12-17 Paul Eggert <eggert@cs.ucla.edu> |
8500 | ||
8501 | Remove uses of 'short int' and 'unsigned short int'. This raises | |
8502 | some arbitrary limits. It uses more memory but nowadays that's | |
8503 | not much of an issue. | |
8504 | ||
8505 | This change does not affect the generated parsers; that's a different | |
8506 | task, as some users will want to conserve memory there. | |
8507 | ||
8508 | Ideally we should use size_t to represent all object counts, and | |
8509 | something like ptrdiff_t to represent signed differences of object | |
8510 | counts; but that will require more code-cleanup than I have the | |
8511 | time to do right now. | |
8512 | ||
8513 | * src/LR0.c (allocate_itemsets, new_itemsets, save_reductions): | |
8514 | Use size_t, not int or short int, to count objects. | |
8515 | * src/closure.c (nritemset, closure): Likewise. | |
8516 | * src/closure.h (nritemset, closure): Likewise. | |
8517 | * src/nullable.c (nullable_compute): Likewise. | |
8518 | * src/print.c (print_core): Likewise. | |
8519 | * src/print_graph.c (print_core): Likewise. | |
8520 | * src/state.c (state_compare, state_hash): Likewise. | |
8521 | * src/state.h (struct state): Likewise. | |
8522 | * src/tables.c (default_goto, goto_actions): Likewise. | |
8523 | ||
8524 | * src/gram.h (rule_number, rule): Use int, not short int. | |
8525 | * src/output.c (prepare_rules): Likewise. | |
8526 | * src/state.h (state_number, STATE_NUMBER_MAXIMUM, transitions, | |
8527 | errs, reductions): Likewise. | |
8528 | * src/symtab.h (symbol_number, SYMBOL_NUMBER_MAXIMUM, struct symbol): | |
8529 | Likewise. | |
8530 | * src/tables.c (vector_number, tally, action_number, | |
8531 | ACTION_NUMBER_MINIMUM): Likewise. | |
8532 | * src/output.c (muscle_insert_short_int_table): Remove. | |
8533 | ||
efeed023 AD |
8534 | 2004-12-17 Akim Demaille <akim@epita.fr> |
8535 | ||
8536 | * data/lalr1.cc: Extensive Doxygenation. | |
8537 | (error_): Rename as... | |
8538 | (error): this, since it is visible to the user. | |
8539 | Adjust callers. | |
8540 | (Parser::message): Now an automatic variable from... | |
8541 | (Parser::yyreport_syntax_error_): here. | |
8542 | * tests/actions.at, tests/calc.at, tests/regression.at: Adjust to | |
8543 | Parser::error. | |
8544 | * tests/input.at: Escape $. | |
8545 | ||
bc82c5a5 PE |
8546 | 2004-12-16 Paul Eggert <eggert@cs.ucla.edu> |
8547 | ||
8548 | * data/glr.c (b4_lhs_value, b4_rhs_value, b4_rhs-location): | |
8549 | Parenthesize rhs to avoid obscure problems with mistakes like | |
8550 | "foo$$bar = foo$1bar;". Problem reported by twlevo at xs4all. | |
8551 | * data/lalr1.cc (b4_lhs_value, b4_rhs_value, b4_lhs_location, | |
8552 | b4_rhs_location): Likewise. | |
8553 | * data/yacc.c (b4_lhs_value, b4_rhs_value, b4_lhs_location, | |
8554 | b4_rhs_location): Likewise. | |
8555 | ||
fd19f271 AD |
8556 | 2004-12-16 Akim Demaille <akim@epita.fr> |
8557 | ||
8558 | * data/lalr1.cc (yyreport_syntax_error_): Catch up with glr.c and | |
8559 | yacc.c: be sure to stay within yycheck_. | |
8560 | * tests/actions.at: Re-enable C++ tests. | |
8561 | ||
10454ea4 AD |
8562 | 2004-12-16 Akim Demaille <akim@epita.fr> |
8563 | ||
8564 | * src/print_graph.c (print_graph): Remove layoutalgorithm uses for | |
8565 | real. | |
8566 | ||
c5b95ccf AD |
8567 | 2004-12-16 Akim Demaille <akim@epita.fr> |
8568 | ||
8569 | Use #define to handle the %name-prefix. | |
8570 | ||
8571 | * data/glr.c, data/yacc.c: Comment changes. | |
8572 | * data/lalr1.cc (yylex): Use #define to select the name of yylex, | |
8573 | so that one can refer to yylex in the parser file, and have it | |
8574 | renamed, as is the case with other skeletons. | |
8575 | ||
617a8f12 AD |
8576 | 2004-12-16 Akim Demaille <akim@epita.fr> |
8577 | ||
8578 | Move lalr1.cc internals into yy*. | |
8579 | ||
8580 | * data/lalr1.cc (semantic_stack_, location_stack_, state_stack_) | |
8581 | (semantic_stack_, location_stack_, pact_, pact_ninf_, defact_) | |
8582 | (pgoto_, defgoto_, table_, table_ninf_, check_, stos_, r1_, r2_) | |
8583 | (name_, rhs_, prhs_, rline_, token_number_, eof_, last_, nnts_) | |
8584 | (empty_, final_, terror_, errcode_, ntokens_) | |
8585 | (user_token_number_max_, undef_token_, n_, len_, state_, nerrs_) | |
8586 | (looka_, ilooka_, error_range_, nerrs_): | |
8587 | Rename as... | |
8588 | (yysemantic_stack_, yylocation_stack_, yystate_stack_) | |
8589 | (yysemantic_stack_, yylocation_stack_, yypact_, yypact_ninf_) | |
8590 | (yydefact_, yypgoto_, yydefgoto_, yytable_, yytable_ninf_) | |
8591 | (yycheck_, yystos_, yyr1_, yyr2_, yyname_, yyrhs_, yyprhs_) | |
8592 | (yyrline_, yytoken_number_, yyeof_, yylast_, yynnts_, yyempty_) | |
8593 | (yyfinal_, yyterror_, yyerrcode_, yyntokens_) | |
8594 | (yyuser_token_number_max_, yyundef_token_, yyn_, yylen_, yystate_) | |
8595 | (yynerrs_, yylooka_, yyilooka_, yyerror_range_, yynerrs_): | |
8596 | these. | |
8597 | ||
1e547e6e PE |
8598 | 2004-12-15 Paul Eggert <eggert@cs.ucla.edu> |
8599 | ||
8600 | Fix some problems reported by twlevo at xs4all. | |
8601 | * src/symtab.c (symbol_new): Report an error if the input grammar | |
8602 | contains too many symbols. This is better than calling abort() later. | |
8603 | * src/vcg.h (enum layoutalgorithm): Remove. All uses removed. | |
8604 | (struct node, struct graph): | |
8605 | Rename member expand to stretch. All uses changed. | |
8606 | (struct graph): Remove member layoutalgorithm. All uses removed. | |
8607 | * src/vcg.c (get_layoutalgorithm_str): Remove. All uses removed. | |
8608 | * src/vcg_defaults.h (G_STRETCH): Renamed from G_EXPAND. | |
8609 | All uses changed. | |
8610 | (N_STRETCH): Rename from N_EXPAND. All uses changed. | |
8611 | ||
735d6bd4 AD |
8612 | 2004-12-15 Akim Demaille <akim@epita.fr> |
8613 | ||
8614 | * data/lalr1.cc: Normalize /** \brief ... */ to ///. | |
8615 | Add more Doxygen comments. | |
8616 | (symprint_, stack_print_, reduce_print_, destruct_, pop) | |
8617 | (report_syntax_error_, translate_): Rename as... | |
8618 | (yysymprint_, yystack_print_, yyreduce_print_, yydestruct_) | |
8619 | (yypop_, yyreport_syntax_error_, yytranslate_): this. | |
8620 | ||
2e1f5829 AD |
8621 | 2004-12-15 Akim Demaille <akim@epita.fr> |
8622 | ||
8623 | * data/lalr1.cc (lex_): Rename as... | |
8624 | (yylex_): this. | |
8625 | Move the trace here. | |
8626 | Take the %name-prefix into account. | |
8627 | Reported by Alexandre Duret-Lutz. | |
8628 | ||
a3cb6248 AD |
8629 | 2004-12-15 Akim Demaille <akim@epita.fr> |
8630 | ||
8631 | Simplify the C++ parser constructor. | |
8632 | ||
8633 | * data/lalr1.cc (debug_): Rename as... | |
8634 | (yydebug_): so that the parser's internals are always in the yy* | |
8635 | pseudo namespace. | |
8636 | Adjust uses. | |
8637 | (b4_parse_param_decl): Remove the leading comma as it is now only | |
8638 | called as unique argument list. | |
8639 | (Parser::Parser): Remove the constructor accepting a location and | |
8640 | an initial debugging level. | |
8641 | Remove from the other ctor the argument for the debugging level. | |
8642 | (debug_level_type, debug_level, set_debug_level): New. | |
8643 | ||
8644 | * tests/actions.at, tests/calc.at, tests/regression.at: Adjust | |
8645 | constructor calls. | |
8646 | ||
07fed891 AD |
8647 | 2004-12-15 Akim Demaille <akim@epita.fr> |
8648 | ||
8649 | Remove b4_root related material: failure experiment | |
a3cb6248 | 8650 | (which goal was to allow to derive from a class). |
07fed891 AD |
8651 | |
8652 | * data/lalr1.cc (b4_root, b4_param, b4_constructor): Remove | |
8653 | definitions and uses. | |
8654 | ||
e603eaa5 PE |
8655 | 2004-12-14 Paul Eggert <eggert@cs.ucla.edu> |
8656 | ||
8657 | * data/glr.c (struct yyGLRStack): yyerror_range now has 3 items, | |
8658 | not 2, since it's not portable to subtract 1 from the start of an | |
8659 | array. The new item 0 is never set or used. All uses changed. | |
8660 | ||
8661 | (yyrecoverSyntaxError): Use YYLLOC_DEFAULT instead of assuming | |
8662 | the default definition of YYLLOC_DEFAULT. Problem reported | |
8663 | by Frank Heckenbach. | |
8664 | ||
fafb007d PE |
8665 | 2004-12-12 Paul Eggert <eggert@cs.ucla.edu> |
8666 | ||
8667 | * data/glr.c (YYRHSLOC): Don't have two definitions, one for | |
8668 | the normal case and one for the error case. Just use the | |
8669 | first one uniformly. Problem reported by Frank Heckenbach. | |
8670 | (YYLLOC_DEFAULT): Use the conventions of yacc.c, so we can | |
8671 | use exactly the same macro in both places. | |
8672 | (yyerror_range): Now of type yyGLRStackItem, not YYLTYPE, | |
8673 | so that the normal-case YYRHSLOC works for the error case too. | |
8674 | All uses changed. | |
8675 | * data/yacc.c (YYRHSLOC): New macro, taken from glr.c. | |
8676 | (YYLLOC_DEFAULT): Use the same macro as glr.c. | |
8677 | * doc/bison.texinfo (Location Default Action): Don't claim that | |
8678 | we have an array of locations. Use the same macro for both glr | |
8679 | and lalr parsers. Mention YYRHSLOC. Mention what happens when | |
8680 | the index is 0. | |
8681 | ||
48814dcd PE |
8682 | 2004-12-10 Paul Eggert <eggert@cs.ucla.edu> |
8683 | ||
a4e1a53b PE |
8684 | * HACKING: Update email addresses to send announcements to. |
8685 | ||
48814dcd PE |
8686 | * configure.ac (AC_INIT): Bump version to 1.875f. |
8687 | ||
337116ba PE |
8688 | 2004-12-10 Paul Eggert <eggert@cs.ucla.edu> |
8689 | ||
8690 | * NEWS: Version 1.875e. | |
8691 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 1.875e. | |
8692 | ||
8693 | * src/scan-skel.l: Include "complain.h", for "fatal". | |
8694 | ||
8695 | * src/relation.h (relation_print, relation_digraph): | |
8696 | Relation sizes are of type relation_node, not size_t (this is | |
8697 | merely a doc fix, since the two types are equivalent). | |
8698 | (relation_transpose): Relation sizes are of type relation_node, | |
8699 | not int. | |
8700 | * src/relation.c: Likewise. | |
8701 | (top, infinity): Now of type relation_node, not int. | |
8702 | (traverse, relation_transpose): Use relation_node, not int. | |
8703 | ||
8704 | * data/glr.c (yyuserAction, yyrecoverSyntaxError): Mark args | |
8705 | with ATTRIBUTE_UNUSED if they're not used, to avoid GCC warning. | |
8706 | (yyparse): Remove unused local introduced in 2004-10-25 patch. | |
8707 | ||
8708 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): New arg | |
68b082af | 8709 | specifying whether the test should be skipped. Use it tp |
337116ba | 8710 | specify that the [%defines %skeleton "lalr1.cc"] tests currently |
68b082af | 8711 | fail on some hosts, and should be skipped. |
337116ba | 8712 | |
da2a7671 PE |
8713 | 2004-12-08 Paul Eggert <eggert@cs.ucla.edu> |
8714 | ||
8715 | * src/system.h (CALLOC, MALLOC, REALLOC): Remove. All callers | |
8716 | changed to use xcalloc, xnmalloc, xnrealloc, respectively, | |
8717 | unless otherwise specified below. | |
8718 | ||
8719 | * src/LR0.c (allocate_itemsets): Use xnmalloc, not xcalloc, | |
8720 | to allocate kernel_base, kernel_items, kernel_size, since | |
8721 | they needn't be initialized to 0. | |
8722 | (allocate_storgae): Likewise, for shiftset, redset, shift_symbol. | |
8723 | * src/closure.c (new_closure): Likewise, for itemset. | |
8724 | * src/derives.c (derives_compute): Likewise, for delts, derives, q. | |
8725 | * src/lalr.c (set_goto_map): Likewise, for temp_map. | |
8726 | (initialize_F): Likewise, for reads, edge, reads[i], includes[i]. | |
8727 | (build_relations): Likewise for edge, states1, includes. | |
8728 | * src/nullable.c (nullable_compute): Likewise, for squeue, relts. | |
8729 | * src/reader.c (packgram): Likewise, for ritem, rules. | |
8730 | * src/reduce.c (nonterminals_reduce): Likewise for nontermmap. | |
8731 | * src/relation.c (relation_digraph): Likewise for VERTICES. | |
8732 | (relation_transpose): Likewise for new_R, end_R. | |
8733 | * src/symtab.c (symbols_token_translations_init): Likewise for | |
8734 | token_translations. | |
8735 | * src/tables.c (save_row): Likewise for froms, tos, conflict_tos. | |
8736 | (token_actions): Likewise for yydefact, actrow, conflrow, | |
8737 | conflict_list. | |
8738 | (save_column): Likewise for froms[symno], tos[symno]. | |
8739 | (goto_actions): Likewise for state_count. | |
8740 | (pack_table): Likewise for base, pos, check. | |
8741 | (tables_generate): Likewise for width. | |
8742 | ||
8743 | * src/LR0.c (set_states): Don't reuse kernel_size and kernel_base | |
8744 | for initial core. Just have a separate core, so we needn't worry | |
8745 | about whether kernel_size and kernel_base are initialized. | |
8746 | ||
8747 | * src/LR0.c (shift_symbol, redset, shiftset, kernel_base, | |
8748 | kernel_size, kernel_items): Remove unnecessary initialization. | |
8749 | * src/conflicts.c (conflicts): Likewise. | |
8750 | * src/derives.c (derives): Likewise. | |
8751 | * src/muscle_tablc (muscle_insert): Likewise. | |
8752 | * src/relation.c (relation_digraph): Likewise. | |
8753 | * src/tables.c (froms, tos, conflict_tos, tally, width, actrow, order, | |
8754 | conflrow, conflict_table, conflict_list, table, check): | |
8755 | Likewise. | |
8756 | ||
8757 | * src/closure.c (new_closure): Arg is of type unsigned int, not int. | |
8758 | This is because all callers pass unsigned int. | |
8759 | * src/closure.h (new_closure): Likewise. | |
8760 | ||
8761 | * src/lalr.c (initialize_F): Initialize reads[i] in all cases. | |
8762 | (build_relations): Initialize includes[i] in all cases. | |
8763 | * src/reader.c (packgram): Always initialize rules[ruleno].prec | |
8764 | and rules[ruleno].precsym. Initialize members in order. | |
8765 | * src/relation.c (relation_transpose): Always initialize new_R[i] | |
8766 | and end_R[i]. | |
8767 | * src/table.c (conflict_row): Initialize 0 at end of conflict_list. | |
8768 | ||
8769 | * src/output.c (prepare_actions): Pass 0 instead of conflict_list[0]; | |
8770 | conflict_list[0] was always 0, but now it isn't initialized. | |
8771 | ||
8772 | * src/table.c (table_grow): When conflict_table grew, the grown | |
8773 | area wasn't cleared. Fix this. | |
8774 | ||
8775 | * lib/.cvsignore: Add strdup.c, strdup.h. | |
8776 | * m4/.cvsignore: Add strdup.m4. | |
8777 | ||
00baeeac PE |
8778 | 2004-12-07 Paul Eggert <eggert@cs.ucla.edu> |
8779 | ||
8780 | * src/lalr.h (GOTO_NUMBER_MAXIMUM): New macro. | |
8781 | * src/lalr.c (set_goto_map): Don't allow ngotos to equal | |
8782 | GOTO_NUMBER_MAXIMUM, since we occasionally compute | |
8783 | ngotos + 1 without checking for overflow. | |
8784 | (build_relations): Use END_NODE, not -1, to denote end of edges. | |
8785 | * src/lalr.c (set_goto_map, map_goto, initialize_F, add_loopback_edge, | |
8786 | build_relations): Use goto_number, not int, for goto numbers. | |
8787 | * src/tables.c (save_column, default_goto): Likewise. | |
8788 | ||
be3d9d42 AD |
8789 | 2004-11-23 Akim Demaille <akim@epita.fr> |
8790 | ||
8791 | * data/lalr1.cc (YYSTYPE): Define it as is done for C, instead | |
8792 | of #defining from yystype. | |
8793 | Don't typedef yystype, C++ does not need it. | |
8794 | This lets it possible to forward declare it as union. | |
8795 | ||
78e526d5 PE |
8796 | 2004-11-23 Paul Eggert <eggert@cs.ucla.edu> |
8797 | ||
8798 | * bootstrap (gnulib_modules): Add extensions. | |
8799 | Problem reported by Jim Meyering. | |
8800 | ||
afbb696d PE |
8801 | 2004-11-22 Paul Eggert <eggert@cs.ucla.edu> |
8802 | ||
8803 | * src/LR0.c, src/closure.c, src/derives.c, src/gram.c, | |
8804 | src/lalr.c, src/nullable.c, src/relation.c, src/scan-skel.l, | |
8805 | src/system.h, src/tables.c: XFREE -> free, to accommodate | |
8806 | recent change to gnulib xalloc.h. | |
78e526d5 | 8807 | Problem reported by Jim Meyering. |
afbb696d | 8808 | |
c1f8f16a AD |
8809 | 2004-11-17 Akim Demaille <akim@epita.fr> |
8810 | ||
8811 | * data/lalr1.cc (symprint_): Use cdebug_ to avoid warnings. | |
8812 | ||
db7e5eb5 | 8813 | 2004-11-17 Akim Demaille <akim@epita.fr>, |
9a1e9989 AD |
8814 | Alexandre Duret-Lutz <adl@gnu.org> |
8815 | ||
8816 | * data/lalr1.cc (Parser::yycdebug_): New, a pointer, to allow | |
8817 | changes. | |
8818 | (YYCDEBUG): Adjust. | |
8819 | Use it instead of cdebug_. | |
8820 | (Parser::debug_stream, Parser::set_debug_stream): New. | |
8821 | (Parser::symprint_): Define cdebug_ for temporary backward | |
8822 | compatibility. | |
8823 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Use | |
8824 | debug_stream (). | |
8825 | ||
68e11668 AD |
8826 | 2004-11-17 Akim Demaille <akim@epita.fr> |
8827 | ||
8828 | * data/lalr1.cc (Parser:print_): Remove, use %printer instead. | |
8829 | * tests/regression.at (_AT_DATA_DANCER_Y): Adjust. | |
8830 | * tests/calc.at (_AT_DATA_CALC_Y): Ditto. | |
8831 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise. | |
8832 | ||
97cbc73e PE |
8833 | 2004-10-27 Paul Eggert <eggert@cs.ucla.edu> |
8834 | ||
8835 | * data/glr.c (yyloc_default): Remove; not used. | |
8836 | Problem reported by Frank Heckenbach. | |
8837 | ||
e342c3be AD |
8838 | 2004-10-25 Akim Demaille <akim@epita.fr> |
8839 | ||
8840 | * data/glr.c (YYRHSLOC): Move its definition next to its uses. | |
8841 | Introduce another definition to address simple location arrays. | |
8842 | (yyGLRStack): New member: yyerror_range. | |
8843 | (yyrecoverSyntaxError, yyparse): Update it. | |
8844 | (yyrecoverSyntaxError): Use it when shifting the error token to | |
8845 | have an accurate range, equivalent to the one computed by both | |
8846 | yacc.c and lalr1.cc. | |
8847 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Change its yylex so | |
8848 | that column numbers start at column 0, as per GNU Coding | |
8849 | Standards, the others tests, and the doc. | |
8850 | (_AT_RESOLVED_GLR_OUTPUT_WITH_LOC, _AT_AMBIG_GLR_OUTPUT_WITH_LOC): | |
8851 | Adjust to the above change (first column is 0). | |
8852 | And adjust the location of the "<error>", now covering the whole | |
8853 | line. | |
8854 | ||
93602feb | 8855 | 2004-10-22 Akim Demaille <akim@epita.fr> |
04098407 | 8856 | and Paul Eggert <eggert@cs.ucla.edu> |
93602feb PE |
8857 | |
8858 | Remove some arbitrary limits on goto numbers and relations. | |
8859 | * src/lalr.c (goto_map, ngotos, from_state, to_state): Omit | |
8860 | initial values, since they're never used. | |
8861 | (set_goto_map): ngotos is now unsigned, so test for overflow | |
8862 | by seeing whether it wraps around to zero. | |
8863 | * src/lalr.h (goto_number): Now size_t, not short int. | |
8864 | (GOTO_NUMBER_MAXIMUM): Remove. | |
8865 | * src/relation.c (relation_print, traverse, relation_transpose): | |
8866 | Check for END_NODE rather than looking at sign. | |
8867 | * src/relation.h (END_NODE): New macro. | |
8868 | (relation_node): Now size_t, not short int. | |
8869 | ||
dba08b04 PE |
8870 | 2004-10-22 Paul Eggert <eggert@cs.ucla.edu> |
8871 | ||
8872 | * doc/bison.texinfo (Language and Grammar): In example, "int" is a | |
8873 | keyword, not an identifier. Problem reported by Baron Schwartz in | |
8874 | <http://lists.gnu.org/archive/html/bug-bison/2004-10/msg00017.html>. | |
8875 | ||
df09ef2e AD |
8876 | 2004-10-11 Akim Demaille <akim@epita.fr> |
8877 | ||
8878 | * src/symtab.c (symbol_check_alias_consistency): Also check | |
8879 | type names, destructors, and printers. | |
8880 | Reported by Alexandre Duret-Lutz. | |
8881 | Recode the handling of associativity and precedence in terms | |
8882 | of symbol_precedence_set. | |
8883 | Accept no redeclaration at all, not even equal to the previous | |
8884 | value. | |
8885 | (redeclaration): New. | |
8886 | Use it to factor redeclaration complaints. | |
8887 | (symbol_make_alias): Don't set the type of the alias, let | |
8888 | symbol_check_alias_consistency do it as for other features. | |
8889 | * src/symtab.h (symbol): Add new member prec_location, and | |
8890 | type_location. | |
8891 | * src/symtab.c (symbol_precedence_set, symbol_type_set): Set them. | |
8892 | * tests/input.at (Incompatible Aliases): New. | |
8893 | ||
146bc99d PE |
8894 | 2004-10-09 Paul Eggert <eggert@cs.ucla.edu> |
8895 | ||
8896 | .cvsignore fixes to accommodate gnulib changes, | |
8897 | and the practice of naming build directories "_build". | |
8898 | * .cvsignore: Add "_*". Sort. | |
8899 | * lib/.cvsignore: Add getopt_.h, xalloc-die.c. | |
8900 | * m4/.cvsignore: Add "*_gl.m4". | |
8901 | ||
e503aa60 AD |
8902 | 2004-10-06 Akim Demaille <akim@epita.fr> |
8903 | ||
8904 | * src/parse-gram.y (add_param): Fix the truncation of trailing | |
8905 | spaces. | |
8906 | ||
b4a20338 AD |
8907 | 2004-10-05 Akim Demaille <akim@epita.fr> |
8908 | ||
8909 | In Bison 1.875's yacc.c, YYLLOC_DEFAULT was called regardless | |
8910 | whether the reducion was empty or not. This leaves room to | |
8911 | improve the use of YYLLOC_DEFAULT in such a case. | |
8912 | lalr1.cc is still experimental, so changing this is acceptable. | |
8913 | And finally, there are probably not many users who changed the | |
8914 | handling of locations in GLR, so changing is admissible too. | |
8915 | ||
8916 | * data/glr.c, data/lalr1.cc, data/yacc.c (YYLLOC_DEFAULT): On an | |
8917 | empty reduction, set @$ to an empty location ending the previously | |
8918 | stacked symbol. | |
8919 | Adjust uses to make sure the code is triggered on empty | |
8920 | reductions. | |
8921 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust the | |
8922 | expected output: empty reductions have empty locations. | |
8923 | ||
f85a5e6f AD |
8924 | 2004-09-29 Akim Demaille <akim@epita.fr> |
8925 | ||
8926 | * data/lalr1.cc: Move towards a more standard C++ coding style | |
8927 | for templates: Class < T > -> Class<T>. | |
8928 | ||
b203fc2c AD |
8929 | 2004-09-29 Akim Demaille <akim@epita.fr> |
8930 | ||
8931 | * data/lalr1.cc: Reinstall the former ctor, for sake of | |
8932 | compatibility, but warn it will be removed. | |
8933 | Move towards a more standard C++ coding style (i.e., type *var -> | |
8934 | type* var). | |
8935 | ||
5b7e1e73 PE |
8936 | 2004-09-27 Paul Eggert <eggert@cs.ucla.edu> |
8937 | ||
3fee967f PE |
8938 | * src/parse-gram.y (add_param): Rewrite to avoid strchr, |
8939 | since it's less likely to work if NULs are involved in the future. | |
5b7e1e73 | 8940 | |
0dcca5c2 AD |
8941 | 2004-09-27 Akim Demaille <akim@epita.fr> |
8942 | ||
8943 | * data/yacc.c (YY_LOCATION_PRINT): Fix its default declaration. | |
8944 | ||
6dde1c82 AD |
8945 | 2004-09-27 Akim Demaille <akim@epita.fr> |
8946 | ||
8947 | * data/lalr1.cc (b4_parse_param_decl_1): New. | |
b203fc2c | 8948 | (b4_parse_param_decl): Use it to have different names between attribute |
6dde1c82 AD |
8949 | and argument names. |
8950 | (b4_cc_constructor_call): Likewise. | |
8951 | ||
b233d555 AD |
8952 | 2004-09-24 Akim Demaille <akim@epita.fr> |
8953 | ||
8954 | * src/parse-gram.y (add_param): Strip the leading and trailing | |
8955 | blanks from a formal argument declaration. | |
8956 | (YY_LOCATION_PRINT): New. | |
8957 | ||
619404e3 AD |
8958 | 2004-09-24 Akim Demaille <akim@epita.fr> |
8959 | ||
8960 | * data/c.m4 (b4_yysymprint_generate): Move the YYINPUT invocation | |
8961 | after the location. | |
8962 | ||
dd8d9022 AD |
8963 | 2004-09-24 Akim Demaille <akim@epita.fr> |
8964 | ||
8965 | * doc/bison.texinfo (Table of Symbols): Sort. | |
8966 | ||
0092f063 AD |
8967 | 2004-09-21 Akim Demaille <akim@epita.fr> |
8968 | ||
8969 | * data/yacc.c, data/glr.c (b4_at_dollar, b4_dollar_dollar): Remove | |
8970 | the useless parentheses. | |
8971 | Suggested by Paul Eggert. | |
8972 | ||
451364ed AD |
8973 | 2004-09-20 Akim Demaille <akim@epita.fr> |
8974 | ||
8975 | Let the initial-action act on the look-ahead, and use it for the | |
8976 | "initial push" (corresponding to an hypothetical beginning-of-file). | |
8977 | And let lalr1.cc honor %initial-action. | |
8978 | ||
8979 | * doc/bison.texinfo (Initial Action Decl): Clarify, and add an | |
8980 | example. | |
8981 | * data/lalr1.cc (Parser::initlocation_): Remove, bad experiment. | |
8982 | (Parser::Parser): Remove the ctor that used to initialize it. | |
8983 | (Parser::parse): Like in the other skeletons, issue the "starting | |
8984 | parse" message before any action. | |
8985 | Honor %initial-action. | |
8986 | Initialize the stacks with the lookahead. | |
8987 | * data/yacc.c: Let $$ and @$ in %initial-action designate the | |
8988 | look-ahead. | |
8989 | Push them in the stacks. | |
8990 | * tests/actions.at, tests/calc.at: Adjust the C++ ctor invocations. | |
8991 | ||
18d192f0 AD |
8992 | 2004-09-20 Akim Demaille <akim@epita.fr> |
8993 | ||
8994 | * doc/bison.texinfo (Initial Action Decl): New. | |
8995 | ||
b8458aa5 AD |
8996 | 2004-09-20 Akim Demaille <akim@epita.fr> |
8997 | ||
8998 | * data/yacc.c (YY_LOCATION_PRINT): Use YYLTYPE_IS_TRIVIAL as a | |
8999 | clearer criterion to define it. | |
9000 | (parse): Initialize the initial location when YYLTYPE_IS_TRIVIAL. | |
9001 | When reducing on an empty RHS, use the latest stacked location as | |
9002 | location. | |
9003 | yylloc is not always available. | |
9004 | * data/glr.c: Likewise. | |
9005 | Also, honor initial-actions. | |
9006 | ||
3fc16193 AD |
9007 | 2004-09-20 Akim Demaille <akim@epita.fr> |
9008 | ||
9009 | * data/yacc.c (YY_LOCATION_PRINT): New. | |
9010 | Define when we know YYLTYPE's structure, i.e., when the default | |
9011 | YYLLOC_DEFAULT is used. | |
9012 | * data/c.m4 (b4_yysymprint_generate): Use it. | |
9013 | * data/lalr1.cc (YYLLOC_DEFAULT): Stop relying on the initial | |
9014 | value of the result. | |
9015 | (error_start_): Replace with... | |
9016 | (error_range_): this location array. | |
9017 | This allows to replace code relying on the implementation of | |
9018 | locations by portable code. | |
9019 | * data/yacc.c (yylerrsp): Replace with... | |
9020 | (yyerror_range): this. | |
9021 | Every time a token is popped, update yyerror_range[0], to have an | |
9022 | accurate location for the error token. | |
9023 | * data/glr.c (YY_LOCATION_PRINT): New. | |
9024 | (yyprocessOneStack): Fix an invocation of YY_SYMBOL_PRINT: | |
9025 | deference a pointer. | |
9026 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): No longer | |
9027 | report the location in %printers. | |
9028 | ||
9029 | * src/scan-skel.l: Instead of abort, report error messages to ease | |
9030 | understanding skeleton scanning failures. | |
9031 | ||
ecfe33e7 AD |
9032 | 2004-09-16 Akim Demaille <akim@epita.fr> |
9033 | ||
9034 | * data/lalr1.cc (Stack::Iterator, Stack::ConstIterator): Rename as... | |
9035 | (iterator, const_iterator): these, to be more in the C++ spirit. | |
9036 | Also, return reverse iterators so that when displaying the stack | |
9037 | we display its bottom first. | |
9038 | (Parser::stack_print_, Parser::reduce_print_): Match the messages | |
9039 | from yacc.c. | |
9040 | We should probably use vector here though. | |
9041 | ||
1576d44d AD |
9042 | 2004-09-16 Akim Demaille <akim@epita.fr> |
9043 | ||
9044 | Have more complete shift traces. | |
9045 | ||
9046 | * data/yacc.c, data/lalr1.c, data/glr.c: Use YY_SYMBOL_PRINT | |
9047 | to report Shifts instead of ad hoc YYDPRINTF invocations, | |
9048 | including for the error token. | |
9049 | * data/lalr1.cc (symprint_): Output the location. | |
9050 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): In C++, don't | |
9051 | output the location within the %printer. | |
9052 | Activate GLR tests, at least to make sure they compile properly. | |
9053 | They still don't pass though. | |
9054 | * tests/calc.at: Adjust expect verbose output, since now "Entering | |
9055 | state..." is on a different line than the "Shifting" message. | |
9056 | ||
9c66f418 AD |
9057 | 2004-09-08 Akim Demaille <akim@epita.fr> |
9058 | ||
9059 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Move the | |
9060 | Bison directive from the Bison file to the invocation of this | |
9061 | macro, so that these directives are passed to | |
9062 | AT_BISON_OPTION_PUSHDEFS to get correct help macros. | |
9063 | Use these helping macros (e.g., AT_LOC, AT_VAL and so forth). | |
9064 | Move the AT_SETUP/AT_CLEANUP outside, to report as test title | |
9065 | the extra Bison directives instead of the whole series. | |
9066 | Change the grammar so that there are recoverable errors, and | |
9067 | unrecoverable errors. Now we can have the parser give up before | |
9068 | consuming the whole input. As a result we now can observe that | |
9069 | the lookahead is freed when needed. | |
9070 | Change the parser source to parse argv[1] instead of a hard coded | |
9071 | string. | |
9072 | Simplify yylex, and give a value and location to EOF. | |
9073 | Simplify some invocations of AT_CHECK_PRINTER_AND_DESTRUCTOR that | |
9074 | passed directives already coded in the file. | |
9075 | Add some tests to check the location of "error". | |
9076 | For some tests, the C++ parser is correct, and not yacc.c. | |
9077 | For other tests, they provide different, but unsatisfying, values, | |
9078 | so keep the C++ value so that at least one parser is "correct" | |
9079 | according to the test suite. | |
9080 | (Actions after errors): Remove, this is subsumed by the | |
9081 | AT_CHECK_PRINTER_AND_DESTRUCTOR series. | |
9082 | ||
52d5733f AD |
9083 | 2004-09-06 Akim Demaille <akim@epita.fr> |
9084 | ||
9085 | * data/lalr1.cc: Adjust the indentation of the labels. | |
04098407 | 9086 | (Parser::pop): New. |
52d5733f AD |
9087 | Use it. |
9088 | ||
a0e68930 AD |
9089 | 2004-09-06 Akim Demaille <akim@epita.fr> |
9090 | ||
9091 | * data/yacc.cc, data/glr.cc (yydestruct): Accept an additional | |
9092 | argument, an informative message. | |
9093 | Call YY_SYMBOL_PRINT. | |
9094 | Adjust all callers: integrate the associated YY_SYMBOL_PRINT. | |
9095 | * data/lalr1.cc (destruct_): Likewise. | |
9096 | In addition, no longer depend on b4_yysymprint_generate and | |
9097 | b4_yydestruct_generate to generate these functions, do it "by | |
9098 | hand". | |
9099 | ||
e757bb10 AD |
9100 | 2004-09-03 Akim Demaille <akim@epita.fr> |
9101 | ||
9102 | * data/glr.c, data/lalr1.cc, data/yacc.c: When YYABORT was | |
9103 | invoked, yydestruct the lookahead. | |
9104 | * tests/calc.at (Calculator $1): Update the expected lengths of | |
9105 | traces: there is an added line for the discarded lookahead. | |
9106 | * doc/bison.texinfo (Destructor Decl): Some rewording. | |
9107 | Define "discarded" symbols. | |
9108 | ||
0fe1f06d AD |
9109 | 2004-09-02 Akim Demaille <akim@epita.fr> |
9110 | ||
9111 | * data/lalr1.cc (translate_, destruct_): No reason to be static. | |
9112 | ||
284acc8b AD |
9113 | 2004-09-02 Akim Demaille <akim@epita.fr> |
9114 | ||
9115 | * data/glr.c, yacc.c (YYDSYMPRINT): Remove, not used. | |
9116 | (YYDSYMPRINTF): Rename as... | |
9117 | (YY_SYMBOL_PRINT): this. | |
9118 | * data/lalr1.cc (YY_SYMBOL_PRINT): New, modeled after the previous | |
9119 | two. | |
9120 | Use it instead of direct symprint_ calls. | |
9121 | (yybackup): Tweak the "Now at end of input" case to match yacc.c's | |
9122 | one. | |
9123 | ||
a5eb1ed2 AD |
9124 | 2004-09-02 Akim Demaille <akim@epita.fr> |
9125 | ||
b7c72fe1 AD |
9126 | * data/lalr1.cc (b4_yysymprint_generate): New. |
9127 | (symprint_): New member function, defined when YYDEBUG. | |
9128 | Use it consistently instead of token/nterm debugging output by | |
9129 | hand. | |
a5eb1ed2 AD |
9130 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust |
9131 | %printer calls to use cdebug_ when using lalr1.cc. | |
9132 | ||
417141dd AD |
9133 | 2004-08-30 Florian Krohm <florian@edamail.fishkill.ibm.com> |
9134 | ||
9135 | * data/glr.c: Guard the declarations of yypstack and yypdumpstack | |
9136 | with #ifdef YYDEBUG. | |
9137 | ||
2fa09258 AD |
9138 | 2004-08-26 Akim Demaille <akim@epita.fr> |
9139 | ||
9140 | * doc/bison.texinfo (Implementing Loops): Rename as... | |
9141 | (Implementing Gotos/Loops): this. | |
9142 | ||
9378b508 PE |
9143 | 2004-08-13 Paul Eggert <eggert@cs.ucla.edu> |
9144 | ||
9145 | Adjust to latest gnulib. | |
9146 | * bootstrap (gnulib_modules): Add xalloc-die. | |
9147 | Set LC_ALL=C so that file names sort consistently. | |
9148 | Prefer the gnulib copies of gettext.m4, glibc21.m4, | |
9149 | inttypes_h.m4, lib-ld.m4, lib-prefix.m4, po.m4, stdint_h.m4, | |
9150 | uintmax_t.m4, ulonglong.m4. | |
9151 | (intl_files_to_remove): Add gettext.m4, lib-ld.m4, lib-prefix.m4, | |
9152 | po.m4 since we are now using _gl.m4 instead. | |
9153 | ||
87a8ad5c PE |
9154 | 2004-08-10 Florian Krohm <florian@edamail.fishkill.ibm.com> |
9155 | ||
9156 | * src/scan-action.l: Remove. Scanning of semantic actions is | |
9157 | handled in scan-gram.l. | |
9158 | ||
dca81a78 PE |
9159 | 2004-08-07 Florian Krohm <florian@edamail.fishkill.ibm.com> |
9160 | ||
9161 | * src/scan-gram.l (handle_syncline): Use uniqstr_new not xstrdup. | |
9162 | ||
9163 | * src/location.h (struct): The file member is a uniqstr. | |
9164 | (equal_boundaries): Use UNIQSTR_EQ for comparison. | |
9165 | ||
c9cbf7c5 PE |
9166 | 2004-07-22 Paul Eggert <eggert@cs.ucla.edu> |
9167 | ||
9168 | Fix bug with non-%union parsers that have printers or destructors, | |
9169 | which led to a Bison core dump. Reported by Peter Fales in | |
9170 | <http://lists.gnu.org/archive/html/bug-bison/2004-07/msg00014.html>. | |
2fa09258 | 9171 | |
c9cbf7c5 PE |
9172 | * data/c.m4 (b4_symbol_actions): Don't assume %union was used. |
9173 | * data/lalr1.cc (yystype) [defined YYSTYPE]: Define to YYSTYPE, | |
9174 | not to our own type. | |
9175 | * src/output.c (symbol_destructors_output, symbol_printers_output): | |
9176 | Don't assume %union. | |
9177 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR, | |
9178 | AT_CHECK_PRINTER_AND_DESTRUCTOR): New argument | |
9179 | UNION-FLAG. All callers changed. | |
9180 | (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Don't assume %union. | |
9181 | Use type char, not unsigned int, when declaring an array of char; | |
9182 | this lets us remove a cast. | |
9183 | (Printers and Destructors): Add non-%union test cases. | |
9184 | ||
fa7e68c3 PE |
9185 | 2004-06-21 Paul Eggert <eggert@cs.ucla.edu> |
9186 | ||
9187 | * doc/bison.texinfo: Minor editorial changes, mostly to the new | |
9188 | GLR writeups. E.g., avoid frenchspacing and the future tense, | |
9189 | change "lookahead" to "look-ahead", and change "wrt" to "with | |
9190 | respect to". | |
2fa09258 | 9191 | |
fa7e68c3 PE |
9192 | 2004-06-21 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> |
9193 | ||
9194 | * doc/bison.texinfo (Merging GLR Parses, Compiler Requirements): | |
9195 | New sections, split off from the GLR Parsers section. Put the new | |
9196 | Simple GLR Parser near the start of the GLR section, for clarity. | |
9197 | Rewrite connective text. | |
9198 | ||
99a9344e PE |
9199 | 2004-06-21 Frank Heckenbach <frank@g-n-u.de> |
9200 | ||
9201 | * doc/bison.texinfo (Simple GLR Parsers): New section. | |
9202 | ||
8dd162d3 PE |
9203 | 2004-06-21 Paul Eggert <eggert@cs.ucla.edu> |
9204 | ||
9205 | * NEWS, TODO, doc/bison.texinfo: | |
9206 | Use "look-ahead" instead of "lookahead", to be consistent. | |
9207 | * REFERENCES: Fix incorrect reference to DeRemer and Pennello, | |
9208 | while we're fixing "look-ahead". | |
9209 | * src/conflicts.c (shift_set): Renamed from shiftset. | |
9210 | (look_ahead_set): Renamed from lookaheadset. | |
9211 | * src/print.c: Likewise. | |
9212 | * src/getargs.c (report_args): Add "look-ahead" as the new canonical | |
9213 | name for "lookahead". | |
9214 | (report_types, usage): Likewise. | |
9215 | * src/getargs.h (report_look_ahead_tokens): Renamed from | |
9216 | report_lookaheads. | |
9217 | * src/lalr.c (compute_look_ahead_tokens): Renamed from | |
9218 | compute_lookaheads. | |
9219 | (state_look_ahead_tokens_count): Renamed from state_lookaheads_count. | |
9220 | (look_ahead_tokens_print): Renamed from lookaheads_print. | |
9221 | * src/state.c (state_rule_look_ahead_tokens_print): Renamed from | |
9222 | state_rule_lookaheads_print. | |
9223 | * src/state.h: Likewise. | |
9224 | (reductions.look_ahead_tokens): Renamed from lookaheads. | |
9225 | * tests/torture.at (AT_DATA_LOOK_AHEAD_TOKENS_GRAMMAR): Renamed from | |
9226 | AT_DATA_LOOKAHEADS_GRAMMAR. | |
9227 | ||
57a90331 PE |
9228 | 2004-06-03 Paul Eggert <eggert@cs.ucla.edu> |
9229 | ||
9230 | * README: Update location of patched M4 distribution. | |
9231 | ||
8ed3234a PE |
9232 | 2004-05-30 Albert Chin-A-Young <china@thewrittenword.com> |
9233 | ||
9234 | Don't assume the C++ compiler takes the same arguments as the C compiler | |
9235 | (trivial change). | |
9236 | * configure.ac (O0CXXFLAGS): New var. | |
9237 | * tests/atlocal.in (CXXFLAGS): Use it. | |
9238 | ||
07971983 PE |
9239 | 2004-05-29 Paul Eggert <eggert@cs.ucla.edu> |
9240 | ||
9241 | Fix some "make check" problems with C++ reported by | |
9242 | Albert Chin-A-Young for Tru64 C++ in this thread: | |
9243 | http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00049.html | |
9244 | ||
9245 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Check for std::cerr. | |
9246 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
9247 | Output to a .cc file for C++, not to a .c file. | |
9248 | * tests/calc.at (AT_CHECK_CALC): Likewise. | |
9249 | * tests/regression.at (AT_CHECK_DANCER): Likewise. | |
9250 | * tests/local.at (AT_COMPILE_CXX): Default to OUTPUT.cc, not OUTPUT.c. | |
9251 | ||
29058652 PE |
9252 | 2004-05-28 Albert Chin-A-Young <china@thewrittenword.com> |
9253 | ||
9254 | * tests/calc.at, tests/actions.at: Workaround for SGI | |
9255 | C++ compiler. (trivial change) | |
9256 | ||
62cb8a99 PE |
9257 | 2004-05-27 Paul Eggert <eggert@cs.ucla.edu> |
9258 | ||
fd418816 PE |
9259 | Spent a few hours checking out which prerequisite versions the |
9260 | current sources actually require. I went all the way back to | |
9261 | Gettext 0.10.40, Automake 1.4, and Autoconf 2.57 and investigated | |
9262 | a seemingly endless set of combinations of versions more recent | |
9263 | than that. The bottom line is that the current sources require | |
9264 | fairly recent versions of the build tools, and it'll be some work | |
9265 | to change this. | |
9266 | * configure.ac (AC_PREREQ): Increase from 2.58 to 2.59. | |
9267 | (AM_INIT_AUTOMAKE): Increase from 1.7 to 1.8. | |
9268 | (AM_GNU_GETTEXT_VERSION): Increase from 0.11.5 to 0.12. | |
9269 | Add comments explaining why those particular versions are | |
9270 | currently needed. | |
2fa09258 | 9271 | |
62cb8a99 PE |
9272 | * src/parse-gram.y (lloc_default): Rewrite to avoid compiler bug |
9273 | in SGI MIPSpro 7.4.1m. Problem reported by Albert Chin-A-Young in | |
161a71f3 | 9274 | <http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00037.html>. |
62cb8a99 PE |
9275 | |
9276 | * configure.ac (AC_PREREQ): Bump to 2.58, since 2.57 doesn't work | |
9277 | (it fails with a Autoconf-without-aclocal-m4 diagnostic). | |
9278 | ||
caa52c10 PE |
9279 | 2004-05-26 Paul Eggert <eggert@cs.ucla.edu> |
9280 | ||
9281 | * configure.ac (AM_GNU_GETTEXT_VERSION): Lower it from 0.14.1 to | |
9282 | 0.11.5. Suggested by Bruno Haible. | |
9283 | * bootstrap: Remove gettext version checking. | |
9284 | ||
9285 | * doc/bison.texinfo (Decl Summary): Also mention that %union | |
9286 | can depend on prerequisite types. Problem reported by Tim | |
9287 | Van Holder. | |
9288 | ||
4bfd5e4e PE |
9289 | 2004-05-25 Paul Eggert <eggert@cs.ucla.edu> |
9290 | ||
2cef3017 PE |
9291 | * README: Mention GNU m4 1.4 bugs and Akim's patched version. |
9292 | * README-alpha: Don't tell people not to package this. | |
9293 | ||
b9c85d5c PE |
9294 | * bootstrap: Don't assume $(...) works; use `...` instead. |
9295 | Problem reported by Paul Hilfinger. Also, diagnose non-GNU | |
9296 | gettext better. | |
9297 | ||
4bfd5e4e PE |
9298 | * doc/bison.texinfo (Decl Summary, Bison Options): Clarify what's |
9299 | put into the -d output file, and mention what to do if YYSTYPE is | |
9300 | defined as a macro. | |
9301 | ||
6a36ff94 PE |
9302 | 2004-05-24 Paul Eggert <eggert@cs.ucla.edu> |
9303 | ||
6712933e PE |
9304 | Undo change made earlier today: it caused autopoint to not bring |
9305 | in ABOUT-NLS. Ouch. Instead, substitute our own diagnostic for | |
9306 | autopoint's. | |
9307 | ||
9308 | * bootstrap: Check that gettext version matches what's in | |
9309 | configure.ac. Warn users to ignore robots.txt ERROR 404. | |
9310 | * bootstrap: Undo today's earlier change (logged below). | |
9311 | * configure.ac (AM_GNU_GETTEXT_VERSION): Likewise. | |
b9c85d5c | 9312 | |
6a36ff94 PE |
9313 | The gettext version checking is causing more trouble than it's |
9314 | curing; remove it. Problem reported by Paul Hilfinger. | |
9315 | ||
9316 | * bootstrap: Issue a warning that one can expect a message | |
9317 | 'AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION'. | |
9318 | * configure.ac (AM_GNU_GETTEXT_VERSION): Remove. | |
9319 | ||
209ea708 PE |
9320 | 2004-05-23 Paul Eggert <eggert@cs.ucla.edu> |
9321 | ||
9322 | Ensure that the C++ compiler used for testing actually works on a | |
9323 | simple test program; if not, skip the C++-related tests. Problem | |
9324 | reported by Vin Shelton in: | |
161a71f3 | 9325 | http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00026.html |
209ea708 PE |
9326 | |
9327 | * m4/cxx.m4: New file. | |
9328 | * configure.ac (BISON_TEST_FOR_WORKING_CXX_COMPILER): Add. | |
9329 | * tests/atlocal.in (BISON_CXX_WORKS): Add. | |
9330 | * tests/local.at (AT_COMPILE_CXX): Use it. | |
9331 | ||
41ca2549 PE |
9332 | 2004-05-21 Paul Eggert <eggert@cs.ucla.edu> |
9333 | ||
383e69dc PE |
9334 | * data/glr.c (yylloc): Output this macro even if locations are not |
9335 | being generated, as the GLR parser needs it even in that case. | |
9336 | Problem reported by Troy A. Johnson | |
9337 | <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=195946>. | |
9338 | ||
41ca2549 PE |
9339 | * configure.ac (AC_INIT): Update to 1.875e. |
9340 | ||
e476c87d PE |
9341 | 2004-05-21 Paul Eggert <eggert@cs.ucla.edu> |
9342 | ||
9343 | * NEWS: Version 1.875d. | |
9344 | * configure.ac (AC_INIT): Likewise. | |
9345 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 1.875d. | |
9346 | ||
9347 | * configure.ac (--enable-gcc-warnings): Do not enable -Wshadow, | |
9348 | -Wmissing-prototypes, or -Wstrict-prototypes for C++. The current | |
9349 | lalr1.cc runs afoul of the first, and the last two are no longer | |
9350 | supported by GCC 3.4.0. | |
9351 | * README: Mention GNU m4 1.4 or later; mention m4 patches. | |
9352 | * HACKING: Use ./bootstrap, not "make update" to import foreign files. | |
9353 | ||
233a88ad PE |
9354 | 2004-05-06 Paul Eggert <eggert@cs.ucla.edu> |
9355 | ||
9356 | * src/muscle_tab.c (hash_muscle): Accept and return size_t, not | |
9357 | unsigned int, for compatibility with latest gnulib hash module. | |
9358 | * src/state.c (state_hash, state_hasher): Likewise. | |
9359 | * src/symtab.c (hash_symbol, hash_symbol_hasher): Likewise. | |
9360 | * src/uniqstr.c (hash_uniqstr): Likewise. | |
e476c87d | 9361 | |
12ffdd28 PE |
9362 | 2004-05-03 Paul Eggert <eggert@cs.ucla.edu> |
9363 | ||
9364 | * NEWS: Unescaped newlines are no longer allowed in char & strings. | |
9365 | ||
9366 | * src/scan-gram.l (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER, | |
9367 | SC_CHARACTER,SC_STRING>): Reject unescaped newlines in | |
9368 | character and string literals. | |
9369 | (unexpected_end): New function. | |
9370 | (unexpected_eof): Use it. | |
9371 | (unexpected_newline): New function. | |
9372 | (<INITIAL,SC_AFTER_IDENTIFIER,SC_PRE_CODE>): Coalesce duplicate | |
9373 | actions. | |
e476c87d | 9374 | |
12ffdd28 PE |
9375 | * NEWS: Document %expect-rr. |
9376 | ||
9377 | * bootstrap (--gnulib-srcdir=*, --cvs-user=*): | |
9378 | Fix typo by replacing $1 with $option. | |
9379 | Remove more 'intl'-related files. | |
9668e2be | 9380 | Don't DEFUN AM_INTL_SUBDIR twice. |
12ffdd28 PE |
9381 | |
9382 | * lib/.cvsignore: Add strndup.h. Remove memchr.c, memcmp.c, | |
9383 | memrchr.c, strcasecmp.c, strchr.c, strrchr.c, strspn.c, strtol.c, | |
9384 | strtoul.c. | |
9385 | * m4/.cvsignore: Add exitfail.m4, extensions.m4, gnulib.m4, | |
9386 | hard-locale.m4, mbstate_t.m4, strerror_r.m4, strndup.m4, | |
9387 | xstrndup.m4. Remove glibc21.m4, intdiv0.m4, inttypes-pri.m4, | |
9388 | inttypes.m4, inttypes_h.m4, isc-posix.m4, lcmessage.m4, | |
9389 | stdint_h.m4, uintmax_t.m4, ulonglong.m4. | |
9390 | * src/.cvsignore: Add *.output. | |
9391 | ||
9392 | * src/parse-gram.y: Put copyright notice inside %{ %} so it | |
9393 | gets copied to the output file. | |
e476c87d | 9394 | |
1f65350a PE |
9395 | 2004-04-28 Paul Eggert <eggert@twinsun.com> |
9396 | ||
9397 | Get files from the gnulib and po repositories, instead of relying | |
9398 | on them being in our CVS. Upgrade to latest versions of gnulib | |
9399 | and Automake. | |
9400 | ||
9401 | * Makefile.am (SUBDIRS): Remove m4; Automake now does m4. | |
9402 | * bootstrap: Bootstrap from gnulib and po repositories. | |
9403 | Much of this code was stolen from GNU diff and GNU tar's bootstrap. | |
9404 | * README-cvs: Document these changes. Remove version numbers from | |
9405 | mentions of build tools, since they change so often. Mention Flex. | |
9406 | ||
9407 | * configure.ac (AC_CONFIG_MACRO_DIR): Add, with m4 as arg. | |
9408 | (gl_USE_SYSTEM_EXTENSIONS): Add. | |
12ffdd28 PE |
9409 | (AC_GNU_SOURCE, AC_AIX, AC_MINIX): |
9410 | Remove; no longer needed, as gl_USE_SYSTEM_EXTENSIONS | |
1f65350a | 9411 | does this for us. |
12ffdd28 PE |
9412 | (AC_ISC_POSIX): Remove; we no longer support this |
9413 | ancient OS, as it gets in the way of latest Autoconf & gnulib. | |
1f65350a PE |
9414 | (AC_HEADER_STDC): Remove: we now assume C89 or better. |
9415 | (AC_CHECK_HEADERS_ONCE): Use instead of AC_CHECK_HEADERS. | |
9416 | Do not check for C89 headers, except for locale.h which is used | |
9417 | by the Yacc library and must port to K&R hosts. | |
9418 | (AC_CHECK_FUNCS_ONCE): Use instead of AC_CHECK_FUNCS. | |
9419 | Do not check for C89 functions, except for setlocale which is | |
9420 | used by the Yacc library. | |
9421 | (AC_CHECK_DECLS, AC_REPLACE_FUNCS): Remove; no longer needed. | |
9422 | (gl_DIRNAME, gl_ERROR, gl_FUNC_ALLOCA, gl_FUNC_MEMCHR, | |
9423 | gl_FUNC_MEMRCHR, gl_FUNC_STPCPY, gl_FUNC_STRNLEN, gl_FUNC_STRTOL, | |
9424 | gl_GETOPT, gl_HASH, gl_MBSWIDTH, gl_OBSTACK, gl_QUOTE, | |
9425 | gl_QUOTEARG, gl_XALLOC, jm_FUNC_GLIBC_UNLOCKED_IO, jm_FUNC_MALLOC, | |
9426 | AM_GNU_GETTEXT): Remove; now done by: | |
9427 | (GNULIB_AUTOCONF_SNIPPET): Add. "bootstrap" builds this for us. | |
9428 | (AC_CONFIG_FILES): Remove m4/Makefile, as Automake now does this | |
9429 | for us. | |
9430 | ||
9431 | * lib/Makefile.am: Include gnulib.mk, built for us by "bootstrap". | |
9432 | (BUILT_SOURCES, EXTRA_DIST, MOSTLYCLEANFILES): | |
9433 | Define to empty, as gnulib.mk will do the rest for us. | |
9434 | ($(libbison_a_OBJECTS), stdbool.h): Remove, as gnulib.mk does this | |
9435 | for us. | |
9436 | (libbison_a_SOURCES): Define to $(lib_SOURCES) now. | |
9437 | (lib_SOURCES): New symbol, containing only the non-gnulib libs. | |
9438 | ||
9439 | * src/files.c: Include gnulib's xstrndup.h. | |
9440 | ||
9441 | * src/system.h (MALLOC): Use xnmalloc, for better overflow checking. | |
9442 | (REALLOC): Use xnrealloc, for likewise. | |
9443 | (xstrndup, stpcpy): Remove decls, as gnulib does this for us now. | |
9444 | (strnlen, memrchr): Remove decls; functions no longer used. | |
9445 | Include <stpcpy.h>. | |
9446 | ||
9447 | * config/depcomp, config/install-sh, lib/alloca.c, lib/argmatch.c, | |
9448 | lib/argmatch.h, lib/basename.c, lib/dirname.c, lib/dirname.h, | |
9449 | lib/error.c, lib/error.h, lib/getopt.c, lib/getopt.h, | |
9450 | lib/getopt1.c, lib/gettext.h, lib/hash.c, lib/hash.h, | |
9451 | lib/malloc.c, lib/mbswidth.c, lib/mbswidth.h, lib/memchr.c, | |
9452 | lib/memcmp.c, lib/memrchr.c, lib/obstack.c, lib/obstack.h, | |
9453 | lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, | |
9454 | lib/realloc.c, lib/stdbool_.h, lib/stpcpy.c, lib/strcasecmp.c, | |
9455 | lib/strchr.c, lib/strncasecmp.c, lib/strnlen.c, lib/strrchr.c, | |
9456 | lib/strspn.c, lib/strtol.c, lib/strtoul.c, lib/unlocked-io.h, | |
9457 | lib/xalloc.h, lib/xmalloc.c, lib/xstrdup.c, lib/xstrndup.c, | |
9458 | m4/Makefile.am, m4/alloca.m4, m4/dirname.m4, m4/dos.m4, | |
9459 | m4/error.m4, m4/getopt.m4, m4/hash.m4, m4/malloc.m4, | |
9460 | m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4, m4/memcmp.m4, | |
9461 | m4/memrchr.m4, m4/obstack.m4, m4/onceonly.m4, m4/prereq.m4, | |
9462 | m4/quote.m4, m4/quotearg.m4, m4/realloc.m4, m4/stdbool.m4, | |
9463 | m4/stpcpy.m4, m4/strnlen.m4, m4/strtol.m4, m4/strtoul.m4, | |
9464 | m4/unlocked-io.m4, m4/xalloc.m4, po/LINGUAS, po/Makefile.in.in, | |
9465 | po/Makevars, po/da.po, po/de.po, po/es.po, po/et.po, po/fr.po, | |
9466 | po/hr.po, po/id.po, po/it.po, po/ja.po, po/ms.po, po/nl.po, | |
9467 | po/pt_BR.po, po/ro.po, po/ru.po, po/sv.po, po/tr.po: | |
9468 | Remove, as these files are now generated automatically | |
9469 | by bootstrap or automake. | |
9470 | ||
9471 | * po/ChangeLog: Remove: all but one entry was a duplicate | |
9472 | of this file, and I moved that 2000-11-02 entry here. | |
9473 | ||
9474 | * config/.cvsignore: Add Makefile, depcomp, install-sh. | |
9475 | * lib/.cvsignore: Add alloca.c, alloca.h, alloca_.h, argmatch.c, | |
9476 | argmatch.h, basename.c, dirname.c, dirname.h, error.c, error.h, | |
9477 | exit.h, exitfail.c, exitfail.h, getopt.c, getopt.h, getopt1.c, | |
9478 | getopt_int.h, gettext.h, gnulib.mk, hard-locale.c, hard-locale.h, | |
9479 | hash.c, hash.h, malloc.c, mbswidth.c, mbswidth.h, memchr.c, | |
9480 | memcmp.c, memrchr.c, obstack.c, obstack.h, quote.c, quote.h, | |
9481 | quotearg.c, quotearg.h, realloc.c, stdbool_.h, stpcpy.c, stpcpy.h, | |
9482 | strcasecmp.c, strchr.c, stripslash.c, strncasecmp.c, strndup.c, | |
9483 | strnlen.c, strrchr.c, strspn.c, strtol.c, strtoul.c, | |
9484 | unlocked-io.h, xalloc.h, xmalloc.c, xstrdup.c, xstrndup.c, | |
9485 | xstrndup.h. | |
9486 | * m4/.cvsignore: Remove Makefile, Makefile.in. Add alloca.m4, | |
9487 | dirname.m4, dos.m4, error.m4, getopt.m4, hash.m4, mbrtowc.m4, | |
9488 | mbswidth.m4, obstack.m4, onceonly.m4, quote.m4, quotearg.m4, | |
9489 | stdbool.m4, stpcpy.m4, strnlen.m4, unlocked-io.m4, xalloc.m4. | |
9490 | * po/.cvsignore: Add *.po, LINGUAS, Makefile.in.in, Makevars. | |
9491 | * src/.cvsignore: Remove *_.c. | |
9492 | ||
9493 | ||
9494 | * Makefile.maint (GZIP_ENV): Don't use --rsyncable if gzip doesn't | |
9495 | support it. (The latest stable gzip doesn't.) | |
9496 | ||
9497 | 2004-04-27 Paul Eggert <eggert@twinsun.com> | |
9498 | ||
9499 | * data/lalr1.cc (Parser::stos_) [! YYDEBUG]: Define even in this | |
9500 | case, as stos_ is now used by destructors due to the 2004-02-09 | |
9501 | change. | |
9502 | ||
9503 | Remove more K&R C support. | |
9504 | * lib/libiberty.y (PARAMS): Remove. All uses removed. | |
9505 | * lib/subpipe.c (errno): Remove decl. | |
9506 | Include <stdlib.h> unconditionally. | |
9507 | (EXIT_FAILURE): Remove macro. | |
9508 | * src/complain.c (vfprintf, strerror): Remove. | |
9509 | * src/system.h: Include limits.h, stdlib.h, string.h, locale.h | |
9510 | unconditionally. | |
9511 | (EXIT_FAILURE, EXIT_SUCCESS, setlocale): Remove defns. | |
9512 | Use latest Autoconf recommendations for including inttypes.h, stdint.h. | |
9513 | (strchr, strspn, memchr): Remove decls. | |
9514 | * tests/calc.at (_AT_DATA_CALC_Y): Include stdlib.h, string.h | |
9515 | unconditionally. Do not declare perror. | |
9516 | * tests/conflicts.at (%nonassoc and eof): Include stdlib.h | |
9517 | unconditionally. | |
9518 | ||
9519 | * src/complain.c (_): Remove useless defn, as system.h defines this. | |
9520 | ||
9521 | * lib/bitset.h (__INT_TO_PTR): Remove; workaround no longer needed | |
9522 | with latest obstack.h. | |
9523 | * lib/ebitset.c (ebitset_elt_alloc): Don't bother to cast args | |
9524 | to procedure types, as obstack.h now does that for us. | |
9525 | * lib/lbitset.c (lbitset_elt_alloc): Likewise. | |
9526 | ||
9527 | * lib/subpipe.h [HAVE_SYS_TYPES_H]: Include <sys/types.h>, | |
9528 | so that this include file can stand alone. | |
9529 | * lib/subpipe.c: Do not include <sys/types.h>, as subpipe.h | |
9530 | does this now. Include subpipe.h first after config.h, to | |
9531 | test whether it can stand alone. | |
9532 | ||
9533 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Don't | |
9534 | declare yyerror when using lalr.cc, as GCC 3.4.0 warns about the | |
9535 | unused declaration. | |
9536 | ||
9537 | * tests/synclines.at (%union synch line): Put a dummy member in | |
9538 | the union, because empty unions aren't allowed in C. Caught | |
9539 | by GCC 3.4.0. | |
9540 | ||
4f16766c PE |
9541 | 2004-04-13 Jim Meyering <jim@meyering.net> |
9542 | ||
9543 | * src/conflicts.c (conflicts_print): Correct format string typo: | |
9544 | use `%%' to produce literal `%'. (trivial change) | |
9545 | ||
779e7ceb PE |
9546 | 2004-03-30 Paul Eggert <eggert@twinsun.com> |
9547 | ||
9548 | * src/getargs.c (version): Update copyright year to 2004. | |
9549 | ||
9550 | * data/c.m4 (b4_int_type): Use 'short int' rather than | |
9551 | 'short', and similarly for 'long', 'unsigned', etc. | |
9552 | * data/glr.c (YYTRANSLATE, yyconfl, yySymbol, yyItemNum, | |
9553 | yygetLRActions, yyprocessOneStack, yyrecoverSyntaxError, | |
9554 | yy_yypstack, yydumpstack): Likewise. | |
9555 | * data/lalr1.cc (user_token_number_max_, user_token_number_max_, | |
9556 | translate_, seq_, [], pop, Slice, range_, operator+, operator+=): | |
9557 | Likewise. | |
9558 | * data/yacc.c (b4_int_type, yyss, YYSTACK_BYTES, yysigned_char, | |
9559 | yy_stack_print, yyparse): Likewise. | |
9560 | * doc/bison.texinfo (Prologue, Multiple Types): Likewise. | |
9561 | * lib/bbitset.h (bitset_word, BITSET_WORD_BITS): Likewise. | |
9562 | * lib/bitset.c (bitset_print): Likewise. | |
9563 | * lib/bitset_stats.c (bitste_log_histogram_print): Likewise. | |
9564 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
9565 | * lib/bitsetv.c (bitsetv_dump): Likewise. | |
9566 | * lib/ebitset.c (EBITSET_ELT_BITS, ebitset_elt_alloc): Likewise. | |
9567 | * lib/lbitset.c (LBITSET_ELT_BITS, lbitset_elt_alloc, debug_lbitset): | |
9568 | Likewise. | |
9569 | * src/LR0.c (allocate_itemsets): Likewise. | |
9570 | * src/gram.h (rule_number, rule): Likewise. | |
9571 | * src/lalr.h (goto_number): Likewise. | |
9572 | * src/nullable.c (nullable_compute): Likewise. | |
9573 | * src/output.c (prepare_rules): Likewise. | |
9574 | * src/relation.c (relation_print, relation_digraph): Likewise. | |
9575 | * src/relation.h (relation_node): Likewise. | |
9576 | * src/state.h (state_number, transitions, errs, reductions, | |
9577 | struct state): Likewise. | |
9578 | * src/symtab.h (symbol_number, struct symbol): Likewise. | |
9579 | * src/tables.c (vector_number, tally, action_number, | |
9580 | default_goto, goto_actions): Likewise. | |
9581 | * tests/existing.at (GNU Cim Grammar): Likewise. | |
9582 | * tests/regression.at (Web2c Actions): Likewise. | |
9583 | ||
9584 | * src/output.c (muscle_insert_short_int_table): Renamed from | |
9585 | muscle_insert_short_table. All uses changed. | |
9586 | ||
d6328241 PH |
9587 | 2004-03-25 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
9588 | ||
9589 | * src/parse-gram.y: Define PERCENT_EXPECT_RR. | |
9590 | (declaration): Replace expected_conflicts with expected_sr_conflicts. | |
9591 | Add %expect-rr rule. | |
4f16766c | 9592 | |
d6328241 PH |
9593 | * src/scan-gram.l: Recognize %expect-rr. |
9594 | ||
4f16766c | 9595 | * src/conflicts.h (expected_sr_conflicts): Rename from |
d6328241 | 9596 | expected_conflicts. |
4f16766c | 9597 | (expected_rr_conflicts): Declare. |
d6328241 PH |
9598 | |
9599 | * src/conflicts.c (expected_sr_conflicts): Rename from | |
9600 | expected_conflicts. | |
9601 | (expected_rr_conflicts): Define. | |
9602 | (conflicts_print): Check r/r conflicts against expected_rr_conflicts | |
9603 | for GLR parsers. | |
9604 | Use expected_sr_conflicts in place of expected_conflicts. | |
9605 | Warn if expected_rr_conflicts used in non-GLR parser. | |
4f16766c | 9606 | |
d6328241 | 9607 | * doc/bison.texinfo: Add documentation for %expect-rr. |
4f16766c | 9608 | |
1452af69 PE |
9609 | 2004-03-08 Paul Eggert <eggert@gnu.org> |
9610 | ||
9611 | Add support for hex token numbers. Suggested by Odd Arild Olsen in | |
161a71f3 | 9612 | <http://lists.gnu.org/archive/html/bison-patches/2004-03/msg00000.html>. |
1452af69 PE |
9613 | |
9614 | * NEWS: Document hexadecimal tokens, no NUL bytes, %destructor | |
9615 | in lalr1.cc. | |
9616 | * doc/bison.texinfo (Token Decl): Add hexadecimal token numbers. | |
9617 | * src/scan-gram.l (scan_integer): New function. | |
9618 | ({int}): Use it. | |
9619 | (0[xX][0-9abcdefABCDEF]+): New pattern, to support hex numbers. | |
9620 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>, \\x[0-9abcdefABCDEF]+, | |
9621 | handle_action_dollar, handle_action_at, convert_ucn_to_byte): | |
9622 | Say "long int", not "long", for uniformity with GNU style. | |
9623 | ||
006d217d PE |
9624 | 2004-02-25 Paul Eggert <eggert@twinsun.com> |
9625 | ||
9626 | * tests/local.at (AT_COMPILE, AT_COMPILE_CXX): Ignore stdout from | |
9627 | compilers. This fixes a problem with Intel's C++ compiler being | |
9628 | chatty, reported by Guido Trentalancia in | |
161a71f3 | 9629 | <http://lists.gnu.org/archive/html/bug-bison/2004-02/msg00030.html>. |
006d217d | 9630 | |
c2729758 ADL |
9631 | 2004-02-09 Alexandre Duret-Lutz <adl@gnu.org> |
9632 | ||
9633 | Support %destructor and merge error locations in lalr1.cc. | |
9634 | ||
9635 | * data/lalr1.cc (b4_cxx_destruct_def): New macro. | |
9636 | (Parser::stos_): Define unconditionally. | |
9637 | (Parser::destruct_): New method. Generate its body with | |
9638 | b4_yydestruct_generate. | |
9639 | (Parser::error_start_): New attribute. | |
9640 | (Parser::parse) <yyerrlab, yyerrlab1>: Call destruct_ on erroneous | |
9641 | token which are discarded. | |
9642 | (Parser::parse) <yyerrlab, yyerrorlab, yyerrlab1>: Update | |
9643 | error_start_ when erroneous token are discarded. | |
9644 | (Parser::parse) <yyerrlab1>: Compute the location of the error | |
9645 | token so that it covers all the discarded tokens. | |
9646 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust so | |
9647 | it can be called with `%skeleton "lalr1.cc"', and do that. | |
9648 | ||
dd0e0635 PE |
9649 | 2004-02-02 Paul Eggert <eggert@twinsun.com> |
9650 | ||
9651 | * src/Makefile.am (AM_CPPFLAGS): New macro. It mentions | |
9652 | $(top_srcdir)/lib and ../lib. This fixes a bug reported | |
9653 | by Paul Hilfinger; the old INCLUDES value didn't mention ../lib. | |
9654 | There's no need to mention top_builddir since Automake does that | |
9655 | for us. | |
9656 | (INCLUDES): Remove, as Automake says it's obsolescent. | |
9657 | Contents migrated into AM_CPPFLAGS as described above. | |
9658 | * lib/Makefile.am (INCLUDES): Remove; obsolescent. | |
9659 | ||
9660 | 2004-01-14 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> | |
9661 | ||
9662 | * data/glr.c (yytokenName): Bullet-proof against YYEMPTY token. | |
9663 | (yyreportSyntaxError): Handle case where lookahead token is | |
9664 | YYEMPTY. | |
9665 | ||
be16239b PH |
9666 | 2004-01-13 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
9667 | ||
9668 | * data/glr.c: Put casts on uses of YYREALLOC and YYMALLOC so that | |
9669 | resulting parsers are compilable with C++. | |
9670 | ||
5fa90832 PE |
9671 | 2003-12-23 Paul Eggert <eggert@twinsun.com> |
9672 | ||
9673 | * config/depcomp, config/install-sh: Sync with Automake 1.8. | |
9674 | * src/output.c (output_skeleton): Rename local var. | |
9675 | * tests/input.at (Torturing the Scanner): Don't use \x0 or \0 in | |
9676 | Bison tokens, as this runs afoul of the 2003-10-07 change that | |
9677 | disallowed NUL bytes in character constants or string literals. | |
9678 | ||
9679 | * tests/local.at: Require Autoconf 2.59's Autotest. | |
9680 | * tests/testsuite.at: Don't include local.at, since we now assume | |
9681 | Autoconf 2.59 or later. Autoconf 2.59 had some problems with | |
9682 | including it. | |
9683 | * tests/Makefile.am ($(TESTSUITE)): Remove warning about ignoring | |
9684 | multiple inclusion warnings. | |
dd0e0635 | 9685 | |
b165c324 AD |
9686 | 2003-12-02 Akim Demaille <akim@epita.fr> |
9687 | ||
9688 | * doc/bison.texinfo (How Can I Reset the Parser): More about start | |
9689 | conditions. | |
9690 | From Bruno Haible. | |
9691 | ||
26e06a21 ADL |
9692 | 2003-11-18 Alexandre Duret-Lutz <adl@gnu.org> |
9693 | ||
9694 | * doc/bison.texinfo (Bison Options): Escape `@' in `$@'. | |
9695 | ||
92ac3705 PE |
9696 | 2003-10-07 Paul Eggert <eggert@twinsun.com> |
9697 | ||
6a5ecb38 PE |
9698 | * tests/Makefile.am (clean-local): Don't run 'testsuite --clean' |
9699 | if testsuite doesn't exist. | |
9700 | ||
92ac3705 PE |
9701 | * doc/bison.texinfo (Symbols): NUL bytes are not allowed in string |
9702 | literals, unfortunately. | |
9703 | * src/scan-gram.l (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>): | |
9704 | Complain about NUL bytes in character constants or string literals. | |
9705 | ||
91d2c560 PE |
9706 | 2003-10-05 Paul Eggert <eggert@twinsun.com> |
9707 | ||
9708 | * NEWS: Don't document %no-default-prec, as it's still | |
9709 | too experimental. | |
9710 | * doc/bison.texinfo: Document %no-default-prec only if | |
9711 | the defaultprec flag is set. Normally it's not. | |
9712 | ||
0cc3da3a PE |
9713 | 2003-10-04 Paul Eggert <eggert@twinsun.com> |
9714 | ||
9715 | * data/glr.c (b4_rhs_value, b4_rhs_location): Yield a | |
9716 | non-modifiable lvalue, instead of a modifiable one. | |
9717 | * doc/bison.texinfo (Actions): Document that $$ can | |
9718 | be assigned to. Do not claim that $$ and $N are | |
9719 | array element references: user code should not rely on this. | |
9720 | ||
22fccf95 PE |
9721 | 2003-10-01 Paul Eggert <eggert@twinsun.com> |
9722 | ||
9723 | * src/parse-gram.h (PERCENT_NO_DEFAULT_PREC): New token. | |
9724 | (grammar_declaration): Use it. | |
9725 | * src/scan-gram.l: New token %no-default-prec. | |
9726 | * tests/conflicts.at: Revamp tests to use %no-default-prec. | |
9727 | * NEWS, doc/bison.texinfo: Document the above. | |
9728 | ||
fc8f2965 AD |
9729 | 2003-10-01 Akim Demaille <akim@epita.fr> |
9730 | ||
9731 | VCG no longer supports long_straight_phase. | |
9732 | ||
9733 | * src/vcg.c, src/vcg.h: Remove the handling of long_straight_phase. | |
9734 | * src/print_graph.c (print_graph): Adjust. | |
9735 | ||
39a06c25 PE |
9736 | 2003-09-30 Frank Heckenbach <frank@g-n-u.de> |
9737 | and Paul Eggert <eggert@twinsun.com> | |
9738 | ||
9739 | * doc/bison.texinfo (Decl Summary, Contextual Precedence, | |
9740 | Table of Symbols): Document %default-prec. | |
9741 | * src/parse-gram.y (PERCENT_DEFAULT_PREC): New token. | |
9742 | (grammar_declaration): Set default_prec on %default-prec. | |
9743 | * src/scan-gram.l (%default-prec): New token. | |
9744 | * src/reader.h (default_prec): New flag. | |
9745 | * src/reader.c: Likewise. | |
9746 | (packgram): Handle it. | |
9747 | * tests/conflicts.at (%default-prec without %prec, | |
9748 | %default-prec with %prec, %default-prec 1): New tests. | |
fc8f2965 | 9749 | |
39a06c25 PE |
9750 | 2003-09-30 Paul Eggert <eggert@twinsun.com> |
9751 | ||
9752 | * tests/testsuite.at: Include local.at, not input.at, fixing | |
9753 | a typo in the 2003-08-25 patch. | |
9754 | ||
62b6aef9 AD |
9755 | 2003-08-27 Akim Demaille <akim@epita.fr> |
9756 | ||
9757 | * data/lalr1.cc (yyparse) [__GNUC__]: "Use" yyerrorlab to pacify | |
9758 | GCC warnings. | |
9759 | ||
89e1cc61 AD |
9760 | 2003-08-26 Akim Demaille <akim@epita.fr> |
9761 | ||
9762 | * config/announce-gen (print_changelog_deltas): Neutralize "<#" as | |
9763 | "<\#" to avoid magic from Gnus when posting parts of this script. | |
9764 | ||
a08460b0 AD |
9765 | 2003-08-26 Akim Demaille <akim@epita.fr> |
9766 | ||
9767 | * data/lalr1.cc (Parser::report_syntax_error_): New, extracted from | |
9768 | (Parser::parse): here. | |
9769 | Adjust: nerrs and errstatus is now replaced by... | |
9770 | (Parser::nerrs_, Parser::errstatus_): New. | |
9771 | ||
603f1cfd AD |
9772 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9773 | ||
9774 | * config/announce-gen, Makefile.cfg: New. | |
9775 | * Makefile.am: Adjust. | |
9776 | * GNUmakefile, Makefile.maint: Update from CVS Autoconf, but | |
9777 | keeping local WGET and WGETFLAGS modifications from Paul Eggert. | |
9778 | ||
cd3684cf AD |
9779 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9780 | ||
9781 | When reducing initial empty rules, Bison parser read an initial | |
9782 | location that is not defined. This results in garbage, and that | |
9783 | affects Bison's own parser. Therefore we need (i) to extend Bison | |
9784 | to support a means to initialize this location, and (ii) to use | |
9785 | this CVS Bison to fix CVS Bison's parser. | |
9786 | ||
9787 | * src/reader.h, reader.c (epilogue_augment): Remove, replace | |
9788 | with... | |
9789 | * src/muscle_tab.h, src/muscle_tab.c (muscle_code_grow): this. | |
9790 | * src/parse-gram.y: Adjust. | |
9791 | (%initial-action): New. | |
9792 | (%error-verbose): Since we require CVS Bison, there is no reason | |
9793 | not to use it. | |
9794 | * src/scan-gram.l: Adjust. | |
9795 | * src/Makefile.am (YACC): New, to make sure we use our own parser. | |
9796 | * data/yacc.c (yyparse): Use b4_initial_action. | |
9797 | ||
4e03e201 AD |
9798 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9799 | ||
9800 | * doc/bison.texinfo: Don't promote stdout for error messages. | |
9801 | ||
8c182d05 AD |
9802 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9803 | ||
9804 | * data/lalr1.cc (Parser::reduce_print_): Remove unused yyi. | |
9805 | From Alexandre Duret-Lutz. | |
9806 | ||
6a60c4cf PE |
9807 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9808 | ||
9809 | Version 1.875c. | |
9810 | ||
25f66e1a AD |
9811 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9812 | ||
9813 | * data/lalr1.cc (Parser::stack_print_, YY_STACK_PRINT): New. | |
9814 | Use them. | |
9815 | ||
5348bfbe AD |
9816 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9817 | ||
9818 | * data/lalr1.cc (Parser::reduce_print_): New. | |
9819 | Use it. | |
9820 | ||
47301314 AD |
9821 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9822 | ||
9823 | Have lalr1.cc catch with Paul Eggert's patch to fix the infinite | |
9824 | error recovery loops. This patch is based on | |
161a71f3 | 9825 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00000.html>. |
47301314 AD |
9826 | Also, augment the similarity between lalr1.cc and yacc.c. |
9827 | Note: the locations of error recovery rules are not correct yet. | |
9828 | ||
9829 | * data/lalr1.cc: Comment changes to augment the similarity between | |
9830 | lalr1.cc and yacc.c. | |
9831 | (YYERROR): Goto to yyerrorlab, not yyerrlab1. | |
9832 | (yyerrlab1): Remove, but where it used to be (now the bottom part of | |
9833 | yyerrlab), when hitting EOF, pop the whole stack here instead of | |
9834 | merely falling thru the default error handling mechanism. | |
9835 | (yyerrorlab): New label, with the old contents of YYERROR, | |
9836 | plus the following change: pop the stack of rhs corresponding | |
9837 | to the production that invoked YYERROR. That is how Yacc | |
9838 | behaves (required by POSIX). | |
9839 | * tests/calc.at (AT_CHECK_CALC_LALR1_CC): No longer expected to | |
9840 | fail. | |
9841 | ||
1f7a61ff AD |
9842 | 2003-08-25 Akim Demaille <akim@epita.fr> |
9843 | ||
9844 | Tune local.at so that people can "autom4te -l autotest calc.at -o | |
9845 | calc" for instance, to extract a sub test suite. | |
9846 | ||
9847 | * tests/testsuite.at: Move the initialization, Autotest version | |
9848 | requirement, and AT_TESTED invocation into... | |
9849 | * tests/local.at: here. | |
9850 | * tests/testsuite.at: Include it for compatibility with Autoconf | |
9851 | 2.57. | |
9852 | * tests/Makefile.am ($(TESTSUITE)): Report that the warning should | |
9853 | be ignore. | |
9854 | ||
327b5b56 PE |
9855 | 2003-08-04 Paul Eggert <eggert@twinsun.com> |
9856 | ||
9857 | Rework code slightly to avoid gcc -Wtraditional warnings. | |
9858 | * data/glr.c (yyuserMerge): Return void, not YYSTYPE. | |
9859 | The returned value is now stored in *YY0. All callers changed. | |
9860 | * src/output.c (merge_output): Adjust to the above change. | |
9861 | ||
0051e3ed PE |
9862 | 2003-07-26 Paul Eggert <eggert@twinsun.com> |
9863 | ||
9864 | * data/glr.c (YYASSERT): New macro. | |
9865 | (yyfillin, yydoAction, yyglrReduce, yysplitStack, | |
9866 | yyresolveStates, yyprocessOneStack): | |
9867 | Use `YYASSERT (FOO);' rather than `if (! (FOO)) abort ();'. | |
9868 | Derived from a suggestion by Frank Heckenbach. | |
1f7a61ff | 9869 | |
137437c6 PE |
9870 | 2003-07-25 Paul Eggert <eggert@twinsun.com> |
9871 | ||
5b620e06 PE |
9872 | * data/glr.c (yyglrReduce): Don't use C89 string concatenation, |
9873 | for portability to K&R C (after ansi2knr, presumably). See | |
161a71f3 | 9874 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00041.html> |
5b620e06 PE |
9875 | by Frank Heckenbach, though I have omitted the structure-initialization |
9876 | part of his glr-knr.diff patch since I recall that the Portable | |
9877 | C Compiler didn't require that change. | |
9878 | ||
137437c6 PE |
9879 | Let the user specify how to allocate and free memory. |
9880 | Derived from a suggestion by Frank Heckenbach in | |
161a71f3 | 9881 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00041.html>. |
137437c6 PE |
9882 | * data/glr.c (YYFREE, YYMALLOC, YYREALLOC): New macros. |
9883 | All uses of free, malloc, realloc changed to use these macros, | |
9884 | and unnecessary casts removed. | |
9885 | * data/yacc.c (YYFREE, YYMALLOC): Likewise. | |
9886 | ||
ddb85ca5 PE |
9887 | 2003-07-06 Matthias Mann <MatthiasMann@gmx.de> |
9888 | ||
9889 | * data/lalr1.cc (operator<<(std::ostream&, const Position&)): | |
9890 | use s.empty() rather than s == "" to test for empty string; see | |
161a71f3 | 9891 | <http://lists.gnu.org/archive/html/bison-patches/2003-07/msg00003.html> |
ddb85ca5 PE |
9892 | (trivial change) |
9893 | ||
39910e09 AD |
9894 | 2003-06-25 Akim Demaille <akim@epita.fr> |
9895 | ||
9896 | * config/depcomp, config/install-sh: Update from masters. | |
9897 | ||
0ae99356 PE |
9898 | 2003-06-20 Paul Eggert <eggert@twinsun.com> |
9899 | ||
9900 | * data/glr.c (YYLLOC_DEFAULT): Parenthesize arguments as needed, | |
9901 | and return properly parenthesized result. | |
9902 | * data/lalar1.cc (YYLLOC_DEFAULT): Likewise. | |
9903 | * data/yacc.c (YYLLOC_DEFAULT): Likewise. | |
9904 | Remove unnecessary parentheses from uses. | |
9905 | * doc/bison.texinfo (Location Default Action): Describe the | |
9906 | conventions for parentheses. | |
9907 | ||
cd05d13c PE |
9908 | 2003-06-19 Paul Eggert <eggert@twinsun.com> |
9909 | ||
81fd08ca PE |
9910 | * data/glr.c (yyremoveDeletes, yy_reduce_print, yyglrReduce, |
9911 | yyreportTree): Do not assume that size_t is the same width as int, | |
9912 | when printing sizes. Print sizes using an unsigned format. | |
9913 | Problem reported by Frank Heckenbach in | |
161a71f3 | 9914 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00035.html>. |
4dcf140b | 9915 | |
cd05d13c PE |
9916 | Port to Forte Developer 7 C compiler. |
9917 | * data/glr.c (struct YYLTYPE): If locations are not being used, | |
9918 | declare a single dummy member, as empty structs do not conform | |
9919 | to the C standard. | |
9920 | (YYERROR, YYBACKUP): Do not use "do { ...; return foo; } while (0)"; | |
9921 | the Forte Developer 7 C compiler complains that end-of-loop | |
9922 | code is not reached. | |
9923 | ||
4dcf140b PE |
9924 | 2003-06-17 Paul Eggert <eggert@twinsun.com> |
9925 | ||
9926 | * lib/libiberty.h (PARAMS): Spell argument as Args, not as X, to | |
9927 | avoid warnings from picky compilers about redefinition of PARAMS. | |
9928 | ||
8dd76bee PE |
9929 | 2003-06-17 Paul Eggert <eggert@twinsun.com> |
9930 | ||
9931 | Version 1.875b. | |
9932 | ||
9933 | * NEWS: Document 1.875b. | |
9934 | ||
9935 | * lib/bbitset.h: Do not include config.h; that's the includer's job. | |
9936 | Do not include <sys/types.h>; shouldn't be needed on a C89 host. | |
9937 | * lib/bitset.h (bitset_compatible_p): Indent as per GNU standard. | |
9938 | Don't use 'index' in comments, as it's a builtin fn on some hosts. | |
9939 | * lib/bitset_stats.c: Include gettext.h unconditionally, as | |
9940 | per recent gettext manual's suggestion. | |
9941 | * lib/ebitset.c (ebitset_resize, ebitset_unused_clear): | |
9942 | Use prototypes, not old-style definitions. | |
9943 | * lib/lbitset.c (lbitset_unused_clear): Likewise. | |
9944 | * lib/vbitset.c (vbitset_resize, vbitset_ones, vbitset_zero, | |
9945 | vbitset_empty_p, vbitset_copy1, vbitset_not, vbitset_equal_p, | |
9946 | vbitset_subset_p, vbitset_disjoint_p, vbitset_and, vbitset_and_cmp, | |
9947 | vbitset_andn, vbitset_andn_cmp, vbitset_or, vbitset_or_cmp, | |
9948 | vbitset_xor, vbitset_xor_cmp, vbitset_and_or, vbitset_and_or_cmp, | |
9949 | vbitset_andn_or, vbitset_andn_or_cmp, vbitset_or_and, | |
9950 | vbitset_or_and_cmp, vbitset_copy): Likewise. | |
9951 | ||
9952 | * lib/libiberty.h: Do not include config.h; that's the includer's job. | |
9953 | Do not include <stdlib.h>. | |
9954 | (PARAMS): Define unconditionally for C89. | |
9955 | (ATTRIBUTE_NORETURN): Remove. | |
9956 | (ATTRIBUTE_UNUSED): Define unconditionally. | |
9957 | ||
9958 | Upgrade to 2003-06-08 libbitset, submitted by Michael Hayes in: | |
161a71f3 | 9959 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00005.html> |
8dd76bee PE |
9960 | * lib/Makefile.am (bitsets_sources): Add vbitset.c, vbitset.h. |
9961 | * lib/vbitset.c, lib/vbitset.h: New files. | |
9962 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
9963 | lib/bitset_stats.c, lib/ebitset.c, lib/lbitset.c: Import | |
9964 | from libbitset. | |
9965 | ||
9966 | * doc/bison.texinfo (How Can I Reset the Parser): Renamed from | |
9967 | `How Can I Reset @code{yyparse}', since texinfo does not allow | |
9968 | arbitrary @ in node names. | |
9969 | ||
9970 | * m4/Makefile.am (EXTRA_DIST): Add the following files, which | |
9971 | shouldn't be needed according to the gettext 0.12.1 documentation | |
9972 | but which seem to be needed anyway: codeset.m4 glibc21.m4 | |
f8e8262e | 9973 | intdiv0.m4 inttypes-pri.m4 inttypes.m4 inttypes_h.m4 isc-posix.m4 |
8dd76bee | 9974 | lcmessage.m4 nls.m4 po.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4. |
f8e8262e | 9975 | * po/Makefile.in.in: Upgrade to gettext 0.12.1 version. |
cd05d13c | 9976 | |
8dd76bee PE |
9977 | * lib/.cvsignore: Add stdbool.h. |
9978 | * m4/.cvsignore: Add nls.m4, po.m4. | |
9979 | ||
9980 | Upgrade to CVS gnulib. | |
9981 | * stdbool_.h: File renamed from stdbool.h.in. | |
9982 | * configure.ac (AM_STDBOOL_H): Invoke this instead of | |
9983 | AC_HEADER_STDBOOL. | |
9984 | (AM_GNU_GETTEXT): Put brackets around args, as latest manual suggests. | |
9985 | (AM_GNU_GETTEXT_VERSION): Update to 0.12.1. | |
9986 | * lib/Makefile.am (EXTRA_DIST): Add stdbool_.h. | |
9987 | (MOSTLYCLEANFILES): New var. | |
9988 | ($(libbison_a_OBJECTS)): Depend on $(STDBOOL_H). | |
9989 | (stdbool.h): New rule. | |
9990 | * lib/dirname.c, lib/dirname.h, lib/hash.c, lib/hash.h, | |
9991 | lib/malloc.c, lib/obstack.h, lib/quote.c, lib/realloc.c, | |
9992 | lib/strcasecmp.c, lib/xalloc.h, m4/alloca.m4, m4/onceonly.m4, | |
9993 | m4/quote.m4: Upgrade to today's gnulib. | |
9994 | ||
9995 | * tests/calc.at (AT_CHECK_CALC): New option EXPECTED-TO-FAIL. | |
9996 | (AT_CHECK_CALC_LALR1_CC): Use it, since the C++ LALR parser fails | |
9997 | the tests right now. | |
9998 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Ensure yylex and | |
9999 | yyerror are declared before use; C99 requires this. | |
10000 | ||
25005f6a PH |
10001 | 2003-06-09 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
10002 | ||
10003 | * data/glr.c (YYERROR): Update definition to reset yyerrState to 0 | |
10004 | first. | |
10005 | (yyrecoverSyntaxError): Correct the logic for setting and testing | |
10006 | yyerrState. | |
10007 | Correct comment on handling EOF. | |
10008 | Allow states with only a default reduction, rather than failing | |
8dd76bee | 10009 | (I can't quite reconstruct why these were not allowed before). |
25005f6a | 10010 | |
137437c6 | 10011 | Fixes to avoid problem that $-N rules in GLR parsers can cause |
25005f6a | 10012 | buffer overruns, corrupting state. |
8dd76bee PE |
10013 | |
10014 | * src/output.c (prepare_rules): Output max_left_semantic_context | |
25005f6a PH |
10015 | definition. |
10016 | * src/reader.h (max_left_semantic_context): New variable declaration. | |
10017 | * src/scan-gram.l (max_left_semantic_context): Define. | |
10018 | (handle_action_dollar): Update max_left_semantic_context. | |
10019 | * data/glr.c (YYMAXLEFT): New definition. | |
10020 | (yydoAction): Increase size of yyrhsVals by YYMAXLEFT. | |
10021 | (yyresolveAction): Ditto. | |
10022 | ||
10023 | Fixes to problems with location handling in GLR parsers reported by | |
10024 | Frank Heckenbach (2003/06/05). | |
10025 | ||
10026 | * data/glr.c (YYLTYPE): Make trivial if locations not used. | |
10027 | (YYRHSLOC): Add parentheses, and define only if locations used. | |
10028 | (YYLLOC_DEFAULT): Add parentheses, and give trivial definition if | |
10029 | locations not used. | |
10030 | (yyuserAction): Use YYLLOC_DEFAULT to set *yylocp. | |
10031 | (yydoAction): Remove redundant initialization of *yyvalp and *yylocp. | |
8dd76bee | 10032 | |
25005f6a PH |
10033 | * tests/cxx-type.at: Exercise location information; update tests |
10034 | to differentiate output with and without locations. | |
8dd76bee | 10035 | Remove forward declarations of yylex and yyerror---caused errors |
25005f6a PH |
10036 | because default YYLTYPE not yet defined. |
10037 | Change semantic actions to compute strings, rather than printing | |
10038 | them directly (to test proper passing of semantics values). Change | |
10039 | output to prefix notation and update test data and expected results. | |
10040 | (yylex): Track locations. | |
10041 | (stmtMerge): Return value rather than printing, and include arguments | |
10042 | in value. | |
8dd76bee | 10043 | |
711f40b7 PE |
10044 | 2003-06-03 Paul Eggert <eggert@twinsun.com> |
10045 | ||
10046 | Avoid warnings generated by GCC 2.95.4 when Bison is | |
10047 | configured with --enable-gcc-warnings. | |
10048 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse, | |
10049 | yy::]b4_parser_class_name[::translate_, | |
10050 | yy::Stack::operator[] (unsigned), | |
10051 | yy::Stack::operator[] (unsigned) const, | |
10052 | yy::Slice::operator[] (unsigned), | |
10053 | yy::Slice::operator[] (unsigned) const): | |
10054 | Rename local vars to avoid warnings. | |
10055 | * tests/glr-regression.at (Improper handling of embedded actions | |
10056 | and $-N in GLR parsers): Remove unused local variable from yylex. | |
10057 | * tests/regression.at (_AT_DATA_DANCER_Y): Declare yylex to take | |
10058 | (void) as arg when not pure, since we now assume C89 when building | |
10059 | Bison. Pacify GCC by using parameter. | |
10060 | ||
ac695f7d PE |
10061 | 2003-06-02 Paul Eggert <eggert@twinsun.com> |
10062 | ||
10063 | * data/lalr1.cc (yy::Position::lines, yy::Position::columns, | |
10064 | yy::Location::lines, yy::Location::columns): Rename arguments | |
10065 | to avoid shadowing; this removes a warning generated by GCC 3.3. | |
10066 | ||
26ec81e0 PE |
10067 | 2003-06-01 Paul Eggert <eggert@twinsun.com> |
10068 | ||
10069 | Don't pass C-only warning optins (e.g., -Wmissing-declarations) | |
10070 | to g++, as GCC 3.3 complains if you do it. | |
10071 | * configure.ac (WARNING_CXXFLAGS): New subst. Set it to | |
10072 | everything that WARNING_CFLAGS has, except omit warnings | |
10073 | not suitable for C++. | |
10074 | (AC_PROG_CXX): Use this instead of AC_CHECK_PROGS([CXX], [g++]). | |
10075 | * tests/atlocal.in (CXXFLAGS): New var. | |
10076 | * tests/local.at (AT_COMPILE_CXX): Use it instead of CFLAGS. | |
10077 | ||
10078 | Fix a GLR parser bug I reported in February; see | |
161a71f3 | 10079 | <http://lists.gnu.org/archive/html/bison-patches/2003-02/msg00008.html>. |
26ec81e0 PE |
10080 | The problem was that GLR parsers did not conform to the C standard, |
10081 | because actions like { $1 = $2 + $3; } expanded to expressions | |
10082 | that invoked YYFILL in separate subexpressions, and YYFILL assigned | |
10083 | to a local variable. The C standard says that expressions | |
10084 | like (var = f ()) + (var = f ()) have undefined behavior. | |
10085 | Another problem was that GCC sometimes issues warnings that | |
10086 | yyfill and its parameters are unused. | |
10087 | ||
10088 | * data/glr.c (yyfillin): Renamed from the old yyfill. Mark | |
10089 | as possibly unused. | |
10090 | (yyfill): New function. | |
10091 | (YYFILL): Use it. | |
10092 | (yyuserAction): Change type of yynormal to bool, so that it matches | |
10093 | the new yyfill signature. Mark it as possibly unused. | |
10094 | ||
10095 | ||
10096 | Follow up on a bug I reported in February, where a Bison-generated | |
10097 | parser can loop. Provide a test case and a fix for yacc.c. I | |
10098 | don't have a fix for lalr1.cc or for glr.c, unfortunately. | |
10099 | The original bug report is in: | |
161a71f3 | 10100 | <http://lists.gnu.org/archive/html/bison-patches/2003-02/msg00044.html> |
26ec81e0 PE |
10101 | |
10102 | * data/yacc.c (YYERROR): Now just 'goto yyerrorlab', since the | |
10103 | macro's size was becoming unwieldy. | |
10104 | (yyerrlab): Do not discard an empty lookahead symbol, as this | |
10105 | might destroy garbage. | |
10106 | (yyerrorlab): New label, with the old contents of YYERROR, | |
10107 | plus the following change: pop the stack of rhs corresponding | |
10108 | to the production that invoked YYERROR. That is how Yacc | |
10109 | behaves, and POSIX requires this behavior. | |
10110 | (yyerrlab1): Use YYPOPSTACK instead of its definiens. | |
10111 | * tests/calc.at (_AT_DATA_CALC_Y): Include unistd.h if available. | |
10112 | Define 'alarm' to do nothing if unistd.h is not available. | |
10113 | Add a new rule "exp: '-' error;" to test the above change to | |
10114 | data/yacc.c. Use 'alarm' to abort any test taking longer than | |
10115 | 10 seconds, as it's probably looping. | |
10116 | (AT_CHECK_CALC): Test recovery from error in new grammar rule. | |
10117 | Also, the new yacc.c generates two fewer diagnostics for an | |
10118 | existing test. | |
10119 | ||
d0829076 PE |
10120 | 2003-05-24 Paul Eggert <eggert@twinsun.com> |
10121 | ||
c6ae27df PE |
10122 | * data/glr.c (YYSTACKEXPANDABLE): Do not evaluate |
10123 | YYSTYPE_IS_TRIVIAL or YYSTYPE_IS_TRIVIAL unless they are defined. | |
10124 | This fixes a problem reported by John Bowman when the Compaq/HP | |
10125 | Alpha cxx compiler happy (e.g. using cxx -D__USE_STD_IOSTREAM | |
10126 | -ansi -Wall -gall). | |
10127 | * data/yacc.c (union yyalloc): Likewise. | |
10128 | (YYCOPY): Do not evaluate __GNUC__ unless it is defined. | |
26ec81e0 | 10129 | |
d0829076 PE |
10130 | Switch from 'int' to 'bool' where that makes sense. |
10131 | ||
10132 | * lib/abitset.c (abitset_test, abitset_empty_p, abitset_equal_p, | |
10133 | abitset_subset_p, abitset_disjoint_p, abitset_and_cmp, | |
10134 | abitset_andn_cmp, abitset_or_cmp, abitset_xor_cmp, abitset_and_or, | |
10135 | abitset_and_or_cmp, abitset_andn_or_cmp, abitset_or_and_cmp): | |
10136 | Return or accept bool, not int. All callers changed. | |
10137 | * lib/bbitset.h: (bitset_toggle_, bitset_copy_, bitset_and_or_cmp_, | |
10138 | bitset_andn_or_cmp_, bitset_or_and_cmp_): Likewise. | |
10139 | * lib/bitset.c (bitset_only_set_p, bitset_print, bitset_toggle_, | |
10140 | bitset_copy_, bitset_op4_cmp, bitset_and_or_cmp_, bitset_andn_or_cmp_, | |
10141 | bitset_or_and_cmp_): Likewise. | |
10142 | * lib/bitset.h (bitset_test, bitset_only_set_p): Likewise. | |
10143 | * lib/bitset_stats.c (bitset_stats_print, bitset_stats_toggle, | |
10144 | bitset_stats_test, bitset_stats_empty_p, bitset_stats_disjoint_p, | |
10145 | bitset_stats_equal_p, bitset_stats_subset_p, bitset_stats_and_cmp, | |
10146 | bitset_stats_andn_cmp, bitset_stats_or_cmp, bitset_stats_xor_cmp, | |
10147 | bitset_stats_and_or_cmp, bitset_stats_andn_or_cmp, | |
10148 | bitset_stats_or_and_cmp): Likewise. | |
10149 | * lib/ebitset.c (ebitset_elt_zero_p, ebitset_equal_p, ebitset_copy_cmp, | |
10150 | ebitset_test, ebitset_empty_p, ebitset_subset_p, ebitset_disjoint_p, | |
10151 | ebitset_op3_cmp, ebitset_and_cmp, ebitset_andn_cmp, ebitset_or_cmp, | |
10152 | ebitset_xor_cmp): Likewise. | |
10153 | * lib/lbitset.c (lbitset_elt_zero_p, lbitset_equal_p, lbitset_copy_cmp, | |
10154 | lbitset_test, lbitset_empty_p, lbitset_subset_p, lbitset_disjoint_p, | |
10155 | lbitset_op3_cmp, lbitset_and_cmp, lbitset_andn_cmp, lbitset_or_cmp, | |
10156 | lbitset_xor_cmp): Likewise. | |
10157 | * lib/bbitset.h: Include <stdbool.h>. | |
10158 | (struct bitset_vtable): The following members now return bool, not | |
10159 | int: toggle, test, empty_p, disjoint_p, equal_p, subset_p, | |
10160 | and_cmp, andn_cmp, or_cmp, xor_cmp, and_or_cmp, andn_or_cmp, | |
10161 | or_and_cmp). | |
10162 | * src/conflicts.c (count_rr_conflicts): Likewise. | |
10163 | * lib/bitset_stats.h (bitset_stats_enabled): Now bool, not int. | |
10164 | All uses changed. | |
10165 | * lib/ebitset.c (ebitset_obstack_init): Likewise. | |
10166 | * lib/lbitset.c (lbitset_obstack_init): Likewise. | |
10167 | * src/getargs.c (debug_flag, defines_flag, locations_flag, | |
10168 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
10169 | graph_flag): Likewise. | |
10170 | * src/getargs.h (debug_flag, defines_flag, locations_flag, | |
10171 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
10172 | graph_flag): Likewise. | |
10173 | * src/output.c (error_verbose): Likewise. | |
10174 | * src/output.h (error_verbose): Likewise. | |
10175 | * src/reader.c (start_flag, typed): Likewise. | |
10176 | * src/reader.h (typed): Likewise. | |
10177 | * src/getargs.c (LOCATIONS_OPTION): New constant. | |
10178 | (long_options, getargs): Use it. | |
10179 | * src/lalr.c (build_relations): Use bool, not int. | |
10180 | * src/nullable.c (nullable_compute): Likewise. | |
10181 | * src/print.c (print_reductions): Likewise. | |
10182 | * src/tables.c (action_row, pack_vector): Likewise. | |
10183 | * src/muscle_tab.h (MUSCLE_INSERT_BOOL): New macro. | |
10184 | * src/output.c (prepare): Use it. | |
10185 | * src/output.c (token_definitions_output, | |
10186 | symbol_destructors_output, symbol_destructors_output): Use string, | |
10187 | not boolean integer, to keep track of whether to output separator. | |
10188 | * src/print_graph.c (print_core): Likewise. | |
10189 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
10190 | ||
10191 | * config/install-sh: Sync from automake 1.7.5. | |
10192 | ||
6b2584b7 PE |
10193 | 2003-05-14 Paul Eggert <eggert@twinsun.com> |
10194 | ||
10195 | * src/parse-gram.y (rules_or_grammar_declaration): Require a | |
10196 | semicolon after a grammar declaration, in the interest of possible | |
10197 | future changes to the Bison input language. | |
10198 | Do not allow a stray semicolon at the start of the grammar. | |
10199 | (rhses.1): Allow one or more semicolons after any rule, including | |
10200 | just before "|" as required by POSIX. | |
10201 | * tests/input.at (Torturing the Scanner): Add tests for ";|" in a | |
10202 | grammar. | |
10203 | ||
caf37a36 ADL |
10204 | 2003-05-14 Alexandre Duret-Lutz <adl@gnu.org> |
10205 | ||
10206 | %parse-param support for lalr1.cc. | |
10207 | ||
10208 | * data/lalr1.cc (b4_parse_param_decl, b4_parse_param_cons, | |
10209 | b4_cc_constructor_calls, b4_cc_constructor_call, | |
10210 | b4_parse_param_vars, b4_cc_var_decls, b4_cc_var_decl): New m4 | |
10211 | definitions. | |
10212 | (yy::b4_parser_class_name::b4_parser_class_name): Take extra | |
10213 | parse-param arguments. | |
10214 | (yy::b4_parser_class_name): Declare instance variables to | |
10215 | hold parse-param arguments. | |
10216 | * tests/calc.at: s/value/semantic_value/ because value clashes | |
10217 | with a member of yy::b4_parser_class_name. Adjust C++ code | |
10218 | to handle %parse-param. Enable %parse-param test in C++. | |
10219 | ||
3ab37077 PE |
10220 | 2003-05-12 Paul Eggert <eggert@twinsun.com> |
10221 | ||
10222 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): Reword the | |
10223 | English a bit. Fix fclose typo. Change "const char" to "char | |
10224 | const", and use ANSI C rather than K&R for "main". Suggest | |
10225 | YY_FLUSH_BUFFER over yyrestart (as that is what Flex recommends) | |
10226 | and suggest yy_switch_to_buffer. | |
10227 | ||
10228 | 2003-05-05 Paul Eggert <eggert@twinsun.com> | |
163ab321 PE |
10229 | |
10230 | * lib/bitset.h (__INT_TO_PTR): Define to a value that presumes | |
10231 | C89. This avoids a diagnostic on compilers that define __STDC__ | |
10232 | to 0, fixing a problem with Tru64 cc reported by Martin Mokrejs in | |
161a71f3 | 10233 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. |
163ab321 | 10234 | |
e743727f PE |
10235 | 2003-05-03 Paul Eggert <eggert@twinsun.com> |
10236 | ||
10237 | * lib/bitset.h (BITSET_FOR_EACH, BITSET_FOR_EACH_REVERSE): | |
10238 | Do not overrun array bounds. | |
10239 | This should fix a bug reported today by Olatunji Oluwabukunmi in | |
161a71f3 | 10240 | <http://lists.gnu.org/archive/html/bug-bison/2003-05/msg00004.html>. |
e743727f | 10241 | |
916708d5 AD |
10242 | 2003-04-29 Akim Demaille <akim@epita.fr> |
10243 | ||
10244 | * src/gram.h, src/gram.c (pure_parser, glr_parser): Move to... | |
10245 | * src/getargs.c, src/getargs.h: here, as bool, not int. | |
10246 | (nondeterministic_parser): New. | |
10247 | * src/parse-gram.y, src/scan-gram.l: Support | |
10248 | %nondeterministic-parser. | |
10249 | * src/output.c (prepare): Use nondeterministic_parser instead | |
10250 | of glr_parser where appropriate. | |
10251 | * src/tables.c (conflict_row, action_row, save_row) | |
10252 | (token_actions, token_actions, pack_vector): Ditto. | |
10253 | ||
a06ea4aa AD |
10254 | 2003-04-29 Akim Demaille <akim@epita.fr> |
10255 | ||
10256 | * doc/bison.texinfo (C++ Parsers, Implementing Loops): New. | |
10257 | ||
211074ca AD |
10258 | 2003-04-29 Akim Demaille <akim@epita.fr> |
10259 | ||
10260 | * tests/calc.at: Also test yacc.c and glr.c (but not lalr1.cc yet) | |
10261 | with %pure-parser and %locations to exercise the patch from Yakov | |
10262 | Markovitch below. | |
10263 | ||
6175ffe3 PE |
10264 | 2003-04-28 Tim Van Holder <tim.van.holder@pandora.be> |
10265 | ||
10266 | * data/yacc.c: (b4_lex_param): Corrected for the case where | |
10267 | %lex-param is provided and %pure-parser isn't. | |
10268 | ||
b1e95857 PE |
10269 | 2003-04-27 Paul Eggert <eggert@twinsun.com> |
10270 | ||
10271 | Avoid gcc -Wundef warnings reported by Gerald Pfeifer in | |
161a71f3 | 10272 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00044.html>. |
b1e95857 PE |
10273 | * data/yacc.c (YYSTACK_ALLOC): Don't evaluate YYSTACK_USE_ALLOCA |
10274 | if it is not defined. | |
10275 | (YYMAXDEPTH): Don't evaluate YYMAXDEPTH if it is not defined. | |
10276 | ||
acda9df6 PE |
10277 | 2003-04-26 Paul Eggert <eggert@twinsun.com> |
10278 | ||
3470c57b PE |
10279 | * data/lalr1.cc (yy::Parser::pact_ninf_, yy::Parser::table_ninf_): |
10280 | Declare to be of type suitable for the ninf value itself, not of | |
10281 | type suitable for the corresponding table, since the latter might | |
10282 | be unsigned but the ninf value might be negative. This fixes a | |
10283 | bug reported by Alexandre Duret-Lutz in | |
161a71f3 | 10284 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00017.html>. |
3470c57b | 10285 | |
acda9df6 PE |
10286 | * configure.ac (AC_FUNC_ERROR_AT_LINE): Remove, since gl_ERROR |
10287 | invokes it. We shouldn't invoke it twice because it will attempt | |
10288 | to put error.o in the archive twice. This fixes a glitch reported | |
10289 | by Martin Mokrejs in | |
161a71f3 | 10290 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. |
acda9df6 | 10291 | |
b5250f26 PE |
10292 | 2003-04-21 Paul Eggert <eggert@twinsun.com> |
10293 | ||
10294 | * m4/error.m4: Update from Bruno Haible's 2003-04-14 patch | |
10295 | to gnulib. | |
10296 | ||
089ac0f1 PE |
10297 | 2003-04-21 Yakov Markovitch <Markovitch@iso.ru> |
10298 | ||
10299 | * data/glr.c (yyexpandGLRStack) [!YYSTACKEXPANDABLE]: | |
10300 | Fix obvious typo that results in uncompilable GLR parsers | |
10301 | when both %pure-parser and %locations are used. (trivial change) | |
10302 | ||
5ededac6 PE |
10303 | 2003-04-17 Paul Eggert <eggert@twinsun.com> |
10304 | ||
1b8f2fff PE |
10305 | * src/scan-gram.l: Add %option nounput, since we no longer use unput. |
10306 | (unexpected_eof): Renamed from unexpected_end_of_file, for brevity. | |
10307 | Do not insert the expected token via unput, as this runs afoul | |
10308 | of a POSIX-compatibility bug in flex 2.5.31. | |
10309 | All uses changed to BEGIN the parent state, | |
10310 | since we no longer insert the expected token via unput. | |
10311 | * tests/regression.at (Invalid inputs): Remove cascaded diagnostic | |
10312 | that is no longer emitted after the above change. | |
10313 | ||
5ededac6 PE |
10314 | * src/conflicts.c (set_conflicts): Resolve all conflicts, not just |
10315 | the first one. This change is from Paul Hilfinger, and it fixes | |
10316 | regression reported by Werner Lemberg in | |
161a71f3 | 10317 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00026.html>. |
5ededac6 PE |
10318 | |
10319 | (resolve_sr_conflict): Don't invoke state_errs_set | |
10320 | unless one or more tokens have been explicitly made errors. | |
10321 | Otherwise, the above change causes Bison to abort. | |
10322 | ||
10323 | * tests/existing.at (GNU pic Grammar): New test case, taken from | |
10324 | Lemberg's email. | |
10325 | ||
b8be9132 AD |
10326 | 2003-03-31 Akim Demaille <akim@epita.fr> |
10327 | ||
10328 | * doc/Makefile.am (AM_MAKEINFOFLAGS): Don't split the info file. | |
10329 | ||
d423d460 AD |
10330 | 2003-03-31 Akim Demaille <akim@epita.fr> |
10331 | ||
10332 | * src/output.c (prepare_symbols): Avoid trailing spaces in the | |
10333 | output. | |
10334 | ||
c7e441b4 AD |
10335 | 2003-03-31 Akim Demaille <akim@epita.fr> |
10336 | ||
10337 | * doc/bison.texinfo (Strings are Destroyed): s/losses/loses/. | |
10338 | From Paul Hilfinger. | |
10339 | ||
231897ad AD |
10340 | 2003-03-29 Akim Demaille <akim@epita.fr> |
10341 | ||
10342 | * m4/error.m4: Do not put under dynamic conditions some code which | |
10343 | expansion is under static control. | |
10344 | ||
5b066063 AD |
10345 | 2003-03-29 Akim Demaille <akim@epita.fr> |
10346 | ||
10347 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): New. | |
10348 | ||
22a74fec AD |
10349 | 2003-03-29 Akim Demaille <akim@epita.fr> |
10350 | ||
10351 | * doc/bison.texinfo (Strings are Destroyed): New. | |
10352 | ||
0eee27e7 PE |
10353 | 2003-03-13 Paul Eggert <eggert@twinsun.com> |
10354 | ||
10355 | * .cvsignore: Add configure.lineno. | |
10356 | * src/.cvsignore: Add yacc. | |
10357 | * tests/.cvsignore: Add testsuite.log. | |
10358 | * doc/fdl.texi: Sync with latest FSF version. | |
10359 | ||
f61aad93 PE |
10360 | 2003-03-12 Paul Eggert <eggert@twinsun.com> |
10361 | ||
537636c7 PE |
10362 | * scan-gram.l (YY_USER_INIT): Initialize code_start, too. |
10363 | (<INITIAL><<EOF>>, <SC_PRE_CODE><<EOF>>): Set *loc to the scanner | |
10364 | cursor, instead of leaving it undefined. This fixes a bug | |
10365 | reported by Tim Van Holder in | |
161a71f3 | 10366 | <http://lists.gnu.org/archive/html/bug-bison/2003-03/msg00023.html>. |
537636c7 PE |
10367 | * tests/input.at (Torturing the Scanner): Test the scanner on |
10368 | an empty input file, which was Tim Van Holder's test case. | |
10369 | ||
10370 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): When checking whether | |
10371 | <sys/resource.h> can be included, include sys/time.h and | |
10372 | sys/times.h first, if available. This works around the SunOS | |
10373 | 4.1.4 porting bug reported by Bruce Becker in | |
161a71f3 | 10374 | <http://lists.gnu.org/archive/html/bug-bison/2003-03/msg00018.html>. |
537636c7 PE |
10375 | |
10376 | * m4/subpipe.m4 (BISON_PREREQ_SUBPIPE): Don't | |
10377 | AC_CHECK_HEADERS([sys/wait.h]), as this interferes with | |
10378 | AC_HEADER_SYS_WAIT. | |
10379 | ||
f61aad93 PE |
10380 | Merge changes from gnulib. This was prompted because the CVS |
10381 | snapshot didn't build on Solaris 7 due to strnlen problems. | |
10382 | ||
10383 | These changes need to be merged back into gnulib: | |
10384 | * lib/hash.c: Include <stdbool.h> unconditionally. | |
10385 | * m4/onceonly.m4 (m4_quote): New macro. | |
10386 | (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE): | |
10387 | Quote AC_FOREACH variable-expansions properly. | |
10388 | The 2003-01-03 obstack.h change also needs merging. | |
10389 | {end of changes requiring merging} | |
5b066063 | 10390 | |
f61aad93 PE |
10391 | * lib/stdbool.h.in, m4/alloca.m4, m4/dirname.m4, m4/dos.m4, |
10392 | m4/getopt.m4, m4/hash.m4, m4/malloc.m4, m4/memchr.m4, | |
10393 | m4/memrchr.m4, m4/obstack.m4, m4/onceonly.m4, m4/quote.m4, | |
10394 | m4/quotearg.m4, m4/realloc.m4, m4/stpcpy.m4, m4/strnlen.m4, | |
10395 | m4/strtol.m4, m4/strtoul.m4, m4/unlocked-io.m4, m4/xalloc.m4: | |
10396 | New files, imported from gnulib. | |
10397 | * m4/Makefile.am (EXTRA_DIST): Add the new m4/*.m4 files mentioned | |
10398 | above. | |
10399 | ||
10400 | * lib/mbswidth.c, m4/error.m4, m4/mbrtowc.m4, m4/mbswidth.m4, | |
10401 | m4/memcmp.m4, m4/prereq.m4, m4/stdbool.m4: Update to current | |
10402 | gnulib sources. | |
10403 | ||
10404 | * configure.ac (gl_DIRNAME, gl_GETOPT, gl_HASH, gl_QUOTE, gl_XALLOC): | |
10405 | Add. | |
10406 | (gl_ERROR): New, replacing jm_PREREQ_ERROR. | |
10407 | (gl_FUNC_ALLOCA): New, replacing AC_FUNC_ALLOCA. | |
10408 | (gl_FUNC_STPCPY): New, replacing AC_REPLACE_FUNCS(stpcpy). | |
10409 | (gl_FUNC_STRNLEN): New, replacing AC_FUNC_STRNLEN. | |
10410 | (gl_MBSWIDTH): New, replacing jm_PREREQ_MBSWIDTH. | |
10411 | (gl_OBSTACK): New, replacing AC_FUNC_OBSTACK. | |
10412 | (gl_QUOTEARG): New, replacing jm_PREREQ_QUOTEARG. | |
10413 | (jm_FUNC_GLIBC_UNLOCKED_IO, gl_FUNC_STPCPY, gl_FUNC_STRTOL): New. | |
10414 | (jm_FUNC_MALLOC): New, replacing AC_FUNC_MALLOC. | |
10415 | (jm_FUNC_REALLOC): New, replacing AC_FUNC_REALLOC. | |
10416 | (jm_PREREQ_ARGMATCH): Remove. | |
10417 | (AC_REPLACE_FUNCS): Remove memchr, memrchr, stpcpy, strtol, strtoul. | |
10418 | * lib/Makefile.am (libbison_a_SOURCES): Add argmatch.c, argmatch.h. | |
10419 | ||
10420 | * src/system.h: Include <stdbool.h> unconditionally. | |
10421 | ||
10422 | * lib/bbitset.h: Include <limits.h> unconditionally. We have been | |
10423 | assuming at least C89 in the bitset code for some time now. | |
10424 | ||
d2ffe116 AD |
10425 | 2003-03-03 Akim Demaille <akim@epita.fr> |
10426 | ||
10427 | * ro.po: New. | |
10428 | ||
052826fd AD |
10429 | 2003-03-02 Akim Demaille <akim@epita.fr> |
10430 | ||
10431 | * doc/bison.texinfo (Table of Symbols): Reactivate the | |
10432 | documentation for %lex-param, and %parse-param. | |
10433 | ||
c4749565 AD |
10434 | 2003-03-02 Akim Demaille <akim@epita.fr> |
10435 | ||
10436 | * data/yacc.c, data/glr.c, data/lal1.cc: Use similar code to | |
10437 | generate verbose error messages. | |
10438 | Use the number of tokens as an upper bound in yytname, as it | |
10439 | cannot be a non terminal. | |
10440 | ||
d5286af1 AD |
10441 | 2003-03-02 Akim Demaille <akim@epita.fr> |
10442 | ||
10443 | * tests/regression.at (_AT_DATA_DANCER_Y): Fix the expected error | |
10444 | message. | |
10445 | ||
22e304a6 AD |
10446 | 2003-03-02 Akim Demaille <akim@epita.fr> |
10447 | ||
22e304a6 AD |
10448 | * tests/regression.at (_AT_DATA_DANCER_Y, AT_CHECK_DANCER): New. |
10449 | Use them to exercise yycheck overrun. | |
10450 | Based on Andrew Suffield's grammar. | |
10451 | ||
67a25fed AD |
10452 | 2003-03-02 Akim Demaille <akim@epita.fr> |
10453 | ||
10454 | Create tests/local.at for Bison generic testing macros. | |
10455 | ||
10456 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Move to... | |
10457 | * tests/local.at (AT_BISON_OPTION_PUSHDEFS, AT_BISON_OPTION_POPDEFS): | |
10458 | This new file. | |
10459 | * tests/calc.at (AT_CHECK_CALC): Adjust. | |
10460 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR) | |
10461 | (AT_COMPILE, AT_COMPILE_CXX, AT_PARSER_CHECK): Move to... | |
10462 | * tests/local.at: here. | |
10463 | (AT_COMPILE_CXX): Tags the tests using it as c++. | |
10464 | Ignore the test if CXX is not functional. | |
10465 | ||
9c2b381f PE |
10466 | 2003-03-01 Paul Eggert <eggert@twinsun.com> |
10467 | ||
10468 | * src/scan-gram.l (code_start): Initialize it to scanner_cursor, | |
10469 | not loc->end, since loc->end might contain garbage and this leads | |
10470 | to undefined behavior on some platforms. | |
10471 | (id_loc, token_start): Use (IF_LINTed) initial values that do not | |
10472 | depend on *loc, so that the reader doesn't give the the false | |
10473 | impression that *loc is initialized. | |
10474 | (<INITIAL>"%%"): Do not bother setting code_start, since its value | |
10475 | does not survive the return. | |
10476 | ||
0433ba88 AD |
10477 | 2003-03-01 Akim Demaille <akim@epita.fr> |
10478 | ||
10479 | * src/scan-gram.l (code_start): Always initialize it when entering | |
10480 | into yylex, as SC_EPILOGUE is activated *before* the corresponding | |
10481 | yylex invocation. An alternative would be making it static, but | |
10482 | then it starts with the second %%'s beginning, instead of its end. | |
10483 | ||
b305ea69 PE |
10484 | 2003-02-28 Paul Eggert <eggert@twinsun.com> |
10485 | ||
10486 | * lib/mbswidth.c: Include <wchar.h> before "mbswidth.h", to work | |
10487 | around a UnixWare 7.1.1 porting bug reported by John Hughes in | |
161a71f3 | 10488 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00030.html>. |
b305ea69 | 10489 | |
c3d25e01 PE |
10490 | 2003-02-26 Paul Eggert <eggert@twinsun.com> |
10491 | ||
10492 | * README: Mention compiler bug in Sun Forte Developer 6 update 2. | |
10493 | Remove Sequent/Pyramid discussion (nobody uses them any more). | |
10494 | Merge VMS and MS-DOS discussion; these ports may well be dead | |
10495 | but let's keep mentioning them for now. Put <> around email | |
10496 | addresses. Add copyright notice. | |
10497 | ||
c267ffbc PE |
10498 | 2003-02-24 Paul Eggert <eggert@twinsun.com> |
10499 | ||
10500 | * data/glr.c (yy_reduce_print): yylineno -> yylno, | |
10501 | to avoid collision with flex use of yylineno. | |
10502 | Problem reported by Bruce Lilly in | |
161a71f3 | 10503 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00016.html>. |
c267ffbc PE |
10504 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Likewise. |
10505 | * data/yacc.c (yy_reduce_print): Likewise. | |
10506 | ||
10507 | * config/depcomp: Sync with Automake 1.7.3. | |
10508 | ||
f939fc12 AD |
10509 | 2003-02-21 Akim Demaille <akim@epita.fr> |
10510 | ||
10511 | * data/lalr1.cc: Use temporary variables instead of casts to | |
10512 | change integer types. | |
10513 | Suggested by Paul Eggert. | |
10514 | ||
95923bd6 AD |
10515 | 2003-02-21 Akim Demaille <akim@epita.fr> |
10516 | ||
10517 | * doc/bison.texinfo: Use "location" consistently to refer to @n, | |
10518 | to avoid confusions with lalr1.cc's notion of Position. | |
10519 | Suggested by Paul Eggert. | |
10520 | ||
2cdc240e AD |
10521 | 2003-02-20 Akim Demaille <akim@epita.fr> |
10522 | ||
10523 | * data/lalr1.cc (position.hh): Make sure "columns" never pushes | |
10524 | before initial_columns. | |
10525 | (location.hh): Use consistent variable names when defining the | |
10526 | operator<<. | |
10527 | Use "last" so that we subtract from Positions, not from unsigned. | |
10528 | ||
5d003116 AD |
10529 | 2003-02-20 Akim Demaille <akim@epita.fr> |
10530 | ||
10531 | * data/lalr1.cc (position.hh): New subfile, including the extended | |
10532 | and Doxygen'ed documentation of class Position. | |
10533 | (location.hh): Use it. | |
10534 | Document a` la Doxygen. | |
ba1ecc07 | 10535 | With the help of Benoit Perrot. |
5d003116 | 10536 | |
d02b25f9 AD |
10537 | 2003-02-20 Akim Demaille <akim@epita.fr> |
10538 | ||
10539 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Define | |
10540 | AT_YACC_IF. | |
10541 | Redefine AT_YYERROR_SEES_LOC_IF using it. | |
10542 | (_AT_DATA_CALC_Y): Don't declare yyerror when lalr1.cc, as it is | |
10543 | not defined. | |
10544 | Don't use the location in yy::Parser::error_ and | |
10545 | yy::Parser::print_ when not %locations. | |
10546 | Activate more lalr1.cc tests. | |
10547 | ||
0d1c3a04 AD |
10548 | 2003-02-19 Akim Demaille <akim@epita.fr> |
10549 | ||
10550 | * data/lalr1.cc: When displaying a line number, be sure to make it | |
10551 | an int. | |
10552 | ||
60a777aa AD |
10553 | 2003-02-19 Akim Demaille <akim@epita.fr> |
10554 | ||
10555 | * data/lalr1.cc (b4_stack_depth_init, yy::Parser::initdepth_): | |
10556 | Remove, useless. | |
10557 | (YYABORT, YYACCEPT, YYERROR): New. | |
10558 | * tests/calc.at: Renable the lalr1.cc test. | |
10559 | ||
0b86fc41 AD |
10560 | 2003-02-19 Akim Demaille <akim@epita.fr> |
10561 | ||
10562 | * tests/calc.at (AT_CHECK_CALC): Check different scenarios of | |
10563 | error recovery, mixing with/without pops and discarding of the | |
10564 | lookahead. | |
10565 | Exercise YYERROR. | |
10566 | Disable the lalr1.cc tests as currently it doesn't support YYERROR. | |
10567 | ||
da99a5dc PE |
10568 | 2003-02-17 Paul Eggert <eggert@twinsun.com> |
10569 | ||
10570 | * tests/atlocal.in (LDFLAGS, LIBS): New vars. | |
10571 | * tests/testsuite.at (AT_COMPILE): Use them. | |
10572 | This fixes the testsuite problem reported by Robert Lentz in | |
161a71f3 | 10573 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00011.html>. |
da99a5dc | 10574 | |
93b8c255 PE |
10575 | 2003-02-12 Paul Eggert <eggert@twinsun.com> |
10576 | ||
10577 | * data/yacc.c (yyerrlab) [YYERROR_VERBOSE]: | |
10578 | Avoid subscript error in yycheck. Bug reported by Andrew Suffield in | |
161a71f3 | 10579 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00003.html>. |
93b8c255 PE |
10580 | * data/glr.c (yyreportSyntaxError) [YYERROR_VERBOSE]: Likewise. |
10581 | Check for malloc failure, for consistency with yacc.c. | |
10582 | (yytname_size): Remove, for consistency with yacc.c. | |
10583 | ||
10584 | The bug still remains in data/lalr1.cc, as I didn't have time | |
10585 | to fix it there. | |
10586 | ||
7548fed2 AD |
10587 | 2003-02-06 Akim Demaille <akim@epita.fr> |
10588 | ||
10589 | * configure.ac (GXX): Rename as... | |
10590 | (CXX): this, to keep the original Autoconf semantics. | |
10591 | Require 2.57. | |
10592 | * data/lalr1.cc: Fix b4_copyright invocations. | |
10593 | If YYDEBUG is not defined, don't depend upon name_ being defined. | |
10594 | (location.hh): Include string and iostream. | |
10595 | (Position::filename): New member. | |
10596 | (Position::Position ()): New. | |
10597 | (operator<< (Position)): New. | |
10598 | (operator- (Position, int)): New. | |
10599 | (Location::first, Location::last): Rename as... | |
10600 | (Location::begin, Location::end): these, to mock the conventional | |
10601 | iterator names. | |
10602 | (operator<< (Location)): New. | |
10603 | * tests/atlocal.in (CXX): New. | |
10604 | * tests/testsuite.at (AT_COMPILE_CXX): New. | |
10605 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust yyerror to report the | |
10606 | locations in a more synthetic way. | |
10607 | (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF is positive if | |
10608 | lalr1.cc is used. | |
10609 | Adjust the C locations to match those from Emacs: first column is | |
10610 | column 0. | |
10611 | Change all the expected results. | |
10612 | Conform to the GCS: simplify the locations when applicable. | |
10613 | (LOC, VAL, YYLLOC_FORMAL, YYLLOC_ARG, USE_YYLLOC, LEX_FORMALS) | |
10614 | (LEX_ARGS, USE_LEX_ARGS, LEX_PRE_FORMALS, LEX_PRE_ARGS): Replace | |
10615 | these CPP macros with the m4 macros new defined by... | |
10616 | (AT_CHECK_PUSHDEFS): this, i.e.: | |
10617 | (AT_LALR1_CC_IF, AT_PURE_LEX_IF, AT_LOC, AT_VAL, AT_LEX_FORMALS) | |
d02b25f9 | 10618 | (AT_LEX_ARGS, AT_USE_LEX_ARGS, AT_LEX_PRE_FORMALS, AT_LEX_PRE_ARGS) |
7548fed2 AD |
10619 | New macros. |
10620 | (AT_CHECK_POPDEFS): Undefine them. | |
10621 | (AT_CHECK_CALC_LALR1_CC): New. | |
10622 | Use it for the first lalr1.cc test. | |
10623 | ||
43a176ef AD |
10624 | 2003-02-04 Akim Demaille <akim@epita.fr> |
10625 | ||
10626 | * data/lalr1.cc (YYLLOC_DEFAULT): Fix its definition: be based on | |
10627 | Location as is defined. | |
10628 | ||
fc049e9c AD |
10629 | 2003-02-04 Akim Demaille <akim@epita.fr> |
10630 | ||
10631 | * data/lalr1.cc: If YYDEBUG is not defined, don't depend upon | |
10632 | name_ being defined. | |
10633 | ||
a737b216 PE |
10634 | 2003-02-03 Paul Eggert <eggert@twinsun.com> |
10635 | ||
10636 | * src/gram.h (start_symbol): Remove unused decl. | |
10637 | ||
10638 | Use more-consistent naming conventions for local vars. | |
10639 | ||
10640 | * src/derives.c (derives_compute): Change type of local var from | |
10641 | int to rule_number. | |
10642 | * src/gram.c (grammar_rules_partial_print): Likewise. | |
10643 | * src/print.c (print_core): Likewise. | |
10644 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
10645 | ||
10646 | * src/gram.c (grammar_dump): Change name of item_number * | |
10647 | local var from r to rp. | |
10648 | * src/nullable.c (nullable_compute): Likewise. | |
10649 | ||
10650 | * src/gram.h (ISTOKEN, ISVAR): Use i, not s, for int var. | |
10651 | ||
10652 | * src/gram.h (symbol_number_as_item_number): Use sym, not s, | |
10653 | for symbol or symbol_number var. | |
10654 | * src/reader.c (grammar_start_symbol_set): Likewise. | |
10655 | * src/reader.h (grammar_start_symbol_set, grammar_symbol_append): | |
10656 | Likewise. | |
10657 | * src/state.c (transitions_to): Likewise. | |
10658 | * src/state.h: Likewise. | |
10659 | * src/tables.c (symbol_number_to_vector_number): Likewise. | |
10660 | ||
10661 | * src/muscle_tab.h (MUSCLE_OBSTACK_SGROW): Use p, not s, for | |
10662 | char * var. | |
10663 | ||
10664 | * src/parse-gram.y (lloc_default): Use loc, not r, for YYLTYPE | |
10665 | var. | |
10666 | ||
10667 | * src/scan-gram.l (no_cr_read): Use bytes_read, not s, for size | |
10668 | var. | |
10669 | ||
10670 | * src/system.h (xstrndup, strchr, strspn, strnlen, memchr, memrchr): | |
10671 | Use str, not s, for char * var. Use ch, not c, for character var. | |
10672 | Use size for size var. | |
10673 | ||
10674 | * src/uniqstr.c (uniqstr_new, uniqstr_assert): Use str, not s, for | |
10675 | char * var. | |
10676 | (uniqstr_print, uniqst_print_processor): Use ustr, not s, for | |
10677 | uniqstr var. | |
10678 | * src/uniqstr.h: Likewise. | |
10679 | ||
10680 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
10681 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
10682 | get_node_alignment_str, get_arrow_mode_str, get_crossing_type_str, | |
10683 | get_view_str, get_linestyle_str, get_arrowstyle_str): Rename | |
10684 | param to have same name as that of enum, so that we don't use | |
10685 | "s" to stand for a non-state. | |
10686 | ||
68e93ad5 AD |
10687 | 2003-02-02 Akim Demaille <akim@epita.fr> |
10688 | ||
10689 | * src/scan-skel.l: Scan more than one inert character per yylex | |
10690 | invocation. | |
10691 | ||
92898986 PE |
10692 | 2003-02-01 Paul Eggert <eggert@twinsun.com> |
10693 | ||
10694 | Version 1.875a. | |
10695 | ||
1d9d5d71 PE |
10696 | * po/LINGUAS: Add ms. |
10697 | ||
0435d061 AD |
10698 | 2003-01-30 Akim Demaille <akim@epita.fr> |
10699 | ||
10700 | * doc/Makefile.am (CLEANFILES): Add bison.fns for distcheck. | |
10701 | ||
6029a57f PH |
10702 | 2003-01-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
10703 | ||
10704 | * tests/cxx-type.at: Correct apparent typo in Bison input: $$ instead | |
10705 | of $1. | |
0435d061 AD |
10706 | |
10707 | Changes in response to error report by S. Eken: GLR mode does not | |
6029a57f | 10708 | handle negative $ indices or $ indices in embedded rules correctly. |
161a71f3 | 10709 | See <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00076.html>. |
0435d061 | 10710 | |
6029a57f PH |
10711 | * data/glr.c (b4_rhs_value): Change to use YYFILL macro. |
10712 | (b4_rhs_location): Ditto. | |
0435d061 | 10713 | (yyfill): New function to copy from stack tree into array |
6029a57f | 10714 | incrementally. |
0435d061 AD |
10715 | (yyuserAction): Modify to allow incremental move of semantic values |
10716 | to rhs array when in GLR mode. | |
10717 | Define YYFILL to use in user-defined actions to fill semantic array | |
6029a57f PH |
10718 | as needed. |
10719 | Remove dummy use of yystack, as there is now a guaranteed use. | |
10720 | (yydoAction): Modify to allow incremental move of semantic values | |
10721 | to rhs array when in GLR mode. | |
10722 | (yyresolveAction): Ditto. | |
10723 | (yyglrShiftDefer): Update comment. | |
0435d061 | 10724 | (yyresolveStates): Use X == NULL for pointers, not !X. |
6029a57f PH |
10725 | (yyglrReduce): Ditto. |
10726 | (yydoAction): Ditto | |
0435d061 | 10727 | |
6029a57f PH |
10728 | * tests/glr-regr1.at: Rename to ... |
10729 | * tests/glr-regression.at: Add new regression test for the problems | |
10730 | described above (adapted from S. Eken). | |
10731 | Update copyright notice. | |
10732 | * tests/testsuite.at: Rename glr-regr1.at to glr-regression.at. | |
10733 | * tests/Makefile.am: Ditto. | |
10734 | ||
6cee6297 PE |
10735 | 2003-01-28 Paul Eggert <eggert@twinsun.com> |
10736 | ||
10737 | * data/lalr1.cc: Do not use @output_header_name@ unless | |
10738 | b4_defines_flag is set. This fixes two bugs reported by | |
10739 | Tim Van Holder in | |
161a71f3 PE |
10740 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00071.html> |
10741 | and <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00073.html>. | |
6cee6297 | 10742 | |
b2a836b5 PE |
10743 | 2003-01-21 Paul Eggert <eggert@twinsun.com> |
10744 | ||
10745 | * data/yacc.c (YYERROR): Move code from yyerrlab1 to here, so that | |
10746 | we don't need to worry about yyerrlab1 being reported as an | |
10747 | "unused label" by non-GCC C compilers. The downside is that if | |
10748 | locations are used then a couple of statements are duplicated each | |
10749 | time YYERROR is invoked, but the upside is that the warnings | |
10750 | should vanish. | |
10751 | (yyerrlab1): Move code to YERROR. | |
10752 | (yyerrlab2): Remove. Change uses back to yyerrlab1. | |
10753 | This reverts some of the 2002-12-27 change. | |
10754 | ||
4196b931 PE |
10755 | 2003-01-17 Paul Eggert <eggert@twinsun.com> |
10756 | ||
10757 | * src/output.c (symbol_printers_output): Fix typo that led | |
10758 | to core dump. Problem reported by Antonio Rus in | |
161a71f3 | 10759 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00058.html>. |
4196b931 | 10760 | |
3ae831b4 AD |
10761 | 2003-01-13 Akim Demaille <akim@epita.fr>, |
10762 | Quoc Peyrot <chojin@lrde.epita.fr>, | |
10763 | Robert Anisko <anisko_r@lrde.epita.fr> | |
10764 | ||
10765 | * data/lalr1.cc (parse::yyerrlab1): When popping the stack, stop | |
10766 | when the stacks contain one element, as the loop would otherwise | |
10767 | free the last state, and then use the top state (the one we just | |
10768 | popped). This means that the initial elements will not be freed | |
10769 | explicitly, as is the case in yacc.c; it is not a problem, as | |
10770 | these elements have fake values. | |
10771 | ||
e3aa65c5 PE |
10772 | 2003-01-11 Paul Eggert <eggert@twinsun.com> |
10773 | ||
10774 | * NEWS: %expect-violations are now just warnings, reverting | |
10775 | to Bison 1.30 and 1.75 behavior. This fixes the GCC 3.2 | |
10776 | bootstrapping problem reported by Matthias Klose; see | |
161a71f3 | 10777 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00053.html>. |
e3aa65c5 PE |
10778 | * src/conflicts.c (conflicts_print): Likewise. |
10779 | * tests/conflicts.at (%expect not enough, %expect too much, | |
10780 | %expect with reduce conflicts): Likewise. | |
10781 | * doc/bison.texinfo (Expect Decl): Document this. Also mention | |
10782 | that the warning is enabled if the number of conflicts changes | |
10783 | (not necessarily increases). | |
10784 | ||
10785 | * src/getargs.c (version): Update copyright year. | |
10786 | ||
f0057011 AD |
10787 | 2003-01-09 Akim Demaille <akim@epita.fr> |
10788 | ||
10789 | * src/Makefile.am, lib/Makefile.am: Use $(VAR) instead of @VAR@. | |
10790 | ||
1ee6d2a0 PE |
10791 | 2003-01-08 Paul Eggert <eggert@twinsun.com> |
10792 | ||
10793 | * Makefile.maint (WGETFLAGS): | |
10794 | New macro, containing "-C off" to disable proxy caches. | |
10795 | All uses of $(WGET) changed to $(WGET) $(WGETFLAGS). | |
10796 | (rel-check): Use $(WGET) instead of wget. | |
10797 | ||
d4fd77c4 PE |
10798 | 2003-01-06 Paul Eggert <eggert@twinsun.com> |
10799 | ||
10800 | * doc/bison.texinfo (Generalized LR Parsing): Add a reference to | |
10801 | the GLR paper of Scott, Johnstone and Hussain. | |
10802 | ||
464c6927 PE |
10803 | 2003-01-04 Paul Eggert <eggert@twinsun.com> |
10804 | ||
d600ee67 PE |
10805 | * configure.ac (AC_ARG_ENABLE): Add --disable-yacc. |
10806 | (YACC_SCRIPT, YACC_LIBRARY): New vars to AC_SUBST. | |
10807 | * lib/Makefile.am (lib_LIBRARIES): liby.a -> @YACC_LIBRARY@. | |
10808 | (EXTRA_LIBRARIES): New var, for liby.a. | |
10809 | * src/Makefile.am (bin_SCRIPTS): yacc -> @YACC_SCRIPT@. | |
10810 | (EXTRA_SCRIPTS): New var, for yacc. | |
10811 | ||
464c6927 PE |
10812 | * data/yacc.c (yyerrlab1): Omit attribute if __cplusplus is defined, |
10813 | since GNU C++ (as of 3.2.1) does not allow attributes on labels. | |
10814 | Problem reported by Nelson H. F. Beebe. | |
10815 | ||
10816 | 2003-01-03 Paul Eggert <eggert@twinsun.com> | |
10817 | ||
10818 | * lib/obstack.h (__INT_TO_PTR) [__STDC__]: Cast result to | |
10819 | (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5 | |
10820 | when compiling Bison 1.875's `bitset bset = obstack_alloc | |
10821 | (bobstack, bytes);'. Problem reported by Nelson H. F. Beebe. | |
10822 | ||
10823 | * src/scan-skel.l (QPUTS): Omit redundant `;' from macro definition. | |
10824 | ([^@\n]): Renamed from [^@\n]+ so that the token buffer does not | |
10825 | grow to a huge size with typical invocation. | |
d600ee67 | 10826 | |
464c6927 PE |
10827 | * lib/hash.c (_Bool, bool, false, true, __bool_true_false_are_defined): |
10828 | Use the pattern recommended by Autoconf 2.57, except also protect | |
10829 | against double-definition. | |
10830 | * src/system.h: Likewise. | |
10831 | Portability issues reported by Nelson H. F. Beebe. | |
d600ee67 | 10832 | |
464c6927 PE |
10833 | * data/glr.c (yybool): Renamed from bool, to avoid collisions in C. |
10834 | All uses changed. Provide a definition in both C and C++. | |
10835 | (yytrue, yyfalse): Define even if defined (__cplusplus). | |
10836 | ||
10837 | * lib/bitset_stats.c (bitset_stats_list): Remove unused var. | |
10838 | Reported by Nelson H. F. Beebe. | |
d600ee67 | 10839 | |
464c6927 PE |
10840 | * src/scan-skel.l ("@oline@"): Output lineno+1, not lineno. |
10841 | ||
0f42c7d5 PE |
10842 | 2003-01-02 Paul Eggert <eggert@twinsun.com> |
10843 | ||
10844 | * data/yacc.c (yyerrlab1): Append `;' after attribute, to | |
10845 | pacify the buggy "smart preprocessor" in MacOS 10.2.3. | |
10846 | Bug reported by Nelson H. F. Beebe. | |
10847 | ||
dc546b0f PE |
10848 | 2003-01-01 Paul Eggert <eggert@twinsun.com> |
10849 | ||
10850 | * Version 1.875. | |
10851 | ||
2c09b6a7 PE |
10852 | 2002-12-30 Paul Eggert <eggert@twinsun.com> |
10853 | ||
10854 | * src/scan-gram.l (<INITIAL,SC_AFTER_IDENTIFIER,SC_PRE_CODE>","): | |
10855 | Moved here from... | |
10856 | (<INITIAL>","): Here. This causes stray "," to be treated | |
10857 | more uniformly. | |
10858 | ||
dc546b0f | 10859 | * src/scan-gram.l (<SC_BRACED_CODE>"}"): Output ";" before the |
2c09b6a7 PE |
10860 | last brace in braced code when not in Yacc mode, for compatibility |
10861 | with Bison 1.35. This resurrects the 2001-12-15 patch to | |
10862 | src/reader.c. | |
10863 | ||
10864 | * src/reader.h (YYDECL): Use YYSTYPE, not its deprecated alias | |
10865 | yystype. This follows up the 2002-12-24 YYSTYPE bug fix. | |
10866 | ||
535c0f63 PE |
10867 | 2002-12-28 Paul Eggert <eggert@twinsun.com> |
10868 | ||
10869 | * src/symtab.c (symbol_make_alias): Set type of SYMVAL to be | |
10870 | that of SYM's type. This fixes Debian bug 168069, reported by | |
10871 | Thomas Olsson. | |
d600ee67 | 10872 | |
963fcc17 PE |
10873 | 2002-12-28 Paul Eggert <eggert@twinsun.com> |
10874 | ||
10875 | Version 1.75f. | |
10876 | ||
10877 | Switch back to the Yacc style of conflict reports, undoing some | |
10878 | of the 2002-07-30 change. | |
10879 | * doc/bison.texinfo (Understanding): Use Yacc style for | |
10880 | conflict reports. Also, use new way of locating rules. | |
10881 | * src/conflicts.c (conflict_report): | |
10882 | Renamed from conflict_report_yacc, removing the old | |
10883 | 'conflict_report'. Translate the entire conflict report at once, | |
10884 | so that we don't assume that "," has the same interpretation in | |
10885 | all languages. | |
10886 | (conflicts_output): Use Yacc-style conflict report for each state, | |
10887 | instead of our more-complicated style. | |
10888 | (conflicts_print): Use Yacc-style conflict report, except print | |
10889 | the input file name when not emulating Yacc. | |
10890 | * tests/conflicts.at (Unresolved SR Conflicts, Defaulted | |
10891 | Conflicted Reduction, %expect not enough, %expect too much, | |
10892 | %expect with reduce conflicts): Switch to Yacc-style conflict reports. | |
10893 | * tests/existing.at (GNU Cim Grammar): Likewise. | |
10894 | * tests/glr-regr1.at (Badly Collapsed GLR States): Likewise. | |
10895 | ||
10896 | * src/complain.c (warn_at, warn, complain_at, complain, fatal_at, | |
10897 | fatal): Don't invoke fflush; it's not needed and it might even be | |
10898 | harmful for stdout, as stdout might not be open. | |
10899 | * src/reduce.c (reduce_print): Likewise. | |
10900 | ||
b1efe548 PE |
10901 | 2002-12-27 Paul Eggert <eggert@twinsun.com> |
10902 | ||
10903 | Fix a bug where error locations were not being recorded correctly. | |
10904 | This problem was originally reported by Paul Hilfinger in | |
161a71f3 | 10905 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00086.html>. |
b1efe548 PE |
10906 | |
10907 | * data/yacc.c (yyparse): New local var yylerrsp, to record the | |
10908 | top of the location stack's error locations. | |
10909 | (yyerrlab): Set it. When discarding a token, push its location | |
10910 | onto yylerrsp so that we don't lose track of the error's end. | |
10911 | (yyerrlab1): Now is only the target of YYERROR, so that we can | |
10912 | properly record the location of the action that failed. For GCC | |
10913 | 2.93 and later, insert an __attribute__ ((__unused__)) to avoid | |
10914 | GCC warning about yyerrlab1 being unused if YYERROR is unused. | |
10915 | (yyerrlab2): New label, which yyerrlab now falls through to. | |
10916 | Compute the error's location by applying YYLLOC_DEFAULT to | |
10917 | the locations of all the symbols that went into the error. | |
10918 | * doc/bison.texinfo (Location Default Action): Mention that | |
10919 | YYLLOC_DEFAULT is also invoked for syntax errors. | |
10920 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
10921 | Error locations include the locations of all the tokens that were | |
10922 | discarded, not just the last token. | |
d600ee67 | 10923 | |
983c5c2c PE |
10924 | 2002-12-26 Paul Eggert <eggert@twinsun.com> |
10925 | ||
b1efe548 PE |
10926 | * src/files.c: Include quote.h. |
10927 | (compute_output_file_names): Warn if we detect conflicting | |
10928 | outputs to the same file. This should catch the misunderstanding | |
10929 | exemplified by Debian Bug 165349, reported by Bruce Stephens.. | |
10930 | ||
10931 | * src/conflicts.c (conflicts_print): If the user specifies | |
10932 | "%expect N", report an error if there are any reduce/reduce | |
10933 | conflicts. This is what the manual says should happen. | |
10934 | This fixes Debian bug 130890, reported by Anthony DeRobertis. | |
10935 | * tests/conflicts.at (%expect with reduce conflicts): New test. | |
10936 | ||
983c5c2c PE |
10937 | Don't use m4_include on relative file names, as it doesn't work as |
10938 | desired if there happens to be a file with that name under ".". | |
d600ee67 | 10939 | |
983c5c2c PE |
10940 | * m4sugar/version.m4: Remove; it was included but it wasn't used. |
10941 | * data/Makefile.am (dist_m4sugar_DATA): Remove m4sugar/version.m4. | |
10942 | * data/m4sugar/m4sugar.m4: Don't include m4sugar/version.m4. | |
10943 | * data/glr.c, data/lalr1.cc, data/yacc.c: Don't include c.m4. | |
10944 | * src/output.c (output_skeleton): Use full path names when | |
10945 | specifying a file to include; don't rely on include path, as | |
10946 | it's unreliable when the working file contains a file with | |
10947 | that name. | |
d600ee67 | 10948 | |
983c5c2c PE |
10949 | 2002-12-25 Paul Eggert <eggert@twinsun.com> |
10950 | ||
10951 | Remove obsolete references to bison.simple and bison.hairy. | |
10952 | Problem mentioned by Aubin Mahe in | |
161a71f3 | 10953 | <http://lists.gnu.org/archive/html/help-bison/2002-12/msg00010.html>. |
983c5c2c PE |
10954 | * data/glr.c: Comment fix. |
10955 | * doc/bison.1: Remove references. Also, mention "yacc". | |
10956 | ||
10957 | * src/getargs.c (getargs) [MSDOS]: Don't assume optarg != NULL | |
10958 | with -g option. | |
10959 | ||
10960 | * src/parse-gram.y (declaration): Use enum "report_states" rather | |
10961 | than its numeric value 1. | |
10962 | ||
10963 | * src/scan-skel.l ("@output ".*\n): Close any old yyout before | |
10964 | opening a new one. This fixes Debian bug 165349, reported by | |
10965 | Bruce Stephens. | |
10966 | ||
23f2d9dc PE |
10967 | 2002-12-24 Paul Eggert <eggert@twinsun.com> |
10968 | ||
10969 | Version 1.75e. | |
10970 | ||
10971 | * Makefile.maint (cvs-update): Don't assume that the shell | |
10972 | supports $(...), as Solaris sh doesn't. | |
10973 | ||
10974 | * src/parse-gram.y (lloc_default): Remove test for empty | |
10975 | nonterminals at the end, since it didn't change the result. | |
10976 | ||
10977 | 2002-12-24 Paul Eggert <eggert@twinsun.com> | |
33167b8b PE |
10978 | |
10979 | If the user does not define YYSTYPE as a macro, Bison now declares it | |
10980 | using typedef instead of defining it as a macro. POSIX requires this. | |
10981 | For consistency, YYLTYPE is also declared instead of defined. | |
10982 | ||
10983 | %union directives can now have a tag before the `{', e.g., the | |
10984 | directive `%union foo {...}' now generates the C code | |
10985 | `typedef union foo { ... } YYSTYPE;'; this is for Yacc compatibility. | |
10986 | The default union tag is `YYSTYPE', for compatibility with Solaris 9 | |
10987 | Yacc. For consistency, YYLTYPE's struct tag is now `YYLTYPE' | |
10988 | instead of `yyltype'. | |
10989 | ||
10990 | `yystype' and `yyltype' are now obsolescent macros instead of being | |
10991 | typedefs or tags; they are no longer documented and will be | |
10992 | withdrawn in a future release. | |
10993 | ||
10994 | * data/glr.c (b4_location_type): Remove. | |
10995 | (YYSTYPE): Renamed from yystype. | |
10996 | (YYSTYPE_IS_DECLARED): New macro, used to prevent double-typedef. | |
10997 | (struct YYLTYPE): Renamed from struct yyltype. | |
10998 | (YYLTYPE): Renamed from yyltype. | |
10999 | (yyltype, yystype): New (and obsolescent) macros, | |
11000 | for backward compatibility. | |
11001 | * data/yacc.c: Likewise. | |
11002 | ||
11003 | * data/yacc.c (YYSTYPE): Declare as union YYSTYPE if the user | |
11004 | does not specify a union tag. This is for compatibility with | |
11005 | Solaris 9 yacc. | |
11006 | ||
11007 | * src/parse-gram.y (add_param): 2nd arg is now char * not char | |
11008 | const *, since it is now modified by stripping surrounding { }. | |
11009 | (current_braced_code): Remove. | |
11010 | (PERCENT_DESTRUCTOR, PERCENT_PRINTER, PERCENT_UNION, | |
11011 | PERCENT_LEX_PARAM, PERCENT_PARSE_PARAM): Change names to include | |
11012 | trailing " {...}". Now of type <chars>. | |
11013 | (grammar_declaration): Adjust to bundled tokens. | |
11014 | (code_content): Remove; stripping is now done by add_param. | |
11015 | (print_token_value): Print contents of bundled tokens. | |
11016 | (token_name): New function. | |
11017 | ||
11018 | * src/reader.h (braced_code, current_braced_code): Remove. | |
11019 | (token_name): New decl. | |
11020 | ||
11021 | * src/scan-gram.l (handle_dollar, handle_at): Now takes int | |
11022 | token_type, not braced_code code_kind. All uses changed. | |
11023 | (SC_PRE_CODE): New state, for scanning after a keyword that | |
11024 | has (or usually has) an immediately-following braced code. | |
11025 | (token_type): New local var, to keep track of which token type | |
11026 | to return when scanning braced code. | |
11027 | (<INITIAL>"%destructor", <INITIAL>"%lex-param", | |
dc546b0f | 11028 | <INITIAL>"%parse-param", <INITIAL>"%printer", |
33167b8b PE |
11029 | <INITIAL>"%union"): Set token type and BEGIN SC_PRE_CODE |
11030 | instead of returning a token type immediately. | |
11031 | (<INITIAL>"{"): Set token type. | |
11032 | (<SC_BRACED_CODE>"}"): Use it. | |
11033 | (handle_action_dollar, handle_action_at): Now returns bool | |
11034 | indicating success. Fail if ! current_rule; this prevents a core dump. | |
11035 | (handle_symbol_code_dollar, handle_symbol_code_at): | |
11036 | Remove; merge body into caller. | |
11037 | (handle_dollar, handle_at): Complain in invalid contexts. | |
11038 | ||
11039 | * NEWS, doc/bison.texinfo: Document the above. | |
11040 | * NEWS: Fix years and program names in copyright notice. | |
11041 | ||
879ca4f8 PE |
11042 | 2002-12-17 Paul Eggert <eggert@twinsun.com> |
11043 | ||
11044 | * NEWS, doc/bison.texinfo (Parser Function, Pure Calling, Error | |
11045 | Reporting, Table of Symbols): Omit mentions of %lex-param and | |
11046 | %parse-param from the documentation for now. | |
11047 | ||
1c5fe69d PE |
11048 | 2002-12-15 Paul Eggert <eggert@twinsun.com> |
11049 | ||
11050 | Undo most of the 2002-11-12 yychar -> yytoken patch, as it broke | |
11051 | GCC 3.2.1 (which depends on yychar == YYEMPTY when there is no | |
11052 | lookahead symbol, and which sets yychar in parser actions) and it | |
7ea9026a PE |
11053 | disagreed with the Bison documentation. Bug |
11054 | reported by Andrew Walrond. | |
d600ee67 | 11055 | |
1c5fe69d PE |
11056 | * data/yacc.c (YYTRANSLATE): Don't check for negative argument, |
11057 | as the caller now does that. | |
11058 | (yyclearin, YYBACKUP, yyparse): Use yychar, not yytoken. | |
11059 | (YYEMPTY): Parenthesize right hand side, since others use it. | |
11060 | (yyparse): Don't assume that our generated code is the only code | |
11061 | that sets yychar. | |
11062 | ||
d1de5372 PE |
11063 | 2002-12-13 Paul Eggert <eggert@twinsun.com> |
11064 | ||
11065 | Version 1.75d. | |
11066 | ||
11067 | POSIX requires a "yacc" command. | |
11068 | * src/Makefile.am (bin_SCRIPTS): New macro, for yacc. | |
11069 | (MOSTLYCLEANFILES): Add yacc. | |
11070 | (yacc): New rule. | |
1c5fe69d | 11071 | * doc/bison.texinfo (Invocation, Bison Options): Mention yacc |
d1de5372 PE |
11072 | as an alias for bison y. |
11073 | ||
11074 | * po/LINGUAS: Add da. | |
d600ee67 | 11075 | |
d1de5372 PE |
11076 | * src/getargs.c (__GNU_LIBRARY__) [lint]: Define to work around |
11077 | problem with latest <getopt.h>. | |
11078 | (HACK_FOR___GNU_LIBRARY___PROTOTYPE): New macro. | |
11079 | ||
11080 | * doc/fdl.texi: Upgrade to 1.2. | |
11081 | * lib/alloca.c, lib/error.c, lib/getopt.c, lib/getopt.h | |
11082 | lib/getopt1.c, lib/gettext.h, lib/memrchr.c, lib/obstack.c, | |
11083 | lib/obstack.h, lib/strnlen.c, lib/unlocked-io.h: Sync with | |
11084 | gnulib. | |
11085 | * config/install-sh: Sync with autotools. | |
11086 | ||
11087 | Fix a bad interaction with flex 2.5.23 reported by Bruce Lilly in | |
161a71f3 | 11088 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. |
d1de5372 PE |
11089 | * data/yacc.c (YYLTYPE, struct yyltype): Do not define unless |
11090 | locations are requested. | |
11091 | (union yyalloc): Do not depend on YYLTYPE_IS_TRIVIAL unless | |
11092 | locations are requested. | |
11093 | ||
d0f3fe23 PE |
11094 | 2002-12-12 Paul Eggert <eggert@twinsun.com> |
11095 | ||
11096 | Remove unportable casts and storage allocation tricks. | |
11097 | While we're at it, remove almost all casts, since they | |
11098 | usually aren't needed and are a sign of trouble. | |
11099 | ||
11100 | * configure.ac (AC_CHECK_TYPES): Check for uintptr_t. | |
11101 | ||
11102 | * src/derives.c (derives_compute): Do not subtract NTOKENS from | |
11103 | the pointer DSET returned by malloc; this isn't portable. | |
11104 | Instead, always use DSET[i - NTOKENS] rather than DSET[i]. | |
11105 | Similarly for DERIVES. | |
11106 | * src/lalr.c (set_goto_map): Likewise, for GOTO_MAP and TEMP_MAP. | |
11107 | * src/nullable.c (nullable_compute): Likewise, for RSETS and NULLABLE. | |
11108 | * src/reduce.c (reduce_grammar_tables): Likewise, for nontermmap | |
11109 | ||
11110 | * src/derives.c (derives_compute): Do not bother invoking | |
11111 | int_of_rule_number, since rule numbers are integers. | |
11112 | ||
11113 | * src/files.c (concat2, tr, compute_base_name): Use xmalloc (N) | |
11114 | rather than XMALLOC (char, N). | |
11115 | ||
11116 | * src/files.c (filename_split): Rewrite to avoid cast. | |
11117 | ||
11118 | * src/gram.h (symbol_number_as_item_number, | |
11119 | item_number_as_symbol_number, rule_number_as_item_number, | |
11120 | item_number_as_rule_number): | |
11121 | Now inline functions rather than macros, to avoid casts. | |
11122 | * src/state.h (state_number_as_int): Likewise. | |
11123 | * src/tables.c (state_number_to_vector_number, | |
11124 | symbol_number_to_vector_number): Likewise. | |
11125 | ||
11126 | * src/gram.h (int_of_rule_number): Remove; no longer used. | |
11127 | ||
11128 | * src/lalr.c (add_lookback_edge): Use malloc rather than calloc, | |
11129 | since the resulting storage is always stored into. | |
11130 | ||
11131 | * src/main.c (alloca) [C_ALLOCA]: Add decl here, the only place | |
11132 | where it's needed. | |
11133 | ||
11134 | * src/muscle_tab.c (muscle_m4_output): | |
11135 | Now inline. Return bool, not int. | |
11136 | * src/state.c (state_compare): Likewise. | |
11137 | * src/symtab.c (symbol_check_defined, | |
11138 | symbol_check_alias_consistency, symbol_pack, symbol_translation, | |
11139 | hash_compare_symbol, hash_symbol): | |
11140 | Likewise. | |
11141 | * src/uniqstr.c (uniqstr_print): Likewise. | |
11142 | * src/muscle_tab.c (muscle_m4_output_processor): | |
11143 | New function, to avoid casts. | |
11144 | * src/state.c (state_comparator, stage_hasher): Likewise. | |
11145 | * src/symtab.c (symbol_check_defined_processor, | |
11146 | symbol_check_alias_consistency_processor, symbol_pack_processor, | |
11147 | symbol_translation_processor, hash_symbol_comparator, | |
11148 | hash_symbol_hasher): Likewise. | |
11149 | * src/uniqstr.c (uniqstr_print_processor): Likewise. | |
11150 | * src/muscle_tab.c (muscles_m4_output): | |
11151 | Use new functions instead of casting old functions unportably. | |
11152 | * src/state.c (state_hash_new): Likewise. | |
11153 | * src/symtab.c (symbols_new, symbols_do, symbols_check_defined, | |
11154 | symbols_token_translations_init): | |
11155 | Likewise. | |
11156 | * src/uniqstr.c (uniqstrs_new, hash_initialize, uniqstrs_do): Likewise. | |
11157 | ||
11158 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): Use long local | |
11159 | var instead of casting to long, to avoid casts. | |
11160 | (prepare_states): Use MALLOC rather than alloca, so that we don't | |
11161 | have to worry about alloca. | |
11162 | * src/state.c (state_hash_lookup): Likewise. | |
11163 | ||
11164 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>"'"): Use unsigned char | |
11165 | local var instead of casting to unsigned char, to avoid casts. | |
11166 | ||
11167 | * src/state.c (TRANSITIONS_ALLOC, ERRS_ALLOC, REDUCTIONS_ALLOC, | |
11168 | STATE_ALLOC): Remove. | |
11169 | (transitions_new, errs_new, reductions_new, state_new): Use malloc | |
11170 | rather than calloc, and use offsetof to avoid allocating slightly | |
11171 | too much storage. | |
11172 | (state_new): Initialize all members. | |
11173 | ||
11174 | * src/state.c (state_hash): Use unsigned accumulator, not signed. | |
11175 | ||
11176 | * src/symtab.c (symbol_free): Remove; unused. | |
11177 | (symbol_get): Remove cast in lhs of assignment. | |
11178 | (symbols_do): Now static. Accept generic arguments, not | |
11179 | hashing-related ones. | |
11180 | ||
11181 | * src/symtab.h: (NUMBER_UNDEFINED): Remove unnecessary cast. | |
11182 | (symbol_processor): Remove. | |
11183 | (symbols_do): Remove decl; now static. | |
11184 | ||
11185 | * src/system.h (alloca): Remove; decl no longer needed. | |
11186 | (<stddef.h>): Include, for offsetof. | |
11187 | (<inttypes.>, <stdint.h>): Include if available. | |
11188 | (uintptr_t): New type, if system lacks it. | |
11189 | (CALLOC, MALLOC, REALLOC): New macros. | |
11190 | All uses of XCALLOC, XMALLOC, and XREALLOC changed to use these | |
11191 | new macros. | |
11192 | ||
11193 | * src/tables.c (table_size): Now int, to pacify GCC. | |
11194 | (table_grow, table_ninf_remap): Use signed table size. | |
11195 | (save_row): Don't bother initializing locals when not needed. | |
11196 | (default_goto, goto_actions, pack_vector): Remove unnecessary casts. | |
11197 | * src/uniqstr.c (hash_compare_uniqstr): Likewise. | |
11198 | ||
11199 | * src/vcg.h: Correct misspellings. | |
11200 | ||
11201 | * src/vcg_defaults.h (G_CMAX): Now INT_MAX. | |
11202 | ||
11203 | ||
11204 | * src/getargs.c (getargs): Don't assume EOF == -1. | |
11205 | ||
26b4a969 PE |
11206 | 2002-12-09 Paul Eggert <eggert@twinsun.com> |
11207 | ||
11208 | Change identifier spellings to avoid collisions with names | |
11209 | that are reserved by POSIX. | |
11210 | ||
11211 | Don't use names ending in _t, since POSIX reserves them. | |
11212 | For consistency, remove _e and _s endings -- they're weren't | |
11213 | needed to remove ambiguity. All uses changed. | |
11214 | * src/uniqstr.h (uniqstr): Renamed from uniqstr_t, which in | |
11215 | turn was just renamed from struniq_t. | |
11216 | * src/uniqstr.c (uniqstr_processor): Renamed from struniq_processor, | |
11217 | which in turn was just renamed from struniq_processor_t. | |
11218 | (hash_compare_uniqstr): Renamed from hash_compare_struniq, which | |
11219 | in turn was renamed from hash_compare_struniq_t. | |
11220 | * src/LR0.c (struct state_list): Renamed from struct state_list_s. | |
11221 | (state_list): Renamed from state_list_t. | |
11222 | * src/assoc.h (assoc): Renamed from assoc_t. | |
11223 | * src/conflicts.c (enum conflict_resolution): Renamed from | |
11224 | enum conflict_resolution_e. | |
11225 | * src/derives.c (struct rule_list): Renamed from struct rule_list_s. | |
11226 | (rule_list): Renamed from rule_list_t. | |
11227 | * src/getargs.h (enum trace): Renamed from enum trace_e. | |
11228 | (enum report): Renamed from enum report_e. | |
11229 | * src/gram.h (item_number): Renamed from item_number_t. | |
11230 | (rule_number): Renamed from rule_number_t. | |
11231 | (struct rule_s): Remove the "rule_s" part; not used. | |
11232 | (rule): Renamed from rule_t. | |
11233 | (rule_filter): Renamed from rule_filter_t. | |
11234 | * src/lalr.c (struct goto_list): Renamed from struct goto_list_s. | |
11235 | (goto_list): Renamed from goto_list_t. | |
11236 | * src/lalr.h (goto_number): Renamed from goto_number_t. | |
11237 | * src/location.h (location): Renamed from location_t. | |
11238 | * src/muscle_tab.c (muscle_entry): Renamed from muscle_entry_t, | |
11239 | and moved here from: | |
11240 | * src/muscle_tab.h (muscle_entry_t): here. | |
11241 | * src/nullable.c (struct rule_list): Renamed from struct rule_list_s. | |
11242 | (rule_list): Renamed from rule_list_t. | |
11243 | * src/print_graph.c (static_graph): Renamed from graph. | |
11244 | * src/reader.h (braced_code): Renamed from braced_code_t. | |
11245 | Remove brace_code_e tag. | |
11246 | * src/relation.h (relation_node): Renamed from relation_node_t. | |
11247 | (relation_nodes): Renamed from relation_nodes_t. | |
11248 | (relation): Renamed from relation_t. | |
11249 | * src/state.h (state_number): Renamed from state_number_t. | |
11250 | (struct state): Renamed from struct state_s. | |
11251 | (state): Renamed from state_t. | |
11252 | (transitions): Renamed from transitions_t. Unused (and | |
11253 | misspelled) transtion_s tag removed. | |
11254 | (errs): Renamed from errs_t. Unused errs_s tag removed. | |
11255 | (reductions): Renamed from reductions_t. Unused tag | |
11256 | reductions_s removed. | |
11257 | * src/symlist.h (symbol_list): Renamed from symbol_list_t. | |
11258 | (struct symbol_list): Renamed from struct symbol_list_s. | |
11259 | * src/symtab.h (symbol_number): Renamed from symbol_number_t. | |
11260 | (struct symbol): Renamed from struct symbol_s. | |
11261 | (symbol): Renamed from symbol_t. | |
11262 | * src/tables.c (vector_number): Renamed from vector_number_t. | |
11263 | (action_number): Renamed from action_t. | |
11264 | * src/tables.h (base_number): Renamed from base_t. | |
11265 | * src/vcg.h (enum color): Renamed from enum color_e. | |
11266 | (enum textmode): Renamed from enum textmode_e. | |
11267 | (enum shape): Renamed from enum shape_e. | |
11268 | (struct colorentry): Renamed from struct colorentry_s. | |
11269 | (struct classname): Renamed from struct classname_s. | |
11270 | (struct infoname): Renamed from struct infoname_s. | |
11271 | (enum layoutalgorithm): Renamed from enum layoutalgorithm_e. | |
11272 | (enum decision): Renamed from enum decision_e. | |
11273 | (enum orientation): Renamed from enum orientation_e. | |
11274 | (enum alignment): Renamed from enum alignment_e. | |
11275 | (enum arrow_mode): Renamed from enum arrow_mode_e. | |
11276 | (enum crossing_type): Renamed from enum crossing_type_e. | |
11277 | (enum view): Renamed from enum view_e. | |
11278 | (struct node): Renamed from struct node_s. | |
11279 | (node): Renamed from node_t. | |
11280 | (enum linestyle): Renamed from enum linestyle_e. | |
11281 | (enum arrowstyle): Renamed from enum arrowstyle_e. | |
11282 | (struct edge): Renamed from struct edge. | |
11283 | (edge): Renamed from edge_t. | |
11284 | (struct graph): Renamed from struct graph_s. | |
11285 | (graph): Renamed from graph_t. | |
11286 | * tests/calc.at (_AT_DATA_CALC_Y, Simple LALR Calculator): | |
11287 | Rename value_t -> value. | |
11288 | * tests/input.at (Torturing the Scanner): Rename value_t -> value, | |
11289 | value_t_as_yystype -> value_as_yystype. | |
11290 | ||
11291 | Don't include <errno.h> in the mainstream code, since it | |
11292 | reserves E[A-Z0-9]* and we want to use symbols like 'EQUALS'. | |
11293 | * lib/get-errno.c, lib/get-errno.h: New files. | |
11294 | * lib/Makefile.am (libbison_a_SOURCES): Add get-errno.h, | |
11295 | get-errno.c. | |
11296 | * src/files.c (xfopen, xfclose): Use get_errno instead of errno. | |
11297 | * src/output.c (output_skeleton): Likewise. | |
11298 | * src/scan-gram.l (<INITIAL>{int}): Use set_errno and get_errno | |
11299 | instead of errno. | |
11300 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>\\x[0-9abcdefABCDEF]+): | |
11301 | Likewise. | |
11302 | (handle_action_dollar, handle_action_at): Likewise. | |
11303 | * src/system.h: Do not include <errno.h>. | |
11304 | (TAB_EXT): Renamed from EXT_TAB. | |
11305 | (OUTPUT_EXT): Renamed from EXT_OUTPUT. | |
11306 | ||
11307 | Avoid str[a-z]*, since <string.h> reserves that name space. | |
11308 | Change all instances of "struniq" in names to "uniqstr", and | |
11309 | likewise for "STRUNIQ" and "UNIQSTR". | |
11310 | * src/uniqstr.c: Renamed from src/struniq.c. | |
11311 | * src/uniqstr.h: Renamed from src/struniq.h. | |
11312 | * src/Makefile.am (bison_SOURCES): Adjust to these renamings. | |
11313 | * src/files.c (strsuffix): Remove; unused. | |
11314 | (concat2): Renamed from stringappend. Now static. | |
11315 | * src/files.h (strsuffix, stringappend): Remove; unused. | |
11316 | * src/parse-gram.y (<chars>): Renamed from <string>. | |
11317 | (<uniqstr>): Renamed from <struniq>. | |
11318 | * src/scan-gram.l (obstack_for_string): Renamed from string_obstack. | |
11319 | * src/vcg.h (struct node_s.expand): Renamed from struct node_s.stretch. | |
11320 | (struct graph_s.expand): Renamed from struct graph_s.stretch. | |
11321 | * src/vcg_defaults.h (G_EXPAND): Renamed from G_STRETCH. | |
11322 | (G_LONG_STRAIGHT_PHASE): Renamed from G_STRAIGHT_PHASE. | |
11323 | (N_EXPAND): Renamed from N_STRETCH. | |
11324 | ||
11325 | Avoid *_MAX and *_MIN, since <limits.h> reserves that name space. | |
11326 | * data/yacc.c (YYSTACK_GAP_MAXIMUM): Renamed from YYSTACK_GAP_MAX. | |
11327 | * src/gram.h (ITEM_NUMBER_MAX, ITEM_NUMBER_MIN, RULE_NUMBER_MAX): | |
11328 | Remove; unused. | |
11329 | * src/lalr.h (GOTO_NUMBER_MAXIMUM): Renamed from GOTO_NUMBER_MAX. | |
11330 | * src/state.h (STATE_NUMBER_MAXIMUM): Renamed from STATE_NUMBER_MAX. | |
11331 | * src/symtab.h (SYMBOL_NUMBER_MAXIMUM): Renamed from SYMBOL_NUMBER_MAX. | |
11332 | * src/tables.c (VECTOR_NUMBER_MAX, VECTOR_NUMBER_MIN): Remove; unused. | |
11333 | (BASE_MAXIMUM): Renamed from BASE_MAX. | |
11334 | (BASE_MINIMUM): Renamed from BASE_MIN. | |
11335 | (ACTION_MAX): Remove; unused. | |
11336 | (ACTION_NUMBER_MINIMUM): Renamed from ACTION_MIN. | |
11337 | Unnecessary casts removed from above defines. | |
11338 | ||
11339 | ||
11340 | Fix misspelling in names. | |
11341 | * src/vcg.h (enum_alignment_e): Renamed from enum_alignement_e. | |
11342 | * src/vcg_defaults.h (G_NODE_ALIGNMENT): Renamed from | |
11343 | G_NODE_ALIGNEMENT. | |
11344 | ||
11345 | ||
11346 | * lib/timevar.c (timevar_report): Renamed from time_report, | |
11347 | for consistency with other names. | |
11348 | * lib/timevar.h (timevar_report): New decl. | |
11349 | * src/system.h (time_report): Remove; decl is now in lib/timevar.h. | |
11350 | ||
11351 | ||
11352 | Sort include-file uses. | |
11353 | ||
11354 | Reorder all include files under src to be in the order "system.h". | |
11355 | then the ../lib include files in angle brackets (alphabetized), | |
11356 | then the . include files in double-quotes (alphabetized). Fix | |
11357 | dependency breakages encountered in this process, as follows: | |
11358 | * src/closure.h, src/derives.h, src/state.h: Include "gram.h". | |
11359 | * src/complain.c: Don't include stdlib.h, string.h _LIBC stuff. | |
11360 | * src/state.h: Include "symtab.h". | |
11361 | ||
996b1c7e PE |
11362 | 2002-12-08 Paul Eggert <eggert@twinsun.com> |
11363 | ||
11364 | * data/glr.c, data/lalr1.cc, data/yacc.c: Do not use __file__, | |
11365 | since this causes problems when __file__ contains character | |
11366 | sequences like "@" that are treated specially by src/scan-skel.l. | |
11367 | Instead, just use the file's basename. This fixes the bug | |
11368 | reported by Martin Mokrejs in | |
161a71f3 | 11369 | <http://lists.gnu.org/archive/html/bug-bison/2002-12/msg00007.html>. |
996b1c7e | 11370 | |
e19c4e5d PE |
11371 | 2002-12-06 Paul Eggert <eggert@twinsun.com> |
11372 | ||
11373 | Add support for rules that do not have trailing semicolons, as | |
11374 | POSIX requires. Improve the quality of locations in Bison | |
11375 | diagnostics. | |
26b4a969 | 11376 | |
e19c4e5d PE |
11377 | * src/location.c: Include <quotearg.h>. |
11378 | (empty_location): Now const. | |
11379 | (location_print): New function. Follow the recommendation of the | |
11380 | GNU Coding Standards for locations that span file boundaries. | |
11381 | * src/location.h: Do not include <quotearg.h>; no longer needed. | |
11382 | (boundary): New type. | |
11383 | (location_t): Use it. This allows locations to span file boundaries. | |
11384 | All member uses changed: file -> start.file or end.file (as needed), | |
11385 | first_line -> start.line, first_column -> start.column, | |
11386 | last_line -> end.line, last_column -> end.column. | |
11387 | (equal_boundaries): New function. | |
11388 | (LOCATION_RESET, LOCATION_STEP): Remove. | |
11389 | (LOCATION_PRINT): Remove. All callers changed to use location_print. | |
11390 | (empty_location): Now const. | |
11391 | (location_print): New decl. | |
11392 | * src/parse-gram.y (lloc_default): New function, which handles | |
11393 | empty locations more accurately. | |
11394 | (YYLLOC_DEFAULT): Use it. | |
11395 | (%token COLON): Remove. | |
11396 | (%token ID_COLON): New token. | |
26b4a969 | 11397 | (rules): Use it. |
e19c4e5d PE |
11398 | (declarations, rules): Remove trailing semicolon. |
11399 | (declaration, rules_or_grammar_declaration): | |
11400 | Allow empty (";") declaration. | |
11401 | (symbol_def): Remove empty actions; no longer needed. | |
11402 | (rules_or_grammar_declaration): Remove trailing semicolon. | |
11403 | (semi_colon.opt): Remove. | |
11404 | * src/reader.h: Include location.h. | |
11405 | (scanner_cursor): New decl. | |
11406 | * src/reduce.c (nonterminals_reduce): Use warn_at rather than | |
11407 | rolling our own. | |
11408 | * src/scan-gram.l (YY_USER_INIT): Initialize scanner_cursor instead | |
11409 | of *loc. | |
11410 | (STEP): Remove. No longer needed, now that adjust_location does | |
11411 | the work. All uses removed. | |
11412 | (scanner_cursor): New var. | |
11413 | (adjust_location): Renamed from extend_location. It now sets | |
11414 | *loc and adjusts the scanner cursor. All uses changed. | |
11415 | Don't bother testing for CR. | |
11416 | (handle_syncline): Remove location arg; now updates scanner cursor. | |
11417 | All callers changed. | |
11418 | (unexpected_end_of_file): Now accepts start boundary of token or | |
11419 | comment, not location. All callers changed. Update scanner cursor, | |
11420 | not the location. | |
11421 | (SC_AFTER_IDENTIFIER): New state. | |
11422 | (context_state): Renamed from c_context. All uses changed. | |
11423 | (id_loc, code_start, token_start): New local vars. | |
11424 | (<INITIAL,SC_AFTER_IDENTIFIER>): New initial context. Move all | |
11425 | processing of Yacc white space and equivalents here. | |
11426 | (<INITIAL>{id}): Save id_loc. Begin state SC_AFTER_IDENTIFIER | |
11427 | instead of returning ID immediately, since we need to search for | |
11428 | a subsequent colon. | |
11429 | (<INITIAL>"'", "\""): Save token_start. | |
11430 | (<INITIAL>"%{", "{", "%%"): Save code_start. | |
11431 | (<SC_AFTER_IDENTIFIER>): New state, looking for a colon. | |
11432 | (<SC_YACC_COMMENT>, <SC_COMMENT>, <SC_LINE_COMMENT>): | |
11433 | BEGIN context_state at end, not INITIAL. | |
11434 | (<SC_ESCAPED_STRING>"\"", <SC_ESCAPED_CHARACTER>"'", | |
11435 | <SC_BRACED_CODE>"}", <SC_PROLOGUE>"%}", <SC_EPILOGUE><<EOF>>): | |
11436 | Return correct token start. | |
11437 | (<SC_BRACED_CODE,SC_PROLOGUE,SC_EPILOGUE>): Save start boundary when | |
11438 | the start of a character, string or multiline comment is found. | |
11439 | * tests/conflicts.at (S/R in initial, Defaulted Conflicted | |
11440 | Reduction): Adjust reported locations to match the more-precise | |
11441 | results now expected. | |
11442 | * tests/input.at (Invalid $n, Invalid @n, Type Clashes): Likewise. | |
11443 | * tests/reduce.at (Useless Rules, Reduced Automaton, | |
11444 | Underivable Rules): Likewise. | |
11445 | * tests/regression.at (Invalid inputs): No longer `expecting ";" | |
11446 | or "|"' now that so many other tokens are allowed by the new grammar. | |
11447 | ||
11448 | * src/complain.h (current_file): Remove duplicate decl; | |
11449 | current_file is now owned by files.h. | |
11450 | * src/complain.c, src/scan-gram.l: Include files.h. | |
11451 | ||
11452 | 2002-12-06 Paul Eggert <eggert@twinsun.com> | |
26b4a969 | 11453 | |
e19c4e5d PE |
11454 | * data/glr.c (yy_reduce_print): Don't assume that yyrline[yyrule] |
11455 | promotes to int; it might be unsigned int. | |
11456 | * data/yacc.c (yy_reduce_print): Likewise. | |
11457 | ||
11458 | * doc/bison.texinfo (Table of Symbols): YYERROR_VERBOSE should | |
11459 | be #defined in the prologue, not in the Bison declarations. | |
11460 | This fixes Debian Bug 102878, reported by Shaul Karl. | |
26b4a969 | 11461 | |
b64755e3 PE |
11462 | 2002-12-02 Paul Eggert <eggert@twinsun.com> |
11463 | ||
11464 | * configure.ac (AC_REPLACE_FUNCS): Add strtoul. | |
11465 | * lib/strtoul.c: New file, from gnulib. | |
11466 | This fixes a porting bug reported by Peter Klein in | |
161a71f3 | 11467 | <http://lists.gnu.org/archive/html/bug-bison/2002-12/msg00000.html>. |
b64755e3 | 11468 | |
6e746484 PE |
11469 | 2002-11-30 Paul Eggert <eggert@twinsun.com> |
11470 | ||
b64755e3 PE |
11471 | * src/scan-gram.l (no_cr_read, extend_location): Move to epilogue, |
11472 | and put only a forward declaration in the prologue. This is for | |
11473 | consistency with the other scanner helper functions. | |
11474 | ||
6ba55592 PE |
11475 | Type clashes now generate warnings, not errors, since it |
11476 | appears that POSIX may allow some grammars with type clashes. | |
11477 | * src/reader.c (grammar_current_rule_check): Warn about | |
11478 | type clashes instead of complaining. | |
11479 | * tests/input.at (Type Clashes): Expect warnings, not complaints. | |
11480 | ||
6e746484 PE |
11481 | Add Yacc library, since POSIX requires it. |
11482 | * doc/bison.texinfo (Yacc Library): New node. Regenerate top menu. | |
11483 | * lib/Makefile.am (lib_LIBRARIES, liby_a_SOURCES): New macros. | |
11484 | * lib/main.c, lib/yyerror.c: New files. | |
11485 | ||
11486 | gram_error can be static; it need not be extern. | |
11487 | * src/reader.h (gram_error): Remove decl. | |
11488 | * src/parse-gram.y (gram_error): Now static. Add static decl. | |
11489 | (print_token_value): Omit parameter names from forward decl, | |
11490 | for consistency. | |
11491 | ||
88510f9c PE |
11492 | 2002-11-29 Paul Eggert <eggert@twinsun.com> |
11493 | ||
6e746484 PE |
11494 | * doc/bison.texinfo: Emphasize that yylex and yyerror must |
11495 | be declared before being used. E.g., one should typically | |
11496 | declare them in the prologue. Use GNU coding style in examples. | |
11497 | Put "const" consistently after the type it modifies. Mention | |
11498 | that C99 supports "inline". Mention that yyerror traditionally | |
11499 | returns "int". | |
11500 | ||
88510f9c PE |
11501 | %parse-param and %lex-param now take just one argument, the |
11502 | declaration; the argument name is deduced from the declaration. | |
11503 | ||
11504 | * doc/bison.texinfo (Parser Function, Pure Calling, Error | |
11505 | Reporting, Table of Symbols): Document this. | |
11506 | * src/parse-gram.y (add_param): New function. | |
11507 | (COMMA): Remove. | |
11508 | (declaration): Implement new rule for %parse-param and %lex-param. | |
11509 | * src/scan-gram.l: "," now elicits a warning, rather than being | |
11510 | a token; this is more compatible with byacc. | |
11511 | * tests/calc.at (Simple LALR Calculator): Adopt new convention. | |
11512 | ||
bb92250c PE |
11513 | 2002-11-27 Paul Eggert <eggert@twinsun.com> |
11514 | ||
11515 | Rename identifiers to avoid real and potential collisions. | |
11516 | ||
11517 | * data/c.m4 (b4_yysymprint_generate): yyout -> yyoutput, | |
11518 | to avoid collision with lex macro described by Bruce Lilly in | |
161a71f3 | 11519 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. |
bb92250c PE |
11520 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise. |
11521 | * doc/bison.texinfo (Prologue, Tracing): yyprint -> print_token_value. | |
11522 | * src/parse-gram.y (print_token_value): Renamed from yyprint. | |
11523 | All uses changed. | |
11524 | (YYPARSE_PARAM, YYLEX_PARAM, yycontrol): Remove. All uses changed. | |
11525 | The name "yycontrol" violates the name space rules, and this stuff | |
11526 | wasn't being used anyway. | |
11527 | (input): Remove action; this stuff wasn't being used. | |
11528 | (gram_error): Rename local variable yylloc -> loc. | |
11529 | * src/reader.h (struct gram_control_s, gram_control_t): Remove. | |
11530 | (YY_DECL): Don't use "yy" at start of local variables. | |
11531 | All uses changed, e.g., yylloc -> loc. | |
11532 | * src/scan-gram.l (STEP): Renamed from YY_STEP. All uses changed. | |
11533 | (STRING_GROW): Renamed from YY_OBS_GROW. All uses changed. | |
11534 | (STRING_FINISH): Renamed from YY_OBS_FINISH. All uses changed. | |
11535 | (STRING_FREE): Renamed from YY_OBS_FREE. All uses changed. | |
11536 | ||
11537 | * src/parse-gram.y (gram_error): loc is now const *. | |
11538 | * src/reader.h (gram_error): Likewise. | |
11539 | ||
3af4feb2 PE |
11540 | 2002-11-24 Paul Eggert <eggert@twinsun.com> |
11541 | ||
11542 | Version 1.75c. | |
11543 | ||
11544 | * tests/actions.at (Actions after errors): Use an output format | |
11545 | more similar to that of the Printers and Destructors test. | |
11546 | Test the position of the ';' token too. | |
11547 | (Printers and Destructors): Likewise. | |
11548 | (Printers and Destructors: %glr-parser): Remove for now, to avoid | |
11549 | unnecessarily alarming people when the test fails. | |
11550 | ||
11551 | * data/yacc.c (yyerrlab1): Move this label down, so that the | |
11552 | parser does not discard the lookahead token if the user code | |
11553 | invokes YYERROR. This change is required for POSIX conformance. | |
11554 | ||
11555 | * lib/error.c: Sync with gnulib. | |
11556 | ||
11557 | 2002-11-22 Paul Eggert <eggert@twinsun.com> | |
11558 | ||
11559 | * lib/quotearg.c, lib/quotearg.h: Sync with gnulib. | |
11560 | * lib/mbswidth.c, lib/mbswidth.h: Likewise. | |
11561 | * lib/xmalloc.c: Likewise. | |
26b4a969 | 11562 | |
58004308 PE |
11563 | 2002-11-20 Paul Eggert <eggert@twinsun.com> |
11564 | ||
11565 | * lib/argmatch.c, lib/argmatch.h: Sync with gnulib. | |
11566 | ||
11567 | 2002-11-20 Paul Eggert <eggert@twinsun.com> | |
26b4a969 | 11568 | |
58004308 PE |
11569 | Avoid use of <assert.h>, as the GNU Coding Standards hint that one |
11570 | should use `if (! x) abort ();' rather than `assert (x);', and | |
11571 | anyway it's one less thing to worry about configuring. | |
11572 | ||
11573 | * data/glr.c, lib/hash.c, src/system.h: Do not include <assert.h>. | |
11574 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise, | |
11575 | and replace all instances of assert with abort. | |
11576 | * tests/calc.at (_AT_DATA_CALC_Y): Likewise. | |
11577 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Likewise. | |
11578 | ||
11579 | * data/glr.c (yydoAction, yyglrReduce, yysplitStack, yyresolveStates, | |
11580 | yyresolveAction, yyprocessOneStack): Use abort rather than assert. | |
11581 | * lib/hash.c (hash_lookup, hash_get_first, hash_get_next, | |
11582 | hash_find_entry, hash_rehash, hash_insert): Likewise. | |
11583 | * src/conflicts.c (resolve_sr_conflict): Likewise. | |
11584 | * src/lalr.c (set_goto_map, map_goto): Likewise. | |
11585 | * src/nullable.c (nullable_compute): Likewise. | |
11586 | * src/output.c (prepare_rules, token_definitions_output): Likewise. | |
11587 | * src/reader.c (packgram, reader): Likewise. | |
11588 | * src/state.c (state_new, state_free, state_transitions_set, | |
11589 | state_reduction_find): Likewise. | |
11590 | * src/symtab.c (symbol_user_token_number_set, symbol_make_alias, | |
11591 | symbol_pack): Likewise. | |
11592 | * src/tables.c (conflict_row, pack_vector): Likewise. | |
11593 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
11594 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
11595 | get_node_alignement_str, get_arrow_mode_str, get_crossing_type_str, | |
11596 | get_view_str, get_linestyle_str, get_arrowstyle_str): Likewise. | |
11597 | ||
11598 | * lib/argmatch.h (ARRAY_CARDINALITY): Do not bother to #undef. | |
11599 | (ARGMATCH_CONSTRAINT): New macro. | |
11600 | (ARGMATCH_ASSERT): Use it. | |
11601 | ||
11602 | * src/system.h (verify): New macro. | |
11603 | * src/getargs.c (trace_argmatch, report_argmatch): Use verify | |
11604 | rather than assert. | |
11605 | * src/tables.c (tables_generate): Likewise. | |
11606 | ||
11607 | * src/struniq.c (struniq_assert): Now returns void, and aborts | |
11608 | if the assertion is false. | |
11609 | (struniq_assert_p): Remove. | |
11610 | * src/struniq.h: Likewise. | |
11611 | ||
76ae8198 PE |
11612 | 2002-11-18 Paul Eggert <eggert@twinsun.com> |
11613 | ||
11614 | * data/glr.c (yygetLRActions): Replace `yyindex' with | |
11615 | `yytable[yyindex]' to fix typo introduced in my 2002-11-09 patch. | |
11616 | This fixes the regression with Sun ONE Studio 7 cc that I reported in | |
161a71f3 | 11617 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00077.html>. |
76ae8198 | 11618 | |
d3c4e709 AD |
11619 | 2002-11-18 Akim Demaille <akim@epita.fr> |
11620 | ||
11621 | * doc/bison.texinfo (Tracing): `yyprint' shouldn't prepend a | |
11622 | space. | |
11623 | From Tim Van Holder. | |
11624 | ||
8d8a7238 PE |
11625 | 2002-11-17 Paul Eggert <eggert@twinsun.com> |
11626 | ||
11627 | Pacify Sun ONE Studio 7 lint. Also, rename "ParseError" | |
11628 | to "SyntaxError" for consistency with my 2002-11-15 change. | |
11629 | ||
11630 | * data/glr.c (YYDPRINTF, YYDSYMPRINT, YYDSYMPRINTF) [!YYDEBUG]: Do | |
11631 | not define to {}, since this breaks the common use of `YYDPRINTF | |
11632 | ((...));' if a single statement is desired (e.g. before `else'). | |
11633 | Work around GCC warnings by surrounding corresponding calls with | |
11634 | {} if needed. | |
11635 | (yyhasResolvedValue): Remove unused function. | |
11636 | (yymergeOptionSets, yyresolvStack): Use `continue;' for empty | |
11637 | loop body. | |
11638 | (yyreportSyntaxError): Renamed from yyreportParseError. | |
11639 | (yyrecoverSyntaxError): Renamed from yyrecoverParseError. | |
11640 | All uses changed. | |
11641 | * tests/calc.at (_AT_DATA_CALC_Y): Make vars static instead of | |
11642 | extern when possible. Remove unused initializations. | |
11643 | ||
b0937b22 AD |
11644 | 2002-11-16 Akim Demaille <akim@epita.fr> |
11645 | ||
11646 | Augment the similarity between GLR and LALR traces. | |
11647 | ||
11648 | * data/yacc.c (yy_stack_print, YY_STACK_PRINT, yy_reduce_print) | |
11649 | (YY_REDUCE_PRINT): New. | |
11650 | (yyparse): Use them. | |
11651 | * data/glr.c (yy_reduce_print): Use YYFPRINTF, no need for | |
11652 | YYDPRINT here. | |
11653 | (yyglrReduce, yyrecoverParseError, yyparse): Don't report the | |
11654 | state reached after the reduction/recovery, since... | |
11655 | (yyparse, yyprocessOneStack): Report the state we are entering in. | |
11656 | ||
c5e3e510 AD |
11657 | 2002-11-16 Akim Demaille <akim@epita.fr> |
11658 | ||
11659 | * src/getargs.h, src/getargs.c (trace_e, trace_args, trace_types): | |
11660 | Add support for --trace=skeleton. | |
11661 | * src/scan-skel.l: %option debug. | |
11662 | Scan strings of non-@ or \n instead of character by character. | |
11663 | (scan_skel): Handle trace_skeleton. | |
11664 | (QPUTS): New. | |
11665 | (@output_parser_name@, @output_header_name@): ``Restore'' their | |
11666 | support (used to be M4 macros). | |
11667 | * data/yacc.c: Quote larger chunks, a la glr.c. | |
11668 | * data/lalr1.cc: Likewise. | |
11669 | The header guards are no longer available, so use some other | |
11670 | string than `YYLSP_NEEDED'. | |
11671 | ||
4c6cc1db AD |
11672 | 2002-11-16 Akim Demaille <akim@epita.fr> |
11673 | ||
11674 | Make the ``Printers and Destructors'' test more verbose, taking | |
11675 | `yacc.c''s behavior as (possibly wrong) reference. | |
11676 | ||
11677 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Use printf | |
11678 | instead of fprint on stdout. | |
11679 | Set and report the last_line of the symbols. | |
11680 | Consistently display values and locations. | |
11681 | ||
6d9e8019 PE |
11682 | 2002-11-16 Paul Eggert <eggert@twinsun.com> |
11683 | ||
11684 | * data/yacc.c: Avoid over-quoting of __line__ and __file__. | |
11685 | ||
6e649e65 PE |
11686 | 2002-11-15 Paul Eggert <eggert@twinsun.com> |
11687 | ||
b25d88f6 PE |
11688 | * tests/actions.at (Actions after errors): New test case. |
11689 | ||
6e649e65 PE |
11690 | * data/glr.c, data/lalr1.cc, data/yacc.cc, doc/bison.texinfo, |
11691 | src/conflicts.c, src/parse-gram.y, src/tables.c, src/tables.h, | |
11692 | tests/action.at, tests/calc.at, tests/conflicts.at, | |
11693 | tests/cxx-type.at, tests/regression.at: | |
11694 | "parse error" -> "syntax error" for POSIX compatibility. | |
11695 | "parsing stack overflow..." -> "parser stack overflow" so | |
11696 | that code matches Bison documentation. | |
11697 | ||
0f39aab9 AD |
11698 | 2002-11-15 Akim Demaille <akim@epita.fr> |
11699 | ||
11700 | * src/parse-gram.y (declaration): Have %parse-param and %lex-param | |
11701 | take two BRACED_CODE, not two string_content. | |
11702 | Free the scanner's obstack when we are done. | |
11703 | (code_content): New. | |
11704 | * tests/calc.at: Adjust. | |
11705 | * doc/bison.texinfo: Adjust. | |
11706 | Also, make sure to include the `,' for these declarations. | |
11707 | ||
761c1926 AD |
11708 | 2002-11-15 Tim Van Holder <tim.van.holder@pandora.be> |
11709 | ||
11710 | * m4/prereq.m4: Removed the commented jm_PREREQ_HASH | |
11711 | definition; avoids potential autoreconf problems. | |
11712 | ||
b0f98b10 AD |
11713 | 2002-11-15 Akim Demaille <akim@epita.fr> |
11714 | ||
11715 | Always check the value returned by yyparse. | |
11716 | ||
11717 | * tests/calc.at (_AT_DATA_CALC_Y): Have `main' exit with the value | |
11718 | returned by yyparse. | |
11719 | (_AT_CHECK_CALC_ERROR): Take the expected exit value as argument. | |
11720 | Adjust calls. | |
11721 | * tests/glr-regr1.at (glr-regr1.y): Have `main' exit with the value | |
11722 | returned by yyparse. | |
11723 | ||
970785f1 PH |
11724 | 2002-11-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
11725 | ||
11726 | * data/glr.c (yyFail): Always set yyerrflag. Corrects regression | |
11727 | on input.at test. | |
11728 | ||
8fcc7db1 PE |
11729 | 2002-11-14 Paul Eggert <eggert@twinsun.com> |
11730 | ||
7ec1b48e PE |
11731 | * src/output.c (output_skeleton): Call xfopen instead of |
11732 | duplicating xfopen's body. | |
11733 | ||
cfff7583 | 11734 | Fix bugs reported by Nelson H. F. Beebe in |
161a71f3 | 11735 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00078.html>. |
cfff7583 | 11736 | |
8fcc7db1 PE |
11737 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Don't assume that |
11738 | "$CC -E foo.h" is allowed, as this doesn't work with the Portland | |
11739 | Group compiler. Instead, use "$CC -E bar.c". Include the .h | |
11740 | file twice in the grammar, as an extra check. | |
11741 | ||
11742 | * tests/input.at (Torturing the Scanner): Surround the | |
11743 | backslash-newline tests with "#if 0", to make it less likely that | |
11744 | we'll run into compiler bugs. Bring back solitary \ inside | |
11745 | comment, but add a closing comment to work around HP C bug. Don't | |
e3aa65c5 | 11746 | test backslash-newline in C character constant. |
8fcc7db1 | 11747 | |
4e8d992c AD |
11748 | 2002-11-14 Akim Demaille <akim@epita.fr> |
11749 | ||
11750 | * tests/synclines.at (AT_SYNCLINES_COMPILE): Ignore the exit | |
11751 | status of the compiler. | |
f32b346d | 11752 | Calling `exit 1' is no longer needed. |
4e8d992c AD |
11753 | Reported by Nelson H. F. Beebe. |
11754 | ||
9501dc6e AD |
11755 | 2002-11-14 Akim Demaille <akim@epita.fr> |
11756 | ||
11757 | * tests/atlocal.in (CPPFLAGS): We have config.h. | |
11758 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR): | |
11759 | New. | |
11760 | * tests/actions.at, tests/calc.at, tests/conflicts.at, | |
11761 | * tests/cxx-type.at, tests/glr-regr1.at, tests/headers.at, | |
11762 | * tests/regression.at, tests/torture.at: Use them for all the | |
11763 | grammars that are to be compiled. | |
11764 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Rename as... | |
11765 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): this. | |
11766 | * doc/bison.texinfo (GLR Parsers): Document `inline'. | |
11767 | ||
18b519c0 AD |
11768 | 2002-11-14 Akim Demaille <akim@epita.fr> |
11769 | ||
11770 | * doc/bison.texinfo: Various formatting changes (alignments in | |
11771 | samples, additional @group/@end group, GCS in samples. | |
11772 | Use @deffn instead of simple @table to define the directives, | |
11773 | macros, variables etc. | |
11774 | ||
9a86cdb9 PE |
11775 | 2002-11-13 Paul Eggert <eggert@twinsun.com> |
11776 | ||
daa33def | 11777 | Fix some bugs reported by Albert Chin-A-Young in |
161a71f3 | 11778 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00066.html>. |
18b519c0 | 11779 | |
daa33def | 11780 | * tests/input.at (Torturing the Scanner): Don't invoke "cc a.c b.c |
8fcc7db1 | 11781 | -o c"; the HP C compiler chatters during compilation. |
daa33def PE |
11782 | Instead, invoke "cc -c a.c -o a.o; cc -c b.c -o b.o; cc a.o b.o -o c". |
11783 | * tests/headers.at (export YYLTYPE): Likewise. | |
11784 | ||
11785 | * tests/input.at (Torturing the Scanner): Remove lines containing | |
8fcc7db1 | 11786 | solitary backslashes, as they tickle a bug in the HP C compiler. |
daa33def | 11787 | |
9a86cdb9 PE |
11788 | * tests/glr-regr1.at (Badly Collapsed GLR States): Avoid // |
11789 | comments, since they're not portable. Use GNU coding style. | |
11790 | ||
9c1e26bd AD |
11791 | 2002-11-13 Akim Demaille <akim@epita.fr> |
11792 | ||
11793 | * data/yacc.c: Leave bigger chunks of quoted text. | |
11794 | (YYDSYMPRINTF): New. | |
11795 | Use it to report symbol activities. | |
11796 | * data/glr.c (YYDSYMPRINTF): New. | |
11797 | Use it. | |
11798 | ||
87f721cc PE |
11799 | 2002-11-12 Paul Eggert <eggert@twinsun.com> |
11800 | ||
11801 | Version 1.75b. | |
11802 | ||
11803 | * data/glr.c (yydoAction): Return YYRESULTTAG, not int. | |
11804 | (yyglrReduce): Return yyok, not 0. | |
11805 | This should avoid the enumerated-type warnings reported | |
464c6927 | 11806 | by Nelson H. F. Beebe in |
161a71f3 | 11807 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00057.html>. |
87f721cc PE |
11808 | |
11809 | * lib/bbitset.h (BITSET_INLINE): Remove. | |
11810 | * lib/bitset.h [! BITSET_INLINE]: Remove. | |
11811 | (bitset_set, bitset_reset, bitset_test): Rename local vars | |
11812 | to avoid shadowing warnings by GCC. | |
11813 | ||
11814 | * data/glr.c (inline): Remove #define. It's the user's | |
11815 | responsibility to #define it away, just like 'const'. | |
464c6927 | 11816 | This fixes one of the bugs reported by Nelson H. F. Beebe in |
161a71f3 | 11817 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00058.html>. |
18b519c0 | 11818 | |
87f721cc PE |
11819 | * Makefile.maint (po-check): Scan .l and .y files instead of the |
11820 | .c and the .h files that they generate. This fixes the bug | |
11821 | reported by Tim Van Holder in: | |
161a71f3 | 11822 | <http://lists.gnu.org/archive/html/bison-patches/2002-11/msg00062.html> |
87f721cc PE |
11823 | Look for N_ as well as for _. Try to avoid matching #define for |
11824 | N_ and _. | |
11825 | * po/POTFILES.in: Remove src/parse-gram.c, src/scan-gram.c, | |
11826 | src/system.h. Add src/parse-gram.y, src/scan-gram.l. | |
11827 | * src/scan-gram.l: Revamp regular expressions so that " and ' | |
11828 | do not confuse xgettext. | |
11829 | ||
11830 | * src/struniq.h (struniq_new): Do not declare the return type | |
11831 | to be 'const'; this violates the C standard. | |
11832 | * src/struniq.c (struniq_new): Likewise. | |
11833 | ||
be14ade5 AD |
11834 | 2002-11-12 Albert Chin-A-Young <china@thewrittenword.com> |
11835 | ||
11836 | * src/Makefile.am (LDADD): Link $(LIBINTL) last to avoid the | |
11837 | duplicate definition of optind on Tru64 UNIX 4.0D with the Compaq | |
11838 | linker. | |
11839 | ||
05291fbc AD |
11840 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11841 | ||
11842 | * Makefile.maint: Sync with Autoconf: | |
11843 | (local_updates): New. | |
11844 | ||
1f5fd52e AD |
11845 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11846 | ||
11847 | * po/POTFILES.in (src/lalr.c, src/state.c): Remove | |
11848 | ||
283f1e64 AD |
11849 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11850 | ||
11851 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Display the | |
11852 | locations. | |
11853 | ||
886b69d1 AD |
11854 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11855 | ||
11856 | * data/c.m4 (b4_yysymprint_generate): Pass *yyvaluep to YYPRINT, | |
11857 | not yyvalue. | |
11858 | ||
3df37415 AD |
11859 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11860 | ||
11861 | * tests/actions.at (AT_CHECK_PRINTER_AND_DESTRUCTOR): New. | |
11862 | Use it to test the GLR parser. | |
11863 | ||
7bd6c77e AD |
11864 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11865 | ||
11866 | * tests/regression.at (input.y): s/YYEOF/MYEOF/, as the skeleton | |
11867 | defines it. | |
11868 | * data/glr.c (yystos): New. | |
11869 | (b4_yysymprint_generate, b4_yydestruct_generate): Invoke. | |
11870 | (YYDSYMPRINT): New. | |
11871 | (yyval): Don't define it, it is handled via M4. | |
11872 | (yyrecoverParseError): Free verbosely the discarded symbols. | |
11873 | * data/yacc.c (yysymprint): Remove, rather... | |
11874 | (b4_yysymprint_generate): invoke. | |
11875 | * data/c.m4 (b4_yysymprint_generate): New. | |
11876 | Accept pointers as arguments, as opposed to the version from | |
11877 | yacc.c. | |
11878 | (b4_yydestruct_generate): Likewise. | |
11879 | * tests/cations.at (Printers and Destructors): Use Bison directives | |
11880 | instead of CPP macros. | |
11881 | Don't rely on internal details. | |
11882 | ||
b0400cc6 AD |
11883 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11884 | ||
11885 | * data/c.m4 (b4_yydestruct_generate, b4_symbol_actions): New. | |
11886 | * data/yacc.c: Rename yychar1 as yytoken, as in glr.c. | |
11887 | Don't work on yychar (i.e., do set it to YYEMPTY, don't match | |
11888 | it against YYEMPTY and so forth), work on yytoken (i.e., set | |
11889 | it to YYEMPTY etc.). | |
11890 | (yydestruct): Replace with a b4_yydestruct_generate invocation. | |
11891 | (b4_symbol_actions): Remove. | |
11892 | * data/glr.c (YYTRANSLATE): As for yacc.c, if negative, it stands | |
11893 | for 0, end-of-input. | |
11894 | ||
72f889cc AD |
11895 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11896 | ||
11897 | * doc/bison.texinfo (Destructor Decl): New. | |
11898 | ||
b1ae9233 AD |
11899 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11900 | ||
11901 | * src/tables.c (tables_generate): Use free for pointers that | |
11902 | cannot be NULL, not XFREE. | |
11903 | (pack_vector): Use assert, not fatal, for bound violations. | |
11904 | * src/state.c (state_new): Likewise. | |
11905 | * src/reader.c (reader): Likewise. | |
11906 | * src/lalr.c (set_goto_map): Likewise. | |
72f889cc | 11907 | * src/location.h (LOCATION_PRINT): If first_line is 0, just issue |
b1ae9233 AD |
11908 | the file name. |
11909 | ||
7ec2d4cd AD |
11910 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11911 | ||
11912 | * src/scan-gram.l, src/reader.h (scanner_last_string_free): | |
11913 | Restore. | |
11914 | * src/scan-gram.l (last_string): Is global to the file, not to | |
11915 | yylex. | |
11916 | * src/parse-gram.y (input): Don't append the epilogue here, | |
11917 | (epilogue.opt): do it here, and free the scanner's obstack. | |
11918 | * src/reader.c (epilogue_set): Rename as... | |
11919 | (epilogue_augment): this. | |
11920 | * data/c.m4 (b4_epilogue): Defaults to empty. | |
11921 | ||
573a6cd3 AD |
11922 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11923 | ||
11924 | * src/getargs.c (long_options): Remove duplicates. | |
11925 | * src/vmsgetargs.c, src/build.com, src/bison.cld, src/vmshlp.mar: | |
11926 | Remove. | |
11927 | * doc/bison.rnh: Remove. | |
11928 | * doc/bison.texinfo (VMS Invocation): Remove. | |
11929 | ||
95612cfa AD |
11930 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11931 | ||
11932 | * src/struniq.h, src/struniq.c (struniq_t): Is const. | |
11933 | (STRUNIQ_EQ, struniq_assert, struniq_assert_p): New. | |
11934 | ||
11935 | Use struniq for symbols. | |
11936 | ||
11937 | * src/symtab.h (symbol_t): The tag member is a struniq. | |
11938 | (symbol_type_set): Adjust. | |
11939 | * src/symtab.c (symbol_new): Takes a struniq. | |
11940 | (symbol_free): Don't free the tag member. | |
11941 | (hash_compare_symbol_t, hash_symbol_t): Rename as... | |
11942 | (hash_compare_symbol, hash_symbol): these. | |
11943 | Use the fact that tags as struniqs. | |
11944 | (symbol_get): Use struniq_new. | |
11945 | * src/symlist.h, src/symlist.c (symbol_list_n_type_name_get): | |
11946 | Returns a strniq. | |
11947 | * src/reader.h (merger_list, grammar_currentmerge_set): The name | |
11948 | and type members are struniqs. | |
11949 | * src/reader.c (get_merge_function) | |
11950 | (grammar_current_rule_merge_set): Adjust. | |
11951 | (TYPE, current_type): Are struniq. | |
11952 | ||
11953 | Use struniq for file names. | |
11954 | ||
11955 | * src/files.h, src/files.c (infile): Split into... | |
11956 | (grammar_file, current_file): these. | |
11957 | * src/scan-gram.c (YY_USER_INIT, handle_syncline): Adjust. | |
11958 | * src/reduce.c (reduce_print): Likewise. | |
11959 | * src/getargs.c (getargs): Likewise. | |
11960 | * src/complain.h, src/complain.c: Likewise. | |
11961 | * src/main.c (main): Call struniqs_new early enough to use it for | |
11962 | file names. | |
11963 | Don't free the input file name. | |
11964 | ||
3e6656f9 AD |
11965 | 2002-11-12 Akim Demaille <akim@epita.fr> |
11966 | ||
11967 | * src/symtab.c (symbol_free): Remove dead deactivated code: | |
11968 | type_name are properly removed. | |
11969 | Don't use XFREE to free items that cannot be NULL. | |
11970 | * src/struniq.h, src/struniq.c: New. | |
11971 | * src/main.c (main): Initialize/free struniqs. | |
11972 | * src/parse-gram.y (%union): Add astruniq member. | |
11973 | (yyprint): Adjust. | |
11974 | * src/scan-gram.l (<{tag}>): Return a struniq. | |
11975 | Free the obstack bit that used to store it. | |
11976 | * src/symtab.h (symbol_t): The 'type_name' member is a struniq. | |
11977 | ||
7672019c PE |
11978 | 2002-11-11 Paul Eggert <eggert@twinsun.com> |
11979 | ||
11980 | Revamp to fix many (but not all) of the C- and M4-related quoting | |
11981 | problems. Among other things, this fixes the Bison bug reported | |
11982 | by Jan Hubicka when processing the Bash grammar; see: | |
161a71f3 | 11983 | <http://lists.gnu.org/archive/html/bison-patches/2002-11/msg00039.html> |
7672019c PE |
11984 | |
11985 | Use new @ escapes consistently. Represent brackets with @{ and @} | |
11986 | rather than @<:@ and @:>@, since this works a bit better with dumb | |
11987 | editors like vi. Represent @ with @@, since @ is now consistently | |
11988 | an escape. Use @oline@ and @ofile@ rather than __oline__ and | |
11989 | __ofile__, to avoid unexpected expansions. Similarly, use @output | |
11990 | rather than #output. | |
11991 | ||
11992 | * data/c.m4 (b4_copyright): Omit file name from comment, since | |
11993 | the file name could contain "*/". | |
11994 | (b4_synclines_flag): Don't quote the 2nd argument; it should already | |
11995 | be quoted. All uses changed. | |
11996 | ||
11997 | * data/glr.c: Use new @ escapes consistently. | |
11998 | (b4_input_suffix, b4_output_parser_suffix, b4_output_parser_name, | |
11999 | b4_output_header_suffix, b4_output_header_name, b4_header_guard): | |
12000 | Remove, since they couldn't handle arbitrary characters in file | |
12001 | names. | |
12002 | * data/lalr1.cc: Likewise. | |
12003 | * data/yacc.c: Likewise. | |
12004 | ||
12005 | * src/files.c (output_infix): Remove; all uses removed. | |
12006 | * src/files.h: Likewise. | |
12007 | ||
12008 | * data/glr.c: Remove use of "#ifdef b4_header_guard", since it | |
12009 | mishandled funny characters in file names, and anyway it isn't | |
12010 | needed any more. | |
12011 | * data/yacc.c: Likewise. | |
12012 | * data/lalr1.cc: Use YYSLP_NEEDED instead of b4_header_guard. | |
12013 | ||
12014 | * data/glr.c (YYSTYPE_IS_TRIVIAL): Define when the .h file would. | |
12015 | * data/yacc.c: Likewise. | |
12016 | ||
12017 | * src/muscle_tab.c: Include quotearg.h, since we need to quote C | |
12018 | strings now. | |
12019 | (muscle_init): Quote filename as a C string. | |
12020 | * src/muscle_tab.h (MUSCLE_GROW_STRING_PAIR): Remove; unused. | |
12021 | (MUSCLE_OBSTACK_SGROW, MUSCLE_INSERT_C_STRING): New macros. | |
12022 | * src/output.c (escaped_file_name_output): New function. | |
12023 | (prepare_symbols): Quote tokens for M4. | |
12024 | (prepare): Don't insert output_infix, output_prefix, | |
12025 | output_parser_name, output_header_name; this is now down by scan-skel. | |
12026 | Insert skeleton as a C string. | |
12027 | ||
12028 | * src/output.c (user_actions_output, symbol_destructors_output, | |
12029 | symbol_printers_output): Quote filenames for C and M4. | |
12030 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
12031 | ||
12032 | * src/scan-gram.l (<SC_CHARACTER>): Don't worry about any backslash | |
12033 | escapes other than \\ and \'; this simplifies the code. | |
12034 | (<SC_STRING>): Likewise, for \\ and \". | |
12035 | (<SC_COMMENT,SC_LINE_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE, | |
12036 | SC_PROLOGUE,SC_EPILOGUE>): Escape $ and @, too. | |
12037 | Use new escapes @{ and @} for [ and ]. | |
12038 | ||
12039 | * src/scan-skel.l (yylineno, yyoutname): Remove static vars, replacing | |
12040 | them with auto vars. | |
12041 | Switch to new escape scheme, where @ is the escape character uniformly. | |
12042 | Abort if a stray escape character is found. Avoid unbounded input | |
12043 | buffer when parsing non-escaped text. | |
12044 | ||
12045 | * tests/input.at (Torturing the Scanner): Add tests that @oline@, | |
12046 | __oline__, #output, $@, and @{ do not have unintended meanings. | |
12047 | ||
acea4f3b PE |
12048 | 2002-11-09 Paul Eggert <eggert@twinsun.com> |
12049 | ||
12050 | Fix the test failure due to GCC warnings described in | |
161a71f3 | 12051 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00000.html>. |
acea4f3b PE |
12052 | * data/glr.c (yyis_pact_ninf, yyis_table_ninf): New macros, which |
12053 | evaluate to 0 if it's impossible for NINF to be in the respective | |
12054 | table. | |
12055 | (yygetLRActions, yyrecoverParseError): Use them. | |
12056 | ||
12057 | * src/scan-gram.l (unexpected_end_of_file): Fix bug: columns were | |
12058 | counted in the token inserted at end of file. Now takes | |
12059 | location_t *, not location_t, so that the location can be | |
12060 | adjusted. All uses changed. | |
12061 | ||
12062 | * tests/regression.at (Invalid inputs): Adjust wording in | |
12063 | diagnostic to match the new behavior. | |
12064 | ||
12065 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR, | |
12066 | AT_DATA_HORIZONTAL_GRAMMAR, AT_DATA_LOOKAHEADS_GRAMMAR, | |
12067 | AT_DATA_STACK_TORTURE): Replace `assert (x);' with `if (! (x)) | |
12068 | abort ();'. This reduces the runtime of the "Many lookaheads" | |
12069 | test from 27.6 to 2.7 minutes on a 440 MHz Ultrasparc III running | |
12070 | GCC 3.2. | |
12071 | ||
20ef1ad5 PE |
12072 | 2002-11-07 Paul Eggert <eggert@twinsun.com> |
12073 | ||
12074 | * src/parse-gram.y (CHARACTER): Remove unused token. | |
12075 | All uses removed. | |
12076 | ||
12077 | * src/scan-gram.l: Remove stack option. We no longer use the | |
12078 | stack, since the stack was never deeper than 1; instead, use the | |
12079 | new auto var c_context to record the stacked value. | |
12080 | ||
12081 | Remove nounput option. At an unexpected end of file, we now unput | |
12082 | the minimal input necessary to end cleanly; this simplifies the | |
12083 | code. | |
12084 | ||
12085 | Avoid unbounded token sizes where this is easy. | |
12086 | ||
12087 | (unexpected_end_of_file): New function. | |
12088 | Use it to systematize the error message on unexpected EOF. | |
12089 | (last-string): Now auto, not static. | |
12090 | (YY_OBS_FREE): Remove unnecessary do while (0) wrapper. | |
12091 | (scanner_last_string_free): Remove; not used. | |
12092 | (percent_percent_count): Move decl to just before use. | |
12093 | (SC_ESCAPED_CHARACTER): Return ID at unexpected end of file, | |
12094 | not the (never otherwised-used) CHARACTER. | |
12095 | ||
93724f13 AD |
12096 | 2002-11-07 Akim Demaille <akim@epita.fr> |
12097 | ||
12098 | Let yyerror always receive the msg as last argument, so that | |
12099 | yyerror can be variadic. | |
12100 | ||
12101 | * data/yacc.c (b4_yyerror_args): New. | |
12102 | Use it when calling yyerror. | |
12103 | * data/glr.c (b4_yyerror_args, b4_lyyerror_args): New. | |
12104 | Use it when calling yyerror. | |
12105 | * doc/bison.texinfo (Error Reporting): Adjust. | |
12106 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust. | |
12107 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Adjust. | |
12108 | ||
6e40b4eb AD |
12109 | 2002-11-06 Akim Demaille <akim@epita.fr> |
12110 | ||
12111 | #line should have quoted strings. | |
12112 | Ideally, this should be done by m4_quotearg. | |
12113 | ||
12114 | * src/scan-skel.l: Include quotearg.h. | |
12115 | Quote __ofile__. | |
12116 | * src/output.c (symbol_printers_output) | |
12117 | (symbol_destructors_output): Quote the file name. | |
12118 | ||
2dfbfc12 AD |
12119 | 2002-11-06 Akim Demaille <akim@epita.fr> |
12120 | ||
12121 | * tests/regression.at (Invalid inputs): Adjust to the recent | |
12122 | messages. | |
12123 | ||
437c2d80 AD |
12124 | 2002-11-06 Akim Demaille <akim@epita.fr> |
12125 | ||
12126 | Restore --no-lines. | |
12127 | Reported by Jim Kent. | |
12128 | ||
12129 | * data/c.m4 (b4_syncline): New. | |
12130 | * data/glr.c, data/yacc.c, data/lalr1.cc: Use it. | |
12131 | * src/reader.c (prologue_augment, epilogue_set): Use b4_syncline. | |
12132 | * src/output.c (user_actions_output): Likewise. | |
12133 | (prepare): Define 'b4_synclines_flag'. | |
2dfbfc12 | 12134 | * src/muscle_tab.c (muscle_init): Don't define b4_linef. |
437c2d80 | 12135 | |
900c5db5 AD |
12136 | 2002-11-06 Akim Demaille <akim@epita.fr> |
12137 | ||
12138 | * src/main.c (main): Free `infile'. | |
12139 | * src/scan-gram.l (handle_syncline): New. | |
12140 | Recognize `#line'. | |
12141 | * src/output.c (user_actions_output, symbol_destructors_output) | |
12142 | (symbol_printers_output): Use the location's file name, not | |
12143 | infile. | |
12144 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
12145 | ||
e183b123 | 12146 | 2002-11-05 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
51b4a04c | 12147 | |
e183b123 | 12148 | * src/tables.c (matching_state): Don't allow states to match if |
51b4a04c | 12149 | either has GLR conflict entries. |
e183b123 | 12150 | |
193eb6b7 PE |
12151 | 2002-11-05 Paul Eggert <eggert@twinsun.com> |
12152 | ||
e183b123 PE |
12153 | * src/scan-gram.l: Use more accurate diagnostics, e.g. |
12154 | "integer out of range" rather than "invalid value". | |
12155 | * tests/input.at (Invalid $n, Invalid @n): Change expected wording | |
12156 | accordingly. | |
12157 | ||
193eb6b7 PE |
12158 | Scan <% and %> digraphs in C code as POSIX 1003.1-2001 requires. |
12159 | Also, remove one static variable in the scanner. | |
12160 | ||
12161 | * src/scan-gram.l (braces_level): Now auto, not static. | |
12162 | Initialize to zero if the compiler is being picky. | |
12163 | (INITIAL): Clear braces_level instead of incrementing it. | |
12164 | (SC_BRACED_CODE): Treat <% and %> as { and } when inside C code, | |
12165 | as POSIX 1003.1-2001 requires. | |
12166 | * src/system.h (IF_LINT): New macro, taken from coreutils. | |
12167 | * configure.ac: Define "lint" if --enable-gcc-warnings. | |
12168 | ||
29c01725 AD |
12169 | 2002-11-05 Akim Demaille <akim@epita.fr> |
12170 | ||
12171 | * src/scan-gram.l: When it starts with `%', complain about the | |
12172 | whole directive, not just that `invalid character: %'. | |
12173 | ||
8aeac3ca AD |
12174 | 2002-11-04 Akim Demaille <akim@epita.fr> |
12175 | ||
12176 | * Makefile.maint: Update from Autoconf. | |
12177 | (update, cvs-update, po-update, do-po-update): New. | |
12178 | ||
793a58bb AD |
12179 | 2002-11-04 Akim Demaille <akim@epita.fr> |
12180 | ||
12181 | * tests/glr-regr1.at (Badly Collapsed GLR States): Prototype yylex | |
12182 | and yyerror. | |
12183 | Have yyerror `use' its arguments. | |
12184 | * tests/calc.at (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF | |
12185 | returns true when location & yacc & pure & parse-param. | |
12186 | (_AT_DATA_CALC_Y): Let yyerror ``use'' its arguments. | |
12187 | ||
c4d720cd AD |
12188 | 2002-11-04 Akim Demaille <akim@epita.fr> |
12189 | ||
12190 | * src/location.h (LOCATION_PRINT): Use quotearg slot 3 to avoid | |
12191 | clashes. | |
12192 | * src/scan-gram.l: Use [\'] instead of ['] to pacify | |
12193 | font-lock-mode. | |
12194 | Use complain_at. | |
12195 | Use quote, not quote_n since LOCATION_PRINT no longer uses the | |
12196 | slot 0. | |
12197 | ||
613a0dc5 PE |
12198 | 2002-11-03 Paul Eggert <eggert@twinsun.com> |
12199 | ||
12200 | * src/reader.c (get_merge_function, grammar_current_rule_check): | |
12201 | Use consistent diagnostics for reporting type name clashes. | |
12202 | Quote the types with <>, for consistency with Yacc. | |
12203 | * tests/input.at (Type Clashes): Adjust to diagnostic changes. | |
12204 | ||
2a8d363a AD |
12205 | 2002-11-03 Akim Demaille <akim@epita.fr> |
12206 | ||
12207 | * data/c.m4 (b4_identification, b4_user_args, b4_parse_param): | |
12208 | New. | |
12209 | * data/yacc.m4 (b4_pure_args, b4_Pure_args): New. | |
12210 | (b4_parse_param): Remove. | |
12211 | Use b4_identification. | |
12212 | Propagate b4_pure_args where needed to pass them to yyerror. | |
12213 | * data/glr.m4 (b4_parse_param): Remove. | |
12214 | (b4_user_formals, b4_pure_args, b4_pure_formals, b4_lpure_args) | |
12215 | (b4_lpure_formals): New. | |
12216 | Use b4_identification. | |
12217 | (YY_USER_FORMALS, YY_USER_ARGS): Remove, replaced by | |
12218 | b4_user_formals and b4_user_args. | |
12219 | (yyexpandGLRStack, yyFail, yyaddDeferredAction, yyglrShiftDefer) | |
12220 | (yyreportAmbiguity): When using a pure parser, also need | |
12221 | the location, and the parse-params. | |
12222 | Adjust callers. | |
12223 | (yyuserAction, yyglrShift, yyreportParseError, yyrecoverParseError): | |
12224 | When using a pure parser, also need the parse-params. | |
12225 | Adjust callers. | |
12226 | * tests/calc.at: Test pure (%pure-parser) and absolutely pure | |
12227 | (%pure-parser + %parse-param) LALR and GLR parsers. | |
12228 | (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): New, define AT_PARAM_IF, | |
12229 | AT_LOCATION_IF, AT_PURE_IF, AT_GLR_IF, AAT_PURE_AND_LOC_IF, | |
12230 | AT_GLR_OR_PARAM_IF, AT_YYERROR_ARG_LOC_IF, AT_YYERROR_SEES_LOC_IF. | |
12231 | (_AT_DATA_CALC_Y): Equip for purity of yyerror. | |
12232 | (_AT_CHECK_CALC_ERROR): Use AT_YYERROR_SEES_LOC_IF. | |
12233 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Equip for yyerror purity. | |
12234 | * doc/bison.texinfo: Untabify the whole file. | |
12235 | (Parser Function): Document %parse-param, deprecate YYPARSE_PARAM. | |
12236 | (Pure Calling): Document %lex-param, deprecate YYLEX_PARAM. | |
12237 | (Error Reporting): Adjust to these new directives. | |
12238 | Document %error-verbose, deprecate YYERROR_VERBOSE. | |
12239 | ||
9e32add8 AD |
12240 | 2002-11-03 Akim Demaille <akim@epita.fr> |
12241 | ||
12242 | * tests/calc.at: Change all the AT_CHECK_CALC_LALR and | |
12243 | AT_CHECK_CALC_GLR invocations to use % directives, instead of | |
12244 | command line options. | |
12245 | * tests/cxx-type.at: Formatting changes. | |
12246 | ||
b02d90a5 PE |
12247 | 2002-11-03 Paul Eggert <eggert@twinsun.com> |
12248 | ||
12249 | * src/scan-gram.l: Revamp to fix POSIX incompatibilities, | |
12250 | to count columns correctly, and to check for invalid inputs. | |
9e32add8 | 12251 | |
b02d90a5 PE |
12252 | Use mbsnwidth to count columns correctly. Account for tabs, too. |
12253 | Include mbswidth.h. | |
12254 | (YY_USER_ACTION): Invoke extend_location rather than LOCATION_COLUMNS. | |
12255 | (extend_location): New function. | |
12256 | (YY_LINES): Remove. | |
12257 | ||
12258 | Handle CRLF in C code rather than in Lex code. | |
12259 | (YY_INPUT): New macro. | |
12260 | (no_cr_read): New function. | |
12261 | ||
12262 | Scan UCNs, even though we don't fully handle them yet. | |
12263 | (convert_ucn_to_byte): New function. | |
12264 | ||
12265 | Handle backslash-newline correctly in C code. | |
12266 | (SC_LINE_COMMENT, SC_YACC_COMMENT): New states. | |
12267 | (eols, blanks): Remove. YY_USER_ACTION now counts newlines etc.; | |
12268 | all uses changed. | |
12269 | (tag, splice): New EREs. Do not allow NUL or newline in tags. | |
12270 | Use {splice} wherever C allows backslash-newline. | |
12271 | YY_STEP after space, newline, vertical-tab. | |
12272 | ("/*"): BEGIN SC_YACC_COMMENT, not yy_push_state (SC_COMMENT). | |
9e32add8 | 12273 | |
b02d90a5 PE |
12274 | (letter, id): Don't assume ASCII; e.g., spell out a-z. |
12275 | ||
12276 | ({int}, handle_action_dollar, handle_action_at): Check for integer | |
12277 | overflow. | |
9e32add8 | 12278 | |
b02d90a5 PE |
12279 | (YY_STEP): Omit trailing semicolon, so that it's more like C. |
12280 | ||
12281 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>): Allow \0 and \00 | |
12282 | as well as \000. Check for UCHAR_MAX, not 255. | |
12283 | Allow \x with an arbitrary positive number of digits, as in C. | |
12284 | Check for overflow here. | |
12285 | Allow \? and UCNs, for compatibility with C. | |
12286 | ||
12287 | (handle_symbol_code_dollar): Use quote_n slot 1 to avoid collision | |
12288 | with quote slot used by complain_at. | |
12289 | ||
12290 | * tests/input.at: Add tests for backslash-newline, m4 quotes | |
12291 | in symbols, long literals, and funny escapes in strings. | |
12292 | ||
12293 | * configure.ac (jm_PREREQ_MBSWIDTH): Add. | |
12294 | * lib/Makefile.am (libbison_a_SOURCES): Add mbswidth.h, mbswidth.c. | |
12295 | * lib/mbswidth.h, lib/mbswidth.c: New files, from GNU gettext. | |
12296 | * m4/Makefile.am (EXTRA_DIST): Add mbswidth.m4. | |
12297 | * m4/mbswidth.m4: New file, from GNU coreutils. | |
12298 | ||
12299 | * doc/bison.texinfo (Grammar Outline): Document // comments. | |
12300 | (Symbols): Document that trigraphs have no special meaning in Bison, | |
12301 | nor is backslash-newline allowed. | |
12302 | (Actions): Document that trigraphs have no special meaning. | |
12303 | ||
12304 | * src/location.h (LOCATION_COLUMNS, LOCATION_LINES): Remove; | |
12305 | no longer used. | |
12306 | ||
12307 | 2002-11-02 Paul Eggert <eggert@twinsun.com> | |
12308 | ||
12309 | * src/reader.c: Don't include quote.h; not needed. | |
12310 | (get_merge_function): Reword warning to be consistent with | |
12311 | type clash diagnostic in grammar_current_rule_check. | |
12312 | ||
12313 | * lib/quotearg.c (quotearg_buffer_restyled): Fix off-by-two | |
12314 | bug in trigraph handling. | |
12315 | ||
12316 | * src/output.c (prepare_symbols): When printing token names, | |
12317 | escape "[" as "@<:@" and likewise for "]". | |
12318 | ||
12319 | * src/system.h (errno): Remove declaration, as we are now | |
12320 | assuming C89 or better, and C89 guarantees errno. | |
12321 | ||
762b212b PE |
12322 | 2002-10-30 Paul Eggert <eggert@twinsun.com> |
12323 | ||
12324 | * lib/bitset_stats.c (bitset_stats_read, bitset_stats_write): | |
12325 | Check for close failures. | |
12326 | * src/files.h (xfclose): Return void, not int, since it always | |
12327 | returned zero. | |
12328 | * src/files.c (xfclose): Likewise. Report I/O error if ferror | |
12329 | indicates one. | |
12330 | * src/output.c (output_skeleton): Use xfclose rather than fclose | |
12331 | and ferror. xfclose now checks ferror. | |
12332 | ||
12333 | * data/glr.c (YYLEFTMOST_STATE): Remove. | |
12334 | (yyreportTree): Use a stack-based leftmost state. This avoids | |
12335 | our continuing battles with bogus warnings about initializers. | |
12336 | ||
56100c60 AD |
12337 | 2002-10-30 Akim Demaille <akim@epita.fr> |
12338 | ||
12339 | * src/system.h: Don't use #ifdef/#ifndef on HAVE_ values, only | |
12340 | #if. | |
12341 | ||
51b4a04c PH |
12342 | 2002-10-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
12343 | ||
12344 | * tests/glr-regr1.at: New test for reported regressions. | |
12345 | * tests/testsuite.at: Add glr-regr1.at test. | |
12346 | * tests/Makefile.am: Add glr-regr1.at test. | |
e183b123 | 12347 | |
bf1ebda2 PE |
12348 | 2002-10-24 Paul Eggert <eggert@twinsun.com> |
12349 | ||
5c16c6b1 PE |
12350 | Version 1.75a. |
12351 | ||
bf1ebda2 PE |
12352 | * tests/calc.at (_AT_DATA_CALC_Y): Remove unused strcat declaration. |
12353 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Include stdlib.h, since | |
12354 | we use malloc. Don't assume 'A' through 'Z' are contiguous. | |
12355 | Don't assume strdup exists; POSIX says its an XSI extension. | |
12356 | Check for buffer overflow on input. | |
12357 | ||
b526ee61 AD |
12358 | 2002-10-24 Akim Demaille <akim@epita.fr> |
12359 | ||
12360 | * src/output.c (output_skeleton): Don't disable M4sugar comments | |
12361 | too soon: it results in comments being expanded. | |
12362 | * data/yacc.c, data/glr.c, data/lalr1.cc: Do it right before the | |
12363 | first output. | |
12364 | ||
f1886bb2 AD |
12365 | 2002-10-24 Akim Demaille <akim@epita.fr> |
12366 | ||
12367 | * data/yacc.c (m4_int_type): New. | |
12368 | * data/c.m4 (m4_int_type): Don't use yysigned_char, but `signed | |
12369 | char' as only yacc.c wants K&R portability. | |
12370 | * data/glr.c (yysigned_char): Remove. | |
12371 | * data/lalr1.cc: Rename the trailing b4_name as b4_parser_class_name. | |
12372 | Reported by Quoc Peyrot. | |
12373 | ||
c5576256 PE |
12374 | 2002-10-23 Paul Eggert <eggert@twinsun.com> |
12375 | ||
12376 | * src/main.c (main): With --trace=time, report times even if a | |
12377 | non-fatal error occurs. Formerly, the times were reported in some | |
12378 | such cases but not in others. | |
12379 | * src/reader.c (reader): Just return if a complaint has been issued, | |
12380 | instead of exiting, so that 'main' can report times. | |
12381 | ||
27b0ffea AD |
12382 | 2002-10-22 Akim Demaille <akim@epita.fr> |
12383 | ||
12384 | * src/system.h: Include sys/types. | |
12385 | Reported by Bert Deknuydt. | |
12386 | ||
223a7883 PE |
12387 | 2002-10-23 Paul Eggert <eggert@twinsun.com> |
12388 | ||
12389 | * configure.ac (AC_PROG_LEX): Use instead of AM_PROG_LEX. | |
12390 | Suggested by Art Haas. | |
12391 | ||
12392 | 2002-10-22 Paul Eggert <eggert@twinsun.com> | |
12393 | ||
12394 | * src/complain.c (exit) [! (STDC_HEADERS || _LIBC)]: Remove exit | |
12395 | decl; not needed any more. | |
12396 | * src/main.c (main): Use return to exit, undoing yesterday's change. | |
12397 | The last OS that we could find where this wouldn't work is | |
12398 | SunOS 3.5, and that's too old to worry about now. | |
12399 | ||
12400 | * data/glr.c (struct yyltype): Define members even when not | |
12401 | doing locations. This is more consistent with yacc.c, and it | |
12402 | works around the following bug reports: | |
161a71f3 PE |
12403 | http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00106.html |
12404 | http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00111.html | |
27b0ffea | 12405 | |
223a7883 PE |
12406 | * doc/bison.texinfo: Minor spelling and typographical fixes. Use |
12407 | @acronym consistently. Standardize on "Yacc" instead of "YACC", | |
12408 | "Algol" instead of "ALGOL". Give a bit more history about BNF. | |
12409 | ||
8b76775a AD |
12410 | 2002-10-22 Akim Demaille <akim@epita.fr> |
12411 | ||
12412 | * data/README: New. | |
12413 | ||
6db10d14 PE |
12414 | 2002-10-21 Paul Eggert <eggert@twinsun.com> |
12415 | ||
12416 | Be consistent about 'bool'; the old code used an enum in one | |
12417 | module and an int in another, and this violates the C standard. | |
12418 | * m4/stdbool.m4: New file, from coreutils 4.5.3. | |
12419 | * configure.ac (AC_HEADER_STDBOOL): Add. | |
12420 | * m4/Makefile.am (EXTRA_DIST): Add stdbool.m4. | |
12421 | * src/muscle_tab.c (hash_compare_muscles): (a ? FALSE : TRUE) -> (! a) | |
12422 | * src/symtab.c (hash_compare_symbol_t): Likewise. | |
12423 | * src/system.h (bool, false, true): Use a definition consistent | |
12424 | with ../lib/hash.c. All uses changed. | |
12425 | ||
12426 | * src/complain.c (warning_issued): Renamed from warn_message_count, | |
12427 | so that we needn't worry about integer overflow (!). | |
12428 | Now of type bool. All uses changed. | |
12429 | (complaint_issued): Renamed from complain_message_count; likewise. | |
12430 | ||
12431 | * src/main.c (main): Use exit to exit with failure. | |
27b0ffea | 12432 | |
6db10d14 PE |
12433 | * src/complain.c (fatal_at, fatal): Use EXIT_FAILURE and EXIT_SUCCESS |
12434 | rather than 1 and 0. | |
12435 | * src/main.c (main): Likewise. | |
12436 | * src/getargs.c (getargs): Likewise. | |
12437 | * src/reader.c (reader): Likewise. | |
12438 | ||
12439 | * src/getarg.c (getargs): Remove duplicate code for | |
12440 | "Try `bison --help'". | |
12441 | ||
12442 | * src/files.c (xfopen, xfclose): Use EXIT_FAILURE rather than 2. | |
12443 | What was that "2" for? | |
12444 | ||
12445 | * src/complain.h (fatal, fatal_at): Add __attribute__((__noreturn__)). | |
12446 | * src/getargs.c (usage): Likewise. | |
12447 | ||
12448 | * src/getargs.c (getargs): When there are too few operands, report | |
12449 | the last one. When there are too many, report the first extra | |
12450 | one. This is how diffutils does it. | |
12451 | ||
92a060fd PE |
12452 | 2002-10-20 Paul Eggert <eggert@twinsun.com> |
12453 | ||
12454 | Remove K&R vestiges. | |
12455 | * configure.ac (AC_C_CONST, AM_C_PROTOTYPES): Remove. | |
12456 | * src/complain.c (VA_START): Remove. Assume prototypes. | |
12457 | (vfprintf) [! (HAVE_VPRINTF || defined vfprintf)]: New macro. | |
12458 | (private_strerror, warn_at, warn, complain_at, complain, fatal_at, | |
12459 | fatal): Assume prototypes. | |
12460 | * src/complain.h: Assume prototypes. | |
12461 | * src/system.h (PARAMS): Remove. | |
12462 | Include <limits.h> unconditionally, since it's guaranteeed even | |
12463 | for a freestanding C89 compiler. | |
12464 | (SHRT_MIN, SHRT_MAX): Remove, since C89 guarantees them. | |
12465 | * src/vmsgetargs.c (getargs, cli_present, cli_get_value): Prototype. | |
8b76775a | 12466 | |
e7cb57c0 AD |
12467 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12468 | ||
12469 | * src/muscle_tab.c (muscle_grow): Remove trailing debugging code. | |
12470 | * data/glr.c (YY_USER_FORMALS, YY_USER_ARGS): New. | |
12471 | (yyuserAction, yydoAction, yyglrReduce, yyresolveValue) | |
12472 | (yyresolveStates, yyresolveAction, yyresolveStack) | |
12473 | (yyprocessOneStack): Use them. | |
12474 | (yy_reduce_print): New. | |
12475 | * tests/calc.at (_AT_DATA_CALC_Y): Exercise %parse-param. | |
12476 | ||
0245f82d AD |
12477 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12478 | ||
12479 | * data/c.m4 (b4_c_ansi_args): Recognize functions with no | |
12480 | arguments and output `void'. | |
12481 | (b4_c_function): Rename as... | |
12482 | (b4_c_function_def): this. | |
12483 | (b4_c_function_decl, b4_c_ansi_function_def) | |
12484 | (b4_c_ansi_function_decl): New. | |
12485 | Change the interpretation of the arguments: before `int, foo', now | |
12486 | `int foo, foo'. | |
12487 | * data/yacc.c (yyparse): Prototype and define thanks to these. | |
12488 | Adjust b4_c_function_def uses. | |
12489 | * data/glr.c (yyparse): Likewise, but ANSI only. | |
12490 | ||
39912f52 AD |
12491 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12492 | ||
12493 | * src/output.c (prepare): Move the definition of `tokens_number', | |
12494 | `nterms_number', `undef_token_number', `user_token_number_max' | |
12495 | to... | |
12496 | (prepare_tokens): Here. | |
12497 | (prepare_tokens): Rename as... | |
12498 | (prepare_symbols): this. | |
12499 | (prepare): Move the definition of `rules_number' to... | |
12500 | (prepare_rules): here. | |
12501 | (prepare): Move the definition of `last', `final_state_number', | |
12502 | `states_number' to... | |
12503 | (prepare_states): here. | |
12504 | * data/yacc.c, data/lalr1.cc, data/glr.c: Normalize `>' into `<'. | |
12505 | ||
20c1e2ad AD |
12506 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12507 | ||
12508 | * src/tables.h, src/tables.c, src/output.c: Comment changes. | |
12509 | ||
21964f43 AD |
12510 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12511 | ||
12512 | * data/yacc.c, data/yacc.c (b4_location_if, b4_pure_if): Move to... | |
12513 | * data/c.m4: here. | |
12514 | ||
66d30cd4 AD |
12515 | 2002-10-20 Akim Demaille <akim@epita.fr> |
12516 | ||
12517 | * src/output.c (prepare): Use MUSCLE_INSERT_STRING. | |
12518 | * src/muscle_tab.c (muscle_pair_list_grow): Rename `val as | |
12519 | `pair'. | |
12520 | (muscle_init): Move the `b4_ltype', `b4_maxdepth', `b4_initdepth', | |
12521 | `name' to... | |
12522 | * data/glr.c, data/lalr1.cc, data/yacc.c (b4_location_type) | |
12523 | (b4_stack_depth_init, b4_stack_depth_max, b4_parser_class_name): | |
12524 | These. | |
12525 | ||
95f2c9fe PE |
12526 | 2002-10-19 Paul Eggert <eggert@twinsun.com> |
12527 | ||
12528 | Do not create a temporary file, as that involves security and | |
12529 | cleanup headaches. Instead, use a pair of pipes. | |
12530 | Derived from a suggestion by Florian Krohm. | |
12531 | * lib/subpipe.c, lib/subpipe.h, m4/subpipe.m4: New files. | |
12532 | * lib/mkstemp.c, lib/readpipe.c, lib/tempname.c, m4/mkstemp.m4: Remove. | |
12533 | * configure.ac (UTILS_FUNC_MKSTEMP, jm_PREREQ_TEMPNAME): Remove. | |
12534 | (BISON_PREREQ_SUBPIPE): Add. | |
12535 | * lib/Makefile.am (libbison_a_SOURCES): Remove readpipe.c. | |
12536 | Add subpipe.h, subpipe.c. | |
12537 | * m4/Makefile.am (EXTRA_DIST): Remove mkstemp.m4. Add subpipe.m4. | |
12538 | * po/POTFILES.in: Add lib/subpipe.c. | |
12539 | * src/output.c: Include "subpipe.h". | |
12540 | (m4_invoke): Remove decl. | |
12541 | (scan_skel): New decl. | |
12542 | (output_skeleton): Use pipe rather than temporary file for m4 input. | |
12543 | Check that m4sugar.m4 is readable, to avoid deadlock. | |
12544 | Check for pipe I/O error. | |
12545 | * src/scan-skel.l (readpipe): Remove decl. | |
12546 | (scan_skel): New function, to be used in place of m4_invoke. | |
12547 | Read from stream rather than file. | |
66d30cd4 | 12548 | |
95f2c9fe PE |
12549 | * lib/timevar.c (TICKS_TO_MSEC, CLOCKS_TO_MSEC): Do not cast to |
12550 | float, as this generates a warning on Solaris 8 + GCC 3.2 with | |
12551 | --enable-gcc-warnings. Instead, divide into 1.0 rather than 1; | |
12552 | this generates a more-accurate value anyway. | |
12553 | ||
12554 | * lib/timevar.c (timervar_accumulate): Rename locals to | |
12555 | avoid confusion with similarly-named more-global. | |
12556 | * src/muscle_tab.c (muscle_pair_list_grow): Likewise. | |
12557 | ||
12558 | * src/output.c (prepare): Use xstrdup to convert char const * | |
12559 | to char *, to avoid GCC warning. | |
12560 | ||
c19988b7 AD |
12561 | 2002-10-19 Akim Demaille <akim@epita.fr> |
12562 | ||
12563 | * tests/calc.at (_AT_DATA_CALC_Y): Define VAL, LOC, LEX_FORMALS, | |
12564 | LEX_PRE_FORMALS, LEX_ARGS, LEX_PRE_ARGS, USE_LEX_ARGS. | |
12565 | Use them to have `calc.y' ready for %pure-parser. | |
12566 | * data/yacc.c (YYLEX): Pass a yylex return type to | |
12567 | b4_c_function_call. | |
12568 | ||
ae7453f2 AD |
12569 | 2002-10-19 Akim Demaille <akim@epita.fr> |
12570 | ||
12571 | Prototype support of %lex-param and %parse-param. | |
12572 | ||
12573 | * src/parse-gram.y: Add the definition of the %lex-param and | |
12574 | %parse-param tokens, plus their rules. | |
12575 | Drop the `_' version of %glr-parser. | |
12576 | Add the "," token. | |
12577 | * src/scan-gram.l (INITIAL): Scan them. | |
12578 | * src/muscle_tab.c: Comment changes. | |
12579 | (muscle_insert, muscle_find): Rename `pair' as `probe'. | |
12580 | * src/muscle_tab.h (MUSCLE_INSERT_PREFIX): Remove unused. | |
12581 | (muscle_entry_s): The `value' member is no longer const. | |
12582 | Adjust all dependencies. | |
12583 | * src/muscle_tab.c (muscle_init): Adjust: use | |
12584 | MUSCLE_INSERT_STRING. | |
12585 | Initialize the obstack earlier. | |
12586 | * src/muscle_tab.h, src/muscle_tab.c (muscle_grow) | |
12587 | (muscle_pair_list_grow): New. | |
12588 | * data/c.m4 (b4_c_function_call, b4_c_args): New. | |
12589 | * data/yacc.c (YYLEX): Use b4_c_function_call to honor %lex-param. | |
12590 | * tests/calc.at: Use %locations, not --locations. | |
12591 | (AT_CHECK_CALC_GLR): Use %glr-parser, not %glr_parser. | |
12592 | ||
0e575721 AD |
12593 | 2002-10-19 Akim Demaille <akim@epita.fr> |
12594 | ||
12595 | * src/getargs.c (usage): Take status as argument and exit | |
12596 | accordingly. | |
12597 | Report the traditional `Try ... --help' message when status != 0. | |
12598 | (usage, version): Don't take a FILE * as arg, it is pointless. | |
12599 | (getargs): When there is an incorrect number of arguments, make it | |
12600 | an error, and report it GNUlically thanks to `usage ()'. | |
12601 | ||
724ce7f5 PE |
12602 | 2002-10-18 Paul Eggert <eggert@twinsun.com> |
12603 | ||
3a781eb2 PE |
12604 | * data/glr.c (yyreportParseError): Don't assume that sprintf |
12605 | yields the length of the printed string, as this is not true | |
12606 | on SunOS 4.1.4. Reported by Peter Klein. | |
12607 | ||
724ce7f5 PE |
12608 | * tests/calc.at (_AT_DATA_CALC_Y): #undef memcmp and realloc. |
12609 | * tests/conflicts.at (%nonassoc and eof): Likewise. | |
12610 | Fixes SunOS 4.1.4 test failure reported by Peter Klein. | |
12611 | ||
473d0a75 AD |
12612 | 2002-10-17 Akim Demaille <akim@epita.fr> |
12613 | ||
12614 | * src/getargs.h (trace_e): Add trace_scan, and trace_parse. | |
12615 | * src/getargs.c (trace_types, trace_args): Adjust. | |
12616 | * src/reader.c (grammar_current_rule_prec_set) | |
12617 | (grammar_current_rule_dprec_set, grammar_current_rule_merge_set): | |
12618 | Standardize error messages. | |
12619 | And s/@prec/%prec/! | |
12620 | (reader): Use trace_flag to enable scanner/parser debugging, | |
12621 | instead of an adhoc scheme. | |
12622 | * src/scan-gram.l: Remove trailing debugging code. | |
12623 | ||
e76d2469 PE |
12624 | 2002-10-16 Paul Eggert <eggert@twinsun.com> |
12625 | ||
93e2236a PE |
12626 | * src/muscle_tab.h (MUSCLE_TAB_H_): Was misspelled as |
12627 | MUSCLE_TAB_H. | |
12628 | ||
e76d2469 PE |
12629 | * NEWS: Officially drop support for building Bison with K&R C, |
12630 | since it didn't work anyway and it's not worth worrying about. | |
12631 | * Makefile.maint (wget_files): Remove ansi2knr.c. | |
12632 | (ansi2knr.c-url_prefix): Remove. | |
12633 | * lib/.cvsignore: Remove ansi2knr, ansi2knr.*. | |
12634 | * lib/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
12635 | * src/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
12636 | ||
5bd1c419 PE |
12637 | 2002-10-15 Paul Eggert <eggert@twinsun.com> |
12638 | ||
12639 | Stop using the "enum_" trick for K&R-style function definitions; | |
12640 | it confused me, and I was the author! Instead, assume that people | |
12641 | who want to use K&R C compilers (when using these modules in GCC, | |
12642 | perhaps?) will run ansi2knr. | |
12643 | ||
12644 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): Remove. | |
12645 | All uses of "enum_" changed to "enum ". | |
12646 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
12647 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
e76d2469 | 12648 | |
5bd1c419 PE |
12649 | * lib/abitset.c (abitset_and, abitset_and_cmp, abitset_and_or, |
12650 | abitset_and_or_cmp, abitset_andn, abitset_andn_cmp, | |
12651 | abitset_andn_or, abitset_andn_or_cmp, abitset_bytes, abitset_copy, | |
12652 | abitset_copy1, abitset_disjoint_p, abitset_empty_p, | |
12653 | abitset_equal_p, abitset_init, abitset_list, abitset_list_reverse, | |
12654 | abitset_not, abitset_ones, abitset_or, abitset_or_and, | |
12655 | abitset_or_and_cmp, abitset_or_cmp, abitset_reset, abitset_set, | |
12656 | abitset_size, abitset_small_list, abitset_subset_p, abitset_test, | |
12657 | abitset_unused_clear, abitset_xor, abitset_xor_cmp, abitset_zero): | |
12658 | Use function prototypes; this removes the need for declaring | |
12659 | static functions simply to provide their prototypes. | |
12660 | * lib/bitset.c (bitset_alloc, bitset_and_or_, bitset_and_or_cmp_, | |
12661 | bitset_andn_or_, bitset_andn_or_cmp_, bitset_bytes, bitset_copy_, | |
12662 | bitset_count_, bitset_create, bitset_dump, bitset_first, | |
12663 | bitset_free, bitset_init, bitset_last, bitset_next, | |
12664 | bitset_obstack_alloc, bitset_obstack_free, bitset_only_set_p, | |
12665 | bitset_op4_cmp, bitset_or_and_, bitset_or_and_cmp_, bitset_prev, | |
12666 | bitset_print, bitset_release_memory, bitset_toggle_, | |
12667 | bitset_type_choose, bitset_type_get, bitset_type_name_get, | |
12668 | debug_bitset): Likewise. | |
12669 | * lib/bitset.h (bitset_set, bitset_reset, bitset_test): Likewise. | |
12670 | * lib/bitset_stats.c (bitset_log_histogram_print, | |
12671 | bitset_percent_histogram_print, bitset_stats_and, | |
12672 | bitset_stats_and_cmp, bitset_stats_and_or, | |
12673 | bitset_stats_and_or_cmp, bitset_stats_andn, bitset_stats_andn_cmp, | |
12674 | bitset_stats_andn_or, bitset_stats_andn_or_cmp, bitset_stats_copy, | |
12675 | bitset_stats_count, bitset_stats_disable, bitset_stats_disjoint_p, | |
12676 | bitset_stats_dump, bitset_stats_empty_p, bitset_stats_enable, | |
12677 | bitset_stats_equal_p, bitset_stats_free, bitset_stats_init, | |
12678 | bitset_stats_list, bitset_stats_list_reverse, bitset_stats_not, | |
12679 | bitset_stats_ones, bitset_stats_or, bitset_stats_or_and, | |
12680 | bitset_stats_or_and_cmp, bitset_stats_or_cmp, bitset_stats_print, | |
12681 | bitset_stats_print_1, bitset_stats_read, bitset_stats_reset, | |
12682 | bitset_stats_set, bitset_stats_size, bitset_stats_subset_p, | |
12683 | bitset_stats_test, bitset_stats_toggle, bitset_stats_type_get, | |
12684 | bitset_stats_write, bitset_stats_xor, bitset_stats_xor_cmp, | |
12685 | bitset_stats_zero): Likewise. | |
12686 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
12687 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
12688 | bitsetv_dump, debug_bitsetv): Likewise. | |
12689 | * lib/ebitset.c (ebitset_and, ebitset_and_cmp, ebitset_andn, | |
12690 | ebitset_andn_cmp, ebitset_bytes, ebitset_copy, ebitset_copy_, | |
12691 | ebitset_copy_cmp, ebitset_disjoint_p, ebitset_elt_add, | |
12692 | ebitset_elt_alloc, ebitset_elt_calloc, ebitset_elt_find, | |
12693 | ebitset_elt_free, ebitset_elt_last, ebitset_elt_remove, | |
12694 | ebitset_elt_zero_p, ebitset_elts_grow, ebitset_empty_p, | |
12695 | ebitset_equal_p, ebitset_free, ebitset_init, ebitset_list, | |
12696 | ebitset_list_reverse, ebitset_not, ebitset_ones, ebitset_op3_cmp, | |
12697 | ebitset_or, ebitset_or_cmp, ebitset_release_memory, ebitset_reset, | |
12698 | ebitset_set, ebitset_size, ebitset_subset_p, ebitset_test, | |
12699 | ebitset_weed, ebitset_xor, ebitset_xor_cmp, ebitset_zero): | |
12700 | Likewise. | |
12701 | * lib/lbitset.c (debug_lbitset, lbitset_and, lbitset_and_cmp, | |
12702 | lbitset_andn, lbitset_andn_cmp, lbitset_bytes, lbitset_copy, | |
12703 | lbitset_copy_cmp, lbitset_disjoint_p, lbitset_elt_alloc, | |
12704 | lbitset_elt_calloc, lbitset_elt_find, lbitset_elt_free, | |
12705 | lbitset_elt_link, lbitset_elt_unlink, lbitset_elt_zero_p, | |
12706 | lbitset_empty_p, lbitset_equal_p, lbitset_free, lbitset_init, | |
12707 | lbitset_list, lbitset_list_reverse, lbitset_not, lbitset_ones, | |
12708 | lbitset_op3_cmp, lbitset_or, lbitset_or_cmp, lbitset_prune, | |
12709 | lbitset_release_memory, lbitset_reset, lbitset_set, lbitset_size, | |
12710 | lbitset_subset_p, lbitset_test, lbitset_weed, lbitset_xor, | |
12711 | lbitset_xor_cmp, lbitset_zero): Likewise. | |
e76d2469 | 12712 | |
ae26e1f0 AD |
12713 | 2002-10-14 Akim Demaille <akim@epita.fr> |
12714 | ||
12715 | Version 1.75. | |
12716 | ||
d43baf71 AD |
12717 | 2002-10-14 Akim Demaille <akim@epita.fr> |
12718 | ||
12719 | * tests/Makefile.am (maintainer-check-posix): New. | |
12720 | ||
7ebc83e3 AD |
12721 | 2002-10-14 Akim Demaille <akim@epita.fr> |
12722 | ||
12723 | * data/glr.c [YYDEBUG] (YYLEFTMOST_STATE): Initialize the yyloc | |
12724 | member. | |
12725 | ||
05846dae AD |
12726 | 2002-10-14 Akim Demaille <akim@epita.fr> |
12727 | ||
12728 | * src/tables.c (table_ninf_remap): base -> tab. | |
12729 | Reported by Matt Rosing. | |
12730 | ||
1318e37d PE |
12731 | 2002-10-14 Paul Eggert <eggert@twinsun.com> |
12732 | ||
447fbb17 PE |
12733 | * tests/action.at, tests/calc.at, tests/conflicts.at, |
12734 | tests/cxx-type.at, tests/headers.at, tests/input.at, | |
12735 | tests/regression.at, tests/synclines.at, tests/torture.at: | |
12736 | Say "bison -o foo.c foo.y", not "bison foo.y -o foo.c", | |
12737 | so that the tests still work even if POSIXLY_CORRECT is set. | |
12738 | * doc/bison.texinfo (Rpcalc Compile, Invocation): Likewise. | |
05846dae | 12739 | |
1318e37d PE |
12740 | * data/c.m4 (b4_int_type): Use yysigned_char instead of signed char, |
12741 | for portability to K&R hosts. Fix typo: signed char is guaranteed | |
12742 | only to 127, not to 128. | |
12743 | * data/glr.c (yysigned_char): New type. | |
12744 | * data/yacc.c (yysigned_char): Likewise. | |
12745 | * tests/regression.at (Web2c Actions): signed char -> yysigned_char. | |
12746 | ||
cc0f0794 PE |
12747 | 2002-10-13 Paul Eggert <eggert@twinsun.com> |
12748 | ||
5038f418 PE |
12749 | * data/yacc.c (yyparse): Rewrite to avoid "comparison is always |
12750 | true due to limited range of data type" warning from GCC. | |
12751 | ||
cc0f0794 PE |
12752 | * data/c.m4 (b4_token_defines): Protect against double-inclusion |
12753 | by wrapping enum yytokentype's definition inside #ifndef | |
12754 | YYTOKENTYPE. This undoes a bug I introduced on 2002-10-12. | |
12755 | ||
6fed0802 AD |
12756 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12757 | ||
12758 | * data/glr.c (yyglrShiftDefer, yyaddDeferredAction, yydoAction): | |
12759 | Un yy- yyrhs to avoid the name clash with the global YYRHS. | |
12760 | ||
32f0598d AD |
12761 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12762 | ||
12763 | * Makefile.maint: Update from Autoconf 2.54. | |
12764 | * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Remove, shipped with 2.54. | |
12765 | ||
7ea9a33f AD |
12766 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12767 | ||
12768 | * src/print.c (print_state): Separate the list of solved conflicts | |
12769 | from the other items. | |
12770 | * tests/conflicts.at (Resolved SR Conflicts): Adjust. | |
12771 | ||
ea99527d AD |
12772 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12773 | ||
12774 | Let nondeterministic skeletons be usable with deterministic | |
12775 | tables. | |
12776 | ||
12777 | With the patch, GAWK compiled by GCC without -O2 passes its test | |
12778 | suite using a GLR parser driven by LALR tables. It fails with -O2 | |
12779 | because `struct stat' gives two different answers on my machine: | |
12780 | 88 (definition of an auto var) and later 96 (memset on this var). | |
12781 | Hence the stack is badly corrumpted. The headers inclusion is to | |
12782 | blame: if I move the awk.h inclusion before GLR's system header | |
12783 | inclusion, the two struct stat have the same size. | |
12784 | ||
12785 | * src/tables.c (pack_table): Always create conflict_table. | |
12786 | (token_actions): Always create conflict_list. | |
12787 | * data/glr.c (YYFLAG): Remove, unused. | |
12788 | ||
f377f69f AD |
12789 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12790 | ||
12791 | * configure.ac (AC_GNU_SOURCE): Use it instead of hand written code. | |
12792 | (O0FLAGS): New. | |
12793 | (VALGRIND, GXX): New. | |
12794 | * tests/atlocal.in (CFLAGS): Use O0FLAGS. | |
12795 | * tests/bison.in: Run $PREBISON a pre-command. | |
12796 | * tests/Makefile.am (maintainer-check, maintainer-check-valgrind) | |
12797 | (maintainer-check-g++): New. | |
12798 | * Makefile.am (maintainer-check): New. | |
12799 | ||
2a1fe6ed AD |
12800 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12801 | ||
12802 | * data/glr.c: Formatting changes. | |
12803 | Tweak some trace messages to match yacc.c's. | |
12804 | ||
f50adbbd AD |
12805 | 2002-10-13 Akim Demaille <akim@epita.fr> |
12806 | ||
12807 | GLR parsers sometimes raise parse errors instead of performing the | |
12808 | default reduction. | |
12809 | Reported by Charles-Henry de Boysson. | |
12810 | ||
12811 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Don't | |
ba0fe3c7 | 12812 | check the length of the traces when %glr. |
f50adbbd AD |
12813 | (_AT_CHECK_CALC_ERROR): Also skip `^Stack' lines, coming from |
12814 | GLR's traces. | |
12815 | (AT_CHECK_CALC_LALR, AT_CHECK_CALC_GLR): New. | |
12816 | Test GLR parsers. | |
12817 | * data/glr.c (YYLEFTMOST_STATE): Fix its value. | |
12818 | (yyltype): Remove the yy prefix from the member names. | |
12819 | (yytable): Complete its comment. | |
12820 | (yygetLRActions): Map error action number from YYTABLE from | |
12821 | YYTABLE_NINF to 0. | |
12822 | (yyisErrorAction): No longer compare YYACTION to YYPACT_NINF | |
12823 | (which was a bug: it should have been YYTABEL_NINF, and yet it was | |
12824 | not satisfying as we could compare an YYACTION computed from | |
12825 | YYDEFACT to YYTABLE_NINF although they are unrelated): 0 is the | |
12826 | only value for error actions. | |
12827 | (yyreportParseError): In verbose parse error messages, don't issue | |
12828 | `error' in the list of expected tokens. | |
12829 | * data/yacc.c (yyparse) <yybackup>: Rewrite the decoding of the | |
12830 | next action to perform to match glr.c's decoding. | |
12831 | (yytable): Complete its comment. | |
12832 | ||
bcbad5b9 PE |
12833 | 2002-10-13 Paul Eggert <eggert@twinsun.com> |
12834 | ||
12835 | Fix problem reported by Henrik Grubbstroem in | |
161a71f3 | 12836 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00098.html>: |
bcbad5b9 PE |
12837 | "nonterm: { $$ = 123; } { $$ = $1; };" was wrongly rejected, |
12838 | because the Bison parser reads the second action before reducing | |
12839 | the first one. | |
12840 | * src/scan-gram.l (rule_length): New static var. | |
12841 | Use it to keep track of the rule length in the scanner, since | |
12842 | we can't expect the parser to be in lock-step sync with the scanner. | |
12843 | (handle_action_dollar, handle_action_at): Use this var. | |
12844 | * tests/actions.at (Exotic Dollars): Test for the problem. | |
05846dae | 12845 | |
14904b89 PE |
12846 | 2002-10-12 Paul Eggert <eggert@twinsun.com> |
12847 | ||
1fe611e5 PE |
12848 | * lib/timevar.c [! IN_GCC && HAVE_SYS_TIME_H]: Include <sys/time.h>. |
12849 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): Check for <sys/time.h>. | |
12850 | Include <sys/time.h> when checking for clock_t and struct tms. | |
12851 | Use same include order as source. | |
12852 | This is for the SunOS 4.1.4 porting bug reported by Peter Klein in | |
161a71f3 | 12853 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00016.html>. |
05846dae | 12854 | |
1fe611e5 PE |
12855 | * lib/timevar.c: Update copyright date and clarify comments. |
12856 | (get_time) [IN_GCC]: Keep the GCC version for reference. | |
05846dae | 12857 | |
1fe611e5 PE |
12858 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: Import |
12859 | GCC version as of today, then merge Bison's changes. | |
12860 | Change "GCC" to "Bison" in copyright notice. timevar.def's | |
12861 | author is Akim, so change that too. | |
12862 | ||
98194095 PE |
12863 | * src/reader.c (grammar_current_rule_check): |
12864 | Don't worry about the default action if $$ is untyped. | |
12865 | Prevents bogus warnings reported by Jim Gifford in | |
161a71f3 | 12866 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00015.html>. |
98194095 | 12867 | |
14904b89 PE |
12868 | * data/c.m4 (b4_token_enum): Do not define YYTOKENTYPE. |
12869 | * data/glr.c, data/lalr1.cc, data/yacc.c: | |
12870 | Output token definitions before the first part of user declarations. | |
12871 | Fixes compatibility problem reported by Jim Gifford for kbd in | |
161a71f3 | 12872 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00014.html>. |
14904b89 | 12873 | |
ff6dca18 PE |
12874 | 2002-10-11 Paul Eggert <eggert@twinsun.com> |
12875 | ||
12876 | * data/yacc.c (yyreport_parse_error): Remove, putting its body into... | |
12877 | (yyparse): here. This undoes some of the 2002-07-25 change. | |
12878 | Compatibility problem reported by Ralf S. Engelschall with | |
12879 | OSSP cfg <http://www.ossp.org/pkg/lib/cfg/>. | |
12880 | ||
eb714592 AD |
12881 | 2002-10-11 Akim Demaille <akim@epita.fr> |
12882 | ||
12883 | * tests/regression.at Characters Escapes): New. | |
12884 | * src/scan-gram.l (SC_ESCAPED_CHARACTER): Accept \' in strings and | |
12885 | characters. | |
12886 | Reported by Jan Nieuwenhuizen. | |
12887 | ||
b7195100 AD |
12888 | 2002-10-11 Akim Demaille <akim@epita.fr> |
12889 | ||
12890 | * po/id.po: New. | |
12891 | ||
f28a0f2d PE |
12892 | 2002-10-10 Paul Eggert <eggert@twinsun.com> |
12893 | ||
12894 | Portability fixes for bitsets; this also avoids several GCC | |
12895 | warnings. | |
12896 | ||
12897 | * lib/abitset.c: Include <stddef.h>, for offsetof. | |
12898 | * lib/lbitset.c: Likewise. | |
12899 | ||
12900 | * lib/abitset.c (abitset_bytes): Return a size that is aligned | |
12901 | properly for vectors of objects. Do not assume that adding a | |
12902 | header size to a multiple of a word size yields a value that is | |
12903 | properly aligned for the whole union. | |
12904 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
12905 | ||
12906 | * lib/bitset_stats.c (bitset_stats_bytes): Adjust to new, | |
12907 | unique names for structures. | |
12908 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
12909 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
12910 | ||
12911 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_empty_p, | |
12912 | abitset_copy1, abitset_not, abitset_equal_p, abitset_subset_p, | |
12913 | abitset_disjoint_p, abitset_and, abitset_and_cmp, abitset_andn, | |
12914 | abitset_andn_cmp, abitset_or, abitset_or_cmp, abitset_xor, | |
12915 | abitset_xor_cmp, abitset_and_or, abitset_and_or_cmp, | |
12916 | abitset_andn_or, abitset_andn_or_cmp, abitset_or_and, | |
12917 | abitset_or_and_cmp, abitset_copy): Supply prototype decls, | |
12918 | to improve the type-checking that GCC can do. | |
12919 | * lib/bitset.c (bitset_op4_cmp): Likewise. | |
12920 | * lib/bitset_stats.c (bitset_stats_count, | |
12921 | bitset_stats_empty_p, bitset_stats_ones, bitset_stats_zero, | |
12922 | bitset_stats_copy, bitset_stats_disjoint_p, | |
12923 | bitset_stats_equal_p, bitset_stats_not, bitset_stats_subset_p, | |
12924 | bitset_stats_and, bitset_stats_and_cmp, bitset_stats_andn, | |
12925 | bitset_stats_andn_cmp, bitset_stats_or, bitset_stats_or_cmp, | |
12926 | bitset_stats_xor, bitset_stats_xor_cmp, bitset_stats_and_or, | |
12927 | bitset_stats_and_or_cmp, bitset_stats_andn_or, | |
12928 | bitset_stats_andn_or_cmp, bitset_stats_or_and, | |
12929 | bitset_stats_or_and_cmp): Likewise. | |
12930 | * lib/lbitset.c (lbitset_and, lbitset_and_cmp, lbitset_andn, | |
12931 | lbitset_andn_cmp, lbitset_or, lbitset_or_cmp, lbitset_xor, | |
12932 | lbitset_xor_cmp, lbitset_empty_p, lbitset_ones, lbitset_not, | |
12933 | lbitset_subset_p, lbitset_disjoint_p, debug_lbitset): Likewise. | |
12934 | ||
12935 | * lib/abitset.h: Include bitset.h, not bbitset.h. | |
12936 | * lib/ebitset.h: Likewise. | |
12937 | * lib/lbitset.h: Likewise. | |
12938 | ||
12939 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): New types. | |
12940 | All instances of parameters of type enum bitset_opts are now of | |
12941 | type enum_bitset_opts, to conform to the C Standard, and similarly | |
12942 | for enum_bitset_type. | |
12943 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
12944 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
12945 | ||
12946 | Do not use "struct bitset_struct" to mean different things in | |
12947 | different modules. Not only is this confusing, it violates | |
12948 | the C Standard, which requires that structure types in different | |
12949 | modules must be compatible if one is to be passed to the other. | |
12950 | * lib/bbitset.h (bitset): Now points to a union, not to a struct. | |
12951 | All instances of "struct bitset_struct *" replaced with "bitset". | |
12952 | * lib/bitset.h (struct bitset_struct): Remove, replacing with.... | |
12953 | (union bitset_union, struct abitset_struct, struct ebitset_struct, | |
12954 | struct lbitset_struct, struct bitset_stats_struct): New types. | |
12955 | All uses of struct bitset_struct changed to union bitset_union, | |
12956 | etc. | |
ba0fe3c7 | 12957 | * lib/abitset.c (struct abitset_struct, abitset, |
f28a0f2d PE |
12958 | struct bitset_struct): Remove. |
12959 | * lib/bitset_stats.c (struct bitset_stats_struct, bitset_stats, | |
12960 | struct bitset_struct): Remove. | |
12961 | * lib/ebitset.c (struct ebitset_struct, ebitset, struct | |
12962 | bitset_struct): Remove. | |
12963 | * lib/lbitset.c (struct lbitset_struct, lbitset, bitset_struct): | |
12964 | Likewise. | |
12965 | ||
12966 | Do not call a function of type T using a call that assumes the | |
12967 | function is of a different type U. Standard C requires that a | |
12968 | function must be called with a type that is compatible with its | |
12969 | definition. | |
12970 | * lib/bbitset.h (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
12971 | New decls. | |
12972 | * lib/bitset.c (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
12973 | New functions. | |
12974 | * lib/ebitset.c (PFV): Remove. | |
12975 | * lib/lbitset.c (PFV): Likewise. | |
12976 | * lib/ebitset.c (ebitset_and, ebitset_andn, ebitset_or, | |
12977 | ebitset_xor, ebitset_copy, ebitset_ones, ebitset_empty_p): New | |
12978 | decls. | |
12979 | (ebitset_and, ebitset_andn, ebitset_or, ebitset_xor): New functions. | |
12980 | (ebitset_vtable): Use them. | |
12981 | * lib/lbitset.c (lbitset_and, lbitset_andn, lbitset_or, | |
12982 | lbitset_xor): New functions. | |
12983 | (lbitset_vtable): Use them. | |
12984 | ||
12985 | * lib/bitset.h (bitset_next, bitset_prev, bitset_only_set_p): | |
12986 | Declare. | |
12987 | ||
12988 | * lib/bitsetv.c (bitsetv_alloc): Add a cast to (void *) to avoid a | |
12989 | GCC warning. | |
12990 | * lib/lbitset.c (LBITSET_CURRENT1): Likewise. | |
12991 | Use offsetof, for simplicity. | |
12992 | ||
6fbe4984 PE |
12993 | 2002-10-06 Paul Eggert <eggert@twinsun.com> |
12994 | ||
12995 | * lib/bitset.h (bitset_reset): Do not assume that bitset_word is | |
12996 | the same width as int. This reapplies a hunk of the 2002-08-12 patch | |
161a71f3 | 12997 | <http://lists.gnu.org/archive/html/bison-patches/2002-08/msg00007.html>, |
6fbe4984 PE |
12998 | which was inadvertently undone by the 2002-09-30 patch. |
12999 | * lib/lbitset.c (debug_lbitset): Do not assume that bitset_word is | |
13000 | the same width as int. | |
13001 | ||
420f93c8 PE |
13002 | 2002-10-04 Paul Eggert <eggert@twinsun.com> |
13003 | ||
13004 | Version 1.50. | |
13005 | ||
13006 | * configure.ac (AC_INIT), NEWS: Increment version number. | |
13007 | ||
13008 | * doc/bison.texinfo: Minor spelling, grammar, and white space | |
13009 | fixes. | |
13010 | (Symbols): Mention that any negative value returned from yylex | |
13011 | signifies end-of-input. Warn about negative chars. Mention | |
13012 | the portable Standard C character set. | |
13013 | ||
13014 | The GNU coding standard says CFLAGS and YFLAGS are reserved | |
13015 | for the installer to set. | |
13016 | * lib/Makefile.am (AM_CFLAGS): Renamed from CFLAGS. | |
13017 | * src/Makefile.am (AM_CFLAGS): Likewise. | |
13018 | (AM_YFLAGS): Renamed from YFLAGS. | |
13019 | ||
13020 | Fix some MAX and MIN problems. | |
13021 | * src/gram.h (ITEM_NUMBER_MIN): MIN_MAX -> INT_MIN. | |
13022 | * src/lalr.h (GOTO_NUMBER_MAX): INT_MAX -> SHRT_MAX. | |
13023 | * src/symtab.h (SYMBOL_NUMBER_MAX): New macro. | |
13024 | * src/reader.c (reader): Use it. | |
13025 | ||
13026 | * tests/regression.at (Braces parsing): Use grep, not fgrep, as | |
13027 | POSIX 1003.1-2001 has removed fgrep. | |
13028 | ||
13029 | 2002-10-04 Michael Hayes <m.hayes@elec.canterbury.ac.nz> | |
13030 | ||
13031 | * lib/bbitset.h (BITSET_WINDEX_MAX): Redefine so that it cannot be | |
13032 | interpreted as signed. | |
13033 | * lib/ebitset.c (ebitset_list): Fix bug. | |
13034 | ||
ff68026d PE |
13035 | 2002-10-01 Paul Eggert <eggert@twinsun.com> |
13036 | ||
13037 | More fixes for 64-bit hosts and large bitsets. | |
13038 | ||
13039 | * lib/abitset.c (struct abitset_struct.n_bits, abitset_small_list, | |
13040 | abitset_size, abitset_list, abitset_list_reverse, abitset_list): | |
13041 | Use bitset_bindex, not int or unsigned int or size_t, to count bits. | |
13042 | * lib/bbitset.h (struct bitset_vtable.size, struct bitset_vtable.count, | |
13043 | struct bitset_vtable.list, struct bitset_vtable.list_reverse, | |
13044 | bitset_count_, bitset_next, bitset_prev, bitset_first, bitset_last, | |
13045 | bitset_count_): Likewise. | |
13046 | * lib/bitset.h (bitset_iterator.num, bitset_iterator.i, | |
13047 | bitset_first, bitset_last): Likewise. | |
13048 | * lib/bitset_stats.c (bitset_stats_size, bitset_stats_list, | |
13049 | bitset_stats_list_reverse, bitset_stats_size, | |
13050 | bitset_stats_count, bitset_stats_list, bitset_stat_list_reverse): | |
13051 | Likewise. | |
13052 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
13053 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
13054 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
13055 | bitsetv_reflexive_transitive_closure): Likewise. | |
13056 | * lib/bitsetv.h (bitsetv_alloc, bitsetv_create): Likewise. | |
13057 | * lib/ebitset.c (ebitset_size, ebitset_list, ebitset_list_reverse): | |
13058 | Likewise. | |
13059 | * lib/lbitset.c (lbitset_size, lbitset_list, lbitset_list_merge): | |
13060 | Likewise. | |
420f93c8 | 13061 | |
ff68026d PE |
13062 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_bytes): |
13063 | Use size_t, not unsigned int, to count bytes. | |
13064 | * lib/abitset.h (abitset_bytes): Likewise. | |
13065 | * lib/bitset.c (bitset_bytes, bitset_alloc, bitset_obstack_alloc): | |
13066 | Likewise. | |
13067 | * lib/bitset.h (bitset_bytes): Likewise. | |
13068 | * lib/bitset_stats.c (bitset_stats_bytes, bitset_stats_init): Likewise. | |
13069 | * lib/bitset_stats.h (bitset_stats_bytes): Likewise. | |
13070 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
13071 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
13072 | * lib/ebitset.h (ebitset_bytes): Likewise. | |
13073 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
13074 | * lib/lbitset.h (lbitset_bytes): Likewise. | |
420f93c8 | 13075 | |
ff68026d PE |
13076 | * lib/abitset.c (abitset_empty_p, abitset_not, abitset_equal_p, |
13077 | abitset_subset_p, abitset_disjoint_p, abitset_and, | |
13078 | abitset_and_cmp, abitset_andn, abitset_andn_cmp, abitset_or, | |
13079 | abitset_or_cmp, abitset_xor, abitset_xor_cmp, abitset_and_or, | |
13080 | abitset_and_or_cmp, abitset_andn_or, abitset_andn_or_cmp, | |
13081 | abitset_or_and, abitset_or_and_cmp): | |
13082 | Use bitset_windex instead of unsigned int. | |
13083 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
13084 | * lib/ebitset.c (struct ebitset_struct.size, ebitset_elts_grow, | |
13085 | ebitset_elt_add, ebitset_elt_remove, ebitset_weed, | |
13086 | ebitset_elt_find, ebitset_list_reverse, ebitset_list, ebitset_init): | |
13087 | Likewise. | |
13088 | * lib/lbitset.c (lbitset_ones, lbitset_not): Likewise. | |
420f93c8 | 13089 | |
ff68026d PE |
13090 | * lib/bitset.c (bitset_print): |
13091 | Use proper printf formats for widths of integer types. | |
13092 | * lib/bitset_stats.c (bitset_percent_histogram_print, | |
13093 | bitset_log_histogram_print, bitset_stats_print_1): Likewise. | |
13094 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
13095 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
13096 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
420f93c8 | 13097 | |
ff68026d PE |
13098 | * lib/bbitset.h (BITSET_BINDEX_MAX, BITSET_WINDEX_MAX, |
13099 | BITSET_SIZE_MAX): New macros. | |
13100 | (BITSET_INDEX_MAX): Remove. It wasn't right, since it assumed that | |
13101 | sizeof (bitset_word) == sizeof (bitset_windex). All uses changed | |
13102 | to BITSET_WINDEX_MAX. | |
13103 | ||
13104 | * lib/bitset.c (bitset_next, bitset_prev, bitset_first, | |
13105 | bitset_last): Return BITSET_BINDEX_MAX (not -1) for no value, | |
13106 | since we now return the bitset_bindex type (not int). | |
13107 | ||
13108 | * lib/bitsetv.c (bitsetv_alloc): Check for arithmetic overflow | |
13109 | when computing sizes. | |
13110 | * lib/ebitset.c (ebitset_elts_grow): Likewise. | |
13111 | ||
13112 | * lib/lbitset.c (lbitset_elt_find): Simplify windex calculation | |
13113 | and avoid cast to unsigned. | |
13114 | ||
6aa452a6 AD |
13115 | 2002-09-30 Akim Demaille <akim@epita.fr> |
13116 | ||
13117 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
13118 | * lib/bitset_stats.c, lib/bitsetv.c, lib/ebitset.c, lib/lbitset.c: | |
13119 | Updates from Michael Hayes. | |
13120 | ||
927f7817 AD |
13121 | 2002-09-30 Art Haas <ahaas@neosoft.com> |
13122 | ||
13123 | * configure.ac: Update AC_OUTPUT and AM_CONFIG_HEADER | |
13124 | invocations. | |
13125 | * tests/cxx-type.at (declarator): Don't rely on NDEBUG being not | |
13126 | defined. | |
13127 | ||
9738f41e AD |
13128 | 2002-09-27 Akim Demaille <akim@epita.fr> |
13129 | ||
13130 | Version 1.49c. | |
13131 | ||
a5c75d7f AD |
13132 | 2002-09-27 Akim Demaille <akim@epita.fr> |
13133 | ||
13134 | * configure.ac (AM_INIT_AUTOMAKE): We _need_ 1.7. | |
13135 | (Because of AC_LIBSOURCE). | |
13136 | ||
8280e179 AD |
13137 | 2002-09-27 Akim Demaille <akim@epita.fr> |
13138 | ||
13139 | Playing with Autoscan. | |
13140 | ||
13141 | * configure.ac: Remove the old LIBOBJ tweaks. | |
13142 | (AC_REPLACE_FUNCS): Add strrchr and strtol. | |
13143 | * lib/strrchr.c: New. | |
13144 | * lib/strtol.c: New, from the Coreutils 4.5.1. | |
13145 | ||
ae64af35 AD |
13146 | 2002-09-27 Akim Demaille <akim@epita.fr> |
13147 | ||
13148 | Playing with Autoscan. | |
13149 | ||
13150 | * m4/prereq.m4 (jm_PREREQ_ARGMATCH, jm_FUNC_ARGMATCH): New. | |
13151 | * lib/Makefile.am (libbison_a_SOURCES): No longer include | |
13152 | argmatch.c and argmatch.h, since they are AC_LIBSOURCE'd. | |
13153 | * lib/strcasecmp.c, lib/strncasecmp.c, lib/memcmp.c: New, from the | |
13154 | Coreutils 4.5.1. | |
13155 | ||
d1a1114f AD |
13156 | 2002-09-24 Akim Demaille <akim@epita.fr> |
13157 | ||
13158 | * doc/bison.texinfo (Stack Overflow): xref to Recursion. | |
13159 | (Frequently Asked Questions, Parser Stack Overflow): New. | |
13160 | ||
b906441c AD |
13161 | 2002-09-13 Akim Demaille <akim@epita.fr> |
13162 | ||
13163 | Playing with autoscan. | |
13164 | ||
13165 | * src/reader.c (get_merge_function): Use xstrdup, not strdup. | |
13166 | * src/files.c (skeleton_find): Remove, unused. | |
13167 | * m4/memcmp.m4: New, from the Coreutils 4.5.1. | |
13168 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Run jm_FUNC_MEMCMP. | |
13169 | ||
bd701811 AD |
13170 | 2002-09-13 Akim Demaille <akim@epita.fr> |
13171 | ||
13172 | * configure.ac (AM_INIT_AUTOMAKE): Require Automake 1.6.3. | |
13173 | * Makefile.am (AUTOMAKE_OPTIONS): Don't. | |
13174 | ||
e0a13e7b AD |
13175 | 2002-09-13 Akim Demaille <akim@epita.fr> |
13176 | ||
13177 | * configure.ac: Require 2.54. | |
13178 | s/jm_FUNC_MALLOC/AC_FUNC_MALLOC/. | |
13179 | s/jm_FUNC_REALLOC/AC_FUNC_REALLOC/. | |
13180 | * m4/c-bs-a.m4, m4/malloc.m4, m4/mbstate_t.m4, m4/realloc.m4: | |
13181 | Remove, provided by Autoconf macros. | |
13182 | ||
c97011bf AD |
13183 | 2002-09-12 Akim Demaille <akim@epita.fr> |
13184 | ||
13185 | * m4/prereq.m4: Update, from Coreutils 4.5.1. | |
13186 | ||
d862b1be AD |
13187 | 2002-09-12 Akim Demaille <akim@epita.fr> |
13188 | ||
13189 | * m4/prereq.m4: Update, from Fileutils 4.1.5. | |
13190 | * configure.ac (jm_PREREQ_TEMPNAME): Invoke it. | |
13191 | Reported by Martin Mokrejs. | |
13192 | ||
3d38c03a AD |
13193 | 2002-09-10 Akim Demaille <akim@epita.fr> |
13194 | ||
13195 | * src/parse-gram.y: Associate a human readable string to each | |
13196 | token type. | |
13197 | * tests/regression.at (Invalid inputs): Adjust. | |
13198 | ||
b6347355 AD |
13199 | 2002-09-10 Gary V. Vaughan <gary@gnu.org> |
13200 | ||
13201 | * tests/Makefile.am ($(srcdir)/package.m4): Bison now ships | |
13202 | with an Autoconf-2.5x style configure.ac. | |
13203 | ||
09ba4ab2 PE |
13204 | 2002-09-06 Paul Eggert <eggert@twinsun.com> |
13205 | ||
13206 | * doc/bison.texinfo (Conditions): Make explicit that the GPL | |
13207 | exception applies only to yacc.c. This is a modification of a | |
13208 | patch originally suggested by Akim Demaille. | |
13209 | ||
21846f69 AD |
13210 | 2002-09-06 Akim Demaille <akim@epita.fr> |
13211 | ||
09ba4ab2 PE |
13212 | * data/c.m4 (b4_copyright): Move the GPL exception comment from |
13213 | here to... | |
13214 | * data/yacc.c: here. | |
13215 | ||
21846f69 AD |
13216 | * data/lalr1.cc (struct yyltype): Don't define it, since we use |
13217 | LocationType. | |
13218 | (b4_ltype): Default to yy::Location from location.hh. | |
13219 | ||
c0ad8bf3 AD |
13220 | 2002-09-04 Jim Meyering <jim@meyering.net> |
13221 | ||
13222 | * data/yacc.c: Guard the declaration of yytoknum also with | |
13223 | `#ifdef YYPRINT', so it is declared only when used. | |
13224 | ||
3a93251e AD |
13225 | 2002-09-04 Akim Demaille <akim@epita.fr> |
13226 | ||
13227 | * configure.in: Rename as... | |
13228 | * configure.ac: this. | |
13229 | Bump to 1.49c. | |
13230 | ||
427c0dda AD |
13231 | 2002-09-04 Akim Demaille <akim@epita.fr> |
13232 | ||
13233 | * src/assoc.c, src/closure.c, src/gram.c, src/injections.c, | |
13234 | * src/lalr.c, src/LR0.c, src/relation.c, src/tables.c: Don't | |
13235 | translate maintainer only messages. | |
13236 | ||
6a254321 PE |
13237 | 2002-08-12 Paul Eggert <eggert@twinsun.com> |
13238 | ||
645e30d1 PE |
13239 | Version 1.49b. |
13240 | ||
6a254321 PE |
13241 | * Makefile.am (SUBDIRS): Remove intl. |
13242 | (DISTCLEANFILES): Remove. | |
13243 | * NEWS: Mention that GNU M4 is now required. Clarify what is | |
13244 | meant by "larger grammars". Mention the pt_BR translation. | |
13245 | * configure.in (AC_CHECK_DECLS): Add getenv, getopt. | |
13246 | (AM_GNU_GETTEXT_VERSION): New macro, replacing GETTEXT_VERSION var. | |
13247 | Bump version from 0.11.2 to 0.11.5. | |
13248 | (BISON_PREREQ_STAGE): Remove. | |
13249 | (AM_GNU_GETTEXT): Use external gettext. | |
13250 | (AC_OUTPUT): Remove intl/Makefile. | |
13251 | ||
13252 | * config/depcomp, config/install-sh: Sync with Automake 1.6.3. | |
13253 | ||
13254 | * data/glr.c: Include string.h, for strlen. | |
13255 | (yyreportParseError): Use size_t for yysize. | |
13256 | (yy_yypstack): No longer nested inside yypstates, as nested | |
13257 | functions are not portable. Do not assume size_t is the | |
13258 | same width as int. | |
13259 | (yypstates): Do not assume that ptrdiff_t is the same width | |
13260 | as int, and similarly for yyposn and YYINDEX. | |
13261 | ||
13262 | * data/yacc.c: Fix comment about `$$ = $1': it can copy garbage. | |
13263 | ||
13264 | * lib/Makefile.am (INCLUDES): Do not include from the intl | |
13265 | directory, which has been removed. | |
13266 | * src/Makefile.am (INCLUDES): Likewise. | |
13267 | ||
13268 | * lib/Makefile.am (libbison_a_SOURCES): Add unlocked-io.h. | |
13269 | (bitsets_sources, additional_bitsets_sources, timevars_sources): | |
13270 | New vars. | |
13271 | ||
13272 | * lib/Makefile.am (libbison_a_SOURCES): Avoid +=, a GNU make extension. | |
13273 | * tests/Makefile.am (EXTRA_DIST): Likewise. | |
13274 | ||
13275 | * lib/abitset.c (abitset_reverse_list, ebitset_reverse_list): | |
13276 | Do not assume that bitset_windex is the same width as unsigned. | |
13277 | ||
13278 | * lib/abitset.c (abitset_unused_clear): Do not assume that | |
13279 | bitset_word is the same width as int. | |
13280 | * lib/bbitset.h (BITSET_INDEX_MAX, BITSET_MSB): Likewise. | |
13281 | * lib/bitset.h (bitset_set, bitset_reset): Likewise. | |
13282 | * lib/bitset_stats.c (bitset_stats_set, bitset_stats_reset): Likewise. | |
13283 | * lib/ebitset.c (ebitset_set, ebitset_reset): Likewise. | |
13284 | * lib/lbitset.c (lbitset_set, lbitset_reset): Likewise. | |
13285 | ||
13286 | * lib/abitset.c (abitset_op1): Use -1, not ~0, as memset arg (for | |
13287 | portability to one's complement hosts!). | |
13288 | * lib/ebitset.c (ebitset_op1): Likewise. | |
13289 | * lib/lbitset.c (lbitset_op1): Likewise. | |
13290 | ||
13291 | * lib/argmatch.c, lib/quotearg.c, quotearg.h: Sync with GNU tar. | |
13292 | * lib/argmatch.h, lib/basename.c, lib/dirname.c, lib/dirname.h, | |
13293 | lib/hash.c, lib/hash.h, lib/strnlen.c, lib/xmalloc.c: | |
13294 | Sync with fileutils. | |
13295 | * lib/error.c, lib/getopt.c, lib/getopt.h, lib/getopt1.c, | |
13296 | lib/gettext.h: Sync with diffutils. | |
13297 | ||
13298 | * lib/memrchr.c, lib/mkstemp.c, lib/strchr.c, lib/strnlen.c, | |
13299 | lib/strspn.c, lib/tempname.c: Use GPL, not LGPL. | |
13300 | ||
13301 | * lib/obstack.c, lib/obstack.h: Sync with fileutils, except use | |
13302 | PROTOTYPES to check for prototypes, and "defined __STDC__" to | |
13303 | check for void *. | |
13304 | ||
13305 | * lib/bbitset.h (BITSET_WORD_BITS): Now of type unsigned, not | |
13306 | size_t; the old version tried to do this but casted improperly. | |
13307 | (bitset_bindex, bitset_windex): Now size_t, not unsigned long. | |
13308 | (bitset_test): Now returns int, not unsigned long. | |
13309 | ||
13310 | * lib/bitset_stats.c: Include "gettext.h". | |
13311 | (_): New macro. | |
13312 | (bitset_stats_set, bitset_stats_reset, bitset_stats_test): Don't | |
13313 | name locals "index", as it generates unnecessary warnings on some | |
13314 | hosts that have an "index" function. | |
13315 | ||
13316 | * lib/bitset_stats.c (bitset_stats_print_1, bitset_stats_print, | |
13317 | bitset_stats_read, bitset_stats_write): Wrap strings in _() if | |
13318 | they need translation. | |
13319 | * src/LR0.c (state_list_append, new_itemsets, get_state, | |
13320 | append_states, generate_states): Likewise. | |
13321 | * src/assoc.c (assoc_to_string): Likewise. | |
13322 | * src/closure.c (print_closure, set_firsts, closure): Likewise. | |
13323 | * src/gram.c (grammar_dump): Likewise. | |
13324 | * src/injections.c (injections_compute): Likewise. | |
13325 | * src/lalr.c (lookaheads_print): Likewise. | |
13326 | * src/relation.c (relation_transpose): Likewise. | |
13327 | * src/scan-gram.l: Likewise. | |
13328 | * src/tables.c (table_grow, pack_vector): Likewise. | |
13329 | ||
13330 | * m4/Makefile.am (EXTRA_DIST): Remove codeset.m4, | |
13331 | glibc21.m4, isc-posix.m4 lcmessage.m4, stage.m4. | |
13332 | * m4/malloc.m4, m4/realloc.m4: Sync with diffutils. | |
13333 | * m4/mbstate_t.m4: Sync with fileutils. | |
13334 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): AC_MBSTATE_T -> AC_TYPE_MBSTATE_T. | |
13335 | ||
13336 | * po/LINGUAS: Add pt_BR. | |
13337 | * po/POTFILES.in: Add src/assoc.c, src/closure.c, src/gram.c, | |
13338 | src/main.c, src/relation.c, src/state.c, lib/bitset_stats.c, | |
13339 | lib/timevar.c. | |
13340 | Use src/parse-gram.y instead of src/parse-gram.c, as the gettext | |
13341 | manual recommends. | |
13342 | Similarly, use src/scan-gram.l instead of src/scan-gram.c. | |
13343 | ||
13344 | * src/complain.c (strerror_r): Remove decl; not needed. | |
13345 | (strerror): Use same pattern as ../lib/error.c. | |
13346 | ||
13347 | * src/files.c, src/files.h (compute_header_macro): Remove; unused. | |
13348 | ||
13349 | * src/gram.c (grammar_dump): Do not assume ptrdiff_t fits in int. | |
13350 | ||
13351 | * src/main.c (main): Cast result of bindtextdomain and textdomain | |
13352 | to void, to avoid a GCC warning when --disable-nls is in effect. | |
13353 | ||
13354 | * src/scan-gram.l: Use strings rather than escapes when possible, | |
13355 | to minimize the number of warnings from xgettext. | |
13356 | (handle_action_dollar, handle_action_at): Don't use isdigit, | |
13357 | as it mishandles negative chars and it may not work as expected | |
13358 | outside the C locale. | |
13359 | ||
13360 | * src/symtab.c (symbol_get): Don't cast LHS of an assignment; | |
13361 | this is a GCC extension and is not portable to other compilers. | |
13362 | ||
13363 | * src/system.h (alloca): Use same pattern as ../lib/error.c. | |
13364 | Do not include <ctype.h>; no longer needed. | |
13365 | Do not include <malloc.h>; no longer needed (and generates | |
13366 | warnings on OpenBSD 3.0). | |
13367 | ||
13368 | * tests/cxx-type.at (yylex): Do not pass signed char to isupper; | |
13369 | it's not portable. | |
13370 | ||
13371 | * tests/regression.at: Do not use 'cc -c input.c -o input'; | |
13372 | Sun C rejects this. Instead, use 'cc -c input.c -o input.o'. | |
13373 | ||
13374 | * tests/synclines.at (AC_SYNCLINES_COMPILE): Accept any nonzero | |
13375 | exit status as failure, not just exit status 1. Sun C exits | |
13376 | with status 2 sometimes. | |
13377 | ||
13378 | * tests/torture.at (AT_INCREASE_DATA_SIZE): New macro. | |
13379 | Use it for the two large tests. | |
13380 | ||
c8f002c7 AD |
13381 | 2002-08-02 Akim Demaille <akim@epita.fr> |
13382 | ||
13383 | * src/conflicts.c (conflicts_output): Don't output rules never | |
13384 | reduced here, since anyway that computation doesn't work. | |
13385 | * src/gram.h, src/gram.h (rule_filter_t, rule_useful_p) | |
13386 | (rule_useless_p, rule_never_reduced_p): New. | |
13387 | (grammar_rules_partial_print): Use a filter instead of a range. | |
13388 | Display the title only if needed. | |
13389 | (grammar_rules_print): Adjust. | |
13390 | (grammar_rules_never_reduced_report): New. | |
13391 | * src/tables.c (action_row): Move the computation of rules never | |
13392 | reduced to... | |
13393 | (token_actions): here. | |
13394 | * src/main.c (main): Make the parser before making the report, so | |
13395 | that rules never reduced are computed. | |
13396 | Call grammar_rules_never_reduced_report. | |
13397 | * src/print.c (print_results): Report rules never reduced. | |
13398 | * tests/conflicts.at, tests/reduce.at: Adjust. | |
13399 | ||
cd08e51e AD |
13400 | 2002-08-01 Akim Demaille <akim@epita.fr> |
13401 | ||
13402 | Instead of attaching lookaheads and duplicating the rules being | |
13403 | reduced by a state, attach the lookaheads to the reductions. | |
13404 | ||
13405 | * src/state.h (state_t): Remove the `lookaheads', | |
13406 | `lookaheads_rule' member. | |
13407 | (reductions_t): Add a `lookaheads' member. | |
13408 | Use a regular array for the `rules'. | |
13409 | * src/state.c (reductions_new): Initialize the lookaheads member | |
13410 | to 0. | |
13411 | (state_rule_lookaheads_print): Adjust. | |
13412 | * src/state.h, src/state.c (state_reductions_find): New. | |
13413 | * src/conflicts.c (resolve_sr_conflict, set_conflicts) | |
13414 | (count_rr_conflicts): Adjust. | |
13415 | * src/lalr.c (LArule): Remove. | |
13416 | (add_lookback_edge): Adjust. | |
13417 | (state_lookaheads_count): New. | |
13418 | (states_lookaheads_initialize): Merge into... | |
13419 | (initialize_LA): this. | |
13420 | (lalr_free): Adjust. | |
13421 | * src/main.c (main): Don't free nullable and derives too early: it | |
13422 | is used by --verbose. | |
13423 | * src/print.c, src/print_graph.c, src/tables.c: Adjust. | |
13424 | ||
bb0027a9 AD |
13425 | 2002-08-01 Akim Demaille <akim@epita.fr> |
13426 | ||
13427 | * src/derives.h, src/derives.c (derives): A `rule_t***' instead of | |
13428 | `rule_number_t**'. | |
13429 | (set_derives, free_derives): Rename as... | |
13430 | (derives_compute, derives_free): this. | |
13431 | Adjust all dependencies. | |
13432 | * src/nullable.c (set_nullable, free_nullable): Rename as... | |
13433 | (nullable_compute, nullable_free): these. | |
13434 | (rule_list_t): Store rule_t *, not rule_number_t. | |
13435 | * src/state.c (state_rule_lookaheads_print): Directly compare rule | |
13436 | pointers, instead of their numbers. | |
13437 | * src/main.c (main): Call nullable_free, and derives_free earlier, | |
13438 | as they were lo longer used. | |
13439 | ||
3325ddc4 AD |
13440 | 2002-08-01 Akim Demaille <akim@epita.fr> |
13441 | ||
13442 | * lib/timevar.c (get_time): Include children time. | |
13443 | * src/lalr.h (LA, LArule): Don't export them: used with the | |
13444 | state_t. | |
13445 | * src/lalr.c (LA, LArule): Static. | |
13446 | * src/lalr.h, src/lalr.c (lalr_free): New. | |
13447 | * src/main.c (main): Call it. | |
13448 | * src/tables.c (pack_vector): Check whether loc is >= to the | |
13449 | table_size, not >. | |
13450 | (pack_tables): Don't free froms, tos, conflict_tos, and pos... | |
13451 | (tables_generate): do it, since that's also it which allocates | |
13452 | them. | |
13453 | Don't free LA and LArule, main does. | |
13454 | ||
c6f1a33c AD |
13455 | 2002-07-31 Akim Demaille <akim@epita.fr> |
13456 | ||
13457 | Separate parser tables computation and output. | |
13458 | ||
13459 | * src/output.c (nvectors, base_t, base, base_ninf, conflict_table) | |
13460 | (conflict_list, conflict_list_cnt, table, check, table_ninf) | |
13461 | (yydefgoto, yydefact, high): Move to... | |
13462 | * src/tables.h, src/tables.c: here. | |
13463 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
13464 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
13465 | (symbol_number_to_vector_number, nvectors, BASE_MAX, BASE_MIN) | |
13466 | (froms, tos, conflict_tos, tally, width, action_t, ACTION_MAX) | |
13467 | (ACTION_MIN, actrow, order, nentries, pos, conflrow) | |
13468 | (conflict_list_free, table_size, lowzero, table_grow, conflict_row) | |
13469 | (action_row, save_row, token_actions, save_column, default_goto) | |
13470 | (goto_actions, sort_actions, matching_state, pack_vector) | |
13471 | (table_ninf_remap, pack_table, prepare_actions): Move to... | |
13472 | * src/tables.c: here. | |
13473 | * src/tables.h, src/tables.c(tables_generate, tables_free): New. | |
13474 | * src/output.c (token_actions, output_base, output_conflicts) | |
13475 | (output_check): Merge into... | |
13476 | (prepare_actions): this. | |
13477 | (actions_output): Rename as... | |
13478 | (user_actions_output): this. | |
13479 | * src/main.c (main): Call tables_generate and tables_free. | |
13480 | ||
1509d42f AD |
13481 | 2002-07-31 Akim Demaille <akim@epita.fr> |
13482 | ||
13483 | Steal GCC's --time-report support. | |
13484 | ||
13485 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: New, | |
13486 | stolen/adjusted from GCC. | |
13487 | * m4/stage.m4: Remove time related checks. | |
13488 | * m4/timevar.m4: New. | |
13489 | * configure.in: Adjust. | |
13490 | * src/system.h: Adjust to using timevar.h. | |
13491 | * src/getargs.h, src/getargs.c: Support trace_time for | |
13492 | --trace=time. | |
13493 | * src/main.c (stage): Remove. | |
13494 | (main): Replace `stage' invocations with timevar calls. | |
13495 | * src/output.c: Insert pertinent timevar calls. | |
13496 | ||
273a74fa AD |
13497 | 2002-07-31 Akim Demaille <akim@epita.fr> |
13498 | ||
13499 | Let --trace have arguments. | |
13500 | ||
13501 | * src/getargs.h (enum trace_e): New. | |
13502 | * src/getargs.c (trace_args, trace_types, trace_argmatch): New. | |
13503 | (long_options, short_options): --trace/-T takes an optional | |
13504 | argument. | |
13505 | Change all the uses of trace_flag to reflect the new flags. | |
13506 | * tests/sets.at (Firsts, Nullable, Broken Closure): Use --trace=sets. | |
13507 | ||
13508 | Strengthen `stage' portability. | |
13509 | ||
13510 | * m4/stage.m4 (BISON_PREREQ_STAGE): New. | |
13511 | * configure.in: Use it. | |
13512 | Don't check for malloc.h and sys/times.h. | |
13513 | * src/system.h: Include them when appropriate. | |
13514 | * src/main.c (stage): Compile only when mallinfo, struct mallinfo, | |
13515 | times and struct tms are available. | |
13516 | ||
217598da AD |
13517 | 2002-07-30 Akim Demaille <akim@epita.fr> |
13518 | ||
13519 | In verbose parse error message, don't report `error' as an | |
13520 | expected token. | |
13521 | * tests/actions.at (Printers and Destructors): Adjust. | |
13522 | * tests/calc.at (Calculator $1): Adjust. | |
13523 | * data/yacc.c, data/glr.c, data/lalr1.c: When making the verbose | |
13524 | error message, do not report the parser accepts the error token in | |
13525 | that state. | |
13526 | ||
52489d44 AD |
13527 | 2002-07-30 Akim Demaille <akim@epita.fr> |
13528 | ||
13529 | Normalize conflict related messages. | |
13530 | ||
13531 | * src/complain.h, src/complain.c (warn, complain): New. | |
13532 | * src/conflicts.c (conflicts_print): Use them. | |
13533 | (conflict_report_yacc): New, extracted from... | |
13534 | (conflicts_print): here. | |
13535 | * tests/conflicts.at, tests/existing.at: Adjust. | |
13536 | ||
e8832397 AD |
13537 | 2002-07-30 Akim Demaille <akim@epita.fr> |
13538 | ||
13539 | Report rules which are never reduced by the parser: those hidden | |
13540 | by conflicts. | |
13541 | ||
13542 | * src/LR0.c (save_reductions): Don't make the final state too | |
13543 | different: save its reduction (accept) instead of having a state | |
13544 | without any action (no shift or goto, no reduce). | |
13545 | Note: the final state is now a ``regular'' state, i.e., the | |
13546 | parsers now contain `reduce 0' as default reduction. | |
13547 | Nevertheless, since they decide to `accept' when yystate = | |
13548 | final_state, they still will not reduce rule 0. | |
13549 | * src/print.c (print_actions, print_reduction): Adjust. | |
13550 | * src/output.c (action_row): Track reduced rules. | |
13551 | (token_actions): Report rules never reduced. | |
13552 | * tests/conflicts.at, tests/regression.at: Adjust. | |
13553 | ||
caf23d24 AD |
13554 | 2002-07-30 Akim Demaille <akim@epita.fr> |
13555 | ||
13556 | `stage' was accidently included in a previous patch. | |
13557 | Initiate its autoconfiscation. | |
13558 | ||
13559 | * configure.in: Look for malloc.h and sys/times.h. | |
13560 | * src/main.c (stage): Adjust. | |
13561 | Report only when trace_flag. | |
13562 | ||
640748ee AD |
13563 | 2002-07-29 Akim Demaille <akim@epita.fr> |
13564 | ||
13565 | * src/state.h, src/state.c (transitions_t): Holds state_t*'s, not | |
13566 | state_number_t. | |
13567 | (errs_t): symbol_t*, not symbol_number_t. | |
13568 | (reductions_t): rule_t*, not rule_number_t. | |
13569 | (FOR_EACH_SHIFT): New. | |
13570 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/output.c | |
13571 | * src/print.c, src/print_graph.c: Adjust. | |
13572 | ||
88bce5a2 AD |
13573 | 2002-07-29 Akim Demaille <akim@epita.fr> |
13574 | ||
13575 | Use $accept and $end, as BYacc and BTYacc do, instead of $axiom and $. | |
13576 | ||
13577 | * src/symtab.h, src/symtab.c (eoftoken, axiom): Rename as... | |
13578 | (endtoken, accept): these. | |
13579 | * src/reader.c (reader): Set endtoken's default tag to "$end". | |
13580 | Set undeftoken's tag to "$undefined" instead of "$undefined.". | |
13581 | * doc/bison.texinfo (Table of Symbols): Mention $accept and $end. | |
13582 | Adjust. | |
13583 | ||
1bfb97db AD |
13584 | 2002-07-29 Akim Demaille <akim@epita.fr> |
13585 | ||
13586 | * src/reduce.c (reduce_grammar): When the language is empty, | |
13587 | complain about the start symbol, not the axiom. | |
13588 | Use its location. | |
13589 | * tests/reduce.at (Empty Language): New. | |
13590 | ||
fc5734fe AD |
13591 | 2002-07-26 Akim Demaille <akim@epita.fr> |
13592 | ||
13593 | * src/reader.h, src/reader.c (gram_error): ... can't get | |
13594 | yycontrol without making too strong assumptions on the parser | |
13595 | itself. | |
13596 | * src/output.c (prepare_tokens): Use the real 0th value of | |
13597 | token_translations instead of `0'. | |
13598 | * src/parse-gram.y (yyerror): Don't rely on yycontrol being | |
13599 | visible here. | |
13600 | * data/yacc.c (yyreport_parse_error): Rename yylocation as yylloc | |
13601 | for the time being: %locations ought to provide it to yyerror. | |
13602 | ||
3650b4b8 AD |
13603 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13604 | ||
13605 | * src/output.c (prepare_tokens): Go up to ntokens, not ntokens + 1. | |
13606 | * doc/bison.texinfo (Decl Summary): s/$illegal/$undefined./. | |
13607 | * tests/regression.at (Web2c Actions): Adjust. | |
13608 | ||
4b3d3a8e AD |
13609 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13610 | ||
13611 | Stop storing rules from 1 to nrules + 1. | |
13612 | ||
13613 | * src/LR0.c, src/closure.c, src/derives.c, src/gram.c, src/lalr.c | |
13614 | * src/nullable.c, src/output.c, src/print.c, src/reader.c | |
13615 | * src/reduce.c: Allocate and free from &rules[0], not &rules[1]. | |
13616 | Iterate from 0 to nrules. | |
13617 | Use rule_number_as_item_number and item_number_as_rule_number. | |
13618 | Adjust to `derive' now containing possibly 0. | |
13619 | * src/gram.h (rule_number_as_item_number, item_number_as_rule_number): | |
13620 | Handle the `- 1' part in rule numbers from/to item numbers. | |
13621 | * src/conflicts.c (log_resolution): Fix the message which reversed | |
13622 | shift and reduce. | |
13623 | * src/output.c (action_row): Initialize default_rule to -1. | |
13624 | (token_actions): Adjust. | |
13625 | * tests/sets.at (Nullable, Firsts): Fix the previously bogus | |
13626 | expected output. | |
13627 | * tests/conflicts.at (Resolved SR Conflicts): Likewise. | |
13628 | ||
4a2a22f4 AD |
13629 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13630 | ||
13631 | * data/c.m4 (b4_c_function, b4_c_ansi_args, b4_c_ansi_arg) | |
13632 | (b4_c_knr_arg_names, b4_c_knr_arg_name, b4_c_knr_arg_decls) | |
13633 | (b4_c_knr_arg_decl): New. | |
13634 | * data/yacc.c: Use it to define yysymprint, yydestruct, and | |
13635 | yyreport_parse_error. | |
13636 | ||
b8df3223 AD |
13637 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13638 | ||
13639 | * data/yacc.c (yyreport_parse_error): New, extracted from... | |
13640 | (yyparse): here. | |
13641 | (yydestruct, yysymprint): Move above yyparse. | |
13642 | Be K&R compliant. | |
13643 | ||
a762e609 AD |
13644 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13645 | ||
13646 | * data/c.m4 (b4_ints_in, b4_int_type, b4_int_type_for): New, | |
13647 | replace... | |
13648 | (b4_sint_type, b4_uint_type): these. | |
13649 | * data/yacc.c, data/glr.c, data/lalr1.cc: Use b4_int_type_for. | |
13650 | * tests/regression.at (Web2c Actions): Adjust. | |
13651 | ||
12b0043a AD |
13652 | 2002-07-25 Akim Demaille <akim@epita.fr> |
13653 | ||
13654 | * src/gram.h (TIEM_NUMBER_MAX): New. | |
13655 | (item_number_of_rule_number, rule_number_of_item_number): Rename | |
13656 | as... | |
13657 | (rule_number_as_item_number, item_number_as_rule_number): these. | |
13658 | Adjust dependencies. | |
13659 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
13660 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
13661 | (symbol_number_to_vector_number): New. | |
13662 | (order): Of vector_number_t* type. | |
13663 | (base_t, BASE_MAX, BASE_MIN): New. | |
13664 | (froms, tos, width, pos, check): Of base_t type. | |
13665 | (action_number_t, ACTION_MIN, ACTION_MAX): New. | |
13666 | (actrow): Of action_number_t type. | |
13667 | (conflrow): Of unsigned int type. | |
13668 | (table_ninf, base_ninf): New. | |
13669 | (GENERATE_MUSCLE_INSERT_TABLE): Also output the `*_min' value. | |
13670 | (muscle_insert_int_table, muscle_insert_base_table) | |
13671 | (muscle_insert_rule_number_table): New. | |
13672 | (prepare_tokens): Output `toknum' as int_table. | |
13673 | (action_row): Returns a rule_number_t. | |
13674 | Use ACTION_MIN, not SHRT_MIN. | |
13675 | (token_actions): yydefact is rule_number_t*. | |
13676 | (table_ninf_remap): New. | |
13677 | (pack_table): Use it for `base' and `table'. | |
13678 | * data/yacc.c, data/glr.c, data/lalr1.cc (YYFLAG): Remove, | |
13679 | replaced with... | |
13680 | (YYPACT_NINF, YYTABLE_NINF): these. | |
13681 | (yypact, yytable): Compute their types instead of hard-coded | |
13682 | `short'. | |
13683 | * tests/regression.at (Web2c Actions): Adjust. | |
13684 | ||
5dde258a AD |
13685 | 2002-07-19 Akim Demaille <akim@epita.fr> |
13686 | ||
13687 | * src/scan-gram.l (id): Can start with an underscore. | |
13688 | ||
a945ec39 AD |
13689 | 2002-07-16 Akim Demaille <akim@epita.fr> |
13690 | ||
13691 | * src/assoc.c, src/asssoc.h (assoc_t, assoc_to_string): New. | |
13692 | Adjust all former `associativity' dependencies. | |
13693 | * src/symtab.c (symbol_new): Default associativity is `undef', not | |
13694 | `right'. | |
13695 | (symbol_check_alias_consistence): Adjust. | |
13696 | ||
fae437e8 AD |
13697 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13698 | ||
13699 | * doc/bison.texinfo: Properly set the ``header'' part. | |
13700 | Use @dircategory ``GNU programming tools'' as per Texinfo's | |
13701 | documentation. | |
13702 | Use @copying. | |
13703 | ||
1a715ef2 AD |
13704 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13705 | ||
13706 | * lib/quotearg.h: Protect against multiple inclusions. | |
13707 | * src/location.h (location_t): Add a `file' member. | |
13708 | (LOCATION_RESET, LOCATION_PRINT): Adjust. | |
13709 | * src/complain.c (warn_at, complain_at, fatal_at): Drop | |
13710 | `error_one_per_line' support. | |
13711 | ||
a5d50994 AD |
13712 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13713 | ||
13714 | * src/complain.h, src/complain.c (warn, complain): Remove, unused. | |
13715 | * src/reader.c (lineno): Remove. | |
13716 | Adjust all dependencies. | |
13717 | (get_merge_function): Take a location and use complain_at. | |
13718 | * src/symtab.h, src/symtab.c (symbol_make_alias): Likewise. | |
13719 | * tests/regression.at (Invalid inputs, Mixing %token styles): | |
13720 | Adjust. | |
13721 | ||
b275314e AD |
13722 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13723 | ||
13724 | * src/parse-gram.y (rules_or_grammar_declaration): Add an error | |
13725 | recovery rule, and forbid extensions when --yacc. | |
13726 | (gram_error): Use complain_at. | |
13727 | * src/reader.c (reader): Exit if there were parse errors. | |
13728 | ||
865b9df1 AD |
13729 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13730 | ||
13731 | * tests/synclines.at (AT_SYNCLINES_COMPILE): New. | |
13732 | (AT_TEST_SYNCLINE): Adjust to unusual GCC outputs. | |
13733 | Reported by R Blake <blakers@mac.com>. | |
13734 | ||
c76e14da AD |
13735 | 2002-07-09 Akim Demaille <akim@epita.fr> |
13736 | ||
13737 | * data/yacc.c: Output the copyright notive in the header. | |
13738 | ||
7db2ed2d AD |
13739 | 2002-07-03 Akim Demaille <akim@epita.fr> |
13740 | ||
13741 | * src/output.c (froms, tos): Are state_number_t. | |
13742 | (save_column): sp, sp1, and sp2 are state_number_t. | |
13743 | (prepare): Rename `final' as `final_state_number', `nnts' as | |
13744 | `nterms_number', `nrules' as `rules_number', `nstates' as | |
13745 | `states_number', and `ntokens' as `tokens_number'. Remove `nsym', | |
13746 | unused. | |
13747 | * data/yacc.c, data/glr.c, data/lalr1.cc: Adjust. | |
13748 | * data/lalr1.cc (nsym_): Remove, unused. | |
13749 | ||
e68e0410 AD |
13750 | 2002-07-03 Akim Demaille <akim@epita.fr> |
13751 | ||
13752 | * src/lalr.h, src/lalr.c (goto_number_t): New. | |
13753 | * src/lalr.c (goto_list_t): New. | |
13754 | Propagate them. | |
13755 | * src/nullable.c (rule_list_t): New. | |
13756 | Propagate. | |
13757 | * src/types.h: Remove. | |
13758 | ||
e1a4f3a4 AD |
13759 | 2002-07-03 Akim Demaille <akim@epita.fr> |
13760 | ||
13761 | * src/closure.c (print_fderives): Use rule_rhs_print. | |
13762 | * src/derives.c (print_derives): Use rule_rhs_print. | |
13763 | (rule_list_t): New, replaces `shorts'. | |
13764 | (set_derives): Add comments. | |
13765 | * tests/sets.at (Nullable, Firsts): Adjust. | |
13766 | ||
536545f3 AD |
13767 | 2002-07-03 Akim Demaille <akim@epita.fr> |
13768 | ||
13769 | * src/output.c (prepare_actions): Free `tally' and `width'. | |
13770 | (prepare_actions): Allocate and free `order'. | |
13771 | * src/symtab.c (symbols_free): Free `symbols'. | |
13772 | * src/scan-gram.l (scanner_free): Clear Flex's scanners memory. | |
13773 | * src/output.c (m4_invoke): Move to... | |
13774 | * src/scan-skel.l: here. | |
13775 | (<<EOF>>): Close yyout, and free its name. | |
13776 | ||
8b752b00 AD |
13777 | 2002-07-03 Akim Demaille <akim@epita.fr> |
13778 | ||
13779 | Fix some memory leaks, and fix a bug: state 0 was examined twice. | |
13780 | ||
13781 | * src/LR0.c (new_state): Merge into... | |
13782 | (state_list_append): this. | |
13783 | (new_states): Merge into... | |
13784 | (generate_states): here. | |
13785 | (set_states): Don't ensure a proper `errs' state member here, do it... | |
13786 | * src/conflicts.c (conflicts_solve): here. | |
13787 | * src/state.h, src/state.c: Comment changes. | |
13788 | (state_t): Rename member `shifts' as `transitions'. | |
13789 | Adjust all dependencies. | |
13790 | (errs_new): For consistency, also take the values as argument. | |
13791 | (errs_dup): Remove. | |
13792 | (state_errs_set): New. | |
13793 | (state_reductions_set, state_transitions_set): Assert that no | |
13794 | previous value was assigned. | |
13795 | (state_free): New. | |
13796 | (states_free): Use it. | |
13797 | * src/conflicts.c (resolve_sr_conflict): Don't use an `errs_t' as | |
13798 | temporary storage: use `errs' and `nerrs' as elsewhere. | |
13799 | (set_conflicts): Allocate and free this `errs'. | |
13800 | ||
613f5e1a AD |
13801 | 2002-07-02 Akim Demaille <akim@epita.fr> |
13802 | ||
13803 | * lib/libiberty.h: New. | |
13804 | * lib: Update the bitset implementation from upstream. | |
13805 | * src/closure.c, src/lalr.c, src/output.c, src/print_graph.c, | |
13806 | * src/state.c: Use BITSET_FOR_EACH, not BITSET_EXECUTE. | |
13807 | * src/main.c: Adjust bitset stats calls. | |
13808 | ||
26e0cadc PE |
13809 | 2002-07-01 Paul Eggert <eggert@twinsun.com> |
13810 | ||
13811 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>): Convert to unsigned | |
13812 | char, so that negative chars don't collide with $. | |
13813 | ||
1154cced AD |
13814 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13815 | ||
13816 | Have the GLR tests be `warning' checked, and fix the warnings. | |
13817 | ||
13818 | * data/glr.c (YYFPRINTF): Always define it, not only when YYDEBUG | |
13819 | (yyuserAction, yyreportAmbiguity): `Use' all the arguments. | |
13820 | (yyremoveDeletes): `yyi' and `yyj' are size_t. | |
13821 | Use YYFPRINTF when under if (YYDEBUG) to avoid empty `if' bodies. | |
13822 | (yyaddDeferredAction): static. | |
13823 | (yyglrReduce): yyi, yyk, amd yyposn are size_t. | |
13824 | (yyreportParseError): yyprefix is const. | |
13825 | yytokenp is used only when verbose. | |
13826 | (yy__GNUC__): Replace with __GNUC__. | |
13827 | (yypdumpstack): yyi is size_t. | |
13828 | (yypreference): Un-yy local variables and arguments, to avoid | |
13829 | clashes with `yyr1'. Anyway, we are not in the user name space. | |
13830 | (yytname_size): be an int, as is compared with ints. | |
13831 | * tests/testsuite.at (AT_COMPILE, AT_PARSER_CHECK): New. | |
13832 | Use them. | |
13833 | * tests/cxx-gram.at: Use quotation to protect $1. | |
13834 | Use AT_COMPILE to enable warnings hunts. | |
13835 | Prototype yylex and yyerror. | |
13836 | `Use' argc. | |
13837 | Include `string.h', not `strings.h'. | |
13838 | Produce and prototype stmtMerge only when used. | |
13839 | yylex takes a location. | |
13840 | ||
97650f4e AD |
13841 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13842 | ||
13843 | We spend a lot of time in quotearg, in particular when --verbose. | |
13844 | ||
13845 | * src/symtab.c (symbol_get): Store a quoted version of the key. | |
13846 | (symbol_tag_get, symbol_tag_get_n, symbol_tag_print): Remove. | |
13847 | Adjust all callers. | |
13848 | ||
d2576365 AD |
13849 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13850 | ||
13851 | * src/state.h (reductions_t): Rename member `nreds' as num. | |
13852 | (errs_t): Rename members `nerrs' and `errs' as `num' and `symbols'. | |
13853 | * src/state.c (ERRS_ALLOC, REDUCTIONS_ALLOC): Use the correct types. | |
13854 | ||
ccaf65bc AD |
13855 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13856 | ||
13857 | * src/state.h, src/state.c (shift_t, SHIFT_SYMBOL, SHIFT_IS_SHIFT) | |
13858 | (SHIFT_IS_GOTO, SHIFT_IS_ERROR, SHIFT_DISABLE, SHIFT_IS_DISABLED) | |
13859 | (shifts_to): Rename as... | |
13860 | (transition_t, TRANSITION_SYMBOL, TRANSITION_IS_TRANSITION) | |
13861 | (TRANSITION_IS_GOTO, TRANSITION_IS_ERROR, TRANSITION_DISABLE) | |
13862 | (TRANSITION_IS_DISABLED, transitions_to): these. | |
13863 | ||
87675353 AD |
13864 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13865 | ||
13866 | * src/print.c (print_shifts, print_gotos): Merge into... | |
13867 | (print_transitions): this. | |
13868 | (print_transitions, print_errs, print_reductions): Align the | |
13869 | lookaheads columns. | |
13870 | (print_core, print_transitions, print_errs, print_state, | |
13871 | print_grammar): Output empty lines separator before, not after. | |
13872 | (state_default_rule_compute): Rename as... | |
13873 | (state_default_rule): this. | |
13874 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
13875 | (Unresolved SR Conflicts, Resolved SR Conflicts): Adjust. | |
13876 | * tests/regression.at (Rule Line Numbers, Web2c Report): Adjust. | |
13877 | ||
ce4ccb4b AD |
13878 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13879 | ||
13880 | Display items as we display rules. | |
13881 | ||
13882 | * src/gram.h, src/gram.c (rule_lhs_print): New. | |
13883 | * src/gram.c (grammar_rules_partial_print): Use it. | |
13884 | * src/print.c (print_core): Likewise. | |
13885 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
13886 | (Unresolved SR Conflicts): Adjust. | |
13887 | (Unresolved SR Conflicts): Adjust and rename as... | |
13888 | (Resolved SR Conflicts): this, as was meant. | |
13889 | * tests/regression.at (Web2c Report): Adjust. | |
13890 | ||
bc933ef1 AD |
13891 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13892 | ||
13893 | * src/print.c (state_default_rule_compute): New, extracted from... | |
13894 | (print_reductions): here. | |
13895 | Pessimize, but clarify the code. | |
13896 | * tests/conflicts.at (Defaulted Conflicted Reduction): New. | |
13897 | ||
53d4308d AD |
13898 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13899 | ||
13900 | * src/output.c (action_row): Let default_rule be always a rule | |
13901 | number. | |
13902 | ||
574fb2d5 AD |
13903 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13904 | ||
13905 | * src/closure.c (print_firsts, print_fderives, closure): | |
13906 | Use BITSET_EXECUTE. | |
13907 | * src/lalr.c (lookaheads_print): Likewise. | |
13908 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
13909 | * src/print_graph.c (print_core): Likewise. | |
13910 | * src/print.c (print_reductions): Likewise. | |
13911 | * src/output.c (action_row): Likewise. | |
13912 | Use SHIFT_IS_DISABLED, SHIFT_IS_SHIFT and SHIFT_SYMBOL. | |
13913 | ||
05811fd7 AD |
13914 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13915 | ||
13916 | * src/print_graph.c: Use report_flag. | |
13917 | ||
0e4d5753 AD |
13918 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13919 | ||
13920 | * src/lalr.c (traverse, digraph, matrix_print, transpose): Move | |
13921 | to... | |
13922 | * src/relation.h, src/relation.c (traverse, relation_digraph) | |
13923 | (relation_print, relation_transpose): New. | |
13924 | ||
24c7d800 AD |
13925 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13926 | ||
13927 | * src/state.h, src/state.c (shifts_to): New. | |
13928 | * src/lalr.c (build_relations): Use it. | |
13929 | ||
9222837b AD |
13930 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13931 | ||
13932 | * src/gram.h (rule_number_t, RULE_NUMBER_MAX, int_of_rule_number) | |
13933 | (item_number_of_rule_number, rule_number_of_item_number): New. | |
13934 | * src/LR0.c, src/closure.c, src/derives.c, src/derives.h, | |
13935 | * src/gram.c, src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
13936 | * src/print_graph.c, src/reader.c, src/reduce.c, src/reduce.h: | |
13937 | Propagate their use. | |
13938 | Much remains to be done, in particular wrt `shorts' from types.h. | |
13939 | ||
260008e5 AD |
13940 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13941 | ||
13942 | * src/symtab.c (symbol_new): Initialize the `printer' member. | |
13943 | ||
8a731ca8 AD |
13944 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13945 | ||
13946 | * src/LR0.c (save_reductions): Remove, replaced by... | |
13947 | * src/state.h, src/state.c (state_reductions_set): New. | |
13948 | (reductions, errs): Rename as... | |
13949 | (reductions_t, errs_t): these. | |
13950 | Adjust all dependencies. | |
13951 | ||
32e1e0a4 AD |
13952 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13953 | ||
13954 | * src/LR0.c (state_list_t, state_list_append): New. | |
13955 | (first_state, last_state): Now symbol_list_t. | |
13956 | (this_state): Remove. | |
13957 | (new_itemsets, append_states, save_reductions): Take a state_t as | |
13958 | argument. | |
13959 | (set_states, generate_states): Adjust. | |
13960 | (save_shifts): Remove, replaced by... | |
13961 | * src/state.h, src/state.c (state_shifts_set): New. | |
13962 | (shifts): Rename as... | |
13963 | (shifts_t): this. | |
13964 | Adjust all dependencies. | |
13965 | * src/state.h (state_t): Remove the `next' member. | |
13966 | ||
e5fb6710 AD |
13967 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13968 | ||
13969 | * src/vcg.c (quote): Use slot 2, since we often pass symbol tag | |
13970 | escaped in slot 0. | |
13971 | ||
c7ca99d4 AD |
13972 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13973 | ||
13974 | Use hash.h for the state hash table. | |
13975 | ||
13976 | * src/LR0.c (STATE_HASH_SIZE, state_hash): Remove. | |
13977 | (allocate_storage): Use state_hash_new. | |
13978 | (free_storage): Use state_hash_free. | |
13979 | (new_state, get_state): Adjust. | |
13980 | * src/lalr.h, src/lalr.c (states): Move to... | |
13981 | * src/states.h (state_t): Remove the `link' member, no longer | |
13982 | used. | |
13983 | * src/states.h, src/states.c: here. | |
13984 | (state_hash_new, state_hash_free, state_hash_lookup) | |
13985 | (state_hash_insert, states_free): New. | |
13986 | * src/states.c (state_table, state_compare, state_hash): New. | |
13987 | * src/output.c (output_actions): Do not free states now, since we | |
13988 | still need to know the final_state number in `prepare', called | |
13989 | afterwards. Do it... | |
13990 | * src/main.c (main): here: call states_free after `output'. | |
13991 | ||
df0e7316 AD |
13992 | 2002-06-30 Akim Demaille <akim@epita.fr> |
13993 | ||
13994 | * src/state.h, src/state.c (state_new): New, extracted from... | |
13995 | * src/LR0.c (new_state): here. | |
13996 | * src/state.h (STATE_ALLOC): Move to... | |
13997 | * src/state.c: here. | |
13998 | * src/LR0.h, src/LR0.c (nstates, final_state): Move to... | |
13999 | * src/state.h, src/state.c: here. | |
14000 | ||
39f41916 AD |
14001 | 2002-06-30 Akim Demaille <akim@epita.fr> |
14002 | ||
14003 | * src/reader.c (gensym): Rename as... | |
14004 | * src/symtab.h, src/symtab.c (dummy_symbol_get): this. | |
14005 | (getsym): Rename as... | |
14006 | (symbol_get): this. | |
14007 | ||
d57650a5 AD |
14008 | 2002-06-30 Akim Demaille <akim@epita.fr> |
14009 | ||
14010 | * src/state.h (state_number_t, STATE_NUMBER_MAX): New. | |
14011 | * src/LR0.c, src/LR0.h, src/conflicts.c, src/lalr.c, src/lalr.h, | |
14012 | * src/output.c, src/print.c, src/print_graph.c: Propagate. | |
14013 | * src/LR0.h, src/LR0.h (final_state): Is a state_t*. | |
14014 | ||
5a08f1ce AD |
14015 | 2002-06-30 Akim Demaille <akim@epita.fr> |
14016 | ||
14017 | Make the test suite pass with warnings checked. | |
14018 | ||
14019 | * tests/actions.at (Printers and Destructors): Improve. | |
14020 | Avoid unsigned vs. signed issues. | |
14021 | * tests/calc.at: Don't exercise the scanner here, do it... | |
14022 | * tests/input.at (Torturing the Scanner): here. | |
14023 | ||
720623af PH |
14024 | 2002-06-28 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14025 | ||
88e7e941 | 14026 | * data/glr.c: Correct typo in Emacs-mode directive. Slightly |
720623af PH |
14027 | reorganize first lines parallel to yacc.c. |
14028 | ||
fb8135fa AD |
14029 | 2002-06-28 Akim Demaille <akim@epita.fr> |
14030 | ||
14031 | * data/c.m4 (b4_copyright, b4_sint_type, b4_uint_type, b4_token_define) | |
14032 | (b4_token_enum, b4_token_defines): New, factored from... | |
14033 | * data/lalr1.cc, data/yacc.c, glr.c: here. | |
14034 | ||
41442480 AD |
14035 | 2002-06-28 Akim Demaille <akim@epita.fr> |
14036 | ||
14037 | * data/yacc.c (yydestruct, yysymprint): Pacify GCC warnings for | |
14038 | unused variables. | |
14039 | * src/output.c (merger_output): static. | |
14040 | ||
e0e5bf84 AD |
14041 | 2002-06-28 Akim Demaille <akim@epita.fr> |
14042 | ||
ba0fe3c7 | 14043 | * src/reader.h: s/grammer_current_rule_merge_set/grammar_.../. |
e0e5bf84 AD |
14044 | * src/conflicts.c (conflicts_total_count): `i' is unsigned, to |
14045 | pacify GCC. | |
14046 | * src/output.c (save_row): Initialize all the variables to pacify GCC. | |
e0e5bf84 | 14047 | |
676385e2 PH |
14048 | 2002-06-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14049 | ||
14050 | Accumulated changelog for new GLR parsing features. | |
14051 | ||
6a254321 | 14052 | * src/conflicts.c (count_total_conflicts): Change name to |
676385e2 PH |
14053 | conflicts_total_count. |
14054 | * src/conflicts.h: Ditto. | |
14055 | * src/output.c (token_actions): Use the new name. | |
14056 | (output_conflicts): Change conflp => conflict_list_heads, and | |
14057 | confl => conflict_list for better readability. | |
14058 | * data/glr.c: Use the new names. | |
14059 | * NEWS: Add self to GLR announcement. | |
e0e5bf84 | 14060 | |
676385e2 PH |
14061 | * src/reader.c (free_merger_functions): Cleanup: XFREE->free. |
14062 | ||
14063 | * doc/bison.texinfo (GLR Parsers): Make corrections suggested by | |
14064 | Akim Demaille. | |
14065 | ||
14066 | * data/bison.glr: Change name to glr.c | |
14067 | * data/glr.c: Renamed from bison.glr. | |
14068 | * data/Makefile.am: Add glr.c | |
e0e5bf84 AD |
14069 | |
14070 | * src/getargs.c: | |
14071 | ||
676385e2 | 14072 | * src/symlist.h: Add dprec and merger fields to symbol_list_s. |
ba0fe3c7 | 14073 | * src/symlist.c (symbol_list_new): Initialize dprec and merger fields. |
e0e5bf84 | 14074 | |
676385e2 PH |
14075 | Originally 2002-06-16 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14076 | ||
14077 | * data/bison.glr: Be sure to restore the | |
14078 | current #line when returning to the skeleton contents after having | |
14079 | exposed the input file's #line. | |
14080 | ||
14081 | Originally 2002-06-13 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
14082 | ||
14083 | * data/bison.glr: Bring up to date with changes to bison.simple. | |
14084 | ||
14085 | Originally 2002-06-03 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
14086 | ||
14087 | * data/bison.glr: Correct definitions that use b4_prefix. | |
14088 | Various reformatting. | |
14089 | (GLRStack): Make yychar (in YYPURE case) and yytokenp as part of stack. | |
14090 | (yyreportParseError, yyrecoverParseError, yyprocessOneStack): remove | |
14091 | yytokenp argument; now part of stack. | |
14092 | (yychar): Define to behave as documented. | |
14093 | (yyclearin): Ditto. | |
e0e5bf84 | 14094 | |
676385e2 PH |
14095 | Originally 2002-05-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14096 | ||
14097 | * src/reader.h: Add declaration for free_merger_functions. | |
14098 | ||
14099 | * src/reader.c (merge_functions): New variable. | |
14100 | (get_merge_function): New function. | |
14101 | (free_merger_functions): New function. | |
14102 | (readgram): Check for %prec that is not followed by a symbol. | |
14103 | Handle %dprec and %merge declarations. | |
14104 | (packgram): Initialize dprec and merger fields in rules array. | |
14105 | ||
14106 | * src/output.c (conflict_tos, conflrow, conflict_table, conflict_list, | |
14107 | conflict_list_cnt, conflict_list_free): New variables. | |
14108 | (table_grow): Also grow conflict_table. | |
e0e5bf84 | 14109 | (prepare_rules): Output dprec and merger tables. |
676385e2 | 14110 | (conflict_row): New function. |
e0e5bf84 | 14111 | (action_row): Output conflict lists for GLR parser. Don't use |
676385e2 PH |
14112 | default reduction in conflicted states for GLR parser so that there |
14113 | are spaces for the conflict lists. | |
14114 | (save_row): Also save conflict information. | |
14115 | (token_actions): Allocate conflict list. | |
14116 | (merger_output): New function. | |
14117 | (pack_vector): Pack conflict table, too. | |
14118 | (output_conflicts): New function to output yyconflp and yyconfl. | |
14119 | (output_check): Allocate conflict_tos. | |
14120 | (output_actions): Output conflict tables, also. | |
14121 | (output_skeleton): Output b4_mergers definition. | |
14122 | (prepare): Output b4_max_rhs_length definition. | |
14123 | Use 'bison.glr' as default skeleton for GLR parsers. | |
14124 | ||
14125 | * src/gram.c (glr_parser): New flag. | |
14126 | (grammar_free): Call free_merger_functions. | |
14127 | ||
14128 | * src/conflicts.c (count_rr_conflicts): Augment to optionally count | |
14129 | all pairs of conflicting reductions, rather than just all tokens | |
14130 | causing conflicts. Needed to size conflict tables. | |
e0e5bf84 | 14131 | (conflicts_output): Modify call to count_rr_conflicts for new |
676385e2 PH |
14132 | interface. |
14133 | (conflicts_print): Ditto. | |
14134 | (count_total_conflicts): New function. | |
14135 | ||
14136 | * src/reader.h (merger_list): New type. | |
14137 | (merge_functions): New variable. | |
14138 | ||
14139 | * src/lex.h (tok_dprec, tok_merge): New token types. | |
14140 | ||
14141 | * src/gram.h (rule_s): Add dprec and merger fields. | |
14142 | (glr_parser): New flag. | |
14143 | ||
14144 | * src/conflicts.h (count_total_conflicts): New function. | |
14145 | ||
14146 | * src/options.c (option_table): Add %dprec, %merge, and %glr-parser. | |
14147 | ||
14148 | * doc/bison.texinfo (Generalized LR Parsing): New section. | |
14149 | (GLR Parsers): New section. | |
14150 | (Language and Grammar): Mention GLR parsing. | |
14151 | (Table of Symbols): Add %dprec, %glr-parser, %merge, GLR | |
14152 | Correct typo ("tge" -> "the"). | |
14153 | ||
14154 | * data/bison.glr: New skeleton for GLR parsing. | |
14155 | ||
14156 | * tests/cxx-gram.at: New tests for GLR parsing. | |
14157 | ||
14158 | * tests/testsuite.at: Include cxx-gram.at. | |
14159 | ||
14160 | * tests/Makefile.am: Add cxx-gram.at. | |
e0e5bf84 | 14161 | |
676385e2 PH |
14162 | * src/parse-gram.y: |
14163 | ||
14164 | * src/scan-gram.l: Add %dprec, %glr-parser, %merge. | |
14165 | ||
14166 | * src/parse-gram.y: Grammar for %dprec, %merge, %glr-parser. | |
e0e5bf84 | 14167 | |
b5480d74 | 14168 | 2002-06-27 Akim Demaille <akim@epita.fr> |
e2aaf4c4 AD |
14169 | |
14170 | * src/options.h, src/options.c: Remove. | |
14171 | * src/getargs.c (short_options, long_options): New. | |
14172 | ||
60491a94 AD |
14173 | 2002-06-27 Akim Demaille <akim@epita.fr> |
14174 | ||
14175 | * data/bison.simple, data/bison.c++: Rename as... | |
14176 | * data/yacc.c, data/lalr1.cc: these. | |
14177 | * doc/bison.texinfo (Environment Variables): Remove. | |
14178 | ||
9be0c25b AD |
14179 | 2002-06-25 Raja R Harinath <harinath@cs.umn.edu> |
14180 | ||
14181 | * src/getargs.c (report_argmatch): Initialize strtok(). | |
14182 | ||
1ae72863 AD |
14183 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14184 | ||
14185 | * data/bison.simple (b4_symbol_actions): New, replaces... | |
14186 | (b4_symbol_destructor, b4_symbol_printer): these. | |
14187 | (yysymprint): Be sure to call YYPRINT only for tokens, and using | |
14188 | user token numbers. | |
14189 | ||
87542d29 AD |
14190 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14191 | ||
14192 | * data/bison.simple (yydestructor): Rename as... | |
14193 | (yydestruct): this. | |
14194 | ||
1a31ed21 AD |
14195 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14196 | ||
14197 | * src/symtab.h, src/symtab.c (symbol_type_set) | |
14198 | (symbol_destructor_set, symbol_precedence_set): The location is | |
14199 | the last argument. | |
14200 | Adjust all callers. | |
14201 | ||
e776192e AD |
14202 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14203 | ||
14204 | * src/parse-gram.y (YYPRINT, yyprint): Don't mess with the parser | |
14205 | internals. | |
14206 | * src/reader.h, src/reader.c (grammar_current_rule_prec_set): | |
14207 | Takes a location. | |
14208 | * src/symtab.h, src/symtab.c (symbol_class_set) | |
14209 | (symbol_user_token_number_set): Likewise. | |
14210 | Adjust all callers. | |
14211 | Promote complain_at. | |
14212 | * tests/input.at (Type Clashes): Adjust. | |
14213 | ||
5c1180b3 AD |
14214 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14215 | ||
14216 | * data/bison.simple (YYLEX): Fix the declaration when | |
14217 | %pure-parser. | |
14218 | ||
e3170060 AD |
14219 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14220 | ||
14221 | * data/bison.simple (yysymprint): Don't print the token number, | |
14222 | just its name. | |
14223 | * tests/actions.at (Destructors): Rename as... | |
14224 | (Printers and Destructors): this. | |
14225 | Also exercise %printer. | |
14226 | ||
253862fd AD |
14227 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14228 | ||
14229 | * data/bison.simple (YYDSYMPRINT): New. | |
14230 | Use it to remove many of the #if YYDEBUG/if (yydebug). | |
14231 | ||
366eea36 AD |
14232 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14233 | ||
14234 | * src/symtab.h, src/symtab.c (symbol_t): printer and | |
14235 | printer_location are new members. | |
14236 | (symbol_printer_set): New. | |
14237 | * src/parse-gram.y (PERCENT_PRINTER): New token. | |
14238 | Handle its associated rule. | |
14239 | * src/scan-gram.l: Adjust. | |
14240 | (handle_destructor_at, handle_destructor_dollar): Rename as... | |
14241 | (handle_symbol_code_at, handle_symbol_code_dollar): these. | |
14242 | * src/output.c (symbol_printers_output): New. | |
14243 | (output_skeleton): Call it. | |
14244 | * data/bison.simple (yysymprint): New. Cannot be named yyprint | |
14245 | since there are already many grammar files with a user `yyprint'. | |
14246 | Replace the calls to YYPRINT to calls to yysymprint. | |
14247 | * tests/calc.at: Adjust. | |
14248 | * tests/torture.at (AT_DATA_STACK_TORTURE): Remove YYPRINT: it was | |
14249 | taking advantage of parser very internal details (stack size!). | |
14250 | ||
4f25ebb0 AD |
14251 | 2002-06-20 Akim Demaille <akim@epita.fr> |
14252 | ||
14253 | * src/scan-gram.l: Complete the scanner with the missing patterns | |
14254 | to pacify Flex. | |
14255 | Use `quote' and `symbol_tag_get' where appropriate. | |
14256 | ||
93b68a0e AD |
14257 | 2002-06-19 Akim Demaille <akim@epita.fr> |
14258 | ||
14259 | * tests/actions.at (Destructors): Augment to test locations. | |
14260 | * data/bison.simple (yydestructor): Pass it the current location | |
14261 | if locations are enabled. | |
14262 | Prototype only when __STDC__ or C++. | |
14263 | Change the argument names to move into the yy name space: there is | |
14264 | user code here. | |
14265 | ||
58612f1d AD |
14266 | 2002-06-19 Akim Demaille <akim@epita.fr> |
14267 | ||
74310291 AD |
14268 | * data/bison.simple (b4_pure_if): New. |
14269 | Use it instead of #ifdef YYPURE. | |
14270 | ||
14271 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
14272 | ||
14273 | * data/bison.simple (b4_location_if): New. | |
58612f1d AD |
14274 | Use it instead of #ifdef YYLSP_NEEDED. |
14275 | ||
f25bfb75 AD |
14276 | 2002-06-19 Akim Demaille <akim@epita.fr> |
14277 | ||
14278 | Prepare @$ in %destructor, but currently don't bind it in the | |
14279 | skeleton, as %location use is not cleaned up yet. | |
14280 | ||
14281 | * src/scan-gram.l (handle_dollar, handle_destructor_at) | |
14282 | (handle_action_at): New. | |
14283 | (handle_at, handle_action_dollar, handle_destructor_dollar): Take | |
14284 | a braced_code_t and a location as additional arguments. | |
14285 | (handle_destructor_dollar): Instead of requiring `b4_eval', just | |
14286 | unquote one when outputting `b4_dollar_dollar'. | |
14287 | Adjust callers. | |
14288 | * data/bison.simple (b4_eval): Remove. | |
14289 | (b4_symbol_destructor): Adjust. | |
14290 | * tests/input.at (Invalid @n): Adjust. | |
14291 | ||
c732d2c6 AD |
14292 | 2002-06-19 Zack Weinberg <zack@codesourcery.com> |
14293 | ||
14294 | * doc/bison.texinfo: Document ability to have multiple | |
14295 | prologue sections. | |
14296 | ||
8c165d89 AD |
14297 | 2002-06-18 Akim Demaille <akim@epita.fr> |
14298 | ||
14299 | * src/files.c (compute_base_names): When computing the output file | |
14300 | names from the input file name, strip the directory part. | |
14301 | ||
ca98bf57 AD |
14302 | 2002-06-18 Akim Demaille <akim@epita.fr> |
14303 | ||
14304 | * data/bison.simple.new: Comment changes. | |
14305 | Reported by Andreas Schwab. | |
14306 | ||
0bfb02ff AD |
14307 | 2002-06-18 Matt Kraai <kraai@alumni.cmu.edu> |
14308 | ||
14309 | * data/bison.simple (yyoverflowlab): #ifndef yyoverflow, so that | |
14310 | there are no `label `yyoverflowlab' defined but not used' warnings | |
14311 | when yyoverflow is defined. | |
14312 | ||
24c0aad7 AD |
14313 | 2002-06-18 Akim Demaille <akim@epita.fr> |
14314 | ||
14315 | * src/symtab.h, src/symtab.c (symbol_t): destructor_location is a | |
14316 | new member. | |
14317 | (symbol_destructor_set): Adjust. | |
14318 | * src/output.c (symbol_destructors_output): Output the destructor | |
14319 | locations. | |
14320 | Output the symbol name. | |
14321 | * data/bison.simple (b4_symbol_destructor): Adjust. | |
14322 | ||
5719c109 AD |
14323 | 2002-06-18 Cris Bailiff <c.bailiff@awayweb.com> |
14324 | and Akim Demaille <akim@epita.fr> | |
14325 | ||
14326 | * data/bison.simple.new (yyerrlab1): Be sure to pop and destroy | |
14327 | what's left on the stack when the error recovery hits EOF. | |
14328 | * tests/actions.at (Destructors): Complete to exercise this case. | |
14329 | ||
9280d3ef AD |
14330 | 2002-06-17 Akim Demaille <akim@epita.fr> |
14331 | ||
14332 | * data/m4sugar/m4sugar.m4 (m4_map): Recognize when the list of | |
14333 | arguments is really empty, not only equal to `[]'. | |
14334 | * src/symtab.h, src/symtab.c (symbol_t): `destructor' is a new | |
14335 | member. | |
14336 | (symbol_destructor_set): New. | |
14337 | * src/output.c (symbol_destructors_output): New. | |
14338 | * src/reader.h (brace_code_t, current_braced_code): New. | |
14339 | * src/scan-gram.l (BRACED_CODE): Use it to branch on... | |
14340 | (handle_dollar): Rename as... | |
14341 | (handle_action_dollar): this. | |
14342 | (handle_destructor_dollar): New. | |
14343 | * src/parse-gram.y (PERCENT_DESTRUCTOR): New. | |
14344 | (grammar_declaration): Use it. | |
14345 | * data/bison.simple (yystos): Is always defined. | |
14346 | (yydestructor): New. | |
14347 | * tests/actions.at (Destructors): New. | |
14348 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Don't rely on egrep. | |
14349 | ||
dafdc66f AD |
14350 | 2002-06-17 Akim Demaille <akim@epita.fr> |
14351 | ||
14352 | * src/symlist.h, src/symlist.c (symbol_list_length): New. | |
14353 | * src/scan-gram.l (handle_dollar, handle_at): Compute the | |
14354 | rule_length only when needed. | |
14355 | * src/output.c (actions_output, token_definitions_output): Output | |
14356 | the full M4 block. | |
14357 | * src/symtab.c: Don't access directly to the symbol tag, use | |
14358 | symbol_tag_get. | |
14359 | * src/parse-gram.y: Use symbol_list_free. | |
14360 | ||
56c47203 AD |
14361 | 2002-06-17 Akim Demaille <akim@epita.fr> |
14362 | ||
14363 | * src/reader.h, src/reader.c (symbol_list, symbol_list_new) | |
14364 | (symbol_list_prepend, get_type_name): Move to... | |
14365 | * src/symlist.h, src/symlist.c (symbol_list_t, symbol_list_new) | |
14366 | (symbol_list_prepend, symbol_list_n_type_name_get): here. | |
14367 | Adjust all callers. | |
14368 | (symbol_list_free): New. | |
14369 | * src/scan-gram.l (handle_dollar): Takes a location. | |
14370 | * tests/input.at (Invalid $n): Adjust. | |
14371 | ||
1e0bab92 AD |
14372 | 2002-06-17 Akim Demaille <akim@epita.fr> |
14373 | ||
14374 | * src/reader.h, src/reader.c (symbol_list_new): Export it. | |
14375 | (symbol_list_prepend): New. | |
14376 | * src/parse-gram.y (%union): `list' is a new member. | |
14377 | (symbols.1): New, replaces... | |
14378 | (terms_to_prec.1, nterms_to_type.1): these. | |
14379 | * src/symtab.h, src/symtab.c (symbol_type_set, symbol_precedence_set) | |
14380 | Take a location as additional argument. | |
14381 | Adjust all callers. | |
14382 | ||
04e60654 AD |
14383 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14384 | ||
14385 | * src/parse-gram.y: Move %token in the declaration section so that | |
14386 | we don't depend upon CVS Bison. | |
14387 | ||
10e5b8bd AD |
14388 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14389 | ||
14390 | * src/state.h, src/state.c (state_rule_lookaheads_print): New. | |
14391 | * src/print.c (print_core): Use it. | |
14392 | ||
9801d40c AD |
14393 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14394 | ||
14395 | * src/conflicts.c (log_resolution): Accept the rule involved in | |
14396 | the sr conflicts instead of the lookahead number that points to | |
14397 | that rule. | |
14398 | (flush_reduce): Accept the current lookahead vector as argument, | |
14399 | instead of the index in LA. | |
14400 | (resolve_sr_conflict): Accept the current number of lookahead | |
14401 | bitset to consider for the STATE, instead of the index in LA. | |
14402 | (set_conflicts): Adjust. | |
14403 | * src/lalr.c, src/lalr.h, src/state.h: Comment changes. | |
14404 | ||
c0263492 AD |
14405 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14406 | ||
14407 | * src/state.h (state_t): Replace the `lookaheadsp' member, a | |
14408 | short, with `lookaheads' (bitsetv), `lookaheads_rule' (rule_t**). | |
14409 | Adjust all dependencies. | |
14410 | * src/lalr.c (initialize_lookaheads): Split into... | |
14411 | (states_lookaheads_count, states_lookaheads_initialize): these. | |
14412 | (lalr): Adjust. | |
14413 | ||
9757c359 AD |
14414 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14415 | ||
14416 | * src/gram.h, src/gram.c (grammar_rules_partial_print): New, eved | |
14417 | out of... | |
14418 | (grammar_rules_print): here. | |
14419 | * src/reduce.c (reduce_output): Use it. | |
14420 | * tests/reduce.at (Useless Rules, Reduced Automaton) | |
14421 | (Underivable Rules): Adjust. | |
14422 | ||
6b98e4b5 AD |
14423 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14424 | ||
14425 | Copy BYacc's nice way to report the grammar. | |
14426 | ||
14427 | * src/gram.h, src/gram.c (grammar_rhs_print, grammar_rules_print): | |
14428 | New. | |
14429 | Don't print the rules' location, it is confusing and useless. | |
14430 | (rule_print): Use grammar_rhs_print. | |
14431 | * src/print.c (print_grammar): Use grammar_rules_print. | |
14432 | ||
6b98e4b5 AD |
14433 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14434 | ||
14435 | Complete and rationalize `useless thing' warnings. | |
14436 | ||
14437 | * src/symtab.h, src/symtab.c (symbol_tag_get, symbol_tag_get_n) | |
14438 | (symbol_tag_print): New. | |
14439 | Use them everywhere in place of accessing directly the tag member. | |
14440 | * src/gram.h, src/gram.c (rule_print): New. | |
14441 | Use it where a rule used to be printed `by hand'. | |
14442 | * src/reduce.c (nonterminals_reduce): Report the use nonterminals. | |
14443 | (reduce_grammar_tables): Report the useless rules. | |
14444 | (reduce_print): Useless things are a warning, not an error. | |
14445 | Report it as such. | |
14446 | * tests/reduce.at (Useless Nonterminals, Useless Rules): | |
14447 | (Reduced Automaton, Underivable Rules): Adjust. | |
14448 | * tests/regression.at (Web2c Report, Web2c Report): Adjust. | |
14449 | * tests/conflicts.at (Unresolved SR Conflicts) | |
14450 | (Solved SR Conflicts): Adjust. | |
14451 | ||
ee000ba4 AD |
14452 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14453 | ||
14454 | Let symbols have a location. | |
14455 | ||
14456 | * src/symtab.h, src/symtab.c (symbol_t): Location is a new member. | |
14457 | (getsym): Adjust. | |
14458 | Adjust all callers. | |
14459 | * src/complain.h, src/complain.c (complain_at, fatal_at, warn_at): | |
14460 | Use location_t, not int. | |
14461 | * src/symtab.c (symbol_check_defined): Take advantage of the | |
14462 | location. | |
14463 | * tests/regression.at (Invalid inputs): Adjust. | |
14464 | ||
8efe435c AD |
14465 | 2002-06-15 Akim Demaille <akim@epita.fr> |
14466 | ||
14467 | * src/parse-gram.y (YYLLOC_DEFAULT, current_lhs_location): New. | |
14468 | (input): Don't try to initialize yylloc here, do it in the | |
14469 | scanner. | |
14470 | * src/scan-gram.l (YY_USER_INIT): Initialize yylloc. | |
14471 | * src/gram.h (rule_t): Change line and action_line into location | |
14472 | and action_location, of location_t type. | |
14473 | Adjust all dependencies. | |
14474 | * src/location.h, src/location.c (empty_location): New. | |
14475 | * src/reader.h, src/reader.c (grammar_start_symbol_set) | |
14476 | (grammar_symbol_append, grammar_rule_begin, grammar_rule_end) | |
14477 | (grammar_current_rule_symbol_append) | |
14478 | (grammar_current_rule_action_append): Expect a location as argument. | |
14479 | * src/reader.c (grammar_midrule_action): Adjust to attach an | |
14480 | action's location as dummy symbol location. | |
14481 | * src/symtab.h, src/symtab.c (startsymbol_location): New. | |
14482 | * tests/regression.at (Web2c Report, Rule Line Numbers): Adjust | |
14483 | the line numbers. | |
14484 | ||
1921f1d7 AD |
14485 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14486 | ||
14487 | Grammar declarations may be found in the grammar section. | |
14488 | ||
14489 | * src/parse-gram.y (rules_or_grammar_declaration): New. | |
14490 | (declarations): Each declaration may end with a semicolon, not | |
14491 | just... | |
14492 | (grammar_declaration): `"%union"'. | |
14493 | (grammar): Branch to rules_or_grammar_declaration. | |
14494 | ||
4515534c AD |
14495 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14496 | ||
14497 | * src/main.c (main): Invoke scanner_free. | |
14498 | ||
f958596b AD |
14499 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14500 | ||
14501 | * src/output.c (m4_invoke): Extracted from... | |
14502 | (output_skeleton): here. | |
14503 | Free tempfile. | |
14504 | ||
2c569025 AD |
14505 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14506 | ||
14507 | * src/parse-gram.y (directives, directive, gram) | |
14508 | (grammar_directives, precedence_directives, precedence_directive): | |
14509 | Rename as... | |
14510 | (declarations, declaration, grammar, grammar_declaration) | |
14511 | (precedence_declaration, precedence_declarator): these. | |
14512 | (symbol_declaration): New. | |
14513 | ||
592e8d4d AD |
14514 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14515 | ||
14516 | * src/files.c (action_obstack): Remove, unused. | |
14517 | (output_obstack): Remove it, and all its dependencies, as it is no | |
14518 | longer needed. | |
14519 | * src/reader.c (epilogue_set): Build the epilogue in the | |
14520 | muscle_obstack. | |
14521 | * src/output.h, src/output.c (muscle_obstack): Move to... | |
14522 | * src/muscle_tab.h, src/muscle_tab.h: here. | |
14523 | (muscle_init): Initialize muscle_obstack. | |
14524 | (muscle_free): New. | |
14525 | * src/main.c (main): Call it. | |
14526 | ||
0c15323d AD |
14527 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14528 | ||
14529 | * src/location.h: New, extracted from... | |
14530 | * src/reader.h: here. | |
14531 | * src/Makefile.am (noinst_HEADERS): Merge into | |
14532 | (bison_SOURCES): this. | |
14533 | Add location.h. | |
14534 | * src/parse-gram.y: Use location_t instead of Bison's. | |
14535 | * src/reader.h, src/reader.c (prologue_augment, epilogue_set): | |
14536 | Use location_t instead of ints. | |
14537 | ||
e96c9728 AD |
14538 | 2002-06-14 Akim Demaille <akim@epita.fr> |
14539 | ||
14540 | * data/bison.simple, data/bison.c++: Be sure to restore the | |
14541 | current #line when returning to the skeleton contents after having | |
14542 | exposed the input file's #line. | |
14543 | ||
75d1fe16 AD |
14544 | 2002-06-12 Akim Demaille <akim@epita.fr> |
14545 | ||
14546 | * src/scan-gram.l (SC_BRACED_CODE): Don't use `<.*>', it is too | |
14547 | eager. | |
14548 | * tests/actions.at (Exotic Dollars): New. | |
14549 | ||
6c35d22c AD |
14550 | 2002-06-12 Akim Demaille <akim@epita.fr> |
14551 | ||
14552 | * src/scan-gram.l (SC_PROLOGUE): Don't eat characters amongst | |
14553 | ['"/] too eagerly. | |
14554 | * tests/input.at (Torturing the Scanner): New. | |
14555 | ||
1d6412ad AD |
14556 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14557 | ||
14558 | * src/scan-gram.l (YY_OBS_INIT): Remove, replace with... | |
14559 | [SC_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE,SC_PROLOGUE] | |
14560 | [SC_EPILOGUE]: Output the quadrigraphs only when not in a comment. | |
14561 | * src/reader.h, src/scan-gram.l (scanner_initialize): this. | |
14562 | * src/reader.c (reader): Use it. | |
14563 | ||
4cdb01db AD |
14564 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14565 | ||
14566 | * src/scan-gram.l (YY_OBS_FINISH): Don't set yylval. | |
14567 | Adjust all callers. | |
14568 | (scanner_last_string_free): New. | |
14569 | ||
44995b2e AD |
14570 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14571 | ||
14572 | * src/scan-gram.l (YY_INIT, YY_GROW, YY_FINISH): Rename as... | |
14573 | (YY_OBS_INIT, YY_OBS_GROW, YY_OBS_FINISH): these. | |
14574 | (last_string, YY_OBS_FREE): New. | |
14575 | Use them when returning an ID. | |
14576 | ||
e9955c83 AD |
14577 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14578 | ||
14579 | Have Bison grammars parsed by a Bison grammar. | |
14580 | ||
14581 | * src/reader.c, src/reader.h (prologue_augment): New. | |
14582 | * src/reader.c (copy_definition): Remove. | |
14583 | ||
14584 | * src/reader.h, src/reader.c (gram_start_symbol_set, prologue_augment) | |
14585 | (grammar_symbol_append, grammar_rule_begin, grammar_midrule_action) | |
14586 | (grammar_current_rule_prec_set, grammar_current_rule_check) | |
14587 | (grammar_current_rule_symbol_append) | |
14588 | (grammar_current_rule_action_append): Export. | |
14589 | * src/parse-gram.y (symbol_list_new, symbol_list_symbol_append_ | |
14590 | (symbol_list_action_append): Remove. | |
14591 | Hook the routines from reader. | |
14592 | * src/scan-gram.l: In INITIAL, characters and strings are tokens. | |
14593 | * src/system.h (ATTRIBUTE_NORETURN, ATTRIBUTE_UNUSED): Now. | |
14594 | ||
14595 | * src/reader.c (read_declarations): Remove, unused. | |
14596 | ||
14597 | * src/parse-gram.y: Handle the epilogue. | |
14598 | * src/reader.h, src/reader.c (gram_start_symbol_set): Rename as... | |
14599 | (grammar_start_symbol_set): this. | |
14600 | * src/scan-gram.l: Be sure to ``use'' yycontrol to keep GCC quiet. | |
14601 | * src/reader.c (readgram): Remove, unused. | |
14602 | (reader): Adjust to insert eoftoken and axiom where appropriate. | |
14603 | ||
14604 | * src/reader.c (copy_dollar): Replace with... | |
14605 | * src/scan-gram.h (handle_dollar): this. | |
14606 | * src/parse-gram.y: Remove `%thong'. | |
14607 | ||
14608 | * src/reader.c (copy_at): Replace with... | |
14609 | * src/scan-gram.h (handle_at): this. | |
14610 | ||
14611 | * src/complain.h, src/complain.c (warn_at, complain_at, fatal_at): | |
14612 | New. | |
14613 | ||
14614 | * src/scan-gram.l (YY_LINES): Keep lineno synchronized for the | |
14615 | time being. | |
14616 | ||
14617 | * src/reader.h, src/reader.c (grammar_rule_end): New. | |
14618 | ||
14619 | * src/parse.y (current_type, current_class): New. | |
14620 | Implement `%nterm', `%token' support. | |
14621 | Merge `%term' into `%token'. | |
14622 | (string_as_id): New. | |
14623 | * src/symtab.h, src/symtab.c (symbol_make_alias): Don't pass the | |
14624 | type name. | |
14625 | ||
14626 | * src/parse-gram.y: Be sure to handle properly the beginning of | |
14627 | rules. | |
14628 | ||
14629 | * src/parse-gram.y: Handle %type. | |
14630 | * src/reader.c (grammar_rule_end): Call grammar_current_rule_check. | |
14631 | ||
14632 | * src/parse-gram.y: More directives support. | |
14633 | * src/options.c: No longer handle source directives. | |
14634 | ||
14635 | * src/parse-gram.y: Fix %output. | |
14636 | ||
14637 | * src/parse-gram.y: Handle %union. | |
14638 | Use the prologue locations. | |
14639 | * src/reader.c (parse_union_decl): Remove. | |
14640 | ||
14641 | * src/reader.h, src/reader.c (epilogue_set): New. | |
14642 | * src/parse-gram.y: Use it. | |
14643 | ||
14644 | * data/bison.simple, data/bison.c++: b4_stype is now either not | |
14645 | defined, then default to int, or to the contents of %union, | |
14646 | without `union' itself. | |
14647 | Adjust. | |
14648 | * src/muscle_tab.c (muscle_init): Don't predefine `stype'. | |
14649 | ||
14650 | * src/output.c (actions_output): Don't output braces, as they are | |
14651 | already handled by the scanner. | |
14652 | ||
14653 | * src/scan-gram.l (SC_CHARACTER): Set the user_token_number of | |
14654 | characters to themselves. | |
14655 | ||
14656 | * tests/reduce.at (Reduced Automaton): End the grammars with %% so | |
14657 | that the epilogue has a proper #line. | |
14658 | ||
14659 | * src/parse-gram.y: Handle precedence/associativity. | |
14660 | ||
14661 | * src/symtab.c (symbol_precedence_set): Requires the symbol to be | |
14662 | a terminal. | |
14663 | * src/scan-gram.l (SC_BRACED_CODE): Catch strings and characters. | |
14664 | * tests/calc.at: Do not use `%token "foo"' as it makes not sense | |
14665 | at all to define terminals that cannot be emitted. | |
14666 | ||
14667 | * src/scan-gram.l: Escape M4 characters. | |
14668 | ||
14669 | * src/scan-gram.l: Working properly with escapes in user | |
14670 | strings/characters. | |
14671 | ||
14672 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR) | |
14673 | (AT_DATA_HORIZONTAL_GRAMMAR): Respect the `%token ID NUM STRING' | |
14674 | grammar. | |
14675 | Use more modest sizes, as for the time being the parser does not | |
14676 | release memory, and therefore the process swallows a huge amount | |
14677 | of memory. | |
14678 | ||
14679 | * tests/torture.at (AT_DATA_LOOKAHEADS_GRAMMAR): Adjust to the | |
14680 | stricter %token grammar. | |
14681 | ||
14682 | * src/symtab.h (associativity): Add `undef_assoc'. | |
14683 | (symbol_precedence_set): Do nothing when passed an undef_assoc. | |
14684 | * src/symtab.c (symbol_check_alias_consistence): Adjust. | |
14685 | ||
14686 | * tests/regression.at (Invalid %directive): Remove, as it is now | |
14687 | meaningless. | |
14688 | (Invalid inputs): Adjust to the new error messages. | |
14689 | (Token definitions): The new grammar doesn't allow too many | |
14690 | eccentricities. | |
14691 | ||
14692 | * src/lex.h, src/lex.c: Remove. | |
14693 | * src/reader.c (lastprec, skip_to_char, read_signed_integer) | |
14694 | (copy_character, copy_string2, copy_string, copy_identifier) | |
14695 | (copy_comment, parse_token_decl, parse_type_decl, parse_assoc_decl) | |
14696 | (parse_muscle_decl, parse_dquoted_param, parse_skel_decl) | |
14697 | (parse_action): Remove. | |
14698 | * po/POTFILES.in: Adjust. | |
14699 | ||
2e047461 AD |
14700 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14701 | ||
cd05d13c | 14702 | * src/reader.c (parse_action): Don't store directly into the |
2e047461 AD |
14703 | rule's action member: return the action as a string. |
14704 | Don't require `rule_length' as an argument: compute it. | |
14705 | (grammar_current_rule_symbol_append) | |
14706 | (grammar_current_rule_action_append): New, eved out from | |
14707 | (readgram): here. | |
14708 | Remove `action_flag', `rulelength', unused now. | |
14709 | ||
9af3fbce AD |
14710 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14711 | ||
14712 | * src/reader.c (grammar_current_rule_prec_set). | |
14713 | (grammar_current_rule_check): New, eved out from... | |
14714 | (readgram): here. | |
14715 | Remove `xaction', `first_rhs': useless. | |
14716 | * tests/input.at (Type clashes): New. | |
14717 | * tests/existing.at (GNU Cim Grammar): Adjust. | |
14718 | ||
1485e106 AD |
14719 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14720 | ||
14721 | * src/reader.c (grammar_midrule_action): New, Eved out from | |
14722 | (readgram): here. | |
14723 | ||
da4160c3 AD |
14724 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14725 | ||
14726 | * src/reader.c (grammar_rule_begin, previous_rule, current_rule): | |
14727 | New. | |
14728 | (readgram): Use them as replacement of inlined code, crule and | |
14729 | crule1. | |
14730 | ||
f6d0f937 AD |
14731 | 2002-06-11 Akim Demaille <akim@epita.fr> |
14732 | ||
14733 | * src/reader.c (grammar_end, grammar_symbol_append): New. | |
14734 | (readgram): Use them. | |
14735 | Make the use of `p' as local as possible. | |
14736 | ||
69078d4b AD |
14737 | 2002-06-10 Akim Demaille <akim@epita.fr> |
14738 | ||
14739 | GCJ's parser requires the tokens to be defined before the prologue. | |
14740 | ||
14741 | * data/bison.simple: Output the token definition before the user's | |
14742 | prologue. | |
14743 | * tests/regression.at (Braces parsing, Duplicate string) | |
14744 | (Mixing %token styles): Check the output from bison. | |
14745 | (Early token definitions): New. | |
14746 | ||
5e424082 AD |
14747 | 2002-06-10 Akim Demaille <akim@epita.fr> |
14748 | ||
14749 | * src/symtab.c (symbol_user_token_number_set): Don't complain when | |
14750 | assigning twice the same user number to a token, so that we can | |
14751 | use it in... | |
14752 | * src/lex.c (lex): here. | |
14753 | Also use `symbol_class_set' instead of hand written code. | |
14754 | * src/reader.c (parse_assoc_decl): Likewise. | |
14755 | ||
44536b35 AD |
14756 | 2002-06-10 Akim Demaille <akim@epita.fr> |
14757 | ||
14758 | * src/symtab.c, src/symtab.c (symbol_class_set) | |
14759 | (symbol_user_token_number_set): New. | |
14760 | * src/reader.c (parse_token_decl): Use them. | |
14761 | Use a switch instead of ifs. | |
14762 | Use a single argument. | |
14763 | ||
8b9f2372 AD |
14764 | 2002-06-10 Akim Demaille <akim@epita.fr> |
14765 | ||
14766 | Remove `%thong' support as it is undocumented, unused, duplicates | |
14767 | `%token's job, and creates useless e-mail traffic with people who | |
14768 | want to know what it is, why it is undocumented, unused, and | |
14769 | duplicates `%token's job. | |
14770 | ||
14771 | * src/reader.c (parse_thong_decl): Remove. | |
14772 | * src/options.c (option_table): Remove "thong". | |
14773 | * src/lex.h (tok_thong): Remove. | |
14774 | ||
3ae2b51f AD |
14775 | 2002-06-10 Akim Demaille <akim@epita.fr> |
14776 | ||
14777 | * src/symtab.c, src/symtab.c (symbol_type_set) | |
14778 | (symbol_precedence_set): New. | |
14779 | * src/reader.c (parse_type_decl, parse_assoc_decl): Use them. | |
14780 | (value_components_used): Remove, unused. | |
14781 | ||
2f1afb73 AD |
14782 | 2002-06-09 Akim Demaille <akim@epita.fr> |
14783 | ||
14784 | Move symbols handling code out of the reader. | |
14785 | ||
14786 | * src/reader.h, src/reader.c (errtoken, undeftoken, eoftoken) | |
14787 | (axiom): Move to... | |
14788 | * src/symtab.h, src/symtab.c: here. | |
14789 | ||
14790 | * src/gram.c (start_symbol): Remove: use startsymbol->number. | |
14791 | * src/reader.c (startval): Rename as... | |
14792 | * src/symtab.h, src/symtab.c (startsymbol): this. | |
14793 | * src/reader.c: Adjust. | |
14794 | ||
14795 | * src/reader.c (symbol_check_defined, symbol_make_alias) | |
14796 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
14797 | (token_translations_init) | |
14798 | Move to... | |
14799 | * src/symtab.c: here. | |
14800 | * src/reader.c (packsymbols): Move to... | |
14801 | * src/symtab.h, src/symtab.c (symbols_pack): here. | |
14802 | * src/symtab.h, src/symtab.c (symbol_make_alias): Takes SYMVAL as | |
14803 | argument. | |
14804 | ||
e9bca3ad AD |
14805 | 2002-06-03 Akim Demaille <akim@epita.fr> |
14806 | ||
14807 | * src/muscle_tab.c (muscle_insert, muscle_find): Declarations, | |
14808 | then statements. | |
14809 | ||
86eff183 AD |
14810 | 2002-06-03 Akim Demaille <akim@epita.fr> |
14811 | ||
14812 | * src/muscle_tab.c (muscle_find, muscle_insert): Don't initialize | |
14813 | structs with non literals. | |
14814 | * src/scan-skel.l: never-interactive. | |
14815 | * src/conflicts.c (enum conflict_resolution_e): No trailing | |
14816 | comma. | |
14817 | * src/getargs.c (usage): Split long literal strings. | |
14818 | Reported by Hans Aberg. | |
14819 | ||
717be197 AD |
14820 | 2002-05-28 Akim Demaille <akim@epita.fr> |
14821 | ||
14822 | * data/bison.c++: Use C++ ostreams. | |
14823 | (cdebug_): New member. | |
14824 | ||
670ddffd AD |
14825 | 2002-05-28 Akim Demaille <akim@epita.fr> |
14826 | ||
14827 | * src/output.c (output_skeleton): Be sure to allocate enough room | |
14828 | for `/' _and_ for `\0' in full_skeleton. | |
14829 | ||
769b430f AD |
14830 | 2002-05-28 Akim Demaille <akim@epita.fr> |
14831 | ||
14832 | * data/bison.c++: Catch up with bison.simple: | |
14833 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
14834 | and Paul Eggert <eggert@twinsun.com>: `error' handing. | |
14835 | 2002-05-26 Akim Demaille <akim@epita.fr>: stos_, token_number_, | |
14836 | and popping traces. | |
14837 | ||
7067cb36 PH |
14838 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14839 | ||
14840 | * src/output.c (output_skeleton): Put an explicit path in front of | |
14841 | the skeleton file name, rather than relying on the -I directory, | |
14842 | to partially alleviate effects of having a skeleton file lying around | |
14843 | in the current directory. | |
769b430f | 14844 | |
4a713ec2 PH |
14845 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14846 | ||
769b430f | 14847 | * src/conflicts.c (log_resolution): Correct typo: |
4a713ec2 PH |
14848 | obstack_printf should be obstack_fgrow1. |
14849 | ||
b408954b AD |
14850 | 2002-05-26 Akim Demaille <akim@epita.fr> |
14851 | ||
14852 | * src/state.h (state_t): `solved_conflicts' is a new member. | |
14853 | * src/LR0.c (new_state): Set it to 0. | |
14854 | * src/conflicts.h, src/conflicts.c (print_conflicts) | |
14855 | (free_conflicts, solve_conflicts): Rename as... | |
14856 | (conflicts_print, conflicts_free, conflicts_solve): these. | |
14857 | Adjust callers. | |
14858 | * src/conflicts.c (enum conflict_resolution_e) | |
14859 | (solved_conflicts_obstack): New, used by... | |
14860 | (log_resolution): this. | |
14861 | Adjust to attach the conflict resolution to each state. | |
14862 | Complete the description with the precedence/associativity | |
14863 | information. | |
14864 | (resolve_sr_conflict): Adjust. | |
14865 | * src/print.c (print_state): Output its solved_conflicts. | |
14866 | * tests/conflicts.at (Unresolved SR Conflicts) | |
14867 | (Solved SR Conflicts): Exercise --report=all. | |
14868 | ||
a49aecd5 AD |
14869 | 2002-05-26 Akim Demaille <akim@epita.fr> |
14870 | ||
14871 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
14872 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
14873 | * src/reader.c, src/reduce.c, src/state.h, src/symtab.h | |
14874 | (token_number_t, item_number_as_token_number) | |
14875 | (token_number_as_item_number, muscle_insert_token_number_table): | |
14876 | Rename as... | |
14877 | (symbol_number_t, item_number_as_symbol_number) | |
14878 | (symbol_number_as_item_number, muscle_insert_symbol_number_table): | |
14879 | these, since it is more appropriate. | |
14880 | ||
5504898e AD |
14881 | 2002-05-26 Akim Demaille <akim@epita.fr> |
14882 | ||
14883 | * tests/calc.at (AT_CHECK_CALC): Adjust: there are now additional | |
14884 | `Error:' lines. | |
14885 | * data/bison.simple (yystos) [YYDEBUG]: New. | |
14886 | (yyparse) [YYDEBUG]: Display the symbols which are popped during | |
14887 | error recovery. | |
14888 | * tests/regression.at (Web2c Actions): Adjust: yystos is output now. | |
14889 | ||
ec3bc396 AD |
14890 | 2002-05-25 Akim Demaille <akim@epita.fr> |
14891 | ||
14892 | * doc/bison.texinfo (Debugging): Split into... | |
14893 | (Tracing): this new section, its former contents, and... | |
14894 | (Understanding): this new section. | |
14895 | * src/getargs.h, src/getargs.c (verbose_flag): Remove, replaced | |
14896 | by... | |
14897 | (report_flag): this. | |
14898 | Adjust all dependencies. | |
14899 | (report_args, report_types, report_argmatch): New. | |
14900 | (usage, getargs): Report/support -r, --report. | |
14901 | * src/options.h | |
14902 | (struct option_table_struct): Rename as.., | |
14903 | (struct option_table_s): this. | |
14904 | Rename the `set_flag' member to `flag' to match with getopt_long's | |
14905 | struct. | |
14906 | * src/options.c (option_table): Split verbose into an entry for | |
14907 | %verbose, and another for --verbose. | |
14908 | Support --report/-r, so remove -r from the obsolete --raw. | |
14909 | * src/print.c: Attach full item sets and lookaheads reports to | |
14910 | report_flag instead of trace_flag. | |
14911 | * lib/argmatch.h, lib/argmatch.c: New, from Fileutils 4.1. | |
14912 | ||
78df8250 PE |
14913 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14914 | and Paul Eggert <eggert@twinsun.com> | |
769b430f | 14915 | |
78df8250 PE |
14916 | * data/bison.simple (yyparse): Correct error handling to conform to |
14917 | POSIX and yacc. Specifically, after syntax error is discovered, | |
14918 | do not reduce further before shifting the error token. | |
14919 | Clean up the code a bit by removing the labels yyerrdefault, | |
14920 | yyerrhandle, yyerrpop. | |
14921 | * NEWS: Document the above. | |
14922 | ||
c0c9ea05 PH |
14923 | 2002-05-20 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14924 | ||
14925 | * data/bison.simple (yyr1): Don't use yy_token_number_type as element | |
14926 | type; it isn't always big enough, since it doesn't necessarily | |
14927 | include non-terminals. | |
769b430f | 14928 | (yytranslate): Expand definition of yy_token_number_type, so that |
c0c9ea05 PH |
14929 | the latter can be removed. |
14930 | (yy_token_number_type): Remove, only one use. | |
14931 | * data/bison.c++ (r1_): Parallel change to yyr1 in bison.simple--- | |
14932 | don't use TokenNumberType as element type. | |
769b430f | 14933 | |
c0c9ea05 PH |
14934 | * tests/regression.at: Modify expected output to agree with change |
14935 | to yyr1 and yytranslate. | |
769b430f | 14936 | |
6390a83f FK |
14937 | 2002-05-13 Florian Krohm <florian@edamail.fishkill.ibm.com> |
14938 | ||
14939 | * src/reader.c (parse_action): Use copy_character instead of | |
14940 | obstack_1grow. | |
14941 | ||
db7c8e9a AD |
14942 | 2002-05-13 Akim Demaille <akim@epita.fr> |
14943 | ||
14944 | * tests/regression.at (Token definitions): Prototype yylex and | |
14945 | yyerror. | |
14946 | ||
fcc61800 PH |
14947 | 2002-05-12 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
14948 | ||
158c687b | 14949 | * src/scan-skel.l: Correct off-by-one error in handling of __oline__. |
fcc61800 PH |
14950 | * data/bison.simple (b4_sint_type, b4_uint_type): Correct to reflect |
14951 | 32-bit arithmetic. | |
14952 | * data/bison.c++ (b4_sint_type, b4_uint_type): Ditto. | |
14953 | ||
5683e9b2 AD |
14954 | 2002-05-07 Akim Demaille <akim@epita.fr> |
14955 | ||
14956 | * tests/synclines.at: Be sure to prototype yylex and yyerror to | |
14957 | avoid GCC warnings. | |
14958 | ||
0c2d3f4c AD |
14959 | 2002-05-07 Akim Demaille <akim@epita.fr> |
14960 | ||
14961 | Kill GCC warnings. | |
14962 | ||
14963 | * src/reduce.c (nonterminals_reduce): Don't loop over RITEM: loop | |
14964 | over the RHS of each rule. | |
14965 | * src/gram.h, src/gram.c (nritems): Is `unsigned int', not int. | |
14966 | * src/state.h (state_t): Member `nitems' is unsigned short. | |
14967 | * src/LR0.c (get_state): Adjust. | |
14968 | * src/reader.c (packgram): Likewise. | |
14969 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): `max' is of type | |
14970 | `Type'. | |
14971 | (muscle_insert_int_table): Remove, unused. | |
14972 | (prepare_rules): Remove `max'. | |
14973 | ||
1565b720 AD |
14974 | 2002-05-06 Akim Demaille <akim@epita.fr> |
14975 | ||
14976 | * src/closure.c (print_firsts): Display of the symbol tags. | |
14977 | (bitmatrix_print): Move to... | |
14978 | * lib/bitsetv-print.h, lib/bitsetv-print.c (bitsetv_matrix_dump): | |
14979 | here. | |
14980 | * tests/sets.at (Nullable, Broken Closure, Firsts): Adjust. | |
14981 | ||
cfaee611 AD |
14982 | 2002-05-06 Akim Demaille <akim@epita.fr> |
14983 | ||
14984 | * src/muscle_tab.c (muscle_m4_output): Must return TRUE for | |
14985 | hash_do_for_each. | |
14986 | ||
458be8e0 AD |
14987 | 2002-05-06 Akim Demaille <akim@epita.fr> |
14988 | ||
14989 | * src/LR0.c (new_state, get_state): Instead of using the global | |
14990 | `kernel_size' and `kernel_base', have two new arguments: | |
14991 | `core_size' and `core'. | |
14992 | Adjust callers. | |
14993 | ||
a900a624 AD |
14994 | 2002-05-06 Akim Demaille <akim@epita.fr> |
14995 | ||
14996 | * src/reader.c (packgram): No longer end `ritem' with a 0 | |
14997 | sentinel: it is not used. | |
14998 | ||
d4e7d3a1 AD |
14999 | 2002-05-05 Akim Demaille <akim@epita.fr> |
15000 | ||
15001 | New experimental feature: display the lookaheads in the report and | |
15002 | graph. | |
15003 | ||
15004 | * src/print (print_core): When --trace-flag, display the rules | |
15005 | lookaheads. | |
15006 | * src/print_graph.c (print_core): Likewise. | |
15007 | Swap the arguments. | |
15008 | Adjust caller. | |
15009 | ||
39ceb25b AD |
15010 | 2002-05-05 Akim Demaille <akim@epita.fr> |
15011 | ||
15012 | * tests/torture.at (Many lookaheads): New test. | |
15013 | ||
5372019f AD |
15014 | 2002-05-05 Akim Demaille <akim@epita.fr> |
15015 | ||
15016 | * src/output.c (GENERATE_OUTPUT_TABLE): Replace with... | |
15017 | (GENERATE_MUSCLE_INSERT_TABLE): this. | |
15018 | (output_int_table, output_unsigned_int_table, output_short_table) | |
15019 | (output_token_number_table, output_item_number_table): Replace with... | |
15020 | (muscle_insert_int_table, muscle_insert_unsigned_int_table) | |
15021 | (muscle_insert_short_table, muscle_insert_token_number_table) | |
15022 | (muscle_insert_item_number_table): these. | |
15023 | Adjust all callers. | |
15024 | (prepare_tokens): Don't free `translations', since... | |
15025 | * src/reader.h, src/reader.c (grammar_free): do it. | |
15026 | Move to... | |
15027 | * src/gram.h, src/gram.c (grammar_free): here. | |
15028 | * data/bison.simple, data/bison.c++: b4_token_number_max is now | |
15029 | b4_translate_max. | |
15030 | ||
5df5f6d5 AD |
15031 | 2002-05-05 Akim Demaille <akim@epita.fr> |
15032 | ||
15033 | * src/output.c (output_unsigned_int_table): New. | |
15034 | (prepare_rules): `i' is unsigned. | |
15035 | `prhs', `rline', `r2' are unsigned int. | |
15036 | Rename muscle `rhs_number_max' as `rhs_max'. | |
15037 | Output muscles `prhs_max', `rline_max', and `r2_max'. | |
15038 | Free rline and r1. | |
15039 | * data/bison.simple, data/bison.c++: Adjust to use these muscles | |
15040 | to compute types instead of constant types. | |
15041 | * tests/regression.at (Web2c Actions): Adjust. | |
15042 | ||
b87f8b21 AD |
15043 | 2002-05-04 Akim Demaille <akim@epita.fr> |
15044 | ||
15045 | * src/symtab.h (SALIAS, SUNDEF): Rename as... | |
15046 | (USER_NUMBER_ALIAS, USER_NUMBER_UNDEFINED): these. | |
15047 | Adjust dependencies. | |
15048 | * src/output.c (token_definitions_output): Be sure not to output a | |
15049 | `#define 'a'' when fed with `%token 'a' "a"'. | |
15050 | * tests/regression.at (Token definitions): New. | |
15051 | ||
8bb936e4 PE |
15052 | 2002-05-03 Paul Eggert <eggert@twinsun.com> |
15053 | ||
15054 | * data/bison.simple (b4_token_defines): Also define YYTOKENTYPE | |
15055 | for K&R C. | |
15056 | ||
15057 | 2002-05-03 gettextize <bug-gnu-gettext@gnu.org> | |
15058 | ||
15059 | * Makefile.am (SUBDIRS): Remove intl. | |
15060 | (EXTRA_DIST): Add config/config.rpath. | |
15061 | ||
53c71a12 AD |
15062 | 2002-05-03 Akim Demaille <akim@epita.fr> |
15063 | ||
15064 | * data/bison.simple (m4_if): Don't output empty enums. | |
15065 | And actually, output valid enum definitions :(. | |
15066 | ||
289dd0cf AD |
15067 | 2002-05-03 Akim Demaille <akim@epita.fr> |
15068 | ||
15069 | * configure.bat: Remove, completely obsolete. | |
15070 | * Makefile.am (EXTRA_DIST): Adjust. | |
15071 | Don't distribute config.rpath... | |
15072 | * config/Makefile.am (EXTRA_DIST): Do it. | |
15073 | ||
db85e524 AD |
15074 | 2002-05-03 Akim Demaille <akim@epita.fr> |
15075 | ||
15076 | * configure.in (GETTEXT_VERSION): New. | |
15077 | Suggested by Bruno Haible for the forthcoming Gettext 0.10.3. | |
15078 | ||
83ccf991 AD |
15079 | 2002-05-03 Akim Demaille <akim@epita.fr> |
15080 | ||
15081 | * data/bison.simple (b4_token_enum): New. | |
15082 | (b4_token_defines): Use it to output tokens both as #define and | |
15083 | enums. | |
15084 | Suggested by Paul Eggert. | |
15085 | * src/output.c (token_definitions_output): Don't output spurious | |
15086 | white spaces. | |
15087 | ||
1f418995 AD |
15088 | 2002-05-03 Akim Demaille <akim@epita.fr> |
15089 | ||
15090 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
15091 | ||
45119f04 RA |
15092 | 2002-05-02 Robert Anisko <robert@lrde.epita.fr> |
15093 | ||
15094 | * data/bison.c++: Adapt expansion of $s and @s to the C++ parser. | |
15095 | Update the stack class, give a try to deque as the default container. | |
15096 | ||
b2d52318 AD |
15097 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15098 | ||
15099 | * data/bison.simple (yyparse): Do not implement @$ = @1. | |
15100 | (YYLLOC_DEFAULT): Adjust to do it. | |
15101 | * doc/bison.texinfo (Location Default Action): Fix. | |
15102 | ||
3a8b4109 AD |
15103 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15104 | ||
15105 | * src/reader.c (parse_braces): Merge into... | |
15106 | (parse_action): this. | |
15107 | ||
84614e13 AD |
15108 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15109 | ||
15110 | * configure.in (ALL_LINGUAS): Remove. | |
15111 | * po/LINGUAS, hr.po: New. | |
15112 | ||
fdbcd8e2 AD |
15113 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15114 | ||
15115 | Remove the so called hairy (semantic) parsers. | |
15116 | ||
15117 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove. | |
15118 | * src/gram.h, src/gram.c (semantic_parser): Remove. | |
15119 | (rule_t): Remove the guard and guard_line members. | |
15120 | * src/lex.h (token_t): remove tok_guard. | |
15121 | * src/options.c (option_table): Remove %guard and %semantic_parser | |
15122 | support. | |
15123 | * src/output.c, src/output.h (guards_output): Remove. | |
15124 | (prepare): Adjust. | |
15125 | (token_definitions_output): Don't output the `T' | |
15126 | tokens (???). | |
15127 | (output_skeleton): Don't output the guards. | |
15128 | * src/files.c, src/files.c (attrsfile): Remove. | |
15129 | * src/reader.c (symbol_list): Remove the guard and guard_line | |
15130 | members. | |
15131 | Adjust dependencies. | |
15132 | (parse_guard): Remove. | |
15133 | * data/bison.hairy: Remove. | |
15134 | * doc/bison.texinfo (Environment Variables): Remove occurrences of | |
15135 | BISON_HAIRY. | |
15136 | ||
82b6cb3f AD |
15137 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15138 | ||
15139 | * src/reader.c (copy_at, copy_dollarm parse_braces, parse_action) | |
15140 | (parse_guard): Rename the formal argument `stack_offset' as | |
15141 | `rule_length', which is more readable. | |
15142 | Adjust callers. | |
15143 | (copy_at, copy_dollar): Instead of outputting the hard coded | |
15144 | values of $$, $n and so forth, output invocation to b4_lhs_value, | |
15145 | b4_lhs_location, b4_rhs_value, and b4_rhs_location. | |
900c877b AD |
15146 | Note: this patch partially drops `semantic-parser' support: it |
15147 | always does `rule_length - n', where semantic parsers ought to | |
15148 | always use `-n'. | |
82b6cb3f AD |
15149 | * data/bison.simple, data/bison.c++ (b4_lhs_value) |
15150 | (b4_lhs_location, b4_rhs_value, and b4_rhs_location: New. | |
15151 | ||
6cbfbcc5 AD |
15152 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15153 | ||
15154 | * configure.in (AC_INIT): Bump to 1.49b. | |
15155 | (AM_INIT_AUTOMAKE): Short invocation. | |
15156 | ||
b8548114 AD |
15157 | 2002-05-02 Akim Demaille <akim@epita.fr> |
15158 | ||
15159 | Version 1.49a. | |
15160 | ||
c20cd1fa AD |
15161 | 2002-05-01 Akim Demaille <akim@epita.fr> |
15162 | ||
15163 | * src/skeleton.h: Remove. | |
15164 | ||
8a9566d4 AD |
15165 | 2002-05-01 Akim Demaille <akim@epita.fr> |
15166 | ||
15167 | * src/skeleton.h: Fix the #endif. | |
15168 | Reported by Magnus Fromreide. | |
15169 | ||
8c6d399a PE |
15170 | 2002-04-26 Paul Eggert <eggert@twinsun.com> |
15171 | ||
15172 | * data/bison.simple (YYSTYPE_IS_TRIVIAL, YYLTYPE_IS_TRIVIAL): | |
15173 | Define if we define YYSTYPE and YYLTYPE, respectively. | |
b756bb75 | 15174 | (YYCOPY): Fix [] quoting problem in the non-GCC case. |
8a9566d4 | 15175 | |
2b7ed18a RA |
15176 | 2002-04-25 Robert Anisko <robert@lrde.epita.fr> |
15177 | ||
15178 | * src/scan-skel.l: Postprocess quadrigraphs. | |
15179 | ||
15180 | * src/reader.c (copy_character): New function, used to output | |
15181 | single characters while replacing `[' and `]' with quadrigraphs, to | |
15182 | avoid troubles with M4 quotes. | |
15183 | (copy_comment): Output characters with copy_character. | |
15184 | (read_additionnal_code): Likewise. | |
15185 | (copy_string2): Likewise. | |
15186 | (copy_definition): Likewise. | |
15187 | ||
15188 | * tests/calc.at: Exercise M4 quoting. | |
15189 | ||
34a89c50 AD |
15190 | 2002-04-25 Akim Demaille <akim@epita.fr> |
15191 | ||
15192 | * tests/sets.at (AT_EXTRACT_SETS): Sed portability issue: no space | |
15193 | between `!' and the command. | |
15194 | Reported by Paul Eggert. | |
15195 | ||
0dd1580a RA |
15196 | 2002-04-24 Robert Anisko <robert@lrde.epita.fr> |
15197 | ||
15198 | * tests/calc.at: Exercise prologue splitting. | |
15199 | ||
15200 | * data/bison.simple, data/bison.c++: Use `b4_pre_prologue' and | |
15201 | `b4_post_prologue' instead of `b4_prologue'. | |
15202 | ||
15203 | * src/output.c (prepare): Add the `pre_prologue' and `post_prologue' | |
15204 | muscles. | |
15205 | (output): Free pre_prologue_obstack and post_prologue_obstack. | |
15206 | * src/files.h, src/files.c (attrs_obstack): Remove. | |
15207 | (pre_prologue_obstack, post_prologue_obstack): New. | |
15208 | * src/reader.c (copy_definition): Add a parameter to specify the | |
15209 | obstack to fill, instead of using attrs_obstack unconditionally. | |
15210 | (read_declarations): Pass pre_prologue_obstack to copy_definition if | |
15211 | `%union' has not yet been seen, pass post_prologue_obstack otherwise. | |
15212 | ||
83c1796f PE |
15213 | 2002-04-23 Paul Eggert <eggert@twinsun.com> |
15214 | ||
15215 | * data/bison.simple: Remove unnecessary commentary and white | |
15216 | space differences from 1_29-branch. | |
15217 | Depend on YYERROR_VERBOSE, not defined (YYERROR_VERBOSE). | |
15218 | ||
15219 | (union yyalloc, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYCOPY, | |
15220 | YYSTACK_RELOCATE): Do not define if yyoverflow is defined, or | |
15221 | if this is a C++ parser and YYSTYPE or YYLTYPE has nontrivial | |
15222 | constructors or destructors. | |
15223 | ||
15224 | (yyparse) [! defined YYSTACK_RELOCATE]: Do not relocate the stack. | |
15225 | ||
1207eeac AD |
15226 | 2002-04-23 Akim Demaille <akim@epita.fr> |
15227 | ||
15228 | * tests/sets.at (AT_EXTRACT_SETS): Don't use 8 char long sed labels. | |
15229 | * tests/synclines.at (AT_TEST_SYNCLINE): Be robust to GCC's | |
15230 | location with columns. | |
15231 | * tests/conflicts.at (%nonassoc and eof): Don't use `error.h'. | |
15232 | All reported by Paul Eggert. | |
15233 | ||
78ab8f67 AD |
15234 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15235 | ||
15236 | * src/reduce.c (dump_grammar): Move to... | |
15237 | * src/gram.h, src/gram.c (grammar_dump): here. | |
15238 | Be sure to separate long item numbers. | |
15239 | Don't read the members of a rule's prec if its nil. | |
15240 | ||
133c20e2 AD |
15241 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15242 | ||
15243 | * src/output.c (table_size, table_grow): New. | |
15244 | (MAXTABLE): Remove, replace uses with table_size. | |
15245 | (pack_vector): Instead of dying when the table is too big, grow it. | |
15246 | ||
9515e8a7 AD |
15247 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15248 | ||
15249 | * data/bison.simple (yyr1): Its type is that of a token number. | |
15250 | * data/bison.c++ (r1_): Likewise. | |
15251 | * tests/regression.at (Web2c Actions): Adjust. | |
15252 | ||
23c5a174 AD |
15253 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15254 | ||
15255 | * src/reader.c (token_translations_init): 256 is now the default | |
15256 | value for the error token, i.e., it will be assigned another | |
15257 | number if the user assigned 256 to one of her tokens. | |
15258 | (reader): Don't force 256 to error. | |
15259 | * doc/bison.texinfo (Symbols): Adjust. | |
15260 | * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR) | |
15261 | (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3 | |
15262 | etc. instead of 10, 20, 30 (which was used to `jump' over error | |
15263 | (256) and undefined (2)). | |
15264 | ||
5fbb0954 AD |
15265 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15266 | ||
15267 | Propagate more token_number_t. | |
15268 | ||
15269 | * src/gram.h (token_number_as_item_number) | |
15270 | (item_number_as_token_number): New. | |
15271 | * src/output.c (GENERATE_OUTPUT_TABLE): New. | |
15272 | Use it to create output_item_number_table and | |
15273 | output_token_number_table. | |
15274 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
15275 | * src/lex.c, src/nullable.c, src/output.c, src/print.c, | |
15276 | * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h, | |
15277 | * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts. | |
15278 | ||
4f940944 AD |
15279 | 2002-04-22 Akim Demaille <akim@epita.fr> |
15280 | ||
15281 | * src/output.h, src/output.c (get_lines_number): Remove. | |
15282 | ||
3ded9a63 AD |
15283 | 2002-04-19 Akim Demaille <akim@epita.fr> |
15284 | ||
15285 | * doc/bison.texinfo (Actions): Make clear that `|' is not the same | |
15286 | as Lex/Flex'. | |
15287 | (Debugging): More details about enabling the debugging features. | |
15288 | (Table of Symbols): Describe $$, $n, @$, and @n. | |
15289 | Suggested by Tim Josling. | |
15290 | ||
e0c471a9 AD |
15291 | 2002-04-19 Akim Demaille <akim@epita.fr> |
15292 | ||
15293 | * doc/bison.texinfo: Remove the uses of the obsolete @refill. | |
15294 | ||
fecc10cd AD |
15295 | 2002-04-10 Akim Demaille <akim@epita.fr> |
15296 | ||
15297 | * src/system.h: Rely on HAVE_LIMITS_H. | |
15298 | Suggested by Paul Eggert. | |
15299 | ||
51dec47b AD |
15300 | 2002-04-09 Akim Demaille <akim@epita.fr> |
15301 | ||
15302 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the | |
15303 | full stderr, and strip it according to the bison options, instead | |
15304 | of composing the error message from different bits. | |
15305 | This makes it easier to check for several error messages. | |
15306 | Adjust all the invocations. | |
15307 | Add an invocation exercising the error token. | |
15308 | Add an invocation demonstrating a stupid error message. | |
15309 | (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0. | |
15310 | Adjust the tests. | |
15311 | Error message are for stderr, not stdout. | |
15312 | ||
007a50a4 AD |
15313 | 2002-04-09 Akim Demaille <akim@epita.fr> |
15314 | ||
15315 | * src/gram.h, src/gram.c (error_token_number): Remove, use | |
15316 | errtoken->number. | |
15317 | * src/reader.c (reader): Don't specify the user token number (2) | |
15318 | for $undefined, as it uselessly prevents using it. | |
15319 | * src/gram.h (token_number_t): Move to... | |
15320 | * src/symtab.h: here. | |
15321 | (state_t.number): Is a token_number_t. | |
15322 | * src/print.c, src/reader.c: Use undeftoken->number instead of | |
15323 | hard coded 2. | |
15324 | (Even though this 2 is not the same as above: the number of the | |
15325 | undeftoken remains being 2, it is its user token number which | |
15326 | might not be 2). | |
15327 | * src/output.c (prepare_tokens): Rename the `maxtok' muscle with | |
15328 | `user_token_number_max'. | |
15329 | Output `undef_token_number'. | |
15330 | * data/bison.simple, data/bison.c++: Use them. | |
15331 | Be sure to map invalid yylex return values to | |
15332 | `undef_token_number'. This saves us from gratuitous SEGV. | |
15333 | ||
15334 | * tests/conflicts.at (Solved SR Conflicts) | |
15335 | (Unresolved SR Conflicts): Adjust. | |
15336 | * tests/regression.at (Web2c Actions): Adjust. | |
15337 | ||
06446ccf AD |
15338 | 2002-04-08 Akim Demaille <akim@epita.fr> |
15339 | ||
15340 | * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/. | |
15341 | Adding #line. | |
15342 | Remove the duplicate `typedefs'. | |
15343 | (RhsNumberType): Fix the declaration and various other typos. | |
15344 | Use __ofile__. | |
15345 | * data/bison.simple: Use __ofile__. | |
15346 | * src/scan-skel.l: Handle __ofile__. | |
15347 | ||
62a3e4f0 AD |
15348 | 2002-04-08 Akim Demaille <akim@epita.fr> |
15349 | ||
15350 | * src/gram.h (item_number_t): New, the type of item numbers in | |
15351 | RITEM. Note that it must be able to code symbol numbers as | |
15352 | positive number, and the negation of rule numbers as negative | |
15353 | numbers. | |
15354 | Adjust all dependencies (pretty many). | |
15355 | * src/reduce.c (rule): Remove this `short *' pointer: use | |
15356 | item_number_t. | |
15357 | * src/system.h (MINSHORT, MAXSHORT): Remove. | |
15358 | Include `limits.h'. | |
15359 | Adjust dependencies to using SHRT_MAX and SHRT_MIN. | |
15360 | (shortcpy): Remove. | |
15361 | (MAXTABLE): Move to... | |
15362 | * src/output.c (MAXTABLE): here. | |
15363 | (prepare_rules): Use output_int_table to output rhs. | |
15364 | * data/bison.simple, data/bison.c++: Adjust. | |
15365 | * tests/torture.at (Big triangle): Move the limit from 254 to | |
15366 | 500. | |
15367 | * tests/regression.at (Web2c Actions): Ajust. | |
15368 | ||
15369 | Trying with bigger grammars shows various phenomena: at 3000 (28Mb | |
15370 | of grammar file) bison is killed by my system, at 2000 (12Mb) bison | |
15371 | passes, but produces negative #line number, once fixed, GCC is | |
15372 | killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of | |
15373 | C), it passes. | |
15374 | * src/state.h (state_h): Code input lines on ints, not shorts. | |
15375 | ||
bb88b0fc AD |
15376 | 2002-04-08 Akim Demaille <akim@epita.fr> |
15377 | ||
15378 | * src/reduce.c (reduce_grammar): First reduce the nonterminals, | |
15379 | and then the grammar. | |
15380 | ||
9a636f47 AD |
15381 | 2002-04-08 Akim Demaille <akim@epita.fr> |
15382 | ||
15383 | * src/system.h: No longer using strndup. | |
15384 | ||
680e8701 AD |
15385 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15386 | ||
15387 | * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New. | |
15388 | * src/output.c (output_table_data): Return the longest number. | |
15389 | (prepare_tokens): Output `token_number_max'). | |
15390 | * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type): | |
15391 | New. | |
15392 | Use them to define yy_token_number_type/TokenNumberType. | |
15393 | Use this type for yytranslate. | |
15394 | * tests/torture.at (Big triangle): Push the limit from 124 to | |
15395 | 253. | |
15396 | * tests/regression.at (Web2c Actions): Adjust. | |
15397 | ||
817e9f41 AD |
15398 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15399 | ||
15400 | * tests/torture.at (Big triangle): New. | |
15401 | (GNU AWK Grammar, GNU Cim Grammar): Move to... | |
15402 | * tests/existing.at: here. | |
15403 | ||
5123689b AD |
15404 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15405 | ||
15406 | * src/gram.h, src/gram.c (nitems): Remove, it is an alias of | |
15407 | nritems. | |
15408 | Adjust dependencies. | |
15409 | ||
f3849179 AD |
15410 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15411 | ||
15412 | * src/reader.c: Normalize increments to prefix form. | |
15413 | ||
bd02036a AD |
15414 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15415 | ||
15416 | * src/reader.c, symtab.c: Remove debugging code. | |
15417 | ||
db8837cb AD |
15418 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15419 | ||
15420 | Rename all the `bucket's as `symbol_t'. | |
15421 | ||
15422 | * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c, | |
15423 | * src/reader.c, src/reader.h, src/reduce.c, src/state.h, | |
15424 | * src/symtab.c, src/symtab.h (bucket): Rename as... | |
15425 | (symbol_t): this. | |
15426 | (symbol_list_new, bucket_check_defined, bucket_make_alias) | |
15427 | (bucket_check_alias_consistence, bucket_pack, bucket_translation) | |
15428 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
15429 | (buckets_new, buckets_free, buckets_do): Rename as... | |
15430 | (symbol_list_new, symbol_check_defined, symbol_make_alias) | |
15431 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
15432 | (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t) | |
15433 | (symbols_new, symbols_free, symbols_do): these. | |
15434 | ||
72a23c97 AD |
15435 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15436 | ||
15437 | Use lib/hash for the symbol table. | |
15438 | ||
15439 | * src/gram.c (ntokens): Initialize to 1, to reserve a slot for | |
15440 | EOF. | |
15441 | * src/lex.c (lex): Set the `number' member of new terminals. | |
15442 | * src/reader.c (bucket_check_defined, bucket_make_alias) | |
15443 | (bucket_check_alias_consistence, bucket_translation): New. | |
15444 | (reader, grammar_free, readgram, token_translations_init) | |
15445 | (packsymbols): Adjust. | |
15446 | (reader): Number the predefined tokens. | |
15447 | * src/reduce.c (inaccessable_symbols): Just use hard coded numbers | |
15448 | for predefined tokens. | |
15449 | * src/symtab.h (bucket): Remove all the hash table related | |
15450 | members. | |
15451 | * src/symtab.c (symtab): Replace by... | |
15452 | (bucket_table): this. | |
15453 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
15454 | (buckets_new, buckets_do): New. | |
15455 | ||
280a38c3 AD |
15456 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15457 | ||
15458 | * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems) | |
15459 | (start_symbol, max_user_token_number, semantic_parser) | |
15460 | (error_token_number): Initialize. | |
15461 | * src/reader.c (grammar, start_flag, startval, typed, lastprec): | |
15462 | Initialize. | |
15463 | (reader): Don't. | |
15464 | (errtoken, eoftoken, undeftoken, axiom): Extern. | |
15465 | ||
03b31c0c AD |
15466 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15467 | ||
15468 | * src/gram.h (rule_s): prec and precsym are now pointers | |
15469 | to the bucket giving the priority/associativity. | |
15470 | Member `associativity' removed: useless. | |
15471 | * src/reduce.c, src/conflicts.c: Adjust. | |
15472 | ||
8b3df748 AD |
15473 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15474 | ||
15475 | * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c: | |
15476 | Properly escape the symbols' TAG when outputting them. | |
15477 | ||
e601aa1d AD |
15478 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15479 | ||
15480 | * src/lalr.h (LA): Is a bitsetv, not bitset*. | |
15481 | ||
b0299a2e AD |
15482 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15483 | ||
15484 | * src/lalr.h, src/lalr.c (LAruleno): Replace with... | |
15485 | (LArule): this, which is an array to rule_t*. | |
15486 | * src/print.c, src/conflicts.c: Adjust. | |
15487 | ||
d7e1f00c AD |
15488 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15489 | ||
15490 | * src/gram.h (rule_t): Rename `number' as `user_number'. | |
15491 | `number' is a new member. | |
15492 | Adjust dependencies. | |
15493 | * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number. | |
15494 | ||
cc9305dd AD |
15495 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15496 | ||
15497 | As a result of the previous patch, it is no longer needed | |
15498 | to reorder ritem itself. | |
15499 | ||
15500 | * src/reduce.c (reduce_grammar_tables): Don't sort RITEM. | |
15501 | ||
b0940840 AD |
15502 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15503 | ||
15504 | Be sure never to walk through RITEMS, but use only data related to | |
15505 | the rules themselves. RITEMS should be banished. | |
15506 | ||
15507 | * src/output.c (output_token_translations): Rename as... | |
15508 | (prepare_tokens): this. | |
15509 | In addition to `translate', prepare the muscles `tname' and | |
15510 | `toknum', which were handled by... | |
15511 | (output_rule_data): this. | |
15512 | Remove, and move the remainder of its outputs into... | |
15513 | (prepare_rules): this new routines, which also merges content from | |
15514 | (output_gram): this. | |
15515 | (prepare_rules): Be sure never to walk through RITEMS. | |
15516 | (output_stos): Rename as... | |
15517 | (prepare_stos): this. | |
15518 | (output): Always invoke prepare_states, after all, just don't use it | |
15519 | in the output if you don't need it. | |
15520 | ||
643a5994 AD |
15521 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15522 | ||
15523 | * src/LR0.c (new_state): Display `nstates' as the name of the | |
15524 | newly created state. | |
15525 | Adjust to initialize first_state and last_state if needed. | |
15526 | Be sure to distinguish the initial from the final state. | |
15527 | (new_states): Create the itemset of the initial state, and use | |
15528 | new_state. | |
15529 | * src/closure.c (closure): Now that the initial state has its | |
15530 | items properly set, there is no need for a special case when | |
15531 | creating `ruleset'. | |
15532 | ||
15533 | As a result, now the rule 0, reducing to $axiom, is visible in the | |
15534 | outputs. Adjust the test suite. | |
15535 | ||
15536 | * tests/conflicts.at (Solved SR Conflicts) | |
15537 | (Unresolved SR Conflicts): Adjust. | |
15538 | * tests/regression.at (Web2c Report, Rule Line Numbers): Idem. | |
15539 | * tests/conflicts.at (S/R in initial): New. | |
15540 | ||
b4c4ccc2 AD |
15541 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15542 | ||
15543 | * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over | |
15544 | the RHS of the rules. | |
15545 | * src/output.c (output_gram): Likewise. | |
15546 | ||
bba97eb2 AD |
15547 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15548 | ||
15549 | * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's | |
15550 | bucket. | |
15551 | Adjust all dependencies. | |
15552 | * src/reduce.c (nonterminals_reduce): Don't forget to renumber the | |
15553 | `number' of the buckets too. | |
15554 | * src/gram.h: Include `symtab.h'. | |
15555 | (associativity): Move to... | |
15556 | * src/symtab.h: here. | |
15557 | No longer include `gram.h'. | |
15558 | ||
c3b407f4 AD |
15559 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15560 | ||
15561 | * src/gram.h, src/gram.c (rules_rhs_length): New. | |
15562 | (ritem_longest_rhs): Use it. | |
15563 | * src/gram.h (rule_t): `number' is a new member. | |
15564 | * src/reader.c (packgram): Set it. | |
15565 | * src/reduce.c (reduce_grammar_tables): Move the useless rules at | |
15566 | the end of `rules', and count them out of `nrules'. | |
15567 | (reduce_output, dump_grammar): Adjust. | |
15568 | * src/print.c (print_grammar): It is no longer needed to check for | |
15569 | the usefulness of a rule, as useless rules are beyond `nrules + 1'. | |
15570 | * tests/reduce.at (Reduced Automaton): New test. | |
15571 | ||
11652ab3 AD |
15572 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15573 | ||
15574 | * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a | |
15575 | lacking `+ 1' to nrules, Bison reported as useless a token if it | |
15576 | was used solely to set the precedence of the last rule... | |
15577 | ||
26b23c1a AD |
15578 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15579 | ||
15580 | * data/bison.c++, data/bison.simple: Don't output the current file | |
15581 | name in #line, to avoid useless diffs between two identical | |
15582 | outputs under different names. | |
15583 | ||
18bcecb0 AD |
15584 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15585 | ||
15586 | * src/closure.c, src/print.c, src/reader.c, src/reduce.c: | |
15587 | Normalize loops to using `< nrules + 1', not `<= nrules'. | |
15588 | ||
fa770c86 AD |
15589 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15590 | ||
15591 | * TODO: Update. | |
15592 | ||
d9b739c3 AD |
15593 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15594 | ||
15595 | * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename | |
15596 | bucket.value as bucket.number. | |
15597 | ||
99013900 AD |
15598 | 2002-04-07 Akim Demaille <akim@epita.fr> |
15599 | ||
15600 | * src/closure.c, src/derives.c, src/gram.h, src/lalr.c, | |
15601 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
15602 | * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the | |
15603 | RHS, instead of being an index in RITEMS. | |
15604 | ||
e966383b PE |
15605 | 2002-04-04 Paul Eggert <eggert@twinsun.com> |
15606 | ||
15607 | * doc/bison.texinfo: Update copyright date. | |
15608 | (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII. | |
15609 | (Symbols): Warn about running Bison in one character set, | |
15610 | but compiling and/or running in an incompatible one. | |
15611 | Warn about character code 256, too. | |
15612 | ||
15613 | 2002-04-03 Paul Eggert <eggert@twinsun.com> | |
15614 | ||
15615 | * src/bison.data (YYSTACK_ALLOC): Depend on whether | |
15616 | YYERROR_VERBOSE is nonzero, not whether it is defined. | |
15617 | ||
15618 | Merge changes from bison-1_29-branch. | |
c307773e | 15619 | |
8d6c48b9 PE |
15620 | 2002-03-20 Paul Eggert <eggert@twinsun.com> |
15621 | ||
15622 | Merge fixes from Debian bison_1.34-1.diff. | |
15623 | ||
15624 | * configure.in (AC_PREREQ): 2.53. | |
15625 | ||
e53c6322 AD |
15626 | 2002-03-20 Akim Demaille <akim@epita.fr> |
15627 | ||
15628 | * src/conflicts.c (log_resolution): Argument `resolution' is const. | |
15629 | ||
9ffbeca7 PE |
15630 | 2002-03-19 Paul Eggert <eggert@twinsun.com> |
15631 | ||
21db0b2a PE |
15632 | * src/bison.simple (YYCOPY): New macro. |
15633 | (YYSTACK_RELOCATE): Use it. | |
15634 | Remove Type arg; no longer needed. All callers changed. | |
15635 | (yymemcpy): Remove; no longer needed. | |
15636 | ||
9ffbeca7 PE |
15637 | * Makefile.am (AUTOMAKE_OPTIONS): 1.6. |
15638 | * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
15639 | ||
642cb8f8 AD |
15640 | 2002-03-19 Akim Demaille <akim@epita.fr> |
15641 | ||
15642 | Test and fix the #line outputs. | |
15643 | ||
15644 | * tests/atlocal.at (GCC): New. | |
15645 | * tests/synclines.at (AT_TEST_SYNCLINE): New macro. | |
0ffd4fd1 | 15646 | (Prologue synch line, %union synch line, Postprologue synch line) |
642cb8f8 AD |
15647 | (Action synch line, Epilogue synch line): New tests. |
15648 | * src/reader.c (parse_union_decl): Define the muscle stype_line. | |
15649 | * data/bison.simple, data/bison.c++: Use it. | |
15650 | ||
3c31a486 AD |
15651 | 2002-03-19 Akim Demaille <akim@epita.fr> |
15652 | ||
15653 | * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts) | |
15654 | (Solved SR Conflicts, %expect not enough, %expect right) | |
15655 | (%expect too much): Move to... | |
15656 | * tests/conflicts.at: this new file. | |
15657 | ||
0d8bed56 AD |
15658 | 2002-03-19 Akim Demaille <akim@epita.fr> |
15659 | ||
15660 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
15661 | * data/bison.simple, data/bison.c++: Handle the `#define' part, so | |
15662 | that we can move to enums for instance. | |
15663 | * src/output.c (token_definitions_output): Output a list of | |
15664 | `token-name, token-number' instead of the #define. | |
15665 | (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'. | |
15666 | ||
9208d17f AD |
15667 | 2002-03-14 Akim Demaille <akim@epita.fr> |
15668 | ||
15669 | Use Gettext 0.11.1. | |
15670 | ||
af27eacb RA |
15671 | 2002-03-09 Robert Anisko <robert@lrde.epita.fr> |
15672 | ||
15673 | * data/bison.c++: Make the user able to add members to the generated | |
15674 | parser by subclassing. | |
15675 | ||
9101a310 RA |
15676 | 2002-03-05 Robert Anisko <robert@lrde.epita.fr> |
15677 | ||
15678 | * src/reader.c (read_additionnal_code): `c' should be an integer, not | |
15679 | a character. | |
15680 | Reported by Nicolas Tisserand and Nicolas Burrus. | |
15681 | ||
fff9bf0b RA |
15682 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
15683 | ||
15684 | * src/reader.c: Warn about lacking semi-colons, do not complain. | |
15685 | ||
64dba31e RA |
15686 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
15687 | ||
15688 | * data/bison.c++: Remove a debug line. | |
15689 | ||
374f5a14 RA |
15690 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
15691 | ||
15692 | * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge | |
15693 | location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and | |
15694 | provide a default implementation. | |
15695 | ||
bfcf1f3a AD |
15696 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15697 | ||
15698 | * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'. | |
15699 | * tests/output.at (AT_CHECK_OUTPUT): Likewise. | |
15700 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto. | |
15701 | * tests/semantic.at (Parsing Guards): Similarly. | |
15702 | * src/reader.at (readgram): Complain if the last rule is not ended | |
15703 | with a semi-colon. | |
15704 | ||
65ccf9fc AD |
15705 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15706 | ||
15707 | * src/warshall.h, src/warshall.c (bitmatrix_print): Move to... | |
15708 | * src/closure.c: here. | |
15709 | (set_firsts): Use bitsetv_reflexive_transitive_closure instead of | |
15710 | RTC. | |
15711 | * src/warshall.h, src/warshall.c: Remove. | |
15712 | * tests/sets.at (Broken Closure): Adjust. | |
15713 | ||
d0039cbc AD |
15714 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15715 | ||
15716 | * src/output.c (output_skeleton): tempdir is const. | |
15717 | bytes_read is unused. | |
15718 | ||
345cea78 AD |
15719 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15720 | ||
15721 | * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
15722 | * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c: | |
15723 | Update. | |
15724 | From Michael Hayes. | |
15725 | ||
564801f7 AD |
15726 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15727 | ||
15728 | * src/closure.c (closure): `r' is unused. | |
15729 | ||
e5352bc7 AD |
15730 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15731 | ||
15732 | * tests/sets.at (Broken Closure): Add the ending `;'. | |
15733 | * src/reader.at (readgram): Complain if a rule is not ended with a | |
15734 | semi-colon. | |
15735 | ||
914feea9 AD |
15736 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15737 | ||
15738 | * src/conflicts.c (set_conflicts): Use bitset_disjoint_p. | |
15739 | (count_sr_conflicts): Use bitset_count. | |
15740 | * src/reduce.c (inaccessable_symbols): Ditto. | |
15741 | (bits_size): Remove. | |
15742 | * src/warshall.h, src/warshall.c: Convert to bitsetv. | |
15743 | ||
f0250de6 AD |
15744 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15745 | ||
15746 | * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c, | |
15747 | * src/reduce.c: Remove the `bitset_zero's following the | |
15748 | `bitset_create's, as now it is performed by the latter. | |
15749 | ||
ef017502 AD |
15750 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15751 | ||
15752 | * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h, | |
15753 | * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h, | |
15754 | * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the | |
15755 | latest sources from Michael. | |
15756 | ||
76514394 AD |
15757 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15758 | ||
15759 | * src/output.c (output): Don't free the grammar. | |
15760 | * src/reader.c (grammar_free): New. | |
15761 | * src/main.c (main): Call it and don't free symtab here. | |
15762 | ||
55024580 AD |
15763 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15764 | ||
15765 | * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer | |
15766 | before returning. | |
15767 | Reported by Benoit Perrot. | |
15768 | ||
f9abaa2c AD |
15769 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15770 | ||
15771 | Use bitset operations when possible, not loops over bits. | |
15772 | ||
15773 | * src/conflicts.c (set_conflicts, count_sr_conflicts): Use | |
15774 | bitset_or. | |
15775 | * src/print.c (print_reductions): Use bitset_and, bitset_andn. | |
15776 | * src/reduce.c (useless_nonterminals): Formatting changes. | |
15777 | * src/warshall.c (TC): Use bitset_or. | |
15778 | ||
0e721e75 AD |
15779 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15780 | ||
15781 | * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused. | |
15782 | * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET): | |
15783 | Ditto. | |
15784 | ||
0fb1ffb1 AD |
15785 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15786 | ||
15787 | * src/lalr.c (F): Now a bitset*. | |
15788 | Adjust all dependencies. | |
15789 | ||
b86796bf AD |
15790 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15791 | ||
15792 | * src/conflicts.c (shiftset, lookaheadset): Now bitset. | |
15793 | Adjust all dependencies. | |
15794 | ||
602bbf31 AD |
15795 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15796 | ||
15797 | * src/L0.c, src/LR0.h (nstates): Be size_t. | |
15798 | Adjust comparisons (signed vs unsigned). | |
15799 | * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a | |
15800 | bitset*. | |
15801 | Adjust all dependencies. | |
15802 | ||
d8a0245c AD |
15803 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15804 | ||
15805 | * src/closure.c (firsts): Now, also a bitset. | |
15806 | Adjust all dependencies. | |
15807 | (varsetsize): Remove, now unused. | |
15808 | * src/warshall.h, src/warshall.c: Now work on arrays of bitsets. | |
15809 | ||
34ba9743 AD |
15810 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15811 | ||
15812 | * src/print.c: Convert to use bitset.h, not hand coded iterations | |
15813 | over ints. | |
15814 | ||
ed86e78c AD |
15815 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15816 | ||
15817 | * src/reduce.c: Convert to use bitset.h, not hand coded BSet. | |
15818 | ||
dfdb1797 AD |
15819 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15820 | ||
15821 | * src/closure.c (ruleset): Be a bitset. | |
15822 | (rulesetsize): Remove. | |
15823 | ||
7086e707 AD |
15824 | 2002-03-04 Akim Demaille <akim@epita.fr> |
15825 | ||
15826 | * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
15827 | * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, | |
15828 | * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New. | |
15829 | * src/closure.c (fderives): Be an array of bitsets. | |
15830 | ||
98254360 RA |
15831 | 2002-02-28 Robert Anisko <robert@lrde.epita.fr> |
15832 | ||
15833 | * data/bison.c++: Merge the two generated headers. Insert a copyright | |
15834 | notice in each output file. | |
15835 | ||
a75c057f AD |
15836 | 2002-02-28 Akim Demaille <akim@epita.fr> |
15837 | ||
15838 | * data/bison.c++: Copy the prologue of bison.simple to fetch | |
15839 | useful M4 definitions, such as b4_header_guard. | |
15840 | ||
06b00abc AD |
15841 | 2002-02-25 Akim Demaille <akim@epita.fr> |
15842 | ||
15843 | * src/getargs.c (version): Give the name of the authors, and use a | |
a75c057f AD |
15844 | translator friendly scheme for the bgr |
15845 | copyright notice. | |
06b00abc | 15846 | |
70e7d534 AD |
15847 | 2002-02-25 Akim Demaille <akim@epita.fr> |
15848 | ||
15849 | * src/output.c (header_output): Remove, now handled completely via | |
15850 | M4. | |
15851 | ||
abe017f6 AD |
15852 | 2002-02-25 Akim Demaille <akim@epita.fr> |
15853 | ||
15854 | * m4/m4.m4: New, from CVS Autoconf. | |
15855 | * configure.in: Invoke it. | |
15856 | * src/output.c (output_skeleton): Use its result instead of the | |
15857 | hard coded name. | |
15858 | ||
381fb12e AD |
15859 | 2002-02-25 Akim Demaille <akim@epita.fr> |
15860 | ||
15861 | * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from | |
15862 | Fileutils 4.1.5. | |
15863 | * configure.in: Invoke UTILS_FUNC_MKSTEMP. | |
15864 | * src/output.c (output_skeleton): Use mkstemp to create a real | |
15865 | temporary file. | |
15866 | Move the filling of `skeleton' and its muscle to... | |
15867 | (prepare): here. | |
15868 | (output): Move the definition of the prologue muscle to... | |
15869 | (prepare): here. | |
15870 | * src/system.h (DEFAULT_TMPDIR): New. | |
15871 | ||
6f38107f PE |
15872 | 2002-02-14 Paul Eggert <eggert@twinsun.com> |
15873 | ||
15874 | Remove the support for C++ namespace cleanliness; it was | |
15875 | causing more problems than it was curing, since it didn't work | |
15876 | properly on some nonstandard C++ compilers. This can wait | |
15877 | for a proper C++ parser. | |
15878 | ||
15879 | * NEWS: Document this. | |
15880 | * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention | |
15881 | of C++, as it's treated like C now. | |
15882 | * src/bison.simple (YYSTD): Remove. | |
15883 | (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL): | |
15884 | Treat C++ just like Standard C instead of trying to support | |
15885 | namespace cleanliness. | |
15886 | ||
80cce3da AD |
15887 | 2002-02-14 Akim Demaille <akim@epita.fr> |
15888 | ||
15889 | * tests/regression.at (else): Adjust to Andreas' change. | |
15890 | ||
842e8679 AD |
15891 | 2002-02-14 Akim Demaille <akim@epita.fr> |
15892 | ||
15893 | * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c. | |
15894 | ||
4bda3f10 AD |
15895 | 2002-02-13 Andreas Schwab <schwab@suse.de> |
15896 | ||
15897 | * src/output.c (output_rule_data): Don't output NULL, it might | |
15898 | not be defined yet. | |
15899 | ||
4162fa07 | 15900 | 2002-02-11 Robert Anisko <robert@lrde.epita.fr> |
b418ecd8 | 15901 | |
4162fa07 RA |
15902 | * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue. |
15903 | (Copyright notice): Update. | |
b418ecd8 | 15904 | |
bd16a5dc AD |
15905 | 2002-02-11 Akim Demaille <akim@epita.fr> |
15906 | ||
15907 | * tests/regression.at (%nonassoc and eof): Don't include | |
15908 | nonportable headers. | |
15909 | ||
8d69a1a3 RA |
15910 | 2002-02-08 Robert Anisko <robert@lrde.epita.fr> |
15911 | ||
15912 | * data/bison.c++: Correct error recovery. Make the user able to | |
15913 | initialize the starting location. | |
15914 | ||
9b2d0677 AD |
15915 | 2002-02-07 Akim Demaille <akim@epita.fr> |
15916 | ||
15917 | * tests/input.at: New. | |
15918 | ||
69e2658b RA |
15919 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
15920 | ||
15921 | * data/bison.c++: Replace some direct m4 expansions by constants. Be | |
9b2d0677 | 15922 | more consistent when naming methods and variables. Put preprocessor |
69e2658b RA |
15923 | directives around tables only needed for debugging. |
15924 | ||
4aacc3a7 RA |
15925 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
15926 | ||
15927 | * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in | |
15928 | C++ parsers. | |
15929 | (yy::b4_name::parse): Use print_. | |
15930 | ||
762a801e RA |
15931 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
15932 | ||
15933 | * data/bison.c++ (yy::b4_name::parse): Error recovery is back. | |
15934 | ||
4bb2bc3f RA |
15935 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
15936 | ||
15937 | * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in | |
15938 | C++ parsers. | |
15939 | (yy::b4_name::parse): Build verbose error messages, and use error_. | |
15940 | ||
6b45a3ca RA |
15941 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> |
15942 | ||
15943 | * data/bison.c++: Fix m4 quoting in comments. | |
15944 | ||
50997c6e RA |
15945 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> |
15946 | ||
15947 | * data/bison.c++: Adjust the parser code. Fix some muscles that were | |
15948 | not expanded by m4. | |
15949 | ||
3f3eed27 AD |
15950 | 2002-02-05 Akim Demaille <akim@epita.fr> |
15951 | ||
15952 | * data/bison.c++: Adjust to the M4 back end. | |
15953 | More is certainly needed. | |
15954 | ||
be2a1a68 AD |
15955 | 2002-02-05 Akim Demaille <akim@epita.fr> |
15956 | ||
15957 | Give a try to M4 as a back end. | |
15958 | ||
15959 | * lib/readpipe.c: New, from wdiff. | |
15960 | * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and | |
15961 | BISON_HAIRY. | |
15962 | * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS | |
15963 | specific values. Now it is m4 that performs the lookup. | |
15964 | * src/parse-skel.y: Remove. | |
15965 | * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New. | |
15966 | * src/output.c (actions_output, guards_output) | |
15967 | (token_definitions_output): No longer keeps track of the output | |
15968 | line number, hence remove the second argument. | |
15969 | (guards_output): Check against the guard member of a rule, not the | |
15970 | action member. | |
15971 | Adjust callers. | |
15972 | (output_skeleton): Don't look for the skeleton location, let m4 do | |
15973 | that. | |
15974 | Create `/tmp/muscles.m4'. This is temporary, a proper temporary | |
15975 | file will be used. | |
15976 | Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton. | |
15977 | (prepare): Given that for the time being changesyntax is not | |
15978 | usable in M4, rename the muscles using `-' to `_'. | |
15979 | Define `defines_flag', `output_parser_name' and `output_header_name'. | |
15980 | * src/output.h (actions_output, guards_output) | |
15981 | (token_definitions_output): Adjust prototypes. | |
15982 | * src/scan-skel.l: Instead of scanning the skeletons, it now | |
15983 | processes the output of m4: `__oline__' and `#output'. | |
15984 | * data/bison.simple: Adjust to be used by M4(sugar). | |
15985 | * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up | |
15986 | to date. | |
15987 | * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR' | |
15988 | instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'. | |
15989 | * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New, | |
15990 | shamelessly stolen from CVS Autoconf. | |
15991 | ||
beda758b AD |
15992 | 2002-02-05 Akim Demaille <akim@epita.fr> |
15993 | ||
15994 | * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version. | |
15995 | * configure.in: Check for the declarations of free and malloc. | |
15996 | * src/muscle_tab.c: Adjust. | |
15997 | ||
5ece6d43 AD |
15998 | 2002-02-05 Akim Demaille <akim@epita.fr> |
15999 | ||
16000 | * src/muscle_tab.c (muscle_init): Don't default to NULL muscle | |
16001 | which have no values. | |
16002 | ||
5bb18f9a AD |
16003 | 2002-02-05 Akim Demaille <akim@epita.fr> |
16004 | ||
16005 | * src/bison.simple, src/bison.hairy, src/bison.c++: Move to... | |
16006 | * data/: here. | |
16007 | ||
894dd62e PE |
16008 | 2002-01-29 Paul Eggert <eggert@twinsun.com> |
16009 | ||
16010 | * src/bison.simple (YYSIZE_T): Do not define merely because | |
16011 | YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined. | |
16012 | On some platforms, <alloca.h> does not declare YYSTD (size_t). | |
16013 | ||
82841af7 AD |
16014 | 2002-01-27 Akim Demaille <akim@epita.fr> |
16015 | ||
16016 | Fix `%nonassoc and eof'. | |
16017 | ||
16018 | * src/state.c (errs_dup): Aaaah! The failure was due to bytes | |
16019 | which were not properly copied! Replace | |
16020 | memcpy (res->errs, src->errs, src->nerrs); | |
16021 | with | |
16022 | memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0])); | |
16023 | !!! | |
16024 | * tests/regression.at (%nonassoc and eof): Adjust to newest | |
16025 | Autotest: `.' is not in the PATH. | |
16026 | ||
318b76e9 AD |
16027 | 2002-01-27 Akim Demaille <akim@epita.fr> |
16028 | ||
16029 | * tests/sets.at (AT_EXTRACT_SETS): New. | |
16030 | (Nullable): Use it. | |
16031 | (Firsts): New. | |
16032 | ||
30d2f3d5 AD |
16033 | 2002-01-26 Akim Demaille <akim@epita.fr> |
16034 | ||
16035 | * tests/actions.at, tests/calc.at, tests/headers.at, | |
16036 | * tests/torture.at: Adjust to the newest Autotest which no longer | |
16037 | forces `.' in the PATH. | |
16038 | ||
30f8c395 AD |
16039 | 2002-01-25 Akim Demaille <akim@epita.fr> |
16040 | ||
16041 | * tests/regression.at (%nonassoc and eof): New. | |
16042 | Suggested by Robert Anisko. | |
16043 | ||
29ae55f1 AD |
16044 | 2002-01-24 Akim Demaille <akim@epita.fr> |
16045 | ||
16046 | Bison dumps core when trying to complain about broken input files. | |
16047 | Reported by Cris van Pelt. | |
16048 | ||
16049 | * src/lex.c (parse_percent_token): Be sure to set token_buffer. | |
16050 | * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge | |
16051 | into... | |
16052 | (Invalid inputs): Strengthen: exercise parse_percent_token. | |
16053 | ||
2b548aa6 RA |
16054 | 2002-01-24 Robert Anisko <robert.anisko@epita.fr> |
16055 | ||
16056 | * src/Makefile.am: Add bison.c++. | |
16057 | * src/bison.c++: New skeleton. | |
16058 | ||
bb0146c2 AD |
16059 | 2002-01-21 Paolo Bonzini <bonzini@gnu.org> |
16060 | ||
16061 | * po/it.po: New. | |
16062 | ||
bec30531 AD |
16063 | 2002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net> |
16064 | ||
16065 | * src/files.c (skeleton_find) [MSDOS]: Fix cp definition. | |
16066 | ||
fc6edc45 MA |
16067 | 2002-01-20 Marc Autret <marc@gnu.org> |
16068 | ||
16069 | * src/files.c (compute_output_file_names): Fix | |
16070 | ||
5e5d5415 MA |
16071 | 2002-01-20 Marc Autret <marc@gnu.org> |
16072 | ||
16073 | * tests/output.at: New test. | |
16074 | * src/files.c (compute_base_names): Don't map extensions when | |
16075 | the YACC flag is set, use defaults. | |
16076 | Reported by Evgeny Stambulchik. | |
16077 | ||
44ea3fbd MA |
16078 | 2002-01-20 Marc Autret <marc@gnu.org> |
16079 | ||
ba0fe3c7 PE |
16080 | * src/system.h: Need to define __attribute__ away for non-GCC |
16081 | compilers as well (i.e., the vendor C compiler). | |
44ea3fbd MA |
16082 | Suggested by Albert Chin-A-Young. |
16083 | ||
338963d1 TVH |
16084 | 2002-01-11 Tim Van Holder <tim.van.holder@pandora.be> |
16085 | ||
16086 | * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the | |
16087 | canonical definition. | |
16088 | * src/system.h: Use the canonical definition for PARAMS (avoids | |
16089 | a conflict with the macro from lib/hash.h). | |
16090 | ||
c57b2479 AD |
16091 | 2002-01-11 Akim Demaille <akim@epita.fr> |
16092 | ||
16093 | * configure.in: Use AC_FUNC_STRNLEN. | |
d9e9746c | 16094 | Fixes the failures observed on AIX 4.3 by H.Merijn Brand. |
c57b2479 | 16095 | |
b85810ae AD |
16096 | 2002-01-09 Akim Demaille <akim@epita.fr> |
16097 | ||
16098 | * src/files.c, src/files.h (output_infix): New. | |
16099 | (tab_extension): Remove. | |
16100 | (compute_base_names): Compute the former, drop the latter. | |
16101 | * src/output.c (prepare): Insert the muscles `output-infix', and | |
16102 | `output-suffix'. | |
16103 | * src/parse-skel.y (string, string.1): New. | |
16104 | (section.header): Use it. | |
16105 | (section.yacc): Remove. | |
16106 | (prefix): Remove too. | |
16107 | * src/scan-skel.l: Adjust. | |
16108 | * src/bison.simple, src/bison.hairy: Adjust. | |
16109 | ||
cae60122 AD |
16110 | 2002-01-09 Akim Demaille <akim@epita.fr> |
16111 | ||
16112 | * configure.in (WERROR_CFLAGS): Compute it. | |
16113 | * src/Makefile.am (CFLAGS): Pass it. | |
16114 | * tests/atlocal.in (CFLAGS): Idem. | |
16115 | * src/files.c: Fix a few warnings. | |
16116 | (get_extension_index): Remove, unused. | |
16117 | ||
ae404801 AD |
16118 | 2002-01-08 Akim Demaille <akim@epita.fr> |
16119 | ||
16120 | * src/getargs.c (AS_FILE_NAME): New. | |
16121 | (getargs): Use it to convert DOSish file names. | |
16122 | * src/files.c (base_name): Rename as full_base_name to avoid | |
16123 | clashes with `base_name ()'. | |
16124 | (filename_split): New. | |
16125 | (compute_base_names): N-th rewrite, using filename_split. | |
16126 | ||
22312b71 AD |
16127 | 2002-01-08 Akim Demaille <akim@epita.fr> |
16128 | ||
16129 | * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c: | |
16130 | New, stolen from the Fileutils 4.1. | |
16131 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
16132 | * configure.in: Check for the presence of memrchr, and of its | |
16133 | prototype. | |
16134 | ||
a67cef01 TVH |
16135 | 2002-01-07 Tim Van Holder <tim.van.holder@pandora.be> |
16136 | ||
16137 | * lib/hash.h (__P): Added definition for this macro. | |
16138 | * src/Makefile.am: Add parse-skel.c and scan-skel.c to | |
16139 | BUILT_SOURCES, to ensure they are generated first. | |
16140 | * src/parse-skel.y: Use YYERROR_VERBOSE instead of | |
16141 | %error-verbose to allow bootstrapping with bison 1.30x. | |
16142 | ||
2b25d624 AD |
16143 | 2002-01-06 Akim Demaille <akim@epita.fr> |
16144 | ||
16145 | * src/reader.c (parse_braces): Don't fetch the next char, the | |
16146 | convention is to fetch on entry. | |
16147 | * tests/torture.at (GNU Cim Grammar): Reintroduce their weird | |
16148 | 'switch' without a following semicolon. | |
16149 | * tests/regression.at (braces parsing): New. | |
16150 | ||
3460813b AD |
16151 | 2002-01-06 Akim Demaille <akim@epita.fr> |
16152 | ||
16153 | Bison is dead wrong in its RR conflict reports. | |
16154 | ||
16155 | * tests/torture.at (GNU Cim Grammar): New. | |
16156 | * src/conflicts.c (count_rr_conflicts): Fix. | |
16157 | ||
73784c64 AD |
16158 | 2002-01-06 Akim Demaille <akim@epita.fr> |
16159 | ||
16160 | Creating package.m4 from configure.ac causes too many problems. | |
16161 | ||
16162 | * tests/Makefile.am (package.m4): Create it by hand, | |
16163 | AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf. | |
16164 | ||
25d81090 AD |
16165 | 2002-01-06 Akim Demaille <akim@epita.fr> |
16166 | ||
16167 | * src/Makefile.am (bison_SOURCES): Add parse-skel.h and | |
16168 | skeleton.h. | |
16169 | ||
a9b8959e PE |
16170 | 2002-01-04 Paul Eggert <eggert@twinsun.com> |
16171 | ||
16172 | * doc/bison.texinfo (Debugging): | |
16173 | Remove YYSTDERR; it's no longer defined or used. | |
16174 | Also, s/cstdio.h/cstdio/. | |
16175 | ||
25d81090 AD |
16176 | 2002-01-03 Akim Demaille <akim@epita.fr> |
16177 | ||
16178 | * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf. | |
16179 | ||
1109455c AD |
16180 | 2002-01-03 Akim Demaille <akim@epita.fr> |
16181 | ||
16182 | * src/parse-skel.y (process_skeleton): Don't bind the parser's | |
16183 | tracing code to --trace, wait for a better --trace option, with | |
16184 | args. | |
16185 | ||
7ea5e977 AD |
16186 | 2002-01-03 Akim Demaille <akim@epita.fr> |
16187 | ||
16188 | * src/bison.simple (YYSTDERR): Remove, replace `stderr'. | |
16189 | The ISO C++ standard is extremely clear about it: stderr is | |
16190 | considered a macro, not a regular symbol (see table 94 `Header | |
16191 | <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files). | |
16192 | Therefore std:: does not apply to it. It still does with fprintf. | |
16193 | Also, s/cstdio.h/cstdio/. | |
16194 | ||
fab5b110 AD |
16195 | 2002-01-03 Akim Demaille <akim@epita.fr> |
16196 | ||
16197 | * lib/quotearg.c: Use `#include "..."' instead of `#include <...>' | |
16198 | for non system headers. | |
16199 | ||
aed7fd9b AD |
16200 | 2002-01-02 Akim Demaille <akim@epita.fr> |
16201 | ||
16202 | Equip the skeleton chain with location tracking, runtime trace, | |
16203 | pure parser and scanner. | |
16204 | ||
16205 | * src/parse-skel.y: Request a pure parser, locations, and prefix | |
16206 | renaming. | |
16207 | (%union): Having several members with the same type does not help | |
16208 | type mismatches, simplify. | |
16209 | (YYPRINT, yyprint): New. | |
16210 | (yyerror): ``Rename'' (there is a #define yyerror skel_error) as... | |
16211 | (skel_error): this. | |
16212 | Handle locations. | |
16213 | * src/scan-skel.l: Adjust to these changes. | |
16214 | * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP) | |
16215 | (LOCATION_PRINT, skel_control_t): New. | |
16216 | ||
24fad99e AD |
16217 | 2001-12-30 Akim Demaille <akim@epita.fr> |
16218 | ||
16219 | * src/parse-skel.y: Get rid of the shift/reduce conflict: | |
16220 | replace `gb' with BLANKS. | |
16221 | * src/scan-skel.l: Adjust. | |
16222 | ||
a4b36db4 AD |
16223 | 2001-12-30 Akim Demaille <akim@epita.fr> |
16224 | ||
16225 | * src/system.h: We don't need nor want bcopy. | |
16226 | Throw away MS-DOS crap: we don't need getpid. | |
16227 | * configure.in: We don't need strndup. It was even causing | |
16228 | problems: because Flex includes the headers *before* us, | |
16229 | _GNU_SOURCE is not defined by config.h, and therefore strndup was | |
16230 | not visible. | |
16231 | * lib/xstrndup.c: New. | |
16232 | * src/scan-skel.l: Use it. | |
16233 | Be sure to initialize yylval.muscle member when scanning a MUSCLE. | |
16234 | * src/parse-skel.y: Use %directives instead of #defines. | |
16235 | ||
1239777d AD |
16236 | 2001-12-30 Akim Demaille <akim@epita.fr> |
16237 | ||
16238 | * src/skeleton.h: New. | |
16239 | * src/output.c (output_parser, output_master_parser): Remove, dead | |
16240 | code. | |
16241 | * src/output.h (get_lines_number, actions_output, guards_output) | |
16242 | (token_definitions_output): Prototype them. | |
16243 | * src/parse-skel.y: Add the license notice. | |
16244 | Include output.h and skeleton.h. | |
16245 | (process_skeleton): Returns void, and takes a single parameter. | |
16246 | * src/scan-skel.l: Add the license notice. | |
16247 | Include skeleton.h. | |
16248 | Don't use %option yylineno: it seems that then Flex imagines | |
16249 | REJECT has been used, and therefore it won't reallocate its | |
16250 | buffers (which makes no other sense to me than a bug). It results | |
16251 | in warnings for `unused: yy_flex_realloc'. | |
16252 | ||
9b3add5b RA |
16253 | 2001-12-30 Robert Anisko <robert.anisko@epita.fr> |
16254 | ||
16255 | * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
16256 | (MUSCLE_INSERT_PREFIX): ...to there. | |
16257 | * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
16258 | (MUSCLE_INSERT_PREFIX): Move from here... | |
16259 | ||
16260 | * src/bison.hairy: Add a section directive. Put braces around muscle | |
16261 | names. This parser skeleton is still broken, but Bison should not | |
16262 | choke on a bad muscle 'syntax'. | |
16263 | * src/bison.simple: Add a section directive. Put braces around muscle | |
16264 | names. | |
16265 | ||
16266 | * src/files.h (strsuffix, stringappend): Add declarations. | |
16267 | (tab_extension): Add declaration. | |
16268 | (short_base_name): Add declaration. | |
16269 | ||
16270 | * src/files.c (strsuffix, stringappend): No longer static. These | |
16271 | functions are used in the skeleton parser. | |
16272 | (tab_extension): New. | |
16273 | (compute_base_names): Use the computations done in this function | |
fab5b110 | 16274 | to guess if the generated parsers should have '.tab' in their |
9b3add5b RA |
16275 | names. |
16276 | (short_base_name): No longer static. | |
16277 | ||
16278 | * src/output.c (output_skeleton): New. | |
16279 | (output): Disable call to output_master_parser, and give a try to | |
16280 | a new skeleton handling system. | |
16281 | (guards_output, actions_output): No longer static. | |
16282 | (token_definitions_output, get_lines_number): No longer static. | |
16283 | ||
16284 | * configure.in: Use AM_PROG_LEX and AC_PROG_YACC. | |
16285 | ||
fab5b110 | 16286 | * src/Makefile.am (bison_SOURCES): Add scan-skel.l and |
9b3add5b RA |
16287 | parse-skel.y. |
16288 | ||
16289 | * src/parse-skel.y: New file. | |
16290 | * src/scan-skel.l: New file. | |
16291 | ||
b5b61c61 AD |
16292 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16293 | ||
16294 | %name-prefix is broken. | |
16295 | ||
16296 | * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy". | |
16297 | Adjust all dependencies. | |
16298 | * tests/headers.at (export YYLTYPE): Strengthen this test: use | |
16299 | %name-prefix. | |
16300 | ||
16301 | Renaming yylval but not yylloc is not consistent. Now we do. | |
16302 | ||
16303 | * src/bison.simple: Prefix yylloc if used. | |
16304 | * doc/bison.texinfo (Decl Summary): Document that. | |
16305 | ||
8c9a50be AD |
16306 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16307 | ||
16308 | * doc/bison.texinfo: Promote `%long-directive' over | |
16309 | `%long_directive'. | |
16310 | Remove all references to fixed-output-files, yacc is enough. | |
16311 | ||
d99361e6 AD |
16312 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16313 | ||
16314 | * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the | |
16315 | user prologue. These are defaults. | |
16316 | * tests/actions.at (Mid-rule actions): Make sure the user can | |
16317 | define YYDEBUG and YYERROR_VERBOSE. | |
16318 | ||
b9cecb91 AD |
16319 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16320 | ||
16321 | * src/output.c (header_output): Don't forget to export YYLTYPE and | |
16322 | yylloc. | |
16323 | * tests/headers.at (export YYLTYPE): New, make sure it does. | |
16324 | * tests/regression.at (%union and --defines, Invalid CPP headers): | |
16325 | Move to... | |
16326 | * tests/headers.at: here. | |
16327 | ||
aea13e97 AD |
16328 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16329 | ||
16330 | * src/gram.h (rule_s): Member `assoc' is of type `associativity'. | |
16331 | ||
931394cb AD |
16332 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16333 | ||
16334 | * tests/actions.at (Mid-rule actions): Output on a single line | |
16335 | instead of several. | |
16336 | ||
704a47c4 AD |
16337 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16338 | ||
16339 | * doc/bison.texinfo: Formatting changes. | |
16340 | ||
091e20bb AD |
16341 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16342 | ||
16343 | Don't store the token defs in a muscle, just be ready to output it | |
16344 | on command. Now possible via `symbols'. Fixes a memory leak. | |
16345 | ||
16346 | * src/output.c (token_definitions_output): New. | |
16347 | (output_parser, header_output): Use it. | |
16348 | * src/reader.c (symbols_save): Remove. | |
16349 | ||
cce71710 AD |
16350 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16351 | ||
16352 | * src/bison.simple: Do not provide a default for YYSTYPE and | |
16353 | YYLTYPE before the user's prologue. Otherwise it's hardly... a | |
16354 | default. | |
16355 | ||
82c035a8 AD |
16356 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16357 | ||
16358 | Mid-rule actions are simply... ignored! | |
16359 | ||
16360 | * src/reader.c (readgram): Be sure to attach mid-rule actions to | |
16361 | the empty-rule associated to the dummy symbol, not to the host | |
16362 | rule. | |
16363 | * tests/actions.at (Mid-rule actions): New. | |
16364 | ||
8419d367 AD |
16365 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16366 | ||
16367 | Memory leak. | |
16368 | ||
16369 | * src/reader.c (reader): Free grammar. | |
16370 | ||
375d5806 AD |
16371 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16372 | ||
16373 | Memory leak. | |
16374 | ||
16375 | * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here, | |
16376 | since it allocates it for each state, although only one is needed. | |
16377 | (allocate_storage): Do it here. | |
16378 | ||
f51cb8ff AD |
16379 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16380 | ||
16381 | * src/options.h, src/options.c (create_long_option_table): Rename | |
16382 | as... | |
16383 | (long_option_table_new): this, with a clearer prototype. | |
16384 | (percent_table): Remove, unused, | |
16385 | * src/getargs.c (getargs): Adjust. | |
16386 | ||
29e88316 AD |
16387 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16388 | ||
16389 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c | |
16390 | * src/print.c, src/print_graph.c, src/state.h: Rename state_table | |
16391 | as states. | |
16392 | ||
b9f71f19 AD |
16393 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16394 | ||
16395 | * src/lalr.c (build_relations): Rename `states' as `states1'. | |
16396 | Sorry, I don't understand exactly what it is, no better name... | |
16397 | ||
1a2b5d37 AD |
16398 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16399 | ||
16400 | * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c | |
16401 | * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c | |
16402 | * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table | |
16403 | as rules. | |
16404 | ||
1cca533e AD |
16405 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16406 | ||
16407 | * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long | |
16408 | ago. | |
16409 | ||
c03ae966 AD |
16410 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16411 | ||
16412 | * src/reader.c, src/reader.h (user_toknums): Remove. | |
16413 | Adjust all users to use symbols[i]->user_token_number. | |
16414 | ||
5a670b1e AD |
16415 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16416 | ||
16417 | * src/gram.c, src/gram.h (sprec, sassoc): Remove. | |
16418 | Adjust all users to use symbols[i]->prec or ->assoc. | |
16419 | ||
ad949da9 AD |
16420 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16421 | ||
16422 | * src/reader.c, src/reader.h (tags): Remove. | |
16423 | Adjust all users to use symbols[i]->tag. | |
16424 | ||
0e78e603 AD |
16425 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16426 | ||
16427 | * src/gram.h, src/gram.c (symbols): New, similar to state_table | |
16428 | and rule_table. | |
16429 | * src/reader.c (packsymbols): Fill this table. | |
16430 | Drop sprec. | |
16431 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
16432 | * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a | |
16433 | single table. | |
16434 | Use symbols[i]->tag instead of tags[i]. | |
16435 | ||
213e640e AD |
16436 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16437 | ||
16438 | * tests/calc.at (_AT_DATA_CALC_Y): Also use %union. | |
16439 | In addition, put a comment in there, to replace... | |
16440 | * tests/regression.at (%union and C comments): Remove. | |
16441 | ||
e7b8bef1 AD |
16442 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16443 | ||
16444 | * tests/regression.at (Web2c Actions): Blindly move the actual | |
16445 | output as expected output. The contents *seem* right to me, but I | |
16446 | can't pretend reading perfectly parser tables... Nonetheless, all | |
16447 | the other tests pass correctly, the table look OK, even though the | |
16448 | presence of `$axiom' is to be noted: AFAICS it is useless (but | |
16449 | harmless). | |
16450 | ||
b68e7744 AD |
16451 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16452 | ||
16453 | * src/reader.c (readgram): Don't add the rule 0 if there were no | |
16454 | rules read. In other words, add it _after_ having performed | |
16455 | grammar sanity checks. | |
16456 | Fixes the `tests/regression.at (Invalid input: 1)' Failure. | |
16457 | ||
78d5bae9 AD |
16458 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16459 | ||
16460 | * tests/regression.at (Web2c Report): Catch up: the rule 0 is now | |
16461 | visible, and some states have now a different number. | |
16462 | ||
ff442794 AD |
16463 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16464 | ||
16465 | * src/reader.c (readgram): Bind the initial rule's lineno to that | |
16466 | of the first rule. | |
16467 | * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts): | |
16468 | (Solved SR Conflicts): Adjust rule 0's line number. | |
16469 | ||
610ab194 AD |
16470 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16471 | ||
16472 | Fix the `GAWK Grammar' failure. | |
16473 | ||
16474 | * src/LR0.c (final_state): Initialize to -1 so that we do compute | |
16475 | the reductions of the first state which was mistakenly confused | |
16476 | with the final state because precisely final_state was initialized | |
16477 | to 0. | |
16478 | * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads, | |
16479 | now noticed by Bison. | |
16480 | * tests/regression.at (Rule Line Numbers): Adjust: state 0 does | |
16481 | have a reduction on $default. | |
16482 | ||
29d29c8f AD |
16483 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16484 | ||
16485 | * src/gram.c (ritem_print): Be sure to subtract 1 when displaying | |
16486 | rule line numbers. | |
16487 | * src/closure.c (print_closure): Likewise. | |
16488 | * src/derives.c (print_derives): Likewise. | |
16489 | * tests/sets.at (Nullable): Adjust: the rule numbers are correct | |
16490 | now. | |
16491 | ||
7c6b64d0 AD |
16492 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16493 | ||
16494 | * src/lalr.c (lookaheads_print): New. | |
16495 | (lalr): Call it when --trace-flag. | |
16496 | * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads | |
16497 | are dumped. | |
16498 | ||
3d4daee3 AD |
16499 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16500 | ||
16501 | * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0', | |
16502 | when walking through ritem, even via rule->rhs. | |
16503 | * src/reduce.c (dump_grammar, useful_production, reduce_output) | |
16504 | (useful_production, useless_nonterminals): Likewise. | |
16505 | (reduce_grammar_tables): Likewise, plus update nritems. | |
16506 | * src/nullable.c (set_nullable): Likewise. | |
16507 | * src/lalr.c (build_relations): Likewise. | |
16508 | * tests/sets.at (Nullable): Adjust. | |
16509 | Fortunately, now, the $axiom is no longer nullable. | |
16510 | ||
9e7f6bbd AD |
16511 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16512 | ||
16513 | * src/LR0.c (generate_states): Use nritems, not nitems, nor using | |
16514 | the 0-sentinel. | |
16515 | * src/gram.c (ritem_longest_rhs): Likewise. | |
16516 | * src/reduce.c (nonterminals_reduce): Likewise. | |
16517 | * src/print_graph.c (print_graph): Likewise. | |
16518 | * src/output.c (output_rule_data): Likewise. | |
16519 | * src/nullable.c (set_nullable): Likewise. | |
16520 | ||
255ef638 AD |
16521 | 2001-12-29 Akim Demaille <akim@epita.fr> |
16522 | ||
16523 | * src/output.c: Comment changes. | |
16524 | ||
0d8a7363 AD |
16525 | 2001-12-27 Paul Eggert <eggert@twinsun.com> |
16526 | ||
16527 | * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special | |
16528 | cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and | |
16529 | Sparc, as they were causing more porting problems than the | |
16530 | (minor) performance improvement was worth. | |
16531 | ||
16532 | Also, catch up with 1.31's YYSTD. | |
16533 | ||
3db472b9 AD |
16534 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16535 | ||
16536 | * src/output.c (output_gram): Rely on nritems, not the | |
16537 | 0-sentinel. See below. | |
16538 | Use -1 as separator, not 0. | |
16539 | * src/bison.simple (yyparse): Subtract 1 to the rule numbers. | |
16540 | Rely on -1 as separator in yyrhs, instead of 0. | |
16541 | * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue | |
16542 | twice `Now at end of input', therefore there are two lines less to | |
16543 | expect. | |
16544 | ||
b365aa05 AD |
16545 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16546 | ||
16547 | * tests/regression.at (Unresolved SR Conflicts): | |
16548 | (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes | |
16549 | below. | |
16550 | ||
30171f79 AD |
16551 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16552 | ||
16553 | * src/LR0.c (new_state): Recognize the final state by the fact it | |
16554 | is reached by eoftoken. | |
16555 | (insert_start_shifting_state, insert_eof_shifting_state) | |
16556 | (insert_accepting_state, augment_automaton): Remove, since now | |
16557 | these states are automatically computed from the initial state. | |
16558 | (generate_states): Adjust. | |
16559 | * src/print.c: When reporting a rule number to the user, substract | |
16560 | 1, so that the axiom rule is rule 0, and the first user rule is 1. | |
16561 | * src/reduce.c: Likewise. | |
16562 | * src/print_graph.c (print_core): For the time being, just as for | |
16563 | the report, depend upon --trace-flags to dump the full set of | |
16564 | items. | |
16565 | * src/reader.c (readgram): Once the grammar read, insert the rule | |
16566 | 0: `$axiom: START-SYMBOL $'. | |
16567 | * tests/set.at: Adjust: rule 0 is now displayed, and since the | |
16568 | number of the states has changed (the final state is no longer | |
16569 | necessarily the last), catch up. | |
16570 | ||
75142d45 AD |
16571 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16572 | ||
16573 | Try to make the use of the eoftoken valid. Given that its value | |
16574 | is 0 which was also used as a sentinel in ritem, (i) make sure >= 0 | |
16575 | is used instead of > 0 where appropriate, (ii), depend upon nritems | |
16576 | instead of the 0-sentinel. | |
16577 | ||
16578 | * src/gram.h, src/gram.c (nritems): New. | |
16579 | Expected to be duplication of nitems, but for the time being... | |
16580 | * src/reader.c (packgram): Assert nritems and nitems are equal. | |
16581 | * src/LR0.c (allocate_itemsets, new_itemsets): Adjust. | |
16582 | * src/closure.c (print_closure, print_fderives): Likewise. | |
16583 | * src/gram.c (ritem_print): Likewise. | |
16584 | * src/print.c (print_core, print_grammar): Likewise. | |
16585 | * src/print_graph.c: Likewise. | |
16586 | ||
b7c49edf AD |
16587 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16588 | ||
16589 | * src/main.c (main): If there are complains after grammar | |
16590 | reductions, then output the report anyway if requested, then die. | |
16591 | * src/symtab.c (bucket_new): Initialize `value' to -1, not 0. | |
16592 | * src/reader.c (eoftoken): New. | |
16593 | (parse_token_decl): If the token being defined has value `0', it | |
16594 | is the eoftoken. | |
16595 | (packsymbols): No longer hack `tags' to insert `$' by hand. | |
16596 | Be sure to preserve the value of the eoftoken. | |
16597 | (reader): Make sure eoftoken is defined. | |
16598 | Initialize nsyms to 0: now eoftoken is created just like the others. | |
16599 | * src/print.c (print_grammar): Don't special case the eof token. | |
16600 | * src/regression.at: Adjust: `$' has value 0, not -1, which was a | |
16601 | lie anyway, albeit pleasant. | |
16602 | * tests/calc.at: Exercise error messages with eoftoken. | |
16603 | Change the grammar so that empty input is invalid. | |
16604 | Adjust expectations. | |
16605 | When yyungeting, be sure to use a valid yylloc: use last_yylloc. | |
16606 | ||
ec2da99f AD |
16607 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16608 | ||
16609 | * configure.in: Check the protos of strchr ans strspn. | |
16610 | Replace strchr if needed. | |
16611 | * src/system.h: Provide the protos of strchr, strspn and memchr if | |
16612 | missing. | |
16613 | * lib/strchr.c: New. | |
16614 | * src/reader.c (symbols_save): Use strchr. | |
16615 | ||
8adfa272 AD |
16616 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16617 | ||
16618 | * src/print.c, src/print_graph.c (escape): New. | |
16619 | Use it to quote the TAGS outputs. | |
16620 | * src/print_graph.c (print_state): Now errors are in red, and | |
16621 | reductions in green. | |
16622 | Prefer high to wide: output the state number on a line of its own. | |
16623 | ||
80dac38c AD |
16624 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16625 | ||
16626 | * src/state.h, src/state.c (reductions_new): New. | |
16627 | * src/LR0.c (set_state_table): Let all the states have a | |
16628 | `reductions', even if reduced to 0. | |
16629 | (save_reductions): Adjust. | |
16630 | * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust. | |
16631 | * src/print.c (print_reductions, print_actions): Adjust. | |
16632 | * src/output.c (action_row): Adjust. | |
16633 | ||
2cec70b9 AD |
16634 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16635 | ||
16636 | * src/state.h, src/state.c (errs_new, errs_dup): New. | |
16637 | * src/LR0.c (set_state_table): Let all the states have an errs, | |
16638 | even if reduced to 0. | |
16639 | * src/print.c (print_errs, print_reductions): Adjust. | |
16640 | * src/output.c (output_actions, action_row): Adjust. | |
16641 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
16642 | ||
13ca549a AD |
16643 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16644 | ||
16645 | * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL. | |
16646 | ||
5092aba5 AD |
16647 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16648 | ||
16649 | * src/conflicts.c, src/conflicts.h (print_reductions): Move to... | |
16650 | * src/print.c: here. | |
16651 | (lookaheadset, shiftset): New, used as additional storage by | |
16652 | print_reductions. | |
16653 | (print_results): Adjust. | |
16654 | (print_shifts, print_gotos, print_errs): New, extracted from... | |
16655 | (print_actions): here. | |
16656 | * src/print_graph.c (print_actions): Remove dead code. | |
16657 | ||
11e2beca AD |
16658 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16659 | ||
16660 | * src/reader.c (copy_dollar, copy_at): Better checking of `n' in | |
16661 | `$n' and `@n'. | |
16662 | ||
dac3c910 AD |
16663 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16664 | ||
16665 | * src/lalr.c (add_lookback_edge): Use state_t instead of ints. | |
16666 | (build_relations): Adjust. | |
16667 | ||
d0b0fefa AD |
16668 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16669 | ||
16670 | * src/lalr.c (set_goto_map): Remove a wrong but benign loop | |
16671 | duplication. | |
16672 | ||
adc8c848 AD |
16673 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16674 | ||
16675 | * src/reader.c (packgram): Catch nitems overflows. | |
16676 | ||
14d293ac AD |
16677 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16678 | ||
16679 | * src/files.c, src/files.h (guard_obstack): Remove. | |
16680 | * src/output.c (output): Adjust. | |
16681 | * src/reader.c (parse_braces): New, factoring... | |
16682 | (copy_action, copy_guard): these two which are renamed as... | |
16683 | (parse_action, parse_guard): these. | |
16684 | As a voluntary consequence, using braces around guards is now | |
16685 | mandatory. | |
16686 | ||
f499b062 AD |
16687 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16688 | ||
16689 | * src/gram.h (rule_t): `guard' and `guard_line' are new members. | |
16690 | * src/reader.c (symbol_list): `guard' and `guard_line' are new | |
16691 | members. | |
16692 | (symbol_list_new): Adjust. | |
16693 | (copy_action): action_line is the first line, not the last. | |
16694 | (copy_guard): Just as for actions, store the `action' only, not | |
16695 | the switch/case/break flesh. | |
16696 | Don't parse the user action that might follow the guard, let... | |
16697 | (readgram): do it, i.e., now, there can be an action after a | |
16698 | guard. | |
16699 | In other words the guard is just explicitly optional. | |
16700 | (packgram): Adjust. | |
16701 | * src/output.c (guards_output): New. | |
16702 | (output_parser): Call it when needed. | |
16703 | (output): Also free the guard and attrs obstacks. | |
16704 | * src/files.c, src/files.h (obstack_save): Remove. | |
16705 | (output_files): Remove. | |
16706 | As a result, if one needs the former `.act' file, using an | |
16707 | appropriate skeleton which requires actions and guards is now | |
16708 | required. | |
16709 | * src/main.c (main): Adjust. | |
16710 | * tests/semantic.at: New. | |
16711 | * tests/regression.at: Use `input.y' as input file name. | |
16712 | Avoid 8+3 problems by requiring input.c when the test needs the | |
16713 | parser. | |
16714 | ||
d945f5cd AD |
16715 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16716 | ||
16717 | * src/reader.c (symbol_list_new): Be sure to initialize all the | |
16718 | fields. | |
16719 | ||
d200e455 AD |
16720 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16721 | ||
16722 | All the hacks using a final pseudo state are now useless. | |
16723 | ||
16724 | * src/LR0.c (set_state_table): state_table holds exactly nstates. | |
16725 | * src/lalr.c (nLA): New. | |
16726 | (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it | |
16727 | instead of lookaheadsp from the pseudo state (nstate + 1). | |
16728 | ||
f9507c28 AD |
16729 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16730 | ||
16731 | * src/output.c (action_row, token_actions): Use a state_t instead | |
16732 | of a integer, and nlookaheads instead of the following state's | |
16733 | lookaheadsp. | |
16734 | ||
065fbd27 AD |
16735 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16736 | ||
16737 | * src/conflicts.c (log_resolution, flush_shift) | |
16738 | (resolve_sr_conflict, set_conflicts, solve_conflicts) | |
16739 | (count_sr_conflicts, count_rr_conflicts, conflicts_output) | |
16740 | (conflicts_print, print_reductions): Use a state_t instead of an | |
16741 | integer when referring to a state. | |
16742 | As much as possible, depend upon nlookaheads, instead of the | |
16743 | `lookaheadsp' member of the following state (since lookaheads of | |
16744 | successive states are successive, the difference between state n + 1 | |
16745 | and n served as the number of lookaheads for state n). | |
16746 | * src/lalr.c (add_lookback_edge): Likewise. | |
16747 | * src/print.c (print_core, print_actions, print_state) | |
16748 | (print_results): Likewise. | |
16749 | * src/print_graph.c (print_core, print_actions, print_state) | |
16750 | (print_graph): Likewise. | |
16751 | * src/conflicts.h: Adjust. | |
16752 | ||
1b177bd7 AD |
16753 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16754 | ||
16755 | * src/bison.hairy: Formatting/comment changes. | |
16756 | ANSIfy. | |
16757 | Remove `register' indications. | |
16758 | Add plenty of `static'. | |
16759 | ||
7742ddeb AD |
16760 | 2001-12-27 Akim Demaille <akim@epita.fr> |
16761 | ||
16762 | * src/output.c (prepare): Drop the muscle `ntbase' which | |
16763 | duplicates ntokens. | |
16764 | * src/bison.simple: Formatting/comment changes. | |
16765 | Use YYNTOKENS only, which is documented, but not YYNTBASE, which | |
16766 | is an undocumented synonym. | |
16767 | ||
1fa14068 AD |
16768 | 2001-12-22 Akim Demaille <akim@epita.fr> |
16769 | ||
16770 | * src/output.c (output_table_data): Change the prototype to use | |
16771 | `int' for array ranges: some invocations do pass an int, not a | |
16772 | short. | |
16773 | Reported by Wayne Green. | |
16774 | ||
b9752825 AD |
16775 | 2001-12-22 Akim Demaille <akim@epita.fr> |
16776 | ||
16777 | Some actions of web2c.y are improperly triggered. | |
16778 | Reported by Mike Castle. | |
16779 | ||
16780 | * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/. | |
16781 | * tests/regression.at (Web2c): Rename as... | |
16782 | (Web2c Report): this. | |
16783 | (Web2c Actions): New. | |
16784 | ||
776209d6 AD |
16785 | 2001-12-22 Akim Demaille <akim@epita.fr> |
16786 | ||
16787 | Reductions in web2c.y are improperly reported. | |
16788 | Reported by Mike Castle. | |
16789 | ||
16790 | * src/conflicts.c (print_reductions): Fix. | |
16791 | * tests/regression.at (Web2c): New. | |
16792 | ||
275fc3ad AD |
16793 | 2001-12-18 Akim Demaille <akim@epita.fr> |
16794 | ||
16795 | Some host fail on `assert (!"foo")', which expands to | |
16796 | ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__)) | |
16797 | Reported by Nelson Beebee. | |
16798 | ||
16799 | * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with | |
16800 | `#define it_succeeded 0' and `assert (it_succeeded)'. | |
16801 | ||
897668ee MA |
16802 | 2001-12-17 Marc Autret <autret_m@epita.fr> |
16803 | ||
16804 | * src/bison.simple: Don't hard code the skeleton line and filename. | |
16805 | * src/output.c (output_parser): Rename 'line' as 'output_line'. | |
16806 | New line counter 'skeleton_line' (skeleton-line muscle). | |
16807 | ||
ab3399e0 PE |
16808 | 2001-12-17 Paul Eggert <eggert@twinsun.com> |
16809 | ||
16810 | * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that | |
16811 | YYDEBUG must be defined to a nonzero value. | |
16812 | ||
16813 | * src/bison.simple (yytname): Do not assume that the user defines | |
16814 | YYDEBUG to a properly parenthesized expression. | |
16815 | ||
3877f72b AD |
16816 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16817 | ||
16818 | * src/state.h (state_t): Rename lookaheads as lookaheadsp. | |
16819 | nlookaheads is a new member. | |
16820 | Adjust all users. | |
16821 | * src/lalr.h (nlookaheads): Remove this orphan declaration. | |
16822 | * src/lalr.c (initialize_lookaheads): Set nlookaheads for each | |
16823 | state. | |
776209d6 | 16824 | |
331dbc1b AD |
16825 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16826 | ||
16827 | * src/files.h, src/files.c (open_files, close_files): Remove. | |
16828 | * src/main.c (main): Don't open/close files, nor invoke lex_free, | |
16829 | let... | |
16830 | * src/reader.c (reader): Do it. | |
776209d6 | 16831 | |
be750e4c AD |
16832 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16833 | ||
16834 | * src/conflicts.c (print_reductions): Formatting changes. | |
776209d6 | 16835 | |
709ae8c6 AD |
16836 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16837 | ||
16838 | * src/conflicts.c (flush_shift): Also adjust lookaheadset. | |
16839 | (flush_reduce): New. | |
16840 | (resolve_sr_conflict): Adjust. | |
776209d6 | 16841 | |
f87685c3 AD |
16842 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16843 | ||
16844 | * src/output.c (output_obstack): Be static and rename as... | |
16845 | (format_obstack): this, to avoid any confusion with files.c's | |
16846 | output_obstack. | |
16847 | * src/reader.h (muscle_obstack): Move to... | |
16848 | * src/output.h: here, since it's defined in output.c. | |
16849 | ||
837491d8 AD |
16850 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16851 | ||
16852 | * src/output.c (action_row, save_column, default_goto) | |
16853 | (sort_actions, matching_state, pack_vector): Better variable | |
16854 | locality. | |
16855 | ||
796d61fb AD |
16856 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16857 | ||
16858 | * src/output.c: Various formatting changes. | |
776209d6 | 16859 | |
64d15509 AD |
16860 | 2001-12-17 Akim Demaille <akim@epita.fr> |
16861 | ||
16862 | * src/files.c (output_files): Free the output_obstack. | |
16863 | * src/main.c (main): Call print and print_graph conditionally. | |
16864 | * src/print.c (print): Work unconditionally. | |
16865 | * src/print_graph.c (print_graph): Work unconditionally. | |
16866 | * src/conflicts.c (log_resolution): Output only if verbose_flag. | |
16867 | ||
fbc8ecb7 MA |
16868 | 2001-12-16 Marc Autret <autret_m@epita.fr> |
16869 | ||
16870 | * src/output.c (actions_output): Fix. When we use %no-lines, | |
16871 | there is one less line per action. | |
16872 | ||
f0440388 MA |
16873 | 2001-12-16 Marc Autret <autret_m@epita.fr> |
16874 | ||
16875 | * src/bison.simple: Remove a useless #line directive. | |
16876 | s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'. | |
16877 | * src/output.c (get_lines_number): New. | |
776209d6 | 16878 | (output_parser): Adjust, now takes care about the lines of a |
f0440388 MA |
16879 | output muscles. |
16880 | Fix line numbering. | |
16881 | (actions_output): Computes the number of lines taken by actions. | |
16882 | (output_master_parser): Insert new skeleton which is the name of | |
16883 | the output parser file name. | |
16884 | ||
a79986b8 MA |
16885 | 2001-12-15 Marc Autret <autret_m@epita.fr> |
16886 | ||
16887 | * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility. | |
16888 | ||
4ec8e00f MA |
16889 | 2001-12-15 Marc Autret <autret_m@epita.fr> |
16890 | ||
16891 | * src/output.c (output_gram): Keep track of the hairy one. | |
16892 | ||
1a4648ff AD |
16893 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16894 | ||
16895 | Make `make distcheck' work. | |
16896 | ||
16897 | * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses | |
16898 | system.h which uses libgettext.h. | |
16899 | ||
9c2c67e6 AD |
16900 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16901 | ||
16902 | * src/nullable.c (set_nullable): Useless rules must be skipped, | |
16903 | otherwise, since we range over their symbols, we might look at a | |
16904 | nonterminal which no longer ``exists'', i.e., it is not counted in | |
16905 | `nvars', hence we overflow our arrays. | |
16906 | ||
93ede233 AD |
16907 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16908 | ||
16909 | The header can also be produced directly, without any obstack! | |
16910 | Yahoo! | |
16911 | ||
16912 | * src/files.c, src/files.h (defines_obstack): Remove. | |
16913 | (compute_header_macro): Global. | |
16914 | (defines_obstack_save): Remove. | |
16915 | * src/reader.c (parse_union_decl): No longer output to | |
16916 | defines_obstack: its content can be found in the `stype' muscle | |
16917 | anyway. | |
16918 | (output_token_translations): Merge into... | |
16919 | (symbols_output): this. | |
16920 | Rename as... | |
16921 | (symbols_save): this. | |
16922 | (reader): Adjust. | |
16923 | * src/output.c (header_output): New. | |
16924 | (output): Call it. | |
16925 | ||
2666f928 AD |
16926 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16927 | ||
16928 | * src/reader.c (parse_union_decl): Instead of handling two obstack | |
16929 | simultaneously, use one to define the `stype' muscle, and use the | |
16930 | value of the latter to fill defines_obstack. | |
16931 | (copy_comment): Remove. | |
16932 | (copy_comment2): Work for a single obstack. | |
16933 | Rename as... | |
16934 | (copy_comment): this. | |
16935 | ||
428046f8 AD |
16936 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16937 | ||
16938 | * src/lex.c, src/lex.h (xgetc): No longer static. | |
16939 | * src/reader.c (parse_union_decl): Revamp. | |
16940 | ||
ea52d706 AD |
16941 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16942 | ||
16943 | Still making progress in separating Bison into (i) input, (ii) | |
16944 | process, (iii) output: now we can directly output the parser file | |
16945 | without using table_obstack at all. | |
16946 | ||
16947 | * src/files.c, src/files.h (table_obstack): Bye bye. | |
16948 | (parser_file_name): New. | |
16949 | * src/files.c (compute_output_file_names): Compute it. | |
16950 | * src/output.c (actions_output, output_parser) | |
16951 | (output_master_parser): To a file instead of an obstack. | |
16952 | ||
3f96f4dc AD |
16953 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16954 | ||
16955 | Attach actions to rules, instead of pre-outputting them to | |
16956 | actions_obstack. | |
16957 | ||
16958 | * src/gram.h (rule_t): action and action_line are new members. | |
16959 | * src/reader.c (symbol_list): Likewise. | |
16960 | (copy_action): Save the actions within the rule. | |
16961 | (packgram): Save them in rule_table. | |
16962 | * src/output.c (actions_output): New. | |
16963 | (output_parser): Use it on `%%actions'. | |
16964 | (output_rule_data): Don't free rule_table. | |
16965 | (output): Do it. | |
16966 | (prepare): Don't save the `action' muscle. | |
16967 | * src/bison.simple: s/%%action/%%actions/. | |
16968 | ||
51576fb3 AD |
16969 | 2001-12-15 Akim Demaille <akim@epita.fr> |
16970 | ||
16971 | * src/reader.c (copy_action): When --yacc, don't append a `;' | |
16972 | to the user action: let it fail if lacking. | |
dee049eb | 16973 | Suggested by Arnold Robbins and Tom Tromey. |
51576fb3 | 16974 | |
2648a72d AD |
16975 | 2001-12-14 Akim Demaille <akim@epita.fr> |
16976 | ||
16977 | * src/lex.c (literalchar): Simply return the char you decoded, non | |
16978 | longer mess around with obstacks and int pointers. | |
16979 | Adjust all callers. | |
16980 | ||
92790e5b AD |
16981 | 2001-12-14 Akim Demaille <akim@epita.fr> |
16982 | ||
16983 | * src/lex.c (literalchar): Don't escape the special characters, | |
16984 | just decode them, and keep them as char (before, eol was output as | |
16985 | the 2 char string `\n' etc.). | |
16986 | * src/output.c (output_rule_data): Use quotearg to output the | |
16987 | token strings. | |
16988 | ||
927c1557 PE |
16989 | 2001-12-13 Paul Eggert <eggert@twinsun.com> |
16990 | ||
16991 | * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE): | |
16992 | Do not infringe on the global user namespace when using C++. | |
16993 | (YYFPRINTF, YYSTDERR): New macros, needed for the above. | |
16994 | All uses of `fprintf' and `stderr' changed. | |
16995 | ||
16996 | * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR. | |
16997 | ||
ed8e1f68 AD |
16998 | 2001-12-13 Akim Demaille <akim@epita.fr> |
16999 | ||
17000 | The computation of nullable is broken: it doesn't handle empty | |
17001 | RHS's properly. | |
17002 | ||
17003 | * tests/torture.at (GNU AWK Grammar): New. | |
17004 | * tests/sets.at (Nullable): New. | |
17005 | * src/nullable.c (set_nullable): Instead of blindly looping over | |
17006 | `ritems', loop over the rules, and then over their rhs's. | |
17007 | ||
17008 | Work around Autotest bugs. | |
17009 | ||
17010 | * src/warshall.c (bitmatrix_print): Don't use `+--+' as table | |
17011 | frame, because Autotest understand lines starting with a `+' as | |
17012 | traces from the shell. Then, they are not processed properly. | |
17013 | Admittedly an Autotest bug, but we don't have time to wait for | |
17014 | Autotest to catch up. | |
17015 | * tests/regression.at (Broken Closure): Adjust to the new table | |
17016 | frames. | |
17017 | Move to... | |
17018 | * tests/sets.at: here. | |
17019 | ||
cb581495 AD |
17020 | 2001-12-13 Akim Demaille <akim@epita.fr> |
17021 | ||
17022 | * src/closure.c (closure): Use nrules instead of playing tricks | |
17023 | with BITS_PER_WORD. | |
17024 | ||
2e729273 AD |
17025 | 2001-12-13 Akim Demaille <akim@epita.fr> |
17026 | ||
17027 | * src/print.c (print_actions): Output the handling of `$' as the | |
17028 | traces do: shifting the token EOF. Before EOF was treated as a | |
17029 | nonterminal. | |
17030 | * tests/regression.at: Adjust some tests. | |
17031 | * src/print_graph.c (print_core): Complete the set of items via | |
17032 | closure. The next-to-final and final states are still unsatisfying, | |
17033 | but that's to be addressed elsewhere. | |
17034 | No longer output the rule numbers, but do output the state number. | |
17035 | A single loop for the shifts + gotos is enough, but picked a | |
17036 | distinct color for each. | |
17037 | (print_graph): Initialize and finalize closure. | |
17038 | ||
107f7dfb AD |
17039 | 2001-12-13 Akim Demaille <akim@epita.fr> |
17040 | ||
17041 | * src/reader.c (readgram): Remove dead code, an strip useless | |
17042 | braces. | |
17043 | (get_type): Remove, unused. | |
17044 | ||
9b53a24f AD |
17045 | 2001-12-12 Akim Demaille <akim@epita.fr> |
17046 | ||
17047 | * src/complain.h, src/complain.c: Remove error_one_per_line, rely | |
17048 | on that of lib/error.c. | |
17049 | ||
dbfb6dcd AD |
17050 | 2001-12-12 Akim Demaille <akim@epita.fr> |
17051 | ||
17052 | Some hosts don't like `/' in includes. | |
17053 | ||
17054 | * src/system.h: Include libgettext.h without qualifying the path. | |
17055 | * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove | |
17056 | $(top_srcdir). | |
17057 | ||
c25fb648 MA |
17058 | 2001-12-11 Marc Autret <autret_m@epita.fr> |
17059 | ||
17060 | * src/output.c (output_parser): Remove useless muscle. | |
17061 | ||
710ddc4f MA |
17062 | 2001-12-11 Marc Autret <autret_m@epita.fr> |
17063 | ||
17064 | * src/bison.simple: Remove #line just before %%epilogue. It | |
17065 | is now handled in ... | |
17066 | * src/reader.c (read_additionnal_code): Add the output of a | |
17067 | #line for the epilogue. | |
17068 | ||
e83d80b8 MA |
17069 | 2001-12-10 Marc Autret <autret_m@epita.fr> |
17070 | ||
927c1557 | 17071 | * src/reader.c (copy_definition): Re-use CPP-outed code which |
e83d80b8 MA |
17072 | replace precedent remove. |
17073 | * src/bison.simple: Remove #line before %%prologue because | |
17074 | %%input-line is wrong at this time. | |
17075 | ||
971d5158 MA |
17076 | 2001-12-10 Marc Autret <autret_m@epita.fr> |
17077 | ||
17078 | * src/reader.c (symbols_output): Clean up. | |
927c1557 | 17079 | * src/output.c (output_gram, output): Clean up. |
971d5158 | 17080 | |
5edafffd AD |
17081 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17082 | ||
17083 | * src/lalr.c (initialize_lookaheads): New. Extracted from... | |
17084 | * src/LR0.c (set_state_table): here. | |
17085 | * src/lalr.c (lalr): Call it. | |
17086 | ||
0279f8e9 AD |
17087 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17088 | ||
17089 | * src/state.h (shifts): Remove the `number' member: shifts are | |
17090 | attached to state, hence no longer need to be labelled with a | |
17091 | state number. | |
17092 | ||
190c4f5f AD |
17093 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17094 | ||
17095 | Now that states have a complete set of members, the linked list of | |
17096 | shifts is useless: just fill directly the state's shifts member. | |
17097 | ||
17098 | * src/state.h (shifts): Remove the `next' member. | |
17099 | * src/LR0.c (first_state, last_state): Remove. | |
17100 | Adjust the callers. | |
17101 | (augment_automaton): Don't look for the shifts that must be added | |
17102 | a shift on EOF: it is those of the state we looked for! But now, | |
17103 | since shifts are attached, it is no longer needed to looking | |
17104 | merely by its id: its number. | |
17105 | ||
2a73b93d AD |
17106 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17107 | ||
17108 | * src/LR0.c (augment_automaton): Better variable locality. | |
17109 | Remove an impossible branch: if there is a state corresponding to | |
17110 | the start symbol being shifted, then there is shift for the start | |
17111 | symbol from the initial state. | |
17112 | ||
74392f6a AD |
17113 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17114 | ||
17115 | * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state' | |
17116 | only when appropriate: when insert_start_shifting_state' is not | |
17117 | invoked. | |
17118 | * tests/regression.at (Rule Line Numbers): Adjust. | |
17119 | ||
37c82725 AD |
17120 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17121 | ||
17122 | * src/LR0.c (augment_automaton): Now that all states have shifts, | |
17123 | merge the two cases addition shifts to the initial state. | |
17124 | ||
6a164e0c AD |
17125 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17126 | ||
17127 | * src/lalr.c (set_state_table): Move to... | |
17128 | * src/LR0.c: here. | |
17129 | * src/lalr.c (lalr): Don't call it... | |
17130 | * src/LR0.c (generate_states): do it. | |
17131 | * src/LR0.h (first_state): Remove, only the table is used. | |
17132 | ||
7215de24 AD |
17133 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17134 | ||
17135 | * src/LR0.h (first_shift, first_reduction): Remove. | |
17136 | * src/lalr.c: Don't use first_shift: find shifts through the | |
17137 | states. | |
17138 | ||
80e25d4d AD |
17139 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17140 | ||
17141 | * src/LR0.c: Attach shifts to states as soon as they are | |
17142 | computed. | |
17143 | * src/lalr.c (set_state_table): Instead of assigning shifts to | |
17144 | state, just assert that the mapping was properly done. | |
17145 | ||
0ab3728b AD |
17146 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17147 | ||
17148 | * src/LR0.c (insert_start_shift): Rename as... | |
17149 | (insert_start_shifting_state): this. | |
17150 | (insert_eof_shifting_state, insert_accepting_state): New. | |
17151 | (augment_automaton): Adjust. | |
17152 | Better locality of the variables. | |
17153 | When looking if the start_symbol is shifted from the initial | |
17154 | state, using `while (... symbol != start_symbol ...)' sounds | |
17155 | better than `while (... symbol < start_symbol ...)': If fail | |
17156 | to see how the order between symbols could be relevant! | |
17157 | ||
78af9bbc AD |
17158 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17159 | ||
17160 | * src/getargs.h: Don't declare `spec_name_prefix' and | |
17161 | `spec_file_prefix', declared by src/files.h. | |
17162 | * src/files.c, src/files.h: Default for spec_name_prefix is "yy". | |
17163 | * src/muscle_tab.c (muscle_init): Default prefix to NULL. | |
17164 | * src/output.c (prepare): Adjust. | |
17165 | * src/reader.c (symbols_output): Likewise. | |
17166 | * src/vmsgetargs.c: Vaguely adjust, but who cares? | |
17167 | ||
bdef2a41 AD |
17168 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17169 | ||
17170 | * src/muscle_tab.c (muscle_init): NULL is a better default than | |
17171 | `"0"'. | |
17172 | ||
3735969c AD |
17173 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17174 | ||
17175 | * src/reader.c (reader): Calling symbols_output once is enough. | |
17176 | ||
49701457 AD |
17177 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17178 | ||
17179 | Now that states have a complete set of members, the linked list of | |
17180 | reductions is useless: just fill directly the state's reductions | |
17181 | member. | |
17182 | ||
17183 | * src/state.h (struct reductions): Remove member `number' and | |
17184 | `next'. | |
17185 | * src/LR0.c (first_reduction, last_reduction): Remove. | |
17186 | (save_reductions): Don't link the new reductions, store them in | |
17187 | this_state. | |
17188 | * src/lalr.c (set_state_table): No need to attach reductions to | |
17189 | states, it's already done. | |
17190 | * src/output.c (output_actions): No longer free the shifts, then | |
17191 | the reductions, then the states: free all the states and their | |
17192 | members. | |
17193 | ||
0edad749 AD |
17194 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17195 | ||
17196 | * src/options.c (OPTN, DRTV, BOTH): New. | |
17197 | (option_table): Use them. | |
17198 | ||
0edad749 AD |
17199 | * src/muscle_tab.c: Don't include xalloc.h and string.h: that's |
17200 | the job of system.h. | |
17201 | * src/options.c: Don't include stdio.h and xalloc.h for the same | |
17202 | reasons. | |
17203 | ||
5449dd0f AD |
17204 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17205 | ||
17206 | * src/output.c (output, prepare): Make sure the values of the | |
17207 | muscles `action' and `prologue' are 0-terminated. | |
17208 | ||
a870c567 AD |
17209 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17210 | ||
17211 | Clean up GCC warnings. | |
17212 | ||
17213 | * src/reader.c (copy_action): `buf' is not used. | |
17214 | (parse_skel_decl): Be static. | |
17215 | * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'. | |
17216 | * src/options.h (create_long_option_table): Have a real prototype. | |
17217 | * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete) | |
17218 | (hash_delete_at): Return const void *. | |
17219 | Adjust casts to preserve the const. | |
17220 | ||
80df8768 AD |
17221 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17222 | ||
17223 | * configure.in: Require 2.52g. | |
17224 | M4 is not needed, but AUTOM4TE is. | |
17225 | * m4/m4.m4: Remove. | |
17226 | * tests/Makefile.am: Adjust. | |
17227 | ||
f693ad14 AD |
17228 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17229 | ||
17230 | One structure for states is enough, even though theoretically | |
17231 | there are LR(0) states and LALR(1) states. | |
17232 | ||
17233 | * src/lalr.h (state_t): Remove. | |
17234 | (state_table): Be state_t **, not state_t *. | |
17235 | * src/state.h (core, CORE_ALLOC): Rename as... | |
17236 | (state_t, STATE_ALLOC): this. | |
17237 | Add the LALR(1) members: shifts, reductions, errs. | |
17238 | * src/LR0.c (state_table): Rename as... | |
17239 | (state_hash): this, to avoid name clashes with the global | |
17240 | `state_table'. | |
17241 | * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c | |
17242 | * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust. | |
17243 | ||
74ffbcb6 AD |
17244 | 2001-12-10 Akim Demaille <akim@epita.fr> |
17245 | ||
17246 | Bison dumps core on bash.y. | |
17247 | Reported by Pascal Bart. | |
17248 | ||
17249 | * src/warshall.c (bitmatrix_print): New. | |
17250 | (TC): Use it. | |
ba0fe3c7 | 17251 | When performing a transitive closure R(i, j) && R(j, k) => R(i, k), |
74ffbcb6 AD |
17252 | j must be the outer loop. |
17253 | * tests/regression.at (Broken Closure): New. | |
17254 | ||
07708e19 AD |
17255 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17256 | ||
17257 | * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and | |
17258 | its argument. | |
ba1ecc07 | 17259 | Reported by Peter Hamorsky. |
07708e19 | 17260 | |
92b16366 AD |
17261 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17262 | ||
17263 | * src/conflicts.c (err_table): Remove. | |
17264 | (resolve_sr_conflict): Adjust. | |
17265 | * src/lalr.h (state_t.reduction_table, state_t.shift_table): | |
17266 | Rename as... | |
17267 | (state_t.reductions, state_t.shifts): this. | |
17268 | ||
076ab033 AD |
17269 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17270 | ||
17271 | * src/reduce.c (reduce_grammar_tables): No longer disable the | |
17272 | removal of useless rules via CPP but via `if (0)', so that the | |
17273 | compiler still check the code is valid. | |
17274 | For instance, it should have noticed `rline' no longer exists: use | |
17275 | the `line' member of rule_t. | |
17276 | * src/gram.c (dummy, rline): Remove, unused. | |
17277 | ||
3843c413 AD |
17278 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17279 | ||
17280 | * src/output.c (pack_vector): Use assert, not berror. | |
17281 | * src/main.c (berror): Remove, unused. | |
17282 | ||
43168960 AD |
17283 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17284 | ||
17285 | New experimental feature: if --verbose --trace output all the | |
17286 | items of a state, not only its kernel. | |
17287 | ||
17288 | * src/print.c (print_core): If `trace_flag', then invoke closure | |
17289 | before outputting the items of the state (print_core is no longer | |
17290 | a correct name them). | |
17291 | (print_results): Invoke new_closure/free_closure if needed. | |
17292 | ||
b2872512 AD |
17293 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17294 | ||
17295 | * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount. | |
17296 | * src/closure.c, src/closure.h (itemsetsize): Rename as... | |
17297 | (nitemset): for consistency with the rest of the project. | |
17298 | ||
23cbcc6c AD |
17299 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17300 | ||
17301 | * src/closure.c (print_closure): Improve. | |
17302 | (closure): Use it for printing input and output. | |
17303 | ||
03ec521c AD |
17304 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17305 | ||
17306 | * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are | |
17307 | indexed by nonterminals. | |
17308 | ||
3a7456dd AD |
17309 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17310 | ||
17311 | * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of | |
17312 | what it was!). | |
17313 | * src/warshall.h: Remove accidental duplication of the content. | |
17314 | ||
1cbcf2e7 AD |
17315 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17316 | ||
17317 | * src/closure.c (set_fderives): De-obfuscate. | |
17318 | ||
84182270 AD |
17319 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17320 | ||
17321 | * src/closure.c (print_firsts, print_fderives): De-obfuscate. | |
17322 | ||
3f6f053c AD |
17323 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17324 | ||
17325 | * src/closure.c (set_firsts): De-obfuscate. | |
17326 | ||
7a5350ba AD |
17327 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17328 | ||
17329 | * src/output.c (action_row): De-obfuscate | |
17330 | using the good o' techniques: arrays not pointers, variable | |
17331 | locality, BITISSET, RESETBIT etc. | |
17332 | ||
d954473d AD |
17333 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17334 | ||
17335 | Pessimize the code to simplify it: from now on, all the states | |
17336 | have a valid SHIFTS, which NSHIFTS is possibly 0. | |
17337 | ||
17338 | * src/LR0.c (shifts_new): Be global and move to.. | |
17339 | * src/state.c, src/state.h: here. | |
17340 | * src/conflicts, src/lalr.c, src/output.c, src/print.c, | |
17341 | * src/print_graph: Adjust. | |
17342 | ||
9839bbe5 AD |
17343 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17344 | ||
17345 | * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New. | |
17346 | * src/conflicts.c: Use it. | |
17347 | Restore a few missing `if (!SHIFT_IS_DISABLED)' which were | |
17348 | incorrectly ``simplified''. | |
17349 | ||
9f136c07 AD |
17350 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17351 | ||
17352 | * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate | |
17353 | using the good o' techniques: arrays not pointers, variable | |
17354 | locality, BITISSET, RESETBIT etc. | |
17355 | ||
b608206e AD |
17356 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17357 | ||
17358 | * src/state.h (SHIFT_SYMBOL): New. | |
17359 | * src/conflicts.c: Use it to deobfuscate. | |
17360 | ||
52afa962 AD |
17361 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17362 | ||
17363 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts) | |
17364 | (print_reductions): De-obfuscate using the good o' techniques: | |
17365 | arrays not pointers, variable locality, BITISSET. | |
17366 | ||
e74dc321 AD |
17367 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17368 | ||
17369 | * src/conflicts.c (print_reductions): Arrays, not pointers. | |
17370 | Use BITISSET. | |
17371 | ||
768fca83 AD |
17372 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17373 | ||
17374 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
17375 | ||
a17e599f AD |
17376 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17377 | ||
17378 | * src/conflicts.c (print_reductions): Improve variable locality. | |
17379 | ||
a04bc341 AD |
17380 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17381 | ||
17382 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
17383 | ||
c8ea038e AD |
17384 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17385 | ||
17386 | * src/conflicts.c (print_reductions): Improve variable locality. | |
17387 | ||
aa2aab3c AD |
17388 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17389 | ||
17390 | * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New. | |
17391 | * src/lalr.c: Use them. | |
17392 | ||
b178c8cc AD |
17393 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17394 | ||
17395 | * src/LR0.c (augment_automaton): Formatting changes. | |
17396 | Better variable locality. | |
17397 | ||
f67d13aa AD |
17398 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17399 | ||
17400 | * src/lalr.c (matrix_print): New. | |
17401 | (transpose): Use it. | |
17402 | Use arrays instead of pointers. | |
17403 | ||
c2713865 AD |
17404 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17405 | ||
17406 | * src/lalr.c (maxrhs): Move to... | |
17407 | * src/gram.c, src/gram.h (ritem_longest_rhs): here. | |
17408 | * src/lalr.c (build_relations): Adjust. | |
17409 | ||
9887c18a AD |
17410 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17411 | ||
17412 | * src/lalr.c (transpose): Free the memory allocated to the | |
17413 | argument, as it is replaced by the results by the unique caller. | |
17414 | (build_relations): Merely invoke transpose: it handles the memory | |
17415 | deallocation. | |
17416 | Improve variable locality. | |
17417 | Avoid variables used as mere abbreviations. | |
17418 | (compute_lookaheads): Use arrays instead of pointers. | |
17419 | ||
4d4f699c AD |
17420 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17421 | ||
17422 | * src/lalr.c (initialize_F): Improve variable locality. | |
17423 | Avoid variables used as mere abbreviations. | |
17424 | ||
80a69750 AD |
17425 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17426 | ||
17427 | * src/derives.c (print_derives): Display the ruleno. | |
17428 | * src/lalr.c (initialize_F, transpose): Better variable locality | |
17429 | to improve readability. | |
17430 | Avoid variables used as mere abbreviations. | |
17431 | ||
fe961097 AD |
17432 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17433 | ||
17434 | * src/lalr.c (traverse): Use arrays instead of pointers. | |
17435 | ||
e3e4e814 AD |
17436 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17437 | ||
17438 | * src/nullable.c (set_nullable): Use a for loop to de-obfuscate | |
17439 | the handling of squeue. | |
17440 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
17441 | ||
630e182b AD |
17442 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17443 | ||
17444 | Because useless nonterminals are now kept alive (instead of being | |
17445 | `destroyed'), we now sometimes examine them, and store information | |
17446 | related to them. Hence we need to know their number, and adjust | |
17447 | memory allocations. | |
17448 | ||
17449 | * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer | |
17450 | static. | |
17451 | * src/LR0.c (allocate_itemsets): The memory allocated to | |
17452 | `symbol_count' was used for two different purpose: once to count | |
17453 | the number of occurrences of each symbol, and later reassigned to | |
17454 | `shift_symbol', containing the symbol that can be shifted from a | |
17455 | given state. | |
17456 | Deobfuscate, i.e., allocate, use and free `symbol_count' here | |
17457 | only, and... | |
17458 | (new_itemsets): Allocate `shift_symbol' here. | |
17459 | (allocate_itemsets): symbol_count includes useless nonterminals. | |
17460 | Make room for them. | |
17461 | (free_storage): Use `free', not `XFREE', for pointers that cannot | |
17462 | be null. | |
17463 | ||
81b51460 AD |
17464 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17465 | ||
17466 | * src/nullable.c (set_nullable): Deobfuscate the handling of | |
17467 | ritem. | |
17468 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
17469 | ||
3067fbef AD |
17470 | 2001-12-05 Akim Demaille <akim@epita.fr> |
17471 | ||
17472 | * src/gram.c, src/gram.h (ritem_print): New. | |
17473 | * src/gram.c (dummy): Remove, now there is actual code in gram.c. | |
17474 | (This useless function was defined only to work around VMS linkers | |
17475 | that can't handle compilation units with variables only). | |
17476 | * src/reduce.c (dump_grammar): Use it to trace the construction of | |
17477 | ritem. | |
17478 | ||
c2bea5f9 PE |
17479 | 2001-12-04 Paul Eggert <eggert@twinsun.com> |
17480 | ||
7d27c823 PE |
17481 | * src/bison.simple (union yyalloc): Change member names |
17482 | to be the same as the stack names. | |
17483 | (yyparse): yyptr is now union yyalloc *, not char *. | |
17484 | (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning, | |
17485 | and may generate better code on some machines. | |
c2bea5f9 PE |
17486 | (yystpcpy): Use prototype if __STDC__ is defined, not just |
17487 | if __cplusplus is defined. | |
35687a9d | 17488 | |
2c8a9dfa AD |
17489 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17490 | ||
17491 | * configure.in (WARNING_CFLAGS): Add -Werror when possible. | |
17492 | (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU | |
17493 | Gettext doesn't compile cleanly, and dies with -Werror. | |
17494 | * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS): | |
17495 | Include WARNING_CFLAGS here. | |
17496 | * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared | |
17497 | before being defined. | |
17498 | ||
f4e421e6 AD |
17499 | 2001-11-27 Paul Eggert <eggert@twinsun.com> |
17500 | ||
17501 | * lib/quotearg.h (quotearg_n, quotearg_n_style): | |
17502 | First arg is int, not unsigned. | |
17503 | * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise. | |
17504 | (SIZE_MAX, UINT_MAX): New macros. | |
17505 | (quotearg_n_options): Abort if N is negative. | |
17506 | Avoid overflow check on hosts where size_t is 64 bits and int | |
17507 | is 32 bits, as overflow is impossible there. | |
17508 | Fix off-by-one typo that caused unnecessary reallocation. | |
17509 | ||
7093d0f5 AD |
17510 | 2001-11-29 Paul Eggert <eggert@twinsun.com> |
17511 | ||
17512 | Name space cleanup in generated parser. | |
17513 | ||
17514 | * doc/bison.texinfo (Bison Parser): Discuss system headers | |
17515 | and their effect on the user name space. | |
17516 | ||
17517 | * src/bison.simple: | |
17518 | (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX, | |
17519 | YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary, | |
17520 | i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE). | |
17521 | ||
17522 | (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing | |
17523 | on user names when possible. | |
17524 | ||
17525 | (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn. | |
17526 | Simplify test for whather <alloca.h> exists. | |
17527 | ||
17528 | (<stdlib.h>): Include if we will use malloc, and if standard C or C++. | |
17529 | ||
17530 | (<stdio.h>): Include if YYDEBUG. | |
17531 | ||
17532 | (yymemcpy): Renamed from __yy_memcpy. Do not define unless | |
17533 | ! defined (yyoverflow) && ! defined (yymemcpy). | |
17534 | ||
17535 | (yymemcpy, yyparse): Rename local variables as needed so that | |
17536 | they all begin with 'yy'. | |
17537 | ||
17538 | (yystrlen, yystpcpy): New functions. | |
17539 | ||
17540 | (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES. | |
17541 | All uses changed. | |
17542 | ||
17543 | (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy | |
17544 | instead of relying on string.h functions. Use YYSTACK_ALLOC | |
17545 | and YYSTACK_FREE instead of malloc and free. | |
17546 | ||
fd51e5ff AD |
17547 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17548 | ||
17549 | * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions | |
17550 | before their first uses. | |
17551 | (YYBISON, YYPURE): Move to the top of the output. | |
17552 | ||
7d13ff5f AD |
17553 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17554 | ||
17555 | * tests/reduce.at (Useless Nonterminals): Fix. | |
17556 | ||
892a3995 AD |
17557 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17558 | ||
17559 | * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty | |
17560 | if body instead of `;' to pacify GCC's warnings. | |
17561 | ||
68f1e3ed AD |
17562 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17563 | ||
17564 | Instead of mapping the LHS of unused rules to -1, keep the LHS | |
17565 | valid, but flag the rules as invalid. | |
17566 | ||
17567 | * src/gram.h (rule_t): `useful' is a new member. | |
17568 | * src/print.c (print_grammar): Adjust. | |
17569 | * src/derives.c (set_derives): Likewise. | |
17570 | * src/reader.c (packgram, reduce_output): Likewise. | |
17571 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
17572 | * tests/reduce.at (Underivable Rules, Useless Rules): New. | |
17573 | ||
d2d1b42b AD |
17574 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17575 | ||
17576 | * src/reduce.c (reduce_output): Formatting changes. | |
17577 | * src/print.c (print_results, print_grammar): Likewise. | |
17578 | * tests/regression.at (Rule Line Numbers) | |
17579 | (Solved SR Conflicts, Unresolved SR Conflicts): Adjust. | |
17580 | ||
760b53a8 AD |
17581 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17582 | ||
17583 | * src/reduce.c (nonterminals_reduce): Instead of throwing away | |
17584 | useless nonterminals, move them at the end of the symbol arrays. | |
17585 | (reduce_output): Adjust. | |
17586 | * tests/reduce.at (Useless Nonterminals): Adjust. | |
17587 | ||
00238958 AD |
17588 | 2001-11-30 Akim Demaille <akim@epita.fr> |
17589 | ||
17590 | * src/reduce.c: Various comment/formatting changes. | |
17591 | (nonterminals_reduce): New, extracted from... | |
17592 | (reduce_grammar_tables): here. | |
17593 | (reduce_grammar): Call nonterminals_reduce. | |
17594 | ||
396452de PE |
17595 | 2001-11-29 Paul Eggert <eggert@twinsun.com> |
17596 | ||
17597 | * src/bison.simple (YYSTACK_REALLOC): Remove. | |
17598 | (YYSTACK_ALLOC): Resurrect this macro, with its old meaning. | |
17599 | (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE): | |
17600 | New macros. | |
17601 | (union yyalloc): New type. | |
17602 | (__yy_memcpy): Last arg is size_t, not unsigned int, to remove | |
17603 | an arbitrary restriction on hosts where size_t is wider than int. | |
17604 | ||
17605 | (yyparse): Don't dump core if alloca or malloc fails; instead, report | |
17606 | a parser stack overflow. Allocate just one block of memory for all | |
17607 | three stacks, instead of allocating three blocks; this typically is | |
17608 | faster and reduces fragmentation. | |
17609 | ||
17610 | Do not limit the number of items in the stack to a value that fits | |
17611 | in 'int', as this is an arbitrary limit on hosts with 64-bit | |
17612 | size_t and 32-bit int. | |
17613 | ||
147e184c MA |
17614 | 2001-11-29 Marc Autret <autret_m@epita.fr> |
17615 | ||
17616 | * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead | |
17617 | of defining YYERROR_VERBOSE. | |
17618 | [AT_DATA]: $4 is now out of C declarations in the prologue. | |
17619 | ||
426cf563 MA |
17620 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
17621 | ||
17622 | * src/reader.c (parse_dquoted_param): New. | |
17623 | (parse_skel_decl): Use it. | |
17624 | * src/lex.h: Add its prototype. | |
17625 | * src/lex.c (literalchar): Become not static. | |
17626 | ||
c7925b99 MA |
17627 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
17628 | ||
17629 | * src/output.h: And put its extern declaration here. | |
17630 | * src/output.c (error_verbose): Define here. | |
17631 | (prepare): Echo name modification. | |
17632 | * src/getargs.h: Clean its extern declaration. | |
17633 | * src/getargs.c (error_verbose_flag): Remove. | |
17634 | (getargs): Remove case 'e'. | |
17635 | * src/options.c (option_table): 'error-verbose' is now seen as simple | |
17636 | percent option. | |
17637 | Include output.h. | |
17638 | ||
17639 | * src/reader.c (read_declarations): Remove case tok_include. | |
17640 | (parse_include_decl): Remove. | |
17641 | * src/lex.h (token_t): Remove tok_include. | |
17642 | * src/options.c (option_table): 'include' is now a simple command line | |
17643 | option. | |
17644 | ||
5b5d1929 MA |
17645 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
17646 | ||
17647 | * src/bison.simple: Adjust muscle names. | |
17648 | * src/muscle_tab.c (muscle_init): Also rename the muscles. | |
17649 | * src/output.c (prepare): s/_/-/ for the muscles names. | |
17650 | (output_parser): When scanning for a muscle, allow '-' instead of '_'. | |
17651 | ||
8850be4b MA |
17652 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
17653 | ||
17654 | * src/bison.simple: Fix debug. | |
17655 | [YYERROR_VERBOSE]: Re-integrate as an internal macro. | |
17656 | ||
4a38e613 AD |
17657 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17658 | ||
17659 | * src/LR0.c (shifts_new): New. | |
17660 | (save_shifts, insert_start_shift, augment_automaton): Use it. | |
17661 | ||
4b35e1c1 AD |
17662 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17663 | ||
17664 | * src/closure.c (closure): `b' and `ruleno' denote the same value: | |
17665 | keep ruleno only. | |
17666 | ||
d2b04478 AD |
17667 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17668 | ||
17669 | * src/closure.c (closure): Instead of looping over word in array | |
17670 | then bits in words, loop over bits in array. | |
17671 | ||
2c4c30aa AD |
17672 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17673 | ||
17674 | * src/closure.c (closure): No longer optimize the special case | |
17675 | where all the bits of `ruleset[r]' are set to 0, to make the code | |
17676 | clearer. | |
17677 | ||
576890b7 AD |
17678 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17679 | ||
17680 | * src/closure.c (closure): `r' and `c' are new variables, used to | |
17681 | de-obfuscate accesses to RULESET and CORE. | |
17682 | ||
cb487d7d AD |
17683 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17684 | ||
17685 | * src/reduce.c (reduce_print): Use ngettext. | |
17686 | (dump_grammar): Improve the trace accuracy. | |
17687 | ||
6013d43f AD |
17688 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17689 | ||
17690 | * src/reduce.c (dump_grammar): Don't translate trace messages. | |
17691 | ||
cb4956ee AD |
17692 | 2001-11-28 Akim Demaille <akim@epita.fr> |
17693 | ||
17694 | * tests/reduce.at (Useless Terminals, Useless Nonterminals): New. | |
17695 | * src/reduce.c (reduce_grammar_tables): Do not free useless tags, | |
17696 | as all tags are free'ed afterwards. | |
17697 | From Enrico Scholz. | |
17698 | ||
648185ab PE |
17699 | 2001-11-27 Paul Eggert <eggert@twinsun.com> |
17700 | ||
17701 | * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to | |
17702 | use alloca when we didn't want to, and vice versa. | |
17703 | ||
68254a03 MA |
17704 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
17705 | ||
9113b58f AD |
17706 | * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle |
17707 | initialization. | |
68254a03 MA |
17708 | * src/output.c (prepare): Remove its update. |
17709 | ||
04d843a2 MA |
17710 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
17711 | ||
17712 | * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition. | |
17713 | Use %error-verbose. | |
17714 | ||
d2079671 | 17715 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
eeeb962b MA |
17716 | |
17717 | * src/bison.simple: Remove YYERROR_VERBOSE using. | |
17718 | Use %%error_verbose. | |
17719 | (yyparse): Likewise. | |
17720 | * src/output.c (prepare): Give its final value. | |
17721 | * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'. | |
17722 | * src/getargs.h: Add its extern declaration. | |
17723 | * src/getargs.c (error_verbose_flag): New int. | |
17724 | (getargs): Update to catch new case. | |
17725 | * src/options.c (option_table): 'error-verbose' is a new option. | |
17726 | (shortopts): Update. | |
17727 | ||
e0327bc8 AD |
17728 | 2001-11-27 Akim Demaille <akim@epita.fr> |
17729 | ||
17730 | * src/system.h: Use intl/libgettext.h. | |
17731 | * src/Makefile.am (INCLUDES): Add -I $(top_srcdir). | |
17732 | ||
000f1a3c AD |
17733 | 2001-11-27 Akim Demaille <akim@epita.fr> |
17734 | ||
17735 | * tests/torture.at (Exploding the Stack Size with Malloc): | |
17736 | s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/. | |
17737 | ||
26cfe0be AD |
17738 | 2001-11-27 Akim Demaille <akim@epita.fr> |
17739 | ||
17740 | * src/files.c: Include error.h. | |
17741 | Reported by Hans Aberg. | |
17742 | ||
f6bd5427 MA |
17743 | 2001-11-26 Marc Autret <autret_m@epita.fr> |
17744 | ||
d2079671 | 17745 | * src/reader.c (parse_include_decl): New, not yet implemented. |
f6bd5427 MA |
17746 | (read_declarations): Add case tok_include. |
17747 | * src/getargs.h (include): Add its extern definition. | |
17748 | * src/getargs.c (include): New const char *. | |
17749 | (getargs): Add case '-I'. | |
17750 | * src/options.c (option_table): Add include as command line and | |
17751 | percent option. | |
17752 | * src/lex.h (token_t): Add tok_include. | |
17753 | ||
2ca209c1 AD |
17754 | 2001-11-26 Akim Demaille <akim@epita.fr> |
17755 | ||
17756 | * src/reader.c (readgram): Make sure rules for mid-rule actions | |
17757 | have a lineno equal to that of their host rule. | |
17758 | Reported by Hans Aberg. | |
17759 | * tests/regression.at (Rule Line Numbers): New. | |
17760 | ||
0e41b407 AD |
17761 | 2001-11-26 Akim Demaille <akim@epita.fr> |
17762 | ||
17763 | * src/LR0.c (allocate_itemsets): kernel_size contains ints, not | |
17764 | size_ts. | |
17765 | ||
17766 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
17767 | ||
17768 | * src/complain.c, src/complain.h (error): Remove, provided by | |
17769 | lib/error.[ch]. | |
17770 | ||
e0c40012 AD |
17771 | 2001-11-26 Akim Demaille <akim@epita.fr> |
17772 | ||
17773 | * src/reader.c (read_declarations): Don't abort on tok_illegal, | |
17774 | issue an error message. | |
17775 | * tests/regression.at (Invalid %directive): New. | |
17776 | Reported by Hans Aberg. | |
17777 | ||
5e147124 AD |
17778 | 2001-11-26 Akim Demaille <akim@epita.fr> |
17779 | ||
17780 | * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE. | |
17781 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
17782 | ||
a034c8b8 AD |
17783 | 2001-11-26 Akim Demaille <akim@epita.fr> |
17784 | ||
17785 | * src/conflicts.c (conflicts_print): Don't complain at all when | |
17786 | there are no reduce/reduce conflicts, and as many shift/reduce | |
17787 | conflicts as expected. | |
17788 | * tests/regression.at (%expect right): Adjust. | |
17789 | ||
c64a20f3 AD |
17790 | 2001-11-23 Akim Demaille <akim@epita.fr> |
17791 | ||
17792 | * lib/alloca.c: Update, from fileutils. | |
17793 | ||
5b0d29bb AD |
17794 | 2001-11-23 Akim Demaille <akim@epita.fr> |
17795 | ||
17796 | * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@. | |
17797 | ||
722c4bfe AD |
17798 | 2001-11-23 Akim Demaille <akim@epita.fr> |
17799 | ||
17800 | * src/system.h: Include alloca.h. | |
17801 | * src/main.c (main) [C_ALLOCA]: Call alloca (0). | |
17802 | ||
6255b435 AD |
17803 | 2001-11-23 Akim Demaille <akim@epita.fr> |
17804 | ||
17805 | * src/print_graph.c (print_actions): Remove `rule', unused. | |
17806 | * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to | |
17807 | pacify GCC's signed < unsigned warnings. | |
17808 | * src/closure.c (itemsetsize): Likewise. | |
17809 | * src/reader.c (symbol_list_new): Static. | |
17810 | ||
b29b2ed5 AD |
17811 | 2001-11-23 Akim Demaille <akim@epita.fr> |
17812 | ||
17813 | Attaching lineno to buckets is stupid, since only one copy of each | |
17814 | symbol is kept, only the line of the first occurrence is kept too. | |
17815 | ||
17816 | * src/symtab.h, src/symtab.c (bucket): Remove the line member. | |
17817 | * src/reader.c (rline_allocated): Remove, unused. | |
17818 | (symbol_list): Have a `line' member. | |
17819 | (symbol_list_new): New. | |
17820 | (readgram): Use it. | |
17821 | * src/print.c (print_grammar): Output the rule line numbers. | |
17822 | * tests/regression.at (Solved SR Conflicts) | |
17823 | (Unresolved SR Conflicts): Adjust. | |
17824 | Reported by Hans Aberg. | |
17825 | ||
a81b1d4a MA |
17826 | 2001-11-22 Marc Autret <autret_m@epita.fr> |
17827 | ||
17828 | * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0. | |
17829 | ||
c1ecb3c1 MA |
17830 | 2001-11-22 Marc Autret <autret_m@epita.fr> |
17831 | ||
17832 | * src/muscle_tab.c (muscle_init): Remove initialization of | |
17833 | skeleton muscle. | |
17834 | * src/output.c (output_master_parser): Do it here. | |
17835 | ||
fbe01355 AD |
17836 | 2001-11-20 Akim Demaille <akim@epita.fr> |
17837 | ||
17838 | * po/sv.po: New. | |
17839 | * configure.in (ALL_LINGUAS): Adjust. | |
17840 | * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no | |
17841 | longer contains strings to translate. | |
17842 | ||
81e895c0 AD |
17843 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17844 | ||
17845 | * src/conflicts.c (conflicts_print): Add a missing \n. | |
17846 | ||
6bb1878b AD |
17847 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17848 | ||
17849 | * src/nullable.c (nullable_print): New. | |
17850 | (set_nullable): Call it when tracing. | |
17851 | Better locality of variables. | |
17852 | ||
d9ec2d07 AD |
17853 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17854 | ||
17855 | * src/print.c (print_actions): Better locality of variables. | |
17856 | ||
720e5c1b AD |
17857 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17858 | ||
17859 | * src/derives.c (print_derives): Fix and enrich. | |
17860 | * src/closure.c (print_fderives): Likewise. | |
17861 | ||
fb908786 AD |
17862 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17863 | ||
17864 | * src/closure.c (itemsetend): Remove, replaced with... | |
17865 | (itemsetsize): new. | |
17866 | ||
125ecb56 AD |
17867 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17868 | ||
17869 | * src/LR0.c (kernel_end): Remove, replaced with... | |
17870 | (kernel_size): new. | |
17871 | ||
d8cf039f AD |
17872 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17873 | ||
17874 | * src/conflicts.c (set_conflicts): Use arrays instead of pointers | |
17875 | to clarify. | |
17876 | ||
7bec0760 AD |
17877 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17878 | ||
17879 | * src/closure.c (closure): Use arrays instead of pointers to clarify. | |
17880 | ||
c87d4863 AD |
17881 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17882 | ||
17883 | * src/closure.c, src/derives.c, src/nullable.c: Adjust various | |
17884 | trace messages. | |
17885 | * src/LR0.c: Likewise. | |
17886 | (allocate_itemsets): Use arrays instead of pointers to clarify. | |
17887 | ||
9bfe901c AD |
17888 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17889 | ||
17890 | * src/getargs.c (statistics_flag): Replace with... | |
17891 | (trace_flag): New. | |
17892 | (longopts): Accept --trace instead of --statistics. | |
17893 | * src/getargs.h, src/options.c: Adjust. | |
17894 | * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c, | |
17895 | * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE. | |
17896 | ||
97db7bd4 AD |
17897 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17898 | ||
cc72668c | 17899 | * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer |
97db7bd4 AD |
17900 | pointers to clarify the code. |
17901 | (save_reductions, save_shifts): Factor common parts of alternatives. | |
17902 | ||
2c5f66ed AD |
17903 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17904 | ||
17905 | * src/LR0.c (new_state, get_state): Complete TRACE code. | |
17906 | * src/closure.c: Include `reader.h' to get `tags', needed by the | |
17907 | trace code. | |
17908 | Rename the conditional DEBUG as TRACE. | |
17909 | Output consistently TRACEs to stderr, not stdout. | |
17910 | * src/derives.c: Likewise. | |
17911 | * src/reduce.c: (inaccessable_symbols): Using if is better style | |
17912 | than goto. | |
17913 | Use `#if TRACE' instead of `#if 0' for tracing code. | |
17914 | ||
300f275f AD |
17915 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17916 | ||
17917 | * src/system.h (LIST_FREE, shortcpy): New. | |
17918 | * src/LR0.c: Use them. | |
17919 | * src/output.c (free_itemsets, free_reductions, free_shifts): | |
17920 | Remove, replaced by LIST_FREE. | |
17921 | ||
f59c437a AD |
17922 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17923 | ||
17924 | * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC) | |
17925 | (REDUCTIONS_ALLOC): New. | |
17926 | * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory | |
17927 | allocation. | |
17928 | ||
6986fd9e AD |
17929 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17930 | ||
17931 | * src/LR0.c (new_state): Complete trace code. | |
17932 | * src/nullable.c (set_nullable): Don't translate traces. | |
17933 | ||
4bc30f78 AD |
17934 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17935 | ||
17936 | * src/print_graph.c (print_core): Better locality of variables. | |
17937 | * src/print.c (print_core): Likewise. | |
17938 | ||
08a946e0 AD |
17939 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17940 | ||
17941 | * src/vcg.c: You do the output, so you are responsible of the | |
17942 | handling of VCG syntax, in particular: use quotearg. | |
17943 | * src/print_graph.c: Don't. | |
17944 | (print_actions): Don't output the actions as part of the nodes, | |
17945 | since that's the job of the edges. | |
17946 | (print_state): Don't output by hand: fill the node description, | |
9bfe901c | 17947 | and ask for its output. |
08a946e0 | 17948 | |
f0473484 AD |
17949 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17950 | ||
cc72668c AD |
17951 | * src/bison.simple (yyparse): When verbosely reporting an error, |
17952 | no longer put additional quotes around token names. | |
f0473484 AD |
17953 | * tests/calc.at: Adjust. |
17954 | ||
e41dc700 AD |
17955 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17956 | ||
17957 | * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'. | |
17958 | * src/reader.c (record_rule_lines, rline, rline_allocated): Remove. | |
17959 | * src/output.c: Adjust. | |
17960 | ||
652a871c AD |
17961 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17962 | ||
17963 | * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of... | |
17964 | (rule_t): this. | |
17965 | * src/conflicts.c, src/reader.c, src/reduce.c: Adjust. | |
17966 | ||
b2ed6e58 AD |
17967 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17968 | ||
17969 | * src/gram.h (rule_t): New. | |
17970 | (rule_table): New. | |
17971 | (rrhs, rlhs): Remove, part of state_t. | |
17972 | * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c, | |
17973 | * src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
17974 | * src/reader.c, src/reduce.c: Adjust. | |
17975 | ||
edad7067 AD |
17976 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17977 | ||
17978 | * src/reader.c (symbols_output): New, extracted from... | |
17979 | (packsymbols): Here. | |
17980 | (reader): Call it. | |
17981 | ||
3feec034 AD |
17982 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17983 | ||
17984 | * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with... | |
17985 | (maxrhs): this new function. | |
17986 | ||
ddcd5fdf AD |
17987 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17988 | ||
cc72668c | 17989 | * src/lalr.c (F): New macro to access the variable F. |
ddcd5fdf AD |
17990 | Adjust. |
17991 | ||
bb527fc2 AD |
17992 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17993 | ||
cc72668c | 17994 | * src/lalr.h (LA): New macro to access the variable LA. |
bb527fc2 AD |
17995 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: |
17996 | * src/lalr.c: Adjust. | |
17997 | ||
a845a697 AD |
17998 | 2001-11-19 Akim Demaille <akim@epita.fr> |
17999 | ||
18000 | * src/lalr.c (initialize_LA): Only initialize LA. Let... | |
18001 | (set_state_table): handle the `lookaheads' members. | |
18002 | ||
f004bf6a AD |
18003 | 2001-11-19 Akim Demaille <akim@epita.fr> |
18004 | ||
cc72668c AD |
18005 | * src/lalr.h (lookaheads): Removed array, whose contents is now |
18006 | a member of... | |
f004bf6a AD |
18007 | (state_t): this structure. |
18008 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
18009 | Adjust. | |
18010 | ||
de326cc0 AD |
18011 | 2001-11-19 Akim Demaille <akim@epita.fr> |
18012 | ||
cc72668c AD |
18013 | * src/lalr.h (consistent): Removed array, whose contents is now |
18014 | a member of... | |
de326cc0 AD |
18015 | (state_t): this structure. |
18016 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
18017 | Adjust. | |
18018 | ||
90b4416b AD |
18019 | 2001-11-19 Akim Demaille <akim@epita.fr> |
18020 | ||
cc72668c AD |
18021 | * src/lalr.h (reduction_table, shift_table): Removed arrays, whose |
18022 | contents are now members of... | |
90b4416b AD |
18023 | (state_t): this structure. |
18024 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
18025 | Adjust. | |
18026 | ||
9703cc49 AD |
18027 | 2001-11-19 Akim Demaille <akim@epita.fr> |
18028 | ||
18029 | * src/lalr.h (state_t): New. | |
18030 | (state_table): Be a state_t * instead of a core **. | |
18031 | (accessing_symbol): Remove, part of state_t. | |
18032 | * src/lalr.c: Adjust. | |
18033 | (set_accessing_symbol): Merge into... | |
18034 | (set_state_table): this. | |
18035 | * src/print_graph.c, src/conflicts.c: Adjust. | |
18036 | ||
d803322e AD |
18037 | 2001-11-14 Akim Demaille <akim@epita.fr> |
18038 | ||
18039 | * tests/calc.at, tests/output.at, tests/regression.at, | |
18040 | * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g: | |
18041 | now the tests are run in private dirs, therefore AC_CLEANUP and | |
18042 | family can be simplified to 0-ary. | |
18043 | * tests/atlocal.in: Now that we run `elsewhere' than in tests/, | |
18044 | use abs. path to find config.h. | |
18045 | * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's | |
18046 | stderr, there can be way too much random noise. | |
18047 | Instead pass -Werror to GCC and rely on the exit status. | |
18048 | Reported by Wolfram Wagner. | |
18049 | ||
3d76b07d AD |
18050 | 2001-11-14 Akim Demaille <akim@epita.fr> |
18051 | ||
18052 | * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be | |
18053 | defined only if yyoverflow is defined, to avoid `warning: unused | |
18054 | variable `yyvs1''. | |
18055 | Reported by The Test Suite. | |
18056 | ||
09b503c8 AD |
18057 | 2001-11-14 Akim Demaille <akim@epita.fr> |
18058 | ||
18059 | * src/print.c: Include reduce.h. | |
18060 | Reported by Hans Aberg. | |
18061 | ||
18062 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
18063 | ||
18064 | * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer): | |
18065 | Revert a previous patch: these are really const. | |
18066 | * src/conflicts.c (conflict_report): Additional useless pair of | |
18067 | braces to pacify GCC's warnings for `if () if () {} else {}'. | |
18068 | * src/lex.c (parse_percent_token): Replace equal_offset with | |
18069 | arg_offset. | |
18070 | arg is const. | |
18071 | Be sure to strdup `arg' when used, since there is no reason for | |
18072 | token_buffer not to change. | |
18073 | ||
0f37a994 AD |
18074 | 2001-11-14 Akim Demaille <akim@epita.fr> |
18075 | ||
18076 | * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper | |
18077 | definition. | |
18078 | * src/main.c (main): Use them. | |
18079 | Suggested by Hans Aberg. | |
18080 | ||
d39d93b8 AD |
18081 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18082 | ||
18083 | * src/system.h (ngettext): Now that we use ngettext, be sure to | |
18084 | provide a default definition when NLS are not used. | |
18085 | ||
9edcd895 AD |
18086 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18087 | ||
18088 | * doc/bison.texinfo: Use `$' as shell prompt, not `%'. | |
18089 | Use @kbd to denote user input. | |
18090 | (Language and Grammar): ANSIfy the example. | |
18091 | Adjust its layout for info/notinfo. | |
18092 | (Location Tracking Calc): Output error messages to stderr. | |
18093 | Output locations in a more GNUtically correct way. | |
18094 | Fix a couple of Englishos. | |
18095 | Adjust @group/@end group pairs. | |
18096 | ||
7da99ede AD |
18097 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18098 | ||
e3aa65c5 | 18099 | %expect was not functioning at all. |
7da99ede AD |
18100 | |
18101 | * src/conflicts.c (expected_conflicts): Set to -1. | |
18102 | (conflict_report): Use ngettext. | |
18103 | (conflicts_print): Check %expect and make its violation an error. | |
18104 | * doc/bison.texinfo (Expect Decl): Adjust. | |
18105 | * configure.in (AM_GNU_GETTEXT): Ask for ngettext. | |
18106 | * tests/regression.at (%expect not enough, %expect right) | |
18107 | (%expect too much): New. | |
18108 | ||
ba9dda1a AD |
18109 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18110 | ||
18111 | * tests/regression.at (Conflicts): Rename as... | |
18112 | (Unresolved SR Conflicts): this. | |
18113 | (Solved SR Conflicts): New. | |
18114 | ||
337c5bd1 AD |
18115 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18116 | ||
18117 | * src/reduce.c (print_results): Rename as... | |
18118 | (reduce_output): This. | |
18119 | Output to OUT, passed as argument, instead of output_obstack. | |
18120 | (dump_grammar): Likewise. | |
18121 | (reduce_free): New. | |
18122 | Also free V1. | |
18123 | (reduce_grammar): No longer call reduce_output, since... | |
18124 | * src/print.c (print_results): do it. | |
18125 | * src/main.c (main): Call reduce_free; | |
18126 | ||
c73a41af AD |
18127 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18128 | ||
18129 | * src/conflicts.c (print_reductions): Accept OUT as argument. | |
18130 | Output to it, not to output_obstack. | |
18131 | * src/print.c (print_actions): Adjust. | |
18132 | ||
0df87bb6 AD |
18133 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18134 | ||
18135 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return | |
18136 | the result instead of using... | |
18137 | (src_total, rrc_total, src_count, rrc_count): Remove. | |
18138 | (any_conflicts): Remove. | |
18139 | (print_conflicts): Split into... | |
18140 | (conflicts_print, conflicts_output): New. | |
18141 | * src/conflicts.h: Adjust. | |
18142 | * src/main.c (main): Invoke both conflicts_output and conflicts_print. | |
0f37a994 | 18143 | * src/print.c (print_grammar): Issue `\n' between two rules. |
0df87bb6 AD |
18144 | * tests/regression.at (Conflicts): New. |
18145 | Reported by Tom Lane. | |
18146 | ||
e4d3d4de AD |
18147 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18148 | ||
18149 | * tests/regression.at (Invalid input): Remove, duplicate with | |
18150 | ``Invalid input: 1''. | |
18151 | ||
6d7d248e AD |
18152 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18153 | ||
18154 | * tests/torture.at (AT_DATA_STACK_TORTURE) | |
18155 | (Exploding the Stack Size with Alloca) | |
18156 | (Exploding the Stack Size with Malloc): New. | |
18157 | ||
e9e4c321 AD |
18158 | 2001-11-12 Akim Demaille <akim@epita.fr> |
18159 | ||
18160 | * src/bison.simple (YYSTACK_REALLOC): New. | |
18161 | (yyparse) [!yyoverflow]: Use it and free the old stack. | |
0f37a994 | 18162 | Reported by Per Allansson. |
e9e4c321 | 18163 | |
5f7e0832 AD |
18164 | 2001-11-12 Pascal Bart <pascal.bart@epita.fr> |
18165 | ||
18166 | * src/bison.simple: Define type yystype instead of YYSTYPE, and | |
18167 | define CPP macro, which substitute YYSTYPE by yystype. | |
18168 | * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do | |
18169 | with yyltype/YYLTYPE. This allows inclusion of the generated | |
18170 | header within the parser if the compiler, such as GGC, accepts | |
18171 | multiple equivalent #defines. | |
18172 | From Akim. | |
18173 | ||
e3f1699f AD |
18174 | 2001-11-05 Akim Demaille <akim@epita.fr> |
18175 | ||
18176 | * src/reader.c (symbols_output): New, extracted from... | |
18177 | (packsymbols): here. | |
18178 | (reader): Adjust. | |
18179 | ||
65be0866 AD |
18180 | 2001-11-05 Akim Demaille <akim@epita.fr> |
18181 | ||
18182 | * src/lex.c (parse_percent_token): s/quotearg/quote/. | |
18183 | ||
e4d910bf AD |
18184 | 2001-11-05 Akim Demaille <akim@epita.fr> |
18185 | ||
18186 | * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up | |
18187 | pattern. | |
18188 | ||
951366c1 AD |
18189 | 2001-11-05 Akim Demaille <akim@epita.fr> |
18190 | ||
18191 | * src/options.h (struct option_table_struct): set_flags is void*. | |
18192 | * src/options.c (longopts): Support `--output' and `%output'. | |
18193 | (usage): Adjust. | |
18194 | * src/lex.h (tok_setopt): Remove, replaced with... | |
18195 | (tok_intopt, tok_stropt): these new guys. | |
18196 | * src/lex.c (getopt.h): Not needed. | |
18197 | (token_buffer, unlexed_token_buffer): Not const. | |
18198 | (percent_table): Promote `-' over `_' in directive names. | |
18199 | Active `%name-prefix', `file-prefix', and `output'. | |
18200 | (parse_percent_token): Accept possible arguments to directives. | |
18201 | Promote `-' over `_' in directive names. | |
18202 | ||
d8988b2f AD |
18203 | 2001-11-04 Akim Demaille <akim@epita.fr> |
18204 | ||
18205 | * doc/bison.texinfo (Decl Summary): Split the list into | |
18206 | `directives for grammars' and `directives for bison'. | |
18207 | Sort'em. | |
18208 | Add description of `%name-prefix', `file-prefix', and `output'. | |
18209 | Promote `-' over `_' in directive names. | |
18210 | (Bison Options): s/%locactions/%locations/. Nice Freudian slip. | |
18211 | Simplify the description of `--name-prefix'. | |
18212 | Promote `-' over `_' in directive names. | |
18213 | Promote `--output' over `--output-file'. | |
18214 | Fix the description of `--defines'. | |
18215 | * tests/output.at: Exercise %file-prefix and %output. | |
18216 | ||
6468d18e AD |
18217 | 2001-11-02 Akim Demaille <akim@epita.fr> |
18218 | ||
18219 | * doc/refcard.tex: Update. | |
18220 | ||
6b7e85b9 AD |
18221 | 2001-11-02 Akim Demaille <akim@epita.fr> |
18222 | ||
18223 | * src/symtab.h (SUNDEF): New. | |
18224 | * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to | |
18225 | stand for `uninitialized', instead of 0. | |
18226 | * src/reader.c (packsymbols, parse_thong_decl): Adjust. | |
18227 | * src/lex.c (lex): Adjust. | |
18228 | ||
18229 | * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF. | |
18230 | Number it 0. | |
18231 | Let yylex return it instead of a plain 0. | |
18232 | Reported by Dick Streefland. | |
18233 | ||
cd5aafcf AD |
18234 | 2001-11-02 Akim Demaille <akim@epita.fr> |
18235 | ||
18236 | * tests/regression.at (Mixing %token styles): New test. | |
18237 | ||
037ca2f1 AD |
18238 | 2001-11-02 Akim Demaille <akim@epita.fr> |
18239 | ||
18240 | * src/reader.c (parse_thong_decl): Formatting changes. | |
18241 | (token_translations_init): New, extracted from... | |
18242 | (packsymbols): Here. | |
18243 | Adjust. | |
18244 | ||
270a173c AD |
18245 | 2001-11-01 Akim Demaille <akim@epita.fr> |
18246 | ||
18247 | * tests/regression.at (AT_TEST_CPP_GUARD_H): New. | |
18248 | Check that `9foo.y' produces correct cpp guards. | |
18249 | * src/files.c (compute_header_macro): Prepend `BISON_' to CPP | |
18250 | guards. | |
18251 | Reported by Wwp. | |
18252 | ||
561f9a30 AD |
18253 | 2001-11-01 Akim Demaille <akim@epita.fr> |
18254 | ||
18255 | * tests/regression.at (Invalid input: 2): New. | |
18256 | * src/lex.c (unlexed_token_buffer): New. | |
18257 | (lex, unlex): Adjust: when unlexing, be sure to save token_buffer | |
18258 | too. | |
18259 | Reported by Wwp. | |
18260 | ||
f987e9d2 AD |
18261 | 2001-11-01 Akim Demaille <akim@epita.fr> |
18262 | ||
18263 | * tests/calc.at: Catch up with 1.30. | |
18264 | * configure.in: Bump to 1.49a. | |
18265 | Adjust to newer Autotest. | |
18266 | ||
0846f581 PB |
18267 | 2001-10-19 Pascal Bart <pascal.bart@epita.fr> |
18268 | ||
18269 | * src/conflicts.c: Move global variables rrc_total and src_total ... | |
18270 | (print_conflicts): here. | |
18271 | * src/output.c (output): Free global variable user_toknums. | |
18272 | * src/lex.c (token_obstack): Become static. | |
18273 | ||
3c1a79b3 AD |
18274 | 2001-10-18 Akim Demaille <akim@epita.fr> |
18275 | ||
18276 | * tests/atlocal.in (GCC): Add. | |
18277 | * tests/calc.at: s/m4_match/m4_bmatch/. | |
18278 | s/m4_patsubst/m4_bpatsubst/. | |
18279 | (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC. | |
18280 | * configure.in: AC_SUBST(GCC). | |
18281 | ||
5d52e7d0 MA |
18282 | 2001-10-14 Marc Autret <autret_m@epita.fr> |
18283 | ||
18284 | * src/options.c (create_long_option_table): Fix. | |
18285 | ||
631aa1d3 AD |
18286 | 2001-10-10 Akim Demaille <akim@epita.fr> |
18287 | ||
18288 | * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA. | |
18289 | ||
f6ec6d13 AD |
18290 | 2001-10-04 Akim Demaille <akim@epita.fr> |
18291 | ||
18292 | * src/reader.c (parse_union_decl): Push the caracters in | |
18293 | union_obstack, not attrs_obstack. | |
18294 | ||
342b8b6e AD |
18295 | 2001-10-04 Akim Demaille <akim@epita.fr> |
18296 | ||
18297 | Merge in the branch 1.29. | |
18298 | ||
18299 | * src/reader.c (packsymbols): Use a temporary obstack for | |
18300 | `%%tokendef', since output_stack is already used elsewhere. | |
18301 | ||
18302 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18303 | ||
18304 | Bump 1.29d. | |
18305 | ||
18306 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18307 | ||
18308 | Version 1.29c. | |
18309 | ||
18310 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18311 | ||
18312 | * tests/regression.at (Invalid CPP headers): New. | |
18313 | From Alexander Belopolsky. | |
18314 | * src/files.c (compute_header_macro): Map non alnum chars to `_'. | |
18315 | ||
18316 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18317 | ||
18318 | * tests/regression.at (Invalid input): New. | |
18319 | * src/lex.c (lex): Be sure to set `token_buffer' in any case. | |
18320 | Reported by Shura. | |
18321 | ||
18322 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18323 | ||
18324 | * tests/calc.at: Now that --debug works, the tests must be adjusted. | |
18325 | ||
18326 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
18327 | ||
18328 | * src/output.c (output_parser): Assert `skeleton'. | |
18329 | * src/files.c (skeleton_find): Look harder for skeletons on DOSish | |
18330 | systems. | |
18331 | From Shura. | |
18332 | ||
18333 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
18334 | ||
18335 | * src/lex.h: Echo modifications. | |
18336 | * src/lex.c (unlex): Parameter is now token_t. | |
18337 | From Hans Aberg. | |
18338 | ||
18339 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
18340 | ||
18341 | * src/main.c: Include lex.h. | |
18342 | From Hans Aberg. | |
18343 | ||
18344 | 2001-09-29 Akim Demaille <akim@epita.fr> | |
18345 | ||
18346 | * src/getargs.c (longopts): `--debug' is `-t', not `-d'. | |
18347 | ||
18348 | 2001-09-28 Akim Demaille <akim@epita.fr> | |
18349 | ||
18350 | * tests/testsuite.at: Update to newer Autotest. | |
18351 | * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped. | |
18352 | ||
18353 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
18354 | ||
18355 | Position independent wrapper. | |
18356 | ||
18357 | * tests/bison: Remove. | |
18358 | * tests/bison.in: New. | |
18359 | * configure.in: Adjust. | |
18360 | ||
18361 | 2001-09-27 Paul Eggert <eggert@twinsun.com> | |
18362 | ||
18363 | Port quotearg fixes from tar 1.13.24. | |
18364 | ||
18365 | * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct | |
18366 | tm to be declared. | |
18367 | (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC. | |
18368 | (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT. | |
18369 | ||
18370 | * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4. | |
18371 | * m4/mbrtowc.m4: New file. | |
18372 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h. | |
18373 | Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc). | |
18374 | ||
18375 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
18376 | ||
18377 | Bump to 1.29c. | |
18378 | ||
18379 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
18380 | ||
18381 | Version 1.29b. | |
18382 | ||
18383 | 2001-09-25 Akim Demaille <akim@epita.fr> | |
18384 | ||
18385 | * src/system.h: Include `xalloc.h'. | |
18386 | Remove it from the C files. | |
18387 | * src/files.c (output_files): Free the obstacks. | |
18388 | * src/lex.c (init_lex): Rename as... | |
18389 | (lex_init): this. | |
18390 | (lex_free): New. | |
18391 | * src/main.c (main): Use it. | |
18392 | ||
18393 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
18394 | ||
18395 | * src/vcg.c (open_edge, close_edge, open_node, close_node): Change | |
18396 | to output informations in fout (FILE*). | |
18397 | (open_graph, close_graph): Likewise. | |
18398 | (output_graph, output_edge, output_node): Likewise. | |
18399 | * src/vcg.h: Update function prototypes. | |
18400 | * src/print_graph.c (print_graph): Open output graph file. | |
18401 | (print_actions): Adjust. | |
18402 | * src/files.h: Remove extern declaration. | |
18403 | * src/files.c: Remove graph_obstack declaration. | |
18404 | (open_files): Remove graph_obstack initialization. | |
18405 | (output_files): Remove graph_obstack saving. | |
18406 | ||
18407 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
18408 | ||
18409 | * src/files.c (compute_output_file_names): Fix. | |
18410 | ||
18411 | 2001-09-24 Marc Autret <autret_m@epita.fr>, | |
18412 | Akim Demaille <akim@epita.fr> | |
18413 | ||
18414 | * src/reader.c (reader): Remove call to free_symtab (). | |
18415 | * src/main.c (main): Call it here. | |
18416 | Include symtab.h. | |
18417 | * src/conflicts.c (initialize_conflicts): Rename as... | |
18418 | (solve_conflicts): this. | |
18419 | * src/print.c (print_core, print_actions, print_state) | |
18420 | (print_grammar): Dump to a file instead a `output_obstack'. | |
18421 | (print_results): Dump `output_obstack', and then proceed with the | |
18422 | FILE *. | |
18423 | * src/files.c (compute_output_file_names, close_files): New. | |
18424 | (output_files): Adjust. | |
18425 | * src/main.c (main): Adjust. | |
18426 | ||
18427 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
18428 | ||
18429 | * src/files.c (compute_header_macro): Computes header macro name | |
18430 | from spec_defines_file when given. | |
18431 | ||
18432 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
18433 | ||
18434 | * src/files.c (output_files): Add default extensions. | |
18435 | ||
18436 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
18437 | ||
18438 | * src/conflicts.c (finalize_conflicts): Rename as... | |
18439 | (free_conflicts): this. | |
18440 | ||
18441 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
18442 | ||
18443 | * src/gram.c (gram_free): Rename back as... | |
18444 | (dummy): this. | |
18445 | (output_token_translations): Free `token_translations'. | |
18446 | * src/symtab.c (free_symtab): Free the tag field. | |
18447 | ||
18448 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
18449 | ||
18450 | Remove `translations' as it is always set to true. | |
18451 | ||
18452 | * src/gram.h: Adjust. | |
18453 | * src/reader.c (packsymbols, parse_token_decl): Adjust | |
18454 | * src/print.c (print_grammar): Adjust. | |
18455 | * src/output.c (output_token_translations): Adjust. | |
18456 | * src/lex.c (lex): Adjust. | |
18457 | * src/gram.c: Be sure the set pointers to NULL. | |
18458 | (dummy): Rename as... | |
18459 | (gram_free): this. | |
18460 | ||
18461 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
18462 | ||
18463 | * configure.in: Invoke AM_LIB_DMALLOC. | |
18464 | * src/system.h: Use dmalloc. | |
18465 | * src/LR0.c: Be sure to have pointers initialized to NULL. | |
18466 | (allocate_itemsets): Allocate kernel_items only if needed. | |
18467 | ||
18468 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
18469 | ||
18470 | * configure.in: Bump to 1.29b. | |
18471 | * tests/Makefile.am (DISTCLEANFILES): Add package.m4. | |
18472 | * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't | |
18473 | need xmalloc.c in calc.y. | |
18474 | From Pascal Bart. | |
18475 | ||
18476 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
18477 | ||
18478 | Version 1.29a. | |
18479 | * Makefile.maint, config/config.guess, config/config.sub, | |
18480 | * config/missing: Update from masters. | |
18481 | * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend | |
18482 | upon package.m4. | |
18483 | * configure.in (ALL_LINGUAS): Add `tr'. | |
18484 | ||
18485 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
18486 | ||
18487 | * tests/Makefile.am (package.m4): Move to... | |
18488 | ($(srcdir)/$(TESTSUITE)): here. | |
18489 | ||
18490 | 2001-09-20 Akim Demaille <akim@epita.fr> | |
18491 | ||
18492 | * src/complain.c: No longer try to be standalone: use system.h. | |
18493 | Don't assume __STDC__ is defined to 1. Just test if it is defined. | |
18494 | * src/complain.h: Likewise. | |
18495 | * src/reduce.c (useless_nonterminals, inaccessable_symbols): | |
18496 | Remove the unused variable `n'. | |
18497 | From Albert Chin-A-Young. | |
18498 | ||
18499 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18500 | ||
18501 | * doc/bison.1: Update. | |
18502 | * doc/bison.texinfo (Bison Options): Update --defines and --graph | |
18503 | descriptions. | |
18504 | (Option Cross Key): Update. | |
18505 | Add --graph. | |
18506 | ||
18507 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18508 | ||
18509 | * tests/regression.at: New test (comment in %union). | |
18510 | ||
18511 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18512 | ||
18513 | * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment | |
18514 | do that. | |
18515 | Reported by Keith Browne. | |
18516 | ||
18517 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18518 | ||
18519 | * tests/output.at: Add tests for --defines and --graph. | |
18520 | ||
18521 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18522 | ||
18523 | * tests/output.at: Removes tests of %{header,src}_extension features. | |
18524 | ||
18525 | 2001-09-18 Akim Demaille <akim@epita.fr> | |
18526 | ||
18527 | * tests/Makefile.am (package.m4): New. | |
18528 | * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'. | |
18529 | (_AT_CHECK_CALC_ERROR): Likewise. | |
18530 | Factor the `, ' part of verbose error messages. | |
18531 | ||
18532 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18533 | ||
18534 | * src/getargs.c (longopts): Declare --defines and --graph as options | |
18535 | with optional arguments. | |
18536 | * src/files.h: Add extern declarations. | |
18537 | * src/files.c (spec_graph_file, spec_defines_file): New. | |
18538 | (output_files): Update. | |
18539 | Remove CPP-outed code. | |
18540 | ||
18541 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
18542 | ||
18543 | Turn off %{source,header}_extension feature. | |
18544 | ||
18545 | * src/files.c (compute_exts_from_gf): Update. | |
18546 | (compute_exts_from_src): Update. | |
18547 | (output_files): CPP-out useless code. | |
18548 | * src/files.h: Remove {header,source}_extension extern declarations. | |
18549 | * src/reader.c (parse_dquoted_param): CPP-out. | |
18550 | (parse_header_extension_decl): Remove. | |
18551 | (parse_source_extension_decl): Remove. | |
18552 | (read_declarations): Remove cases tok_{hdrext,srcext}. | |
18553 | * src/lex.c (percent_table): Remove {header,source}_extension entries. | |
18554 | * src/lex.h (token_t): Remove tok_hdrext and tok_srcext. | |
18555 | ||
18556 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
18557 | ||
18558 | * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT): | |
18559 | (AT_CHECK_BISON_PERCENT_FLAGS): Merge into... | |
18560 | (AT_CHECK_OUTPUT): this. | |
18561 | Merely check ls' exit status, its output is useless. | |
18562 | ||
18563 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
18564 | ||
18565 | * tests/calc.at: Use m4_match. | |
18566 | (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'. | |
18567 | ||
18568 | 2001-09-10 Marc Autret <autret_m@epita.fr>, | |
18569 | Akim Demaille <akim@epita.fr> | |
18570 | ||
18571 | * src/vcg.h (graph_s): color, textcolor, bordercolor are now | |
18572 | enum color_e. | |
18573 | * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm | |
18574 | to `normal'. | |
18575 | * src/reader.c (parse_token_decl): Initialize token with tok_eof. | |
18576 | * src/lex.h: Adjust prototype. | |
18577 | (token_t): Add `tok_undef'. | |
18578 | * src/lex.c (struct percent_table_struct): Retval is now a token_t. | |
18579 | (parse_percent_token): Now returns token_t. | |
18580 | Add default statement in switch. | |
18581 | (lex): Separate `c' as an input variable, from the token_t result | |
18582 | part. | |
18583 | (unlexed): Is a token_t. | |
18584 | ||
18585 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
18586 | ||
18587 | * configure.in: Bump to 1.29a. | |
18588 | ||
18589 | 2001-09-07 Akim Demaille <akim@epita.fr> | |
18590 | ||
18591 | Version 1.29. | |
18592 | ||
18593 | 2001-08-30 Akim Demaille <akim@epita.fr> | |
18594 | ||
18595 | * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove. | |
18596 | * m4/atconfig.m4: Remove. | |
18597 | * tests/testsuite.at, tests/atlocal.in, tests/output.at, | |
18598 | * tests/bison: New. | |
18599 | * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER, | |
18600 | m4_if, m4_patsubst, and m4_regexp. | |
18601 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an | |
18602 | `input' file instead of echo. | |
18603 | ||
18604 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
18605 | ||
18606 | Bump to 1.28e. | |
18607 | ||
18608 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
18609 | ||
18610 | Version 1.28d. | |
18611 | ||
18612 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
18613 | ||
18614 | * src/bison.simple (yyparse): Don't take the address of an | |
18615 | item before the start of an array, as that doesn't conform to | |
18616 | the C Standard. | |
18617 | ||
18618 | 2001-08-29 Robert Anisko <anisko_r@epita.fr> | |
18619 | ||
18620 | * doc/bison.texinfo (Location Tracking Calc): New node. | |
18621 | ||
18622 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
18623 | ||
18624 | * src/output.c (output): Do not define const, as this now | |
18625 | causes more problems than it cures. | |
18626 | ||
18627 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
18628 | ||
18629 | * doc/bison.texinfo: Modernize `@node' and `@top' use: just name | |
18630 | the nodes. | |
18631 | Be sure to tag the `detailmenu'. | |
18632 | ||
18633 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
18634 | ||
18635 | * Makefile.maint (do-po-update): Wget refuses to overwrite files: | |
18636 | download in a tmp dir. | |
18637 | ||
18638 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
18639 | ||
18640 | * config/depcomp: New file. | |
18641 | ||
18642 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
18643 | ||
18644 | * doc/bison.1 (mandoc): Adjust. | |
18645 | From Juan Manuel Guerrero. | |
18646 | ||
18647 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
18648 | ||
18649 | * src/print_graph.c (print_state): Fix. | |
18650 | ||
18651 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
18652 | ||
18653 | * src/vcg.h (classname_s, infoname_s, node_s): Constify the | |
18654 | char * members. | |
18655 | Echo modifications to the functions prototypes. | |
18656 | * src/vcg.c (add_classname, add_infoname): Adjust arguments. | |
18657 | ||
18658 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
18659 | ||
18660 | * src/vcg.c: Include `xalloc.h'. | |
18661 | (add_colorentry): New. | |
18662 | (add_classname): New. | |
18663 | (add_infoname): New. | |
18664 | * src/vcg.h: Add new prototypes. | |
18665 | ||
18666 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
18667 | ||
18668 | * Makefile.maint: Sync. again with CVS Autoconf. | |
18669 | ||
18670 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
18671 | ||
18672 | * Makefile.maint: Formatting changes. | |
18673 | (po-update, cvs-update, update): New targets. | |
18674 | (AMTAR): Remove. | |
18675 | ||
18676 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
18677 | ||
18678 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
18679 | * Makefile.maint: Sync. with CVS Autoconf. | |
18680 | ||
18681 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
18682 | ||
18683 | * src/vcg.h (struct infoname_s): New. | |
18684 | (struct colorentry_s): New. | |
18685 | (graph_s): New fields {vertical,horizontal}_order in structure. | |
18686 | Add `infoname' field. | |
18687 | Add `colorentry' field; | |
18688 | * src/vcg_defaults.h (G_VERTICAL_ORDER): New. | |
18689 | (G_HORIZONTAL_ORDER): New. | |
18690 | (G_INFONAME): New. | |
18691 | (G_COLORENTRY): New. | |
18692 | * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order. | |
18693 | Add output of `infoname'. | |
18694 | Add output of `colorentry'. | |
18695 | ||
18696 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
18697 | ||
18698 | * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'. | |
18699 | This one shadowed a global parameter. | |
18700 | ||
18701 | 2001-08-24 Marc Autret <autret_m@epita.fr> | |
18702 | ||
18703 | * src/print_graph.c (node_output_size): Declared POSIX `size_t' type, | |
18704 | instead of `unsigned'. | |
18705 | (print_state): Do not call obstack_object_size () in obstack_grow () | |
18706 | to avoid macro variables shadowing. | |
18707 | ||
18708 | 2001-08-23 Marc Autret <autret_m@epita.fr> | |
18709 | ||
18710 | * src/lex.c (percent_table): Typo: s/naem/name/. | |
18711 | Add graph option. | |
18712 | Normalize new options declarations. | |
18713 | ||
18714 | 2001-08-20 Pascal Bart <pascal.bart@epita.fr> | |
18715 | ||
18716 | * tests/suite.at: Exercise %header_extension and %source_extension. | |
18717 | ||
18718 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
18719 | ||
18720 | * src/reader.c (parse_dquoted_param): New. | |
18721 | (parse_header_extension_decl): Use it. | |
18722 | (parse_source_extension_decl): Likewise. | |
18723 | ||
18724 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
18725 | ||
18726 | * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'. | |
18727 | (get_xxxx_str): Use assert () instead of complain (). | |
18728 | Remove return invokations in default cases. | |
18729 | (get_decision_str): Modify default behaviour. Remove second argument. | |
18730 | Echo modifications on calls. | |
18731 | (output_graph): Fix. | |
18732 | ||
18733 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
18734 | ||
18735 | * src/getargs.c (usage): Update with ``-g, --graph''. | |
18736 | ||
18737 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
18738 | ||
18739 | * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'. | |
18740 | (Option Cross Key): Likewise. | |
18741 | * doc/bison.1: Update. | |
18742 | ||
1c8c2190 PB |
18743 | 2001-09-25 Pascal Bart <pascal.bart@epita.fr> |
18744 | ||
18745 | * src/output.c (output_master_parser): Don't finish action_obstack. | |
18746 | (output_parser): Don't care about the muscle action, here. | |
18747 | (prepare): Copy the action_obstack in the action muscle. | |
18748 | (output): Free action_obstack. | |
18749 | ||
180d45ba PB |
18750 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> |
18751 | ||
18752 | * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which | |
18753 | will contain `%union' declaration. | |
18754 | (parse_union_decl): Delete #line directive output. | |
18755 | (parse_union_decl): Substitute /attrs_obstack/union_obstack for all | |
18756 | informations about %union. | |
18757 | (parse_union_decl): Copy the union_obstack in the muscle stype. | |
18758 | * src/bison.simple: Add new #line directive. | |
18759 | Add typdef %%stype YYSTYPE. | |
18760 | ||
c51d1a19 PB |
18761 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> |
18762 | ||
18763 | * src/bison.simple: Add new `#line' directive. | |
18764 | ||
6f9344da PB |
18765 | 2001-09-22 Pascal Bart <pascal.bart@epita.fr> |
18766 | ||
18767 | * src/bison.simple: New `#line' directive. | |
18768 | * src/output.c (output_parser): Support new dynamic muscle input_line. | |
18769 | ||
652def80 MA |
18770 | 2001-09-22 Marc Autret <autret_m@epita.fr> |
18771 | ||
18772 | * src/output.c (output_master_parser): New. | |
18773 | (output_parser): Be more re-entrant. | |
18774 | ||
25b222fa MA |
18775 | 2001-09-21 Marc Autret <autret_m@epita.fr> |
18776 | ||
18777 | * src/reader.c (copy_definition, parse_union_decl): Update and use | |
18778 | `linef' muscle. | |
18779 | (copy_action): Likewise. | |
18780 | Use obstack_1grow (). | |
18781 | * src/muscle_tab.c (muscle_init): Add muscle `linef'. | |
18782 | ||
6bc35ae5 MA |
18783 | 2001-09-21 Marc Autret <autret_m@epita.fr> |
18784 | ||
18785 | * src/options.c (option_table): Adjust. | |
18786 | * src/lex.c (parse_percent_token): Fix. | |
18787 | ||
c0629aa1 PB |
18788 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> |
18789 | ||
18790 | * src/options.c (symtab.h): Include it, need by lex.h. | |
342b8b6e | 18791 | |
82b6d266 PB |
18792 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> |
18793 | ||
18794 | * src/lex.c (parse_percent_token): Change type of variable `tx', which | |
18795 | is now an option_table_struct*. | |
18796 | (option_strcmp): New function option_strcmp. | |
18797 | (parse_percent_token): Call option_strcmp. | |
18798 | * src/getargs.c (xalloc.h, options.h): Include it. | |
18799 | (getargs): Call create_long_option_table. | |
18800 | (getargs): Free longopts at the end of the function. | |
18801 | (shortopts): Move in options.c. | |
18802 | * src/options.c (create_long_option_table): New function. Convert | |
18803 | information from option_table to option structure. | |
18804 | * src/reader.c (options.h): Include it. | |
18805 | ||
18806 | * src/Makefile.am: Adjust. | |
18807 | * src/options.c (option_table): Create from longopts and percent_table. | |
18808 | * src/getargs.c (longopts): Delete. | |
18809 | * src/lex.c (struct percent_table_struct): Delete. | |
18810 | (percent_table): Delete. | |
18811 | (options.h): Include it. | |
18812 | * src/options.c: Create. | |
18813 | * src/options.h: Create. | |
18814 | Declare enum opt_access_e. | |
18815 | Define struct option_table_struct. | |
18816 | ||
75f5aaea MA |
18817 | 2001-09-20 Marc Autret <autret_m@epita.fr> |
18818 | ||
18819 | * doc/bison.texinfo: Adjust terminologies about prologue and epilogue | |
18820 | sections of Bison. | |
18821 | ||
f508cb0a PB |
18822 | 2001-09-19 Pascal Bart <pascal.bart@epita.fr> |
18823 | ||
18824 | * src/bison.simple: s/%%filename/%%skeleton. | |
18825 | * src/muscle_tab.c (getargs.h): Include it. | |
18826 | (muscle_init): Insert new muscle skeleton. | |
18827 | ||
13105fc1 PB |
18828 | 2001-09-18 Pascal Bart <pascal.bart@epita.fr> |
18829 | ||
18830 | * src/output.c (output_parser): Delete unused variable actions_dumped. | |
18831 | ||
b0c4483e PB |
18832 | 2001-09-07 Pascal Bart <pascal.bart@epita.fr> |
18833 | ||
18834 | * src/output.c (output): Delete call to reader_output_yylsp. | |
18835 | * src/reader.c (reader): Likewise. | |
ba0fe3c7 | 18836 | * src/reader.h: Delete declaration of reader_output_yylsp. |
342b8b6e | 18837 | |
11d82f03 MA |
18838 | 2001-09-02 Marc Autret <autret_m@epita.fr> |
18839 | ||
18840 | * src/reader.c: Include muscle_tab.h. | |
18841 | (parse_union_decl): Update. | |
18842 | (parse_macro_decl): Rename parse_muscle_decl. | |
18843 | Update to use renamed functions and variable. | |
18844 | (read_declarations, copy_action, read_additionnal_code, : Updated | |
18845 | with correct variables and functions names. | |
18846 | (packsymbols, reader): Likewise. | |
342b8b6e | 18847 | |
11d82f03 | 18848 | * src/reader.h (muscle_obstack): Extern declaration update. |
342b8b6e | 18849 | |
11d82f03 MA |
18850 | * src/output.c: Include muscle_tab.h |
18851 | In all functions using macro_insert, change by using muscle_insert (). | |
18852 | (macro_obstack): Rename muscle_obstack. | |
18853 | Echo modifications in the whole file. | |
18854 | (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT. | |
18855 | (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING. | |
18856 | (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX. | |
18857 | ||
18858 | * src/muscle_tab.h: Update double inclusion macros. | |
18859 | (macro_entry_s): Rename muscle_entry_s. | |
18860 | Update prototypes. | |
342b8b6e | 18861 | |
11d82f03 MA |
18862 | * src/muscle_tab.c: Include muscle_tab.h. |
18863 | Rename macro_tabble to muscle_table. | |
18864 | (mhash1, mhash2, mcmp): Use muscle_entry. | |
18865 | (macro_init): Rename muscle_init. Update. | |
18866 | (macro_insert): Rename muscle_insert. Update. | |
18867 | (macro_find): Rename muscle_find. Update. | |
18868 | ||
18869 | * src/main.c: Include muscle_tab.h. | |
18870 | (main): Call muscle_init (). | |
18871 | * src/Makefile.am (bison_SOURCES): Echo modifications. | |
18872 | ||
93a37297 MA |
18873 | 2001-09-02 Marc Autret <autret_m@epita.fr> |
18874 | ||
f753cd62 | 18875 | Now the files macro_tab.[ch] are named muscle_tab.[ch]. |
342b8b6e | 18876 | |
f753cd62 MA |
18877 | * src/muscle_tab.c, src/muscle_tab.h: Add files. |
18878 | ||
18879 | 2001-09-02 Marc Autret <autret_m@epita.fr> | |
18880 | ||
18881 | * src/macrotab.c, src/macrotab.h: Remove. | |
93a37297 | 18882 | |
682d48cd PB |
18883 | 2001-09-01 Pascal Bart <pascal.bart@epita.fr> |
18884 | ||
342b8b6e | 18885 | * src/reader.c (copy_guard): Use muscle to specify the `#line' |
682d48cd PB |
18886 | filename. |
18887 | ||
087c8fda MA |
18888 | 2001-09-01 Marc Autret <autret_m@epita.fr> |
18889 | ||
18890 | * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set | |
18891 | to an explicit value to activate the feature. We do it here. | |
18892 | ||
dda680cb PB |
18893 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
18894 | ||
18895 | * src/output.c (prepare): Delete the `filename' muscule insertion. | |
18896 | * src/reader.c (copy_action): Use `filename' muscule with `#line'. | |
18897 | (parse_union_decl): Likewise. | |
18898 | * src/macrotab.c (macro_init): Initialize filename by infile. | |
18899 | ||
9e644e64 MA |
18900 | 2001-08-31 Marc Autret <autret_m@epita.fr> |
18901 | ||
18902 | * src/bison.simple (YYLSP_NEEDED): New definition. | |
18903 | * src/output.c (prepare): Add macro insertion of `locations_flag' | |
18904 | ||
17da6427 PB |
18905 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
18906 | ||
18907 | * src/output.c (prepare): Delete insertion of previous muscles, | |
18908 | and insert the `prefix' muscles. | |
18909 | * src/macrotab.c (macro_init): Likewise. | |
18910 | (macro_init): Initialization prefix directive by `yy'. | |
342b8b6e | 18911 | * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval, |
17da6427 PB |
18912 | %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar, |
18913 | yylval, yydebug, yyerror, yynerrs and yyparse. | |
342b8b6e | 18914 | New directive `#define' to substitute yydebug, ... with option |
17da6427 PB |
18915 | name_prefix. |
18916 | ||
e8cb70b9 PB |
18917 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
18918 | ||
18919 | * src/main.c (main): Standardize. | |
18920 | * src/output.c (output_table_data, output_parser): Likewise. | |
18921 | * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise. | |
18922 | ||
63c2d5de MA |
18923 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr> |
18924 | ||
342b8b6e | 18925 | * src/reader.c (read_additionnal_code): Rename %%user_code to |
63c2d5de MA |
18926 | %%epilogue. |
18927 | * src/output.c (output): Rename %%declarations to %%prologue. | |
18928 | * src/bison.simple: Echo modifications. | |
342b8b6e | 18929 | |
d8cb5183 MA |
18930 | 2001-08-31 Marc Autret <autret_m@epita.fr> |
18931 | ||
18932 | * src/reader.c (readgram): CleanUp. | |
18933 | (output_token_defines): Likewise. | |
18934 | (packsymbols): Likewise. | |
18935 | (reader): Likewise. | |
18936 | * src/output.c (output): CPP-out useless code. | |
18937 | ||
6c686258 PB |
18938 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
18939 | ||
342b8b6e | 18940 | * src/reader.c (reader): Delete obsolete call to function |
6c686258 PB |
18941 | output_trailers and output_headers. |
18942 | * src/output.h: Remove obsolete functions prototypes of output_headers | |
18943 | and output_trailers. | |
18944 | ||
8f451ef7 PB |
18945 | 2001-08-30 Pascal Bart <pascal.bart@epita.fr> |
18946 | ||
18947 | * src/main.c: Include macrotab.h. | |
342b8b6e | 18948 | * src/macrotab.h (macro_entry_s): Constify fields. |
8f451ef7 PB |
18949 | Adjust functions prototypes. |
18950 | * src/macrotab.c (macro_insert): Constify key and value. | |
18951 | (macro_find): Constify key. | |
18952 | (macro_insert): Include 'xalloc.h' | |
18953 | (macro_insert): Use XMALLOC. | |
18954 | (macro_find): Constify return value. | |
18955 | * src/output.c (output_table_data): Rename table to table_data. | |
18956 | (output_parser): Constify macro_key, macro_value. | |
18957 | ||
997b6fd0 | 18958 | 2001-08-30 Marc Autret <autret_m@epita.fr> |
2ba3b73c MA |
18959 | |
18960 | * src/reader.c (parse_skel_decl): New. | |
342b8b6e | 18961 | (read_declarations): Add case `tok_skel', call parse_skel_decl (). |
2ba3b73c MA |
18962 | * src/lex.h (token_t): New token `tok_skel'. |
18963 | * src/lex.c (percent_table): Add skeleton option entry. | |
18964 | Standardize. | |
18965 | ||
ff48177d MA |
18966 | 2001-08-29 Marc Autret <autret_m@epita.fr> |
18967 | ||
18968 | * src/bison.simple: Add %%user_code directive at the end. | |
18969 | * src/reader.c (read_additionnal_code): New. | |
18970 | (reader): Use it. | |
18971 | * src/output.c (output_program): Remove. | |
18972 | (output): Update. | |
18973 | ||
b33160bf MA |
18974 | 2001-08-28 Marc Autret <autret_m@epita.fr> |
18975 | ||
18976 | * src/output.c (output_actions): Clean up. | |
4e5caae2 | 18977 | (output_gram): CPP-out useless code. |
b33160bf MA |
18978 | * src/reader.c (reader): Clean up, CPP-out useless code. |
18979 | ||
d1a2daf7 PB |
18980 | 2001-08-28 Pascal Bart <pascal.bart@epita.fr> |
18981 | ||
342b8b6e | 18982 | * src/output.c (output): Copy attrs_obstack in the '%%definitions' |
535c0e75 | 18983 | directive. |
d1a2daf7 PB |
18984 | * src/bison.simple: Add `%%definitions'. |
18985 | ||
2b763dfe MA |
18986 | 2001-08-28 Marc Autret <autret_m@epita.fr> |
18987 | ||
18988 | * config/depcomp: New file. | |
18989 | ||
f1a87ef6 PE |
18990 | 2001-08-27 Paul Eggert <eggert@twinsun.com> |
18991 | ||
18992 | * src/bison.simple (yyparse): Don't take the address of an | |
18993 | item before the start of an array, as that doesn't conform to | |
18994 | the C Standard. | |
18995 | ||
82e236e2 RA |
18996 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> |
18997 | ||
f1a87ef6 | 18998 | * src/output.c (output): Remove the initialization of the macro |
82e236e2 RA |
18999 | obstack. It was done too late here. |
19000 | ||
19001 | * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was | |
19002 | completely wrong. | |
19003 | (reader): Initialize the macro obstack here, since we need it to grow | |
19004 | '%define' directives. | |
19005 | ||
19006 | * src/reader.h: Declare the macro obstack as extern. | |
19007 | ||
b0cfa28a RA |
19008 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> |
19009 | ||
19010 | * src/output.c (output_parser): Fix. Store single '%' characters in | |
19011 | the output obstack instead of throwing them away. | |
19012 | ||
6fc74234 AD |
19013 | 2001-08-27 Akim Demaille <akim@epita.fr> |
19014 | ||
19015 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
19016 | ||
9c76d118 RA |
19017 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19018 | ||
19019 | * lib/Makefile.am: Adjust. | |
19020 | ||
a8289c62 RA |
19021 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19022 | ||
19023 | * src/bison.simple: Update and add '%%' directives. | |
19024 | ||
b6610515 RA |
19025 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19026 | ||
19027 | * src/reader.c (reader): Remove calls to 'output_headers' and | |
19028 | 'output_trailers'. Remove some C output. | |
19029 | (readgram): Disable a piece of code that was writing a default | |
19030 | definition for 'YYSTYPE'. | |
19031 | (reader_output_yylsp): Remove. | |
19032 | (packsymbols): Output token defintions to a macro. | |
19033 | (copy_definition): Disable C output. | |
6fc74234 | 19034 | |
b6610515 RA |
19035 | * src/reader.c (parse_macro_decl): New function used to parse macro |
19036 | declarations. | |
19037 | (copy_string2): Put the body of copy_string into this new function. | |
19038 | Add a parameter to let the caller choose whether he wants to copy the | |
19039 | string delimiters or not. | |
19040 | (copy_string): Be a simple call to copy_string2 with the last argument | |
19041 | bound to true. | |
19042 | (read_declarations): Add case for macro definition. | |
19043 | (copy_identifier): New. | |
6fc74234 | 19044 | (parse_macro_decl): Read macro identifiers using copy_identifier |
b6610515 RA |
19045 | rather than lex. |
19046 | ||
26f609ff RA |
19047 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19048 | ||
19049 | * src/output.c (prepare): Add prefixed names. | |
19050 | (output_parser): Output semantic actions. | |
19051 | (output_parser): Fix bug on '%%line' directives. | |
6fc74234 | 19052 | |
26f609ff RA |
19053 | * src/output.c (output_headers): Remove. The C code printed by this |
19054 | function should now be in the skeletons. | |
19055 | (output_trailers): Remove. | |
19056 | (output): Disable call to 'reader_output_yylsp'. | |
19057 | (output_rule_data): Do not output tables to the table obstack. | |
19058 | ||
19059 | * src/output.c: Remove some C dedicated output. | |
19060 | Improve the use of macro and output obstacks. | |
19061 | (output_defines): Remove. | |
6fc74234 | 19062 | |
26f609ff RA |
19063 | * src/output.c (output_token_translations): Associate 'translate' |
19064 | table with a macro. No output to the table obstack. | |
19065 | (output_gram): Same for 'rhs' and 'prhs'. | |
19066 | (output_stos): Same for 'stos'. | |
19067 | (output_rule_data): Same for 'r1' and 'r2'. | |
19068 | (token_actions): Same for 'defact'. | |
19069 | (goto_actions): Same for 'defgoto'. | |
19070 | (output_base): Same for 'pact' and 'pgoto'. | |
19071 | (output_table): Same for 'table'. | |
19072 | (output_check): Same for 'check'. | |
6fc74234 | 19073 | |
26f609ff RA |
19074 | * src/output.c (output_table_data): New function. |
19075 | (output_short_table): Remove. | |
19076 | (output_short_or_char_table): Remove. | |
6fc74234 | 19077 | |
26f609ff RA |
19078 | * src/output.c (output_parser): Replace most of the skeleton copy code |
19079 | with something new. Skeletons are now processed character by character | |
19080 | rather than line by line, and Bison looks for '%%' macros. This is the | |
19081 | first step in making Bison's output process (a lot) more flexible. | |
19082 | (output_parser): Use the macro table. | |
19083 | ||
6f43b113 RA |
19084 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19085 | ||
19086 | * src/main.c (main): Initialize the macro table. | |
19087 | ||
dd3127cf RA |
19088 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19089 | ||
19090 | * src/lex.c (percent_table): Add tok_define. | |
19091 | * src/lex.h: Add tok_define. | |
19092 | ||
aa321494 RA |
19093 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19094 | ||
19095 | * src/macrotab.c: New file. | |
19096 | * src/macrotab.h: New file. | |
19097 | * src/Makefile.am: Update. | |
19098 | ||
68bd3b6b RA |
19099 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
19100 | ||
19101 | * lib/hash.c: New file. | |
19102 | * lib/hash.h: New file. | |
19103 | * lib/Makefile.am: Update. | |
19104 | ||
45f8dd1e AD |
19105 | 2001-08-15 Akim Demaille <akim@epita.fr> |
19106 | ||
19107 | Version 1.28c. | |
19108 | ||
40a64a7a | 19109 | 2001-08-15 Marc Autret <autret_m@epita.fr> |
0b8afb77 AD |
19110 | |
19111 | * src/reader.c (readgram): Indent output macro YYSTYPE. | |
19112 | (packsymbols): Likewise. | |
19113 | (output_token_defines): Likewise. | |
19114 | * src/files.c: Standardize. | |
19115 | (compute_header_macro): New. | |
19116 | (defines_obstack_save): New. Use compute_header_macro. | |
19117 | (output_files): Update. Use defines_obstack_save. | |
19118 | ||
f9a8293a AD |
19119 | 2001-08-15 Akim Demaille <akim@epita.fr> |
19120 | ||
19121 | * doc/bison.texinfo (Table of Symbols): Document | |
19122 | YYSTACK_USE_ALLOCA. | |
19123 | ||
150ca7a7 AD |
19124 | 2001-08-15 Akim Demaille <akim@epita.fr> |
19125 | ||
19126 | * missing: Update from CVS Automake. | |
19127 | * config/config.guess, config/config.sub, config/texinfo.tex: | |
19128 | Update from gnu.org. | |
19129 | ||
69b5cec4 AD |
19130 | 2001-08-15 Akim Demaille <akim@epita.fr> |
19131 | ||
19132 | * Makefile.maint: Sync with CVS Autoconf. | |
19133 | ||
f2b5126e PB |
19134 | 2001-08-14 Pascal Bart <pascal.bart@epita.fr> |
19135 | ||
69b5cec4 | 19136 | * doc/bison.texinfo: Include GNU Free Documentation License from |
f2b5126e PB |
19137 | `fdl.texi'. |
19138 | * doc/fdl.texi: Add to package. | |
19139 | ||
4ecbf796 MA |
19140 | 2001-08-14 Marc Autret <autret_m@epita.fr> |
19141 | ||
19142 | Turn on %{source,header}_extension features. | |
19143 | ||
69b5cec4 | 19144 | * src/lex.c (percent_table): Un-CPP out header_extension and |
4ecbf796 MA |
19145 | source_extension. |
19146 | * src/files.c (compute_exts_from_gf): Compare pointers with NULL. | |
69b5cec4 | 19147 | (compute_exts_from_src): Remove conditions. It restores priorities |
4ecbf796 MA |
19148 | between options. |
19149 | ||
95fb5662 MA |
19150 | 2001-08-14 Marc Autret <autret_m@epita.fr> |
19151 | ||
19152 | * src/files.c (compute_base_names): Add extensions computing when | |
19153 | `--file-prefix' used. | |
19154 | Standardize function calls. | |
19155 | ||
78d09da9 MA |
19156 | 2001-08-13 Marc Autret <autret_m@epita.fr> |
19157 | ||
69b5cec4 | 19158 | * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users |
78d09da9 MA |
19159 | defining it (defined but null disables alloca). |
19160 | ||
5a009f2c MA |
19161 | 2001-08-13 Marc Autret <autret_m@epita.fr> |
19162 | ||
19163 | * src/bison.simple (_yy_memcpy): CPP reformat. | |
19164 | ||
1e41465a PB |
19165 | 2001-08-13 Pascal Bart <pascal.bart@epita.fr> |
19166 | ||
19167 | * tests/atconfig.in (CPPFLAGS): Fix. | |
19168 | ||
c67a198d PB |
19169 | 2001-08-10 Pascal Bart <pascal.bart@epita.fr> |
19170 | ||
79282c6c | 19171 | * doc/bison.texinfo: Include GNU General Public License from |
c67a198d PB |
19172 | `gpl.texi'. |
19173 | * doc/gpl.texi: Add to package. | |
19174 | ||
09a6de7e MA |
19175 | 2001-08-10 Marc Autret <autret_m@epita.fr> |
19176 | ||
19177 | * src/print_graph.h: Fix. | |
19178 | * src/reader.c (read_declarations): Use parse_header_extension_decl (). | |
19179 | ||
b77b9ee0 AD |
19180 | 2001-08-10 Akim Demaille <akim@epita.fr> |
19181 | ||
19182 | * src/system.h: Provide default declarations for stpcpy, strndup, | |
19183 | and strnlen. | |
19184 | ||
3e259915 MA |
19185 | 2001-08-10 Robert Anisko <anisko_r@epita.fr> |
19186 | ||
19187 | * doc/bison.texinfo (Locations): Update @$ stuff. | |
19188 | ||
ca96bc2d MA |
19189 | 2001-08-09 Robert Anisko <anisko_r@epita.fr> |
19190 | ||
19191 | * src/bison.simple (YYLLOC_DEFAULT): Update. | |
19192 | (yyparse): Adjust. | |
19193 | ||
fdc6758b MA |
19194 | 2001-08-08 Marc Autret <autret_m@epita.fr> |
19195 | ||
b77b9ee0 | 19196 | * doc/bison.texinfo: Change @samp{$<@dots{}>} to |
fdc6758b MA |
19197 | @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule. |
19198 | Reported by Fabrice Bauzac. | |
957d4dbf | 19199 | |
600cad3b MA |
19200 | 2001-08-08 Marc Autret <autret_m@epita.fr> |
19201 | ||
19202 | * src/vcg_default.h: Use NULL instead of 0 to initialize pointers. | |
19203 | * src/vcg.c (output_node): Fix. | |
19204 | * src/vcg.h: Cleanup. | |
19205 | * src/print_graph.c: Add comments. | |
b77b9ee0 | 19206 | (node_output_size): New global variable. Simplify the formatting of |
600cad3b | 19207 | the VCG graph output. |
b77b9ee0 | 19208 | (print_actions): Unused code is now used. It notifies the final state |
600cad3b | 19209 | and no action states in the VCG graph. It also give the reduce actions. |
b77b9ee0 | 19210 | The `shift and goto' edges are red and the `go to state' edges are |
600cad3b MA |
19211 | blue. |
19212 | Get the current node name and node_obstack by argument. | |
19213 | (node_obstack): New variable. | |
19214 | (print_state): Manage node_obstack. | |
19215 | (print_core): Use node_obstack given by argument. | |
19216 | A node is not only computed here but in print_actions also. | |
19217 | (print_graph): CPP out useless code instead of commenting it. | |
19218 | ||
976e528f AD |
19219 | 2001-08-07 Pascal Bart <pascal.bart@epita.fr> |
19220 | ||
19221 | * tests/atconfig.in (CPPFLAGS): Fix. | |
19222 | ||
20e8e5ca AD |
19223 | 2001-08-07 Akim Demaille <akim@epita.fr> |
19224 | ||
19225 | * src/print_graph.c (quote): New. | |
19226 | (print_core): Use it. | |
19227 | ||
957d4dbf | 19228 | 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr> |
3e3da797 | 19229 | |
3e3da797 AD |
19230 | * src/vcg.c (complain.h): Include it. |
19231 | Unepitaize `return' invocations. | |
c4b66126 | 19232 | [NDEBUG] (main): Remove. |
79282c6c | 19233 | * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members. |
c4b66126 AD |
19234 | * src/files.c (open_files): Initialize graph_obstack. |
19235 | * src/print_graph.c (print_actions): CPP out useless code. | |
19236 | (print_core): Don't output the last `\n' in labels. | |
19237 | Use `quote'. | |
19238 | * src/files.c (output_files): Output the VCG file. | |
19239 | * src/main.c (main): Invoke print_graph (); | |
3e3da797 | 19240 | |
957d4dbf | 19241 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
22c2cbc0 AD |
19242 | |
19243 | Automaton VCG graph output. | |
19244 | Using option ``-g'' or long option ``--graph'', you can generate | |
19245 | a gram_filename.vcg file containing a VCG description of the LALR (1) | |
19246 | automaton of your grammar. | |
19247 | ||
19248 | * src/main.c: Call to print_graph() function. | |
19249 | * src/getargs.h: Update. | |
19250 | * src/getargs.c (options): Update to catch `-g' and `--graph' options. | |
19251 | (graph_flag): New flag. | |
19252 | (longopts): Update. | |
19253 | (getargs): Add case `g'. | |
19254 | * src/files.c (graph_obstack): New obstack struct. | |
19255 | (open_files): Initialize new obstack. | |
19256 | (output_files): Saves graph_obstack if required. | |
19257 | * src/files.h (graph_obstack): New extern declaration. | |
19258 | * src/Makefile.am: Add new source files. | |
19259 | ||
927c1557 | 19260 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
ce4d5ce0 AD |
19261 | |
19262 | * src/print_graph.c, src/print_graph.h (graph): New. | |
19263 | * src/vcg.h: New file. | |
19264 | * src/vcg.c: New file, VCG graph handling. | |
19265 | ||
7333d403 AD |
19266 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
19267 | ||
19268 | Add of %source_extension and %header_extension which specify | |
19269 | the source or/and the header output file extension. | |
19270 | ||
19271 | * src/files.c (compute_base_names): Remove initialisation of | |
19272 | src_extension and header_extension. | |
19273 | (compute_exts_from_gf): Update. | |
19274 | (compute_exts_from_src): Update. | |
19275 | (output_files): Update. | |
19276 | * src/reader.c (parse_header_extension_decl): New. | |
19277 | (parse_source_extension_decl): New. | |
19278 | (read_declarations): New case statements for the new tokens. | |
19279 | * src/lex.c (percent_table): Add entries for %source_extension | |
19280 | and %header_extension. | |
19281 | * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext. | |
19282 | ||
84163231 AD |
19283 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
19284 | ||
19285 | * configure.in: Bump to 1.28c. | |
19286 | * doc/bison.texinfo: Texinfo thingies. | |
19287 | ||
8303fc42 AD |
19288 | 2001-08-04 Pascal Bart <pascal.bart@epita.fr> |
19289 | ||
19290 | * tests/atconfig.in (CPPFLAGS): Add. | |
19291 | * tests/calc.at (AT_CHECK): Use CPPFLAGS. | |
19292 | ||
70a84437 AD |
19293 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19294 | ||
19295 | Version 1.28b. | |
19296 | ||
2ce10144 AD |
19297 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19298 | ||
19299 | * tests/Makefile.am (check-local): Ship testsuite. | |
19300 | * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions. | |
19301 | Include `string.h'. | |
19302 | ||
1e3e4bc1 AD |
19303 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19304 | ||
19305 | * configure.in: Try using -Wformat when compiling. | |
19306 | ||
42b45b7f AD |
19307 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19308 | ||
19309 | * configure.in: Bump to 1.28b. | |
19310 | ||
8f13fe33 AD |
19311 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19312 | ||
19313 | * src/complain.c: Adjust strerror_r portability issues. | |
19314 | ||
b37ba92c AD |
19315 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19316 | ||
19317 | Version 1.28a. | |
19318 | ||
b0ce6046 AD |
19319 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19320 | ||
19321 | * src/getargs.c, src/getarg.h (skeleton)): Constify. | |
19322 | * src/lex.c (literalchar): Avoid name clashes on `buf'. | |
19323 | * src/getargs.c: Include complain.h. | |
19324 | * src/files.c, src/files.h (skeleton_find): Avoid name clashes. | |
19325 | * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1. | |
19326 | ||
d01c415b AD |
19327 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19328 | ||
19329 | * src/reader.c (readgram): Display hidden chars in error messages. | |
19330 | ||
459dd1a6 AD |
19331 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19332 | ||
19333 | Update to gettext 0.10.39. | |
19334 | ||
53b74c0c AD |
19335 | 2001-08-03 Akim Demaille <akim@epita.fr> |
19336 | ||
19337 | * lib/strspn.c: New. | |
19338 | ||
234a3be3 AD |
19339 | 2001-08-01 Marc Autret <autret_m@epita.fr> |
19340 | ||
19341 | * doc/bison.texinfo: Update. | |
19342 | * doc/bison.1 (mandoc): Update. | |
19343 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h. | |
19344 | * src/files.c: Support output files extensions computing. | |
19345 | (src_extension): New static variable. | |
19346 | (header_extension): New static variable. | |
19347 | (tr): New function. | |
19348 | (get_extension_index): New function, gets the index of an extension | |
19349 | filename in a string. | |
19350 | (compute_exts_from_gf): New function, computes extensions from the | |
19351 | grammar file extension. | |
19352 | (compute_exts_from_src): New functions, computes extensions from the | |
19353 | C source file extension, file given by ``-o'' option. | |
19354 | (compute_base_names): Update. | |
19355 | (output_files): Update. | |
19356 | ||
847bf1f5 AD |
19357 | 2001-08-01 Robert Anisko <anisko_r@epita.fr> |
19358 | ||
d995fee7 | 19359 | * doc/bison.texi: Document @$. |
847bf1f5 AD |
19360 | (Locations): New section. |
19361 | ||
d074a105 AD |
19362 | 2001-07-18 Akim Demaille <akim@epita.fr> |
19363 | ||
19364 | * Makefile.maint, GNUmakefile: New, from Autoconf 2.52. | |
19365 | * config/prev-version.txt, config/move-if-change: New. | |
19366 | * Makefile.am: Adjust. | |
19367 | ||
3419715d AD |
19368 | 2001-07-08 Pascal Bart <pascal.bart@epita.fr> |
19369 | ||
19370 | * src/bison.simple (yyparse): Suppress warning `comparaison | |
19371 | between signed and unsigned'. | |
19372 | ||
62ab6972 AD |
19373 | 2001-07-05 Pascal Bart <pascal.bart@epita.fr> |
19374 | ||
19375 | * src/getargs.h (raw_flag): Remove. | |
19376 | * src/getargs.c: Die on `-r'/`--raw'. | |
19377 | * src/lex.c (parse_percent_token): Die on `%raw'. | |
19378 | * src/reader.c (output_token_defines): Suppress call to `raw_flag'. | |
19379 | * tests/calc.at: Suppress test with option `--raw'. | |
19380 | ||
1e24cc5b AD |
19381 | 2001-07-14 Akim Demaille <akim@epita.fr> |
19382 | ||
19383 | * config/: New. | |
19384 | * configure.in: Require Autoconf 2.50. | |
19385 | Update to gettext 0.10.38. | |
19386 | ||
32dfccf8 AD |
19387 | 2001-03-16 Akim Demaille <akim@epita.fr> |
19388 | ||
19389 | * doc/bison.texinfo: ANSIfy the examples. | |
19390 | ||
cd5bd6ac AD |
19391 | 2001-03-16 Akim Demaille <akim@epita.fr> |
19392 | ||
19393 | * getargs.c (skeleton): New variable. | |
19394 | (longopts): --skeleton is a new option. | |
19395 | (shortopts, getargs): -S is a new option. | |
19396 | * getargs.h: Declare skeleton. | |
19397 | * output.c (output_parser): Use it. | |
19398 | ||
5141b016 AD |
19399 | 2001-03-16 Akim Demaille <akim@epita.fr> |
19400 | ||
19401 | * m4/strerror_r.m4: New. | |
19402 | * m4/error.m4: Run AC_FUNC_STRERROR_R. | |
19403 | * lib/error.h, lib/error.c: Update. | |
19404 | ||
447992b9 AD |
19405 | 2001-03-16 Akim Demaille <akim@epita.fr> |
19406 | ||
19407 | * src/getargs.c (longopts): Clean up. | |
19408 | ||
274d42ce AD |
19409 | 2001-02-21 Akim Demaille <akim@epita.fr> |
19410 | ||
19411 | * src/reader.c (gensym): `gensym_count' is your own. | |
19412 | Use a static buf to create the symbol name, as token_buffer is no | |
19413 | longer a buffer. | |
19414 | ||
22c821f3 AD |
19415 | 2001-02-08 Akim Demaille <akim@epita.fr> |
19416 | ||
19417 | * src/conflicts.c (conflict_report): Be sure not to append to res | |
19418 | between two calls, which could happen if both first sprintf were | |
19419 | skipped, but not the first cp += strlen. | |
19420 | ||
18569462 AD |
19421 | 2001-02-08 Akim Demaille <akim@epita.fr> |
19422 | ||
19423 | * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c: | |
19424 | New, from fileutils 4.0.37. | |
19425 | * configure.in: Require Autoconf 2.49c. I took some time before | |
19426 | making this decision. This is the only way out for portability | |
19427 | issues in Bison, it would mean way too much duplicate effort to | |
19428 | import in Bison features implemented in 2.49c since 2.13. | |
19429 | AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above. | |
19430 | ||
0d8f3c8a AD |
19431 | 2001-02-02 Akim Demaille <akim@epita.fr> |
19432 | ||
19433 | * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37. | |
66075dcf | 19434 | * lib/xalloc.h, lib/xmalloc.c: Update. |
0d8f3c8a | 19435 | |
f17bcd1f AD |
19436 | 2001-01-19 Akim Demaille <akim@epita.fr> |
19437 | ||
19438 | Get rid of the ad hoc handling of token_buffer in the scanner: use | |
19439 | the obstacks. | |
19440 | ||
19441 | * src/lex.c (token_obstack): New. | |
19442 | (init_lex): Initialize it. No longer call... | |
19443 | (grow_token_buffer): this. Remove it. | |
19444 | Adjust all the places which used it to use the obstack. | |
19445 | ||
511e79b3 AD |
19446 | 2001-01-19 Akim Demaille <akim@epita.fr> |
19447 | ||
19448 | * src/lex.h: Rename all the tokens: | |
19449 | s/\bENDFILE\b/tok_eof/g; | |
19450 | s/\bIDENTIFIER\b/tok_identifier/g; | |
19451 | etc. | |
19452 | Let them be enums, not #define, to ease debugging. | |
19453 | Adjust all the code. | |
19454 | ||
0d6508ef AD |
19455 | 2001-01-18 Akim Demaille <akim@epita.fr> |
19456 | ||
19457 | * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private. | |
19458 | * src/lex.c (maxtoken, grow_token_buffer): Static. | |
19459 | ||
6deb4447 AD |
19460 | 2001-01-18 Akim Demaille <akim@epita.fr> |
19461 | ||
19462 | Since we now use obstacks, more % directives can be enabled. | |
19463 | ||
19464 | * src/lex.c (percent_table): Also accept `%yacc', | |
19465 | `%fixed_output_files', `%defines', `%no_parser', `%verbose', and | |
19466 | `%debug'. | |
19467 | Handle the actions for `%semantic_parser' and `%pure_parser' here, | |
19468 | instead of returning a token. | |
19469 | * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused. | |
19470 | * src/reader.c (read_declarations): Adjust. | |
19471 | * src/files.c (open_files): Don't call `compute_base_names', don't | |
19472 | compute `attrsfile' since they depend upon data which might be | |
19473 | *in* the input file now. | |
19474 | (output_files): Do it here. | |
19475 | * src/output.c (output_headers): Document the fact that this patch | |
19476 | introduces a guaranteed SEGV for semantic parsers. | |
19477 | * doc/bison.texinfo: Document them. | |
19478 | * tests/suite.at: Exercise these %options. | |
19479 | ||
ff4423cc AD |
19480 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19481 | ||
19482 | Also handle the output file (--verbose) with obstacks. | |
19483 | ||
19484 | * files.c (foutput): Remove. | |
19485 | (output_obstack): New. | |
19486 | Adjust all dependencies. | |
19487 | * src/conflicts.c: Return a string. | |
19488 | * src/system.h (obstack_grow_string): Rename as... | |
19489 | (obstack_sgrow): this. Be ready to work with non literals. | |
19490 | (obstack_fgrow4): New. | |
19491 | ||
956dba3a AD |
19492 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19493 | ||
19494 | * src/files.c (open_files): Fix the computation of short_base_name | |
19495 | in the case of `-o foo.tab.c'. | |
19496 | ||
337bab46 AD |
19497 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19498 | ||
19499 | * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at) | |
19500 | (copy_dollar): Now that everything uses obstacks, get rid of the | |
19501 | FILE * parameters. | |
19502 | ||
5d3214b8 AD |
19503 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19504 | ||
19505 | * src/files.c (open_files): Actually the `.output' file is based | |
19506 | on the short_base_name, not base_name. | |
19507 | * tests/suite.at (Checking output file names): Adjust. | |
19508 | ||
29092a57 AD |
19509 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19510 | ||
19511 | * src/bison.s1: Remove, we now use directly... | |
19512 | * src/bison.simple: this. | |
19513 | * src/Makefile.am: Use pkgdata instead of data. | |
19514 | ||
ea5607fd AD |
19515 | 2000-12-20 Akim Demaille <akim@epita.fr> |
19516 | ||
19517 | * src/files.c (guard_obstack): New. | |
19518 | (open_files): Initialize it. | |
19519 | (output_files): Dump it... | |
19520 | * src/files.h: Export it. | |
19521 | * src/reader.c (copy_guard): Use it. | |
19522 | ||
27110317 AD |
19523 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19524 | ||
19525 | * src/files.c (outfile, defsfile, actfile): Removed as global | |
19526 | vars. | |
19527 | (open_files): Don't compute them. | |
19528 | (output_files): Adjust. | |
19529 | (base_name, short_base_name): Be global. | |
19530 | Adjust dependencies. | |
19531 | ||
19c50364 AD |
19532 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19533 | ||
19534 | * src/files.c (strsuffix): New. | |
19535 | (stringappend): Be just like strcat but allocate. | |
19536 | (base_names): Eve out from open_files. | |
19537 | Try to simplify the rather hairy computation of base_name and | |
19538 | short_base_name. | |
19539 | (open_files): Use it. | |
19540 | * tests/suite.at (Checking output file names): New test. | |
19541 | ||
573c1d9f AD |
19542 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19543 | ||
19544 | * src/system.h (obstack_grow_literal_string): Rename as... | |
19545 | (obstack_grow_string): this. | |
19546 | * src/output.c (output_parser): Recognize `%% actions' instead of | |
19547 | `$'. | |
19548 | * src/bison.s1: s/$/%% actions/. | |
19549 | * src/bison.hairy: Likewise. | |
19550 | ||
ef7ddedd AD |
19551 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19552 | ||
19553 | * src/output.c (output_parser): Compute the `#line' lines when | |
19554 | there are. | |
19555 | * src/Makefile.am (bison.simple): Be a simple copy of bison.s1. | |
19556 | Suggested by Hans Aberg. | |
19557 | ||
ff61dabd AD |
19558 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19559 | ||
19560 | Let the handling of the skeleton files be local to the procedures | |
19561 | that use it. | |
19562 | ||
19563 | * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No | |
19564 | longer static. | |
19565 | (fparser, open_extra_files): Remove. | |
19566 | (open_files, output_files): Don't take care of fparser. | |
19567 | * src/files.h: Adjust. | |
19568 | * src/output.c (output_parser): Open and close the file to the | |
19569 | skeleton. | |
19570 | * src/reader.c (read_declarations): When %semantic_parser, open | |
19571 | fguard. | |
19572 | ||
55b96341 AD |
19573 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19574 | ||
19575 | * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here... | |
19576 | * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here. | |
19577 | ||
358c15b7 AD |
19578 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19579 | ||
19580 | * src/files.c (open_files): Yipee! We no longer need all the code | |
19581 | looking for `/tmp' since we have no tmp file. | |
19582 | ||
7de3329e AD |
19583 | 2000-12-19 Akim Demaille <akim@epita.fr> |
19584 | ||
19585 | * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C): | |
19586 | New macros. | |
19587 | * src/files.c (open_files): Less dependency on MSDOS etc. | |
19588 | ||
3abcd459 AD |
19589 | 2000-12-14 Akim Demaille <akim@epita.fr> |
19590 | ||
19591 | * src/bison.s1 (YYLLOC_DEFAULT): New macro. | |
19592 | Provide a default definition. | |
19593 | Use it when executing the default @ action. | |
19594 | * src/reader.c (reader_output_yylsp): No longer include | |
19595 | `timestamp' and `text' in the default YYLTYPE. | |
19596 | ||
2a91a95e AD |
19597 | 2000-12-12 Akim Demaille <akim@epita.fr> |
19598 | ||
19599 | * src/reader.c (copy_definition, parse_union_decl, copy_action) | |
19600 | (copy_guard): Quote the file names. | |
19601 | Reported by Laurent Mascherpa. | |
19602 | ||
14d3eb9b AD |
19603 | 2000-12-12 Akim Demaille <akim@epita.fr> |
19604 | ||
19605 | * src/output.c (output_headers, output_program, output): Be sure | |
19606 | to escape special characters when outputting filenames. | |
19607 | (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove. | |
19608 | (output_headers): Don't depend on them, Use ACTSTR. | |
19609 | ||
d7045ec6 AD |
19610 | 2000-11-17 Akim Demaille <akim@epita.fr> |
19611 | ||
19612 | * lib/obstack.h: Formatting changes. | |
19613 | (obstack_grow, obstack_grow0): Don't cast WHERE at all: it | |
19614 | prevents type checking. | |
19615 | (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't | |
19616 | cast the value to (void *): assigning a `foo *' to a `void *' | |
19617 | variable is valid. | |
19618 | (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int. | |
19619 | * src/reader.c (parse_union_decl): Typo: use obstack_1grow to | |
19620 | append characters. | |
19621 | ||
6fd54b73 AD |
19622 | 2000-11-17 Akim Demaille <akim@epita.fr> |
19623 | ||
19624 | * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename | |
19625 | as... | |
19626 | (suite.m4, regression.m4, calc.m4): these. | |
19627 | * tests/atgeneral.m4: Update from CVS Autoconf. | |
19628 | ||
4c50eae6 AD |
19629 | 2000-11-17 Akim Demaille <akim@epita.fr> |
19630 | ||
19631 | * tests/regression.m4 (%union and --defines): New test, | |
19632 | demonstrating a current bug in the obstack implementation. | |
19633 | ||
a35f64ea AD |
19634 | 2000-11-17 Akim Demaille <akim@epita.fr> |
19635 | ||
19636 | * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New | |
19637 | macros. | |
19638 | Use them to declare the variables which are global or local to | |
19639 | `yyparse'. | |
19640 | ||
7de23534 AD |
19641 | 2000-11-17 Akim Demaille <akim@epita.fr> |
19642 | ||
19643 | * acconfig.h: Remove, no longer used. | |
19644 | ||
aa7815f5 AD |
19645 | 2000-11-07 Akim Demaille <akim@epita.fr> |
19646 | ||
19647 | * src: s/Copyright (C)/Copyright/g. | |
19648 | ||
5af1f549 AD |
19649 | 2000-11-07 Akim Demaille <akim@epita.fr> |
19650 | ||
19651 | * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just | |
19652 | defining. | |
19653 | * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/. | |
19654 | ||
553e2b22 AD |
19655 | 2000-11-07 Akim Demaille <akim@epita.fr> |
19656 | ||
19657 | * src/bison.s1 (YYLEX): Use #if instead of #ifdef. | |
19658 | Merge in a single CPP if/else. | |
19659 | ||
8a4f41d6 AD |
19660 | 2000-11-07 Akim Demaille <akim@epita.fr> |
19661 | ||
19662 | * src/output.c (output): Remove useless variables. | |
19663 | * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second | |
19664 | argument `data' for consistency with the prototypes. | |
19665 | Qualify it `const'. | |
19666 | (obstack_copy, obstack_copy0): Rename the second argument as | |
19667 | `address' for consistency. Qualify it `const'. | |
19668 | * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow) | |
19669 | (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify | |
19670 | `const' their input argument (`data' or `address'). | |
19671 | Adjust the corresponding macros to include `const' in casts. | |
19672 | ||
095a3fb5 AD |
19673 | 2000-11-03 Akim Demaille <akim@epita.fr> |
19674 | ||
19675 | * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/. | |
19676 | s/PFILE1/BISON_HAIRY/. | |
19677 | Adjust dependencies. | |
19678 | ||
d1cdce7c AD |
19679 | 2000-11-03 Akim Demaille <akim@epita.fr> |
19680 | ||
090c5ebf | 19681 | For some reason, this was not applied. |
d1cdce7c AD |
19682 | |
19683 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
19684 | `unlink': it's no longer used. | |
19685 | ||
9311529b AD |
19686 | 2000-11-03 Akim Demaille <akim@epita.fr> |
19687 | ||
19688 | * src/files.c (skeleton_find): New function, eved out of... | |
19689 | (open_files, open_extra_files): here. | |
19690 | ||
d8880f69 AD |
19691 | 2000-11-03 Akim Demaille <akim@epita.fr> |
19692 | ||
19693 | Don't use `atexit'. | |
19694 | ||
19695 | * src/files.c (obstack_save): New function. | |
19696 | (done): Rename as... | |
19697 | (output_files): this. | |
19698 | Use `obstack_save'. | |
19699 | * src/main.c (main): Don't use `atexit' to register `done', since | |
19700 | it no longer has to remove tmp files, just call `output_files' | |
19701 | when there are no errors. | |
19702 | ||
0dbb648e AD |
19703 | 2000-11-02 Akim Demaille <akim@epita.fr> |
19704 | ||
19705 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
19706 | `unlink': it's no longer used. | |
19707 | * src/files.h: Formatting changes. | |
19708 | ||
896fe5c1 AD |
19709 | 2000-11-02 Akim Demaille <akim@epita.fr> |
19710 | ||
19711 | Remove the last uses of mktemp and unlink/delete. | |
19712 | ||
19713 | * src/files.c (fdefines, ftable): Removed. | |
19714 | (defines_ostack, table_obstack): New. | |
19715 | Adjust dependencies of the former into uses of the latter. | |
19716 | * src/output.c (output_short_or_char_table, output_short_table): | |
19717 | Convert to using obstacks. | |
19718 | * src/reader.c (copy_comment2): Accept one FILE * and two | |
19719 | obstacks. | |
19720 | (output_token_defines, reader_output_yylsp): Use obstacks. | |
19721 | * src/system.h (obstack_fgrow3): New. | |
1f65350a | 19722 | * po/POTFILES.in: Adjust. |
896fe5c1 | 19723 | |
dd60faec AD |
19724 | 2000-11-01 Akim Demaille <akim@epita.fr> |
19725 | ||
19726 | Change each use of `fattrs' into a use of `attrs_obstack'. | |
19727 | ||
19728 | * src/reader.c (copy_at): Typo: s/yylloc/yyloc/. | |
19729 | * src/files.c (fattrs): Remove. | |
19730 | (attrs_obstack): New. | |
19731 | Adjust all dependencies. | |
19732 | (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile. | |
19733 | ||
8c7ebe49 AD |
19734 | 2000-11-01 Akim Demaille <akim@epita.fr> |
19735 | ||
19736 | Introduce obstacks. | |
19737 | Change each use of `faction' into a use of `action_obstack'. | |
19738 | ||
19739 | * lib/obstack.h, lib/obstack.c: New files. | |
19740 | * src/files.c (faction): Remove. | |
19741 | (action_obstack): New. | |
19742 | Adjust all dependencies. | |
19743 | ||
77aee789 AD |
19744 | 2000-10-20 Akim Demaille <akim@epita.fr> |
19745 | ||
19746 | * lib/quote.h (PARAMS): New macro. Use it. | |
19747 | ||
43591cec AD |
19748 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19749 | ||
19750 | * src/output.c (output_short_or_char_table): New function. | |
19751 | (output_short_table, output_token_translations): Use it. | |
19752 | (goto_actions): Use output_short_table. | |
19753 | ||
1e9798d5 AD |
19754 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19755 | ||
19756 | * src/symtab.c (bucket_new): New function. | |
19757 | (getsym): Use it. | |
19758 | ||
19759 | * src/output.c (output_short_table): New argument to display the | |
19760 | comment associated with the table. | |
19761 | Adjust dependencies. | |
19762 | (output_gram): Use it. | |
19763 | (output_rule_data): Nicer output layout for YYTNAME. | |
19764 | ||
f282676b AD |
19765 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19766 | ||
19767 | * src/lex.c (read_typename): New function. | |
19768 | (lex): Use it. | |
19769 | * src/reader.c (copy_dollar): Likewise. | |
19770 | ||
550a72a3 AD |
19771 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19772 | ||
19773 | * src/reader.c (copy_comment2): Expect the input stream to be on | |
19774 | the `/' which is suspected to open a comment, instead of being | |
19775 | called after `//' or `/*' was read. | |
19776 | (copy_comment, copy_definition, parse_union_decl, copy_action) | |
19777 | (copy_guard): Adjust. | |
19778 | ||
131e2fef AD |
19779 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19780 | ||
19781 | * src/reader.c (parse_expect_decl): Use `skip_white_space' and | |
19782 | `read_signed_integer'. | |
19783 | ||
79282c5a AD |
19784 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19785 | ||
19786 | * src/reader.c (copy_dollar): New function. | |
19787 | (copy_guard, copy_action): Use it. | |
19788 | ||
ff4a34be AD |
19789 | 2000-10-16 Akim Demaille <akim@epita.fr> |
19790 | ||
19791 | * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c: | |
19792 | * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4: | |
19793 | New files, from Fileutils 4.0.27. | |
19794 | * src/main.c (printable_version): Remove. | |
19795 | * src/lex.c, src/reader.c: Use `quote'. | |
19796 | ||
19797 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
19798 | ||
19799 | * lib/error.c, lib/error.h: New files, needed by xmalloc.c. | |
19800 | ||
14ded682 AD |
19801 | 2000-10-04 Akim Demaille <akim@epita.fr> |
19802 | ||
19803 | * doc/bison.texinfo: Various typos spotted by Neil Booth. | |
19804 | ||
8e03724b AD |
19805 | 2000-10-04 Akim Demaille <akim@epita.fr> |
19806 | ||
19807 | When a literal string is used to define two different tokens, | |
19808 | `bison -v' segfaults. | |
19809 | Reported by Piotr Gackiewicz, and fixed by Neil Booth. | |
19810 | ||
19811 | * tests/regression.m4: New file. | |
19812 | Include the core of the sample provided by Piotr Gackiewicz. | |
19813 | * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed | |
19814 | properly. | |
19815 | ||
a9e64249 AD |
19816 | 2000-10-04 Akim Demaille <akim@epita.fr> |
19817 | ||
19818 | * src/reader.c (parse_expect_decl): Keep `count' within the size | |
19819 | of `buffer'. | |
19820 | From Neil Booth. | |
19821 | ||
da9abf43 AD |
19822 | 2000-10-02 Paul Eggert <eggert@twinsun.com> |
19823 | ||
19824 | * bison.s1 (yyparse): Assign the default value | |
19825 | unconditionally, to avoid a GCC warning and make the parser a | |
19826 | tad smaller. | |
19827 | ||
c33638bb AD |
19828 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19829 | ||
19830 | * src/getargs.c (getargs): Don't dump `--help' on unrecognized | |
19831 | options. | |
19832 | ||
444c570a AD |
19833 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19834 | ||
19835 | * src/derives.c, src/print.c, src/reduce.c: To ease the | |
19836 | translation, move some `\n' out of the translated strings. | |
19837 | ||
89cab50d AD |
19838 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19839 | ||
19840 | The location tracking mechanism is precious for parse error | |
19841 | messages. Nevertheless, it is enabled only when `@n' is used in | |
19842 | the grammar, which is a different issue (you can use it in error | |
19843 | message, but not in the grammar per se). Therefore, there should | |
19844 | be another means to enable it. | |
19845 | ||
19846 | * src/getargs.c (getargs): Support `--locations'. | |
19847 | (usage): Report it. | |
19848 | * src/getargs.h (locationsflag): Export it. | |
19849 | * src/lex.c (percent_table): Support `%locations'. | |
19850 | * src/reader.c (yylsp_needed): Remove this variable, now replaced | |
19851 | with `locationsflag'. | |
19852 | * doc/bison.texinfo: Document `--locations' and `%locations'. | |
19853 | Sort the options. | |
19854 | * tests/calc.m4: Test it. | |
19855 | ||
19856 | For regularity of the names, replace each | |
19857 | (nolineflag, toknumflag, rawtokenumflag, noparserflag): with... | |
19858 | (no_lineflag, token_tableflag, rawflag, no_parserflag): this. | |
19859 | In addition replace each `flag' with `_flag'. | |
19860 | ||
d6c2cba0 AD |
19861 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19862 | ||
19863 | Also test parse error messages, including with YYERROR_VERBOSE. | |
19864 | ||
19865 | * tests/calc.m4 (calc.y): Add support for `exp = exp' (non | |
19866 | associative). | |
19867 | Use it to check the computations. | |
19868 | Use it to check `nonassoc' is honored. | |
19869 | (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed | |
19870 | `--yyerror-verbose'. | |
19871 | (_AT_CHECK_CALC): Adjust to this option. | |
19872 | (_AT_CHECK_CALC_ERROR): New macro to check parse error messages. | |
19873 | ||
5a35a6cb AD |
19874 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19875 | ||
19876 | Test also `--verbose', `--defines' and `--name-prefix'. Testing | |
19877 | the latter demonstrates a flaw in the handling of non debugging | |
19878 | parsers introduced by myself on 2000-03-16: `#define yydebug 0' | |
19879 | was used in order to simplify: | |
19880 | ||
19881 | #if YYDEBUG | |
19882 | if (yydebug) | |
19883 | { | |
19884 | ... | |
19885 | } | |
19886 | #endif | |
19887 | ||
19888 | into | |
19889 | ||
19890 | if (yydebug) | |
19891 | { | |
19892 | ... | |
19893 | } | |
19894 | ||
19895 | unfortunately this leads to a CPP conflict when | |
19896 | `--name-prefix=foo' is used since it produces `#define yydebug | |
19897 | foodebug'. | |
19898 | ||
19899 | * src/bison.s1 [!YYDEBUG]: Do not define yydebug. | |
19900 | (YYDPRINTF): New macro. | |
19901 | Spread its use. | |
19902 | * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from | |
19903 | the bison options. | |
19904 | Also test `--verbose', `--defines' and `--name-prefix'. | |
19905 | ||
71da9eea AD |
19906 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19907 | ||
19908 | Improve the readability of the produced parsers. | |
19909 | ||
19910 | * src/bison.s1: Formatting changes. | |
19911 | Improve the comment related to the `$' mark. | |
19912 | (yydefault): Don't fall through to `yyresume': `goto' there. | |
19913 | * src/output.c (output_parser): When the `$' is met, skip the end | |
19914 | of its line. | |
19915 | New variable, `number_of_dollar_signs', to check there's exactly | |
19916 | one `$' in the parser skeleton. | |
19917 | ||
95e36146 AD |
19918 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19919 | ||
19920 | * lib/xstrdup.c: New file, from the fileutils. | |
19921 | * src/reader.c (parse_token_decl, get_type_name, parse_type_decl) | |
19922 | (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup' | |
19923 | instead of strlen + xmalloc + strcpy. | |
19924 | * src/symtab.c (copys): Remove, use xstrdup instead. | |
19925 | ||
d7020c20 AD |
19926 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19927 | ||
19928 | * src/gram.h (associativity): New enum type which replaces the | |
19929 | former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with | |
19930 | `right_assoc', `left_assoc' and `non_assoc'. | |
19931 | Adjust all dependencies. | |
19932 | * src/reader.c: Formatting changes. | |
19933 | (LTYPESTR): Don't define it, use it as a literal in | |
19934 | `reader_output_yylsp'. | |
19935 | * src/symtab.h (symbol_class): New enum type which replaces the | |
19936 | former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with | |
19937 | `sunknown', `stoken and `snterm'. | |
19938 | ||
1916f98e AD |
19939 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19940 | ||
19941 | * src/getargs.c (fixed_outfiles): Rename as... | |
19942 | (yaccflag): for consistency and accuracy. | |
19943 | Adjust dependencies. | |
19944 | ||
d7913476 AD |
19945 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19946 | ||
19947 | Use the more standard files `xalloc.h' and `xmalloc.c' instead of | |
19948 | Bison's `allocate.c' and `alloc.h'. This patch was surprisingly | |
19949 | difficult and introduced a lot of core dump. It turns out that | |
19950 | Bison used an implementation of `xmalloc' based on `calloc', and | |
19951 | at various places it does depend upon the initialization to 0. I | |
19952 | have not tried to isolate the pertinent places, and all the former | |
19953 | calls to Bison's `xmalloc' are now using `XCALLOC'. Someday, | |
19954 | someone should address this issue. | |
19955 | ||
19956 | * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove. | |
19957 | * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New | |
19958 | files. | |
19959 | Adjust dependencies. | |
19960 | * src/warshall.h: New file. | |
19961 | Propagate. | |
19962 | ||
340ef489 AD |
19963 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19964 | ||
19965 | Various anti-`extern in *.c' changes. | |
19966 | ||
19967 | * src/system.h: Include `assert.h'. | |
19968 | ||
b2ca4022 AD |
19969 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19970 | ||
19971 | * src/state.h (nstates, final_state, first_state, first_shift) | |
19972 | (first_reduction): Move their exportation from here... | |
19973 | * src/LR0.h: to here. | |
19974 | Adjust dependencies. | |
19975 | * src/getargs.c (statisticsflag): New variable. | |
19976 | Add support for `--statistics'. | |
19977 | Adjust dependencies. | |
19978 | ||
19979 | Remove a lot of now useless `extern' statements in most files. | |
19980 | ||
403b315b AD |
19981 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19982 | ||
19983 | * src/LR0.h: New file. | |
19984 | Propagate its use. | |
19985 | ||
07a58c13 AD |
19986 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19987 | ||
19988 | * src/print.h: New file. | |
19989 | Propagate its use. | |
19990 | * src/print.c: Formatting and ordering changes. | |
19991 | (verbose, terse): Replace with... | |
19992 | (print_results): this new function. | |
19993 | Adjust dependencies. | |
19994 | ||
0619caf0 AD |
19995 | 2000-10-02 Akim Demaille <akim@epita.fr> |
19996 | ||
19997 | * src/conflicts.c (conflict_report): New function. | |
19998 | (conflict_log, verbose_conflict_log): Replace with... | |
19999 | (print_conflicts): this function. | |
20000 | Adjust dependencies. | |
20001 | * src/conflicts.h: New file. | |
20002 | Propagate its inclusion. | |
20003 | ||
3519ec76 AD |
20004 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20005 | ||
20006 | * src/nullable.h: New file. | |
20007 | Propagate its inclusion. | |
20008 | * src/nullable.c: Formatting changes. | |
20009 | ||
015acc48 AD |
20010 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20011 | ||
20012 | * src/reduce.h: New file. | |
20013 | Propagate its inclusion. | |
20014 | * src/reduce.c: Topological sort and other formatting changes. | |
20015 | (bool, TRUE, FALSE): Move their definition to... | |
20016 | * src/system.h: here. | |
20017 | ||
8963a27b AD |
20018 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20019 | ||
20020 | * src/files.c: Formatting changes. | |
20021 | (tryopen, tryclose, openfiles): Rename as... | |
20022 | (xfopen, xfclose, open_files): this. | |
20023 | (stringappend): static. | |
20024 | * src/files.h: Complete the list of exported symbols. | |
20025 | Propagate its use. | |
20026 | ||
a70083a3 AD |
20027 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20028 | ||
20029 | * src/reader.h: New file. | |
20030 | Propagate its use instead of tedious list of `extern' and | |
20031 | prototypes. | |
20032 | * src/reader.c: Formatting changes, topological sort, | |
20033 | s/register//. | |
20034 | ||
abadc117 AD |
20035 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20036 | ||
20037 | * src/lex.h: Prototype `lex.c' exported functions. | |
20038 | * src/reader.c: Adjust. | |
20039 | * src/lex.c: Formatting changes. | |
20040 | (safegetc): Rename as... | |
20041 | (xgetc): this. | |
20042 | ||
720d742f AD |
20043 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20044 | ||
20045 | * src/lalr.h: New file. | |
20046 | Propagate its inclusion instead of prototypes and `extern'. | |
20047 | * src/lalr.c: Formatting changes, topological sorting etc. | |
20048 | ||
f2acea59 AD |
20049 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20050 | ||
20051 | * src/output.c (token_actions): Introduce a temporary array, | |
20052 | YYDEFACT, that makes it possible for this function to use | |
20053 | output_short_table. | |
20054 | ||
d019d655 AD |
20055 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20056 | ||
20057 | `user_toknums' is output as a `short[]' in `output.c', while it is | |
20058 | defined as a `int[]' in `reader.c'. For consistency with the | |
20059 | other output tables, `user_toknums' is now defined as a table of | |
20060 | shorts. | |
20061 | ||
20062 | * src/reader.c (user_toknums): Be a short table instead of an int | |
20063 | table. | |
20064 | Adjust dependencies. | |
20065 | ||
20066 | Factor the short table outputs. | |
20067 | ||
20068 | * src/output.c (output_short_table): New function. | |
20069 | * src/output.c (output_gram, output_stos, output_rule_data) | |
20070 | (output_base, output_table, output_check): Use it. | |
20071 | ||
6c89f1c1 AD |
20072 | 2000-10-02 Akim Demaille <akim@epita.fr> |
20073 | ||
20074 | * src/output.c (output): Topological sort of the functions, in | |
20075 | order to get rid of the `static' prototypes. | |
20076 | No longer use `register'. | |
20077 | * src/output.h: New file. | |
20078 | Propagate its inclusion in files explicitly prototyping functions | |
20079 | from output.c. | |
20080 | ||
d9efd181 AD |
20081 | 2000-09-21 Akim Demaille <akim@epita.fr> |
20082 | ||
20083 | * src/atgeneral.m4: Update from Autoconf. | |
20084 | ||
c29240e7 | 20085 | 2000-09-21 Akim Demaille <akim@epita.fr> |
2fa6973e AD |
20086 | |
20087 | * src/closure.h: New file. | |
20088 | * src/closure.c: Formatting changes, topological sort over the | |
20089 | functions, use of closure.h. | |
20090 | (initialize_closure, finalize_closure): Rename as... | |
20091 | (new_closure, free_closure): these. Adjust dependencies. | |
20092 | * src/LR0.c: Formatting changes, topological sort, use of | |
20093 | cloture.h. | |
20094 | (initialize_states): Rename as... | |
20095 | (new_states): this. | |
20096 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
20097 | ||
499daa50 AD |
20098 | 2000-09-20 Akim Demaille <akim@epita.fr> |
20099 | ||
20100 | * src/acconfig.h: Don't protect config.h against multiple | |
20101 | inclusion. | |
20102 | Don't define PARAMS. | |
20103 | * src/system.h: Define PARAMS. | |
20104 | Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the | |
20105 | purpose of config.h. system.h must not try to fix wrong | |
20106 | definitions in config.h. | |
20107 | ||
cc84fd5d AD |
20108 | 2000-09-20 Akim Demaille <akim@epita.fr> |
20109 | ||
20110 | * src/derives.h: New file. | |
20111 | * src/main.c, src/derives.h: Use it. | |
20112 | Formatting changes. | |
20113 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
20114 | ||
db5b3a89 AD |
20115 | 2000-09-20 Akim Demaille <akim@epita.fr> |
20116 | ||
20117 | * tests/atgeneral.m4: Update from Autoconf. | |
20118 | * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC) | |
20119 | (AT_CHECK_CALC): New macros. | |
20120 | Use these macros to test bison with options `', `--raw', | |
20121 | `--debug', `--yacc', `--yacc --debug'. | |
20122 | ||
ceed8467 AD |
20123 | 2000-09-19 Akim Demaille <akim@epita.fr> |
20124 | ||
20125 | * src/output.c: Formatting changes. | |
20126 | * src/machine.h: Remove, leaving its contents in... | |
20127 | * src/system.h: here. | |
20128 | Include stdio.h. | |
20129 | Adjust all dependencies on stdio.h and machine.h. | |
20130 | * src/getargs.h: New file. | |
20131 | Let all `extern' declarations about getargs.c be replaced with | |
20132 | inclusion of `getargs.h'. | |
20133 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
20134 | ||
20135 | * tests/calc.m4 (yyin): Be initialized in main, not on the global | |
20136 | scope. | |
20137 | (yyerror): Returns void, not int. | |
20138 | * doc/bison.texinfo: Formatting changes. | |
20139 | ||
05a1d24b AD |
20140 | 2000-09-19 Akim Demaille <akim@epita.fr> |
20141 | ||
20142 | * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not | |
20143 | portable. | |
20144 | ||
cbd25751 AD |
20145 | 2000-09-18 Akim Demaille <akim@epita.fr> |
20146 | ||
20147 | * configure.in: Append WARNING_CFLAGS to CFLAGS. | |
20148 | * src/Makefile.am (INCLUDES): Don't. | |
20149 | Be ready to fetch headers in lib/. | |
20150 | ||
13863333 AD |
20151 | 2000-09-18 Akim Demaille <akim@epita.fr> |
20152 | ||
20153 | * doc/bison.texinfo: Update the copyright. | |
20154 | ANSIfy and GNUify the examples. | |
20155 | Remove the old menu. | |
20156 | ||
0d533154 AD |
20157 | 2000-09-18 Akim Demaille <akim@epita.fr> |
20158 | ||
20159 | First set of tests: use the `calc' example from the documentation. | |
20160 | ||
20161 | * src/bison.s1 (yyparse): Condition the code using `yytname' which | |
20162 | is defined only when YYDEBUG is. | |
20163 | * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13. | |
20164 | * src/files.c (tryopen, tryclose): Formatting changes. | |
20165 | Move to the top and be static. | |
20166 | * src/reader.c (read_signed_integer): Likewise. | |
20167 | * tests/calc.m4: New file. | |
20168 | * Makefile.am, suite.m4: Adjust. | |
20169 | * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY. | |
20170 | ||
e79137ac AD |
20171 | 2000-09-18 Akim Demaille <akim@epita.fr> |
20172 | ||
20173 | Add support for an Autotest test suite for Bison. | |
20174 | ||
20175 | * m4/m4.m4, m4/atconfig.m4: New files. | |
20176 | * m4/Makefile.am (EXTRA_DIST): Adjust. | |
20177 | * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New | |
20178 | files. | |
20179 | * src/getargs.c: Display a more standard --version message. | |
20180 | * src/reader.c (reader): Formatting changes. | |
20181 | No longer depend upon VERSION_STRING. | |
20182 | * configure.in: No longer use `dnl'. | |
20183 | Set up the test suite and the new directory `tests/. | |
20184 | (VERSION_STRING): Remove. | |
20185 | ||
27821bff AD |
20186 | 2000-04-14 Akim Demaille <akim@epita.fr> |
20187 | ||
20188 | * src/reader.c (copy_comment2): New function, same as former | |
20189 | `copy_comment', but outputs into two FILE *. | |
20190 | (copy_comment): Use it. | |
20191 | (parse_union_decl): Use it. | |
20192 | (get_type, parse_start_decl): Use the same `invalid' message. | |
20193 | (parse_start_decl, parse_union_decl): Use the same `multiple' | |
20194 | message. | |
20195 | (parse_union_decl, copy_guard, copy_action): Use the same | |
20196 | `unmatched' message. | |
20197 | * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'. | |
20198 | ||
cfe5fbc0 AD |
20199 | 2000-03-31 Akim Demaille <akim@epita.fr> |
20200 | ||
20201 | * src/files.c (tryopen, tryclose): Move to the top. | |
20202 | Be static. | |
20203 | ||
cb7db13e AD |
20204 | 2000-03-31 Akim Demaille <akim@epita.fr> |
20205 | ||
20206 | * src/main.c (main): Don't call `done', exit does it. | |
20207 | ||
a0f6b076 AD |
20208 | 2000-03-31 Akim Demaille <akim@epita.fr> |
20209 | ||
36281465 AD |
20210 | * allocate.c: s/return (foo)/return foo/. |
20211 | * lalr.c: Likewise. | |
20212 | * LR0.c: Likewise. | |
20213 | * output.c: Likewise. | |
20214 | * reader.c: Likewise. | |
20215 | * symtab.c: Likewise. | |
20216 | * vmsgetargs.c: Likewise. | |
20217 | ||
20218 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
20219 | ||
20220 | Clean up the error reporting functions. | |
a0f6b076 AD |
20221 | |
20222 | * src/report.c: New file. | |
20223 | * src/report.h: Likewise. | |
20224 | * src/Makefile.am: Adjust. | |
20225 | * m4/error.m4: New file. | |
20226 | * m4/Makefile.am: Adjust. | |
20227 | * configure.in (jm_PREREQ_ERROR): Call it. | |
20228 | * src/main.c (int_to_string, banner, fatal_banner, warn_banner): | |
20229 | Remove. | |
20230 | (fatal, fatals): Remove. All callers use complain.c::fatal. | |
20231 | (warn, warni, warns, warnss, warnss): Remove. All callers use | |
20232 | complain.c::complain. | |
20233 | (toomany): Remove, use fatal instead. | |
20234 | * src/files.c (done): No argument, use complain_message_count. | |
20235 | * src/main.c (main): Register `done' to `atexit'. | |
20236 | ||
20237 | * src/getargs.c (usage): More `fputs', less `fprintf'. | |
20238 | ||
18539825 AD |
20239 | 2000-03-28 Akim Demaille <akim@epita.fr> |
20240 | ||
20241 | * lib/: New directory. | |
20242 | * Makefile.am (SUBDIRS): Adjust. | |
20243 | * configure.in: Adjust. | |
20244 | (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's | |
20245 | useless. | |
20246 | * src/alloca.c: Moved to lib/. | |
20247 | * src/getopt.c: Likewise. | |
20248 | * src/getopt1.c: Likewise. | |
20249 | * src/getopt.h: Likewise. | |
20250 | * src/ansi2knr.c: Likewise. | |
20251 | * src/ansi2knr.1: Likewise. | |
20252 | * src/Makefile.am: Adjust. | |
20253 | * lib/Makefile.am: New file. | |
20254 | ||
9f306f2a AD |
20255 | 2000-03-28 Akim Demaille <akim@epita.fr> |
20256 | ||
20257 | * src/getargs.c (usage): Refresh the help message. | |
20258 | ||
0ba347b6 AD |
20259 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20260 | ||
20261 | * src/getopt1.c: Updated from textutils 2.0e | |
20262 | * src/getopt.c: Likewise. | |
20263 | * src/getopt.h: Likewise. | |
20264 | ||
dbe7f271 AD |
20265 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20266 | ||
20267 | * src/Makefile.am (bison.simple): Fix the awk program: quote only | |
20268 | the file name, not the whole `#line LINE FILE'. | |
20269 | ||
75bbe78d AD |
20270 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20271 | ||
20272 | On syntax errors, report the token on which we choked. | |
20273 | ||
aa5fd0ee AD |
20274 | * src/bison.s1 (yyparse): In the label yyerrlab, when |
20275 | YYERROR_VERBOSE, add yychar in msg. | |
75bbe78d | 20276 | |
7b306f52 AD |
20277 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20278 | ||
aa5fd0ee | 20279 | * src/reader.c (copy_at): New function. |
7b306f52 AD |
20280 | (copy_guard): Use it. |
20281 | (copy_action): Use it. | |
20282 | ||
e87b5700 AD |
20283 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20284 | ||
20285 | Be kind to translators, save some useless translations. | |
20286 | ||
aa5fd0ee | 20287 | * src/main.c (banner): New function. |
e87b5700 AD |
20288 | (fatal_banner): Use it. |
20289 | (warn_banner): Use it. | |
20290 | ||
ae3c3164 AD |
20291 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20292 | ||
aa5fd0ee AD |
20293 | * src/reader.c (copy_definition): Use copy_string and |
20294 | copy_comment. Removed now unused `match', `ended', | |
20295 | `cplus_comment'. | |
ae3c3164 AD |
20296 | (copy_comment, copy_string): Moved, to be visible from |
20297 | copy_definition. | |
20298 | ||
4dc58e7c AD |
20299 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20300 | ||
aa5fd0ee AD |
20301 | * src/reader.c (copy_string): Declare `static inline'. No |
20302 | problems with inline, since it is checked by configure. | |
4dc58e7c AD |
20303 | (copy_comment): Likewise. |
20304 | ||
0a6384c4 AD |
20305 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20306 | ||
aa5fd0ee | 20307 | * src/reader.c (packsymbols): Formatting changes. |
0a6384c4 | 20308 | |
3cef001a AD |
20309 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20310 | ||
aa5fd0ee | 20311 | * src/reader.c (copy_comment): New function, factored out from: |
3cef001a AD |
20312 | (copy_action): Use it. Removed now unused `match', `ended', |
20313 | `cplus_comment'. | |
20314 | (copy_guard): Likewise. | |
20315 | ||
ca36d2ef AD |
20316 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20317 | ||
aa5fd0ee | 20318 | * src/reader.c (copy_string): New function, factored out from: |
ca36d2ef AD |
20319 | (copy_action): Use it. |
20320 | (copy_guard): Likewise. | |
20321 | ||
6666f98f AD |
20322 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20323 | ||
20324 | Change the handling of @s so that they behave exactly like $s. | |
20325 | There is now a pseudo variable @$ (readble and writable), location | |
20326 | of the lhs of the rule (by default ranging from the location of | |
20327 | the first symbol of the rhs, to the location of the last symbol, | |
20328 | or, if the rhs is empty, YYLLOC). | |
20329 | ||
20330 | * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of | |
20331 | yyval. | |
20332 | (yyparse): When providing a default semantic action, provide a | |
20333 | default location action. | |
20334 | (after the $): No longer change `*YYLSP', just stack YYLOC the | |
20335 | same way you stack YYVAL. | |
20336 | * src/reader.c (read_declarations): Use warns. | |
20337 | (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'. | |
20338 | (copy_action, case '@'): Likewise. | |
20339 | Use a standard error message, to save useless work from | |
20340 | translators. | |
20341 | ||
41aca2e0 AD |
20342 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20343 | ||
aa5fd0ee AD |
20344 | * src/bison.s1: Formatting and cosmetics changes. |
20345 | * src/reader.c: Likewise. | |
41aca2e0 AD |
20346 | Update the Copyright notice. |
20347 | ||
dc08c1d5 AD |
20348 | 2000-03-17 Akim Demaille <akim@epita.fr> |
20349 | ||
aa5fd0ee AD |
20350 | * src/bison.s1 (#line): All set to `#line' only, since the |
20351 | Makefile now handles them. | |
dc08c1d5 | 20352 | |
9ee3c97b AD |
20353 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20354 | ||
20355 | * src/output.c (output_rule_data): Output the documentation of | |
20356 | some of the tables. | |
20357 | (Copyright notice): Update. | |
20358 | Formatting changes. | |
20359 | ||
0de741ca AD |
20360 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20361 | ||
20362 | * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to | |
20363 | remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough. | |
20364 | One `#if YYDEBUG' remains, since it uses variables which are | |
20365 | defined only if `YYDEBUG != 0'. | |
20366 | ||
bb10be54 AD |
20367 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20368 | ||
20369 | * src/bison.s1 (yyparse): Reorganize the definitions of the stacks | |
20370 | and related variables so that the similarities are highlighted. | |
20371 | ||
b07b484a AD |
20372 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20373 | ||
20374 | * src/bison.s1: Properly indent CPP directives. | |
20375 | ||
361f60b3 AD |
20376 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20377 | ||
20378 | * src/bison.s1: Properly indent the `alloca' CPP section. | |
20379 | ||
8c44d3ec AD |
20380 | 2000-03-16 Akim Demaille <akim@epita.fr> |
20381 | ||
20382 | Do not hard code values of directories in `configure.in'. | |
20383 | Update the `configure' tool chain. | |
20384 | ||
20385 | * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by | |
20386 | src/makefile.am. | |
20387 | (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED. | |
20388 | (AC_OUTPUT): Add m4/Makefile. | |
20389 | Bump to bison 1.28a, 1.29 has never been released. | |
20390 | * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are | |
20391 | handled via src/Makefile.am. | |
20392 | (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS, | |
20393 | HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by | |
20394 | autoheader. | |
20395 | * Makefile.am (SUBDIRS): Add m4. | |
20396 | (ACLOCAL_AM_FLAGS): New variable. | |
20397 | (AUTOMAKE_OPTIONS): Add check-news. | |
20398 | * src/Makefile.am (bison.simple): Use awk to replace #line lines with | |
20399 | the proper line number and file name. | |
20400 | (DEFS): Propagate the location of bison library files and of the | |
20401 | locale files. | |
20402 | (INCLUDES): Added `-I ..' so that one can compile with srcdir != | |
20403 | builddir. | |
20404 | * acinclude.m4: Remove, replaced by the directory m4. | |
20405 | * m4/Makefile.am (EXTRA_DIST): New variable. | |
20406 | * m4/gettext.m4: New file, from the fileutils. | |
20407 | * m4/lcmessage.m4: Likewise | |
20408 | * m4/progtest.m4: Likewise. | |
20409 | * m4/bison-decl.m4: New file, extracted from former acinclude.m4. | |
20410 | ||
f95997e7 AD |
20411 | 2000-03-10 Akim Demaille <akim@epita.fr> |
20412 | ||
20413 | * src/closure.c: | |
20414 | Formatting changes of various comments. | |
20415 | Respect the GNU coding standards at various places. | |
20416 | Don't use `_()' when no translation is needed. | |
20417 | ||
20418 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
20419 | ||
20420 | * src/files.c: | |
20421 | OS/2 honors TMPDIR environment variable. | |
20422 | ||
20423 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
20424 | ||
20425 | * doc/bison.texinfo: Tweaked spelling and grammar. | |
20426 | Updated ISBN. | |
20427 | Removed reference to price of printed copy. | |
20428 | Mention BISON_SIMPLE and BISON_HAIRY. | |
20429 | ||
20430 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
20431 | ||
20432 | * configure.in, NEWS: | |
20433 | Bison 1.29 released. | |
20434 | ||
20435 | 1999-10-27 Jesse Thilo <jthilo@gnu.org> | |
20436 | ||
20437 | * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex: | |
20438 | Added reference card. | |
20439 | ||
20440 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
20441 | ||
20442 | * po/ru.po: Added Russian translation. | |
20443 | ||
20444 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
20445 | ||
20446 | * configure.in: Added Russian translation. | |
20447 | ||
20448 | 1999-07-06 Jesse Thilo <jthilo@gnu.org> | |
20449 | ||
20450 | * configure.in, NEWS, README: | |
20451 | Released version 1.28. | |
20452 | ||
20453 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
20454 | ||
20455 | * src/system.h: | |
20456 | Squashed redefinition warning on some systems. | |
20457 | ||
20458 | * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c: | |
20459 | Have configure build version string instead of relying on ANSI string | |
20460 | concatentation. | |
20461 | ||
20462 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
20463 | ||
20464 | * po/POTFILES.in: Got rid of version.c. | |
20465 | ||
20466 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
20467 | ||
20468 | * acconfig.h, configure.in: | |
20469 | Have configure build version string instead of relying on ANSI string | |
20470 | concatentation. | |
20471 | ||
20472 | 1999-06-08 Jesse Thilo <jthilo@gnu.org> | |
20473 | ||
20474 | * doc/bison.1: | |
20475 | Dropped mention of `+' for long-named options. | |
20476 | ||
20477 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
20478 | ||
20479 | * src/files.c: Added <unistd.h> for unlink(). | |
20480 | ||
20481 | * src/Makefile.am, src/system.h: | |
20482 | I18n fixes. | |
20483 | ||
20484 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
20485 | ||
20486 | * README: Added a FAQ list. | |
20487 | ||
20488 | * configure.in, acconfig.h: | |
20489 | I18n fixes. | |
20490 | ||
20491 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
20492 | ||
20493 | * doc/FAQ, doc/Makefile.am: | |
20494 | Added a FAQ list. | |
20495 | ||
20496 | 1999-05-19 Jesse Thilo <jthilo@gnu.org> | |
20497 | ||
20498 | * src/alloc.h, src/symtab.h, src/version.c: | |
20499 | Protected inclusion of "config.h" with HAVE_CONFIG_H. | |
20500 | ||
20501 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
20502 | ||
20503 | * src/.cvsignore, src/Makefile.am: | |
20504 | Reorganized: sources in `src', documentation in `doc'. | |
20505 | ||
20506 | * src/lex.c (literalchar): | |
20507 | fixed the code for escaping double quotes (thanks | |
20508 | Jonathan Czisny.) | |
20509 | ||
20510 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
20511 | ||
20512 | * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in: | |
20513 | Adjusted paths to reflect directory reorganization. | |
20514 | ||
20515 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
20516 | ||
20517 | * doc/.cvsignore, doc/Makefile.am: | |
20518 | Reorganized: sources in `src', documentation in `doc'. | |
20519 | ||
20520 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
20521 | ||
20522 | * configure.in: | |
20523 | Updated AC_INIT file to reflect directory reorganization. | |
20524 | ||
20525 | * configure.in, .cvsignore, Makefile.am, POTFILES.in: | |
20526 | Reorganized: sources in `src', documentation in `doc'. | |
20527 | ||
20528 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
20529 | ||
20530 | * src/allocate.c: | |
20531 | Don't declare calloc() and realloc() if not necessary. | |
20532 | ||
20533 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
20534 | ||
20535 | * configure.in, acconfig.h, acinclude.m4: | |
20536 | Don't declare calloc() and realloc() if not necessary. | |
20537 | ||
20538 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
20539 | ||
20540 | * po/.cvsignore: Added i18n support. | |
20541 | ||
20542 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
20543 | ||
20544 | * acconfig.h, configure.in, Makefile.am: | |
20545 | Added i18n support. | |
20546 | ||
20547 | 1999-03-22 Jesse Thilo <jthilo@gnu.org> | |
20548 | ||
20549 | * src/bison.s1: Fixed #line numbers. | |
20550 | ||
20551 | 1999-03-15 Jesse Thilo <jthilo@gnu.org> | |
20552 | ||
20553 | * po/es.po, po/fr.po, po/nl.po, po/de.po: | |
20554 | Added PO files from Translation Project. | |
20555 | ||
20556 | 1999-03-03 Jesse Thilo <jthilo@gnu.org> | |
20557 | ||
20558 | * Makefile.am: | |
20559 | Added support for non-ANSI compilers (ansi2knr). | |
20560 | ||
20561 | 1999-02-16 Jesse Thilo <jthilo@gnu.org> | |
20562 | ||
20563 | * configure.in: Bumped version number to 1.27. | |
20564 | ||
20565 | * Makefile.am: | |
20566 | Added `bison.simple' to list of files removed by `make distclean'. | |
20567 | ||
20568 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
20569 | ||
20570 | * src/files.c, src/files.h: | |
20571 | Defined locations of parser files in config.h instead of Makefile. | |
20572 | ||
20573 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
20574 | ||
20575 | * acconfig.h, acinclude.m4, configure.in, Makefile.am: | |
20576 | Defined locations of parser files in config.h instead of Makefile. | |
20577 | ||
20578 | 1999-02-09 Jesse Thilo <jthilo@gnu.org> | |
20579 | ||
20580 | * Makefile.am: | |
20581 | Removed inappropriate use of $< macro. | |
20582 | ||
20583 | 1999-02-05 Jesse Thilo <jthilo@gnu.org> | |
20584 | ||
20585 | * po/Makefile.in.in, po/POTFILES.in: | |
20586 | Add `po' directory skeleton. | |
20587 | ||
20588 | 1999-01-27 Jesse Thilo <jthilo@gnu.org> | |
20589 | ||
20590 | * README: Document help-bison list. | |
20591 | ||
20592 | * configure.in: Add check for mkstemp(). | |
20593 | ||
20594 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
20595 | ||
20596 | * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c: | |
20597 | Hush a few compiler warnings. | |
20598 | ||
20599 | * src/files.c: | |
20600 | Add tryclose(), which verifies that fclose was successful. | |
20601 | Hush a couple of compiler warnings. | |
20602 | ||
20603 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
20604 | ||
20605 | * Makefile.am, OChangeLog: | |
20606 | ChangeLog is now automatically generated. Include the old version as | |
20607 | OChangeLog. | |
20608 | ||
20609 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
20610 | ||
20611 | * src/gram.h, src/lalr.c, src/lex.c, src/lex.h, src/machine.h, src/main.c, src/nullable.c, src/output.c, src/print.c, src/reader.c, src/reduce.c, src/state.h, src/symtab.c, src/symtab.h, src/types.h, src/vmsgetargs.c, src/warshall.c, src/allocate.c, src/alloc.h, src/bison.s1, src/closure.c, src/conflicts.c, src/derives.c, src/files.c, src/files.h, src/getargs.c, src/gram.c, src/LR0.c: | |
20612 | Update FSF address. | |
20613 | ||
20614 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
20615 | ||
20616 | * doc/bison.texinfo: Fix formatting glitch. | |
20617 | ||
20618 | * doc/bison.texinfo: Update FSF address. | |
20619 | ||
20620 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
20621 | ||
20622 | * acconfig.h: Update FSF address. | |
20623 | ||
20624 | 1999-01-08 Jesse Thilo <jthilo@gnu.org> | |
20625 | ||
20626 | * src/system.h: | |
20627 | Don't define PACKAGE here, since config.h defines it. | |
20628 | ||
20629 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
20630 | ||
20631 | * src/reader.c: Update copyright date. | |
20632 | ||
20633 | * src/main.c: | |
20634 | Ditch sprintf to statically-sized buffers in fatal/warn functions in | |
20635 | favor of output directly to stderr (avoids buffer overruns). | |
20636 | ||
20637 | * src/reader.c: Some checks for premature EOF. | |
20638 | ||
20639 | * src/allocate.c, src/alloc.h, src/closure.c, src/conflicts.c, src/derives.c, src/getargs.c, src/gram.c, src/lalr.c, src/lex.c, src/LR0.c, src/main.c, src/nullable.c, src/output.c, src/print.c, src/reduce.c, src/symtab.c, src/symtab.h, src/warshall.c: | |
20640 | Use prototypes if the compiler understands them. | |
20641 | ||
20642 | * src/files.c: Honor TMPDIR on Unix hosts. | |
20643 | Use prototypes if the compiler understands them. | |
20644 | ||
20645 | * src/reader.c: | |
20646 | Fix a couple of buffer overrun bugs. | |
20647 | Use prototypes if the compiler understands them. | |
20648 | ||
20649 | * src/system.h: Include unistd.h and ctype.h. | |
20650 | Use #ifdef instead of #if for NLS symbols. | |
20651 | ||
20652 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
20653 | ||
20654 | * doc/bison.texinfo: | |
20655 | Delete comment "consider using @set for edition number, etc..." since | |
20656 | we now are doing so. | |
20657 | ||
20658 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
20659 | ||
20660 | * configure.in: | |
20661 | Use prototypes if the compiler understands them. | |
20662 | ||
20663 | * NEWS: Document 1.26 highlights. | |
20664 | ||
20665 | * Makefile.am: Require Automake 1.3 or later. | |
20666 | ||
20667 | * acconfig.h: | |
20668 | Use prototypes if the compiler understands them. | |
20669 | ||
20670 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
20671 | ||
20672 | * src/version.c: | |
20673 | Use VERSION symbol from automake for version number. | |
20674 | ||
20675 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
20676 | ||
20677 | * acconfig.h, configure.in, version.cin: | |
20678 | Use VERSION symbol from automake for version number. | |
20679 | ||
20680 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
20681 | ||
20682 | * Makefile.am: | |
20683 | Distribute original version of simple parser (bison.s1), not built | |
20684 | version (bison.simple). | |
20685 | ||
20686 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
20687 | ||
20688 | * doc/bison.texinfo: Add info dir entry. | |
20689 | ||
20690 | * doc/bison.texinfo: | |
20691 | Let automake put version number into documentation. | |
20692 | ||
20693 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
20694 | ||
20695 | * src/bison.cld, src/build.com, src/vmshlp.mar: | |
20696 | Add non-RCS files from /gd/gnu/bison. | |
20697 | ||
20698 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
20699 | ||
20700 | * doc/bison.1: | |
20701 | Document the BISON_HAIRY and BISON_SIMPLE variables. | |
20702 | ||
20703 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
20704 | ||
20705 | * src/version.c: Build version.c automatically. | |
20706 | ||
20707 | * src/reader.c: | |
20708 | Fix token numbering (used to start at 258, not 257). | |
20709 | ||
20710 | * src/system.h: Include config.h. | |
20711 | ||
20712 | * src/getargs.c: Update bug report address. | |
20713 | ||
20714 | * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h: | |
20715 | Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org. | |
20716 | ||
20717 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
20718 | ||
20719 | * Makefile.am: | |
20720 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
20721 | ||
20722 | * configure.in, version.cin: | |
20723 | Build version.c automatically. | |
20724 | ||
20725 | * AUTHORS: Add AUTHORS file. | |
20726 | ||
20727 | * README: Update bug report address. | |
20728 | ||
20729 | * bison.simple: | |
20730 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
20731 | ||
20732 | * configure.in, Makefile.am, Makefile.in, stamp-h.in: | |
20733 | Add automake stuff. | |
20734 | ||
20735 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
20736 | ||
20737 | * doc/bison.texinfo: Clean up some formatting. | |
20738 | ||
20739 | 1998-05-05 Richard Stallman <rms@gnu.org> | |
20740 | ||
20741 | * doc/bison.texinfo: | |
20742 | Explain better why to make a pure parser. | |
20743 | ||
20744 | 1998-01-05 Richard Stallman <rms@gnu.org> | |
20745 | ||
20746 | * src/files.c (openfiles): | |
20747 | [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to | |
20748 | find a temporary directory, if possible. Do not unlink files while | |
20749 | they are open. | |
20750 | ||
20751 | 1997-08-25 Richard Stallman <rms@gnu.org> | |
20752 | ||
20753 | * src/reader.c (stack_offset;): | |
20754 | Change some warni to warns. | |
20755 | ||
20756 | * src/lex.c (literalchar): Use warns, not warni. | |
20757 | ||
20758 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
20759 | ||
20760 | * src/bison.s1: Add a Bison version comment. | |
20761 | ||
20762 | * src/main.c (fatal, warn, berror): | |
20763 | Use program_name. | |
20764 | ||
20765 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
20766 | ||
20767 | * Makefile.in (bison_version): New variable. | |
20768 | (dist): Use that variable. | |
20769 | (bison.s1): Substitute the Bison version into bison.simple. | |
20770 | ||
20771 | * bison.simple: Add a Bison version comment. | |
20772 | ||
20773 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
20774 | ||
20775 | * src/main.c (fatal, warn, berror): | |
20776 | Make error messages standard. | |
20777 | (toomany): Improve error message text. | |
20778 | ||
20779 | * src/LR0.c, src/closure.c, src/conflicts.c, src/derives.c, src/files.c, src/lalr.c, src/lex.c, src/nullable.c, src/output.c, src/print.c, src/reader.c, src/reduce.c, src/symtab.c: | |
20780 | new.h renamed to alloc.h. | |
20781 | ||
20782 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
20783 | ||
20784 | * Makefile.in: new.h renamed to alloc.h. | |
20785 | ||
20786 | 1997-05-24 Richard Stallman <rms@gnu.org> | |
20787 | ||
20788 | * src/lex.c (literalchar): | |
20789 | Fix the code for escaping \, " and '. | |
20790 | ||
20791 | (lex): Avoid trouble when there are many chars | |
20792 | to discard in a char literal with just several chars in it. | |
20793 | ||
20794 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
20795 | ||
20796 | * src/bison.s1: | |
20797 | Use malloc, if using alloca is troublesome. | |
20798 | (YYSTACK_USE_ALLOCA): New flag macro. | |
20799 | Define it for some systems and compilers. | |
20800 | (YYSTACK_ALLOC): New macro. | |
20801 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
20802 | If it was malloc'd, free it. | |
20803 | ||
20804 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
20805 | ||
20806 | * bison.simple: | |
20807 | Use malloc, if using alloca is troublesome. | |
20808 | (YYSTACK_USE_ALLOCA): New flag macro. | |
20809 | Define it for some systems and compilers. | |
20810 | (YYSTACK_ALLOC): New macro. | |
20811 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
20812 | If it was malloc'd, free it. | |
20813 | ||
20814 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
20815 | ||
20816 | * src/bison.s1: | |
20817 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
20818 | ||
20819 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
20820 | ||
20821 | * bison.simple: | |
20822 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
20823 | ||
20824 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
20825 | ||
20826 | * src/bison.s1: | |
20827 | [__hpux]: Include alloca.h (right for HPUX 10) | |
20828 | instead of declaring alloca (right for HPUX 9). | |
20829 | ||
20830 | * src/bison.s1 (__yy_memcpy): | |
20831 | Declare arg `count' as unsigned int. | |
20832 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
20833 | ||
20834 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
20835 | ||
20836 | * bison.simple: | |
20837 | [__hpux]: Include alloca.h (right for HPUX 10) | |
20838 | instead of declaring alloca (right for HPUX 9). | |
20839 | ||
20840 | * bison.simple (__yy_memcpy): | |
20841 | Declare arg `count' as unsigned int. | |
20842 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
20843 | ||
20844 | 1997-01-03 Richard Stallman <rms@gnu.org> | |
20845 | ||
20846 | * src/allocate.c: [__STDC__ or _MSC_VER]: | |
20847 | Declare calloc and realloc to return void *. | |
20848 | ||
20849 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
20850 | ||
20851 | * src/system.h: | |
20852 | [_MSC_VER]: Include stdlib.h and process.h. | |
20853 | [_MSC_VER] (getpid): Define as macro--translate it to _getpid. | |
20854 | ||
20855 | * src/main.c (main): Return FAILURE as a value. | |
20856 | (printable_version): Declare arg as int, not char. | |
20857 | ||
20858 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
20859 | ||
20860 | * Makefile.in (dist): | |
20861 | Explicitly check for symlinks, and copy them. | |
20862 | ||
20863 | 1996-12-19 Richard Stallman <rms@gnu.org> | |
20864 | ||
20865 | * src/files.c: | |
20866 | [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined. | |
20867 | ||
20868 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
20869 | ||
20870 | * src/bison.s1 (yyparse): | |
20871 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
20872 | declare yyparse to have a void * argument. | |
20873 | ||
20874 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
20875 | ||
20876 | * bison.simple (yyparse): | |
20877 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
20878 | declare yyparse to have a void * argument. | |
20879 | ||
20880 | 1996-12-17 Richard Stallman <rms@gnu.org> | |
20881 | ||
20882 | * src/reduce.c (nbits): Add some casts. | |
20883 | ||
20884 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
20885 | ||
20886 | * src/bison.s1: Test _MSDOS as well as _MSDOS_. | |
20887 | ||
20888 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
20889 | ||
20890 | * bison.simple: Test _MSDOS as well as _MSDOS_. | |
20891 | ||
20892 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
20893 | ||
20894 | * src/bison.s1: | |
20895 | [__sun && __i386]: Include alloca.h. | |
20896 | ||
20897 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
20898 | ||
20899 | * bison.simple: | |
20900 | [__sun && __i386]: Include alloca.h. | |
20901 | ||
20902 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
20903 | ||
20904 | * src/bison.s1: Comment change. | |
20905 | ||
20906 | * src/bison.s1: Test _MSDOS_, not MSDOS. | |
20907 | ||
20908 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
20909 | ||
20910 | * bison.simple: Comment change. | |
20911 | ||
20912 | * bison.simple: Test _MSDOS_, not MSDOS. | |
20913 | ||
20914 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
20915 | ||
20916 | * src/reduce.c, src/reader.c, src/print.c, src/output.c, src/nullable.c, src/lex.c, src/lalr.c, src/getargs.c, src/derives.c, src/conflicts.c, src/closure.c, src/allocate.c: | |
20917 | Insert `_' macro around many string constants. | |
20918 | ||
20919 | * src/main.c: | |
20920 | Insert `_' macro around many string constants. | |
20921 | ||
20922 | (main): Call setlocale, bindtextdomain and textdomain. | |
20923 | ||
20924 | * src/system.h: [HAVE_LOCALE_H]: Include locale.h. | |
20925 | [! HAVE_LOCALE_H] (setlocale): Define as no-op. | |
20926 | [ENABLE_NLS]: Include libintl.h. | |
20927 | [ENABLE_NLS] (gettext): Define. | |
20928 | [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions. | |
20929 | (N_, PACKAGE, LOCALEDIR): New macros. | |
20930 | ||
20931 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
20932 | ||
20933 | * POTFILES.in: New file. | |
20934 | ||
20935 | * Makefile.in (allocate.o): | |
20936 | Define target explicitly. | |
20937 | ||
20938 | * Makefile.in (CFLAGS): Set to @CFLAGS@. | |
20939 | (LDFLAGS): Set to @LDFLAGS@. | |
20940 | (configure): Run autoconf only if preceding `cd' succeeds. | |
20941 | (bison.s1): Redirect output to temporary file then move the | |
20942 | temporary to the target, rather than redirecting directly to bison.s1. | |
20943 | (clean): Remove config.status and config.log. | |
20944 | (distclean): Don't remove config.status here. | |
20945 | ||
20946 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
20947 | ||
20948 | * src/bison.s1: | |
20949 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
20950 | ||
20951 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
20952 | ||
20953 | * bison.simple: | |
20954 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
20955 | ||
20956 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
20957 | ||
20958 | * src/bison.s1 (__yy_memcpy): | |
20959 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
20960 | (yyparse): Calls changed accordingly. | |
20961 | ||
20962 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
20963 | ||
20964 | * Makefile.in (dist): Don't use $(srcdir). | |
20965 | ||
20966 | * bison.simple (__yy_memcpy): | |
20967 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
20968 | (yyparse): Calls changed accordingly. | |
20969 | ||
20970 | 1996-01-27 Richard Stallman <rms@gnu.org> | |
20971 | ||
20972 | * src/output.c (output_rule_data): | |
20973 | Test YYERROR_VERBOSE in the conditional | |
20974 | around the definition of ttyname. | |
20975 | ||
20976 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
20977 | ||
20978 | * src/bison.s1: | |
20979 | Fix line numbers in #line commands. | |
20980 | ||
20981 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
20982 | ||
20983 | * bison.simple: | |
20984 | Fix line numbers in #line commands. | |
20985 | ||
20986 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
20987 | ||
20988 | * src/bison.s1 (YYPARSE_PARAM_DECL): | |
20989 | In C++, make it always null. | |
20990 | (YYPARSE_PARAM_ARG): New macro. | |
20991 | (yyparse): Use YYPARSE_PARAM_ARG. | |
20992 | ||
20993 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
20994 | ||
20995 | * bison.simple (YYPARSE_PARAM_DECL): | |
20996 | In C++, make it always null. | |
20997 | (YYPARSE_PARAM_ARG): New macro. | |
20998 | (yyparse): Use YYPARSE_PARAM_ARG. | |
20999 | ||
21000 | 1995-11-29 Richard Stallman <rms@gnu.org> | |
21001 | ||
21002 | * doc/bison.texinfo: | |
21003 | Describe literal string tokens, %raw, %no_lines, %token_table. | |
21004 | ||
21005 | 1995-11-29 Daniel Hagerty <hag@gnu.org> | |
21006 | ||
21007 | * doc/bison.texinfo: Fixed update date | |
21008 | ||
21009 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
21010 | ||
21011 | * src/version.c: Version 1.25. | |
21012 | ||
21013 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
21014 | ||
21015 | * NEWS: *** empty log message *** | |
21016 | ||
21017 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
21018 | ||
21019 | * doc/bison.1, doc/bison.rnh: | |
21020 | Add new options. | |
21021 | ||
21022 | 1995-10-15 Richard Stallman <rms@gnu.org> | |
21023 | ||
21024 | * src/vmsgetargs.c, src/getargs.c: | |
21025 | Added -n, -k, and -raw switches. | |
21026 | (noparserflag, toknumflag, rawtoknumflag): New variables. | |
21027 | ||
21028 | * src/symtab.h (SALIAS): | |
21029 | New #define for adding aliases to %token. | |
21030 | (struct bucket): Added `alias' field. | |
21031 | ||
21032 | * src/reduce.c (reduce_grammar): | |
21033 | Revise error message. | |
21034 | (print_notices): Remove final `.' from error message. | |
21035 | ||
21036 | * src/reader.c (reader_output_yylsp): | |
21037 | New function. | |
21038 | (readgram): Use `#if 0' around code that accepted %command | |
21039 | inside grammar rules: The documentation doesn't allow it, | |
21040 | and it will fail since the %command processors scan for the next %. | |
21041 | (parse_token_decl): Extended the %token | |
21042 | declaration to allow a multi-character symbol as an alias. | |
21043 | (parse_thong_decl): New function. | |
21044 | (read_declarations): Added %thong declarations. | |
21045 | (read_declarations): Handle NOOP to deal with allowing | |
21046 | % declarations as another means to specify the flags. | |
21047 | (readgram): Allow %prec prior to semantics embedded in a rule. | |
21048 | (skip_to_char, read_declarations, copy_definition) | |
21049 | (parse_token_decl, parse_start_decl, parse_type_decl) | |
21050 | (parse_assoc_decl, parse_union_decl, parse_expect_decl) | |
21051 | (get_type_name, copy_guard, copy_action, readgram) | |
21052 | (get_type, packsymbols): Revised most error messages. | |
21053 | Changed `fatal' to `warnxxx' to avoid aborting for error. | |
21054 | Revised and use multiple warnxxx functions to avoid using VARARGS1. | |
21055 | (read_declarations): Improve the error message for | |
21056 | an invalid character. Do not abort. | |
21057 | (read_declarations, copy_guard, copy_action): Use | |
21058 | printable_version to avoid unprintable characters in printed output. | |
21059 | (parse_expect_decl): Error if argument to %expect exceeds 10 digits. | |
21060 | (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type): | |
21061 | Allow the type of a non-terminal can be given | |
21062 | more than once, as long as all specifications give the same type. | |
21063 | ||
21064 | * src/output.c: | |
21065 | (output_headers, output_trailers, output, output_gram) | |
21066 | (output_rule_data): Implement noparserflag variable. | |
21067 | Implement toknumflag variable. | |
21068 | (output): Call reader_output_yylsp to output LTYPESTR. | |
21069 | ||
21070 | * src/main.c (main): | |
21071 | If reader sees an error, don't process the grammar. | |
21072 | (fatals): Updated to not use VARARGS1. | |
21073 | (printable_version, int_to_string, warn, warni, warns, warnss) | |
21074 | (warnsss): New error reporting functions. Avoid abort for error. | |
21075 | ||
21076 | * src/lex.h: | |
21077 | Added THONG and NOOP for alias processing. | |
21078 | Added SETOPT for the new code that allows setting options with %flags. | |
21079 | ||
21080 | * src/lex.c: | |
21081 | Include getopt.h. Add some extern decls. | |
21082 | (safegetc): New function to deal with EOF gracefully. | |
21083 | (literalchar); new function to deal with reading \ escapes. | |
21084 | (lex): Use literalchar. | |
21085 | (lex): Implemented "..." tokens. | |
21086 | (literalchar, lex, parse_percent_token): Made tokenbuffer | |
21087 | always contain the token. This includes growing the token | |
21088 | buffer while reading an integer. | |
21089 | (parse_percent_token): Replaced if-else statement with percent_table. | |
21090 | (parse_percent_token): Added % declarations as another | |
21091 | way to specify the flags -n, -l, and -r. Also added hooks for | |
21092 | -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires | |
21093 | major changes to files.c. | |
21094 | (lex) Retain in the incoming stream a character following | |
21095 | an incorrect '/'. | |
21096 | (skip_white_space, lex): Revised most error messages | |
21097 | and changed fatal to warn to avoid aborting. | |
21098 | (percent_table): Added %thong declarations. | |
21099 | ||
21100 | * src/gram.h: Comment changes. | |
21101 | ||
21102 | * src/files.c (openfiles, open_extra_files, done): | |
21103 | Add faction flag | |
21104 | and actfile file. Handle noparserflag. Both for -n switch. | |
21105 | ||
21106 | * src/conflicts.c (resolve_sr_conflict): | |
21107 | Remove use of alloca. | |
21108 | ||
21109 | 1995-06-01 Jim Meyering <meyering@gnu.org> | |
21110 | ||
21111 | * doc/bison.texinfo: *** empty log message *** | |
21112 | ||
21113 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
21114 | ||
21115 | * src/bison.s1: Comment change. | |
21116 | ||
21117 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
21118 | ||
21119 | * bison.simple: Comment change. | |
21120 | ||
21121 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
21122 | ||
21123 | * src/version.c: Version now 1.24. | |
21124 | ||
21125 | * src/bison.s1: Change distribution terms. | |
21126 | ||
21127 | * src/version.c: Version now 1.23. | |
21128 | ||
21129 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
21130 | ||
21131 | * doc/bison.texinfo: | |
21132 | Rewrite "Conditions for Using Bison". | |
21133 | Update version to 1.24. | |
21134 | ||
21135 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
21136 | ||
21137 | * bison.simple: Change distribution terms. | |
21138 | ||
21139 | 1995-02-23 Richard Stallman <rms@gnu.org> | |
21140 | ||
21141 | * src/files.c: Test __VMS_POSIX as well as VMS. | |
21142 | ||
21143 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
21144 | ||
21145 | * src/bison.s1 (__yy_memcpy): | |
21146 | Renamed from __yy_bcopy to avoid | |
21147 | confusion. Reverse FROM and TO arguments to be consistent with | |
21148 | those of memcpy. | |
21149 | ||
21150 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
21151 | ||
21152 | * bison.simple (__yy_memcpy): | |
21153 | Renamed from __yy_bcopy to avoid | |
21154 | confusion. Reverse FROM and TO arguments to be consistent with | |
21155 | those of memcpy. | |
21156 | ||
21157 | 1994-11-10 David J. MacKenzie <djm@gnu.org> | |
21158 | ||
21159 | * NEWS: reformat | |
21160 | ||
21161 | * NEWS: New file. | |
21162 | ||
21163 | * Makefile.in (DISTFILES): Include NEWS. | |
21164 | ||
21165 | * Makefile.in (DISTFILES): | |
21166 | Include install-sh, not install.sh. | |
21167 | ||
21168 | * configure.in: Update to Autoconf v2 macro names. | |
21169 | ||
21170 | 1994-10-05 David J. MacKenzie <djm@gnu.org> | |
21171 | ||
21172 | * Makefile.in: fix typo | |
21173 | ||
21174 | * Makefile.in (prefix, exec_prefix): | |
21175 | Let configure set them. | |
21176 | ||
21177 | 1994-09-28 David J. MacKenzie <djm@gnu.org> | |
21178 | ||
21179 | * Makefile.in: Set datadir to $(prefix)/share. | |
21180 | ||
21181 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
21182 | ||
21183 | * src/bison.s1: | |
21184 | Update copyright notice and GPL version. | |
21185 | ||
21186 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
21187 | ||
21188 | * bison.simple: | |
21189 | Update copyright notice and GPL version. | |
21190 | ||
21191 | 1994-07-12 Richard Stallman <rms@gnu.org> | |
21192 | ||
21193 | * src/reduce.c, src/reader.c: | |
21194 | entered into RCS | |
21195 | ||
21196 | 1994-05-05 David J. MacKenzie <djm@gnu.org> | |
21197 | ||
21198 | * Makefile.in: entered into RCS | |
21199 | ||
21200 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
21201 | ||
21202 | * src/bison.s1: entered into RCS | |
21203 | ||
21204 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
21205 | ||
21206 | * bison.simple: entered into RCS | |
21207 | ||
21208 | 1994-03-25 Richard Stallman <rms@gnu.org> | |
21209 | ||
21210 | * src/main.c: entered into RCS | |
21211 | ||
21212 | 1994-03-24 Richard Stallman <rms@gnu.org> | |
21213 | ||
21214 | * src/conflicts.c: entered into RCS | |
21215 | ||
21216 | 1994-01-02 Richard Stallman <rms@gnu.org> | |
21217 | ||
21218 | * Makefile.in: *** empty log message *** | |
21219 | ||
21220 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
21221 | ||
21222 | * src/bison.s1: *** empty log message *** | |
21223 | ||
21224 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
21225 | ||
21226 | * doc/bison.texinfo: entered into RCS | |
21227 | ||
21228 | * doc/bison.texinfo: *** empty log message *** | |
21229 | ||
21230 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
21231 | ||
21232 | * bison.simple: *** empty log message *** | |
21233 | ||
21234 | 1993-10-25 David J. MacKenzie <djm@gnu.org> | |
21235 | ||
21236 | * doc/bison.texinfo: *** empty log message *** | |
21237 | ||
21238 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
21239 | ||
21240 | * src/bison.s1: *** empty log message *** | |
21241 | ||
21242 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
21243 | ||
21244 | * bison.simple: *** empty log message *** | |
21245 | ||
21246 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
21247 | ||
21248 | * src/bison.s1: *** empty log message *** | |
21249 | ||
21250 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
21251 | ||
21252 | * bison.simple: *** empty log message *** | |
21253 | ||
21254 | 1993-09-14 David J. MacKenzie <djm@gnu.org> | |
21255 | ||
21256 | * doc/bison.texinfo: *** empty log message *** | |
21257 | ||
21258 | 1993-09-13 Noah Friedman <friedman@gnu.org> | |
21259 | ||
21260 | * Makefile.in: *** empty log message *** | |
21261 | ||
21262 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
21263 | ||
21264 | * src/conflicts.c: *** empty log message *** | |
21265 | ||
21266 | * src/system.h: entered into RCS | |
21267 | ||
21268 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
21269 | ||
21270 | * doc/bison.1: entered into RCS | |
21271 | ||
21272 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
21273 | ||
21274 | * src/version.c: entered into RCS | |
21275 | ||
21276 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
21277 | ||
21278 | * Makefile.in: *** empty log message *** | |
21279 | ||
21280 | 1993-07-30 David J. MacKenzie <djm@gnu.org> | |
21281 | ||
21282 | * Makefile.in: *** empty log message *** | |
21283 | ||
21284 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
21285 | ||
21286 | * src/bison.s1: *** empty log message *** | |
21287 | ||
21288 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
21289 | ||
21290 | * bison.simple: *** empty log message *** | |
21291 | ||
21292 | 1993-07-08 David J. MacKenzie <djm@gnu.org> | |
21293 | ||
21294 | * Makefile.in: *** empty log message *** | |
21295 | ||
21296 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
21297 | ||
21298 | * src/bison.s1: *** empty log message *** | |
21299 | ||
21300 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
21301 | ||
21302 | * bison.simple: *** empty log message *** | |
21303 | ||
21304 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
21305 | ||
21306 | * src/getargs.c: entered into RCS | |
21307 | ||
21308 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
21309 | ||
21310 | * doc/bison.texinfo: *** empty log message *** | |
21311 | ||
21312 | * doc/bison.1: New file. | |
21313 | ||
21314 | 1993-06-25 Richard Stallman <rms@gnu.org> | |
21315 | ||
21316 | * src/getargs.c: New file. | |
21317 | ||
21318 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
21319 | ||
21320 | * src/bison.s1: *** empty log message *** | |
21321 | ||
21322 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
21323 | ||
21324 | * bison.simple: *** empty log message *** | |
21325 | ||
21326 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
21327 | ||
21328 | * src/bison.s1: New file. | |
21329 | ||
21330 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
21331 | ||
21332 | * doc/bison.texinfo: *** empty log message *** | |
21333 | ||
21334 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
21335 | ||
21336 | * bison.simple: New file. | |
21337 | ||
21338 | 1993-05-19 Richard Stallman <rms@gnu.org> | |
21339 | ||
21340 | * doc/bison.texinfo: New file. | |
21341 | ||
21342 | 1993-05-07 Noah Friedman <friedman@gnu.org> | |
21343 | ||
21344 | * Makefile.in: *** empty log message *** | |
21345 | ||
21346 | 1993-04-28 Noah Friedman <friedman@gnu.org> | |
21347 | ||
21348 | * src/reader.c: *** empty log message *** | |
21349 | ||
21350 | 1993-04-23 Noah Friedman <friedman@gnu.org> | |
21351 | ||
21352 | * src/alloc.h: entered into RCS | |
21353 | ||
21354 | 1993-04-20 David J. MacKenzie <djm@gnu.org> | |
21355 | ||
21356 | * src/version.c: *** empty log message *** | |
21357 | ||
21358 | * src/files.c, src/allocate.c: | |
21359 | entered into RCS | |
21360 | ||
21361 | * src/reader.c: *** empty log message *** | |
21362 | ||
21363 | * src/lex.c: entered into RCS | |
21364 | ||
21365 | * src/conflicts.c: New file. | |
21366 | ||
21367 | * src/symtab.c: entered into RCS | |
21368 | ||
21369 | * src/alloc.h: New file. | |
21370 | ||
21371 | * src/LR0.c: entered into RCS | |
21372 | ||
21373 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
21374 | ||
21375 | * src/reader.c: New file. | |
21376 | ||
21377 | * src/version.c: *** empty log message *** | |
21378 | ||
21379 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
21380 | ||
21381 | * Makefile.in: *** empty log message *** | |
21382 | ||
21383 | 1993-04-17 Noah Friedman <friedman@gnu.org> | |
21384 | ||
21385 | * Makefile.in: *** empty log message *** | |
21386 | ||
21387 | 1993-04-15 Richard Stallman <rms@gnu.org> | |
21388 | ||
21389 | * src/main.c, src/files.c: | |
21390 | New file. | |
21391 | ||
21392 | 1993-04-15 Noah Friedman <friedman@gnu.org> | |
21393 | ||
21394 | * configure.in: entered into RCS | |
21395 | ||
21396 | * configure.in: *** empty log message *** | |
21397 | ||
21398 | * configure.in: New file. | |
21399 | ||
21400 | 1993-04-14 Richard Stallman <rms@gnu.org> | |
21401 | ||
21402 | * Makefile.in: New file. | |
21403 | ||
21404 | 1993-04-13 Richard Stallman <rms@gnu.org> | |
21405 | ||
21406 | * src/version.c: New file. | |
21407 | ||
21408 | 1993-03-25 Richard Stallman <rms@gnu.org> | |
21409 | ||
21410 | * src/output.c: entered into RCS | |
21411 | ||
21412 | 1992-09-25 Richard Stallman <rms@gnu.org> | |
21413 | ||
21414 | * configure.bat: entered into RCS | |
21415 | ||
21416 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
21417 | ||
21418 | * src/vmsgetargs.c: entered into RCS | |
21419 | ||
21420 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
21421 | ||
21422 | * doc/bison.rnh: entered into RCS | |
21423 | ||
21424 | 1992-04-20 David J. MacKenzie <djm@gnu.org> | |
21425 | ||
21426 | * README: entered into RCS | |
21427 | ||
21428 | 1992-01-22 Richard Stallman <rms@gnu.org> | |
21429 | ||
21430 | * src/machine.h: entered into RCS | |
21431 | ||
21432 | 1991-12-21 Richard Stallman <rms@gnu.org> | |
21433 | ||
21434 | * src/lalr.c, src/closure.c: | |
21435 | entered into RCS | |
21436 | ||
21437 | 1991-12-20 Richard Stallman <rms@gnu.org> | |
21438 | ||
21439 | * src/state.h: entered into RCS | |
21440 | ||
21441 | 1991-12-18 Richard Stallman <rms@gnu.org> | |
21442 | ||
21443 | * src/print.c, src/nullable.c, src/derives.c: | |
21444 | entered into RCS | |
21445 | ||
21446 | 1991-11-03 David J. MacKenzie <djm@gnu.org> | |
21447 | ||
21448 | * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h: | |
21449 | entered into RCS | |
21450 | ||
21451 | 1988-09-09 Richard Stallman <rms@gnu.org> | |
21452 | ||
21453 | * src/bison.hairy: entered into RCS | |
21454 | ||
21455 | 1987-12-16 Richard Stallman <rms@gnu.org> | |
21456 | ||
21457 | * REFERENCES: entered into RCS | |
dc546b0f | 21458 | |
f294a2c2 | 21459 | |
04098407 | 21460 | ----- |
f294a2c2 | 21461 | |
04098407 | 21462 | Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996, |
9126263e | 21463 | 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 |
95021767 | 21464 | Free Software Foundation, Inc. |
f294a2c2 | 21465 | |
04098407 PE |
21466 | Copying and distribution of this file, with or without |
21467 | modification, are permitted provided the copyright notice and this | |
21468 | notice are preserved. |