]>
Commit | Line | Data |
---|---|---|
72f000b0 PE |
1 | 2005-04-17 Paul Eggert <eggert@cs.ucla.edu> |
2 | ||
3 | * NEWS: Bison-generated C parsers no longer quote literal strings | |
4 | associated with tokens. | |
5 | * src/output.c (prepare_symbols): Don't escape strings, | |
6 | since users don't want to see C escapes. | |
7 | * tests/calc.at (AT_CHECK_CALC): Adjust to lack of quotes | |
8 | in diagnostics. | |
9 | * tests/regression.at (Token definitions, Web2c Actions): Likewise. | |
10 | ||
1094323f PE |
11 | 2005-04-16 Paul Eggert <eggert@cs.ucla.edu> |
12 | ||
13 | * tests/torture.at (AT_INCREASE_DATA_SIZE): Skip the test if | |
14 | the data size is known to be too small and we can't increase it. | |
15 | This works around an HP-UX 11.00 glitch reported by Andrew Benham. | |
16 | ||
ca407bdf PE |
17 | 2005-04-15 Paul Eggert <eggert@cs.ucla.edu> |
18 | ||
19 | * src/parse-gram.y: Include quotearg.h. | |
20 | (string_as_id): Quote $1 before using it as a key, since the | |
21 | lexer no longer quotes it for us. | |
22 | (string_content): Don't strip quotes, since lexer no longer | |
23 | quotes it for us. | |
24 | * src/scan-gram.l: Include quotearg.h. | |
25 | ("\""): Omit quote. | |
26 | ("'"<SC_ESCAPED_CHARACTER>): Quote symbol before using it as | |
27 | a key, since the rest of the lexer doesn't quote it. | |
28 | * src/symtab.c (symbol_get): Don't quote symbol; caller does it now. | |
29 | * tests/regression.at (Token definitions): Check for backslashes | |
30 | in token strings. | |
31 | ||
32 | * data/yacc.c (YYSTACK_ALLOC_MAXIMUM): New macro. | |
33 | (YYSIZE_T): Define to unsigned long int when using an older compiler. | |
34 | (yyparse): Revamp code to generate long syntax error message, to | |
35 | make it easier to translate, and to avoid problems with arithmetic | |
36 | overflow. Change "virtual memory" to "memory" in diagnostic, since | |
37 | we don't know whether the memory is virtual. | |
38 | ||
1ce59070 PE |
39 | 2005-04-13 Paul Eggert <eggert@cs.ucla.edu> |
40 | ||
41 | * NEWS: Bison-generated C parsers now use the _ macro to | |
42 | translate strings. | |
43 | * data/yacc.c (_) [!defined _]: New macro. | |
44 | All English strings wrapped inside this macro. | |
45 | * doc/bison.texinfo (Bison Parser): Document _. | |
46 | * po/POTFILES.in: Include src/parse-gram.c, since it now | |
47 | includes translateable strings that parse-gram.y doesn't. | |
48 | ||
a749a695 PE |
49 | 2005-04-12 Paul Eggert <eggert@cs.ucla.edu> |
50 | ||
51 | * src/symtab.c (symbol_make_alias): Call symbol_type_set, | |
52 | reverting the 2004-10-11 change to this function. | |
53 | (symbol_check_alias_consistency): Don't call symbol_type_set | |
54 | if the type name is already correct. | |
55 | * tests/input.at (Typed symbol aliases): New test, from Tim Van Holder. | |
56 | ||
8fb1053b PE |
57 | 2005-03-25 Paul Eggert <eggert@cs.ucla.edu> |
58 | ||
59 | * tests/regression.at (Token definitions): Don't use a token named | |
60 | c, as that generates a "#define c ..." that runs afoul of buggy | |
61 | stdlib.h that uses the identifier c as a member of struct | |
62 | drand48_data. Problem reported by Horst Wente. | |
63 | ||
ff498c4a PE |
64 | 2005-03-21 Paul Eggert <eggert@cs.ucla.edu> |
65 | ||
66 | * bootstrap: Change translation URL from | |
67 | http://www2.iro.umontreal.ca/~gnutra/po/maint/bison/ to | |
68 | http://www.iro.umontreal.ca/translation/maint/bison/ to avoid | |
69 | redirection glitches. Problem reported by twlevo@xs4all.nl. | |
70 | ||
65211d70 PE |
71 | 2005-03-20 Paul Eggert <eggert@cs.ucla.edu> |
72 | ||
73 | * tests/local.at (AT_COMPILE, AT_COMPILE_CXX): Don't put options | |
74 | after operands; POSIX says this isn't portable for the c99 command. | |
75 | ||
9577fb1f PE |
76 | 2005-03-18 Paul Eggert <eggert@cs.ucla.edu> |
77 | ||
78 | * tests/glr-regression.at (glr-regr2a.y): Try to dump core | |
79 | immediately if a data overrun has occurred; this may help us track | |
80 | down what may be a spurious failure on MacOS. | |
81 | ||
78b178f7 PE |
82 | 2005-03-17 Paul Eggert <eggert@cs.ucla.edu> |
83 | ||
a2599d0f PE |
84 | Respond to problems reported by twlevo@xs4all.nl. |
85 | ||
86 | * bootstrap: Use "trap - 0" rather than the unportable "trap 0". | |
87 | ||
78b178f7 PE |
88 | * src/vcg.h: Comment fix. |
89 | * src/vcg_defaults.h: Parenthesize macro bodies to make them safe. | |
90 | (G_CMAX): Change to -1 instead of INT_MAX. | |
91 | ||
92 | * data/yacc.c (yyparse): Omit spaces before #line. | |
78b178f7 | 93 | |
7296e729 PE |
94 | 2005-03-15 Paul Eggert <eggert@cs.ucla.edu> |
95 | ||
96 | * src/tables.c (state_number_to_vector_number): Put it inside an | |
97 | "#if 0", since it's not currently used. Problem reported by | |
98 | Roland McGrath. | |
99 | ||
05ac60f3 PE |
100 | 2005-03-06 Paul Eggert <eggert@cs.ucla.edu> |
101 | ||
102 | * src/output.c (escaped_output): Renamed from | |
103 | escaped_file_name_output, since we now use it for symbol tags as | |
104 | well. All uses changed. | |
105 | (symbol_destructors_output, symbol_printers_output): | |
106 | Escape symbol tags too. | |
107 | Problem reported by Matyas Forstner in | |
108 | <http://lists.gnu.org/archive/html/bug-bison/2005-03/msg00009.html>. | |
109 | ||
110 | * src/muscle_tab.c (muscle_code_grow): Don't quote numbers; it's | |
111 | not needed. | |
112 | * src/output.c (user_actions_output, token_definitions_output, | |
113 | symbol_destructors_output, symbol_printers_output): Likewise. | |
114 | * src/reader.c (prologue_augment): Likewise. | |
115 | * src/scan-gram.l (handle_action_dollar, handle_action_at): Likewise. | |
116 | ||
117 | * src/vcg.c (output_edge): Don't quote linestyle arg. | |
118 | Problem reported by twlevo@xs4all.nl. | |
119 | ||
7eb453ac PE |
120 | 2005-02-28 Paul Eggert <eggert@cs.ucla.edu> |
121 | ||
122 | * doc/bison.texinfo (Semantic Tokens): Fix scoping problem in | |
123 | example, reported by Derek M Jones. Also, make the example even | |
124 | more outrageous, to better illustrate how bad the problem is. | |
125 | ||
4c04c52a PE |
126 | 2005-02-24 Paul Eggert <eggert@cs.ucla.edu> |
127 | ||
128 | * doc/bison.texinfo (Mfcalc Symtab): Correct the prototype for | |
129 | putsym. Typo reported by Sebastian Piping. | |
130 | ||
a61e1620 PE |
131 | 2005-02-23 Paul Eggert <eggert@cs.ucla.edu> |
132 | ||
133 | * doc/bison.texinfo (Language and Grammar): some -> same | |
134 | (Epilogue): int he -> in the | |
135 | Typos reported by Sebastian Piping via Justin Pence. | |
136 | ||
9ec93868 PE |
137 | 2005-02-07 Paul Eggert <eggert@cs.ucla.edu> |
138 | ||
139 | * tests/glr-regression.at (Improper handling of embedded actions | |
140 | and dollar(-N) in GLR parsers): Renamed from "Improper handling of | |
141 | embedded actions and $-N in GLR parsers", work around an Autoconf bug | |
142 | with dollar signs in test names. | |
143 | * tests/input.at (Invalid dollar-n): Renamed from "Invalid \$n", | |
144 | for a similar reason. | |
145 | ||
73ce7e7e PE |
146 | 2005-01-28 Paul Eggert <eggert@cs.ucla.edu> |
147 | ||
148 | * src/vcg.c (output_graph): G_VIEW -> normal_view in case someone | |
149 | wants to redefine G_VIEW. | |
150 | ||
2e72b98e PE |
151 | 2005-01-27 Paul Eggert <eggert@cs.ucla.edu> |
152 | ||
153 | * src/vcg.c (get_view_str): Remove case for normal_view. | |
154 | Problem reported by twlevo@xs4all.nl. | |
155 | ||
e0d634e5 PE |
156 | 2005-01-24 Paul Eggert <eggert@cs.ucla.edu> |
157 | ||
ccf830a4 PE |
158 | * configure.ac (O0CFLAGS, O0CXXFLAGS): Fix quoting bug. |
159 | Problem reported by twlevo@xs4all.nl. | |
160 | ||
e0d634e5 PE |
161 | * doc/bison.texinfo: Change @dircategory from "GNU programming |
162 | tools" to "Software development". Requested by Richard Stallman | |
163 | via Karl Berry. | |
164 | ||
7bbc8cb0 PE |
165 | 2005-01-23 Paul Eggert <eggert@cs.ucla.edu> |
166 | ||
167 | * tests/c++.at (AT_CHECK_DOXYGEN): Don't use options after operands. | |
168 | Problem reported by twlevo@xs4all.nl. | |
169 | ||
08b770bc PE |
170 | 2005-01-21 Paul Eggert <eggert@cs.ucla.edu> |
171 | ||
172 | * data/yacc.c (YYCOPY, yystpcpy, yyparse): Remove "register" | |
173 | keyword; it's not needed with modern compilers, and it doesn't | |
174 | affect correctness with older compilers. Suggested by | |
175 | twlevo@xs4all.nl. | |
176 | ||
95f22ad2 PE |
177 | 2005-01-17 Paul Eggert <eggert@cs.ucla.edu> |
178 | ||
179 | * data/glr.c (yyuserAction): Add "default: break;" case to pacify | |
180 | gcc -Wswitch-default. | |
181 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Likewise. | |
182 | * data/yacc.c (yyparse): Likewise. | |
183 | ||
d229d15c PE |
184 | 2005-01-12 Paul Eggert <eggert@cs.ucla.edu> |
185 | ||
186 | * src/system.h (OUTPUT_EXT, TAB_EXT): Define only if not defined | |
187 | already. Let config.h define any nonstandard values. | |
188 | ||
ecadd90f PE |
189 | 2005-01-10 Paul Eggert <eggert@cs.ucla.edu> |
190 | ||
191 | * tests/calc.at (_AT_DATA_CALC_Y): Use alarm (100), not alarm (10), | |
192 | for the benefit of slower hosts. Problem reported by | |
193 | Nelson H. F. Beebe. | |
194 | ||
213744b5 PE |
195 | 2005-01-07 Paul Eggert <eggert@cs.ucla.edu> |
196 | ||
197 | * data/yacc.c (yyparse): Pacify non-GCC compilers about yyerrorlab | |
198 | being defined and not used. | |
199 | * data/lalr1.cc (yyparse): Likewise. | |
200 | Use "if (false)" rather than "if (0)". | |
201 | ||
249d3236 PE |
202 | 2005-01-05 Paul Eggert <eggert@cs.ucla.edu> |
203 | ||
204 | * TODO: Mention that we should allow NUL bytes in tokens. | |
205 | ||
987cc1fb PE |
206 | 2005-01-02 Paul Eggert <eggert@cs.ucla.edu> |
207 | ||
208 | * src/scan-skel.l (<<EOF>>): Don't close standard output. | |
209 | Problem reported by Hans Aberg. | |
210 | ||
08fe02d9 PE |
211 | 2005-01-01 Paul Eggert <eggert@cs.ucla.edu> |
212 | ||
213 | * src/getargs.c (version): Happy new year; update overall | |
214 | program copyright date from 2004 to 2005. | |
215 | ||
216 | * src/scan-skel.l ("@output ".*\n): Don't close standard output. | |
217 | Problem reported by Hans Aberg. | |
218 | * tests/output.at (AT_CHECK_OUTPUT): New arg SHELLIO. | |
219 | (Output file names.): Add a test for the case when standard output | |
220 | is closed. | |
221 | ||
010c0266 PE |
222 | 2004-12-26 Paul Eggert <eggert@cs.ucla.edu> |
223 | ||
224 | * doc/bison.texinfo (@copying): Update FDL version number to 1.2, | |
225 | to fix an oversight in the Bison 2.0 manual. | |
226 | ||
da12206a PE |
227 | 2004-12-25 Paul Eggert <eggert@cs.ucla.edu> |
228 | ||
229 | * NEWS: Version 2.0. Reformat the existing news items since | |
230 | 1.875, so that related items are grouped together. | |
3a4734aa | 231 | * configure.ac (AC_INIT): Bump version to 2.0. |
da12206a PE |
232 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 2.0. |
233 | ||
c935d934 PE |
234 | * tests/torture.at (Exploding the Stack Size with Alloca): Set |
235 | YYSTACK_USE_ALLOCA to 1 if __GNUC__ or alloca are defined; | |
236 | otherwise, we're not testing alloca. Unfortunately there's no | |
237 | simple way to consult HAVE_ALLOCA here. | |
238 | ||
da12206a PE |
239 | * data/lalr1.cc (yydestruct_): Pacify unused variable warning |
240 | for yymsg, too. | |
241 | ||
242 | * src/LR0.c (new_itemsets): Use memset rather than zeroing by | |
243 | hand. This avoids a warning about comparing int to size_t when | |
244 | GCC warnings are enabled. | |
245 | ||
0a2c5137 PE |
246 | 2004-12-22 Paul Eggert <eggert@cs.ucla.edu> |
247 | ||
d7e14fc0 PE |
248 | * NEWS: Bison-generated parsers no longer default to using the |
249 | alloca function (when available) to extend the parser stack, due | |
250 | to widespread problems in unchecked stack-overflow detection. | |
251 | * data/glr.c (YYMAXDEPTH): Remove undef when zero. It's the user's | |
252 | responsibility to set it to a positive value. This lets the user | |
253 | specify a value that is not a preprocessor constant. | |
254 | * data/yacc.c (YYMAXDEPTH): Likewise. | |
255 | (YYSTACK_ALLOC): Define only if YYSTACK_USE_ALLOCA is nonzero. | |
256 | * doc/bison.texinfo (Stack Overflow): YYMAXDEPTH no longer needs | |
257 | to be a compile-time constant. However, explain the constraints on it. | |
258 | Also, explain the constraints on YYINITDEPTH. | |
259 | (Table of Symbols): Explain that alloca is no longer the default. | |
260 | Explain the user's responsibility if they define YYSTACK_USE_ALLOCA | |
261 | to 1. | |
262 | ||
0a2c5137 PE |
263 | * doc/bison.texinfo (Location Default Action): Mention that n must |
264 | be zero when k is zero. Suggested by Frank Heckenbach. | |
265 | ||
e019c247 AD |
266 | 2004-12-22 Akim Demaille <akim@epita.fr> |
267 | ||
268 | * data/lalr1.cc (parser::token_number_type, parser::rhs_number_type) | |
269 | (parser::state_type, parser::semantic_type, parser::location_type): | |
270 | Private, not public. | |
271 | (parser::parse): Return ints, not bool. | |
272 | Returning a bool introduces a problem: 0 corresponds to false, and | |
273 | it seems weird to return false on success. Returning true changes | |
274 | the conventions for yyparse. | |
275 | Alternatively we could return void and send an exception. | |
276 | There is no clear consensus (yet?). | |
277 | (state_stack, semantic_stack, location_stack): Rename as... | |
278 | (state_stack_type, semantic_stack_type, location_stack_type): these. | |
279 | Private, not public. | |
280 | * tests/c++.at: New. | |
281 | * tests/testsuite.at, tests/Makefile.am: Adjust. | |
282 | ||
72731bb7 AD |
283 | 2004-12-21 Akim Demaille <akim@epita.fr> |
284 | ||
285 | * data/lalr1.cc (parser::parse): Return a bool instead of an int. | |
286 | ||
9a0d8bec AD |
287 | 2004-12-21 Akim Demaille <akim@epita.fr> |
288 | ||
289 | Don't impose std::string for filenames. | |
290 | ||
291 | * data/lalr1.cc (b4_filename_type): New. | |
292 | (position::filename): Use it. | |
293 | (parser.hh): Move the inclusion of stack.hh and location.hh below | |
294 | the user code, so that needed headers for the filename type can be | |
295 | included first. | |
72731bb7 AD |
296 | Forward declare them before the user code. |
297 | * tests/Makefile.am (check-local, installcheck-local): Pass | |
298 | TESTSUITEFLAGS to the TESTSUITE. | |
9a0d8bec | 299 | |
99880de5 AD |
300 | 2004-12-20 Akim Demaille <akim@epita.fr> |
301 | ||
302 | Use more STL like names: my_class instead of MyClass. | |
303 | ||
304 | * data/lalr1.cc (LocationStack, LocationType, RhsNumberType) | |
305 | (SemanticStack, SemanticType, StateStack, StateType) | |
306 | (TokenNumberType, Stack, Slice, Traits, Parser::location) | |
307 | (Parser::value): Rename as... | |
308 | (location_stack, location_type, rhs_number_type, semantic_stack) | |
309 | (semantic_type, state_stack, state_type, token_number_type, stack) | |
310 | (slice, traits, parser::yylloc, parser::yylval): these. | |
311 | ||
312 | * tests/calc.at, tests/regression.at, tests/actions.at: Adjust. | |
313 | ||
9bec482e PE |
314 | 2004-12-19 Paul Eggert <eggert@cs.ucla.edu> |
315 | ||
316 | * data/glr.c (YYLLOC_DEFAULT): Use GNU spacing conventions. | |
317 | * data/yacc.c (YYLLOC_DEFAULT): Likewise. | |
318 | ||
f6fbd3da PE |
319 | 2004-12-17 Paul Eggert <eggert@cs.ucla.edu> |
320 | ||
321 | Remove uses of 'short int' and 'unsigned short int'. This raises | |
322 | some arbitrary limits. It uses more memory but nowadays that's | |
323 | not much of an issue. | |
324 | ||
325 | This change does not affect the generated parsers; that's a different | |
326 | task, as some users will want to conserve memory there. | |
327 | ||
328 | Ideally we should use size_t to represent all object counts, and | |
329 | something like ptrdiff_t to represent signed differences of object | |
330 | counts; but that will require more code-cleanup than I have the | |
331 | time to do right now. | |
332 | ||
333 | * src/LR0.c (allocate_itemsets, new_itemsets, save_reductions): | |
334 | Use size_t, not int or short int, to count objects. | |
335 | * src/closure.c (nritemset, closure): Likewise. | |
336 | * src/closure.h (nritemset, closure): Likewise. | |
337 | * src/nullable.c (nullable_compute): Likewise. | |
338 | * src/print.c (print_core): Likewise. | |
339 | * src/print_graph.c (print_core): Likewise. | |
340 | * src/state.c (state_compare, state_hash): Likewise. | |
341 | * src/state.h (struct state): Likewise. | |
342 | * src/tables.c (default_goto, goto_actions): Likewise. | |
343 | ||
344 | * src/gram.h (rule_number, rule): Use int, not short int. | |
345 | * src/output.c (prepare_rules): Likewise. | |
346 | * src/state.h (state_number, STATE_NUMBER_MAXIMUM, transitions, | |
347 | errs, reductions): Likewise. | |
348 | * src/symtab.h (symbol_number, SYMBOL_NUMBER_MAXIMUM, struct symbol): | |
349 | Likewise. | |
350 | * src/tables.c (vector_number, tally, action_number, | |
351 | ACTION_NUMBER_MINIMUM): Likewise. | |
352 | * src/output.c (muscle_insert_short_int_table): Remove. | |
353 | ||
efeed023 AD |
354 | 2004-12-17 Akim Demaille <akim@epita.fr> |
355 | ||
356 | * data/lalr1.cc: Extensive Doxygenation. | |
357 | (error_): Rename as... | |
358 | (error): this, since it is visible to the user. | |
359 | Adjust callers. | |
360 | (Parser::message): Now an automatic variable from... | |
361 | (Parser::yyreport_syntax_error_): here. | |
362 | * tests/actions.at, tests/calc.at, tests/regression.at: Adjust to | |
363 | Parser::error. | |
364 | * tests/input.at: Escape $. | |
365 | ||
bc82c5a5 PE |
366 | 2004-12-16 Paul Eggert <eggert@cs.ucla.edu> |
367 | ||
368 | * data/glr.c (b4_lhs_value, b4_rhs_value, b4_rhs-location): | |
369 | Parenthesize rhs to avoid obscure problems with mistakes like | |
370 | "foo$$bar = foo$1bar;". Problem reported by twlevo at xs4all. | |
371 | * data/lalr1.cc (b4_lhs_value, b4_rhs_value, b4_lhs_location, | |
372 | b4_rhs_location): Likewise. | |
373 | * data/yacc.c (b4_lhs_value, b4_rhs_value, b4_lhs_location, | |
374 | b4_rhs_location): Likewise. | |
375 | ||
fd19f271 AD |
376 | 2004-12-16 Akim Demaille <akim@epita.fr> |
377 | ||
378 | * data/lalr1.cc (yyreport_syntax_error_): Catch up with glr.c and | |
379 | yacc.c: be sure to stay within yycheck_. | |
380 | * tests/actions.at: Re-enable C++ tests. | |
381 | ||
10454ea4 AD |
382 | 2004-12-16 Akim Demaille <akim@epita.fr> |
383 | ||
384 | * src/print_graph.c (print_graph): Remove layoutalgorithm uses for | |
385 | real. | |
386 | ||
c5b95ccf AD |
387 | 2004-12-16 Akim Demaille <akim@epita.fr> |
388 | ||
389 | Use #define to handle the %name-prefix. | |
390 | ||
391 | * data/glr.c, data/yacc.c: Comment changes. | |
392 | * data/lalr1.cc (yylex): Use #define to select the name of yylex, | |
393 | so that one can refer to yylex in the parser file, and have it | |
394 | renamed, as is the case with other skeletons. | |
395 | ||
617a8f12 AD |
396 | 2004-12-16 Akim Demaille <akim@epita.fr> |
397 | ||
398 | Move lalr1.cc internals into yy*. | |
399 | ||
400 | * data/lalr1.cc (semantic_stack_, location_stack_, state_stack_) | |
401 | (semantic_stack_, location_stack_, pact_, pact_ninf_, defact_) | |
402 | (pgoto_, defgoto_, table_, table_ninf_, check_, stos_, r1_, r2_) | |
403 | (name_, rhs_, prhs_, rline_, token_number_, eof_, last_, nnts_) | |
404 | (empty_, final_, terror_, errcode_, ntokens_) | |
405 | (user_token_number_max_, undef_token_, n_, len_, state_, nerrs_) | |
406 | (looka_, ilooka_, error_range_, nerrs_): | |
407 | Rename as... | |
408 | (yysemantic_stack_, yylocation_stack_, yystate_stack_) | |
409 | (yysemantic_stack_, yylocation_stack_, yypact_, yypact_ninf_) | |
410 | (yydefact_, yypgoto_, yydefgoto_, yytable_, yytable_ninf_) | |
411 | (yycheck_, yystos_, yyr1_, yyr2_, yyname_, yyrhs_, yyprhs_) | |
412 | (yyrline_, yytoken_number_, yyeof_, yylast_, yynnts_, yyempty_) | |
413 | (yyfinal_, yyterror_, yyerrcode_, yyntokens_) | |
414 | (yyuser_token_number_max_, yyundef_token_, yyn_, yylen_, yystate_) | |
415 | (yynerrs_, yylooka_, yyilooka_, yyerror_range_, yynerrs_): | |
416 | these. | |
417 | ||
1e547e6e PE |
418 | 2004-12-15 Paul Eggert <eggert@cs.ucla.edu> |
419 | ||
420 | Fix some problems reported by twlevo at xs4all. | |
421 | * src/symtab.c (symbol_new): Report an error if the input grammar | |
422 | contains too many symbols. This is better than calling abort() later. | |
423 | * src/vcg.h (enum layoutalgorithm): Remove. All uses removed. | |
424 | (struct node, struct graph): | |
425 | Rename member expand to stretch. All uses changed. | |
426 | (struct graph): Remove member layoutalgorithm. All uses removed. | |
427 | * src/vcg.c (get_layoutalgorithm_str): Remove. All uses removed. | |
428 | * src/vcg_defaults.h (G_STRETCH): Renamed from G_EXPAND. | |
429 | All uses changed. | |
430 | (N_STRETCH): Rename from N_EXPAND. All uses changed. | |
431 | ||
735d6bd4 AD |
432 | 2004-12-15 Akim Demaille <akim@epita.fr> |
433 | ||
434 | * data/lalr1.cc: Normalize /** \brief ... */ to ///. | |
435 | Add more Doxygen comments. | |
436 | (symprint_, stack_print_, reduce_print_, destruct_, pop) | |
437 | (report_syntax_error_, translate_): Rename as... | |
438 | (yysymprint_, yystack_print_, yyreduce_print_, yydestruct_) | |
439 | (yypop_, yyreport_syntax_error_, yytranslate_): this. | |
440 | ||
2e1f5829 AD |
441 | 2004-12-15 Akim Demaille <akim@epita.fr> |
442 | ||
443 | * data/lalr1.cc (lex_): Rename as... | |
444 | (yylex_): this. | |
445 | Move the trace here. | |
446 | Take the %name-prefix into account. | |
447 | Reported by Alexandre Duret-Lutz. | |
448 | ||
a3cb6248 AD |
449 | 2004-12-15 Akim Demaille <akim@epita.fr> |
450 | ||
451 | Simplify the C++ parser constructor. | |
452 | ||
453 | * data/lalr1.cc (debug_): Rename as... | |
454 | (yydebug_): so that the parser's internals are always in the yy* | |
455 | pseudo namespace. | |
456 | Adjust uses. | |
457 | (b4_parse_param_decl): Remove the leading comma as it is now only | |
458 | called as unique argument list. | |
459 | (Parser::Parser): Remove the constructor accepting a location and | |
460 | an initial debugging level. | |
461 | Remove from the other ctor the argument for the debugging level. | |
462 | (debug_level_type, debug_level, set_debug_level): New. | |
463 | ||
464 | * tests/actions.at, tests/calc.at, tests/regression.at: Adjust | |
465 | constructor calls. | |
466 | ||
07fed891 AD |
467 | 2004-12-15 Akim Demaille <akim@epita.fr> |
468 | ||
469 | Remove b4_root related material: failure experiment | |
a3cb6248 | 470 | (which goal was to allow to derive from a class). |
07fed891 AD |
471 | |
472 | * data/lalr1.cc (b4_root, b4_param, b4_constructor): Remove | |
473 | definitions and uses. | |
474 | ||
e603eaa5 PE |
475 | 2004-12-14 Paul Eggert <eggert@cs.ucla.edu> |
476 | ||
477 | * data/glr.c (struct yyGLRStack): yyerror_range now has 3 items, | |
478 | not 2, since it's not portable to subtract 1 from the start of an | |
479 | array. The new item 0 is never set or used. All uses changed. | |
480 | ||
481 | (yyrecoverSyntaxError): Use YYLLOC_DEFAULT instead of assuming | |
482 | the default definition of YYLLOC_DEFAULT. Problem reported | |
483 | by Frank Heckenbach. | |
484 | ||
fafb007d PE |
485 | 2004-12-12 Paul Eggert <eggert@cs.ucla.edu> |
486 | ||
487 | * data/glr.c (YYRHSLOC): Don't have two definitions, one for | |
488 | the normal case and one for the error case. Just use the | |
489 | first one uniformly. Problem reported by Frank Heckenbach. | |
490 | (YYLLOC_DEFAULT): Use the conventions of yacc.c, so we can | |
491 | use exactly the same macro in both places. | |
492 | (yyerror_range): Now of type yyGLRStackItem, not YYLTYPE, | |
493 | so that the normal-case YYRHSLOC works for the error case too. | |
494 | All uses changed. | |
495 | * data/yacc.c (YYRHSLOC): New macro, taken from glr.c. | |
496 | (YYLLOC_DEFAULT): Use the same macro as glr.c. | |
497 | * doc/bison.texinfo (Location Default Action): Don't claim that | |
498 | we have an array of locations. Use the same macro for both glr | |
499 | and lalr parsers. Mention YYRHSLOC. Mention what happens when | |
500 | the index is 0. | |
501 | ||
48814dcd PE |
502 | 2004-12-10 Paul Eggert <eggert@cs.ucla.edu> |
503 | ||
a4e1a53b PE |
504 | * HACKING: Update email addresses to send announcements to. |
505 | ||
48814dcd PE |
506 | * configure.ac (AC_INIT): Bump version to 1.875f. |
507 | ||
337116ba PE |
508 | 2004-12-10 Paul Eggert <eggert@cs.ucla.edu> |
509 | ||
510 | * NEWS: Version 1.875e. | |
511 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 1.875e. | |
512 | ||
513 | * src/scan-skel.l: Include "complain.h", for "fatal". | |
514 | ||
515 | * src/relation.h (relation_print, relation_digraph): | |
516 | Relation sizes are of type relation_node, not size_t (this is | |
517 | merely a doc fix, since the two types are equivalent). | |
518 | (relation_transpose): Relation sizes are of type relation_node, | |
519 | not int. | |
520 | * src/relation.c: Likewise. | |
521 | (top, infinity): Now of type relation_node, not int. | |
522 | (traverse, relation_transpose): Use relation_node, not int. | |
523 | ||
524 | * data/glr.c (yyuserAction, yyrecoverSyntaxError): Mark args | |
525 | with ATTRIBUTE_UNUSED if they're not used, to avoid GCC warning. | |
526 | (yyparse): Remove unused local introduced in 2004-10-25 patch. | |
527 | ||
528 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): New arg | |
68b082af | 529 | specifying whether the test should be skipped. Use it tp |
337116ba | 530 | specify that the [%defines %skeleton "lalr1.cc"] tests currently |
68b082af | 531 | fail on some hosts, and should be skipped. |
337116ba | 532 | |
da2a7671 PE |
533 | 2004-12-08 Paul Eggert <eggert@cs.ucla.edu> |
534 | ||
535 | * src/system.h (CALLOC, MALLOC, REALLOC): Remove. All callers | |
536 | changed to use xcalloc, xnmalloc, xnrealloc, respectively, | |
537 | unless otherwise specified below. | |
538 | ||
539 | * src/LR0.c (allocate_itemsets): Use xnmalloc, not xcalloc, | |
540 | to allocate kernel_base, kernel_items, kernel_size, since | |
541 | they needn't be initialized to 0. | |
542 | (allocate_storgae): Likewise, for shiftset, redset, shift_symbol. | |
543 | * src/closure.c (new_closure): Likewise, for itemset. | |
544 | * src/derives.c (derives_compute): Likewise, for delts, derives, q. | |
545 | * src/lalr.c (set_goto_map): Likewise, for temp_map. | |
546 | (initialize_F): Likewise, for reads, edge, reads[i], includes[i]. | |
547 | (build_relations): Likewise for edge, states1, includes. | |
548 | * src/nullable.c (nullable_compute): Likewise, for squeue, relts. | |
549 | * src/reader.c (packgram): Likewise, for ritem, rules. | |
550 | * src/reduce.c (nonterminals_reduce): Likewise for nontermmap. | |
551 | * src/relation.c (relation_digraph): Likewise for VERTICES. | |
552 | (relation_transpose): Likewise for new_R, end_R. | |
553 | * src/symtab.c (symbols_token_translations_init): Likewise for | |
554 | token_translations. | |
555 | * src/tables.c (save_row): Likewise for froms, tos, conflict_tos. | |
556 | (token_actions): Likewise for yydefact, actrow, conflrow, | |
557 | conflict_list. | |
558 | (save_column): Likewise for froms[symno], tos[symno]. | |
559 | (goto_actions): Likewise for state_count. | |
560 | (pack_table): Likewise for base, pos, check. | |
561 | (tables_generate): Likewise for width. | |
562 | ||
563 | * src/LR0.c (set_states): Don't reuse kernel_size and kernel_base | |
564 | for initial core. Just have a separate core, so we needn't worry | |
565 | about whether kernel_size and kernel_base are initialized. | |
566 | ||
567 | * src/LR0.c (shift_symbol, redset, shiftset, kernel_base, | |
568 | kernel_size, kernel_items): Remove unnecessary initialization. | |
569 | * src/conflicts.c (conflicts): Likewise. | |
570 | * src/derives.c (derives): Likewise. | |
571 | * src/muscle_tablc (muscle_insert): Likewise. | |
572 | * src/relation.c (relation_digraph): Likewise. | |
573 | * src/tables.c (froms, tos, conflict_tos, tally, width, actrow, order, | |
574 | conflrow, conflict_table, conflict_list, table, check): | |
575 | Likewise. | |
576 | ||
577 | * src/closure.c (new_closure): Arg is of type unsigned int, not int. | |
578 | This is because all callers pass unsigned int. | |
579 | * src/closure.h (new_closure): Likewise. | |
580 | ||
581 | * src/lalr.c (initialize_F): Initialize reads[i] in all cases. | |
582 | (build_relations): Initialize includes[i] in all cases. | |
583 | * src/reader.c (packgram): Always initialize rules[ruleno].prec | |
584 | and rules[ruleno].precsym. Initialize members in order. | |
585 | * src/relation.c (relation_transpose): Always initialize new_R[i] | |
586 | and end_R[i]. | |
587 | * src/table.c (conflict_row): Initialize 0 at end of conflict_list. | |
588 | ||
589 | * src/output.c (prepare_actions): Pass 0 instead of conflict_list[0]; | |
590 | conflict_list[0] was always 0, but now it isn't initialized. | |
591 | ||
592 | * src/table.c (table_grow): When conflict_table grew, the grown | |
593 | area wasn't cleared. Fix this. | |
594 | ||
595 | * lib/.cvsignore: Add strdup.c, strdup.h. | |
596 | * m4/.cvsignore: Add strdup.m4. | |
597 | ||
00baeeac PE |
598 | 2004-12-07 Paul Eggert <eggert@cs.ucla.edu> |
599 | ||
600 | * src/lalr.h (GOTO_NUMBER_MAXIMUM): New macro. | |
601 | * src/lalr.c (set_goto_map): Don't allow ngotos to equal | |
602 | GOTO_NUMBER_MAXIMUM, since we occasionally compute | |
603 | ngotos + 1 without checking for overflow. | |
604 | (build_relations): Use END_NODE, not -1, to denote end of edges. | |
605 | * src/lalr.c (set_goto_map, map_goto, initialize_F, add_loopback_edge, | |
606 | build_relations): Use goto_number, not int, for goto numbers. | |
607 | * src/tables.c (save_column, default_goto): Likewise. | |
608 | ||
be3d9d42 AD |
609 | 2004-11-23 Akim Demaille <akim@epita.fr> |
610 | ||
611 | * data/lalr1.cc (YYSTYPE): Define it as is done for C, instead | |
612 | of #defining from yystype. | |
613 | Don't typedef yystype, C++ does not need it. | |
614 | This lets it possible to forward declare it as union. | |
615 | ||
78e526d5 PE |
616 | 2004-11-23 Paul Eggert <eggert@cs.ucla.edu> |
617 | ||
618 | * bootstrap (gnulib_modules): Add extensions. | |
619 | Problem reported by Jim Meyering. | |
620 | ||
afbb696d PE |
621 | 2004-11-22 Paul Eggert <eggert@cs.ucla.edu> |
622 | ||
623 | * src/LR0.c, src/closure.c, src/derives.c, src/gram.c, | |
624 | src/lalr.c, src/nullable.c, src/relation.c, src/scan-skel.l, | |
625 | src/system.h, src/tables.c: XFREE -> free, to accommodate | |
626 | recent change to gnulib xalloc.h. | |
78e526d5 | 627 | Problem reported by Jim Meyering. |
afbb696d | 628 | |
c1f8f16a AD |
629 | 2004-11-17 Akim Demaille <akim@epita.fr> |
630 | ||
631 | * data/lalr1.cc (symprint_): Use cdebug_ to avoid warnings. | |
632 | ||
633 | 2004-10-28 Akim Demaille <akim@epita.fr>, | |
9a1e9989 AD |
634 | Alexandre Duret-Lutz <adl@gnu.org> |
635 | ||
636 | * data/lalr1.cc (Parser::yycdebug_): New, a pointer, to allow | |
637 | changes. | |
638 | (YYCDEBUG): Adjust. | |
639 | Use it instead of cdebug_. | |
640 | (Parser::debug_stream, Parser::set_debug_stream): New. | |
641 | (Parser::symprint_): Define cdebug_ for temporary backward | |
642 | compatibility. | |
643 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Use | |
644 | debug_stream (). | |
645 | ||
68e11668 AD |
646 | 2004-11-17 Akim Demaille <akim@epita.fr> |
647 | ||
648 | * data/lalr1.cc (Parser:print_): Remove, use %printer instead. | |
649 | * tests/regression.at (_AT_DATA_DANCER_Y): Adjust. | |
650 | * tests/calc.at (_AT_DATA_CALC_Y): Ditto. | |
651 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise. | |
652 | ||
97cbc73e PE |
653 | 2004-10-27 Paul Eggert <eggert@cs.ucla.edu> |
654 | ||
655 | * data/glr.c (yyloc_default): Remove; not used. | |
656 | Problem reported by Frank Heckenbach. | |
657 | ||
e342c3be AD |
658 | 2004-10-25 Akim Demaille <akim@epita.fr> |
659 | ||
660 | * data/glr.c (YYRHSLOC): Move its definition next to its uses. | |
661 | Introduce another definition to address simple location arrays. | |
662 | (yyGLRStack): New member: yyerror_range. | |
663 | (yyrecoverSyntaxError, yyparse): Update it. | |
664 | (yyrecoverSyntaxError): Use it when shifting the error token to | |
665 | have an accurate range, equivalent to the one computed by both | |
666 | yacc.c and lalr1.cc. | |
667 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Change its yylex so | |
668 | that column numbers start at column 0, as per GNU Coding | |
669 | Standards, the others tests, and the doc. | |
670 | (_AT_RESOLVED_GLR_OUTPUT_WITH_LOC, _AT_AMBIG_GLR_OUTPUT_WITH_LOC): | |
671 | Adjust to the above change (first column is 0). | |
672 | And adjust the location of the "<error>", now covering the whole | |
673 | line. | |
674 | ||
93602feb PE |
675 | 2004-10-22 Akim Demaille <akim@epita.fr> |
676 | and Paul Eggert <eggert@cs.ucla.edu> | |
677 | ||
678 | Remove some arbitrary limits on goto numbers and relations. | |
679 | * src/lalr.c (goto_map, ngotos, from_state, to_state): Omit | |
680 | initial values, since they're never used. | |
681 | (set_goto_map): ngotos is now unsigned, so test for overflow | |
682 | by seeing whether it wraps around to zero. | |
683 | * src/lalr.h (goto_number): Now size_t, not short int. | |
684 | (GOTO_NUMBER_MAXIMUM): Remove. | |
685 | * src/relation.c (relation_print, traverse, relation_transpose): | |
686 | Check for END_NODE rather than looking at sign. | |
687 | * src/relation.h (END_NODE): New macro. | |
688 | (relation_node): Now size_t, not short int. | |
689 | ||
dba08b04 PE |
690 | 2004-10-22 Paul Eggert <eggert@cs.ucla.edu> |
691 | ||
692 | * doc/bison.texinfo (Language and Grammar): In example, "int" is a | |
693 | keyword, not an identifier. Problem reported by Baron Schwartz in | |
694 | <http://lists.gnu.org/archive/html/bug-bison/2004-10/msg00017.html>. | |
695 | ||
df09ef2e AD |
696 | 2004-10-11 Akim Demaille <akim@epita.fr> |
697 | ||
698 | * src/symtab.c (symbol_check_alias_consistency): Also check | |
699 | type names, destructors, and printers. | |
700 | Reported by Alexandre Duret-Lutz. | |
701 | Recode the handling of associativity and precedence in terms | |
702 | of symbol_precedence_set. | |
703 | Accept no redeclaration at all, not even equal to the previous | |
704 | value. | |
705 | (redeclaration): New. | |
706 | Use it to factor redeclaration complaints. | |
707 | (symbol_make_alias): Don't set the type of the alias, let | |
708 | symbol_check_alias_consistency do it as for other features. | |
709 | * src/symtab.h (symbol): Add new member prec_location, and | |
710 | type_location. | |
711 | * src/symtab.c (symbol_precedence_set, symbol_type_set): Set them. | |
712 | * tests/input.at (Incompatible Aliases): New. | |
713 | ||
146bc99d PE |
714 | 2004-10-09 Paul Eggert <eggert@cs.ucla.edu> |
715 | ||
716 | .cvsignore fixes to accommodate gnulib changes, | |
717 | and the practice of naming build directories "_build". | |
718 | * .cvsignore: Add "_*". Sort. | |
719 | * lib/.cvsignore: Add getopt_.h, xalloc-die.c. | |
720 | * m4/.cvsignore: Add "*_gl.m4". | |
721 | ||
e503aa60 AD |
722 | 2004-10-06 Akim Demaille <akim@epita.fr> |
723 | ||
724 | * src/parse-gram.y (add_param): Fix the truncation of trailing | |
725 | spaces. | |
726 | ||
b4a20338 AD |
727 | 2004-10-05 Akim Demaille <akim@epita.fr> |
728 | ||
729 | In Bison 1.875's yacc.c, YYLLOC_DEFAULT was called regardless | |
730 | whether the reducion was empty or not. This leaves room to | |
731 | improve the use of YYLLOC_DEFAULT in such a case. | |
732 | lalr1.cc is still experimental, so changing this is acceptable. | |
733 | And finally, there are probably not many users who changed the | |
734 | handling of locations in GLR, so changing is admissible too. | |
735 | ||
736 | * data/glr.c, data/lalr1.cc, data/yacc.c (YYLLOC_DEFAULT): On an | |
737 | empty reduction, set @$ to an empty location ending the previously | |
738 | stacked symbol. | |
739 | Adjust uses to make sure the code is triggered on empty | |
740 | reductions. | |
741 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust the | |
742 | expected output: empty reductions have empty locations. | |
743 | ||
f85a5e6f AD |
744 | 2004-09-29 Akim Demaille <akim@epita.fr> |
745 | ||
746 | * data/lalr1.cc: Move towards a more standard C++ coding style | |
747 | for templates: Class < T > -> Class<T>. | |
748 | ||
b203fc2c AD |
749 | 2004-09-29 Akim Demaille <akim@epita.fr> |
750 | ||
751 | * data/lalr1.cc: Reinstall the former ctor, for sake of | |
752 | compatibility, but warn it will be removed. | |
753 | Move towards a more standard C++ coding style (i.e., type *var -> | |
754 | type* var). | |
755 | ||
5b7e1e73 PE |
756 | 2004-09-27 Paul Eggert <eggert@cs.ucla.edu> |
757 | ||
3fee967f PE |
758 | * src/parse-gram.y (add_param): Rewrite to avoid strchr, |
759 | since it's less likely to work if NULs are involved in the future. | |
5b7e1e73 | 760 | |
0dcca5c2 AD |
761 | 2004-09-27 Akim Demaille <akim@epita.fr> |
762 | ||
763 | * data/yacc.c (YY_LOCATION_PRINT): Fix its default declaration. | |
764 | ||
6dde1c82 AD |
765 | 2004-09-27 Akim Demaille <akim@epita.fr> |
766 | ||
767 | * data/lalr1.cc (b4_parse_param_decl_1): New. | |
b203fc2c | 768 | (b4_parse_param_decl): Use it to have different names between attribute |
6dde1c82 AD |
769 | and argument names. |
770 | (b4_cc_constructor_call): Likewise. | |
771 | ||
b233d555 AD |
772 | 2004-09-24 Akim Demaille <akim@epita.fr> |
773 | ||
774 | * src/parse-gram.y (add_param): Strip the leading and trailing | |
775 | blanks from a formal argument declaration. | |
776 | (YY_LOCATION_PRINT): New. | |
777 | ||
619404e3 AD |
778 | 2004-09-24 Akim Demaille <akim@epita.fr> |
779 | ||
780 | * data/c.m4 (b4_yysymprint_generate): Move the YYINPUT invocation | |
781 | after the location. | |
782 | ||
dd8d9022 AD |
783 | 2004-09-24 Akim Demaille <akim@epita.fr> |
784 | ||
785 | * doc/bison.texinfo (Table of Symbols): Sort. | |
786 | ||
0092f063 AD |
787 | 2004-09-21 Akim Demaille <akim@epita.fr> |
788 | ||
789 | * data/yacc.c, data/glr.c (b4_at_dollar, b4_dollar_dollar): Remove | |
790 | the useless parentheses. | |
791 | Suggested by Paul Eggert. | |
792 | ||
451364ed AD |
793 | 2004-09-20 Akim Demaille <akim@epita.fr> |
794 | ||
795 | Let the initial-action act on the look-ahead, and use it for the | |
796 | "initial push" (corresponding to an hypothetical beginning-of-file). | |
797 | And let lalr1.cc honor %initial-action. | |
798 | ||
799 | * doc/bison.texinfo (Initial Action Decl): Clarify, and add an | |
800 | example. | |
801 | * data/lalr1.cc (Parser::initlocation_): Remove, bad experiment. | |
802 | (Parser::Parser): Remove the ctor that used to initialize it. | |
803 | (Parser::parse): Like in the other skeletons, issue the "starting | |
804 | parse" message before any action. | |
805 | Honor %initial-action. | |
806 | Initialize the stacks with the lookahead. | |
807 | * data/yacc.c: Let $$ and @$ in %initial-action designate the | |
808 | look-ahead. | |
809 | Push them in the stacks. | |
810 | * tests/actions.at, tests/calc.at: Adjust the C++ ctor invocations. | |
811 | ||
18d192f0 AD |
812 | 2004-09-20 Akim Demaille <akim@epita.fr> |
813 | ||
814 | * doc/bison.texinfo (Initial Action Decl): New. | |
815 | ||
b8458aa5 AD |
816 | 2004-09-20 Akim Demaille <akim@epita.fr> |
817 | ||
818 | * data/yacc.c (YY_LOCATION_PRINT): Use YYLTYPE_IS_TRIVIAL as a | |
819 | clearer criterion to define it. | |
820 | (parse): Initialize the initial location when YYLTYPE_IS_TRIVIAL. | |
821 | When reducing on an empty RHS, use the latest stacked location as | |
822 | location. | |
823 | yylloc is not always available. | |
824 | * data/glr.c: Likewise. | |
825 | Also, honor initial-actions. | |
826 | ||
3fc16193 AD |
827 | 2004-09-20 Akim Demaille <akim@epita.fr> |
828 | ||
829 | * data/yacc.c (YY_LOCATION_PRINT): New. | |
830 | Define when we know YYLTYPE's structure, i.e., when the default | |
831 | YYLLOC_DEFAULT is used. | |
832 | * data/c.m4 (b4_yysymprint_generate): Use it. | |
833 | * data/lalr1.cc (YYLLOC_DEFAULT): Stop relying on the initial | |
834 | value of the result. | |
835 | (error_start_): Replace with... | |
836 | (error_range_): this location array. | |
837 | This allows to replace code relying on the implementation of | |
838 | locations by portable code. | |
839 | * data/yacc.c (yylerrsp): Replace with... | |
840 | (yyerror_range): this. | |
841 | Every time a token is popped, update yyerror_range[0], to have an | |
842 | accurate location for the error token. | |
843 | * data/glr.c (YY_LOCATION_PRINT): New. | |
844 | (yyprocessOneStack): Fix an invocation of YY_SYMBOL_PRINT: | |
845 | deference a pointer. | |
846 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): No longer | |
847 | report the location in %printers. | |
848 | ||
849 | * src/scan-skel.l: Instead of abort, report error messages to ease | |
850 | understanding skeleton scanning failures. | |
851 | ||
ecfe33e7 AD |
852 | 2004-09-16 Akim Demaille <akim@epita.fr> |
853 | ||
854 | * data/lalr1.cc (Stack::Iterator, Stack::ConstIterator): Rename as... | |
855 | (iterator, const_iterator): these, to be more in the C++ spirit. | |
856 | Also, return reverse iterators so that when displaying the stack | |
857 | we display its bottom first. | |
858 | (Parser::stack_print_, Parser::reduce_print_): Match the messages | |
859 | from yacc.c. | |
860 | We should probably use vector here though. | |
861 | ||
1576d44d AD |
862 | 2004-09-16 Akim Demaille <akim@epita.fr> |
863 | ||
864 | Have more complete shift traces. | |
865 | ||
866 | * data/yacc.c, data/lalr1.c, data/glr.c: Use YY_SYMBOL_PRINT | |
867 | to report Shifts instead of ad hoc YYDPRINTF invocations, | |
868 | including for the error token. | |
869 | * data/lalr1.cc (symprint_): Output the location. | |
870 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): In C++, don't | |
871 | output the location within the %printer. | |
872 | Activate GLR tests, at least to make sure they compile properly. | |
873 | They still don't pass though. | |
874 | * tests/calc.at: Adjust expect verbose output, since now "Entering | |
875 | state..." is on a different line than the "Shifting" message. | |
876 | ||
9c66f418 AD |
877 | 2004-09-08 Akim Demaille <akim@epita.fr> |
878 | ||
879 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Move the | |
880 | Bison directive from the Bison file to the invocation of this | |
881 | macro, so that these directives are passed to | |
882 | AT_BISON_OPTION_PUSHDEFS to get correct help macros. | |
883 | Use these helping macros (e.g., AT_LOC, AT_VAL and so forth). | |
884 | Move the AT_SETUP/AT_CLEANUP outside, to report as test title | |
885 | the extra Bison directives instead of the whole series. | |
886 | Change the grammar so that there are recoverable errors, and | |
887 | unrecoverable errors. Now we can have the parser give up before | |
888 | consuming the whole input. As a result we now can observe that | |
889 | the lookahead is freed when needed. | |
890 | Change the parser source to parse argv[1] instead of a hard coded | |
891 | string. | |
892 | Simplify yylex, and give a value and location to EOF. | |
893 | Simplify some invocations of AT_CHECK_PRINTER_AND_DESTRUCTOR that | |
894 | passed directives already coded in the file. | |
895 | Add some tests to check the location of "error". | |
896 | For some tests, the C++ parser is correct, and not yacc.c. | |
897 | For other tests, they provide different, but unsatisfying, values, | |
898 | so keep the C++ value so that at least one parser is "correct" | |
899 | according to the test suite. | |
900 | (Actions after errors): Remove, this is subsumed by the | |
901 | AT_CHECK_PRINTER_AND_DESTRUCTOR series. | |
902 | ||
52d5733f AD |
903 | 2004-09-06 Akim Demaille <akim@epita.fr> |
904 | ||
905 | * data/lalr1.cc: Adjust the indentation of the labels. | |
906 | (Parser::pop): New. | |
907 | Use it. | |
908 | ||
a0e68930 AD |
909 | 2004-09-06 Akim Demaille <akim@epita.fr> |
910 | ||
911 | * data/yacc.cc, data/glr.cc (yydestruct): Accept an additional | |
912 | argument, an informative message. | |
913 | Call YY_SYMBOL_PRINT. | |
914 | Adjust all callers: integrate the associated YY_SYMBOL_PRINT. | |
915 | * data/lalr1.cc (destruct_): Likewise. | |
916 | In addition, no longer depend on b4_yysymprint_generate and | |
917 | b4_yydestruct_generate to generate these functions, do it "by | |
918 | hand". | |
919 | ||
e757bb10 AD |
920 | 2004-09-03 Akim Demaille <akim@epita.fr> |
921 | ||
922 | * data/glr.c, data/lalr1.cc, data/yacc.c: When YYABORT was | |
923 | invoked, yydestruct the lookahead. | |
924 | * tests/calc.at (Calculator $1): Update the expected lengths of | |
925 | traces: there is an added line for the discarded lookahead. | |
926 | * doc/bison.texinfo (Destructor Decl): Some rewording. | |
927 | Define "discarded" symbols. | |
928 | ||
0fe1f06d AD |
929 | 2004-09-02 Akim Demaille <akim@epita.fr> |
930 | ||
931 | * data/lalr1.cc (translate_, destruct_): No reason to be static. | |
932 | ||
284acc8b AD |
933 | 2004-09-02 Akim Demaille <akim@epita.fr> |
934 | ||
935 | * data/glr.c, yacc.c (YYDSYMPRINT): Remove, not used. | |
936 | (YYDSYMPRINTF): Rename as... | |
937 | (YY_SYMBOL_PRINT): this. | |
938 | * data/lalr1.cc (YY_SYMBOL_PRINT): New, modeled after the previous | |
939 | two. | |
940 | Use it instead of direct symprint_ calls. | |
941 | (yybackup): Tweak the "Now at end of input" case to match yacc.c's | |
942 | one. | |
943 | ||
a5eb1ed2 AD |
944 | 2004-09-02 Akim Demaille <akim@epita.fr> |
945 | ||
b7c72fe1 AD |
946 | * data/lalr1.cc (b4_yysymprint_generate): New. |
947 | (symprint_): New member function, defined when YYDEBUG. | |
948 | Use it consistently instead of token/nterm debugging output by | |
949 | hand. | |
a5eb1ed2 AD |
950 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust |
951 | %printer calls to use cdebug_ when using lalr1.cc. | |
952 | ||
417141dd AD |
953 | 2004-08-30 Florian Krohm <florian@edamail.fishkill.ibm.com> |
954 | ||
955 | * data/glr.c: Guard the declarations of yypstack and yypdumpstack | |
956 | with #ifdef YYDEBUG. | |
957 | ||
2fa09258 AD |
958 | 2004-08-26 Akim Demaille <akim@epita.fr> |
959 | ||
960 | * doc/bison.texinfo (Implementing Loops): Rename as... | |
961 | (Implementing Gotos/Loops): this. | |
962 | ||
9378b508 PE |
963 | 2004-08-13 Paul Eggert <eggert@cs.ucla.edu> |
964 | ||
965 | Adjust to latest gnulib. | |
966 | * bootstrap (gnulib_modules): Add xalloc-die. | |
967 | Set LC_ALL=C so that file names sort consistently. | |
968 | Prefer the gnulib copies of gettext.m4, glibc21.m4, | |
969 | inttypes_h.m4, lib-ld.m4, lib-prefix.m4, po.m4, stdint_h.m4, | |
970 | uintmax_t.m4, ulonglong.m4. | |
971 | (intl_files_to_remove): Add gettext.m4, lib-ld.m4, lib-prefix.m4, | |
972 | po.m4 since we are now using _gl.m4 instead. | |
973 | ||
87a8ad5c PE |
974 | 2004-08-10 Florian Krohm <florian@edamail.fishkill.ibm.com> |
975 | ||
976 | * src/scan-action.l: Remove. Scanning of semantic actions is | |
977 | handled in scan-gram.l. | |
978 | ||
dca81a78 PE |
979 | 2004-08-07 Florian Krohm <florian@edamail.fishkill.ibm.com> |
980 | ||
981 | * src/scan-gram.l (handle_syncline): Use uniqstr_new not xstrdup. | |
982 | ||
983 | * src/location.h (struct): The file member is a uniqstr. | |
984 | (equal_boundaries): Use UNIQSTR_EQ for comparison. | |
985 | ||
c9cbf7c5 PE |
986 | 2004-07-22 Paul Eggert <eggert@cs.ucla.edu> |
987 | ||
988 | Fix bug with non-%union parsers that have printers or destructors, | |
989 | which led to a Bison core dump. Reported by Peter Fales in | |
990 | <http://lists.gnu.org/archive/html/bug-bison/2004-07/msg00014.html>. | |
2fa09258 | 991 | |
c9cbf7c5 PE |
992 | * data/c.m4 (b4_symbol_actions): Don't assume %union was used. |
993 | * data/lalr1.cc (yystype) [defined YYSTYPE]: Define to YYSTYPE, | |
994 | not to our own type. | |
995 | * src/output.c (symbol_destructors_output, symbol_printers_output): | |
996 | Don't assume %union. | |
997 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR, | |
998 | AT_CHECK_PRINTER_AND_DESTRUCTOR): New argument | |
999 | UNION-FLAG. All callers changed. | |
1000 | (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Don't assume %union. | |
1001 | Use type char, not unsigned int, when declaring an array of char; | |
1002 | this lets us remove a cast. | |
1003 | (Printers and Destructors): Add non-%union test cases. | |
1004 | ||
fa7e68c3 PE |
1005 | 2004-06-21 Paul Eggert <eggert@cs.ucla.edu> |
1006 | ||
1007 | * doc/bison.texinfo: Minor editorial changes, mostly to the new | |
1008 | GLR writeups. E.g., avoid frenchspacing and the future tense, | |
1009 | change "lookahead" to "look-ahead", and change "wrt" to "with | |
1010 | respect to". | |
2fa09258 | 1011 | |
fa7e68c3 PE |
1012 | 2004-06-21 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> |
1013 | ||
1014 | * doc/bison.texinfo (Merging GLR Parses, Compiler Requirements): | |
1015 | New sections, split off from the GLR Parsers section. Put the new | |
1016 | Simple GLR Parser near the start of the GLR section, for clarity. | |
1017 | Rewrite connective text. | |
1018 | ||
99a9344e PE |
1019 | 2004-06-21 Frank Heckenbach <frank@g-n-u.de> |
1020 | ||
1021 | * doc/bison.texinfo (Simple GLR Parsers): New section. | |
1022 | ||
8dd162d3 PE |
1023 | 2004-06-21 Paul Eggert <eggert@cs.ucla.edu> |
1024 | ||
1025 | * NEWS, TODO, doc/bison.texinfo: | |
1026 | Use "look-ahead" instead of "lookahead", to be consistent. | |
1027 | * REFERENCES: Fix incorrect reference to DeRemer and Pennello, | |
1028 | while we're fixing "look-ahead". | |
1029 | * src/conflicts.c (shift_set): Renamed from shiftset. | |
1030 | (look_ahead_set): Renamed from lookaheadset. | |
1031 | * src/print.c: Likewise. | |
1032 | * src/getargs.c (report_args): Add "look-ahead" as the new canonical | |
1033 | name for "lookahead". | |
1034 | (report_types, usage): Likewise. | |
1035 | * src/getargs.h (report_look_ahead_tokens): Renamed from | |
1036 | report_lookaheads. | |
1037 | * src/lalr.c (compute_look_ahead_tokens): Renamed from | |
1038 | compute_lookaheads. | |
1039 | (state_look_ahead_tokens_count): Renamed from state_lookaheads_count. | |
1040 | (look_ahead_tokens_print): Renamed from lookaheads_print. | |
1041 | * src/state.c (state_rule_look_ahead_tokens_print): Renamed from | |
1042 | state_rule_lookaheads_print. | |
1043 | * src/state.h: Likewise. | |
1044 | (reductions.look_ahead_tokens): Renamed from lookaheads. | |
1045 | * tests/torture.at (AT_DATA_LOOK_AHEAD_TOKENS_GRAMMAR): Renamed from | |
1046 | AT_DATA_LOOKAHEADS_GRAMMAR. | |
1047 | ||
57a90331 PE |
1048 | 2004-06-03 Paul Eggert <eggert@cs.ucla.edu> |
1049 | ||
1050 | * README: Update location of patched M4 distribution. | |
1051 | ||
8ed3234a PE |
1052 | 2004-05-30 Albert Chin-A-Young <china@thewrittenword.com> |
1053 | ||
1054 | Don't assume the C++ compiler takes the same arguments as the C compiler | |
1055 | (trivial change). | |
1056 | * configure.ac (O0CXXFLAGS): New var. | |
1057 | * tests/atlocal.in (CXXFLAGS): Use it. | |
1058 | ||
07971983 PE |
1059 | 2004-05-29 Paul Eggert <eggert@cs.ucla.edu> |
1060 | ||
1061 | Fix some "make check" problems with C++ reported by | |
1062 | Albert Chin-A-Young for Tru64 C++ in this thread: | |
1063 | http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00049.html | |
1064 | ||
1065 | * m4/cxx.m4 (BISON_TEST_FOR_WORKING_CXX_COMPILER): Check for std::cerr. | |
1066 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
1067 | Output to a .cc file for C++, not to a .c file. | |
1068 | * tests/calc.at (AT_CHECK_CALC): Likewise. | |
1069 | * tests/regression.at (AT_CHECK_DANCER): Likewise. | |
1070 | * tests/local.at (AT_COMPILE_CXX): Default to OUTPUT.cc, not OUTPUT.c. | |
1071 | ||
29058652 PE |
1072 | 2004-05-28 Albert Chin-A-Young <china@thewrittenword.com> |
1073 | ||
1074 | * tests/calc.at, tests/actions.at: Workaround for SGI | |
1075 | C++ compiler. (trivial change) | |
1076 | ||
62cb8a99 PE |
1077 | 2004-05-27 Paul Eggert <eggert@cs.ucla.edu> |
1078 | ||
fd418816 PE |
1079 | Spent a few hours checking out which prerequisite versions the |
1080 | current sources actually require. I went all the way back to | |
1081 | Gettext 0.10.40, Automake 1.4, and Autoconf 2.57 and investigated | |
1082 | a seemingly endless set of combinations of versions more recent | |
1083 | than that. The bottom line is that the current sources require | |
1084 | fairly recent versions of the build tools, and it'll be some work | |
1085 | to change this. | |
1086 | * configure.ac (AC_PREREQ): Increase from 2.58 to 2.59. | |
1087 | (AM_INIT_AUTOMAKE): Increase from 1.7 to 1.8. | |
1088 | (AM_GNU_GETTEXT_VERSION): Increase from 0.11.5 to 0.12. | |
1089 | Add comments explaining why those particular versions are | |
1090 | currently needed. | |
2fa09258 | 1091 | |
62cb8a99 PE |
1092 | * src/parse-gram.y (lloc_default): Rewrite to avoid compiler bug |
1093 | in SGI MIPSpro 7.4.1m. Problem reported by Albert Chin-A-Young in | |
161a71f3 | 1094 | <http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00037.html>. |
62cb8a99 PE |
1095 | |
1096 | * configure.ac (AC_PREREQ): Bump to 2.58, since 2.57 doesn't work | |
1097 | (it fails with a Autoconf-without-aclocal-m4 diagnostic). | |
1098 | ||
caa52c10 PE |
1099 | 2004-05-26 Paul Eggert <eggert@cs.ucla.edu> |
1100 | ||
1101 | * configure.ac (AM_GNU_GETTEXT_VERSION): Lower it from 0.14.1 to | |
1102 | 0.11.5. Suggested by Bruno Haible. | |
1103 | * bootstrap: Remove gettext version checking. | |
1104 | ||
1105 | * doc/bison.texinfo (Decl Summary): Also mention that %union | |
1106 | can depend on prerequisite types. Problem reported by Tim | |
1107 | Van Holder. | |
1108 | ||
4bfd5e4e PE |
1109 | 2004-05-25 Paul Eggert <eggert@cs.ucla.edu> |
1110 | ||
2cef3017 PE |
1111 | * README: Mention GNU m4 1.4 bugs and Akim's patched version. |
1112 | * README-alpha: Don't tell people not to package this. | |
1113 | ||
b9c85d5c PE |
1114 | * bootstrap: Don't assume $(...) works; use `...` instead. |
1115 | Problem reported by Paul Hilfinger. Also, diagnose non-GNU | |
1116 | gettext better. | |
1117 | ||
4bfd5e4e PE |
1118 | * doc/bison.texinfo (Decl Summary, Bison Options): Clarify what's |
1119 | put into the -d output file, and mention what to do if YYSTYPE is | |
1120 | defined as a macro. | |
1121 | ||
6a36ff94 PE |
1122 | 2004-05-24 Paul Eggert <eggert@cs.ucla.edu> |
1123 | ||
6712933e PE |
1124 | Undo change made earlier today: it caused autopoint to not bring |
1125 | in ABOUT-NLS. Ouch. Instead, substitute our own diagnostic for | |
1126 | autopoint's. | |
1127 | ||
1128 | * bootstrap: Check that gettext version matches what's in | |
1129 | configure.ac. Warn users to ignore robots.txt ERROR 404. | |
1130 | * bootstrap: Undo today's earlier change (logged below). | |
1131 | * configure.ac (AM_GNU_GETTEXT_VERSION): Likewise. | |
b9c85d5c | 1132 | |
6a36ff94 PE |
1133 | The gettext version checking is causing more trouble than it's |
1134 | curing; remove it. Problem reported by Paul Hilfinger. | |
1135 | ||
1136 | * bootstrap: Issue a warning that one can expect a message | |
1137 | 'AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION'. | |
1138 | * configure.ac (AM_GNU_GETTEXT_VERSION): Remove. | |
1139 | ||
209ea708 PE |
1140 | 2004-05-23 Paul Eggert <eggert@cs.ucla.edu> |
1141 | ||
1142 | Ensure that the C++ compiler used for testing actually works on a | |
1143 | simple test program; if not, skip the C++-related tests. Problem | |
1144 | reported by Vin Shelton in: | |
161a71f3 | 1145 | http://lists.gnu.org/archive/html/bug-bison/2004-05/msg00026.html |
209ea708 PE |
1146 | |
1147 | * m4/cxx.m4: New file. | |
1148 | * configure.ac (BISON_TEST_FOR_WORKING_CXX_COMPILER): Add. | |
1149 | * tests/atlocal.in (BISON_CXX_WORKS): Add. | |
1150 | * tests/local.at (AT_COMPILE_CXX): Use it. | |
1151 | ||
41ca2549 PE |
1152 | 2004-05-21 Paul Eggert <eggert@cs.ucla.edu> |
1153 | ||
383e69dc PE |
1154 | * data/glr.c (yylloc): Output this macro even if locations are not |
1155 | being generated, as the GLR parser needs it even in that case. | |
1156 | Problem reported by Troy A. Johnson | |
1157 | <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=195946>. | |
1158 | ||
41ca2549 PE |
1159 | * configure.ac (AC_INIT): Update to 1.875e. |
1160 | ||
e476c87d PE |
1161 | 2004-05-21 Paul Eggert <eggert@cs.ucla.edu> |
1162 | ||
1163 | * NEWS: Version 1.875d. | |
1164 | * configure.ac (AC_INIT): Likewise. | |
1165 | * src/parse-gram.c, src/parse-gram.h: Regenerate with 1.875d. | |
1166 | ||
1167 | * configure.ac (--enable-gcc-warnings): Do not enable -Wshadow, | |
1168 | -Wmissing-prototypes, or -Wstrict-prototypes for C++. The current | |
1169 | lalr1.cc runs afoul of the first, and the last two are no longer | |
1170 | supported by GCC 3.4.0. | |
1171 | * README: Mention GNU m4 1.4 or later; mention m4 patches. | |
1172 | * HACKING: Use ./bootstrap, not "make update" to import foreign files. | |
1173 | ||
233a88ad PE |
1174 | 2004-05-06 Paul Eggert <eggert@cs.ucla.edu> |
1175 | ||
1176 | * src/muscle_tab.c (hash_muscle): Accept and return size_t, not | |
1177 | unsigned int, for compatibility with latest gnulib hash module. | |
1178 | * src/state.c (state_hash, state_hasher): Likewise. | |
1179 | * src/symtab.c (hash_symbol, hash_symbol_hasher): Likewise. | |
1180 | * src/uniqstr.c (hash_uniqstr): Likewise. | |
e476c87d | 1181 | |
12ffdd28 PE |
1182 | 2004-05-03 Paul Eggert <eggert@cs.ucla.edu> |
1183 | ||
1184 | * NEWS: Unescaped newlines are no longer allowed in char & strings. | |
1185 | ||
1186 | * src/scan-gram.l (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER, | |
1187 | SC_CHARACTER,SC_STRING>): Reject unescaped newlines in | |
1188 | character and string literals. | |
1189 | (unexpected_end): New function. | |
1190 | (unexpected_eof): Use it. | |
1191 | (unexpected_newline): New function. | |
1192 | (<INITIAL,SC_AFTER_IDENTIFIER,SC_PRE_CODE>): Coalesce duplicate | |
1193 | actions. | |
e476c87d | 1194 | |
12ffdd28 PE |
1195 | * NEWS: Document %expect-rr. |
1196 | ||
1197 | * bootstrap (--gnulib-srcdir=*, --cvs-user=*): | |
1198 | Fix typo by replacing $1 with $option. | |
1199 | Remove more 'intl'-related files. | |
9668e2be | 1200 | Don't DEFUN AM_INTL_SUBDIR twice. |
12ffdd28 PE |
1201 | |
1202 | * lib/.cvsignore: Add strndup.h. Remove memchr.c, memcmp.c, | |
1203 | memrchr.c, strcasecmp.c, strchr.c, strrchr.c, strspn.c, strtol.c, | |
1204 | strtoul.c. | |
1205 | * m4/.cvsignore: Add exitfail.m4, extensions.m4, gnulib.m4, | |
1206 | hard-locale.m4, mbstate_t.m4, strerror_r.m4, strndup.m4, | |
1207 | xstrndup.m4. Remove glibc21.m4, intdiv0.m4, inttypes-pri.m4, | |
1208 | inttypes.m4, inttypes_h.m4, isc-posix.m4, lcmessage.m4, | |
1209 | stdint_h.m4, uintmax_t.m4, ulonglong.m4. | |
1210 | * src/.cvsignore: Add *.output. | |
1211 | ||
1212 | * src/parse-gram.y: Put copyright notice inside %{ %} so it | |
1213 | gets copied to the output file. | |
e476c87d | 1214 | |
1f65350a PE |
1215 | 2004-04-28 Paul Eggert <eggert@twinsun.com> |
1216 | ||
1217 | Get files from the gnulib and po repositories, instead of relying | |
1218 | on them being in our CVS. Upgrade to latest versions of gnulib | |
1219 | and Automake. | |
1220 | ||
1221 | * Makefile.am (SUBDIRS): Remove m4; Automake now does m4. | |
1222 | * bootstrap: Bootstrap from gnulib and po repositories. | |
1223 | Much of this code was stolen from GNU diff and GNU tar's bootstrap. | |
1224 | * README-cvs: Document these changes. Remove version numbers from | |
1225 | mentions of build tools, since they change so often. Mention Flex. | |
1226 | ||
1227 | * configure.ac (AC_CONFIG_MACRO_DIR): Add, with m4 as arg. | |
1228 | (gl_USE_SYSTEM_EXTENSIONS): Add. | |
12ffdd28 PE |
1229 | (AC_GNU_SOURCE, AC_AIX, AC_MINIX): |
1230 | Remove; no longer needed, as gl_USE_SYSTEM_EXTENSIONS | |
1f65350a | 1231 | does this for us. |
12ffdd28 PE |
1232 | (AC_ISC_POSIX): Remove; we no longer support this |
1233 | ancient OS, as it gets in the way of latest Autoconf & gnulib. | |
1f65350a PE |
1234 | (AC_HEADER_STDC): Remove: we now assume C89 or better. |
1235 | (AC_CHECK_HEADERS_ONCE): Use instead of AC_CHECK_HEADERS. | |
1236 | Do not check for C89 headers, except for locale.h which is used | |
1237 | by the Yacc library and must port to K&R hosts. | |
1238 | (AC_CHECK_FUNCS_ONCE): Use instead of AC_CHECK_FUNCS. | |
1239 | Do not check for C89 functions, except for setlocale which is | |
1240 | used by the Yacc library. | |
1241 | (AC_CHECK_DECLS, AC_REPLACE_FUNCS): Remove; no longer needed. | |
1242 | (gl_DIRNAME, gl_ERROR, gl_FUNC_ALLOCA, gl_FUNC_MEMCHR, | |
1243 | gl_FUNC_MEMRCHR, gl_FUNC_STPCPY, gl_FUNC_STRNLEN, gl_FUNC_STRTOL, | |
1244 | gl_GETOPT, gl_HASH, gl_MBSWIDTH, gl_OBSTACK, gl_QUOTE, | |
1245 | gl_QUOTEARG, gl_XALLOC, jm_FUNC_GLIBC_UNLOCKED_IO, jm_FUNC_MALLOC, | |
1246 | AM_GNU_GETTEXT): Remove; now done by: | |
1247 | (GNULIB_AUTOCONF_SNIPPET): Add. "bootstrap" builds this for us. | |
1248 | (AC_CONFIG_FILES): Remove m4/Makefile, as Automake now does this | |
1249 | for us. | |
1250 | ||
1251 | * lib/Makefile.am: Include gnulib.mk, built for us by "bootstrap". | |
1252 | (BUILT_SOURCES, EXTRA_DIST, MOSTLYCLEANFILES): | |
1253 | Define to empty, as gnulib.mk will do the rest for us. | |
1254 | ($(libbison_a_OBJECTS), stdbool.h): Remove, as gnulib.mk does this | |
1255 | for us. | |
1256 | (libbison_a_SOURCES): Define to $(lib_SOURCES) now. | |
1257 | (lib_SOURCES): New symbol, containing only the non-gnulib libs. | |
1258 | ||
1259 | * src/files.c: Include gnulib's xstrndup.h. | |
1260 | ||
1261 | * src/system.h (MALLOC): Use xnmalloc, for better overflow checking. | |
1262 | (REALLOC): Use xnrealloc, for likewise. | |
1263 | (xstrndup, stpcpy): Remove decls, as gnulib does this for us now. | |
1264 | (strnlen, memrchr): Remove decls; functions no longer used. | |
1265 | Include <stpcpy.h>. | |
1266 | ||
1267 | * config/depcomp, config/install-sh, lib/alloca.c, lib/argmatch.c, | |
1268 | lib/argmatch.h, lib/basename.c, lib/dirname.c, lib/dirname.h, | |
1269 | lib/error.c, lib/error.h, lib/getopt.c, lib/getopt.h, | |
1270 | lib/getopt1.c, lib/gettext.h, lib/hash.c, lib/hash.h, | |
1271 | lib/malloc.c, lib/mbswidth.c, lib/mbswidth.h, lib/memchr.c, | |
1272 | lib/memcmp.c, lib/memrchr.c, lib/obstack.c, lib/obstack.h, | |
1273 | lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, | |
1274 | lib/realloc.c, lib/stdbool_.h, lib/stpcpy.c, lib/strcasecmp.c, | |
1275 | lib/strchr.c, lib/strncasecmp.c, lib/strnlen.c, lib/strrchr.c, | |
1276 | lib/strspn.c, lib/strtol.c, lib/strtoul.c, lib/unlocked-io.h, | |
1277 | lib/xalloc.h, lib/xmalloc.c, lib/xstrdup.c, lib/xstrndup.c, | |
1278 | m4/Makefile.am, m4/alloca.m4, m4/dirname.m4, m4/dos.m4, | |
1279 | m4/error.m4, m4/getopt.m4, m4/hash.m4, m4/malloc.m4, | |
1280 | m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4, m4/memcmp.m4, | |
1281 | m4/memrchr.m4, m4/obstack.m4, m4/onceonly.m4, m4/prereq.m4, | |
1282 | m4/quote.m4, m4/quotearg.m4, m4/realloc.m4, m4/stdbool.m4, | |
1283 | m4/stpcpy.m4, m4/strnlen.m4, m4/strtol.m4, m4/strtoul.m4, | |
1284 | m4/unlocked-io.m4, m4/xalloc.m4, po/LINGUAS, po/Makefile.in.in, | |
1285 | po/Makevars, po/da.po, po/de.po, po/es.po, po/et.po, po/fr.po, | |
1286 | po/hr.po, po/id.po, po/it.po, po/ja.po, po/ms.po, po/nl.po, | |
1287 | po/pt_BR.po, po/ro.po, po/ru.po, po/sv.po, po/tr.po: | |
1288 | Remove, as these files are now generated automatically | |
1289 | by bootstrap or automake. | |
1290 | ||
1291 | * po/ChangeLog: Remove: all but one entry was a duplicate | |
1292 | of this file, and I moved that 2000-11-02 entry here. | |
1293 | ||
1294 | * config/.cvsignore: Add Makefile, depcomp, install-sh. | |
1295 | * lib/.cvsignore: Add alloca.c, alloca.h, alloca_.h, argmatch.c, | |
1296 | argmatch.h, basename.c, dirname.c, dirname.h, error.c, error.h, | |
1297 | exit.h, exitfail.c, exitfail.h, getopt.c, getopt.h, getopt1.c, | |
1298 | getopt_int.h, gettext.h, gnulib.mk, hard-locale.c, hard-locale.h, | |
1299 | hash.c, hash.h, malloc.c, mbswidth.c, mbswidth.h, memchr.c, | |
1300 | memcmp.c, memrchr.c, obstack.c, obstack.h, quote.c, quote.h, | |
1301 | quotearg.c, quotearg.h, realloc.c, stdbool_.h, stpcpy.c, stpcpy.h, | |
1302 | strcasecmp.c, strchr.c, stripslash.c, strncasecmp.c, strndup.c, | |
1303 | strnlen.c, strrchr.c, strspn.c, strtol.c, strtoul.c, | |
1304 | unlocked-io.h, xalloc.h, xmalloc.c, xstrdup.c, xstrndup.c, | |
1305 | xstrndup.h. | |
1306 | * m4/.cvsignore: Remove Makefile, Makefile.in. Add alloca.m4, | |
1307 | dirname.m4, dos.m4, error.m4, getopt.m4, hash.m4, mbrtowc.m4, | |
1308 | mbswidth.m4, obstack.m4, onceonly.m4, quote.m4, quotearg.m4, | |
1309 | stdbool.m4, stpcpy.m4, strnlen.m4, unlocked-io.m4, xalloc.m4. | |
1310 | * po/.cvsignore: Add *.po, LINGUAS, Makefile.in.in, Makevars. | |
1311 | * src/.cvsignore: Remove *_.c. | |
1312 | ||
1313 | ||
1314 | * Makefile.maint (GZIP_ENV): Don't use --rsyncable if gzip doesn't | |
1315 | support it. (The latest stable gzip doesn't.) | |
1316 | ||
1317 | 2004-04-27 Paul Eggert <eggert@twinsun.com> | |
1318 | ||
1319 | * data/lalr1.cc (Parser::stos_) [! YYDEBUG]: Define even in this | |
1320 | case, as stos_ is now used by destructors due to the 2004-02-09 | |
1321 | change. | |
1322 | ||
1323 | Remove more K&R C support. | |
1324 | * lib/libiberty.y (PARAMS): Remove. All uses removed. | |
1325 | * lib/subpipe.c (errno): Remove decl. | |
1326 | Include <stdlib.h> unconditionally. | |
1327 | (EXIT_FAILURE): Remove macro. | |
1328 | * src/complain.c (vfprintf, strerror): Remove. | |
1329 | * src/system.h: Include limits.h, stdlib.h, string.h, locale.h | |
1330 | unconditionally. | |
1331 | (EXIT_FAILURE, EXIT_SUCCESS, setlocale): Remove defns. | |
1332 | Use latest Autoconf recommendations for including inttypes.h, stdint.h. | |
1333 | (strchr, strspn, memchr): Remove decls. | |
1334 | * tests/calc.at (_AT_DATA_CALC_Y): Include stdlib.h, string.h | |
1335 | unconditionally. Do not declare perror. | |
1336 | * tests/conflicts.at (%nonassoc and eof): Include stdlib.h | |
1337 | unconditionally. | |
1338 | ||
1339 | * src/complain.c (_): Remove useless defn, as system.h defines this. | |
1340 | ||
1341 | * lib/bitset.h (__INT_TO_PTR): Remove; workaround no longer needed | |
1342 | with latest obstack.h. | |
1343 | * lib/ebitset.c (ebitset_elt_alloc): Don't bother to cast args | |
1344 | to procedure types, as obstack.h now does that for us. | |
1345 | * lib/lbitset.c (lbitset_elt_alloc): Likewise. | |
1346 | ||
1347 | * lib/subpipe.h [HAVE_SYS_TYPES_H]: Include <sys/types.h>, | |
1348 | so that this include file can stand alone. | |
1349 | * lib/subpipe.c: Do not include <sys/types.h>, as subpipe.h | |
1350 | does this now. Include subpipe.h first after config.h, to | |
1351 | test whether it can stand alone. | |
1352 | ||
1353 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Don't | |
1354 | declare yyerror when using lalr.cc, as GCC 3.4.0 warns about the | |
1355 | unused declaration. | |
1356 | ||
1357 | * tests/synclines.at (%union synch line): Put a dummy member in | |
1358 | the union, because empty unions aren't allowed in C. Caught | |
1359 | by GCC 3.4.0. | |
1360 | ||
4f16766c PE |
1361 | 2004-04-13 Jim Meyering <jim@meyering.net> |
1362 | ||
1363 | * src/conflicts.c (conflicts_print): Correct format string typo: | |
1364 | use `%%' to produce literal `%'. (trivial change) | |
1365 | ||
779e7ceb PE |
1366 | 2004-03-30 Paul Eggert <eggert@twinsun.com> |
1367 | ||
1368 | * src/getargs.c (version): Update copyright year to 2004. | |
1369 | ||
1370 | * data/c.m4 (b4_int_type): Use 'short int' rather than | |
1371 | 'short', and similarly for 'long', 'unsigned', etc. | |
1372 | * data/glr.c (YYTRANSLATE, yyconfl, yySymbol, yyItemNum, | |
1373 | yygetLRActions, yyprocessOneStack, yyrecoverSyntaxError, | |
1374 | yy_yypstack, yydumpstack): Likewise. | |
1375 | * data/lalr1.cc (user_token_number_max_, user_token_number_max_, | |
1376 | translate_, seq_, [], pop, Slice, range_, operator+, operator+=): | |
1377 | Likewise. | |
1378 | * data/yacc.c (b4_int_type, yyss, YYSTACK_BYTES, yysigned_char, | |
1379 | yy_stack_print, yyparse): Likewise. | |
1380 | * doc/bison.texinfo (Prologue, Multiple Types): Likewise. | |
1381 | * lib/bbitset.h (bitset_word, BITSET_WORD_BITS): Likewise. | |
1382 | * lib/bitset.c (bitset_print): Likewise. | |
1383 | * lib/bitset_stats.c (bitste_log_histogram_print): Likewise. | |
1384 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
1385 | * lib/bitsetv.c (bitsetv_dump): Likewise. | |
1386 | * lib/ebitset.c (EBITSET_ELT_BITS, ebitset_elt_alloc): Likewise. | |
1387 | * lib/lbitset.c (LBITSET_ELT_BITS, lbitset_elt_alloc, debug_lbitset): | |
1388 | Likewise. | |
1389 | * src/LR0.c (allocate_itemsets): Likewise. | |
1390 | * src/gram.h (rule_number, rule): Likewise. | |
1391 | * src/lalr.h (goto_number): Likewise. | |
1392 | * src/nullable.c (nullable_compute): Likewise. | |
1393 | * src/output.c (prepare_rules): Likewise. | |
1394 | * src/relation.c (relation_print, relation_digraph): Likewise. | |
1395 | * src/relation.h (relation_node): Likewise. | |
1396 | * src/state.h (state_number, transitions, errs, reductions, | |
1397 | struct state): Likewise. | |
1398 | * src/symtab.h (symbol_number, struct symbol): Likewise. | |
1399 | * src/tables.c (vector_number, tally, action_number, | |
1400 | default_goto, goto_actions): Likewise. | |
1401 | * tests/existing.at (GNU Cim Grammar): Likewise. | |
1402 | * tests/regression.at (Web2c Actions): Likewise. | |
1403 | ||
1404 | * src/output.c (muscle_insert_short_int_table): Renamed from | |
1405 | muscle_insert_short_table. All uses changed. | |
1406 | ||
d6328241 PH |
1407 | 2004-03-25 Paul Hilfinger <hilfingr@tully.CS.Berkeley.EDU> |
1408 | ||
1409 | * src/parse-gram.y: Define PERCENT_EXPECT_RR. | |
1410 | (declaration): Replace expected_conflicts with expected_sr_conflicts. | |
1411 | Add %expect-rr rule. | |
4f16766c | 1412 | |
d6328241 PH |
1413 | * src/scan-gram.l: Recognize %expect-rr. |
1414 | ||
4f16766c | 1415 | * src/conflicts.h (expected_sr_conflicts): Rename from |
d6328241 | 1416 | expected_conflicts. |
4f16766c | 1417 | (expected_rr_conflicts): Declare. |
d6328241 PH |
1418 | |
1419 | * src/conflicts.c (expected_sr_conflicts): Rename from | |
1420 | expected_conflicts. | |
1421 | (expected_rr_conflicts): Define. | |
1422 | (conflicts_print): Check r/r conflicts against expected_rr_conflicts | |
1423 | for GLR parsers. | |
1424 | Use expected_sr_conflicts in place of expected_conflicts. | |
1425 | Warn if expected_rr_conflicts used in non-GLR parser. | |
4f16766c | 1426 | |
d6328241 | 1427 | * doc/bison.texinfo: Add documentation for %expect-rr. |
4f16766c | 1428 | |
1452af69 PE |
1429 | 2004-03-08 Paul Eggert <eggert@gnu.org> |
1430 | ||
1431 | Add support for hex token numbers. Suggested by Odd Arild Olsen in | |
161a71f3 | 1432 | <http://lists.gnu.org/archive/html/bison-patches/2004-03/msg00000.html>. |
1452af69 PE |
1433 | |
1434 | * NEWS: Document hexadecimal tokens, no NUL bytes, %destructor | |
1435 | in lalr1.cc. | |
1436 | * doc/bison.texinfo (Token Decl): Add hexadecimal token numbers. | |
1437 | * src/scan-gram.l (scan_integer): New function. | |
1438 | ({int}): Use it. | |
1439 | (0[xX][0-9abcdefABCDEF]+): New pattern, to support hex numbers. | |
1440 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>, \\x[0-9abcdefABCDEF]+, | |
1441 | handle_action_dollar, handle_action_at, convert_ucn_to_byte): | |
1442 | Say "long int", not "long", for uniformity with GNU style. | |
1443 | ||
006d217d PE |
1444 | 2004-02-25 Paul Eggert <eggert@twinsun.com> |
1445 | ||
1446 | * tests/local.at (AT_COMPILE, AT_COMPILE_CXX): Ignore stdout from | |
1447 | compilers. This fixes a problem with Intel's C++ compiler being | |
1448 | chatty, reported by Guido Trentalancia in | |
161a71f3 | 1449 | <http://lists.gnu.org/archive/html/bug-bison/2004-02/msg00030.html>. |
006d217d | 1450 | |
c2729758 ADL |
1451 | 2004-02-09 Alexandre Duret-Lutz <adl@gnu.org> |
1452 | ||
1453 | Support %destructor and merge error locations in lalr1.cc. | |
1454 | ||
1455 | * data/lalr1.cc (b4_cxx_destruct_def): New macro. | |
1456 | (Parser::stos_): Define unconditionally. | |
1457 | (Parser::destruct_): New method. Generate its body with | |
1458 | b4_yydestruct_generate. | |
1459 | (Parser::error_start_): New attribute. | |
1460 | (Parser::parse) <yyerrlab, yyerrlab1>: Call destruct_ on erroneous | |
1461 | token which are discarded. | |
1462 | (Parser::parse) <yyerrlab, yyerrorlab, yyerrlab1>: Update | |
1463 | error_start_ when erroneous token are discarded. | |
1464 | (Parser::parse) <yyerrlab1>: Compute the location of the error | |
1465 | token so that it covers all the discarded tokens. | |
1466 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Adjust so | |
1467 | it can be called with `%skeleton "lalr1.cc"', and do that. | |
1468 | ||
dd0e0635 PE |
1469 | 2004-02-02 Paul Eggert <eggert@twinsun.com> |
1470 | ||
1471 | * src/Makefile.am (AM_CPPFLAGS): New macro. It mentions | |
1472 | $(top_srcdir)/lib and ../lib. This fixes a bug reported | |
1473 | by Paul Hilfinger; the old INCLUDES value didn't mention ../lib. | |
1474 | There's no need to mention top_builddir since Automake does that | |
1475 | for us. | |
1476 | (INCLUDES): Remove, as Automake says it's obsolescent. | |
1477 | Contents migrated into AM_CPPFLAGS as described above. | |
1478 | * lib/Makefile.am (INCLUDES): Remove; obsolescent. | |
1479 | ||
1480 | 2004-01-14 Paul Hilfinger <hilfingr@CS.Berkeley.EDU> | |
1481 | ||
1482 | * data/glr.c (yytokenName): Bullet-proof against YYEMPTY token. | |
1483 | (yyreportSyntaxError): Handle case where lookahead token is | |
1484 | YYEMPTY. | |
1485 | ||
be16239b PH |
1486 | 2004-01-13 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
1487 | ||
1488 | * data/glr.c: Put casts on uses of YYREALLOC and YYMALLOC so that | |
1489 | resulting parsers are compilable with C++. | |
1490 | ||
5fa90832 PE |
1491 | 2003-12-23 Paul Eggert <eggert@twinsun.com> |
1492 | ||
1493 | * config/depcomp, config/install-sh: Sync with Automake 1.8. | |
1494 | * src/output.c (output_skeleton): Rename local var. | |
1495 | * tests/input.at (Torturing the Scanner): Don't use \x0 or \0 in | |
1496 | Bison tokens, as this runs afoul of the 2003-10-07 change that | |
1497 | disallowed NUL bytes in character constants or string literals. | |
1498 | ||
1499 | * tests/local.at: Require Autoconf 2.59's Autotest. | |
1500 | * tests/testsuite.at: Don't include local.at, since we now assume | |
1501 | Autoconf 2.59 or later. Autoconf 2.59 had some problems with | |
1502 | including it. | |
1503 | * tests/Makefile.am ($(TESTSUITE)): Remove warning about ignoring | |
1504 | multiple inclusion warnings. | |
dd0e0635 | 1505 | |
b165c324 AD |
1506 | 2003-12-02 Akim Demaille <akim@epita.fr> |
1507 | ||
1508 | * doc/bison.texinfo (How Can I Reset the Parser): More about start | |
1509 | conditions. | |
1510 | From Bruno Haible. | |
1511 | ||
26e06a21 ADL |
1512 | 2003-11-18 Alexandre Duret-Lutz <adl@gnu.org> |
1513 | ||
1514 | * doc/bison.texinfo (Bison Options): Escape `@' in `$@'. | |
1515 | ||
92ac3705 PE |
1516 | 2003-10-07 Paul Eggert <eggert@twinsun.com> |
1517 | ||
6a5ecb38 PE |
1518 | * tests/Makefile.am (clean-local): Don't run 'testsuite --clean' |
1519 | if testsuite doesn't exist. | |
1520 | ||
92ac3705 PE |
1521 | * doc/bison.texinfo (Symbols): NUL bytes are not allowed in string |
1522 | literals, unfortunately. | |
1523 | * src/scan-gram.l (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>): | |
1524 | Complain about NUL bytes in character constants or string literals. | |
1525 | ||
91d2c560 PE |
1526 | 2003-10-05 Paul Eggert <eggert@twinsun.com> |
1527 | ||
1528 | * NEWS: Don't document %no-default-prec, as it's still | |
1529 | too experimental. | |
1530 | * doc/bison.texinfo: Document %no-default-prec only if | |
1531 | the defaultprec flag is set. Normally it's not. | |
1532 | ||
0cc3da3a PE |
1533 | 2003-10-04 Paul Eggert <eggert@twinsun.com> |
1534 | ||
1535 | * data/glr.c (b4_rhs_value, b4_rhs_location): Yield a | |
1536 | non-modifiable lvalue, instead of a modifiable one. | |
1537 | * doc/bison.texinfo (Actions): Document that $$ can | |
1538 | be assigned to. Do not claim that $$ and $N are | |
1539 | array element references: user code should not rely on this. | |
1540 | ||
22fccf95 PE |
1541 | 2003-10-01 Paul Eggert <eggert@twinsun.com> |
1542 | ||
1543 | * src/parse-gram.h (PERCENT_NO_DEFAULT_PREC): New token. | |
1544 | (grammar_declaration): Use it. | |
1545 | * src/scan-gram.l: New token %no-default-prec. | |
1546 | * tests/conflicts.at: Revamp tests to use %no-default-prec. | |
1547 | * NEWS, doc/bison.texinfo: Document the above. | |
1548 | ||
fc8f2965 AD |
1549 | 2003-10-01 Akim Demaille <akim@epita.fr> |
1550 | ||
1551 | VCG no longer supports long_straight_phase. | |
1552 | ||
1553 | * src/vcg.c, src/vcg.h: Remove the handling of long_straight_phase. | |
1554 | * src/print_graph.c (print_graph): Adjust. | |
1555 | ||
39a06c25 PE |
1556 | 2003-09-30 Frank Heckenbach <frank@g-n-u.de> |
1557 | and Paul Eggert <eggert@twinsun.com> | |
1558 | ||
1559 | * doc/bison.texinfo (Decl Summary, Contextual Precedence, | |
1560 | Table of Symbols): Document %default-prec. | |
1561 | * src/parse-gram.y (PERCENT_DEFAULT_PREC): New token. | |
1562 | (grammar_declaration): Set default_prec on %default-prec. | |
1563 | * src/scan-gram.l (%default-prec): New token. | |
1564 | * src/reader.h (default_prec): New flag. | |
1565 | * src/reader.c: Likewise. | |
1566 | (packgram): Handle it. | |
1567 | * tests/conflicts.at (%default-prec without %prec, | |
1568 | %default-prec with %prec, %default-prec 1): New tests. | |
fc8f2965 | 1569 | |
39a06c25 PE |
1570 | 2003-09-30 Paul Eggert <eggert@twinsun.com> |
1571 | ||
1572 | * tests/testsuite.at: Include local.at, not input.at, fixing | |
1573 | a typo in the 2003-08-25 patch. | |
1574 | ||
62b6aef9 AD |
1575 | 2003-08-27 Akim Demaille <akim@epita.fr> |
1576 | ||
1577 | * data/lalr1.cc (yyparse) [__GNUC__]: "Use" yyerrorlab to pacify | |
1578 | GCC warnings. | |
1579 | ||
89e1cc61 AD |
1580 | 2003-08-26 Akim Demaille <akim@epita.fr> |
1581 | ||
1582 | * config/announce-gen (print_changelog_deltas): Neutralize "<#" as | |
1583 | "<\#" to avoid magic from Gnus when posting parts of this script. | |
1584 | ||
a08460b0 AD |
1585 | 2003-08-26 Akim Demaille <akim@epita.fr> |
1586 | ||
1587 | * data/lalr1.cc (Parser::report_syntax_error_): New, extracted from | |
1588 | (Parser::parse): here. | |
1589 | Adjust: nerrs and errstatus is now replaced by... | |
1590 | (Parser::nerrs_, Parser::errstatus_): New. | |
1591 | ||
603f1cfd AD |
1592 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1593 | ||
1594 | * config/announce-gen, Makefile.cfg: New. | |
1595 | * Makefile.am: Adjust. | |
1596 | * GNUmakefile, Makefile.maint: Update from CVS Autoconf, but | |
1597 | keeping local WGET and WGETFLAGS modifications from Paul Eggert. | |
1598 | ||
cd3684cf AD |
1599 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1600 | ||
1601 | When reducing initial empty rules, Bison parser read an initial | |
1602 | location that is not defined. This results in garbage, and that | |
1603 | affects Bison's own parser. Therefore we need (i) to extend Bison | |
1604 | to support a means to initialize this location, and (ii) to use | |
1605 | this CVS Bison to fix CVS Bison's parser. | |
1606 | ||
1607 | * src/reader.h, reader.c (epilogue_augment): Remove, replace | |
1608 | with... | |
1609 | * src/muscle_tab.h, src/muscle_tab.c (muscle_code_grow): this. | |
1610 | * src/parse-gram.y: Adjust. | |
1611 | (%initial-action): New. | |
1612 | (%error-verbose): Since we require CVS Bison, there is no reason | |
1613 | not to use it. | |
1614 | * src/scan-gram.l: Adjust. | |
1615 | * src/Makefile.am (YACC): New, to make sure we use our own parser. | |
1616 | * data/yacc.c (yyparse): Use b4_initial_action. | |
1617 | ||
4e03e201 AD |
1618 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1619 | ||
1620 | * doc/bison.texinfo: Don't promote stdout for error messages. | |
1621 | ||
8c182d05 AD |
1622 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1623 | ||
1624 | * data/lalr1.cc (Parser::reduce_print_): Remove unused yyi. | |
1625 | From Alexandre Duret-Lutz. | |
1626 | ||
6a60c4cf PE |
1627 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1628 | ||
1629 | Version 1.875c. | |
1630 | ||
25f66e1a AD |
1631 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1632 | ||
1633 | * data/lalr1.cc (Parser::stack_print_, YY_STACK_PRINT): New. | |
1634 | Use them. | |
1635 | ||
5348bfbe AD |
1636 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1637 | ||
1638 | * data/lalr1.cc (Parser::reduce_print_): New. | |
1639 | Use it. | |
1640 | ||
47301314 AD |
1641 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1642 | ||
1643 | Have lalr1.cc catch with Paul Eggert's patch to fix the infinite | |
1644 | error recovery loops. This patch is based on | |
161a71f3 | 1645 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00000.html>. |
47301314 AD |
1646 | Also, augment the similarity between lalr1.cc and yacc.c. |
1647 | Note: the locations of error recovery rules are not correct yet. | |
1648 | ||
1649 | * data/lalr1.cc: Comment changes to augment the similarity between | |
1650 | lalr1.cc and yacc.c. | |
1651 | (YYERROR): Goto to yyerrorlab, not yyerrlab1. | |
1652 | (yyerrlab1): Remove, but where it used to be (now the bottom part of | |
1653 | yyerrlab), when hitting EOF, pop the whole stack here instead of | |
1654 | merely falling thru the default error handling mechanism. | |
1655 | (yyerrorlab): New label, with the old contents of YYERROR, | |
1656 | plus the following change: pop the stack of rhs corresponding | |
1657 | to the production that invoked YYERROR. That is how Yacc | |
1658 | behaves (required by POSIX). | |
1659 | * tests/calc.at (AT_CHECK_CALC_LALR1_CC): No longer expected to | |
1660 | fail. | |
1661 | ||
1f7a61ff AD |
1662 | 2003-08-25 Akim Demaille <akim@epita.fr> |
1663 | ||
1664 | Tune local.at so that people can "autom4te -l autotest calc.at -o | |
1665 | calc" for instance, to extract a sub test suite. | |
1666 | ||
1667 | * tests/testsuite.at: Move the initialization, Autotest version | |
1668 | requirement, and AT_TESTED invocation into... | |
1669 | * tests/local.at: here. | |
1670 | * tests/testsuite.at: Include it for compatibility with Autoconf | |
1671 | 2.57. | |
1672 | * tests/Makefile.am ($(TESTSUITE)): Report that the warning should | |
1673 | be ignore. | |
1674 | ||
327b5b56 PE |
1675 | 2003-08-04 Paul Eggert <eggert@twinsun.com> |
1676 | ||
1677 | Rework code slightly to avoid gcc -Wtraditional warnings. | |
1678 | * data/glr.c (yyuserMerge): Return void, not YYSTYPE. | |
1679 | The returned value is now stored in *YY0. All callers changed. | |
1680 | * src/output.c (merge_output): Adjust to the above change. | |
1681 | ||
0051e3ed PE |
1682 | 2003-07-26 Paul Eggert <eggert@twinsun.com> |
1683 | ||
1684 | * data/glr.c (YYASSERT): New macro. | |
1685 | (yyfillin, yydoAction, yyglrReduce, yysplitStack, | |
1686 | yyresolveStates, yyprocessOneStack): | |
1687 | Use `YYASSERT (FOO);' rather than `if (! (FOO)) abort ();'. | |
1688 | Derived from a suggestion by Frank Heckenbach. | |
1f7a61ff | 1689 | |
137437c6 PE |
1690 | 2003-07-25 Paul Eggert <eggert@twinsun.com> |
1691 | ||
5b620e06 PE |
1692 | * data/glr.c (yyglrReduce): Don't use C89 string concatenation, |
1693 | for portability to K&R C (after ansi2knr, presumably). See | |
161a71f3 | 1694 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00041.html> |
5b620e06 PE |
1695 | by Frank Heckenbach, though I have omitted the structure-initialization |
1696 | part of his glr-knr.diff patch since I recall that the Portable | |
1697 | C Compiler didn't require that change. | |
1698 | ||
137437c6 PE |
1699 | Let the user specify how to allocate and free memory. |
1700 | Derived from a suggestion by Frank Heckenbach in | |
161a71f3 | 1701 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00041.html>. |
137437c6 PE |
1702 | * data/glr.c (YYFREE, YYMALLOC, YYREALLOC): New macros. |
1703 | All uses of free, malloc, realloc changed to use these macros, | |
1704 | and unnecessary casts removed. | |
1705 | * data/yacc.c (YYFREE, YYMALLOC): Likewise. | |
1706 | ||
ddb85ca5 PE |
1707 | 2003-07-06 Matthias Mann <MatthiasMann@gmx.de> |
1708 | ||
1709 | * data/lalr1.cc (operator<<(std::ostream&, const Position&)): | |
1710 | use s.empty() rather than s == "" to test for empty string; see | |
161a71f3 | 1711 | <http://lists.gnu.org/archive/html/bison-patches/2003-07/msg00003.html> |
ddb85ca5 PE |
1712 | (trivial change) |
1713 | ||
39910e09 AD |
1714 | 2003-06-25 Akim Demaille <akim@epita.fr> |
1715 | ||
1716 | * config/depcomp, config/install-sh: Update from masters. | |
1717 | ||
0ae99356 PE |
1718 | 2003-06-20 Paul Eggert <eggert@twinsun.com> |
1719 | ||
1720 | * data/glr.c (YYLLOC_DEFAULT): Parenthesize arguments as needed, | |
1721 | and return properly parenthesized result. | |
1722 | * data/lalar1.cc (YYLLOC_DEFAULT): Likewise. | |
1723 | * data/yacc.c (YYLLOC_DEFAULT): Likewise. | |
1724 | Remove unnecessary parentheses from uses. | |
1725 | * doc/bison.texinfo (Location Default Action): Describe the | |
1726 | conventions for parentheses. | |
1727 | ||
cd05d13c PE |
1728 | 2003-06-19 Paul Eggert <eggert@twinsun.com> |
1729 | ||
81fd08ca PE |
1730 | * data/glr.c (yyremoveDeletes, yy_reduce_print, yyglrReduce, |
1731 | yyreportTree): Do not assume that size_t is the same width as int, | |
1732 | when printing sizes. Print sizes using an unsigned format. | |
1733 | Problem reported by Frank Heckenbach in | |
161a71f3 | 1734 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00035.html>. |
4dcf140b | 1735 | |
cd05d13c PE |
1736 | Port to Forte Developer 7 C compiler. |
1737 | * data/glr.c (struct YYLTYPE): If locations are not being used, | |
1738 | declare a single dummy member, as empty structs do not conform | |
1739 | to the C standard. | |
1740 | (YYERROR, YYBACKUP): Do not use "do { ...; return foo; } while (0)"; | |
1741 | the Forte Developer 7 C compiler complains that end-of-loop | |
1742 | code is not reached. | |
1743 | ||
4dcf140b PE |
1744 | 2003-06-17 Paul Eggert <eggert@twinsun.com> |
1745 | ||
1746 | * lib/libiberty.h (PARAMS): Spell argument as Args, not as X, to | |
1747 | avoid warnings from picky compilers about redefinition of PARAMS. | |
1748 | ||
8dd76bee PE |
1749 | 2003-06-17 Paul Eggert <eggert@twinsun.com> |
1750 | ||
1751 | Version 1.875b. | |
1752 | ||
1753 | * NEWS: Document 1.875b. | |
1754 | ||
1755 | * lib/bbitset.h: Do not include config.h; that's the includer's job. | |
1756 | Do not include <sys/types.h>; shouldn't be needed on a C89 host. | |
1757 | * lib/bitset.h (bitset_compatible_p): Indent as per GNU standard. | |
1758 | Don't use 'index' in comments, as it's a builtin fn on some hosts. | |
1759 | * lib/bitset_stats.c: Include gettext.h unconditionally, as | |
1760 | per recent gettext manual's suggestion. | |
1761 | * lib/ebitset.c (ebitset_resize, ebitset_unused_clear): | |
1762 | Use prototypes, not old-style definitions. | |
1763 | * lib/lbitset.c (lbitset_unused_clear): Likewise. | |
1764 | * lib/vbitset.c (vbitset_resize, vbitset_ones, vbitset_zero, | |
1765 | vbitset_empty_p, vbitset_copy1, vbitset_not, vbitset_equal_p, | |
1766 | vbitset_subset_p, vbitset_disjoint_p, vbitset_and, vbitset_and_cmp, | |
1767 | vbitset_andn, vbitset_andn_cmp, vbitset_or, vbitset_or_cmp, | |
1768 | vbitset_xor, vbitset_xor_cmp, vbitset_and_or, vbitset_and_or_cmp, | |
1769 | vbitset_andn_or, vbitset_andn_or_cmp, vbitset_or_and, | |
1770 | vbitset_or_and_cmp, vbitset_copy): Likewise. | |
1771 | ||
1772 | * lib/libiberty.h: Do not include config.h; that's the includer's job. | |
1773 | Do not include <stdlib.h>. | |
1774 | (PARAMS): Define unconditionally for C89. | |
1775 | (ATTRIBUTE_NORETURN): Remove. | |
1776 | (ATTRIBUTE_UNUSED): Define unconditionally. | |
1777 | ||
1778 | Upgrade to 2003-06-08 libbitset, submitted by Michael Hayes in: | |
161a71f3 | 1779 | <http://lists.gnu.org/archive/html/bison-patches/2003-06/msg00005.html> |
8dd76bee PE |
1780 | * lib/Makefile.am (bitsets_sources): Add vbitset.c, vbitset.h. |
1781 | * lib/vbitset.c, lib/vbitset.h: New files. | |
1782 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
1783 | lib/bitset_stats.c, lib/ebitset.c, lib/lbitset.c: Import | |
1784 | from libbitset. | |
1785 | ||
1786 | * doc/bison.texinfo (How Can I Reset the Parser): Renamed from | |
1787 | `How Can I Reset @code{yyparse}', since texinfo does not allow | |
1788 | arbitrary @ in node names. | |
1789 | ||
1790 | * m4/Makefile.am (EXTRA_DIST): Add the following files, which | |
1791 | shouldn't be needed according to the gettext 0.12.1 documentation | |
1792 | but which seem to be needed anyway: codeset.m4 glibc21.m4 | |
f8e8262e | 1793 | intdiv0.m4 inttypes-pri.m4 inttypes.m4 inttypes_h.m4 isc-posix.m4 |
8dd76bee | 1794 | lcmessage.m4 nls.m4 po.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4. |
f8e8262e | 1795 | * po/Makefile.in.in: Upgrade to gettext 0.12.1 version. |
cd05d13c | 1796 | |
8dd76bee PE |
1797 | * lib/.cvsignore: Add stdbool.h. |
1798 | * m4/.cvsignore: Add nls.m4, po.m4. | |
1799 | ||
1800 | Upgrade to CVS gnulib. | |
1801 | * stdbool_.h: File renamed from stdbool.h.in. | |
1802 | * configure.ac (AM_STDBOOL_H): Invoke this instead of | |
1803 | AC_HEADER_STDBOOL. | |
1804 | (AM_GNU_GETTEXT): Put brackets around args, as latest manual suggests. | |
1805 | (AM_GNU_GETTEXT_VERSION): Update to 0.12.1. | |
1806 | * lib/Makefile.am (EXTRA_DIST): Add stdbool_.h. | |
1807 | (MOSTLYCLEANFILES): New var. | |
1808 | ($(libbison_a_OBJECTS)): Depend on $(STDBOOL_H). | |
1809 | (stdbool.h): New rule. | |
1810 | * lib/dirname.c, lib/dirname.h, lib/hash.c, lib/hash.h, | |
1811 | lib/malloc.c, lib/obstack.h, lib/quote.c, lib/realloc.c, | |
1812 | lib/strcasecmp.c, lib/xalloc.h, m4/alloca.m4, m4/onceonly.m4, | |
1813 | m4/quote.m4: Upgrade to today's gnulib. | |
1814 | ||
1815 | * tests/calc.at (AT_CHECK_CALC): New option EXPECTED-TO-FAIL. | |
1816 | (AT_CHECK_CALC_LALR1_CC): Use it, since the C++ LALR parser fails | |
1817 | the tests right now. | |
1818 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Ensure yylex and | |
1819 | yyerror are declared before use; C99 requires this. | |
1820 | ||
25005f6a PH |
1821 | 2003-06-09 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
1822 | ||
1823 | * data/glr.c (YYERROR): Update definition to reset yyerrState to 0 | |
1824 | first. | |
1825 | (yyrecoverSyntaxError): Correct the logic for setting and testing | |
1826 | yyerrState. | |
1827 | Correct comment on handling EOF. | |
1828 | Allow states with only a default reduction, rather than failing | |
8dd76bee | 1829 | (I can't quite reconstruct why these were not allowed before). |
25005f6a | 1830 | |
137437c6 | 1831 | Fixes to avoid problem that $-N rules in GLR parsers can cause |
25005f6a | 1832 | buffer overruns, corrupting state. |
8dd76bee PE |
1833 | |
1834 | * src/output.c (prepare_rules): Output max_left_semantic_context | |
25005f6a PH |
1835 | definition. |
1836 | * src/reader.h (max_left_semantic_context): New variable declaration. | |
1837 | * src/scan-gram.l (max_left_semantic_context): Define. | |
1838 | (handle_action_dollar): Update max_left_semantic_context. | |
1839 | * data/glr.c (YYMAXLEFT): New definition. | |
1840 | (yydoAction): Increase size of yyrhsVals by YYMAXLEFT. | |
1841 | (yyresolveAction): Ditto. | |
1842 | ||
1843 | Fixes to problems with location handling in GLR parsers reported by | |
1844 | Frank Heckenbach (2003/06/05). | |
1845 | ||
1846 | * data/glr.c (YYLTYPE): Make trivial if locations not used. | |
1847 | (YYRHSLOC): Add parentheses, and define only if locations used. | |
1848 | (YYLLOC_DEFAULT): Add parentheses, and give trivial definition if | |
1849 | locations not used. | |
1850 | (yyuserAction): Use YYLLOC_DEFAULT to set *yylocp. | |
1851 | (yydoAction): Remove redundant initialization of *yyvalp and *yylocp. | |
8dd76bee | 1852 | |
25005f6a PH |
1853 | * tests/cxx-type.at: Exercise location information; update tests |
1854 | to differentiate output with and without locations. | |
8dd76bee | 1855 | Remove forward declarations of yylex and yyerror---caused errors |
25005f6a PH |
1856 | because default YYLTYPE not yet defined. |
1857 | Change semantic actions to compute strings, rather than printing | |
1858 | them directly (to test proper passing of semantics values). Change | |
1859 | output to prefix notation and update test data and expected results. | |
1860 | (yylex): Track locations. | |
1861 | (stmtMerge): Return value rather than printing, and include arguments | |
1862 | in value. | |
8dd76bee | 1863 | |
711f40b7 PE |
1864 | 2003-06-03 Paul Eggert <eggert@twinsun.com> |
1865 | ||
1866 | Avoid warnings generated by GCC 2.95.4 when Bison is | |
1867 | configured with --enable-gcc-warnings. | |
1868 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse, | |
1869 | yy::]b4_parser_class_name[::translate_, | |
1870 | yy::Stack::operator[] (unsigned), | |
1871 | yy::Stack::operator[] (unsigned) const, | |
1872 | yy::Slice::operator[] (unsigned), | |
1873 | yy::Slice::operator[] (unsigned) const): | |
1874 | Rename local vars to avoid warnings. | |
1875 | * tests/glr-regression.at (Improper handling of embedded actions | |
1876 | and $-N in GLR parsers): Remove unused local variable from yylex. | |
1877 | * tests/regression.at (_AT_DATA_DANCER_Y): Declare yylex to take | |
1878 | (void) as arg when not pure, since we now assume C89 when building | |
1879 | Bison. Pacify GCC by using parameter. | |
1880 | ||
ac695f7d PE |
1881 | 2003-06-02 Paul Eggert <eggert@twinsun.com> |
1882 | ||
1883 | * data/lalr1.cc (yy::Position::lines, yy::Position::columns, | |
1884 | yy::Location::lines, yy::Location::columns): Rename arguments | |
1885 | to avoid shadowing; this removes a warning generated by GCC 3.3. | |
1886 | ||
26ec81e0 PE |
1887 | 2003-06-01 Paul Eggert <eggert@twinsun.com> |
1888 | ||
1889 | Don't pass C-only warning optins (e.g., -Wmissing-declarations) | |
1890 | to g++, as GCC 3.3 complains if you do it. | |
1891 | * configure.ac (WARNING_CXXFLAGS): New subst. Set it to | |
1892 | everything that WARNING_CFLAGS has, except omit warnings | |
1893 | not suitable for C++. | |
1894 | (AC_PROG_CXX): Use this instead of AC_CHECK_PROGS([CXX], [g++]). | |
1895 | * tests/atlocal.in (CXXFLAGS): New var. | |
1896 | * tests/local.at (AT_COMPILE_CXX): Use it instead of CFLAGS. | |
1897 | ||
1898 | Fix a GLR parser bug I reported in February; see | |
161a71f3 | 1899 | <http://lists.gnu.org/archive/html/bison-patches/2003-02/msg00008.html>. |
26ec81e0 PE |
1900 | The problem was that GLR parsers did not conform to the C standard, |
1901 | because actions like { $1 = $2 + $3; } expanded to expressions | |
1902 | that invoked YYFILL in separate subexpressions, and YYFILL assigned | |
1903 | to a local variable. The C standard says that expressions | |
1904 | like (var = f ()) + (var = f ()) have undefined behavior. | |
1905 | Another problem was that GCC sometimes issues warnings that | |
1906 | yyfill and its parameters are unused. | |
1907 | ||
1908 | * data/glr.c (yyfillin): Renamed from the old yyfill. Mark | |
1909 | as possibly unused. | |
1910 | (yyfill): New function. | |
1911 | (YYFILL): Use it. | |
1912 | (yyuserAction): Change type of yynormal to bool, so that it matches | |
1913 | the new yyfill signature. Mark it as possibly unused. | |
1914 | ||
1915 | ||
1916 | Follow up on a bug I reported in February, where a Bison-generated | |
1917 | parser can loop. Provide a test case and a fix for yacc.c. I | |
1918 | don't have a fix for lalr1.cc or for glr.c, unfortunately. | |
1919 | The original bug report is in: | |
161a71f3 | 1920 | <http://lists.gnu.org/archive/html/bison-patches/2003-02/msg00044.html> |
26ec81e0 PE |
1921 | |
1922 | * data/yacc.c (YYERROR): Now just 'goto yyerrorlab', since the | |
1923 | macro's size was becoming unwieldy. | |
1924 | (yyerrlab): Do not discard an empty lookahead symbol, as this | |
1925 | might destroy garbage. | |
1926 | (yyerrorlab): New label, with the old contents of YYERROR, | |
1927 | plus the following change: pop the stack of rhs corresponding | |
1928 | to the production that invoked YYERROR. That is how Yacc | |
1929 | behaves, and POSIX requires this behavior. | |
1930 | (yyerrlab1): Use YYPOPSTACK instead of its definiens. | |
1931 | * tests/calc.at (_AT_DATA_CALC_Y): Include unistd.h if available. | |
1932 | Define 'alarm' to do nothing if unistd.h is not available. | |
1933 | Add a new rule "exp: '-' error;" to test the above change to | |
1934 | data/yacc.c. Use 'alarm' to abort any test taking longer than | |
1935 | 10 seconds, as it's probably looping. | |
1936 | (AT_CHECK_CALC): Test recovery from error in new grammar rule. | |
1937 | Also, the new yacc.c generates two fewer diagnostics for an | |
1938 | existing test. | |
1939 | ||
d0829076 PE |
1940 | 2003-05-24 Paul Eggert <eggert@twinsun.com> |
1941 | ||
c6ae27df PE |
1942 | * data/glr.c (YYSTACKEXPANDABLE): Do not evaluate |
1943 | YYSTYPE_IS_TRIVIAL or YYSTYPE_IS_TRIVIAL unless they are defined. | |
1944 | This fixes a problem reported by John Bowman when the Compaq/HP | |
1945 | Alpha cxx compiler happy (e.g. using cxx -D__USE_STD_IOSTREAM | |
1946 | -ansi -Wall -gall). | |
1947 | * data/yacc.c (union yyalloc): Likewise. | |
1948 | (YYCOPY): Do not evaluate __GNUC__ unless it is defined. | |
26ec81e0 | 1949 | |
d0829076 PE |
1950 | Switch from 'int' to 'bool' where that makes sense. |
1951 | ||
1952 | * lib/abitset.c (abitset_test, abitset_empty_p, abitset_equal_p, | |
1953 | abitset_subset_p, abitset_disjoint_p, abitset_and_cmp, | |
1954 | abitset_andn_cmp, abitset_or_cmp, abitset_xor_cmp, abitset_and_or, | |
1955 | abitset_and_or_cmp, abitset_andn_or_cmp, abitset_or_and_cmp): | |
1956 | Return or accept bool, not int. All callers changed. | |
1957 | * lib/bbitset.h: (bitset_toggle_, bitset_copy_, bitset_and_or_cmp_, | |
1958 | bitset_andn_or_cmp_, bitset_or_and_cmp_): Likewise. | |
1959 | * lib/bitset.c (bitset_only_set_p, bitset_print, bitset_toggle_, | |
1960 | bitset_copy_, bitset_op4_cmp, bitset_and_or_cmp_, bitset_andn_or_cmp_, | |
1961 | bitset_or_and_cmp_): Likewise. | |
1962 | * lib/bitset.h (bitset_test, bitset_only_set_p): Likewise. | |
1963 | * lib/bitset_stats.c (bitset_stats_print, bitset_stats_toggle, | |
1964 | bitset_stats_test, bitset_stats_empty_p, bitset_stats_disjoint_p, | |
1965 | bitset_stats_equal_p, bitset_stats_subset_p, bitset_stats_and_cmp, | |
1966 | bitset_stats_andn_cmp, bitset_stats_or_cmp, bitset_stats_xor_cmp, | |
1967 | bitset_stats_and_or_cmp, bitset_stats_andn_or_cmp, | |
1968 | bitset_stats_or_and_cmp): Likewise. | |
1969 | * lib/ebitset.c (ebitset_elt_zero_p, ebitset_equal_p, ebitset_copy_cmp, | |
1970 | ebitset_test, ebitset_empty_p, ebitset_subset_p, ebitset_disjoint_p, | |
1971 | ebitset_op3_cmp, ebitset_and_cmp, ebitset_andn_cmp, ebitset_or_cmp, | |
1972 | ebitset_xor_cmp): Likewise. | |
1973 | * lib/lbitset.c (lbitset_elt_zero_p, lbitset_equal_p, lbitset_copy_cmp, | |
1974 | lbitset_test, lbitset_empty_p, lbitset_subset_p, lbitset_disjoint_p, | |
1975 | lbitset_op3_cmp, lbitset_and_cmp, lbitset_andn_cmp, lbitset_or_cmp, | |
1976 | lbitset_xor_cmp): Likewise. | |
1977 | * lib/bbitset.h: Include <stdbool.h>. | |
1978 | (struct bitset_vtable): The following members now return bool, not | |
1979 | int: toggle, test, empty_p, disjoint_p, equal_p, subset_p, | |
1980 | and_cmp, andn_cmp, or_cmp, xor_cmp, and_or_cmp, andn_or_cmp, | |
1981 | or_and_cmp). | |
1982 | * src/conflicts.c (count_rr_conflicts): Likewise. | |
1983 | * lib/bitset_stats.h (bitset_stats_enabled): Now bool, not int. | |
1984 | All uses changed. | |
1985 | * lib/ebitset.c (ebitset_obstack_init): Likewise. | |
1986 | * lib/lbitset.c (lbitset_obstack_init): Likewise. | |
1987 | * src/getargs.c (debug_flag, defines_flag, locations_flag, | |
1988 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
1989 | graph_flag): Likewise. | |
1990 | * src/getargs.h (debug_flag, defines_flag, locations_flag, | |
1991 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
1992 | graph_flag): Likewise. | |
1993 | * src/output.c (error_verbose): Likewise. | |
1994 | * src/output.h (error_verbose): Likewise. | |
1995 | * src/reader.c (start_flag, typed): Likewise. | |
1996 | * src/reader.h (typed): Likewise. | |
1997 | * src/getargs.c (LOCATIONS_OPTION): New constant. | |
1998 | (long_options, getargs): Use it. | |
1999 | * src/lalr.c (build_relations): Use bool, not int. | |
2000 | * src/nullable.c (nullable_compute): Likewise. | |
2001 | * src/print.c (print_reductions): Likewise. | |
2002 | * src/tables.c (action_row, pack_vector): Likewise. | |
2003 | * src/muscle_tab.h (MUSCLE_INSERT_BOOL): New macro. | |
2004 | * src/output.c (prepare): Use it. | |
2005 | * src/output.c (token_definitions_output, | |
2006 | symbol_destructors_output, symbol_destructors_output): Use string, | |
2007 | not boolean integer, to keep track of whether to output separator. | |
2008 | * src/print_graph.c (print_core): Likewise. | |
2009 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
2010 | ||
2011 | * config/install-sh: Sync from automake 1.7.5. | |
2012 | ||
6b2584b7 PE |
2013 | 2003-05-14 Paul Eggert <eggert@twinsun.com> |
2014 | ||
2015 | * src/parse-gram.y (rules_or_grammar_declaration): Require a | |
2016 | semicolon after a grammar declaration, in the interest of possible | |
2017 | future changes to the Bison input language. | |
2018 | Do not allow a stray semicolon at the start of the grammar. | |
2019 | (rhses.1): Allow one or more semicolons after any rule, including | |
2020 | just before "|" as required by POSIX. | |
2021 | * tests/input.at (Torturing the Scanner): Add tests for ";|" in a | |
2022 | grammar. | |
2023 | ||
caf37a36 ADL |
2024 | 2003-05-14 Alexandre Duret-Lutz <adl@gnu.org> |
2025 | ||
2026 | %parse-param support for lalr1.cc. | |
2027 | ||
2028 | * data/lalr1.cc (b4_parse_param_decl, b4_parse_param_cons, | |
2029 | b4_cc_constructor_calls, b4_cc_constructor_call, | |
2030 | b4_parse_param_vars, b4_cc_var_decls, b4_cc_var_decl): New m4 | |
2031 | definitions. | |
2032 | (yy::b4_parser_class_name::b4_parser_class_name): Take extra | |
2033 | parse-param arguments. | |
2034 | (yy::b4_parser_class_name): Declare instance variables to | |
2035 | hold parse-param arguments. | |
2036 | * tests/calc.at: s/value/semantic_value/ because value clashes | |
2037 | with a member of yy::b4_parser_class_name. Adjust C++ code | |
2038 | to handle %parse-param. Enable %parse-param test in C++. | |
2039 | ||
3ab37077 PE |
2040 | 2003-05-12 Paul Eggert <eggert@twinsun.com> |
2041 | ||
2042 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): Reword the | |
2043 | English a bit. Fix fclose typo. Change "const char" to "char | |
2044 | const", and use ANSI C rather than K&R for "main". Suggest | |
2045 | YY_FLUSH_BUFFER over yyrestart (as that is what Flex recommends) | |
2046 | and suggest yy_switch_to_buffer. | |
2047 | ||
2048 | 2003-05-05 Paul Eggert <eggert@twinsun.com> | |
163ab321 PE |
2049 | |
2050 | * lib/bitset.h (__INT_TO_PTR): Define to a value that presumes | |
2051 | C89. This avoids a diagnostic on compilers that define __STDC__ | |
2052 | to 0, fixing a problem with Tru64 cc reported by Martin Mokrejs in | |
161a71f3 | 2053 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. |
163ab321 | 2054 | |
e743727f PE |
2055 | 2003-05-03 Paul Eggert <eggert@twinsun.com> |
2056 | ||
2057 | * lib/bitset.h (BITSET_FOR_EACH, BITSET_FOR_EACH_REVERSE): | |
2058 | Do not overrun array bounds. | |
2059 | This should fix a bug reported today by Olatunji Oluwabukunmi in | |
161a71f3 | 2060 | <http://lists.gnu.org/archive/html/bug-bison/2003-05/msg00004.html>. |
e743727f | 2061 | |
916708d5 AD |
2062 | 2003-04-29 Akim Demaille <akim@epita.fr> |
2063 | ||
2064 | * src/gram.h, src/gram.c (pure_parser, glr_parser): Move to... | |
2065 | * src/getargs.c, src/getargs.h: here, as bool, not int. | |
2066 | (nondeterministic_parser): New. | |
2067 | * src/parse-gram.y, src/scan-gram.l: Support | |
2068 | %nondeterministic-parser. | |
2069 | * src/output.c (prepare): Use nondeterministic_parser instead | |
2070 | of glr_parser where appropriate. | |
2071 | * src/tables.c (conflict_row, action_row, save_row) | |
2072 | (token_actions, token_actions, pack_vector): Ditto. | |
2073 | ||
a06ea4aa AD |
2074 | 2003-04-29 Akim Demaille <akim@epita.fr> |
2075 | ||
2076 | * doc/bison.texinfo (C++ Parsers, Implementing Loops): New. | |
2077 | ||
211074ca AD |
2078 | 2003-04-29 Akim Demaille <akim@epita.fr> |
2079 | ||
2080 | * tests/calc.at: Also test yacc.c and glr.c (but not lalr1.cc yet) | |
2081 | with %pure-parser and %locations to exercise the patch from Yakov | |
2082 | Markovitch below. | |
2083 | ||
6175ffe3 PE |
2084 | 2003-04-28 Tim Van Holder <tim.van.holder@pandora.be> |
2085 | ||
2086 | * data/yacc.c: (b4_lex_param): Corrected for the case where | |
2087 | %lex-param is provided and %pure-parser isn't. | |
2088 | ||
b1e95857 PE |
2089 | 2003-04-27 Paul Eggert <eggert@twinsun.com> |
2090 | ||
2091 | Avoid gcc -Wundef warnings reported by Gerald Pfeifer in | |
161a71f3 | 2092 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00044.html>. |
b1e95857 PE |
2093 | * data/yacc.c (YYSTACK_ALLOC): Don't evaluate YYSTACK_USE_ALLOCA |
2094 | if it is not defined. | |
2095 | (YYMAXDEPTH): Don't evaluate YYMAXDEPTH if it is not defined. | |
2096 | ||
acda9df6 PE |
2097 | 2003-04-26 Paul Eggert <eggert@twinsun.com> |
2098 | ||
3470c57b PE |
2099 | * data/lalr1.cc (yy::Parser::pact_ninf_, yy::Parser::table_ninf_): |
2100 | Declare to be of type suitable for the ninf value itself, not of | |
2101 | type suitable for the corresponding table, since the latter might | |
2102 | be unsigned but the ninf value might be negative. This fixes a | |
2103 | bug reported by Alexandre Duret-Lutz in | |
161a71f3 | 2104 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00017.html>. |
3470c57b | 2105 | |
acda9df6 PE |
2106 | * configure.ac (AC_FUNC_ERROR_AT_LINE): Remove, since gl_ERROR |
2107 | invokes it. We shouldn't invoke it twice because it will attempt | |
2108 | to put error.o in the archive twice. This fixes a glitch reported | |
2109 | by Martin Mokrejs in | |
161a71f3 | 2110 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. |
acda9df6 | 2111 | |
b5250f26 PE |
2112 | 2003-04-21 Paul Eggert <eggert@twinsun.com> |
2113 | ||
2114 | * m4/error.m4: Update from Bruno Haible's 2003-04-14 patch | |
2115 | to gnulib. | |
2116 | ||
089ac0f1 PE |
2117 | 2003-04-21 Yakov Markovitch <Markovitch@iso.ru> |
2118 | ||
2119 | * data/glr.c (yyexpandGLRStack) [!YYSTACKEXPANDABLE]: | |
2120 | Fix obvious typo that results in uncompilable GLR parsers | |
2121 | when both %pure-parser and %locations are used. (trivial change) | |
2122 | ||
5ededac6 PE |
2123 | 2003-04-17 Paul Eggert <eggert@twinsun.com> |
2124 | ||
1b8f2fff PE |
2125 | * src/scan-gram.l: Add %option nounput, since we no longer use unput. |
2126 | (unexpected_eof): Renamed from unexpected_end_of_file, for brevity. | |
2127 | Do not insert the expected token via unput, as this runs afoul | |
2128 | of a POSIX-compatibility bug in flex 2.5.31. | |
2129 | All uses changed to BEGIN the parent state, | |
2130 | since we no longer insert the expected token via unput. | |
2131 | * tests/regression.at (Invalid inputs): Remove cascaded diagnostic | |
2132 | that is no longer emitted after the above change. | |
2133 | ||
5ededac6 PE |
2134 | * src/conflicts.c (set_conflicts): Resolve all conflicts, not just |
2135 | the first one. This change is from Paul Hilfinger, and it fixes | |
2136 | regression reported by Werner Lemberg in | |
161a71f3 | 2137 | <http://lists.gnu.org/archive/html/bug-bison/2003-04/msg00026.html>. |
5ededac6 PE |
2138 | |
2139 | (resolve_sr_conflict): Don't invoke state_errs_set | |
2140 | unless one or more tokens have been explicitly made errors. | |
2141 | Otherwise, the above change causes Bison to abort. | |
2142 | ||
2143 | * tests/existing.at (GNU pic Grammar): New test case, taken from | |
2144 | Lemberg's email. | |
2145 | ||
b8be9132 AD |
2146 | 2003-03-31 Akim Demaille <akim@epita.fr> |
2147 | ||
2148 | * doc/Makefile.am (AM_MAKEINFOFLAGS): Don't split the info file. | |
2149 | ||
d423d460 AD |
2150 | 2003-03-31 Akim Demaille <akim@epita.fr> |
2151 | ||
2152 | * src/output.c (prepare_symbols): Avoid trailing spaces in the | |
2153 | output. | |
2154 | ||
c7e441b4 AD |
2155 | 2003-03-31 Akim Demaille <akim@epita.fr> |
2156 | ||
2157 | * doc/bison.texinfo (Strings are Destroyed): s/losses/loses/. | |
2158 | From Paul Hilfinger. | |
2159 | ||
231897ad AD |
2160 | 2003-03-29 Akim Demaille <akim@epita.fr> |
2161 | ||
2162 | * m4/error.m4: Do not put under dynamic conditions some code which | |
2163 | expansion is under static control. | |
2164 | ||
5b066063 AD |
2165 | 2003-03-29 Akim Demaille <akim@epita.fr> |
2166 | ||
2167 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): New. | |
2168 | ||
22a74fec AD |
2169 | 2003-03-29 Akim Demaille <akim@epita.fr> |
2170 | ||
2171 | * doc/bison.texinfo (Strings are Destroyed): New. | |
2172 | ||
0eee27e7 PE |
2173 | 2003-03-13 Paul Eggert <eggert@twinsun.com> |
2174 | ||
2175 | * .cvsignore: Add configure.lineno. | |
2176 | * src/.cvsignore: Add yacc. | |
2177 | * tests/.cvsignore: Add testsuite.log. | |
2178 | * doc/fdl.texi: Sync with latest FSF version. | |
2179 | ||
f61aad93 PE |
2180 | 2003-03-12 Paul Eggert <eggert@twinsun.com> |
2181 | ||
537636c7 PE |
2182 | * scan-gram.l (YY_USER_INIT): Initialize code_start, too. |
2183 | (<INITIAL><<EOF>>, <SC_PRE_CODE><<EOF>>): Set *loc to the scanner | |
2184 | cursor, instead of leaving it undefined. This fixes a bug | |
2185 | reported by Tim Van Holder in | |
161a71f3 | 2186 | <http://lists.gnu.org/archive/html/bug-bison/2003-03/msg00023.html>. |
537636c7 PE |
2187 | * tests/input.at (Torturing the Scanner): Test the scanner on |
2188 | an empty input file, which was Tim Van Holder's test case. | |
2189 | ||
2190 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): When checking whether | |
2191 | <sys/resource.h> can be included, include sys/time.h and | |
2192 | sys/times.h first, if available. This works around the SunOS | |
2193 | 4.1.4 porting bug reported by Bruce Becker in | |
161a71f3 | 2194 | <http://lists.gnu.org/archive/html/bug-bison/2003-03/msg00018.html>. |
537636c7 PE |
2195 | |
2196 | * m4/subpipe.m4 (BISON_PREREQ_SUBPIPE): Don't | |
2197 | AC_CHECK_HEADERS([sys/wait.h]), as this interferes with | |
2198 | AC_HEADER_SYS_WAIT. | |
2199 | ||
f61aad93 PE |
2200 | Merge changes from gnulib. This was prompted because the CVS |
2201 | snapshot didn't build on Solaris 7 due to strnlen problems. | |
2202 | ||
2203 | These changes need to be merged back into gnulib: | |
2204 | * lib/hash.c: Include <stdbool.h> unconditionally. | |
2205 | * m4/onceonly.m4 (m4_quote): New macro. | |
2206 | (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE): | |
2207 | Quote AC_FOREACH variable-expansions properly. | |
2208 | The 2003-01-03 obstack.h change also needs merging. | |
2209 | {end of changes requiring merging} | |
5b066063 | 2210 | |
f61aad93 PE |
2211 | * lib/stdbool.h.in, m4/alloca.m4, m4/dirname.m4, m4/dos.m4, |
2212 | m4/getopt.m4, m4/hash.m4, m4/malloc.m4, m4/memchr.m4, | |
2213 | m4/memrchr.m4, m4/obstack.m4, m4/onceonly.m4, m4/quote.m4, | |
2214 | m4/quotearg.m4, m4/realloc.m4, m4/stpcpy.m4, m4/strnlen.m4, | |
2215 | m4/strtol.m4, m4/strtoul.m4, m4/unlocked-io.m4, m4/xalloc.m4: | |
2216 | New files, imported from gnulib. | |
2217 | * m4/Makefile.am (EXTRA_DIST): Add the new m4/*.m4 files mentioned | |
2218 | above. | |
2219 | ||
2220 | * lib/mbswidth.c, m4/error.m4, m4/mbrtowc.m4, m4/mbswidth.m4, | |
2221 | m4/memcmp.m4, m4/prereq.m4, m4/stdbool.m4: Update to current | |
2222 | gnulib sources. | |
2223 | ||
2224 | * configure.ac (gl_DIRNAME, gl_GETOPT, gl_HASH, gl_QUOTE, gl_XALLOC): | |
2225 | Add. | |
2226 | (gl_ERROR): New, replacing jm_PREREQ_ERROR. | |
2227 | (gl_FUNC_ALLOCA): New, replacing AC_FUNC_ALLOCA. | |
2228 | (gl_FUNC_STPCPY): New, replacing AC_REPLACE_FUNCS(stpcpy). | |
2229 | (gl_FUNC_STRNLEN): New, replacing AC_FUNC_STRNLEN. | |
2230 | (gl_MBSWIDTH): New, replacing jm_PREREQ_MBSWIDTH. | |
2231 | (gl_OBSTACK): New, replacing AC_FUNC_OBSTACK. | |
2232 | (gl_QUOTEARG): New, replacing jm_PREREQ_QUOTEARG. | |
2233 | (jm_FUNC_GLIBC_UNLOCKED_IO, gl_FUNC_STPCPY, gl_FUNC_STRTOL): New. | |
2234 | (jm_FUNC_MALLOC): New, replacing AC_FUNC_MALLOC. | |
2235 | (jm_FUNC_REALLOC): New, replacing AC_FUNC_REALLOC. | |
2236 | (jm_PREREQ_ARGMATCH): Remove. | |
2237 | (AC_REPLACE_FUNCS): Remove memchr, memrchr, stpcpy, strtol, strtoul. | |
2238 | * lib/Makefile.am (libbison_a_SOURCES): Add argmatch.c, argmatch.h. | |
2239 | ||
2240 | * src/system.h: Include <stdbool.h> unconditionally. | |
2241 | ||
2242 | * lib/bbitset.h: Include <limits.h> unconditionally. We have been | |
2243 | assuming at least C89 in the bitset code for some time now. | |
2244 | ||
d2ffe116 AD |
2245 | 2003-03-03 Akim Demaille <akim@epita.fr> |
2246 | ||
2247 | * ro.po: New. | |
2248 | ||
052826fd AD |
2249 | 2003-03-02 Akim Demaille <akim@epita.fr> |
2250 | ||
2251 | * doc/bison.texinfo (Table of Symbols): Reactivate the | |
2252 | documentation for %lex-param, and %parse-param. | |
2253 | ||
c4749565 AD |
2254 | 2003-03-02 Akim Demaille <akim@epita.fr> |
2255 | ||
2256 | * data/yacc.c, data/glr.c, data/lal1.cc: Use similar code to | |
2257 | generate verbose error messages. | |
2258 | Use the number of tokens as an upper bound in yytname, as it | |
2259 | cannot be a non terminal. | |
2260 | ||
d5286af1 AD |
2261 | 2003-03-02 Akim Demaille <akim@epita.fr> |
2262 | ||
2263 | * tests/regression.at (_AT_DATA_DANCER_Y): Fix the expected error | |
2264 | message. | |
2265 | ||
22e304a6 AD |
2266 | 2003-03-02 Akim Demaille <akim@epita.fr> |
2267 | ||
22e304a6 AD |
2268 | * tests/regression.at (_AT_DATA_DANCER_Y, AT_CHECK_DANCER): New. |
2269 | Use them to exercise yycheck overrun. | |
2270 | Based on Andrew Suffield's grammar. | |
2271 | ||
67a25fed AD |
2272 | 2003-03-02 Akim Demaille <akim@epita.fr> |
2273 | ||
2274 | Create tests/local.at for Bison generic testing macros. | |
2275 | ||
2276 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Move to... | |
2277 | * tests/local.at (AT_BISON_OPTION_PUSHDEFS, AT_BISON_OPTION_POPDEFS): | |
2278 | This new file. | |
2279 | * tests/calc.at (AT_CHECK_CALC): Adjust. | |
2280 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR) | |
2281 | (AT_COMPILE, AT_COMPILE_CXX, AT_PARSER_CHECK): Move to... | |
2282 | * tests/local.at: here. | |
2283 | (AT_COMPILE_CXX): Tags the tests using it as c++. | |
2284 | Ignore the test if CXX is not functional. | |
2285 | ||
9c2b381f PE |
2286 | 2003-03-01 Paul Eggert <eggert@twinsun.com> |
2287 | ||
2288 | * src/scan-gram.l (code_start): Initialize it to scanner_cursor, | |
2289 | not loc->end, since loc->end might contain garbage and this leads | |
2290 | to undefined behavior on some platforms. | |
2291 | (id_loc, token_start): Use (IF_LINTed) initial values that do not | |
2292 | depend on *loc, so that the reader doesn't give the the false | |
2293 | impression that *loc is initialized. | |
2294 | (<INITIAL>"%%"): Do not bother setting code_start, since its value | |
2295 | does not survive the return. | |
2296 | ||
0433ba88 AD |
2297 | 2003-03-01 Akim Demaille <akim@epita.fr> |
2298 | ||
2299 | * src/scan-gram.l (code_start): Always initialize it when entering | |
2300 | into yylex, as SC_EPILOGUE is activated *before* the corresponding | |
2301 | yylex invocation. An alternative would be making it static, but | |
2302 | then it starts with the second %%'s beginning, instead of its end. | |
2303 | ||
b305ea69 PE |
2304 | 2003-02-28 Paul Eggert <eggert@twinsun.com> |
2305 | ||
2306 | * lib/mbswidth.c: Include <wchar.h> before "mbswidth.h", to work | |
2307 | around a UnixWare 7.1.1 porting bug reported by John Hughes in | |
161a71f3 | 2308 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00030.html>. |
b305ea69 | 2309 | |
c3d25e01 PE |
2310 | 2003-02-26 Paul Eggert <eggert@twinsun.com> |
2311 | ||
2312 | * README: Mention compiler bug in Sun Forte Developer 6 update 2. | |
2313 | Remove Sequent/Pyramid discussion (nobody uses them any more). | |
2314 | Merge VMS and MS-DOS discussion; these ports may well be dead | |
2315 | but let's keep mentioning them for now. Put <> around email | |
2316 | addresses. Add copyright notice. | |
2317 | ||
c267ffbc PE |
2318 | 2003-02-24 Paul Eggert <eggert@twinsun.com> |
2319 | ||
2320 | * data/glr.c (yy_reduce_print): yylineno -> yylno, | |
2321 | to avoid collision with flex use of yylineno. | |
2322 | Problem reported by Bruce Lilly in | |
161a71f3 | 2323 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00016.html>. |
c267ffbc PE |
2324 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Likewise. |
2325 | * data/yacc.c (yy_reduce_print): Likewise. | |
2326 | ||
2327 | * config/depcomp: Sync with Automake 1.7.3. | |
2328 | ||
f939fc12 AD |
2329 | 2003-02-21 Akim Demaille <akim@epita.fr> |
2330 | ||
2331 | * data/lalr1.cc: Use temporary variables instead of casts to | |
2332 | change integer types. | |
2333 | Suggested by Paul Eggert. | |
2334 | ||
95923bd6 AD |
2335 | 2003-02-21 Akim Demaille <akim@epita.fr> |
2336 | ||
2337 | * doc/bison.texinfo: Use "location" consistently to refer to @n, | |
2338 | to avoid confusions with lalr1.cc's notion of Position. | |
2339 | Suggested by Paul Eggert. | |
2340 | ||
2cdc240e AD |
2341 | 2003-02-20 Akim Demaille <akim@epita.fr> |
2342 | ||
2343 | * data/lalr1.cc (position.hh): Make sure "columns" never pushes | |
2344 | before initial_columns. | |
2345 | (location.hh): Use consistent variable names when defining the | |
2346 | operator<<. | |
2347 | Use "last" so that we subtract from Positions, not from unsigned. | |
2348 | ||
5d003116 AD |
2349 | 2003-02-20 Akim Demaille <akim@epita.fr> |
2350 | ||
2351 | * data/lalr1.cc (position.hh): New subfile, including the extended | |
2352 | and Doxygen'ed documentation of class Position. | |
2353 | (location.hh): Use it. | |
2354 | Document a` la Doxygen. | |
ba1ecc07 | 2355 | With the help of Benoit Perrot. |
5d003116 | 2356 | |
d02b25f9 AD |
2357 | 2003-02-20 Akim Demaille <akim@epita.fr> |
2358 | ||
2359 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Define | |
2360 | AT_YACC_IF. | |
2361 | Redefine AT_YYERROR_SEES_LOC_IF using it. | |
2362 | (_AT_DATA_CALC_Y): Don't declare yyerror when lalr1.cc, as it is | |
2363 | not defined. | |
2364 | Don't use the location in yy::Parser::error_ and | |
2365 | yy::Parser::print_ when not %locations. | |
2366 | Activate more lalr1.cc tests. | |
2367 | ||
0d1c3a04 AD |
2368 | 2003-02-19 Akim Demaille <akim@epita.fr> |
2369 | ||
2370 | * data/lalr1.cc: When displaying a line number, be sure to make it | |
2371 | an int. | |
2372 | ||
60a777aa AD |
2373 | 2003-02-19 Akim Demaille <akim@epita.fr> |
2374 | ||
2375 | * data/lalr1.cc (b4_stack_depth_init, yy::Parser::initdepth_): | |
2376 | Remove, useless. | |
2377 | (YYABORT, YYACCEPT, YYERROR): New. | |
2378 | * tests/calc.at: Renable the lalr1.cc test. | |
2379 | ||
0b86fc41 AD |
2380 | 2003-02-19 Akim Demaille <akim@epita.fr> |
2381 | ||
2382 | * tests/calc.at (AT_CHECK_CALC): Check different scenarios of | |
2383 | error recovery, mixing with/without pops and discarding of the | |
2384 | lookahead. | |
2385 | Exercise YYERROR. | |
2386 | Disable the lalr1.cc tests as currently it doesn't support YYERROR. | |
2387 | ||
da99a5dc PE |
2388 | 2003-02-17 Paul Eggert <eggert@twinsun.com> |
2389 | ||
2390 | * tests/atlocal.in (LDFLAGS, LIBS): New vars. | |
2391 | * tests/testsuite.at (AT_COMPILE): Use them. | |
2392 | This fixes the testsuite problem reported by Robert Lentz in | |
161a71f3 | 2393 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00011.html>. |
da99a5dc | 2394 | |
93b8c255 PE |
2395 | 2003-02-12 Paul Eggert <eggert@twinsun.com> |
2396 | ||
2397 | * data/yacc.c (yyerrlab) [YYERROR_VERBOSE]: | |
2398 | Avoid subscript error in yycheck. Bug reported by Andrew Suffield in | |
161a71f3 | 2399 | <http://lists.gnu.org/archive/html/bug-bison/2003-02/msg00003.html>. |
93b8c255 PE |
2400 | * data/glr.c (yyreportSyntaxError) [YYERROR_VERBOSE]: Likewise. |
2401 | Check for malloc failure, for consistency with yacc.c. | |
2402 | (yytname_size): Remove, for consistency with yacc.c. | |
2403 | ||
2404 | The bug still remains in data/lalr1.cc, as I didn't have time | |
2405 | to fix it there. | |
2406 | ||
7548fed2 AD |
2407 | 2003-02-06 Akim Demaille <akim@epita.fr> |
2408 | ||
2409 | * configure.ac (GXX): Rename as... | |
2410 | (CXX): this, to keep the original Autoconf semantics. | |
2411 | Require 2.57. | |
2412 | * data/lalr1.cc: Fix b4_copyright invocations. | |
2413 | If YYDEBUG is not defined, don't depend upon name_ being defined. | |
2414 | (location.hh): Include string and iostream. | |
2415 | (Position::filename): New member. | |
2416 | (Position::Position ()): New. | |
2417 | (operator<< (Position)): New. | |
2418 | (operator- (Position, int)): New. | |
2419 | (Location::first, Location::last): Rename as... | |
2420 | (Location::begin, Location::end): these, to mock the conventional | |
2421 | iterator names. | |
2422 | (operator<< (Location)): New. | |
2423 | * tests/atlocal.in (CXX): New. | |
2424 | * tests/testsuite.at (AT_COMPILE_CXX): New. | |
2425 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust yyerror to report the | |
2426 | locations in a more synthetic way. | |
2427 | (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF is positive if | |
2428 | lalr1.cc is used. | |
2429 | Adjust the C locations to match those from Emacs: first column is | |
2430 | column 0. | |
2431 | Change all the expected results. | |
2432 | Conform to the GCS: simplify the locations when applicable. | |
2433 | (LOC, VAL, YYLLOC_FORMAL, YYLLOC_ARG, USE_YYLLOC, LEX_FORMALS) | |
2434 | (LEX_ARGS, USE_LEX_ARGS, LEX_PRE_FORMALS, LEX_PRE_ARGS): Replace | |
2435 | these CPP macros with the m4 macros new defined by... | |
2436 | (AT_CHECK_PUSHDEFS): this, i.e.: | |
2437 | (AT_LALR1_CC_IF, AT_PURE_LEX_IF, AT_LOC, AT_VAL, AT_LEX_FORMALS) | |
d02b25f9 | 2438 | (AT_LEX_ARGS, AT_USE_LEX_ARGS, AT_LEX_PRE_FORMALS, AT_LEX_PRE_ARGS) |
7548fed2 AD |
2439 | New macros. |
2440 | (AT_CHECK_POPDEFS): Undefine them. | |
2441 | (AT_CHECK_CALC_LALR1_CC): New. | |
2442 | Use it for the first lalr1.cc test. | |
2443 | ||
43a176ef AD |
2444 | 2003-02-04 Akim Demaille <akim@epita.fr> |
2445 | ||
2446 | * data/lalr1.cc (YYLLOC_DEFAULT): Fix its definition: be based on | |
2447 | Location as is defined. | |
2448 | ||
fc049e9c AD |
2449 | 2003-02-04 Akim Demaille <akim@epita.fr> |
2450 | ||
2451 | * data/lalr1.cc: If YYDEBUG is not defined, don't depend upon | |
2452 | name_ being defined. | |
2453 | ||
a737b216 PE |
2454 | 2003-02-03 Paul Eggert <eggert@twinsun.com> |
2455 | ||
2456 | * src/gram.h (start_symbol): Remove unused decl. | |
2457 | ||
2458 | Use more-consistent naming conventions for local vars. | |
2459 | ||
2460 | * src/derives.c (derives_compute): Change type of local var from | |
2461 | int to rule_number. | |
2462 | * src/gram.c (grammar_rules_partial_print): Likewise. | |
2463 | * src/print.c (print_core): Likewise. | |
2464 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
2465 | ||
2466 | * src/gram.c (grammar_dump): Change name of item_number * | |
2467 | local var from r to rp. | |
2468 | * src/nullable.c (nullable_compute): Likewise. | |
2469 | ||
2470 | * src/gram.h (ISTOKEN, ISVAR): Use i, not s, for int var. | |
2471 | ||
2472 | * src/gram.h (symbol_number_as_item_number): Use sym, not s, | |
2473 | for symbol or symbol_number var. | |
2474 | * src/reader.c (grammar_start_symbol_set): Likewise. | |
2475 | * src/reader.h (grammar_start_symbol_set, grammar_symbol_append): | |
2476 | Likewise. | |
2477 | * src/state.c (transitions_to): Likewise. | |
2478 | * src/state.h: Likewise. | |
2479 | * src/tables.c (symbol_number_to_vector_number): Likewise. | |
2480 | ||
2481 | * src/muscle_tab.h (MUSCLE_OBSTACK_SGROW): Use p, not s, for | |
2482 | char * var. | |
2483 | ||
2484 | * src/parse-gram.y (lloc_default): Use loc, not r, for YYLTYPE | |
2485 | var. | |
2486 | ||
2487 | * src/scan-gram.l (no_cr_read): Use bytes_read, not s, for size | |
2488 | var. | |
2489 | ||
2490 | * src/system.h (xstrndup, strchr, strspn, strnlen, memchr, memrchr): | |
2491 | Use str, not s, for char * var. Use ch, not c, for character var. | |
2492 | Use size for size var. | |
2493 | ||
2494 | * src/uniqstr.c (uniqstr_new, uniqstr_assert): Use str, not s, for | |
2495 | char * var. | |
2496 | (uniqstr_print, uniqst_print_processor): Use ustr, not s, for | |
2497 | uniqstr var. | |
2498 | * src/uniqstr.h: Likewise. | |
2499 | ||
2500 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
2501 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
2502 | get_node_alignment_str, get_arrow_mode_str, get_crossing_type_str, | |
2503 | get_view_str, get_linestyle_str, get_arrowstyle_str): Rename | |
2504 | param to have same name as that of enum, so that we don't use | |
2505 | "s" to stand for a non-state. | |
2506 | ||
68e93ad5 AD |
2507 | 2003-02-02 Akim Demaille <akim@epita.fr> |
2508 | ||
2509 | * src/scan-skel.l: Scan more than one inert character per yylex | |
2510 | invocation. | |
2511 | ||
92898986 PE |
2512 | 2003-02-01 Paul Eggert <eggert@twinsun.com> |
2513 | ||
2514 | Version 1.875a. | |
2515 | ||
1d9d5d71 PE |
2516 | * po/LINGUAS: Add ms. |
2517 | ||
0435d061 AD |
2518 | 2003-01-30 Akim Demaille <akim@epita.fr> |
2519 | ||
2520 | * doc/Makefile.am (CLEANFILES): Add bison.fns for distcheck. | |
2521 | ||
6029a57f PH |
2522 | 2003-01-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
2523 | ||
2524 | * tests/cxx-type.at: Correct apparent typo in Bison input: $$ instead | |
2525 | of $1. | |
0435d061 AD |
2526 | |
2527 | Changes in response to error report by S. Eken: GLR mode does not | |
6029a57f | 2528 | handle negative $ indices or $ indices in embedded rules correctly. |
161a71f3 | 2529 | See <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00076.html>. |
0435d061 | 2530 | |
6029a57f PH |
2531 | * data/glr.c (b4_rhs_value): Change to use YYFILL macro. |
2532 | (b4_rhs_location): Ditto. | |
0435d061 | 2533 | (yyfill): New function to copy from stack tree into array |
6029a57f | 2534 | incrementally. |
0435d061 AD |
2535 | (yyuserAction): Modify to allow incremental move of semantic values |
2536 | to rhs array when in GLR mode. | |
2537 | Define YYFILL to use in user-defined actions to fill semantic array | |
6029a57f PH |
2538 | as needed. |
2539 | Remove dummy use of yystack, as there is now a guaranteed use. | |
2540 | (yydoAction): Modify to allow incremental move of semantic values | |
2541 | to rhs array when in GLR mode. | |
2542 | (yyresolveAction): Ditto. | |
2543 | (yyglrShiftDefer): Update comment. | |
0435d061 | 2544 | (yyresolveStates): Use X == NULL for pointers, not !X. |
6029a57f PH |
2545 | (yyglrReduce): Ditto. |
2546 | (yydoAction): Ditto | |
0435d061 | 2547 | |
6029a57f PH |
2548 | * tests/glr-regr1.at: Rename to ... |
2549 | * tests/glr-regression.at: Add new regression test for the problems | |
2550 | described above (adapted from S. Eken). | |
2551 | Update copyright notice. | |
2552 | * tests/testsuite.at: Rename glr-regr1.at to glr-regression.at. | |
2553 | * tests/Makefile.am: Ditto. | |
2554 | ||
6cee6297 PE |
2555 | 2003-01-28 Paul Eggert <eggert@twinsun.com> |
2556 | ||
2557 | * data/lalr1.cc: Do not use @output_header_name@ unless | |
2558 | b4_defines_flag is set. This fixes two bugs reported by | |
2559 | Tim Van Holder in | |
161a71f3 PE |
2560 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00071.html> |
2561 | and <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00073.html>. | |
6cee6297 | 2562 | |
b2a836b5 PE |
2563 | 2003-01-21 Paul Eggert <eggert@twinsun.com> |
2564 | ||
2565 | * data/yacc.c (YYERROR): Move code from yyerrlab1 to here, so that | |
2566 | we don't need to worry about yyerrlab1 being reported as an | |
2567 | "unused label" by non-GCC C compilers. The downside is that if | |
2568 | locations are used then a couple of statements are duplicated each | |
2569 | time YYERROR is invoked, but the upside is that the warnings | |
2570 | should vanish. | |
2571 | (yyerrlab1): Move code to YERROR. | |
2572 | (yyerrlab2): Remove. Change uses back to yyerrlab1. | |
2573 | This reverts some of the 2002-12-27 change. | |
2574 | ||
4196b931 PE |
2575 | 2003-01-17 Paul Eggert <eggert@twinsun.com> |
2576 | ||
2577 | * src/output.c (symbol_printers_output): Fix typo that led | |
2578 | to core dump. Problem reported by Antonio Rus in | |
161a71f3 | 2579 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00058.html>. |
4196b931 | 2580 | |
3ae831b4 AD |
2581 | 2003-01-13 Akim Demaille <akim@epita.fr>, |
2582 | Quoc Peyrot <chojin@lrde.epita.fr>, | |
2583 | Robert Anisko <anisko_r@lrde.epita.fr> | |
2584 | ||
2585 | * data/lalr1.cc (parse::yyerrlab1): When popping the stack, stop | |
2586 | when the stacks contain one element, as the loop would otherwise | |
2587 | free the last state, and then use the top state (the one we just | |
2588 | popped). This means that the initial elements will not be freed | |
2589 | explicitly, as is the case in yacc.c; it is not a problem, as | |
2590 | these elements have fake values. | |
2591 | ||
e3aa65c5 PE |
2592 | 2003-01-11 Paul Eggert <eggert@twinsun.com> |
2593 | ||
2594 | * NEWS: %expect-violations are now just warnings, reverting | |
2595 | to Bison 1.30 and 1.75 behavior. This fixes the GCC 3.2 | |
2596 | bootstrapping problem reported by Matthias Klose; see | |
161a71f3 | 2597 | <http://lists.gnu.org/archive/html/bug-bison/2003-01/msg00053.html>. |
e3aa65c5 PE |
2598 | * src/conflicts.c (conflicts_print): Likewise. |
2599 | * tests/conflicts.at (%expect not enough, %expect too much, | |
2600 | %expect with reduce conflicts): Likewise. | |
2601 | * doc/bison.texinfo (Expect Decl): Document this. Also mention | |
2602 | that the warning is enabled if the number of conflicts changes | |
2603 | (not necessarily increases). | |
2604 | ||
2605 | * src/getargs.c (version): Update copyright year. | |
2606 | ||
f0057011 AD |
2607 | 2003-01-09 Akim Demaille <akim@epita.fr> |
2608 | ||
2609 | * src/Makefile.am, lib/Makefile.am: Use $(VAR) instead of @VAR@. | |
2610 | ||
1ee6d2a0 PE |
2611 | 2003-01-08 Paul Eggert <eggert@twinsun.com> |
2612 | ||
2613 | * Makefile.maint (WGETFLAGS): | |
2614 | New macro, containing "-C off" to disable proxy caches. | |
2615 | All uses of $(WGET) changed to $(WGET) $(WGETFLAGS). | |
2616 | (rel-check): Use $(WGET) instead of wget. | |
2617 | ||
d4fd77c4 PE |
2618 | 2003-01-06 Paul Eggert <eggert@twinsun.com> |
2619 | ||
2620 | * doc/bison.texinfo (Generalized LR Parsing): Add a reference to | |
2621 | the GLR paper of Scott, Johnstone and Hussain. | |
2622 | ||
464c6927 PE |
2623 | 2003-01-04 Paul Eggert <eggert@twinsun.com> |
2624 | ||
d600ee67 PE |
2625 | * configure.ac (AC_ARG_ENABLE): Add --disable-yacc. |
2626 | (YACC_SCRIPT, YACC_LIBRARY): New vars to AC_SUBST. | |
2627 | * lib/Makefile.am (lib_LIBRARIES): liby.a -> @YACC_LIBRARY@. | |
2628 | (EXTRA_LIBRARIES): New var, for liby.a. | |
2629 | * src/Makefile.am (bin_SCRIPTS): yacc -> @YACC_SCRIPT@. | |
2630 | (EXTRA_SCRIPTS): New var, for yacc. | |
2631 | ||
464c6927 PE |
2632 | * data/yacc.c (yyerrlab1): Omit attribute if __cplusplus is defined, |
2633 | since GNU C++ (as of 3.2.1) does not allow attributes on labels. | |
2634 | Problem reported by Nelson H. F. Beebe. | |
2635 | ||
2636 | 2003-01-03 Paul Eggert <eggert@twinsun.com> | |
2637 | ||
2638 | * lib/obstack.h (__INT_TO_PTR) [__STDC__]: Cast result to | |
2639 | (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5 | |
2640 | when compiling Bison 1.875's `bitset bset = obstack_alloc | |
2641 | (bobstack, bytes);'. Problem reported by Nelson H. F. Beebe. | |
2642 | ||
2643 | * src/scan-skel.l (QPUTS): Omit redundant `;' from macro definition. | |
2644 | ([^@\n]): Renamed from [^@\n]+ so that the token buffer does not | |
2645 | grow to a huge size with typical invocation. | |
d600ee67 | 2646 | |
464c6927 PE |
2647 | * lib/hash.c (_Bool, bool, false, true, __bool_true_false_are_defined): |
2648 | Use the pattern recommended by Autoconf 2.57, except also protect | |
2649 | against double-definition. | |
2650 | * src/system.h: Likewise. | |
2651 | Portability issues reported by Nelson H. F. Beebe. | |
d600ee67 | 2652 | |
464c6927 PE |
2653 | * data/glr.c (yybool): Renamed from bool, to avoid collisions in C. |
2654 | All uses changed. Provide a definition in both C and C++. | |
2655 | (yytrue, yyfalse): Define even if defined (__cplusplus). | |
2656 | ||
2657 | * lib/bitset_stats.c (bitset_stats_list): Remove unused var. | |
2658 | Reported by Nelson H. F. Beebe. | |
d600ee67 | 2659 | |
464c6927 PE |
2660 | * src/scan-skel.l ("@oline@"): Output lineno+1, not lineno. |
2661 | ||
0f42c7d5 PE |
2662 | 2003-01-02 Paul Eggert <eggert@twinsun.com> |
2663 | ||
2664 | * data/yacc.c (yyerrlab1): Append `;' after attribute, to | |
2665 | pacify the buggy "smart preprocessor" in MacOS 10.2.3. | |
2666 | Bug reported by Nelson H. F. Beebe. | |
2667 | ||
dc546b0f PE |
2668 | 2003-01-01 Paul Eggert <eggert@twinsun.com> |
2669 | ||
2670 | * Version 1.875. | |
2671 | ||
2c09b6a7 PE |
2672 | 2002-12-30 Paul Eggert <eggert@twinsun.com> |
2673 | ||
2674 | * src/scan-gram.l (<INITIAL,SC_AFTER_IDENTIFIER,SC_PRE_CODE>","): | |
2675 | Moved here from... | |
2676 | (<INITIAL>","): Here. This causes stray "," to be treated | |
2677 | more uniformly. | |
2678 | ||
dc546b0f | 2679 | * src/scan-gram.l (<SC_BRACED_CODE>"}"): Output ";" before the |
2c09b6a7 PE |
2680 | last brace in braced code when not in Yacc mode, for compatibility |
2681 | with Bison 1.35. This resurrects the 2001-12-15 patch to | |
2682 | src/reader.c. | |
2683 | ||
2684 | * src/reader.h (YYDECL): Use YYSTYPE, not its deprecated alias | |
2685 | yystype. This follows up the 2002-12-24 YYSTYPE bug fix. | |
2686 | ||
535c0f63 PE |
2687 | 2002-12-28 Paul Eggert <eggert@twinsun.com> |
2688 | ||
2689 | * src/symtab.c (symbol_make_alias): Set type of SYMVAL to be | |
2690 | that of SYM's type. This fixes Debian bug 168069, reported by | |
2691 | Thomas Olsson. | |
d600ee67 | 2692 | |
963fcc17 PE |
2693 | 2002-12-28 Paul Eggert <eggert@twinsun.com> |
2694 | ||
2695 | Version 1.75f. | |
2696 | ||
2697 | Switch back to the Yacc style of conflict reports, undoing some | |
2698 | of the 2002-07-30 change. | |
2699 | * doc/bison.texinfo (Understanding): Use Yacc style for | |
2700 | conflict reports. Also, use new way of locating rules. | |
2701 | * src/conflicts.c (conflict_report): | |
2702 | Renamed from conflict_report_yacc, removing the old | |
2703 | 'conflict_report'. Translate the entire conflict report at once, | |
2704 | so that we don't assume that "," has the same interpretation in | |
2705 | all languages. | |
2706 | (conflicts_output): Use Yacc-style conflict report for each state, | |
2707 | instead of our more-complicated style. | |
2708 | (conflicts_print): Use Yacc-style conflict report, except print | |
2709 | the input file name when not emulating Yacc. | |
2710 | * tests/conflicts.at (Unresolved SR Conflicts, Defaulted | |
2711 | Conflicted Reduction, %expect not enough, %expect too much, | |
2712 | %expect with reduce conflicts): Switch to Yacc-style conflict reports. | |
2713 | * tests/existing.at (GNU Cim Grammar): Likewise. | |
2714 | * tests/glr-regr1.at (Badly Collapsed GLR States): Likewise. | |
2715 | ||
2716 | * src/complain.c (warn_at, warn, complain_at, complain, fatal_at, | |
2717 | fatal): Don't invoke fflush; it's not needed and it might even be | |
2718 | harmful for stdout, as stdout might not be open. | |
2719 | * src/reduce.c (reduce_print): Likewise. | |
2720 | ||
b1efe548 PE |
2721 | 2002-12-27 Paul Eggert <eggert@twinsun.com> |
2722 | ||
2723 | Fix a bug where error locations were not being recorded correctly. | |
2724 | This problem was originally reported by Paul Hilfinger in | |
161a71f3 | 2725 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00086.html>. |
b1efe548 PE |
2726 | |
2727 | * data/yacc.c (yyparse): New local var yylerrsp, to record the | |
2728 | top of the location stack's error locations. | |
2729 | (yyerrlab): Set it. When discarding a token, push its location | |
2730 | onto yylerrsp so that we don't lose track of the error's end. | |
2731 | (yyerrlab1): Now is only the target of YYERROR, so that we can | |
2732 | properly record the location of the action that failed. For GCC | |
2733 | 2.93 and later, insert an __attribute__ ((__unused__)) to avoid | |
2734 | GCC warning about yyerrlab1 being unused if YYERROR is unused. | |
2735 | (yyerrlab2): New label, which yyerrlab now falls through to. | |
2736 | Compute the error's location by applying YYLLOC_DEFAULT to | |
2737 | the locations of all the symbols that went into the error. | |
2738 | * doc/bison.texinfo (Location Default Action): Mention that | |
2739 | YYLLOC_DEFAULT is also invoked for syntax errors. | |
2740 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
2741 | Error locations include the locations of all the tokens that were | |
2742 | discarded, not just the last token. | |
d600ee67 | 2743 | |
983c5c2c PE |
2744 | 2002-12-26 Paul Eggert <eggert@twinsun.com> |
2745 | ||
b1efe548 PE |
2746 | * src/files.c: Include quote.h. |
2747 | (compute_output_file_names): Warn if we detect conflicting | |
2748 | outputs to the same file. This should catch the misunderstanding | |
2749 | exemplified by Debian Bug 165349, reported by Bruce Stephens.. | |
2750 | ||
2751 | * src/conflicts.c (conflicts_print): If the user specifies | |
2752 | "%expect N", report an error if there are any reduce/reduce | |
2753 | conflicts. This is what the manual says should happen. | |
2754 | This fixes Debian bug 130890, reported by Anthony DeRobertis. | |
2755 | * tests/conflicts.at (%expect with reduce conflicts): New test. | |
2756 | ||
983c5c2c PE |
2757 | Don't use m4_include on relative file names, as it doesn't work as |
2758 | desired if there happens to be a file with that name under ".". | |
d600ee67 | 2759 | |
983c5c2c PE |
2760 | * m4sugar/version.m4: Remove; it was included but it wasn't used. |
2761 | * data/Makefile.am (dist_m4sugar_DATA): Remove m4sugar/version.m4. | |
2762 | * data/m4sugar/m4sugar.m4: Don't include m4sugar/version.m4. | |
2763 | * data/glr.c, data/lalr1.cc, data/yacc.c: Don't include c.m4. | |
2764 | * src/output.c (output_skeleton): Use full path names when | |
2765 | specifying a file to include; don't rely on include path, as | |
2766 | it's unreliable when the working file contains a file with | |
2767 | that name. | |
d600ee67 | 2768 | |
983c5c2c PE |
2769 | 2002-12-25 Paul Eggert <eggert@twinsun.com> |
2770 | ||
2771 | Remove obsolete references to bison.simple and bison.hairy. | |
2772 | Problem mentioned by Aubin Mahe in | |
161a71f3 | 2773 | <http://lists.gnu.org/archive/html/help-bison/2002-12/msg00010.html>. |
983c5c2c PE |
2774 | * data/glr.c: Comment fix. |
2775 | * doc/bison.1: Remove references. Also, mention "yacc". | |
2776 | ||
2777 | * src/getargs.c (getargs) [MSDOS]: Don't assume optarg != NULL | |
2778 | with -g option. | |
2779 | ||
2780 | * src/parse-gram.y (declaration): Use enum "report_states" rather | |
2781 | than its numeric value 1. | |
2782 | ||
2783 | * src/scan-skel.l ("@output ".*\n): Close any old yyout before | |
2784 | opening a new one. This fixes Debian bug 165349, reported by | |
2785 | Bruce Stephens. | |
2786 | ||
23f2d9dc PE |
2787 | 2002-12-24 Paul Eggert <eggert@twinsun.com> |
2788 | ||
2789 | Version 1.75e. | |
2790 | ||
2791 | * Makefile.maint (cvs-update): Don't assume that the shell | |
2792 | supports $(...), as Solaris sh doesn't. | |
2793 | ||
2794 | * src/parse-gram.y (lloc_default): Remove test for empty | |
2795 | nonterminals at the end, since it didn't change the result. | |
2796 | ||
2797 | 2002-12-24 Paul Eggert <eggert@twinsun.com> | |
33167b8b PE |
2798 | |
2799 | If the user does not define YYSTYPE as a macro, Bison now declares it | |
2800 | using typedef instead of defining it as a macro. POSIX requires this. | |
2801 | For consistency, YYLTYPE is also declared instead of defined. | |
2802 | ||
2803 | %union directives can now have a tag before the `{', e.g., the | |
2804 | directive `%union foo {...}' now generates the C code | |
2805 | `typedef union foo { ... } YYSTYPE;'; this is for Yacc compatibility. | |
2806 | The default union tag is `YYSTYPE', for compatibility with Solaris 9 | |
2807 | Yacc. For consistency, YYLTYPE's struct tag is now `YYLTYPE' | |
2808 | instead of `yyltype'. | |
2809 | ||
2810 | `yystype' and `yyltype' are now obsolescent macros instead of being | |
2811 | typedefs or tags; they are no longer documented and will be | |
2812 | withdrawn in a future release. | |
2813 | ||
2814 | * data/glr.c (b4_location_type): Remove. | |
2815 | (YYSTYPE): Renamed from yystype. | |
2816 | (YYSTYPE_IS_DECLARED): New macro, used to prevent double-typedef. | |
2817 | (struct YYLTYPE): Renamed from struct yyltype. | |
2818 | (YYLTYPE): Renamed from yyltype. | |
2819 | (yyltype, yystype): New (and obsolescent) macros, | |
2820 | for backward compatibility. | |
2821 | * data/yacc.c: Likewise. | |
2822 | ||
2823 | * data/yacc.c (YYSTYPE): Declare as union YYSTYPE if the user | |
2824 | does not specify a union tag. This is for compatibility with | |
2825 | Solaris 9 yacc. | |
2826 | ||
2827 | * src/parse-gram.y (add_param): 2nd arg is now char * not char | |
2828 | const *, since it is now modified by stripping surrounding { }. | |
2829 | (current_braced_code): Remove. | |
2830 | (PERCENT_DESTRUCTOR, PERCENT_PRINTER, PERCENT_UNION, | |
2831 | PERCENT_LEX_PARAM, PERCENT_PARSE_PARAM): Change names to include | |
2832 | trailing " {...}". Now of type <chars>. | |
2833 | (grammar_declaration): Adjust to bundled tokens. | |
2834 | (code_content): Remove; stripping is now done by add_param. | |
2835 | (print_token_value): Print contents of bundled tokens. | |
2836 | (token_name): New function. | |
2837 | ||
2838 | * src/reader.h (braced_code, current_braced_code): Remove. | |
2839 | (token_name): New decl. | |
2840 | ||
2841 | * src/scan-gram.l (handle_dollar, handle_at): Now takes int | |
2842 | token_type, not braced_code code_kind. All uses changed. | |
2843 | (SC_PRE_CODE): New state, for scanning after a keyword that | |
2844 | has (or usually has) an immediately-following braced code. | |
2845 | (token_type): New local var, to keep track of which token type | |
2846 | to return when scanning braced code. | |
2847 | (<INITIAL>"%destructor", <INITIAL>"%lex-param", | |
dc546b0f | 2848 | <INITIAL>"%parse-param", <INITIAL>"%printer", |
33167b8b PE |
2849 | <INITIAL>"%union"): Set token type and BEGIN SC_PRE_CODE |
2850 | instead of returning a token type immediately. | |
2851 | (<INITIAL>"{"): Set token type. | |
2852 | (<SC_BRACED_CODE>"}"): Use it. | |
2853 | (handle_action_dollar, handle_action_at): Now returns bool | |
2854 | indicating success. Fail if ! current_rule; this prevents a core dump. | |
2855 | (handle_symbol_code_dollar, handle_symbol_code_at): | |
2856 | Remove; merge body into caller. | |
2857 | (handle_dollar, handle_at): Complain in invalid contexts. | |
2858 | ||
2859 | * NEWS, doc/bison.texinfo: Document the above. | |
2860 | * NEWS: Fix years and program names in copyright notice. | |
2861 | ||
879ca4f8 PE |
2862 | 2002-12-17 Paul Eggert <eggert@twinsun.com> |
2863 | ||
2864 | * NEWS, doc/bison.texinfo (Parser Function, Pure Calling, Error | |
2865 | Reporting, Table of Symbols): Omit mentions of %lex-param and | |
2866 | %parse-param from the documentation for now. | |
2867 | ||
1c5fe69d PE |
2868 | 2002-12-15 Paul Eggert <eggert@twinsun.com> |
2869 | ||
2870 | Undo most of the 2002-11-12 yychar -> yytoken patch, as it broke | |
2871 | GCC 3.2.1 (which depends on yychar == YYEMPTY when there is no | |
2872 | lookahead symbol, and which sets yychar in parser actions) and it | |
7ea9026a PE |
2873 | disagreed with the Bison documentation. Bug |
2874 | reported by Andrew Walrond. | |
d600ee67 | 2875 | |
1c5fe69d PE |
2876 | * data/yacc.c (YYTRANSLATE): Don't check for negative argument, |
2877 | as the caller now does that. | |
2878 | (yyclearin, YYBACKUP, yyparse): Use yychar, not yytoken. | |
2879 | (YYEMPTY): Parenthesize right hand side, since others use it. | |
2880 | (yyparse): Don't assume that our generated code is the only code | |
2881 | that sets yychar. | |
2882 | ||
d1de5372 PE |
2883 | 2002-12-13 Paul Eggert <eggert@twinsun.com> |
2884 | ||
2885 | Version 1.75d. | |
2886 | ||
2887 | POSIX requires a "yacc" command. | |
2888 | * src/Makefile.am (bin_SCRIPTS): New macro, for yacc. | |
2889 | (MOSTLYCLEANFILES): Add yacc. | |
2890 | (yacc): New rule. | |
1c5fe69d | 2891 | * doc/bison.texinfo (Invocation, Bison Options): Mention yacc |
d1de5372 PE |
2892 | as an alias for bison y. |
2893 | ||
2894 | * po/LINGUAS: Add da. | |
d600ee67 | 2895 | |
d1de5372 PE |
2896 | * src/getargs.c (__GNU_LIBRARY__) [lint]: Define to work around |
2897 | problem with latest <getopt.h>. | |
2898 | (HACK_FOR___GNU_LIBRARY___PROTOTYPE): New macro. | |
2899 | ||
2900 | * doc/fdl.texi: Upgrade to 1.2. | |
2901 | * lib/alloca.c, lib/error.c, lib/getopt.c, lib/getopt.h | |
2902 | lib/getopt1.c, lib/gettext.h, lib/memrchr.c, lib/obstack.c, | |
2903 | lib/obstack.h, lib/strnlen.c, lib/unlocked-io.h: Sync with | |
2904 | gnulib. | |
2905 | * config/install-sh: Sync with autotools. | |
2906 | ||
2907 | Fix a bad interaction with flex 2.5.23 reported by Bruce Lilly in | |
161a71f3 | 2908 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. |
d1de5372 PE |
2909 | * data/yacc.c (YYLTYPE, struct yyltype): Do not define unless |
2910 | locations are requested. | |
2911 | (union yyalloc): Do not depend on YYLTYPE_IS_TRIVIAL unless | |
2912 | locations are requested. | |
2913 | ||
d0f3fe23 PE |
2914 | 2002-12-12 Paul Eggert <eggert@twinsun.com> |
2915 | ||
2916 | Remove unportable casts and storage allocation tricks. | |
2917 | While we're at it, remove almost all casts, since they | |
2918 | usually aren't needed and are a sign of trouble. | |
2919 | ||
2920 | * configure.ac (AC_CHECK_TYPES): Check for uintptr_t. | |
2921 | ||
2922 | * src/derives.c (derives_compute): Do not subtract NTOKENS from | |
2923 | the pointer DSET returned by malloc; this isn't portable. | |
2924 | Instead, always use DSET[i - NTOKENS] rather than DSET[i]. | |
2925 | Similarly for DERIVES. | |
2926 | * src/lalr.c (set_goto_map): Likewise, for GOTO_MAP and TEMP_MAP. | |
2927 | * src/nullable.c (nullable_compute): Likewise, for RSETS and NULLABLE. | |
2928 | * src/reduce.c (reduce_grammar_tables): Likewise, for nontermmap | |
2929 | ||
2930 | * src/derives.c (derives_compute): Do not bother invoking | |
2931 | int_of_rule_number, since rule numbers are integers. | |
2932 | ||
2933 | * src/files.c (concat2, tr, compute_base_name): Use xmalloc (N) | |
2934 | rather than XMALLOC (char, N). | |
2935 | ||
2936 | * src/files.c (filename_split): Rewrite to avoid cast. | |
2937 | ||
2938 | * src/gram.h (symbol_number_as_item_number, | |
2939 | item_number_as_symbol_number, rule_number_as_item_number, | |
2940 | item_number_as_rule_number): | |
2941 | Now inline functions rather than macros, to avoid casts. | |
2942 | * src/state.h (state_number_as_int): Likewise. | |
2943 | * src/tables.c (state_number_to_vector_number, | |
2944 | symbol_number_to_vector_number): Likewise. | |
2945 | ||
2946 | * src/gram.h (int_of_rule_number): Remove; no longer used. | |
2947 | ||
2948 | * src/lalr.c (add_lookback_edge): Use malloc rather than calloc, | |
2949 | since the resulting storage is always stored into. | |
2950 | ||
2951 | * src/main.c (alloca) [C_ALLOCA]: Add decl here, the only place | |
2952 | where it's needed. | |
2953 | ||
2954 | * src/muscle_tab.c (muscle_m4_output): | |
2955 | Now inline. Return bool, not int. | |
2956 | * src/state.c (state_compare): Likewise. | |
2957 | * src/symtab.c (symbol_check_defined, | |
2958 | symbol_check_alias_consistency, symbol_pack, symbol_translation, | |
2959 | hash_compare_symbol, hash_symbol): | |
2960 | Likewise. | |
2961 | * src/uniqstr.c (uniqstr_print): Likewise. | |
2962 | * src/muscle_tab.c (muscle_m4_output_processor): | |
2963 | New function, to avoid casts. | |
2964 | * src/state.c (state_comparator, stage_hasher): Likewise. | |
2965 | * src/symtab.c (symbol_check_defined_processor, | |
2966 | symbol_check_alias_consistency_processor, symbol_pack_processor, | |
2967 | symbol_translation_processor, hash_symbol_comparator, | |
2968 | hash_symbol_hasher): Likewise. | |
2969 | * src/uniqstr.c (uniqstr_print_processor): Likewise. | |
2970 | * src/muscle_tab.c (muscles_m4_output): | |
2971 | Use new functions instead of casting old functions unportably. | |
2972 | * src/state.c (state_hash_new): Likewise. | |
2973 | * src/symtab.c (symbols_new, symbols_do, symbols_check_defined, | |
2974 | symbols_token_translations_init): | |
2975 | Likewise. | |
2976 | * src/uniqstr.c (uniqstrs_new, hash_initialize, uniqstrs_do): Likewise. | |
2977 | ||
2978 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): Use long local | |
2979 | var instead of casting to long, to avoid casts. | |
2980 | (prepare_states): Use MALLOC rather than alloca, so that we don't | |
2981 | have to worry about alloca. | |
2982 | * src/state.c (state_hash_lookup): Likewise. | |
2983 | ||
2984 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>"'"): Use unsigned char | |
2985 | local var instead of casting to unsigned char, to avoid casts. | |
2986 | ||
2987 | * src/state.c (TRANSITIONS_ALLOC, ERRS_ALLOC, REDUCTIONS_ALLOC, | |
2988 | STATE_ALLOC): Remove. | |
2989 | (transitions_new, errs_new, reductions_new, state_new): Use malloc | |
2990 | rather than calloc, and use offsetof to avoid allocating slightly | |
2991 | too much storage. | |
2992 | (state_new): Initialize all members. | |
2993 | ||
2994 | * src/state.c (state_hash): Use unsigned accumulator, not signed. | |
2995 | ||
2996 | * src/symtab.c (symbol_free): Remove; unused. | |
2997 | (symbol_get): Remove cast in lhs of assignment. | |
2998 | (symbols_do): Now static. Accept generic arguments, not | |
2999 | hashing-related ones. | |
3000 | ||
3001 | * src/symtab.h: (NUMBER_UNDEFINED): Remove unnecessary cast. | |
3002 | (symbol_processor): Remove. | |
3003 | (symbols_do): Remove decl; now static. | |
3004 | ||
3005 | * src/system.h (alloca): Remove; decl no longer needed. | |
3006 | (<stddef.h>): Include, for offsetof. | |
3007 | (<inttypes.>, <stdint.h>): Include if available. | |
3008 | (uintptr_t): New type, if system lacks it. | |
3009 | (CALLOC, MALLOC, REALLOC): New macros. | |
3010 | All uses of XCALLOC, XMALLOC, and XREALLOC changed to use these | |
3011 | new macros. | |
3012 | ||
3013 | * src/tables.c (table_size): Now int, to pacify GCC. | |
3014 | (table_grow, table_ninf_remap): Use signed table size. | |
3015 | (save_row): Don't bother initializing locals when not needed. | |
3016 | (default_goto, goto_actions, pack_vector): Remove unnecessary casts. | |
3017 | * src/uniqstr.c (hash_compare_uniqstr): Likewise. | |
3018 | ||
3019 | * src/vcg.h: Correct misspellings. | |
3020 | ||
3021 | * src/vcg_defaults.h (G_CMAX): Now INT_MAX. | |
3022 | ||
3023 | ||
3024 | * src/getargs.c (getargs): Don't assume EOF == -1. | |
3025 | ||
26b4a969 PE |
3026 | 2002-12-09 Paul Eggert <eggert@twinsun.com> |
3027 | ||
3028 | Change identifier spellings to avoid collisions with names | |
3029 | that are reserved by POSIX. | |
3030 | ||
3031 | Don't use names ending in _t, since POSIX reserves them. | |
3032 | For consistency, remove _e and _s endings -- they're weren't | |
3033 | needed to remove ambiguity. All uses changed. | |
3034 | * src/uniqstr.h (uniqstr): Renamed from uniqstr_t, which in | |
3035 | turn was just renamed from struniq_t. | |
3036 | * src/uniqstr.c (uniqstr_processor): Renamed from struniq_processor, | |
3037 | which in turn was just renamed from struniq_processor_t. | |
3038 | (hash_compare_uniqstr): Renamed from hash_compare_struniq, which | |
3039 | in turn was renamed from hash_compare_struniq_t. | |
3040 | * src/LR0.c (struct state_list): Renamed from struct state_list_s. | |
3041 | (state_list): Renamed from state_list_t. | |
3042 | * src/assoc.h (assoc): Renamed from assoc_t. | |
3043 | * src/conflicts.c (enum conflict_resolution): Renamed from | |
3044 | enum conflict_resolution_e. | |
3045 | * src/derives.c (struct rule_list): Renamed from struct rule_list_s. | |
3046 | (rule_list): Renamed from rule_list_t. | |
3047 | * src/getargs.h (enum trace): Renamed from enum trace_e. | |
3048 | (enum report): Renamed from enum report_e. | |
3049 | * src/gram.h (item_number): Renamed from item_number_t. | |
3050 | (rule_number): Renamed from rule_number_t. | |
3051 | (struct rule_s): Remove the "rule_s" part; not used. | |
3052 | (rule): Renamed from rule_t. | |
3053 | (rule_filter): Renamed from rule_filter_t. | |
3054 | * src/lalr.c (struct goto_list): Renamed from struct goto_list_s. | |
3055 | (goto_list): Renamed from goto_list_t. | |
3056 | * src/lalr.h (goto_number): Renamed from goto_number_t. | |
3057 | * src/location.h (location): Renamed from location_t. | |
3058 | * src/muscle_tab.c (muscle_entry): Renamed from muscle_entry_t, | |
3059 | and moved here from: | |
3060 | * src/muscle_tab.h (muscle_entry_t): here. | |
3061 | * src/nullable.c (struct rule_list): Renamed from struct rule_list_s. | |
3062 | (rule_list): Renamed from rule_list_t. | |
3063 | * src/print_graph.c (static_graph): Renamed from graph. | |
3064 | * src/reader.h (braced_code): Renamed from braced_code_t. | |
3065 | Remove brace_code_e tag. | |
3066 | * src/relation.h (relation_node): Renamed from relation_node_t. | |
3067 | (relation_nodes): Renamed from relation_nodes_t. | |
3068 | (relation): Renamed from relation_t. | |
3069 | * src/state.h (state_number): Renamed from state_number_t. | |
3070 | (struct state): Renamed from struct state_s. | |
3071 | (state): Renamed from state_t. | |
3072 | (transitions): Renamed from transitions_t. Unused (and | |
3073 | misspelled) transtion_s tag removed. | |
3074 | (errs): Renamed from errs_t. Unused errs_s tag removed. | |
3075 | (reductions): Renamed from reductions_t. Unused tag | |
3076 | reductions_s removed. | |
3077 | * src/symlist.h (symbol_list): Renamed from symbol_list_t. | |
3078 | (struct symbol_list): Renamed from struct symbol_list_s. | |
3079 | * src/symtab.h (symbol_number): Renamed from symbol_number_t. | |
3080 | (struct symbol): Renamed from struct symbol_s. | |
3081 | (symbol): Renamed from symbol_t. | |
3082 | * src/tables.c (vector_number): Renamed from vector_number_t. | |
3083 | (action_number): Renamed from action_t. | |
3084 | * src/tables.h (base_number): Renamed from base_t. | |
3085 | * src/vcg.h (enum color): Renamed from enum color_e. | |
3086 | (enum textmode): Renamed from enum textmode_e. | |
3087 | (enum shape): Renamed from enum shape_e. | |
3088 | (struct colorentry): Renamed from struct colorentry_s. | |
3089 | (struct classname): Renamed from struct classname_s. | |
3090 | (struct infoname): Renamed from struct infoname_s. | |
3091 | (enum layoutalgorithm): Renamed from enum layoutalgorithm_e. | |
3092 | (enum decision): Renamed from enum decision_e. | |
3093 | (enum orientation): Renamed from enum orientation_e. | |
3094 | (enum alignment): Renamed from enum alignment_e. | |
3095 | (enum arrow_mode): Renamed from enum arrow_mode_e. | |
3096 | (enum crossing_type): Renamed from enum crossing_type_e. | |
3097 | (enum view): Renamed from enum view_e. | |
3098 | (struct node): Renamed from struct node_s. | |
3099 | (node): Renamed from node_t. | |
3100 | (enum linestyle): Renamed from enum linestyle_e. | |
3101 | (enum arrowstyle): Renamed from enum arrowstyle_e. | |
3102 | (struct edge): Renamed from struct edge. | |
3103 | (edge): Renamed from edge_t. | |
3104 | (struct graph): Renamed from struct graph_s. | |
3105 | (graph): Renamed from graph_t. | |
3106 | * tests/calc.at (_AT_DATA_CALC_Y, Simple LALR Calculator): | |
3107 | Rename value_t -> value. | |
3108 | * tests/input.at (Torturing the Scanner): Rename value_t -> value, | |
3109 | value_t_as_yystype -> value_as_yystype. | |
3110 | ||
3111 | Don't include <errno.h> in the mainstream code, since it | |
3112 | reserves E[A-Z0-9]* and we want to use symbols like 'EQUALS'. | |
3113 | * lib/get-errno.c, lib/get-errno.h: New files. | |
3114 | * lib/Makefile.am (libbison_a_SOURCES): Add get-errno.h, | |
3115 | get-errno.c. | |
3116 | * src/files.c (xfopen, xfclose): Use get_errno instead of errno. | |
3117 | * src/output.c (output_skeleton): Likewise. | |
3118 | * src/scan-gram.l (<INITIAL>{int}): Use set_errno and get_errno | |
3119 | instead of errno. | |
3120 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>\\x[0-9abcdefABCDEF]+): | |
3121 | Likewise. | |
3122 | (handle_action_dollar, handle_action_at): Likewise. | |
3123 | * src/system.h: Do not include <errno.h>. | |
3124 | (TAB_EXT): Renamed from EXT_TAB. | |
3125 | (OUTPUT_EXT): Renamed from EXT_OUTPUT. | |
3126 | ||
3127 | Avoid str[a-z]*, since <string.h> reserves that name space. | |
3128 | Change all instances of "struniq" in names to "uniqstr", and | |
3129 | likewise for "STRUNIQ" and "UNIQSTR". | |
3130 | * src/uniqstr.c: Renamed from src/struniq.c. | |
3131 | * src/uniqstr.h: Renamed from src/struniq.h. | |
3132 | * src/Makefile.am (bison_SOURCES): Adjust to these renamings. | |
3133 | * src/files.c (strsuffix): Remove; unused. | |
3134 | (concat2): Renamed from stringappend. Now static. | |
3135 | * src/files.h (strsuffix, stringappend): Remove; unused. | |
3136 | * src/parse-gram.y (<chars>): Renamed from <string>. | |
3137 | (<uniqstr>): Renamed from <struniq>. | |
3138 | * src/scan-gram.l (obstack_for_string): Renamed from string_obstack. | |
3139 | * src/vcg.h (struct node_s.expand): Renamed from struct node_s.stretch. | |
3140 | (struct graph_s.expand): Renamed from struct graph_s.stretch. | |
3141 | * src/vcg_defaults.h (G_EXPAND): Renamed from G_STRETCH. | |
3142 | (G_LONG_STRAIGHT_PHASE): Renamed from G_STRAIGHT_PHASE. | |
3143 | (N_EXPAND): Renamed from N_STRETCH. | |
3144 | ||
3145 | Avoid *_MAX and *_MIN, since <limits.h> reserves that name space. | |
3146 | * data/yacc.c (YYSTACK_GAP_MAXIMUM): Renamed from YYSTACK_GAP_MAX. | |
3147 | * src/gram.h (ITEM_NUMBER_MAX, ITEM_NUMBER_MIN, RULE_NUMBER_MAX): | |
3148 | Remove; unused. | |
3149 | * src/lalr.h (GOTO_NUMBER_MAXIMUM): Renamed from GOTO_NUMBER_MAX. | |
3150 | * src/state.h (STATE_NUMBER_MAXIMUM): Renamed from STATE_NUMBER_MAX. | |
3151 | * src/symtab.h (SYMBOL_NUMBER_MAXIMUM): Renamed from SYMBOL_NUMBER_MAX. | |
3152 | * src/tables.c (VECTOR_NUMBER_MAX, VECTOR_NUMBER_MIN): Remove; unused. | |
3153 | (BASE_MAXIMUM): Renamed from BASE_MAX. | |
3154 | (BASE_MINIMUM): Renamed from BASE_MIN. | |
3155 | (ACTION_MAX): Remove; unused. | |
3156 | (ACTION_NUMBER_MINIMUM): Renamed from ACTION_MIN. | |
3157 | Unnecessary casts removed from above defines. | |
3158 | ||
3159 | ||
3160 | Fix misspelling in names. | |
3161 | * src/vcg.h (enum_alignment_e): Renamed from enum_alignement_e. | |
3162 | * src/vcg_defaults.h (G_NODE_ALIGNMENT): Renamed from | |
3163 | G_NODE_ALIGNEMENT. | |
3164 | ||
3165 | ||
3166 | * lib/timevar.c (timevar_report): Renamed from time_report, | |
3167 | for consistency with other names. | |
3168 | * lib/timevar.h (timevar_report): New decl. | |
3169 | * src/system.h (time_report): Remove; decl is now in lib/timevar.h. | |
3170 | ||
3171 | ||
3172 | Sort include-file uses. | |
3173 | ||
3174 | Reorder all include files under src to be in the order "system.h". | |
3175 | then the ../lib include files in angle brackets (alphabetized), | |
3176 | then the . include files in double-quotes (alphabetized). Fix | |
3177 | dependency breakages encountered in this process, as follows: | |
3178 | * src/closure.h, src/derives.h, src/state.h: Include "gram.h". | |
3179 | * src/complain.c: Don't include stdlib.h, string.h _LIBC stuff. | |
3180 | * src/state.h: Include "symtab.h". | |
3181 | ||
996b1c7e PE |
3182 | 2002-12-08 Paul Eggert <eggert@twinsun.com> |
3183 | ||
3184 | * data/glr.c, data/lalr1.cc, data/yacc.c: Do not use __file__, | |
3185 | since this causes problems when __file__ contains character | |
3186 | sequences like "@" that are treated specially by src/scan-skel.l. | |
3187 | Instead, just use the file's basename. This fixes the bug | |
3188 | reported by Martin Mokrejs in | |
161a71f3 | 3189 | <http://lists.gnu.org/archive/html/bug-bison/2002-12/msg00007.html>. |
996b1c7e | 3190 | |
e19c4e5d PE |
3191 | 2002-12-06 Paul Eggert <eggert@twinsun.com> |
3192 | ||
3193 | Add support for rules that do not have trailing semicolons, as | |
3194 | POSIX requires. Improve the quality of locations in Bison | |
3195 | diagnostics. | |
26b4a969 | 3196 | |
e19c4e5d PE |
3197 | * src/location.c: Include <quotearg.h>. |
3198 | (empty_location): Now const. | |
3199 | (location_print): New function. Follow the recommendation of the | |
3200 | GNU Coding Standards for locations that span file boundaries. | |
3201 | * src/location.h: Do not include <quotearg.h>; no longer needed. | |
3202 | (boundary): New type. | |
3203 | (location_t): Use it. This allows locations to span file boundaries. | |
3204 | All member uses changed: file -> start.file or end.file (as needed), | |
3205 | first_line -> start.line, first_column -> start.column, | |
3206 | last_line -> end.line, last_column -> end.column. | |
3207 | (equal_boundaries): New function. | |
3208 | (LOCATION_RESET, LOCATION_STEP): Remove. | |
3209 | (LOCATION_PRINT): Remove. All callers changed to use location_print. | |
3210 | (empty_location): Now const. | |
3211 | (location_print): New decl. | |
3212 | * src/parse-gram.y (lloc_default): New function, which handles | |
3213 | empty locations more accurately. | |
3214 | (YYLLOC_DEFAULT): Use it. | |
3215 | (%token COLON): Remove. | |
3216 | (%token ID_COLON): New token. | |
26b4a969 | 3217 | (rules): Use it. |
e19c4e5d PE |
3218 | (declarations, rules): Remove trailing semicolon. |
3219 | (declaration, rules_or_grammar_declaration): | |
3220 | Allow empty (";") declaration. | |
3221 | (symbol_def): Remove empty actions; no longer needed. | |
3222 | (rules_or_grammar_declaration): Remove trailing semicolon. | |
3223 | (semi_colon.opt): Remove. | |
3224 | * src/reader.h: Include location.h. | |
3225 | (scanner_cursor): New decl. | |
3226 | * src/reduce.c (nonterminals_reduce): Use warn_at rather than | |
3227 | rolling our own. | |
3228 | * src/scan-gram.l (YY_USER_INIT): Initialize scanner_cursor instead | |
3229 | of *loc. | |
3230 | (STEP): Remove. No longer needed, now that adjust_location does | |
3231 | the work. All uses removed. | |
3232 | (scanner_cursor): New var. | |
3233 | (adjust_location): Renamed from extend_location. It now sets | |
3234 | *loc and adjusts the scanner cursor. All uses changed. | |
3235 | Don't bother testing for CR. | |
3236 | (handle_syncline): Remove location arg; now updates scanner cursor. | |
3237 | All callers changed. | |
3238 | (unexpected_end_of_file): Now accepts start boundary of token or | |
3239 | comment, not location. All callers changed. Update scanner cursor, | |
3240 | not the location. | |
3241 | (SC_AFTER_IDENTIFIER): New state. | |
3242 | (context_state): Renamed from c_context. All uses changed. | |
3243 | (id_loc, code_start, token_start): New local vars. | |
3244 | (<INITIAL,SC_AFTER_IDENTIFIER>): New initial context. Move all | |
3245 | processing of Yacc white space and equivalents here. | |
3246 | (<INITIAL>{id}): Save id_loc. Begin state SC_AFTER_IDENTIFIER | |
3247 | instead of returning ID immediately, since we need to search for | |
3248 | a subsequent colon. | |
3249 | (<INITIAL>"'", "\""): Save token_start. | |
3250 | (<INITIAL>"%{", "{", "%%"): Save code_start. | |
3251 | (<SC_AFTER_IDENTIFIER>): New state, looking for a colon. | |
3252 | (<SC_YACC_COMMENT>, <SC_COMMENT>, <SC_LINE_COMMENT>): | |
3253 | BEGIN context_state at end, not INITIAL. | |
3254 | (<SC_ESCAPED_STRING>"\"", <SC_ESCAPED_CHARACTER>"'", | |
3255 | <SC_BRACED_CODE>"}", <SC_PROLOGUE>"%}", <SC_EPILOGUE><<EOF>>): | |
3256 | Return correct token start. | |
3257 | (<SC_BRACED_CODE,SC_PROLOGUE,SC_EPILOGUE>): Save start boundary when | |
3258 | the start of a character, string or multiline comment is found. | |
3259 | * tests/conflicts.at (S/R in initial, Defaulted Conflicted | |
3260 | Reduction): Adjust reported locations to match the more-precise | |
3261 | results now expected. | |
3262 | * tests/input.at (Invalid $n, Invalid @n, Type Clashes): Likewise. | |
3263 | * tests/reduce.at (Useless Rules, Reduced Automaton, | |
3264 | Underivable Rules): Likewise. | |
3265 | * tests/regression.at (Invalid inputs): No longer `expecting ";" | |
3266 | or "|"' now that so many other tokens are allowed by the new grammar. | |
3267 | ||
3268 | * src/complain.h (current_file): Remove duplicate decl; | |
3269 | current_file is now owned by files.h. | |
3270 | * src/complain.c, src/scan-gram.l: Include files.h. | |
3271 | ||
3272 | 2002-12-06 Paul Eggert <eggert@twinsun.com> | |
26b4a969 | 3273 | |
e19c4e5d PE |
3274 | * data/glr.c (yy_reduce_print): Don't assume that yyrline[yyrule] |
3275 | promotes to int; it might be unsigned int. | |
3276 | * data/yacc.c (yy_reduce_print): Likewise. | |
3277 | ||
3278 | * doc/bison.texinfo (Table of Symbols): YYERROR_VERBOSE should | |
3279 | be #defined in the prologue, not in the Bison declarations. | |
3280 | This fixes Debian Bug 102878, reported by Shaul Karl. | |
26b4a969 | 3281 | |
b64755e3 PE |
3282 | 2002-12-02 Paul Eggert <eggert@twinsun.com> |
3283 | ||
3284 | * configure.ac (AC_REPLACE_FUNCS): Add strtoul. | |
3285 | * lib/strtoul.c: New file, from gnulib. | |
3286 | This fixes a porting bug reported by Peter Klein in | |
161a71f3 | 3287 | <http://lists.gnu.org/archive/html/bug-bison/2002-12/msg00000.html>. |
b64755e3 | 3288 | |
6e746484 PE |
3289 | 2002-11-30 Paul Eggert <eggert@twinsun.com> |
3290 | ||
b64755e3 PE |
3291 | * src/scan-gram.l (no_cr_read, extend_location): Move to epilogue, |
3292 | and put only a forward declaration in the prologue. This is for | |
3293 | consistency with the other scanner helper functions. | |
3294 | ||
6ba55592 PE |
3295 | Type clashes now generate warnings, not errors, since it |
3296 | appears that POSIX may allow some grammars with type clashes. | |
3297 | * src/reader.c (grammar_current_rule_check): Warn about | |
3298 | type clashes instead of complaining. | |
3299 | * tests/input.at (Type Clashes): Expect warnings, not complaints. | |
3300 | ||
6e746484 PE |
3301 | Add Yacc library, since POSIX requires it. |
3302 | * doc/bison.texinfo (Yacc Library): New node. Regenerate top menu. | |
3303 | * lib/Makefile.am (lib_LIBRARIES, liby_a_SOURCES): New macros. | |
3304 | * lib/main.c, lib/yyerror.c: New files. | |
3305 | ||
3306 | gram_error can be static; it need not be extern. | |
3307 | * src/reader.h (gram_error): Remove decl. | |
3308 | * src/parse-gram.y (gram_error): Now static. Add static decl. | |
3309 | (print_token_value): Omit parameter names from forward decl, | |
3310 | for consistency. | |
3311 | ||
88510f9c PE |
3312 | 2002-11-29 Paul Eggert <eggert@twinsun.com> |
3313 | ||
6e746484 PE |
3314 | * doc/bison.texinfo: Emphasize that yylex and yyerror must |
3315 | be declared before being used. E.g., one should typically | |
3316 | declare them in the prologue. Use GNU coding style in examples. | |
3317 | Put "const" consistently after the type it modifies. Mention | |
3318 | that C99 supports "inline". Mention that yyerror traditionally | |
3319 | returns "int". | |
3320 | ||
88510f9c PE |
3321 | %parse-param and %lex-param now take just one argument, the |
3322 | declaration; the argument name is deduced from the declaration. | |
3323 | ||
3324 | * doc/bison.texinfo (Parser Function, Pure Calling, Error | |
3325 | Reporting, Table of Symbols): Document this. | |
3326 | * src/parse-gram.y (add_param): New function. | |
3327 | (COMMA): Remove. | |
3328 | (declaration): Implement new rule for %parse-param and %lex-param. | |
3329 | * src/scan-gram.l: "," now elicits a warning, rather than being | |
3330 | a token; this is more compatible with byacc. | |
3331 | * tests/calc.at (Simple LALR Calculator): Adopt new convention. | |
3332 | ||
bb92250c PE |
3333 | 2002-11-27 Paul Eggert <eggert@twinsun.com> |
3334 | ||
3335 | Rename identifiers to avoid real and potential collisions. | |
3336 | ||
3337 | * data/c.m4 (b4_yysymprint_generate): yyout -> yyoutput, | |
3338 | to avoid collision with lex macro described by Bruce Lilly in | |
161a71f3 | 3339 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. |
bb92250c PE |
3340 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise. |
3341 | * doc/bison.texinfo (Prologue, Tracing): yyprint -> print_token_value. | |
3342 | * src/parse-gram.y (print_token_value): Renamed from yyprint. | |
3343 | All uses changed. | |
3344 | (YYPARSE_PARAM, YYLEX_PARAM, yycontrol): Remove. All uses changed. | |
3345 | The name "yycontrol" violates the name space rules, and this stuff | |
3346 | wasn't being used anyway. | |
3347 | (input): Remove action; this stuff wasn't being used. | |
3348 | (gram_error): Rename local variable yylloc -> loc. | |
3349 | * src/reader.h (struct gram_control_s, gram_control_t): Remove. | |
3350 | (YY_DECL): Don't use "yy" at start of local variables. | |
3351 | All uses changed, e.g., yylloc -> loc. | |
3352 | * src/scan-gram.l (STEP): Renamed from YY_STEP. All uses changed. | |
3353 | (STRING_GROW): Renamed from YY_OBS_GROW. All uses changed. | |
3354 | (STRING_FINISH): Renamed from YY_OBS_FINISH. All uses changed. | |
3355 | (STRING_FREE): Renamed from YY_OBS_FREE. All uses changed. | |
3356 | ||
3357 | * src/parse-gram.y (gram_error): loc is now const *. | |
3358 | * src/reader.h (gram_error): Likewise. | |
3359 | ||
3af4feb2 PE |
3360 | 2002-11-24 Paul Eggert <eggert@twinsun.com> |
3361 | ||
3362 | Version 1.75c. | |
3363 | ||
3364 | * tests/actions.at (Actions after errors): Use an output format | |
3365 | more similar to that of the Printers and Destructors test. | |
3366 | Test the position of the ';' token too. | |
3367 | (Printers and Destructors): Likewise. | |
3368 | (Printers and Destructors: %glr-parser): Remove for now, to avoid | |
3369 | unnecessarily alarming people when the test fails. | |
3370 | ||
3371 | * data/yacc.c (yyerrlab1): Move this label down, so that the | |
3372 | parser does not discard the lookahead token if the user code | |
3373 | invokes YYERROR. This change is required for POSIX conformance. | |
3374 | ||
3375 | * lib/error.c: Sync with gnulib. | |
3376 | ||
3377 | 2002-11-22 Paul Eggert <eggert@twinsun.com> | |
3378 | ||
3379 | * lib/quotearg.c, lib/quotearg.h: Sync with gnulib. | |
3380 | * lib/mbswidth.c, lib/mbswidth.h: Likewise. | |
3381 | * lib/xmalloc.c: Likewise. | |
26b4a969 | 3382 | |
58004308 PE |
3383 | 2002-11-20 Paul Eggert <eggert@twinsun.com> |
3384 | ||
3385 | * lib/argmatch.c, lib/argmatch.h: Sync with gnulib. | |
3386 | ||
3387 | 2002-11-20 Paul Eggert <eggert@twinsun.com> | |
26b4a969 | 3388 | |
58004308 PE |
3389 | Avoid use of <assert.h>, as the GNU Coding Standards hint that one |
3390 | should use `if (! x) abort ();' rather than `assert (x);', and | |
3391 | anyway it's one less thing to worry about configuring. | |
3392 | ||
3393 | * data/glr.c, lib/hash.c, src/system.h: Do not include <assert.h>. | |
3394 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise, | |
3395 | and replace all instances of assert with abort. | |
3396 | * tests/calc.at (_AT_DATA_CALC_Y): Likewise. | |
3397 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Likewise. | |
3398 | ||
3399 | * data/glr.c (yydoAction, yyglrReduce, yysplitStack, yyresolveStates, | |
3400 | yyresolveAction, yyprocessOneStack): Use abort rather than assert. | |
3401 | * lib/hash.c (hash_lookup, hash_get_first, hash_get_next, | |
3402 | hash_find_entry, hash_rehash, hash_insert): Likewise. | |
3403 | * src/conflicts.c (resolve_sr_conflict): Likewise. | |
3404 | * src/lalr.c (set_goto_map, map_goto): Likewise. | |
3405 | * src/nullable.c (nullable_compute): Likewise. | |
3406 | * src/output.c (prepare_rules, token_definitions_output): Likewise. | |
3407 | * src/reader.c (packgram, reader): Likewise. | |
3408 | * src/state.c (state_new, state_free, state_transitions_set, | |
3409 | state_reduction_find): Likewise. | |
3410 | * src/symtab.c (symbol_user_token_number_set, symbol_make_alias, | |
3411 | symbol_pack): Likewise. | |
3412 | * src/tables.c (conflict_row, pack_vector): Likewise. | |
3413 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
3414 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
3415 | get_node_alignement_str, get_arrow_mode_str, get_crossing_type_str, | |
3416 | get_view_str, get_linestyle_str, get_arrowstyle_str): Likewise. | |
3417 | ||
3418 | * lib/argmatch.h (ARRAY_CARDINALITY): Do not bother to #undef. | |
3419 | (ARGMATCH_CONSTRAINT): New macro. | |
3420 | (ARGMATCH_ASSERT): Use it. | |
3421 | ||
3422 | * src/system.h (verify): New macro. | |
3423 | * src/getargs.c (trace_argmatch, report_argmatch): Use verify | |
3424 | rather than assert. | |
3425 | * src/tables.c (tables_generate): Likewise. | |
3426 | ||
3427 | * src/struniq.c (struniq_assert): Now returns void, and aborts | |
3428 | if the assertion is false. | |
3429 | (struniq_assert_p): Remove. | |
3430 | * src/struniq.h: Likewise. | |
3431 | ||
76ae8198 PE |
3432 | 2002-11-18 Paul Eggert <eggert@twinsun.com> |
3433 | ||
3434 | * data/glr.c (yygetLRActions): Replace `yyindex' with | |
3435 | `yytable[yyindex]' to fix typo introduced in my 2002-11-09 patch. | |
3436 | This fixes the regression with Sun ONE Studio 7 cc that I reported in | |
161a71f3 | 3437 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00077.html>. |
76ae8198 | 3438 | |
d3c4e709 AD |
3439 | 2002-11-18 Akim Demaille <akim@epita.fr> |
3440 | ||
3441 | * doc/bison.texinfo (Tracing): `yyprint' shouldn't prepend a | |
3442 | space. | |
3443 | From Tim Van Holder. | |
3444 | ||
8d8a7238 PE |
3445 | 2002-11-17 Paul Eggert <eggert@twinsun.com> |
3446 | ||
3447 | Pacify Sun ONE Studio 7 lint. Also, rename "ParseError" | |
3448 | to "SyntaxError" for consistency with my 2002-11-15 change. | |
3449 | ||
3450 | * data/glr.c (YYDPRINTF, YYDSYMPRINT, YYDSYMPRINTF) [!YYDEBUG]: Do | |
3451 | not define to {}, since this breaks the common use of `YYDPRINTF | |
3452 | ((...));' if a single statement is desired (e.g. before `else'). | |
3453 | Work around GCC warnings by surrounding corresponding calls with | |
3454 | {} if needed. | |
3455 | (yyhasResolvedValue): Remove unused function. | |
3456 | (yymergeOptionSets, yyresolvStack): Use `continue;' for empty | |
3457 | loop body. | |
3458 | (yyreportSyntaxError): Renamed from yyreportParseError. | |
3459 | (yyrecoverSyntaxError): Renamed from yyrecoverParseError. | |
3460 | All uses changed. | |
3461 | * tests/calc.at (_AT_DATA_CALC_Y): Make vars static instead of | |
3462 | extern when possible. Remove unused initializations. | |
3463 | ||
b0937b22 AD |
3464 | 2002-11-16 Akim Demaille <akim@epita.fr> |
3465 | ||
3466 | Augment the similarity between GLR and LALR traces. | |
3467 | ||
3468 | * data/yacc.c (yy_stack_print, YY_STACK_PRINT, yy_reduce_print) | |
3469 | (YY_REDUCE_PRINT): New. | |
3470 | (yyparse): Use them. | |
3471 | * data/glr.c (yy_reduce_print): Use YYFPRINTF, no need for | |
3472 | YYDPRINT here. | |
3473 | (yyglrReduce, yyrecoverParseError, yyparse): Don't report the | |
3474 | state reached after the reduction/recovery, since... | |
3475 | (yyparse, yyprocessOneStack): Report the state we are entering in. | |
3476 | ||
c5e3e510 AD |
3477 | 2002-11-16 Akim Demaille <akim@epita.fr> |
3478 | ||
3479 | * src/getargs.h, src/getargs.c (trace_e, trace_args, trace_types): | |
3480 | Add support for --trace=skeleton. | |
3481 | * src/scan-skel.l: %option debug. | |
3482 | Scan strings of non-@ or \n instead of character by character. | |
3483 | (scan_skel): Handle trace_skeleton. | |
3484 | (QPUTS): New. | |
3485 | (@output_parser_name@, @output_header_name@): ``Restore'' their | |
3486 | support (used to be M4 macros). | |
3487 | * data/yacc.c: Quote larger chunks, a la glr.c. | |
3488 | * data/lalr1.cc: Likewise. | |
3489 | The header guards are no longer available, so use some other | |
3490 | string than `YYLSP_NEEDED'. | |
3491 | ||
4c6cc1db AD |
3492 | 2002-11-16 Akim Demaille <akim@epita.fr> |
3493 | ||
3494 | Make the ``Printers and Destructors'' test more verbose, taking | |
3495 | `yacc.c''s behavior as (possibly wrong) reference. | |
3496 | ||
3497 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Use printf | |
3498 | instead of fprint on stdout. | |
3499 | Set and report the last_line of the symbols. | |
3500 | Consistently display values and locations. | |
3501 | ||
6d9e8019 PE |
3502 | 2002-11-16 Paul Eggert <eggert@twinsun.com> |
3503 | ||
3504 | * data/yacc.c: Avoid over-quoting of __line__ and __file__. | |
3505 | ||
6e649e65 PE |
3506 | 2002-11-15 Paul Eggert <eggert@twinsun.com> |
3507 | ||
b25d88f6 PE |
3508 | * tests/actions.at (Actions after errors): New test case. |
3509 | ||
6e649e65 PE |
3510 | * data/glr.c, data/lalr1.cc, data/yacc.cc, doc/bison.texinfo, |
3511 | src/conflicts.c, src/parse-gram.y, src/tables.c, src/tables.h, | |
3512 | tests/action.at, tests/calc.at, tests/conflicts.at, | |
3513 | tests/cxx-type.at, tests/regression.at: | |
3514 | "parse error" -> "syntax error" for POSIX compatibility. | |
3515 | "parsing stack overflow..." -> "parser stack overflow" so | |
3516 | that code matches Bison documentation. | |
3517 | ||
0f39aab9 AD |
3518 | 2002-11-15 Akim Demaille <akim@epita.fr> |
3519 | ||
3520 | * src/parse-gram.y (declaration): Have %parse-param and %lex-param | |
3521 | take two BRACED_CODE, not two string_content. | |
3522 | Free the scanner's obstack when we are done. | |
3523 | (code_content): New. | |
3524 | * tests/calc.at: Adjust. | |
3525 | * doc/bison.texinfo: Adjust. | |
3526 | Also, make sure to include the `,' for these declarations. | |
3527 | ||
761c1926 AD |
3528 | 2002-11-15 Tim Van Holder <tim.van.holder@pandora.be> |
3529 | ||
3530 | * m4/prereq.m4: Removed the commented jm_PREREQ_HASH | |
3531 | definition; avoids potential autoreconf problems. | |
3532 | ||
b0f98b10 AD |
3533 | 2002-11-15 Akim Demaille <akim@epita.fr> |
3534 | ||
3535 | Always check the value returned by yyparse. | |
3536 | ||
3537 | * tests/calc.at (_AT_DATA_CALC_Y): Have `main' exit with the value | |
3538 | returned by yyparse. | |
3539 | (_AT_CHECK_CALC_ERROR): Take the expected exit value as argument. | |
3540 | Adjust calls. | |
3541 | * tests/glr-regr1.at (glr-regr1.y): Have `main' exit with the value | |
3542 | returned by yyparse. | |
3543 | ||
970785f1 PH |
3544 | 2002-11-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
3545 | ||
3546 | * data/glr.c (yyFail): Always set yyerrflag. Corrects regression | |
3547 | on input.at test. | |
3548 | ||
8fcc7db1 PE |
3549 | 2002-11-14 Paul Eggert <eggert@twinsun.com> |
3550 | ||
7ec1b48e PE |
3551 | * src/output.c (output_skeleton): Call xfopen instead of |
3552 | duplicating xfopen's body. | |
3553 | ||
cfff7583 | 3554 | Fix bugs reported by Nelson H. F. Beebe in |
161a71f3 | 3555 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00078.html>. |
cfff7583 | 3556 | |
8fcc7db1 PE |
3557 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Don't assume that |
3558 | "$CC -E foo.h" is allowed, as this doesn't work with the Portland | |
3559 | Group compiler. Instead, use "$CC -E bar.c". Include the .h | |
3560 | file twice in the grammar, as an extra check. | |
3561 | ||
3562 | * tests/input.at (Torturing the Scanner): Surround the | |
3563 | backslash-newline tests with "#if 0", to make it less likely that | |
3564 | we'll run into compiler bugs. Bring back solitary \ inside | |
3565 | comment, but add a closing comment to work around HP C bug. Don't | |
e3aa65c5 | 3566 | test backslash-newline in C character constant. |
8fcc7db1 | 3567 | |
4e8d992c AD |
3568 | 2002-11-14 Akim Demaille <akim@epita.fr> |
3569 | ||
3570 | * tests/synclines.at (AT_SYNCLINES_COMPILE): Ignore the exit | |
3571 | status of the compiler. | |
f32b346d | 3572 | Calling `exit 1' is no longer needed. |
4e8d992c AD |
3573 | Reported by Nelson H. F. Beebe. |
3574 | ||
9501dc6e AD |
3575 | 2002-11-14 Akim Demaille <akim@epita.fr> |
3576 | ||
3577 | * tests/atlocal.in (CPPFLAGS): We have config.h. | |
3578 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR): | |
3579 | New. | |
3580 | * tests/actions.at, tests/calc.at, tests/conflicts.at, | |
3581 | * tests/cxx-type.at, tests/glr-regr1.at, tests/headers.at, | |
3582 | * tests/regression.at, tests/torture.at: Use them for all the | |
3583 | grammars that are to be compiled. | |
3584 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Rename as... | |
3585 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): this. | |
3586 | * doc/bison.texinfo (GLR Parsers): Document `inline'. | |
3587 | ||
18b519c0 AD |
3588 | 2002-11-14 Akim Demaille <akim@epita.fr> |
3589 | ||
3590 | * doc/bison.texinfo: Various formatting changes (alignments in | |
3591 | samples, additional @group/@end group, GCS in samples. | |
3592 | Use @deffn instead of simple @table to define the directives, | |
3593 | macros, variables etc. | |
3594 | ||
9a86cdb9 PE |
3595 | 2002-11-13 Paul Eggert <eggert@twinsun.com> |
3596 | ||
daa33def | 3597 | Fix some bugs reported by Albert Chin-A-Young in |
161a71f3 | 3598 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00066.html>. |
18b519c0 | 3599 | |
daa33def | 3600 | * tests/input.at (Torturing the Scanner): Don't invoke "cc a.c b.c |
8fcc7db1 | 3601 | -o c"; the HP C compiler chatters during compilation. |
daa33def PE |
3602 | Instead, invoke "cc -c a.c -o a.o; cc -c b.c -o b.o; cc a.o b.o -o c". |
3603 | * tests/headers.at (export YYLTYPE): Likewise. | |
3604 | ||
3605 | * tests/input.at (Torturing the Scanner): Remove lines containing | |
8fcc7db1 | 3606 | solitary backslashes, as they tickle a bug in the HP C compiler. |
daa33def | 3607 | |
9a86cdb9 PE |
3608 | * tests/glr-regr1.at (Badly Collapsed GLR States): Avoid // |
3609 | comments, since they're not portable. Use GNU coding style. | |
3610 | ||
9c1e26bd AD |
3611 | 2002-11-13 Akim Demaille <akim@epita.fr> |
3612 | ||
3613 | * data/yacc.c: Leave bigger chunks of quoted text. | |
3614 | (YYDSYMPRINTF): New. | |
3615 | Use it to report symbol activities. | |
3616 | * data/glr.c (YYDSYMPRINTF): New. | |
3617 | Use it. | |
3618 | ||
87f721cc PE |
3619 | 2002-11-12 Paul Eggert <eggert@twinsun.com> |
3620 | ||
3621 | Version 1.75b. | |
3622 | ||
3623 | * data/glr.c (yydoAction): Return YYRESULTTAG, not int. | |
3624 | (yyglrReduce): Return yyok, not 0. | |
3625 | This should avoid the enumerated-type warnings reported | |
464c6927 | 3626 | by Nelson H. F. Beebe in |
161a71f3 | 3627 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00057.html>. |
87f721cc PE |
3628 | |
3629 | * lib/bbitset.h (BITSET_INLINE): Remove. | |
3630 | * lib/bitset.h [! BITSET_INLINE]: Remove. | |
3631 | (bitset_set, bitset_reset, bitset_test): Rename local vars | |
3632 | to avoid shadowing warnings by GCC. | |
3633 | ||
3634 | * data/glr.c (inline): Remove #define. It's the user's | |
3635 | responsibility to #define it away, just like 'const'. | |
464c6927 | 3636 | This fixes one of the bugs reported by Nelson H. F. Beebe in |
161a71f3 | 3637 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00058.html>. |
18b519c0 | 3638 | |
87f721cc PE |
3639 | * Makefile.maint (po-check): Scan .l and .y files instead of the |
3640 | .c and the .h files that they generate. This fixes the bug | |
3641 | reported by Tim Van Holder in: | |
161a71f3 | 3642 | <http://lists.gnu.org/archive/html/bison-patches/2002-11/msg00062.html> |
87f721cc PE |
3643 | Look for N_ as well as for _. Try to avoid matching #define for |
3644 | N_ and _. | |
3645 | * po/POTFILES.in: Remove src/parse-gram.c, src/scan-gram.c, | |
3646 | src/system.h. Add src/parse-gram.y, src/scan-gram.l. | |
3647 | * src/scan-gram.l: Revamp regular expressions so that " and ' | |
3648 | do not confuse xgettext. | |
3649 | ||
3650 | * src/struniq.h (struniq_new): Do not declare the return type | |
3651 | to be 'const'; this violates the C standard. | |
3652 | * src/struniq.c (struniq_new): Likewise. | |
3653 | ||
be14ade5 AD |
3654 | 2002-11-12 Albert Chin-A-Young <china@thewrittenword.com> |
3655 | ||
3656 | * src/Makefile.am (LDADD): Link $(LIBINTL) last to avoid the | |
3657 | duplicate definition of optind on Tru64 UNIX 4.0D with the Compaq | |
3658 | linker. | |
3659 | ||
05291fbc AD |
3660 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3661 | ||
3662 | * Makefile.maint: Sync with Autoconf: | |
3663 | (local_updates): New. | |
3664 | ||
1f5fd52e AD |
3665 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3666 | ||
3667 | * po/POTFILES.in (src/lalr.c, src/state.c): Remove | |
3668 | ||
283f1e64 AD |
3669 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3670 | ||
3671 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Display the | |
3672 | locations. | |
3673 | ||
886b69d1 AD |
3674 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3675 | ||
3676 | * data/c.m4 (b4_yysymprint_generate): Pass *yyvaluep to YYPRINT, | |
3677 | not yyvalue. | |
3678 | ||
3df37415 AD |
3679 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3680 | ||
3681 | * tests/actions.at (AT_CHECK_PRINTER_AND_DESTRUCTOR): New. | |
3682 | Use it to test the GLR parser. | |
3683 | ||
7bd6c77e AD |
3684 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3685 | ||
3686 | * tests/regression.at (input.y): s/YYEOF/MYEOF/, as the skeleton | |
3687 | defines it. | |
3688 | * data/glr.c (yystos): New. | |
3689 | (b4_yysymprint_generate, b4_yydestruct_generate): Invoke. | |
3690 | (YYDSYMPRINT): New. | |
3691 | (yyval): Don't define it, it is handled via M4. | |
3692 | (yyrecoverParseError): Free verbosely the discarded symbols. | |
3693 | * data/yacc.c (yysymprint): Remove, rather... | |
3694 | (b4_yysymprint_generate): invoke. | |
3695 | * data/c.m4 (b4_yysymprint_generate): New. | |
3696 | Accept pointers as arguments, as opposed to the version from | |
3697 | yacc.c. | |
3698 | (b4_yydestruct_generate): Likewise. | |
3699 | * tests/cations.at (Printers and Destructors): Use Bison directives | |
3700 | instead of CPP macros. | |
3701 | Don't rely on internal details. | |
3702 | ||
b0400cc6 AD |
3703 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3704 | ||
3705 | * data/c.m4 (b4_yydestruct_generate, b4_symbol_actions): New. | |
3706 | * data/yacc.c: Rename yychar1 as yytoken, as in glr.c. | |
3707 | Don't work on yychar (i.e., do set it to YYEMPTY, don't match | |
3708 | it against YYEMPTY and so forth), work on yytoken (i.e., set | |
3709 | it to YYEMPTY etc.). | |
3710 | (yydestruct): Replace with a b4_yydestruct_generate invocation. | |
3711 | (b4_symbol_actions): Remove. | |
3712 | * data/glr.c (YYTRANSLATE): As for yacc.c, if negative, it stands | |
3713 | for 0, end-of-input. | |
3714 | ||
72f889cc AD |
3715 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3716 | ||
3717 | * doc/bison.texinfo (Destructor Decl): New. | |
3718 | ||
b1ae9233 AD |
3719 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3720 | ||
3721 | * src/tables.c (tables_generate): Use free for pointers that | |
3722 | cannot be NULL, not XFREE. | |
3723 | (pack_vector): Use assert, not fatal, for bound violations. | |
3724 | * src/state.c (state_new): Likewise. | |
3725 | * src/reader.c (reader): Likewise. | |
3726 | * src/lalr.c (set_goto_map): Likewise. | |
72f889cc | 3727 | * src/location.h (LOCATION_PRINT): If first_line is 0, just issue |
b1ae9233 AD |
3728 | the file name. |
3729 | ||
7ec2d4cd AD |
3730 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3731 | ||
3732 | * src/scan-gram.l, src/reader.h (scanner_last_string_free): | |
3733 | Restore. | |
3734 | * src/scan-gram.l (last_string): Is global to the file, not to | |
3735 | yylex. | |
3736 | * src/parse-gram.y (input): Don't append the epilogue here, | |
3737 | (epilogue.opt): do it here, and free the scanner's obstack. | |
3738 | * src/reader.c (epilogue_set): Rename as... | |
3739 | (epilogue_augment): this. | |
3740 | * data/c.m4 (b4_epilogue): Defaults to empty. | |
3741 | ||
573a6cd3 AD |
3742 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3743 | ||
3744 | * src/getargs.c (long_options): Remove duplicates. | |
3745 | * src/vmsgetargs.c, src/build.com, src/bison.cld, src/vmshlp.mar: | |
3746 | Remove. | |
3747 | * doc/bison.rnh: Remove. | |
3748 | * doc/bison.texinfo (VMS Invocation): Remove. | |
3749 | ||
95612cfa AD |
3750 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3751 | ||
3752 | * src/struniq.h, src/struniq.c (struniq_t): Is const. | |
3753 | (STRUNIQ_EQ, struniq_assert, struniq_assert_p): New. | |
3754 | ||
3755 | Use struniq for symbols. | |
3756 | ||
3757 | * src/symtab.h (symbol_t): The tag member is a struniq. | |
3758 | (symbol_type_set): Adjust. | |
3759 | * src/symtab.c (symbol_new): Takes a struniq. | |
3760 | (symbol_free): Don't free the tag member. | |
3761 | (hash_compare_symbol_t, hash_symbol_t): Rename as... | |
3762 | (hash_compare_symbol, hash_symbol): these. | |
3763 | Use the fact that tags as struniqs. | |
3764 | (symbol_get): Use struniq_new. | |
3765 | * src/symlist.h, src/symlist.c (symbol_list_n_type_name_get): | |
3766 | Returns a strniq. | |
3767 | * src/reader.h (merger_list, grammar_currentmerge_set): The name | |
3768 | and type members are struniqs. | |
3769 | * src/reader.c (get_merge_function) | |
3770 | (grammar_current_rule_merge_set): Adjust. | |
3771 | (TYPE, current_type): Are struniq. | |
3772 | ||
3773 | Use struniq for file names. | |
3774 | ||
3775 | * src/files.h, src/files.c (infile): Split into... | |
3776 | (grammar_file, current_file): these. | |
3777 | * src/scan-gram.c (YY_USER_INIT, handle_syncline): Adjust. | |
3778 | * src/reduce.c (reduce_print): Likewise. | |
3779 | * src/getargs.c (getargs): Likewise. | |
3780 | * src/complain.h, src/complain.c: Likewise. | |
3781 | * src/main.c (main): Call struniqs_new early enough to use it for | |
3782 | file names. | |
3783 | Don't free the input file name. | |
3784 | ||
3e6656f9 AD |
3785 | 2002-11-12 Akim Demaille <akim@epita.fr> |
3786 | ||
3787 | * src/symtab.c (symbol_free): Remove dead deactivated code: | |
3788 | type_name are properly removed. | |
3789 | Don't use XFREE to free items that cannot be NULL. | |
3790 | * src/struniq.h, src/struniq.c: New. | |
3791 | * src/main.c (main): Initialize/free struniqs. | |
3792 | * src/parse-gram.y (%union): Add astruniq member. | |
3793 | (yyprint): Adjust. | |
3794 | * src/scan-gram.l (<{tag}>): Return a struniq. | |
3795 | Free the obstack bit that used to store it. | |
3796 | * src/symtab.h (symbol_t): The 'type_name' member is a struniq. | |
3797 | ||
7672019c PE |
3798 | 2002-11-11 Paul Eggert <eggert@twinsun.com> |
3799 | ||
3800 | Revamp to fix many (but not all) of the C- and M4-related quoting | |
3801 | problems. Among other things, this fixes the Bison bug reported | |
3802 | by Jan Hubicka when processing the Bash grammar; see: | |
161a71f3 | 3803 | <http://lists.gnu.org/archive/html/bison-patches/2002-11/msg00039.html> |
7672019c PE |
3804 | |
3805 | Use new @ escapes consistently. Represent brackets with @{ and @} | |
3806 | rather than @<:@ and @:>@, since this works a bit better with dumb | |
3807 | editors like vi. Represent @ with @@, since @ is now consistently | |
3808 | an escape. Use @oline@ and @ofile@ rather than __oline__ and | |
3809 | __ofile__, to avoid unexpected expansions. Similarly, use @output | |
3810 | rather than #output. | |
3811 | ||
3812 | * data/c.m4 (b4_copyright): Omit file name from comment, since | |
3813 | the file name could contain "*/". | |
3814 | (b4_synclines_flag): Don't quote the 2nd argument; it should already | |
3815 | be quoted. All uses changed. | |
3816 | ||
3817 | * data/glr.c: Use new @ escapes consistently. | |
3818 | (b4_input_suffix, b4_output_parser_suffix, b4_output_parser_name, | |
3819 | b4_output_header_suffix, b4_output_header_name, b4_header_guard): | |
3820 | Remove, since they couldn't handle arbitrary characters in file | |
3821 | names. | |
3822 | * data/lalr1.cc: Likewise. | |
3823 | * data/yacc.c: Likewise. | |
3824 | ||
3825 | * src/files.c (output_infix): Remove; all uses removed. | |
3826 | * src/files.h: Likewise. | |
3827 | ||
3828 | * data/glr.c: Remove use of "#ifdef b4_header_guard", since it | |
3829 | mishandled funny characters in file names, and anyway it isn't | |
3830 | needed any more. | |
3831 | * data/yacc.c: Likewise. | |
3832 | * data/lalr1.cc: Use YYSLP_NEEDED instead of b4_header_guard. | |
3833 | ||
3834 | * data/glr.c (YYSTYPE_IS_TRIVIAL): Define when the .h file would. | |
3835 | * data/yacc.c: Likewise. | |
3836 | ||
3837 | * src/muscle_tab.c: Include quotearg.h, since we need to quote C | |
3838 | strings now. | |
3839 | (muscle_init): Quote filename as a C string. | |
3840 | * src/muscle_tab.h (MUSCLE_GROW_STRING_PAIR): Remove; unused. | |
3841 | (MUSCLE_OBSTACK_SGROW, MUSCLE_INSERT_C_STRING): New macros. | |
3842 | * src/output.c (escaped_file_name_output): New function. | |
3843 | (prepare_symbols): Quote tokens for M4. | |
3844 | (prepare): Don't insert output_infix, output_prefix, | |
3845 | output_parser_name, output_header_name; this is now down by scan-skel. | |
3846 | Insert skeleton as a C string. | |
3847 | ||
3848 | * src/output.c (user_actions_output, symbol_destructors_output, | |
3849 | symbol_printers_output): Quote filenames for C and M4. | |
3850 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
3851 | ||
3852 | * src/scan-gram.l (<SC_CHARACTER>): Don't worry about any backslash | |
3853 | escapes other than \\ and \'; this simplifies the code. | |
3854 | (<SC_STRING>): Likewise, for \\ and \". | |
3855 | (<SC_COMMENT,SC_LINE_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE, | |
3856 | SC_PROLOGUE,SC_EPILOGUE>): Escape $ and @, too. | |
3857 | Use new escapes @{ and @} for [ and ]. | |
3858 | ||
3859 | * src/scan-skel.l (yylineno, yyoutname): Remove static vars, replacing | |
3860 | them with auto vars. | |
3861 | Switch to new escape scheme, where @ is the escape character uniformly. | |
3862 | Abort if a stray escape character is found. Avoid unbounded input | |
3863 | buffer when parsing non-escaped text. | |
3864 | ||
3865 | * tests/input.at (Torturing the Scanner): Add tests that @oline@, | |
3866 | __oline__, #output, $@, and @{ do not have unintended meanings. | |
3867 | ||
acea4f3b PE |
3868 | 2002-11-09 Paul Eggert <eggert@twinsun.com> |
3869 | ||
3870 | Fix the test failure due to GCC warnings described in | |
161a71f3 | 3871 | <http://lists.gnu.org/archive/html/bug-bison/2002-11/msg00000.html>. |
acea4f3b PE |
3872 | * data/glr.c (yyis_pact_ninf, yyis_table_ninf): New macros, which |
3873 | evaluate to 0 if it's impossible for NINF to be in the respective | |
3874 | table. | |
3875 | (yygetLRActions, yyrecoverParseError): Use them. | |
3876 | ||
3877 | * src/scan-gram.l (unexpected_end_of_file): Fix bug: columns were | |
3878 | counted in the token inserted at end of file. Now takes | |
3879 | location_t *, not location_t, so that the location can be | |
3880 | adjusted. All uses changed. | |
3881 | ||
3882 | * tests/regression.at (Invalid inputs): Adjust wording in | |
3883 | diagnostic to match the new behavior. | |
3884 | ||
3885 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR, | |
3886 | AT_DATA_HORIZONTAL_GRAMMAR, AT_DATA_LOOKAHEADS_GRAMMAR, | |
3887 | AT_DATA_STACK_TORTURE): Replace `assert (x);' with `if (! (x)) | |
3888 | abort ();'. This reduces the runtime of the "Many lookaheads" | |
3889 | test from 27.6 to 2.7 minutes on a 440 MHz Ultrasparc III running | |
3890 | GCC 3.2. | |
3891 | ||
20ef1ad5 PE |
3892 | 2002-11-07 Paul Eggert <eggert@twinsun.com> |
3893 | ||
3894 | * src/parse-gram.y (CHARACTER): Remove unused token. | |
3895 | All uses removed. | |
3896 | ||
3897 | * src/scan-gram.l: Remove stack option. We no longer use the | |
3898 | stack, since the stack was never deeper than 1; instead, use the | |
3899 | new auto var c_context to record the stacked value. | |
3900 | ||
3901 | Remove nounput option. At an unexpected end of file, we now unput | |
3902 | the minimal input necessary to end cleanly; this simplifies the | |
3903 | code. | |
3904 | ||
3905 | Avoid unbounded token sizes where this is easy. | |
3906 | ||
3907 | (unexpected_end_of_file): New function. | |
3908 | Use it to systematize the error message on unexpected EOF. | |
3909 | (last-string): Now auto, not static. | |
3910 | (YY_OBS_FREE): Remove unnecessary do while (0) wrapper. | |
3911 | (scanner_last_string_free): Remove; not used. | |
3912 | (percent_percent_count): Move decl to just before use. | |
3913 | (SC_ESCAPED_CHARACTER): Return ID at unexpected end of file, | |
3914 | not the (never otherwised-used) CHARACTER. | |
3915 | ||
93724f13 AD |
3916 | 2002-11-07 Akim Demaille <akim@epita.fr> |
3917 | ||
3918 | Let yyerror always receive the msg as last argument, so that | |
3919 | yyerror can be variadic. | |
3920 | ||
3921 | * data/yacc.c (b4_yyerror_args): New. | |
3922 | Use it when calling yyerror. | |
3923 | * data/glr.c (b4_yyerror_args, b4_lyyerror_args): New. | |
3924 | Use it when calling yyerror. | |
3925 | * doc/bison.texinfo (Error Reporting): Adjust. | |
3926 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust. | |
3927 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Adjust. | |
3928 | ||
6e40b4eb AD |
3929 | 2002-11-06 Akim Demaille <akim@epita.fr> |
3930 | ||
3931 | #line should have quoted strings. | |
3932 | Ideally, this should be done by m4_quotearg. | |
3933 | ||
3934 | * src/scan-skel.l: Include quotearg.h. | |
3935 | Quote __ofile__. | |
3936 | * src/output.c (symbol_printers_output) | |
3937 | (symbol_destructors_output): Quote the file name. | |
3938 | ||
2dfbfc12 AD |
3939 | 2002-11-06 Akim Demaille <akim@epita.fr> |
3940 | ||
3941 | * tests/regression.at (Invalid inputs): Adjust to the recent | |
3942 | messages. | |
3943 | ||
437c2d80 AD |
3944 | 2002-11-06 Akim Demaille <akim@epita.fr> |
3945 | ||
3946 | Restore --no-lines. | |
3947 | Reported by Jim Kent. | |
3948 | ||
3949 | * data/c.m4 (b4_syncline): New. | |
3950 | * data/glr.c, data/yacc.c, data/lalr1.cc: Use it. | |
3951 | * src/reader.c (prologue_augment, epilogue_set): Use b4_syncline. | |
3952 | * src/output.c (user_actions_output): Likewise. | |
3953 | (prepare): Define 'b4_synclines_flag'. | |
2dfbfc12 | 3954 | * src/muscle_tab.c (muscle_init): Don't define b4_linef. |
437c2d80 | 3955 | |
900c5db5 AD |
3956 | 2002-11-06 Akim Demaille <akim@epita.fr> |
3957 | ||
3958 | * src/main.c (main): Free `infile'. | |
3959 | * src/scan-gram.l (handle_syncline): New. | |
3960 | Recognize `#line'. | |
3961 | * src/output.c (user_actions_output, symbol_destructors_output) | |
3962 | (symbol_printers_output): Use the location's file name, not | |
3963 | infile. | |
3964 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
3965 | ||
e183b123 | 3966 | 2002-11-05 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
51b4a04c | 3967 | |
e183b123 | 3968 | * src/tables.c (matching_state): Don't allow states to match if |
51b4a04c | 3969 | either has GLR conflict entries. |
e183b123 | 3970 | |
193eb6b7 PE |
3971 | 2002-11-05 Paul Eggert <eggert@twinsun.com> |
3972 | ||
e183b123 PE |
3973 | * src/scan-gram.l: Use more accurate diagnostics, e.g. |
3974 | "integer out of range" rather than "invalid value". | |
3975 | * tests/input.at (Invalid $n, Invalid @n): Change expected wording | |
3976 | accordingly. | |
3977 | ||
193eb6b7 PE |
3978 | Scan <% and %> digraphs in C code as POSIX 1003.1-2001 requires. |
3979 | Also, remove one static variable in the scanner. | |
3980 | ||
3981 | * src/scan-gram.l (braces_level): Now auto, not static. | |
3982 | Initialize to zero if the compiler is being picky. | |
3983 | (INITIAL): Clear braces_level instead of incrementing it. | |
3984 | (SC_BRACED_CODE): Treat <% and %> as { and } when inside C code, | |
3985 | as POSIX 1003.1-2001 requires. | |
3986 | * src/system.h (IF_LINT): New macro, taken from coreutils. | |
3987 | * configure.ac: Define "lint" if --enable-gcc-warnings. | |
3988 | ||
29c01725 AD |
3989 | 2002-11-05 Akim Demaille <akim@epita.fr> |
3990 | ||
3991 | * src/scan-gram.l: When it starts with `%', complain about the | |
3992 | whole directive, not just that `invalid character: %'. | |
3993 | ||
8aeac3ca AD |
3994 | 2002-11-04 Akim Demaille <akim@epita.fr> |
3995 | ||
3996 | * Makefile.maint: Update from Autoconf. | |
3997 | (update, cvs-update, po-update, do-po-update): New. | |
3998 | ||
793a58bb AD |
3999 | 2002-11-04 Akim Demaille <akim@epita.fr> |
4000 | ||
4001 | * tests/glr-regr1.at (Badly Collapsed GLR States): Prototype yylex | |
4002 | and yyerror. | |
4003 | Have yyerror `use' its arguments. | |
4004 | * tests/calc.at (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF | |
4005 | returns true when location & yacc & pure & parse-param. | |
4006 | (_AT_DATA_CALC_Y): Let yyerror ``use'' its arguments. | |
4007 | ||
c4d720cd AD |
4008 | 2002-11-04 Akim Demaille <akim@epita.fr> |
4009 | ||
4010 | * src/location.h (LOCATION_PRINT): Use quotearg slot 3 to avoid | |
4011 | clashes. | |
4012 | * src/scan-gram.l: Use [\'] instead of ['] to pacify | |
4013 | font-lock-mode. | |
4014 | Use complain_at. | |
4015 | Use quote, not quote_n since LOCATION_PRINT no longer uses the | |
4016 | slot 0. | |
4017 | ||
613a0dc5 PE |
4018 | 2002-11-03 Paul Eggert <eggert@twinsun.com> |
4019 | ||
4020 | * src/reader.c (get_merge_function, grammar_current_rule_check): | |
4021 | Use consistent diagnostics for reporting type name clashes. | |
4022 | Quote the types with <>, for consistency with Yacc. | |
4023 | * tests/input.at (Type Clashes): Adjust to diagnostic changes. | |
4024 | ||
2a8d363a AD |
4025 | 2002-11-03 Akim Demaille <akim@epita.fr> |
4026 | ||
4027 | * data/c.m4 (b4_identification, b4_user_args, b4_parse_param): | |
4028 | New. | |
4029 | * data/yacc.m4 (b4_pure_args, b4_Pure_args): New. | |
4030 | (b4_parse_param): Remove. | |
4031 | Use b4_identification. | |
4032 | Propagate b4_pure_args where needed to pass them to yyerror. | |
4033 | * data/glr.m4 (b4_parse_param): Remove. | |
4034 | (b4_user_formals, b4_pure_args, b4_pure_formals, b4_lpure_args) | |
4035 | (b4_lpure_formals): New. | |
4036 | Use b4_identification. | |
4037 | (YY_USER_FORMALS, YY_USER_ARGS): Remove, replaced by | |
4038 | b4_user_formals and b4_user_args. | |
4039 | (yyexpandGLRStack, yyFail, yyaddDeferredAction, yyglrShiftDefer) | |
4040 | (yyreportAmbiguity): When using a pure parser, also need | |
4041 | the location, and the parse-params. | |
4042 | Adjust callers. | |
4043 | (yyuserAction, yyglrShift, yyreportParseError, yyrecoverParseError): | |
4044 | When using a pure parser, also need the parse-params. | |
4045 | Adjust callers. | |
4046 | * tests/calc.at: Test pure (%pure-parser) and absolutely pure | |
4047 | (%pure-parser + %parse-param) LALR and GLR parsers. | |
4048 | (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): New, define AT_PARAM_IF, | |
4049 | AT_LOCATION_IF, AT_PURE_IF, AT_GLR_IF, AAT_PURE_AND_LOC_IF, | |
4050 | AT_GLR_OR_PARAM_IF, AT_YYERROR_ARG_LOC_IF, AT_YYERROR_SEES_LOC_IF. | |
4051 | (_AT_DATA_CALC_Y): Equip for purity of yyerror. | |
4052 | (_AT_CHECK_CALC_ERROR): Use AT_YYERROR_SEES_LOC_IF. | |
4053 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Equip for yyerror purity. | |
4054 | * doc/bison.texinfo: Untabify the whole file. | |
4055 | (Parser Function): Document %parse-param, deprecate YYPARSE_PARAM. | |
4056 | (Pure Calling): Document %lex-param, deprecate YYLEX_PARAM. | |
4057 | (Error Reporting): Adjust to these new directives. | |
4058 | Document %error-verbose, deprecate YYERROR_VERBOSE. | |
4059 | ||
9e32add8 AD |
4060 | 2002-11-03 Akim Demaille <akim@epita.fr> |
4061 | ||
4062 | * tests/calc.at: Change all the AT_CHECK_CALC_LALR and | |
4063 | AT_CHECK_CALC_GLR invocations to use % directives, instead of | |
4064 | command line options. | |
4065 | * tests/cxx-type.at: Formatting changes. | |
4066 | ||
b02d90a5 PE |
4067 | 2002-11-03 Paul Eggert <eggert@twinsun.com> |
4068 | ||
4069 | * src/scan-gram.l: Revamp to fix POSIX incompatibilities, | |
4070 | to count columns correctly, and to check for invalid inputs. | |
9e32add8 | 4071 | |
b02d90a5 PE |
4072 | Use mbsnwidth to count columns correctly. Account for tabs, too. |
4073 | Include mbswidth.h. | |
4074 | (YY_USER_ACTION): Invoke extend_location rather than LOCATION_COLUMNS. | |
4075 | (extend_location): New function. | |
4076 | (YY_LINES): Remove. | |
4077 | ||
4078 | Handle CRLF in C code rather than in Lex code. | |
4079 | (YY_INPUT): New macro. | |
4080 | (no_cr_read): New function. | |
4081 | ||
4082 | Scan UCNs, even though we don't fully handle them yet. | |
4083 | (convert_ucn_to_byte): New function. | |
4084 | ||
4085 | Handle backslash-newline correctly in C code. | |
4086 | (SC_LINE_COMMENT, SC_YACC_COMMENT): New states. | |
4087 | (eols, blanks): Remove. YY_USER_ACTION now counts newlines etc.; | |
4088 | all uses changed. | |
4089 | (tag, splice): New EREs. Do not allow NUL or newline in tags. | |
4090 | Use {splice} wherever C allows backslash-newline. | |
4091 | YY_STEP after space, newline, vertical-tab. | |
4092 | ("/*"): BEGIN SC_YACC_COMMENT, not yy_push_state (SC_COMMENT). | |
9e32add8 | 4093 | |
b02d90a5 PE |
4094 | (letter, id): Don't assume ASCII; e.g., spell out a-z. |
4095 | ||
4096 | ({int}, handle_action_dollar, handle_action_at): Check for integer | |
4097 | overflow. | |
9e32add8 | 4098 | |
b02d90a5 PE |
4099 | (YY_STEP): Omit trailing semicolon, so that it's more like C. |
4100 | ||
4101 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>): Allow \0 and \00 | |
4102 | as well as \000. Check for UCHAR_MAX, not 255. | |
4103 | Allow \x with an arbitrary positive number of digits, as in C. | |
4104 | Check for overflow here. | |
4105 | Allow \? and UCNs, for compatibility with C. | |
4106 | ||
4107 | (handle_symbol_code_dollar): Use quote_n slot 1 to avoid collision | |
4108 | with quote slot used by complain_at. | |
4109 | ||
4110 | * tests/input.at: Add tests for backslash-newline, m4 quotes | |
4111 | in symbols, long literals, and funny escapes in strings. | |
4112 | ||
4113 | * configure.ac (jm_PREREQ_MBSWIDTH): Add. | |
4114 | * lib/Makefile.am (libbison_a_SOURCES): Add mbswidth.h, mbswidth.c. | |
4115 | * lib/mbswidth.h, lib/mbswidth.c: New files, from GNU gettext. | |
4116 | * m4/Makefile.am (EXTRA_DIST): Add mbswidth.m4. | |
4117 | * m4/mbswidth.m4: New file, from GNU coreutils. | |
4118 | ||
4119 | * doc/bison.texinfo (Grammar Outline): Document // comments. | |
4120 | (Symbols): Document that trigraphs have no special meaning in Bison, | |
4121 | nor is backslash-newline allowed. | |
4122 | (Actions): Document that trigraphs have no special meaning. | |
4123 | ||
4124 | * src/location.h (LOCATION_COLUMNS, LOCATION_LINES): Remove; | |
4125 | no longer used. | |
4126 | ||
4127 | 2002-11-02 Paul Eggert <eggert@twinsun.com> | |
4128 | ||
4129 | * src/reader.c: Don't include quote.h; not needed. | |
4130 | (get_merge_function): Reword warning to be consistent with | |
4131 | type clash diagnostic in grammar_current_rule_check. | |
4132 | ||
4133 | * lib/quotearg.c (quotearg_buffer_restyled): Fix off-by-two | |
4134 | bug in trigraph handling. | |
4135 | ||
4136 | * src/output.c (prepare_symbols): When printing token names, | |
4137 | escape "[" as "@<:@" and likewise for "]". | |
4138 | ||
4139 | * src/system.h (errno): Remove declaration, as we are now | |
4140 | assuming C89 or better, and C89 guarantees errno. | |
4141 | ||
762b212b PE |
4142 | 2002-10-30 Paul Eggert <eggert@twinsun.com> |
4143 | ||
4144 | * lib/bitset_stats.c (bitset_stats_read, bitset_stats_write): | |
4145 | Check for close failures. | |
4146 | * src/files.h (xfclose): Return void, not int, since it always | |
4147 | returned zero. | |
4148 | * src/files.c (xfclose): Likewise. Report I/O error if ferror | |
4149 | indicates one. | |
4150 | * src/output.c (output_skeleton): Use xfclose rather than fclose | |
4151 | and ferror. xfclose now checks ferror. | |
4152 | ||
4153 | * data/glr.c (YYLEFTMOST_STATE): Remove. | |
4154 | (yyreportTree): Use a stack-based leftmost state. This avoids | |
4155 | our continuing battles with bogus warnings about initializers. | |
4156 | ||
56100c60 AD |
4157 | 2002-10-30 Akim Demaille <akim@epita.fr> |
4158 | ||
4159 | * src/system.h: Don't use #ifdef/#ifndef on HAVE_ values, only | |
4160 | #if. | |
4161 | ||
51b4a04c PH |
4162 | 2002-10-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
4163 | ||
4164 | * tests/glr-regr1.at: New test for reported regressions. | |
4165 | * tests/testsuite.at: Add glr-regr1.at test. | |
4166 | * tests/Makefile.am: Add glr-regr1.at test. | |
e183b123 | 4167 | |
bf1ebda2 PE |
4168 | 2002-10-24 Paul Eggert <eggert@twinsun.com> |
4169 | ||
5c16c6b1 PE |
4170 | Version 1.75a. |
4171 | ||
bf1ebda2 PE |
4172 | * tests/calc.at (_AT_DATA_CALC_Y): Remove unused strcat declaration. |
4173 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Include stdlib.h, since | |
4174 | we use malloc. Don't assume 'A' through 'Z' are contiguous. | |
4175 | Don't assume strdup exists; POSIX says its an XSI extension. | |
4176 | Check for buffer overflow on input. | |
4177 | ||
b526ee61 AD |
4178 | 2002-10-24 Akim Demaille <akim@epita.fr> |
4179 | ||
4180 | * src/output.c (output_skeleton): Don't disable M4sugar comments | |
4181 | too soon: it results in comments being expanded. | |
4182 | * data/yacc.c, data/glr.c, data/lalr1.cc: Do it right before the | |
4183 | first output. | |
4184 | ||
f1886bb2 AD |
4185 | 2002-10-24 Akim Demaille <akim@epita.fr> |
4186 | ||
4187 | * data/yacc.c (m4_int_type): New. | |
4188 | * data/c.m4 (m4_int_type): Don't use yysigned_char, but `signed | |
4189 | char' as only yacc.c wants K&R portability. | |
4190 | * data/glr.c (yysigned_char): Remove. | |
4191 | * data/lalr1.cc: Rename the trailing b4_name as b4_parser_class_name. | |
4192 | Reported by Quoc Peyrot. | |
4193 | ||
c5576256 PE |
4194 | 2002-10-23 Paul Eggert <eggert@twinsun.com> |
4195 | ||
4196 | * src/main.c (main): With --trace=time, report times even if a | |
4197 | non-fatal error occurs. Formerly, the times were reported in some | |
4198 | such cases but not in others. | |
4199 | * src/reader.c (reader): Just return if a complaint has been issued, | |
4200 | instead of exiting, so that 'main' can report times. | |
4201 | ||
27b0ffea AD |
4202 | 2002-10-22 Akim Demaille <akim@epita.fr> |
4203 | ||
4204 | * src/system.h: Include sys/types. | |
4205 | Reported by Bert Deknuydt. | |
4206 | ||
223a7883 PE |
4207 | 2002-10-23 Paul Eggert <eggert@twinsun.com> |
4208 | ||
4209 | * configure.ac (AC_PROG_LEX): Use instead of AM_PROG_LEX. | |
4210 | Suggested by Art Haas. | |
4211 | ||
4212 | 2002-10-22 Paul Eggert <eggert@twinsun.com> | |
4213 | ||
4214 | * src/complain.c (exit) [! (STDC_HEADERS || _LIBC)]: Remove exit | |
4215 | decl; not needed any more. | |
4216 | * src/main.c (main): Use return to exit, undoing yesterday's change. | |
4217 | The last OS that we could find where this wouldn't work is | |
4218 | SunOS 3.5, and that's too old to worry about now. | |
4219 | ||
4220 | * data/glr.c (struct yyltype): Define members even when not | |
4221 | doing locations. This is more consistent with yacc.c, and it | |
4222 | works around the following bug reports: | |
161a71f3 PE |
4223 | http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00106.html |
4224 | http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00111.html | |
27b0ffea | 4225 | |
223a7883 PE |
4226 | * doc/bison.texinfo: Minor spelling and typographical fixes. Use |
4227 | @acronym consistently. Standardize on "Yacc" instead of "YACC", | |
4228 | "Algol" instead of "ALGOL". Give a bit more history about BNF. | |
4229 | ||
8b76775a AD |
4230 | 2002-10-22 Akim Demaille <akim@epita.fr> |
4231 | ||
4232 | * data/README: New. | |
4233 | ||
6db10d14 PE |
4234 | 2002-10-21 Paul Eggert <eggert@twinsun.com> |
4235 | ||
4236 | Be consistent about 'bool'; the old code used an enum in one | |
4237 | module and an int in another, and this violates the C standard. | |
4238 | * m4/stdbool.m4: New file, from coreutils 4.5.3. | |
4239 | * configure.ac (AC_HEADER_STDBOOL): Add. | |
4240 | * m4/Makefile.am (EXTRA_DIST): Add stdbool.m4. | |
4241 | * src/muscle_tab.c (hash_compare_muscles): (a ? FALSE : TRUE) -> (! a) | |
4242 | * src/symtab.c (hash_compare_symbol_t): Likewise. | |
4243 | * src/system.h (bool, false, true): Use a definition consistent | |
4244 | with ../lib/hash.c. All uses changed. | |
4245 | ||
4246 | * src/complain.c (warning_issued): Renamed from warn_message_count, | |
4247 | so that we needn't worry about integer overflow (!). | |
4248 | Now of type bool. All uses changed. | |
4249 | (complaint_issued): Renamed from complain_message_count; likewise. | |
4250 | ||
4251 | * src/main.c (main): Use exit to exit with failure. | |
27b0ffea | 4252 | |
6db10d14 PE |
4253 | * src/complain.c (fatal_at, fatal): Use EXIT_FAILURE and EXIT_SUCCESS |
4254 | rather than 1 and 0. | |
4255 | * src/main.c (main): Likewise. | |
4256 | * src/getargs.c (getargs): Likewise. | |
4257 | * src/reader.c (reader): Likewise. | |
4258 | ||
4259 | * src/getarg.c (getargs): Remove duplicate code for | |
4260 | "Try `bison --help'". | |
4261 | ||
4262 | * src/files.c (xfopen, xfclose): Use EXIT_FAILURE rather than 2. | |
4263 | What was that "2" for? | |
4264 | ||
4265 | * src/complain.h (fatal, fatal_at): Add __attribute__((__noreturn__)). | |
4266 | * src/getargs.c (usage): Likewise. | |
4267 | ||
4268 | * src/getargs.c (getargs): When there are too few operands, report | |
4269 | the last one. When there are too many, report the first extra | |
4270 | one. This is how diffutils does it. | |
4271 | ||
92a060fd PE |
4272 | 2002-10-20 Paul Eggert <eggert@twinsun.com> |
4273 | ||
4274 | Remove K&R vestiges. | |
4275 | * configure.ac (AC_C_CONST, AM_C_PROTOTYPES): Remove. | |
4276 | * src/complain.c (VA_START): Remove. Assume prototypes. | |
4277 | (vfprintf) [! (HAVE_VPRINTF || defined vfprintf)]: New macro. | |
4278 | (private_strerror, warn_at, warn, complain_at, complain, fatal_at, | |
4279 | fatal): Assume prototypes. | |
4280 | * src/complain.h: Assume prototypes. | |
4281 | * src/system.h (PARAMS): Remove. | |
4282 | Include <limits.h> unconditionally, since it's guaranteeed even | |
4283 | for a freestanding C89 compiler. | |
4284 | (SHRT_MIN, SHRT_MAX): Remove, since C89 guarantees them. | |
4285 | * src/vmsgetargs.c (getargs, cli_present, cli_get_value): Prototype. | |
8b76775a | 4286 | |
e7cb57c0 AD |
4287 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4288 | ||
4289 | * src/muscle_tab.c (muscle_grow): Remove trailing debugging code. | |
4290 | * data/glr.c (YY_USER_FORMALS, YY_USER_ARGS): New. | |
4291 | (yyuserAction, yydoAction, yyglrReduce, yyresolveValue) | |
4292 | (yyresolveStates, yyresolveAction, yyresolveStack) | |
4293 | (yyprocessOneStack): Use them. | |
4294 | (yy_reduce_print): New. | |
4295 | * tests/calc.at (_AT_DATA_CALC_Y): Exercise %parse-param. | |
4296 | ||
0245f82d AD |
4297 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4298 | ||
4299 | * data/c.m4 (b4_c_ansi_args): Recognize functions with no | |
4300 | arguments and output `void'. | |
4301 | (b4_c_function): Rename as... | |
4302 | (b4_c_function_def): this. | |
4303 | (b4_c_function_decl, b4_c_ansi_function_def) | |
4304 | (b4_c_ansi_function_decl): New. | |
4305 | Change the interpretation of the arguments: before `int, foo', now | |
4306 | `int foo, foo'. | |
4307 | * data/yacc.c (yyparse): Prototype and define thanks to these. | |
4308 | Adjust b4_c_function_def uses. | |
4309 | * data/glr.c (yyparse): Likewise, but ANSI only. | |
4310 | ||
39912f52 AD |
4311 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4312 | ||
4313 | * src/output.c (prepare): Move the definition of `tokens_number', | |
4314 | `nterms_number', `undef_token_number', `user_token_number_max' | |
4315 | to... | |
4316 | (prepare_tokens): Here. | |
4317 | (prepare_tokens): Rename as... | |
4318 | (prepare_symbols): this. | |
4319 | (prepare): Move the definition of `rules_number' to... | |
4320 | (prepare_rules): here. | |
4321 | (prepare): Move the definition of `last', `final_state_number', | |
4322 | `states_number' to... | |
4323 | (prepare_states): here. | |
4324 | * data/yacc.c, data/lalr1.cc, data/glr.c: Normalize `>' into `<'. | |
4325 | ||
20c1e2ad AD |
4326 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4327 | ||
4328 | * src/tables.h, src/tables.c, src/output.c: Comment changes. | |
4329 | ||
21964f43 AD |
4330 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4331 | ||
4332 | * data/yacc.c, data/yacc.c (b4_location_if, b4_pure_if): Move to... | |
4333 | * data/c.m4: here. | |
4334 | ||
66d30cd4 AD |
4335 | 2002-10-20 Akim Demaille <akim@epita.fr> |
4336 | ||
4337 | * src/output.c (prepare): Use MUSCLE_INSERT_STRING. | |
4338 | * src/muscle_tab.c (muscle_pair_list_grow): Rename `val as | |
4339 | `pair'. | |
4340 | (muscle_init): Move the `b4_ltype', `b4_maxdepth', `b4_initdepth', | |
4341 | `name' to... | |
4342 | * data/glr.c, data/lalr1.cc, data/yacc.c (b4_location_type) | |
4343 | (b4_stack_depth_init, b4_stack_depth_max, b4_parser_class_name): | |
4344 | These. | |
4345 | ||
95f2c9fe PE |
4346 | 2002-10-19 Paul Eggert <eggert@twinsun.com> |
4347 | ||
4348 | Do not create a temporary file, as that involves security and | |
4349 | cleanup headaches. Instead, use a pair of pipes. | |
4350 | Derived from a suggestion by Florian Krohm. | |
4351 | * lib/subpipe.c, lib/subpipe.h, m4/subpipe.m4: New files. | |
4352 | * lib/mkstemp.c, lib/readpipe.c, lib/tempname.c, m4/mkstemp.m4: Remove. | |
4353 | * configure.ac (UTILS_FUNC_MKSTEMP, jm_PREREQ_TEMPNAME): Remove. | |
4354 | (BISON_PREREQ_SUBPIPE): Add. | |
4355 | * lib/Makefile.am (libbison_a_SOURCES): Remove readpipe.c. | |
4356 | Add subpipe.h, subpipe.c. | |
4357 | * m4/Makefile.am (EXTRA_DIST): Remove mkstemp.m4. Add subpipe.m4. | |
4358 | * po/POTFILES.in: Add lib/subpipe.c. | |
4359 | * src/output.c: Include "subpipe.h". | |
4360 | (m4_invoke): Remove decl. | |
4361 | (scan_skel): New decl. | |
4362 | (output_skeleton): Use pipe rather than temporary file for m4 input. | |
4363 | Check that m4sugar.m4 is readable, to avoid deadlock. | |
4364 | Check for pipe I/O error. | |
4365 | * src/scan-skel.l (readpipe): Remove decl. | |
4366 | (scan_skel): New function, to be used in place of m4_invoke. | |
4367 | Read from stream rather than file. | |
66d30cd4 | 4368 | |
95f2c9fe PE |
4369 | * lib/timevar.c (TICKS_TO_MSEC, CLOCKS_TO_MSEC): Do not cast to |
4370 | float, as this generates a warning on Solaris 8 + GCC 3.2 with | |
4371 | --enable-gcc-warnings. Instead, divide into 1.0 rather than 1; | |
4372 | this generates a more-accurate value anyway. | |
4373 | ||
4374 | * lib/timevar.c (timervar_accumulate): Rename locals to | |
4375 | avoid confusion with similarly-named more-global. | |
4376 | * src/muscle_tab.c (muscle_pair_list_grow): Likewise. | |
4377 | ||
4378 | * src/output.c (prepare): Use xstrdup to convert char const * | |
4379 | to char *, to avoid GCC warning. | |
4380 | ||
c19988b7 AD |
4381 | 2002-10-19 Akim Demaille <akim@epita.fr> |
4382 | ||
4383 | * tests/calc.at (_AT_DATA_CALC_Y): Define VAL, LOC, LEX_FORMALS, | |
4384 | LEX_PRE_FORMALS, LEX_ARGS, LEX_PRE_ARGS, USE_LEX_ARGS. | |
4385 | Use them to have `calc.y' ready for %pure-parser. | |
4386 | * data/yacc.c (YYLEX): Pass a yylex return type to | |
4387 | b4_c_function_call. | |
4388 | ||
ae7453f2 AD |
4389 | 2002-10-19 Akim Demaille <akim@epita.fr> |
4390 | ||
4391 | Prototype support of %lex-param and %parse-param. | |
4392 | ||
4393 | * src/parse-gram.y: Add the definition of the %lex-param and | |
4394 | %parse-param tokens, plus their rules. | |
4395 | Drop the `_' version of %glr-parser. | |
4396 | Add the "," token. | |
4397 | * src/scan-gram.l (INITIAL): Scan them. | |
4398 | * src/muscle_tab.c: Comment changes. | |
4399 | (muscle_insert, muscle_find): Rename `pair' as `probe'. | |
4400 | * src/muscle_tab.h (MUSCLE_INSERT_PREFIX): Remove unused. | |
4401 | (muscle_entry_s): The `value' member is no longer const. | |
4402 | Adjust all dependencies. | |
4403 | * src/muscle_tab.c (muscle_init): Adjust: use | |
4404 | MUSCLE_INSERT_STRING. | |
4405 | Initialize the obstack earlier. | |
4406 | * src/muscle_tab.h, src/muscle_tab.c (muscle_grow) | |
4407 | (muscle_pair_list_grow): New. | |
4408 | * data/c.m4 (b4_c_function_call, b4_c_args): New. | |
4409 | * data/yacc.c (YYLEX): Use b4_c_function_call to honor %lex-param. | |
4410 | * tests/calc.at: Use %locations, not --locations. | |
4411 | (AT_CHECK_CALC_GLR): Use %glr-parser, not %glr_parser. | |
4412 | ||
0e575721 AD |
4413 | 2002-10-19 Akim Demaille <akim@epita.fr> |
4414 | ||
4415 | * src/getargs.c (usage): Take status as argument and exit | |
4416 | accordingly. | |
4417 | Report the traditional `Try ... --help' message when status != 0. | |
4418 | (usage, version): Don't take a FILE * as arg, it is pointless. | |
4419 | (getargs): When there is an incorrect number of arguments, make it | |
4420 | an error, and report it GNUlically thanks to `usage ()'. | |
4421 | ||
724ce7f5 PE |
4422 | 2002-10-18 Paul Eggert <eggert@twinsun.com> |
4423 | ||
3a781eb2 PE |
4424 | * data/glr.c (yyreportParseError): Don't assume that sprintf |
4425 | yields the length of the printed string, as this is not true | |
4426 | on SunOS 4.1.4. Reported by Peter Klein. | |
4427 | ||
724ce7f5 PE |
4428 | * tests/calc.at (_AT_DATA_CALC_Y): #undef memcmp and realloc. |
4429 | * tests/conflicts.at (%nonassoc and eof): Likewise. | |
4430 | Fixes SunOS 4.1.4 test failure reported by Peter Klein. | |
4431 | ||
473d0a75 AD |
4432 | 2002-10-17 Akim Demaille <akim@epita.fr> |
4433 | ||
4434 | * src/getargs.h (trace_e): Add trace_scan, and trace_parse. | |
4435 | * src/getargs.c (trace_types, trace_args): Adjust. | |
4436 | * src/reader.c (grammar_current_rule_prec_set) | |
4437 | (grammar_current_rule_dprec_set, grammar_current_rule_merge_set): | |
4438 | Standardize error messages. | |
4439 | And s/@prec/%prec/! | |
4440 | (reader): Use trace_flag to enable scanner/parser debugging, | |
4441 | instead of an adhoc scheme. | |
4442 | * src/scan-gram.l: Remove trailing debugging code. | |
4443 | ||
e76d2469 PE |
4444 | 2002-10-16 Paul Eggert <eggert@twinsun.com> |
4445 | ||
93e2236a PE |
4446 | * src/muscle_tab.h (MUSCLE_TAB_H_): Was misspelled as |
4447 | MUSCLE_TAB_H. | |
4448 | ||
e76d2469 PE |
4449 | * NEWS: Officially drop support for building Bison with K&R C, |
4450 | since it didn't work anyway and it's not worth worrying about. | |
4451 | * Makefile.maint (wget_files): Remove ansi2knr.c. | |
4452 | (ansi2knr.c-url_prefix): Remove. | |
4453 | * lib/.cvsignore: Remove ansi2knr, ansi2knr.*. | |
4454 | * lib/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
4455 | * src/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
4456 | ||
5bd1c419 PE |
4457 | 2002-10-15 Paul Eggert <eggert@twinsun.com> |
4458 | ||
4459 | Stop using the "enum_" trick for K&R-style function definitions; | |
4460 | it confused me, and I was the author! Instead, assume that people | |
4461 | who want to use K&R C compilers (when using these modules in GCC, | |
4462 | perhaps?) will run ansi2knr. | |
4463 | ||
4464 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): Remove. | |
4465 | All uses of "enum_" changed to "enum ". | |
4466 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
4467 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
e76d2469 | 4468 | |
5bd1c419 PE |
4469 | * lib/abitset.c (abitset_and, abitset_and_cmp, abitset_and_or, |
4470 | abitset_and_or_cmp, abitset_andn, abitset_andn_cmp, | |
4471 | abitset_andn_or, abitset_andn_or_cmp, abitset_bytes, abitset_copy, | |
4472 | abitset_copy1, abitset_disjoint_p, abitset_empty_p, | |
4473 | abitset_equal_p, abitset_init, abitset_list, abitset_list_reverse, | |
4474 | abitset_not, abitset_ones, abitset_or, abitset_or_and, | |
4475 | abitset_or_and_cmp, abitset_or_cmp, abitset_reset, abitset_set, | |
4476 | abitset_size, abitset_small_list, abitset_subset_p, abitset_test, | |
4477 | abitset_unused_clear, abitset_xor, abitset_xor_cmp, abitset_zero): | |
4478 | Use function prototypes; this removes the need for declaring | |
4479 | static functions simply to provide their prototypes. | |
4480 | * lib/bitset.c (bitset_alloc, bitset_and_or_, bitset_and_or_cmp_, | |
4481 | bitset_andn_or_, bitset_andn_or_cmp_, bitset_bytes, bitset_copy_, | |
4482 | bitset_count_, bitset_create, bitset_dump, bitset_first, | |
4483 | bitset_free, bitset_init, bitset_last, bitset_next, | |
4484 | bitset_obstack_alloc, bitset_obstack_free, bitset_only_set_p, | |
4485 | bitset_op4_cmp, bitset_or_and_, bitset_or_and_cmp_, bitset_prev, | |
4486 | bitset_print, bitset_release_memory, bitset_toggle_, | |
4487 | bitset_type_choose, bitset_type_get, bitset_type_name_get, | |
4488 | debug_bitset): Likewise. | |
4489 | * lib/bitset.h (bitset_set, bitset_reset, bitset_test): Likewise. | |
4490 | * lib/bitset_stats.c (bitset_log_histogram_print, | |
4491 | bitset_percent_histogram_print, bitset_stats_and, | |
4492 | bitset_stats_and_cmp, bitset_stats_and_or, | |
4493 | bitset_stats_and_or_cmp, bitset_stats_andn, bitset_stats_andn_cmp, | |
4494 | bitset_stats_andn_or, bitset_stats_andn_or_cmp, bitset_stats_copy, | |
4495 | bitset_stats_count, bitset_stats_disable, bitset_stats_disjoint_p, | |
4496 | bitset_stats_dump, bitset_stats_empty_p, bitset_stats_enable, | |
4497 | bitset_stats_equal_p, bitset_stats_free, bitset_stats_init, | |
4498 | bitset_stats_list, bitset_stats_list_reverse, bitset_stats_not, | |
4499 | bitset_stats_ones, bitset_stats_or, bitset_stats_or_and, | |
4500 | bitset_stats_or_and_cmp, bitset_stats_or_cmp, bitset_stats_print, | |
4501 | bitset_stats_print_1, bitset_stats_read, bitset_stats_reset, | |
4502 | bitset_stats_set, bitset_stats_size, bitset_stats_subset_p, | |
4503 | bitset_stats_test, bitset_stats_toggle, bitset_stats_type_get, | |
4504 | bitset_stats_write, bitset_stats_xor, bitset_stats_xor_cmp, | |
4505 | bitset_stats_zero): Likewise. | |
4506 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
4507 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
4508 | bitsetv_dump, debug_bitsetv): Likewise. | |
4509 | * lib/ebitset.c (ebitset_and, ebitset_and_cmp, ebitset_andn, | |
4510 | ebitset_andn_cmp, ebitset_bytes, ebitset_copy, ebitset_copy_, | |
4511 | ebitset_copy_cmp, ebitset_disjoint_p, ebitset_elt_add, | |
4512 | ebitset_elt_alloc, ebitset_elt_calloc, ebitset_elt_find, | |
4513 | ebitset_elt_free, ebitset_elt_last, ebitset_elt_remove, | |
4514 | ebitset_elt_zero_p, ebitset_elts_grow, ebitset_empty_p, | |
4515 | ebitset_equal_p, ebitset_free, ebitset_init, ebitset_list, | |
4516 | ebitset_list_reverse, ebitset_not, ebitset_ones, ebitset_op3_cmp, | |
4517 | ebitset_or, ebitset_or_cmp, ebitset_release_memory, ebitset_reset, | |
4518 | ebitset_set, ebitset_size, ebitset_subset_p, ebitset_test, | |
4519 | ebitset_weed, ebitset_xor, ebitset_xor_cmp, ebitset_zero): | |
4520 | Likewise. | |
4521 | * lib/lbitset.c (debug_lbitset, lbitset_and, lbitset_and_cmp, | |
4522 | lbitset_andn, lbitset_andn_cmp, lbitset_bytes, lbitset_copy, | |
4523 | lbitset_copy_cmp, lbitset_disjoint_p, lbitset_elt_alloc, | |
4524 | lbitset_elt_calloc, lbitset_elt_find, lbitset_elt_free, | |
4525 | lbitset_elt_link, lbitset_elt_unlink, lbitset_elt_zero_p, | |
4526 | lbitset_empty_p, lbitset_equal_p, lbitset_free, lbitset_init, | |
4527 | lbitset_list, lbitset_list_reverse, lbitset_not, lbitset_ones, | |
4528 | lbitset_op3_cmp, lbitset_or, lbitset_or_cmp, lbitset_prune, | |
4529 | lbitset_release_memory, lbitset_reset, lbitset_set, lbitset_size, | |
4530 | lbitset_subset_p, lbitset_test, lbitset_weed, lbitset_xor, | |
4531 | lbitset_xor_cmp, lbitset_zero): Likewise. | |
e76d2469 | 4532 | |
ae26e1f0 AD |
4533 | 2002-10-14 Akim Demaille <akim@epita.fr> |
4534 | ||
4535 | Version 1.75. | |
4536 | ||
d43baf71 AD |
4537 | 2002-10-14 Akim Demaille <akim@epita.fr> |
4538 | ||
4539 | * tests/Makefile.am (maintainer-check-posix): New. | |
4540 | ||
7ebc83e3 AD |
4541 | 2002-10-14 Akim Demaille <akim@epita.fr> |
4542 | ||
4543 | * data/glr.c [YYDEBUG] (YYLEFTMOST_STATE): Initialize the yyloc | |
4544 | member. | |
4545 | ||
05846dae AD |
4546 | 2002-10-14 Akim Demaille <akim@epita.fr> |
4547 | ||
4548 | * src/tables.c (table_ninf_remap): base -> tab. | |
4549 | Reported by Matt Rosing. | |
4550 | ||
1318e37d PE |
4551 | 2002-10-14 Paul Eggert <eggert@twinsun.com> |
4552 | ||
447fbb17 PE |
4553 | * tests/action.at, tests/calc.at, tests/conflicts.at, |
4554 | tests/cxx-type.at, tests/headers.at, tests/input.at, | |
4555 | tests/regression.at, tests/synclines.at, tests/torture.at: | |
4556 | Say "bison -o foo.c foo.y", not "bison foo.y -o foo.c", | |
4557 | so that the tests still work even if POSIXLY_CORRECT is set. | |
4558 | * doc/bison.texinfo (Rpcalc Compile, Invocation): Likewise. | |
05846dae | 4559 | |
1318e37d PE |
4560 | * data/c.m4 (b4_int_type): Use yysigned_char instead of signed char, |
4561 | for portability to K&R hosts. Fix typo: signed char is guaranteed | |
4562 | only to 127, not to 128. | |
4563 | * data/glr.c (yysigned_char): New type. | |
4564 | * data/yacc.c (yysigned_char): Likewise. | |
4565 | * tests/regression.at (Web2c Actions): signed char -> yysigned_char. | |
4566 | ||
cc0f0794 PE |
4567 | 2002-10-13 Paul Eggert <eggert@twinsun.com> |
4568 | ||
5038f418 PE |
4569 | * data/yacc.c (yyparse): Rewrite to avoid "comparison is always |
4570 | true due to limited range of data type" warning from GCC. | |
4571 | ||
cc0f0794 PE |
4572 | * data/c.m4 (b4_token_defines): Protect against double-inclusion |
4573 | by wrapping enum yytokentype's definition inside #ifndef | |
4574 | YYTOKENTYPE. This undoes a bug I introduced on 2002-10-12. | |
4575 | ||
6fed0802 AD |
4576 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4577 | ||
4578 | * data/glr.c (yyglrShiftDefer, yyaddDeferredAction, yydoAction): | |
4579 | Un yy- yyrhs to avoid the name clash with the global YYRHS. | |
4580 | ||
32f0598d AD |
4581 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4582 | ||
4583 | * Makefile.maint: Update from Autoconf 2.54. | |
4584 | * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Remove, shipped with 2.54. | |
4585 | ||
7ea9a33f AD |
4586 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4587 | ||
4588 | * src/print.c (print_state): Separate the list of solved conflicts | |
4589 | from the other items. | |
4590 | * tests/conflicts.at (Resolved SR Conflicts): Adjust. | |
4591 | ||
ea99527d AD |
4592 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4593 | ||
4594 | Let nondeterministic skeletons be usable with deterministic | |
4595 | tables. | |
4596 | ||
4597 | With the patch, GAWK compiled by GCC without -O2 passes its test | |
4598 | suite using a GLR parser driven by LALR tables. It fails with -O2 | |
4599 | because `struct stat' gives two different answers on my machine: | |
4600 | 88 (definition of an auto var) and later 96 (memset on this var). | |
4601 | Hence the stack is badly corrumpted. The headers inclusion is to | |
4602 | blame: if I move the awk.h inclusion before GLR's system header | |
4603 | inclusion, the two struct stat have the same size. | |
4604 | ||
4605 | * src/tables.c (pack_table): Always create conflict_table. | |
4606 | (token_actions): Always create conflict_list. | |
4607 | * data/glr.c (YYFLAG): Remove, unused. | |
4608 | ||
f377f69f AD |
4609 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4610 | ||
4611 | * configure.ac (AC_GNU_SOURCE): Use it instead of hand written code. | |
4612 | (O0FLAGS): New. | |
4613 | (VALGRIND, GXX): New. | |
4614 | * tests/atlocal.in (CFLAGS): Use O0FLAGS. | |
4615 | * tests/bison.in: Run $PREBISON a pre-command. | |
4616 | * tests/Makefile.am (maintainer-check, maintainer-check-valgrind) | |
4617 | (maintainer-check-g++): New. | |
4618 | * Makefile.am (maintainer-check): New. | |
4619 | ||
2a1fe6ed AD |
4620 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4621 | ||
4622 | * data/glr.c: Formatting changes. | |
4623 | Tweak some trace messages to match yacc.c's. | |
4624 | ||
f50adbbd AD |
4625 | 2002-10-13 Akim Demaille <akim@epita.fr> |
4626 | ||
4627 | GLR parsers sometimes raise parse errors instead of performing the | |
4628 | default reduction. | |
4629 | Reported by Charles-Henry de Boysson. | |
4630 | ||
4631 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Don't | |
4632 | check the length of the traces when %glr. | |
4633 | (_AT_CHECK_CALC_ERROR): Also skip `^Stack' lines, coming from | |
4634 | GLR's traces. | |
4635 | (AT_CHECK_CALC_LALR, AT_CHECK_CALC_GLR): New. | |
4636 | Test GLR parsers. | |
4637 | * data/glr.c (YYLEFTMOST_STATE): Fix its value. | |
4638 | (yyltype): Remove the yy prefix from the member names. | |
4639 | (yytable): Complete its comment. | |
4640 | (yygetLRActions): Map error action number from YYTABLE from | |
4641 | YYTABLE_NINF to 0. | |
4642 | (yyisErrorAction): No longer compare YYACTION to YYPACT_NINF | |
4643 | (which was a bug: it should have been YYTABEL_NINF, and yet it was | |
4644 | not satisfying as we could compare an YYACTION computed from | |
4645 | YYDEFACT to YYTABLE_NINF although they are unrelated): 0 is the | |
4646 | only value for error actions. | |
4647 | (yyreportParseError): In verbose parse error messages, don't issue | |
4648 | `error' in the list of expected tokens. | |
4649 | * data/yacc.c (yyparse) <yybackup>: Rewrite the decoding of the | |
4650 | next action to perform to match glr.c's decoding. | |
4651 | (yytable): Complete its comment. | |
4652 | ||
bcbad5b9 PE |
4653 | 2002-10-13 Paul Eggert <eggert@twinsun.com> |
4654 | ||
4655 | Fix problem reported by Henrik Grubbstroem in | |
161a71f3 | 4656 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00098.html>: |
bcbad5b9 PE |
4657 | "nonterm: { $$ = 123; } { $$ = $1; };" was wrongly rejected, |
4658 | because the Bison parser reads the second action before reducing | |
4659 | the first one. | |
4660 | * src/scan-gram.l (rule_length): New static var. | |
4661 | Use it to keep track of the rule length in the scanner, since | |
4662 | we can't expect the parser to be in lock-step sync with the scanner. | |
4663 | (handle_action_dollar, handle_action_at): Use this var. | |
4664 | * tests/actions.at (Exotic Dollars): Test for the problem. | |
05846dae | 4665 | |
14904b89 PE |
4666 | 2002-10-12 Paul Eggert <eggert@twinsun.com> |
4667 | ||
1fe611e5 PE |
4668 | * lib/timevar.c [! IN_GCC && HAVE_SYS_TIME_H]: Include <sys/time.h>. |
4669 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): Check for <sys/time.h>. | |
4670 | Include <sys/time.h> when checking for clock_t and struct tms. | |
4671 | Use same include order as source. | |
4672 | This is for the SunOS 4.1.4 porting bug reported by Peter Klein in | |
161a71f3 | 4673 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00016.html>. |
05846dae | 4674 | |
1fe611e5 PE |
4675 | * lib/timevar.c: Update copyright date and clarify comments. |
4676 | (get_time) [IN_GCC]: Keep the GCC version for reference. | |
05846dae | 4677 | |
1fe611e5 PE |
4678 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: Import |
4679 | GCC version as of today, then merge Bison's changes. | |
4680 | Change "GCC" to "Bison" in copyright notice. timevar.def's | |
4681 | author is Akim, so change that too. | |
4682 | ||
98194095 PE |
4683 | * src/reader.c (grammar_current_rule_check): |
4684 | Don't worry about the default action if $$ is untyped. | |
4685 | Prevents bogus warnings reported by Jim Gifford in | |
161a71f3 | 4686 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00015.html>. |
98194095 | 4687 | |
14904b89 PE |
4688 | * data/c.m4 (b4_token_enum): Do not define YYTOKENTYPE. |
4689 | * data/glr.c, data/lalr1.cc, data/yacc.c: | |
4690 | Output token definitions before the first part of user declarations. | |
4691 | Fixes compatibility problem reported by Jim Gifford for kbd in | |
161a71f3 | 4692 | <http://lists.gnu.org/archive/html/bug-bison/2002-10/msg00014.html>. |
14904b89 | 4693 | |
ff6dca18 PE |
4694 | 2002-10-11 Paul Eggert <eggert@twinsun.com> |
4695 | ||
4696 | * data/yacc.c (yyreport_parse_error): Remove, putting its body into... | |
4697 | (yyparse): here. This undoes some of the 2002-07-25 change. | |
4698 | Compatibility problem reported by Ralf S. Engelschall with | |
4699 | OSSP cfg <http://www.ossp.org/pkg/lib/cfg/>. | |
4700 | ||
eb714592 AD |
4701 | 2002-10-11 Akim Demaille <akim@epita.fr> |
4702 | ||
4703 | * tests/regression.at Characters Escapes): New. | |
4704 | * src/scan-gram.l (SC_ESCAPED_CHARACTER): Accept \' in strings and | |
4705 | characters. | |
4706 | Reported by Jan Nieuwenhuizen. | |
4707 | ||
b7195100 AD |
4708 | 2002-10-11 Akim Demaille <akim@epita.fr> |
4709 | ||
4710 | * po/id.po: New. | |
4711 | ||
f28a0f2d PE |
4712 | 2002-10-10 Paul Eggert <eggert@twinsun.com> |
4713 | ||
4714 | Portability fixes for bitsets; this also avoids several GCC | |
4715 | warnings. | |
4716 | ||
4717 | * lib/abitset.c: Include <stddef.h>, for offsetof. | |
4718 | * lib/lbitset.c: Likewise. | |
4719 | ||
4720 | * lib/abitset.c (abitset_bytes): Return a size that is aligned | |
4721 | properly for vectors of objects. Do not assume that adding a | |
4722 | header size to a multiple of a word size yields a value that is | |
4723 | properly aligned for the whole union. | |
4724 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
4725 | ||
4726 | * lib/bitset_stats.c (bitset_stats_bytes): Adjust to new, | |
4727 | unique names for structures. | |
4728 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
4729 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
4730 | ||
4731 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_empty_p, | |
4732 | abitset_copy1, abitset_not, abitset_equal_p, abitset_subset_p, | |
4733 | abitset_disjoint_p, abitset_and, abitset_and_cmp, abitset_andn, | |
4734 | abitset_andn_cmp, abitset_or, abitset_or_cmp, abitset_xor, | |
4735 | abitset_xor_cmp, abitset_and_or, abitset_and_or_cmp, | |
4736 | abitset_andn_or, abitset_andn_or_cmp, abitset_or_and, | |
4737 | abitset_or_and_cmp, abitset_copy): Supply prototype decls, | |
4738 | to improve the type-checking that GCC can do. | |
4739 | * lib/bitset.c (bitset_op4_cmp): Likewise. | |
4740 | * lib/bitset_stats.c (bitset_stats_count, | |
4741 | bitset_stats_empty_p, bitset_stats_ones, bitset_stats_zero, | |
4742 | bitset_stats_copy, bitset_stats_disjoint_p, | |
4743 | bitset_stats_equal_p, bitset_stats_not, bitset_stats_subset_p, | |
4744 | bitset_stats_and, bitset_stats_and_cmp, bitset_stats_andn, | |
4745 | bitset_stats_andn_cmp, bitset_stats_or, bitset_stats_or_cmp, | |
4746 | bitset_stats_xor, bitset_stats_xor_cmp, bitset_stats_and_or, | |
4747 | bitset_stats_and_or_cmp, bitset_stats_andn_or, | |
4748 | bitset_stats_andn_or_cmp, bitset_stats_or_and, | |
4749 | bitset_stats_or_and_cmp): Likewise. | |
4750 | * lib/lbitset.c (lbitset_and, lbitset_and_cmp, lbitset_andn, | |
4751 | lbitset_andn_cmp, lbitset_or, lbitset_or_cmp, lbitset_xor, | |
4752 | lbitset_xor_cmp, lbitset_empty_p, lbitset_ones, lbitset_not, | |
4753 | lbitset_subset_p, lbitset_disjoint_p, debug_lbitset): Likewise. | |
4754 | ||
4755 | * lib/abitset.h: Include bitset.h, not bbitset.h. | |
4756 | * lib/ebitset.h: Likewise. | |
4757 | * lib/lbitset.h: Likewise. | |
4758 | ||
4759 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): New types. | |
4760 | All instances of parameters of type enum bitset_opts are now of | |
4761 | type enum_bitset_opts, to conform to the C Standard, and similarly | |
4762 | for enum_bitset_type. | |
4763 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
4764 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
4765 | ||
4766 | Do not use "struct bitset_struct" to mean different things in | |
4767 | different modules. Not only is this confusing, it violates | |
4768 | the C Standard, which requires that structure types in different | |
4769 | modules must be compatible if one is to be passed to the other. | |
4770 | * lib/bbitset.h (bitset): Now points to a union, not to a struct. | |
4771 | All instances of "struct bitset_struct *" replaced with "bitset". | |
4772 | * lib/bitset.h (struct bitset_struct): Remove, replacing with.... | |
4773 | (union bitset_union, struct abitset_struct, struct ebitset_struct, | |
4774 | struct lbitset_struct, struct bitset_stats_struct): New types. | |
4775 | All uses of struct bitset_struct changed to union bitset_union, | |
4776 | etc. | |
4777 | * lib/abitset.c (struct abitset_struct, abitset, | |
4778 | struct bitset_struct): Remove. | |
4779 | * lib/bitset_stats.c (struct bitset_stats_struct, bitset_stats, | |
4780 | struct bitset_struct): Remove. | |
4781 | * lib/ebitset.c (struct ebitset_struct, ebitset, struct | |
4782 | bitset_struct): Remove. | |
4783 | * lib/lbitset.c (struct lbitset_struct, lbitset, bitset_struct): | |
4784 | Likewise. | |
4785 | ||
4786 | Do not call a function of type T using a call that assumes the | |
4787 | function is of a different type U. Standard C requires that a | |
4788 | function must be called with a type that is compatible with its | |
4789 | definition. | |
4790 | * lib/bbitset.h (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
4791 | New decls. | |
4792 | * lib/bitset.c (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
4793 | New functions. | |
4794 | * lib/ebitset.c (PFV): Remove. | |
4795 | * lib/lbitset.c (PFV): Likewise. | |
4796 | * lib/ebitset.c (ebitset_and, ebitset_andn, ebitset_or, | |
4797 | ebitset_xor, ebitset_copy, ebitset_ones, ebitset_empty_p): New | |
4798 | decls. | |
4799 | (ebitset_and, ebitset_andn, ebitset_or, ebitset_xor): New functions. | |
4800 | (ebitset_vtable): Use them. | |
4801 | * lib/lbitset.c (lbitset_and, lbitset_andn, lbitset_or, | |
4802 | lbitset_xor): New functions. | |
4803 | (lbitset_vtable): Use them. | |
4804 | ||
4805 | * lib/bitset.h (bitset_next, bitset_prev, bitset_only_set_p): | |
4806 | Declare. | |
4807 | ||
4808 | * lib/bitsetv.c (bitsetv_alloc): Add a cast to (void *) to avoid a | |
4809 | GCC warning. | |
4810 | * lib/lbitset.c (LBITSET_CURRENT1): Likewise. | |
4811 | Use offsetof, for simplicity. | |
4812 | ||
6fbe4984 PE |
4813 | 2002-10-06 Paul Eggert <eggert@twinsun.com> |
4814 | ||
4815 | * lib/bitset.h (bitset_reset): Do not assume that bitset_word is | |
4816 | the same width as int. This reapplies a hunk of the 2002-08-12 patch | |
161a71f3 | 4817 | <http://lists.gnu.org/archive/html/bison-patches/2002-08/msg00007.html>, |
6fbe4984 PE |
4818 | which was inadvertently undone by the 2002-09-30 patch. |
4819 | * lib/lbitset.c (debug_lbitset): Do not assume that bitset_word is | |
4820 | the same width as int. | |
4821 | ||
420f93c8 PE |
4822 | 2002-10-04 Paul Eggert <eggert@twinsun.com> |
4823 | ||
4824 | Version 1.50. | |
4825 | ||
4826 | * configure.ac (AC_INIT), NEWS: Increment version number. | |
4827 | ||
4828 | * doc/bison.texinfo: Minor spelling, grammar, and white space | |
4829 | fixes. | |
4830 | (Symbols): Mention that any negative value returned from yylex | |
4831 | signifies end-of-input. Warn about negative chars. Mention | |
4832 | the portable Standard C character set. | |
4833 | ||
4834 | The GNU coding standard says CFLAGS and YFLAGS are reserved | |
4835 | for the installer to set. | |
4836 | * lib/Makefile.am (AM_CFLAGS): Renamed from CFLAGS. | |
4837 | * src/Makefile.am (AM_CFLAGS): Likewise. | |
4838 | (AM_YFLAGS): Renamed from YFLAGS. | |
4839 | ||
4840 | Fix some MAX and MIN problems. | |
4841 | * src/gram.h (ITEM_NUMBER_MIN): MIN_MAX -> INT_MIN. | |
4842 | * src/lalr.h (GOTO_NUMBER_MAX): INT_MAX -> SHRT_MAX. | |
4843 | * src/symtab.h (SYMBOL_NUMBER_MAX): New macro. | |
4844 | * src/reader.c (reader): Use it. | |
4845 | ||
4846 | * tests/regression.at (Braces parsing): Use grep, not fgrep, as | |
4847 | POSIX 1003.1-2001 has removed fgrep. | |
4848 | ||
4849 | 2002-10-04 Michael Hayes <m.hayes@elec.canterbury.ac.nz> | |
4850 | ||
4851 | * lib/bbitset.h (BITSET_WINDEX_MAX): Redefine so that it cannot be | |
4852 | interpreted as signed. | |
4853 | * lib/ebitset.c (ebitset_list): Fix bug. | |
4854 | ||
ff68026d PE |
4855 | 2002-10-01 Paul Eggert <eggert@twinsun.com> |
4856 | ||
4857 | More fixes for 64-bit hosts and large bitsets. | |
4858 | ||
4859 | * lib/abitset.c (struct abitset_struct.n_bits, abitset_small_list, | |
4860 | abitset_size, abitset_list, abitset_list_reverse, abitset_list): | |
4861 | Use bitset_bindex, not int or unsigned int or size_t, to count bits. | |
4862 | * lib/bbitset.h (struct bitset_vtable.size, struct bitset_vtable.count, | |
4863 | struct bitset_vtable.list, struct bitset_vtable.list_reverse, | |
4864 | bitset_count_, bitset_next, bitset_prev, bitset_first, bitset_last, | |
4865 | bitset_count_): Likewise. | |
4866 | * lib/bitset.h (bitset_iterator.num, bitset_iterator.i, | |
4867 | bitset_first, bitset_last): Likewise. | |
4868 | * lib/bitset_stats.c (bitset_stats_size, bitset_stats_list, | |
4869 | bitset_stats_list_reverse, bitset_stats_size, | |
4870 | bitset_stats_count, bitset_stats_list, bitset_stat_list_reverse): | |
4871 | Likewise. | |
4872 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
4873 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
4874 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
4875 | bitsetv_reflexive_transitive_closure): Likewise. | |
4876 | * lib/bitsetv.h (bitsetv_alloc, bitsetv_create): Likewise. | |
4877 | * lib/ebitset.c (ebitset_size, ebitset_list, ebitset_list_reverse): | |
4878 | Likewise. | |
4879 | * lib/lbitset.c (lbitset_size, lbitset_list, lbitset_list_merge): | |
4880 | Likewise. | |
420f93c8 | 4881 | |
ff68026d PE |
4882 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_bytes): |
4883 | Use size_t, not unsigned int, to count bytes. | |
4884 | * lib/abitset.h (abitset_bytes): Likewise. | |
4885 | * lib/bitset.c (bitset_bytes, bitset_alloc, bitset_obstack_alloc): | |
4886 | Likewise. | |
4887 | * lib/bitset.h (bitset_bytes): Likewise. | |
4888 | * lib/bitset_stats.c (bitset_stats_bytes, bitset_stats_init): Likewise. | |
4889 | * lib/bitset_stats.h (bitset_stats_bytes): Likewise. | |
4890 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
4891 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
4892 | * lib/ebitset.h (ebitset_bytes): Likewise. | |
4893 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
4894 | * lib/lbitset.h (lbitset_bytes): Likewise. | |
420f93c8 | 4895 | |
ff68026d PE |
4896 | * lib/abitset.c (abitset_empty_p, abitset_not, abitset_equal_p, |
4897 | abitset_subset_p, abitset_disjoint_p, abitset_and, | |
4898 | abitset_and_cmp, abitset_andn, abitset_andn_cmp, abitset_or, | |
4899 | abitset_or_cmp, abitset_xor, abitset_xor_cmp, abitset_and_or, | |
4900 | abitset_and_or_cmp, abitset_andn_or, abitset_andn_or_cmp, | |
4901 | abitset_or_and, abitset_or_and_cmp): | |
4902 | Use bitset_windex instead of unsigned int. | |
4903 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
4904 | * lib/ebitset.c (struct ebitset_struct.size, ebitset_elts_grow, | |
4905 | ebitset_elt_add, ebitset_elt_remove, ebitset_weed, | |
4906 | ebitset_elt_find, ebitset_list_reverse, ebitset_list, ebitset_init): | |
4907 | Likewise. | |
4908 | * lib/lbitset.c (lbitset_ones, lbitset_not): Likewise. | |
420f93c8 | 4909 | |
ff68026d PE |
4910 | * lib/bitset.c (bitset_print): |
4911 | Use proper printf formats for widths of integer types. | |
4912 | * lib/bitset_stats.c (bitset_percent_histogram_print, | |
4913 | bitset_log_histogram_print, bitset_stats_print_1): Likewise. | |
4914 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
4915 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
4916 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
420f93c8 | 4917 | |
ff68026d PE |
4918 | * lib/bbitset.h (BITSET_BINDEX_MAX, BITSET_WINDEX_MAX, |
4919 | BITSET_SIZE_MAX): New macros. | |
4920 | (BITSET_INDEX_MAX): Remove. It wasn't right, since it assumed that | |
4921 | sizeof (bitset_word) == sizeof (bitset_windex). All uses changed | |
4922 | to BITSET_WINDEX_MAX. | |
4923 | ||
4924 | * lib/bitset.c (bitset_next, bitset_prev, bitset_first, | |
4925 | bitset_last): Return BITSET_BINDEX_MAX (not -1) for no value, | |
4926 | since we now return the bitset_bindex type (not int). | |
4927 | ||
4928 | * lib/bitsetv.c (bitsetv_alloc): Check for arithmetic overflow | |
4929 | when computing sizes. | |
4930 | * lib/ebitset.c (ebitset_elts_grow): Likewise. | |
4931 | ||
4932 | * lib/lbitset.c (lbitset_elt_find): Simplify windex calculation | |
4933 | and avoid cast to unsigned. | |
4934 | ||
6aa452a6 AD |
4935 | 2002-09-30 Akim Demaille <akim@epita.fr> |
4936 | ||
4937 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
4938 | * lib/bitset_stats.c, lib/bitsetv.c, lib/ebitset.c, lib/lbitset.c: | |
4939 | Updates from Michael Hayes. | |
4940 | ||
927f7817 AD |
4941 | 2002-09-30 Art Haas <ahaas@neosoft.com> |
4942 | ||
4943 | * configure.ac: Update AC_OUTPUT and AM_CONFIG_HEADER | |
4944 | invocations. | |
4945 | * tests/cxx-type.at (declarator): Don't rely on NDEBUG being not | |
4946 | defined. | |
4947 | ||
9738f41e AD |
4948 | 2002-09-27 Akim Demaille <akim@epita.fr> |
4949 | ||
4950 | Version 1.49c. | |
4951 | ||
a5c75d7f AD |
4952 | 2002-09-27 Akim Demaille <akim@epita.fr> |
4953 | ||
4954 | * configure.ac (AM_INIT_AUTOMAKE): We _need_ 1.7. | |
4955 | (Because of AC_LIBSOURCE). | |
4956 | ||
8280e179 AD |
4957 | 2002-09-27 Akim Demaille <akim@epita.fr> |
4958 | ||
4959 | Playing with Autoscan. | |
4960 | ||
4961 | * configure.ac: Remove the old LIBOBJ tweaks. | |
4962 | (AC_REPLACE_FUNCS): Add strrchr and strtol. | |
4963 | * lib/strrchr.c: New. | |
4964 | * lib/strtol.c: New, from the Coreutils 4.5.1. | |
4965 | ||
ae64af35 AD |
4966 | 2002-09-27 Akim Demaille <akim@epita.fr> |
4967 | ||
4968 | Playing with Autoscan. | |
4969 | ||
4970 | * m4/prereq.m4 (jm_PREREQ_ARGMATCH, jm_FUNC_ARGMATCH): New. | |
4971 | * lib/Makefile.am (libbison_a_SOURCES): No longer include | |
4972 | argmatch.c and argmatch.h, since they are AC_LIBSOURCE'd. | |
4973 | * lib/strcasecmp.c, lib/strncasecmp.c, lib/memcmp.c: New, from the | |
4974 | Coreutils 4.5.1. | |
4975 | ||
d1a1114f AD |
4976 | 2002-09-24 Akim Demaille <akim@epita.fr> |
4977 | ||
4978 | * doc/bison.texinfo (Stack Overflow): xref to Recursion. | |
4979 | (Frequently Asked Questions, Parser Stack Overflow): New. | |
4980 | ||
b906441c AD |
4981 | 2002-09-13 Akim Demaille <akim@epita.fr> |
4982 | ||
4983 | Playing with autoscan. | |
4984 | ||
4985 | * src/reader.c (get_merge_function): Use xstrdup, not strdup. | |
4986 | * src/files.c (skeleton_find): Remove, unused. | |
4987 | * m4/memcmp.m4: New, from the Coreutils 4.5.1. | |
4988 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Run jm_FUNC_MEMCMP. | |
4989 | ||
bd701811 AD |
4990 | 2002-09-13 Akim Demaille <akim@epita.fr> |
4991 | ||
4992 | * configure.ac (AM_INIT_AUTOMAKE): Require Automake 1.6.3. | |
4993 | * Makefile.am (AUTOMAKE_OPTIONS): Don't. | |
4994 | ||
e0a13e7b AD |
4995 | 2002-09-13 Akim Demaille <akim@epita.fr> |
4996 | ||
4997 | * configure.ac: Require 2.54. | |
4998 | s/jm_FUNC_MALLOC/AC_FUNC_MALLOC/. | |
4999 | s/jm_FUNC_REALLOC/AC_FUNC_REALLOC/. | |
5000 | * m4/c-bs-a.m4, m4/malloc.m4, m4/mbstate_t.m4, m4/realloc.m4: | |
5001 | Remove, provided by Autoconf macros. | |
5002 | ||
c97011bf AD |
5003 | 2002-09-12 Akim Demaille <akim@epita.fr> |
5004 | ||
5005 | * m4/prereq.m4: Update, from Coreutils 4.5.1. | |
5006 | ||
d862b1be AD |
5007 | 2002-09-12 Akim Demaille <akim@epita.fr> |
5008 | ||
5009 | * m4/prereq.m4: Update, from Fileutils 4.1.5. | |
5010 | * configure.ac (jm_PREREQ_TEMPNAME): Invoke it. | |
5011 | Reported by Martin Mokrejs. | |
5012 | ||
3d38c03a AD |
5013 | 2002-09-10 Akim Demaille <akim@epita.fr> |
5014 | ||
5015 | * src/parse-gram.y: Associate a human readable string to each | |
5016 | token type. | |
5017 | * tests/regression.at (Invalid inputs): Adjust. | |
5018 | ||
b6347355 AD |
5019 | 2002-09-10 Gary V. Vaughan <gary@gnu.org> |
5020 | ||
5021 | * tests/Makefile.am ($(srcdir)/package.m4): Bison now ships | |
5022 | with an Autoconf-2.5x style configure.ac. | |
5023 | ||
09ba4ab2 PE |
5024 | 2002-09-06 Paul Eggert <eggert@twinsun.com> |
5025 | ||
5026 | * doc/bison.texinfo (Conditions): Make explicit that the GPL | |
5027 | exception applies only to yacc.c. This is a modification of a | |
5028 | patch originally suggested by Akim Demaille. | |
5029 | ||
21846f69 AD |
5030 | 2002-09-06 Akim Demaille <akim@epita.fr> |
5031 | ||
09ba4ab2 PE |
5032 | * data/c.m4 (b4_copyright): Move the GPL exception comment from |
5033 | here to... | |
5034 | * data/yacc.c: here. | |
5035 | ||
21846f69 AD |
5036 | * data/lalr1.cc (struct yyltype): Don't define it, since we use |
5037 | LocationType. | |
5038 | (b4_ltype): Default to yy::Location from location.hh. | |
5039 | ||
c0ad8bf3 AD |
5040 | 2002-09-04 Jim Meyering <jim@meyering.net> |
5041 | ||
5042 | * data/yacc.c: Guard the declaration of yytoknum also with | |
5043 | `#ifdef YYPRINT', so it is declared only when used. | |
5044 | ||
3a93251e AD |
5045 | 2002-09-04 Akim Demaille <akim@epita.fr> |
5046 | ||
5047 | * configure.in: Rename as... | |
5048 | * configure.ac: this. | |
5049 | Bump to 1.49c. | |
5050 | ||
427c0dda AD |
5051 | 2002-09-04 Akim Demaille <akim@epita.fr> |
5052 | ||
5053 | * src/assoc.c, src/closure.c, src/gram.c, src/injections.c, | |
5054 | * src/lalr.c, src/LR0.c, src/relation.c, src/tables.c: Don't | |
5055 | translate maintainer only messages. | |
5056 | ||
6a254321 PE |
5057 | 2002-08-12 Paul Eggert <eggert@twinsun.com> |
5058 | ||
645e30d1 PE |
5059 | Version 1.49b. |
5060 | ||
6a254321 PE |
5061 | * Makefile.am (SUBDIRS): Remove intl. |
5062 | (DISTCLEANFILES): Remove. | |
5063 | * NEWS: Mention that GNU M4 is now required. Clarify what is | |
5064 | meant by "larger grammars". Mention the pt_BR translation. | |
5065 | * configure.in (AC_CHECK_DECLS): Add getenv, getopt. | |
5066 | (AM_GNU_GETTEXT_VERSION): New macro, replacing GETTEXT_VERSION var. | |
5067 | Bump version from 0.11.2 to 0.11.5. | |
5068 | (BISON_PREREQ_STAGE): Remove. | |
5069 | (AM_GNU_GETTEXT): Use external gettext. | |
5070 | (AC_OUTPUT): Remove intl/Makefile. | |
5071 | ||
5072 | * config/depcomp, config/install-sh: Sync with Automake 1.6.3. | |
5073 | ||
5074 | * data/glr.c: Include string.h, for strlen. | |
5075 | (yyreportParseError): Use size_t for yysize. | |
5076 | (yy_yypstack): No longer nested inside yypstates, as nested | |
5077 | functions are not portable. Do not assume size_t is the | |
5078 | same width as int. | |
5079 | (yypstates): Do not assume that ptrdiff_t is the same width | |
5080 | as int, and similarly for yyposn and YYINDEX. | |
5081 | ||
5082 | * data/yacc.c: Fix comment about `$$ = $1': it can copy garbage. | |
5083 | ||
5084 | * lib/Makefile.am (INCLUDES): Do not include from the intl | |
5085 | directory, which has been removed. | |
5086 | * src/Makefile.am (INCLUDES): Likewise. | |
5087 | ||
5088 | * lib/Makefile.am (libbison_a_SOURCES): Add unlocked-io.h. | |
5089 | (bitsets_sources, additional_bitsets_sources, timevars_sources): | |
5090 | New vars. | |
5091 | ||
5092 | * lib/Makefile.am (libbison_a_SOURCES): Avoid +=, a GNU make extension. | |
5093 | * tests/Makefile.am (EXTRA_DIST): Likewise. | |
5094 | ||
5095 | * lib/abitset.c (abitset_reverse_list, ebitset_reverse_list): | |
5096 | Do not assume that bitset_windex is the same width as unsigned. | |
5097 | ||
5098 | * lib/abitset.c (abitset_unused_clear): Do not assume that | |
5099 | bitset_word is the same width as int. | |
5100 | * lib/bbitset.h (BITSET_INDEX_MAX, BITSET_MSB): Likewise. | |
5101 | * lib/bitset.h (bitset_set, bitset_reset): Likewise. | |
5102 | * lib/bitset_stats.c (bitset_stats_set, bitset_stats_reset): Likewise. | |
5103 | * lib/ebitset.c (ebitset_set, ebitset_reset): Likewise. | |
5104 | * lib/lbitset.c (lbitset_set, lbitset_reset): Likewise. | |
5105 | ||
5106 | * lib/abitset.c (abitset_op1): Use -1, not ~0, as memset arg (for | |
5107 | portability to one's complement hosts!). | |
5108 | * lib/ebitset.c (ebitset_op1): Likewise. | |
5109 | * lib/lbitset.c (lbitset_op1): Likewise. | |
5110 | ||
5111 | * lib/argmatch.c, lib/quotearg.c, quotearg.h: Sync with GNU tar. | |
5112 | * lib/argmatch.h, lib/basename.c, lib/dirname.c, lib/dirname.h, | |
5113 | lib/hash.c, lib/hash.h, lib/strnlen.c, lib/xmalloc.c: | |
5114 | Sync with fileutils. | |
5115 | * lib/error.c, lib/getopt.c, lib/getopt.h, lib/getopt1.c, | |
5116 | lib/gettext.h: Sync with diffutils. | |
5117 | ||
5118 | * lib/memrchr.c, lib/mkstemp.c, lib/strchr.c, lib/strnlen.c, | |
5119 | lib/strspn.c, lib/tempname.c: Use GPL, not LGPL. | |
5120 | ||
5121 | * lib/obstack.c, lib/obstack.h: Sync with fileutils, except use | |
5122 | PROTOTYPES to check for prototypes, and "defined __STDC__" to | |
5123 | check for void *. | |
5124 | ||
5125 | * lib/bbitset.h (BITSET_WORD_BITS): Now of type unsigned, not | |
5126 | size_t; the old version tried to do this but casted improperly. | |
5127 | (bitset_bindex, bitset_windex): Now size_t, not unsigned long. | |
5128 | (bitset_test): Now returns int, not unsigned long. | |
5129 | ||
5130 | * lib/bitset_stats.c: Include "gettext.h". | |
5131 | (_): New macro. | |
5132 | (bitset_stats_set, bitset_stats_reset, bitset_stats_test): Don't | |
5133 | name locals "index", as it generates unnecessary warnings on some | |
5134 | hosts that have an "index" function. | |
5135 | ||
5136 | * lib/bitset_stats.c (bitset_stats_print_1, bitset_stats_print, | |
5137 | bitset_stats_read, bitset_stats_write): Wrap strings in _() if | |
5138 | they need translation. | |
5139 | * src/LR0.c (state_list_append, new_itemsets, get_state, | |
5140 | append_states, generate_states): Likewise. | |
5141 | * src/assoc.c (assoc_to_string): Likewise. | |
5142 | * src/closure.c (print_closure, set_firsts, closure): Likewise. | |
5143 | * src/gram.c (grammar_dump): Likewise. | |
5144 | * src/injections.c (injections_compute): Likewise. | |
5145 | * src/lalr.c (lookaheads_print): Likewise. | |
5146 | * src/relation.c (relation_transpose): Likewise. | |
5147 | * src/scan-gram.l: Likewise. | |
5148 | * src/tables.c (table_grow, pack_vector): Likewise. | |
5149 | ||
5150 | * m4/Makefile.am (EXTRA_DIST): Remove codeset.m4, | |
5151 | glibc21.m4, isc-posix.m4 lcmessage.m4, stage.m4. | |
5152 | * m4/malloc.m4, m4/realloc.m4: Sync with diffutils. | |
5153 | * m4/mbstate_t.m4: Sync with fileutils. | |
5154 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): AC_MBSTATE_T -> AC_TYPE_MBSTATE_T. | |
5155 | ||
5156 | * po/LINGUAS: Add pt_BR. | |
5157 | * po/POTFILES.in: Add src/assoc.c, src/closure.c, src/gram.c, | |
5158 | src/main.c, src/relation.c, src/state.c, lib/bitset_stats.c, | |
5159 | lib/timevar.c. | |
5160 | Use src/parse-gram.y instead of src/parse-gram.c, as the gettext | |
5161 | manual recommends. | |
5162 | Similarly, use src/scan-gram.l instead of src/scan-gram.c. | |
5163 | ||
5164 | * src/complain.c (strerror_r): Remove decl; not needed. | |
5165 | (strerror): Use same pattern as ../lib/error.c. | |
5166 | ||
5167 | * src/files.c, src/files.h (compute_header_macro): Remove; unused. | |
5168 | ||
5169 | * src/gram.c (grammar_dump): Do not assume ptrdiff_t fits in int. | |
5170 | ||
5171 | * src/main.c (main): Cast result of bindtextdomain and textdomain | |
5172 | to void, to avoid a GCC warning when --disable-nls is in effect. | |
5173 | ||
5174 | * src/scan-gram.l: Use strings rather than escapes when possible, | |
5175 | to minimize the number of warnings from xgettext. | |
5176 | (handle_action_dollar, handle_action_at): Don't use isdigit, | |
5177 | as it mishandles negative chars and it may not work as expected | |
5178 | outside the C locale. | |
5179 | ||
5180 | * src/symtab.c (symbol_get): Don't cast LHS of an assignment; | |
5181 | this is a GCC extension and is not portable to other compilers. | |
5182 | ||
5183 | * src/system.h (alloca): Use same pattern as ../lib/error.c. | |
5184 | Do not include <ctype.h>; no longer needed. | |
5185 | Do not include <malloc.h>; no longer needed (and generates | |
5186 | warnings on OpenBSD 3.0). | |
5187 | ||
5188 | * tests/cxx-type.at (yylex): Do not pass signed char to isupper; | |
5189 | it's not portable. | |
5190 | ||
5191 | * tests/regression.at: Do not use 'cc -c input.c -o input'; | |
5192 | Sun C rejects this. Instead, use 'cc -c input.c -o input.o'. | |
5193 | ||
5194 | * tests/synclines.at (AC_SYNCLINES_COMPILE): Accept any nonzero | |
5195 | exit status as failure, not just exit status 1. Sun C exits | |
5196 | with status 2 sometimes. | |
5197 | ||
5198 | * tests/torture.at (AT_INCREASE_DATA_SIZE): New macro. | |
5199 | Use it for the two large tests. | |
5200 | ||
c8f002c7 AD |
5201 | 2002-08-02 Akim Demaille <akim@epita.fr> |
5202 | ||
5203 | * src/conflicts.c (conflicts_output): Don't output rules never | |
5204 | reduced here, since anyway that computation doesn't work. | |
5205 | * src/gram.h, src/gram.h (rule_filter_t, rule_useful_p) | |
5206 | (rule_useless_p, rule_never_reduced_p): New. | |
5207 | (grammar_rules_partial_print): Use a filter instead of a range. | |
5208 | Display the title only if needed. | |
5209 | (grammar_rules_print): Adjust. | |
5210 | (grammar_rules_never_reduced_report): New. | |
5211 | * src/tables.c (action_row): Move the computation of rules never | |
5212 | reduced to... | |
5213 | (token_actions): here. | |
5214 | * src/main.c (main): Make the parser before making the report, so | |
5215 | that rules never reduced are computed. | |
5216 | Call grammar_rules_never_reduced_report. | |
5217 | * src/print.c (print_results): Report rules never reduced. | |
5218 | * tests/conflicts.at, tests/reduce.at: Adjust. | |
5219 | ||
cd08e51e AD |
5220 | 2002-08-01 Akim Demaille <akim@epita.fr> |
5221 | ||
5222 | Instead of attaching lookaheads and duplicating the rules being | |
5223 | reduced by a state, attach the lookaheads to the reductions. | |
5224 | ||
5225 | * src/state.h (state_t): Remove the `lookaheads', | |
5226 | `lookaheads_rule' member. | |
5227 | (reductions_t): Add a `lookaheads' member. | |
5228 | Use a regular array for the `rules'. | |
5229 | * src/state.c (reductions_new): Initialize the lookaheads member | |
5230 | to 0. | |
5231 | (state_rule_lookaheads_print): Adjust. | |
5232 | * src/state.h, src/state.c (state_reductions_find): New. | |
5233 | * src/conflicts.c (resolve_sr_conflict, set_conflicts) | |
5234 | (count_rr_conflicts): Adjust. | |
5235 | * src/lalr.c (LArule): Remove. | |
5236 | (add_lookback_edge): Adjust. | |
5237 | (state_lookaheads_count): New. | |
5238 | (states_lookaheads_initialize): Merge into... | |
5239 | (initialize_LA): this. | |
5240 | (lalr_free): Adjust. | |
5241 | * src/main.c (main): Don't free nullable and derives too early: it | |
5242 | is used by --verbose. | |
5243 | * src/print.c, src/print_graph.c, src/tables.c: Adjust. | |
5244 | ||
bb0027a9 AD |
5245 | 2002-08-01 Akim Demaille <akim@epita.fr> |
5246 | ||
5247 | * src/derives.h, src/derives.c (derives): A `rule_t***' instead of | |
5248 | `rule_number_t**'. | |
5249 | (set_derives, free_derives): Rename as... | |
5250 | (derives_compute, derives_free): this. | |
5251 | Adjust all dependencies. | |
5252 | * src/nullable.c (set_nullable, free_nullable): Rename as... | |
5253 | (nullable_compute, nullable_free): these. | |
5254 | (rule_list_t): Store rule_t *, not rule_number_t. | |
5255 | * src/state.c (state_rule_lookaheads_print): Directly compare rule | |
5256 | pointers, instead of their numbers. | |
5257 | * src/main.c (main): Call nullable_free, and derives_free earlier, | |
5258 | as they were lo longer used. | |
5259 | ||
3325ddc4 AD |
5260 | 2002-08-01 Akim Demaille <akim@epita.fr> |
5261 | ||
5262 | * lib/timevar.c (get_time): Include children time. | |
5263 | * src/lalr.h (LA, LArule): Don't export them: used with the | |
5264 | state_t. | |
5265 | * src/lalr.c (LA, LArule): Static. | |
5266 | * src/lalr.h, src/lalr.c (lalr_free): New. | |
5267 | * src/main.c (main): Call it. | |
5268 | * src/tables.c (pack_vector): Check whether loc is >= to the | |
5269 | table_size, not >. | |
5270 | (pack_tables): Don't free froms, tos, conflict_tos, and pos... | |
5271 | (tables_generate): do it, since that's also it which allocates | |
5272 | them. | |
5273 | Don't free LA and LArule, main does. | |
5274 | ||
c6f1a33c AD |
5275 | 2002-07-31 Akim Demaille <akim@epita.fr> |
5276 | ||
5277 | Separate parser tables computation and output. | |
5278 | ||
5279 | * src/output.c (nvectors, base_t, base, base_ninf, conflict_table) | |
5280 | (conflict_list, conflict_list_cnt, table, check, table_ninf) | |
5281 | (yydefgoto, yydefact, high): Move to... | |
5282 | * src/tables.h, src/tables.c: here. | |
5283 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
5284 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
5285 | (symbol_number_to_vector_number, nvectors, BASE_MAX, BASE_MIN) | |
5286 | (froms, tos, conflict_tos, tally, width, action_t, ACTION_MAX) | |
5287 | (ACTION_MIN, actrow, order, nentries, pos, conflrow) | |
5288 | (conflict_list_free, table_size, lowzero, table_grow, conflict_row) | |
5289 | (action_row, save_row, token_actions, save_column, default_goto) | |
5290 | (goto_actions, sort_actions, matching_state, pack_vector) | |
5291 | (table_ninf_remap, pack_table, prepare_actions): Move to... | |
5292 | * src/tables.c: here. | |
5293 | * src/tables.h, src/tables.c(tables_generate, tables_free): New. | |
5294 | * src/output.c (token_actions, output_base, output_conflicts) | |
5295 | (output_check): Merge into... | |
5296 | (prepare_actions): this. | |
5297 | (actions_output): Rename as... | |
5298 | (user_actions_output): this. | |
5299 | * src/main.c (main): Call tables_generate and tables_free. | |
5300 | ||
1509d42f AD |
5301 | 2002-07-31 Akim Demaille <akim@epita.fr> |
5302 | ||
5303 | Steal GCC's --time-report support. | |
5304 | ||
5305 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: New, | |
5306 | stolen/adjusted from GCC. | |
5307 | * m4/stage.m4: Remove time related checks. | |
5308 | * m4/timevar.m4: New. | |
5309 | * configure.in: Adjust. | |
5310 | * src/system.h: Adjust to using timevar.h. | |
5311 | * src/getargs.h, src/getargs.c: Support trace_time for | |
5312 | --trace=time. | |
5313 | * src/main.c (stage): Remove. | |
5314 | (main): Replace `stage' invocations with timevar calls. | |
5315 | * src/output.c: Insert pertinent timevar calls. | |
5316 | ||
273a74fa AD |
5317 | 2002-07-31 Akim Demaille <akim@epita.fr> |
5318 | ||
5319 | Let --trace have arguments. | |
5320 | ||
5321 | * src/getargs.h (enum trace_e): New. | |
5322 | * src/getargs.c (trace_args, trace_types, trace_argmatch): New. | |
5323 | (long_options, short_options): --trace/-T takes an optional | |
5324 | argument. | |
5325 | Change all the uses of trace_flag to reflect the new flags. | |
5326 | * tests/sets.at (Firsts, Nullable, Broken Closure): Use --trace=sets. | |
5327 | ||
5328 | Strengthen `stage' portability. | |
5329 | ||
5330 | * m4/stage.m4 (BISON_PREREQ_STAGE): New. | |
5331 | * configure.in: Use it. | |
5332 | Don't check for malloc.h and sys/times.h. | |
5333 | * src/system.h: Include them when appropriate. | |
5334 | * src/main.c (stage): Compile only when mallinfo, struct mallinfo, | |
5335 | times and struct tms are available. | |
5336 | ||
217598da AD |
5337 | 2002-07-30 Akim Demaille <akim@epita.fr> |
5338 | ||
5339 | In verbose parse error message, don't report `error' as an | |
5340 | expected token. | |
5341 | * tests/actions.at (Printers and Destructors): Adjust. | |
5342 | * tests/calc.at (Calculator $1): Adjust. | |
5343 | * data/yacc.c, data/glr.c, data/lalr1.c: When making the verbose | |
5344 | error message, do not report the parser accepts the error token in | |
5345 | that state. | |
5346 | ||
52489d44 AD |
5347 | 2002-07-30 Akim Demaille <akim@epita.fr> |
5348 | ||
5349 | Normalize conflict related messages. | |
5350 | ||
5351 | * src/complain.h, src/complain.c (warn, complain): New. | |
5352 | * src/conflicts.c (conflicts_print): Use them. | |
5353 | (conflict_report_yacc): New, extracted from... | |
5354 | (conflicts_print): here. | |
5355 | * tests/conflicts.at, tests/existing.at: Adjust. | |
5356 | ||
e8832397 AD |
5357 | 2002-07-30 Akim Demaille <akim@epita.fr> |
5358 | ||
5359 | Report rules which are never reduced by the parser: those hidden | |
5360 | by conflicts. | |
5361 | ||
5362 | * src/LR0.c (save_reductions): Don't make the final state too | |
5363 | different: save its reduction (accept) instead of having a state | |
5364 | without any action (no shift or goto, no reduce). | |
5365 | Note: the final state is now a ``regular'' state, i.e., the | |
5366 | parsers now contain `reduce 0' as default reduction. | |
5367 | Nevertheless, since they decide to `accept' when yystate = | |
5368 | final_state, they still will not reduce rule 0. | |
5369 | * src/print.c (print_actions, print_reduction): Adjust. | |
5370 | * src/output.c (action_row): Track reduced rules. | |
5371 | (token_actions): Report rules never reduced. | |
5372 | * tests/conflicts.at, tests/regression.at: Adjust. | |
5373 | ||
caf23d24 AD |
5374 | 2002-07-30 Akim Demaille <akim@epita.fr> |
5375 | ||
5376 | `stage' was accidently included in a previous patch. | |
5377 | Initiate its autoconfiscation. | |
5378 | ||
5379 | * configure.in: Look for malloc.h and sys/times.h. | |
5380 | * src/main.c (stage): Adjust. | |
5381 | Report only when trace_flag. | |
5382 | ||
640748ee AD |
5383 | 2002-07-29 Akim Demaille <akim@epita.fr> |
5384 | ||
5385 | * src/state.h, src/state.c (transitions_t): Holds state_t*'s, not | |
5386 | state_number_t. | |
5387 | (errs_t): symbol_t*, not symbol_number_t. | |
5388 | (reductions_t): rule_t*, not rule_number_t. | |
5389 | (FOR_EACH_SHIFT): New. | |
5390 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/output.c | |
5391 | * src/print.c, src/print_graph.c: Adjust. | |
5392 | ||
88bce5a2 AD |
5393 | 2002-07-29 Akim Demaille <akim@epita.fr> |
5394 | ||
5395 | Use $accept and $end, as BYacc and BTYacc do, instead of $axiom and $. | |
5396 | ||
5397 | * src/symtab.h, src/symtab.c (eoftoken, axiom): Rename as... | |
5398 | (endtoken, accept): these. | |
5399 | * src/reader.c (reader): Set endtoken's default tag to "$end". | |
5400 | Set undeftoken's tag to "$undefined" instead of "$undefined.". | |
5401 | * doc/bison.texinfo (Table of Symbols): Mention $accept and $end. | |
5402 | Adjust. | |
5403 | ||
1bfb97db AD |
5404 | 2002-07-29 Akim Demaille <akim@epita.fr> |
5405 | ||
5406 | * src/reduce.c (reduce_grammar): When the language is empty, | |
5407 | complain about the start symbol, not the axiom. | |
5408 | Use its location. | |
5409 | * tests/reduce.at (Empty Language): New. | |
5410 | ||
fc5734fe AD |
5411 | 2002-07-26 Akim Demaille <akim@epita.fr> |
5412 | ||
5413 | * src/reader.h, src/reader.c (gram_error): ... can't get | |
5414 | yycontrol without making too strong assumptions on the parser | |
5415 | itself. | |
5416 | * src/output.c (prepare_tokens): Use the real 0th value of | |
5417 | token_translations instead of `0'. | |
5418 | * src/parse-gram.y (yyerror): Don't rely on yycontrol being | |
5419 | visible here. | |
5420 | * data/yacc.c (yyreport_parse_error): Rename yylocation as yylloc | |
5421 | for the time being: %locations ought to provide it to yyerror. | |
5422 | ||
3650b4b8 AD |
5423 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5424 | ||
5425 | * src/output.c (prepare_tokens): Go up to ntokens, not ntokens + 1. | |
5426 | * doc/bison.texinfo (Decl Summary): s/$illegal/$undefined./. | |
5427 | * tests/regression.at (Web2c Actions): Adjust. | |
5428 | ||
4b3d3a8e AD |
5429 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5430 | ||
5431 | Stop storing rules from 1 to nrules + 1. | |
5432 | ||
5433 | * src/LR0.c, src/closure.c, src/derives.c, src/gram.c, src/lalr.c | |
5434 | * src/nullable.c, src/output.c, src/print.c, src/reader.c | |
5435 | * src/reduce.c: Allocate and free from &rules[0], not &rules[1]. | |
5436 | Iterate from 0 to nrules. | |
5437 | Use rule_number_as_item_number and item_number_as_rule_number. | |
5438 | Adjust to `derive' now containing possibly 0. | |
5439 | * src/gram.h (rule_number_as_item_number, item_number_as_rule_number): | |
5440 | Handle the `- 1' part in rule numbers from/to item numbers. | |
5441 | * src/conflicts.c (log_resolution): Fix the message which reversed | |
5442 | shift and reduce. | |
5443 | * src/output.c (action_row): Initialize default_rule to -1. | |
5444 | (token_actions): Adjust. | |
5445 | * tests/sets.at (Nullable, Firsts): Fix the previously bogus | |
5446 | expected output. | |
5447 | * tests/conflicts.at (Resolved SR Conflicts): Likewise. | |
5448 | ||
4a2a22f4 AD |
5449 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5450 | ||
5451 | * data/c.m4 (b4_c_function, b4_c_ansi_args, b4_c_ansi_arg) | |
5452 | (b4_c_knr_arg_names, b4_c_knr_arg_name, b4_c_knr_arg_decls) | |
5453 | (b4_c_knr_arg_decl): New. | |
5454 | * data/yacc.c: Use it to define yysymprint, yydestruct, and | |
5455 | yyreport_parse_error. | |
5456 | ||
b8df3223 AD |
5457 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5458 | ||
5459 | * data/yacc.c (yyreport_parse_error): New, extracted from... | |
5460 | (yyparse): here. | |
5461 | (yydestruct, yysymprint): Move above yyparse. | |
5462 | Be K&R compliant. | |
5463 | ||
a762e609 AD |
5464 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5465 | ||
5466 | * data/c.m4 (b4_ints_in, b4_int_type, b4_int_type_for): New, | |
5467 | replace... | |
5468 | (b4_sint_type, b4_uint_type): these. | |
5469 | * data/yacc.c, data/glr.c, data/lalr1.cc: Use b4_int_type_for. | |
5470 | * tests/regression.at (Web2c Actions): Adjust. | |
5471 | ||
12b0043a AD |
5472 | 2002-07-25 Akim Demaille <akim@epita.fr> |
5473 | ||
5474 | * src/gram.h (TIEM_NUMBER_MAX): New. | |
5475 | (item_number_of_rule_number, rule_number_of_item_number): Rename | |
5476 | as... | |
5477 | (rule_number_as_item_number, item_number_as_rule_number): these. | |
5478 | Adjust dependencies. | |
5479 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
5480 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
5481 | (symbol_number_to_vector_number): New. | |
5482 | (order): Of vector_number_t* type. | |
5483 | (base_t, BASE_MAX, BASE_MIN): New. | |
5484 | (froms, tos, width, pos, check): Of base_t type. | |
5485 | (action_number_t, ACTION_MIN, ACTION_MAX): New. | |
5486 | (actrow): Of action_number_t type. | |
5487 | (conflrow): Of unsigned int type. | |
5488 | (table_ninf, base_ninf): New. | |
5489 | (GENERATE_MUSCLE_INSERT_TABLE): Also output the `*_min' value. | |
5490 | (muscle_insert_int_table, muscle_insert_base_table) | |
5491 | (muscle_insert_rule_number_table): New. | |
5492 | (prepare_tokens): Output `toknum' as int_table. | |
5493 | (action_row): Returns a rule_number_t. | |
5494 | Use ACTION_MIN, not SHRT_MIN. | |
5495 | (token_actions): yydefact is rule_number_t*. | |
5496 | (table_ninf_remap): New. | |
5497 | (pack_table): Use it for `base' and `table'. | |
5498 | * data/yacc.c, data/glr.c, data/lalr1.cc (YYFLAG): Remove, | |
5499 | replaced with... | |
5500 | (YYPACT_NINF, YYTABLE_NINF): these. | |
5501 | (yypact, yytable): Compute their types instead of hard-coded | |
5502 | `short'. | |
5503 | * tests/regression.at (Web2c Actions): Adjust. | |
5504 | ||
5dde258a AD |
5505 | 2002-07-19 Akim Demaille <akim@epita.fr> |
5506 | ||
5507 | * src/scan-gram.l (id): Can start with an underscore. | |
5508 | ||
a945ec39 AD |
5509 | 2002-07-16 Akim Demaille <akim@epita.fr> |
5510 | ||
5511 | * src/assoc.c, src/asssoc.h (assoc_t, assoc_to_string): New. | |
5512 | Adjust all former `associativity' dependencies. | |
5513 | * src/symtab.c (symbol_new): Default associativity is `undef', not | |
5514 | `right'. | |
5515 | (symbol_check_alias_consistence): Adjust. | |
5516 | ||
fae437e8 AD |
5517 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5518 | ||
5519 | * doc/bison.texinfo: Properly set the ``header'' part. | |
5520 | Use @dircategory ``GNU programming tools'' as per Texinfo's | |
5521 | documentation. | |
5522 | Use @copying. | |
5523 | ||
1a715ef2 AD |
5524 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5525 | ||
5526 | * lib/quotearg.h: Protect against multiple inclusions. | |
5527 | * src/location.h (location_t): Add a `file' member. | |
5528 | (LOCATION_RESET, LOCATION_PRINT): Adjust. | |
5529 | * src/complain.c (warn_at, complain_at, fatal_at): Drop | |
5530 | `error_one_per_line' support. | |
5531 | ||
a5d50994 AD |
5532 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5533 | ||
5534 | * src/complain.h, src/complain.c (warn, complain): Remove, unused. | |
5535 | * src/reader.c (lineno): Remove. | |
5536 | Adjust all dependencies. | |
5537 | (get_merge_function): Take a location and use complain_at. | |
5538 | * src/symtab.h, src/symtab.c (symbol_make_alias): Likewise. | |
5539 | * tests/regression.at (Invalid inputs, Mixing %token styles): | |
5540 | Adjust. | |
5541 | ||
b275314e AD |
5542 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5543 | ||
5544 | * src/parse-gram.y (rules_or_grammar_declaration): Add an error | |
5545 | recovery rule, and forbid extensions when --yacc. | |
5546 | (gram_error): Use complain_at. | |
5547 | * src/reader.c (reader): Exit if there were parse errors. | |
5548 | ||
865b9df1 AD |
5549 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5550 | ||
5551 | * tests/synclines.at (AT_SYNCLINES_COMPILE): New. | |
5552 | (AT_TEST_SYNCLINE): Adjust to unusual GCC outputs. | |
5553 | Reported by R Blake <blakers@mac.com>. | |
5554 | ||
c76e14da AD |
5555 | 2002-07-09 Akim Demaille <akim@epita.fr> |
5556 | ||
5557 | * data/yacc.c: Output the copyright notive in the header. | |
5558 | ||
7db2ed2d AD |
5559 | 2002-07-03 Akim Demaille <akim@epita.fr> |
5560 | ||
5561 | * src/output.c (froms, tos): Are state_number_t. | |
5562 | (save_column): sp, sp1, and sp2 are state_number_t. | |
5563 | (prepare): Rename `final' as `final_state_number', `nnts' as | |
5564 | `nterms_number', `nrules' as `rules_number', `nstates' as | |
5565 | `states_number', and `ntokens' as `tokens_number'. Remove `nsym', | |
5566 | unused. | |
5567 | * data/yacc.c, data/glr.c, data/lalr1.cc: Adjust. | |
5568 | * data/lalr1.cc (nsym_): Remove, unused. | |
5569 | ||
e68e0410 AD |
5570 | 2002-07-03 Akim Demaille <akim@epita.fr> |
5571 | ||
5572 | * src/lalr.h, src/lalr.c (goto_number_t): New. | |
5573 | * src/lalr.c (goto_list_t): New. | |
5574 | Propagate them. | |
5575 | * src/nullable.c (rule_list_t): New. | |
5576 | Propagate. | |
5577 | * src/types.h: Remove. | |
5578 | ||
e1a4f3a4 AD |
5579 | 2002-07-03 Akim Demaille <akim@epita.fr> |
5580 | ||
5581 | * src/closure.c (print_fderives): Use rule_rhs_print. | |
5582 | * src/derives.c (print_derives): Use rule_rhs_print. | |
5583 | (rule_list_t): New, replaces `shorts'. | |
5584 | (set_derives): Add comments. | |
5585 | * tests/sets.at (Nullable, Firsts): Adjust. | |
5586 | ||
536545f3 AD |
5587 | 2002-07-03 Akim Demaille <akim@epita.fr> |
5588 | ||
5589 | * src/output.c (prepare_actions): Free `tally' and `width'. | |
5590 | (prepare_actions): Allocate and free `order'. | |
5591 | * src/symtab.c (symbols_free): Free `symbols'. | |
5592 | * src/scan-gram.l (scanner_free): Clear Flex's scanners memory. | |
5593 | * src/output.c (m4_invoke): Move to... | |
5594 | * src/scan-skel.l: here. | |
5595 | (<<EOF>>): Close yyout, and free its name. | |
5596 | ||
8b752b00 AD |
5597 | 2002-07-03 Akim Demaille <akim@epita.fr> |
5598 | ||
5599 | Fix some memory leaks, and fix a bug: state 0 was examined twice. | |
5600 | ||
5601 | * src/LR0.c (new_state): Merge into... | |
5602 | (state_list_append): this. | |
5603 | (new_states): Merge into... | |
5604 | (generate_states): here. | |
5605 | (set_states): Don't ensure a proper `errs' state member here, do it... | |
5606 | * src/conflicts.c (conflicts_solve): here. | |
5607 | * src/state.h, src/state.c: Comment changes. | |
5608 | (state_t): Rename member `shifts' as `transitions'. | |
5609 | Adjust all dependencies. | |
5610 | (errs_new): For consistency, also take the values as argument. | |
5611 | (errs_dup): Remove. | |
5612 | (state_errs_set): New. | |
5613 | (state_reductions_set, state_transitions_set): Assert that no | |
5614 | previous value was assigned. | |
5615 | (state_free): New. | |
5616 | (states_free): Use it. | |
5617 | * src/conflicts.c (resolve_sr_conflict): Don't use an `errs_t' as | |
5618 | temporary storage: use `errs' and `nerrs' as elsewhere. | |
5619 | (set_conflicts): Allocate and free this `errs'. | |
5620 | ||
613f5e1a AD |
5621 | 2002-07-02 Akim Demaille <akim@epita.fr> |
5622 | ||
5623 | * lib/libiberty.h: New. | |
5624 | * lib: Update the bitset implementation from upstream. | |
5625 | * src/closure.c, src/lalr.c, src/output.c, src/print_graph.c, | |
5626 | * src/state.c: Use BITSET_FOR_EACH, not BITSET_EXECUTE. | |
5627 | * src/main.c: Adjust bitset stats calls. | |
5628 | ||
26e0cadc PE |
5629 | 2002-07-01 Paul Eggert <eggert@twinsun.com> |
5630 | ||
5631 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>): Convert to unsigned | |
5632 | char, so that negative chars don't collide with $. | |
5633 | ||
1154cced AD |
5634 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5635 | ||
5636 | Have the GLR tests be `warning' checked, and fix the warnings. | |
5637 | ||
5638 | * data/glr.c (YYFPRINTF): Always define it, not only when YYDEBUG | |
5639 | (yyuserAction, yyreportAmbiguity): `Use' all the arguments. | |
5640 | (yyremoveDeletes): `yyi' and `yyj' are size_t. | |
5641 | Use YYFPRINTF when under if (YYDEBUG) to avoid empty `if' bodies. | |
5642 | (yyaddDeferredAction): static. | |
5643 | (yyglrReduce): yyi, yyk, amd yyposn are size_t. | |
5644 | (yyreportParseError): yyprefix is const. | |
5645 | yytokenp is used only when verbose. | |
5646 | (yy__GNUC__): Replace with __GNUC__. | |
5647 | (yypdumpstack): yyi is size_t. | |
5648 | (yypreference): Un-yy local variables and arguments, to avoid | |
5649 | clashes with `yyr1'. Anyway, we are not in the user name space. | |
5650 | (yytname_size): be an int, as is compared with ints. | |
5651 | * tests/testsuite.at (AT_COMPILE, AT_PARSER_CHECK): New. | |
5652 | Use them. | |
5653 | * tests/cxx-gram.at: Use quotation to protect $1. | |
5654 | Use AT_COMPILE to enable warnings hunts. | |
5655 | Prototype yylex and yyerror. | |
5656 | `Use' argc. | |
5657 | Include `string.h', not `strings.h'. | |
5658 | Produce and prototype stmtMerge only when used. | |
5659 | yylex takes a location. | |
5660 | ||
97650f4e AD |
5661 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5662 | ||
5663 | We spend a lot of time in quotearg, in particular when --verbose. | |
5664 | ||
5665 | * src/symtab.c (symbol_get): Store a quoted version of the key. | |
5666 | (symbol_tag_get, symbol_tag_get_n, symbol_tag_print): Remove. | |
5667 | Adjust all callers. | |
5668 | ||
d2576365 AD |
5669 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5670 | ||
5671 | * src/state.h (reductions_t): Rename member `nreds' as num. | |
5672 | (errs_t): Rename members `nerrs' and `errs' as `num' and `symbols'. | |
5673 | * src/state.c (ERRS_ALLOC, REDUCTIONS_ALLOC): Use the correct types. | |
5674 | ||
ccaf65bc AD |
5675 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5676 | ||
5677 | * src/state.h, src/state.c (shift_t, SHIFT_SYMBOL, SHIFT_IS_SHIFT) | |
5678 | (SHIFT_IS_GOTO, SHIFT_IS_ERROR, SHIFT_DISABLE, SHIFT_IS_DISABLED) | |
5679 | (shifts_to): Rename as... | |
5680 | (transition_t, TRANSITION_SYMBOL, TRANSITION_IS_TRANSITION) | |
5681 | (TRANSITION_IS_GOTO, TRANSITION_IS_ERROR, TRANSITION_DISABLE) | |
5682 | (TRANSITION_IS_DISABLED, transitions_to): these. | |
5683 | ||
87675353 AD |
5684 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5685 | ||
5686 | * src/print.c (print_shifts, print_gotos): Merge into... | |
5687 | (print_transitions): this. | |
5688 | (print_transitions, print_errs, print_reductions): Align the | |
5689 | lookaheads columns. | |
5690 | (print_core, print_transitions, print_errs, print_state, | |
5691 | print_grammar): Output empty lines separator before, not after. | |
5692 | (state_default_rule_compute): Rename as... | |
5693 | (state_default_rule): this. | |
5694 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
5695 | (Unresolved SR Conflicts, Resolved SR Conflicts): Adjust. | |
5696 | * tests/regression.at (Rule Line Numbers, Web2c Report): Adjust. | |
5697 | ||
ce4ccb4b AD |
5698 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5699 | ||
5700 | Display items as we display rules. | |
5701 | ||
5702 | * src/gram.h, src/gram.c (rule_lhs_print): New. | |
5703 | * src/gram.c (grammar_rules_partial_print): Use it. | |
5704 | * src/print.c (print_core): Likewise. | |
5705 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
5706 | (Unresolved SR Conflicts): Adjust. | |
5707 | (Unresolved SR Conflicts): Adjust and rename as... | |
5708 | (Resolved SR Conflicts): this, as was meant. | |
5709 | * tests/regression.at (Web2c Report): Adjust. | |
5710 | ||
bc933ef1 AD |
5711 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5712 | ||
5713 | * src/print.c (state_default_rule_compute): New, extracted from... | |
5714 | (print_reductions): here. | |
5715 | Pessimize, but clarify the code. | |
5716 | * tests/conflicts.at (Defaulted Conflicted Reduction): New. | |
5717 | ||
53d4308d AD |
5718 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5719 | ||
5720 | * src/output.c (action_row): Let default_rule be always a rule | |
5721 | number. | |
5722 | ||
574fb2d5 AD |
5723 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5724 | ||
5725 | * src/closure.c (print_firsts, print_fderives, closure): | |
5726 | Use BITSET_EXECUTE. | |
5727 | * src/lalr.c (lookaheads_print): Likewise. | |
5728 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
5729 | * src/print_graph.c (print_core): Likewise. | |
5730 | * src/print.c (print_reductions): Likewise. | |
5731 | * src/output.c (action_row): Likewise. | |
5732 | Use SHIFT_IS_DISABLED, SHIFT_IS_SHIFT and SHIFT_SYMBOL. | |
5733 | ||
05811fd7 AD |
5734 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5735 | ||
5736 | * src/print_graph.c: Use report_flag. | |
5737 | ||
0e4d5753 AD |
5738 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5739 | ||
5740 | * src/lalr.c (traverse, digraph, matrix_print, transpose): Move | |
5741 | to... | |
5742 | * src/relation.h, src/relation.c (traverse, relation_digraph) | |
5743 | (relation_print, relation_transpose): New. | |
5744 | ||
24c7d800 AD |
5745 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5746 | ||
5747 | * src/state.h, src/state.c (shifts_to): New. | |
5748 | * src/lalr.c (build_relations): Use it. | |
5749 | ||
9222837b AD |
5750 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5751 | ||
5752 | * src/gram.h (rule_number_t, RULE_NUMBER_MAX, int_of_rule_number) | |
5753 | (item_number_of_rule_number, rule_number_of_item_number): New. | |
5754 | * src/LR0.c, src/closure.c, src/derives.c, src/derives.h, | |
5755 | * src/gram.c, src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
5756 | * src/print_graph.c, src/reader.c, src/reduce.c, src/reduce.h: | |
5757 | Propagate their use. | |
5758 | Much remains to be done, in particular wrt `shorts' from types.h. | |
5759 | ||
260008e5 AD |
5760 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5761 | ||
5762 | * src/symtab.c (symbol_new): Initialize the `printer' member. | |
5763 | ||
8a731ca8 AD |
5764 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5765 | ||
5766 | * src/LR0.c (save_reductions): Remove, replaced by... | |
5767 | * src/state.h, src/state.c (state_reductions_set): New. | |
5768 | (reductions, errs): Rename as... | |
5769 | (reductions_t, errs_t): these. | |
5770 | Adjust all dependencies. | |
5771 | ||
32e1e0a4 AD |
5772 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5773 | ||
5774 | * src/LR0.c (state_list_t, state_list_append): New. | |
5775 | (first_state, last_state): Now symbol_list_t. | |
5776 | (this_state): Remove. | |
5777 | (new_itemsets, append_states, save_reductions): Take a state_t as | |
5778 | argument. | |
5779 | (set_states, generate_states): Adjust. | |
5780 | (save_shifts): Remove, replaced by... | |
5781 | * src/state.h, src/state.c (state_shifts_set): New. | |
5782 | (shifts): Rename as... | |
5783 | (shifts_t): this. | |
5784 | Adjust all dependencies. | |
5785 | * src/state.h (state_t): Remove the `next' member. | |
5786 | ||
e5fb6710 AD |
5787 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5788 | ||
5789 | * src/vcg.c (quote): Use slot 2, since we often pass symbol tag | |
5790 | escaped in slot 0. | |
5791 | ||
c7ca99d4 AD |
5792 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5793 | ||
5794 | Use hash.h for the state hash table. | |
5795 | ||
5796 | * src/LR0.c (STATE_HASH_SIZE, state_hash): Remove. | |
5797 | (allocate_storage): Use state_hash_new. | |
5798 | (free_storage): Use state_hash_free. | |
5799 | (new_state, get_state): Adjust. | |
5800 | * src/lalr.h, src/lalr.c (states): Move to... | |
5801 | * src/states.h (state_t): Remove the `link' member, no longer | |
5802 | used. | |
5803 | * src/states.h, src/states.c: here. | |
5804 | (state_hash_new, state_hash_free, state_hash_lookup) | |
5805 | (state_hash_insert, states_free): New. | |
5806 | * src/states.c (state_table, state_compare, state_hash): New. | |
5807 | * src/output.c (output_actions): Do not free states now, since we | |
5808 | still need to know the final_state number in `prepare', called | |
5809 | afterwards. Do it... | |
5810 | * src/main.c (main): here: call states_free after `output'. | |
5811 | ||
df0e7316 AD |
5812 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5813 | ||
5814 | * src/state.h, src/state.c (state_new): New, extracted from... | |
5815 | * src/LR0.c (new_state): here. | |
5816 | * src/state.h (STATE_ALLOC): Move to... | |
5817 | * src/state.c: here. | |
5818 | * src/LR0.h, src/LR0.c (nstates, final_state): Move to... | |
5819 | * src/state.h, src/state.c: here. | |
5820 | ||
39f41916 AD |
5821 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5822 | ||
5823 | * src/reader.c (gensym): Rename as... | |
5824 | * src/symtab.h, src/symtab.c (dummy_symbol_get): this. | |
5825 | (getsym): Rename as... | |
5826 | (symbol_get): this. | |
5827 | ||
d57650a5 AD |
5828 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5829 | ||
5830 | * src/state.h (state_number_t, STATE_NUMBER_MAX): New. | |
5831 | * src/LR0.c, src/LR0.h, src/conflicts.c, src/lalr.c, src/lalr.h, | |
5832 | * src/output.c, src/print.c, src/print_graph.c: Propagate. | |
5833 | * src/LR0.h, src/LR0.h (final_state): Is a state_t*. | |
5834 | ||
5a08f1ce AD |
5835 | 2002-06-30 Akim Demaille <akim@epita.fr> |
5836 | ||
5837 | Make the test suite pass with warnings checked. | |
5838 | ||
5839 | * tests/actions.at (Printers and Destructors): Improve. | |
5840 | Avoid unsigned vs. signed issues. | |
5841 | * tests/calc.at: Don't exercise the scanner here, do it... | |
5842 | * tests/input.at (Torturing the Scanner): here. | |
5843 | ||
720623af PH |
5844 | 2002-06-28 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
5845 | ||
88e7e941 | 5846 | * data/glr.c: Correct typo in Emacs-mode directive. Slightly |
720623af PH |
5847 | reorganize first lines parallel to yacc.c. |
5848 | ||
fb8135fa AD |
5849 | 2002-06-28 Akim Demaille <akim@epita.fr> |
5850 | ||
5851 | * data/c.m4 (b4_copyright, b4_sint_type, b4_uint_type, b4_token_define) | |
5852 | (b4_token_enum, b4_token_defines): New, factored from... | |
5853 | * data/lalr1.cc, data/yacc.c, glr.c: here. | |
5854 | ||
41442480 AD |
5855 | 2002-06-28 Akim Demaille <akim@epita.fr> |
5856 | ||
5857 | * data/yacc.c (yydestruct, yysymprint): Pacify GCC warnings for | |
5858 | unused variables. | |
5859 | * src/output.c (merger_output): static. | |
5860 | ||
e0e5bf84 AD |
5861 | 2002-06-28 Akim Demaille <akim@epita.fr> |
5862 | ||
5863 | * src/reader.h: s/grammer_current_rule_merge_set/grammar_.../. | |
5864 | * src/conflicts.c (conflicts_total_count): `i' is unsigned, to | |
5865 | pacify GCC. | |
5866 | * src/output.c (save_row): Initialize all the variables to pacify GCC. | |
e0e5bf84 | 5867 | |
676385e2 PH |
5868 | 2002-06-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
5869 | ||
5870 | Accumulated changelog for new GLR parsing features. | |
5871 | ||
6a254321 | 5872 | * src/conflicts.c (count_total_conflicts): Change name to |
676385e2 PH |
5873 | conflicts_total_count. |
5874 | * src/conflicts.h: Ditto. | |
5875 | * src/output.c (token_actions): Use the new name. | |
5876 | (output_conflicts): Change conflp => conflict_list_heads, and | |
5877 | confl => conflict_list for better readability. | |
5878 | * data/glr.c: Use the new names. | |
5879 | * NEWS: Add self to GLR announcement. | |
e0e5bf84 | 5880 | |
676385e2 PH |
5881 | * src/reader.c (free_merger_functions): Cleanup: XFREE->free. |
5882 | ||
5883 | * doc/bison.texinfo (GLR Parsers): Make corrections suggested by | |
5884 | Akim Demaille. | |
5885 | ||
5886 | * data/bison.glr: Change name to glr.c | |
5887 | * data/glr.c: Renamed from bison.glr. | |
5888 | * data/Makefile.am: Add glr.c | |
e0e5bf84 AD |
5889 | |
5890 | * src/getargs.c: | |
5891 | ||
676385e2 PH |
5892 | * src/symlist.h: Add dprec and merger fields to symbol_list_s. |
5893 | * src/symlist.c (symbol_list_new): Initialize dprec and merger fields. | |
e0e5bf84 | 5894 | |
676385e2 PH |
5895 | Originally 2002-06-16 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
5896 | ||
5897 | * data/bison.glr: Be sure to restore the | |
5898 | current #line when returning to the skeleton contents after having | |
5899 | exposed the input file's #line. | |
5900 | ||
5901 | Originally 2002-06-13 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5902 | ||
5903 | * data/bison.glr: Bring up to date with changes to bison.simple. | |
5904 | ||
5905 | Originally 2002-06-03 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5906 | ||
5907 | * data/bison.glr: Correct definitions that use b4_prefix. | |
5908 | Various reformatting. | |
5909 | (GLRStack): Make yychar (in YYPURE case) and yytokenp as part of stack. | |
5910 | (yyreportParseError, yyrecoverParseError, yyprocessOneStack): remove | |
5911 | yytokenp argument; now part of stack. | |
5912 | (yychar): Define to behave as documented. | |
5913 | (yyclearin): Ditto. | |
e0e5bf84 | 5914 | |
676385e2 PH |
5915 | Originally 2002-05-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
5916 | ||
5917 | * src/reader.h: Add declaration for free_merger_functions. | |
5918 | ||
5919 | * src/reader.c (merge_functions): New variable. | |
5920 | (get_merge_function): New function. | |
5921 | (free_merger_functions): New function. | |
5922 | (readgram): Check for %prec that is not followed by a symbol. | |
5923 | Handle %dprec and %merge declarations. | |
5924 | (packgram): Initialize dprec and merger fields in rules array. | |
5925 | ||
5926 | * src/output.c (conflict_tos, conflrow, conflict_table, conflict_list, | |
5927 | conflict_list_cnt, conflict_list_free): New variables. | |
5928 | (table_grow): Also grow conflict_table. | |
e0e5bf84 | 5929 | (prepare_rules): Output dprec and merger tables. |
676385e2 | 5930 | (conflict_row): New function. |
e0e5bf84 | 5931 | (action_row): Output conflict lists for GLR parser. Don't use |
676385e2 PH |
5932 | default reduction in conflicted states for GLR parser so that there |
5933 | are spaces for the conflict lists. | |
5934 | (save_row): Also save conflict information. | |
5935 | (token_actions): Allocate conflict list. | |
5936 | (merger_output): New function. | |
5937 | (pack_vector): Pack conflict table, too. | |
5938 | (output_conflicts): New function to output yyconflp and yyconfl. | |
5939 | (output_check): Allocate conflict_tos. | |
5940 | (output_actions): Output conflict tables, also. | |
5941 | (output_skeleton): Output b4_mergers definition. | |
5942 | (prepare): Output b4_max_rhs_length definition. | |
5943 | Use 'bison.glr' as default skeleton for GLR parsers. | |
5944 | ||
5945 | * src/gram.c (glr_parser): New flag. | |
5946 | (grammar_free): Call free_merger_functions. | |
5947 | ||
5948 | * src/conflicts.c (count_rr_conflicts): Augment to optionally count | |
5949 | all pairs of conflicting reductions, rather than just all tokens | |
5950 | causing conflicts. Needed to size conflict tables. | |
e0e5bf84 | 5951 | (conflicts_output): Modify call to count_rr_conflicts for new |
676385e2 PH |
5952 | interface. |
5953 | (conflicts_print): Ditto. | |
5954 | (count_total_conflicts): New function. | |
5955 | ||
5956 | * src/reader.h (merger_list): New type. | |
5957 | (merge_functions): New variable. | |
5958 | ||
5959 | * src/lex.h (tok_dprec, tok_merge): New token types. | |
5960 | ||
5961 | * src/gram.h (rule_s): Add dprec and merger fields. | |
5962 | (glr_parser): New flag. | |
5963 | ||
5964 | * src/conflicts.h (count_total_conflicts): New function. | |
5965 | ||
5966 | * src/options.c (option_table): Add %dprec, %merge, and %glr-parser. | |
5967 | ||
5968 | * doc/bison.texinfo (Generalized LR Parsing): New section. | |
5969 | (GLR Parsers): New section. | |
5970 | (Language and Grammar): Mention GLR parsing. | |
5971 | (Table of Symbols): Add %dprec, %glr-parser, %merge, GLR | |
5972 | Correct typo ("tge" -> "the"). | |
5973 | ||
5974 | * data/bison.glr: New skeleton for GLR parsing. | |
5975 | ||
5976 | * tests/cxx-gram.at: New tests for GLR parsing. | |
5977 | ||
5978 | * tests/testsuite.at: Include cxx-gram.at. | |
5979 | ||
5980 | * tests/Makefile.am: Add cxx-gram.at. | |
e0e5bf84 | 5981 | |
676385e2 PH |
5982 | * src/parse-gram.y: |
5983 | ||
5984 | * src/scan-gram.l: Add %dprec, %glr-parser, %merge. | |
5985 | ||
5986 | * src/parse-gram.y: Grammar for %dprec, %merge, %glr-parser. | |
e0e5bf84 | 5987 | |
b5480d74 | 5988 | 2002-06-27 Akim Demaille <akim@epita.fr> |
e2aaf4c4 AD |
5989 | |
5990 | * src/options.h, src/options.c: Remove. | |
5991 | * src/getargs.c (short_options, long_options): New. | |
5992 | ||
60491a94 AD |
5993 | 2002-06-27 Akim Demaille <akim@epita.fr> |
5994 | ||
5995 | * data/bison.simple, data/bison.c++: Rename as... | |
5996 | * data/yacc.c, data/lalr1.cc: these. | |
5997 | * doc/bison.texinfo (Environment Variables): Remove. | |
5998 | ||
9be0c25b AD |
5999 | 2002-06-25 Raja R Harinath <harinath@cs.umn.edu> |
6000 | ||
6001 | * src/getargs.c (report_argmatch): Initialize strtok(). | |
6002 | ||
1ae72863 AD |
6003 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6004 | ||
6005 | * data/bison.simple (b4_symbol_actions): New, replaces... | |
6006 | (b4_symbol_destructor, b4_symbol_printer): these. | |
6007 | (yysymprint): Be sure to call YYPRINT only for tokens, and using | |
6008 | user token numbers. | |
6009 | ||
87542d29 AD |
6010 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6011 | ||
6012 | * data/bison.simple (yydestructor): Rename as... | |
6013 | (yydestruct): this. | |
6014 | ||
1a31ed21 AD |
6015 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6016 | ||
6017 | * src/symtab.h, src/symtab.c (symbol_type_set) | |
6018 | (symbol_destructor_set, symbol_precedence_set): The location is | |
6019 | the last argument. | |
6020 | Adjust all callers. | |
6021 | ||
e776192e AD |
6022 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6023 | ||
6024 | * src/parse-gram.y (YYPRINT, yyprint): Don't mess with the parser | |
6025 | internals. | |
6026 | * src/reader.h, src/reader.c (grammar_current_rule_prec_set): | |
6027 | Takes a location. | |
6028 | * src/symtab.h, src/symtab.c (symbol_class_set) | |
6029 | (symbol_user_token_number_set): Likewise. | |
6030 | Adjust all callers. | |
6031 | Promote complain_at. | |
6032 | * tests/input.at (Type Clashes): Adjust. | |
6033 | ||
5c1180b3 AD |
6034 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6035 | ||
6036 | * data/bison.simple (YYLEX): Fix the declaration when | |
6037 | %pure-parser. | |
6038 | ||
e3170060 AD |
6039 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6040 | ||
6041 | * data/bison.simple (yysymprint): Don't print the token number, | |
6042 | just its name. | |
6043 | * tests/actions.at (Destructors): Rename as... | |
6044 | (Printers and Destructors): this. | |
6045 | Also exercise %printer. | |
6046 | ||
253862fd AD |
6047 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6048 | ||
6049 | * data/bison.simple (YYDSYMPRINT): New. | |
6050 | Use it to remove many of the #if YYDEBUG/if (yydebug). | |
6051 | ||
366eea36 AD |
6052 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6053 | ||
6054 | * src/symtab.h, src/symtab.c (symbol_t): printer and | |
6055 | printer_location are new members. | |
6056 | (symbol_printer_set): New. | |
6057 | * src/parse-gram.y (PERCENT_PRINTER): New token. | |
6058 | Handle its associated rule. | |
6059 | * src/scan-gram.l: Adjust. | |
6060 | (handle_destructor_at, handle_destructor_dollar): Rename as... | |
6061 | (handle_symbol_code_at, handle_symbol_code_dollar): these. | |
6062 | * src/output.c (symbol_printers_output): New. | |
6063 | (output_skeleton): Call it. | |
6064 | * data/bison.simple (yysymprint): New. Cannot be named yyprint | |
6065 | since there are already many grammar files with a user `yyprint'. | |
6066 | Replace the calls to YYPRINT to calls to yysymprint. | |
6067 | * tests/calc.at: Adjust. | |
6068 | * tests/torture.at (AT_DATA_STACK_TORTURE): Remove YYPRINT: it was | |
6069 | taking advantage of parser very internal details (stack size!). | |
6070 | ||
4f25ebb0 AD |
6071 | 2002-06-20 Akim Demaille <akim@epita.fr> |
6072 | ||
6073 | * src/scan-gram.l: Complete the scanner with the missing patterns | |
6074 | to pacify Flex. | |
6075 | Use `quote' and `symbol_tag_get' where appropriate. | |
6076 | ||
93b68a0e AD |
6077 | 2002-06-19 Akim Demaille <akim@epita.fr> |
6078 | ||
6079 | * tests/actions.at (Destructors): Augment to test locations. | |
6080 | * data/bison.simple (yydestructor): Pass it the current location | |
6081 | if locations are enabled. | |
6082 | Prototype only when __STDC__ or C++. | |
6083 | Change the argument names to move into the yy name space: there is | |
6084 | user code here. | |
6085 | ||
58612f1d AD |
6086 | 2002-06-19 Akim Demaille <akim@epita.fr> |
6087 | ||
74310291 AD |
6088 | * data/bison.simple (b4_pure_if): New. |
6089 | Use it instead of #ifdef YYPURE. | |
6090 | ||
6091 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
6092 | ||
6093 | * data/bison.simple (b4_location_if): New. | |
58612f1d AD |
6094 | Use it instead of #ifdef YYLSP_NEEDED. |
6095 | ||
f25bfb75 AD |
6096 | 2002-06-19 Akim Demaille <akim@epita.fr> |
6097 | ||
6098 | Prepare @$ in %destructor, but currently don't bind it in the | |
6099 | skeleton, as %location use is not cleaned up yet. | |
6100 | ||
6101 | * src/scan-gram.l (handle_dollar, handle_destructor_at) | |
6102 | (handle_action_at): New. | |
6103 | (handle_at, handle_action_dollar, handle_destructor_dollar): Take | |
6104 | a braced_code_t and a location as additional arguments. | |
6105 | (handle_destructor_dollar): Instead of requiring `b4_eval', just | |
6106 | unquote one when outputting `b4_dollar_dollar'. | |
6107 | Adjust callers. | |
6108 | * data/bison.simple (b4_eval): Remove. | |
6109 | (b4_symbol_destructor): Adjust. | |
6110 | * tests/input.at (Invalid @n): Adjust. | |
6111 | ||
c732d2c6 AD |
6112 | 2002-06-19 Zack Weinberg <zack@codesourcery.com> |
6113 | ||
6114 | * doc/bison.texinfo: Document ability to have multiple | |
6115 | prologue sections. | |
6116 | ||
8c165d89 AD |
6117 | 2002-06-18 Akim Demaille <akim@epita.fr> |
6118 | ||
6119 | * src/files.c (compute_base_names): When computing the output file | |
6120 | names from the input file name, strip the directory part. | |
6121 | ||
ca98bf57 AD |
6122 | 2002-06-18 Akim Demaille <akim@epita.fr> |
6123 | ||
6124 | * data/bison.simple.new: Comment changes. | |
6125 | Reported by Andreas Schwab. | |
6126 | ||
0bfb02ff AD |
6127 | 2002-06-18 Matt Kraai <kraai@alumni.cmu.edu> |
6128 | ||
6129 | * data/bison.simple (yyoverflowlab): #ifndef yyoverflow, so that | |
6130 | there are no `label `yyoverflowlab' defined but not used' warnings | |
6131 | when yyoverflow is defined. | |
6132 | ||
24c0aad7 AD |
6133 | 2002-06-18 Akim Demaille <akim@epita.fr> |
6134 | ||
6135 | * src/symtab.h, src/symtab.c (symbol_t): destructor_location is a | |
6136 | new member. | |
6137 | (symbol_destructor_set): Adjust. | |
6138 | * src/output.c (symbol_destructors_output): Output the destructor | |
6139 | locations. | |
6140 | Output the symbol name. | |
6141 | * data/bison.simple (b4_symbol_destructor): Adjust. | |
6142 | ||
5719c109 AD |
6143 | 2002-06-18 Cris Bailiff <c.bailiff@awayweb.com> |
6144 | and Akim Demaille <akim@epita.fr> | |
6145 | ||
6146 | * data/bison.simple.new (yyerrlab1): Be sure to pop and destroy | |
6147 | what's left on the stack when the error recovery hits EOF. | |
6148 | * tests/actions.at (Destructors): Complete to exercise this case. | |
6149 | ||
9280d3ef AD |
6150 | 2002-06-17 Akim Demaille <akim@epita.fr> |
6151 | ||
6152 | * data/m4sugar/m4sugar.m4 (m4_map): Recognize when the list of | |
6153 | arguments is really empty, not only equal to `[]'. | |
6154 | * src/symtab.h, src/symtab.c (symbol_t): `destructor' is a new | |
6155 | member. | |
6156 | (symbol_destructor_set): New. | |
6157 | * src/output.c (symbol_destructors_output): New. | |
6158 | * src/reader.h (brace_code_t, current_braced_code): New. | |
6159 | * src/scan-gram.l (BRACED_CODE): Use it to branch on... | |
6160 | (handle_dollar): Rename as... | |
6161 | (handle_action_dollar): this. | |
6162 | (handle_destructor_dollar): New. | |
6163 | * src/parse-gram.y (PERCENT_DESTRUCTOR): New. | |
6164 | (grammar_declaration): Use it. | |
6165 | * data/bison.simple (yystos): Is always defined. | |
6166 | (yydestructor): New. | |
6167 | * tests/actions.at (Destructors): New. | |
6168 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Don't rely on egrep. | |
6169 | ||
dafdc66f AD |
6170 | 2002-06-17 Akim Demaille <akim@epita.fr> |
6171 | ||
6172 | * src/symlist.h, src/symlist.c (symbol_list_length): New. | |
6173 | * src/scan-gram.l (handle_dollar, handle_at): Compute the | |
6174 | rule_length only when needed. | |
6175 | * src/output.c (actions_output, token_definitions_output): Output | |
6176 | the full M4 block. | |
6177 | * src/symtab.c: Don't access directly to the symbol tag, use | |
6178 | symbol_tag_get. | |
6179 | * src/parse-gram.y: Use symbol_list_free. | |
6180 | ||
56c47203 AD |
6181 | 2002-06-17 Akim Demaille <akim@epita.fr> |
6182 | ||
6183 | * src/reader.h, src/reader.c (symbol_list, symbol_list_new) | |
6184 | (symbol_list_prepend, get_type_name): Move to... | |
6185 | * src/symlist.h, src/symlist.c (symbol_list_t, symbol_list_new) | |
6186 | (symbol_list_prepend, symbol_list_n_type_name_get): here. | |
6187 | Adjust all callers. | |
6188 | (symbol_list_free): New. | |
6189 | * src/scan-gram.l (handle_dollar): Takes a location. | |
6190 | * tests/input.at (Invalid $n): Adjust. | |
6191 | ||
1e0bab92 AD |
6192 | 2002-06-17 Akim Demaille <akim@epita.fr> |
6193 | ||
6194 | * src/reader.h, src/reader.c (symbol_list_new): Export it. | |
6195 | (symbol_list_prepend): New. | |
6196 | * src/parse-gram.y (%union): `list' is a new member. | |
6197 | (symbols.1): New, replaces... | |
6198 | (terms_to_prec.1, nterms_to_type.1): these. | |
6199 | * src/symtab.h, src/symtab.c (symbol_type_set, symbol_precedence_set) | |
6200 | Take a location as additional argument. | |
6201 | Adjust all callers. | |
6202 | ||
04e60654 AD |
6203 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6204 | ||
6205 | * src/parse-gram.y: Move %token in the declaration section so that | |
6206 | we don't depend upon CVS Bison. | |
6207 | ||
10e5b8bd AD |
6208 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6209 | ||
6210 | * src/state.h, src/state.c (state_rule_lookaheads_print): New. | |
6211 | * src/print.c (print_core): Use it. | |
6212 | ||
9801d40c AD |
6213 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6214 | ||
6215 | * src/conflicts.c (log_resolution): Accept the rule involved in | |
6216 | the sr conflicts instead of the lookahead number that points to | |
6217 | that rule. | |
6218 | (flush_reduce): Accept the current lookahead vector as argument, | |
6219 | instead of the index in LA. | |
6220 | (resolve_sr_conflict): Accept the current number of lookahead | |
6221 | bitset to consider for the STATE, instead of the index in LA. | |
6222 | (set_conflicts): Adjust. | |
6223 | * src/lalr.c, src/lalr.h, src/state.h: Comment changes. | |
6224 | ||
c0263492 AD |
6225 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6226 | ||
6227 | * src/state.h (state_t): Replace the `lookaheadsp' member, a | |
6228 | short, with `lookaheads' (bitsetv), `lookaheads_rule' (rule_t**). | |
6229 | Adjust all dependencies. | |
6230 | * src/lalr.c (initialize_lookaheads): Split into... | |
6231 | (states_lookaheads_count, states_lookaheads_initialize): these. | |
6232 | (lalr): Adjust. | |
6233 | ||
9757c359 AD |
6234 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6235 | ||
6236 | * src/gram.h, src/gram.c (grammar_rules_partial_print): New, eved | |
6237 | out of... | |
6238 | (grammar_rules_print): here. | |
6239 | * src/reduce.c (reduce_output): Use it. | |
6240 | * tests/reduce.at (Useless Rules, Reduced Automaton) | |
6241 | (Underivable Rules): Adjust. | |
6242 | ||
6b98e4b5 AD |
6243 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6244 | ||
6245 | Copy BYacc's nice way to report the grammar. | |
6246 | ||
6247 | * src/gram.h, src/gram.c (grammar_rhs_print, grammar_rules_print): | |
6248 | New. | |
6249 | Don't print the rules' location, it is confusing and useless. | |
6250 | (rule_print): Use grammar_rhs_print. | |
6251 | * src/print.c (print_grammar): Use grammar_rules_print. | |
6252 | ||
6b98e4b5 AD |
6253 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6254 | ||
6255 | Complete and rationalize `useless thing' warnings. | |
6256 | ||
6257 | * src/symtab.h, src/symtab.c (symbol_tag_get, symbol_tag_get_n) | |
6258 | (symbol_tag_print): New. | |
6259 | Use them everywhere in place of accessing directly the tag member. | |
6260 | * src/gram.h, src/gram.c (rule_print): New. | |
6261 | Use it where a rule used to be printed `by hand'. | |
6262 | * src/reduce.c (nonterminals_reduce): Report the use nonterminals. | |
6263 | (reduce_grammar_tables): Report the useless rules. | |
6264 | (reduce_print): Useless things are a warning, not an error. | |
6265 | Report it as such. | |
6266 | * tests/reduce.at (Useless Nonterminals, Useless Rules): | |
6267 | (Reduced Automaton, Underivable Rules): Adjust. | |
6268 | * tests/regression.at (Web2c Report, Web2c Report): Adjust. | |
6269 | * tests/conflicts.at (Unresolved SR Conflicts) | |
6270 | (Solved SR Conflicts): Adjust. | |
6271 | ||
ee000ba4 AD |
6272 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6273 | ||
6274 | Let symbols have a location. | |
6275 | ||
6276 | * src/symtab.h, src/symtab.c (symbol_t): Location is a new member. | |
6277 | (getsym): Adjust. | |
6278 | Adjust all callers. | |
6279 | * src/complain.h, src/complain.c (complain_at, fatal_at, warn_at): | |
6280 | Use location_t, not int. | |
6281 | * src/symtab.c (symbol_check_defined): Take advantage of the | |
6282 | location. | |
6283 | * tests/regression.at (Invalid inputs): Adjust. | |
6284 | ||
8efe435c AD |
6285 | 2002-06-15 Akim Demaille <akim@epita.fr> |
6286 | ||
6287 | * src/parse-gram.y (YYLLOC_DEFAULT, current_lhs_location): New. | |
6288 | (input): Don't try to initialize yylloc here, do it in the | |
6289 | scanner. | |
6290 | * src/scan-gram.l (YY_USER_INIT): Initialize yylloc. | |
6291 | * src/gram.h (rule_t): Change line and action_line into location | |
6292 | and action_location, of location_t type. | |
6293 | Adjust all dependencies. | |
6294 | * src/location.h, src/location.c (empty_location): New. | |
6295 | * src/reader.h, src/reader.c (grammar_start_symbol_set) | |
6296 | (grammar_symbol_append, grammar_rule_begin, grammar_rule_end) | |
6297 | (grammar_current_rule_symbol_append) | |
6298 | (grammar_current_rule_action_append): Expect a location as argument. | |
6299 | * src/reader.c (grammar_midrule_action): Adjust to attach an | |
6300 | action's location as dummy symbol location. | |
6301 | * src/symtab.h, src/symtab.c (startsymbol_location): New. | |
6302 | * tests/regression.at (Web2c Report, Rule Line Numbers): Adjust | |
6303 | the line numbers. | |
6304 | ||
1921f1d7 AD |
6305 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6306 | ||
6307 | Grammar declarations may be found in the grammar section. | |
6308 | ||
6309 | * src/parse-gram.y (rules_or_grammar_declaration): New. | |
6310 | (declarations): Each declaration may end with a semicolon, not | |
6311 | just... | |
6312 | (grammar_declaration): `"%union"'. | |
6313 | (grammar): Branch to rules_or_grammar_declaration. | |
6314 | ||
4515534c AD |
6315 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6316 | ||
6317 | * src/main.c (main): Invoke scanner_free. | |
6318 | ||
f958596b AD |
6319 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6320 | ||
6321 | * src/output.c (m4_invoke): Extracted from... | |
6322 | (output_skeleton): here. | |
6323 | Free tempfile. | |
6324 | ||
2c569025 AD |
6325 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6326 | ||
6327 | * src/parse-gram.y (directives, directive, gram) | |
6328 | (grammar_directives, precedence_directives, precedence_directive): | |
6329 | Rename as... | |
6330 | (declarations, declaration, grammar, grammar_declaration) | |
6331 | (precedence_declaration, precedence_declarator): these. | |
6332 | (symbol_declaration): New. | |
6333 | ||
592e8d4d AD |
6334 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6335 | ||
6336 | * src/files.c (action_obstack): Remove, unused. | |
6337 | (output_obstack): Remove it, and all its dependencies, as it is no | |
6338 | longer needed. | |
6339 | * src/reader.c (epilogue_set): Build the epilogue in the | |
6340 | muscle_obstack. | |
6341 | * src/output.h, src/output.c (muscle_obstack): Move to... | |
6342 | * src/muscle_tab.h, src/muscle_tab.h: here. | |
6343 | (muscle_init): Initialize muscle_obstack. | |
6344 | (muscle_free): New. | |
6345 | * src/main.c (main): Call it. | |
6346 | ||
0c15323d AD |
6347 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6348 | ||
6349 | * src/location.h: New, extracted from... | |
6350 | * src/reader.h: here. | |
6351 | * src/Makefile.am (noinst_HEADERS): Merge into | |
6352 | (bison_SOURCES): this. | |
6353 | Add location.h. | |
6354 | * src/parse-gram.y: Use location_t instead of Bison's. | |
6355 | * src/reader.h, src/reader.c (prologue_augment, epilogue_set): | |
6356 | Use location_t instead of ints. | |
6357 | ||
e96c9728 AD |
6358 | 2002-06-14 Akim Demaille <akim@epita.fr> |
6359 | ||
6360 | * data/bison.simple, data/bison.c++: Be sure to restore the | |
6361 | current #line when returning to the skeleton contents after having | |
6362 | exposed the input file's #line. | |
6363 | ||
75d1fe16 AD |
6364 | 2002-06-12 Akim Demaille <akim@epita.fr> |
6365 | ||
6366 | * src/scan-gram.l (SC_BRACED_CODE): Don't use `<.*>', it is too | |
6367 | eager. | |
6368 | * tests/actions.at (Exotic Dollars): New. | |
6369 | ||
6c35d22c AD |
6370 | 2002-06-12 Akim Demaille <akim@epita.fr> |
6371 | ||
6372 | * src/scan-gram.l (SC_PROLOGUE): Don't eat characters amongst | |
6373 | ['"/] too eagerly. | |
6374 | * tests/input.at (Torturing the Scanner): New. | |
6375 | ||
1d6412ad AD |
6376 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6377 | ||
6378 | * src/scan-gram.l (YY_OBS_INIT): Remove, replace with... | |
6379 | [SC_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE,SC_PROLOGUE] | |
6380 | [SC_EPILOGUE]: Output the quadrigraphs only when not in a comment. | |
6381 | * src/reader.h, src/scan-gram.l (scanner_initialize): this. | |
6382 | * src/reader.c (reader): Use it. | |
6383 | ||
4cdb01db AD |
6384 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6385 | ||
6386 | * src/scan-gram.l (YY_OBS_FINISH): Don't set yylval. | |
6387 | Adjust all callers. | |
6388 | (scanner_last_string_free): New. | |
6389 | ||
44995b2e AD |
6390 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6391 | ||
6392 | * src/scan-gram.l (YY_INIT, YY_GROW, YY_FINISH): Rename as... | |
6393 | (YY_OBS_INIT, YY_OBS_GROW, YY_OBS_FINISH): these. | |
6394 | (last_string, YY_OBS_FREE): New. | |
6395 | Use them when returning an ID. | |
6396 | ||
e9955c83 AD |
6397 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6398 | ||
6399 | Have Bison grammars parsed by a Bison grammar. | |
6400 | ||
6401 | * src/reader.c, src/reader.h (prologue_augment): New. | |
6402 | * src/reader.c (copy_definition): Remove. | |
6403 | ||
6404 | * src/reader.h, src/reader.c (gram_start_symbol_set, prologue_augment) | |
6405 | (grammar_symbol_append, grammar_rule_begin, grammar_midrule_action) | |
6406 | (grammar_current_rule_prec_set, grammar_current_rule_check) | |
6407 | (grammar_current_rule_symbol_append) | |
6408 | (grammar_current_rule_action_append): Export. | |
6409 | * src/parse-gram.y (symbol_list_new, symbol_list_symbol_append_ | |
6410 | (symbol_list_action_append): Remove. | |
6411 | Hook the routines from reader. | |
6412 | * src/scan-gram.l: In INITIAL, characters and strings are tokens. | |
6413 | * src/system.h (ATTRIBUTE_NORETURN, ATTRIBUTE_UNUSED): Now. | |
6414 | ||
6415 | * src/reader.c (read_declarations): Remove, unused. | |
6416 | ||
6417 | * src/parse-gram.y: Handle the epilogue. | |
6418 | * src/reader.h, src/reader.c (gram_start_symbol_set): Rename as... | |
6419 | (grammar_start_symbol_set): this. | |
6420 | * src/scan-gram.l: Be sure to ``use'' yycontrol to keep GCC quiet. | |
6421 | * src/reader.c (readgram): Remove, unused. | |
6422 | (reader): Adjust to insert eoftoken and axiom where appropriate. | |
6423 | ||
6424 | * src/reader.c (copy_dollar): Replace with... | |
6425 | * src/scan-gram.h (handle_dollar): this. | |
6426 | * src/parse-gram.y: Remove `%thong'. | |
6427 | ||
6428 | * src/reader.c (copy_at): Replace with... | |
6429 | * src/scan-gram.h (handle_at): this. | |
6430 | ||
6431 | * src/complain.h, src/complain.c (warn_at, complain_at, fatal_at): | |
6432 | New. | |
6433 | ||
6434 | * src/scan-gram.l (YY_LINES): Keep lineno synchronized for the | |
6435 | time being. | |
6436 | ||
6437 | * src/reader.h, src/reader.c (grammar_rule_end): New. | |
6438 | ||
6439 | * src/parse.y (current_type, current_class): New. | |
6440 | Implement `%nterm', `%token' support. | |
6441 | Merge `%term' into `%token'. | |
6442 | (string_as_id): New. | |
6443 | * src/symtab.h, src/symtab.c (symbol_make_alias): Don't pass the | |
6444 | type name. | |
6445 | ||
6446 | * src/parse-gram.y: Be sure to handle properly the beginning of | |
6447 | rules. | |
6448 | ||
6449 | * src/parse-gram.y: Handle %type. | |
6450 | * src/reader.c (grammar_rule_end): Call grammar_current_rule_check. | |
6451 | ||
6452 | * src/parse-gram.y: More directives support. | |
6453 | * src/options.c: No longer handle source directives. | |
6454 | ||
6455 | * src/parse-gram.y: Fix %output. | |
6456 | ||
6457 | * src/parse-gram.y: Handle %union. | |
6458 | Use the prologue locations. | |
6459 | * src/reader.c (parse_union_decl): Remove. | |
6460 | ||
6461 | * src/reader.h, src/reader.c (epilogue_set): New. | |
6462 | * src/parse-gram.y: Use it. | |
6463 | ||
6464 | * data/bison.simple, data/bison.c++: b4_stype is now either not | |
6465 | defined, then default to int, or to the contents of %union, | |
6466 | without `union' itself. | |
6467 | Adjust. | |
6468 | * src/muscle_tab.c (muscle_init): Don't predefine `stype'. | |
6469 | ||
6470 | * src/output.c (actions_output): Don't output braces, as they are | |
6471 | already handled by the scanner. | |
6472 | ||
6473 | * src/scan-gram.l (SC_CHARACTER): Set the user_token_number of | |
6474 | characters to themselves. | |
6475 | ||
6476 | * tests/reduce.at (Reduced Automaton): End the grammars with %% so | |
6477 | that the epilogue has a proper #line. | |
6478 | ||
6479 | * src/parse-gram.y: Handle precedence/associativity. | |
6480 | ||
6481 | * src/symtab.c (symbol_precedence_set): Requires the symbol to be | |
6482 | a terminal. | |
6483 | * src/scan-gram.l (SC_BRACED_CODE): Catch strings and characters. | |
6484 | * tests/calc.at: Do not use `%token "foo"' as it makes not sense | |
6485 | at all to define terminals that cannot be emitted. | |
6486 | ||
6487 | * src/scan-gram.l: Escape M4 characters. | |
6488 | ||
6489 | * src/scan-gram.l: Working properly with escapes in user | |
6490 | strings/characters. | |
6491 | ||
6492 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR) | |
6493 | (AT_DATA_HORIZONTAL_GRAMMAR): Respect the `%token ID NUM STRING' | |
6494 | grammar. | |
6495 | Use more modest sizes, as for the time being the parser does not | |
6496 | release memory, and therefore the process swallows a huge amount | |
6497 | of memory. | |
6498 | ||
6499 | * tests/torture.at (AT_DATA_LOOKAHEADS_GRAMMAR): Adjust to the | |
6500 | stricter %token grammar. | |
6501 | ||
6502 | * src/symtab.h (associativity): Add `undef_assoc'. | |
6503 | (symbol_precedence_set): Do nothing when passed an undef_assoc. | |
6504 | * src/symtab.c (symbol_check_alias_consistence): Adjust. | |
6505 | ||
6506 | * tests/regression.at (Invalid %directive): Remove, as it is now | |
6507 | meaningless. | |
6508 | (Invalid inputs): Adjust to the new error messages. | |
6509 | (Token definitions): The new grammar doesn't allow too many | |
6510 | eccentricities. | |
6511 | ||
6512 | * src/lex.h, src/lex.c: Remove. | |
6513 | * src/reader.c (lastprec, skip_to_char, read_signed_integer) | |
6514 | (copy_character, copy_string2, copy_string, copy_identifier) | |
6515 | (copy_comment, parse_token_decl, parse_type_decl, parse_assoc_decl) | |
6516 | (parse_muscle_decl, parse_dquoted_param, parse_skel_decl) | |
6517 | (parse_action): Remove. | |
6518 | * po/POTFILES.in: Adjust. | |
6519 | ||
2e047461 AD |
6520 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6521 | ||
cd05d13c | 6522 | * src/reader.c (parse_action): Don't store directly into the |
2e047461 AD |
6523 | rule's action member: return the action as a string. |
6524 | Don't require `rule_length' as an argument: compute it. | |
6525 | (grammar_current_rule_symbol_append) | |
6526 | (grammar_current_rule_action_append): New, eved out from | |
6527 | (readgram): here. | |
6528 | Remove `action_flag', `rulelength', unused now. | |
6529 | ||
9af3fbce AD |
6530 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6531 | ||
6532 | * src/reader.c (grammar_current_rule_prec_set). | |
6533 | (grammar_current_rule_check): New, eved out from... | |
6534 | (readgram): here. | |
6535 | Remove `xaction', `first_rhs': useless. | |
6536 | * tests/input.at (Type clashes): New. | |
6537 | * tests/existing.at (GNU Cim Grammar): Adjust. | |
6538 | ||
1485e106 AD |
6539 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6540 | ||
6541 | * src/reader.c (grammar_midrule_action): New, Eved out from | |
6542 | (readgram): here. | |
6543 | ||
da4160c3 AD |
6544 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6545 | ||
6546 | * src/reader.c (grammar_rule_begin, previous_rule, current_rule): | |
6547 | New. | |
6548 | (readgram): Use them as replacement of inlined code, crule and | |
6549 | crule1. | |
6550 | ||
f6d0f937 AD |
6551 | 2002-06-11 Akim Demaille <akim@epita.fr> |
6552 | ||
6553 | * src/reader.c (grammar_end, grammar_symbol_append): New. | |
6554 | (readgram): Use them. | |
6555 | Make the use of `p' as local as possible. | |
6556 | ||
69078d4b AD |
6557 | 2002-06-10 Akim Demaille <akim@epita.fr> |
6558 | ||
6559 | GCJ's parser requires the tokens to be defined before the prologue. | |
6560 | ||
6561 | * data/bison.simple: Output the token definition before the user's | |
6562 | prologue. | |
6563 | * tests/regression.at (Braces parsing, Duplicate string) | |
6564 | (Mixing %token styles): Check the output from bison. | |
6565 | (Early token definitions): New. | |
6566 | ||
5e424082 AD |
6567 | 2002-06-10 Akim Demaille <akim@epita.fr> |
6568 | ||
6569 | * src/symtab.c (symbol_user_token_number_set): Don't complain when | |
6570 | assigning twice the same user number to a token, so that we can | |
6571 | use it in... | |
6572 | * src/lex.c (lex): here. | |
6573 | Also use `symbol_class_set' instead of hand written code. | |
6574 | * src/reader.c (parse_assoc_decl): Likewise. | |
6575 | ||
44536b35 AD |
6576 | 2002-06-10 Akim Demaille <akim@epita.fr> |
6577 | ||
6578 | * src/symtab.c, src/symtab.c (symbol_class_set) | |
6579 | (symbol_user_token_number_set): New. | |
6580 | * src/reader.c (parse_token_decl): Use them. | |
6581 | Use a switch instead of ifs. | |
6582 | Use a single argument. | |
6583 | ||
8b9f2372 AD |
6584 | 2002-06-10 Akim Demaille <akim@epita.fr> |
6585 | ||
6586 | Remove `%thong' support as it is undocumented, unused, duplicates | |
6587 | `%token's job, and creates useless e-mail traffic with people who | |
6588 | want to know what it is, why it is undocumented, unused, and | |
6589 | duplicates `%token's job. | |
6590 | ||
6591 | * src/reader.c (parse_thong_decl): Remove. | |
6592 | * src/options.c (option_table): Remove "thong". | |
6593 | * src/lex.h (tok_thong): Remove. | |
6594 | ||
3ae2b51f AD |
6595 | 2002-06-10 Akim Demaille <akim@epita.fr> |
6596 | ||
6597 | * src/symtab.c, src/symtab.c (symbol_type_set) | |
6598 | (symbol_precedence_set): New. | |
6599 | * src/reader.c (parse_type_decl, parse_assoc_decl): Use them. | |
6600 | (value_components_used): Remove, unused. | |
6601 | ||
2f1afb73 AD |
6602 | 2002-06-09 Akim Demaille <akim@epita.fr> |
6603 | ||
6604 | Move symbols handling code out of the reader. | |
6605 | ||
6606 | * src/reader.h, src/reader.c (errtoken, undeftoken, eoftoken) | |
6607 | (axiom): Move to... | |
6608 | * src/symtab.h, src/symtab.c: here. | |
6609 | ||
6610 | * src/gram.c (start_symbol): Remove: use startsymbol->number. | |
6611 | * src/reader.c (startval): Rename as... | |
6612 | * src/symtab.h, src/symtab.c (startsymbol): this. | |
6613 | * src/reader.c: Adjust. | |
6614 | ||
6615 | * src/reader.c (symbol_check_defined, symbol_make_alias) | |
6616 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
6617 | (token_translations_init) | |
6618 | Move to... | |
6619 | * src/symtab.c: here. | |
6620 | * src/reader.c (packsymbols): Move to... | |
6621 | * src/symtab.h, src/symtab.c (symbols_pack): here. | |
6622 | * src/symtab.h, src/symtab.c (symbol_make_alias): Takes SYMVAL as | |
6623 | argument. | |
6624 | ||
e9bca3ad AD |
6625 | 2002-06-03 Akim Demaille <akim@epita.fr> |
6626 | ||
6627 | * src/muscle_tab.c (muscle_insert, muscle_find): Declarations, | |
6628 | then statements. | |
6629 | ||
86eff183 AD |
6630 | 2002-06-03 Akim Demaille <akim@epita.fr> |
6631 | ||
6632 | * src/muscle_tab.c (muscle_find, muscle_insert): Don't initialize | |
6633 | structs with non literals. | |
6634 | * src/scan-skel.l: never-interactive. | |
6635 | * src/conflicts.c (enum conflict_resolution_e): No trailing | |
6636 | comma. | |
6637 | * src/getargs.c (usage): Split long literal strings. | |
6638 | Reported by Hans Aberg. | |
6639 | ||
717be197 AD |
6640 | 2002-05-28 Akim Demaille <akim@epita.fr> |
6641 | ||
6642 | * data/bison.c++: Use C++ ostreams. | |
6643 | (cdebug_): New member. | |
6644 | ||
670ddffd AD |
6645 | 2002-05-28 Akim Demaille <akim@epita.fr> |
6646 | ||
6647 | * src/output.c (output_skeleton): Be sure to allocate enough room | |
6648 | for `/' _and_ for `\0' in full_skeleton. | |
6649 | ||
769b430f AD |
6650 | 2002-05-28 Akim Demaille <akim@epita.fr> |
6651 | ||
6652 | * data/bison.c++: Catch up with bison.simple: | |
6653 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
6654 | and Paul Eggert <eggert@twinsun.com>: `error' handing. | |
6655 | 2002-05-26 Akim Demaille <akim@epita.fr>: stos_, token_number_, | |
6656 | and popping traces. | |
6657 | ||
7067cb36 PH |
6658 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
6659 | ||
6660 | * src/output.c (output_skeleton): Put an explicit path in front of | |
6661 | the skeleton file name, rather than relying on the -I directory, | |
6662 | to partially alleviate effects of having a skeleton file lying around | |
6663 | in the current directory. | |
769b430f | 6664 | |
4a713ec2 PH |
6665 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
6666 | ||
769b430f | 6667 | * src/conflicts.c (log_resolution): Correct typo: |
4a713ec2 PH |
6668 | obstack_printf should be obstack_fgrow1. |
6669 | ||
b408954b AD |
6670 | 2002-05-26 Akim Demaille <akim@epita.fr> |
6671 | ||
6672 | * src/state.h (state_t): `solved_conflicts' is a new member. | |
6673 | * src/LR0.c (new_state): Set it to 0. | |
6674 | * src/conflicts.h, src/conflicts.c (print_conflicts) | |
6675 | (free_conflicts, solve_conflicts): Rename as... | |
6676 | (conflicts_print, conflicts_free, conflicts_solve): these. | |
6677 | Adjust callers. | |
6678 | * src/conflicts.c (enum conflict_resolution_e) | |
6679 | (solved_conflicts_obstack): New, used by... | |
6680 | (log_resolution): this. | |
6681 | Adjust to attach the conflict resolution to each state. | |
6682 | Complete the description with the precedence/associativity | |
6683 | information. | |
6684 | (resolve_sr_conflict): Adjust. | |
6685 | * src/print.c (print_state): Output its solved_conflicts. | |
6686 | * tests/conflicts.at (Unresolved SR Conflicts) | |
6687 | (Solved SR Conflicts): Exercise --report=all. | |
6688 | ||
a49aecd5 AD |
6689 | 2002-05-26 Akim Demaille <akim@epita.fr> |
6690 | ||
6691 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
6692 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
6693 | * src/reader.c, src/reduce.c, src/state.h, src/symtab.h | |
6694 | (token_number_t, item_number_as_token_number) | |
6695 | (token_number_as_item_number, muscle_insert_token_number_table): | |
6696 | Rename as... | |
6697 | (symbol_number_t, item_number_as_symbol_number) | |
6698 | (symbol_number_as_item_number, muscle_insert_symbol_number_table): | |
6699 | these, since it is more appropriate. | |
6700 | ||
5504898e AD |
6701 | 2002-05-26 Akim Demaille <akim@epita.fr> |
6702 | ||
6703 | * tests/calc.at (AT_CHECK_CALC): Adjust: there are now additional | |
6704 | `Error:' lines. | |
6705 | * data/bison.simple (yystos) [YYDEBUG]: New. | |
6706 | (yyparse) [YYDEBUG]: Display the symbols which are popped during | |
6707 | error recovery. | |
6708 | * tests/regression.at (Web2c Actions): Adjust: yystos is output now. | |
6709 | ||
ec3bc396 AD |
6710 | 2002-05-25 Akim Demaille <akim@epita.fr> |
6711 | ||
6712 | * doc/bison.texinfo (Debugging): Split into... | |
6713 | (Tracing): this new section, its former contents, and... | |
6714 | (Understanding): this new section. | |
6715 | * src/getargs.h, src/getargs.c (verbose_flag): Remove, replaced | |
6716 | by... | |
6717 | (report_flag): this. | |
6718 | Adjust all dependencies. | |
6719 | (report_args, report_types, report_argmatch): New. | |
6720 | (usage, getargs): Report/support -r, --report. | |
6721 | * src/options.h | |
6722 | (struct option_table_struct): Rename as.., | |
6723 | (struct option_table_s): this. | |
6724 | Rename the `set_flag' member to `flag' to match with getopt_long's | |
6725 | struct. | |
6726 | * src/options.c (option_table): Split verbose into an entry for | |
6727 | %verbose, and another for --verbose. | |
6728 | Support --report/-r, so remove -r from the obsolete --raw. | |
6729 | * src/print.c: Attach full item sets and lookaheads reports to | |
6730 | report_flag instead of trace_flag. | |
6731 | * lib/argmatch.h, lib/argmatch.c: New, from Fileutils 4.1. | |
6732 | ||
78df8250 PE |
6733 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
6734 | and Paul Eggert <eggert@twinsun.com> | |
769b430f | 6735 | |
78df8250 PE |
6736 | * data/bison.simple (yyparse): Correct error handling to conform to |
6737 | POSIX and yacc. Specifically, after syntax error is discovered, | |
6738 | do not reduce further before shifting the error token. | |
6739 | Clean up the code a bit by removing the labels yyerrdefault, | |
6740 | yyerrhandle, yyerrpop. | |
6741 | * NEWS: Document the above. | |
6742 | ||
c0c9ea05 PH |
6743 | 2002-05-20 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
6744 | ||
6745 | * data/bison.simple (yyr1): Don't use yy_token_number_type as element | |
6746 | type; it isn't always big enough, since it doesn't necessarily | |
6747 | include non-terminals. | |
769b430f | 6748 | (yytranslate): Expand definition of yy_token_number_type, so that |
c0c9ea05 PH |
6749 | the latter can be removed. |
6750 | (yy_token_number_type): Remove, only one use. | |
6751 | * data/bison.c++ (r1_): Parallel change to yyr1 in bison.simple--- | |
6752 | don't use TokenNumberType as element type. | |
769b430f | 6753 | |
c0c9ea05 PH |
6754 | * tests/regression.at: Modify expected output to agree with change |
6755 | to yyr1 and yytranslate. | |
769b430f | 6756 | |
6390a83f FK |
6757 | 2002-05-13 Florian Krohm <florian@edamail.fishkill.ibm.com> |
6758 | ||
6759 | * src/reader.c (parse_action): Use copy_character instead of | |
6760 | obstack_1grow. | |
6761 | ||
db7c8e9a AD |
6762 | 2002-05-13 Akim Demaille <akim@epita.fr> |
6763 | ||
6764 | * tests/regression.at (Token definitions): Prototype yylex and | |
6765 | yyerror. | |
6766 | ||
fcc61800 PH |
6767 | 2002-05-12 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> |
6768 | ||
158c687b | 6769 | * src/scan-skel.l: Correct off-by-one error in handling of __oline__. |
fcc61800 PH |
6770 | * data/bison.simple (b4_sint_type, b4_uint_type): Correct to reflect |
6771 | 32-bit arithmetic. | |
6772 | * data/bison.c++ (b4_sint_type, b4_uint_type): Ditto. | |
6773 | ||
5683e9b2 AD |
6774 | 2002-05-07 Akim Demaille <akim@epita.fr> |
6775 | ||
6776 | * tests/synclines.at: Be sure to prototype yylex and yyerror to | |
6777 | avoid GCC warnings. | |
6778 | ||
0c2d3f4c AD |
6779 | 2002-05-07 Akim Demaille <akim@epita.fr> |
6780 | ||
6781 | Kill GCC warnings. | |
6782 | ||
6783 | * src/reduce.c (nonterminals_reduce): Don't loop over RITEM: loop | |
6784 | over the RHS of each rule. | |
6785 | * src/gram.h, src/gram.c (nritems): Is `unsigned int', not int. | |
6786 | * src/state.h (state_t): Member `nitems' is unsigned short. | |
6787 | * src/LR0.c (get_state): Adjust. | |
6788 | * src/reader.c (packgram): Likewise. | |
6789 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): `max' is of type | |
6790 | `Type'. | |
6791 | (muscle_insert_int_table): Remove, unused. | |
6792 | (prepare_rules): Remove `max'. | |
6793 | ||
1565b720 AD |
6794 | 2002-05-06 Akim Demaille <akim@epita.fr> |
6795 | ||
6796 | * src/closure.c (print_firsts): Display of the symbol tags. | |
6797 | (bitmatrix_print): Move to... | |
6798 | * lib/bitsetv-print.h, lib/bitsetv-print.c (bitsetv_matrix_dump): | |
6799 | here. | |
6800 | * tests/sets.at (Nullable, Broken Closure, Firsts): Adjust. | |
6801 | ||
cfaee611 AD |
6802 | 2002-05-06 Akim Demaille <akim@epita.fr> |
6803 | ||
6804 | * src/muscle_tab.c (muscle_m4_output): Must return TRUE for | |
6805 | hash_do_for_each. | |
6806 | ||
458be8e0 AD |
6807 | 2002-05-06 Akim Demaille <akim@epita.fr> |
6808 | ||
6809 | * src/LR0.c (new_state, get_state): Instead of using the global | |
6810 | `kernel_size' and `kernel_base', have two new arguments: | |
6811 | `core_size' and `core'. | |
6812 | Adjust callers. | |
6813 | ||
a900a624 AD |
6814 | 2002-05-06 Akim Demaille <akim@epita.fr> |
6815 | ||
6816 | * src/reader.c (packgram): No longer end `ritem' with a 0 | |
6817 | sentinel: it is not used. | |
6818 | ||
d4e7d3a1 AD |
6819 | 2002-05-05 Akim Demaille <akim@epita.fr> |
6820 | ||
6821 | New experimental feature: display the lookaheads in the report and | |
6822 | graph. | |
6823 | ||
6824 | * src/print (print_core): When --trace-flag, display the rules | |
6825 | lookaheads. | |
6826 | * src/print_graph.c (print_core): Likewise. | |
6827 | Swap the arguments. | |
6828 | Adjust caller. | |
6829 | ||
39ceb25b AD |
6830 | 2002-05-05 Akim Demaille <akim@epita.fr> |
6831 | ||
6832 | * tests/torture.at (Many lookaheads): New test. | |
6833 | ||
5372019f AD |
6834 | 2002-05-05 Akim Demaille <akim@epita.fr> |
6835 | ||
6836 | * src/output.c (GENERATE_OUTPUT_TABLE): Replace with... | |
6837 | (GENERATE_MUSCLE_INSERT_TABLE): this. | |
6838 | (output_int_table, output_unsigned_int_table, output_short_table) | |
6839 | (output_token_number_table, output_item_number_table): Replace with... | |
6840 | (muscle_insert_int_table, muscle_insert_unsigned_int_table) | |
6841 | (muscle_insert_short_table, muscle_insert_token_number_table) | |
6842 | (muscle_insert_item_number_table): these. | |
6843 | Adjust all callers. | |
6844 | (prepare_tokens): Don't free `translations', since... | |
6845 | * src/reader.h, src/reader.c (grammar_free): do it. | |
6846 | Move to... | |
6847 | * src/gram.h, src/gram.c (grammar_free): here. | |
6848 | * data/bison.simple, data/bison.c++: b4_token_number_max is now | |
6849 | b4_translate_max. | |
6850 | ||
5df5f6d5 AD |
6851 | 2002-05-05 Akim Demaille <akim@epita.fr> |
6852 | ||
6853 | * src/output.c (output_unsigned_int_table): New. | |
6854 | (prepare_rules): `i' is unsigned. | |
6855 | `prhs', `rline', `r2' are unsigned int. | |
6856 | Rename muscle `rhs_number_max' as `rhs_max'. | |
6857 | Output muscles `prhs_max', `rline_max', and `r2_max'. | |
6858 | Free rline and r1. | |
6859 | * data/bison.simple, data/bison.c++: Adjust to use these muscles | |
6860 | to compute types instead of constant types. | |
6861 | * tests/regression.at (Web2c Actions): Adjust. | |
6862 | ||
b87f8b21 AD |
6863 | 2002-05-04 Akim Demaille <akim@epita.fr> |
6864 | ||
6865 | * src/symtab.h (SALIAS, SUNDEF): Rename as... | |
6866 | (USER_NUMBER_ALIAS, USER_NUMBER_UNDEFINED): these. | |
6867 | Adjust dependencies. | |
6868 | * src/output.c (token_definitions_output): Be sure not to output a | |
6869 | `#define 'a'' when fed with `%token 'a' "a"'. | |
6870 | * tests/regression.at (Token definitions): New. | |
6871 | ||
8bb936e4 PE |
6872 | 2002-05-03 Paul Eggert <eggert@twinsun.com> |
6873 | ||
6874 | * data/bison.simple (b4_token_defines): Also define YYTOKENTYPE | |
6875 | for K&R C. | |
6876 | ||
6877 | 2002-05-03 gettextize <bug-gnu-gettext@gnu.org> | |
6878 | ||
6879 | * Makefile.am (SUBDIRS): Remove intl. | |
6880 | (EXTRA_DIST): Add config/config.rpath. | |
6881 | ||
53c71a12 AD |
6882 | 2002-05-03 Akim Demaille <akim@epita.fr> |
6883 | ||
6884 | * data/bison.simple (m4_if): Don't output empty enums. | |
6885 | And actually, output valid enum definitions :(. | |
6886 | ||
289dd0cf AD |
6887 | 2002-05-03 Akim Demaille <akim@epita.fr> |
6888 | ||
6889 | * configure.bat: Remove, completely obsolete. | |
6890 | * Makefile.am (EXTRA_DIST): Adjust. | |
6891 | Don't distribute config.rpath... | |
6892 | * config/Makefile.am (EXTRA_DIST): Do it. | |
6893 | ||
db85e524 AD |
6894 | 2002-05-03 Akim Demaille <akim@epita.fr> |
6895 | ||
6896 | * configure.in (GETTEXT_VERSION): New. | |
6897 | Suggested by Bruno Haible for the forthcoming Gettext 0.10.3. | |
6898 | ||
83ccf991 AD |
6899 | 2002-05-03 Akim Demaille <akim@epita.fr> |
6900 | ||
6901 | * data/bison.simple (b4_token_enum): New. | |
6902 | (b4_token_defines): Use it to output tokens both as #define and | |
6903 | enums. | |
6904 | Suggested by Paul Eggert. | |
6905 | * src/output.c (token_definitions_output): Don't output spurious | |
6906 | white spaces. | |
6907 | ||
1f418995 AD |
6908 | 2002-05-03 Akim Demaille <akim@epita.fr> |
6909 | ||
6910 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
6911 | ||
45119f04 RA |
6912 | 2002-05-02 Robert Anisko <robert@lrde.epita.fr> |
6913 | ||
6914 | * data/bison.c++: Adapt expansion of $s and @s to the C++ parser. | |
6915 | Update the stack class, give a try to deque as the default container. | |
6916 | ||
b2d52318 AD |
6917 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6918 | ||
6919 | * data/bison.simple (yyparse): Do not implement @$ = @1. | |
6920 | (YYLLOC_DEFAULT): Adjust to do it. | |
6921 | * doc/bison.texinfo (Location Default Action): Fix. | |
6922 | ||
3a8b4109 AD |
6923 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6924 | ||
6925 | * src/reader.c (parse_braces): Merge into... | |
6926 | (parse_action): this. | |
6927 | ||
84614e13 AD |
6928 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6929 | ||
6930 | * configure.in (ALL_LINGUAS): Remove. | |
6931 | * po/LINGUAS, hr.po: New. | |
6932 | ||
fdbcd8e2 AD |
6933 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6934 | ||
6935 | Remove the so called hairy (semantic) parsers. | |
6936 | ||
6937 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove. | |
6938 | * src/gram.h, src/gram.c (semantic_parser): Remove. | |
6939 | (rule_t): Remove the guard and guard_line members. | |
6940 | * src/lex.h (token_t): remove tok_guard. | |
6941 | * src/options.c (option_table): Remove %guard and %semantic_parser | |
6942 | support. | |
6943 | * src/output.c, src/output.h (guards_output): Remove. | |
6944 | (prepare): Adjust. | |
6945 | (token_definitions_output): Don't output the `T' | |
6946 | tokens (???). | |
6947 | (output_skeleton): Don't output the guards. | |
6948 | * src/files.c, src/files.c (attrsfile): Remove. | |
6949 | * src/reader.c (symbol_list): Remove the guard and guard_line | |
6950 | members. | |
6951 | Adjust dependencies. | |
6952 | (parse_guard): Remove. | |
6953 | * data/bison.hairy: Remove. | |
6954 | * doc/bison.texinfo (Environment Variables): Remove occurrences of | |
6955 | BISON_HAIRY. | |
6956 | ||
82b6cb3f AD |
6957 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6958 | ||
6959 | * src/reader.c (copy_at, copy_dollarm parse_braces, parse_action) | |
6960 | (parse_guard): Rename the formal argument `stack_offset' as | |
6961 | `rule_length', which is more readable. | |
6962 | Adjust callers. | |
6963 | (copy_at, copy_dollar): Instead of outputting the hard coded | |
6964 | values of $$, $n and so forth, output invocation to b4_lhs_value, | |
6965 | b4_lhs_location, b4_rhs_value, and b4_rhs_location. | |
900c877b AD |
6966 | Note: this patch partially drops `semantic-parser' support: it |
6967 | always does `rule_length - n', where semantic parsers ought to | |
6968 | always use `-n'. | |
82b6cb3f AD |
6969 | * data/bison.simple, data/bison.c++ (b4_lhs_value) |
6970 | (b4_lhs_location, b4_rhs_value, and b4_rhs_location: New. | |
6971 | ||
6cbfbcc5 AD |
6972 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6973 | ||
6974 | * configure.in (AC_INIT): Bump to 1.49b. | |
6975 | (AM_INIT_AUTOMAKE): Short invocation. | |
6976 | ||
b8548114 AD |
6977 | 2002-05-02 Akim Demaille <akim@epita.fr> |
6978 | ||
6979 | Version 1.49a. | |
6980 | ||
c20cd1fa AD |
6981 | 2002-05-01 Akim Demaille <akim@epita.fr> |
6982 | ||
6983 | * src/skeleton.h: Remove. | |
6984 | ||
8a9566d4 AD |
6985 | 2002-05-01 Akim Demaille <akim@epita.fr> |
6986 | ||
6987 | * src/skeleton.h: Fix the #endif. | |
6988 | Reported by Magnus Fromreide. | |
6989 | ||
8c6d399a PE |
6990 | 2002-04-26 Paul Eggert <eggert@twinsun.com> |
6991 | ||
6992 | * data/bison.simple (YYSTYPE_IS_TRIVIAL, YYLTYPE_IS_TRIVIAL): | |
6993 | Define if we define YYSTYPE and YYLTYPE, respectively. | |
b756bb75 | 6994 | (YYCOPY): Fix [] quoting problem in the non-GCC case. |
8a9566d4 | 6995 | |
2b7ed18a RA |
6996 | 2002-04-25 Robert Anisko <robert@lrde.epita.fr> |
6997 | ||
6998 | * src/scan-skel.l: Postprocess quadrigraphs. | |
6999 | ||
7000 | * src/reader.c (copy_character): New function, used to output | |
7001 | single characters while replacing `[' and `]' with quadrigraphs, to | |
7002 | avoid troubles with M4 quotes. | |
7003 | (copy_comment): Output characters with copy_character. | |
7004 | (read_additionnal_code): Likewise. | |
7005 | (copy_string2): Likewise. | |
7006 | (copy_definition): Likewise. | |
7007 | ||
7008 | * tests/calc.at: Exercise M4 quoting. | |
7009 | ||
34a89c50 AD |
7010 | 2002-04-25 Akim Demaille <akim@epita.fr> |
7011 | ||
7012 | * tests/sets.at (AT_EXTRACT_SETS): Sed portability issue: no space | |
7013 | between `!' and the command. | |
7014 | Reported by Paul Eggert. | |
7015 | ||
0dd1580a RA |
7016 | 2002-04-24 Robert Anisko <robert@lrde.epita.fr> |
7017 | ||
7018 | * tests/calc.at: Exercise prologue splitting. | |
7019 | ||
7020 | * data/bison.simple, data/bison.c++: Use `b4_pre_prologue' and | |
7021 | `b4_post_prologue' instead of `b4_prologue'. | |
7022 | ||
7023 | * src/output.c (prepare): Add the `pre_prologue' and `post_prologue' | |
7024 | muscles. | |
7025 | (output): Free pre_prologue_obstack and post_prologue_obstack. | |
7026 | * src/files.h, src/files.c (attrs_obstack): Remove. | |
7027 | (pre_prologue_obstack, post_prologue_obstack): New. | |
7028 | * src/reader.c (copy_definition): Add a parameter to specify the | |
7029 | obstack to fill, instead of using attrs_obstack unconditionally. | |
7030 | (read_declarations): Pass pre_prologue_obstack to copy_definition if | |
7031 | `%union' has not yet been seen, pass post_prologue_obstack otherwise. | |
7032 | ||
83c1796f PE |
7033 | 2002-04-23 Paul Eggert <eggert@twinsun.com> |
7034 | ||
7035 | * data/bison.simple: Remove unnecessary commentary and white | |
7036 | space differences from 1_29-branch. | |
7037 | Depend on YYERROR_VERBOSE, not defined (YYERROR_VERBOSE). | |
7038 | ||
7039 | (union yyalloc, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYCOPY, | |
7040 | YYSTACK_RELOCATE): Do not define if yyoverflow is defined, or | |
7041 | if this is a C++ parser and YYSTYPE or YYLTYPE has nontrivial | |
7042 | constructors or destructors. | |
7043 | ||
7044 | (yyparse) [! defined YYSTACK_RELOCATE]: Do not relocate the stack. | |
7045 | ||
1207eeac AD |
7046 | 2002-04-23 Akim Demaille <akim@epita.fr> |
7047 | ||
7048 | * tests/sets.at (AT_EXTRACT_SETS): Don't use 8 char long sed labels. | |
7049 | * tests/synclines.at (AT_TEST_SYNCLINE): Be robust to GCC's | |
7050 | location with columns. | |
7051 | * tests/conflicts.at (%nonassoc and eof): Don't use `error.h'. | |
7052 | All reported by Paul Eggert. | |
7053 | ||
78ab8f67 AD |
7054 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7055 | ||
7056 | * src/reduce.c (dump_grammar): Move to... | |
7057 | * src/gram.h, src/gram.c (grammar_dump): here. | |
7058 | Be sure to separate long item numbers. | |
7059 | Don't read the members of a rule's prec if its nil. | |
7060 | ||
133c20e2 AD |
7061 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7062 | ||
7063 | * src/output.c (table_size, table_grow): New. | |
7064 | (MAXTABLE): Remove, replace uses with table_size. | |
7065 | (pack_vector): Instead of dying when the table is too big, grow it. | |
7066 | ||
9515e8a7 AD |
7067 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7068 | ||
7069 | * data/bison.simple (yyr1): Its type is that of a token number. | |
7070 | * data/bison.c++ (r1_): Likewise. | |
7071 | * tests/regression.at (Web2c Actions): Adjust. | |
7072 | ||
23c5a174 AD |
7073 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7074 | ||
7075 | * src/reader.c (token_translations_init): 256 is now the default | |
7076 | value for the error token, i.e., it will be assigned another | |
7077 | number if the user assigned 256 to one of her tokens. | |
7078 | (reader): Don't force 256 to error. | |
7079 | * doc/bison.texinfo (Symbols): Adjust. | |
7080 | * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR) | |
7081 | (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3 | |
7082 | etc. instead of 10, 20, 30 (which was used to `jump' over error | |
7083 | (256) and undefined (2)). | |
7084 | ||
5fbb0954 AD |
7085 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7086 | ||
7087 | Propagate more token_number_t. | |
7088 | ||
7089 | * src/gram.h (token_number_as_item_number) | |
7090 | (item_number_as_token_number): New. | |
7091 | * src/output.c (GENERATE_OUTPUT_TABLE): New. | |
7092 | Use it to create output_item_number_table and | |
7093 | output_token_number_table. | |
7094 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
7095 | * src/lex.c, src/nullable.c, src/output.c, src/print.c, | |
7096 | * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h, | |
7097 | * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts. | |
7098 | ||
4f940944 AD |
7099 | 2002-04-22 Akim Demaille <akim@epita.fr> |
7100 | ||
7101 | * src/output.h, src/output.c (get_lines_number): Remove. | |
7102 | ||
3ded9a63 AD |
7103 | 2002-04-19 Akim Demaille <akim@epita.fr> |
7104 | ||
7105 | * doc/bison.texinfo (Actions): Make clear that `|' is not the same | |
7106 | as Lex/Flex'. | |
7107 | (Debugging): More details about enabling the debugging features. | |
7108 | (Table of Symbols): Describe $$, $n, @$, and @n. | |
7109 | Suggested by Tim Josling. | |
7110 | ||
e0c471a9 AD |
7111 | 2002-04-19 Akim Demaille <akim@epita.fr> |
7112 | ||
7113 | * doc/bison.texinfo: Remove the uses of the obsolete @refill. | |
7114 | ||
fecc10cd AD |
7115 | 2002-04-10 Akim Demaille <akim@epita.fr> |
7116 | ||
7117 | * src/system.h: Rely on HAVE_LIMITS_H. | |
7118 | Suggested by Paul Eggert. | |
7119 | ||
51dec47b AD |
7120 | 2002-04-09 Akim Demaille <akim@epita.fr> |
7121 | ||
7122 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the | |
7123 | full stderr, and strip it according to the bison options, instead | |
7124 | of composing the error message from different bits. | |
7125 | This makes it easier to check for several error messages. | |
7126 | Adjust all the invocations. | |
7127 | Add an invocation exercising the error token. | |
7128 | Add an invocation demonstrating a stupid error message. | |
7129 | (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0. | |
7130 | Adjust the tests. | |
7131 | Error message are for stderr, not stdout. | |
7132 | ||
007a50a4 AD |
7133 | 2002-04-09 Akim Demaille <akim@epita.fr> |
7134 | ||
7135 | * src/gram.h, src/gram.c (error_token_number): Remove, use | |
7136 | errtoken->number. | |
7137 | * src/reader.c (reader): Don't specify the user token number (2) | |
7138 | for $undefined, as it uselessly prevents using it. | |
7139 | * src/gram.h (token_number_t): Move to... | |
7140 | * src/symtab.h: here. | |
7141 | (state_t.number): Is a token_number_t. | |
7142 | * src/print.c, src/reader.c: Use undeftoken->number instead of | |
7143 | hard coded 2. | |
7144 | (Even though this 2 is not the same as above: the number of the | |
7145 | undeftoken remains being 2, it is its user token number which | |
7146 | might not be 2). | |
7147 | * src/output.c (prepare_tokens): Rename the `maxtok' muscle with | |
7148 | `user_token_number_max'. | |
7149 | Output `undef_token_number'. | |
7150 | * data/bison.simple, data/bison.c++: Use them. | |
7151 | Be sure to map invalid yylex return values to | |
7152 | `undef_token_number'. This saves us from gratuitous SEGV. | |
7153 | ||
7154 | * tests/conflicts.at (Solved SR Conflicts) | |
7155 | (Unresolved SR Conflicts): Adjust. | |
7156 | * tests/regression.at (Web2c Actions): Adjust. | |
7157 | ||
06446ccf AD |
7158 | 2002-04-08 Akim Demaille <akim@epita.fr> |
7159 | ||
7160 | * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/. | |
7161 | Adding #line. | |
7162 | Remove the duplicate `typedefs'. | |
7163 | (RhsNumberType): Fix the declaration and various other typos. | |
7164 | Use __ofile__. | |
7165 | * data/bison.simple: Use __ofile__. | |
7166 | * src/scan-skel.l: Handle __ofile__. | |
7167 | ||
62a3e4f0 AD |
7168 | 2002-04-08 Akim Demaille <akim@epita.fr> |
7169 | ||
7170 | * src/gram.h (item_number_t): New, the type of item numbers in | |
7171 | RITEM. Note that it must be able to code symbol numbers as | |
7172 | positive number, and the negation of rule numbers as negative | |
7173 | numbers. | |
7174 | Adjust all dependencies (pretty many). | |
7175 | * src/reduce.c (rule): Remove this `short *' pointer: use | |
7176 | item_number_t. | |
7177 | * src/system.h (MINSHORT, MAXSHORT): Remove. | |
7178 | Include `limits.h'. | |
7179 | Adjust dependencies to using SHRT_MAX and SHRT_MIN. | |
7180 | (shortcpy): Remove. | |
7181 | (MAXTABLE): Move to... | |
7182 | * src/output.c (MAXTABLE): here. | |
7183 | (prepare_rules): Use output_int_table to output rhs. | |
7184 | * data/bison.simple, data/bison.c++: Adjust. | |
7185 | * tests/torture.at (Big triangle): Move the limit from 254 to | |
7186 | 500. | |
7187 | * tests/regression.at (Web2c Actions): Ajust. | |
7188 | ||
7189 | Trying with bigger grammars shows various phenomena: at 3000 (28Mb | |
7190 | of grammar file) bison is killed by my system, at 2000 (12Mb) bison | |
7191 | passes, but produces negative #line number, once fixed, GCC is | |
7192 | killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of | |
7193 | C), it passes. | |
7194 | * src/state.h (state_h): Code input lines on ints, not shorts. | |
7195 | ||
bb88b0fc AD |
7196 | 2002-04-08 Akim Demaille <akim@epita.fr> |
7197 | ||
7198 | * src/reduce.c (reduce_grammar): First reduce the nonterminals, | |
7199 | and then the grammar. | |
7200 | ||
9a636f47 AD |
7201 | 2002-04-08 Akim Demaille <akim@epita.fr> |
7202 | ||
7203 | * src/system.h: No longer using strndup. | |
7204 | ||
680e8701 AD |
7205 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7206 | ||
7207 | * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New. | |
7208 | * src/output.c (output_table_data): Return the longest number. | |
7209 | (prepare_tokens): Output `token_number_max'). | |
7210 | * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type): | |
7211 | New. | |
7212 | Use them to define yy_token_number_type/TokenNumberType. | |
7213 | Use this type for yytranslate. | |
7214 | * tests/torture.at (Big triangle): Push the limit from 124 to | |
7215 | 253. | |
7216 | * tests/regression.at (Web2c Actions): Adjust. | |
7217 | ||
817e9f41 AD |
7218 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7219 | ||
7220 | * tests/torture.at (Big triangle): New. | |
7221 | (GNU AWK Grammar, GNU Cim Grammar): Move to... | |
7222 | * tests/existing.at: here. | |
7223 | ||
5123689b AD |
7224 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7225 | ||
7226 | * src/gram.h, src/gram.c (nitems): Remove, it is an alias of | |
7227 | nritems. | |
7228 | Adjust dependencies. | |
7229 | ||
f3849179 AD |
7230 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7231 | ||
7232 | * src/reader.c: Normalize increments to prefix form. | |
7233 | ||
bd02036a AD |
7234 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7235 | ||
7236 | * src/reader.c, symtab.c: Remove debugging code. | |
7237 | ||
db8837cb AD |
7238 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7239 | ||
7240 | Rename all the `bucket's as `symbol_t'. | |
7241 | ||
7242 | * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c, | |
7243 | * src/reader.c, src/reader.h, src/reduce.c, src/state.h, | |
7244 | * src/symtab.c, src/symtab.h (bucket): Rename as... | |
7245 | (symbol_t): this. | |
7246 | (symbol_list_new, bucket_check_defined, bucket_make_alias) | |
7247 | (bucket_check_alias_consistence, bucket_pack, bucket_translation) | |
7248 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
7249 | (buckets_new, buckets_free, buckets_do): Rename as... | |
7250 | (symbol_list_new, symbol_check_defined, symbol_make_alias) | |
7251 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
7252 | (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t) | |
7253 | (symbols_new, symbols_free, symbols_do): these. | |
7254 | ||
72a23c97 AD |
7255 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7256 | ||
7257 | Use lib/hash for the symbol table. | |
7258 | ||
7259 | * src/gram.c (ntokens): Initialize to 1, to reserve a slot for | |
7260 | EOF. | |
7261 | * src/lex.c (lex): Set the `number' member of new terminals. | |
7262 | * src/reader.c (bucket_check_defined, bucket_make_alias) | |
7263 | (bucket_check_alias_consistence, bucket_translation): New. | |
7264 | (reader, grammar_free, readgram, token_translations_init) | |
7265 | (packsymbols): Adjust. | |
7266 | (reader): Number the predefined tokens. | |
7267 | * src/reduce.c (inaccessable_symbols): Just use hard coded numbers | |
7268 | for predefined tokens. | |
7269 | * src/symtab.h (bucket): Remove all the hash table related | |
7270 | members. | |
7271 | * src/symtab.c (symtab): Replace by... | |
7272 | (bucket_table): this. | |
7273 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
7274 | (buckets_new, buckets_do): New. | |
7275 | ||
280a38c3 AD |
7276 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7277 | ||
7278 | * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems) | |
7279 | (start_symbol, max_user_token_number, semantic_parser) | |
7280 | (error_token_number): Initialize. | |
7281 | * src/reader.c (grammar, start_flag, startval, typed, lastprec): | |
7282 | Initialize. | |
7283 | (reader): Don't. | |
7284 | (errtoken, eoftoken, undeftoken, axiom): Extern. | |
7285 | ||
03b31c0c AD |
7286 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7287 | ||
7288 | * src/gram.h (rule_s): prec and precsym are now pointers | |
7289 | to the bucket giving the priority/associativity. | |
7290 | Member `associativity' removed: useless. | |
7291 | * src/reduce.c, src/conflicts.c: Adjust. | |
7292 | ||
8b3df748 AD |
7293 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7294 | ||
7295 | * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c: | |
7296 | Properly escape the symbols' TAG when outputting them. | |
7297 | ||
e601aa1d AD |
7298 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7299 | ||
7300 | * src/lalr.h (LA): Is a bitsetv, not bitset*. | |
7301 | ||
b0299a2e AD |
7302 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7303 | ||
7304 | * src/lalr.h, src/lalr.c (LAruleno): Replace with... | |
7305 | (LArule): this, which is an array to rule_t*. | |
7306 | * src/print.c, src/conflicts.c: Adjust. | |
7307 | ||
d7e1f00c AD |
7308 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7309 | ||
7310 | * src/gram.h (rule_t): Rename `number' as `user_number'. | |
7311 | `number' is a new member. | |
7312 | Adjust dependencies. | |
7313 | * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number. | |
7314 | ||
cc9305dd AD |
7315 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7316 | ||
7317 | As a result of the previous patch, it is no longer needed | |
7318 | to reorder ritem itself. | |
7319 | ||
7320 | * src/reduce.c (reduce_grammar_tables): Don't sort RITEM. | |
7321 | ||
b0940840 AD |
7322 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7323 | ||
7324 | Be sure never to walk through RITEMS, but use only data related to | |
7325 | the rules themselves. RITEMS should be banished. | |
7326 | ||
7327 | * src/output.c (output_token_translations): Rename as... | |
7328 | (prepare_tokens): this. | |
7329 | In addition to `translate', prepare the muscles `tname' and | |
7330 | `toknum', which were handled by... | |
7331 | (output_rule_data): this. | |
7332 | Remove, and move the remainder of its outputs into... | |
7333 | (prepare_rules): this new routines, which also merges content from | |
7334 | (output_gram): this. | |
7335 | (prepare_rules): Be sure never to walk through RITEMS. | |
7336 | (output_stos): Rename as... | |
7337 | (prepare_stos): this. | |
7338 | (output): Always invoke prepare_states, after all, just don't use it | |
7339 | in the output if you don't need it. | |
7340 | ||
643a5994 AD |
7341 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7342 | ||
7343 | * src/LR0.c (new_state): Display `nstates' as the name of the | |
7344 | newly created state. | |
7345 | Adjust to initialize first_state and last_state if needed. | |
7346 | Be sure to distinguish the initial from the final state. | |
7347 | (new_states): Create the itemset of the initial state, and use | |
7348 | new_state. | |
7349 | * src/closure.c (closure): Now that the initial state has its | |
7350 | items properly set, there is no need for a special case when | |
7351 | creating `ruleset'. | |
7352 | ||
7353 | As a result, now the rule 0, reducing to $axiom, is visible in the | |
7354 | outputs. Adjust the test suite. | |
7355 | ||
7356 | * tests/conflicts.at (Solved SR Conflicts) | |
7357 | (Unresolved SR Conflicts): Adjust. | |
7358 | * tests/regression.at (Web2c Report, Rule Line Numbers): Idem. | |
7359 | * tests/conflicts.at (S/R in initial): New. | |
7360 | ||
b4c4ccc2 AD |
7361 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7362 | ||
7363 | * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over | |
7364 | the RHS of the rules. | |
7365 | * src/output.c (output_gram): Likewise. | |
7366 | ||
bba97eb2 AD |
7367 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7368 | ||
7369 | * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's | |
7370 | bucket. | |
7371 | Adjust all dependencies. | |
7372 | * src/reduce.c (nonterminals_reduce): Don't forget to renumber the | |
7373 | `number' of the buckets too. | |
7374 | * src/gram.h: Include `symtab.h'. | |
7375 | (associativity): Move to... | |
7376 | * src/symtab.h: here. | |
7377 | No longer include `gram.h'. | |
7378 | ||
c3b407f4 AD |
7379 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7380 | ||
7381 | * src/gram.h, src/gram.c (rules_rhs_length): New. | |
7382 | (ritem_longest_rhs): Use it. | |
7383 | * src/gram.h (rule_t): `number' is a new member. | |
7384 | * src/reader.c (packgram): Set it. | |
7385 | * src/reduce.c (reduce_grammar_tables): Move the useless rules at | |
7386 | the end of `rules', and count them out of `nrules'. | |
7387 | (reduce_output, dump_grammar): Adjust. | |
7388 | * src/print.c (print_grammar): It is no longer needed to check for | |
7389 | the usefulness of a rule, as useless rules are beyond `nrules + 1'. | |
7390 | * tests/reduce.at (Reduced Automaton): New test. | |
7391 | ||
11652ab3 AD |
7392 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7393 | ||
7394 | * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a | |
7395 | lacking `+ 1' to nrules, Bison reported as useless a token if it | |
7396 | was used solely to set the precedence of the last rule... | |
7397 | ||
26b23c1a AD |
7398 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7399 | ||
7400 | * data/bison.c++, data/bison.simple: Don't output the current file | |
7401 | name in #line, to avoid useless diffs between two identical | |
7402 | outputs under different names. | |
7403 | ||
18bcecb0 AD |
7404 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7405 | ||
7406 | * src/closure.c, src/print.c, src/reader.c, src/reduce.c: | |
7407 | Normalize loops to using `< nrules + 1', not `<= nrules'. | |
7408 | ||
fa770c86 AD |
7409 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7410 | ||
7411 | * TODO: Update. | |
7412 | ||
d9b739c3 AD |
7413 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7414 | ||
7415 | * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename | |
7416 | bucket.value as bucket.number. | |
7417 | ||
99013900 AD |
7418 | 2002-04-07 Akim Demaille <akim@epita.fr> |
7419 | ||
7420 | * src/closure.c, src/derives.c, src/gram.h, src/lalr.c, | |
7421 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
7422 | * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the | |
7423 | RHS, instead of being an index in RITEMS. | |
7424 | ||
e966383b PE |
7425 | 2002-04-04 Paul Eggert <eggert@twinsun.com> |
7426 | ||
7427 | * doc/bison.texinfo: Update copyright date. | |
7428 | (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII. | |
7429 | (Symbols): Warn about running Bison in one character set, | |
7430 | but compiling and/or running in an incompatible one. | |
7431 | Warn about character code 256, too. | |
7432 | ||
7433 | 2002-04-03 Paul Eggert <eggert@twinsun.com> | |
7434 | ||
7435 | * src/bison.data (YYSTACK_ALLOC): Depend on whether | |
7436 | YYERROR_VERBOSE is nonzero, not whether it is defined. | |
7437 | ||
7438 | Merge changes from bison-1_29-branch. | |
c307773e | 7439 | |
8d6c48b9 PE |
7440 | 2002-03-20 Paul Eggert <eggert@twinsun.com> |
7441 | ||
7442 | Merge fixes from Debian bison_1.34-1.diff. | |
7443 | ||
7444 | * configure.in (AC_PREREQ): 2.53. | |
7445 | ||
e53c6322 AD |
7446 | 2002-03-20 Akim Demaille <akim@epita.fr> |
7447 | ||
7448 | * src/conflicts.c (log_resolution): Argument `resolution' is const. | |
7449 | ||
9ffbeca7 PE |
7450 | 2002-03-19 Paul Eggert <eggert@twinsun.com> |
7451 | ||
21db0b2a PE |
7452 | * src/bison.simple (YYCOPY): New macro. |
7453 | (YYSTACK_RELOCATE): Use it. | |
7454 | Remove Type arg; no longer needed. All callers changed. | |
7455 | (yymemcpy): Remove; no longer needed. | |
7456 | ||
9ffbeca7 PE |
7457 | * Makefile.am (AUTOMAKE_OPTIONS): 1.6. |
7458 | * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
7459 | ||
642cb8f8 AD |
7460 | 2002-03-19 Akim Demaille <akim@epita.fr> |
7461 | ||
7462 | Test and fix the #line outputs. | |
7463 | ||
7464 | * tests/atlocal.at (GCC): New. | |
7465 | * tests/synclines.at (AT_TEST_SYNCLINE): New macro. | |
7466 | (Prologue synch line, ,%union synch line, Postprologue synch line) | |
7467 | (Action synch line, Epilogue synch line): New tests. | |
7468 | * src/reader.c (parse_union_decl): Define the muscle stype_line. | |
7469 | * data/bison.simple, data/bison.c++: Use it. | |
7470 | ||
3c31a486 AD |
7471 | 2002-03-19 Akim Demaille <akim@epita.fr> |
7472 | ||
7473 | * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts) | |
7474 | (Solved SR Conflicts, %expect not enough, %expect right) | |
7475 | (%expect too much): Move to... | |
7476 | * tests/conflicts.at: this new file. | |
7477 | ||
0d8bed56 AD |
7478 | 2002-03-19 Akim Demaille <akim@epita.fr> |
7479 | ||
7480 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
7481 | * data/bison.simple, data/bison.c++: Handle the `#define' part, so | |
7482 | that we can move to enums for instance. | |
7483 | * src/output.c (token_definitions_output): Output a list of | |
7484 | `token-name, token-number' instead of the #define. | |
7485 | (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'. | |
7486 | ||
9208d17f AD |
7487 | 2002-03-14 Akim Demaille <akim@epita.fr> |
7488 | ||
7489 | Use Gettext 0.11.1. | |
7490 | ||
af27eacb RA |
7491 | 2002-03-09 Robert Anisko <robert@lrde.epita.fr> |
7492 | ||
7493 | * data/bison.c++: Make the user able to add members to the generated | |
7494 | parser by subclassing. | |
7495 | ||
9101a310 RA |
7496 | 2002-03-05 Robert Anisko <robert@lrde.epita.fr> |
7497 | ||
7498 | * src/reader.c (read_additionnal_code): `c' should be an integer, not | |
7499 | a character. | |
7500 | Reported by Nicolas Tisserand and Nicolas Burrus. | |
7501 | ||
fff9bf0b RA |
7502 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
7503 | ||
7504 | * src/reader.c: Warn about lacking semi-colons, do not complain. | |
7505 | ||
64dba31e RA |
7506 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
7507 | ||
7508 | * data/bison.c++: Remove a debug line. | |
7509 | ||
374f5a14 RA |
7510 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> |
7511 | ||
7512 | * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge | |
7513 | location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and | |
7514 | provide a default implementation. | |
7515 | ||
bfcf1f3a AD |
7516 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7517 | ||
7518 | * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'. | |
7519 | * tests/output.at (AT_CHECK_OUTPUT): Likewise. | |
7520 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto. | |
7521 | * tests/semantic.at (Parsing Guards): Similarly. | |
7522 | * src/reader.at (readgram): Complain if the last rule is not ended | |
7523 | with a semi-colon. | |
7524 | ||
65ccf9fc AD |
7525 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7526 | ||
7527 | * src/warshall.h, src/warshall.c (bitmatrix_print): Move to... | |
7528 | * src/closure.c: here. | |
7529 | (set_firsts): Use bitsetv_reflexive_transitive_closure instead of | |
7530 | RTC. | |
7531 | * src/warshall.h, src/warshall.c: Remove. | |
7532 | * tests/sets.at (Broken Closure): Adjust. | |
7533 | ||
d0039cbc AD |
7534 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7535 | ||
7536 | * src/output.c (output_skeleton): tempdir is const. | |
7537 | bytes_read is unused. | |
7538 | ||
345cea78 AD |
7539 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7540 | ||
7541 | * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
7542 | * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c: | |
7543 | Update. | |
7544 | From Michael Hayes. | |
7545 | ||
564801f7 AD |
7546 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7547 | ||
7548 | * src/closure.c (closure): `r' is unused. | |
7549 | ||
e5352bc7 AD |
7550 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7551 | ||
7552 | * tests/sets.at (Broken Closure): Add the ending `;'. | |
7553 | * src/reader.at (readgram): Complain if a rule is not ended with a | |
7554 | semi-colon. | |
7555 | ||
914feea9 AD |
7556 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7557 | ||
7558 | * src/conflicts.c (set_conflicts): Use bitset_disjoint_p. | |
7559 | (count_sr_conflicts): Use bitset_count. | |
7560 | * src/reduce.c (inaccessable_symbols): Ditto. | |
7561 | (bits_size): Remove. | |
7562 | * src/warshall.h, src/warshall.c: Convert to bitsetv. | |
7563 | ||
f0250de6 AD |
7564 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7565 | ||
7566 | * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c, | |
7567 | * src/reduce.c: Remove the `bitset_zero's following the | |
7568 | `bitset_create's, as now it is performed by the latter. | |
7569 | ||
ef017502 AD |
7570 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7571 | ||
7572 | * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h, | |
7573 | * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h, | |
7574 | * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the | |
7575 | latest sources from Michael. | |
7576 | ||
76514394 AD |
7577 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7578 | ||
7579 | * src/output.c (output): Don't free the grammar. | |
7580 | * src/reader.c (grammar_free): New. | |
7581 | * src/main.c (main): Call it and don't free symtab here. | |
7582 | ||
55024580 AD |
7583 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7584 | ||
7585 | * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer | |
7586 | before returning. | |
7587 | Reported by Benoit Perrot. | |
7588 | ||
f9abaa2c AD |
7589 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7590 | ||
7591 | Use bitset operations when possible, not loops over bits. | |
7592 | ||
7593 | * src/conflicts.c (set_conflicts, count_sr_conflicts): Use | |
7594 | bitset_or. | |
7595 | * src/print.c (print_reductions): Use bitset_and, bitset_andn. | |
7596 | * src/reduce.c (useless_nonterminals): Formatting changes. | |
7597 | * src/warshall.c (TC): Use bitset_or. | |
7598 | ||
0e721e75 AD |
7599 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7600 | ||
7601 | * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused. | |
7602 | * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET): | |
7603 | Ditto. | |
7604 | ||
0fb1ffb1 AD |
7605 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7606 | ||
7607 | * src/lalr.c (F): Now a bitset*. | |
7608 | Adjust all dependencies. | |
7609 | ||
b86796bf AD |
7610 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7611 | ||
7612 | * src/conflicts.c (shiftset, lookaheadset): Now bitset. | |
7613 | Adjust all dependencies. | |
7614 | ||
602bbf31 AD |
7615 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7616 | ||
7617 | * src/L0.c, src/LR0.h (nstates): Be size_t. | |
7618 | Adjust comparisons (signed vs unsigned). | |
7619 | * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a | |
7620 | bitset*. | |
7621 | Adjust all dependencies. | |
7622 | ||
d8a0245c AD |
7623 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7624 | ||
7625 | * src/closure.c (firsts): Now, also a bitset. | |
7626 | Adjust all dependencies. | |
7627 | (varsetsize): Remove, now unused. | |
7628 | * src/warshall.h, src/warshall.c: Now work on arrays of bitsets. | |
7629 | ||
34ba9743 AD |
7630 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7631 | ||
7632 | * src/print.c: Convert to use bitset.h, not hand coded iterations | |
7633 | over ints. | |
7634 | ||
ed86e78c AD |
7635 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7636 | ||
7637 | * src/reduce.c: Convert to use bitset.h, not hand coded BSet. | |
7638 | ||
dfdb1797 AD |
7639 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7640 | ||
7641 | * src/closure.c (ruleset): Be a bitset. | |
7642 | (rulesetsize): Remove. | |
7643 | ||
7086e707 AD |
7644 | 2002-03-04 Akim Demaille <akim@epita.fr> |
7645 | ||
7646 | * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
7647 | * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, | |
7648 | * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New. | |
7649 | * src/closure.c (fderives): Be an array of bitsets. | |
7650 | ||
98254360 RA |
7651 | 2002-02-28 Robert Anisko <robert@lrde.epita.fr> |
7652 | ||
7653 | * data/bison.c++: Merge the two generated headers. Insert a copyright | |
7654 | notice in each output file. | |
7655 | ||
a75c057f AD |
7656 | 2002-02-28 Akim Demaille <akim@epita.fr> |
7657 | ||
7658 | * data/bison.c++: Copy the prologue of bison.simple to fetch | |
7659 | useful M4 definitions, such as b4_header_guard. | |
7660 | ||
06b00abc AD |
7661 | 2002-02-25 Akim Demaille <akim@epita.fr> |
7662 | ||
7663 | * src/getargs.c (version): Give the name of the authors, and use a | |
a75c057f AD |
7664 | translator friendly scheme for the bgr |
7665 | copyright notice. | |
06b00abc | 7666 | |
70e7d534 AD |
7667 | 2002-02-25 Akim Demaille <akim@epita.fr> |
7668 | ||
7669 | * src/output.c (header_output): Remove, now handled completely via | |
7670 | M4. | |
7671 | ||
abe017f6 AD |
7672 | 2002-02-25 Akim Demaille <akim@epita.fr> |
7673 | ||
7674 | * m4/m4.m4: New, from CVS Autoconf. | |
7675 | * configure.in: Invoke it. | |
7676 | * src/output.c (output_skeleton): Use its result instead of the | |
7677 | hard coded name. | |
7678 | ||
381fb12e AD |
7679 | 2002-02-25 Akim Demaille <akim@epita.fr> |
7680 | ||
7681 | * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from | |
7682 | Fileutils 4.1.5. | |
7683 | * configure.in: Invoke UTILS_FUNC_MKSTEMP. | |
7684 | * src/output.c (output_skeleton): Use mkstemp to create a real | |
7685 | temporary file. | |
7686 | Move the filling of `skeleton' and its muscle to... | |
7687 | (prepare): here. | |
7688 | (output): Move the definition of the prologue muscle to... | |
7689 | (prepare): here. | |
7690 | * src/system.h (DEFAULT_TMPDIR): New. | |
7691 | ||
6f38107f PE |
7692 | 2002-02-14 Paul Eggert <eggert@twinsun.com> |
7693 | ||
7694 | Remove the support for C++ namespace cleanliness; it was | |
7695 | causing more problems than it was curing, since it didn't work | |
7696 | properly on some nonstandard C++ compilers. This can wait | |
7697 | for a proper C++ parser. | |
7698 | ||
7699 | * NEWS: Document this. | |
7700 | * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention | |
7701 | of C++, as it's treated like C now. | |
7702 | * src/bison.simple (YYSTD): Remove. | |
7703 | (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL): | |
7704 | Treat C++ just like Standard C instead of trying to support | |
7705 | namespace cleanliness. | |
7706 | ||
80cce3da AD |
7707 | 2002-02-14 Akim Demaille <akim@epita.fr> |
7708 | ||
7709 | * tests/regression.at (else): Adjust to Andreas' change. | |
7710 | ||
842e8679 AD |
7711 | 2002-02-14 Akim Demaille <akim@epita.fr> |
7712 | ||
7713 | * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c. | |
7714 | ||
4bda3f10 AD |
7715 | 2002-02-13 Andreas Schwab <schwab@suse.de> |
7716 | ||
7717 | * src/output.c (output_rule_data): Don't output NULL, it might | |
7718 | not be defined yet. | |
7719 | ||
4162fa07 | 7720 | 2002-02-11 Robert Anisko <robert@lrde.epita.fr> |
b418ecd8 | 7721 | |
4162fa07 RA |
7722 | * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue. |
7723 | (Copyright notice): Update. | |
b418ecd8 | 7724 | |
bd16a5dc AD |
7725 | 2002-02-11 Akim Demaille <akim@epita.fr> |
7726 | ||
7727 | * tests/regression.at (%nonassoc and eof): Don't include | |
7728 | nonportable headers. | |
7729 | ||
8d69a1a3 RA |
7730 | 2002-02-08 Robert Anisko <robert@lrde.epita.fr> |
7731 | ||
7732 | * data/bison.c++: Correct error recovery. Make the user able to | |
7733 | initialize the starting location. | |
7734 | ||
9b2d0677 AD |
7735 | 2002-02-07 Akim Demaille <akim@epita.fr> |
7736 | ||
7737 | * tests/input.at: New. | |
7738 | ||
69e2658b RA |
7739 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
7740 | ||
7741 | * data/bison.c++: Replace some direct m4 expansions by constants. Be | |
9b2d0677 | 7742 | more consistent when naming methods and variables. Put preprocessor |
69e2658b RA |
7743 | directives around tables only needed for debugging. |
7744 | ||
4aacc3a7 RA |
7745 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
7746 | ||
7747 | * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in | |
7748 | C++ parsers. | |
7749 | (yy::b4_name::parse): Use print_. | |
7750 | ||
762a801e RA |
7751 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
7752 | ||
7753 | * data/bison.c++ (yy::b4_name::parse): Error recovery is back. | |
7754 | ||
4bb2bc3f RA |
7755 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> |
7756 | ||
7757 | * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in | |
7758 | C++ parsers. | |
7759 | (yy::b4_name::parse): Build verbose error messages, and use error_. | |
7760 | ||
6b45a3ca RA |
7761 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> |
7762 | ||
7763 | * data/bison.c++: Fix m4 quoting in comments. | |
7764 | ||
50997c6e RA |
7765 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> |
7766 | ||
7767 | * data/bison.c++: Adjust the parser code. Fix some muscles that were | |
7768 | not expanded by m4. | |
7769 | ||
3f3eed27 AD |
7770 | 2002-02-05 Akim Demaille <akim@epita.fr> |
7771 | ||
7772 | * data/bison.c++: Adjust to the M4 back end. | |
7773 | More is certainly needed. | |
7774 | ||
be2a1a68 AD |
7775 | 2002-02-05 Akim Demaille <akim@epita.fr> |
7776 | ||
7777 | Give a try to M4 as a back end. | |
7778 | ||
7779 | * lib/readpipe.c: New, from wdiff. | |
7780 | * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and | |
7781 | BISON_HAIRY. | |
7782 | * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS | |
7783 | specific values. Now it is m4 that performs the lookup. | |
7784 | * src/parse-skel.y: Remove. | |
7785 | * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New. | |
7786 | * src/output.c (actions_output, guards_output) | |
7787 | (token_definitions_output): No longer keeps track of the output | |
7788 | line number, hence remove the second argument. | |
7789 | (guards_output): Check against the guard member of a rule, not the | |
7790 | action member. | |
7791 | Adjust callers. | |
7792 | (output_skeleton): Don't look for the skeleton location, let m4 do | |
7793 | that. | |
7794 | Create `/tmp/muscles.m4'. This is temporary, a proper temporary | |
7795 | file will be used. | |
7796 | Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton. | |
7797 | (prepare): Given that for the time being changesyntax is not | |
7798 | usable in M4, rename the muscles using `-' to `_'. | |
7799 | Define `defines_flag', `output_parser_name' and `output_header_name'. | |
7800 | * src/output.h (actions_output, guards_output) | |
7801 | (token_definitions_output): Adjust prototypes. | |
7802 | * src/scan-skel.l: Instead of scanning the skeletons, it now | |
7803 | processes the output of m4: `__oline__' and `#output'. | |
7804 | * data/bison.simple: Adjust to be used by M4(sugar). | |
7805 | * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up | |
7806 | to date. | |
7807 | * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR' | |
7808 | instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'. | |
7809 | * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New, | |
7810 | shamelessly stolen from CVS Autoconf. | |
7811 | ||
beda758b AD |
7812 | 2002-02-05 Akim Demaille <akim@epita.fr> |
7813 | ||
7814 | * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version. | |
7815 | * configure.in: Check for the declarations of free and malloc. | |
7816 | * src/muscle_tab.c: Adjust. | |
7817 | ||
5ece6d43 AD |
7818 | 2002-02-05 Akim Demaille <akim@epita.fr> |
7819 | ||
7820 | * src/muscle_tab.c (muscle_init): Don't default to NULL muscle | |
7821 | which have no values. | |
7822 | ||
5bb18f9a AD |
7823 | 2002-02-05 Akim Demaille <akim@epita.fr> |
7824 | ||
7825 | * src/bison.simple, src/bison.hairy, src/bison.c++: Move to... | |
7826 | * data/: here. | |
7827 | ||
894dd62e PE |
7828 | 2002-01-29 Paul Eggert <eggert@twinsun.com> |
7829 | ||
7830 | * src/bison.simple (YYSIZE_T): Do not define merely because | |
7831 | YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined. | |
7832 | On some platforms, <alloca.h> does not declare YYSTD (size_t). | |
7833 | ||
82841af7 AD |
7834 | 2002-01-27 Akim Demaille <akim@epita.fr> |
7835 | ||
7836 | Fix `%nonassoc and eof'. | |
7837 | ||
7838 | * src/state.c (errs_dup): Aaaah! The failure was due to bytes | |
7839 | which were not properly copied! Replace | |
7840 | memcpy (res->errs, src->errs, src->nerrs); | |
7841 | with | |
7842 | memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0])); | |
7843 | !!! | |
7844 | * tests/regression.at (%nonassoc and eof): Adjust to newest | |
7845 | Autotest: `.' is not in the PATH. | |
7846 | ||
318b76e9 AD |
7847 | 2002-01-27 Akim Demaille <akim@epita.fr> |
7848 | ||
7849 | * tests/sets.at (AT_EXTRACT_SETS): New. | |
7850 | (Nullable): Use it. | |
7851 | (Firsts): New. | |
7852 | ||
30d2f3d5 AD |
7853 | 2002-01-26 Akim Demaille <akim@epita.fr> |
7854 | ||
7855 | * tests/actions.at, tests/calc.at, tests/headers.at, | |
7856 | * tests/torture.at: Adjust to the newest Autotest which no longer | |
7857 | forces `.' in the PATH. | |
7858 | ||
30f8c395 AD |
7859 | 2002-01-25 Akim Demaille <akim@epita.fr> |
7860 | ||
7861 | * tests/regression.at (%nonassoc and eof): New. | |
7862 | Suggested by Robert Anisko. | |
7863 | ||
29ae55f1 AD |
7864 | 2002-01-24 Akim Demaille <akim@epita.fr> |
7865 | ||
7866 | Bison dumps core when trying to complain about broken input files. | |
7867 | Reported by Cris van Pelt. | |
7868 | ||
7869 | * src/lex.c (parse_percent_token): Be sure to set token_buffer. | |
7870 | * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge | |
7871 | into... | |
7872 | (Invalid inputs): Strengthen: exercise parse_percent_token. | |
7873 | ||
2b548aa6 RA |
7874 | 2002-01-24 Robert Anisko <robert.anisko@epita.fr> |
7875 | ||
7876 | * src/Makefile.am: Add bison.c++. | |
7877 | * src/bison.c++: New skeleton. | |
7878 | ||
bb0146c2 AD |
7879 | 2002-01-21 Paolo Bonzini <bonzini@gnu.org> |
7880 | ||
7881 | * po/it.po: New. | |
7882 | ||
bec30531 AD |
7883 | 2002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net> |
7884 | ||
7885 | * src/files.c (skeleton_find) [MSDOS]: Fix cp definition. | |
7886 | ||
fc6edc45 MA |
7887 | 2002-01-20 Marc Autret <marc@gnu.org> |
7888 | ||
7889 | * src/files.c (compute_output_file_names): Fix | |
7890 | ||
5e5d5415 MA |
7891 | 2002-01-20 Marc Autret <marc@gnu.org> |
7892 | ||
7893 | * tests/output.at: New test. | |
7894 | * src/files.c (compute_base_names): Don't map extensions when | |
7895 | the YACC flag is set, use defaults. | |
7896 | Reported by Evgeny Stambulchik. | |
7897 | ||
44ea3fbd MA |
7898 | 2002-01-20 Marc Autret <marc@gnu.org> |
7899 | ||
bb0146c2 | 7900 | * src/system.h: Need to define __attribute__ away for non-GCC |
44ea3fbd MA |
7901 | compilers as well (i.e. the vendor C compiler). |
7902 | Suggested by Albert Chin-A-Young. | |
7903 | ||
338963d1 TVH |
7904 | 2002-01-11 Tim Van Holder <tim.van.holder@pandora.be> |
7905 | ||
7906 | * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the | |
7907 | canonical definition. | |
7908 | * src/system.h: Use the canonical definition for PARAMS (avoids | |
7909 | a conflict with the macro from lib/hash.h). | |
7910 | ||
c57b2479 AD |
7911 | 2002-01-11 Akim Demaille <akim@epita.fr> |
7912 | ||
7913 | * configure.in: Use AC_FUNC_STRNLEN. | |
d9e9746c | 7914 | Fixes the failures observed on AIX 4.3 by H.Merijn Brand. |
c57b2479 | 7915 | |
b85810ae AD |
7916 | 2002-01-09 Akim Demaille <akim@epita.fr> |
7917 | ||
7918 | * src/files.c, src/files.h (output_infix): New. | |
7919 | (tab_extension): Remove. | |
7920 | (compute_base_names): Compute the former, drop the latter. | |
7921 | * src/output.c (prepare): Insert the muscles `output-infix', and | |
7922 | `output-suffix'. | |
7923 | * src/parse-skel.y (string, string.1): New. | |
7924 | (section.header): Use it. | |
7925 | (section.yacc): Remove. | |
7926 | (prefix): Remove too. | |
7927 | * src/scan-skel.l: Adjust. | |
7928 | * src/bison.simple, src/bison.hairy: Adjust. | |
7929 | ||
cae60122 AD |
7930 | 2002-01-09 Akim Demaille <akim@epita.fr> |
7931 | ||
7932 | * configure.in (WERROR_CFLAGS): Compute it. | |
7933 | * src/Makefile.am (CFLAGS): Pass it. | |
7934 | * tests/atlocal.in (CFLAGS): Idem. | |
7935 | * src/files.c: Fix a few warnings. | |
7936 | (get_extension_index): Remove, unused. | |
7937 | ||
ae404801 AD |
7938 | 2002-01-08 Akim Demaille <akim@epita.fr> |
7939 | ||
7940 | * src/getargs.c (AS_FILE_NAME): New. | |
7941 | (getargs): Use it to convert DOSish file names. | |
7942 | * src/files.c (base_name): Rename as full_base_name to avoid | |
7943 | clashes with `base_name ()'. | |
7944 | (filename_split): New. | |
7945 | (compute_base_names): N-th rewrite, using filename_split. | |
7946 | ||
22312b71 AD |
7947 | 2002-01-08 Akim Demaille <akim@epita.fr> |
7948 | ||
7949 | * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c: | |
7950 | New, stolen from the Fileutils 4.1. | |
7951 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
7952 | * configure.in: Check for the presence of memrchr, and of its | |
7953 | prototype. | |
7954 | ||
a67cef01 TVH |
7955 | 2002-01-07 Tim Van Holder <tim.van.holder@pandora.be> |
7956 | ||
7957 | * lib/hash.h (__P): Added definition for this macro. | |
7958 | * src/Makefile.am: Add parse-skel.c and scan-skel.c to | |
7959 | BUILT_SOURCES, to ensure they are generated first. | |
7960 | * src/parse-skel.y: Use YYERROR_VERBOSE instead of | |
7961 | %error-verbose to allow bootstrapping with bison 1.30x. | |
7962 | ||
2b25d624 AD |
7963 | 2002-01-06 Akim Demaille <akim@epita.fr> |
7964 | ||
7965 | * src/reader.c (parse_braces): Don't fetch the next char, the | |
7966 | convention is to fetch on entry. | |
7967 | * tests/torture.at (GNU Cim Grammar): Reintroduce their weird | |
7968 | 'switch' without a following semicolon. | |
7969 | * tests/regression.at (braces parsing): New. | |
7970 | ||
3460813b AD |
7971 | 2002-01-06 Akim Demaille <akim@epita.fr> |
7972 | ||
7973 | Bison is dead wrong in its RR conflict reports. | |
7974 | ||
7975 | * tests/torture.at (GNU Cim Grammar): New. | |
7976 | * src/conflicts.c (count_rr_conflicts): Fix. | |
7977 | ||
73784c64 AD |
7978 | 2002-01-06 Akim Demaille <akim@epita.fr> |
7979 | ||
7980 | Creating package.m4 from configure.ac causes too many problems. | |
7981 | ||
7982 | * tests/Makefile.am (package.m4): Create it by hand, | |
7983 | AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf. | |
7984 | ||
25d81090 AD |
7985 | 2002-01-06 Akim Demaille <akim@epita.fr> |
7986 | ||
7987 | * src/Makefile.am (bison_SOURCES): Add parse-skel.h and | |
7988 | skeleton.h. | |
7989 | ||
a9b8959e PE |
7990 | 2002-01-04 Paul Eggert <eggert@twinsun.com> |
7991 | ||
7992 | * doc/bison.texinfo (Debugging): | |
7993 | Remove YYSTDERR; it's no longer defined or used. | |
7994 | Also, s/cstdio.h/cstdio/. | |
7995 | ||
25d81090 AD |
7996 | 2002-01-03 Akim Demaille <akim@epita.fr> |
7997 | ||
7998 | * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf. | |
7999 | ||
1109455c AD |
8000 | 2002-01-03 Akim Demaille <akim@epita.fr> |
8001 | ||
8002 | * src/parse-skel.y (process_skeleton): Don't bind the parser's | |
8003 | tracing code to --trace, wait for a better --trace option, with | |
8004 | args. | |
8005 | ||
7ea5e977 AD |
8006 | 2002-01-03 Akim Demaille <akim@epita.fr> |
8007 | ||
8008 | * src/bison.simple (YYSTDERR): Remove, replace `stderr'. | |
8009 | The ISO C++ standard is extremely clear about it: stderr is | |
8010 | considered a macro, not a regular symbol (see table 94 `Header | |
8011 | <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files). | |
8012 | Therefore std:: does not apply to it. It still does with fprintf. | |
8013 | Also, s/cstdio.h/cstdio/. | |
8014 | ||
fab5b110 AD |
8015 | 2002-01-03 Akim Demaille <akim@epita.fr> |
8016 | ||
8017 | * lib/quotearg.c: Use `#include "..."' instead of `#include <...>' | |
8018 | for non system headers. | |
8019 | ||
aed7fd9b AD |
8020 | 2002-01-02 Akim Demaille <akim@epita.fr> |
8021 | ||
8022 | Equip the skeleton chain with location tracking, runtime trace, | |
8023 | pure parser and scanner. | |
8024 | ||
8025 | * src/parse-skel.y: Request a pure parser, locations, and prefix | |
8026 | renaming. | |
8027 | (%union): Having several members with the same type does not help | |
8028 | type mismatches, simplify. | |
8029 | (YYPRINT, yyprint): New. | |
8030 | (yyerror): ``Rename'' (there is a #define yyerror skel_error) as... | |
8031 | (skel_error): this. | |
8032 | Handle locations. | |
8033 | * src/scan-skel.l: Adjust to these changes. | |
8034 | * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP) | |
8035 | (LOCATION_PRINT, skel_control_t): New. | |
8036 | ||
24fad99e AD |
8037 | 2001-12-30 Akim Demaille <akim@epita.fr> |
8038 | ||
8039 | * src/parse-skel.y: Get rid of the shift/reduce conflict: | |
8040 | replace `gb' with BLANKS. | |
8041 | * src/scan-skel.l: Adjust. | |
8042 | ||
a4b36db4 AD |
8043 | 2001-12-30 Akim Demaille <akim@epita.fr> |
8044 | ||
8045 | * src/system.h: We don't need nor want bcopy. | |
8046 | Throw away MS-DOS crap: we don't need getpid. | |
8047 | * configure.in: We don't need strndup. It was even causing | |
8048 | problems: because Flex includes the headers *before* us, | |
8049 | _GNU_SOURCE is not defined by config.h, and therefore strndup was | |
8050 | not visible. | |
8051 | * lib/xstrndup.c: New. | |
8052 | * src/scan-skel.l: Use it. | |
8053 | Be sure to initialize yylval.muscle member when scanning a MUSCLE. | |
8054 | * src/parse-skel.y: Use %directives instead of #defines. | |
8055 | ||
1239777d AD |
8056 | 2001-12-30 Akim Demaille <akim@epita.fr> |
8057 | ||
8058 | * src/skeleton.h: New. | |
8059 | * src/output.c (output_parser, output_master_parser): Remove, dead | |
8060 | code. | |
8061 | * src/output.h (get_lines_number, actions_output, guards_output) | |
8062 | (token_definitions_output): Prototype them. | |
8063 | * src/parse-skel.y: Add the license notice. | |
8064 | Include output.h and skeleton.h. | |
8065 | (process_skeleton): Returns void, and takes a single parameter. | |
8066 | * src/scan-skel.l: Add the license notice. | |
8067 | Include skeleton.h. | |
8068 | Don't use %option yylineno: it seems that then Flex imagines | |
8069 | REJECT has been used, and therefore it won't reallocate its | |
8070 | buffers (which makes no other sense to me than a bug). It results | |
8071 | in warnings for `unused: yy_flex_realloc'. | |
8072 | ||
9b3add5b RA |
8073 | 2001-12-30 Robert Anisko <robert.anisko@epita.fr> |
8074 | ||
8075 | * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
8076 | (MUSCLE_INSERT_PREFIX): ...to there. | |
8077 | * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
8078 | (MUSCLE_INSERT_PREFIX): Move from here... | |
8079 | ||
8080 | * src/bison.hairy: Add a section directive. Put braces around muscle | |
8081 | names. This parser skeleton is still broken, but Bison should not | |
8082 | choke on a bad muscle 'syntax'. | |
8083 | * src/bison.simple: Add a section directive. Put braces around muscle | |
8084 | names. | |
8085 | ||
8086 | * src/files.h (strsuffix, stringappend): Add declarations. | |
8087 | (tab_extension): Add declaration. | |
8088 | (short_base_name): Add declaration. | |
8089 | ||
8090 | * src/files.c (strsuffix, stringappend): No longer static. These | |
8091 | functions are used in the skeleton parser. | |
8092 | (tab_extension): New. | |
8093 | (compute_base_names): Use the computations done in this function | |
fab5b110 | 8094 | to guess if the generated parsers should have '.tab' in their |
9b3add5b RA |
8095 | names. |
8096 | (short_base_name): No longer static. | |
8097 | ||
8098 | * src/output.c (output_skeleton): New. | |
8099 | (output): Disable call to output_master_parser, and give a try to | |
8100 | a new skeleton handling system. | |
8101 | (guards_output, actions_output): No longer static. | |
8102 | (token_definitions_output, get_lines_number): No longer static. | |
8103 | ||
8104 | * configure.in: Use AM_PROG_LEX and AC_PROG_YACC. | |
8105 | ||
fab5b110 | 8106 | * src/Makefile.am (bison_SOURCES): Add scan-skel.l and |
9b3add5b RA |
8107 | parse-skel.y. |
8108 | ||
8109 | * src/parse-skel.y: New file. | |
8110 | * src/scan-skel.l: New file. | |
8111 | ||
b5b61c61 AD |
8112 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8113 | ||
8114 | %name-prefix is broken. | |
8115 | ||
8116 | * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy". | |
8117 | Adjust all dependencies. | |
8118 | * tests/headers.at (export YYLTYPE): Strengthen this test: use | |
8119 | %name-prefix. | |
8120 | ||
8121 | Renaming yylval but not yylloc is not consistent. Now we do. | |
8122 | ||
8123 | * src/bison.simple: Prefix yylloc if used. | |
8124 | * doc/bison.texinfo (Decl Summary): Document that. | |
8125 | ||
8c9a50be AD |
8126 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8127 | ||
8128 | * doc/bison.texinfo: Promote `%long-directive' over | |
8129 | `%long_directive'. | |
8130 | Remove all references to fixed-output-files, yacc is enough. | |
8131 | ||
d99361e6 AD |
8132 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8133 | ||
8134 | * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the | |
8135 | user prologue. These are defaults. | |
8136 | * tests/actions.at (Mid-rule actions): Make sure the user can | |
8137 | define YYDEBUG and YYERROR_VERBOSE. | |
8138 | ||
b9cecb91 AD |
8139 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8140 | ||
8141 | * src/output.c (header_output): Don't forget to export YYLTYPE and | |
8142 | yylloc. | |
8143 | * tests/headers.at (export YYLTYPE): New, make sure it does. | |
8144 | * tests/regression.at (%union and --defines, Invalid CPP headers): | |
8145 | Move to... | |
8146 | * tests/headers.at: here. | |
8147 | ||
aea13e97 AD |
8148 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8149 | ||
8150 | * src/gram.h (rule_s): Member `assoc' is of type `associativity'. | |
8151 | ||
931394cb AD |
8152 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8153 | ||
8154 | * tests/actions.at (Mid-rule actions): Output on a single line | |
8155 | instead of several. | |
8156 | ||
704a47c4 AD |
8157 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8158 | ||
8159 | * doc/bison.texinfo: Formatting changes. | |
8160 | ||
091e20bb AD |
8161 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8162 | ||
8163 | Don't store the token defs in a muscle, just be ready to output it | |
8164 | on command. Now possible via `symbols'. Fixes a memory leak. | |
8165 | ||
8166 | * src/output.c (token_definitions_output): New. | |
8167 | (output_parser, header_output): Use it. | |
8168 | * src/reader.c (symbols_save): Remove. | |
8169 | ||
cce71710 AD |
8170 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8171 | ||
8172 | * src/bison.simple: Do not provide a default for YYSTYPE and | |
8173 | YYLTYPE before the user's prologue. Otherwise it's hardly... a | |
8174 | default. | |
8175 | ||
82c035a8 AD |
8176 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8177 | ||
8178 | Mid-rule actions are simply... ignored! | |
8179 | ||
8180 | * src/reader.c (readgram): Be sure to attach mid-rule actions to | |
8181 | the empty-rule associated to the dummy symbol, not to the host | |
8182 | rule. | |
8183 | * tests/actions.at (Mid-rule actions): New. | |
8184 | ||
8419d367 AD |
8185 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8186 | ||
8187 | Memory leak. | |
8188 | ||
8189 | * src/reader.c (reader): Free grammar. | |
8190 | ||
375d5806 AD |
8191 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8192 | ||
8193 | Memory leak. | |
8194 | ||
8195 | * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here, | |
8196 | since it allocates it for each state, although only one is needed. | |
8197 | (allocate_storage): Do it here. | |
8198 | ||
f51cb8ff AD |
8199 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8200 | ||
8201 | * src/options.h, src/options.c (create_long_option_table): Rename | |
8202 | as... | |
8203 | (long_option_table_new): this, with a clearer prototype. | |
8204 | (percent_table): Remove, unused, | |
8205 | * src/getargs.c (getargs): Adjust. | |
8206 | ||
29e88316 AD |
8207 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8208 | ||
8209 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c | |
8210 | * src/print.c, src/print_graph.c, src/state.h: Rename state_table | |
8211 | as states. | |
8212 | ||
b9f71f19 AD |
8213 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8214 | ||
8215 | * src/lalr.c (build_relations): Rename `states' as `states1'. | |
8216 | Sorry, I don't understand exactly what it is, no better name... | |
8217 | ||
1a2b5d37 AD |
8218 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8219 | ||
8220 | * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c | |
8221 | * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c | |
8222 | * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table | |
8223 | as rules. | |
8224 | ||
1cca533e AD |
8225 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8226 | ||
8227 | * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long | |
8228 | ago. | |
8229 | ||
c03ae966 AD |
8230 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8231 | ||
8232 | * src/reader.c, src/reader.h (user_toknums): Remove. | |
8233 | Adjust all users to use symbols[i]->user_token_number. | |
8234 | ||
5a670b1e AD |
8235 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8236 | ||
8237 | * src/gram.c, src/gram.h (sprec, sassoc): Remove. | |
8238 | Adjust all users to use symbols[i]->prec or ->assoc. | |
8239 | ||
ad949da9 AD |
8240 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8241 | ||
8242 | * src/reader.c, src/reader.h (tags): Remove. | |
8243 | Adjust all users to use symbols[i]->tag. | |
8244 | ||
0e78e603 AD |
8245 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8246 | ||
8247 | * src/gram.h, src/gram.c (symbols): New, similar to state_table | |
8248 | and rule_table. | |
8249 | * src/reader.c (packsymbols): Fill this table. | |
8250 | Drop sprec. | |
8251 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
8252 | * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a | |
8253 | single table. | |
8254 | Use symbols[i]->tag instead of tags[i]. | |
8255 | ||
213e640e AD |
8256 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8257 | ||
8258 | * tests/calc.at (_AT_DATA_CALC_Y): Also use %union. | |
8259 | In addition, put a comment in there, to replace... | |
8260 | * tests/regression.at (%union and C comments): Remove. | |
8261 | ||
e7b8bef1 AD |
8262 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8263 | ||
8264 | * tests/regression.at (Web2c Actions): Blindly move the actual | |
8265 | output as expected output. The contents *seem* right to me, but I | |
8266 | can't pretend reading perfectly parser tables... Nonetheless, all | |
8267 | the other tests pass correctly, the table look OK, even though the | |
8268 | presence of `$axiom' is to be noted: AFAICS it is useless (but | |
8269 | harmless). | |
8270 | ||
b68e7744 AD |
8271 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8272 | ||
8273 | * src/reader.c (readgram): Don't add the rule 0 if there were no | |
8274 | rules read. In other words, add it _after_ having performed | |
8275 | grammar sanity checks. | |
8276 | Fixes the `tests/regression.at (Invalid input: 1)' Failure. | |
8277 | ||
78d5bae9 AD |
8278 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8279 | ||
8280 | * tests/regression.at (Web2c Report): Catch up: the rule 0 is now | |
8281 | visible, and some states have now a different number. | |
8282 | ||
ff442794 AD |
8283 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8284 | ||
8285 | * src/reader.c (readgram): Bind the initial rule's lineno to that | |
8286 | of the first rule. | |
8287 | * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts): | |
8288 | (Solved SR Conflicts): Adjust rule 0's line number. | |
8289 | ||
610ab194 AD |
8290 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8291 | ||
8292 | Fix the `GAWK Grammar' failure. | |
8293 | ||
8294 | * src/LR0.c (final_state): Initialize to -1 so that we do compute | |
8295 | the reductions of the first state which was mistakenly confused | |
8296 | with the final state because precisely final_state was initialized | |
8297 | to 0. | |
8298 | * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads, | |
8299 | now noticed by Bison. | |
8300 | * tests/regression.at (Rule Line Numbers): Adjust: state 0 does | |
8301 | have a reduction on $default. | |
8302 | ||
29d29c8f AD |
8303 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8304 | ||
8305 | * src/gram.c (ritem_print): Be sure to subtract 1 when displaying | |
8306 | rule line numbers. | |
8307 | * src/closure.c (print_closure): Likewise. | |
8308 | * src/derives.c (print_derives): Likewise. | |
8309 | * tests/sets.at (Nullable): Adjust: the rule numbers are correct | |
8310 | now. | |
8311 | ||
7c6b64d0 AD |
8312 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8313 | ||
8314 | * src/lalr.c (lookaheads_print): New. | |
8315 | (lalr): Call it when --trace-flag. | |
8316 | * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads | |
8317 | are dumped. | |
8318 | ||
3d4daee3 AD |
8319 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8320 | ||
8321 | * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0', | |
8322 | when walking through ritem, even via rule->rhs. | |
8323 | * src/reduce.c (dump_grammar, useful_production, reduce_output) | |
8324 | (useful_production, useless_nonterminals): Likewise. | |
8325 | (reduce_grammar_tables): Likewise, plus update nritems. | |
8326 | * src/nullable.c (set_nullable): Likewise. | |
8327 | * src/lalr.c (build_relations): Likewise. | |
8328 | * tests/sets.at (Nullable): Adjust. | |
8329 | Fortunately, now, the $axiom is no longer nullable. | |
8330 | ||
9e7f6bbd AD |
8331 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8332 | ||
8333 | * src/LR0.c (generate_states): Use nritems, not nitems, nor using | |
8334 | the 0-sentinel. | |
8335 | * src/gram.c (ritem_longest_rhs): Likewise. | |
8336 | * src/reduce.c (nonterminals_reduce): Likewise. | |
8337 | * src/print_graph.c (print_graph): Likewise. | |
8338 | * src/output.c (output_rule_data): Likewise. | |
8339 | * src/nullable.c (set_nullable): Likewise. | |
8340 | ||
255ef638 AD |
8341 | 2001-12-29 Akim Demaille <akim@epita.fr> |
8342 | ||
8343 | * src/output.c: Comment changes. | |
8344 | ||
0d8a7363 AD |
8345 | 2001-12-27 Paul Eggert <eggert@twinsun.com> |
8346 | ||
8347 | * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special | |
8348 | cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and | |
8349 | Sparc, as they were causing more porting problems than the | |
8350 | (minor) performance improvement was worth. | |
8351 | ||
8352 | Also, catch up with 1.31's YYSTD. | |
8353 | ||
3db472b9 AD |
8354 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8355 | ||
8356 | * src/output.c (output_gram): Rely on nritems, not the | |
8357 | 0-sentinel. See below. | |
8358 | Use -1 as separator, not 0. | |
8359 | * src/bison.simple (yyparse): Subtract 1 to the rule numbers. | |
8360 | Rely on -1 as separator in yyrhs, instead of 0. | |
8361 | * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue | |
8362 | twice `Now at end of input', therefore there are two lines less to | |
8363 | expect. | |
8364 | ||
b365aa05 AD |
8365 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8366 | ||
8367 | * tests/regression.at (Unresolved SR Conflicts): | |
8368 | (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes | |
8369 | below. | |
8370 | ||
30171f79 AD |
8371 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8372 | ||
8373 | * src/LR0.c (new_state): Recognize the final state by the fact it | |
8374 | is reached by eoftoken. | |
8375 | (insert_start_shifting_state, insert_eof_shifting_state) | |
8376 | (insert_accepting_state, augment_automaton): Remove, since now | |
8377 | these states are automatically computed from the initial state. | |
8378 | (generate_states): Adjust. | |
8379 | * src/print.c: When reporting a rule number to the user, substract | |
8380 | 1, so that the axiom rule is rule 0, and the first user rule is 1. | |
8381 | * src/reduce.c: Likewise. | |
8382 | * src/print_graph.c (print_core): For the time being, just as for | |
8383 | the report, depend upon --trace-flags to dump the full set of | |
8384 | items. | |
8385 | * src/reader.c (readgram): Once the grammar read, insert the rule | |
8386 | 0: `$axiom: START-SYMBOL $'. | |
8387 | * tests/set.at: Adjust: rule 0 is now displayed, and since the | |
8388 | number of the states has changed (the final state is no longer | |
8389 | necessarily the last), catch up. | |
8390 | ||
75142d45 AD |
8391 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8392 | ||
8393 | Try to make the use of the eoftoken valid. Given that its value | |
8394 | is 0 which was also used as a sentinel in ritem, (i) make sure >= 0 | |
8395 | is used instead of > 0 where appropriate, (ii), depend upon nritems | |
8396 | instead of the 0-sentinel. | |
8397 | ||
8398 | * src/gram.h, src/gram.c (nritems): New. | |
8399 | Expected to be duplication of nitems, but for the time being... | |
8400 | * src/reader.c (packgram): Assert nritems and nitems are equal. | |
8401 | * src/LR0.c (allocate_itemsets, new_itemsets): Adjust. | |
8402 | * src/closure.c (print_closure, print_fderives): Likewise. | |
8403 | * src/gram.c (ritem_print): Likewise. | |
8404 | * src/print.c (print_core, print_grammar): Likewise. | |
8405 | * src/print_graph.c: Likewise. | |
8406 | ||
b7c49edf AD |
8407 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8408 | ||
8409 | * src/main.c (main): If there are complains after grammar | |
8410 | reductions, then output the report anyway if requested, then die. | |
8411 | * src/symtab.c (bucket_new): Initialize `value' to -1, not 0. | |
8412 | * src/reader.c (eoftoken): New. | |
8413 | (parse_token_decl): If the token being defined has value `0', it | |
8414 | is the eoftoken. | |
8415 | (packsymbols): No longer hack `tags' to insert `$' by hand. | |
8416 | Be sure to preserve the value of the eoftoken. | |
8417 | (reader): Make sure eoftoken is defined. | |
8418 | Initialize nsyms to 0: now eoftoken is created just like the others. | |
8419 | * src/print.c (print_grammar): Don't special case the eof token. | |
8420 | * src/regression.at: Adjust: `$' has value 0, not -1, which was a | |
8421 | lie anyway, albeit pleasant. | |
8422 | * tests/calc.at: Exercise error messages with eoftoken. | |
8423 | Change the grammar so that empty input is invalid. | |
8424 | Adjust expectations. | |
8425 | When yyungeting, be sure to use a valid yylloc: use last_yylloc. | |
8426 | ||
ec2da99f AD |
8427 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8428 | ||
8429 | * configure.in: Check the protos of strchr ans strspn. | |
8430 | Replace strchr if needed. | |
8431 | * src/system.h: Provide the protos of strchr, strspn and memchr if | |
8432 | missing. | |
8433 | * lib/strchr.c: New. | |
8434 | * src/reader.c (symbols_save): Use strchr. | |
8435 | ||
8adfa272 AD |
8436 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8437 | ||
8438 | * src/print.c, src/print_graph.c (escape): New. | |
8439 | Use it to quote the TAGS outputs. | |
8440 | * src/print_graph.c (print_state): Now errors are in red, and | |
8441 | reductions in green. | |
8442 | Prefer high to wide: output the state number on a line of its own. | |
8443 | ||
80dac38c AD |
8444 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8445 | ||
8446 | * src/state.h, src/state.c (reductions_new): New. | |
8447 | * src/LR0.c (set_state_table): Let all the states have a | |
8448 | `reductions', even if reduced to 0. | |
8449 | (save_reductions): Adjust. | |
8450 | * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust. | |
8451 | * src/print.c (print_reductions, print_actions): Adjust. | |
8452 | * src/output.c (action_row): Adjust. | |
8453 | ||
2cec70b9 AD |
8454 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8455 | ||
8456 | * src/state.h, src/state.c (errs_new, errs_dup): New. | |
8457 | * src/LR0.c (set_state_table): Let all the states have an errs, | |
8458 | even if reduced to 0. | |
8459 | * src/print.c (print_errs, print_reductions): Adjust. | |
8460 | * src/output.c (output_actions, action_row): Adjust. | |
8461 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
8462 | ||
13ca549a AD |
8463 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8464 | ||
8465 | * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL. | |
8466 | ||
5092aba5 AD |
8467 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8468 | ||
8469 | * src/conflicts.c, src/conflicts.h (print_reductions): Move to... | |
8470 | * src/print.c: here. | |
8471 | (lookaheadset, shiftset): New, used as additional storage by | |
8472 | print_reductions. | |
8473 | (print_results): Adjust. | |
8474 | (print_shifts, print_gotos, print_errs): New, extracted from... | |
8475 | (print_actions): here. | |
8476 | * src/print_graph.c (print_actions): Remove dead code. | |
8477 | ||
11e2beca AD |
8478 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8479 | ||
8480 | * src/reader.c (copy_dollar, copy_at): Better checking of `n' in | |
8481 | `$n' and `@n'. | |
8482 | ||
dac3c910 AD |
8483 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8484 | ||
8485 | * src/lalr.c (add_lookback_edge): Use state_t instead of ints. | |
8486 | (build_relations): Adjust. | |
8487 | ||
d0b0fefa AD |
8488 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8489 | ||
8490 | * src/lalr.c (set_goto_map): Remove a wrong but benign loop | |
8491 | duplication. | |
8492 | ||
adc8c848 AD |
8493 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8494 | ||
8495 | * src/reader.c (packgram): Catch nitems overflows. | |
8496 | ||
14d293ac AD |
8497 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8498 | ||
8499 | * src/files.c, src/files.h (guard_obstack): Remove. | |
8500 | * src/output.c (output): Adjust. | |
8501 | * src/reader.c (parse_braces): New, factoring... | |
8502 | (copy_action, copy_guard): these two which are renamed as... | |
8503 | (parse_action, parse_guard): these. | |
8504 | As a voluntary consequence, using braces around guards is now | |
8505 | mandatory. | |
8506 | ||
f499b062 AD |
8507 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8508 | ||
8509 | * src/gram.h (rule_t): `guard' and `guard_line' are new members. | |
8510 | * src/reader.c (symbol_list): `guard' and `guard_line' are new | |
8511 | members. | |
8512 | (symbol_list_new): Adjust. | |
8513 | (copy_action): action_line is the first line, not the last. | |
8514 | (copy_guard): Just as for actions, store the `action' only, not | |
8515 | the switch/case/break flesh. | |
8516 | Don't parse the user action that might follow the guard, let... | |
8517 | (readgram): do it, i.e., now, there can be an action after a | |
8518 | guard. | |
8519 | In other words the guard is just explicitly optional. | |
8520 | (packgram): Adjust. | |
8521 | * src/output.c (guards_output): New. | |
8522 | (output_parser): Call it when needed. | |
8523 | (output): Also free the guard and attrs obstacks. | |
8524 | * src/files.c, src/files.h (obstack_save): Remove. | |
8525 | (output_files): Remove. | |
8526 | As a result, if one needs the former `.act' file, using an | |
8527 | appropriate skeleton which requires actions and guards is now | |
8528 | required. | |
8529 | * src/main.c (main): Adjust. | |
8530 | * tests/semantic.at: New. | |
8531 | * tests/regression.at: Use `input.y' as input file name. | |
8532 | Avoid 8+3 problems by requiring input.c when the test needs the | |
8533 | parser. | |
8534 | ||
d945f5cd AD |
8535 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8536 | ||
8537 | * src/reader.c (symbol_list_new): Be sure to initialize all the | |
8538 | fields. | |
8539 | ||
d200e455 AD |
8540 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8541 | ||
8542 | All the hacks using a final pseudo state are now useless. | |
8543 | ||
8544 | * src/LR0.c (set_state_table): state_table holds exactly nstates. | |
8545 | * src/lalr.c (nLA): New. | |
8546 | (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it | |
8547 | instead of lookaheadsp from the pseudo state (nstate + 1). | |
8548 | ||
f9507c28 AD |
8549 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8550 | ||
8551 | * src/output.c (action_row, token_actions): Use a state_t instead | |
8552 | of a integer, and nlookaheads instead of the following state's | |
8553 | lookaheadsp. | |
8554 | ||
065fbd27 AD |
8555 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8556 | ||
8557 | * src/conflicts.c (log_resolution, flush_shift) | |
8558 | (resolve_sr_conflict, set_conflicts, solve_conflicts) | |
8559 | (count_sr_conflicts, count_rr_conflicts, conflicts_output) | |
8560 | (conflicts_print, print_reductions): Use a state_t instead of an | |
8561 | integer when referring to a state. | |
8562 | As much as possible, depend upon nlookaheads, instead of the | |
8563 | `lookaheadsp' member of the following state (since lookaheads of | |
8564 | successive states are successive, the difference between state n + 1 | |
8565 | and n served as the number of lookaheads for state n). | |
8566 | * src/lalr.c (add_lookback_edge): Likewise. | |
8567 | * src/print.c (print_core, print_actions, print_state) | |
8568 | (print_results): Likewise. | |
8569 | * src/print_graph.c (print_core, print_actions, print_state) | |
8570 | (print_graph): Likewise. | |
8571 | * src/conflicts.h: Adjust. | |
8572 | ||
1b177bd7 AD |
8573 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8574 | ||
8575 | * src/bison.hairy: Formatting/comment changes. | |
8576 | ANSIfy. | |
8577 | Remove `register' indications. | |
8578 | Add plenty of `static'. | |
8579 | ||
7742ddeb AD |
8580 | 2001-12-27 Akim Demaille <akim@epita.fr> |
8581 | ||
8582 | * src/output.c (prepare): Drop the muscle `ntbase' which | |
8583 | duplicates ntokens. | |
8584 | * src/bison.simple: Formatting/comment changes. | |
8585 | Use YYNTOKENS only, which is documented, but not YYNTBASE, which | |
8586 | is an undocumented synonym. | |
8587 | ||
1fa14068 AD |
8588 | 2001-12-22 Akim Demaille <akim@epita.fr> |
8589 | ||
8590 | * src/output.c (output_table_data): Change the prototype to use | |
8591 | `int' for array ranges: some invocations do pass an int, not a | |
8592 | short. | |
8593 | Reported by Wayne Green. | |
8594 | ||
b9752825 AD |
8595 | 2001-12-22 Akim Demaille <akim@epita.fr> |
8596 | ||
8597 | Some actions of web2c.y are improperly triggered. | |
8598 | Reported by Mike Castle. | |
8599 | ||
8600 | * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/. | |
8601 | * tests/regression.at (Web2c): Rename as... | |
8602 | (Web2c Report): this. | |
8603 | (Web2c Actions): New. | |
8604 | ||
776209d6 AD |
8605 | 2001-12-22 Akim Demaille <akim@epita.fr> |
8606 | ||
8607 | Reductions in web2c.y are improperly reported. | |
8608 | Reported by Mike Castle. | |
8609 | ||
8610 | * src/conflicts.c (print_reductions): Fix. | |
8611 | * tests/regression.at (Web2c): New. | |
8612 | ||
275fc3ad AD |
8613 | 2001-12-18 Akim Demaille <akim@epita.fr> |
8614 | ||
8615 | Some host fail on `assert (!"foo")', which expands to | |
8616 | ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__)) | |
8617 | Reported by Nelson Beebee. | |
8618 | ||
8619 | * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with | |
8620 | `#define it_succeeded 0' and `assert (it_succeeded)'. | |
8621 | ||
897668ee MA |
8622 | 2001-12-17 Marc Autret <autret_m@epita.fr> |
8623 | ||
8624 | * src/bison.simple: Don't hard code the skeleton line and filename. | |
8625 | * src/output.c (output_parser): Rename 'line' as 'output_line'. | |
8626 | New line counter 'skeleton_line' (skeleton-line muscle). | |
8627 | ||
ab3399e0 PE |
8628 | 2001-12-17 Paul Eggert <eggert@twinsun.com> |
8629 | ||
8630 | * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that | |
8631 | YYDEBUG must be defined to a nonzero value. | |
8632 | ||
8633 | * src/bison.simple (yytname): Do not assume that the user defines | |
8634 | YYDEBUG to a properly parenthesized expression. | |
8635 | ||
3877f72b AD |
8636 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8637 | ||
8638 | * src/state.h (state_t): Rename lookaheads as lookaheadsp. | |
8639 | nlookaheads is a new member. | |
8640 | Adjust all users. | |
8641 | * src/lalr.h (nlookaheads): Remove this orphan declaration. | |
8642 | * src/lalr.c (initialize_lookaheads): Set nlookaheads for each | |
8643 | state. | |
776209d6 | 8644 | |
331dbc1b AD |
8645 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8646 | ||
8647 | * src/files.h, src/files.c (open_files, close_files): Remove. | |
8648 | * src/main.c (main): Don't open/close files, nor invoke lex_free, | |
8649 | let... | |
8650 | * src/reader.c (reader): Do it. | |
776209d6 | 8651 | |
be750e4c AD |
8652 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8653 | ||
8654 | * src/conflicts.c (print_reductions): Formatting changes. | |
776209d6 | 8655 | |
709ae8c6 AD |
8656 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8657 | ||
8658 | * src/conflicts.c (flush_shift): Also adjust lookaheadset. | |
8659 | (flush_reduce): New. | |
8660 | (resolve_sr_conflict): Adjust. | |
776209d6 | 8661 | |
f87685c3 AD |
8662 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8663 | ||
8664 | * src/output.c (output_obstack): Be static and rename as... | |
8665 | (format_obstack): this, to avoid any confusion with files.c's | |
8666 | output_obstack. | |
8667 | * src/reader.h (muscle_obstack): Move to... | |
8668 | * src/output.h: here, since it's defined in output.c. | |
8669 | ||
837491d8 AD |
8670 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8671 | ||
8672 | * src/output.c (action_row, save_column, default_goto) | |
8673 | (sort_actions, matching_state, pack_vector): Better variable | |
8674 | locality. | |
8675 | ||
796d61fb AD |
8676 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8677 | ||
8678 | * src/output.c: Various formatting changes. | |
776209d6 | 8679 | |
64d15509 AD |
8680 | 2001-12-17 Akim Demaille <akim@epita.fr> |
8681 | ||
8682 | * src/files.c (output_files): Free the output_obstack. | |
8683 | * src/main.c (main): Call print and print_graph conditionally. | |
8684 | * src/print.c (print): Work unconditionally. | |
8685 | * src/print_graph.c (print_graph): Work unconditionally. | |
8686 | * src/conflicts.c (log_resolution): Output only if verbose_flag. | |
8687 | ||
fbc8ecb7 MA |
8688 | 2001-12-16 Marc Autret <autret_m@epita.fr> |
8689 | ||
8690 | * src/output.c (actions_output): Fix. When we use %no-lines, | |
8691 | there is one less line per action. | |
8692 | ||
f0440388 MA |
8693 | 2001-12-16 Marc Autret <autret_m@epita.fr> |
8694 | ||
8695 | * src/bison.simple: Remove a useless #line directive. | |
8696 | s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'. | |
8697 | * src/output.c (get_lines_number): New. | |
776209d6 | 8698 | (output_parser): Adjust, now takes care about the lines of a |
f0440388 MA |
8699 | output muscles. |
8700 | Fix line numbering. | |
8701 | (actions_output): Computes the number of lines taken by actions. | |
8702 | (output_master_parser): Insert new skeleton which is the name of | |
8703 | the output parser file name. | |
8704 | ||
a79986b8 MA |
8705 | 2001-12-15 Marc Autret <autret_m@epita.fr> |
8706 | ||
8707 | * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility. | |
8708 | ||
4ec8e00f MA |
8709 | 2001-12-15 Marc Autret <autret_m@epita.fr> |
8710 | ||
8711 | * src/output.c (output_gram): Keep track of the hairy one. | |
8712 | ||
1a4648ff AD |
8713 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8714 | ||
8715 | Make `make distcheck' work. | |
8716 | ||
8717 | * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses | |
8718 | system.h which uses libgettext.h. | |
8719 | ||
9c2c67e6 AD |
8720 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8721 | ||
8722 | * src/nullable.c (set_nullable): Useless rules must be skipped, | |
8723 | otherwise, since we range over their symbols, we might look at a | |
8724 | nonterminal which no longer ``exists'', i.e., it is not counted in | |
8725 | `nvars', hence we overflow our arrays. | |
8726 | ||
93ede233 AD |
8727 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8728 | ||
8729 | The header can also be produced directly, without any obstack! | |
8730 | Yahoo! | |
8731 | ||
8732 | * src/files.c, src/files.h (defines_obstack): Remove. | |
8733 | (compute_header_macro): Global. | |
8734 | (defines_obstack_save): Remove. | |
8735 | * src/reader.c (parse_union_decl): No longer output to | |
8736 | defines_obstack: its content can be found in the `stype' muscle | |
8737 | anyway. | |
8738 | (output_token_translations): Merge into... | |
8739 | (symbols_output): this. | |
8740 | Rename as... | |
8741 | (symbols_save): this. | |
8742 | (reader): Adjust. | |
8743 | * src/output.c (header_output): New. | |
8744 | (output): Call it. | |
8745 | ||
2666f928 AD |
8746 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8747 | ||
8748 | * src/reader.c (parse_union_decl): Instead of handling two obstack | |
8749 | simultaneously, use one to define the `stype' muscle, and use the | |
8750 | value of the latter to fill defines_obstack. | |
8751 | (copy_comment): Remove. | |
8752 | (copy_comment2): Work for a single obstack. | |
8753 | Rename as... | |
8754 | (copy_comment): this. | |
8755 | ||
428046f8 AD |
8756 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8757 | ||
8758 | * src/lex.c, src/lex.h (xgetc): No longer static. | |
8759 | * src/reader.c (parse_union_decl): Revamp. | |
8760 | ||
ea52d706 AD |
8761 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8762 | ||
8763 | Still making progress in separating Bison into (i) input, (ii) | |
8764 | process, (iii) output: now we can directly output the parser file | |
8765 | without using table_obstack at all. | |
8766 | ||
8767 | * src/files.c, src/files.h (table_obstack): Bye bye. | |
8768 | (parser_file_name): New. | |
8769 | * src/files.c (compute_output_file_names): Compute it. | |
8770 | * src/output.c (actions_output, output_parser) | |
8771 | (output_master_parser): To a file instead of an obstack. | |
8772 | ||
3f96f4dc AD |
8773 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8774 | ||
8775 | Attach actions to rules, instead of pre-outputting them to | |
8776 | actions_obstack. | |
8777 | ||
8778 | * src/gram.h (rule_t): action and action_line are new members. | |
8779 | * src/reader.c (symbol_list): Likewise. | |
8780 | (copy_action): Save the actions within the rule. | |
8781 | (packgram): Save them in rule_table. | |
8782 | * src/output.c (actions_output): New. | |
8783 | (output_parser): Use it on `%%actions'. | |
8784 | (output_rule_data): Don't free rule_table. | |
8785 | (output): Do it. | |
8786 | (prepare): Don't save the `action' muscle. | |
8787 | * src/bison.simple: s/%%action/%%actions/. | |
8788 | ||
51576fb3 AD |
8789 | 2001-12-15 Akim Demaille <akim@epita.fr> |
8790 | ||
8791 | * src/reader.c (copy_action): When --yacc, don't append a `;' | |
8792 | to the user action: let it fail if lacking. | |
dee049eb | 8793 | Suggested by Arnold Robbins and Tom Tromey. |
51576fb3 | 8794 | |
2648a72d AD |
8795 | 2001-12-14 Akim Demaille <akim@epita.fr> |
8796 | ||
8797 | * src/lex.c (literalchar): Simply return the char you decoded, non | |
8798 | longer mess around with obstacks and int pointers. | |
8799 | Adjust all callers. | |
8800 | ||
92790e5b AD |
8801 | 2001-12-14 Akim Demaille <akim@epita.fr> |
8802 | ||
8803 | * src/lex.c (literalchar): Don't escape the special characters, | |
8804 | just decode them, and keep them as char (before, eol was output as | |
8805 | the 2 char string `\n' etc.). | |
8806 | * src/output.c (output_rule_data): Use quotearg to output the | |
8807 | token strings. | |
8808 | ||
927c1557 PE |
8809 | 2001-12-13 Paul Eggert <eggert@twinsun.com> |
8810 | ||
8811 | * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE): | |
8812 | Do not infringe on the global user namespace when using C++. | |
8813 | (YYFPRINTF, YYSTDERR): New macros, needed for the above. | |
8814 | All uses of `fprintf' and `stderr' changed. | |
8815 | ||
8816 | * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR. | |
8817 | ||
ed8e1f68 AD |
8818 | 2001-12-13 Akim Demaille <akim@epita.fr> |
8819 | ||
8820 | The computation of nullable is broken: it doesn't handle empty | |
8821 | RHS's properly. | |
8822 | ||
8823 | * tests/torture.at (GNU AWK Grammar): New. | |
8824 | * tests/sets.at (Nullable): New. | |
8825 | * src/nullable.c (set_nullable): Instead of blindly looping over | |
8826 | `ritems', loop over the rules, and then over their rhs's. | |
8827 | ||
8828 | Work around Autotest bugs. | |
8829 | ||
8830 | * src/warshall.c (bitmatrix_print): Don't use `+--+' as table | |
8831 | frame, because Autotest understand lines starting with a `+' as | |
8832 | traces from the shell. Then, they are not processed properly. | |
8833 | Admittedly an Autotest bug, but we don't have time to wait for | |
8834 | Autotest to catch up. | |
8835 | * tests/regression.at (Broken Closure): Adjust to the new table | |
8836 | frames. | |
8837 | Move to... | |
8838 | * tests/sets.at: here. | |
8839 | ||
cb581495 AD |
8840 | 2001-12-13 Akim Demaille <akim@epita.fr> |
8841 | ||
8842 | * src/closure.c (closure): Use nrules instead of playing tricks | |
8843 | with BITS_PER_WORD. | |
8844 | ||
2e729273 AD |
8845 | 2001-12-13 Akim Demaille <akim@epita.fr> |
8846 | ||
8847 | * src/print.c (print_actions): Output the handling of `$' as the | |
8848 | traces do: shifting the token EOF. Before EOF was treated as a | |
8849 | nonterminal. | |
8850 | * tests/regression.at: Adjust some tests. | |
8851 | * src/print_graph.c (print_core): Complete the set of items via | |
8852 | closure. The next-to-final and final states are still unsatisfying, | |
8853 | but that's to be addressed elsewhere. | |
8854 | No longer output the rule numbers, but do output the state number. | |
8855 | A single loop for the shifts + gotos is enough, but picked a | |
8856 | distinct color for each. | |
8857 | (print_graph): Initialize and finalize closure. | |
8858 | ||
107f7dfb AD |
8859 | 2001-12-13 Akim Demaille <akim@epita.fr> |
8860 | ||
8861 | * src/reader.c (readgram): Remove dead code, an strip useless | |
8862 | braces. | |
8863 | (get_type): Remove, unused. | |
8864 | ||
9b53a24f AD |
8865 | 2001-12-12 Akim Demaille <akim@epita.fr> |
8866 | ||
8867 | * src/complain.h, src/complain.c: Remove error_one_per_line, rely | |
8868 | on that of lib/error.c. | |
8869 | ||
dbfb6dcd AD |
8870 | 2001-12-12 Akim Demaille <akim@epita.fr> |
8871 | ||
8872 | Some hosts don't like `/' in includes. | |
8873 | ||
8874 | * src/system.h: Include libgettext.h without qualifying the path. | |
8875 | * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove | |
8876 | $(top_srcdir). | |
8877 | ||
c25fb648 MA |
8878 | 2001-12-11 Marc Autret <autret_m@epita.fr> |
8879 | ||
8880 | * src/output.c (output_parser): Remove useless muscle. | |
8881 | ||
710ddc4f MA |
8882 | 2001-12-11 Marc Autret <autret_m@epita.fr> |
8883 | ||
8884 | * src/bison.simple: Remove #line just before %%epilogue. It | |
8885 | is now handled in ... | |
8886 | * src/reader.c (read_additionnal_code): Add the output of a | |
8887 | #line for the epilogue. | |
8888 | ||
e83d80b8 MA |
8889 | 2001-12-10 Marc Autret <autret_m@epita.fr> |
8890 | ||
927c1557 | 8891 | * src/reader.c (copy_definition): Re-use CPP-outed code which |
e83d80b8 MA |
8892 | replace precedent remove. |
8893 | * src/bison.simple: Remove #line before %%prologue because | |
8894 | %%input-line is wrong at this time. | |
8895 | ||
971d5158 MA |
8896 | 2001-12-10 Marc Autret <autret_m@epita.fr> |
8897 | ||
8898 | * src/reader.c (symbols_output): Clean up. | |
927c1557 | 8899 | * src/output.c (output_gram, output): Clean up. |
971d5158 | 8900 | |
5edafffd AD |
8901 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8902 | ||
8903 | * src/lalr.c (initialize_lookaheads): New. Extracted from... | |
8904 | * src/LR0.c (set_state_table): here. | |
8905 | * src/lalr.c (lalr): Call it. | |
8906 | ||
0279f8e9 AD |
8907 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8908 | ||
8909 | * src/state.h (shifts): Remove the `number' member: shifts are | |
8910 | attached to state, hence no longer need to be labelled with a | |
8911 | state number. | |
8912 | ||
190c4f5f AD |
8913 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8914 | ||
8915 | Now that states have a complete set of members, the linked list of | |
8916 | shifts is useless: just fill directly the state's shifts member. | |
8917 | ||
8918 | * src/state.h (shifts): Remove the `next' member. | |
8919 | * src/LR0.c (first_state, last_state): Remove. | |
8920 | Adjust the callers. | |
8921 | (augment_automaton): Don't look for the shifts that must be added | |
8922 | a shift on EOF: it is those of the state we looked for! But now, | |
8923 | since shifts are attached, it is no longer needed to looking | |
8924 | merely by its id: its number. | |
8925 | ||
2a73b93d AD |
8926 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8927 | ||
8928 | * src/LR0.c (augment_automaton): Better variable locality. | |
8929 | Remove an impossible branch: if there is a state corresponding to | |
8930 | the start symbol being shifted, then there is shift for the start | |
8931 | symbol from the initial state. | |
8932 | ||
74392f6a AD |
8933 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8934 | ||
8935 | * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state' | |
8936 | only when appropriate: when insert_start_shifting_state' is not | |
8937 | invoked. | |
8938 | * tests/regression.at (Rule Line Numbers): Adjust. | |
8939 | ||
37c82725 AD |
8940 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8941 | ||
8942 | * src/LR0.c (augment_automaton): Now that all states have shifts, | |
8943 | merge the two cases addition shifts to the initial state. | |
8944 | ||
6a164e0c AD |
8945 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8946 | ||
8947 | * src/lalr.c (set_state_table): Move to... | |
8948 | * src/LR0.c: here. | |
8949 | * src/lalr.c (lalr): Don't call it... | |
8950 | * src/LR0.c (generate_states): do it. | |
8951 | * src/LR0.h (first_state): Remove, only the table is used. | |
8952 | ||
7215de24 AD |
8953 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8954 | ||
8955 | * src/LR0.h (first_shift, first_reduction): Remove. | |
8956 | * src/lalr.c: Don't use first_shift: find shifts through the | |
8957 | states. | |
8958 | ||
80e25d4d AD |
8959 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8960 | ||
8961 | * src/LR0.c: Attach shifts to states as soon as they are | |
8962 | computed. | |
8963 | * src/lalr.c (set_state_table): Instead of assigning shifts to | |
8964 | state, just assert that the mapping was properly done. | |
8965 | ||
0ab3728b AD |
8966 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8967 | ||
8968 | * src/LR0.c (insert_start_shift): Rename as... | |
8969 | (insert_start_shifting_state): this. | |
8970 | (insert_eof_shifting_state, insert_accepting_state): New. | |
8971 | (augment_automaton): Adjust. | |
8972 | Better locality of the variables. | |
8973 | When looking if the start_symbol is shifted from the initial | |
8974 | state, using `while (... symbol != start_symbol ...)' sounds | |
8975 | better than `while (... symbol < start_symbol ...)': If fail | |
8976 | to see how the order between symbols could be relevant! | |
8977 | ||
78af9bbc AD |
8978 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8979 | ||
8980 | * src/getargs.h: Don't declare `spec_name_prefix' and | |
8981 | `spec_file_prefix', declared by src/files.h. | |
8982 | * src/files.c, src/files.h: Default for spec_name_prefix is "yy". | |
8983 | * src/muscle_tab.c (muscle_init): Default prefix to NULL. | |
8984 | * src/output.c (prepare): Adjust. | |
8985 | * src/reader.c (symbols_output): Likewise. | |
8986 | * src/vmsgetargs.c: Vaguely adjust, but who cares? | |
8987 | ||
bdef2a41 AD |
8988 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8989 | ||
8990 | * src/muscle_tab.c (muscle_init): NULL is a better default than | |
8991 | `"0"'. | |
8992 | ||
3735969c AD |
8993 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8994 | ||
8995 | * src/reader.c (reader): Calling symbols_output once is enough. | |
8996 | ||
49701457 AD |
8997 | 2001-12-10 Akim Demaille <akim@epita.fr> |
8998 | ||
8999 | Now that states have a complete set of members, the linked list of | |
9000 | reductions is useless: just fill directly the state's reductions | |
9001 | member. | |
9002 | ||
9003 | * src/state.h (struct reductions): Remove member `number' and | |
9004 | `next'. | |
9005 | * src/LR0.c (first_reduction, last_reduction): Remove. | |
9006 | (save_reductions): Don't link the new reductions, store them in | |
9007 | this_state. | |
9008 | * src/lalr.c (set_state_table): No need to attach reductions to | |
9009 | states, it's already done. | |
9010 | * src/output.c (output_actions): No longer free the shifts, then | |
9011 | the reductions, then the states: free all the states and their | |
9012 | members. | |
9013 | ||
0edad749 AD |
9014 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9015 | ||
9016 | * src/options.c (OPTN, DRTV, BOTH): New. | |
9017 | (option_table): Use them. | |
9018 | ||
0edad749 AD |
9019 | * src/muscle_tab.c: Don't include xalloc.h and string.h: that's |
9020 | the job of system.h. | |
9021 | * src/options.c: Don't include stdio.h and xalloc.h for the same | |
9022 | reasons. | |
9023 | ||
5449dd0f AD |
9024 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9025 | ||
9026 | * src/output.c (output, prepare): Make sure the values of the | |
9027 | muscles `action' and `prologue' are 0-terminated. | |
9028 | ||
a870c567 AD |
9029 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9030 | ||
9031 | Clean up GCC warnings. | |
9032 | ||
9033 | * src/reader.c (copy_action): `buf' is not used. | |
9034 | (parse_skel_decl): Be static. | |
9035 | * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'. | |
9036 | * src/options.h (create_long_option_table): Have a real prototype. | |
9037 | * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete) | |
9038 | (hash_delete_at): Return const void *. | |
9039 | Adjust casts to preserve the const. | |
9040 | ||
80df8768 AD |
9041 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9042 | ||
9043 | * configure.in: Require 2.52g. | |
9044 | M4 is not needed, but AUTOM4TE is. | |
9045 | * m4/m4.m4: Remove. | |
9046 | * tests/Makefile.am: Adjust. | |
9047 | ||
f693ad14 AD |
9048 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9049 | ||
9050 | One structure for states is enough, even though theoretically | |
9051 | there are LR(0) states and LALR(1) states. | |
9052 | ||
9053 | * src/lalr.h (state_t): Remove. | |
9054 | (state_table): Be state_t **, not state_t *. | |
9055 | * src/state.h (core, CORE_ALLOC): Rename as... | |
9056 | (state_t, STATE_ALLOC): this. | |
9057 | Add the LALR(1) members: shifts, reductions, errs. | |
9058 | * src/LR0.c (state_table): Rename as... | |
9059 | (state_hash): this, to avoid name clashes with the global | |
9060 | `state_table'. | |
9061 | * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c | |
9062 | * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust. | |
9063 | ||
74ffbcb6 AD |
9064 | 2001-12-10 Akim Demaille <akim@epita.fr> |
9065 | ||
9066 | Bison dumps core on bash.y. | |
9067 | Reported by Pascal Bart. | |
9068 | ||
9069 | * src/warshall.c (bitmatrix_print): New. | |
9070 | (TC): Use it. | |
9071 | When performing a transitive closure R(i, j) && R(j, k) => R(i, k), | |
9072 | j must be the outer loop. | |
9073 | * tests/regression.at (Broken Closure): New. | |
9074 | ||
07708e19 AD |
9075 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9076 | ||
9077 | * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and | |
9078 | its argument. | |
ba1ecc07 | 9079 | Reported by Peter Hamorsky. |
07708e19 | 9080 | |
92b16366 AD |
9081 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9082 | ||
9083 | * src/conflicts.c (err_table): Remove. | |
9084 | (resolve_sr_conflict): Adjust. | |
9085 | * src/lalr.h (state_t.reduction_table, state_t.shift_table): | |
9086 | Rename as... | |
9087 | (state_t.reductions, state_t.shifts): this. | |
9088 | ||
076ab033 AD |
9089 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9090 | ||
9091 | * src/reduce.c (reduce_grammar_tables): No longer disable the | |
9092 | removal of useless rules via CPP but via `if (0)', so that the | |
9093 | compiler still check the code is valid. | |
9094 | For instance, it should have noticed `rline' no longer exists: use | |
9095 | the `line' member of rule_t. | |
9096 | * src/gram.c (dummy, rline): Remove, unused. | |
9097 | ||
3843c413 AD |
9098 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9099 | ||
9100 | * src/output.c (pack_vector): Use assert, not berror. | |
9101 | * src/main.c (berror): Remove, unused. | |
9102 | ||
43168960 AD |
9103 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9104 | ||
9105 | New experimental feature: if --verbose --trace output all the | |
9106 | items of a state, not only its kernel. | |
9107 | ||
9108 | * src/print.c (print_core): If `trace_flag', then invoke closure | |
9109 | before outputting the items of the state (print_core is no longer | |
9110 | a correct name them). | |
9111 | (print_results): Invoke new_closure/free_closure if needed. | |
9112 | ||
b2872512 AD |
9113 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9114 | ||
9115 | * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount. | |
9116 | * src/closure.c, src/closure.h (itemsetsize): Rename as... | |
9117 | (nitemset): for consistency with the rest of the project. | |
9118 | ||
23cbcc6c AD |
9119 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9120 | ||
9121 | * src/closure.c (print_closure): Improve. | |
9122 | (closure): Use it for printing input and output. | |
9123 | ||
03ec521c AD |
9124 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9125 | ||
9126 | * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are | |
9127 | indexed by nonterminals. | |
9128 | ||
3a7456dd AD |
9129 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9130 | ||
9131 | * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of | |
9132 | what it was!). | |
9133 | * src/warshall.h: Remove accidental duplication of the content. | |
9134 | ||
1cbcf2e7 AD |
9135 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9136 | ||
9137 | * src/closure.c (set_fderives): De-obfuscate. | |
9138 | ||
84182270 AD |
9139 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9140 | ||
9141 | * src/closure.c (print_firsts, print_fderives): De-obfuscate. | |
9142 | ||
3f6f053c AD |
9143 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9144 | ||
9145 | * src/closure.c (set_firsts): De-obfuscate. | |
9146 | ||
7a5350ba AD |
9147 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9148 | ||
9149 | * src/output.c (action_row): De-obfuscate | |
9150 | using the good o' techniques: arrays not pointers, variable | |
9151 | locality, BITISSET, RESETBIT etc. | |
9152 | ||
d954473d AD |
9153 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9154 | ||
9155 | Pessimize the code to simplify it: from now on, all the states | |
9156 | have a valid SHIFTS, which NSHIFTS is possibly 0. | |
9157 | ||
9158 | * src/LR0.c (shifts_new): Be global and move to.. | |
9159 | * src/state.c, src/state.h: here. | |
9160 | * src/conflicts, src/lalr.c, src/output.c, src/print.c, | |
9161 | * src/print_graph: Adjust. | |
9162 | ||
9839bbe5 AD |
9163 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9164 | ||
9165 | * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New. | |
9166 | * src/conflicts.c: Use it. | |
9167 | Restore a few missing `if (!SHIFT_IS_DISABLED)' which were | |
9168 | incorrectly ``simplified''. | |
9169 | ||
9f136c07 AD |
9170 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9171 | ||
9172 | * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate | |
9173 | using the good o' techniques: arrays not pointers, variable | |
9174 | locality, BITISSET, RESETBIT etc. | |
9175 | ||
b608206e AD |
9176 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9177 | ||
9178 | * src/state.h (SHIFT_SYMBOL): New. | |
9179 | * src/conflicts.c: Use it to deobfuscate. | |
9180 | ||
52afa962 AD |
9181 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9182 | ||
9183 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts) | |
9184 | (print_reductions): De-obfuscate using the good o' techniques: | |
9185 | arrays not pointers, variable locality, BITISSET. | |
9186 | ||
e74dc321 AD |
9187 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9188 | ||
9189 | * src/conflicts.c (print_reductions): Arrays, not pointers. | |
9190 | Use BITISSET. | |
9191 | ||
768fca83 AD |
9192 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9193 | ||
9194 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
9195 | ||
a17e599f AD |
9196 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9197 | ||
9198 | * src/conflicts.c (print_reductions): Improve variable locality. | |
9199 | ||
a04bc341 AD |
9200 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9201 | ||
9202 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
9203 | ||
c8ea038e AD |
9204 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9205 | ||
9206 | * src/conflicts.c (print_reductions): Improve variable locality. | |
9207 | ||
aa2aab3c AD |
9208 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9209 | ||
9210 | * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New. | |
9211 | * src/lalr.c: Use them. | |
9212 | ||
b178c8cc AD |
9213 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9214 | ||
9215 | * src/LR0.c (augment_automaton): Formatting changes. | |
9216 | Better variable locality. | |
9217 | ||
f67d13aa AD |
9218 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9219 | ||
9220 | * src/lalr.c (matrix_print): New. | |
9221 | (transpose): Use it. | |
9222 | Use arrays instead of pointers. | |
9223 | ||
c2713865 AD |
9224 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9225 | ||
9226 | * src/lalr.c (maxrhs): Move to... | |
9227 | * src/gram.c, src/gram.h (ritem_longest_rhs): here. | |
9228 | * src/lalr.c (build_relations): Adjust. | |
9229 | ||
9887c18a AD |
9230 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9231 | ||
9232 | * src/lalr.c (transpose): Free the memory allocated to the | |
9233 | argument, as it is replaced by the results by the unique caller. | |
9234 | (build_relations): Merely invoke transpose: it handles the memory | |
9235 | deallocation. | |
9236 | Improve variable locality. | |
9237 | Avoid variables used as mere abbreviations. | |
9238 | (compute_lookaheads): Use arrays instead of pointers. | |
9239 | ||
4d4f699c AD |
9240 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9241 | ||
9242 | * src/lalr.c (initialize_F): Improve variable locality. | |
9243 | Avoid variables used as mere abbreviations. | |
9244 | ||
80a69750 AD |
9245 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9246 | ||
9247 | * src/derives.c (print_derives): Display the ruleno. | |
9248 | * src/lalr.c (initialize_F, transpose): Better variable locality | |
9249 | to improve readability. | |
9250 | Avoid variables used as mere abbreviations. | |
9251 | ||
fe961097 AD |
9252 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9253 | ||
9254 | * src/lalr.c (traverse): Use arrays instead of pointers. | |
9255 | ||
e3e4e814 AD |
9256 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9257 | ||
9258 | * src/nullable.c (set_nullable): Use a for loop to de-obfuscate | |
9259 | the handling of squeue. | |
9260 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
9261 | ||
630e182b AD |
9262 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9263 | ||
9264 | Because useless nonterminals are now kept alive (instead of being | |
9265 | `destroyed'), we now sometimes examine them, and store information | |
9266 | related to them. Hence we need to know their number, and adjust | |
9267 | memory allocations. | |
9268 | ||
9269 | * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer | |
9270 | static. | |
9271 | * src/LR0.c (allocate_itemsets): The memory allocated to | |
9272 | `symbol_count' was used for two different purpose: once to count | |
9273 | the number of occurrences of each symbol, and later reassigned to | |
9274 | `shift_symbol', containing the symbol that can be shifted from a | |
9275 | given state. | |
9276 | Deobfuscate, i.e., allocate, use and free `symbol_count' here | |
9277 | only, and... | |
9278 | (new_itemsets): Allocate `shift_symbol' here. | |
9279 | (allocate_itemsets): symbol_count includes useless nonterminals. | |
9280 | Make room for them. | |
9281 | (free_storage): Use `free', not `XFREE', for pointers that cannot | |
9282 | be null. | |
9283 | ||
81b51460 AD |
9284 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9285 | ||
9286 | * src/nullable.c (set_nullable): Deobfuscate the handling of | |
9287 | ritem. | |
9288 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
9289 | ||
3067fbef AD |
9290 | 2001-12-05 Akim Demaille <akim@epita.fr> |
9291 | ||
9292 | * src/gram.c, src/gram.h (ritem_print): New. | |
9293 | * src/gram.c (dummy): Remove, now there is actual code in gram.c. | |
9294 | (This useless function was defined only to work around VMS linkers | |
9295 | that can't handle compilation units with variables only). | |
9296 | * src/reduce.c (dump_grammar): Use it to trace the construction of | |
9297 | ritem. | |
9298 | ||
c2bea5f9 PE |
9299 | 2001-12-04 Paul Eggert <eggert@twinsun.com> |
9300 | ||
7d27c823 PE |
9301 | * src/bison.simple (union yyalloc): Change member names |
9302 | to be the same as the stack names. | |
9303 | (yyparse): yyptr is now union yyalloc *, not char *. | |
9304 | (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning, | |
9305 | and may generate better code on some machines. | |
c2bea5f9 PE |
9306 | (yystpcpy): Use prototype if __STDC__ is defined, not just |
9307 | if __cplusplus is defined. | |
35687a9d | 9308 | |
2c8a9dfa AD |
9309 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9310 | ||
9311 | * configure.in (WARNING_CFLAGS): Add -Werror when possible. | |
9312 | (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU | |
9313 | Gettext doesn't compile cleanly, and dies with -Werror. | |
9314 | * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS): | |
9315 | Include WARNING_CFLAGS here. | |
9316 | * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared | |
9317 | before being defined. | |
9318 | ||
f4e421e6 AD |
9319 | 2001-11-27 Paul Eggert <eggert@twinsun.com> |
9320 | ||
9321 | * lib/quotearg.h (quotearg_n, quotearg_n_style): | |
9322 | First arg is int, not unsigned. | |
9323 | * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise. | |
9324 | (SIZE_MAX, UINT_MAX): New macros. | |
9325 | (quotearg_n_options): Abort if N is negative. | |
9326 | Avoid overflow check on hosts where size_t is 64 bits and int | |
9327 | is 32 bits, as overflow is impossible there. | |
9328 | Fix off-by-one typo that caused unnecessary reallocation. | |
9329 | ||
7093d0f5 AD |
9330 | 2001-11-29 Paul Eggert <eggert@twinsun.com> |
9331 | ||
9332 | Name space cleanup in generated parser. | |
9333 | ||
9334 | * doc/bison.texinfo (Bison Parser): Discuss system headers | |
9335 | and their effect on the user name space. | |
9336 | ||
9337 | * src/bison.simple: | |
9338 | (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX, | |
9339 | YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary, | |
9340 | i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE). | |
9341 | ||
9342 | (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing | |
9343 | on user names when possible. | |
9344 | ||
9345 | (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn. | |
9346 | Simplify test for whather <alloca.h> exists. | |
9347 | ||
9348 | (<stdlib.h>): Include if we will use malloc, and if standard C or C++. | |
9349 | ||
9350 | (<stdio.h>): Include if YYDEBUG. | |
9351 | ||
9352 | (yymemcpy): Renamed from __yy_memcpy. Do not define unless | |
9353 | ! defined (yyoverflow) && ! defined (yymemcpy). | |
9354 | ||
9355 | (yymemcpy, yyparse): Rename local variables as needed so that | |
9356 | they all begin with 'yy'. | |
9357 | ||
9358 | (yystrlen, yystpcpy): New functions. | |
9359 | ||
9360 | (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES. | |
9361 | All uses changed. | |
9362 | ||
9363 | (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy | |
9364 | instead of relying on string.h functions. Use YYSTACK_ALLOC | |
9365 | and YYSTACK_FREE instead of malloc and free. | |
9366 | ||
fd51e5ff AD |
9367 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9368 | ||
9369 | * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions | |
9370 | before their first uses. | |
9371 | (YYBISON, YYPURE): Move to the top of the output. | |
9372 | ||
7d13ff5f AD |
9373 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9374 | ||
9375 | * tests/reduce.at (Useless Nonterminals): Fix. | |
9376 | ||
892a3995 AD |
9377 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9378 | ||
9379 | * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty | |
9380 | if body instead of `;' to pacify GCC's warnings. | |
9381 | ||
68f1e3ed AD |
9382 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9383 | ||
9384 | Instead of mapping the LHS of unused rules to -1, keep the LHS | |
9385 | valid, but flag the rules as invalid. | |
9386 | ||
9387 | * src/gram.h (rule_t): `useful' is a new member. | |
9388 | * src/print.c (print_grammar): Adjust. | |
9389 | * src/derives.c (set_derives): Likewise. | |
9390 | * src/reader.c (packgram, reduce_output): Likewise. | |
9391 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
9392 | * tests/reduce.at (Underivable Rules, Useless Rules): New. | |
9393 | ||
d2d1b42b AD |
9394 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9395 | ||
9396 | * src/reduce.c (reduce_output): Formatting changes. | |
9397 | * src/print.c (print_results, print_grammar): Likewise. | |
9398 | * tests/regression.at (Rule Line Numbers) | |
9399 | (Solved SR Conflicts, Unresolved SR Conflicts): Adjust. | |
9400 | ||
760b53a8 AD |
9401 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9402 | ||
9403 | * src/reduce.c (nonterminals_reduce): Instead of throwing away | |
9404 | useless nonterminals, move them at the end of the symbol arrays. | |
9405 | (reduce_output): Adjust. | |
9406 | * tests/reduce.at (Useless Nonterminals): Adjust. | |
9407 | ||
00238958 AD |
9408 | 2001-11-30 Akim Demaille <akim@epita.fr> |
9409 | ||
9410 | * src/reduce.c: Various comment/formatting changes. | |
9411 | (nonterminals_reduce): New, extracted from... | |
9412 | (reduce_grammar_tables): here. | |
9413 | (reduce_grammar): Call nonterminals_reduce. | |
9414 | ||
396452de PE |
9415 | 2001-11-29 Paul Eggert <eggert@twinsun.com> |
9416 | ||
9417 | * src/bison.simple (YYSTACK_REALLOC): Remove. | |
9418 | (YYSTACK_ALLOC): Resurrect this macro, with its old meaning. | |
9419 | (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE): | |
9420 | New macros. | |
9421 | (union yyalloc): New type. | |
9422 | (__yy_memcpy): Last arg is size_t, not unsigned int, to remove | |
9423 | an arbitrary restriction on hosts where size_t is wider than int. | |
9424 | ||
9425 | (yyparse): Don't dump core if alloca or malloc fails; instead, report | |
9426 | a parser stack overflow. Allocate just one block of memory for all | |
9427 | three stacks, instead of allocating three blocks; this typically is | |
9428 | faster and reduces fragmentation. | |
9429 | ||
9430 | Do not limit the number of items in the stack to a value that fits | |
9431 | in 'int', as this is an arbitrary limit on hosts with 64-bit | |
9432 | size_t and 32-bit int. | |
9433 | ||
147e184c MA |
9434 | 2001-11-29 Marc Autret <autret_m@epita.fr> |
9435 | ||
9436 | * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead | |
9437 | of defining YYERROR_VERBOSE. | |
9438 | [AT_DATA]: $4 is now out of C declarations in the prologue. | |
9439 | ||
426cf563 MA |
9440 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
9441 | ||
9442 | * src/reader.c (parse_dquoted_param): New. | |
9443 | (parse_skel_decl): Use it. | |
9444 | * src/lex.h: Add its prototype. | |
9445 | * src/lex.c (literalchar): Become not static. | |
9446 | ||
c7925b99 MA |
9447 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
9448 | ||
9449 | * src/output.h: And put its extern declaration here. | |
9450 | * src/output.c (error_verbose): Define here. | |
9451 | (prepare): Echo name modification. | |
9452 | * src/getargs.h: Clean its extern declaration. | |
9453 | * src/getargs.c (error_verbose_flag): Remove. | |
9454 | (getargs): Remove case 'e'. | |
9455 | * src/options.c (option_table): 'error-verbose' is now seen as simple | |
9456 | percent option. | |
9457 | Include output.h. | |
9458 | ||
9459 | * src/reader.c (read_declarations): Remove case tok_include. | |
9460 | (parse_include_decl): Remove. | |
9461 | * src/lex.h (token_t): Remove tok_include. | |
9462 | * src/options.c (option_table): 'include' is now a simple command line | |
9463 | option. | |
9464 | ||
5b5d1929 MA |
9465 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
9466 | ||
9467 | * src/bison.simple: Adjust muscle names. | |
9468 | * src/muscle_tab.c (muscle_init): Also rename the muscles. | |
9469 | * src/output.c (prepare): s/_/-/ for the muscles names. | |
9470 | (output_parser): When scanning for a muscle, allow '-' instead of '_'. | |
9471 | ||
8850be4b MA |
9472 | 2001-11-28 Marc Autret <autret_m@epita.fr> |
9473 | ||
9474 | * src/bison.simple: Fix debug. | |
9475 | [YYERROR_VERBOSE]: Re-integrate as an internal macro. | |
9476 | ||
4a38e613 AD |
9477 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9478 | ||
9479 | * src/LR0.c (shifts_new): New. | |
9480 | (save_shifts, insert_start_shift, augment_automaton): Use it. | |
9481 | ||
4b35e1c1 AD |
9482 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9483 | ||
9484 | * src/closure.c (closure): `b' and `ruleno' denote the same value: | |
9485 | keep ruleno only. | |
9486 | ||
d2b04478 AD |
9487 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9488 | ||
9489 | * src/closure.c (closure): Instead of looping over word in array | |
9490 | then bits in words, loop over bits in array. | |
9491 | ||
2c4c30aa AD |
9492 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9493 | ||
9494 | * src/closure.c (closure): No longer optimize the special case | |
9495 | where all the bits of `ruleset[r]' are set to 0, to make the code | |
9496 | clearer. | |
9497 | ||
576890b7 AD |
9498 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9499 | ||
9500 | * src/closure.c (closure): `r' and `c' are new variables, used to | |
9501 | de-obfuscate accesses to RULESET and CORE. | |
9502 | ||
cb487d7d AD |
9503 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9504 | ||
9505 | * src/reduce.c (reduce_print): Use ngettext. | |
9506 | (dump_grammar): Improve the trace accuracy. | |
9507 | ||
6013d43f AD |
9508 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9509 | ||
9510 | * src/reduce.c (dump_grammar): Don't translate trace messages. | |
9511 | ||
cb4956ee AD |
9512 | 2001-11-28 Akim Demaille <akim@epita.fr> |
9513 | ||
9514 | * tests/reduce.at (Useless Terminals, Useless Nonterminals): New. | |
9515 | * src/reduce.c (reduce_grammar_tables): Do not free useless tags, | |
9516 | as all tags are free'ed afterwards. | |
9517 | From Enrico Scholz. | |
9518 | ||
648185ab PE |
9519 | 2001-11-27 Paul Eggert <eggert@twinsun.com> |
9520 | ||
9521 | * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to | |
9522 | use alloca when we didn't want to, and vice versa. | |
9523 | ||
68254a03 MA |
9524 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
9525 | ||
9113b58f AD |
9526 | * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle |
9527 | initialization. | |
68254a03 MA |
9528 | * src/output.c (prepare): Remove its update. |
9529 | ||
04d843a2 MA |
9530 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
9531 | ||
9532 | * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition. | |
9533 | Use %error-verbose. | |
9534 | ||
d2079671 | 9535 | 2001-11-27 Marc Autret <autret_m@epita.fr> |
eeeb962b MA |
9536 | |
9537 | * src/bison.simple: Remove YYERROR_VERBOSE using. | |
9538 | Use %%error_verbose. | |
9539 | (yyparse): Likewise. | |
9540 | * src/output.c (prepare): Give its final value. | |
9541 | * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'. | |
9542 | * src/getargs.h: Add its extern declaration. | |
9543 | * src/getargs.c (error_verbose_flag): New int. | |
9544 | (getargs): Update to catch new case. | |
9545 | * src/options.c (option_table): 'error-verbose' is a new option. | |
9546 | (shortopts): Update. | |
9547 | ||
e0327bc8 AD |
9548 | 2001-11-27 Akim Demaille <akim@epita.fr> |
9549 | ||
9550 | * src/system.h: Use intl/libgettext.h. | |
9551 | * src/Makefile.am (INCLUDES): Add -I $(top_srcdir). | |
9552 | ||
000f1a3c AD |
9553 | 2001-11-27 Akim Demaille <akim@epita.fr> |
9554 | ||
9555 | * tests/torture.at (Exploding the Stack Size with Malloc): | |
9556 | s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/. | |
9557 | ||
26cfe0be AD |
9558 | 2001-11-27 Akim Demaille <akim@epita.fr> |
9559 | ||
9560 | * src/files.c: Include error.h. | |
9561 | Reported by Hans Aberg. | |
9562 | ||
f6bd5427 MA |
9563 | 2001-11-26 Marc Autret <autret_m@epita.fr> |
9564 | ||
d2079671 | 9565 | * src/reader.c (parse_include_decl): New, not yet implemented. |
f6bd5427 MA |
9566 | (read_declarations): Add case tok_include. |
9567 | * src/getargs.h (include): Add its extern definition. | |
9568 | * src/getargs.c (include): New const char *. | |
9569 | (getargs): Add case '-I'. | |
9570 | * src/options.c (option_table): Add include as command line and | |
9571 | percent option. | |
9572 | * src/lex.h (token_t): Add tok_include. | |
9573 | ||
2ca209c1 AD |
9574 | 2001-11-26 Akim Demaille <akim@epita.fr> |
9575 | ||
9576 | * src/reader.c (readgram): Make sure rules for mid-rule actions | |
9577 | have a lineno equal to that of their host rule. | |
9578 | Reported by Hans Aberg. | |
9579 | * tests/regression.at (Rule Line Numbers): New. | |
9580 | ||
0e41b407 AD |
9581 | 2001-11-26 Akim Demaille <akim@epita.fr> |
9582 | ||
9583 | * src/LR0.c (allocate_itemsets): kernel_size contains ints, not | |
9584 | size_ts. | |
9585 | ||
9586 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
9587 | ||
9588 | * src/complain.c, src/complain.h (error): Remove, provided by | |
9589 | lib/error.[ch]. | |
9590 | ||
e0c40012 AD |
9591 | 2001-11-26 Akim Demaille <akim@epita.fr> |
9592 | ||
9593 | * src/reader.c (read_declarations): Don't abort on tok_illegal, | |
9594 | issue an error message. | |
9595 | * tests/regression.at (Invalid %directive): New. | |
9596 | Reported by Hans Aberg. | |
9597 | ||
5e147124 AD |
9598 | 2001-11-26 Akim Demaille <akim@epita.fr> |
9599 | ||
9600 | * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE. | |
9601 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
9602 | ||
a034c8b8 AD |
9603 | 2001-11-26 Akim Demaille <akim@epita.fr> |
9604 | ||
9605 | * src/conflicts.c (conflicts_print): Don't complain at all when | |
9606 | there are no reduce/reduce conflicts, and as many shift/reduce | |
9607 | conflicts as expected. | |
9608 | * tests/regression.at (%expect right): Adjust. | |
9609 | ||
c64a20f3 AD |
9610 | 2001-11-23 Akim Demaille <akim@epita.fr> |
9611 | ||
9612 | * lib/alloca.c: Update, from fileutils. | |
9613 | ||
5b0d29bb AD |
9614 | 2001-11-23 Akim Demaille <akim@epita.fr> |
9615 | ||
9616 | * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@. | |
9617 | ||
722c4bfe AD |
9618 | 2001-11-23 Akim Demaille <akim@epita.fr> |
9619 | ||
9620 | * src/system.h: Include alloca.h. | |
9621 | * src/main.c (main) [C_ALLOCA]: Call alloca (0). | |
9622 | ||
6255b435 AD |
9623 | 2001-11-23 Akim Demaille <akim@epita.fr> |
9624 | ||
9625 | * src/print_graph.c (print_actions): Remove `rule', unused. | |
9626 | * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to | |
9627 | pacify GCC's signed < unsigned warnings. | |
9628 | * src/closure.c (itemsetsize): Likewise. | |
9629 | * src/reader.c (symbol_list_new): Static. | |
9630 | ||
b29b2ed5 AD |
9631 | 2001-11-23 Akim Demaille <akim@epita.fr> |
9632 | ||
9633 | Attaching lineno to buckets is stupid, since only one copy of each | |
9634 | symbol is kept, only the line of the first occurrence is kept too. | |
9635 | ||
9636 | * src/symtab.h, src/symtab.c (bucket): Remove the line member. | |
9637 | * src/reader.c (rline_allocated): Remove, unused. | |
9638 | (symbol_list): Have a `line' member. | |
9639 | (symbol_list_new): New. | |
9640 | (readgram): Use it. | |
9641 | * src/print.c (print_grammar): Output the rule line numbers. | |
9642 | * tests/regression.at (Solved SR Conflicts) | |
9643 | (Unresolved SR Conflicts): Adjust. | |
9644 | Reported by Hans Aberg. | |
9645 | ||
a81b1d4a MA |
9646 | 2001-11-22 Marc Autret <autret_m@epita.fr> |
9647 | ||
9648 | * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0. | |
9649 | ||
c1ecb3c1 MA |
9650 | 2001-11-22 Marc Autret <autret_m@epita.fr> |
9651 | ||
9652 | * src/muscle_tab.c (muscle_init): Remove initialization of | |
9653 | skeleton muscle. | |
9654 | * src/output.c (output_master_parser): Do it here. | |
9655 | ||
fbe01355 AD |
9656 | 2001-11-20 Akim Demaille <akim@epita.fr> |
9657 | ||
9658 | * po/sv.po: New. | |
9659 | * configure.in (ALL_LINGUAS): Adjust. | |
9660 | * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no | |
9661 | longer contains strings to translate. | |
9662 | ||
81e895c0 AD |
9663 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9664 | ||
9665 | * src/conflicts.c (conflicts_print): Add a missing \n. | |
9666 | ||
6bb1878b AD |
9667 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9668 | ||
9669 | * src/nullable.c (nullable_print): New. | |
9670 | (set_nullable): Call it when tracing. | |
9671 | Better locality of variables. | |
9672 | ||
d9ec2d07 AD |
9673 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9674 | ||
9675 | * src/print.c (print_actions): Better locality of variables. | |
9676 | ||
720e5c1b AD |
9677 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9678 | ||
9679 | * src/derives.c (print_derives): Fix and enrich. | |
9680 | * src/closure.c (print_fderives): Likewise. | |
9681 | ||
fb908786 AD |
9682 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9683 | ||
9684 | * src/closure.c (itemsetend): Remove, replaced with... | |
9685 | (itemsetsize): new. | |
9686 | ||
125ecb56 AD |
9687 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9688 | ||
9689 | * src/LR0.c (kernel_end): Remove, replaced with... | |
9690 | (kernel_size): new. | |
9691 | ||
d8cf039f AD |
9692 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9693 | ||
9694 | * src/conflicts.c (set_conflicts): Use arrays instead of pointers | |
9695 | to clarify. | |
9696 | ||
7bec0760 AD |
9697 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9698 | ||
9699 | * src/closure.c (closure): Use arrays instead of pointers to clarify. | |
9700 | ||
c87d4863 AD |
9701 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9702 | ||
9703 | * src/closure.c, src/derives.c, src/nullable.c: Adjust various | |
9704 | trace messages. | |
9705 | * src/LR0.c: Likewise. | |
9706 | (allocate_itemsets): Use arrays instead of pointers to clarify. | |
9707 | ||
9bfe901c AD |
9708 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9709 | ||
9710 | * src/getargs.c (statistics_flag): Replace with... | |
9711 | (trace_flag): New. | |
9712 | (longopts): Accept --trace instead of --statistics. | |
9713 | * src/getargs.h, src/options.c: Adjust. | |
9714 | * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c, | |
9715 | * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE. | |
9716 | ||
97db7bd4 AD |
9717 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9718 | ||
cc72668c | 9719 | * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer |
97db7bd4 AD |
9720 | pointers to clarify the code. |
9721 | (save_reductions, save_shifts): Factor common parts of alternatives. | |
9722 | ||
2c5f66ed AD |
9723 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9724 | ||
9725 | * src/LR0.c (new_state, get_state): Complete TRACE code. | |
9726 | * src/closure.c: Include `reader.h' to get `tags', needed by the | |
9727 | trace code. | |
9728 | Rename the conditional DEBUG as TRACE. | |
9729 | Output consistently TRACEs to stderr, not stdout. | |
9730 | * src/derives.c: Likewise. | |
9731 | * src/reduce.c: (inaccessable_symbols): Using if is better style | |
9732 | than goto. | |
9733 | Use `#if TRACE' instead of `#if 0' for tracing code. | |
9734 | ||
300f275f AD |
9735 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9736 | ||
9737 | * src/system.h (LIST_FREE, shortcpy): New. | |
9738 | * src/LR0.c: Use them. | |
9739 | * src/output.c (free_itemsets, free_reductions, free_shifts): | |
9740 | Remove, replaced by LIST_FREE. | |
9741 | ||
f59c437a AD |
9742 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9743 | ||
9744 | * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC) | |
9745 | (REDUCTIONS_ALLOC): New. | |
9746 | * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory | |
9747 | allocation. | |
9748 | ||
6986fd9e AD |
9749 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9750 | ||
9751 | * src/LR0.c (new_state): Complete trace code. | |
9752 | * src/nullable.c (set_nullable): Don't translate traces. | |
9753 | ||
4bc30f78 AD |
9754 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9755 | ||
9756 | * src/print_graph.c (print_core): Better locality of variables. | |
9757 | * src/print.c (print_core): Likewise. | |
9758 | ||
08a946e0 AD |
9759 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9760 | ||
9761 | * src/vcg.c: You do the output, so you are responsible of the | |
9762 | handling of VCG syntax, in particular: use quotearg. | |
9763 | * src/print_graph.c: Don't. | |
9764 | (print_actions): Don't output the actions as part of the nodes, | |
9765 | since that's the job of the edges. | |
9766 | (print_state): Don't output by hand: fill the node description, | |
9bfe901c | 9767 | and ask for its output. |
08a946e0 | 9768 | |
f0473484 AD |
9769 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9770 | ||
cc72668c AD |
9771 | * src/bison.simple (yyparse): When verbosely reporting an error, |
9772 | no longer put additional quotes around token names. | |
f0473484 AD |
9773 | * tests/calc.at: Adjust. |
9774 | ||
e41dc700 AD |
9775 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9776 | ||
9777 | * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'. | |
9778 | * src/reader.c (record_rule_lines, rline, rline_allocated): Remove. | |
9779 | * src/output.c: Adjust. | |
9780 | ||
652a871c AD |
9781 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9782 | ||
9783 | * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of... | |
9784 | (rule_t): this. | |
9785 | * src/conflicts.c, src/reader.c, src/reduce.c: Adjust. | |
9786 | ||
b2ed6e58 AD |
9787 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9788 | ||
9789 | * src/gram.h (rule_t): New. | |
9790 | (rule_table): New. | |
9791 | (rrhs, rlhs): Remove, part of state_t. | |
9792 | * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c, | |
9793 | * src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
9794 | * src/reader.c, src/reduce.c: Adjust. | |
9795 | ||
edad7067 AD |
9796 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9797 | ||
9798 | * src/reader.c (symbols_output): New, extracted from... | |
9799 | (packsymbols): Here. | |
9800 | (reader): Call it. | |
9801 | ||
3feec034 AD |
9802 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9803 | ||
9804 | * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with... | |
9805 | (maxrhs): this new function. | |
9806 | ||
ddcd5fdf AD |
9807 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9808 | ||
cc72668c | 9809 | * src/lalr.c (F): New macro to access the variable F. |
ddcd5fdf AD |
9810 | Adjust. |
9811 | ||
bb527fc2 AD |
9812 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9813 | ||
cc72668c | 9814 | * src/lalr.h (LA): New macro to access the variable LA. |
bb527fc2 AD |
9815 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: |
9816 | * src/lalr.c: Adjust. | |
9817 | ||
a845a697 AD |
9818 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9819 | ||
9820 | * src/lalr.c (initialize_LA): Only initialize LA. Let... | |
9821 | (set_state_table): handle the `lookaheads' members. | |
9822 | ||
f004bf6a AD |
9823 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9824 | ||
cc72668c AD |
9825 | * src/lalr.h (lookaheads): Removed array, whose contents is now |
9826 | a member of... | |
f004bf6a AD |
9827 | (state_t): this structure. |
9828 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
9829 | Adjust. | |
9830 | ||
de326cc0 AD |
9831 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9832 | ||
cc72668c AD |
9833 | * src/lalr.h (consistent): Removed array, whose contents is now |
9834 | a member of... | |
de326cc0 AD |
9835 | (state_t): this structure. |
9836 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
9837 | Adjust. | |
9838 | ||
90b4416b AD |
9839 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9840 | ||
cc72668c AD |
9841 | * src/lalr.h (reduction_table, shift_table): Removed arrays, whose |
9842 | contents are now members of... | |
90b4416b AD |
9843 | (state_t): this structure. |
9844 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
9845 | Adjust. | |
9846 | ||
9703cc49 AD |
9847 | 2001-11-19 Akim Demaille <akim@epita.fr> |
9848 | ||
9849 | * src/lalr.h (state_t): New. | |
9850 | (state_table): Be a state_t * instead of a core **. | |
9851 | (accessing_symbol): Remove, part of state_t. | |
9852 | * src/lalr.c: Adjust. | |
9853 | (set_accessing_symbol): Merge into... | |
9854 | (set_state_table): this. | |
9855 | * src/print_graph.c, src/conflicts.c: Adjust. | |
9856 | ||
d803322e AD |
9857 | 2001-11-14 Akim Demaille <akim@epita.fr> |
9858 | ||
9859 | * tests/calc.at, tests/output.at, tests/regression.at, | |
9860 | * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g: | |
9861 | now the tests are run in private dirs, therefore AC_CLEANUP and | |
9862 | family can be simplified to 0-ary. | |
9863 | * tests/atlocal.in: Now that we run `elsewhere' than in tests/, | |
9864 | use abs. path to find config.h. | |
9865 | * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's | |
9866 | stderr, there can be way too much random noise. | |
9867 | Instead pass -Werror to GCC and rely on the exit status. | |
9868 | Reported by Wolfram Wagner. | |
9869 | ||
3d76b07d AD |
9870 | 2001-11-14 Akim Demaille <akim@epita.fr> |
9871 | ||
9872 | * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be | |
9873 | defined only if yyoverflow is defined, to avoid `warning: unused | |
9874 | variable `yyvs1''. | |
9875 | Reported by The Test Suite. | |
9876 | ||
09b503c8 AD |
9877 | 2001-11-14 Akim Demaille <akim@epita.fr> |
9878 | ||
9879 | * src/print.c: Include reduce.h. | |
9880 | Reported by Hans Aberg. | |
9881 | ||
9882 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
9883 | ||
9884 | * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer): | |
9885 | Revert a previous patch: these are really const. | |
9886 | * src/conflicts.c (conflict_report): Additional useless pair of | |
9887 | braces to pacify GCC's warnings for `if () if () {} else {}'. | |
9888 | * src/lex.c (parse_percent_token): Replace equal_offset with | |
9889 | arg_offset. | |
9890 | arg is const. | |
9891 | Be sure to strdup `arg' when used, since there is no reason for | |
9892 | token_buffer not to change. | |
9893 | ||
0f37a994 AD |
9894 | 2001-11-14 Akim Demaille <akim@epita.fr> |
9895 | ||
9896 | * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper | |
9897 | definition. | |
9898 | * src/main.c (main): Use them. | |
9899 | Suggested by Hans Aberg. | |
9900 | ||
d39d93b8 AD |
9901 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9902 | ||
9903 | * src/system.h (ngettext): Now that we use ngettext, be sure to | |
9904 | provide a default definition when NLS are not used. | |
9905 | ||
9edcd895 AD |
9906 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9907 | ||
9908 | * doc/bison.texinfo: Use `$' as shell prompt, not `%'. | |
9909 | Use @kbd to denote user input. | |
9910 | (Language and Grammar): ANSIfy the example. | |
9911 | Adjust its layout for info/notinfo. | |
9912 | (Location Tracking Calc): Output error messages to stderr. | |
9913 | Output locations in a more GNUtically correct way. | |
9914 | Fix a couple of Englishos. | |
9915 | Adjust @group/@end group pairs. | |
9916 | ||
7da99ede AD |
9917 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9918 | ||
e3aa65c5 | 9919 | %expect was not functioning at all. |
7da99ede AD |
9920 | |
9921 | * src/conflicts.c (expected_conflicts): Set to -1. | |
9922 | (conflict_report): Use ngettext. | |
9923 | (conflicts_print): Check %expect and make its violation an error. | |
9924 | * doc/bison.texinfo (Expect Decl): Adjust. | |
9925 | * configure.in (AM_GNU_GETTEXT): Ask for ngettext. | |
9926 | * tests/regression.at (%expect not enough, %expect right) | |
9927 | (%expect too much): New. | |
9928 | ||
ba9dda1a AD |
9929 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9930 | ||
9931 | * tests/regression.at (Conflicts): Rename as... | |
9932 | (Unresolved SR Conflicts): this. | |
9933 | (Solved SR Conflicts): New. | |
9934 | ||
337c5bd1 AD |
9935 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9936 | ||
9937 | * src/reduce.c (print_results): Rename as... | |
9938 | (reduce_output): This. | |
9939 | Output to OUT, passed as argument, instead of output_obstack. | |
9940 | (dump_grammar): Likewise. | |
9941 | (reduce_free): New. | |
9942 | Also free V1. | |
9943 | (reduce_grammar): No longer call reduce_output, since... | |
9944 | * src/print.c (print_results): do it. | |
9945 | * src/main.c (main): Call reduce_free; | |
9946 | ||
c73a41af AD |
9947 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9948 | ||
9949 | * src/conflicts.c (print_reductions): Accept OUT as argument. | |
9950 | Output to it, not to output_obstack. | |
9951 | * src/print.c (print_actions): Adjust. | |
9952 | ||
0df87bb6 AD |
9953 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9954 | ||
9955 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return | |
9956 | the result instead of using... | |
9957 | (src_total, rrc_total, src_count, rrc_count): Remove. | |
9958 | (any_conflicts): Remove. | |
9959 | (print_conflicts): Split into... | |
9960 | (conflicts_print, conflicts_output): New. | |
9961 | * src/conflicts.h: Adjust. | |
9962 | * src/main.c (main): Invoke both conflicts_output and conflicts_print. | |
0f37a994 | 9963 | * src/print.c (print_grammar): Issue `\n' between two rules. |
0df87bb6 AD |
9964 | * tests/regression.at (Conflicts): New. |
9965 | Reported by Tom Lane. | |
9966 | ||
e4d3d4de AD |
9967 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9968 | ||
9969 | * tests/regression.at (Invalid input): Remove, duplicate with | |
9970 | ``Invalid input: 1''. | |
9971 | ||
6d7d248e AD |
9972 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9973 | ||
9974 | * tests/torture.at (AT_DATA_STACK_TORTURE) | |
9975 | (Exploding the Stack Size with Alloca) | |
9976 | (Exploding the Stack Size with Malloc): New. | |
9977 | ||
e9e4c321 AD |
9978 | 2001-11-12 Akim Demaille <akim@epita.fr> |
9979 | ||
9980 | * src/bison.simple (YYSTACK_REALLOC): New. | |
9981 | (yyparse) [!yyoverflow]: Use it and free the old stack. | |
0f37a994 | 9982 | Reported by Per Allansson. |
e9e4c321 | 9983 | |
5f7e0832 AD |
9984 | 2001-11-12 Pascal Bart <pascal.bart@epita.fr> |
9985 | ||
9986 | * src/bison.simple: Define type yystype instead of YYSTYPE, and | |
9987 | define CPP macro, which substitute YYSTYPE by yystype. | |
9988 | * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do | |
9989 | with yyltype/YYLTYPE. This allows inclusion of the generated | |
9990 | header within the parser if the compiler, such as GGC, accepts | |
9991 | multiple equivalent #defines. | |
9992 | From Akim. | |
9993 | ||
e3f1699f AD |
9994 | 2001-11-05 Akim Demaille <akim@epita.fr> |
9995 | ||
9996 | * src/reader.c (symbols_output): New, extracted from... | |
9997 | (packsymbols): here. | |
9998 | (reader): Adjust. | |
9999 | ||
65be0866 AD |
10000 | 2001-11-05 Akim Demaille <akim@epita.fr> |
10001 | ||
10002 | * src/lex.c (parse_percent_token): s/quotearg/quote/. | |
10003 | ||
e4d910bf AD |
10004 | 2001-11-05 Akim Demaille <akim@epita.fr> |
10005 | ||
10006 | * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up | |
10007 | pattern. | |
10008 | ||
951366c1 AD |
10009 | 2001-11-05 Akim Demaille <akim@epita.fr> |
10010 | ||
10011 | * src/options.h (struct option_table_struct): set_flags is void*. | |
10012 | * src/options.c (longopts): Support `--output' and `%output'. | |
10013 | (usage): Adjust. | |
10014 | * src/lex.h (tok_setopt): Remove, replaced with... | |
10015 | (tok_intopt, tok_stropt): these new guys. | |
10016 | * src/lex.c (getopt.h): Not needed. | |
10017 | (token_buffer, unlexed_token_buffer): Not const. | |
10018 | (percent_table): Promote `-' over `_' in directive names. | |
10019 | Active `%name-prefix', `file-prefix', and `output'. | |
10020 | (parse_percent_token): Accept possible arguments to directives. | |
10021 | Promote `-' over `_' in directive names. | |
10022 | ||
d8988b2f AD |
10023 | 2001-11-04 Akim Demaille <akim@epita.fr> |
10024 | ||
10025 | * doc/bison.texinfo (Decl Summary): Split the list into | |
10026 | `directives for grammars' and `directives for bison'. | |
10027 | Sort'em. | |
10028 | Add description of `%name-prefix', `file-prefix', and `output'. | |
10029 | Promote `-' over `_' in directive names. | |
10030 | (Bison Options): s/%locactions/%locations/. Nice Freudian slip. | |
10031 | Simplify the description of `--name-prefix'. | |
10032 | Promote `-' over `_' in directive names. | |
10033 | Promote `--output' over `--output-file'. | |
10034 | Fix the description of `--defines'. | |
10035 | * tests/output.at: Exercise %file-prefix and %output. | |
10036 | ||
6468d18e AD |
10037 | 2001-11-02 Akim Demaille <akim@epita.fr> |
10038 | ||
10039 | * doc/refcard.tex: Update. | |
10040 | ||
6b7e85b9 AD |
10041 | 2001-11-02 Akim Demaille <akim@epita.fr> |
10042 | ||
10043 | * src/symtab.h (SUNDEF): New. | |
10044 | * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to | |
10045 | stand for `uninitialized', instead of 0. | |
10046 | * src/reader.c (packsymbols, parse_thong_decl): Adjust. | |
10047 | * src/lex.c (lex): Adjust. | |
10048 | ||
10049 | * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF. | |
10050 | Number it 0. | |
10051 | Let yylex return it instead of a plain 0. | |
10052 | Reported by Dick Streefland. | |
10053 | ||
cd5aafcf AD |
10054 | 2001-11-02 Akim Demaille <akim@epita.fr> |
10055 | ||
10056 | * tests/regression.at (Mixing %token styles): New test. | |
10057 | ||
037ca2f1 AD |
10058 | 2001-11-02 Akim Demaille <akim@epita.fr> |
10059 | ||
10060 | * src/reader.c (parse_thong_decl): Formatting changes. | |
10061 | (token_translations_init): New, extracted from... | |
10062 | (packsymbols): Here. | |
10063 | Adjust. | |
10064 | ||
270a173c AD |
10065 | 2001-11-01 Akim Demaille <akim@epita.fr> |
10066 | ||
10067 | * tests/regression.at (AT_TEST_CPP_GUARD_H): New. | |
10068 | Check that `9foo.y' produces correct cpp guards. | |
10069 | * src/files.c (compute_header_macro): Prepend `BISON_' to CPP | |
10070 | guards. | |
10071 | Reported by Wwp. | |
10072 | ||
561f9a30 AD |
10073 | 2001-11-01 Akim Demaille <akim@epita.fr> |
10074 | ||
10075 | * tests/regression.at (Invalid input: 2): New. | |
10076 | * src/lex.c (unlexed_token_buffer): New. | |
10077 | (lex, unlex): Adjust: when unlexing, be sure to save token_buffer | |
10078 | too. | |
10079 | Reported by Wwp. | |
10080 | ||
f987e9d2 AD |
10081 | 2001-11-01 Akim Demaille <akim@epita.fr> |
10082 | ||
10083 | * tests/calc.at: Catch up with 1.30. | |
10084 | * configure.in: Bump to 1.49a. | |
10085 | Adjust to newer Autotest. | |
10086 | ||
0846f581 PB |
10087 | 2001-10-19 Pascal Bart <pascal.bart@epita.fr> |
10088 | ||
10089 | * src/conflicts.c: Move global variables rrc_total and src_total ... | |
10090 | (print_conflicts): here. | |
10091 | * src/output.c (output): Free global variable user_toknums. | |
10092 | * src/lex.c (token_obstack): Become static. | |
10093 | ||
3c1a79b3 AD |
10094 | 2001-10-18 Akim Demaille <akim@epita.fr> |
10095 | ||
10096 | * tests/atlocal.in (GCC): Add. | |
10097 | * tests/calc.at: s/m4_match/m4_bmatch/. | |
10098 | s/m4_patsubst/m4_bpatsubst/. | |
10099 | (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC. | |
10100 | * configure.in: AC_SUBST(GCC). | |
10101 | ||
5d52e7d0 MA |
10102 | 2001-10-14 Marc Autret <autret_m@epita.fr> |
10103 | ||
10104 | * src/options.c (create_long_option_table): Fix. | |
10105 | ||
631aa1d3 AD |
10106 | 2001-10-10 Akim Demaille <akim@epita.fr> |
10107 | ||
10108 | * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA. | |
10109 | ||
f6ec6d13 AD |
10110 | 2001-10-04 Akim Demaille <akim@epita.fr> |
10111 | ||
10112 | * src/reader.c (parse_union_decl): Push the caracters in | |
10113 | union_obstack, not attrs_obstack. | |
10114 | ||
342b8b6e AD |
10115 | 2001-10-04 Akim Demaille <akim@epita.fr> |
10116 | ||
10117 | Merge in the branch 1.29. | |
10118 | ||
10119 | * src/reader.c (packsymbols): Use a temporary obstack for | |
10120 | `%%tokendef', since output_stack is already used elsewhere. | |
10121 | ||
10122 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10123 | ||
10124 | Bump 1.29d. | |
10125 | ||
10126 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10127 | ||
10128 | Version 1.29c. | |
10129 | ||
10130 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10131 | ||
10132 | * tests/regression.at (Invalid CPP headers): New. | |
10133 | From Alexander Belopolsky. | |
10134 | * src/files.c (compute_header_macro): Map non alnum chars to `_'. | |
10135 | ||
10136 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10137 | ||
10138 | * tests/regression.at (Invalid input): New. | |
10139 | * src/lex.c (lex): Be sure to set `token_buffer' in any case. | |
10140 | Reported by Shura. | |
10141 | ||
10142 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10143 | ||
10144 | * tests/calc.at: Now that --debug works, the tests must be adjusted. | |
10145 | ||
10146 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
10147 | ||
10148 | * src/output.c (output_parser): Assert `skeleton'. | |
10149 | * src/files.c (skeleton_find): Look harder for skeletons on DOSish | |
10150 | systems. | |
10151 | From Shura. | |
10152 | ||
10153 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
10154 | ||
10155 | * src/lex.h: Echo modifications. | |
10156 | * src/lex.c (unlex): Parameter is now token_t. | |
10157 | From Hans Aberg. | |
10158 | ||
10159 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
10160 | ||
10161 | * src/main.c: Include lex.h. | |
10162 | From Hans Aberg. | |
10163 | ||
10164 | 2001-09-29 Akim Demaille <akim@epita.fr> | |
10165 | ||
10166 | * src/getargs.c (longopts): `--debug' is `-t', not `-d'. | |
10167 | ||
10168 | 2001-09-28 Akim Demaille <akim@epita.fr> | |
10169 | ||
10170 | * tests/testsuite.at: Update to newer Autotest. | |
10171 | * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped. | |
10172 | ||
10173 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
10174 | ||
10175 | Position independent wrapper. | |
10176 | ||
10177 | * tests/bison: Remove. | |
10178 | * tests/bison.in: New. | |
10179 | * configure.in: Adjust. | |
10180 | ||
10181 | 2001-09-27 Paul Eggert <eggert@twinsun.com> | |
10182 | ||
10183 | Port quotearg fixes from tar 1.13.24. | |
10184 | ||
10185 | * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct | |
10186 | tm to be declared. | |
10187 | (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC. | |
10188 | (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT. | |
10189 | ||
10190 | * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4. | |
10191 | * m4/mbrtowc.m4: New file. | |
10192 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h. | |
10193 | Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc). | |
10194 | ||
10195 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
10196 | ||
10197 | Bump to 1.29c. | |
10198 | ||
10199 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
10200 | ||
10201 | Version 1.29b. | |
10202 | ||
10203 | 2001-09-25 Akim Demaille <akim@epita.fr> | |
10204 | ||
10205 | * src/system.h: Include `xalloc.h'. | |
10206 | Remove it from the C files. | |
10207 | * src/files.c (output_files): Free the obstacks. | |
10208 | * src/lex.c (init_lex): Rename as... | |
10209 | (lex_init): this. | |
10210 | (lex_free): New. | |
10211 | * src/main.c (main): Use it. | |
10212 | ||
10213 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
10214 | ||
10215 | * src/vcg.c (open_edge, close_edge, open_node, close_node): Change | |
10216 | to output informations in fout (FILE*). | |
10217 | (open_graph, close_graph): Likewise. | |
10218 | (output_graph, output_edge, output_node): Likewise. | |
10219 | * src/vcg.h: Update function prototypes. | |
10220 | * src/print_graph.c (print_graph): Open output graph file. | |
10221 | (print_actions): Adjust. | |
10222 | * src/files.h: Remove extern declaration. | |
10223 | * src/files.c: Remove graph_obstack declaration. | |
10224 | (open_files): Remove graph_obstack initialization. | |
10225 | (output_files): Remove graph_obstack saving. | |
10226 | ||
10227 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
10228 | ||
10229 | * src/files.c (compute_output_file_names): Fix. | |
10230 | ||
10231 | 2001-09-24 Marc Autret <autret_m@epita.fr>, | |
10232 | Akim Demaille <akim@epita.fr> | |
10233 | ||
10234 | * src/reader.c (reader): Remove call to free_symtab (). | |
10235 | * src/main.c (main): Call it here. | |
10236 | Include symtab.h. | |
10237 | * src/conflicts.c (initialize_conflicts): Rename as... | |
10238 | (solve_conflicts): this. | |
10239 | * src/print.c (print_core, print_actions, print_state) | |
10240 | (print_grammar): Dump to a file instead a `output_obstack'. | |
10241 | (print_results): Dump `output_obstack', and then proceed with the | |
10242 | FILE *. | |
10243 | * src/files.c (compute_output_file_names, close_files): New. | |
10244 | (output_files): Adjust. | |
10245 | * src/main.c (main): Adjust. | |
10246 | ||
10247 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
10248 | ||
10249 | * src/files.c (compute_header_macro): Computes header macro name | |
10250 | from spec_defines_file when given. | |
10251 | ||
10252 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
10253 | ||
10254 | * src/files.c (output_files): Add default extensions. | |
10255 | ||
10256 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
10257 | ||
10258 | * src/conflicts.c (finalize_conflicts): Rename as... | |
10259 | (free_conflicts): this. | |
10260 | ||
10261 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
10262 | ||
10263 | * src/gram.c (gram_free): Rename back as... | |
10264 | (dummy): this. | |
10265 | (output_token_translations): Free `token_translations'. | |
10266 | * src/symtab.c (free_symtab): Free the tag field. | |
10267 | ||
10268 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
10269 | ||
10270 | Remove `translations' as it is always set to true. | |
10271 | ||
10272 | * src/gram.h: Adjust. | |
10273 | * src/reader.c (packsymbols, parse_token_decl): Adjust | |
10274 | * src/print.c (print_grammar): Adjust. | |
10275 | * src/output.c (output_token_translations): Adjust. | |
10276 | * src/lex.c (lex): Adjust. | |
10277 | * src/gram.c: Be sure the set pointers to NULL. | |
10278 | (dummy): Rename as... | |
10279 | (gram_free): this. | |
10280 | ||
10281 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
10282 | ||
10283 | * configure.in: Invoke AM_LIB_DMALLOC. | |
10284 | * src/system.h: Use dmalloc. | |
10285 | * src/LR0.c: Be sure to have pointers initialized to NULL. | |
10286 | (allocate_itemsets): Allocate kernel_items only if needed. | |
10287 | ||
10288 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
10289 | ||
10290 | * configure.in: Bump to 1.29b. | |
10291 | * tests/Makefile.am (DISTCLEANFILES): Add package.m4. | |
10292 | * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't | |
10293 | need xmalloc.c in calc.y. | |
10294 | From Pascal Bart. | |
10295 | ||
10296 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
10297 | ||
10298 | Version 1.29a. | |
10299 | * Makefile.maint, config/config.guess, config/config.sub, | |
10300 | * config/missing: Update from masters. | |
10301 | * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend | |
10302 | upon package.m4. | |
10303 | * configure.in (ALL_LINGUAS): Add `tr'. | |
10304 | ||
10305 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
10306 | ||
10307 | * tests/Makefile.am (package.m4): Move to... | |
10308 | ($(srcdir)/$(TESTSUITE)): here. | |
10309 | ||
10310 | 2001-09-20 Akim Demaille <akim@epita.fr> | |
10311 | ||
10312 | * src/complain.c: No longer try to be standalone: use system.h. | |
10313 | Don't assume __STDC__ is defined to 1. Just test if it is defined. | |
10314 | * src/complain.h: Likewise. | |
10315 | * src/reduce.c (useless_nonterminals, inaccessable_symbols): | |
10316 | Remove the unused variable `n'. | |
10317 | From Albert Chin-A-Young. | |
10318 | ||
10319 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10320 | ||
10321 | * doc/bison.1: Update. | |
10322 | * doc/bison.texinfo (Bison Options): Update --defines and --graph | |
10323 | descriptions. | |
10324 | (Option Cross Key): Update. | |
10325 | Add --graph. | |
10326 | ||
10327 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10328 | ||
10329 | * tests/regression.at: New test (comment in %union). | |
10330 | ||
10331 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10332 | ||
10333 | * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment | |
10334 | do that. | |
10335 | Reported by Keith Browne. | |
10336 | ||
10337 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10338 | ||
10339 | * tests/output.at: Add tests for --defines and --graph. | |
10340 | ||
10341 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10342 | ||
10343 | * tests/output.at: Removes tests of %{header,src}_extension features. | |
10344 | ||
10345 | 2001-09-18 Akim Demaille <akim@epita.fr> | |
10346 | ||
10347 | * tests/Makefile.am (package.m4): New. | |
10348 | * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'. | |
10349 | (_AT_CHECK_CALC_ERROR): Likewise. | |
10350 | Factor the `, ' part of verbose error messages. | |
10351 | ||
10352 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10353 | ||
10354 | * src/getargs.c (longopts): Declare --defines and --graph as options | |
10355 | with optional arguments. | |
10356 | * src/files.h: Add extern declarations. | |
10357 | * src/files.c (spec_graph_file, spec_defines_file): New. | |
10358 | (output_files): Update. | |
10359 | Remove CPP-outed code. | |
10360 | ||
10361 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
10362 | ||
10363 | Turn off %{source,header}_extension feature. | |
10364 | ||
10365 | * src/files.c (compute_exts_from_gf): Update. | |
10366 | (compute_exts_from_src): Update. | |
10367 | (output_files): CPP-out useless code. | |
10368 | * src/files.h: Remove {header,source}_extension extern declarations. | |
10369 | * src/reader.c (parse_dquoted_param): CPP-out. | |
10370 | (parse_header_extension_decl): Remove. | |
10371 | (parse_source_extension_decl): Remove. | |
10372 | (read_declarations): Remove cases tok_{hdrext,srcext}. | |
10373 | * src/lex.c (percent_table): Remove {header,source}_extension entries. | |
10374 | * src/lex.h (token_t): Remove tok_hdrext and tok_srcext. | |
10375 | ||
10376 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
10377 | ||
10378 | * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT): | |
10379 | (AT_CHECK_BISON_PERCENT_FLAGS): Merge into... | |
10380 | (AT_CHECK_OUTPUT): this. | |
10381 | Merely check ls' exit status, its output is useless. | |
10382 | ||
10383 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
10384 | ||
10385 | * tests/calc.at: Use m4_match. | |
10386 | (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'. | |
10387 | ||
10388 | 2001-09-10 Marc Autret <autret_m@epita.fr>, | |
10389 | Akim Demaille <akim@epita.fr> | |
10390 | ||
10391 | * src/vcg.h (graph_s): color, textcolor, bordercolor are now | |
10392 | enum color_e. | |
10393 | * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm | |
10394 | to `normal'. | |
10395 | * src/reader.c (parse_token_decl): Initialize token with tok_eof. | |
10396 | * src/lex.h: Adjust prototype. | |
10397 | (token_t): Add `tok_undef'. | |
10398 | * src/lex.c (struct percent_table_struct): Retval is now a token_t. | |
10399 | (parse_percent_token): Now returns token_t. | |
10400 | Add default statement in switch. | |
10401 | (lex): Separate `c' as an input variable, from the token_t result | |
10402 | part. | |
10403 | (unlexed): Is a token_t. | |
10404 | ||
10405 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
10406 | ||
10407 | * configure.in: Bump to 1.29a. | |
10408 | ||
10409 | 2001-09-07 Akim Demaille <akim@epita.fr> | |
10410 | ||
10411 | Version 1.29. | |
10412 | ||
10413 | 2001-08-30 Akim Demaille <akim@epita.fr> | |
10414 | ||
10415 | * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove. | |
10416 | * m4/atconfig.m4: Remove. | |
10417 | * tests/testsuite.at, tests/atlocal.in, tests/output.at, | |
10418 | * tests/bison: New. | |
10419 | * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER, | |
10420 | m4_if, m4_patsubst, and m4_regexp. | |
10421 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an | |
10422 | `input' file instead of echo. | |
10423 | ||
10424 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
10425 | ||
10426 | Bump to 1.28e. | |
10427 | ||
10428 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
10429 | ||
10430 | Version 1.28d. | |
10431 | ||
10432 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
10433 | ||
10434 | * src/bison.simple (yyparse): Don't take the address of an | |
10435 | item before the start of an array, as that doesn't conform to | |
10436 | the C Standard. | |
10437 | ||
10438 | 2001-08-29 Robert Anisko <anisko_r@epita.fr> | |
10439 | ||
10440 | * doc/bison.texinfo (Location Tracking Calc): New node. | |
10441 | ||
10442 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
10443 | ||
10444 | * src/output.c (output): Do not define const, as this now | |
10445 | causes more problems than it cures. | |
10446 | ||
10447 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
10448 | ||
10449 | * doc/bison.texinfo: Modernize `@node' and `@top' use: just name | |
10450 | the nodes. | |
10451 | Be sure to tag the `detailmenu'. | |
10452 | ||
10453 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
10454 | ||
10455 | * Makefile.maint (do-po-update): Wget refuses to overwrite files: | |
10456 | download in a tmp dir. | |
10457 | ||
10458 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
10459 | ||
10460 | * config/depcomp: New file. | |
10461 | ||
10462 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
10463 | ||
10464 | * doc/bison.1 (mandoc): Adjust. | |
10465 | From Juan Manuel Guerrero. | |
10466 | ||
10467 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
10468 | ||
10469 | * src/print_graph.c (print_state): Fix. | |
10470 | ||
10471 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
10472 | ||
10473 | * src/vcg.h (classname_s, infoname_s, node_s): Constify the | |
10474 | char * members. | |
10475 | Echo modifications to the functions prototypes. | |
10476 | * src/vcg.c (add_classname, add_infoname): Adjust arguments. | |
10477 | ||
10478 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
10479 | ||
10480 | * src/vcg.c: Include `xalloc.h'. | |
10481 | (add_colorentry): New. | |
10482 | (add_classname): New. | |
10483 | (add_infoname): New. | |
10484 | * src/vcg.h: Add new prototypes. | |
10485 | ||
10486 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
10487 | ||
10488 | * Makefile.maint: Sync. again with CVS Autoconf. | |
10489 | ||
10490 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
10491 | ||
10492 | * Makefile.maint: Formatting changes. | |
10493 | (po-update, cvs-update, update): New targets. | |
10494 | (AMTAR): Remove. | |
10495 | ||
10496 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
10497 | ||
10498 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
10499 | * Makefile.maint: Sync. with CVS Autoconf. | |
10500 | ||
10501 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
10502 | ||
10503 | * src/vcg.h (struct infoname_s): New. | |
10504 | (struct colorentry_s): New. | |
10505 | (graph_s): New fields {vertical,horizontal}_order in structure. | |
10506 | Add `infoname' field. | |
10507 | Add `colorentry' field; | |
10508 | * src/vcg_defaults.h (G_VERTICAL_ORDER): New. | |
10509 | (G_HORIZONTAL_ORDER): New. | |
10510 | (G_INFONAME): New. | |
10511 | (G_COLORENTRY): New. | |
10512 | * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order. | |
10513 | Add output of `infoname'. | |
10514 | Add output of `colorentry'. | |
10515 | ||
10516 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
10517 | ||
10518 | * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'. | |
10519 | This one shadowed a global parameter. | |
10520 | ||
10521 | 2001-08-24 Marc Autret <autret_m@epita.fr> | |
10522 | ||
10523 | * src/print_graph.c (node_output_size): Declared POSIX `size_t' type, | |
10524 | instead of `unsigned'. | |
10525 | (print_state): Do not call obstack_object_size () in obstack_grow () | |
10526 | to avoid macro variables shadowing. | |
10527 | ||
10528 | 2001-08-23 Marc Autret <autret_m@epita.fr> | |
10529 | ||
10530 | * src/lex.c (percent_table): Typo: s/naem/name/. | |
10531 | Add graph option. | |
10532 | Normalize new options declarations. | |
10533 | ||
10534 | 2001-08-20 Pascal Bart <pascal.bart@epita.fr> | |
10535 | ||
10536 | * tests/suite.at: Exercise %header_extension and %source_extension. | |
10537 | ||
10538 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
10539 | ||
10540 | * src/reader.c (parse_dquoted_param): New. | |
10541 | (parse_header_extension_decl): Use it. | |
10542 | (parse_source_extension_decl): Likewise. | |
10543 | ||
10544 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
10545 | ||
10546 | * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'. | |
10547 | (get_xxxx_str): Use assert () instead of complain (). | |
10548 | Remove return invokations in default cases. | |
10549 | (get_decision_str): Modify default behaviour. Remove second argument. | |
10550 | Echo modifications on calls. | |
10551 | (output_graph): Fix. | |
10552 | ||
10553 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
10554 | ||
10555 | * src/getargs.c (usage): Update with ``-g, --graph''. | |
10556 | ||
10557 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
10558 | ||
10559 | * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'. | |
10560 | (Option Cross Key): Likewise. | |
10561 | * doc/bison.1: Update. | |
10562 | ||
1c8c2190 PB |
10563 | 2001-09-25 Pascal Bart <pascal.bart@epita.fr> |
10564 | ||
10565 | * src/output.c (output_master_parser): Don't finish action_obstack. | |
10566 | (output_parser): Don't care about the muscle action, here. | |
10567 | (prepare): Copy the action_obstack in the action muscle. | |
10568 | (output): Free action_obstack. | |
10569 | ||
180d45ba PB |
10570 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> |
10571 | ||
10572 | * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which | |
10573 | will contain `%union' declaration. | |
10574 | (parse_union_decl): Delete #line directive output. | |
10575 | (parse_union_decl): Substitute /attrs_obstack/union_obstack for all | |
10576 | informations about %union. | |
10577 | (parse_union_decl): Copy the union_obstack in the muscle stype. | |
10578 | * src/bison.simple: Add new #line directive. | |
10579 | Add typdef %%stype YYSTYPE. | |
10580 | ||
c51d1a19 PB |
10581 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> |
10582 | ||
10583 | * src/bison.simple: Add new `#line' directive. | |
10584 | ||
6f9344da PB |
10585 | 2001-09-22 Pascal Bart <pascal.bart@epita.fr> |
10586 | ||
10587 | * src/bison.simple: New `#line' directive. | |
10588 | * src/output.c (output_parser): Support new dynamic muscle input_line. | |
10589 | ||
652def80 MA |
10590 | 2001-09-22 Marc Autret <autret_m@epita.fr> |
10591 | ||
10592 | * src/output.c (output_master_parser): New. | |
10593 | (output_parser): Be more re-entrant. | |
10594 | ||
25b222fa MA |
10595 | 2001-09-21 Marc Autret <autret_m@epita.fr> |
10596 | ||
10597 | * src/reader.c (copy_definition, parse_union_decl): Update and use | |
10598 | `linef' muscle. | |
10599 | (copy_action): Likewise. | |
10600 | Use obstack_1grow (). | |
10601 | * src/muscle_tab.c (muscle_init): Add muscle `linef'. | |
10602 | ||
6bc35ae5 MA |
10603 | 2001-09-21 Marc Autret <autret_m@epita.fr> |
10604 | ||
10605 | * src/options.c (option_table): Adjust. | |
10606 | * src/lex.c (parse_percent_token): Fix. | |
10607 | ||
c0629aa1 PB |
10608 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> |
10609 | ||
10610 | * src/options.c (symtab.h): Include it, need by lex.h. | |
342b8b6e | 10611 | |
82b6d266 PB |
10612 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> |
10613 | ||
10614 | * src/lex.c (parse_percent_token): Change type of variable `tx', which | |
10615 | is now an option_table_struct*. | |
10616 | (option_strcmp): New function option_strcmp. | |
10617 | (parse_percent_token): Call option_strcmp. | |
10618 | * src/getargs.c (xalloc.h, options.h): Include it. | |
10619 | (getargs): Call create_long_option_table. | |
10620 | (getargs): Free longopts at the end of the function. | |
10621 | (shortopts): Move in options.c. | |
10622 | * src/options.c (create_long_option_table): New function. Convert | |
10623 | information from option_table to option structure. | |
10624 | * src/reader.c (options.h): Include it. | |
10625 | ||
10626 | * src/Makefile.am: Adjust. | |
10627 | * src/options.c (option_table): Create from longopts and percent_table. | |
10628 | * src/getargs.c (longopts): Delete. | |
10629 | * src/lex.c (struct percent_table_struct): Delete. | |
10630 | (percent_table): Delete. | |
10631 | (options.h): Include it. | |
10632 | * src/options.c: Create. | |
10633 | * src/options.h: Create. | |
10634 | Declare enum opt_access_e. | |
10635 | Define struct option_table_struct. | |
10636 | ||
75f5aaea MA |
10637 | 2001-09-20 Marc Autret <autret_m@epita.fr> |
10638 | ||
10639 | * doc/bison.texinfo: Adjust terminologies about prologue and epilogue | |
10640 | sections of Bison. | |
10641 | ||
f508cb0a PB |
10642 | 2001-09-19 Pascal Bart <pascal.bart@epita.fr> |
10643 | ||
10644 | * src/bison.simple: s/%%filename/%%skeleton. | |
10645 | * src/muscle_tab.c (getargs.h): Include it. | |
10646 | (muscle_init): Insert new muscle skeleton. | |
10647 | ||
13105fc1 PB |
10648 | 2001-09-18 Pascal Bart <pascal.bart@epita.fr> |
10649 | ||
10650 | * src/output.c (output_parser): Delete unused variable actions_dumped. | |
10651 | ||
b0c4483e PB |
10652 | 2001-09-07 Pascal Bart <pascal.bart@epita.fr> |
10653 | ||
10654 | * src/output.c (output): Delete call to reader_output_yylsp. | |
10655 | * src/reader.c (reader): Likewise. | |
10656 | * src/reader.h: Delete declaration of reader_output_yylsp. | |
342b8b6e | 10657 | |
11d82f03 MA |
10658 | 2001-09-02 Marc Autret <autret_m@epita.fr> |
10659 | ||
10660 | * src/reader.c: Include muscle_tab.h. | |
10661 | (parse_union_decl): Update. | |
10662 | (parse_macro_decl): Rename parse_muscle_decl. | |
10663 | Update to use renamed functions and variable. | |
10664 | (read_declarations, copy_action, read_additionnal_code, : Updated | |
10665 | with correct variables and functions names. | |
10666 | (packsymbols, reader): Likewise. | |
342b8b6e | 10667 | |
11d82f03 | 10668 | * src/reader.h (muscle_obstack): Extern declaration update. |
342b8b6e | 10669 | |
11d82f03 MA |
10670 | * src/output.c: Include muscle_tab.h |
10671 | In all functions using macro_insert, change by using muscle_insert (). | |
10672 | (macro_obstack): Rename muscle_obstack. | |
10673 | Echo modifications in the whole file. | |
10674 | (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT. | |
10675 | (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING. | |
10676 | (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX. | |
10677 | ||
10678 | * src/muscle_tab.h: Update double inclusion macros. | |
10679 | (macro_entry_s): Rename muscle_entry_s. | |
10680 | Update prototypes. | |
342b8b6e | 10681 | |
11d82f03 MA |
10682 | * src/muscle_tab.c: Include muscle_tab.h. |
10683 | Rename macro_tabble to muscle_table. | |
10684 | (mhash1, mhash2, mcmp): Use muscle_entry. | |
10685 | (macro_init): Rename muscle_init. Update. | |
10686 | (macro_insert): Rename muscle_insert. Update. | |
10687 | (macro_find): Rename muscle_find. Update. | |
10688 | ||
10689 | * src/main.c: Include muscle_tab.h. | |
10690 | (main): Call muscle_init (). | |
10691 | * src/Makefile.am (bison_SOURCES): Echo modifications. | |
10692 | ||
93a37297 MA |
10693 | 2001-09-02 Marc Autret <autret_m@epita.fr> |
10694 | ||
f753cd62 | 10695 | Now the files macro_tab.[ch] are named muscle_tab.[ch]. |
342b8b6e | 10696 | |
f753cd62 MA |
10697 | * src/muscle_tab.c, src/muscle_tab.h: Add files. |
10698 | ||
10699 | 2001-09-02 Marc Autret <autret_m@epita.fr> | |
10700 | ||
10701 | * src/macrotab.c, src/macrotab.h: Remove. | |
93a37297 | 10702 | |
682d48cd PB |
10703 | 2001-09-01 Pascal Bart <pascal.bart@epita.fr> |
10704 | ||
342b8b6e | 10705 | * src/reader.c (copy_guard): Use muscle to specify the `#line' |
682d48cd PB |
10706 | filename. |
10707 | ||
087c8fda MA |
10708 | 2001-09-01 Marc Autret <autret_m@epita.fr> |
10709 | ||
10710 | * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set | |
10711 | to an explicit value to activate the feature. We do it here. | |
10712 | ||
dda680cb PB |
10713 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
10714 | ||
10715 | * src/output.c (prepare): Delete the `filename' muscule insertion. | |
10716 | * src/reader.c (copy_action): Use `filename' muscule with `#line'. | |
10717 | (parse_union_decl): Likewise. | |
10718 | * src/macrotab.c (macro_init): Initialize filename by infile. | |
10719 | ||
9e644e64 MA |
10720 | 2001-08-31 Marc Autret <autret_m@epita.fr> |
10721 | ||
10722 | * src/bison.simple (YYLSP_NEEDED): New definition. | |
10723 | * src/output.c (prepare): Add macro insertion of `locations_flag' | |
10724 | ||
17da6427 PB |
10725 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
10726 | ||
10727 | * src/output.c (prepare): Delete insertion of previous muscles, | |
10728 | and insert the `prefix' muscles. | |
10729 | * src/macrotab.c (macro_init): Likewise. | |
10730 | (macro_init): Initialization prefix directive by `yy'. | |
342b8b6e | 10731 | * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval, |
17da6427 PB |
10732 | %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar, |
10733 | yylval, yydebug, yyerror, yynerrs and yyparse. | |
342b8b6e | 10734 | New directive `#define' to substitute yydebug, ... with option |
17da6427 PB |
10735 | name_prefix. |
10736 | ||
e8cb70b9 PB |
10737 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
10738 | ||
10739 | * src/main.c (main): Standardize. | |
10740 | * src/output.c (output_table_data, output_parser): Likewise. | |
10741 | * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise. | |
10742 | ||
63c2d5de MA |
10743 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr> |
10744 | ||
342b8b6e | 10745 | * src/reader.c (read_additionnal_code): Rename %%user_code to |
63c2d5de MA |
10746 | %%epilogue. |
10747 | * src/output.c (output): Rename %%declarations to %%prologue. | |
10748 | * src/bison.simple: Echo modifications. | |
342b8b6e | 10749 | |
d8cb5183 MA |
10750 | 2001-08-31 Marc Autret <autret_m@epita.fr> |
10751 | ||
10752 | * src/reader.c (readgram): CleanUp. | |
10753 | (output_token_defines): Likewise. | |
10754 | (packsymbols): Likewise. | |
10755 | (reader): Likewise. | |
10756 | * src/output.c (output): CPP-out useless code. | |
10757 | ||
6c686258 PB |
10758 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> |
10759 | ||
342b8b6e | 10760 | * src/reader.c (reader): Delete obsolete call to function |
6c686258 PB |
10761 | output_trailers and output_headers. |
10762 | * src/output.h: Remove obsolete functions prototypes of output_headers | |
10763 | and output_trailers. | |
10764 | ||
8f451ef7 PB |
10765 | 2001-08-30 Pascal Bart <pascal.bart@epita.fr> |
10766 | ||
10767 | * src/main.c: Include macrotab.h. | |
342b8b6e | 10768 | * src/macrotab.h (macro_entry_s): Constify fields. |
8f451ef7 PB |
10769 | Adjust functions prototypes. |
10770 | * src/macrotab.c (macro_insert): Constify key and value. | |
10771 | (macro_find): Constify key. | |
10772 | (macro_insert): Include 'xalloc.h' | |
10773 | (macro_insert): Use XMALLOC. | |
10774 | (macro_find): Constify return value. | |
10775 | * src/output.c (output_table_data): Rename table to table_data. | |
10776 | (output_parser): Constify macro_key, macro_value. | |
10777 | ||
997b6fd0 | 10778 | 2001-08-30 Marc Autret <autret_m@epita.fr> |
2ba3b73c MA |
10779 | |
10780 | * src/reader.c (parse_skel_decl): New. | |
342b8b6e | 10781 | (read_declarations): Add case `tok_skel', call parse_skel_decl (). |
2ba3b73c MA |
10782 | * src/lex.h (token_t): New token `tok_skel'. |
10783 | * src/lex.c (percent_table): Add skeleton option entry. | |
10784 | Standardize. | |
10785 | ||
ff48177d MA |
10786 | 2001-08-29 Marc Autret <autret_m@epita.fr> |
10787 | ||
10788 | * src/bison.simple: Add %%user_code directive at the end. | |
10789 | * src/reader.c (read_additionnal_code): New. | |
10790 | (reader): Use it. | |
10791 | * src/output.c (output_program): Remove. | |
10792 | (output): Update. | |
10793 | ||
b33160bf MA |
10794 | 2001-08-28 Marc Autret <autret_m@epita.fr> |
10795 | ||
10796 | * src/output.c (output_actions): Clean up. | |
4e5caae2 | 10797 | (output_gram): CPP-out useless code. |
b33160bf MA |
10798 | * src/reader.c (reader): Clean up, CPP-out useless code. |
10799 | ||
d1a2daf7 PB |
10800 | 2001-08-28 Pascal Bart <pascal.bart@epita.fr> |
10801 | ||
342b8b6e | 10802 | * src/output.c (output): Copy attrs_obstack in the '%%definitions' |
535c0e75 | 10803 | directive. |
d1a2daf7 PB |
10804 | * src/bison.simple: Add `%%definitions'. |
10805 | ||
2b763dfe MA |
10806 | 2001-08-28 Marc Autret <autret_m@epita.fr> |
10807 | ||
10808 | * config/depcomp: New file. | |
10809 | ||
f1a87ef6 PE |
10810 | 2001-08-27 Paul Eggert <eggert@twinsun.com> |
10811 | ||
10812 | * src/bison.simple (yyparse): Don't take the address of an | |
10813 | item before the start of an array, as that doesn't conform to | |
10814 | the C Standard. | |
10815 | ||
82e236e2 RA |
10816 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> |
10817 | ||
f1a87ef6 | 10818 | * src/output.c (output): Remove the initialization of the macro |
82e236e2 RA |
10819 | obstack. It was done too late here. |
10820 | ||
10821 | * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was | |
10822 | completely wrong. | |
10823 | (reader): Initialize the macro obstack here, since we need it to grow | |
10824 | '%define' directives. | |
10825 | ||
10826 | * src/reader.h: Declare the macro obstack as extern. | |
10827 | ||
b0cfa28a RA |
10828 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> |
10829 | ||
10830 | * src/output.c (output_parser): Fix. Store single '%' characters in | |
10831 | the output obstack instead of throwing them away. | |
10832 | ||
6fc74234 AD |
10833 | 2001-08-27 Akim Demaille <akim@epita.fr> |
10834 | ||
10835 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
10836 | ||
9c76d118 RA |
10837 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10838 | ||
10839 | * lib/Makefile.am: Adjust. | |
10840 | ||
a8289c62 RA |
10841 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10842 | ||
10843 | * src/bison.simple: Update and add '%%' directives. | |
10844 | ||
b6610515 RA |
10845 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10846 | ||
10847 | * src/reader.c (reader): Remove calls to 'output_headers' and | |
10848 | 'output_trailers'. Remove some C output. | |
10849 | (readgram): Disable a piece of code that was writing a default | |
10850 | definition for 'YYSTYPE'. | |
10851 | (reader_output_yylsp): Remove. | |
10852 | (packsymbols): Output token defintions to a macro. | |
10853 | (copy_definition): Disable C output. | |
6fc74234 | 10854 | |
b6610515 RA |
10855 | * src/reader.c (parse_macro_decl): New function used to parse macro |
10856 | declarations. | |
10857 | (copy_string2): Put the body of copy_string into this new function. | |
10858 | Add a parameter to let the caller choose whether he wants to copy the | |
10859 | string delimiters or not. | |
10860 | (copy_string): Be a simple call to copy_string2 with the last argument | |
10861 | bound to true. | |
10862 | (read_declarations): Add case for macro definition. | |
10863 | (copy_identifier): New. | |
6fc74234 | 10864 | (parse_macro_decl): Read macro identifiers using copy_identifier |
b6610515 RA |
10865 | rather than lex. |
10866 | ||
26f609ff RA |
10867 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10868 | ||
10869 | * src/output.c (prepare): Add prefixed names. | |
10870 | (output_parser): Output semantic actions. | |
10871 | (output_parser): Fix bug on '%%line' directives. | |
6fc74234 | 10872 | |
26f609ff RA |
10873 | * src/output.c (output_headers): Remove. The C code printed by this |
10874 | function should now be in the skeletons. | |
10875 | (output_trailers): Remove. | |
10876 | (output): Disable call to 'reader_output_yylsp'. | |
10877 | (output_rule_data): Do not output tables to the table obstack. | |
10878 | ||
10879 | * src/output.c: Remove some C dedicated output. | |
10880 | Improve the use of macro and output obstacks. | |
10881 | (output_defines): Remove. | |
6fc74234 | 10882 | |
26f609ff RA |
10883 | * src/output.c (output_token_translations): Associate 'translate' |
10884 | table with a macro. No output to the table obstack. | |
10885 | (output_gram): Same for 'rhs' and 'prhs'. | |
10886 | (output_stos): Same for 'stos'. | |
10887 | (output_rule_data): Same for 'r1' and 'r2'. | |
10888 | (token_actions): Same for 'defact'. | |
10889 | (goto_actions): Same for 'defgoto'. | |
10890 | (output_base): Same for 'pact' and 'pgoto'. | |
10891 | (output_table): Same for 'table'. | |
10892 | (output_check): Same for 'check'. | |
6fc74234 | 10893 | |
26f609ff RA |
10894 | * src/output.c (output_table_data): New function. |
10895 | (output_short_table): Remove. | |
10896 | (output_short_or_char_table): Remove. | |
6fc74234 | 10897 | |
26f609ff RA |
10898 | * src/output.c (output_parser): Replace most of the skeleton copy code |
10899 | with something new. Skeletons are now processed character by character | |
10900 | rather than line by line, and Bison looks for '%%' macros. This is the | |
10901 | first step in making Bison's output process (a lot) more flexible. | |
10902 | (output_parser): Use the macro table. | |
10903 | ||
6f43b113 RA |
10904 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10905 | ||
10906 | * src/main.c (main): Initialize the macro table. | |
10907 | ||
dd3127cf RA |
10908 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10909 | ||
10910 | * src/lex.c (percent_table): Add tok_define. | |
10911 | * src/lex.h: Add tok_define. | |
10912 | ||
aa321494 RA |
10913 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10914 | ||
10915 | * src/macrotab.c: New file. | |
10916 | * src/macrotab.h: New file. | |
10917 | * src/Makefile.am: Update. | |
10918 | ||
68bd3b6b RA |
10919 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> |
10920 | ||
10921 | * lib/hash.c: New file. | |
10922 | * lib/hash.h: New file. | |
10923 | * lib/Makefile.am: Update. | |
10924 | ||
45f8dd1e AD |
10925 | 2001-08-15 Akim Demaille <akim@epita.fr> |
10926 | ||
10927 | Version 1.28c. | |
10928 | ||
40a64a7a | 10929 | 2001-08-15 Marc Autret <autret_m@epita.fr> |
0b8afb77 AD |
10930 | |
10931 | * src/reader.c (readgram): Indent output macro YYSTYPE. | |
10932 | (packsymbols): Likewise. | |
10933 | (output_token_defines): Likewise. | |
10934 | * src/files.c: Standardize. | |
10935 | (compute_header_macro): New. | |
10936 | (defines_obstack_save): New. Use compute_header_macro. | |
10937 | (output_files): Update. Use defines_obstack_save. | |
10938 | ||
f9a8293a AD |
10939 | 2001-08-15 Akim Demaille <akim@epita.fr> |
10940 | ||
10941 | * doc/bison.texinfo (Table of Symbols): Document | |
10942 | YYSTACK_USE_ALLOCA. | |
10943 | ||
150ca7a7 AD |
10944 | 2001-08-15 Akim Demaille <akim@epita.fr> |
10945 | ||
10946 | * missing: Update from CVS Automake. | |
10947 | * config/config.guess, config/config.sub, config/texinfo.tex: | |
10948 | Update from gnu.org. | |
10949 | ||
69b5cec4 AD |
10950 | 2001-08-15 Akim Demaille <akim@epita.fr> |
10951 | ||
10952 | * Makefile.maint: Sync with CVS Autoconf. | |
10953 | ||
f2b5126e PB |
10954 | 2001-08-14 Pascal Bart <pascal.bart@epita.fr> |
10955 | ||
69b5cec4 | 10956 | * doc/bison.texinfo: Include GNU Free Documentation License from |
f2b5126e PB |
10957 | `fdl.texi'. |
10958 | * doc/fdl.texi: Add to package. | |
10959 | ||
4ecbf796 MA |
10960 | 2001-08-14 Marc Autret <autret_m@epita.fr> |
10961 | ||
10962 | Turn on %{source,header}_extension features. | |
10963 | ||
69b5cec4 | 10964 | * src/lex.c (percent_table): Un-CPP out header_extension and |
4ecbf796 MA |
10965 | source_extension. |
10966 | * src/files.c (compute_exts_from_gf): Compare pointers with NULL. | |
69b5cec4 | 10967 | (compute_exts_from_src): Remove conditions. It restores priorities |
4ecbf796 MA |
10968 | between options. |
10969 | ||
95fb5662 MA |
10970 | 2001-08-14 Marc Autret <autret_m@epita.fr> |
10971 | ||
10972 | * src/files.c (compute_base_names): Add extensions computing when | |
10973 | `--file-prefix' used. | |
10974 | Standardize function calls. | |
10975 | ||
78d09da9 MA |
10976 | 2001-08-13 Marc Autret <autret_m@epita.fr> |
10977 | ||
69b5cec4 | 10978 | * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users |
78d09da9 MA |
10979 | defining it (defined but null disables alloca). |
10980 | ||
5a009f2c MA |
10981 | 2001-08-13 Marc Autret <autret_m@epita.fr> |
10982 | ||
10983 | * src/bison.simple (_yy_memcpy): CPP reformat. | |
10984 | ||
1e41465a PB |
10985 | 2001-08-13 Pascal Bart <pascal.bart@epita.fr> |
10986 | ||
10987 | * tests/atconfig.in (CPPFLAGS): Fix. | |
10988 | ||
c67a198d PB |
10989 | 2001-08-10 Pascal Bart <pascal.bart@epita.fr> |
10990 | ||
79282c6c | 10991 | * doc/bison.texinfo: Include GNU General Public License from |
c67a198d PB |
10992 | `gpl.texi'. |
10993 | * doc/gpl.texi: Add to package. | |
10994 | ||
09a6de7e MA |
10995 | 2001-08-10 Marc Autret <autret_m@epita.fr> |
10996 | ||
10997 | * src/print_graph.h: Fix. | |
10998 | * src/reader.c (read_declarations): Use parse_header_extension_decl (). | |
10999 | ||
b77b9ee0 AD |
11000 | 2001-08-10 Akim Demaille <akim@epita.fr> |
11001 | ||
11002 | * src/system.h: Provide default declarations for stpcpy, strndup, | |
11003 | and strnlen. | |
11004 | ||
3e259915 MA |
11005 | 2001-08-10 Robert Anisko <anisko_r@epita.fr> |
11006 | ||
11007 | * doc/bison.texinfo (Locations): Update @$ stuff. | |
11008 | ||
ca96bc2d MA |
11009 | 2001-08-09 Robert Anisko <anisko_r@epita.fr> |
11010 | ||
11011 | * src/bison.simple (YYLLOC_DEFAULT): Update. | |
11012 | (yyparse): Adjust. | |
11013 | ||
fdc6758b MA |
11014 | 2001-08-08 Marc Autret <autret_m@epita.fr> |
11015 | ||
b77b9ee0 | 11016 | * doc/bison.texinfo: Change @samp{$<@dots{}>} to |
fdc6758b MA |
11017 | @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule. |
11018 | Reported by Fabrice Bauzac. | |
957d4dbf | 11019 | |
600cad3b MA |
11020 | 2001-08-08 Marc Autret <autret_m@epita.fr> |
11021 | ||
11022 | * src/vcg_default.h: Use NULL instead of 0 to initialize pointers. | |
11023 | * src/vcg.c (output_node): Fix. | |
11024 | * src/vcg.h: Cleanup. | |
11025 | * src/print_graph.c: Add comments. | |
b77b9ee0 | 11026 | (node_output_size): New global variable. Simplify the formatting of |
600cad3b | 11027 | the VCG graph output. |
b77b9ee0 | 11028 | (print_actions): Unused code is now used. It notifies the final state |
600cad3b | 11029 | and no action states in the VCG graph. It also give the reduce actions. |
b77b9ee0 | 11030 | The `shift and goto' edges are red and the `go to state' edges are |
600cad3b MA |
11031 | blue. |
11032 | Get the current node name and node_obstack by argument. | |
11033 | (node_obstack): New variable. | |
11034 | (print_state): Manage node_obstack. | |
11035 | (print_core): Use node_obstack given by argument. | |
11036 | A node is not only computed here but in print_actions also. | |
11037 | (print_graph): CPP out useless code instead of commenting it. | |
11038 | ||
976e528f AD |
11039 | 2001-08-07 Pascal Bart <pascal.bart@epita.fr> |
11040 | ||
11041 | * tests/atconfig.in (CPPFLAGS): Fix. | |
11042 | ||
20e8e5ca AD |
11043 | 2001-08-07 Akim Demaille <akim@epita.fr> |
11044 | ||
11045 | * src/print_graph.c (quote): New. | |
11046 | (print_core): Use it. | |
11047 | ||
957d4dbf | 11048 | 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr> |
3e3da797 | 11049 | |
3e3da797 AD |
11050 | * src/vcg.c (complain.h): Include it. |
11051 | Unepitaize `return' invocations. | |
c4b66126 | 11052 | [NDEBUG] (main): Remove. |
79282c6c | 11053 | * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members. |
c4b66126 AD |
11054 | * src/files.c (open_files): Initialize graph_obstack. |
11055 | * src/print_graph.c (print_actions): CPP out useless code. | |
11056 | (print_core): Don't output the last `\n' in labels. | |
11057 | Use `quote'. | |
11058 | * src/files.c (output_files): Output the VCG file. | |
11059 | * src/main.c (main): Invoke print_graph (); | |
3e3da797 | 11060 | |
957d4dbf | 11061 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
22c2cbc0 AD |
11062 | |
11063 | Automaton VCG graph output. | |
11064 | Using option ``-g'' or long option ``--graph'', you can generate | |
11065 | a gram_filename.vcg file containing a VCG description of the LALR (1) | |
11066 | automaton of your grammar. | |
11067 | ||
11068 | * src/main.c: Call to print_graph() function. | |
11069 | * src/getargs.h: Update. | |
11070 | * src/getargs.c (options): Update to catch `-g' and `--graph' options. | |
11071 | (graph_flag): New flag. | |
11072 | (longopts): Update. | |
11073 | (getargs): Add case `g'. | |
11074 | * src/files.c (graph_obstack): New obstack struct. | |
11075 | (open_files): Initialize new obstack. | |
11076 | (output_files): Saves graph_obstack if required. | |
11077 | * src/files.h (graph_obstack): New extern declaration. | |
11078 | * src/Makefile.am: Add new source files. | |
11079 | ||
927c1557 | 11080 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
ce4d5ce0 AD |
11081 | |
11082 | * src/print_graph.c, src/print_graph.h (graph): New. | |
11083 | * src/vcg.h: New file. | |
11084 | * src/vcg.c: New file, VCG graph handling. | |
11085 | ||
7333d403 AD |
11086 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
11087 | ||
11088 | Add of %source_extension and %header_extension which specify | |
11089 | the source or/and the header output file extension. | |
11090 | ||
11091 | * src/files.c (compute_base_names): Remove initialisation of | |
11092 | src_extension and header_extension. | |
11093 | (compute_exts_from_gf): Update. | |
11094 | (compute_exts_from_src): Update. | |
11095 | (output_files): Update. | |
11096 | * src/reader.c (parse_header_extension_decl): New. | |
11097 | (parse_source_extension_decl): New. | |
11098 | (read_declarations): New case statements for the new tokens. | |
11099 | * src/lex.c (percent_table): Add entries for %source_extension | |
11100 | and %header_extension. | |
11101 | * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext. | |
11102 | ||
84163231 AD |
11103 | 2001-08-06 Marc Autret <autret_m@epita.fr> |
11104 | ||
11105 | * configure.in: Bump to 1.28c. | |
11106 | * doc/bison.texinfo: Texinfo thingies. | |
11107 | ||
8303fc42 AD |
11108 | 2001-08-04 Pascal Bart <pascal.bart@epita.fr> |
11109 | ||
11110 | * tests/atconfig.in (CPPFLAGS): Add. | |
11111 | * tests/calc.at (AT_CHECK): Use CPPFLAGS. | |
11112 | ||
70a84437 AD |
11113 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11114 | ||
11115 | Version 1.28b. | |
11116 | ||
2ce10144 AD |
11117 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11118 | ||
11119 | * tests/Makefile.am (check-local): Ship testsuite. | |
11120 | * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions. | |
11121 | Include `string.h'. | |
11122 | ||
1e3e4bc1 AD |
11123 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11124 | ||
11125 | * configure.in: Try using -Wformat when compiling. | |
11126 | ||
42b45b7f AD |
11127 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11128 | ||
11129 | * configure.in: Bump to 1.28b. | |
11130 | ||
8f13fe33 AD |
11131 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11132 | ||
11133 | * src/complain.c: Adjust strerror_r portability issues. | |
11134 | ||
b37ba92c AD |
11135 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11136 | ||
11137 | Version 1.28a. | |
11138 | ||
b0ce6046 AD |
11139 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11140 | ||
11141 | * src/getargs.c, src/getarg.h (skeleton)): Constify. | |
11142 | * src/lex.c (literalchar): Avoid name clashes on `buf'. | |
11143 | * src/getargs.c: Include complain.h. | |
11144 | * src/files.c, src/files.h (skeleton_find): Avoid name clashes. | |
11145 | * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1. | |
11146 | ||
d01c415b AD |
11147 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11148 | ||
11149 | * src/reader.c (readgram): Display hidden chars in error messages. | |
11150 | ||
459dd1a6 AD |
11151 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11152 | ||
11153 | Update to gettext 0.10.39. | |
11154 | ||
53b74c0c AD |
11155 | 2001-08-03 Akim Demaille <akim@epita.fr> |
11156 | ||
11157 | * lib/strspn.c: New. | |
11158 | ||
234a3be3 AD |
11159 | 2001-08-01 Marc Autret <autret_m@epita.fr> |
11160 | ||
11161 | * doc/bison.texinfo: Update. | |
11162 | * doc/bison.1 (mandoc): Update. | |
11163 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h. | |
11164 | * src/files.c: Support output files extensions computing. | |
11165 | (src_extension): New static variable. | |
11166 | (header_extension): New static variable. | |
11167 | (tr): New function. | |
11168 | (get_extension_index): New function, gets the index of an extension | |
11169 | filename in a string. | |
11170 | (compute_exts_from_gf): New function, computes extensions from the | |
11171 | grammar file extension. | |
11172 | (compute_exts_from_src): New functions, computes extensions from the | |
11173 | C source file extension, file given by ``-o'' option. | |
11174 | (compute_base_names): Update. | |
11175 | (output_files): Update. | |
11176 | ||
847bf1f5 AD |
11177 | 2001-08-01 Robert Anisko <anisko_r@epita.fr> |
11178 | ||
d995fee7 | 11179 | * doc/bison.texi: Document @$. |
847bf1f5 AD |
11180 | (Locations): New section. |
11181 | ||
d074a105 AD |
11182 | 2001-07-18 Akim Demaille <akim@epita.fr> |
11183 | ||
11184 | * Makefile.maint, GNUmakefile: New, from Autoconf 2.52. | |
11185 | * config/prev-version.txt, config/move-if-change: New. | |
11186 | * Makefile.am: Adjust. | |
11187 | ||
3419715d AD |
11188 | 2001-07-08 Pascal Bart <pascal.bart@epita.fr> |
11189 | ||
11190 | * src/bison.simple (yyparse): Suppress warning `comparaison | |
11191 | between signed and unsigned'. | |
11192 | ||
62ab6972 AD |
11193 | 2001-07-05 Pascal Bart <pascal.bart@epita.fr> |
11194 | ||
11195 | * src/getargs.h (raw_flag): Remove. | |
11196 | * src/getargs.c: Die on `-r'/`--raw'. | |
11197 | * src/lex.c (parse_percent_token): Die on `%raw'. | |
11198 | * src/reader.c (output_token_defines): Suppress call to `raw_flag'. | |
11199 | * tests/calc.at: Suppress test with option `--raw'. | |
11200 | ||
1e24cc5b AD |
11201 | 2001-07-14 Akim Demaille <akim@epita.fr> |
11202 | ||
11203 | * config/: New. | |
11204 | * configure.in: Require Autoconf 2.50. | |
11205 | Update to gettext 0.10.38. | |
11206 | ||
32dfccf8 AD |
11207 | 2001-03-16 Akim Demaille <akim@epita.fr> |
11208 | ||
11209 | * doc/bison.texinfo: ANSIfy the examples. | |
11210 | ||
cd5bd6ac AD |
11211 | 2001-03-16 Akim Demaille <akim@epita.fr> |
11212 | ||
11213 | * getargs.c (skeleton): New variable. | |
11214 | (longopts): --skeleton is a new option. | |
11215 | (shortopts, getargs): -S is a new option. | |
11216 | * getargs.h: Declare skeleton. | |
11217 | * output.c (output_parser): Use it. | |
11218 | ||
5141b016 AD |
11219 | 2001-03-16 Akim Demaille <akim@epita.fr> |
11220 | ||
11221 | * m4/strerror_r.m4: New. | |
11222 | * m4/error.m4: Run AC_FUNC_STRERROR_R. | |
11223 | * lib/error.h, lib/error.c: Update. | |
11224 | ||
447992b9 AD |
11225 | 2001-03-16 Akim Demaille <akim@epita.fr> |
11226 | ||
11227 | * src/getargs.c (longopts): Clean up. | |
11228 | ||
274d42ce AD |
11229 | 2001-02-21 Akim Demaille <akim@epita.fr> |
11230 | ||
11231 | * src/reader.c (gensym): `gensym_count' is your own. | |
11232 | Use a static buf to create the symbol name, as token_buffer is no | |
11233 | longer a buffer. | |
11234 | ||
22c821f3 AD |
11235 | 2001-02-08 Akim Demaille <akim@epita.fr> |
11236 | ||
11237 | * src/conflicts.c (conflict_report): Be sure not to append to res | |
11238 | between two calls, which could happen if both first sprintf were | |
11239 | skipped, but not the first cp += strlen. | |
11240 | ||
18569462 AD |
11241 | 2001-02-08 Akim Demaille <akim@epita.fr> |
11242 | ||
11243 | * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c: | |
11244 | New, from fileutils 4.0.37. | |
11245 | * configure.in: Require Autoconf 2.49c. I took some time before | |
11246 | making this decision. This is the only way out for portability | |
11247 | issues in Bison, it would mean way too much duplicate effort to | |
11248 | import in Bison features implemented in 2.49c since 2.13. | |
11249 | AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above. | |
11250 | ||
0d8f3c8a AD |
11251 | 2001-02-02 Akim Demaille <akim@epita.fr> |
11252 | ||
11253 | * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37. | |
66075dcf | 11254 | * lib/xalloc.h, lib/xmalloc.c: Update. |
0d8f3c8a | 11255 | |
f17bcd1f AD |
11256 | 2001-01-19 Akim Demaille <akim@epita.fr> |
11257 | ||
11258 | Get rid of the ad hoc handling of token_buffer in the scanner: use | |
11259 | the obstacks. | |
11260 | ||
11261 | * src/lex.c (token_obstack): New. | |
11262 | (init_lex): Initialize it. No longer call... | |
11263 | (grow_token_buffer): this. Remove it. | |
11264 | Adjust all the places which used it to use the obstack. | |
11265 | ||
511e79b3 AD |
11266 | 2001-01-19 Akim Demaille <akim@epita.fr> |
11267 | ||
11268 | * src/lex.h: Rename all the tokens: | |
11269 | s/\bENDFILE\b/tok_eof/g; | |
11270 | s/\bIDENTIFIER\b/tok_identifier/g; | |
11271 | etc. | |
11272 | Let them be enums, not #define, to ease debugging. | |
11273 | Adjust all the code. | |
11274 | ||
0d6508ef AD |
11275 | 2001-01-18 Akim Demaille <akim@epita.fr> |
11276 | ||
11277 | * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private. | |
11278 | * src/lex.c (maxtoken, grow_token_buffer): Static. | |
11279 | ||
6deb4447 AD |
11280 | 2001-01-18 Akim Demaille <akim@epita.fr> |
11281 | ||
11282 | Since we now use obstacks, more % directives can be enabled. | |
11283 | ||
11284 | * src/lex.c (percent_table): Also accept `%yacc', | |
11285 | `%fixed_output_files', `%defines', `%no_parser', `%verbose', and | |
11286 | `%debug'. | |
11287 | Handle the actions for `%semantic_parser' and `%pure_parser' here, | |
11288 | instead of returning a token. | |
11289 | * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused. | |
11290 | * src/reader.c (read_declarations): Adjust. | |
11291 | * src/files.c (open_files): Don't call `compute_base_names', don't | |
11292 | compute `attrsfile' since they depend upon data which might be | |
11293 | *in* the input file now. | |
11294 | (output_files): Do it here. | |
11295 | * src/output.c (output_headers): Document the fact that this patch | |
11296 | introduces a guaranteed SEGV for semantic parsers. | |
11297 | * doc/bison.texinfo: Document them. | |
11298 | * tests/suite.at: Exercise these %options. | |
11299 | ||
ff4423cc AD |
11300 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11301 | ||
11302 | Also handle the output file (--verbose) with obstacks. | |
11303 | ||
11304 | * files.c (foutput): Remove. | |
11305 | (output_obstack): New. | |
11306 | Adjust all dependencies. | |
11307 | * src/conflicts.c: Return a string. | |
11308 | * src/system.h (obstack_grow_string): Rename as... | |
11309 | (obstack_sgrow): this. Be ready to work with non literals. | |
11310 | (obstack_fgrow4): New. | |
11311 | ||
956dba3a AD |
11312 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11313 | ||
11314 | * src/files.c (open_files): Fix the computation of short_base_name | |
11315 | in the case of `-o foo.tab.c'. | |
11316 | ||
337bab46 AD |
11317 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11318 | ||
11319 | * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at) | |
11320 | (copy_dollar): Now that everything uses obstacks, get rid of the | |
11321 | FILE * parameters. | |
11322 | ||
5d3214b8 AD |
11323 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11324 | ||
11325 | * src/files.c (open_files): Actually the `.output' file is based | |
11326 | on the short_base_name, not base_name. | |
11327 | * tests/suite.at (Checking output file names): Adjust. | |
11328 | ||
29092a57 AD |
11329 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11330 | ||
11331 | * src/bison.s1: Remove, we now use directly... | |
11332 | * src/bison.simple: this. | |
11333 | * src/Makefile.am: Use pkgdata instead of data. | |
11334 | ||
ea5607fd AD |
11335 | 2000-12-20 Akim Demaille <akim@epita.fr> |
11336 | ||
11337 | * src/files.c (guard_obstack): New. | |
11338 | (open_files): Initialize it. | |
11339 | (output_files): Dump it... | |
11340 | * src/files.h: Export it. | |
11341 | * src/reader.c (copy_guard): Use it. | |
11342 | ||
27110317 AD |
11343 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11344 | ||
11345 | * src/files.c (outfile, defsfile, actfile): Removed as global | |
11346 | vars. | |
11347 | (open_files): Don't compute them. | |
11348 | (output_files): Adjust. | |
11349 | (base_name, short_base_name): Be global. | |
11350 | Adjust dependencies. | |
11351 | ||
19c50364 AD |
11352 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11353 | ||
11354 | * src/files.c (strsuffix): New. | |
11355 | (stringappend): Be just like strcat but allocate. | |
11356 | (base_names): Eve out from open_files. | |
11357 | Try to simplify the rather hairy computation of base_name and | |
11358 | short_base_name. | |
11359 | (open_files): Use it. | |
11360 | * tests/suite.at (Checking output file names): New test. | |
11361 | ||
573c1d9f AD |
11362 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11363 | ||
11364 | * src/system.h (obstack_grow_literal_string): Rename as... | |
11365 | (obstack_grow_string): this. | |
11366 | * src/output.c (output_parser): Recognize `%% actions' instead of | |
11367 | `$'. | |
11368 | * src/bison.s1: s/$/%% actions/. | |
11369 | * src/bison.hairy: Likewise. | |
11370 | ||
ef7ddedd AD |
11371 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11372 | ||
11373 | * src/output.c (output_parser): Compute the `#line' lines when | |
11374 | there are. | |
11375 | * src/Makefile.am (bison.simple): Be a simple copy of bison.s1. | |
11376 | Suggested by Hans Aberg. | |
11377 | ||
ff61dabd AD |
11378 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11379 | ||
11380 | Let the handling of the skeleton files be local to the procedures | |
11381 | that use it. | |
11382 | ||
11383 | * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No | |
11384 | longer static. | |
11385 | (fparser, open_extra_files): Remove. | |
11386 | (open_files, output_files): Don't take care of fparser. | |
11387 | * src/files.h: Adjust. | |
11388 | * src/output.c (output_parser): Open and close the file to the | |
11389 | skeleton. | |
11390 | * src/reader.c (read_declarations): When %semantic_parser, open | |
11391 | fguard. | |
11392 | ||
55b96341 AD |
11393 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11394 | ||
11395 | * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here... | |
11396 | * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here. | |
11397 | ||
358c15b7 AD |
11398 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11399 | ||
11400 | * src/files.c (open_files): Yipee! We no longer need all the code | |
11401 | looking for `/tmp' since we have no tmp file. | |
11402 | ||
7de3329e AD |
11403 | 2000-12-19 Akim Demaille <akim@epita.fr> |
11404 | ||
11405 | * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C): | |
11406 | New macros. | |
11407 | * src/files.c (open_files): Less dependency on MSDOS etc. | |
11408 | ||
3abcd459 AD |
11409 | 2000-12-14 Akim Demaille <akim@epita.fr> |
11410 | ||
11411 | * src/bison.s1 (YYLLOC_DEFAULT): New macro. | |
11412 | Provide a default definition. | |
11413 | Use it when executing the default @ action. | |
11414 | * src/reader.c (reader_output_yylsp): No longer include | |
11415 | `timestamp' and `text' in the default YYLTYPE. | |
11416 | ||
2a91a95e AD |
11417 | 2000-12-12 Akim Demaille <akim@epita.fr> |
11418 | ||
11419 | * src/reader.c (copy_definition, parse_union_decl, copy_action) | |
11420 | (copy_guard): Quote the file names. | |
11421 | Reported by Laurent Mascherpa. | |
11422 | ||
14d3eb9b AD |
11423 | 2000-12-12 Akim Demaille <akim@epita.fr> |
11424 | ||
11425 | * src/output.c (output_headers, output_program, output): Be sure | |
11426 | to escape special characters when outputting filenames. | |
11427 | (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove. | |
11428 | (output_headers): Don't depend on them, Use ACTSTR. | |
11429 | ||
d7045ec6 AD |
11430 | 2000-11-17 Akim Demaille <akim@epita.fr> |
11431 | ||
11432 | * lib/obstack.h: Formatting changes. | |
11433 | (obstack_grow, obstack_grow0): Don't cast WHERE at all: it | |
11434 | prevents type checking. | |
11435 | (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't | |
11436 | cast the value to (void *): assigning a `foo *' to a `void *' | |
11437 | variable is valid. | |
11438 | (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int. | |
11439 | * src/reader.c (parse_union_decl): Typo: use obstack_1grow to | |
11440 | append characters. | |
11441 | ||
6fd54b73 AD |
11442 | 2000-11-17 Akim Demaille <akim@epita.fr> |
11443 | ||
11444 | * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename | |
11445 | as... | |
11446 | (suite.m4, regression.m4, calc.m4): these. | |
11447 | * tests/atgeneral.m4: Update from CVS Autoconf. | |
11448 | ||
4c50eae6 AD |
11449 | 2000-11-17 Akim Demaille <akim@epita.fr> |
11450 | ||
11451 | * tests/regression.m4 (%union and --defines): New test, | |
11452 | demonstrating a current bug in the obstack implementation. | |
11453 | ||
a35f64ea AD |
11454 | 2000-11-17 Akim Demaille <akim@epita.fr> |
11455 | ||
11456 | * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New | |
11457 | macros. | |
11458 | Use them to declare the variables which are global or local to | |
11459 | `yyparse'. | |
11460 | ||
7de23534 AD |
11461 | 2000-11-17 Akim Demaille <akim@epita.fr> |
11462 | ||
11463 | * acconfig.h: Remove, no longer used. | |
11464 | ||
aa7815f5 AD |
11465 | 2000-11-07 Akim Demaille <akim@epita.fr> |
11466 | ||
11467 | * src: s/Copyright (C)/Copyright/g. | |
11468 | ||
5af1f549 AD |
11469 | 2000-11-07 Akim Demaille <akim@epita.fr> |
11470 | ||
11471 | * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just | |
11472 | defining. | |
11473 | * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/. | |
11474 | ||
553e2b22 AD |
11475 | 2000-11-07 Akim Demaille <akim@epita.fr> |
11476 | ||
11477 | * src/bison.s1 (YYLEX): Use #if instead of #ifdef. | |
11478 | Merge in a single CPP if/else. | |
11479 | ||
8a4f41d6 AD |
11480 | 2000-11-07 Akim Demaille <akim@epita.fr> |
11481 | ||
11482 | * src/output.c (output): Remove useless variables. | |
11483 | * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second | |
11484 | argument `data' for consistency with the prototypes. | |
11485 | Qualify it `const'. | |
11486 | (obstack_copy, obstack_copy0): Rename the second argument as | |
11487 | `address' for consistency. Qualify it `const'. | |
11488 | * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow) | |
11489 | (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify | |
11490 | `const' their input argument (`data' or `address'). | |
11491 | Adjust the corresponding macros to include `const' in casts. | |
11492 | ||
095a3fb5 AD |
11493 | 2000-11-03 Akim Demaille <akim@epita.fr> |
11494 | ||
11495 | * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/. | |
11496 | s/PFILE1/BISON_HAIRY/. | |
11497 | Adjust dependencies. | |
11498 | ||
d1cdce7c AD |
11499 | 2000-11-03 Akim Demaille <akim@epita.fr> |
11500 | ||
090c5ebf | 11501 | For some reason, this was not applied. |
d1cdce7c AD |
11502 | |
11503 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
11504 | `unlink': it's no longer used. | |
11505 | ||
9311529b AD |
11506 | 2000-11-03 Akim Demaille <akim@epita.fr> |
11507 | ||
11508 | * src/files.c (skeleton_find): New function, eved out of... | |
11509 | (open_files, open_extra_files): here. | |
11510 | ||
d8880f69 AD |
11511 | 2000-11-03 Akim Demaille <akim@epita.fr> |
11512 | ||
11513 | Don't use `atexit'. | |
11514 | ||
11515 | * src/files.c (obstack_save): New function. | |
11516 | (done): Rename as... | |
11517 | (output_files): this. | |
11518 | Use `obstack_save'. | |
11519 | * src/main.c (main): Don't use `atexit' to register `done', since | |
11520 | it no longer has to remove tmp files, just call `output_files' | |
11521 | when there are no errors. | |
11522 | ||
0dbb648e AD |
11523 | 2000-11-02 Akim Demaille <akim@epita.fr> |
11524 | ||
11525 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
11526 | `unlink': it's no longer used. | |
11527 | * src/files.h: Formatting changes. | |
11528 | ||
896fe5c1 AD |
11529 | 2000-11-02 Akim Demaille <akim@epita.fr> |
11530 | ||
11531 | Remove the last uses of mktemp and unlink/delete. | |
11532 | ||
11533 | * src/files.c (fdefines, ftable): Removed. | |
11534 | (defines_ostack, table_obstack): New. | |
11535 | Adjust dependencies of the former into uses of the latter. | |
11536 | * src/output.c (output_short_or_char_table, output_short_table): | |
11537 | Convert to using obstacks. | |
11538 | * src/reader.c (copy_comment2): Accept one FILE * and two | |
11539 | obstacks. | |
11540 | (output_token_defines, reader_output_yylsp): Use obstacks. | |
11541 | * src/system.h (obstack_fgrow3): New. | |
1f65350a | 11542 | * po/POTFILES.in: Adjust. |
896fe5c1 | 11543 | |
dd60faec AD |
11544 | 2000-11-01 Akim Demaille <akim@epita.fr> |
11545 | ||
11546 | Change each use of `fattrs' into a use of `attrs_obstack'. | |
11547 | ||
11548 | * src/reader.c (copy_at): Typo: s/yylloc/yyloc/. | |
11549 | * src/files.c (fattrs): Remove. | |
11550 | (attrs_obstack): New. | |
11551 | Adjust all dependencies. | |
11552 | (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile. | |
11553 | ||
8c7ebe49 AD |
11554 | 2000-11-01 Akim Demaille <akim@epita.fr> |
11555 | ||
11556 | Introduce obstacks. | |
11557 | Change each use of `faction' into a use of `action_obstack'. | |
11558 | ||
11559 | * lib/obstack.h, lib/obstack.c: New files. | |
11560 | * src/files.c (faction): Remove. | |
11561 | (action_obstack): New. | |
11562 | Adjust all dependencies. | |
11563 | ||
77aee789 AD |
11564 | 2000-10-20 Akim Demaille <akim@epita.fr> |
11565 | ||
11566 | * lib/quote.h (PARAMS): New macro. Use it. | |
11567 | ||
43591cec AD |
11568 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11569 | ||
11570 | * src/output.c (output_short_or_char_table): New function. | |
11571 | (output_short_table, output_token_translations): Use it. | |
11572 | (goto_actions): Use output_short_table. | |
11573 | ||
1e9798d5 AD |
11574 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11575 | ||
11576 | * src/symtab.c (bucket_new): New function. | |
11577 | (getsym): Use it. | |
11578 | ||
11579 | * src/output.c (output_short_table): New argument to display the | |
11580 | comment associated with the table. | |
11581 | Adjust dependencies. | |
11582 | (output_gram): Use it. | |
11583 | (output_rule_data): Nicer output layout for YYTNAME. | |
11584 | ||
f282676b AD |
11585 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11586 | ||
11587 | * src/lex.c (read_typename): New function. | |
11588 | (lex): Use it. | |
11589 | * src/reader.c (copy_dollar): Likewise. | |
11590 | ||
550a72a3 AD |
11591 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11592 | ||
11593 | * src/reader.c (copy_comment2): Expect the input stream to be on | |
11594 | the `/' which is suspected to open a comment, instead of being | |
11595 | called after `//' or `/*' was read. | |
11596 | (copy_comment, copy_definition, parse_union_decl, copy_action) | |
11597 | (copy_guard): Adjust. | |
11598 | ||
131e2fef AD |
11599 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11600 | ||
11601 | * src/reader.c (parse_expect_decl): Use `skip_white_space' and | |
11602 | `read_signed_integer'. | |
11603 | ||
79282c5a AD |
11604 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11605 | ||
11606 | * src/reader.c (copy_dollar): New function. | |
11607 | (copy_guard, copy_action): Use it. | |
11608 | ||
ff4a34be AD |
11609 | 2000-10-16 Akim Demaille <akim@epita.fr> |
11610 | ||
11611 | * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c: | |
11612 | * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4: | |
11613 | New files, from Fileutils 4.0.27. | |
11614 | * src/main.c (printable_version): Remove. | |
11615 | * src/lex.c, src/reader.c: Use `quote'. | |
11616 | ||
11617 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
11618 | ||
11619 | * lib/error.c, lib/error.h: New files, needed by xmalloc.c. | |
11620 | ||
14ded682 AD |
11621 | 2000-10-04 Akim Demaille <akim@epita.fr> |
11622 | ||
11623 | * doc/bison.texinfo: Various typos spotted by Neil Booth. | |
11624 | ||
8e03724b AD |
11625 | 2000-10-04 Akim Demaille <akim@epita.fr> |
11626 | ||
11627 | When a literal string is used to define two different tokens, | |
11628 | `bison -v' segfaults. | |
11629 | Reported by Piotr Gackiewicz, and fixed by Neil Booth. | |
11630 | ||
11631 | * tests/regression.m4: New file. | |
11632 | Include the core of the sample provided by Piotr Gackiewicz. | |
11633 | * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed | |
11634 | properly. | |
11635 | ||
a9e64249 AD |
11636 | 2000-10-04 Akim Demaille <akim@epita.fr> |
11637 | ||
11638 | * src/reader.c (parse_expect_decl): Keep `count' within the size | |
11639 | of `buffer'. | |
11640 | From Neil Booth. | |
11641 | ||
da9abf43 AD |
11642 | 2000-10-02 Paul Eggert <eggert@twinsun.com> |
11643 | ||
11644 | * bison.s1 (yyparse): Assign the default value | |
11645 | unconditionally, to avoid a GCC warning and make the parser a | |
11646 | tad smaller. | |
11647 | ||
c33638bb AD |
11648 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11649 | ||
11650 | * src/getargs.c (getargs): Don't dump `--help' on unrecognized | |
11651 | options. | |
11652 | ||
444c570a AD |
11653 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11654 | ||
11655 | * src/derives.c, src/print.c, src/reduce.c: To ease the | |
11656 | translation, move some `\n' out of the translated strings. | |
11657 | ||
89cab50d AD |
11658 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11659 | ||
11660 | The location tracking mechanism is precious for parse error | |
11661 | messages. Nevertheless, it is enabled only when `@n' is used in | |
11662 | the grammar, which is a different issue (you can use it in error | |
11663 | message, but not in the grammar per se). Therefore, there should | |
11664 | be another means to enable it. | |
11665 | ||
11666 | * src/getargs.c (getargs): Support `--locations'. | |
11667 | (usage): Report it. | |
11668 | * src/getargs.h (locationsflag): Export it. | |
11669 | * src/lex.c (percent_table): Support `%locations'. | |
11670 | * src/reader.c (yylsp_needed): Remove this variable, now replaced | |
11671 | with `locationsflag'. | |
11672 | * doc/bison.texinfo: Document `--locations' and `%locations'. | |
11673 | Sort the options. | |
11674 | * tests/calc.m4: Test it. | |
11675 | ||
11676 | For regularity of the names, replace each | |
11677 | (nolineflag, toknumflag, rawtokenumflag, noparserflag): with... | |
11678 | (no_lineflag, token_tableflag, rawflag, no_parserflag): this. | |
11679 | In addition replace each `flag' with `_flag'. | |
11680 | ||
d6c2cba0 AD |
11681 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11682 | ||
11683 | Also test parse error messages, including with YYERROR_VERBOSE. | |
11684 | ||
11685 | * tests/calc.m4 (calc.y): Add support for `exp = exp' (non | |
11686 | associative). | |
11687 | Use it to check the computations. | |
11688 | Use it to check `nonassoc' is honored. | |
11689 | (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed | |
11690 | `--yyerror-verbose'. | |
11691 | (_AT_CHECK_CALC): Adjust to this option. | |
11692 | (_AT_CHECK_CALC_ERROR): New macro to check parse error messages. | |
11693 | ||
5a35a6cb AD |
11694 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11695 | ||
11696 | Test also `--verbose', `--defines' and `--name-prefix'. Testing | |
11697 | the latter demonstrates a flaw in the handling of non debugging | |
11698 | parsers introduced by myself on 2000-03-16: `#define yydebug 0' | |
11699 | was used in order to simplify: | |
11700 | ||
11701 | #if YYDEBUG | |
11702 | if (yydebug) | |
11703 | { | |
11704 | ... | |
11705 | } | |
11706 | #endif | |
11707 | ||
11708 | into | |
11709 | ||
11710 | if (yydebug) | |
11711 | { | |
11712 | ... | |
11713 | } | |
11714 | ||
11715 | unfortunately this leads to a CPP conflict when | |
11716 | `--name-prefix=foo' is used since it produces `#define yydebug | |
11717 | foodebug'. | |
11718 | ||
11719 | * src/bison.s1 [!YYDEBUG]: Do not define yydebug. | |
11720 | (YYDPRINTF): New macro. | |
11721 | Spread its use. | |
11722 | * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from | |
11723 | the bison options. | |
11724 | Also test `--verbose', `--defines' and `--name-prefix'. | |
11725 | ||
71da9eea AD |
11726 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11727 | ||
11728 | Improve the readability of the produced parsers. | |
11729 | ||
11730 | * src/bison.s1: Formatting changes. | |
11731 | Improve the comment related to the `$' mark. | |
11732 | (yydefault): Don't fall through to `yyresume': `goto' there. | |
11733 | * src/output.c (output_parser): When the `$' is met, skip the end | |
11734 | of its line. | |
11735 | New variable, `number_of_dollar_signs', to check there's exactly | |
11736 | one `$' in the parser skeleton. | |
11737 | ||
95e36146 AD |
11738 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11739 | ||
11740 | * lib/xstrdup.c: New file, from the fileutils. | |
11741 | * src/reader.c (parse_token_decl, get_type_name, parse_type_decl) | |
11742 | (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup' | |
11743 | instead of strlen + xmalloc + strcpy. | |
11744 | * src/symtab.c (copys): Remove, use xstrdup instead. | |
11745 | ||
d7020c20 AD |
11746 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11747 | ||
11748 | * src/gram.h (associativity): New enum type which replaces the | |
11749 | former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with | |
11750 | `right_assoc', `left_assoc' and `non_assoc'. | |
11751 | Adjust all dependencies. | |
11752 | * src/reader.c: Formatting changes. | |
11753 | (LTYPESTR): Don't define it, use it as a literal in | |
11754 | `reader_output_yylsp'. | |
11755 | * src/symtab.h (symbol_class): New enum type which replaces the | |
11756 | former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with | |
11757 | `sunknown', `stoken and `snterm'. | |
11758 | ||
1916f98e AD |
11759 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11760 | ||
11761 | * src/getargs.c (fixed_outfiles): Rename as... | |
11762 | (yaccflag): for consistency and accuracy. | |
11763 | Adjust dependencies. | |
11764 | ||
d7913476 AD |
11765 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11766 | ||
11767 | Use the more standard files `xalloc.h' and `xmalloc.c' instead of | |
11768 | Bison's `allocate.c' and `alloc.h'. This patch was surprisingly | |
11769 | difficult and introduced a lot of core dump. It turns out that | |
11770 | Bison used an implementation of `xmalloc' based on `calloc', and | |
11771 | at various places it does depend upon the initialization to 0. I | |
11772 | have not tried to isolate the pertinent places, and all the former | |
11773 | calls to Bison's `xmalloc' are now using `XCALLOC'. Someday, | |
11774 | someone should address this issue. | |
11775 | ||
11776 | * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove. | |
11777 | * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New | |
11778 | files. | |
11779 | Adjust dependencies. | |
11780 | * src/warshall.h: New file. | |
11781 | Propagate. | |
11782 | ||
340ef489 AD |
11783 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11784 | ||
11785 | Various anti-`extern in *.c' changes. | |
11786 | ||
11787 | * src/system.h: Include `assert.h'. | |
11788 | ||
b2ca4022 AD |
11789 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11790 | ||
11791 | * src/state.h (nstates, final_state, first_state, first_shift) | |
11792 | (first_reduction): Move their exportation from here... | |
11793 | * src/LR0.h: to here. | |
11794 | Adjust dependencies. | |
11795 | * src/getargs.c (statisticsflag): New variable. | |
11796 | Add support for `--statistics'. | |
11797 | Adjust dependencies. | |
11798 | ||
11799 | Remove a lot of now useless `extern' statements in most files. | |
11800 | ||
403b315b AD |
11801 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11802 | ||
11803 | * src/LR0.h: New file. | |
11804 | Propagate its use. | |
11805 | ||
07a58c13 AD |
11806 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11807 | ||
11808 | * src/print.h: New file. | |
11809 | Propagate its use. | |
11810 | * src/print.c: Formatting and ordering changes. | |
11811 | (verbose, terse): Replace with... | |
11812 | (print_results): this new function. | |
11813 | Adjust dependencies. | |
11814 | ||
0619caf0 AD |
11815 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11816 | ||
11817 | * src/conflicts.c (conflict_report): New function. | |
11818 | (conflict_log, verbose_conflict_log): Replace with... | |
11819 | (print_conflicts): this function. | |
11820 | Adjust dependencies. | |
11821 | * src/conflicts.h: New file. | |
11822 | Propagate its inclusion. | |
11823 | ||
3519ec76 AD |
11824 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11825 | ||
11826 | * src/nullable.h: New file. | |
11827 | Propagate its inclusion. | |
11828 | * src/nullable.c: Formatting changes. | |
11829 | ||
015acc48 AD |
11830 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11831 | ||
11832 | * src/reduce.h: New file. | |
11833 | Propagate its inclusion. | |
11834 | * src/reduce.c: Topological sort and other formatting changes. | |
11835 | (bool, TRUE, FALSE): Move their definition to... | |
11836 | * src/system.h: here. | |
11837 | ||
8963a27b AD |
11838 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11839 | ||
11840 | * src/files.c: Formatting changes. | |
11841 | (tryopen, tryclose, openfiles): Rename as... | |
11842 | (xfopen, xfclose, open_files): this. | |
11843 | (stringappend): static. | |
11844 | * src/files.h: Complete the list of exported symbols. | |
11845 | Propagate its use. | |
11846 | ||
a70083a3 AD |
11847 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11848 | ||
11849 | * src/reader.h: New file. | |
11850 | Propagate its use instead of tedious list of `extern' and | |
11851 | prototypes. | |
11852 | * src/reader.c: Formatting changes, topological sort, | |
11853 | s/register//. | |
11854 | ||
abadc117 AD |
11855 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11856 | ||
11857 | * src/lex.h: Prototype `lex.c' exported functions. | |
11858 | * src/reader.c: Adjust. | |
11859 | * src/lex.c: Formatting changes. | |
11860 | (safegetc): Rename as... | |
11861 | (xgetc): this. | |
11862 | ||
720d742f AD |
11863 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11864 | ||
11865 | * src/lalr.h: New file. | |
11866 | Propagate its inclusion instead of prototypes and `extern'. | |
11867 | * src/lalr.c: Formatting changes, topological sorting etc. | |
11868 | ||
f2acea59 AD |
11869 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11870 | ||
11871 | * src/output.c (token_actions): Introduce a temporary array, | |
11872 | YYDEFACT, that makes it possible for this function to use | |
11873 | output_short_table. | |
11874 | ||
d019d655 AD |
11875 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11876 | ||
11877 | `user_toknums' is output as a `short[]' in `output.c', while it is | |
11878 | defined as a `int[]' in `reader.c'. For consistency with the | |
11879 | other output tables, `user_toknums' is now defined as a table of | |
11880 | shorts. | |
11881 | ||
11882 | * src/reader.c (user_toknums): Be a short table instead of an int | |
11883 | table. | |
11884 | Adjust dependencies. | |
11885 | ||
11886 | Factor the short table outputs. | |
11887 | ||
11888 | * src/output.c (output_short_table): New function. | |
11889 | * src/output.c (output_gram, output_stos, output_rule_data) | |
11890 | (output_base, output_table, output_check): Use it. | |
11891 | ||
6c89f1c1 AD |
11892 | 2000-10-02 Akim Demaille <akim@epita.fr> |
11893 | ||
11894 | * src/output.c (output): Topological sort of the functions, in | |
11895 | order to get rid of the `static' prototypes. | |
11896 | No longer use `register'. | |
11897 | * src/output.h: New file. | |
11898 | Propagate its inclusion in files explicitly prototyping functions | |
11899 | from output.c. | |
11900 | ||
d9efd181 AD |
11901 | 2000-09-21 Akim Demaille <akim@epita.fr> |
11902 | ||
11903 | * src/atgeneral.m4: Update from Autoconf. | |
11904 | ||
c29240e7 | 11905 | 2000-09-21 Akim Demaille <akim@epita.fr> |
2fa6973e AD |
11906 | |
11907 | * src/closure.h: New file. | |
11908 | * src/closure.c: Formatting changes, topological sort over the | |
11909 | functions, use of closure.h. | |
11910 | (initialize_closure, finalize_closure): Rename as... | |
11911 | (new_closure, free_closure): these. Adjust dependencies. | |
11912 | * src/LR0.c: Formatting changes, topological sort, use of | |
11913 | cloture.h. | |
11914 | (initialize_states): Rename as... | |
11915 | (new_states): this. | |
11916 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
11917 | ||
499daa50 AD |
11918 | 2000-09-20 Akim Demaille <akim@epita.fr> |
11919 | ||
11920 | * src/acconfig.h: Don't protect config.h against multiple | |
11921 | inclusion. | |
11922 | Don't define PARAMS. | |
11923 | * src/system.h: Define PARAMS. | |
11924 | Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the | |
11925 | purpose of config.h. system.h must not try to fix wrong | |
11926 | definitions in config.h. | |
11927 | ||
cc84fd5d AD |
11928 | 2000-09-20 Akim Demaille <akim@epita.fr> |
11929 | ||
11930 | * src/derives.h: New file. | |
11931 | * src/main.c, src/derives.h: Use it. | |
11932 | Formatting changes. | |
11933 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
11934 | ||
db5b3a89 AD |
11935 | 2000-09-20 Akim Demaille <akim@epita.fr> |
11936 | ||
11937 | * tests/atgeneral.m4: Update from Autoconf. | |
11938 | * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC) | |
11939 | (AT_CHECK_CALC): New macros. | |
11940 | Use these macros to test bison with options `', `--raw', | |
11941 | `--debug', `--yacc', `--yacc --debug'. | |
11942 | ||
ceed8467 AD |
11943 | 2000-09-19 Akim Demaille <akim@epita.fr> |
11944 | ||
11945 | * src/output.c: Formatting changes. | |
11946 | * src/machine.h: Remove, leaving its contents in... | |
11947 | * src/system.h: here. | |
11948 | Include stdio.h. | |
11949 | Adjust all dependencies on stdio.h and machine.h. | |
11950 | * src/getargs.h: New file. | |
11951 | Let all `extern' declarations about getargs.c be replaced with | |
11952 | inclusion of `getargs.h'. | |
11953 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
11954 | ||
11955 | * tests/calc.m4 (yyin): Be initialized in main, not on the global | |
11956 | scope. | |
11957 | (yyerror): Returns void, not int. | |
11958 | * doc/bison.texinfo: Formatting changes. | |
11959 | ||
05a1d24b AD |
11960 | 2000-09-19 Akim Demaille <akim@epita.fr> |
11961 | ||
11962 | * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not | |
11963 | portable. | |
11964 | ||
cbd25751 AD |
11965 | 2000-09-18 Akim Demaille <akim@epita.fr> |
11966 | ||
11967 | * configure.in: Append WARNING_CFLAGS to CFLAGS. | |
11968 | * src/Makefile.am (INCLUDES): Don't. | |
11969 | Be ready to fetch headers in lib/. | |
11970 | ||
13863333 AD |
11971 | 2000-09-18 Akim Demaille <akim@epita.fr> |
11972 | ||
11973 | * doc/bison.texinfo: Update the copyright. | |
11974 | ANSIfy and GNUify the examples. | |
11975 | Remove the old menu. | |
11976 | ||
0d533154 AD |
11977 | 2000-09-18 Akim Demaille <akim@epita.fr> |
11978 | ||
11979 | First set of tests: use the `calc' example from the documentation. | |
11980 | ||
11981 | * src/bison.s1 (yyparse): Condition the code using `yytname' which | |
11982 | is defined only when YYDEBUG is. | |
11983 | * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13. | |
11984 | * src/files.c (tryopen, tryclose): Formatting changes. | |
11985 | Move to the top and be static. | |
11986 | * src/reader.c (read_signed_integer): Likewise. | |
11987 | * tests/calc.m4: New file. | |
11988 | * Makefile.am, suite.m4: Adjust. | |
11989 | * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY. | |
11990 | ||
e79137ac AD |
11991 | 2000-09-18 Akim Demaille <akim@epita.fr> |
11992 | ||
11993 | Add support for an Autotest test suite for Bison. | |
11994 | ||
11995 | * m4/m4.m4, m4/atconfig.m4: New files. | |
11996 | * m4/Makefile.am (EXTRA_DIST): Adjust. | |
11997 | * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New | |
11998 | files. | |
11999 | * src/getargs.c: Display a more standard --version message. | |
12000 | * src/reader.c (reader): Formatting changes. | |
12001 | No longer depend upon VERSION_STRING. | |
12002 | * configure.in: No longer use `dnl'. | |
12003 | Set up the test suite and the new directory `tests/. | |
12004 | (VERSION_STRING): Remove. | |
12005 | ||
27821bff AD |
12006 | 2000-04-14 Akim Demaille <akim@epita.fr> |
12007 | ||
12008 | * src/reader.c (copy_comment2): New function, same as former | |
12009 | `copy_comment', but outputs into two FILE *. | |
12010 | (copy_comment): Use it. | |
12011 | (parse_union_decl): Use it. | |
12012 | (get_type, parse_start_decl): Use the same `invalid' message. | |
12013 | (parse_start_decl, parse_union_decl): Use the same `multiple' | |
12014 | message. | |
12015 | (parse_union_decl, copy_guard, copy_action): Use the same | |
12016 | `unmatched' message. | |
12017 | * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'. | |
12018 | ||
cfe5fbc0 AD |
12019 | 2000-03-31 Akim Demaille <akim@epita.fr> |
12020 | ||
12021 | * src/files.c (tryopen, tryclose): Move to the top. | |
12022 | Be static. | |
12023 | ||
cb7db13e AD |
12024 | 2000-03-31 Akim Demaille <akim@epita.fr> |
12025 | ||
12026 | * src/main.c (main): Don't call `done', exit does it. | |
12027 | ||
a0f6b076 AD |
12028 | 2000-03-31 Akim Demaille <akim@epita.fr> |
12029 | ||
36281465 AD |
12030 | * allocate.c: s/return (foo)/return foo/. |
12031 | * lalr.c: Likewise. | |
12032 | * LR0.c: Likewise. | |
12033 | * output.c: Likewise. | |
12034 | * reader.c: Likewise. | |
12035 | * symtab.c: Likewise. | |
12036 | * vmsgetargs.c: Likewise. | |
12037 | ||
12038 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
12039 | ||
12040 | Clean up the error reporting functions. | |
a0f6b076 AD |
12041 | |
12042 | * src/report.c: New file. | |
12043 | * src/report.h: Likewise. | |
12044 | * src/Makefile.am: Adjust. | |
12045 | * m4/error.m4: New file. | |
12046 | * m4/Makefile.am: Adjust. | |
12047 | * configure.in (jm_PREREQ_ERROR): Call it. | |
12048 | * src/main.c (int_to_string, banner, fatal_banner, warn_banner): | |
12049 | Remove. | |
12050 | (fatal, fatals): Remove. All callers use complain.c::fatal. | |
12051 | (warn, warni, warns, warnss, warnss): Remove. All callers use | |
12052 | complain.c::complain. | |
12053 | (toomany): Remove, use fatal instead. | |
12054 | * src/files.c (done): No argument, use complain_message_count. | |
12055 | * src/main.c (main): Register `done' to `atexit'. | |
12056 | ||
12057 | * src/getargs.c (usage): More `fputs', less `fprintf'. | |
12058 | ||
18539825 AD |
12059 | 2000-03-28 Akim Demaille <akim@epita.fr> |
12060 | ||
12061 | * lib/: New directory. | |
12062 | * Makefile.am (SUBDIRS): Adjust. | |
12063 | * configure.in: Adjust. | |
12064 | (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's | |
12065 | useless. | |
12066 | * src/alloca.c: Moved to lib/. | |
12067 | * src/getopt.c: Likewise. | |
12068 | * src/getopt1.c: Likewise. | |
12069 | * src/getopt.h: Likewise. | |
12070 | * src/ansi2knr.c: Likewise. | |
12071 | * src/ansi2knr.1: Likewise. | |
12072 | * src/Makefile.am: Adjust. | |
12073 | * lib/Makefile.am: New file. | |
12074 | ||
9f306f2a AD |
12075 | 2000-03-28 Akim Demaille <akim@epita.fr> |
12076 | ||
12077 | * src/getargs.c (usage): Refresh the help message. | |
12078 | ||
0ba347b6 AD |
12079 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12080 | ||
12081 | * src/getopt1.c: Updated from textutils 2.0e | |
12082 | * src/getopt.c: Likewise. | |
12083 | * src/getopt.h: Likewise. | |
12084 | ||
dbe7f271 AD |
12085 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12086 | ||
12087 | * src/Makefile.am (bison.simple): Fix the awk program: quote only | |
12088 | the file name, not the whole `#line LINE FILE'. | |
12089 | ||
75bbe78d AD |
12090 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12091 | ||
12092 | On syntax errors, report the token on which we choked. | |
12093 | ||
aa5fd0ee AD |
12094 | * src/bison.s1 (yyparse): In the label yyerrlab, when |
12095 | YYERROR_VERBOSE, add yychar in msg. | |
75bbe78d | 12096 | |
7b306f52 AD |
12097 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12098 | ||
aa5fd0ee | 12099 | * src/reader.c (copy_at): New function. |
7b306f52 AD |
12100 | (copy_guard): Use it. |
12101 | (copy_action): Use it. | |
12102 | ||
e87b5700 AD |
12103 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12104 | ||
12105 | Be kind to translators, save some useless translations. | |
12106 | ||
aa5fd0ee | 12107 | * src/main.c (banner): New function. |
e87b5700 AD |
12108 | (fatal_banner): Use it. |
12109 | (warn_banner): Use it. | |
12110 | ||
ae3c3164 AD |
12111 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12112 | ||
aa5fd0ee AD |
12113 | * src/reader.c (copy_definition): Use copy_string and |
12114 | copy_comment. Removed now unused `match', `ended', | |
12115 | `cplus_comment'. | |
ae3c3164 AD |
12116 | (copy_comment, copy_string): Moved, to be visible from |
12117 | copy_definition. | |
12118 | ||
4dc58e7c AD |
12119 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12120 | ||
aa5fd0ee AD |
12121 | * src/reader.c (copy_string): Declare `static inline'. No |
12122 | problems with inline, since it is checked by configure. | |
4dc58e7c AD |
12123 | (copy_comment): Likewise. |
12124 | ||
0a6384c4 AD |
12125 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12126 | ||
aa5fd0ee | 12127 | * src/reader.c (packsymbols): Formatting changes. |
0a6384c4 | 12128 | |
3cef001a AD |
12129 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12130 | ||
aa5fd0ee | 12131 | * src/reader.c (copy_comment): New function, factored out from: |
3cef001a AD |
12132 | (copy_action): Use it. Removed now unused `match', `ended', |
12133 | `cplus_comment'. | |
12134 | (copy_guard): Likewise. | |
12135 | ||
ca36d2ef AD |
12136 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12137 | ||
aa5fd0ee | 12138 | * src/reader.c (copy_string): New function, factored out from: |
ca36d2ef AD |
12139 | (copy_action): Use it. |
12140 | (copy_guard): Likewise. | |
12141 | ||
6666f98f AD |
12142 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12143 | ||
12144 | Change the handling of @s so that they behave exactly like $s. | |
12145 | There is now a pseudo variable @$ (readble and writable), location | |
12146 | of the lhs of the rule (by default ranging from the location of | |
12147 | the first symbol of the rhs, to the location of the last symbol, | |
12148 | or, if the rhs is empty, YYLLOC). | |
12149 | ||
12150 | * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of | |
12151 | yyval. | |
12152 | (yyparse): When providing a default semantic action, provide a | |
12153 | default location action. | |
12154 | (after the $): No longer change `*YYLSP', just stack YYLOC the | |
12155 | same way you stack YYVAL. | |
12156 | * src/reader.c (read_declarations): Use warns. | |
12157 | (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'. | |
12158 | (copy_action, case '@'): Likewise. | |
12159 | Use a standard error message, to save useless work from | |
12160 | translators. | |
12161 | ||
41aca2e0 AD |
12162 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12163 | ||
aa5fd0ee AD |
12164 | * src/bison.s1: Formatting and cosmetics changes. |
12165 | * src/reader.c: Likewise. | |
41aca2e0 AD |
12166 | Update the Copyright notice. |
12167 | ||
dc08c1d5 AD |
12168 | 2000-03-17 Akim Demaille <akim@epita.fr> |
12169 | ||
aa5fd0ee AD |
12170 | * src/bison.s1 (#line): All set to `#line' only, since the |
12171 | Makefile now handles them. | |
dc08c1d5 | 12172 | |
9ee3c97b AD |
12173 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12174 | ||
12175 | * src/output.c (output_rule_data): Output the documentation of | |
12176 | some of the tables. | |
12177 | (Copyright notice): Update. | |
12178 | Formatting changes. | |
12179 | ||
0de741ca AD |
12180 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12181 | ||
12182 | * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to | |
12183 | remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough. | |
12184 | One `#if YYDEBUG' remains, since it uses variables which are | |
12185 | defined only if `YYDEBUG != 0'. | |
12186 | ||
bb10be54 AD |
12187 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12188 | ||
12189 | * src/bison.s1 (yyparse): Reorganize the definitions of the stacks | |
12190 | and related variables so that the similarities are highlighted. | |
12191 | ||
b07b484a AD |
12192 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12193 | ||
12194 | * src/bison.s1: Properly indent CPP directives. | |
12195 | ||
361f60b3 AD |
12196 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12197 | ||
12198 | * src/bison.s1: Properly indent the `alloca' CPP section. | |
12199 | ||
8c44d3ec AD |
12200 | 2000-03-16 Akim Demaille <akim@epita.fr> |
12201 | ||
12202 | Do not hard code values of directories in `configure.in'. | |
12203 | Update the `configure' tool chain. | |
12204 | ||
12205 | * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by | |
12206 | src/makefile.am. | |
12207 | (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED. | |
12208 | (AC_OUTPUT): Add m4/Makefile. | |
12209 | Bump to bison 1.28a, 1.29 has never been released. | |
12210 | * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are | |
12211 | handled via src/Makefile.am. | |
12212 | (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS, | |
12213 | HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by | |
12214 | autoheader. | |
12215 | * Makefile.am (SUBDIRS): Add m4. | |
12216 | (ACLOCAL_AM_FLAGS): New variable. | |
12217 | (AUTOMAKE_OPTIONS): Add check-news. | |
12218 | * src/Makefile.am (bison.simple): Use awk to replace #line lines with | |
12219 | the proper line number and file name. | |
12220 | (DEFS): Propagate the location of bison library files and of the | |
12221 | locale files. | |
12222 | (INCLUDES): Added `-I ..' so that one can compile with srcdir != | |
12223 | builddir. | |
12224 | * acinclude.m4: Remove, replaced by the directory m4. | |
12225 | * m4/Makefile.am (EXTRA_DIST): New variable. | |
12226 | * m4/gettext.m4: New file, from the fileutils. | |
12227 | * m4/lcmessage.m4: Likewise | |
12228 | * m4/progtest.m4: Likewise. | |
12229 | * m4/bison-decl.m4: New file, extracted from former acinclude.m4. | |
12230 | ||
f95997e7 AD |
12231 | 2000-03-10 Akim Demaille <akim@epita.fr> |
12232 | ||
12233 | * src/closure.c: | |
12234 | Formatting changes of various comments. | |
12235 | Respect the GNU coding standards at various places. | |
12236 | Don't use `_()' when no translation is needed. | |
12237 | ||
12238 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
12239 | ||
12240 | * src/files.c: | |
12241 | OS/2 honors TMPDIR environment variable. | |
12242 | ||
12243 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
12244 | ||
12245 | * doc/bison.texinfo: Tweaked spelling and grammar. | |
12246 | Updated ISBN. | |
12247 | Removed reference to price of printed copy. | |
12248 | Mention BISON_SIMPLE and BISON_HAIRY. | |
12249 | ||
12250 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
12251 | ||
12252 | * configure.in, NEWS: | |
12253 | Bison 1.29 released. | |
12254 | ||
12255 | 1999-10-27 Jesse Thilo <jthilo@gnu.org> | |
12256 | ||
12257 | * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex: | |
12258 | Added reference card. | |
12259 | ||
12260 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
12261 | ||
12262 | * po/ru.po: Added Russian translation. | |
12263 | ||
12264 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
12265 | ||
12266 | * configure.in: Added Russian translation. | |
12267 | ||
12268 | 1999-07-06 Jesse Thilo <jthilo@gnu.org> | |
12269 | ||
12270 | * configure.in, NEWS, README: | |
12271 | Released version 1.28. | |
12272 | ||
12273 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
12274 | ||
12275 | * src/system.h: | |
12276 | Squashed redefinition warning on some systems. | |
12277 | ||
12278 | * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c: | |
12279 | Have configure build version string instead of relying on ANSI string | |
12280 | concatentation. | |
12281 | ||
12282 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
12283 | ||
12284 | * po/POTFILES.in: Got rid of version.c. | |
12285 | ||
12286 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
12287 | ||
12288 | * acconfig.h, configure.in: | |
12289 | Have configure build version string instead of relying on ANSI string | |
12290 | concatentation. | |
12291 | ||
12292 | 1999-06-08 Jesse Thilo <jthilo@gnu.org> | |
12293 | ||
12294 | * doc/bison.1: | |
12295 | Dropped mention of `+' for long-named options. | |
12296 | ||
12297 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
12298 | ||
12299 | * src/files.c: Added <unistd.h> for unlink(). | |
12300 | ||
12301 | * src/Makefile.am, src/system.h: | |
12302 | I18n fixes. | |
12303 | ||
12304 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
12305 | ||
12306 | * README: Added a FAQ list. | |
12307 | ||
12308 | * configure.in, acconfig.h: | |
12309 | I18n fixes. | |
12310 | ||
12311 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
12312 | ||
12313 | * doc/FAQ, doc/Makefile.am: | |
12314 | Added a FAQ list. | |
12315 | ||
12316 | 1999-05-19 Jesse Thilo <jthilo@gnu.org> | |
12317 | ||
12318 | * src/alloc.h, src/symtab.h, src/version.c: | |
12319 | Protected inclusion of "config.h" with HAVE_CONFIG_H. | |
12320 | ||
12321 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
12322 | ||
12323 | * src/.cvsignore, src/Makefile.am: | |
12324 | Reorganized: sources in `src', documentation in `doc'. | |
12325 | ||
12326 | * src/lex.c (literalchar): | |
12327 | fixed the code for escaping double quotes (thanks | |
12328 | Jonathan Czisny.) | |
12329 | ||
12330 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
12331 | ||
12332 | * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in: | |
12333 | Adjusted paths to reflect directory reorganization. | |
12334 | ||
12335 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
12336 | ||
12337 | * doc/.cvsignore, doc/Makefile.am: | |
12338 | Reorganized: sources in `src', documentation in `doc'. | |
12339 | ||
12340 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
12341 | ||
12342 | * configure.in: | |
12343 | Updated AC_INIT file to reflect directory reorganization. | |
12344 | ||
12345 | * configure.in, .cvsignore, Makefile.am, POTFILES.in: | |
12346 | Reorganized: sources in `src', documentation in `doc'. | |
12347 | ||
12348 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
12349 | ||
12350 | * src/allocate.c: | |
12351 | Don't declare calloc() and realloc() if not necessary. | |
12352 | ||
12353 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
12354 | ||
12355 | * configure.in, acconfig.h, acinclude.m4: | |
12356 | Don't declare calloc() and realloc() if not necessary. | |
12357 | ||
12358 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
12359 | ||
12360 | * po/.cvsignore: Added i18n support. | |
12361 | ||
12362 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
12363 | ||
12364 | * acconfig.h, configure.in, Makefile.am: | |
12365 | Added i18n support. | |
12366 | ||
12367 | 1999-03-22 Jesse Thilo <jthilo@gnu.org> | |
12368 | ||
12369 | * src/bison.s1: Fixed #line numbers. | |
12370 | ||
12371 | 1999-03-15 Jesse Thilo <jthilo@gnu.org> | |
12372 | ||
12373 | * po/es.po, po/fr.po, po/nl.po, po/de.po: | |
12374 | Added PO files from Translation Project. | |
12375 | ||
12376 | 1999-03-03 Jesse Thilo <jthilo@gnu.org> | |
12377 | ||
12378 | * Makefile.am: | |
12379 | Added support for non-ANSI compilers (ansi2knr). | |
12380 | ||
12381 | 1999-02-16 Jesse Thilo <jthilo@gnu.org> | |
12382 | ||
12383 | * configure.in: Bumped version number to 1.27. | |
12384 | ||
12385 | * Makefile.am: | |
12386 | Added `bison.simple' to list of files removed by `make distclean'. | |
12387 | ||
12388 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
12389 | ||
12390 | * src/files.c, src/files.h: | |
12391 | Defined locations of parser files in config.h instead of Makefile. | |
12392 | ||
12393 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
12394 | ||
12395 | * acconfig.h, acinclude.m4, configure.in, Makefile.am: | |
12396 | Defined locations of parser files in config.h instead of Makefile. | |
12397 | ||
12398 | 1999-02-09 Jesse Thilo <jthilo@gnu.org> | |
12399 | ||
12400 | * Makefile.am: | |
12401 | Removed inappropriate use of $< macro. | |
12402 | ||
12403 | 1999-02-05 Jesse Thilo <jthilo@gnu.org> | |
12404 | ||
12405 | * po/Makefile.in.in, po/POTFILES.in: | |
12406 | Add `po' directory skeleton. | |
12407 | ||
12408 | 1999-01-27 Jesse Thilo <jthilo@gnu.org> | |
12409 | ||
12410 | * README: Document help-bison list. | |
12411 | ||
12412 | * configure.in: Add check for mkstemp(). | |
12413 | ||
12414 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
12415 | ||
12416 | * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c: | |
12417 | Hush a few compiler warnings. | |
12418 | ||
12419 | * src/files.c: | |
12420 | Add tryclose(), which verifies that fclose was successful. | |
12421 | Hush a couple of compiler warnings. | |
12422 | ||
12423 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
12424 | ||
12425 | * Makefile.am, OChangeLog: | |
12426 | ChangeLog is now automatically generated. Include the old version as | |
12427 | OChangeLog. | |
12428 | ||
12429 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
12430 | ||
12431 | * 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: | |
12432 | Update FSF address. | |
12433 | ||
12434 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
12435 | ||
12436 | * doc/bison.texinfo: Fix formatting glitch. | |
12437 | ||
12438 | * doc/bison.texinfo: Update FSF address. | |
12439 | ||
12440 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
12441 | ||
12442 | * acconfig.h: Update FSF address. | |
12443 | ||
12444 | 1999-01-08 Jesse Thilo <jthilo@gnu.org> | |
12445 | ||
12446 | * src/system.h: | |
12447 | Don't define PACKAGE here, since config.h defines it. | |
12448 | ||
12449 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
12450 | ||
12451 | * src/reader.c: Update copyright date. | |
12452 | ||
12453 | * src/main.c: | |
12454 | Ditch sprintf to statically-sized buffers in fatal/warn functions in | |
12455 | favor of output directly to stderr (avoids buffer overruns). | |
12456 | ||
12457 | * src/reader.c: Some checks for premature EOF. | |
12458 | ||
12459 | * 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: | |
12460 | Use prototypes if the compiler understands them. | |
12461 | ||
12462 | * src/files.c: Honor TMPDIR on Unix hosts. | |
12463 | Use prototypes if the compiler understands them. | |
12464 | ||
12465 | * src/reader.c: | |
12466 | Fix a couple of buffer overrun bugs. | |
12467 | Use prototypes if the compiler understands them. | |
12468 | ||
12469 | * src/system.h: Include unistd.h and ctype.h. | |
12470 | Use #ifdef instead of #if for NLS symbols. | |
12471 | ||
12472 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
12473 | ||
12474 | * doc/bison.texinfo: | |
12475 | Delete comment "consider using @set for edition number, etc..." since | |
12476 | we now are doing so. | |
12477 | ||
12478 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
12479 | ||
12480 | * configure.in: | |
12481 | Use prototypes if the compiler understands them. | |
12482 | ||
12483 | * NEWS: Document 1.26 highlights. | |
12484 | ||
12485 | * Makefile.am: Require Automake 1.3 or later. | |
12486 | ||
12487 | * acconfig.h: | |
12488 | Use prototypes if the compiler understands them. | |
12489 | ||
12490 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
12491 | ||
12492 | * src/version.c: | |
12493 | Use VERSION symbol from automake for version number. | |
12494 | ||
12495 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
12496 | ||
12497 | * acconfig.h, configure.in, version.cin: | |
12498 | Use VERSION symbol from automake for version number. | |
12499 | ||
12500 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
12501 | ||
12502 | * Makefile.am: | |
12503 | Distribute original version of simple parser (bison.s1), not built | |
12504 | version (bison.simple). | |
12505 | ||
12506 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
12507 | ||
12508 | * doc/bison.texinfo: Add info dir entry. | |
12509 | ||
12510 | * doc/bison.texinfo: | |
12511 | Let automake put version number into documentation. | |
12512 | ||
12513 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
12514 | ||
12515 | * src/bison.cld, src/build.com, src/vmshlp.mar: | |
12516 | Add non-RCS files from /gd/gnu/bison. | |
12517 | ||
12518 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
12519 | ||
12520 | * doc/bison.1: | |
12521 | Document the BISON_HAIRY and BISON_SIMPLE variables. | |
12522 | ||
12523 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
12524 | ||
12525 | * src/version.c: Build version.c automatically. | |
12526 | ||
12527 | * src/reader.c: | |
12528 | Fix token numbering (used to start at 258, not 257). | |
12529 | ||
12530 | * src/system.h: Include config.h. | |
12531 | ||
12532 | * src/getargs.c: Update bug report address. | |
12533 | ||
12534 | * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h: | |
12535 | Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org. | |
12536 | ||
12537 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
12538 | ||
12539 | * Makefile.am: | |
12540 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
12541 | ||
12542 | * configure.in, version.cin: | |
12543 | Build version.c automatically. | |
12544 | ||
12545 | * AUTHORS: Add AUTHORS file. | |
12546 | ||
12547 | * README: Update bug report address. | |
12548 | ||
12549 | * bison.simple: | |
12550 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
12551 | ||
12552 | * configure.in, Makefile.am, Makefile.in, stamp-h.in: | |
12553 | Add automake stuff. | |
12554 | ||
12555 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
12556 | ||
12557 | * doc/bison.texinfo: Clean up some formatting. | |
12558 | ||
12559 | 1998-05-05 Richard Stallman <rms@gnu.org> | |
12560 | ||
12561 | * doc/bison.texinfo: | |
12562 | Explain better why to make a pure parser. | |
12563 | ||
12564 | 1998-01-05 Richard Stallman <rms@gnu.org> | |
12565 | ||
12566 | * src/files.c (openfiles): | |
12567 | [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to | |
12568 | find a temporary directory, if possible. Do not unlink files while | |
12569 | they are open. | |
12570 | ||
12571 | 1997-08-25 Richard Stallman <rms@gnu.org> | |
12572 | ||
12573 | * src/reader.c (stack_offset;): | |
12574 | Change some warni to warns. | |
12575 | ||
12576 | * src/lex.c (literalchar): Use warns, not warni. | |
12577 | ||
12578 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
12579 | ||
12580 | * src/bison.s1: Add a Bison version comment. | |
12581 | ||
12582 | * src/main.c (fatal, warn, berror): | |
12583 | Use program_name. | |
12584 | ||
12585 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
12586 | ||
12587 | * Makefile.in (bison_version): New variable. | |
12588 | (dist): Use that variable. | |
12589 | (bison.s1): Substitute the Bison version into bison.simple. | |
12590 | ||
12591 | * bison.simple: Add a Bison version comment. | |
12592 | ||
12593 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
12594 | ||
12595 | * src/main.c (fatal, warn, berror): | |
12596 | Make error messages standard. | |
12597 | (toomany): Improve error message text. | |
12598 | ||
12599 | * 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: | |
12600 | new.h renamed to alloc.h. | |
12601 | ||
12602 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
12603 | ||
12604 | * Makefile.in: new.h renamed to alloc.h. | |
12605 | ||
12606 | 1997-05-24 Richard Stallman <rms@gnu.org> | |
12607 | ||
12608 | * src/lex.c (literalchar): | |
12609 | Fix the code for escaping \, " and '. | |
12610 | ||
12611 | (lex): Avoid trouble when there are many chars | |
12612 | to discard in a char literal with just several chars in it. | |
12613 | ||
12614 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
12615 | ||
12616 | * src/bison.s1: | |
12617 | Use malloc, if using alloca is troublesome. | |
12618 | (YYSTACK_USE_ALLOCA): New flag macro. | |
12619 | Define it for some systems and compilers. | |
12620 | (YYSTACK_ALLOC): New macro. | |
12621 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
12622 | If it was malloc'd, free it. | |
12623 | ||
12624 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
12625 | ||
12626 | * bison.simple: | |
12627 | Use malloc, if using alloca is troublesome. | |
12628 | (YYSTACK_USE_ALLOCA): New flag macro. | |
12629 | Define it for some systems and compilers. | |
12630 | (YYSTACK_ALLOC): New macro. | |
12631 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
12632 | If it was malloc'd, free it. | |
12633 | ||
12634 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
12635 | ||
12636 | * src/bison.s1: | |
12637 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
12638 | ||
12639 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
12640 | ||
12641 | * bison.simple: | |
12642 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
12643 | ||
12644 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
12645 | ||
12646 | * src/bison.s1: | |
12647 | [__hpux]: Include alloca.h (right for HPUX 10) | |
12648 | instead of declaring alloca (right for HPUX 9). | |
12649 | ||
12650 | * src/bison.s1 (__yy_memcpy): | |
12651 | Declare arg `count' as unsigned int. | |
12652 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
12653 | ||
12654 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
12655 | ||
12656 | * bison.simple: | |
12657 | [__hpux]: Include alloca.h (right for HPUX 10) | |
12658 | instead of declaring alloca (right for HPUX 9). | |
12659 | ||
12660 | * bison.simple (__yy_memcpy): | |
12661 | Declare arg `count' as unsigned int. | |
12662 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
12663 | ||
12664 | 1997-01-03 Richard Stallman <rms@gnu.org> | |
12665 | ||
12666 | * src/allocate.c: [__STDC__ or _MSC_VER]: | |
12667 | Declare calloc and realloc to return void *. | |
12668 | ||
12669 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
12670 | ||
12671 | * src/system.h: | |
12672 | [_MSC_VER]: Include stdlib.h and process.h. | |
12673 | [_MSC_VER] (getpid): Define as macro--translate it to _getpid. | |
12674 | ||
12675 | * src/main.c (main): Return FAILURE as a value. | |
12676 | (printable_version): Declare arg as int, not char. | |
12677 | ||
12678 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
12679 | ||
12680 | * Makefile.in (dist): | |
12681 | Explicitly check for symlinks, and copy them. | |
12682 | ||
12683 | 1996-12-19 Richard Stallman <rms@gnu.org> | |
12684 | ||
12685 | * src/files.c: | |
12686 | [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined. | |
12687 | ||
12688 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
12689 | ||
12690 | * src/bison.s1 (yyparse): | |
12691 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
12692 | declare yyparse to have a void * argument. | |
12693 | ||
12694 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
12695 | ||
12696 | * bison.simple (yyparse): | |
12697 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
12698 | declare yyparse to have a void * argument. | |
12699 | ||
12700 | 1996-12-17 Richard Stallman <rms@gnu.org> | |
12701 | ||
12702 | * src/reduce.c (nbits): Add some casts. | |
12703 | ||
12704 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
12705 | ||
12706 | * src/bison.s1: Test _MSDOS as well as _MSDOS_. | |
12707 | ||
12708 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
12709 | ||
12710 | * bison.simple: Test _MSDOS as well as _MSDOS_. | |
12711 | ||
12712 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
12713 | ||
12714 | * src/bison.s1: | |
12715 | [__sun && __i386]: Include alloca.h. | |
12716 | ||
12717 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
12718 | ||
12719 | * bison.simple: | |
12720 | [__sun && __i386]: Include alloca.h. | |
12721 | ||
12722 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
12723 | ||
12724 | * src/bison.s1: Comment change. | |
12725 | ||
12726 | * src/bison.s1: Test _MSDOS_, not MSDOS. | |
12727 | ||
12728 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
12729 | ||
12730 | * bison.simple: Comment change. | |
12731 | ||
12732 | * bison.simple: Test _MSDOS_, not MSDOS. | |
12733 | ||
12734 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
12735 | ||
12736 | * 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: | |
12737 | Insert `_' macro around many string constants. | |
12738 | ||
12739 | * src/main.c: | |
12740 | Insert `_' macro around many string constants. | |
12741 | ||
12742 | (main): Call setlocale, bindtextdomain and textdomain. | |
12743 | ||
12744 | * src/system.h: [HAVE_LOCALE_H]: Include locale.h. | |
12745 | [! HAVE_LOCALE_H] (setlocale): Define as no-op. | |
12746 | [ENABLE_NLS]: Include libintl.h. | |
12747 | [ENABLE_NLS] (gettext): Define. | |
12748 | [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions. | |
12749 | (N_, PACKAGE, LOCALEDIR): New macros. | |
12750 | ||
12751 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
12752 | ||
12753 | * POTFILES.in: New file. | |
12754 | ||
12755 | * Makefile.in (allocate.o): | |
12756 | Define target explicitly. | |
12757 | ||
12758 | * Makefile.in (CFLAGS): Set to @CFLAGS@. | |
12759 | (LDFLAGS): Set to @LDFLAGS@. | |
12760 | (configure): Run autoconf only if preceding `cd' succeeds. | |
12761 | (bison.s1): Redirect output to temporary file then move the | |
12762 | temporary to the target, rather than redirecting directly to bison.s1. | |
12763 | (clean): Remove config.status and config.log. | |
12764 | (distclean): Don't remove config.status here. | |
12765 | ||
12766 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
12767 | ||
12768 | * src/bison.s1: | |
12769 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
12770 | ||
12771 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
12772 | ||
12773 | * bison.simple: | |
12774 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
12775 | ||
12776 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
12777 | ||
12778 | * src/bison.s1 (__yy_memcpy): | |
12779 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
12780 | (yyparse): Calls changed accordingly. | |
12781 | ||
12782 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
12783 | ||
12784 | * Makefile.in (dist): Don't use $(srcdir). | |
12785 | ||
12786 | * bison.simple (__yy_memcpy): | |
12787 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
12788 | (yyparse): Calls changed accordingly. | |
12789 | ||
12790 | 1996-01-27 Richard Stallman <rms@gnu.org> | |
12791 | ||
12792 | * src/output.c (output_rule_data): | |
12793 | Test YYERROR_VERBOSE in the conditional | |
12794 | around the definition of ttyname. | |
12795 | ||
12796 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
12797 | ||
12798 | * src/bison.s1: | |
12799 | Fix line numbers in #line commands. | |
12800 | ||
12801 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
12802 | ||
12803 | * bison.simple: | |
12804 | Fix line numbers in #line commands. | |
12805 | ||
12806 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
12807 | ||
12808 | * src/bison.s1 (YYPARSE_PARAM_DECL): | |
12809 | In C++, make it always null. | |
12810 | (YYPARSE_PARAM_ARG): New macro. | |
12811 | (yyparse): Use YYPARSE_PARAM_ARG. | |
12812 | ||
12813 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
12814 | ||
12815 | * bison.simple (YYPARSE_PARAM_DECL): | |
12816 | In C++, make it always null. | |
12817 | (YYPARSE_PARAM_ARG): New macro. | |
12818 | (yyparse): Use YYPARSE_PARAM_ARG. | |
12819 | ||
12820 | 1995-11-29 Richard Stallman <rms@gnu.org> | |
12821 | ||
12822 | * doc/bison.texinfo: | |
12823 | Describe literal string tokens, %raw, %no_lines, %token_table. | |
12824 | ||
12825 | 1995-11-29 Daniel Hagerty <hag@gnu.org> | |
12826 | ||
12827 | * doc/bison.texinfo: Fixed update date | |
12828 | ||
12829 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
12830 | ||
12831 | * src/version.c: Version 1.25. | |
12832 | ||
12833 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
12834 | ||
12835 | * NEWS: *** empty log message *** | |
12836 | ||
12837 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
12838 | ||
12839 | * doc/bison.1, doc/bison.rnh: | |
12840 | Add new options. | |
12841 | ||
12842 | 1995-10-15 Richard Stallman <rms@gnu.org> | |
12843 | ||
12844 | * src/vmsgetargs.c, src/getargs.c: | |
12845 | Added -n, -k, and -raw switches. | |
12846 | (noparserflag, toknumflag, rawtoknumflag): New variables. | |
12847 | ||
12848 | * src/symtab.h (SALIAS): | |
12849 | New #define for adding aliases to %token. | |
12850 | (struct bucket): Added `alias' field. | |
12851 | ||
12852 | * src/reduce.c (reduce_grammar): | |
12853 | Revise error message. | |
12854 | (print_notices): Remove final `.' from error message. | |
12855 | ||
12856 | * src/reader.c (reader_output_yylsp): | |
12857 | New function. | |
12858 | (readgram): Use `#if 0' around code that accepted %command | |
12859 | inside grammar rules: The documentation doesn't allow it, | |
12860 | and it will fail since the %command processors scan for the next %. | |
12861 | (parse_token_decl): Extended the %token | |
12862 | declaration to allow a multi-character symbol as an alias. | |
12863 | (parse_thong_decl): New function. | |
12864 | (read_declarations): Added %thong declarations. | |
12865 | (read_declarations): Handle NOOP to deal with allowing | |
12866 | % declarations as another means to specify the flags. | |
12867 | (readgram): Allow %prec prior to semantics embedded in a rule. | |
12868 | (skip_to_char, read_declarations, copy_definition) | |
12869 | (parse_token_decl, parse_start_decl, parse_type_decl) | |
12870 | (parse_assoc_decl, parse_union_decl, parse_expect_decl) | |
12871 | (get_type_name, copy_guard, copy_action, readgram) | |
12872 | (get_type, packsymbols): Revised most error messages. | |
12873 | Changed `fatal' to `warnxxx' to avoid aborting for error. | |
12874 | Revised and use multiple warnxxx functions to avoid using VARARGS1. | |
12875 | (read_declarations): Improve the error message for | |
12876 | an invalid character. Do not abort. | |
12877 | (read_declarations, copy_guard, copy_action): Use | |
12878 | printable_version to avoid unprintable characters in printed output. | |
12879 | (parse_expect_decl): Error if argument to %expect exceeds 10 digits. | |
12880 | (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type): | |
12881 | Allow the type of a non-terminal can be given | |
12882 | more than once, as long as all specifications give the same type. | |
12883 | ||
12884 | * src/output.c: | |
12885 | (output_headers, output_trailers, output, output_gram) | |
12886 | (output_rule_data): Implement noparserflag variable. | |
12887 | Implement toknumflag variable. | |
12888 | (output): Call reader_output_yylsp to output LTYPESTR. | |
12889 | ||
12890 | * src/main.c (main): | |
12891 | If reader sees an error, don't process the grammar. | |
12892 | (fatals): Updated to not use VARARGS1. | |
12893 | (printable_version, int_to_string, warn, warni, warns, warnss) | |
12894 | (warnsss): New error reporting functions. Avoid abort for error. | |
12895 | ||
12896 | * src/lex.h: | |
12897 | Added THONG and NOOP for alias processing. | |
12898 | Added SETOPT for the new code that allows setting options with %flags. | |
12899 | ||
12900 | * src/lex.c: | |
12901 | Include getopt.h. Add some extern decls. | |
12902 | (safegetc): New function to deal with EOF gracefully. | |
12903 | (literalchar); new function to deal with reading \ escapes. | |
12904 | (lex): Use literalchar. | |
12905 | (lex): Implemented "..." tokens. | |
12906 | (literalchar, lex, parse_percent_token): Made tokenbuffer | |
12907 | always contain the token. This includes growing the token | |
12908 | buffer while reading an integer. | |
12909 | (parse_percent_token): Replaced if-else statement with percent_table. | |
12910 | (parse_percent_token): Added % declarations as another | |
12911 | way to specify the flags -n, -l, and -r. Also added hooks for | |
12912 | -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires | |
12913 | major changes to files.c. | |
12914 | (lex) Retain in the incoming stream a character following | |
12915 | an incorrect '/'. | |
12916 | (skip_white_space, lex): Revised most error messages | |
12917 | and changed fatal to warn to avoid aborting. | |
12918 | (percent_table): Added %thong declarations. | |
12919 | ||
12920 | * src/gram.h: Comment changes. | |
12921 | ||
12922 | * src/files.c (openfiles, open_extra_files, done): | |
12923 | Add faction flag | |
12924 | and actfile file. Handle noparserflag. Both for -n switch. | |
12925 | ||
12926 | * src/conflicts.c (resolve_sr_conflict): | |
12927 | Remove use of alloca. | |
12928 | ||
12929 | 1995-06-01 Jim Meyering <meyering@gnu.org> | |
12930 | ||
12931 | * doc/bison.texinfo: *** empty log message *** | |
12932 | ||
12933 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
12934 | ||
12935 | * src/bison.s1: Comment change. | |
12936 | ||
12937 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
12938 | ||
12939 | * bison.simple: Comment change. | |
12940 | ||
12941 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
12942 | ||
12943 | * src/version.c: Version now 1.24. | |
12944 | ||
12945 | * src/bison.s1: Change distribution terms. | |
12946 | ||
12947 | * src/version.c: Version now 1.23. | |
12948 | ||
12949 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
12950 | ||
12951 | * doc/bison.texinfo: | |
12952 | Rewrite "Conditions for Using Bison". | |
12953 | Update version to 1.24. | |
12954 | ||
12955 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
12956 | ||
12957 | * bison.simple: Change distribution terms. | |
12958 | ||
12959 | 1995-02-23 Richard Stallman <rms@gnu.org> | |
12960 | ||
12961 | * src/files.c: Test __VMS_POSIX as well as VMS. | |
12962 | ||
12963 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
12964 | ||
12965 | * src/bison.s1 (__yy_memcpy): | |
12966 | Renamed from __yy_bcopy to avoid | |
12967 | confusion. Reverse FROM and TO arguments to be consistent with | |
12968 | those of memcpy. | |
12969 | ||
12970 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
12971 | ||
12972 | * bison.simple (__yy_memcpy): | |
12973 | Renamed from __yy_bcopy to avoid | |
12974 | confusion. Reverse FROM and TO arguments to be consistent with | |
12975 | those of memcpy. | |
12976 | ||
12977 | 1994-11-10 David J. MacKenzie <djm@gnu.org> | |
12978 | ||
12979 | * NEWS: reformat | |
12980 | ||
12981 | * NEWS: New file. | |
12982 | ||
12983 | * Makefile.in (DISTFILES): Include NEWS. | |
12984 | ||
12985 | * Makefile.in (DISTFILES): | |
12986 | Include install-sh, not install.sh. | |
12987 | ||
12988 | * configure.in: Update to Autoconf v2 macro names. | |
12989 | ||
12990 | 1994-10-05 David J. MacKenzie <djm@gnu.org> | |
12991 | ||
12992 | * Makefile.in: fix typo | |
12993 | ||
12994 | * Makefile.in (prefix, exec_prefix): | |
12995 | Let configure set them. | |
12996 | ||
12997 | 1994-09-28 David J. MacKenzie <djm@gnu.org> | |
12998 | ||
12999 | * Makefile.in: Set datadir to $(prefix)/share. | |
13000 | ||
13001 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
13002 | ||
13003 | * src/bison.s1: | |
13004 | Update copyright notice and GPL version. | |
13005 | ||
13006 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
13007 | ||
13008 | * bison.simple: | |
13009 | Update copyright notice and GPL version. | |
13010 | ||
13011 | 1994-07-12 Richard Stallman <rms@gnu.org> | |
13012 | ||
13013 | * src/reduce.c, src/reader.c: | |
13014 | entered into RCS | |
13015 | ||
13016 | 1994-05-05 David J. MacKenzie <djm@gnu.org> | |
13017 | ||
13018 | * Makefile.in: entered into RCS | |
13019 | ||
13020 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
13021 | ||
13022 | * src/bison.s1: entered into RCS | |
13023 | ||
13024 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
13025 | ||
13026 | * bison.simple: entered into RCS | |
13027 | ||
13028 | 1994-03-25 Richard Stallman <rms@gnu.org> | |
13029 | ||
13030 | * src/main.c: entered into RCS | |
13031 | ||
13032 | 1994-03-24 Richard Stallman <rms@gnu.org> | |
13033 | ||
13034 | * src/conflicts.c: entered into RCS | |
13035 | ||
13036 | 1994-01-02 Richard Stallman <rms@gnu.org> | |
13037 | ||
13038 | * Makefile.in: *** empty log message *** | |
13039 | ||
13040 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
13041 | ||
13042 | * src/bison.s1: *** empty log message *** | |
13043 | ||
13044 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
13045 | ||
13046 | * doc/bison.texinfo: entered into RCS | |
13047 | ||
13048 | * doc/bison.texinfo: *** empty log message *** | |
13049 | ||
13050 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
13051 | ||
13052 | * bison.simple: *** empty log message *** | |
13053 | ||
13054 | 1993-10-25 David J. MacKenzie <djm@gnu.org> | |
13055 | ||
13056 | * doc/bison.texinfo: *** empty log message *** | |
13057 | ||
13058 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
13059 | ||
13060 | * src/bison.s1: *** empty log message *** | |
13061 | ||
13062 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
13063 | ||
13064 | * bison.simple: *** empty log message *** | |
13065 | ||
13066 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
13067 | ||
13068 | * src/bison.s1: *** empty log message *** | |
13069 | ||
13070 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
13071 | ||
13072 | * bison.simple: *** empty log message *** | |
13073 | ||
13074 | 1993-09-14 David J. MacKenzie <djm@gnu.org> | |
13075 | ||
13076 | * doc/bison.texinfo: *** empty log message *** | |
13077 | ||
13078 | 1993-09-13 Noah Friedman <friedman@gnu.org> | |
13079 | ||
13080 | * Makefile.in: *** empty log message *** | |
13081 | ||
13082 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
13083 | ||
13084 | * src/conflicts.c: *** empty log message *** | |
13085 | ||
13086 | * src/system.h: entered into RCS | |
13087 | ||
13088 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
13089 | ||
13090 | * doc/bison.1: entered into RCS | |
13091 | ||
13092 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
13093 | ||
13094 | * src/version.c: entered into RCS | |
13095 | ||
13096 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
13097 | ||
13098 | * Makefile.in: *** empty log message *** | |
13099 | ||
13100 | 1993-07-30 David J. MacKenzie <djm@gnu.org> | |
13101 | ||
13102 | * Makefile.in: *** empty log message *** | |
13103 | ||
13104 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
13105 | ||
13106 | * src/bison.s1: *** empty log message *** | |
13107 | ||
13108 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
13109 | ||
13110 | * bison.simple: *** empty log message *** | |
13111 | ||
13112 | 1993-07-08 David J. MacKenzie <djm@gnu.org> | |
13113 | ||
13114 | * Makefile.in: *** empty log message *** | |
13115 | ||
13116 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
13117 | ||
13118 | * src/bison.s1: *** empty log message *** | |
13119 | ||
13120 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
13121 | ||
13122 | * bison.simple: *** empty log message *** | |
13123 | ||
13124 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
13125 | ||
13126 | * src/getargs.c: entered into RCS | |
13127 | ||
13128 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
13129 | ||
13130 | * doc/bison.texinfo: *** empty log message *** | |
13131 | ||
13132 | * doc/bison.1: New file. | |
13133 | ||
13134 | 1993-06-25 Richard Stallman <rms@gnu.org> | |
13135 | ||
13136 | * src/getargs.c: New file. | |
13137 | ||
13138 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
13139 | ||
13140 | * src/bison.s1: *** empty log message *** | |
13141 | ||
13142 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
13143 | ||
13144 | * bison.simple: *** empty log message *** | |
13145 | ||
13146 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
13147 | ||
13148 | * src/bison.s1: New file. | |
13149 | ||
13150 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
13151 | ||
13152 | * doc/bison.texinfo: *** empty log message *** | |
13153 | ||
13154 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
13155 | ||
13156 | * bison.simple: New file. | |
13157 | ||
13158 | 1993-05-19 Richard Stallman <rms@gnu.org> | |
13159 | ||
13160 | * doc/bison.texinfo: New file. | |
13161 | ||
13162 | 1993-05-07 Noah Friedman <friedman@gnu.org> | |
13163 | ||
13164 | * Makefile.in: *** empty log message *** | |
13165 | ||
13166 | 1993-04-28 Noah Friedman <friedman@gnu.org> | |
13167 | ||
13168 | * src/reader.c: *** empty log message *** | |
13169 | ||
13170 | 1993-04-23 Noah Friedman <friedman@gnu.org> | |
13171 | ||
13172 | * src/alloc.h: entered into RCS | |
13173 | ||
13174 | 1993-04-20 David J. MacKenzie <djm@gnu.org> | |
13175 | ||
13176 | * src/version.c: *** empty log message *** | |
13177 | ||
13178 | * src/files.c, src/allocate.c: | |
13179 | entered into RCS | |
13180 | ||
13181 | * src/reader.c: *** empty log message *** | |
13182 | ||
13183 | * src/lex.c: entered into RCS | |
13184 | ||
13185 | * src/conflicts.c: New file. | |
13186 | ||
13187 | * src/symtab.c: entered into RCS | |
13188 | ||
13189 | * src/alloc.h: New file. | |
13190 | ||
13191 | * src/LR0.c: entered into RCS | |
13192 | ||
13193 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
13194 | ||
13195 | * src/reader.c: New file. | |
13196 | ||
13197 | * src/version.c: *** empty log message *** | |
13198 | ||
13199 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
13200 | ||
13201 | * Makefile.in: *** empty log message *** | |
13202 | ||
13203 | 1993-04-17 Noah Friedman <friedman@gnu.org> | |
13204 | ||
13205 | * Makefile.in: *** empty log message *** | |
13206 | ||
13207 | 1993-04-15 Richard Stallman <rms@gnu.org> | |
13208 | ||
13209 | * src/main.c, src/files.c: | |
13210 | New file. | |
13211 | ||
13212 | 1993-04-15 Noah Friedman <friedman@gnu.org> | |
13213 | ||
13214 | * configure.in: entered into RCS | |
13215 | ||
13216 | * configure.in: *** empty log message *** | |
13217 | ||
13218 | * configure.in: New file. | |
13219 | ||
13220 | 1993-04-14 Richard Stallman <rms@gnu.org> | |
13221 | ||
13222 | * Makefile.in: New file. | |
13223 | ||
13224 | 1993-04-13 Richard Stallman <rms@gnu.org> | |
13225 | ||
13226 | * src/version.c: New file. | |
13227 | ||
13228 | 1993-03-25 Richard Stallman <rms@gnu.org> | |
13229 | ||
13230 | * src/output.c: entered into RCS | |
13231 | ||
13232 | 1992-09-25 Richard Stallman <rms@gnu.org> | |
13233 | ||
13234 | * configure.bat: entered into RCS | |
13235 | ||
13236 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
13237 | ||
13238 | * src/vmsgetargs.c: entered into RCS | |
13239 | ||
13240 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
13241 | ||
13242 | * doc/bison.rnh: entered into RCS | |
13243 | ||
13244 | 1992-04-20 David J. MacKenzie <djm@gnu.org> | |
13245 | ||
13246 | * README: entered into RCS | |
13247 | ||
13248 | 1992-01-22 Richard Stallman <rms@gnu.org> | |
13249 | ||
13250 | * src/machine.h: entered into RCS | |
13251 | ||
13252 | 1991-12-21 Richard Stallman <rms@gnu.org> | |
13253 | ||
13254 | * src/lalr.c, src/closure.c: | |
13255 | entered into RCS | |
13256 | ||
13257 | 1991-12-20 Richard Stallman <rms@gnu.org> | |
13258 | ||
13259 | * src/state.h: entered into RCS | |
13260 | ||
13261 | 1991-12-18 Richard Stallman <rms@gnu.org> | |
13262 | ||
13263 | * src/print.c, src/nullable.c, src/derives.c: | |
13264 | entered into RCS | |
13265 | ||
13266 | 1991-11-03 David J. MacKenzie <djm@gnu.org> | |
13267 | ||
13268 | * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h: | |
13269 | entered into RCS | |
13270 | ||
13271 | 1988-09-09 Richard Stallman <rms@gnu.org> | |
13272 | ||
13273 | * src/bison.hairy: entered into RCS | |
13274 | ||
13275 | 1987-12-16 Richard Stallman <rms@gnu.org> | |
13276 | ||
13277 | * REFERENCES: entered into RCS | |
dc546b0f | 13278 | |
f294a2c2 AD |
13279 | ----- |
13280 | ||
33167b8b | 13281 | Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996, 1997, |
05ac60f3 | 13282 | 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
f294a2c2 | 13283 | |
33167b8b | 13284 | This file is part of Bison, the GNU Compiler Compiler. |
f294a2c2 | 13285 | |
33167b8b | 13286 | Bison is free software; you can redistribute it and/or modify |
f294a2c2 AD |
13287 | it under the terms of the GNU General Public License as published by |
13288 | the Free Software Foundation; either version 2, or (at your option) | |
13289 | any later version. | |
13290 | ||
33167b8b | 13291 | Bison is distributed in the hope that it will be useful, |
f294a2c2 AD |
13292 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
13293 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13294 | GNU General Public License for more details. | |
13295 | ||
13296 | You should have received a copy of the GNU General Public License | |
33167b8b | 13297 | along with Bison; see the file COPYING. If not, write to |
f294a2c2 AD |
13298 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
13299 | Boston, MA 02111-1307, USA. |