]>
Commit | Line | Data |
---|---|---|
1 | 2003-08-26 Akim Demaille <akim@epita.fr> | |
2 | ||
3 | * data/lalr1.cc (Parser::report_syntax_error_): New, extracted from | |
4 | (Parser::parse): here. | |
5 | Adjust: nerrs and errstatus is now replaced by... | |
6 | (Parser::nerrs_, Parser::errstatus_): New. | |
7 | ||
8 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
9 | ||
10 | * config/announce-gen, Makefile.cfg: New. | |
11 | * Makefile.am: Adjust. | |
12 | * GNUmakefile, Makefile.maint: Update from CVS Autoconf, but | |
13 | keeping local WGET and WGETFLAGS modifications from Paul Eggert. | |
14 | ||
15 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
16 | ||
17 | When reducing initial empty rules, Bison parser read an initial | |
18 | location that is not defined. This results in garbage, and that | |
19 | affects Bison's own parser. Therefore we need (i) to extend Bison | |
20 | to support a means to initialize this location, and (ii) to use | |
21 | this CVS Bison to fix CVS Bison's parser. | |
22 | ||
23 | * src/reader.h, reader.c (epilogue_augment): Remove, replace | |
24 | with... | |
25 | * src/muscle_tab.h, src/muscle_tab.c (muscle_code_grow): this. | |
26 | * src/parse-gram.y: Adjust. | |
27 | (%initial-action): New. | |
28 | (%error-verbose): Since we require CVS Bison, there is no reason | |
29 | not to use it. | |
30 | * src/scan-gram.l: Adjust. | |
31 | * src/Makefile.am (YACC): New, to make sure we use our own parser. | |
32 | * data/yacc.c (yyparse): Use b4_initial_action. | |
33 | ||
34 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
35 | ||
36 | * doc/bison.texinfo: Don't promote stdout for error messages. | |
37 | ||
38 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
39 | ||
40 | * data/lalr1.cc (Parser::reduce_print_): Remove unused yyi. | |
41 | From Alexandre Duret-Lutz. | |
42 | ||
43 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
44 | ||
45 | * data/lalr1.cc (Parser::stack_print_, YY_STACK_PRINT): New. | |
46 | Use them. | |
47 | ||
48 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
49 | ||
50 | * data/lalr1.cc (Parser::reduce_print_): New. | |
51 | Use it. | |
52 | ||
53 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
54 | ||
55 | Have lalr1.cc catch with Paul Eggert's patch to fix the infinite | |
56 | error recovery loops. This patch is based on | |
57 | <http://mail.gnu.org/archive/html/bison-patches/2003-06/msg00000.html>. | |
58 | Also, augment the similarity between lalr1.cc and yacc.c. | |
59 | Note: the locations of error recovery rules are not correct yet. | |
60 | ||
61 | * data/lalr1.cc: Comment changes to augment the similarity between | |
62 | lalr1.cc and yacc.c. | |
63 | (YYERROR): Goto to yyerrorlab, not yyerrlab1. | |
64 | (yyerrlab1): Remove, but where it used to be (now the bottom part of | |
65 | yyerrlab), when hitting EOF, pop the whole stack here instead of | |
66 | merely falling thru the default error handling mechanism. | |
67 | (yyerrorlab): New label, with the old contents of YYERROR, | |
68 | plus the following change: pop the stack of rhs corresponding | |
69 | to the production that invoked YYERROR. That is how Yacc | |
70 | behaves (required by POSIX). | |
71 | * tests/calc.at (AT_CHECK_CALC_LALR1_CC): No longer expected to | |
72 | fail. | |
73 | ||
74 | 2003-08-25 Akim Demaille <akim@epita.fr> | |
75 | ||
76 | Tune local.at so that people can "autom4te -l autotest calc.at -o | |
77 | calc" for instance, to extract a sub test suite. | |
78 | ||
79 | * tests/testsuite.at: Move the initialization, Autotest version | |
80 | requirement, and AT_TESTED invocation into... | |
81 | * tests/local.at: here. | |
82 | * tests/testsuite.at: Include it for compatibility with Autoconf | |
83 | 2.57. | |
84 | * tests/Makefile.am ($(TESTSUITE)): Report that the warning should | |
85 | be ignore. | |
86 | ||
87 | 2003-08-04 Paul Eggert <eggert@twinsun.com> | |
88 | ||
89 | Rework code slightly to avoid gcc -Wtraditional warnings. | |
90 | * data/glr.c (yyuserMerge): Return void, not YYSTYPE. | |
91 | The returned value is now stored in *YY0. All callers changed. | |
92 | * src/output.c (merge_output): Adjust to the above change. | |
93 | ||
94 | 2003-07-26 Paul Eggert <eggert@twinsun.com> | |
95 | ||
96 | * data/glr.c (YYASSERT): New macro. | |
97 | (yyfillin, yydoAction, yyglrReduce, yysplitStack, | |
98 | yyresolveStates, yyprocessOneStack): | |
99 | Use `YYASSERT (FOO);' rather than `if (! (FOO)) abort ();'. | |
100 | Derived from a suggestion by Frank Heckenbach. | |
101 | ||
102 | 2003-07-25 Paul Eggert <eggert@twinsun.com> | |
103 | ||
104 | * data/glr.c (yyglrReduce): Don't use C89 string concatenation, | |
105 | for portability to K&R C (after ansi2knr, presumably). See | |
106 | <http://mail.gnu.org/archive/html/bison-patches/2003-06/msg00041.html> | |
107 | by Frank Heckenbach, though I have omitted the structure-initialization | |
108 | part of his glr-knr.diff patch since I recall that the Portable | |
109 | C Compiler didn't require that change. | |
110 | ||
111 | Let the user specify how to allocate and free memory. | |
112 | Derived from a suggestion by Frank Heckenbach in | |
113 | <http://mail.gnu.org/archive/html/bison-patches/2003-06/msg00041.html>. | |
114 | * data/glr.c (YYFREE, YYMALLOC, YYREALLOC): New macros. | |
115 | All uses of free, malloc, realloc changed to use these macros, | |
116 | and unnecessary casts removed. | |
117 | * data/yacc.c (YYFREE, YYMALLOC): Likewise. | |
118 | ||
119 | 2003-07-06 Matthias Mann <MatthiasMann@gmx.de> | |
120 | ||
121 | * data/lalr1.cc (operator<<(std::ostream&, const Position&)): | |
122 | use s.empty() rather than s == "" to test for empty string; see | |
123 | <http://mail.gnu.org/archive/html/bison-patches/2003-07/msg00003.html> | |
124 | (trivial change) | |
125 | ||
126 | 2003-06-25 Akim Demaille <akim@epita.fr> | |
127 | ||
128 | * config/depcomp, config/install-sh: Update from masters. | |
129 | ||
130 | 2003-06-20 Paul Eggert <eggert@twinsun.com> | |
131 | ||
132 | * data/glr.c (YYLLOC_DEFAULT): Parenthesize arguments as needed, | |
133 | and return properly parenthesized result. | |
134 | * data/lalar1.cc (YYLLOC_DEFAULT): Likewise. | |
135 | * data/yacc.c (YYLLOC_DEFAULT): Likewise. | |
136 | Remove unnecessary parentheses from uses. | |
137 | * doc/bison.texinfo (Location Default Action): Describe the | |
138 | conventions for parentheses. | |
139 | ||
140 | 2003-06-19 Paul Eggert <eggert@twinsun.com> | |
141 | ||
142 | * data/glr.c (yyremoveDeletes, yy_reduce_print, yyglrReduce, | |
143 | yyreportTree): Do not assume that size_t is the same width as int, | |
144 | when printing sizes. Print sizes using an unsigned format. | |
145 | Problem reported by Frank Heckenbach in | |
146 | <http://mail.gnu.org/archive/html/bison-patches/2003-06/msg00035.html>. | |
147 | ||
148 | Port to Forte Developer 7 C compiler. | |
149 | * data/glr.c (struct YYLTYPE): If locations are not being used, | |
150 | declare a single dummy member, as empty structs do not conform | |
151 | to the C standard. | |
152 | (YYERROR, YYBACKUP): Do not use "do { ...; return foo; } while (0)"; | |
153 | the Forte Developer 7 C compiler complains that end-of-loop | |
154 | code is not reached. | |
155 | ||
156 | 2003-06-17 Paul Eggert <eggert@twinsun.com> | |
157 | ||
158 | * lib/libiberty.h (PARAMS): Spell argument as Args, not as X, to | |
159 | avoid warnings from picky compilers about redefinition of PARAMS. | |
160 | ||
161 | 2003-06-17 Paul Eggert <eggert@twinsun.com> | |
162 | ||
163 | Version 1.875b. | |
164 | ||
165 | * NEWS: Document 1.875b. | |
166 | ||
167 | * lib/bbitset.h: Do not include config.h; that's the includer's job. | |
168 | Do not include <sys/types.h>; shouldn't be needed on a C89 host. | |
169 | * lib/bitset.h (bitset_compatible_p): Indent as per GNU standard. | |
170 | Don't use 'index' in comments, as it's a builtin fn on some hosts. | |
171 | * lib/bitset_stats.c: Include gettext.h unconditionally, as | |
172 | per recent gettext manual's suggestion. | |
173 | * lib/ebitset.c (ebitset_resize, ebitset_unused_clear): | |
174 | Use prototypes, not old-style definitions. | |
175 | * lib/lbitset.c (lbitset_unused_clear): Likewise. | |
176 | * lib/vbitset.c (vbitset_resize, vbitset_ones, vbitset_zero, | |
177 | vbitset_empty_p, vbitset_copy1, vbitset_not, vbitset_equal_p, | |
178 | vbitset_subset_p, vbitset_disjoint_p, vbitset_and, vbitset_and_cmp, | |
179 | vbitset_andn, vbitset_andn_cmp, vbitset_or, vbitset_or_cmp, | |
180 | vbitset_xor, vbitset_xor_cmp, vbitset_and_or, vbitset_and_or_cmp, | |
181 | vbitset_andn_or, vbitset_andn_or_cmp, vbitset_or_and, | |
182 | vbitset_or_and_cmp, vbitset_copy): Likewise. | |
183 | ||
184 | * lib/libiberty.h: Do not include config.h; that's the includer's job. | |
185 | Do not include <stdlib.h>. | |
186 | (PARAMS): Define unconditionally for C89. | |
187 | (ATTRIBUTE_NORETURN): Remove. | |
188 | (ATTRIBUTE_UNUSED): Define unconditionally. | |
189 | ||
190 | Upgrade to 2003-06-08 libbitset, submitted by Michael Hayes in: | |
191 | <http://mail.gnu.org/archive/html/bison-patches/2003-06/msg00005.html> | |
192 | * lib/Makefile.am (bitsets_sources): Add vbitset.c, vbitset.h. | |
193 | * lib/vbitset.c, lib/vbitset.h: New files. | |
194 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
195 | lib/bitset_stats.c, lib/ebitset.c, lib/lbitset.c: Import | |
196 | from libbitset. | |
197 | ||
198 | * doc/bison.texinfo (How Can I Reset the Parser): Renamed from | |
199 | `How Can I Reset @code{yyparse}', since texinfo does not allow | |
200 | arbitrary @ in node names. | |
201 | ||
202 | * m4/Makefile.am (EXTRA_DIST): Add the following files, which | |
203 | shouldn't be needed according to the gettext 0.12.1 documentation | |
204 | but which seem to be needed anyway: codeset.m4 glibc21.m4 | |
205 | intdiv0.m4 inttypes-pri.m4 inttypes.m4 inttypes_h.m4 isc-posix.m4 | |
206 | lcmessage.m4 nls.m4 po.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4. | |
207 | * po/Makefile.in.in: Upgrade to gettext 0.12.1 version. | |
208 | ||
209 | * lib/.cvsignore: Add stdbool.h. | |
210 | * m4/.cvsignore: Add nls.m4, po.m4. | |
211 | ||
212 | Upgrade to CVS gnulib. | |
213 | * stdbool_.h: File renamed from stdbool.h.in. | |
214 | * configure.ac (AM_STDBOOL_H): Invoke this instead of | |
215 | AC_HEADER_STDBOOL. | |
216 | (AM_GNU_GETTEXT): Put brackets around args, as latest manual suggests. | |
217 | (AM_GNU_GETTEXT_VERSION): Update to 0.12.1. | |
218 | * lib/Makefile.am (EXTRA_DIST): Add stdbool_.h. | |
219 | (MOSTLYCLEANFILES): New var. | |
220 | ($(libbison_a_OBJECTS)): Depend on $(STDBOOL_H). | |
221 | (stdbool.h): New rule. | |
222 | * lib/dirname.c, lib/dirname.h, lib/hash.c, lib/hash.h, | |
223 | lib/malloc.c, lib/obstack.h, lib/quote.c, lib/realloc.c, | |
224 | lib/strcasecmp.c, lib/xalloc.h, m4/alloca.m4, m4/onceonly.m4, | |
225 | m4/quote.m4: Upgrade to today's gnulib. | |
226 | ||
227 | * tests/calc.at (AT_CHECK_CALC): New option EXPECTED-TO-FAIL. | |
228 | (AT_CHECK_CALC_LALR1_CC): Use it, since the C++ LALR parser fails | |
229 | the tests right now. | |
230 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Ensure yylex and | |
231 | yyerror are declared before use; C99 requires this. | |
232 | ||
233 | 2003-06-09 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
234 | ||
235 | * data/glr.c (YYERROR): Update definition to reset yyerrState to 0 | |
236 | first. | |
237 | (yyrecoverSyntaxError): Correct the logic for setting and testing | |
238 | yyerrState. | |
239 | Correct comment on handling EOF. | |
240 | Allow states with only a default reduction, rather than failing | |
241 | (I can't quite reconstruct why these were not allowed before). | |
242 | ||
243 | Fixes to avoid problem that $-N rules in GLR parsers can cause | |
244 | buffer overruns, corrupting state. | |
245 | ||
246 | * src/output.c (prepare_rules): Output max_left_semantic_context | |
247 | definition. | |
248 | * src/reader.h (max_left_semantic_context): New variable declaration. | |
249 | * src/scan-gram.l (max_left_semantic_context): Define. | |
250 | (handle_action_dollar): Update max_left_semantic_context. | |
251 | * data/glr.c (YYMAXLEFT): New definition. | |
252 | (yydoAction): Increase size of yyrhsVals by YYMAXLEFT. | |
253 | (yyresolveAction): Ditto. | |
254 | ||
255 | Fixes to problems with location handling in GLR parsers reported by | |
256 | Frank Heckenbach (2003/06/05). | |
257 | ||
258 | * data/glr.c (YYLTYPE): Make trivial if locations not used. | |
259 | (YYRHSLOC): Add parentheses, and define only if locations used. | |
260 | (YYLLOC_DEFAULT): Add parentheses, and give trivial definition if | |
261 | locations not used. | |
262 | (yyuserAction): Use YYLLOC_DEFAULT to set *yylocp. | |
263 | (yydoAction): Remove redundant initialization of *yyvalp and *yylocp. | |
264 | ||
265 | * tests/cxx-type.at: Exercise location information; update tests | |
266 | to differentiate output with and without locations. | |
267 | Remove forward declarations of yylex and yyerror---caused errors | |
268 | because default YYLTYPE not yet defined. | |
269 | Change semantic actions to compute strings, rather than printing | |
270 | them directly (to test proper passing of semantics values). Change | |
271 | output to prefix notation and update test data and expected results. | |
272 | (yylex): Track locations. | |
273 | (stmtMerge): Return value rather than printing, and include arguments | |
274 | in value. | |
275 | ||
276 | 2003-06-03 Paul Eggert <eggert@twinsun.com> | |
277 | ||
278 | Avoid warnings generated by GCC 2.95.4 when Bison is | |
279 | configured with --enable-gcc-warnings. | |
280 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse, | |
281 | yy::]b4_parser_class_name[::translate_, | |
282 | yy::Stack::operator[] (unsigned), | |
283 | yy::Stack::operator[] (unsigned) const, | |
284 | yy::Slice::operator[] (unsigned), | |
285 | yy::Slice::operator[] (unsigned) const): | |
286 | Rename local vars to avoid warnings. | |
287 | * tests/glr-regression.at (Improper handling of embedded actions | |
288 | and $-N in GLR parsers): Remove unused local variable from yylex. | |
289 | * tests/regression.at (_AT_DATA_DANCER_Y): Declare yylex to take | |
290 | (void) as arg when not pure, since we now assume C89 when building | |
291 | Bison. Pacify GCC by using parameter. | |
292 | ||
293 | 2003-06-02 Paul Eggert <eggert@twinsun.com> | |
294 | ||
295 | * data/lalr1.cc (yy::Position::lines, yy::Position::columns, | |
296 | yy::Location::lines, yy::Location::columns): Rename arguments | |
297 | to avoid shadowing; this removes a warning generated by GCC 3.3. | |
298 | ||
299 | 2003-06-01 Paul Eggert <eggert@twinsun.com> | |
300 | ||
301 | Don't pass C-only warning optins (e.g., -Wmissing-declarations) | |
302 | to g++, as GCC 3.3 complains if you do it. | |
303 | * configure.ac (WARNING_CXXFLAGS): New subst. Set it to | |
304 | everything that WARNING_CFLAGS has, except omit warnings | |
305 | not suitable for C++. | |
306 | (AC_PROG_CXX): Use this instead of AC_CHECK_PROGS([CXX], [g++]). | |
307 | * tests/atlocal.in (CXXFLAGS): New var. | |
308 | * tests/local.at (AT_COMPILE_CXX): Use it instead of CFLAGS. | |
309 | ||
310 | Fix a GLR parser bug I reported in February; see | |
311 | <http://mail.gnu.org/archive/html/bison-patches/2003-02/msg00008.html>. | |
312 | The problem was that GLR parsers did not conform to the C standard, | |
313 | because actions like { $1 = $2 + $3; } expanded to expressions | |
314 | that invoked YYFILL in separate subexpressions, and YYFILL assigned | |
315 | to a local variable. The C standard says that expressions | |
316 | like (var = f ()) + (var = f ()) have undefined behavior. | |
317 | Another problem was that GCC sometimes issues warnings that | |
318 | yyfill and its parameters are unused. | |
319 | ||
320 | * data/glr.c (yyfillin): Renamed from the old yyfill. Mark | |
321 | as possibly unused. | |
322 | (yyfill): New function. | |
323 | (YYFILL): Use it. | |
324 | (yyuserAction): Change type of yynormal to bool, so that it matches | |
325 | the new yyfill signature. Mark it as possibly unused. | |
326 | ||
327 | ||
328 | Follow up on a bug I reported in February, where a Bison-generated | |
329 | parser can loop. Provide a test case and a fix for yacc.c. I | |
330 | don't have a fix for lalr1.cc or for glr.c, unfortunately. | |
331 | The original bug report is in: | |
332 | <http://mail.gnu.org/archive/html/bison-patches/2003-02/msg00044.html> | |
333 | ||
334 | * data/yacc.c (YYERROR): Now just 'goto yyerrorlab', since the | |
335 | macro's size was becoming unwieldy. | |
336 | (yyerrlab): Do not discard an empty lookahead symbol, as this | |
337 | might destroy garbage. | |
338 | (yyerrorlab): New label, with the old contents of YYERROR, | |
339 | plus the following change: pop the stack of rhs corresponding | |
340 | to the production that invoked YYERROR. That is how Yacc | |
341 | behaves, and POSIX requires this behavior. | |
342 | (yyerrlab1): Use YYPOPSTACK instead of its definiens. | |
343 | * tests/calc.at (_AT_DATA_CALC_Y): Include unistd.h if available. | |
344 | Define 'alarm' to do nothing if unistd.h is not available. | |
345 | Add a new rule "exp: '-' error;" to test the above change to | |
346 | data/yacc.c. Use 'alarm' to abort any test taking longer than | |
347 | 10 seconds, as it's probably looping. | |
348 | (AT_CHECK_CALC): Test recovery from error in new grammar rule. | |
349 | Also, the new yacc.c generates two fewer diagnostics for an | |
350 | existing test. | |
351 | ||
352 | 2003-05-24 Paul Eggert <eggert@twinsun.com> | |
353 | ||
354 | * data/glr.c (YYSTACKEXPANDABLE): Do not evaluate | |
355 | YYSTYPE_IS_TRIVIAL or YYSTYPE_IS_TRIVIAL unless they are defined. | |
356 | This fixes a problem reported by John Bowman when the Compaq/HP | |
357 | Alpha cxx compiler happy (e.g. using cxx -D__USE_STD_IOSTREAM | |
358 | -ansi -Wall -gall). | |
359 | * data/yacc.c (union yyalloc): Likewise. | |
360 | (YYCOPY): Do not evaluate __GNUC__ unless it is defined. | |
361 | ||
362 | Switch from 'int' to 'bool' where that makes sense. | |
363 | ||
364 | * lib/abitset.c (abitset_test, abitset_empty_p, abitset_equal_p, | |
365 | abitset_subset_p, abitset_disjoint_p, abitset_and_cmp, | |
366 | abitset_andn_cmp, abitset_or_cmp, abitset_xor_cmp, abitset_and_or, | |
367 | abitset_and_or_cmp, abitset_andn_or_cmp, abitset_or_and_cmp): | |
368 | Return or accept bool, not int. All callers changed. | |
369 | * lib/bbitset.h: (bitset_toggle_, bitset_copy_, bitset_and_or_cmp_, | |
370 | bitset_andn_or_cmp_, bitset_or_and_cmp_): Likewise. | |
371 | * lib/bitset.c (bitset_only_set_p, bitset_print, bitset_toggle_, | |
372 | bitset_copy_, bitset_op4_cmp, bitset_and_or_cmp_, bitset_andn_or_cmp_, | |
373 | bitset_or_and_cmp_): Likewise. | |
374 | * lib/bitset.h (bitset_test, bitset_only_set_p): Likewise. | |
375 | * lib/bitset_stats.c (bitset_stats_print, bitset_stats_toggle, | |
376 | bitset_stats_test, bitset_stats_empty_p, bitset_stats_disjoint_p, | |
377 | bitset_stats_equal_p, bitset_stats_subset_p, bitset_stats_and_cmp, | |
378 | bitset_stats_andn_cmp, bitset_stats_or_cmp, bitset_stats_xor_cmp, | |
379 | bitset_stats_and_or_cmp, bitset_stats_andn_or_cmp, | |
380 | bitset_stats_or_and_cmp): Likewise. | |
381 | * lib/ebitset.c (ebitset_elt_zero_p, ebitset_equal_p, ebitset_copy_cmp, | |
382 | ebitset_test, ebitset_empty_p, ebitset_subset_p, ebitset_disjoint_p, | |
383 | ebitset_op3_cmp, ebitset_and_cmp, ebitset_andn_cmp, ebitset_or_cmp, | |
384 | ebitset_xor_cmp): Likewise. | |
385 | * lib/lbitset.c (lbitset_elt_zero_p, lbitset_equal_p, lbitset_copy_cmp, | |
386 | lbitset_test, lbitset_empty_p, lbitset_subset_p, lbitset_disjoint_p, | |
387 | lbitset_op3_cmp, lbitset_and_cmp, lbitset_andn_cmp, lbitset_or_cmp, | |
388 | lbitset_xor_cmp): Likewise. | |
389 | * lib/bbitset.h: Include <stdbool.h>. | |
390 | (struct bitset_vtable): The following members now return bool, not | |
391 | int: toggle, test, empty_p, disjoint_p, equal_p, subset_p, | |
392 | and_cmp, andn_cmp, or_cmp, xor_cmp, and_or_cmp, andn_or_cmp, | |
393 | or_and_cmp). | |
394 | * src/conflicts.c (count_rr_conflicts): Likewise. | |
395 | * lib/bitset_stats.h (bitset_stats_enabled): Now bool, not int. | |
396 | All uses changed. | |
397 | * lib/ebitset.c (ebitset_obstack_init): Likewise. | |
398 | * lib/lbitset.c (lbitset_obstack_init): Likewise. | |
399 | * src/getargs.c (debug_flag, defines_flag, locations_flag, | |
400 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
401 | graph_flag): Likewise. | |
402 | * src/getargs.h (debug_flag, defines_flag, locations_flag, | |
403 | no_lines_flag, no_parser_flag, token_table_flag, yacc_flag, | |
404 | graph_flag): Likewise. | |
405 | * src/output.c (error_verbose): Likewise. | |
406 | * src/output.h (error_verbose): Likewise. | |
407 | * src/reader.c (start_flag, typed): Likewise. | |
408 | * src/reader.h (typed): Likewise. | |
409 | * src/getargs.c (LOCATIONS_OPTION): New constant. | |
410 | (long_options, getargs): Use it. | |
411 | * src/lalr.c (build_relations): Use bool, not int. | |
412 | * src/nullable.c (nullable_compute): Likewise. | |
413 | * src/print.c (print_reductions): Likewise. | |
414 | * src/tables.c (action_row, pack_vector): Likewise. | |
415 | * src/muscle_tab.h (MUSCLE_INSERT_BOOL): New macro. | |
416 | * src/output.c (prepare): Use it. | |
417 | * src/output.c (token_definitions_output, | |
418 | symbol_destructors_output, symbol_destructors_output): Use string, | |
419 | not boolean integer, to keep track of whether to output separator. | |
420 | * src/print_graph.c (print_core): Likewise. | |
421 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
422 | ||
423 | * config/install-sh: Sync from automake 1.7.5. | |
424 | ||
425 | 2003-05-14 Paul Eggert <eggert@twinsun.com> | |
426 | ||
427 | * src/parse-gram.y (rules_or_grammar_declaration): Require a | |
428 | semicolon after a grammar declaration, in the interest of possible | |
429 | future changes to the Bison input language. | |
430 | Do not allow a stray semicolon at the start of the grammar. | |
431 | (rhses.1): Allow one or more semicolons after any rule, including | |
432 | just before "|" as required by POSIX. | |
433 | * tests/input.at (Torturing the Scanner): Add tests for ";|" in a | |
434 | grammar. | |
435 | ||
436 | 2003-05-14 Alexandre Duret-Lutz <adl@gnu.org> | |
437 | ||
438 | %parse-param support for lalr1.cc. | |
439 | ||
440 | * data/lalr1.cc (b4_parse_param_decl, b4_parse_param_cons, | |
441 | b4_cc_constructor_calls, b4_cc_constructor_call, | |
442 | b4_parse_param_vars, b4_cc_var_decls, b4_cc_var_decl): New m4 | |
443 | definitions. | |
444 | (yy::b4_parser_class_name::b4_parser_class_name): Take extra | |
445 | parse-param arguments. | |
446 | (yy::b4_parser_class_name): Declare instance variables to | |
447 | hold parse-param arguments. | |
448 | * tests/calc.at: s/value/semantic_value/ because value clashes | |
449 | with a member of yy::b4_parser_class_name. Adjust C++ code | |
450 | to handle %parse-param. Enable %parse-param test in C++. | |
451 | ||
452 | 2003-05-12 Paul Eggert <eggert@twinsun.com> | |
453 | ||
454 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): Reword the | |
455 | English a bit. Fix fclose typo. Change "const char" to "char | |
456 | const", and use ANSI C rather than K&R for "main". Suggest | |
457 | YY_FLUSH_BUFFER over yyrestart (as that is what Flex recommends) | |
458 | and suggest yy_switch_to_buffer. | |
459 | ||
460 | 2003-05-05 Paul Eggert <eggert@twinsun.com> | |
461 | ||
462 | * lib/bitset.h (__INT_TO_PTR): Define to a value that presumes | |
463 | C89. This avoids a diagnostic on compilers that define __STDC__ | |
464 | to 0, fixing a problem with Tru64 cc reported by Martin Mokrejs in | |
465 | <http://mail.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. | |
466 | ||
467 | 2003-05-03 Paul Eggert <eggert@twinsun.com> | |
468 | ||
469 | * lib/bitset.h (BITSET_FOR_EACH, BITSET_FOR_EACH_REVERSE): | |
470 | Do not overrun array bounds. | |
471 | This should fix a bug reported today by Olatunji Oluwabukunmi in | |
472 | <http://mail.gnu.org/archive/html/bug-bison/2003-05/msg00004.html>. | |
473 | ||
474 | 2003-04-29 Akim Demaille <akim@epita.fr> | |
475 | ||
476 | * src/gram.h, src/gram.c (pure_parser, glr_parser): Move to... | |
477 | * src/getargs.c, src/getargs.h: here, as bool, not int. | |
478 | (nondeterministic_parser): New. | |
479 | * src/parse-gram.y, src/scan-gram.l: Support | |
480 | %nondeterministic-parser. | |
481 | * src/output.c (prepare): Use nondeterministic_parser instead | |
482 | of glr_parser where appropriate. | |
483 | * src/tables.c (conflict_row, action_row, save_row) | |
484 | (token_actions, token_actions, pack_vector): Ditto. | |
485 | ||
486 | 2003-04-29 Akim Demaille <akim@epita.fr> | |
487 | ||
488 | * doc/bison.texinfo (C++ Parsers, Implementing Loops): New. | |
489 | ||
490 | 2003-04-29 Akim Demaille <akim@epita.fr> | |
491 | ||
492 | * tests/calc.at: Also test yacc.c and glr.c (but not lalr1.cc yet) | |
493 | with %pure-parser and %locations to exercise the patch from Yakov | |
494 | Markovitch below. | |
495 | ||
496 | 2003-04-28 Tim Van Holder <tim.van.holder@pandora.be> | |
497 | ||
498 | * data/yacc.c: (b4_lex_param): Corrected for the case where | |
499 | %lex-param is provided and %pure-parser isn't. | |
500 | ||
501 | 2003-04-27 Paul Eggert <eggert@twinsun.com> | |
502 | ||
503 | Avoid gcc -Wundef warnings reported by Gerald Pfeifer in | |
504 | <http://mail.gnu.org/archive/html/bug-bison/2003-04/msg00044.html>. | |
505 | * data/yacc.c (YYSTACK_ALLOC): Don't evaluate YYSTACK_USE_ALLOCA | |
506 | if it is not defined. | |
507 | (YYMAXDEPTH): Don't evaluate YYMAXDEPTH if it is not defined. | |
508 | ||
509 | 2003-04-26 Paul Eggert <eggert@twinsun.com> | |
510 | ||
511 | * data/lalr1.cc (yy::Parser::pact_ninf_, yy::Parser::table_ninf_): | |
512 | Declare to be of type suitable for the ninf value itself, not of | |
513 | type suitable for the corresponding table, since the latter might | |
514 | be unsigned but the ninf value might be negative. This fixes a | |
515 | bug reported by Alexandre Duret-Lutz in | |
516 | <http://mail.gnu.org/archive/html/bug-bison/2003-04/msg00017.html>. | |
517 | ||
518 | * configure.ac (AC_FUNC_ERROR_AT_LINE): Remove, since gl_ERROR | |
519 | invokes it. We shouldn't invoke it twice because it will attempt | |
520 | to put error.o in the archive twice. This fixes a glitch reported | |
521 | by Martin Mokrejs in | |
522 | <http://mail.gnu.org/archive/html/bug-bison/2003-04/msg00041.html>. | |
523 | ||
524 | 2003-04-21 Paul Eggert <eggert@twinsun.com> | |
525 | ||
526 | * m4/error.m4: Update from Bruno Haible's 2003-04-14 patch | |
527 | to gnulib. | |
528 | ||
529 | 2003-04-21 Yakov Markovitch <Markovitch@iso.ru> | |
530 | ||
531 | * data/glr.c (yyexpandGLRStack) [!YYSTACKEXPANDABLE]: | |
532 | Fix obvious typo that results in uncompilable GLR parsers | |
533 | when both %pure-parser and %locations are used. (trivial change) | |
534 | ||
535 | 2003-04-17 Paul Eggert <eggert@twinsun.com> | |
536 | ||
537 | * src/scan-gram.l: Add %option nounput, since we no longer use unput. | |
538 | (unexpected_eof): Renamed from unexpected_end_of_file, for brevity. | |
539 | Do not insert the expected token via unput, as this runs afoul | |
540 | of a POSIX-compatibility bug in flex 2.5.31. | |
541 | All uses changed to BEGIN the parent state, | |
542 | since we no longer insert the expected token via unput. | |
543 | * tests/regression.at (Invalid inputs): Remove cascaded diagnostic | |
544 | that is no longer emitted after the above change. | |
545 | ||
546 | * src/conflicts.c (set_conflicts): Resolve all conflicts, not just | |
547 | the first one. This change is from Paul Hilfinger, and it fixes | |
548 | regression reported by Werner Lemberg in | |
549 | <http://mail.gnu.org/archive/html/bug-bison/2003-04/msg00026.html>. | |
550 | ||
551 | (resolve_sr_conflict): Don't invoke state_errs_set | |
552 | unless one or more tokens have been explicitly made errors. | |
553 | Otherwise, the above change causes Bison to abort. | |
554 | ||
555 | * tests/existing.at (GNU pic Grammar): New test case, taken from | |
556 | Lemberg's email. | |
557 | ||
558 | 2003-03-31 Akim Demaille <akim@epita.fr> | |
559 | ||
560 | * doc/Makefile.am (AM_MAKEINFOFLAGS): Don't split the info file. | |
561 | ||
562 | 2003-03-31 Akim Demaille <akim@epita.fr> | |
563 | ||
564 | * src/output.c (prepare_symbols): Avoid trailing spaces in the | |
565 | output. | |
566 | ||
567 | 2003-03-31 Akim Demaille <akim@epita.fr> | |
568 | ||
569 | * doc/bison.texinfo (Strings are Destroyed): s/losses/loses/. | |
570 | From Paul Hilfinger. | |
571 | ||
572 | 2003-03-29 Akim Demaille <akim@epita.fr> | |
573 | ||
574 | * m4/error.m4: Do not put under dynamic conditions some code which | |
575 | expansion is under static control. | |
576 | ||
577 | 2003-03-29 Akim Demaille <akim@epita.fr> | |
578 | ||
579 | * doc/bison.texinfo (How Can I Reset @code{yyparse}): New. | |
580 | ||
581 | 2003-03-29 Akim Demaille <akim@epita.fr> | |
582 | ||
583 | * doc/bison.texinfo (Strings are Destroyed): New. | |
584 | ||
585 | 2003-03-13 Paul Eggert <eggert@twinsun.com> | |
586 | ||
587 | * .cvsignore: Add configure.lineno. | |
588 | * src/.cvsignore: Add yacc. | |
589 | * tests/.cvsignore: Add testsuite.log. | |
590 | * doc/fdl.texi: Sync with latest FSF version. | |
591 | ||
592 | 2003-03-12 Paul Eggert <eggert@twinsun.com> | |
593 | ||
594 | * scan-gram.l (YY_USER_INIT): Initialize code_start, too. | |
595 | (<INITIAL><<EOF>>, <SC_PRE_CODE><<EOF>>): Set *loc to the scanner | |
596 | cursor, instead of leaving it undefined. This fixes a bug | |
597 | reported by Tim Van Holder in | |
598 | <http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00023.html>. | |
599 | * tests/input.at (Torturing the Scanner): Test the scanner on | |
600 | an empty input file, which was Tim Van Holder's test case. | |
601 | ||
602 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): When checking whether | |
603 | <sys/resource.h> can be included, include sys/time.h and | |
604 | sys/times.h first, if available. This works around the SunOS | |
605 | 4.1.4 porting bug reported by Bruce Becker in | |
606 | <http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00018.html>. | |
607 | ||
608 | * m4/subpipe.m4 (BISON_PREREQ_SUBPIPE): Don't | |
609 | AC_CHECK_HEADERS([sys/wait.h]), as this interferes with | |
610 | AC_HEADER_SYS_WAIT. | |
611 | ||
612 | Merge changes from gnulib. This was prompted because the CVS | |
613 | snapshot didn't build on Solaris 7 due to strnlen problems. | |
614 | ||
615 | These changes need to be merged back into gnulib: | |
616 | * lib/hash.c: Include <stdbool.h> unconditionally. | |
617 | * m4/onceonly.m4 (m4_quote): New macro. | |
618 | (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE): | |
619 | Quote AC_FOREACH variable-expansions properly. | |
620 | The 2003-01-03 obstack.h change also needs merging. | |
621 | {end of changes requiring merging} | |
622 | ||
623 | * lib/stdbool.h.in, m4/alloca.m4, m4/dirname.m4, m4/dos.m4, | |
624 | m4/getopt.m4, m4/hash.m4, m4/malloc.m4, m4/memchr.m4, | |
625 | m4/memrchr.m4, m4/obstack.m4, m4/onceonly.m4, m4/quote.m4, | |
626 | m4/quotearg.m4, m4/realloc.m4, m4/stpcpy.m4, m4/strnlen.m4, | |
627 | m4/strtol.m4, m4/strtoul.m4, m4/unlocked-io.m4, m4/xalloc.m4: | |
628 | New files, imported from gnulib. | |
629 | * m4/Makefile.am (EXTRA_DIST): Add the new m4/*.m4 files mentioned | |
630 | above. | |
631 | ||
632 | * lib/mbswidth.c, m4/error.m4, m4/mbrtowc.m4, m4/mbswidth.m4, | |
633 | m4/memcmp.m4, m4/prereq.m4, m4/stdbool.m4: Update to current | |
634 | gnulib sources. | |
635 | ||
636 | * configure.ac (gl_DIRNAME, gl_GETOPT, gl_HASH, gl_QUOTE, gl_XALLOC): | |
637 | Add. | |
638 | (gl_ERROR): New, replacing jm_PREREQ_ERROR. | |
639 | (gl_FUNC_ALLOCA): New, replacing AC_FUNC_ALLOCA. | |
640 | (gl_FUNC_STPCPY): New, replacing AC_REPLACE_FUNCS(stpcpy). | |
641 | (gl_FUNC_STRNLEN): New, replacing AC_FUNC_STRNLEN. | |
642 | (gl_MBSWIDTH): New, replacing jm_PREREQ_MBSWIDTH. | |
643 | (gl_OBSTACK): New, replacing AC_FUNC_OBSTACK. | |
644 | (gl_QUOTEARG): New, replacing jm_PREREQ_QUOTEARG. | |
645 | (jm_FUNC_GLIBC_UNLOCKED_IO, gl_FUNC_STPCPY, gl_FUNC_STRTOL): New. | |
646 | (jm_FUNC_MALLOC): New, replacing AC_FUNC_MALLOC. | |
647 | (jm_FUNC_REALLOC): New, replacing AC_FUNC_REALLOC. | |
648 | (jm_PREREQ_ARGMATCH): Remove. | |
649 | (AC_REPLACE_FUNCS): Remove memchr, memrchr, stpcpy, strtol, strtoul. | |
650 | * lib/Makefile.am (libbison_a_SOURCES): Add argmatch.c, argmatch.h. | |
651 | ||
652 | * src/system.h: Include <stdbool.h> unconditionally. | |
653 | ||
654 | * lib/bbitset.h: Include <limits.h> unconditionally. We have been | |
655 | assuming at least C89 in the bitset code for some time now. | |
656 | ||
657 | 2003-03-03 Akim Demaille <akim@epita.fr> | |
658 | ||
659 | * ro.po: New. | |
660 | ||
661 | 2003-03-02 Akim Demaille <akim@epita.fr> | |
662 | ||
663 | * doc/bison.texinfo (Table of Symbols): Reactivate the | |
664 | documentation for %lex-param, and %parse-param. | |
665 | ||
666 | 2003-03-02 Akim Demaille <akim@epita.fr> | |
667 | ||
668 | * data/yacc.c, data/glr.c, data/lal1.cc: Use similar code to | |
669 | generate verbose error messages. | |
670 | Use the number of tokens as an upper bound in yytname, as it | |
671 | cannot be a non terminal. | |
672 | ||
673 | 2003-03-02 Akim Demaille <akim@epita.fr> | |
674 | ||
675 | * tests/regression.at (_AT_DATA_DANCER_Y): Fix the expected error | |
676 | message. | |
677 | ||
678 | 2003-03-02 Akim Demaille <akim@epita.fr> | |
679 | ||
680 | * tests/regression.at (_AT_DATA_DANCER_Y, AT_CHECK_DANCER): New. | |
681 | Use them to exercise yycheck overrun. | |
682 | Based on Andrew Suffield's grammar. | |
683 | ||
684 | 2003-03-02 Akim Demaille <akim@epita.fr> | |
685 | ||
686 | Create tests/local.at for Bison generic testing macros. | |
687 | ||
688 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Move to... | |
689 | * tests/local.at (AT_BISON_OPTION_PUSHDEFS, AT_BISON_OPTION_POPDEFS): | |
690 | This new file. | |
691 | * tests/calc.at (AT_CHECK_CALC): Adjust. | |
692 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR) | |
693 | (AT_COMPILE, AT_COMPILE_CXX, AT_PARSER_CHECK): Move to... | |
694 | * tests/local.at: here. | |
695 | (AT_COMPILE_CXX): Tags the tests using it as c++. | |
696 | Ignore the test if CXX is not functional. | |
697 | ||
698 | 2003-03-01 Paul Eggert <eggert@twinsun.com> | |
699 | ||
700 | * src/scan-gram.l (code_start): Initialize it to scanner_cursor, | |
701 | not loc->end, since loc->end might contain garbage and this leads | |
702 | to undefined behavior on some platforms. | |
703 | (id_loc, token_start): Use (IF_LINTed) initial values that do not | |
704 | depend on *loc, so that the reader doesn't give the the false | |
705 | impression that *loc is initialized. | |
706 | (<INITIAL>"%%"): Do not bother setting code_start, since its value | |
707 | does not survive the return. | |
708 | ||
709 | 2003-03-01 Akim Demaille <akim@epita.fr> | |
710 | ||
711 | * src/scan-gram.l (code_start): Always initialize it when entering | |
712 | into yylex, as SC_EPILOGUE is activated *before* the corresponding | |
713 | yylex invocation. An alternative would be making it static, but | |
714 | then it starts with the second %%'s beginning, instead of its end. | |
715 | ||
716 | 2003-02-28 Paul Eggert <eggert@twinsun.com> | |
717 | ||
718 | * lib/mbswidth.c: Include <wchar.h> before "mbswidth.h", to work | |
719 | around a UnixWare 7.1.1 porting bug reported by John Hughes in | |
720 | <http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html>. | |
721 | ||
722 | 2003-02-26 Paul Eggert <eggert@twinsun.com> | |
723 | ||
724 | * README: Mention compiler bug in Sun Forte Developer 6 update 2. | |
725 | Remove Sequent/Pyramid discussion (nobody uses them any more). | |
726 | Merge VMS and MS-DOS discussion; these ports may well be dead | |
727 | but let's keep mentioning them for now. Put <> around email | |
728 | addresses. Add copyright notice. | |
729 | ||
730 | 2003-02-24 Paul Eggert <eggert@twinsun.com> | |
731 | ||
732 | * data/glr.c (yy_reduce_print): yylineno -> yylno, | |
733 | to avoid collision with flex use of yylineno. | |
734 | Problem reported by Bruce Lilly in | |
735 | <http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00016.html>. | |
736 | * data/lalr1.cc (yy::]b4_parser_class_name[::parse): Likewise. | |
737 | * data/yacc.c (yy_reduce_print): Likewise. | |
738 | ||
739 | * config/depcomp: Sync with Automake 1.7.3. | |
740 | ||
741 | 2003-02-21 Akim Demaille <akim@epita.fr> | |
742 | ||
743 | * data/lalr1.cc: Use temporary variables instead of casts to | |
744 | change integer types. | |
745 | Suggested by Paul Eggert. | |
746 | ||
747 | 2003-02-21 Akim Demaille <akim@epita.fr> | |
748 | ||
749 | * doc/bison.texinfo: Use "location" consistently to refer to @n, | |
750 | to avoid confusions with lalr1.cc's notion of Position. | |
751 | Suggested by Paul Eggert. | |
752 | ||
753 | 2003-02-20 Akim Demaille <akim@epita.fr> | |
754 | ||
755 | * data/lalr1.cc (position.hh): Make sure "columns" never pushes | |
756 | before initial_columns. | |
757 | (location.hh): Use consistent variable names when defining the | |
758 | operator<<. | |
759 | Use "last" so that we subtract from Positions, not from unsigned. | |
760 | ||
761 | 2003-02-20 Akim Demaille <akim@epita.fr> | |
762 | ||
763 | * data/lalr1.cc (position.hh): New subfile, including the extended | |
764 | and Doxygen'ed documentation of class Position. | |
765 | (location.hh): Use it. | |
766 | Document a` la Doxygen. | |
767 | With the help of Benoit Perrot. | |
768 | ||
769 | 2003-02-20 Akim Demaille <akim@epita.fr> | |
770 | ||
771 | * tests/calc.at (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): Define | |
772 | AT_YACC_IF. | |
773 | Redefine AT_YYERROR_SEES_LOC_IF using it. | |
774 | (_AT_DATA_CALC_Y): Don't declare yyerror when lalr1.cc, as it is | |
775 | not defined. | |
776 | Don't use the location in yy::Parser::error_ and | |
777 | yy::Parser::print_ when not %locations. | |
778 | Activate more lalr1.cc tests. | |
779 | ||
780 | 2003-02-19 Akim Demaille <akim@epita.fr> | |
781 | ||
782 | * data/lalr1.cc: When displaying a line number, be sure to make it | |
783 | an int. | |
784 | ||
785 | 2003-02-19 Akim Demaille <akim@epita.fr> | |
786 | ||
787 | * data/lalr1.cc (b4_stack_depth_init, yy::Parser::initdepth_): | |
788 | Remove, useless. | |
789 | (YYABORT, YYACCEPT, YYERROR): New. | |
790 | * tests/calc.at: Renable the lalr1.cc test. | |
791 | ||
792 | 2003-02-19 Akim Demaille <akim@epita.fr> | |
793 | ||
794 | * tests/calc.at (AT_CHECK_CALC): Check different scenarios of | |
795 | error recovery, mixing with/without pops and discarding of the | |
796 | lookahead. | |
797 | Exercise YYERROR. | |
798 | Disable the lalr1.cc tests as currently it doesn't support YYERROR. | |
799 | ||
800 | 2003-02-17 Paul Eggert <eggert@twinsun.com> | |
801 | ||
802 | * tests/atlocal.in (LDFLAGS, LIBS): New vars. | |
803 | * tests/testsuite.at (AT_COMPILE): Use them. | |
804 | This fixes the testsuite problem reported by Robert Lentz in | |
805 | <http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00011.html>. | |
806 | ||
807 | 2003-02-12 Paul Eggert <eggert@twinsun.com> | |
808 | ||
809 | * data/yacc.c (yyerrlab) [YYERROR_VERBOSE]: | |
810 | Avoid subscript error in yycheck. Bug reported by Andrew Suffield in | |
811 | <http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00003.html>. | |
812 | * data/glr.c (yyreportSyntaxError) [YYERROR_VERBOSE]: Likewise. | |
813 | Check for malloc failure, for consistency with yacc.c. | |
814 | (yytname_size): Remove, for consistency with yacc.c. | |
815 | ||
816 | The bug still remains in data/lalr1.cc, as I didn't have time | |
817 | to fix it there. | |
818 | ||
819 | 2003-02-06 Akim Demaille <akim@epita.fr> | |
820 | ||
821 | * configure.ac (GXX): Rename as... | |
822 | (CXX): this, to keep the original Autoconf semantics. | |
823 | Require 2.57. | |
824 | * data/lalr1.cc: Fix b4_copyright invocations. | |
825 | If YYDEBUG is not defined, don't depend upon name_ being defined. | |
826 | (location.hh): Include string and iostream. | |
827 | (Position::filename): New member. | |
828 | (Position::Position ()): New. | |
829 | (operator<< (Position)): New. | |
830 | (operator- (Position, int)): New. | |
831 | (Location::first, Location::last): Rename as... | |
832 | (Location::begin, Location::end): these, to mock the conventional | |
833 | iterator names. | |
834 | (operator<< (Location)): New. | |
835 | * tests/atlocal.in (CXX): New. | |
836 | * tests/testsuite.at (AT_COMPILE_CXX): New. | |
837 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust yyerror to report the | |
838 | locations in a more synthetic way. | |
839 | (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF is positive if | |
840 | lalr1.cc is used. | |
841 | Adjust the C locations to match those from Emacs: first column is | |
842 | column 0. | |
843 | Change all the expected results. | |
844 | Conform to the GCS: simplify the locations when applicable. | |
845 | (LOC, VAL, YYLLOC_FORMAL, YYLLOC_ARG, USE_YYLLOC, LEX_FORMALS) | |
846 | (LEX_ARGS, USE_LEX_ARGS, LEX_PRE_FORMALS, LEX_PRE_ARGS): Replace | |
847 | these CPP macros with the m4 macros new defined by... | |
848 | (AT_CHECK_PUSHDEFS): this, i.e.: | |
849 | (AT_LALR1_CC_IF, AT_PURE_LEX_IF, AT_LOC, AT_VAL, AT_LEX_FORMALS) | |
850 | (AT_LEX_ARGS, AT_USE_LEX_ARGS, AT_LEX_PRE_FORMALS, AT_LEX_PRE_ARGS) | |
851 | New macros. | |
852 | (AT_CHECK_POPDEFS): Undefine them. | |
853 | (AT_CHECK_CALC_LALR1_CC): New. | |
854 | Use it for the first lalr1.cc test. | |
855 | ||
856 | 2003-02-04 Akim Demaille <akim@epita.fr> | |
857 | ||
858 | * data/lalr1.cc (YYLLOC_DEFAULT): Fix its definition: be based on | |
859 | Location as is defined. | |
860 | ||
861 | 2003-02-04 Akim Demaille <akim@epita.fr> | |
862 | ||
863 | * data/lalr1.cc: If YYDEBUG is not defined, don't depend upon | |
864 | name_ being defined. | |
865 | ||
866 | 2003-02-03 Paul Eggert <eggert@twinsun.com> | |
867 | ||
868 | * src/gram.h (start_symbol): Remove unused decl. | |
869 | ||
870 | Use more-consistent naming conventions for local vars. | |
871 | ||
872 | * src/derives.c (derives_compute): Change type of local var from | |
873 | int to rule_number. | |
874 | * src/gram.c (grammar_rules_partial_print): Likewise. | |
875 | * src/print.c (print_core): Likewise. | |
876 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
877 | ||
878 | * src/gram.c (grammar_dump): Change name of item_number * | |
879 | local var from r to rp. | |
880 | * src/nullable.c (nullable_compute): Likewise. | |
881 | ||
882 | * src/gram.h (ISTOKEN, ISVAR): Use i, not s, for int var. | |
883 | ||
884 | * src/gram.h (symbol_number_as_item_number): Use sym, not s, | |
885 | for symbol or symbol_number var. | |
886 | * src/reader.c (grammar_start_symbol_set): Likewise. | |
887 | * src/reader.h (grammar_start_symbol_set, grammar_symbol_append): | |
888 | Likewise. | |
889 | * src/state.c (transitions_to): Likewise. | |
890 | * src/state.h: Likewise. | |
891 | * src/tables.c (symbol_number_to_vector_number): Likewise. | |
892 | ||
893 | * src/muscle_tab.h (MUSCLE_OBSTACK_SGROW): Use p, not s, for | |
894 | char * var. | |
895 | ||
896 | * src/parse-gram.y (lloc_default): Use loc, not r, for YYLTYPE | |
897 | var. | |
898 | ||
899 | * src/scan-gram.l (no_cr_read): Use bytes_read, not s, for size | |
900 | var. | |
901 | ||
902 | * src/system.h (xstrndup, strchr, strspn, strnlen, memchr, memrchr): | |
903 | Use str, not s, for char * var. Use ch, not c, for character var. | |
904 | Use size for size var. | |
905 | ||
906 | * src/uniqstr.c (uniqstr_new, uniqstr_assert): Use str, not s, for | |
907 | char * var. | |
908 | (uniqstr_print, uniqst_print_processor): Use ustr, not s, for | |
909 | uniqstr var. | |
910 | * src/uniqstr.h: Likewise. | |
911 | ||
912 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
913 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
914 | get_node_alignment_str, get_arrow_mode_str, get_crossing_type_str, | |
915 | get_view_str, get_linestyle_str, get_arrowstyle_str): Rename | |
916 | param to have same name as that of enum, so that we don't use | |
917 | "s" to stand for a non-state. | |
918 | ||
919 | 2003-02-02 Akim Demaille <akim@epita.fr> | |
920 | ||
921 | * src/scan-skel.l: Scan more than one inert character per yylex | |
922 | invocation. | |
923 | ||
924 | 2003-02-01 Paul Eggert <eggert@twinsun.com> | |
925 | ||
926 | Version 1.875a. | |
927 | ||
928 | * po/LINGUAS: Add ms. | |
929 | ||
930 | 2003-01-30 Akim Demaille <akim@epita.fr> | |
931 | ||
932 | * doc/Makefile.am (CLEANFILES): Add bison.fns for distcheck. | |
933 | ||
934 | 2003-01-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
935 | ||
936 | * tests/cxx-type.at: Correct apparent typo in Bison input: $$ instead | |
937 | of $1. | |
938 | ||
939 | Changes in response to error report by S. Eken: GLR mode does not | |
940 | handle negative $ indices or $ indices in embedded rules correctly. | |
941 | See <http://mail.gnu.org/archive/html/bug-bison/2003-01/msg00076.html>. | |
942 | ||
943 | * data/glr.c (b4_rhs_value): Change to use YYFILL macro. | |
944 | (b4_rhs_location): Ditto. | |
945 | (yyfill): New function to copy from stack tree into array | |
946 | incrementally. | |
947 | (yyuserAction): Modify to allow incremental move of semantic values | |
948 | to rhs array when in GLR mode. | |
949 | Define YYFILL to use in user-defined actions to fill semantic array | |
950 | as needed. | |
951 | Remove dummy use of yystack, as there is now a guaranteed use. | |
952 | (yydoAction): Modify to allow incremental move of semantic values | |
953 | to rhs array when in GLR mode. | |
954 | (yyresolveAction): Ditto. | |
955 | (yyglrShiftDefer): Update comment. | |
956 | (yyresolveStates): Use X == NULL for pointers, not !X. | |
957 | (yyglrReduce): Ditto. | |
958 | (yydoAction): Ditto | |
959 | ||
960 | * tests/glr-regr1.at: Rename to ... | |
961 | * tests/glr-regression.at: Add new regression test for the problems | |
962 | described above (adapted from S. Eken). | |
963 | Update copyright notice. | |
964 | * tests/testsuite.at: Rename glr-regr1.at to glr-regression.at. | |
965 | * tests/Makefile.am: Ditto. | |
966 | ||
967 | 2003-01-28 Paul Eggert <eggert@twinsun.com> | |
968 | ||
969 | * data/lalr1.cc: Do not use @output_header_name@ unless | |
970 | b4_defines_flag is set. This fixes two bugs reported by | |
971 | Tim Van Holder in | |
972 | <http://mail.gnu.org/archive/html/bug-bison/2003-01/msg00071.html> | |
973 | and <http://mail.gnu.org/archive/html/bug-bison/2003-01/msg00073.html>. | |
974 | ||
975 | 2003-01-21 Paul Eggert <eggert@twinsun.com> | |
976 | ||
977 | * data/yacc.c (YYERROR): Move code from yyerrlab1 to here, so that | |
978 | we don't need to worry about yyerrlab1 being reported as an | |
979 | "unused label" by non-GCC C compilers. The downside is that if | |
980 | locations are used then a couple of statements are duplicated each | |
981 | time YYERROR is invoked, but the upside is that the warnings | |
982 | should vanish. | |
983 | (yyerrlab1): Move code to YERROR. | |
984 | (yyerrlab2): Remove. Change uses back to yyerrlab1. | |
985 | This reverts some of the 2002-12-27 change. | |
986 | ||
987 | 2003-01-17 Paul Eggert <eggert@twinsun.com> | |
988 | ||
989 | * src/output.c (symbol_printers_output): Fix typo that led | |
990 | to core dump. Problem reported by Antonio Rus in | |
991 | <http://mail.gnu.org/archive/html/bug-bison/2003-01/msg00058.html>. | |
992 | ||
993 | 2003-01-13 Akim Demaille <akim@epita.fr>, | |
994 | Quoc Peyrot <chojin@lrde.epita.fr>, | |
995 | Robert Anisko <anisko_r@lrde.epita.fr> | |
996 | ||
997 | * data/lalr1.cc (parse::yyerrlab1): When popping the stack, stop | |
998 | when the stacks contain one element, as the loop would otherwise | |
999 | free the last state, and then use the top state (the one we just | |
1000 | popped). This means that the initial elements will not be freed | |
1001 | explicitly, as is the case in yacc.c; it is not a problem, as | |
1002 | these elements have fake values. | |
1003 | ||
1004 | 2003-01-11 Paul Eggert <eggert@twinsun.com> | |
1005 | ||
1006 | * NEWS: %expect-violations are now just warnings, reverting | |
1007 | to Bison 1.30 and 1.75 behavior. This fixes the GCC 3.2 | |
1008 | bootstrapping problem reported by Matthias Klose; see | |
1009 | <http://mail.gnu.org/archive/html/bug-bison/2003-01/msg00053.html>. | |
1010 | * src/conflicts.c (conflicts_print): Likewise. | |
1011 | * tests/conflicts.at (%expect not enough, %expect too much, | |
1012 | %expect with reduce conflicts): Likewise. | |
1013 | * doc/bison.texinfo (Expect Decl): Document this. Also mention | |
1014 | that the warning is enabled if the number of conflicts changes | |
1015 | (not necessarily increases). | |
1016 | ||
1017 | * src/getargs.c (version): Update copyright year. | |
1018 | ||
1019 | 2003-01-09 Akim Demaille <akim@epita.fr> | |
1020 | ||
1021 | * src/Makefile.am, lib/Makefile.am: Use $(VAR) instead of @VAR@. | |
1022 | ||
1023 | 2003-01-08 Paul Eggert <eggert@twinsun.com> | |
1024 | ||
1025 | * Makefile.maint (WGETFLAGS): | |
1026 | New macro, containing "-C off" to disable proxy caches. | |
1027 | All uses of $(WGET) changed to $(WGET) $(WGETFLAGS). | |
1028 | (rel-check): Use $(WGET) instead of wget. | |
1029 | ||
1030 | 2003-01-06 Paul Eggert <eggert@twinsun.com> | |
1031 | ||
1032 | * doc/bison.texinfo (Generalized LR Parsing): Add a reference to | |
1033 | the GLR paper of Scott, Johnstone and Hussain. | |
1034 | ||
1035 | 2003-01-04 Paul Eggert <eggert@twinsun.com> | |
1036 | ||
1037 | * configure.ac (AC_ARG_ENABLE): Add --disable-yacc. | |
1038 | (YACC_SCRIPT, YACC_LIBRARY): New vars to AC_SUBST. | |
1039 | * lib/Makefile.am (lib_LIBRARIES): liby.a -> @YACC_LIBRARY@. | |
1040 | (EXTRA_LIBRARIES): New var, for liby.a. | |
1041 | * src/Makefile.am (bin_SCRIPTS): yacc -> @YACC_SCRIPT@. | |
1042 | (EXTRA_SCRIPTS): New var, for yacc. | |
1043 | ||
1044 | * data/yacc.c (yyerrlab1): Omit attribute if __cplusplus is defined, | |
1045 | since GNU C++ (as of 3.2.1) does not allow attributes on labels. | |
1046 | Problem reported by Nelson H. F. Beebe. | |
1047 | ||
1048 | 2003-01-03 Paul Eggert <eggert@twinsun.com> | |
1049 | ||
1050 | * lib/obstack.h (__INT_TO_PTR) [__STDC__]: Cast result to | |
1051 | (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5 | |
1052 | when compiling Bison 1.875's `bitset bset = obstack_alloc | |
1053 | (bobstack, bytes);'. Problem reported by Nelson H. F. Beebe. | |
1054 | ||
1055 | * src/scan-skel.l (QPUTS): Omit redundant `;' from macro definition. | |
1056 | ([^@\n]): Renamed from [^@\n]+ so that the token buffer does not | |
1057 | grow to a huge size with typical invocation. | |
1058 | ||
1059 | * lib/hash.c (_Bool, bool, false, true, __bool_true_false_are_defined): | |
1060 | Use the pattern recommended by Autoconf 2.57, except also protect | |
1061 | against double-definition. | |
1062 | * src/system.h: Likewise. | |
1063 | Portability issues reported by Nelson H. F. Beebe. | |
1064 | ||
1065 | * data/glr.c (yybool): Renamed from bool, to avoid collisions in C. | |
1066 | All uses changed. Provide a definition in both C and C++. | |
1067 | (yytrue, yyfalse): Define even if defined (__cplusplus). | |
1068 | ||
1069 | * lib/bitset_stats.c (bitset_stats_list): Remove unused var. | |
1070 | Reported by Nelson H. F. Beebe. | |
1071 | ||
1072 | * src/scan-skel.l ("@oline@"): Output lineno+1, not lineno. | |
1073 | ||
1074 | 2003-01-02 Paul Eggert <eggert@twinsun.com> | |
1075 | ||
1076 | * data/yacc.c (yyerrlab1): Append `;' after attribute, to | |
1077 | pacify the buggy "smart preprocessor" in MacOS 10.2.3. | |
1078 | Bug reported by Nelson H. F. Beebe. | |
1079 | ||
1080 | 2003-01-01 Paul Eggert <eggert@twinsun.com> | |
1081 | ||
1082 | * Version 1.875. | |
1083 | ||
1084 | 2002-12-30 Paul Eggert <eggert@twinsun.com> | |
1085 | ||
1086 | * src/scan-gram.l (<INITIAL,SC_AFTER_IDENTIFIER,SC_PRE_CODE>","): | |
1087 | Moved here from... | |
1088 | (<INITIAL>","): Here. This causes stray "," to be treated | |
1089 | more uniformly. | |
1090 | ||
1091 | * src/scan-gram.l (<SC_BRACED_CODE>"}"): Output ";" before the | |
1092 | last brace in braced code when not in Yacc mode, for compatibility | |
1093 | with Bison 1.35. This resurrects the 2001-12-15 patch to | |
1094 | src/reader.c. | |
1095 | ||
1096 | * src/reader.h (YYDECL): Use YYSTYPE, not its deprecated alias | |
1097 | yystype. This follows up the 2002-12-24 YYSTYPE bug fix. | |
1098 | ||
1099 | 2002-12-28 Paul Eggert <eggert@twinsun.com> | |
1100 | ||
1101 | * src/symtab.c (symbol_make_alias): Set type of SYMVAL to be | |
1102 | that of SYM's type. This fixes Debian bug 168069, reported by | |
1103 | Thomas Olsson. | |
1104 | ||
1105 | 2002-12-28 Paul Eggert <eggert@twinsun.com> | |
1106 | ||
1107 | Version 1.75f. | |
1108 | ||
1109 | Switch back to the Yacc style of conflict reports, undoing some | |
1110 | of the 2002-07-30 change. | |
1111 | * doc/bison.texinfo (Understanding): Use Yacc style for | |
1112 | conflict reports. Also, use new way of locating rules. | |
1113 | * src/conflicts.c (conflict_report): | |
1114 | Renamed from conflict_report_yacc, removing the old | |
1115 | 'conflict_report'. Translate the entire conflict report at once, | |
1116 | so that we don't assume that "," has the same interpretation in | |
1117 | all languages. | |
1118 | (conflicts_output): Use Yacc-style conflict report for each state, | |
1119 | instead of our more-complicated style. | |
1120 | (conflicts_print): Use Yacc-style conflict report, except print | |
1121 | the input file name when not emulating Yacc. | |
1122 | * tests/conflicts.at (Unresolved SR Conflicts, Defaulted | |
1123 | Conflicted Reduction, %expect not enough, %expect too much, | |
1124 | %expect with reduce conflicts): Switch to Yacc-style conflict reports. | |
1125 | * tests/existing.at (GNU Cim Grammar): Likewise. | |
1126 | * tests/glr-regr1.at (Badly Collapsed GLR States): Likewise. | |
1127 | ||
1128 | * src/complain.c (warn_at, warn, complain_at, complain, fatal_at, | |
1129 | fatal): Don't invoke fflush; it's not needed and it might even be | |
1130 | harmful for stdout, as stdout might not be open. | |
1131 | * src/reduce.c (reduce_print): Likewise. | |
1132 | ||
1133 | 2002-12-27 Paul Eggert <eggert@twinsun.com> | |
1134 | ||
1135 | Fix a bug where error locations were not being recorded correctly. | |
1136 | This problem was originally reported by Paul Hilfinger in | |
1137 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00086.html>. | |
1138 | ||
1139 | * data/yacc.c (yyparse): New local var yylerrsp, to record the | |
1140 | top of the location stack's error locations. | |
1141 | (yyerrlab): Set it. When discarding a token, push its location | |
1142 | onto yylerrsp so that we don't lose track of the error's end. | |
1143 | (yyerrlab1): Now is only the target of YYERROR, so that we can | |
1144 | properly record the location of the action that failed. For GCC | |
1145 | 2.93 and later, insert an __attribute__ ((__unused__)) to avoid | |
1146 | GCC warning about yyerrlab1 being unused if YYERROR is unused. | |
1147 | (yyerrlab2): New label, which yyerrlab now falls through to. | |
1148 | Compute the error's location by applying YYLLOC_DEFAULT to | |
1149 | the locations of all the symbols that went into the error. | |
1150 | * doc/bison.texinfo (Location Default Action): Mention that | |
1151 | YYLLOC_DEFAULT is also invoked for syntax errors. | |
1152 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): | |
1153 | Error locations include the locations of all the tokens that were | |
1154 | discarded, not just the last token. | |
1155 | ||
1156 | 2002-12-26 Paul Eggert <eggert@twinsun.com> | |
1157 | ||
1158 | * src/files.c: Include quote.h. | |
1159 | (compute_output_file_names): Warn if we detect conflicting | |
1160 | outputs to the same file. This should catch the misunderstanding | |
1161 | exemplified by Debian Bug 165349, reported by Bruce Stephens.. | |
1162 | ||
1163 | * src/conflicts.c (conflicts_print): If the user specifies | |
1164 | "%expect N", report an error if there are any reduce/reduce | |
1165 | conflicts. This is what the manual says should happen. | |
1166 | This fixes Debian bug 130890, reported by Anthony DeRobertis. | |
1167 | * tests/conflicts.at (%expect with reduce conflicts): New test. | |
1168 | ||
1169 | Don't use m4_include on relative file names, as it doesn't work as | |
1170 | desired if there happens to be a file with that name under ".". | |
1171 | ||
1172 | * m4sugar/version.m4: Remove; it was included but it wasn't used. | |
1173 | * data/Makefile.am (dist_m4sugar_DATA): Remove m4sugar/version.m4. | |
1174 | * data/m4sugar/m4sugar.m4: Don't include m4sugar/version.m4. | |
1175 | * data/glr.c, data/lalr1.cc, data/yacc.c: Don't include c.m4. | |
1176 | * src/output.c (output_skeleton): Use full path names when | |
1177 | specifying a file to include; don't rely on include path, as | |
1178 | it's unreliable when the working file contains a file with | |
1179 | that name. | |
1180 | ||
1181 | 2002-12-25 Paul Eggert <eggert@twinsun.com> | |
1182 | ||
1183 | Remove obsolete references to bison.simple and bison.hairy. | |
1184 | Problem mentioned by Aubin Mahe in | |
1185 | <http://mail.gnu.org/archive/html/help-bison/2002-12/msg00010.html>. | |
1186 | * data/glr.c: Comment fix. | |
1187 | * doc/bison.1: Remove references. Also, mention "yacc". | |
1188 | ||
1189 | * src/getargs.c (getargs) [MSDOS]: Don't assume optarg != NULL | |
1190 | with -g option. | |
1191 | ||
1192 | * src/parse-gram.y (declaration): Use enum "report_states" rather | |
1193 | than its numeric value 1. | |
1194 | ||
1195 | * src/scan-skel.l ("@output ".*\n): Close any old yyout before | |
1196 | opening a new one. This fixes Debian bug 165349, reported by | |
1197 | Bruce Stephens. | |
1198 | ||
1199 | 2002-12-24 Paul Eggert <eggert@twinsun.com> | |
1200 | ||
1201 | Version 1.75e. | |
1202 | ||
1203 | * Makefile.maint (cvs-update): Don't assume that the shell | |
1204 | supports $(...), as Solaris sh doesn't. | |
1205 | ||
1206 | * src/parse-gram.y (lloc_default): Remove test for empty | |
1207 | nonterminals at the end, since it didn't change the result. | |
1208 | ||
1209 | 2002-12-24 Paul Eggert <eggert@twinsun.com> | |
1210 | ||
1211 | If the user does not define YYSTYPE as a macro, Bison now declares it | |
1212 | using typedef instead of defining it as a macro. POSIX requires this. | |
1213 | For consistency, YYLTYPE is also declared instead of defined. | |
1214 | ||
1215 | %union directives can now have a tag before the `{', e.g., the | |
1216 | directive `%union foo {...}' now generates the C code | |
1217 | `typedef union foo { ... } YYSTYPE;'; this is for Yacc compatibility. | |
1218 | The default union tag is `YYSTYPE', for compatibility with Solaris 9 | |
1219 | Yacc. For consistency, YYLTYPE's struct tag is now `YYLTYPE' | |
1220 | instead of `yyltype'. | |
1221 | ||
1222 | `yystype' and `yyltype' are now obsolescent macros instead of being | |
1223 | typedefs or tags; they are no longer documented and will be | |
1224 | withdrawn in a future release. | |
1225 | ||
1226 | * data/glr.c (b4_location_type): Remove. | |
1227 | (YYSTYPE): Renamed from yystype. | |
1228 | (YYSTYPE_IS_DECLARED): New macro, used to prevent double-typedef. | |
1229 | (struct YYLTYPE): Renamed from struct yyltype. | |
1230 | (YYLTYPE): Renamed from yyltype. | |
1231 | (yyltype, yystype): New (and obsolescent) macros, | |
1232 | for backward compatibility. | |
1233 | * data/yacc.c: Likewise. | |
1234 | ||
1235 | * data/yacc.c (YYSTYPE): Declare as union YYSTYPE if the user | |
1236 | does not specify a union tag. This is for compatibility with | |
1237 | Solaris 9 yacc. | |
1238 | ||
1239 | * src/parse-gram.y (add_param): 2nd arg is now char * not char | |
1240 | const *, since it is now modified by stripping surrounding { }. | |
1241 | (current_braced_code): Remove. | |
1242 | (PERCENT_DESTRUCTOR, PERCENT_PRINTER, PERCENT_UNION, | |
1243 | PERCENT_LEX_PARAM, PERCENT_PARSE_PARAM): Change names to include | |
1244 | trailing " {...}". Now of type <chars>. | |
1245 | (grammar_declaration): Adjust to bundled tokens. | |
1246 | (code_content): Remove; stripping is now done by add_param. | |
1247 | (print_token_value): Print contents of bundled tokens. | |
1248 | (token_name): New function. | |
1249 | ||
1250 | * src/reader.h (braced_code, current_braced_code): Remove. | |
1251 | (token_name): New decl. | |
1252 | ||
1253 | * src/scan-gram.l (handle_dollar, handle_at): Now takes int | |
1254 | token_type, not braced_code code_kind. All uses changed. | |
1255 | (SC_PRE_CODE): New state, for scanning after a keyword that | |
1256 | has (or usually has) an immediately-following braced code. | |
1257 | (token_type): New local var, to keep track of which token type | |
1258 | to return when scanning braced code. | |
1259 | (<INITIAL>"%destructor", <INITIAL>"%lex-param", | |
1260 | <INITIAL>"%parse-param", <INITIAL>"%printer", | |
1261 | <INITIAL>"%union"): Set token type and BEGIN SC_PRE_CODE | |
1262 | instead of returning a token type immediately. | |
1263 | (<INITIAL>"{"): Set token type. | |
1264 | (<SC_BRACED_CODE>"}"): Use it. | |
1265 | (handle_action_dollar, handle_action_at): Now returns bool | |
1266 | indicating success. Fail if ! current_rule; this prevents a core dump. | |
1267 | (handle_symbol_code_dollar, handle_symbol_code_at): | |
1268 | Remove; merge body into caller. | |
1269 | (handle_dollar, handle_at): Complain in invalid contexts. | |
1270 | ||
1271 | * NEWS, doc/bison.texinfo: Document the above. | |
1272 | * NEWS: Fix years and program names in copyright notice. | |
1273 | ||
1274 | 2002-12-17 Paul Eggert <eggert@twinsun.com> | |
1275 | ||
1276 | * NEWS, doc/bison.texinfo (Parser Function, Pure Calling, Error | |
1277 | Reporting, Table of Symbols): Omit mentions of %lex-param and | |
1278 | %parse-param from the documentation for now. | |
1279 | ||
1280 | 2002-12-15 Paul Eggert <eggert@twinsun.com> | |
1281 | ||
1282 | Undo most of the 2002-11-12 yychar -> yytoken patch, as it broke | |
1283 | GCC 3.2.1 (which depends on yychar == YYEMPTY when there is no | |
1284 | lookahead symbol, and which sets yychar in parser actions) and it | |
1285 | disagreed with the Bison documentation. Bug | |
1286 | reported by Andrew Walrond. | |
1287 | ||
1288 | * data/yacc.c (YYTRANSLATE): Don't check for negative argument, | |
1289 | as the caller now does that. | |
1290 | (yyclearin, YYBACKUP, yyparse): Use yychar, not yytoken. | |
1291 | (YYEMPTY): Parenthesize right hand side, since others use it. | |
1292 | (yyparse): Don't assume that our generated code is the only code | |
1293 | that sets yychar. | |
1294 | ||
1295 | 2002-12-13 Paul Eggert <eggert@twinsun.com> | |
1296 | ||
1297 | Version 1.75d. | |
1298 | ||
1299 | POSIX requires a "yacc" command. | |
1300 | * src/Makefile.am (bin_SCRIPTS): New macro, for yacc. | |
1301 | (MOSTLYCLEANFILES): Add yacc. | |
1302 | (yacc): New rule. | |
1303 | * doc/bison.texinfo (Invocation, Bison Options): Mention yacc | |
1304 | as an alias for bison y. | |
1305 | ||
1306 | * po/LINGUAS: Add da. | |
1307 | ||
1308 | * src/getargs.c (__GNU_LIBRARY__) [lint]: Define to work around | |
1309 | problem with latest <getopt.h>. | |
1310 | (HACK_FOR___GNU_LIBRARY___PROTOTYPE): New macro. | |
1311 | ||
1312 | * doc/fdl.texi: Upgrade to 1.2. | |
1313 | * lib/alloca.c, lib/error.c, lib/getopt.c, lib/getopt.h | |
1314 | lib/getopt1.c, lib/gettext.h, lib/memrchr.c, lib/obstack.c, | |
1315 | lib/obstack.h, lib/strnlen.c, lib/unlocked-io.h: Sync with | |
1316 | gnulib. | |
1317 | * config/install-sh: Sync with autotools. | |
1318 | ||
1319 | Fix a bad interaction with flex 2.5.23 reported by Bruce Lilly in | |
1320 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. | |
1321 | * data/yacc.c (YYLTYPE, struct yyltype): Do not define unless | |
1322 | locations are requested. | |
1323 | (union yyalloc): Do not depend on YYLTYPE_IS_TRIVIAL unless | |
1324 | locations are requested. | |
1325 | ||
1326 | 2002-12-12 Paul Eggert <eggert@twinsun.com> | |
1327 | ||
1328 | Remove unportable casts and storage allocation tricks. | |
1329 | While we're at it, remove almost all casts, since they | |
1330 | usually aren't needed and are a sign of trouble. | |
1331 | ||
1332 | * configure.ac (AC_CHECK_TYPES): Check for uintptr_t. | |
1333 | ||
1334 | * src/derives.c (derives_compute): Do not subtract NTOKENS from | |
1335 | the pointer DSET returned by malloc; this isn't portable. | |
1336 | Instead, always use DSET[i - NTOKENS] rather than DSET[i]. | |
1337 | Similarly for DERIVES. | |
1338 | * src/lalr.c (set_goto_map): Likewise, for GOTO_MAP and TEMP_MAP. | |
1339 | * src/nullable.c (nullable_compute): Likewise, for RSETS and NULLABLE. | |
1340 | * src/reduce.c (reduce_grammar_tables): Likewise, for nontermmap | |
1341 | ||
1342 | * src/derives.c (derives_compute): Do not bother invoking | |
1343 | int_of_rule_number, since rule numbers are integers. | |
1344 | ||
1345 | * src/files.c (concat2, tr, compute_base_name): Use xmalloc (N) | |
1346 | rather than XMALLOC (char, N). | |
1347 | ||
1348 | * src/files.c (filename_split): Rewrite to avoid cast. | |
1349 | ||
1350 | * src/gram.h (symbol_number_as_item_number, | |
1351 | item_number_as_symbol_number, rule_number_as_item_number, | |
1352 | item_number_as_rule_number): | |
1353 | Now inline functions rather than macros, to avoid casts. | |
1354 | * src/state.h (state_number_as_int): Likewise. | |
1355 | * src/tables.c (state_number_to_vector_number, | |
1356 | symbol_number_to_vector_number): Likewise. | |
1357 | ||
1358 | * src/gram.h (int_of_rule_number): Remove; no longer used. | |
1359 | ||
1360 | * src/lalr.c (add_lookback_edge): Use malloc rather than calloc, | |
1361 | since the resulting storage is always stored into. | |
1362 | ||
1363 | * src/main.c (alloca) [C_ALLOCA]: Add decl here, the only place | |
1364 | where it's needed. | |
1365 | ||
1366 | * src/muscle_tab.c (muscle_m4_output): | |
1367 | Now inline. Return bool, not int. | |
1368 | * src/state.c (state_compare): Likewise. | |
1369 | * src/symtab.c (symbol_check_defined, | |
1370 | symbol_check_alias_consistency, symbol_pack, symbol_translation, | |
1371 | hash_compare_symbol, hash_symbol): | |
1372 | Likewise. | |
1373 | * src/uniqstr.c (uniqstr_print): Likewise. | |
1374 | * src/muscle_tab.c (muscle_m4_output_processor): | |
1375 | New function, to avoid casts. | |
1376 | * src/state.c (state_comparator, stage_hasher): Likewise. | |
1377 | * src/symtab.c (symbol_check_defined_processor, | |
1378 | symbol_check_alias_consistency_processor, symbol_pack_processor, | |
1379 | symbol_translation_processor, hash_symbol_comparator, | |
1380 | hash_symbol_hasher): Likewise. | |
1381 | * src/uniqstr.c (uniqstr_print_processor): Likewise. | |
1382 | * src/muscle_tab.c (muscles_m4_output): | |
1383 | Use new functions instead of casting old functions unportably. | |
1384 | * src/state.c (state_hash_new): Likewise. | |
1385 | * src/symtab.c (symbols_new, symbols_do, symbols_check_defined, | |
1386 | symbols_token_translations_init): | |
1387 | Likewise. | |
1388 | * src/uniqstr.c (uniqstrs_new, hash_initialize, uniqstrs_do): Likewise. | |
1389 | ||
1390 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): Use long local | |
1391 | var instead of casting to long, to avoid casts. | |
1392 | (prepare_states): Use MALLOC rather than alloca, so that we don't | |
1393 | have to worry about alloca. | |
1394 | * src/state.c (state_hash_lookup): Likewise. | |
1395 | ||
1396 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>"'"): Use unsigned char | |
1397 | local var instead of casting to unsigned char, to avoid casts. | |
1398 | ||
1399 | * src/state.c (TRANSITIONS_ALLOC, ERRS_ALLOC, REDUCTIONS_ALLOC, | |
1400 | STATE_ALLOC): Remove. | |
1401 | (transitions_new, errs_new, reductions_new, state_new): Use malloc | |
1402 | rather than calloc, and use offsetof to avoid allocating slightly | |
1403 | too much storage. | |
1404 | (state_new): Initialize all members. | |
1405 | ||
1406 | * src/state.c (state_hash): Use unsigned accumulator, not signed. | |
1407 | ||
1408 | * src/symtab.c (symbol_free): Remove; unused. | |
1409 | (symbol_get): Remove cast in lhs of assignment. | |
1410 | (symbols_do): Now static. Accept generic arguments, not | |
1411 | hashing-related ones. | |
1412 | ||
1413 | * src/symtab.h: (NUMBER_UNDEFINED): Remove unnecessary cast. | |
1414 | (symbol_processor): Remove. | |
1415 | (symbols_do): Remove decl; now static. | |
1416 | ||
1417 | * src/system.h (alloca): Remove; decl no longer needed. | |
1418 | (<stddef.h>): Include, for offsetof. | |
1419 | (<inttypes.>, <stdint.h>): Include if available. | |
1420 | (uintptr_t): New type, if system lacks it. | |
1421 | (CALLOC, MALLOC, REALLOC): New macros. | |
1422 | All uses of XCALLOC, XMALLOC, and XREALLOC changed to use these | |
1423 | new macros. | |
1424 | ||
1425 | * src/tables.c (table_size): Now int, to pacify GCC. | |
1426 | (table_grow, table_ninf_remap): Use signed table size. | |
1427 | (save_row): Don't bother initializing locals when not needed. | |
1428 | (default_goto, goto_actions, pack_vector): Remove unnecessary casts. | |
1429 | * src/uniqstr.c (hash_compare_uniqstr): Likewise. | |
1430 | ||
1431 | * src/vcg.h: Correct misspellings. | |
1432 | ||
1433 | * src/vcg_defaults.h (G_CMAX): Now INT_MAX. | |
1434 | ||
1435 | ||
1436 | * src/getargs.c (getargs): Don't assume EOF == -1. | |
1437 | ||
1438 | 2002-12-09 Paul Eggert <eggert@twinsun.com> | |
1439 | ||
1440 | Change identifier spellings to avoid collisions with names | |
1441 | that are reserved by POSIX. | |
1442 | ||
1443 | Don't use names ending in _t, since POSIX reserves them. | |
1444 | For consistency, remove _e and _s endings -- they're weren't | |
1445 | needed to remove ambiguity. All uses changed. | |
1446 | * src/uniqstr.h (uniqstr): Renamed from uniqstr_t, which in | |
1447 | turn was just renamed from struniq_t. | |
1448 | * src/uniqstr.c (uniqstr_processor): Renamed from struniq_processor, | |
1449 | which in turn was just renamed from struniq_processor_t. | |
1450 | (hash_compare_uniqstr): Renamed from hash_compare_struniq, which | |
1451 | in turn was renamed from hash_compare_struniq_t. | |
1452 | * src/LR0.c (struct state_list): Renamed from struct state_list_s. | |
1453 | (state_list): Renamed from state_list_t. | |
1454 | * src/assoc.h (assoc): Renamed from assoc_t. | |
1455 | * src/conflicts.c (enum conflict_resolution): Renamed from | |
1456 | enum conflict_resolution_e. | |
1457 | * src/derives.c (struct rule_list): Renamed from struct rule_list_s. | |
1458 | (rule_list): Renamed from rule_list_t. | |
1459 | * src/getargs.h (enum trace): Renamed from enum trace_e. | |
1460 | (enum report): Renamed from enum report_e. | |
1461 | * src/gram.h (item_number): Renamed from item_number_t. | |
1462 | (rule_number): Renamed from rule_number_t. | |
1463 | (struct rule_s): Remove the "rule_s" part; not used. | |
1464 | (rule): Renamed from rule_t. | |
1465 | (rule_filter): Renamed from rule_filter_t. | |
1466 | * src/lalr.c (struct goto_list): Renamed from struct goto_list_s. | |
1467 | (goto_list): Renamed from goto_list_t. | |
1468 | * src/lalr.h (goto_number): Renamed from goto_number_t. | |
1469 | * src/location.h (location): Renamed from location_t. | |
1470 | * src/muscle_tab.c (muscle_entry): Renamed from muscle_entry_t, | |
1471 | and moved here from: | |
1472 | * src/muscle_tab.h (muscle_entry_t): here. | |
1473 | * src/nullable.c (struct rule_list): Renamed from struct rule_list_s. | |
1474 | (rule_list): Renamed from rule_list_t. | |
1475 | * src/print_graph.c (static_graph): Renamed from graph. | |
1476 | * src/reader.h (braced_code): Renamed from braced_code_t. | |
1477 | Remove brace_code_e tag. | |
1478 | * src/relation.h (relation_node): Renamed from relation_node_t. | |
1479 | (relation_nodes): Renamed from relation_nodes_t. | |
1480 | (relation): Renamed from relation_t. | |
1481 | * src/state.h (state_number): Renamed from state_number_t. | |
1482 | (struct state): Renamed from struct state_s. | |
1483 | (state): Renamed from state_t. | |
1484 | (transitions): Renamed from transitions_t. Unused (and | |
1485 | misspelled) transtion_s tag removed. | |
1486 | (errs): Renamed from errs_t. Unused errs_s tag removed. | |
1487 | (reductions): Renamed from reductions_t. Unused tag | |
1488 | reductions_s removed. | |
1489 | * src/symlist.h (symbol_list): Renamed from symbol_list_t. | |
1490 | (struct symbol_list): Renamed from struct symbol_list_s. | |
1491 | * src/symtab.h (symbol_number): Renamed from symbol_number_t. | |
1492 | (struct symbol): Renamed from struct symbol_s. | |
1493 | (symbol): Renamed from symbol_t. | |
1494 | * src/tables.c (vector_number): Renamed from vector_number_t. | |
1495 | (action_number): Renamed from action_t. | |
1496 | * src/tables.h (base_number): Renamed from base_t. | |
1497 | * src/vcg.h (enum color): Renamed from enum color_e. | |
1498 | (enum textmode): Renamed from enum textmode_e. | |
1499 | (enum shape): Renamed from enum shape_e. | |
1500 | (struct colorentry): Renamed from struct colorentry_s. | |
1501 | (struct classname): Renamed from struct classname_s. | |
1502 | (struct infoname): Renamed from struct infoname_s. | |
1503 | (enum layoutalgorithm): Renamed from enum layoutalgorithm_e. | |
1504 | (enum decision): Renamed from enum decision_e. | |
1505 | (enum orientation): Renamed from enum orientation_e. | |
1506 | (enum alignment): Renamed from enum alignment_e. | |
1507 | (enum arrow_mode): Renamed from enum arrow_mode_e. | |
1508 | (enum crossing_type): Renamed from enum crossing_type_e. | |
1509 | (enum view): Renamed from enum view_e. | |
1510 | (struct node): Renamed from struct node_s. | |
1511 | (node): Renamed from node_t. | |
1512 | (enum linestyle): Renamed from enum linestyle_e. | |
1513 | (enum arrowstyle): Renamed from enum arrowstyle_e. | |
1514 | (struct edge): Renamed from struct edge. | |
1515 | (edge): Renamed from edge_t. | |
1516 | (struct graph): Renamed from struct graph_s. | |
1517 | (graph): Renamed from graph_t. | |
1518 | * tests/calc.at (_AT_DATA_CALC_Y, Simple LALR Calculator): | |
1519 | Rename value_t -> value. | |
1520 | * tests/input.at (Torturing the Scanner): Rename value_t -> value, | |
1521 | value_t_as_yystype -> value_as_yystype. | |
1522 | ||
1523 | Don't include <errno.h> in the mainstream code, since it | |
1524 | reserves E[A-Z0-9]* and we want to use symbols like 'EQUALS'. | |
1525 | * lib/get-errno.c, lib/get-errno.h: New files. | |
1526 | * lib/Makefile.am (libbison_a_SOURCES): Add get-errno.h, | |
1527 | get-errno.c. | |
1528 | * src/files.c (xfopen, xfclose): Use get_errno instead of errno. | |
1529 | * src/output.c (output_skeleton): Likewise. | |
1530 | * src/scan-gram.l (<INITIAL>{int}): Use set_errno and get_errno | |
1531 | instead of errno. | |
1532 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>\\x[0-9abcdefABCDEF]+): | |
1533 | Likewise. | |
1534 | (handle_action_dollar, handle_action_at): Likewise. | |
1535 | * src/system.h: Do not include <errno.h>. | |
1536 | (TAB_EXT): Renamed from EXT_TAB. | |
1537 | (OUTPUT_EXT): Renamed from EXT_OUTPUT. | |
1538 | ||
1539 | Avoid str[a-z]*, since <string.h> reserves that name space. | |
1540 | Change all instances of "struniq" in names to "uniqstr", and | |
1541 | likewise for "STRUNIQ" and "UNIQSTR". | |
1542 | * src/uniqstr.c: Renamed from src/struniq.c. | |
1543 | * src/uniqstr.h: Renamed from src/struniq.h. | |
1544 | * src/Makefile.am (bison_SOURCES): Adjust to these renamings. | |
1545 | * src/files.c (strsuffix): Remove; unused. | |
1546 | (concat2): Renamed from stringappend. Now static. | |
1547 | * src/files.h (strsuffix, stringappend): Remove; unused. | |
1548 | * src/parse-gram.y (<chars>): Renamed from <string>. | |
1549 | (<uniqstr>): Renamed from <struniq>. | |
1550 | * src/scan-gram.l (obstack_for_string): Renamed from string_obstack. | |
1551 | * src/vcg.h (struct node_s.expand): Renamed from struct node_s.stretch. | |
1552 | (struct graph_s.expand): Renamed from struct graph_s.stretch. | |
1553 | * src/vcg_defaults.h (G_EXPAND): Renamed from G_STRETCH. | |
1554 | (G_LONG_STRAIGHT_PHASE): Renamed from G_STRAIGHT_PHASE. | |
1555 | (N_EXPAND): Renamed from N_STRETCH. | |
1556 | ||
1557 | Avoid *_MAX and *_MIN, since <limits.h> reserves that name space. | |
1558 | * data/yacc.c (YYSTACK_GAP_MAXIMUM): Renamed from YYSTACK_GAP_MAX. | |
1559 | * src/gram.h (ITEM_NUMBER_MAX, ITEM_NUMBER_MIN, RULE_NUMBER_MAX): | |
1560 | Remove; unused. | |
1561 | * src/lalr.h (GOTO_NUMBER_MAXIMUM): Renamed from GOTO_NUMBER_MAX. | |
1562 | * src/state.h (STATE_NUMBER_MAXIMUM): Renamed from STATE_NUMBER_MAX. | |
1563 | * src/symtab.h (SYMBOL_NUMBER_MAXIMUM): Renamed from SYMBOL_NUMBER_MAX. | |
1564 | * src/tables.c (VECTOR_NUMBER_MAX, VECTOR_NUMBER_MIN): Remove; unused. | |
1565 | (BASE_MAXIMUM): Renamed from BASE_MAX. | |
1566 | (BASE_MINIMUM): Renamed from BASE_MIN. | |
1567 | (ACTION_MAX): Remove; unused. | |
1568 | (ACTION_NUMBER_MINIMUM): Renamed from ACTION_MIN. | |
1569 | Unnecessary casts removed from above defines. | |
1570 | ||
1571 | ||
1572 | Fix misspelling in names. | |
1573 | * src/vcg.h (enum_alignment_e): Renamed from enum_alignement_e. | |
1574 | * src/vcg_defaults.h (G_NODE_ALIGNMENT): Renamed from | |
1575 | G_NODE_ALIGNEMENT. | |
1576 | ||
1577 | ||
1578 | * lib/timevar.c (timevar_report): Renamed from time_report, | |
1579 | for consistency with other names. | |
1580 | * lib/timevar.h (timevar_report): New decl. | |
1581 | * src/system.h (time_report): Remove; decl is now in lib/timevar.h. | |
1582 | ||
1583 | ||
1584 | Sort include-file uses. | |
1585 | ||
1586 | Reorder all include files under src to be in the order "system.h". | |
1587 | then the ../lib include files in angle brackets (alphabetized), | |
1588 | then the . include files in double-quotes (alphabetized). Fix | |
1589 | dependency breakages encountered in this process, as follows: | |
1590 | * src/closure.h, src/derives.h, src/state.h: Include "gram.h". | |
1591 | * src/complain.c: Don't include stdlib.h, string.h _LIBC stuff. | |
1592 | * src/state.h: Include "symtab.h". | |
1593 | ||
1594 | 2002-12-08 Paul Eggert <eggert@twinsun.com> | |
1595 | ||
1596 | * data/glr.c, data/lalr1.cc, data/yacc.c: Do not use __file__, | |
1597 | since this causes problems when __file__ contains character | |
1598 | sequences like "@" that are treated specially by src/scan-skel.l. | |
1599 | Instead, just use the file's basename. This fixes the bug | |
1600 | reported by Martin Mokrejs in | |
1601 | <http://mail.gnu.org/archive/html/bug-bison/2002-12/msg00007.html>. | |
1602 | ||
1603 | 2002-12-06 Paul Eggert <eggert@twinsun.com> | |
1604 | ||
1605 | Add support for rules that do not have trailing semicolons, as | |
1606 | POSIX requires. Improve the quality of locations in Bison | |
1607 | diagnostics. | |
1608 | ||
1609 | * src/location.c: Include <quotearg.h>. | |
1610 | (empty_location): Now const. | |
1611 | (location_print): New function. Follow the recommendation of the | |
1612 | GNU Coding Standards for locations that span file boundaries. | |
1613 | * src/location.h: Do not include <quotearg.h>; no longer needed. | |
1614 | (boundary): New type. | |
1615 | (location_t): Use it. This allows locations to span file boundaries. | |
1616 | All member uses changed: file -> start.file or end.file (as needed), | |
1617 | first_line -> start.line, first_column -> start.column, | |
1618 | last_line -> end.line, last_column -> end.column. | |
1619 | (equal_boundaries): New function. | |
1620 | (LOCATION_RESET, LOCATION_STEP): Remove. | |
1621 | (LOCATION_PRINT): Remove. All callers changed to use location_print. | |
1622 | (empty_location): Now const. | |
1623 | (location_print): New decl. | |
1624 | * src/parse-gram.y (lloc_default): New function, which handles | |
1625 | empty locations more accurately. | |
1626 | (YYLLOC_DEFAULT): Use it. | |
1627 | (%token COLON): Remove. | |
1628 | (%token ID_COLON): New token. | |
1629 | (rules): Use it. | |
1630 | (declarations, rules): Remove trailing semicolon. | |
1631 | (declaration, rules_or_grammar_declaration): | |
1632 | Allow empty (";") declaration. | |
1633 | (symbol_def): Remove empty actions; no longer needed. | |
1634 | (rules_or_grammar_declaration): Remove trailing semicolon. | |
1635 | (semi_colon.opt): Remove. | |
1636 | * src/reader.h: Include location.h. | |
1637 | (scanner_cursor): New decl. | |
1638 | * src/reduce.c (nonterminals_reduce): Use warn_at rather than | |
1639 | rolling our own. | |
1640 | * src/scan-gram.l (YY_USER_INIT): Initialize scanner_cursor instead | |
1641 | of *loc. | |
1642 | (STEP): Remove. No longer needed, now that adjust_location does | |
1643 | the work. All uses removed. | |
1644 | (scanner_cursor): New var. | |
1645 | (adjust_location): Renamed from extend_location. It now sets | |
1646 | *loc and adjusts the scanner cursor. All uses changed. | |
1647 | Don't bother testing for CR. | |
1648 | (handle_syncline): Remove location arg; now updates scanner cursor. | |
1649 | All callers changed. | |
1650 | (unexpected_end_of_file): Now accepts start boundary of token or | |
1651 | comment, not location. All callers changed. Update scanner cursor, | |
1652 | not the location. | |
1653 | (SC_AFTER_IDENTIFIER): New state. | |
1654 | (context_state): Renamed from c_context. All uses changed. | |
1655 | (id_loc, code_start, token_start): New local vars. | |
1656 | (<INITIAL,SC_AFTER_IDENTIFIER>): New initial context. Move all | |
1657 | processing of Yacc white space and equivalents here. | |
1658 | (<INITIAL>{id}): Save id_loc. Begin state SC_AFTER_IDENTIFIER | |
1659 | instead of returning ID immediately, since we need to search for | |
1660 | a subsequent colon. | |
1661 | (<INITIAL>"'", "\""): Save token_start. | |
1662 | (<INITIAL>"%{", "{", "%%"): Save code_start. | |
1663 | (<SC_AFTER_IDENTIFIER>): New state, looking for a colon. | |
1664 | (<SC_YACC_COMMENT>, <SC_COMMENT>, <SC_LINE_COMMENT>): | |
1665 | BEGIN context_state at end, not INITIAL. | |
1666 | (<SC_ESCAPED_STRING>"\"", <SC_ESCAPED_CHARACTER>"'", | |
1667 | <SC_BRACED_CODE>"}", <SC_PROLOGUE>"%}", <SC_EPILOGUE><<EOF>>): | |
1668 | Return correct token start. | |
1669 | (<SC_BRACED_CODE,SC_PROLOGUE,SC_EPILOGUE>): Save start boundary when | |
1670 | the start of a character, string or multiline comment is found. | |
1671 | * tests/conflicts.at (S/R in initial, Defaulted Conflicted | |
1672 | Reduction): Adjust reported locations to match the more-precise | |
1673 | results now expected. | |
1674 | * tests/input.at (Invalid $n, Invalid @n, Type Clashes): Likewise. | |
1675 | * tests/reduce.at (Useless Rules, Reduced Automaton, | |
1676 | Underivable Rules): Likewise. | |
1677 | * tests/regression.at (Invalid inputs): No longer `expecting ";" | |
1678 | or "|"' now that so many other tokens are allowed by the new grammar. | |
1679 | ||
1680 | * src/complain.h (current_file): Remove duplicate decl; | |
1681 | current_file is now owned by files.h. | |
1682 | * src/complain.c, src/scan-gram.l: Include files.h. | |
1683 | ||
1684 | 2002-12-06 Paul Eggert <eggert@twinsun.com> | |
1685 | ||
1686 | * data/glr.c (yy_reduce_print): Don't assume that yyrline[yyrule] | |
1687 | promotes to int; it might be unsigned int. | |
1688 | * data/yacc.c (yy_reduce_print): Likewise. | |
1689 | ||
1690 | * doc/bison.texinfo (Table of Symbols): YYERROR_VERBOSE should | |
1691 | be #defined in the prologue, not in the Bison declarations. | |
1692 | This fixes Debian Bug 102878, reported by Shaul Karl. | |
1693 | ||
1694 | 2002-12-02 Paul Eggert <eggert@twinsun.com> | |
1695 | ||
1696 | * configure.ac (AC_REPLACE_FUNCS): Add strtoul. | |
1697 | * lib/strtoul.c: New file, from gnulib. | |
1698 | This fixes a porting bug reported by Peter Klein in | |
1699 | <http://mail.gnu.org/archive/html/bug-bison/2002-12/msg00000.html>. | |
1700 | ||
1701 | 2002-11-30 Paul Eggert <eggert@twinsun.com> | |
1702 | ||
1703 | * src/scan-gram.l (no_cr_read, extend_location): Move to epilogue, | |
1704 | and put only a forward declaration in the prologue. This is for | |
1705 | consistency with the other scanner helper functions. | |
1706 | ||
1707 | Type clashes now generate warnings, not errors, since it | |
1708 | appears that POSIX may allow some grammars with type clashes. | |
1709 | * src/reader.c (grammar_current_rule_check): Warn about | |
1710 | type clashes instead of complaining. | |
1711 | * tests/input.at (Type Clashes): Expect warnings, not complaints. | |
1712 | ||
1713 | Add Yacc library, since POSIX requires it. | |
1714 | * doc/bison.texinfo (Yacc Library): New node. Regenerate top menu. | |
1715 | * lib/Makefile.am (lib_LIBRARIES, liby_a_SOURCES): New macros. | |
1716 | * lib/main.c, lib/yyerror.c: New files. | |
1717 | ||
1718 | gram_error can be static; it need not be extern. | |
1719 | * src/reader.h (gram_error): Remove decl. | |
1720 | * src/parse-gram.y (gram_error): Now static. Add static decl. | |
1721 | (print_token_value): Omit parameter names from forward decl, | |
1722 | for consistency. | |
1723 | ||
1724 | 2002-11-29 Paul Eggert <eggert@twinsun.com> | |
1725 | ||
1726 | * doc/bison.texinfo: Emphasize that yylex and yyerror must | |
1727 | be declared before being used. E.g., one should typically | |
1728 | declare them in the prologue. Use GNU coding style in examples. | |
1729 | Put "const" consistently after the type it modifies. Mention | |
1730 | that C99 supports "inline". Mention that yyerror traditionally | |
1731 | returns "int". | |
1732 | ||
1733 | %parse-param and %lex-param now take just one argument, the | |
1734 | declaration; the argument name is deduced from the declaration. | |
1735 | ||
1736 | * doc/bison.texinfo (Parser Function, Pure Calling, Error | |
1737 | Reporting, Table of Symbols): Document this. | |
1738 | * src/parse-gram.y (add_param): New function. | |
1739 | (COMMA): Remove. | |
1740 | (declaration): Implement new rule for %parse-param and %lex-param. | |
1741 | * src/scan-gram.l: "," now elicits a warning, rather than being | |
1742 | a token; this is more compatible with byacc. | |
1743 | * tests/calc.at (Simple LALR Calculator): Adopt new convention. | |
1744 | ||
1745 | 2002-11-27 Paul Eggert <eggert@twinsun.com> | |
1746 | ||
1747 | Rename identifiers to avoid real and potential collisions. | |
1748 | ||
1749 | * data/c.m4 (b4_yysymprint_generate): yyout -> yyoutput, | |
1750 | to avoid collision with lex macro described by Bruce Lilly in | |
1751 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00114.html>. | |
1752 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise. | |
1753 | * doc/bison.texinfo (Prologue, Tracing): yyprint -> print_token_value. | |
1754 | * src/parse-gram.y (print_token_value): Renamed from yyprint. | |
1755 | All uses changed. | |
1756 | (YYPARSE_PARAM, YYLEX_PARAM, yycontrol): Remove. All uses changed. | |
1757 | The name "yycontrol" violates the name space rules, and this stuff | |
1758 | wasn't being used anyway. | |
1759 | (input): Remove action; this stuff wasn't being used. | |
1760 | (gram_error): Rename local variable yylloc -> loc. | |
1761 | * src/reader.h (struct gram_control_s, gram_control_t): Remove. | |
1762 | (YY_DECL): Don't use "yy" at start of local variables. | |
1763 | All uses changed, e.g., yylloc -> loc. | |
1764 | * src/scan-gram.l (STEP): Renamed from YY_STEP. All uses changed. | |
1765 | (STRING_GROW): Renamed from YY_OBS_GROW. All uses changed. | |
1766 | (STRING_FINISH): Renamed from YY_OBS_FINISH. All uses changed. | |
1767 | (STRING_FREE): Renamed from YY_OBS_FREE. All uses changed. | |
1768 | ||
1769 | * src/parse-gram.y (gram_error): loc is now const *. | |
1770 | * src/reader.h (gram_error): Likewise. | |
1771 | ||
1772 | 2002-11-24 Paul Eggert <eggert@twinsun.com> | |
1773 | ||
1774 | Version 1.75c. | |
1775 | ||
1776 | * tests/actions.at (Actions after errors): Use an output format | |
1777 | more similar to that of the Printers and Destructors test. | |
1778 | Test the position of the ';' token too. | |
1779 | (Printers and Destructors): Likewise. | |
1780 | (Printers and Destructors: %glr-parser): Remove for now, to avoid | |
1781 | unnecessarily alarming people when the test fails. | |
1782 | ||
1783 | * data/yacc.c (yyerrlab1): Move this label down, so that the | |
1784 | parser does not discard the lookahead token if the user code | |
1785 | invokes YYERROR. This change is required for POSIX conformance. | |
1786 | ||
1787 | * lib/error.c: Sync with gnulib. | |
1788 | ||
1789 | 2002-11-22 Paul Eggert <eggert@twinsun.com> | |
1790 | ||
1791 | * lib/quotearg.c, lib/quotearg.h: Sync with gnulib. | |
1792 | * lib/mbswidth.c, lib/mbswidth.h: Likewise. | |
1793 | * lib/xmalloc.c: Likewise. | |
1794 | ||
1795 | 2002-11-20 Paul Eggert <eggert@twinsun.com> | |
1796 | ||
1797 | * lib/argmatch.c, lib/argmatch.h: Sync with gnulib. | |
1798 | ||
1799 | 2002-11-20 Paul Eggert <eggert@twinsun.com> | |
1800 | ||
1801 | Avoid use of <assert.h>, as the GNU Coding Standards hint that one | |
1802 | should use `if (! x) abort ();' rather than `assert (x);', and | |
1803 | anyway it's one less thing to worry about configuring. | |
1804 | ||
1805 | * data/glr.c, lib/hash.c, src/system.h: Do not include <assert.h>. | |
1806 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Likewise, | |
1807 | and replace all instances of assert with abort. | |
1808 | * tests/calc.at (_AT_DATA_CALC_Y): Likewise. | |
1809 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Likewise. | |
1810 | ||
1811 | * data/glr.c (yydoAction, yyglrReduce, yysplitStack, yyresolveStates, | |
1812 | yyresolveAction, yyprocessOneStack): Use abort rather than assert. | |
1813 | * lib/hash.c (hash_lookup, hash_get_first, hash_get_next, | |
1814 | hash_find_entry, hash_rehash, hash_insert): Likewise. | |
1815 | * src/conflicts.c (resolve_sr_conflict): Likewise. | |
1816 | * src/lalr.c (set_goto_map, map_goto): Likewise. | |
1817 | * src/nullable.c (nullable_compute): Likewise. | |
1818 | * src/output.c (prepare_rules, token_definitions_output): Likewise. | |
1819 | * src/reader.c (packgram, reader): Likewise. | |
1820 | * src/state.c (state_new, state_free, state_transitions_set, | |
1821 | state_reduction_find): Likewise. | |
1822 | * src/symtab.c (symbol_user_token_number_set, symbol_make_alias, | |
1823 | symbol_pack): Likewise. | |
1824 | * src/tables.c (conflict_row, pack_vector): Likewise. | |
1825 | * src/vcg.c (get_color_str, get_textmode_str, get_shape_str, | |
1826 | get_layoutalgorithm_str, get_decision_str, get_orientation_str, | |
1827 | get_node_alignement_str, get_arrow_mode_str, get_crossing_type_str, | |
1828 | get_view_str, get_linestyle_str, get_arrowstyle_str): Likewise. | |
1829 | ||
1830 | * lib/argmatch.h (ARRAY_CARDINALITY): Do not bother to #undef. | |
1831 | (ARGMATCH_CONSTRAINT): New macro. | |
1832 | (ARGMATCH_ASSERT): Use it. | |
1833 | ||
1834 | * src/system.h (verify): New macro. | |
1835 | * src/getargs.c (trace_argmatch, report_argmatch): Use verify | |
1836 | rather than assert. | |
1837 | * src/tables.c (tables_generate): Likewise. | |
1838 | ||
1839 | * src/struniq.c (struniq_assert): Now returns void, and aborts | |
1840 | if the assertion is false. | |
1841 | (struniq_assert_p): Remove. | |
1842 | * src/struniq.h: Likewise. | |
1843 | ||
1844 | 2002-11-18 Paul Eggert <eggert@twinsun.com> | |
1845 | ||
1846 | * data/glr.c (yygetLRActions): Replace `yyindex' with | |
1847 | `yytable[yyindex]' to fix typo introduced in my 2002-11-09 patch. | |
1848 | This fixes the regression with Sun ONE Studio 7 cc that I reported in | |
1849 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00077.html>. | |
1850 | ||
1851 | 2002-11-18 Akim Demaille <akim@epita.fr> | |
1852 | ||
1853 | * doc/bison.texinfo (Tracing): `yyprint' shouldn't prepend a | |
1854 | space. | |
1855 | From Tim Van Holder. | |
1856 | ||
1857 | 2002-11-17 Paul Eggert <eggert@twinsun.com> | |
1858 | ||
1859 | Pacify Sun ONE Studio 7 lint. Also, rename "ParseError" | |
1860 | to "SyntaxError" for consistency with my 2002-11-15 change. | |
1861 | ||
1862 | * data/glr.c (YYDPRINTF, YYDSYMPRINT, YYDSYMPRINTF) [!YYDEBUG]: Do | |
1863 | not define to {}, since this breaks the common use of `YYDPRINTF | |
1864 | ((...));' if a single statement is desired (e.g. before `else'). | |
1865 | Work around GCC warnings by surrounding corresponding calls with | |
1866 | {} if needed. | |
1867 | (yyhasResolvedValue): Remove unused function. | |
1868 | (yymergeOptionSets, yyresolvStack): Use `continue;' for empty | |
1869 | loop body. | |
1870 | (yyreportSyntaxError): Renamed from yyreportParseError. | |
1871 | (yyrecoverSyntaxError): Renamed from yyrecoverParseError. | |
1872 | All uses changed. | |
1873 | * tests/calc.at (_AT_DATA_CALC_Y): Make vars static instead of | |
1874 | extern when possible. Remove unused initializations. | |
1875 | ||
1876 | 2002-11-16 Akim Demaille <akim@epita.fr> | |
1877 | ||
1878 | Augment the similarity between GLR and LALR traces. | |
1879 | ||
1880 | * data/yacc.c (yy_stack_print, YY_STACK_PRINT, yy_reduce_print) | |
1881 | (YY_REDUCE_PRINT): New. | |
1882 | (yyparse): Use them. | |
1883 | * data/glr.c (yy_reduce_print): Use YYFPRINTF, no need for | |
1884 | YYDPRINT here. | |
1885 | (yyglrReduce, yyrecoverParseError, yyparse): Don't report the | |
1886 | state reached after the reduction/recovery, since... | |
1887 | (yyparse, yyprocessOneStack): Report the state we are entering in. | |
1888 | ||
1889 | 2002-11-16 Akim Demaille <akim@epita.fr> | |
1890 | ||
1891 | * src/getargs.h, src/getargs.c (trace_e, trace_args, trace_types): | |
1892 | Add support for --trace=skeleton. | |
1893 | * src/scan-skel.l: %option debug. | |
1894 | Scan strings of non-@ or \n instead of character by character. | |
1895 | (scan_skel): Handle trace_skeleton. | |
1896 | (QPUTS): New. | |
1897 | (@output_parser_name@, @output_header_name@): ``Restore'' their | |
1898 | support (used to be M4 macros). | |
1899 | * data/yacc.c: Quote larger chunks, a la glr.c. | |
1900 | * data/lalr1.cc: Likewise. | |
1901 | The header guards are no longer available, so use some other | |
1902 | string than `YYLSP_NEEDED'. | |
1903 | ||
1904 | 2002-11-16 Akim Demaille <akim@epita.fr> | |
1905 | ||
1906 | Make the ``Printers and Destructors'' test more verbose, taking | |
1907 | `yacc.c''s behavior as (possibly wrong) reference. | |
1908 | ||
1909 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Use printf | |
1910 | instead of fprint on stdout. | |
1911 | Set and report the last_line of the symbols. | |
1912 | Consistently display values and locations. | |
1913 | ||
1914 | 2002-11-16 Paul Eggert <eggert@twinsun.com> | |
1915 | ||
1916 | * data/yacc.c: Avoid over-quoting of __line__ and __file__. | |
1917 | ||
1918 | 2002-11-15 Paul Eggert <eggert@twinsun.com> | |
1919 | ||
1920 | * tests/actions.at (Actions after errors): New test case. | |
1921 | ||
1922 | * data/glr.c, data/lalr1.cc, data/yacc.cc, doc/bison.texinfo, | |
1923 | src/conflicts.c, src/parse-gram.y, src/tables.c, src/tables.h, | |
1924 | tests/action.at, tests/calc.at, tests/conflicts.at, | |
1925 | tests/cxx-type.at, tests/regression.at: | |
1926 | "parse error" -> "syntax error" for POSIX compatibility. | |
1927 | "parsing stack overflow..." -> "parser stack overflow" so | |
1928 | that code matches Bison documentation. | |
1929 | ||
1930 | 2002-11-15 Akim Demaille <akim@epita.fr> | |
1931 | ||
1932 | * src/parse-gram.y (declaration): Have %parse-param and %lex-param | |
1933 | take two BRACED_CODE, not two string_content. | |
1934 | Free the scanner's obstack when we are done. | |
1935 | (code_content): New. | |
1936 | * tests/calc.at: Adjust. | |
1937 | * doc/bison.texinfo: Adjust. | |
1938 | Also, make sure to include the `,' for these declarations. | |
1939 | ||
1940 | 2002-11-15 Tim Van Holder <tim.van.holder@pandora.be> | |
1941 | ||
1942 | * m4/prereq.m4: Removed the commented jm_PREREQ_HASH | |
1943 | definition; avoids potential autoreconf problems. | |
1944 | ||
1945 | 2002-11-15 Akim Demaille <akim@epita.fr> | |
1946 | ||
1947 | Always check the value returned by yyparse. | |
1948 | ||
1949 | * tests/calc.at (_AT_DATA_CALC_Y): Have `main' exit with the value | |
1950 | returned by yyparse. | |
1951 | (_AT_CHECK_CALC_ERROR): Take the expected exit value as argument. | |
1952 | Adjust calls. | |
1953 | * tests/glr-regr1.at (glr-regr1.y): Have `main' exit with the value | |
1954 | returned by yyparse. | |
1955 | ||
1956 | 2002-11-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
1957 | ||
1958 | * data/glr.c (yyFail): Always set yyerrflag. Corrects regression | |
1959 | on input.at test. | |
1960 | ||
1961 | 2002-11-14 Paul Eggert <eggert@twinsun.com> | |
1962 | ||
1963 | * src/output.c (output_skeleton): Call xfopen instead of | |
1964 | duplicating xfopen's body. | |
1965 | ||
1966 | Fix bugs reported by Nelson H. F. Beebe in | |
1967 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00078.html>. | |
1968 | ||
1969 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Don't assume that | |
1970 | "$CC -E foo.h" is allowed, as this doesn't work with the Portland | |
1971 | Group compiler. Instead, use "$CC -E bar.c". Include the .h | |
1972 | file twice in the grammar, as an extra check. | |
1973 | ||
1974 | * tests/input.at (Torturing the Scanner): Surround the | |
1975 | backslash-newline tests with "#if 0", to make it less likely that | |
1976 | we'll run into compiler bugs. Bring back solitary \ inside | |
1977 | comment, but add a closing comment to work around HP C bug. Don't | |
1978 | test backslash-newline in C character constant. | |
1979 | ||
1980 | 2002-11-14 Akim Demaille <akim@epita.fr> | |
1981 | ||
1982 | * tests/synclines.at (AT_SYNCLINES_COMPILE): Ignore the exit | |
1983 | status of the compiler. | |
1984 | Calling `exit 1' is no longer needed. | |
1985 | Reported by Nelson H. F. Beebe. | |
1986 | ||
1987 | 2002-11-14 Akim Demaille <akim@epita.fr> | |
1988 | ||
1989 | * tests/atlocal.in (CPPFLAGS): We have config.h. | |
1990 | * tests/testsuite.at (AT_DATA_GRAMMAR_PROLOGUE, AT_DATA_GRAMMAR): | |
1991 | New. | |
1992 | * tests/actions.at, tests/calc.at, tests/conflicts.at, | |
1993 | * tests/cxx-type.at, tests/glr-regr1.at, tests/headers.at, | |
1994 | * tests/regression.at, tests/torture.at: Use them for all the | |
1995 | grammars that are to be compiled. | |
1996 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Rename as... | |
1997 | * tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): this. | |
1998 | * doc/bison.texinfo (GLR Parsers): Document `inline'. | |
1999 | ||
2000 | 2002-11-14 Akim Demaille <akim@epita.fr> | |
2001 | ||
2002 | * doc/bison.texinfo: Various formatting changes (alignments in | |
2003 | samples, additional @group/@end group, GCS in samples. | |
2004 | Use @deffn instead of simple @table to define the directives, | |
2005 | macros, variables etc. | |
2006 | ||
2007 | 2002-11-13 Paul Eggert <eggert@twinsun.com> | |
2008 | ||
2009 | Fix some bugs reported by Albert Chin-A-Young in | |
2010 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00066.html>. | |
2011 | ||
2012 | * tests/input.at (Torturing the Scanner): Don't invoke "cc a.c b.c | |
2013 | -o c"; the HP C compiler chatters during compilation. | |
2014 | Instead, invoke "cc -c a.c -o a.o; cc -c b.c -o b.o; cc a.o b.o -o c". | |
2015 | * tests/headers.at (export YYLTYPE): Likewise. | |
2016 | ||
2017 | * tests/input.at (Torturing the Scanner): Remove lines containing | |
2018 | solitary backslashes, as they tickle a bug in the HP C compiler. | |
2019 | ||
2020 | * tests/glr-regr1.at (Badly Collapsed GLR States): Avoid // | |
2021 | comments, since they're not portable. Use GNU coding style. | |
2022 | ||
2023 | 2002-11-13 Akim Demaille <akim@epita.fr> | |
2024 | ||
2025 | * data/yacc.c: Leave bigger chunks of quoted text. | |
2026 | (YYDSYMPRINTF): New. | |
2027 | Use it to report symbol activities. | |
2028 | * data/glr.c (YYDSYMPRINTF): New. | |
2029 | Use it. | |
2030 | ||
2031 | 2002-11-12 Paul Eggert <eggert@twinsun.com> | |
2032 | ||
2033 | Version 1.75b. | |
2034 | ||
2035 | * data/glr.c (yydoAction): Return YYRESULTTAG, not int. | |
2036 | (yyglrReduce): Return yyok, not 0. | |
2037 | This should avoid the enumerated-type warnings reported | |
2038 | by Nelson H. F. Beebe in | |
2039 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00057.html>. | |
2040 | ||
2041 | * lib/bbitset.h (BITSET_INLINE): Remove. | |
2042 | * lib/bitset.h [! BITSET_INLINE]: Remove. | |
2043 | (bitset_set, bitset_reset, bitset_test): Rename local vars | |
2044 | to avoid shadowing warnings by GCC. | |
2045 | ||
2046 | * data/glr.c (inline): Remove #define. It's the user's | |
2047 | responsibility to #define it away, just like 'const'. | |
2048 | This fixes one of the bugs reported by Nelson H. F. Beebe in | |
2049 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00058.html>. | |
2050 | ||
2051 | * Makefile.maint (po-check): Scan .l and .y files instead of the | |
2052 | .c and the .h files that they generate. This fixes the bug | |
2053 | reported by Tim Van Holder in: | |
2054 | <http://mail.gnu.org/archive/html/bison-patches/2002-11/msg00062.html> | |
2055 | Look for N_ as well as for _. Try to avoid matching #define for | |
2056 | N_ and _. | |
2057 | * po/POTFILES.in: Remove src/parse-gram.c, src/scan-gram.c, | |
2058 | src/system.h. Add src/parse-gram.y, src/scan-gram.l. | |
2059 | * src/scan-gram.l: Revamp regular expressions so that " and ' | |
2060 | do not confuse xgettext. | |
2061 | ||
2062 | * src/struniq.h (struniq_new): Do not declare the return type | |
2063 | to be 'const'; this violates the C standard. | |
2064 | * src/struniq.c (struniq_new): Likewise. | |
2065 | ||
2066 | 2002-11-12 Albert Chin-A-Young <china@thewrittenword.com> | |
2067 | ||
2068 | * src/Makefile.am (LDADD): Link $(LIBINTL) last to avoid the | |
2069 | duplicate definition of optind on Tru64 UNIX 4.0D with the Compaq | |
2070 | linker. | |
2071 | ||
2072 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2073 | ||
2074 | * Makefile.maint: Sync with Autoconf: | |
2075 | (local_updates): New. | |
2076 | ||
2077 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2078 | ||
2079 | * po/POTFILES.in (src/lalr.c, src/state.c): Remove | |
2080 | ||
2081 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2082 | ||
2083 | * tests/actions.at (_AT_CHECK_PRINTER_AND_DESTRUCTOR): Display the | |
2084 | locations. | |
2085 | ||
2086 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2087 | ||
2088 | * data/c.m4 (b4_yysymprint_generate): Pass *yyvaluep to YYPRINT, | |
2089 | not yyvalue. | |
2090 | ||
2091 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2092 | ||
2093 | * tests/actions.at (AT_CHECK_PRINTER_AND_DESTRUCTOR): New. | |
2094 | Use it to test the GLR parser. | |
2095 | ||
2096 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2097 | ||
2098 | * tests/regression.at (input.y): s/YYEOF/MYEOF/, as the skeleton | |
2099 | defines it. | |
2100 | * data/glr.c (yystos): New. | |
2101 | (b4_yysymprint_generate, b4_yydestruct_generate): Invoke. | |
2102 | (YYDSYMPRINT): New. | |
2103 | (yyval): Don't define it, it is handled via M4. | |
2104 | (yyrecoverParseError): Free verbosely the discarded symbols. | |
2105 | * data/yacc.c (yysymprint): Remove, rather... | |
2106 | (b4_yysymprint_generate): invoke. | |
2107 | * data/c.m4 (b4_yysymprint_generate): New. | |
2108 | Accept pointers as arguments, as opposed to the version from | |
2109 | yacc.c. | |
2110 | (b4_yydestruct_generate): Likewise. | |
2111 | * tests/cations.at (Printers and Destructors): Use Bison directives | |
2112 | instead of CPP macros. | |
2113 | Don't rely on internal details. | |
2114 | ||
2115 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2116 | ||
2117 | * data/c.m4 (b4_yydestruct_generate, b4_symbol_actions): New. | |
2118 | * data/yacc.c: Rename yychar1 as yytoken, as in glr.c. | |
2119 | Don't work on yychar (i.e., do set it to YYEMPTY, don't match | |
2120 | it against YYEMPTY and so forth), work on yytoken (i.e., set | |
2121 | it to YYEMPTY etc.). | |
2122 | (yydestruct): Replace with a b4_yydestruct_generate invocation. | |
2123 | (b4_symbol_actions): Remove. | |
2124 | * data/glr.c (YYTRANSLATE): As for yacc.c, if negative, it stands | |
2125 | for 0, end-of-input. | |
2126 | ||
2127 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2128 | ||
2129 | * doc/bison.texinfo (Destructor Decl): New. | |
2130 | ||
2131 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2132 | ||
2133 | * src/tables.c (tables_generate): Use free for pointers that | |
2134 | cannot be NULL, not XFREE. | |
2135 | (pack_vector): Use assert, not fatal, for bound violations. | |
2136 | * src/state.c (state_new): Likewise. | |
2137 | * src/reader.c (reader): Likewise. | |
2138 | * src/lalr.c (set_goto_map): Likewise. | |
2139 | * src/location.h (LOCATION_PRINT): If first_line is 0, just issue | |
2140 | the file name. | |
2141 | ||
2142 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2143 | ||
2144 | * src/scan-gram.l, src/reader.h (scanner_last_string_free): | |
2145 | Restore. | |
2146 | * src/scan-gram.l (last_string): Is global to the file, not to | |
2147 | yylex. | |
2148 | * src/parse-gram.y (input): Don't append the epilogue here, | |
2149 | (epilogue.opt): do it here, and free the scanner's obstack. | |
2150 | * src/reader.c (epilogue_set): Rename as... | |
2151 | (epilogue_augment): this. | |
2152 | * data/c.m4 (b4_epilogue): Defaults to empty. | |
2153 | ||
2154 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2155 | ||
2156 | * src/getargs.c (long_options): Remove duplicates. | |
2157 | * src/vmsgetargs.c, src/build.com, src/bison.cld, src/vmshlp.mar: | |
2158 | Remove. | |
2159 | * doc/bison.rnh: Remove. | |
2160 | * doc/bison.texinfo (VMS Invocation): Remove. | |
2161 | ||
2162 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2163 | ||
2164 | * src/struniq.h, src/struniq.c (struniq_t): Is const. | |
2165 | (STRUNIQ_EQ, struniq_assert, struniq_assert_p): New. | |
2166 | ||
2167 | Use struniq for symbols. | |
2168 | ||
2169 | * src/symtab.h (symbol_t): The tag member is a struniq. | |
2170 | (symbol_type_set): Adjust. | |
2171 | * src/symtab.c (symbol_new): Takes a struniq. | |
2172 | (symbol_free): Don't free the tag member. | |
2173 | (hash_compare_symbol_t, hash_symbol_t): Rename as... | |
2174 | (hash_compare_symbol, hash_symbol): these. | |
2175 | Use the fact that tags as struniqs. | |
2176 | (symbol_get): Use struniq_new. | |
2177 | * src/symlist.h, src/symlist.c (symbol_list_n_type_name_get): | |
2178 | Returns a strniq. | |
2179 | * src/reader.h (merger_list, grammar_currentmerge_set): The name | |
2180 | and type members are struniqs. | |
2181 | * src/reader.c (get_merge_function) | |
2182 | (grammar_current_rule_merge_set): Adjust. | |
2183 | (TYPE, current_type): Are struniq. | |
2184 | ||
2185 | Use struniq for file names. | |
2186 | ||
2187 | * src/files.h, src/files.c (infile): Split into... | |
2188 | (grammar_file, current_file): these. | |
2189 | * src/scan-gram.c (YY_USER_INIT, handle_syncline): Adjust. | |
2190 | * src/reduce.c (reduce_print): Likewise. | |
2191 | * src/getargs.c (getargs): Likewise. | |
2192 | * src/complain.h, src/complain.c: Likewise. | |
2193 | * src/main.c (main): Call struniqs_new early enough to use it for | |
2194 | file names. | |
2195 | Don't free the input file name. | |
2196 | ||
2197 | 2002-11-12 Akim Demaille <akim@epita.fr> | |
2198 | ||
2199 | * src/symtab.c (symbol_free): Remove dead deactivated code: | |
2200 | type_name are properly removed. | |
2201 | Don't use XFREE to free items that cannot be NULL. | |
2202 | * src/struniq.h, src/struniq.c: New. | |
2203 | * src/main.c (main): Initialize/free struniqs. | |
2204 | * src/parse-gram.y (%union): Add astruniq member. | |
2205 | (yyprint): Adjust. | |
2206 | * src/scan-gram.l (<{tag}>): Return a struniq. | |
2207 | Free the obstack bit that used to store it. | |
2208 | * src/symtab.h (symbol_t): The 'type_name' member is a struniq. | |
2209 | ||
2210 | 2002-11-11 Paul Eggert <eggert@twinsun.com> | |
2211 | ||
2212 | Revamp to fix many (but not all) of the C- and M4-related quoting | |
2213 | problems. Among other things, this fixes the Bison bug reported | |
2214 | by Jan Hubicka when processing the Bash grammar; see: | |
2215 | <http://mail.gnu.org/archive/html/bison-patches/2002-11/msg00039.html> | |
2216 | ||
2217 | Use new @ escapes consistently. Represent brackets with @{ and @} | |
2218 | rather than @<:@ and @:>@, since this works a bit better with dumb | |
2219 | editors like vi. Represent @ with @@, since @ is now consistently | |
2220 | an escape. Use @oline@ and @ofile@ rather than __oline__ and | |
2221 | __ofile__, to avoid unexpected expansions. Similarly, use @output | |
2222 | rather than #output. | |
2223 | ||
2224 | * data/c.m4 (b4_copyright): Omit file name from comment, since | |
2225 | the file name could contain "*/". | |
2226 | (b4_synclines_flag): Don't quote the 2nd argument; it should already | |
2227 | be quoted. All uses changed. | |
2228 | ||
2229 | * data/glr.c: Use new @ escapes consistently. | |
2230 | (b4_input_suffix, b4_output_parser_suffix, b4_output_parser_name, | |
2231 | b4_output_header_suffix, b4_output_header_name, b4_header_guard): | |
2232 | Remove, since they couldn't handle arbitrary characters in file | |
2233 | names. | |
2234 | * data/lalr1.cc: Likewise. | |
2235 | * data/yacc.c: Likewise. | |
2236 | ||
2237 | * src/files.c (output_infix): Remove; all uses removed. | |
2238 | * src/files.h: Likewise. | |
2239 | ||
2240 | * data/glr.c: Remove use of "#ifdef b4_header_guard", since it | |
2241 | mishandled funny characters in file names, and anyway it isn't | |
2242 | needed any more. | |
2243 | * data/yacc.c: Likewise. | |
2244 | * data/lalr1.cc: Use YYSLP_NEEDED instead of b4_header_guard. | |
2245 | ||
2246 | * data/glr.c (YYSTYPE_IS_TRIVIAL): Define when the .h file would. | |
2247 | * data/yacc.c: Likewise. | |
2248 | ||
2249 | * src/muscle_tab.c: Include quotearg.h, since we need to quote C | |
2250 | strings now. | |
2251 | (muscle_init): Quote filename as a C string. | |
2252 | * src/muscle_tab.h (MUSCLE_GROW_STRING_PAIR): Remove; unused. | |
2253 | (MUSCLE_OBSTACK_SGROW, MUSCLE_INSERT_C_STRING): New macros. | |
2254 | * src/output.c (escaped_file_name_output): New function. | |
2255 | (prepare_symbols): Quote tokens for M4. | |
2256 | (prepare): Don't insert output_infix, output_prefix, | |
2257 | output_parser_name, output_header_name; this is now down by scan-skel. | |
2258 | Insert skeleton as a C string. | |
2259 | ||
2260 | * src/output.c (user_actions_output, symbol_destructors_output, | |
2261 | symbol_printers_output): Quote filenames for C and M4. | |
2262 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
2263 | ||
2264 | * src/scan-gram.l (<SC_CHARACTER>): Don't worry about any backslash | |
2265 | escapes other than \\ and \'; this simplifies the code. | |
2266 | (<SC_STRING>): Likewise, for \\ and \". | |
2267 | (<SC_COMMENT,SC_LINE_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE, | |
2268 | SC_PROLOGUE,SC_EPILOGUE>): Escape $ and @, too. | |
2269 | Use new escapes @{ and @} for [ and ]. | |
2270 | ||
2271 | * src/scan-skel.l (yylineno, yyoutname): Remove static vars, replacing | |
2272 | them with auto vars. | |
2273 | Switch to new escape scheme, where @ is the escape character uniformly. | |
2274 | Abort if a stray escape character is found. Avoid unbounded input | |
2275 | buffer when parsing non-escaped text. | |
2276 | ||
2277 | * tests/input.at (Torturing the Scanner): Add tests that @oline@, | |
2278 | __oline__, #output, $@, and @{ do not have unintended meanings. | |
2279 | ||
2280 | 2002-11-09 Paul Eggert <eggert@twinsun.com> | |
2281 | ||
2282 | Fix the test failure due to GCC warnings described in | |
2283 | <http://mail.gnu.org/archive/html/bug-bison/2002-11/msg00000.html>. | |
2284 | * data/glr.c (yyis_pact_ninf, yyis_table_ninf): New macros, which | |
2285 | evaluate to 0 if it's impossible for NINF to be in the respective | |
2286 | table. | |
2287 | (yygetLRActions, yyrecoverParseError): Use them. | |
2288 | ||
2289 | * src/scan-gram.l (unexpected_end_of_file): Fix bug: columns were | |
2290 | counted in the token inserted at end of file. Now takes | |
2291 | location_t *, not location_t, so that the location can be | |
2292 | adjusted. All uses changed. | |
2293 | ||
2294 | * tests/regression.at (Invalid inputs): Adjust wording in | |
2295 | diagnostic to match the new behavior. | |
2296 | ||
2297 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR, | |
2298 | AT_DATA_HORIZONTAL_GRAMMAR, AT_DATA_LOOKAHEADS_GRAMMAR, | |
2299 | AT_DATA_STACK_TORTURE): Replace `assert (x);' with `if (! (x)) | |
2300 | abort ();'. This reduces the runtime of the "Many lookaheads" | |
2301 | test from 27.6 to 2.7 minutes on a 440 MHz Ultrasparc III running | |
2302 | GCC 3.2. | |
2303 | ||
2304 | 2002-11-07 Paul Eggert <eggert@twinsun.com> | |
2305 | ||
2306 | * src/parse-gram.y (CHARACTER): Remove unused token. | |
2307 | All uses removed. | |
2308 | ||
2309 | * src/scan-gram.l: Remove stack option. We no longer use the | |
2310 | stack, since the stack was never deeper than 1; instead, use the | |
2311 | new auto var c_context to record the stacked value. | |
2312 | ||
2313 | Remove nounput option. At an unexpected end of file, we now unput | |
2314 | the minimal input necessary to end cleanly; this simplifies the | |
2315 | code. | |
2316 | ||
2317 | Avoid unbounded token sizes where this is easy. | |
2318 | ||
2319 | (unexpected_end_of_file): New function. | |
2320 | Use it to systematize the error message on unexpected EOF. | |
2321 | (last-string): Now auto, not static. | |
2322 | (YY_OBS_FREE): Remove unnecessary do while (0) wrapper. | |
2323 | (scanner_last_string_free): Remove; not used. | |
2324 | (percent_percent_count): Move decl to just before use. | |
2325 | (SC_ESCAPED_CHARACTER): Return ID at unexpected end of file, | |
2326 | not the (never otherwised-used) CHARACTER. | |
2327 | ||
2328 | 2002-11-07 Akim Demaille <akim@epita.fr> | |
2329 | ||
2330 | Let yyerror always receive the msg as last argument, so that | |
2331 | yyerror can be variadic. | |
2332 | ||
2333 | * data/yacc.c (b4_yyerror_args): New. | |
2334 | Use it when calling yyerror. | |
2335 | * data/glr.c (b4_yyerror_args, b4_lyyerror_args): New. | |
2336 | Use it when calling yyerror. | |
2337 | * doc/bison.texinfo (Error Reporting): Adjust. | |
2338 | * tests/calc.at (_AT_DATA_CALC_Y): Adjust. | |
2339 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Adjust. | |
2340 | ||
2341 | 2002-11-06 Akim Demaille <akim@epita.fr> | |
2342 | ||
2343 | #line should have quoted strings. | |
2344 | Ideally, this should be done by m4_quotearg. | |
2345 | ||
2346 | * src/scan-skel.l: Include quotearg.h. | |
2347 | Quote __ofile__. | |
2348 | * src/output.c (symbol_printers_output) | |
2349 | (symbol_destructors_output): Quote the file name. | |
2350 | ||
2351 | 2002-11-06 Akim Demaille <akim@epita.fr> | |
2352 | ||
2353 | * tests/regression.at (Invalid inputs): Adjust to the recent | |
2354 | messages. | |
2355 | ||
2356 | 2002-11-06 Akim Demaille <akim@epita.fr> | |
2357 | ||
2358 | Restore --no-lines. | |
2359 | Reported by Jim Kent. | |
2360 | ||
2361 | * data/c.m4 (b4_syncline): New. | |
2362 | * data/glr.c, data/yacc.c, data/lalr1.cc: Use it. | |
2363 | * src/reader.c (prologue_augment, epilogue_set): Use b4_syncline. | |
2364 | * src/output.c (user_actions_output): Likewise. | |
2365 | (prepare): Define 'b4_synclines_flag'. | |
2366 | * src/muscle_tab.c (muscle_init): Don't define b4_linef. | |
2367 | ||
2368 | 2002-11-06 Akim Demaille <akim@epita.fr> | |
2369 | ||
2370 | * src/main.c (main): Free `infile'. | |
2371 | * src/scan-gram.l (handle_syncline): New. | |
2372 | Recognize `#line'. | |
2373 | * src/output.c (user_actions_output, symbol_destructors_output) | |
2374 | (symbol_printers_output): Use the location's file name, not | |
2375 | infile. | |
2376 | * src/reader.c (prologue_augment, epilogue_set): Likewise. | |
2377 | ||
2378 | 2002-11-05 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
2379 | ||
2380 | * src/tables.c (matching_state): Don't allow states to match if | |
2381 | either has GLR conflict entries. | |
2382 | ||
2383 | 2002-11-05 Paul Eggert <eggert@twinsun.com> | |
2384 | ||
2385 | * src/scan-gram.l: Use more accurate diagnostics, e.g. | |
2386 | "integer out of range" rather than "invalid value". | |
2387 | * tests/input.at (Invalid $n, Invalid @n): Change expected wording | |
2388 | accordingly. | |
2389 | ||
2390 | Scan <% and %> digraphs in C code as POSIX 1003.1-2001 requires. | |
2391 | Also, remove one static variable in the scanner. | |
2392 | ||
2393 | * src/scan-gram.l (braces_level): Now auto, not static. | |
2394 | Initialize to zero if the compiler is being picky. | |
2395 | (INITIAL): Clear braces_level instead of incrementing it. | |
2396 | (SC_BRACED_CODE): Treat <% and %> as { and } when inside C code, | |
2397 | as POSIX 1003.1-2001 requires. | |
2398 | * src/system.h (IF_LINT): New macro, taken from coreutils. | |
2399 | * configure.ac: Define "lint" if --enable-gcc-warnings. | |
2400 | ||
2401 | 2002-11-05 Akim Demaille <akim@epita.fr> | |
2402 | ||
2403 | * src/scan-gram.l: When it starts with `%', complain about the | |
2404 | whole directive, not just that `invalid character: %'. | |
2405 | ||
2406 | 2002-11-04 Akim Demaille <akim@epita.fr> | |
2407 | ||
2408 | * Makefile.maint: Update from Autoconf. | |
2409 | (update, cvs-update, po-update, do-po-update): New. | |
2410 | ||
2411 | 2002-11-04 Akim Demaille <akim@epita.fr> | |
2412 | ||
2413 | * tests/glr-regr1.at (Badly Collapsed GLR States): Prototype yylex | |
2414 | and yyerror. | |
2415 | Have yyerror `use' its arguments. | |
2416 | * tests/calc.at (AT_CHECK_PUSHDEFS): AT_YYERROR_SEES_LOC_IF | |
2417 | returns true when location & yacc & pure & parse-param. | |
2418 | (_AT_DATA_CALC_Y): Let yyerror ``use'' its arguments. | |
2419 | ||
2420 | 2002-11-04 Akim Demaille <akim@epita.fr> | |
2421 | ||
2422 | * src/location.h (LOCATION_PRINT): Use quotearg slot 3 to avoid | |
2423 | clashes. | |
2424 | * src/scan-gram.l: Use [\'] instead of ['] to pacify | |
2425 | font-lock-mode. | |
2426 | Use complain_at. | |
2427 | Use quote, not quote_n since LOCATION_PRINT no longer uses the | |
2428 | slot 0. | |
2429 | ||
2430 | 2002-11-03 Paul Eggert <eggert@twinsun.com> | |
2431 | ||
2432 | * src/reader.c (get_merge_function, grammar_current_rule_check): | |
2433 | Use consistent diagnostics for reporting type name clashes. | |
2434 | Quote the types with <>, for consistency with Yacc. | |
2435 | * tests/input.at (Type Clashes): Adjust to diagnostic changes. | |
2436 | ||
2437 | 2002-11-03 Akim Demaille <akim@epita.fr> | |
2438 | ||
2439 | * data/c.m4 (b4_identification, b4_user_args, b4_parse_param): | |
2440 | New. | |
2441 | * data/yacc.m4 (b4_pure_args, b4_Pure_args): New. | |
2442 | (b4_parse_param): Remove. | |
2443 | Use b4_identification. | |
2444 | Propagate b4_pure_args where needed to pass them to yyerror. | |
2445 | * data/glr.m4 (b4_parse_param): Remove. | |
2446 | (b4_user_formals, b4_pure_args, b4_pure_formals, b4_lpure_args) | |
2447 | (b4_lpure_formals): New. | |
2448 | Use b4_identification. | |
2449 | (YY_USER_FORMALS, YY_USER_ARGS): Remove, replaced by | |
2450 | b4_user_formals and b4_user_args. | |
2451 | (yyexpandGLRStack, yyFail, yyaddDeferredAction, yyglrShiftDefer) | |
2452 | (yyreportAmbiguity): When using a pure parser, also need | |
2453 | the location, and the parse-params. | |
2454 | Adjust callers. | |
2455 | (yyuserAction, yyglrShift, yyreportParseError, yyrecoverParseError): | |
2456 | When using a pure parser, also need the parse-params. | |
2457 | Adjust callers. | |
2458 | * tests/calc.at: Test pure (%pure-parser) and absolutely pure | |
2459 | (%pure-parser + %parse-param) LALR and GLR parsers. | |
2460 | (AT_CHECK_PUSHDEFS, AT_CHECK_POPDEFS): New, define AT_PARAM_IF, | |
2461 | AT_LOCATION_IF, AT_PURE_IF, AT_GLR_IF, AAT_PURE_AND_LOC_IF, | |
2462 | AT_GLR_OR_PARAM_IF, AT_YYERROR_ARG_LOC_IF, AT_YYERROR_SEES_LOC_IF. | |
2463 | (_AT_DATA_CALC_Y): Equip for purity of yyerror. | |
2464 | (_AT_CHECK_CALC_ERROR): Use AT_YYERROR_SEES_LOC_IF. | |
2465 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Equip for yyerror purity. | |
2466 | * doc/bison.texinfo: Untabify the whole file. | |
2467 | (Parser Function): Document %parse-param, deprecate YYPARSE_PARAM. | |
2468 | (Pure Calling): Document %lex-param, deprecate YYLEX_PARAM. | |
2469 | (Error Reporting): Adjust to these new directives. | |
2470 | Document %error-verbose, deprecate YYERROR_VERBOSE. | |
2471 | ||
2472 | 2002-11-03 Akim Demaille <akim@epita.fr> | |
2473 | ||
2474 | * tests/calc.at: Change all the AT_CHECK_CALC_LALR and | |
2475 | AT_CHECK_CALC_GLR invocations to use % directives, instead of | |
2476 | command line options. | |
2477 | * tests/cxx-type.at: Formatting changes. | |
2478 | ||
2479 | 2002-11-03 Paul Eggert <eggert@twinsun.com> | |
2480 | ||
2481 | * src/scan-gram.l: Revamp to fix POSIX incompatibilities, | |
2482 | to count columns correctly, and to check for invalid inputs. | |
2483 | ||
2484 | Use mbsnwidth to count columns correctly. Account for tabs, too. | |
2485 | Include mbswidth.h. | |
2486 | (YY_USER_ACTION): Invoke extend_location rather than LOCATION_COLUMNS. | |
2487 | (extend_location): New function. | |
2488 | (YY_LINES): Remove. | |
2489 | ||
2490 | Handle CRLF in C code rather than in Lex code. | |
2491 | (YY_INPUT): New macro. | |
2492 | (no_cr_read): New function. | |
2493 | ||
2494 | Scan UCNs, even though we don't fully handle them yet. | |
2495 | (convert_ucn_to_byte): New function. | |
2496 | ||
2497 | Handle backslash-newline correctly in C code. | |
2498 | (SC_LINE_COMMENT, SC_YACC_COMMENT): New states. | |
2499 | (eols, blanks): Remove. YY_USER_ACTION now counts newlines etc.; | |
2500 | all uses changed. | |
2501 | (tag, splice): New EREs. Do not allow NUL or newline in tags. | |
2502 | Use {splice} wherever C allows backslash-newline. | |
2503 | YY_STEP after space, newline, vertical-tab. | |
2504 | ("/*"): BEGIN SC_YACC_COMMENT, not yy_push_state (SC_COMMENT). | |
2505 | ||
2506 | (letter, id): Don't assume ASCII; e.g., spell out a-z. | |
2507 | ||
2508 | ({int}, handle_action_dollar, handle_action_at): Check for integer | |
2509 | overflow. | |
2510 | ||
2511 | (YY_STEP): Omit trailing semicolon, so that it's more like C. | |
2512 | ||
2513 | (<SC_ESCAPED_STRING,SC_ESCAPED_CHARACTER>): Allow \0 and \00 | |
2514 | as well as \000. Check for UCHAR_MAX, not 255. | |
2515 | Allow \x with an arbitrary positive number of digits, as in C. | |
2516 | Check for overflow here. | |
2517 | Allow \? and UCNs, for compatibility with C. | |
2518 | ||
2519 | (handle_symbol_code_dollar): Use quote_n slot 1 to avoid collision | |
2520 | with quote slot used by complain_at. | |
2521 | ||
2522 | * tests/input.at: Add tests for backslash-newline, m4 quotes | |
2523 | in symbols, long literals, and funny escapes in strings. | |
2524 | ||
2525 | * configure.ac (jm_PREREQ_MBSWIDTH): Add. | |
2526 | * lib/Makefile.am (libbison_a_SOURCES): Add mbswidth.h, mbswidth.c. | |
2527 | * lib/mbswidth.h, lib/mbswidth.c: New files, from GNU gettext. | |
2528 | * m4/Makefile.am (EXTRA_DIST): Add mbswidth.m4. | |
2529 | * m4/mbswidth.m4: New file, from GNU coreutils. | |
2530 | ||
2531 | * doc/bison.texinfo (Grammar Outline): Document // comments. | |
2532 | (Symbols): Document that trigraphs have no special meaning in Bison, | |
2533 | nor is backslash-newline allowed. | |
2534 | (Actions): Document that trigraphs have no special meaning. | |
2535 | ||
2536 | * src/location.h (LOCATION_COLUMNS, LOCATION_LINES): Remove; | |
2537 | no longer used. | |
2538 | ||
2539 | 2002-11-02 Paul Eggert <eggert@twinsun.com> | |
2540 | ||
2541 | * src/reader.c: Don't include quote.h; not needed. | |
2542 | (get_merge_function): Reword warning to be consistent with | |
2543 | type clash diagnostic in grammar_current_rule_check. | |
2544 | ||
2545 | * lib/quotearg.c (quotearg_buffer_restyled): Fix off-by-two | |
2546 | bug in trigraph handling. | |
2547 | ||
2548 | * src/output.c (prepare_symbols): When printing token names, | |
2549 | escape "[" as "@<:@" and likewise for "]". | |
2550 | ||
2551 | * src/system.h (errno): Remove declaration, as we are now | |
2552 | assuming C89 or better, and C89 guarantees errno. | |
2553 | ||
2554 | 2002-10-30 Paul Eggert <eggert@twinsun.com> | |
2555 | ||
2556 | * lib/bitset_stats.c (bitset_stats_read, bitset_stats_write): | |
2557 | Check for close failures. | |
2558 | * src/files.h (xfclose): Return void, not int, since it always | |
2559 | returned zero. | |
2560 | * src/files.c (xfclose): Likewise. Report I/O error if ferror | |
2561 | indicates one. | |
2562 | * src/output.c (output_skeleton): Use xfclose rather than fclose | |
2563 | and ferror. xfclose now checks ferror. | |
2564 | ||
2565 | * data/glr.c (YYLEFTMOST_STATE): Remove. | |
2566 | (yyreportTree): Use a stack-based leftmost state. This avoids | |
2567 | our continuing battles with bogus warnings about initializers. | |
2568 | ||
2569 | 2002-10-30 Akim Demaille <akim@epita.fr> | |
2570 | ||
2571 | * src/system.h: Don't use #ifdef/#ifndef on HAVE_ values, only | |
2572 | #if. | |
2573 | ||
2574 | 2002-10-29 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
2575 | ||
2576 | * tests/glr-regr1.at: New test for reported regressions. | |
2577 | * tests/testsuite.at: Add glr-regr1.at test. | |
2578 | * tests/Makefile.am: Add glr-regr1.at test. | |
2579 | ||
2580 | 2002-10-24 Paul Eggert <eggert@twinsun.com> | |
2581 | ||
2582 | Version 1.75a. | |
2583 | ||
2584 | * tests/calc.at (_AT_DATA_CALC_Y): Remove unused strcat declaration. | |
2585 | * tests/cxx-type.at (_AT_TEST_GLR_CALC): Include stdlib.h, since | |
2586 | we use malloc. Don't assume 'A' through 'Z' are contiguous. | |
2587 | Don't assume strdup exists; POSIX says its an XSI extension. | |
2588 | Check for buffer overflow on input. | |
2589 | ||
2590 | 2002-10-24 Akim Demaille <akim@epita.fr> | |
2591 | ||
2592 | * src/output.c (output_skeleton): Don't disable M4sugar comments | |
2593 | too soon: it results in comments being expanded. | |
2594 | * data/yacc.c, data/glr.c, data/lalr1.cc: Do it right before the | |
2595 | first output. | |
2596 | ||
2597 | 2002-10-24 Akim Demaille <akim@epita.fr> | |
2598 | ||
2599 | * data/yacc.c (m4_int_type): New. | |
2600 | * data/c.m4 (m4_int_type): Don't use yysigned_char, but `signed | |
2601 | char' as only yacc.c wants K&R portability. | |
2602 | * data/glr.c (yysigned_char): Remove. | |
2603 | * data/lalr1.cc: Rename the trailing b4_name as b4_parser_class_name. | |
2604 | Reported by Quoc Peyrot. | |
2605 | ||
2606 | 2002-10-23 Paul Eggert <eggert@twinsun.com> | |
2607 | ||
2608 | * src/main.c (main): With --trace=time, report times even if a | |
2609 | non-fatal error occurs. Formerly, the times were reported in some | |
2610 | such cases but not in others. | |
2611 | * src/reader.c (reader): Just return if a complaint has been issued, | |
2612 | instead of exiting, so that 'main' can report times. | |
2613 | ||
2614 | 2002-10-22 Akim Demaille <akim@epita.fr> | |
2615 | ||
2616 | * src/system.h: Include sys/types. | |
2617 | Reported by Bert Deknuydt. | |
2618 | ||
2619 | 2002-10-23 Paul Eggert <eggert@twinsun.com> | |
2620 | ||
2621 | * configure.ac (AC_PROG_LEX): Use instead of AM_PROG_LEX. | |
2622 | Suggested by Art Haas. | |
2623 | ||
2624 | 2002-10-22 Paul Eggert <eggert@twinsun.com> | |
2625 | ||
2626 | * src/complain.c (exit) [! (STDC_HEADERS || _LIBC)]: Remove exit | |
2627 | decl; not needed any more. | |
2628 | * src/main.c (main): Use return to exit, undoing yesterday's change. | |
2629 | The last OS that we could find where this wouldn't work is | |
2630 | SunOS 3.5, and that's too old to worry about now. | |
2631 | ||
2632 | * data/glr.c (struct yyltype): Define members even when not | |
2633 | doing locations. This is more consistent with yacc.c, and it | |
2634 | works around the following bug reports: | |
2635 | http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00106.html | |
2636 | http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00111.html | |
2637 | ||
2638 | * doc/bison.texinfo: Minor spelling and typographical fixes. Use | |
2639 | @acronym consistently. Standardize on "Yacc" instead of "YACC", | |
2640 | "Algol" instead of "ALGOL". Give a bit more history about BNF. | |
2641 | ||
2642 | 2002-10-22 Akim Demaille <akim@epita.fr> | |
2643 | ||
2644 | * data/README: New. | |
2645 | ||
2646 | 2002-10-21 Paul Eggert <eggert@twinsun.com> | |
2647 | ||
2648 | Be consistent about 'bool'; the old code used an enum in one | |
2649 | module and an int in another, and this violates the C standard. | |
2650 | * m4/stdbool.m4: New file, from coreutils 4.5.3. | |
2651 | * configure.ac (AC_HEADER_STDBOOL): Add. | |
2652 | * m4/Makefile.am (EXTRA_DIST): Add stdbool.m4. | |
2653 | * src/muscle_tab.c (hash_compare_muscles): (a ? FALSE : TRUE) -> (! a) | |
2654 | * src/symtab.c (hash_compare_symbol_t): Likewise. | |
2655 | * src/system.h (bool, false, true): Use a definition consistent | |
2656 | with ../lib/hash.c. All uses changed. | |
2657 | ||
2658 | * src/complain.c (warning_issued): Renamed from warn_message_count, | |
2659 | so that we needn't worry about integer overflow (!). | |
2660 | Now of type bool. All uses changed. | |
2661 | (complaint_issued): Renamed from complain_message_count; likewise. | |
2662 | ||
2663 | * src/main.c (main): Use exit to exit with failure. | |
2664 | ||
2665 | * src/complain.c (fatal_at, fatal): Use EXIT_FAILURE and EXIT_SUCCESS | |
2666 | rather than 1 and 0. | |
2667 | * src/main.c (main): Likewise. | |
2668 | * src/getargs.c (getargs): Likewise. | |
2669 | * src/reader.c (reader): Likewise. | |
2670 | ||
2671 | * src/getarg.c (getargs): Remove duplicate code for | |
2672 | "Try `bison --help'". | |
2673 | ||
2674 | * src/files.c (xfopen, xfclose): Use EXIT_FAILURE rather than 2. | |
2675 | What was that "2" for? | |
2676 | ||
2677 | * src/complain.h (fatal, fatal_at): Add __attribute__((__noreturn__)). | |
2678 | * src/getargs.c (usage): Likewise. | |
2679 | ||
2680 | * src/getargs.c (getargs): When there are too few operands, report | |
2681 | the last one. When there are too many, report the first extra | |
2682 | one. This is how diffutils does it. | |
2683 | ||
2684 | 2002-10-20 Paul Eggert <eggert@twinsun.com> | |
2685 | ||
2686 | Remove K&R vestiges. | |
2687 | * configure.ac (AC_C_CONST, AM_C_PROTOTYPES): Remove. | |
2688 | * src/complain.c (VA_START): Remove. Assume prototypes. | |
2689 | (vfprintf) [! (HAVE_VPRINTF || defined vfprintf)]: New macro. | |
2690 | (private_strerror, warn_at, warn, complain_at, complain, fatal_at, | |
2691 | fatal): Assume prototypes. | |
2692 | * src/complain.h: Assume prototypes. | |
2693 | * src/system.h (PARAMS): Remove. | |
2694 | Include <limits.h> unconditionally, since it's guaranteeed even | |
2695 | for a freestanding C89 compiler. | |
2696 | (SHRT_MIN, SHRT_MAX): Remove, since C89 guarantees them. | |
2697 | * src/vmsgetargs.c (getargs, cli_present, cli_get_value): Prototype. | |
2698 | ||
2699 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2700 | ||
2701 | * src/muscle_tab.c (muscle_grow): Remove trailing debugging code. | |
2702 | * data/glr.c (YY_USER_FORMALS, YY_USER_ARGS): New. | |
2703 | (yyuserAction, yydoAction, yyglrReduce, yyresolveValue) | |
2704 | (yyresolveStates, yyresolveAction, yyresolveStack) | |
2705 | (yyprocessOneStack): Use them. | |
2706 | (yy_reduce_print): New. | |
2707 | * tests/calc.at (_AT_DATA_CALC_Y): Exercise %parse-param. | |
2708 | ||
2709 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2710 | ||
2711 | * data/c.m4 (b4_c_ansi_args): Recognize functions with no | |
2712 | arguments and output `void'. | |
2713 | (b4_c_function): Rename as... | |
2714 | (b4_c_function_def): this. | |
2715 | (b4_c_function_decl, b4_c_ansi_function_def) | |
2716 | (b4_c_ansi_function_decl): New. | |
2717 | Change the interpretation of the arguments: before `int, foo', now | |
2718 | `int foo, foo'. | |
2719 | * data/yacc.c (yyparse): Prototype and define thanks to these. | |
2720 | Adjust b4_c_function_def uses. | |
2721 | * data/glr.c (yyparse): Likewise, but ANSI only. | |
2722 | ||
2723 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2724 | ||
2725 | * src/output.c (prepare): Move the definition of `tokens_number', | |
2726 | `nterms_number', `undef_token_number', `user_token_number_max' | |
2727 | to... | |
2728 | (prepare_tokens): Here. | |
2729 | (prepare_tokens): Rename as... | |
2730 | (prepare_symbols): this. | |
2731 | (prepare): Move the definition of `rules_number' to... | |
2732 | (prepare_rules): here. | |
2733 | (prepare): Move the definition of `last', `final_state_number', | |
2734 | `states_number' to... | |
2735 | (prepare_states): here. | |
2736 | * data/yacc.c, data/lalr1.cc, data/glr.c: Normalize `>' into `<'. | |
2737 | ||
2738 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2739 | ||
2740 | * src/tables.h, src/tables.c, src/output.c: Comment changes. | |
2741 | ||
2742 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2743 | ||
2744 | * data/yacc.c, data/yacc.c (b4_location_if, b4_pure_if): Move to... | |
2745 | * data/c.m4: here. | |
2746 | ||
2747 | 2002-10-20 Akim Demaille <akim@epita.fr> | |
2748 | ||
2749 | * src/output.c (prepare): Use MUSCLE_INSERT_STRING. | |
2750 | * src/muscle_tab.c (muscle_pair_list_grow): Rename `val as | |
2751 | `pair'. | |
2752 | (muscle_init): Move the `b4_ltype', `b4_maxdepth', `b4_initdepth', | |
2753 | `name' to... | |
2754 | * data/glr.c, data/lalr1.cc, data/yacc.c (b4_location_type) | |
2755 | (b4_stack_depth_init, b4_stack_depth_max, b4_parser_class_name): | |
2756 | These. | |
2757 | ||
2758 | 2002-10-19 Paul Eggert <eggert@twinsun.com> | |
2759 | ||
2760 | Do not create a temporary file, as that involves security and | |
2761 | cleanup headaches. Instead, use a pair of pipes. | |
2762 | Derived from a suggestion by Florian Krohm. | |
2763 | * lib/subpipe.c, lib/subpipe.h, m4/subpipe.m4: New files. | |
2764 | * lib/mkstemp.c, lib/readpipe.c, lib/tempname.c, m4/mkstemp.m4: Remove. | |
2765 | * configure.ac (UTILS_FUNC_MKSTEMP, jm_PREREQ_TEMPNAME): Remove. | |
2766 | (BISON_PREREQ_SUBPIPE): Add. | |
2767 | * lib/Makefile.am (libbison_a_SOURCES): Remove readpipe.c. | |
2768 | Add subpipe.h, subpipe.c. | |
2769 | * m4/Makefile.am (EXTRA_DIST): Remove mkstemp.m4. Add subpipe.m4. | |
2770 | * po/POTFILES.in: Add lib/subpipe.c. | |
2771 | * src/output.c: Include "subpipe.h". | |
2772 | (m4_invoke): Remove decl. | |
2773 | (scan_skel): New decl. | |
2774 | (output_skeleton): Use pipe rather than temporary file for m4 input. | |
2775 | Check that m4sugar.m4 is readable, to avoid deadlock. | |
2776 | Check for pipe I/O error. | |
2777 | * src/scan-skel.l (readpipe): Remove decl. | |
2778 | (scan_skel): New function, to be used in place of m4_invoke. | |
2779 | Read from stream rather than file. | |
2780 | ||
2781 | * lib/timevar.c (TICKS_TO_MSEC, CLOCKS_TO_MSEC): Do not cast to | |
2782 | float, as this generates a warning on Solaris 8 + GCC 3.2 with | |
2783 | --enable-gcc-warnings. Instead, divide into 1.0 rather than 1; | |
2784 | this generates a more-accurate value anyway. | |
2785 | ||
2786 | * lib/timevar.c (timervar_accumulate): Rename locals to | |
2787 | avoid confusion with similarly-named more-global. | |
2788 | * src/muscle_tab.c (muscle_pair_list_grow): Likewise. | |
2789 | ||
2790 | * src/output.c (prepare): Use xstrdup to convert char const * | |
2791 | to char *, to avoid GCC warning. | |
2792 | ||
2793 | 2002-10-19 Akim Demaille <akim@epita.fr> | |
2794 | ||
2795 | * tests/calc.at (_AT_DATA_CALC_Y): Define VAL, LOC, LEX_FORMALS, | |
2796 | LEX_PRE_FORMALS, LEX_ARGS, LEX_PRE_ARGS, USE_LEX_ARGS. | |
2797 | Use them to have `calc.y' ready for %pure-parser. | |
2798 | * data/yacc.c (YYLEX): Pass a yylex return type to | |
2799 | b4_c_function_call. | |
2800 | ||
2801 | 2002-10-19 Akim Demaille <akim@epita.fr> | |
2802 | ||
2803 | Prototype support of %lex-param and %parse-param. | |
2804 | ||
2805 | * src/parse-gram.y: Add the definition of the %lex-param and | |
2806 | %parse-param tokens, plus their rules. | |
2807 | Drop the `_' version of %glr-parser. | |
2808 | Add the "," token. | |
2809 | * src/scan-gram.l (INITIAL): Scan them. | |
2810 | * src/muscle_tab.c: Comment changes. | |
2811 | (muscle_insert, muscle_find): Rename `pair' as `probe'. | |
2812 | * src/muscle_tab.h (MUSCLE_INSERT_PREFIX): Remove unused. | |
2813 | (muscle_entry_s): The `value' member is no longer const. | |
2814 | Adjust all dependencies. | |
2815 | * src/muscle_tab.c (muscle_init): Adjust: use | |
2816 | MUSCLE_INSERT_STRING. | |
2817 | Initialize the obstack earlier. | |
2818 | * src/muscle_tab.h, src/muscle_tab.c (muscle_grow) | |
2819 | (muscle_pair_list_grow): New. | |
2820 | * data/c.m4 (b4_c_function_call, b4_c_args): New. | |
2821 | * data/yacc.c (YYLEX): Use b4_c_function_call to honor %lex-param. | |
2822 | * tests/calc.at: Use %locations, not --locations. | |
2823 | (AT_CHECK_CALC_GLR): Use %glr-parser, not %glr_parser. | |
2824 | ||
2825 | 2002-10-19 Akim Demaille <akim@epita.fr> | |
2826 | ||
2827 | * src/getargs.c (usage): Take status as argument and exit | |
2828 | accordingly. | |
2829 | Report the traditional `Try ... --help' message when status != 0. | |
2830 | (usage, version): Don't take a FILE * as arg, it is pointless. | |
2831 | (getargs): When there is an incorrect number of arguments, make it | |
2832 | an error, and report it GNUlically thanks to `usage ()'. | |
2833 | ||
2834 | 2002-10-18 Paul Eggert <eggert@twinsun.com> | |
2835 | ||
2836 | * data/glr.c (yyreportParseError): Don't assume that sprintf | |
2837 | yields the length of the printed string, as this is not true | |
2838 | on SunOS 4.1.4. Reported by Peter Klein. | |
2839 | ||
2840 | * tests/calc.at (_AT_DATA_CALC_Y): #undef memcmp and realloc. | |
2841 | * tests/conflicts.at (%nonassoc and eof): Likewise. | |
2842 | Fixes SunOS 4.1.4 test failure reported by Peter Klein. | |
2843 | ||
2844 | 2002-10-17 Akim Demaille <akim@epita.fr> | |
2845 | ||
2846 | * src/getargs.h (trace_e): Add trace_scan, and trace_parse. | |
2847 | * src/getargs.c (trace_types, trace_args): Adjust. | |
2848 | * src/reader.c (grammar_current_rule_prec_set) | |
2849 | (grammar_current_rule_dprec_set, grammar_current_rule_merge_set): | |
2850 | Standardize error messages. | |
2851 | And s/@prec/%prec/! | |
2852 | (reader): Use trace_flag to enable scanner/parser debugging, | |
2853 | instead of an adhoc scheme. | |
2854 | * src/scan-gram.l: Remove trailing debugging code. | |
2855 | ||
2856 | 2002-10-16 Paul Eggert <eggert@twinsun.com> | |
2857 | ||
2858 | * src/muscle_tab.h (MUSCLE_TAB_H_): Was misspelled as | |
2859 | MUSCLE_TAB_H. | |
2860 | ||
2861 | * NEWS: Officially drop support for building Bison with K&R C, | |
2862 | since it didn't work anyway and it's not worth worrying about. | |
2863 | * Makefile.maint (wget_files): Remove ansi2knr.c. | |
2864 | (ansi2knr.c-url_prefix): Remove. | |
2865 | * lib/.cvsignore: Remove ansi2knr, ansi2knr.*. | |
2866 | * lib/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
2867 | * src/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
2868 | ||
2869 | 2002-10-15 Paul Eggert <eggert@twinsun.com> | |
2870 | ||
2871 | Stop using the "enum_" trick for K&R-style function definitions; | |
2872 | it confused me, and I was the author! Instead, assume that people | |
2873 | who want to use K&R C compilers (when using these modules in GCC, | |
2874 | perhaps?) will run ansi2knr. | |
2875 | ||
2876 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): Remove. | |
2877 | All uses of "enum_" changed to "enum ". | |
2878 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
2879 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
2880 | ||
2881 | * lib/abitset.c (abitset_and, abitset_and_cmp, abitset_and_or, | |
2882 | abitset_and_or_cmp, abitset_andn, abitset_andn_cmp, | |
2883 | abitset_andn_or, abitset_andn_or_cmp, abitset_bytes, abitset_copy, | |
2884 | abitset_copy1, abitset_disjoint_p, abitset_empty_p, | |
2885 | abitset_equal_p, abitset_init, abitset_list, abitset_list_reverse, | |
2886 | abitset_not, abitset_ones, abitset_or, abitset_or_and, | |
2887 | abitset_or_and_cmp, abitset_or_cmp, abitset_reset, abitset_set, | |
2888 | abitset_size, abitset_small_list, abitset_subset_p, abitset_test, | |
2889 | abitset_unused_clear, abitset_xor, abitset_xor_cmp, abitset_zero): | |
2890 | Use function prototypes; this removes the need for declaring | |
2891 | static functions simply to provide their prototypes. | |
2892 | * lib/bitset.c (bitset_alloc, bitset_and_or_, bitset_and_or_cmp_, | |
2893 | bitset_andn_or_, bitset_andn_or_cmp_, bitset_bytes, bitset_copy_, | |
2894 | bitset_count_, bitset_create, bitset_dump, bitset_first, | |
2895 | bitset_free, bitset_init, bitset_last, bitset_next, | |
2896 | bitset_obstack_alloc, bitset_obstack_free, bitset_only_set_p, | |
2897 | bitset_op4_cmp, bitset_or_and_, bitset_or_and_cmp_, bitset_prev, | |
2898 | bitset_print, bitset_release_memory, bitset_toggle_, | |
2899 | bitset_type_choose, bitset_type_get, bitset_type_name_get, | |
2900 | debug_bitset): Likewise. | |
2901 | * lib/bitset.h (bitset_set, bitset_reset, bitset_test): Likewise. | |
2902 | * lib/bitset_stats.c (bitset_log_histogram_print, | |
2903 | bitset_percent_histogram_print, bitset_stats_and, | |
2904 | bitset_stats_and_cmp, bitset_stats_and_or, | |
2905 | bitset_stats_and_or_cmp, bitset_stats_andn, bitset_stats_andn_cmp, | |
2906 | bitset_stats_andn_or, bitset_stats_andn_or_cmp, bitset_stats_copy, | |
2907 | bitset_stats_count, bitset_stats_disable, bitset_stats_disjoint_p, | |
2908 | bitset_stats_dump, bitset_stats_empty_p, bitset_stats_enable, | |
2909 | bitset_stats_equal_p, bitset_stats_free, bitset_stats_init, | |
2910 | bitset_stats_list, bitset_stats_list_reverse, bitset_stats_not, | |
2911 | bitset_stats_ones, bitset_stats_or, bitset_stats_or_and, | |
2912 | bitset_stats_or_and_cmp, bitset_stats_or_cmp, bitset_stats_print, | |
2913 | bitset_stats_print_1, bitset_stats_read, bitset_stats_reset, | |
2914 | bitset_stats_set, bitset_stats_size, bitset_stats_subset_p, | |
2915 | bitset_stats_test, bitset_stats_toggle, bitset_stats_type_get, | |
2916 | bitset_stats_write, bitset_stats_xor, bitset_stats_xor_cmp, | |
2917 | bitset_stats_zero): Likewise. | |
2918 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
2919 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
2920 | bitsetv_dump, debug_bitsetv): Likewise. | |
2921 | * lib/ebitset.c (ebitset_and, ebitset_and_cmp, ebitset_andn, | |
2922 | ebitset_andn_cmp, ebitset_bytes, ebitset_copy, ebitset_copy_, | |
2923 | ebitset_copy_cmp, ebitset_disjoint_p, ebitset_elt_add, | |
2924 | ebitset_elt_alloc, ebitset_elt_calloc, ebitset_elt_find, | |
2925 | ebitset_elt_free, ebitset_elt_last, ebitset_elt_remove, | |
2926 | ebitset_elt_zero_p, ebitset_elts_grow, ebitset_empty_p, | |
2927 | ebitset_equal_p, ebitset_free, ebitset_init, ebitset_list, | |
2928 | ebitset_list_reverse, ebitset_not, ebitset_ones, ebitset_op3_cmp, | |
2929 | ebitset_or, ebitset_or_cmp, ebitset_release_memory, ebitset_reset, | |
2930 | ebitset_set, ebitset_size, ebitset_subset_p, ebitset_test, | |
2931 | ebitset_weed, ebitset_xor, ebitset_xor_cmp, ebitset_zero): | |
2932 | Likewise. | |
2933 | * lib/lbitset.c (debug_lbitset, lbitset_and, lbitset_and_cmp, | |
2934 | lbitset_andn, lbitset_andn_cmp, lbitset_bytes, lbitset_copy, | |
2935 | lbitset_copy_cmp, lbitset_disjoint_p, lbitset_elt_alloc, | |
2936 | lbitset_elt_calloc, lbitset_elt_find, lbitset_elt_free, | |
2937 | lbitset_elt_link, lbitset_elt_unlink, lbitset_elt_zero_p, | |
2938 | lbitset_empty_p, lbitset_equal_p, lbitset_free, lbitset_init, | |
2939 | lbitset_list, lbitset_list_reverse, lbitset_not, lbitset_ones, | |
2940 | lbitset_op3_cmp, lbitset_or, lbitset_or_cmp, lbitset_prune, | |
2941 | lbitset_release_memory, lbitset_reset, lbitset_set, lbitset_size, | |
2942 | lbitset_subset_p, lbitset_test, lbitset_weed, lbitset_xor, | |
2943 | lbitset_xor_cmp, lbitset_zero): Likewise. | |
2944 | ||
2945 | 2002-10-14 Akim Demaille <akim@epita.fr> | |
2946 | ||
2947 | Version 1.75. | |
2948 | ||
2949 | 2002-10-14 Akim Demaille <akim@epita.fr> | |
2950 | ||
2951 | * tests/Makefile.am (maintainer-check-posix): New. | |
2952 | ||
2953 | 2002-10-14 Akim Demaille <akim@epita.fr> | |
2954 | ||
2955 | * data/glr.c [YYDEBUG] (YYLEFTMOST_STATE): Initialize the yyloc | |
2956 | member. | |
2957 | ||
2958 | 2002-10-14 Akim Demaille <akim@epita.fr> | |
2959 | ||
2960 | * src/tables.c (table_ninf_remap): base -> tab. | |
2961 | Reported by Matt Rosing. | |
2962 | ||
2963 | 2002-10-14 Paul Eggert <eggert@twinsun.com> | |
2964 | ||
2965 | * tests/action.at, tests/calc.at, tests/conflicts.at, | |
2966 | tests/cxx-type.at, tests/headers.at, tests/input.at, | |
2967 | tests/regression.at, tests/synclines.at, tests/torture.at: | |
2968 | Say "bison -o foo.c foo.y", not "bison foo.y -o foo.c", | |
2969 | so that the tests still work even if POSIXLY_CORRECT is set. | |
2970 | * doc/bison.texinfo (Rpcalc Compile, Invocation): Likewise. | |
2971 | ||
2972 | * data/c.m4 (b4_int_type): Use yysigned_char instead of signed char, | |
2973 | for portability to K&R hosts. Fix typo: signed char is guaranteed | |
2974 | only to 127, not to 128. | |
2975 | * data/glr.c (yysigned_char): New type. | |
2976 | * data/yacc.c (yysigned_char): Likewise. | |
2977 | * tests/regression.at (Web2c Actions): signed char -> yysigned_char. | |
2978 | ||
2979 | 2002-10-13 Paul Eggert <eggert@twinsun.com> | |
2980 | ||
2981 | * data/yacc.c (yyparse): Rewrite to avoid "comparison is always | |
2982 | true due to limited range of data type" warning from GCC. | |
2983 | ||
2984 | * data/c.m4 (b4_token_defines): Protect against double-inclusion | |
2985 | by wrapping enum yytokentype's definition inside #ifndef | |
2986 | YYTOKENTYPE. This undoes a bug I introduced on 2002-10-12. | |
2987 | ||
2988 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
2989 | ||
2990 | * data/glr.c (yyglrShiftDefer, yyaddDeferredAction, yydoAction): | |
2991 | Un yy- yyrhs to avoid the name clash with the global YYRHS. | |
2992 | ||
2993 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
2994 | ||
2995 | * Makefile.maint: Update from Autoconf 2.54. | |
2996 | * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Remove, shipped with 2.54. | |
2997 | ||
2998 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
2999 | ||
3000 | * src/print.c (print_state): Separate the list of solved conflicts | |
3001 | from the other items. | |
3002 | * tests/conflicts.at (Resolved SR Conflicts): Adjust. | |
3003 | ||
3004 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
3005 | ||
3006 | Let nondeterministic skeletons be usable with deterministic | |
3007 | tables. | |
3008 | ||
3009 | With the patch, GAWK compiled by GCC without -O2 passes its test | |
3010 | suite using a GLR parser driven by LALR tables. It fails with -O2 | |
3011 | because `struct stat' gives two different answers on my machine: | |
3012 | 88 (definition of an auto var) and later 96 (memset on this var). | |
3013 | Hence the stack is badly corrumpted. The headers inclusion is to | |
3014 | blame: if I move the awk.h inclusion before GLR's system header | |
3015 | inclusion, the two struct stat have the same size. | |
3016 | ||
3017 | * src/tables.c (pack_table): Always create conflict_table. | |
3018 | (token_actions): Always create conflict_list. | |
3019 | * data/glr.c (YYFLAG): Remove, unused. | |
3020 | ||
3021 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
3022 | ||
3023 | * configure.ac (AC_GNU_SOURCE): Use it instead of hand written code. | |
3024 | (O0FLAGS): New. | |
3025 | (VALGRIND, GXX): New. | |
3026 | * tests/atlocal.in (CFLAGS): Use O0FLAGS. | |
3027 | * tests/bison.in: Run $PREBISON a pre-command. | |
3028 | * tests/Makefile.am (maintainer-check, maintainer-check-valgrind) | |
3029 | (maintainer-check-g++): New. | |
3030 | * Makefile.am (maintainer-check): New. | |
3031 | ||
3032 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
3033 | ||
3034 | * data/glr.c: Formatting changes. | |
3035 | Tweak some trace messages to match yacc.c's. | |
3036 | ||
3037 | 2002-10-13 Akim Demaille <akim@epita.fr> | |
3038 | ||
3039 | GLR parsers sometimes raise parse errors instead of performing the | |
3040 | default reduction. | |
3041 | Reported by Charles-Henry de Boysson. | |
3042 | ||
3043 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Don't | |
3044 | check the length of the traces when %glr. | |
3045 | (_AT_CHECK_CALC_ERROR): Also skip `^Stack' lines, coming from | |
3046 | GLR's traces. | |
3047 | (AT_CHECK_CALC_LALR, AT_CHECK_CALC_GLR): New. | |
3048 | Test GLR parsers. | |
3049 | * data/glr.c (YYLEFTMOST_STATE): Fix its value. | |
3050 | (yyltype): Remove the yy prefix from the member names. | |
3051 | (yytable): Complete its comment. | |
3052 | (yygetLRActions): Map error action number from YYTABLE from | |
3053 | YYTABLE_NINF to 0. | |
3054 | (yyisErrorAction): No longer compare YYACTION to YYPACT_NINF | |
3055 | (which was a bug: it should have been YYTABEL_NINF, and yet it was | |
3056 | not satisfying as we could compare an YYACTION computed from | |
3057 | YYDEFACT to YYTABLE_NINF although they are unrelated): 0 is the | |
3058 | only value for error actions. | |
3059 | (yyreportParseError): In verbose parse error messages, don't issue | |
3060 | `error' in the list of expected tokens. | |
3061 | * data/yacc.c (yyparse) <yybackup>: Rewrite the decoding of the | |
3062 | next action to perform to match glr.c's decoding. | |
3063 | (yytable): Complete its comment. | |
3064 | ||
3065 | 2002-10-13 Paul Eggert <eggert@twinsun.com> | |
3066 | ||
3067 | Fix problem reported by Henrik Grubbstroem in | |
3068 | <http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00098.html>: | |
3069 | "nonterm: { $$ = 123; } { $$ = $1; };" was wrongly rejected, | |
3070 | because the Bison parser reads the second action before reducing | |
3071 | the first one. | |
3072 | * src/scan-gram.l (rule_length): New static var. | |
3073 | Use it to keep track of the rule length in the scanner, since | |
3074 | we can't expect the parser to be in lock-step sync with the scanner. | |
3075 | (handle_action_dollar, handle_action_at): Use this var. | |
3076 | * tests/actions.at (Exotic Dollars): Test for the problem. | |
3077 | ||
3078 | 2002-10-12 Paul Eggert <eggert@twinsun.com> | |
3079 | ||
3080 | * lib/timevar.c [! IN_GCC && HAVE_SYS_TIME_H]: Include <sys/time.h>. | |
3081 | * m4/timevar.m4 (BISON_PREREQ_TIMEVAR): Check for <sys/time.h>. | |
3082 | Include <sys/time.h> when checking for clock_t and struct tms. | |
3083 | Use same include order as source. | |
3084 | This is for the SunOS 4.1.4 porting bug reported by Peter Klein in | |
3085 | <http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00016.html>. | |
3086 | ||
3087 | * lib/timevar.c: Update copyright date and clarify comments. | |
3088 | (get_time) [IN_GCC]: Keep the GCC version for reference. | |
3089 | ||
3090 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: Import | |
3091 | GCC version as of today, then merge Bison's changes. | |
3092 | Change "GCC" to "Bison" in copyright notice. timevar.def's | |
3093 | author is Akim, so change that too. | |
3094 | ||
3095 | * src/reader.c (grammar_current_rule_check): | |
3096 | Don't worry about the default action if $$ is untyped. | |
3097 | Prevents bogus warnings reported by Jim Gifford in | |
3098 | <http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00015.html>. | |
3099 | ||
3100 | * data/c.m4 (b4_token_enum): Do not define YYTOKENTYPE. | |
3101 | * data/glr.c, data/lalr1.cc, data/yacc.c: | |
3102 | Output token definitions before the first part of user declarations. | |
3103 | Fixes compatibility problem reported by Jim Gifford for kbd in | |
3104 | <http://mail.gnu.org/archive/html/bug-bison/2002-10/msg00014.html>. | |
3105 | ||
3106 | 2002-10-11 Paul Eggert <eggert@twinsun.com> | |
3107 | ||
3108 | * data/yacc.c (yyreport_parse_error): Remove, putting its body into... | |
3109 | (yyparse): here. This undoes some of the 2002-07-25 change. | |
3110 | Compatibility problem reported by Ralf S. Engelschall with | |
3111 | OSSP cfg <http://www.ossp.org/pkg/lib/cfg/>. | |
3112 | ||
3113 | 2002-10-11 Akim Demaille <akim@epita.fr> | |
3114 | ||
3115 | * tests/regression.at Characters Escapes): New. | |
3116 | * src/scan-gram.l (SC_ESCAPED_CHARACTER): Accept \' in strings and | |
3117 | characters. | |
3118 | Reported by Jan Nieuwenhuizen. | |
3119 | ||
3120 | 2002-10-11 Akim Demaille <akim@epita.fr> | |
3121 | ||
3122 | * po/id.po: New. | |
3123 | ||
3124 | 2002-10-10 Paul Eggert <eggert@twinsun.com> | |
3125 | ||
3126 | Portability fixes for bitsets; this also avoids several GCC | |
3127 | warnings. | |
3128 | ||
3129 | * lib/abitset.c: Include <stddef.h>, for offsetof. | |
3130 | * lib/lbitset.c: Likewise. | |
3131 | ||
3132 | * lib/abitset.c (abitset_bytes): Return a size that is aligned | |
3133 | properly for vectors of objects. Do not assume that adding a | |
3134 | header size to a multiple of a word size yields a value that is | |
3135 | properly aligned for the whole union. | |
3136 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
3137 | ||
3138 | * lib/bitset_stats.c (bitset_stats_bytes): Adjust to new, | |
3139 | unique names for structures. | |
3140 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
3141 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
3142 | ||
3143 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_empty_p, | |
3144 | abitset_copy1, abitset_not, abitset_equal_p, abitset_subset_p, | |
3145 | abitset_disjoint_p, abitset_and, abitset_and_cmp, abitset_andn, | |
3146 | abitset_andn_cmp, abitset_or, abitset_or_cmp, abitset_xor, | |
3147 | abitset_xor_cmp, abitset_and_or, abitset_and_or_cmp, | |
3148 | abitset_andn_or, abitset_andn_or_cmp, abitset_or_and, | |
3149 | abitset_or_and_cmp, abitset_copy): Supply prototype decls, | |
3150 | to improve the type-checking that GCC can do. | |
3151 | * lib/bitset.c (bitset_op4_cmp): Likewise. | |
3152 | * lib/bitset_stats.c (bitset_stats_count, | |
3153 | bitset_stats_empty_p, bitset_stats_ones, bitset_stats_zero, | |
3154 | bitset_stats_copy, bitset_stats_disjoint_p, | |
3155 | bitset_stats_equal_p, bitset_stats_not, bitset_stats_subset_p, | |
3156 | bitset_stats_and, bitset_stats_and_cmp, bitset_stats_andn, | |
3157 | bitset_stats_andn_cmp, bitset_stats_or, bitset_stats_or_cmp, | |
3158 | bitset_stats_xor, bitset_stats_xor_cmp, bitset_stats_and_or, | |
3159 | bitset_stats_and_or_cmp, bitset_stats_andn_or, | |
3160 | bitset_stats_andn_or_cmp, bitset_stats_or_and, | |
3161 | bitset_stats_or_and_cmp): Likewise. | |
3162 | * lib/lbitset.c (lbitset_and, lbitset_and_cmp, lbitset_andn, | |
3163 | lbitset_andn_cmp, lbitset_or, lbitset_or_cmp, lbitset_xor, | |
3164 | lbitset_xor_cmp, lbitset_empty_p, lbitset_ones, lbitset_not, | |
3165 | lbitset_subset_p, lbitset_disjoint_p, debug_lbitset): Likewise. | |
3166 | ||
3167 | * lib/abitset.h: Include bitset.h, not bbitset.h. | |
3168 | * lib/ebitset.h: Likewise. | |
3169 | * lib/lbitset.h: Likewise. | |
3170 | ||
3171 | * lib/bbitset.h: (enum_bitset_ops, enum_bitset_type): New types. | |
3172 | All instances of parameters of type enum bitset_opts are now of | |
3173 | type enum_bitset_opts, to conform to the C Standard, and similarly | |
3174 | for enum_bitset_type. | |
3175 | * lib/ebitset.c (enum_ebitset_find_mode): Likewise. | |
3176 | * lib/lbitset.c (enum_lbitset_find_mode): Likewise. | |
3177 | ||
3178 | Do not use "struct bitset_struct" to mean different things in | |
3179 | different modules. Not only is this confusing, it violates | |
3180 | the C Standard, which requires that structure types in different | |
3181 | modules must be compatible if one is to be passed to the other. | |
3182 | * lib/bbitset.h (bitset): Now points to a union, not to a struct. | |
3183 | All instances of "struct bitset_struct *" replaced with "bitset". | |
3184 | * lib/bitset.h (struct bitset_struct): Remove, replacing with.... | |
3185 | (union bitset_union, struct abitset_struct, struct ebitset_struct, | |
3186 | struct lbitset_struct, struct bitset_stats_struct): New types. | |
3187 | All uses of struct bitset_struct changed to union bitset_union, | |
3188 | etc. | |
3189 | * lib/abitset.c (struct abitset_struct, abitset, | |
3190 | struct bitset_struct): Remove. | |
3191 | * lib/bitset_stats.c (struct bitset_stats_struct, bitset_stats, | |
3192 | struct bitset_struct): Remove. | |
3193 | * lib/ebitset.c (struct ebitset_struct, ebitset, struct | |
3194 | bitset_struct): Remove. | |
3195 | * lib/lbitset.c (struct lbitset_struct, lbitset, bitset_struct): | |
3196 | Likewise. | |
3197 | ||
3198 | Do not call a function of type T using a call that assumes the | |
3199 | function is of a different type U. Standard C requires that a | |
3200 | function must be called with a type that is compatible with its | |
3201 | definition. | |
3202 | * lib/bbitset.h (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
3203 | New decls. | |
3204 | * lib/bitset.c (bitset_and_or_, bitset_andn_or_, bitset_or_and_): | |
3205 | New functions. | |
3206 | * lib/ebitset.c (PFV): Remove. | |
3207 | * lib/lbitset.c (PFV): Likewise. | |
3208 | * lib/ebitset.c (ebitset_and, ebitset_andn, ebitset_or, | |
3209 | ebitset_xor, ebitset_copy, ebitset_ones, ebitset_empty_p): New | |
3210 | decls. | |
3211 | (ebitset_and, ebitset_andn, ebitset_or, ebitset_xor): New functions. | |
3212 | (ebitset_vtable): Use them. | |
3213 | * lib/lbitset.c (lbitset_and, lbitset_andn, lbitset_or, | |
3214 | lbitset_xor): New functions. | |
3215 | (lbitset_vtable): Use them. | |
3216 | ||
3217 | * lib/bitset.h (bitset_next, bitset_prev, bitset_only_set_p): | |
3218 | Declare. | |
3219 | ||
3220 | * lib/bitsetv.c (bitsetv_alloc): Add a cast to (void *) to avoid a | |
3221 | GCC warning. | |
3222 | * lib/lbitset.c (LBITSET_CURRENT1): Likewise. | |
3223 | Use offsetof, for simplicity. | |
3224 | ||
3225 | 2002-10-06 Paul Eggert <eggert@twinsun.com> | |
3226 | ||
3227 | * lib/bitset.h (bitset_reset): Do not assume that bitset_word is | |
3228 | the same width as int. This reapplies a hunk of the 2002-08-12 patch | |
3229 | <http://mail.gnu.org/archive/html/bison-patches/2002-08/msg00007.html>, | |
3230 | which was inadvertently undone by the 2002-09-30 patch. | |
3231 | * lib/lbitset.c (debug_lbitset): Do not assume that bitset_word is | |
3232 | the same width as int. | |
3233 | ||
3234 | 2002-10-04 Paul Eggert <eggert@twinsun.com> | |
3235 | ||
3236 | Version 1.50. | |
3237 | ||
3238 | * configure.ac (AC_INIT), NEWS: Increment version number. | |
3239 | ||
3240 | * doc/bison.texinfo: Minor spelling, grammar, and white space | |
3241 | fixes. | |
3242 | (Symbols): Mention that any negative value returned from yylex | |
3243 | signifies end-of-input. Warn about negative chars. Mention | |
3244 | the portable Standard C character set. | |
3245 | ||
3246 | The GNU coding standard says CFLAGS and YFLAGS are reserved | |
3247 | for the installer to set. | |
3248 | * lib/Makefile.am (AM_CFLAGS): Renamed from CFLAGS. | |
3249 | * src/Makefile.am (AM_CFLAGS): Likewise. | |
3250 | (AM_YFLAGS): Renamed from YFLAGS. | |
3251 | ||
3252 | Fix some MAX and MIN problems. | |
3253 | * src/gram.h (ITEM_NUMBER_MIN): MIN_MAX -> INT_MIN. | |
3254 | * src/lalr.h (GOTO_NUMBER_MAX): INT_MAX -> SHRT_MAX. | |
3255 | * src/symtab.h (SYMBOL_NUMBER_MAX): New macro. | |
3256 | * src/reader.c (reader): Use it. | |
3257 | ||
3258 | * tests/regression.at (Braces parsing): Use grep, not fgrep, as | |
3259 | POSIX 1003.1-2001 has removed fgrep. | |
3260 | ||
3261 | 2002-10-04 Michael Hayes <m.hayes@elec.canterbury.ac.nz> | |
3262 | ||
3263 | * lib/bbitset.h (BITSET_WINDEX_MAX): Redefine so that it cannot be | |
3264 | interpreted as signed. | |
3265 | * lib/ebitset.c (ebitset_list): Fix bug. | |
3266 | ||
3267 | 2002-10-01 Paul Eggert <eggert@twinsun.com> | |
3268 | ||
3269 | More fixes for 64-bit hosts and large bitsets. | |
3270 | ||
3271 | * lib/abitset.c (struct abitset_struct.n_bits, abitset_small_list, | |
3272 | abitset_size, abitset_list, abitset_list_reverse, abitset_list): | |
3273 | Use bitset_bindex, not int or unsigned int or size_t, to count bits. | |
3274 | * lib/bbitset.h (struct bitset_vtable.size, struct bitset_vtable.count, | |
3275 | struct bitset_vtable.list, struct bitset_vtable.list_reverse, | |
3276 | bitset_count_, bitset_next, bitset_prev, bitset_first, bitset_last, | |
3277 | bitset_count_): Likewise. | |
3278 | * lib/bitset.h (bitset_iterator.num, bitset_iterator.i, | |
3279 | bitset_first, bitset_last): Likewise. | |
3280 | * lib/bitset_stats.c (bitset_stats_size, bitset_stats_list, | |
3281 | bitset_stats_list_reverse, bitset_stats_size, | |
3282 | bitset_stats_count, bitset_stats_list, bitset_stat_list_reverse): | |
3283 | Likewise. | |
3284 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
3285 | * lib/bitsetv.c (bitsetv_alloc, bitsetv_create, bitsetv_free, | |
3286 | bitsetv_zero, bitsetv_ones, bitsetv_transitive_closure, | |
3287 | bitsetv_reflexive_transitive_closure): Likewise. | |
3288 | * lib/bitsetv.h (bitsetv_alloc, bitsetv_create): Likewise. | |
3289 | * lib/ebitset.c (ebitset_size, ebitset_list, ebitset_list_reverse): | |
3290 | Likewise. | |
3291 | * lib/lbitset.c (lbitset_size, lbitset_list, lbitset_list_merge): | |
3292 | Likewise. | |
3293 | ||
3294 | * lib/abitset.c (abitset_ones, abitset_zero, abitset_bytes): | |
3295 | Use size_t, not unsigned int, to count bytes. | |
3296 | * lib/abitset.h (abitset_bytes): Likewise. | |
3297 | * lib/bitset.c (bitset_bytes, bitset_alloc, bitset_obstack_alloc): | |
3298 | Likewise. | |
3299 | * lib/bitset.h (bitset_bytes): Likewise. | |
3300 | * lib/bitset_stats.c (bitset_stats_bytes, bitset_stats_init): Likewise. | |
3301 | * lib/bitset_stats.h (bitset_stats_bytes): Likewise. | |
3302 | * lib/bitsetv.c (bitsetv_alloc): Likewise. | |
3303 | * lib/ebitset.c (ebitset_bytes): Likewise. | |
3304 | * lib/ebitset.h (ebitset_bytes): Likewise. | |
3305 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
3306 | * lib/lbitset.h (lbitset_bytes): Likewise. | |
3307 | ||
3308 | * lib/abitset.c (abitset_empty_p, abitset_not, abitset_equal_p, | |
3309 | abitset_subset_p, abitset_disjoint_p, abitset_and, | |
3310 | abitset_and_cmp, abitset_andn, abitset_andn_cmp, abitset_or, | |
3311 | abitset_or_cmp, abitset_xor, abitset_xor_cmp, abitset_and_or, | |
3312 | abitset_and_or_cmp, abitset_andn_or, abitset_andn_or_cmp, | |
3313 | abitset_or_and, abitset_or_and_cmp): | |
3314 | Use bitset_windex instead of unsigned int. | |
3315 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
3316 | * lib/ebitset.c (struct ebitset_struct.size, ebitset_elts_grow, | |
3317 | ebitset_elt_add, ebitset_elt_remove, ebitset_weed, | |
3318 | ebitset_elt_find, ebitset_list_reverse, ebitset_list, ebitset_init): | |
3319 | Likewise. | |
3320 | * lib/lbitset.c (lbitset_ones, lbitset_not): Likewise. | |
3321 | ||
3322 | * lib/bitset.c (bitset_print): | |
3323 | Use proper printf formats for widths of integer types. | |
3324 | * lib/bitset_stats.c (bitset_percent_histogram_print, | |
3325 | bitset_log_histogram_print, bitset_stats_print_1): Likewise. | |
3326 | * lib/bitsetv-print.c (bitsetv_matrix_dump): Likewise. | |
3327 | * lib/bitsetv.c (bitsetv_dump, debug_bitsetv): Likewise. | |
3328 | * lib/lbitset.c (lbitset_bytes): Likewise. | |
3329 | ||
3330 | * lib/bbitset.h (BITSET_BINDEX_MAX, BITSET_WINDEX_MAX, | |
3331 | BITSET_SIZE_MAX): New macros. | |
3332 | (BITSET_INDEX_MAX): Remove. It wasn't right, since it assumed that | |
3333 | sizeof (bitset_word) == sizeof (bitset_windex). All uses changed | |
3334 | to BITSET_WINDEX_MAX. | |
3335 | ||
3336 | * lib/bitset.c (bitset_next, bitset_prev, bitset_first, | |
3337 | bitset_last): Return BITSET_BINDEX_MAX (not -1) for no value, | |
3338 | since we now return the bitset_bindex type (not int). | |
3339 | ||
3340 | * lib/bitsetv.c (bitsetv_alloc): Check for arithmetic overflow | |
3341 | when computing sizes. | |
3342 | * lib/ebitset.c (ebitset_elts_grow): Likewise. | |
3343 | ||
3344 | * lib/lbitset.c (lbitset_elt_find): Simplify windex calculation | |
3345 | and avoid cast to unsigned. | |
3346 | ||
3347 | 2002-09-30 Akim Demaille <akim@epita.fr> | |
3348 | ||
3349 | * lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h, | |
3350 | * lib/bitset_stats.c, lib/bitsetv.c, lib/ebitset.c, lib/lbitset.c: | |
3351 | Updates from Michael Hayes. | |
3352 | ||
3353 | 2002-09-30 Art Haas <ahaas@neosoft.com> | |
3354 | ||
3355 | * configure.ac: Update AC_OUTPUT and AM_CONFIG_HEADER | |
3356 | invocations. | |
3357 | * tests/cxx-type.at (declarator): Don't rely on NDEBUG being not | |
3358 | defined. | |
3359 | ||
3360 | 2002-09-27 Akim Demaille <akim@epita.fr> | |
3361 | ||
3362 | Version 1.49c. | |
3363 | ||
3364 | 2002-09-27 Akim Demaille <akim@epita.fr> | |
3365 | ||
3366 | * configure.ac (AM_INIT_AUTOMAKE): We _need_ 1.7. | |
3367 | (Because of AC_LIBSOURCE). | |
3368 | ||
3369 | 2002-09-27 Akim Demaille <akim@epita.fr> | |
3370 | ||
3371 | Playing with Autoscan. | |
3372 | ||
3373 | * configure.ac: Remove the old LIBOBJ tweaks. | |
3374 | (AC_REPLACE_FUNCS): Add strrchr and strtol. | |
3375 | * lib/strrchr.c: New. | |
3376 | * lib/strtol.c: New, from the Coreutils 4.5.1. | |
3377 | ||
3378 | 2002-09-27 Akim Demaille <akim@epita.fr> | |
3379 | ||
3380 | Playing with Autoscan. | |
3381 | ||
3382 | * m4/prereq.m4 (jm_PREREQ_ARGMATCH, jm_FUNC_ARGMATCH): New. | |
3383 | * lib/Makefile.am (libbison_a_SOURCES): No longer include | |
3384 | argmatch.c and argmatch.h, since they are AC_LIBSOURCE'd. | |
3385 | * lib/strcasecmp.c, lib/strncasecmp.c, lib/memcmp.c: New, from the | |
3386 | Coreutils 4.5.1. | |
3387 | ||
3388 | 2002-09-24 Akim Demaille <akim@epita.fr> | |
3389 | ||
3390 | * doc/bison.texinfo (Stack Overflow): xref to Recursion. | |
3391 | (Frequently Asked Questions, Parser Stack Overflow): New. | |
3392 | ||
3393 | 2002-09-13 Akim Demaille <akim@epita.fr> | |
3394 | ||
3395 | Playing with autoscan. | |
3396 | ||
3397 | * src/reader.c (get_merge_function): Use xstrdup, not strdup. | |
3398 | * src/files.c (skeleton_find): Remove, unused. | |
3399 | * m4/memcmp.m4: New, from the Coreutils 4.5.1. | |
3400 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Run jm_FUNC_MEMCMP. | |
3401 | ||
3402 | 2002-09-13 Akim Demaille <akim@epita.fr> | |
3403 | ||
3404 | * configure.ac (AM_INIT_AUTOMAKE): Require Automake 1.6.3. | |
3405 | * Makefile.am (AUTOMAKE_OPTIONS): Don't. | |
3406 | ||
3407 | 2002-09-13 Akim Demaille <akim@epita.fr> | |
3408 | ||
3409 | * configure.ac: Require 2.54. | |
3410 | s/jm_FUNC_MALLOC/AC_FUNC_MALLOC/. | |
3411 | s/jm_FUNC_REALLOC/AC_FUNC_REALLOC/. | |
3412 | * m4/c-bs-a.m4, m4/malloc.m4, m4/mbstate_t.m4, m4/realloc.m4: | |
3413 | Remove, provided by Autoconf macros. | |
3414 | ||
3415 | 2002-09-12 Akim Demaille <akim@epita.fr> | |
3416 | ||
3417 | * m4/prereq.m4: Update, from Coreutils 4.5.1. | |
3418 | ||
3419 | 2002-09-12 Akim Demaille <akim@epita.fr> | |
3420 | ||
3421 | * m4/prereq.m4: Update, from Fileutils 4.1.5. | |
3422 | * configure.ac (jm_PREREQ_TEMPNAME): Invoke it. | |
3423 | Reported by Martin Mokrejs. | |
3424 | ||
3425 | 2002-09-10 Akim Demaille <akim@epita.fr> | |
3426 | ||
3427 | * src/parse-gram.y: Associate a human readable string to each | |
3428 | token type. | |
3429 | * tests/regression.at (Invalid inputs): Adjust. | |
3430 | ||
3431 | 2002-09-10 Gary V. Vaughan <gary@gnu.org> | |
3432 | ||
3433 | * tests/Makefile.am ($(srcdir)/package.m4): Bison now ships | |
3434 | with an Autoconf-2.5x style configure.ac. | |
3435 | ||
3436 | 2002-09-06 Paul Eggert <eggert@twinsun.com> | |
3437 | ||
3438 | * doc/bison.texinfo (Conditions): Make explicit that the GPL | |
3439 | exception applies only to yacc.c. This is a modification of a | |
3440 | patch originally suggested by Akim Demaille. | |
3441 | ||
3442 | 2002-09-06 Akim Demaille <akim@epita.fr> | |
3443 | ||
3444 | * data/c.m4 (b4_copyright): Move the GPL exception comment from | |
3445 | here to... | |
3446 | * data/yacc.c: here. | |
3447 | ||
3448 | * data/lalr1.cc (struct yyltype): Don't define it, since we use | |
3449 | LocationType. | |
3450 | (b4_ltype): Default to yy::Location from location.hh. | |
3451 | ||
3452 | 2002-09-04 Jim Meyering <jim@meyering.net> | |
3453 | ||
3454 | * data/yacc.c: Guard the declaration of yytoknum also with | |
3455 | `#ifdef YYPRINT', so it is declared only when used. | |
3456 | ||
3457 | 2002-09-04 Akim Demaille <akim@epita.fr> | |
3458 | ||
3459 | * configure.in: Rename as... | |
3460 | * configure.ac: this. | |
3461 | Bump to 1.49c. | |
3462 | ||
3463 | 2002-09-04 Akim Demaille <akim@epita.fr> | |
3464 | ||
3465 | * src/assoc.c, src/closure.c, src/gram.c, src/injections.c, | |
3466 | * src/lalr.c, src/LR0.c, src/relation.c, src/tables.c: Don't | |
3467 | translate maintainer only messages. | |
3468 | ||
3469 | 2002-08-12 Paul Eggert <eggert@twinsun.com> | |
3470 | ||
3471 | Version 1.49b. | |
3472 | ||
3473 | * Makefile.am (SUBDIRS): Remove intl. | |
3474 | (DISTCLEANFILES): Remove. | |
3475 | * NEWS: Mention that GNU M4 is now required. Clarify what is | |
3476 | meant by "larger grammars". Mention the pt_BR translation. | |
3477 | * configure.in (AC_CHECK_DECLS): Add getenv, getopt. | |
3478 | (AM_GNU_GETTEXT_VERSION): New macro, replacing GETTEXT_VERSION var. | |
3479 | Bump version from 0.11.2 to 0.11.5. | |
3480 | (BISON_PREREQ_STAGE): Remove. | |
3481 | (AM_GNU_GETTEXT): Use external gettext. | |
3482 | (AC_OUTPUT): Remove intl/Makefile. | |
3483 | ||
3484 | * config/depcomp, config/install-sh: Sync with Automake 1.6.3. | |
3485 | ||
3486 | * data/glr.c: Include string.h, for strlen. | |
3487 | (yyreportParseError): Use size_t for yysize. | |
3488 | (yy_yypstack): No longer nested inside yypstates, as nested | |
3489 | functions are not portable. Do not assume size_t is the | |
3490 | same width as int. | |
3491 | (yypstates): Do not assume that ptrdiff_t is the same width | |
3492 | as int, and similarly for yyposn and YYINDEX. | |
3493 | ||
3494 | * data/yacc.c: Fix comment about `$$ = $1': it can copy garbage. | |
3495 | ||
3496 | * lib/Makefile.am (INCLUDES): Do not include from the intl | |
3497 | directory, which has been removed. | |
3498 | * src/Makefile.am (INCLUDES): Likewise. | |
3499 | ||
3500 | * lib/Makefile.am (libbison_a_SOURCES): Add unlocked-io.h. | |
3501 | (bitsets_sources, additional_bitsets_sources, timevars_sources): | |
3502 | New vars. | |
3503 | ||
3504 | * lib/Makefile.am (libbison_a_SOURCES): Avoid +=, a GNU make extension. | |
3505 | * tests/Makefile.am (EXTRA_DIST): Likewise. | |
3506 | ||
3507 | * lib/abitset.c (abitset_reverse_list, ebitset_reverse_list): | |
3508 | Do not assume that bitset_windex is the same width as unsigned. | |
3509 | ||
3510 | * lib/abitset.c (abitset_unused_clear): Do not assume that | |
3511 | bitset_word is the same width as int. | |
3512 | * lib/bbitset.h (BITSET_INDEX_MAX, BITSET_MSB): Likewise. | |
3513 | * lib/bitset.h (bitset_set, bitset_reset): Likewise. | |
3514 | * lib/bitset_stats.c (bitset_stats_set, bitset_stats_reset): Likewise. | |
3515 | * lib/ebitset.c (ebitset_set, ebitset_reset): Likewise. | |
3516 | * lib/lbitset.c (lbitset_set, lbitset_reset): Likewise. | |
3517 | ||
3518 | * lib/abitset.c (abitset_op1): Use -1, not ~0, as memset arg (for | |
3519 | portability to one's complement hosts!). | |
3520 | * lib/ebitset.c (ebitset_op1): Likewise. | |
3521 | * lib/lbitset.c (lbitset_op1): Likewise. | |
3522 | ||
3523 | * lib/argmatch.c, lib/quotearg.c, quotearg.h: Sync with GNU tar. | |
3524 | * lib/argmatch.h, lib/basename.c, lib/dirname.c, lib/dirname.h, | |
3525 | lib/hash.c, lib/hash.h, lib/strnlen.c, lib/xmalloc.c: | |
3526 | Sync with fileutils. | |
3527 | * lib/error.c, lib/getopt.c, lib/getopt.h, lib/getopt1.c, | |
3528 | lib/gettext.h: Sync with diffutils. | |
3529 | ||
3530 | * lib/memrchr.c, lib/mkstemp.c, lib/strchr.c, lib/strnlen.c, | |
3531 | lib/strspn.c, lib/tempname.c: Use GPL, not LGPL. | |
3532 | ||
3533 | * lib/obstack.c, lib/obstack.h: Sync with fileutils, except use | |
3534 | PROTOTYPES to check for prototypes, and "defined __STDC__" to | |
3535 | check for void *. | |
3536 | ||
3537 | * lib/bbitset.h (BITSET_WORD_BITS): Now of type unsigned, not | |
3538 | size_t; the old version tried to do this but casted improperly. | |
3539 | (bitset_bindex, bitset_windex): Now size_t, not unsigned long. | |
3540 | (bitset_test): Now returns int, not unsigned long. | |
3541 | ||
3542 | * lib/bitset_stats.c: Include "gettext.h". | |
3543 | (_): New macro. | |
3544 | (bitset_stats_set, bitset_stats_reset, bitset_stats_test): Don't | |
3545 | name locals "index", as it generates unnecessary warnings on some | |
3546 | hosts that have an "index" function. | |
3547 | ||
3548 | * lib/bitset_stats.c (bitset_stats_print_1, bitset_stats_print, | |
3549 | bitset_stats_read, bitset_stats_write): Wrap strings in _() if | |
3550 | they need translation. | |
3551 | * src/LR0.c (state_list_append, new_itemsets, get_state, | |
3552 | append_states, generate_states): Likewise. | |
3553 | * src/assoc.c (assoc_to_string): Likewise. | |
3554 | * src/closure.c (print_closure, set_firsts, closure): Likewise. | |
3555 | * src/gram.c (grammar_dump): Likewise. | |
3556 | * src/injections.c (injections_compute): Likewise. | |
3557 | * src/lalr.c (lookaheads_print): Likewise. | |
3558 | * src/relation.c (relation_transpose): Likewise. | |
3559 | * src/scan-gram.l: Likewise. | |
3560 | * src/tables.c (table_grow, pack_vector): Likewise. | |
3561 | ||
3562 | * m4/Makefile.am (EXTRA_DIST): Remove codeset.m4, | |
3563 | glibc21.m4, isc-posix.m4 lcmessage.m4, stage.m4. | |
3564 | * m4/malloc.m4, m4/realloc.m4: Sync with diffutils. | |
3565 | * m4/mbstate_t.m4: Sync with fileutils. | |
3566 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): AC_MBSTATE_T -> AC_TYPE_MBSTATE_T. | |
3567 | ||
3568 | * po/LINGUAS: Add pt_BR. | |
3569 | * po/POTFILES.in: Add src/assoc.c, src/closure.c, src/gram.c, | |
3570 | src/main.c, src/relation.c, src/state.c, lib/bitset_stats.c, | |
3571 | lib/timevar.c. | |
3572 | Use src/parse-gram.y instead of src/parse-gram.c, as the gettext | |
3573 | manual recommends. | |
3574 | Similarly, use src/scan-gram.l instead of src/scan-gram.c. | |
3575 | ||
3576 | * src/complain.c (strerror_r): Remove decl; not needed. | |
3577 | (strerror): Use same pattern as ../lib/error.c. | |
3578 | ||
3579 | * src/files.c, src/files.h (compute_header_macro): Remove; unused. | |
3580 | ||
3581 | * src/gram.c (grammar_dump): Do not assume ptrdiff_t fits in int. | |
3582 | ||
3583 | * src/main.c (main): Cast result of bindtextdomain and textdomain | |
3584 | to void, to avoid a GCC warning when --disable-nls is in effect. | |
3585 | ||
3586 | * src/scan-gram.l: Use strings rather than escapes when possible, | |
3587 | to minimize the number of warnings from xgettext. | |
3588 | (handle_action_dollar, handle_action_at): Don't use isdigit, | |
3589 | as it mishandles negative chars and it may not work as expected | |
3590 | outside the C locale. | |
3591 | ||
3592 | * src/symtab.c (symbol_get): Don't cast LHS of an assignment; | |
3593 | this is a GCC extension and is not portable to other compilers. | |
3594 | ||
3595 | * src/system.h (alloca): Use same pattern as ../lib/error.c. | |
3596 | Do not include <ctype.h>; no longer needed. | |
3597 | Do not include <malloc.h>; no longer needed (and generates | |
3598 | warnings on OpenBSD 3.0). | |
3599 | ||
3600 | * tests/cxx-type.at (yylex): Do not pass signed char to isupper; | |
3601 | it's not portable. | |
3602 | ||
3603 | * tests/regression.at: Do not use 'cc -c input.c -o input'; | |
3604 | Sun C rejects this. Instead, use 'cc -c input.c -o input.o'. | |
3605 | ||
3606 | * tests/synclines.at (AC_SYNCLINES_COMPILE): Accept any nonzero | |
3607 | exit status as failure, not just exit status 1. Sun C exits | |
3608 | with status 2 sometimes. | |
3609 | ||
3610 | * tests/torture.at (AT_INCREASE_DATA_SIZE): New macro. | |
3611 | Use it for the two large tests. | |
3612 | ||
3613 | 2002-08-02 Akim Demaille <akim@epita.fr> | |
3614 | ||
3615 | * src/conflicts.c (conflicts_output): Don't output rules never | |
3616 | reduced here, since anyway that computation doesn't work. | |
3617 | * src/gram.h, src/gram.h (rule_filter_t, rule_useful_p) | |
3618 | (rule_useless_p, rule_never_reduced_p): New. | |
3619 | (grammar_rules_partial_print): Use a filter instead of a range. | |
3620 | Display the title only if needed. | |
3621 | (grammar_rules_print): Adjust. | |
3622 | (grammar_rules_never_reduced_report): New. | |
3623 | * src/tables.c (action_row): Move the computation of rules never | |
3624 | reduced to... | |
3625 | (token_actions): here. | |
3626 | * src/main.c (main): Make the parser before making the report, so | |
3627 | that rules never reduced are computed. | |
3628 | Call grammar_rules_never_reduced_report. | |
3629 | * src/print.c (print_results): Report rules never reduced. | |
3630 | * tests/conflicts.at, tests/reduce.at: Adjust. | |
3631 | ||
3632 | 2002-08-01 Akim Demaille <akim@epita.fr> | |
3633 | ||
3634 | Instead of attaching lookaheads and duplicating the rules being | |
3635 | reduced by a state, attach the lookaheads to the reductions. | |
3636 | ||
3637 | * src/state.h (state_t): Remove the `lookaheads', | |
3638 | `lookaheads_rule' member. | |
3639 | (reductions_t): Add a `lookaheads' member. | |
3640 | Use a regular array for the `rules'. | |
3641 | * src/state.c (reductions_new): Initialize the lookaheads member | |
3642 | to 0. | |
3643 | (state_rule_lookaheads_print): Adjust. | |
3644 | * src/state.h, src/state.c (state_reductions_find): New. | |
3645 | * src/conflicts.c (resolve_sr_conflict, set_conflicts) | |
3646 | (count_rr_conflicts): Adjust. | |
3647 | * src/lalr.c (LArule): Remove. | |
3648 | (add_lookback_edge): Adjust. | |
3649 | (state_lookaheads_count): New. | |
3650 | (states_lookaheads_initialize): Merge into... | |
3651 | (initialize_LA): this. | |
3652 | (lalr_free): Adjust. | |
3653 | * src/main.c (main): Don't free nullable and derives too early: it | |
3654 | is used by --verbose. | |
3655 | * src/print.c, src/print_graph.c, src/tables.c: Adjust. | |
3656 | ||
3657 | 2002-08-01 Akim Demaille <akim@epita.fr> | |
3658 | ||
3659 | * src/derives.h, src/derives.c (derives): A `rule_t***' instead of | |
3660 | `rule_number_t**'. | |
3661 | (set_derives, free_derives): Rename as... | |
3662 | (derives_compute, derives_free): this. | |
3663 | Adjust all dependencies. | |
3664 | * src/nullable.c (set_nullable, free_nullable): Rename as... | |
3665 | (nullable_compute, nullable_free): these. | |
3666 | (rule_list_t): Store rule_t *, not rule_number_t. | |
3667 | * src/state.c (state_rule_lookaheads_print): Directly compare rule | |
3668 | pointers, instead of their numbers. | |
3669 | * src/main.c (main): Call nullable_free, and derives_free earlier, | |
3670 | as they were lo longer used. | |
3671 | ||
3672 | 2002-08-01 Akim Demaille <akim@epita.fr> | |
3673 | ||
3674 | * lib/timevar.c (get_time): Include children time. | |
3675 | * src/lalr.h (LA, LArule): Don't export them: used with the | |
3676 | state_t. | |
3677 | * src/lalr.c (LA, LArule): Static. | |
3678 | * src/lalr.h, src/lalr.c (lalr_free): New. | |
3679 | * src/main.c (main): Call it. | |
3680 | * src/tables.c (pack_vector): Check whether loc is >= to the | |
3681 | table_size, not >. | |
3682 | (pack_tables): Don't free froms, tos, conflict_tos, and pos... | |
3683 | (tables_generate): do it, since that's also it which allocates | |
3684 | them. | |
3685 | Don't free LA and LArule, main does. | |
3686 | ||
3687 | 2002-07-31 Akim Demaille <akim@epita.fr> | |
3688 | ||
3689 | Separate parser tables computation and output. | |
3690 | ||
3691 | * src/output.c (nvectors, base_t, base, base_ninf, conflict_table) | |
3692 | (conflict_list, conflict_list_cnt, table, check, table_ninf) | |
3693 | (yydefgoto, yydefact, high): Move to... | |
3694 | * src/tables.h, src/tables.c: here. | |
3695 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
3696 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
3697 | (symbol_number_to_vector_number, nvectors, BASE_MAX, BASE_MIN) | |
3698 | (froms, tos, conflict_tos, tally, width, action_t, ACTION_MAX) | |
3699 | (ACTION_MIN, actrow, order, nentries, pos, conflrow) | |
3700 | (conflict_list_free, table_size, lowzero, table_grow, conflict_row) | |
3701 | (action_row, save_row, token_actions, save_column, default_goto) | |
3702 | (goto_actions, sort_actions, matching_state, pack_vector) | |
3703 | (table_ninf_remap, pack_table, prepare_actions): Move to... | |
3704 | * src/tables.c: here. | |
3705 | * src/tables.h, src/tables.c(tables_generate, tables_free): New. | |
3706 | * src/output.c (token_actions, output_base, output_conflicts) | |
3707 | (output_check): Merge into... | |
3708 | (prepare_actions): this. | |
3709 | (actions_output): Rename as... | |
3710 | (user_actions_output): this. | |
3711 | * src/main.c (main): Call tables_generate and tables_free. | |
3712 | ||
3713 | 2002-07-31 Akim Demaille <akim@epita.fr> | |
3714 | ||
3715 | Steal GCC's --time-report support. | |
3716 | ||
3717 | * lib/timevar.c, lib/timevar.h, lib/timevar.def: New, | |
3718 | stolen/adjusted from GCC. | |
3719 | * m4/stage.m4: Remove time related checks. | |
3720 | * m4/timevar.m4: New. | |
3721 | * configure.in: Adjust. | |
3722 | * src/system.h: Adjust to using timevar.h. | |
3723 | * src/getargs.h, src/getargs.c: Support trace_time for | |
3724 | --trace=time. | |
3725 | * src/main.c (stage): Remove. | |
3726 | (main): Replace `stage' invocations with timevar calls. | |
3727 | * src/output.c: Insert pertinent timevar calls. | |
3728 | ||
3729 | 2002-07-31 Akim Demaille <akim@epita.fr> | |
3730 | ||
3731 | Let --trace have arguments. | |
3732 | ||
3733 | * src/getargs.h (enum trace_e): New. | |
3734 | * src/getargs.c (trace_args, trace_types, trace_argmatch): New. | |
3735 | (long_options, short_options): --trace/-T takes an optional | |
3736 | argument. | |
3737 | Change all the uses of trace_flag to reflect the new flags. | |
3738 | * tests/sets.at (Firsts, Nullable, Broken Closure): Use --trace=sets. | |
3739 | ||
3740 | Strengthen `stage' portability. | |
3741 | ||
3742 | * m4/stage.m4 (BISON_PREREQ_STAGE): New. | |
3743 | * configure.in: Use it. | |
3744 | Don't check for malloc.h and sys/times.h. | |
3745 | * src/system.h: Include them when appropriate. | |
3746 | * src/main.c (stage): Compile only when mallinfo, struct mallinfo, | |
3747 | times and struct tms are available. | |
3748 | ||
3749 | 2002-07-30 Akim Demaille <akim@epita.fr> | |
3750 | ||
3751 | In verbose parse error message, don't report `error' as an | |
3752 | expected token. | |
3753 | * tests/actions.at (Printers and Destructors): Adjust. | |
3754 | * tests/calc.at (Calculator $1): Adjust. | |
3755 | * data/yacc.c, data/glr.c, data/lalr1.c: When making the verbose | |
3756 | error message, do not report the parser accepts the error token in | |
3757 | that state. | |
3758 | ||
3759 | 2002-07-30 Akim Demaille <akim@epita.fr> | |
3760 | ||
3761 | Normalize conflict related messages. | |
3762 | ||
3763 | * src/complain.h, src/complain.c (warn, complain): New. | |
3764 | * src/conflicts.c (conflicts_print): Use them. | |
3765 | (conflict_report_yacc): New, extracted from... | |
3766 | (conflicts_print): here. | |
3767 | * tests/conflicts.at, tests/existing.at: Adjust. | |
3768 | ||
3769 | 2002-07-30 Akim Demaille <akim@epita.fr> | |
3770 | ||
3771 | Report rules which are never reduced by the parser: those hidden | |
3772 | by conflicts. | |
3773 | ||
3774 | * src/LR0.c (save_reductions): Don't make the final state too | |
3775 | different: save its reduction (accept) instead of having a state | |
3776 | without any action (no shift or goto, no reduce). | |
3777 | Note: the final state is now a ``regular'' state, i.e., the | |
3778 | parsers now contain `reduce 0' as default reduction. | |
3779 | Nevertheless, since they decide to `accept' when yystate = | |
3780 | final_state, they still will not reduce rule 0. | |
3781 | * src/print.c (print_actions, print_reduction): Adjust. | |
3782 | * src/output.c (action_row): Track reduced rules. | |
3783 | (token_actions): Report rules never reduced. | |
3784 | * tests/conflicts.at, tests/regression.at: Adjust. | |
3785 | ||
3786 | 2002-07-30 Akim Demaille <akim@epita.fr> | |
3787 | ||
3788 | `stage' was accidently included in a previous patch. | |
3789 | Initiate its autoconfiscation. | |
3790 | ||
3791 | * configure.in: Look for malloc.h and sys/times.h. | |
3792 | * src/main.c (stage): Adjust. | |
3793 | Report only when trace_flag. | |
3794 | ||
3795 | 2002-07-29 Akim Demaille <akim@epita.fr> | |
3796 | ||
3797 | * src/state.h, src/state.c (transitions_t): Holds state_t*'s, not | |
3798 | state_number_t. | |
3799 | (errs_t): symbol_t*, not symbol_number_t. | |
3800 | (reductions_t): rule_t*, not rule_number_t. | |
3801 | (FOR_EACH_SHIFT): New. | |
3802 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/output.c | |
3803 | * src/print.c, src/print_graph.c: Adjust. | |
3804 | ||
3805 | 2002-07-29 Akim Demaille <akim@epita.fr> | |
3806 | ||
3807 | Use $accept and $end, as BYacc and BTYacc do, instead of $axiom and $. | |
3808 | ||
3809 | * src/symtab.h, src/symtab.c (eoftoken, axiom): Rename as... | |
3810 | (endtoken, accept): these. | |
3811 | * src/reader.c (reader): Set endtoken's default tag to "$end". | |
3812 | Set undeftoken's tag to "$undefined" instead of "$undefined.". | |
3813 | * doc/bison.texinfo (Table of Symbols): Mention $accept and $end. | |
3814 | Adjust. | |
3815 | ||
3816 | 2002-07-29 Akim Demaille <akim@epita.fr> | |
3817 | ||
3818 | * src/reduce.c (reduce_grammar): When the language is empty, | |
3819 | complain about the start symbol, not the axiom. | |
3820 | Use its location. | |
3821 | * tests/reduce.at (Empty Language): New. | |
3822 | ||
3823 | 2002-07-26 Akim Demaille <akim@epita.fr> | |
3824 | ||
3825 | * src/reader.h, src/reader.c (gram_error): ... can't get | |
3826 | yycontrol without making too strong assumptions on the parser | |
3827 | itself. | |
3828 | * src/output.c (prepare_tokens): Use the real 0th value of | |
3829 | token_translations instead of `0'. | |
3830 | * src/parse-gram.y (yyerror): Don't rely on yycontrol being | |
3831 | visible here. | |
3832 | * data/yacc.c (yyreport_parse_error): Rename yylocation as yylloc | |
3833 | for the time being: %locations ought to provide it to yyerror. | |
3834 | ||
3835 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3836 | ||
3837 | * src/output.c (prepare_tokens): Go up to ntokens, not ntokens + 1. | |
3838 | * doc/bison.texinfo (Decl Summary): s/$illegal/$undefined./. | |
3839 | * tests/regression.at (Web2c Actions): Adjust. | |
3840 | ||
3841 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3842 | ||
3843 | Stop storing rules from 1 to nrules + 1. | |
3844 | ||
3845 | * src/LR0.c, src/closure.c, src/derives.c, src/gram.c, src/lalr.c | |
3846 | * src/nullable.c, src/output.c, src/print.c, src/reader.c | |
3847 | * src/reduce.c: Allocate and free from &rules[0], not &rules[1]. | |
3848 | Iterate from 0 to nrules. | |
3849 | Use rule_number_as_item_number and item_number_as_rule_number. | |
3850 | Adjust to `derive' now containing possibly 0. | |
3851 | * src/gram.h (rule_number_as_item_number, item_number_as_rule_number): | |
3852 | Handle the `- 1' part in rule numbers from/to item numbers. | |
3853 | * src/conflicts.c (log_resolution): Fix the message which reversed | |
3854 | shift and reduce. | |
3855 | * src/output.c (action_row): Initialize default_rule to -1. | |
3856 | (token_actions): Adjust. | |
3857 | * tests/sets.at (Nullable, Firsts): Fix the previously bogus | |
3858 | expected output. | |
3859 | * tests/conflicts.at (Resolved SR Conflicts): Likewise. | |
3860 | ||
3861 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3862 | ||
3863 | * data/c.m4 (b4_c_function, b4_c_ansi_args, b4_c_ansi_arg) | |
3864 | (b4_c_knr_arg_names, b4_c_knr_arg_name, b4_c_knr_arg_decls) | |
3865 | (b4_c_knr_arg_decl): New. | |
3866 | * data/yacc.c: Use it to define yysymprint, yydestruct, and | |
3867 | yyreport_parse_error. | |
3868 | ||
3869 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3870 | ||
3871 | * data/yacc.c (yyreport_parse_error): New, extracted from... | |
3872 | (yyparse): here. | |
3873 | (yydestruct, yysymprint): Move above yyparse. | |
3874 | Be K&R compliant. | |
3875 | ||
3876 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3877 | ||
3878 | * data/c.m4 (b4_ints_in, b4_int_type, b4_int_type_for): New, | |
3879 | replace... | |
3880 | (b4_sint_type, b4_uint_type): these. | |
3881 | * data/yacc.c, data/glr.c, data/lalr1.cc: Use b4_int_type_for. | |
3882 | * tests/regression.at (Web2c Actions): Adjust. | |
3883 | ||
3884 | 2002-07-25 Akim Demaille <akim@epita.fr> | |
3885 | ||
3886 | * src/gram.h (TIEM_NUMBER_MAX): New. | |
3887 | (item_number_of_rule_number, rule_number_of_item_number): Rename | |
3888 | as... | |
3889 | (rule_number_as_item_number, item_number_as_rule_number): these. | |
3890 | Adjust dependencies. | |
3891 | * src/output.c (vector_number_t, VECTOR_NUMBER_MAX) | |
3892 | (VECTOR_NUMBER_MIN, state_number_to_vector_number) | |
3893 | (symbol_number_to_vector_number): New. | |
3894 | (order): Of vector_number_t* type. | |
3895 | (base_t, BASE_MAX, BASE_MIN): New. | |
3896 | (froms, tos, width, pos, check): Of base_t type. | |
3897 | (action_number_t, ACTION_MIN, ACTION_MAX): New. | |
3898 | (actrow): Of action_number_t type. | |
3899 | (conflrow): Of unsigned int type. | |
3900 | (table_ninf, base_ninf): New. | |
3901 | (GENERATE_MUSCLE_INSERT_TABLE): Also output the `*_min' value. | |
3902 | (muscle_insert_int_table, muscle_insert_base_table) | |
3903 | (muscle_insert_rule_number_table): New. | |
3904 | (prepare_tokens): Output `toknum' as int_table. | |
3905 | (action_row): Returns a rule_number_t. | |
3906 | Use ACTION_MIN, not SHRT_MIN. | |
3907 | (token_actions): yydefact is rule_number_t*. | |
3908 | (table_ninf_remap): New. | |
3909 | (pack_table): Use it for `base' and `table'. | |
3910 | * data/yacc.c, data/glr.c, data/lalr1.cc (YYFLAG): Remove, | |
3911 | replaced with... | |
3912 | (YYPACT_NINF, YYTABLE_NINF): these. | |
3913 | (yypact, yytable): Compute their types instead of hard-coded | |
3914 | `short'. | |
3915 | * tests/regression.at (Web2c Actions): Adjust. | |
3916 | ||
3917 | 2002-07-19 Akim Demaille <akim@epita.fr> | |
3918 | ||
3919 | * src/scan-gram.l (id): Can start with an underscore. | |
3920 | ||
3921 | 2002-07-16 Akim Demaille <akim@epita.fr> | |
3922 | ||
3923 | * src/assoc.c, src/asssoc.h (assoc_t, assoc_to_string): New. | |
3924 | Adjust all former `associativity' dependencies. | |
3925 | * src/symtab.c (symbol_new): Default associativity is `undef', not | |
3926 | `right'. | |
3927 | (symbol_check_alias_consistence): Adjust. | |
3928 | ||
3929 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3930 | ||
3931 | * doc/bison.texinfo: Properly set the ``header'' part. | |
3932 | Use @dircategory ``GNU programming tools'' as per Texinfo's | |
3933 | documentation. | |
3934 | Use @copying. | |
3935 | ||
3936 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3937 | ||
3938 | * lib/quotearg.h: Protect against multiple inclusions. | |
3939 | * src/location.h (location_t): Add a `file' member. | |
3940 | (LOCATION_RESET, LOCATION_PRINT): Adjust. | |
3941 | * src/complain.c (warn_at, complain_at, fatal_at): Drop | |
3942 | `error_one_per_line' support. | |
3943 | ||
3944 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3945 | ||
3946 | * src/complain.h, src/complain.c (warn, complain): Remove, unused. | |
3947 | * src/reader.c (lineno): Remove. | |
3948 | Adjust all dependencies. | |
3949 | (get_merge_function): Take a location and use complain_at. | |
3950 | * src/symtab.h, src/symtab.c (symbol_make_alias): Likewise. | |
3951 | * tests/regression.at (Invalid inputs, Mixing %token styles): | |
3952 | Adjust. | |
3953 | ||
3954 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3955 | ||
3956 | * src/parse-gram.y (rules_or_grammar_declaration): Add an error | |
3957 | recovery rule, and forbid extensions when --yacc. | |
3958 | (gram_error): Use complain_at. | |
3959 | * src/reader.c (reader): Exit if there were parse errors. | |
3960 | ||
3961 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3962 | ||
3963 | * tests/synclines.at (AT_SYNCLINES_COMPILE): New. | |
3964 | (AT_TEST_SYNCLINE): Adjust to unusual GCC outputs. | |
3965 | Reported by R Blake <blakers@mac.com>. | |
3966 | ||
3967 | 2002-07-09 Akim Demaille <akim@epita.fr> | |
3968 | ||
3969 | * data/yacc.c: Output the copyright notive in the header. | |
3970 | ||
3971 | 2002-07-03 Akim Demaille <akim@epita.fr> | |
3972 | ||
3973 | * src/output.c (froms, tos): Are state_number_t. | |
3974 | (save_column): sp, sp1, and sp2 are state_number_t. | |
3975 | (prepare): Rename `final' as `final_state_number', `nnts' as | |
3976 | `nterms_number', `nrules' as `rules_number', `nstates' as | |
3977 | `states_number', and `ntokens' as `tokens_number'. Remove `nsym', | |
3978 | unused. | |
3979 | * data/yacc.c, data/glr.c, data/lalr1.cc: Adjust. | |
3980 | * data/lalr1.cc (nsym_): Remove, unused. | |
3981 | ||
3982 | 2002-07-03 Akim Demaille <akim@epita.fr> | |
3983 | ||
3984 | * src/lalr.h, src/lalr.c (goto_number_t): New. | |
3985 | * src/lalr.c (goto_list_t): New. | |
3986 | Propagate them. | |
3987 | * src/nullable.c (rule_list_t): New. | |
3988 | Propagate. | |
3989 | * src/types.h: Remove. | |
3990 | ||
3991 | 2002-07-03 Akim Demaille <akim@epita.fr> | |
3992 | ||
3993 | * src/closure.c (print_fderives): Use rule_rhs_print. | |
3994 | * src/derives.c (print_derives): Use rule_rhs_print. | |
3995 | (rule_list_t): New, replaces `shorts'. | |
3996 | (set_derives): Add comments. | |
3997 | * tests/sets.at (Nullable, Firsts): Adjust. | |
3998 | ||
3999 | 2002-07-03 Akim Demaille <akim@epita.fr> | |
4000 | ||
4001 | * src/output.c (prepare_actions): Free `tally' and `width'. | |
4002 | (prepare_actions): Allocate and free `order'. | |
4003 | * src/symtab.c (symbols_free): Free `symbols'. | |
4004 | * src/scan-gram.l (scanner_free): Clear Flex's scanners memory. | |
4005 | * src/output.c (m4_invoke): Move to... | |
4006 | * src/scan-skel.l: here. | |
4007 | (<<EOF>>): Close yyout, and free its name. | |
4008 | ||
4009 | 2002-07-03 Akim Demaille <akim@epita.fr> | |
4010 | ||
4011 | Fix some memory leaks, and fix a bug: state 0 was examined twice. | |
4012 | ||
4013 | * src/LR0.c (new_state): Merge into... | |
4014 | (state_list_append): this. | |
4015 | (new_states): Merge into... | |
4016 | (generate_states): here. | |
4017 | (set_states): Don't ensure a proper `errs' state member here, do it... | |
4018 | * src/conflicts.c (conflicts_solve): here. | |
4019 | * src/state.h, src/state.c: Comment changes. | |
4020 | (state_t): Rename member `shifts' as `transitions'. | |
4021 | Adjust all dependencies. | |
4022 | (errs_new): For consistency, also take the values as argument. | |
4023 | (errs_dup): Remove. | |
4024 | (state_errs_set): New. | |
4025 | (state_reductions_set, state_transitions_set): Assert that no | |
4026 | previous value was assigned. | |
4027 | (state_free): New. | |
4028 | (states_free): Use it. | |
4029 | * src/conflicts.c (resolve_sr_conflict): Don't use an `errs_t' as | |
4030 | temporary storage: use `errs' and `nerrs' as elsewhere. | |
4031 | (set_conflicts): Allocate and free this `errs'. | |
4032 | ||
4033 | 2002-07-02 Akim Demaille <akim@epita.fr> | |
4034 | ||
4035 | * lib/libiberty.h: New. | |
4036 | * lib: Update the bitset implementation from upstream. | |
4037 | * src/closure.c, src/lalr.c, src/output.c, src/print_graph.c, | |
4038 | * src/state.c: Use BITSET_FOR_EACH, not BITSET_EXECUTE. | |
4039 | * src/main.c: Adjust bitset stats calls. | |
4040 | ||
4041 | 2002-07-01 Paul Eggert <eggert@twinsun.com> | |
4042 | ||
4043 | * src/scan-gram.l (<SC_ESCAPED_CHARACTER>): Convert to unsigned | |
4044 | char, so that negative chars don't collide with $. | |
4045 | ||
4046 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4047 | ||
4048 | Have the GLR tests be `warning' checked, and fix the warnings. | |
4049 | ||
4050 | * data/glr.c (YYFPRINTF): Always define it, not only when YYDEBUG | |
4051 | (yyuserAction, yyreportAmbiguity): `Use' all the arguments. | |
4052 | (yyremoveDeletes): `yyi' and `yyj' are size_t. | |
4053 | Use YYFPRINTF when under if (YYDEBUG) to avoid empty `if' bodies. | |
4054 | (yyaddDeferredAction): static. | |
4055 | (yyglrReduce): yyi, yyk, amd yyposn are size_t. | |
4056 | (yyreportParseError): yyprefix is const. | |
4057 | yytokenp is used only when verbose. | |
4058 | (yy__GNUC__): Replace with __GNUC__. | |
4059 | (yypdumpstack): yyi is size_t. | |
4060 | (yypreference): Un-yy local variables and arguments, to avoid | |
4061 | clashes with `yyr1'. Anyway, we are not in the user name space. | |
4062 | (yytname_size): be an int, as is compared with ints. | |
4063 | * tests/testsuite.at (AT_COMPILE, AT_PARSER_CHECK): New. | |
4064 | Use them. | |
4065 | * tests/cxx-gram.at: Use quotation to protect $1. | |
4066 | Use AT_COMPILE to enable warnings hunts. | |
4067 | Prototype yylex and yyerror. | |
4068 | `Use' argc. | |
4069 | Include `string.h', not `strings.h'. | |
4070 | Produce and prototype stmtMerge only when used. | |
4071 | yylex takes a location. | |
4072 | ||
4073 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4074 | ||
4075 | We spend a lot of time in quotearg, in particular when --verbose. | |
4076 | ||
4077 | * src/symtab.c (symbol_get): Store a quoted version of the key. | |
4078 | (symbol_tag_get, symbol_tag_get_n, symbol_tag_print): Remove. | |
4079 | Adjust all callers. | |
4080 | ||
4081 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4082 | ||
4083 | * src/state.h (reductions_t): Rename member `nreds' as num. | |
4084 | (errs_t): Rename members `nerrs' and `errs' as `num' and `symbols'. | |
4085 | * src/state.c (ERRS_ALLOC, REDUCTIONS_ALLOC): Use the correct types. | |
4086 | ||
4087 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4088 | ||
4089 | * src/state.h, src/state.c (shift_t, SHIFT_SYMBOL, SHIFT_IS_SHIFT) | |
4090 | (SHIFT_IS_GOTO, SHIFT_IS_ERROR, SHIFT_DISABLE, SHIFT_IS_DISABLED) | |
4091 | (shifts_to): Rename as... | |
4092 | (transition_t, TRANSITION_SYMBOL, TRANSITION_IS_TRANSITION) | |
4093 | (TRANSITION_IS_GOTO, TRANSITION_IS_ERROR, TRANSITION_DISABLE) | |
4094 | (TRANSITION_IS_DISABLED, transitions_to): these. | |
4095 | ||
4096 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4097 | ||
4098 | * src/print.c (print_shifts, print_gotos): Merge into... | |
4099 | (print_transitions): this. | |
4100 | (print_transitions, print_errs, print_reductions): Align the | |
4101 | lookaheads columns. | |
4102 | (print_core, print_transitions, print_errs, print_state, | |
4103 | print_grammar): Output empty lines separator before, not after. | |
4104 | (state_default_rule_compute): Rename as... | |
4105 | (state_default_rule): this. | |
4106 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
4107 | (Unresolved SR Conflicts, Resolved SR Conflicts): Adjust. | |
4108 | * tests/regression.at (Rule Line Numbers, Web2c Report): Adjust. | |
4109 | ||
4110 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4111 | ||
4112 | Display items as we display rules. | |
4113 | ||
4114 | * src/gram.h, src/gram.c (rule_lhs_print): New. | |
4115 | * src/gram.c (grammar_rules_partial_print): Use it. | |
4116 | * src/print.c (print_core): Likewise. | |
4117 | * tests/conflicts.at (Defaulted Conflicted Reduction), | |
4118 | (Unresolved SR Conflicts): Adjust. | |
4119 | (Unresolved SR Conflicts): Adjust and rename as... | |
4120 | (Resolved SR Conflicts): this, as was meant. | |
4121 | * tests/regression.at (Web2c Report): Adjust. | |
4122 | ||
4123 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4124 | ||
4125 | * src/print.c (state_default_rule_compute): New, extracted from... | |
4126 | (print_reductions): here. | |
4127 | Pessimize, but clarify the code. | |
4128 | * tests/conflicts.at (Defaulted Conflicted Reduction): New. | |
4129 | ||
4130 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4131 | ||
4132 | * src/output.c (action_row): Let default_rule be always a rule | |
4133 | number. | |
4134 | ||
4135 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4136 | ||
4137 | * src/closure.c (print_firsts, print_fderives, closure): | |
4138 | Use BITSET_EXECUTE. | |
4139 | * src/lalr.c (lookaheads_print): Likewise. | |
4140 | * src/state.c (state_rule_lookaheads_print): Likewise. | |
4141 | * src/print_graph.c (print_core): Likewise. | |
4142 | * src/print.c (print_reductions): Likewise. | |
4143 | * src/output.c (action_row): Likewise. | |
4144 | Use SHIFT_IS_DISABLED, SHIFT_IS_SHIFT and SHIFT_SYMBOL. | |
4145 | ||
4146 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4147 | ||
4148 | * src/print_graph.c: Use report_flag. | |
4149 | ||
4150 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4151 | ||
4152 | * src/lalr.c (traverse, digraph, matrix_print, transpose): Move | |
4153 | to... | |
4154 | * src/relation.h, src/relation.c (traverse, relation_digraph) | |
4155 | (relation_print, relation_transpose): New. | |
4156 | ||
4157 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4158 | ||
4159 | * src/state.h, src/state.c (shifts_to): New. | |
4160 | * src/lalr.c (build_relations): Use it. | |
4161 | ||
4162 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4163 | ||
4164 | * src/gram.h (rule_number_t, RULE_NUMBER_MAX, int_of_rule_number) | |
4165 | (item_number_of_rule_number, rule_number_of_item_number): New. | |
4166 | * src/LR0.c, src/closure.c, src/derives.c, src/derives.h, | |
4167 | * src/gram.c, src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
4168 | * src/print_graph.c, src/reader.c, src/reduce.c, src/reduce.h: | |
4169 | Propagate their use. | |
4170 | Much remains to be done, in particular wrt `shorts' from types.h. | |
4171 | ||
4172 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4173 | ||
4174 | * src/symtab.c (symbol_new): Initialize the `printer' member. | |
4175 | ||
4176 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4177 | ||
4178 | * src/LR0.c (save_reductions): Remove, replaced by... | |
4179 | * src/state.h, src/state.c (state_reductions_set): New. | |
4180 | (reductions, errs): Rename as... | |
4181 | (reductions_t, errs_t): these. | |
4182 | Adjust all dependencies. | |
4183 | ||
4184 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4185 | ||
4186 | * src/LR0.c (state_list_t, state_list_append): New. | |
4187 | (first_state, last_state): Now symbol_list_t. | |
4188 | (this_state): Remove. | |
4189 | (new_itemsets, append_states, save_reductions): Take a state_t as | |
4190 | argument. | |
4191 | (set_states, generate_states): Adjust. | |
4192 | (save_shifts): Remove, replaced by... | |
4193 | * src/state.h, src/state.c (state_shifts_set): New. | |
4194 | (shifts): Rename as... | |
4195 | (shifts_t): this. | |
4196 | Adjust all dependencies. | |
4197 | * src/state.h (state_t): Remove the `next' member. | |
4198 | ||
4199 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4200 | ||
4201 | * src/vcg.c (quote): Use slot 2, since we often pass symbol tag | |
4202 | escaped in slot 0. | |
4203 | ||
4204 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4205 | ||
4206 | Use hash.h for the state hash table. | |
4207 | ||
4208 | * src/LR0.c (STATE_HASH_SIZE, state_hash): Remove. | |
4209 | (allocate_storage): Use state_hash_new. | |
4210 | (free_storage): Use state_hash_free. | |
4211 | (new_state, get_state): Adjust. | |
4212 | * src/lalr.h, src/lalr.c (states): Move to... | |
4213 | * src/states.h (state_t): Remove the `link' member, no longer | |
4214 | used. | |
4215 | * src/states.h, src/states.c: here. | |
4216 | (state_hash_new, state_hash_free, state_hash_lookup) | |
4217 | (state_hash_insert, states_free): New. | |
4218 | * src/states.c (state_table, state_compare, state_hash): New. | |
4219 | * src/output.c (output_actions): Do not free states now, since we | |
4220 | still need to know the final_state number in `prepare', called | |
4221 | afterwards. Do it... | |
4222 | * src/main.c (main): here: call states_free after `output'. | |
4223 | ||
4224 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4225 | ||
4226 | * src/state.h, src/state.c (state_new): New, extracted from... | |
4227 | * src/LR0.c (new_state): here. | |
4228 | * src/state.h (STATE_ALLOC): Move to... | |
4229 | * src/state.c: here. | |
4230 | * src/LR0.h, src/LR0.c (nstates, final_state): Move to... | |
4231 | * src/state.h, src/state.c: here. | |
4232 | ||
4233 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4234 | ||
4235 | * src/reader.c (gensym): Rename as... | |
4236 | * src/symtab.h, src/symtab.c (dummy_symbol_get): this. | |
4237 | (getsym): Rename as... | |
4238 | (symbol_get): this. | |
4239 | ||
4240 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4241 | ||
4242 | * src/state.h (state_number_t, STATE_NUMBER_MAX): New. | |
4243 | * src/LR0.c, src/LR0.h, src/conflicts.c, src/lalr.c, src/lalr.h, | |
4244 | * src/output.c, src/print.c, src/print_graph.c: Propagate. | |
4245 | * src/LR0.h, src/LR0.h (final_state): Is a state_t*. | |
4246 | ||
4247 | 2002-06-30 Akim Demaille <akim@epita.fr> | |
4248 | ||
4249 | Make the test suite pass with warnings checked. | |
4250 | ||
4251 | * tests/actions.at (Printers and Destructors): Improve. | |
4252 | Avoid unsigned vs. signed issues. | |
4253 | * tests/calc.at: Don't exercise the scanner here, do it... | |
4254 | * tests/input.at (Torturing the Scanner): here. | |
4255 | ||
4256 | 2002-06-28 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4257 | ||
4258 | * data/glr.c: Correct typo in Emacs-mode directive. Slightly | |
4259 | reorganize first lines parallel to yacc.c. | |
4260 | ||
4261 | 2002-06-28 Akim Demaille <akim@epita.fr> | |
4262 | ||
4263 | * data/c.m4 (b4_copyright, b4_sint_type, b4_uint_type, b4_token_define) | |
4264 | (b4_token_enum, b4_token_defines): New, factored from... | |
4265 | * data/lalr1.cc, data/yacc.c, glr.c: here. | |
4266 | ||
4267 | 2002-06-28 Akim Demaille <akim@epita.fr> | |
4268 | ||
4269 | * data/yacc.c (yydestruct, yysymprint): Pacify GCC warnings for | |
4270 | unused variables. | |
4271 | * src/output.c (merger_output): static. | |
4272 | ||
4273 | 2002-06-28 Akim Demaille <akim@epita.fr> | |
4274 | ||
4275 | * src/reader.h: s/grammer_current_rule_merge_set/grammar_.../. | |
4276 | * src/conflicts.c (conflicts_total_count): `i' is unsigned, to | |
4277 | pacify GCC. | |
4278 | * src/output.c (save_row): Initialize all the variables to pacify GCC. | |
4279 | ||
4280 | 2002-06-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4281 | ||
4282 | Accumulated changelog for new GLR parsing features. | |
4283 | ||
4284 | * src/conflicts.c (count_total_conflicts): Change name to | |
4285 | conflicts_total_count. | |
4286 | * src/conflicts.h: Ditto. | |
4287 | * src/output.c (token_actions): Use the new name. | |
4288 | (output_conflicts): Change conflp => conflict_list_heads, and | |
4289 | confl => conflict_list for better readability. | |
4290 | * data/glr.c: Use the new names. | |
4291 | * NEWS: Add self to GLR announcement. | |
4292 | ||
4293 | * src/reader.c (free_merger_functions): Cleanup: XFREE->free. | |
4294 | ||
4295 | * doc/bison.texinfo (GLR Parsers): Make corrections suggested by | |
4296 | Akim Demaille. | |
4297 | ||
4298 | * data/bison.glr: Change name to glr.c | |
4299 | * data/glr.c: Renamed from bison.glr. | |
4300 | * data/Makefile.am: Add glr.c | |
4301 | ||
4302 | * src/getargs.c: | |
4303 | ||
4304 | * src/symlist.h: Add dprec and merger fields to symbol_list_s. | |
4305 | * src/symlist.c (symbol_list_new): Initialize dprec and merger fields. | |
4306 | ||
4307 | Originally 2002-06-16 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4308 | ||
4309 | * data/bison.glr: Be sure to restore the | |
4310 | current #line when returning to the skeleton contents after having | |
4311 | exposed the input file's #line. | |
4312 | ||
4313 | Originally 2002-06-13 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4314 | ||
4315 | * data/bison.glr: Bring up to date with changes to bison.simple. | |
4316 | ||
4317 | Originally 2002-06-03 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4318 | ||
4319 | * data/bison.glr: Correct definitions that use b4_prefix. | |
4320 | Various reformatting. | |
4321 | (GLRStack): Make yychar (in YYPURE case) and yytokenp as part of stack. | |
4322 | (yyreportParseError, yyrecoverParseError, yyprocessOneStack): remove | |
4323 | yytokenp argument; now part of stack. | |
4324 | (yychar): Define to behave as documented. | |
4325 | (yyclearin): Ditto. | |
4326 | ||
4327 | Originally 2002-05-14 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
4328 | ||
4329 | * src/reader.h: Add declaration for free_merger_functions. | |
4330 | ||
4331 | * src/reader.c (merge_functions): New variable. | |
4332 | (get_merge_function): New function. | |
4333 | (free_merger_functions): New function. | |
4334 | (readgram): Check for %prec that is not followed by a symbol. | |
4335 | Handle %dprec and %merge declarations. | |
4336 | (packgram): Initialize dprec and merger fields in rules array. | |
4337 | ||
4338 | * src/output.c (conflict_tos, conflrow, conflict_table, conflict_list, | |
4339 | conflict_list_cnt, conflict_list_free): New variables. | |
4340 | (table_grow): Also grow conflict_table. | |
4341 | (prepare_rules): Output dprec and merger tables. | |
4342 | (conflict_row): New function. | |
4343 | (action_row): Output conflict lists for GLR parser. Don't use | |
4344 | default reduction in conflicted states for GLR parser so that there | |
4345 | are spaces for the conflict lists. | |
4346 | (save_row): Also save conflict information. | |
4347 | (token_actions): Allocate conflict list. | |
4348 | (merger_output): New function. | |
4349 | (pack_vector): Pack conflict table, too. | |
4350 | (output_conflicts): New function to output yyconflp and yyconfl. | |
4351 | (output_check): Allocate conflict_tos. | |
4352 | (output_actions): Output conflict tables, also. | |
4353 | (output_skeleton): Output b4_mergers definition. | |
4354 | (prepare): Output b4_max_rhs_length definition. | |
4355 | Use 'bison.glr' as default skeleton for GLR parsers. | |
4356 | ||
4357 | * src/gram.c (glr_parser): New flag. | |
4358 | (grammar_free): Call free_merger_functions. | |
4359 | ||
4360 | * src/conflicts.c (count_rr_conflicts): Augment to optionally count | |
4361 | all pairs of conflicting reductions, rather than just all tokens | |
4362 | causing conflicts. Needed to size conflict tables. | |
4363 | (conflicts_output): Modify call to count_rr_conflicts for new | |
4364 | interface. | |
4365 | (conflicts_print): Ditto. | |
4366 | (count_total_conflicts): New function. | |
4367 | ||
4368 | * src/reader.h (merger_list): New type. | |
4369 | (merge_functions): New variable. | |
4370 | ||
4371 | * src/lex.h (tok_dprec, tok_merge): New token types. | |
4372 | ||
4373 | * src/gram.h (rule_s): Add dprec and merger fields. | |
4374 | (glr_parser): New flag. | |
4375 | ||
4376 | * src/conflicts.h (count_total_conflicts): New function. | |
4377 | ||
4378 | * src/options.c (option_table): Add %dprec, %merge, and %glr-parser. | |
4379 | ||
4380 | * doc/bison.texinfo (Generalized LR Parsing): New section. | |
4381 | (GLR Parsers): New section. | |
4382 | (Language and Grammar): Mention GLR parsing. | |
4383 | (Table of Symbols): Add %dprec, %glr-parser, %merge, GLR | |
4384 | Correct typo ("tge" -> "the"). | |
4385 | ||
4386 | * data/bison.glr: New skeleton for GLR parsing. | |
4387 | ||
4388 | * tests/cxx-gram.at: New tests for GLR parsing. | |
4389 | ||
4390 | * tests/testsuite.at: Include cxx-gram.at. | |
4391 | ||
4392 | * tests/Makefile.am: Add cxx-gram.at. | |
4393 | ||
4394 | * src/parse-gram.y: | |
4395 | ||
4396 | * src/scan-gram.l: Add %dprec, %glr-parser, %merge. | |
4397 | ||
4398 | * src/parse-gram.y: Grammar for %dprec, %merge, %glr-parser. | |
4399 | ||
4400 | 2002-06-27 Akim Demaille <akim@epita.fr> | |
4401 | ||
4402 | * src/options.h, src/options.c: Remove. | |
4403 | * src/getargs.c (short_options, long_options): New. | |
4404 | ||
4405 | 2002-06-27 Akim Demaille <akim@epita.fr> | |
4406 | ||
4407 | * data/bison.simple, data/bison.c++: Rename as... | |
4408 | * data/yacc.c, data/lalr1.cc: these. | |
4409 | * doc/bison.texinfo (Environment Variables): Remove. | |
4410 | ||
4411 | 2002-06-25 Raja R Harinath <harinath@cs.umn.edu> | |
4412 | ||
4413 | * src/getargs.c (report_argmatch): Initialize strtok(). | |
4414 | ||
4415 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4416 | ||
4417 | * data/bison.simple (b4_symbol_actions): New, replaces... | |
4418 | (b4_symbol_destructor, b4_symbol_printer): these. | |
4419 | (yysymprint): Be sure to call YYPRINT only for tokens, and using | |
4420 | user token numbers. | |
4421 | ||
4422 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4423 | ||
4424 | * data/bison.simple (yydestructor): Rename as... | |
4425 | (yydestruct): this. | |
4426 | ||
4427 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4428 | ||
4429 | * src/symtab.h, src/symtab.c (symbol_type_set) | |
4430 | (symbol_destructor_set, symbol_precedence_set): The location is | |
4431 | the last argument. | |
4432 | Adjust all callers. | |
4433 | ||
4434 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4435 | ||
4436 | * src/parse-gram.y (YYPRINT, yyprint): Don't mess with the parser | |
4437 | internals. | |
4438 | * src/reader.h, src/reader.c (grammar_current_rule_prec_set): | |
4439 | Takes a location. | |
4440 | * src/symtab.h, src/symtab.c (symbol_class_set) | |
4441 | (symbol_user_token_number_set): Likewise. | |
4442 | Adjust all callers. | |
4443 | Promote complain_at. | |
4444 | * tests/input.at (Type Clashes): Adjust. | |
4445 | ||
4446 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4447 | ||
4448 | * data/bison.simple (YYLEX): Fix the declaration when | |
4449 | %pure-parser. | |
4450 | ||
4451 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4452 | ||
4453 | * data/bison.simple (yysymprint): Don't print the token number, | |
4454 | just its name. | |
4455 | * tests/actions.at (Destructors): Rename as... | |
4456 | (Printers and Destructors): this. | |
4457 | Also exercise %printer. | |
4458 | ||
4459 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4460 | ||
4461 | * data/bison.simple (YYDSYMPRINT): New. | |
4462 | Use it to remove many of the #if YYDEBUG/if (yydebug). | |
4463 | ||
4464 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4465 | ||
4466 | * src/symtab.h, src/symtab.c (symbol_t): printer and | |
4467 | printer_location are new members. | |
4468 | (symbol_printer_set): New. | |
4469 | * src/parse-gram.y (PERCENT_PRINTER): New token. | |
4470 | Handle its associated rule. | |
4471 | * src/scan-gram.l: Adjust. | |
4472 | (handle_destructor_at, handle_destructor_dollar): Rename as... | |
4473 | (handle_symbol_code_at, handle_symbol_code_dollar): these. | |
4474 | * src/output.c (symbol_printers_output): New. | |
4475 | (output_skeleton): Call it. | |
4476 | * data/bison.simple (yysymprint): New. Cannot be named yyprint | |
4477 | since there are already many grammar files with a user `yyprint'. | |
4478 | Replace the calls to YYPRINT to calls to yysymprint. | |
4479 | * tests/calc.at: Adjust. | |
4480 | * tests/torture.at (AT_DATA_STACK_TORTURE): Remove YYPRINT: it was | |
4481 | taking advantage of parser very internal details (stack size!). | |
4482 | ||
4483 | 2002-06-20 Akim Demaille <akim@epita.fr> | |
4484 | ||
4485 | * src/scan-gram.l: Complete the scanner with the missing patterns | |
4486 | to pacify Flex. | |
4487 | Use `quote' and `symbol_tag_get' where appropriate. | |
4488 | ||
4489 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
4490 | ||
4491 | * tests/actions.at (Destructors): Augment to test locations. | |
4492 | * data/bison.simple (yydestructor): Pass it the current location | |
4493 | if locations are enabled. | |
4494 | Prototype only when __STDC__ or C++. | |
4495 | Change the argument names to move into the yy name space: there is | |
4496 | user code here. | |
4497 | ||
4498 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
4499 | ||
4500 | * data/bison.simple (b4_pure_if): New. | |
4501 | Use it instead of #ifdef YYPURE. | |
4502 | ||
4503 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
4504 | ||
4505 | * data/bison.simple (b4_location_if): New. | |
4506 | Use it instead of #ifdef YYLSP_NEEDED. | |
4507 | ||
4508 | 2002-06-19 Akim Demaille <akim@epita.fr> | |
4509 | ||
4510 | Prepare @$ in %destructor, but currently don't bind it in the | |
4511 | skeleton, as %location use is not cleaned up yet. | |
4512 | ||
4513 | * src/scan-gram.l (handle_dollar, handle_destructor_at) | |
4514 | (handle_action_at): New. | |
4515 | (handle_at, handle_action_dollar, handle_destructor_dollar): Take | |
4516 | a braced_code_t and a location as additional arguments. | |
4517 | (handle_destructor_dollar): Instead of requiring `b4_eval', just | |
4518 | unquote one when outputting `b4_dollar_dollar'. | |
4519 | Adjust callers. | |
4520 | * data/bison.simple (b4_eval): Remove. | |
4521 | (b4_symbol_destructor): Adjust. | |
4522 | * tests/input.at (Invalid @n): Adjust. | |
4523 | ||
4524 | 2002-06-19 Zack Weinberg <zack@codesourcery.com> | |
4525 | ||
4526 | * doc/bison.texinfo: Document ability to have multiple | |
4527 | prologue sections. | |
4528 | ||
4529 | 2002-06-18 Akim Demaille <akim@epita.fr> | |
4530 | ||
4531 | * src/files.c (compute_base_names): When computing the output file | |
4532 | names from the input file name, strip the directory part. | |
4533 | ||
4534 | 2002-06-18 Akim Demaille <akim@epita.fr> | |
4535 | ||
4536 | * data/bison.simple.new: Comment changes. | |
4537 | Reported by Andreas Schwab. | |
4538 | ||
4539 | 2002-06-18 Matt Kraai <kraai@alumni.cmu.edu> | |
4540 | ||
4541 | * data/bison.simple (yyoverflowlab): #ifndef yyoverflow, so that | |
4542 | there are no `label `yyoverflowlab' defined but not used' warnings | |
4543 | when yyoverflow is defined. | |
4544 | ||
4545 | 2002-06-18 Akim Demaille <akim@epita.fr> | |
4546 | ||
4547 | * src/symtab.h, src/symtab.c (symbol_t): destructor_location is a | |
4548 | new member. | |
4549 | (symbol_destructor_set): Adjust. | |
4550 | * src/output.c (symbol_destructors_output): Output the destructor | |
4551 | locations. | |
4552 | Output the symbol name. | |
4553 | * data/bison.simple (b4_symbol_destructor): Adjust. | |
4554 | ||
4555 | 2002-06-18 Cris Bailiff <c.bailiff@awayweb.com> | |
4556 | and Akim Demaille <akim@epita.fr> | |
4557 | ||
4558 | * data/bison.simple.new (yyerrlab1): Be sure to pop and destroy | |
4559 | what's left on the stack when the error recovery hits EOF. | |
4560 | * tests/actions.at (Destructors): Complete to exercise this case. | |
4561 | ||
4562 | 2002-06-17 Akim Demaille <akim@epita.fr> | |
4563 | ||
4564 | * data/m4sugar/m4sugar.m4 (m4_map): Recognize when the list of | |
4565 | arguments is really empty, not only equal to `[]'. | |
4566 | * src/symtab.h, src/symtab.c (symbol_t): `destructor' is a new | |
4567 | member. | |
4568 | (symbol_destructor_set): New. | |
4569 | * src/output.c (symbol_destructors_output): New. | |
4570 | * src/reader.h (brace_code_t, current_braced_code): New. | |
4571 | * src/scan-gram.l (BRACED_CODE): Use it to branch on... | |
4572 | (handle_dollar): Rename as... | |
4573 | (handle_action_dollar): this. | |
4574 | (handle_destructor_dollar): New. | |
4575 | * src/parse-gram.y (PERCENT_DESTRUCTOR): New. | |
4576 | (grammar_declaration): Use it. | |
4577 | * data/bison.simple (yystos): Is always defined. | |
4578 | (yydestructor): New. | |
4579 | * tests/actions.at (Destructors): New. | |
4580 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Don't rely on egrep. | |
4581 | ||
4582 | 2002-06-17 Akim Demaille <akim@epita.fr> | |
4583 | ||
4584 | * src/symlist.h, src/symlist.c (symbol_list_length): New. | |
4585 | * src/scan-gram.l (handle_dollar, handle_at): Compute the | |
4586 | rule_length only when needed. | |
4587 | * src/output.c (actions_output, token_definitions_output): Output | |
4588 | the full M4 block. | |
4589 | * src/symtab.c: Don't access directly to the symbol tag, use | |
4590 | symbol_tag_get. | |
4591 | * src/parse-gram.y: Use symbol_list_free. | |
4592 | ||
4593 | 2002-06-17 Akim Demaille <akim@epita.fr> | |
4594 | ||
4595 | * src/reader.h, src/reader.c (symbol_list, symbol_list_new) | |
4596 | (symbol_list_prepend, get_type_name): Move to... | |
4597 | * src/symlist.h, src/symlist.c (symbol_list_t, symbol_list_new) | |
4598 | (symbol_list_prepend, symbol_list_n_type_name_get): here. | |
4599 | Adjust all callers. | |
4600 | (symbol_list_free): New. | |
4601 | * src/scan-gram.l (handle_dollar): Takes a location. | |
4602 | * tests/input.at (Invalid $n): Adjust. | |
4603 | ||
4604 | 2002-06-17 Akim Demaille <akim@epita.fr> | |
4605 | ||
4606 | * src/reader.h, src/reader.c (symbol_list_new): Export it. | |
4607 | (symbol_list_prepend): New. | |
4608 | * src/parse-gram.y (%union): `list' is a new member. | |
4609 | (symbols.1): New, replaces... | |
4610 | (terms_to_prec.1, nterms_to_type.1): these. | |
4611 | * src/symtab.h, src/symtab.c (symbol_type_set, symbol_precedence_set) | |
4612 | Take a location as additional argument. | |
4613 | Adjust all callers. | |
4614 | ||
4615 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4616 | ||
4617 | * src/parse-gram.y: Move %token in the declaration section so that | |
4618 | we don't depend upon CVS Bison. | |
4619 | ||
4620 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4621 | ||
4622 | * src/state.h, src/state.c (state_rule_lookaheads_print): New. | |
4623 | * src/print.c (print_core): Use it. | |
4624 | ||
4625 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4626 | ||
4627 | * src/conflicts.c (log_resolution): Accept the rule involved in | |
4628 | the sr conflicts instead of the lookahead number that points to | |
4629 | that rule. | |
4630 | (flush_reduce): Accept the current lookahead vector as argument, | |
4631 | instead of the index in LA. | |
4632 | (resolve_sr_conflict): Accept the current number of lookahead | |
4633 | bitset to consider for the STATE, instead of the index in LA. | |
4634 | (set_conflicts): Adjust. | |
4635 | * src/lalr.c, src/lalr.h, src/state.h: Comment changes. | |
4636 | ||
4637 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4638 | ||
4639 | * src/state.h (state_t): Replace the `lookaheadsp' member, a | |
4640 | short, with `lookaheads' (bitsetv), `lookaheads_rule' (rule_t**). | |
4641 | Adjust all dependencies. | |
4642 | * src/lalr.c (initialize_lookaheads): Split into... | |
4643 | (states_lookaheads_count, states_lookaheads_initialize): these. | |
4644 | (lalr): Adjust. | |
4645 | ||
4646 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4647 | ||
4648 | * src/gram.h, src/gram.c (grammar_rules_partial_print): New, eved | |
4649 | out of... | |
4650 | (grammar_rules_print): here. | |
4651 | * src/reduce.c (reduce_output): Use it. | |
4652 | * tests/reduce.at (Useless Rules, Reduced Automaton) | |
4653 | (Underivable Rules): Adjust. | |
4654 | ||
4655 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4656 | ||
4657 | Copy BYacc's nice way to report the grammar. | |
4658 | ||
4659 | * src/gram.h, src/gram.c (grammar_rhs_print, grammar_rules_print): | |
4660 | New. | |
4661 | Don't print the rules' location, it is confusing and useless. | |
4662 | (rule_print): Use grammar_rhs_print. | |
4663 | * src/print.c (print_grammar): Use grammar_rules_print. | |
4664 | ||
4665 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4666 | ||
4667 | Complete and rationalize `useless thing' warnings. | |
4668 | ||
4669 | * src/symtab.h, src/symtab.c (symbol_tag_get, symbol_tag_get_n) | |
4670 | (symbol_tag_print): New. | |
4671 | Use them everywhere in place of accessing directly the tag member. | |
4672 | * src/gram.h, src/gram.c (rule_print): New. | |
4673 | Use it where a rule used to be printed `by hand'. | |
4674 | * src/reduce.c (nonterminals_reduce): Report the use nonterminals. | |
4675 | (reduce_grammar_tables): Report the useless rules. | |
4676 | (reduce_print): Useless things are a warning, not an error. | |
4677 | Report it as such. | |
4678 | * tests/reduce.at (Useless Nonterminals, Useless Rules): | |
4679 | (Reduced Automaton, Underivable Rules): Adjust. | |
4680 | * tests/regression.at (Web2c Report, Web2c Report): Adjust. | |
4681 | * tests/conflicts.at (Unresolved SR Conflicts) | |
4682 | (Solved SR Conflicts): Adjust. | |
4683 | ||
4684 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4685 | ||
4686 | Let symbols have a location. | |
4687 | ||
4688 | * src/symtab.h, src/symtab.c (symbol_t): Location is a new member. | |
4689 | (getsym): Adjust. | |
4690 | Adjust all callers. | |
4691 | * src/complain.h, src/complain.c (complain_at, fatal_at, warn_at): | |
4692 | Use location_t, not int. | |
4693 | * src/symtab.c (symbol_check_defined): Take advantage of the | |
4694 | location. | |
4695 | * tests/regression.at (Invalid inputs): Adjust. | |
4696 | ||
4697 | 2002-06-15 Akim Demaille <akim@epita.fr> | |
4698 | ||
4699 | * src/parse-gram.y (YYLLOC_DEFAULT, current_lhs_location): New. | |
4700 | (input): Don't try to initialize yylloc here, do it in the | |
4701 | scanner. | |
4702 | * src/scan-gram.l (YY_USER_INIT): Initialize yylloc. | |
4703 | * src/gram.h (rule_t): Change line and action_line into location | |
4704 | and action_location, of location_t type. | |
4705 | Adjust all dependencies. | |
4706 | * src/location.h, src/location.c (empty_location): New. | |
4707 | * src/reader.h, src/reader.c (grammar_start_symbol_set) | |
4708 | (grammar_symbol_append, grammar_rule_begin, grammar_rule_end) | |
4709 | (grammar_current_rule_symbol_append) | |
4710 | (grammar_current_rule_action_append): Expect a location as argument. | |
4711 | * src/reader.c (grammar_midrule_action): Adjust to attach an | |
4712 | action's location as dummy symbol location. | |
4713 | * src/symtab.h, src/symtab.c (startsymbol_location): New. | |
4714 | * tests/regression.at (Web2c Report, Rule Line Numbers): Adjust | |
4715 | the line numbers. | |
4716 | ||
4717 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4718 | ||
4719 | Grammar declarations may be found in the grammar section. | |
4720 | ||
4721 | * src/parse-gram.y (rules_or_grammar_declaration): New. | |
4722 | (declarations): Each declaration may end with a semicolon, not | |
4723 | just... | |
4724 | (grammar_declaration): `"%union"'. | |
4725 | (grammar): Branch to rules_or_grammar_declaration. | |
4726 | ||
4727 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4728 | ||
4729 | * src/main.c (main): Invoke scanner_free. | |
4730 | ||
4731 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4732 | ||
4733 | * src/output.c (m4_invoke): Extracted from... | |
4734 | (output_skeleton): here. | |
4735 | Free tempfile. | |
4736 | ||
4737 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4738 | ||
4739 | * src/parse-gram.y (directives, directive, gram) | |
4740 | (grammar_directives, precedence_directives, precedence_directive): | |
4741 | Rename as... | |
4742 | (declarations, declaration, grammar, grammar_declaration) | |
4743 | (precedence_declaration, precedence_declarator): these. | |
4744 | (symbol_declaration): New. | |
4745 | ||
4746 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4747 | ||
4748 | * src/files.c (action_obstack): Remove, unused. | |
4749 | (output_obstack): Remove it, and all its dependencies, as it is no | |
4750 | longer needed. | |
4751 | * src/reader.c (epilogue_set): Build the epilogue in the | |
4752 | muscle_obstack. | |
4753 | * src/output.h, src/output.c (muscle_obstack): Move to... | |
4754 | * src/muscle_tab.h, src/muscle_tab.h: here. | |
4755 | (muscle_init): Initialize muscle_obstack. | |
4756 | (muscle_free): New. | |
4757 | * src/main.c (main): Call it. | |
4758 | ||
4759 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4760 | ||
4761 | * src/location.h: New, extracted from... | |
4762 | * src/reader.h: here. | |
4763 | * src/Makefile.am (noinst_HEADERS): Merge into | |
4764 | (bison_SOURCES): this. | |
4765 | Add location.h. | |
4766 | * src/parse-gram.y: Use location_t instead of Bison's. | |
4767 | * src/reader.h, src/reader.c (prologue_augment, epilogue_set): | |
4768 | Use location_t instead of ints. | |
4769 | ||
4770 | 2002-06-14 Akim Demaille <akim@epita.fr> | |
4771 | ||
4772 | * data/bison.simple, data/bison.c++: Be sure to restore the | |
4773 | current #line when returning to the skeleton contents after having | |
4774 | exposed the input file's #line. | |
4775 | ||
4776 | 2002-06-12 Akim Demaille <akim@epita.fr> | |
4777 | ||
4778 | * src/scan-gram.l (SC_BRACED_CODE): Don't use `<.*>', it is too | |
4779 | eager. | |
4780 | * tests/actions.at (Exotic Dollars): New. | |
4781 | ||
4782 | 2002-06-12 Akim Demaille <akim@epita.fr> | |
4783 | ||
4784 | * src/scan-gram.l (SC_PROLOGUE): Don't eat characters amongst | |
4785 | ['"/] too eagerly. | |
4786 | * tests/input.at (Torturing the Scanner): New. | |
4787 | ||
4788 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4789 | ||
4790 | * src/scan-gram.l (YY_OBS_INIT): Remove, replace with... | |
4791 | [SC_COMMENT,SC_STRING,SC_CHARACTER,SC_BRACED_CODE,SC_PROLOGUE] | |
4792 | [SC_EPILOGUE]: Output the quadrigraphs only when not in a comment. | |
4793 | * src/reader.h, src/scan-gram.l (scanner_initialize): this. | |
4794 | * src/reader.c (reader): Use it. | |
4795 | ||
4796 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4797 | ||
4798 | * src/scan-gram.l (YY_OBS_FINISH): Don't set yylval. | |
4799 | Adjust all callers. | |
4800 | (scanner_last_string_free): New. | |
4801 | ||
4802 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4803 | ||
4804 | * src/scan-gram.l (YY_INIT, YY_GROW, YY_FINISH): Rename as... | |
4805 | (YY_OBS_INIT, YY_OBS_GROW, YY_OBS_FINISH): these. | |
4806 | (last_string, YY_OBS_FREE): New. | |
4807 | Use them when returning an ID. | |
4808 | ||
4809 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4810 | ||
4811 | Have Bison grammars parsed by a Bison grammar. | |
4812 | ||
4813 | * src/reader.c, src/reader.h (prologue_augment): New. | |
4814 | * src/reader.c (copy_definition): Remove. | |
4815 | ||
4816 | * src/reader.h, src/reader.c (gram_start_symbol_set, prologue_augment) | |
4817 | (grammar_symbol_append, grammar_rule_begin, grammar_midrule_action) | |
4818 | (grammar_current_rule_prec_set, grammar_current_rule_check) | |
4819 | (grammar_current_rule_symbol_append) | |
4820 | (grammar_current_rule_action_append): Export. | |
4821 | * src/parse-gram.y (symbol_list_new, symbol_list_symbol_append_ | |
4822 | (symbol_list_action_append): Remove. | |
4823 | Hook the routines from reader. | |
4824 | * src/scan-gram.l: In INITIAL, characters and strings are tokens. | |
4825 | * src/system.h (ATTRIBUTE_NORETURN, ATTRIBUTE_UNUSED): Now. | |
4826 | ||
4827 | * src/reader.c (read_declarations): Remove, unused. | |
4828 | ||
4829 | * src/parse-gram.y: Handle the epilogue. | |
4830 | * src/reader.h, src/reader.c (gram_start_symbol_set): Rename as... | |
4831 | (grammar_start_symbol_set): this. | |
4832 | * src/scan-gram.l: Be sure to ``use'' yycontrol to keep GCC quiet. | |
4833 | * src/reader.c (readgram): Remove, unused. | |
4834 | (reader): Adjust to insert eoftoken and axiom where appropriate. | |
4835 | ||
4836 | * src/reader.c (copy_dollar): Replace with... | |
4837 | * src/scan-gram.h (handle_dollar): this. | |
4838 | * src/parse-gram.y: Remove `%thong'. | |
4839 | ||
4840 | * src/reader.c (copy_at): Replace with... | |
4841 | * src/scan-gram.h (handle_at): this. | |
4842 | ||
4843 | * src/complain.h, src/complain.c (warn_at, complain_at, fatal_at): | |
4844 | New. | |
4845 | ||
4846 | * src/scan-gram.l (YY_LINES): Keep lineno synchronized for the | |
4847 | time being. | |
4848 | ||
4849 | * src/reader.h, src/reader.c (grammar_rule_end): New. | |
4850 | ||
4851 | * src/parse.y (current_type, current_class): New. | |
4852 | Implement `%nterm', `%token' support. | |
4853 | Merge `%term' into `%token'. | |
4854 | (string_as_id): New. | |
4855 | * src/symtab.h, src/symtab.c (symbol_make_alias): Don't pass the | |
4856 | type name. | |
4857 | ||
4858 | * src/parse-gram.y: Be sure to handle properly the beginning of | |
4859 | rules. | |
4860 | ||
4861 | * src/parse-gram.y: Handle %type. | |
4862 | * src/reader.c (grammar_rule_end): Call grammar_current_rule_check. | |
4863 | ||
4864 | * src/parse-gram.y: More directives support. | |
4865 | * src/options.c: No longer handle source directives. | |
4866 | ||
4867 | * src/parse-gram.y: Fix %output. | |
4868 | ||
4869 | * src/parse-gram.y: Handle %union. | |
4870 | Use the prologue locations. | |
4871 | * src/reader.c (parse_union_decl): Remove. | |
4872 | ||
4873 | * src/reader.h, src/reader.c (epilogue_set): New. | |
4874 | * src/parse-gram.y: Use it. | |
4875 | ||
4876 | * data/bison.simple, data/bison.c++: b4_stype is now either not | |
4877 | defined, then default to int, or to the contents of %union, | |
4878 | without `union' itself. | |
4879 | Adjust. | |
4880 | * src/muscle_tab.c (muscle_init): Don't predefine `stype'. | |
4881 | ||
4882 | * src/output.c (actions_output): Don't output braces, as they are | |
4883 | already handled by the scanner. | |
4884 | ||
4885 | * src/scan-gram.l (SC_CHARACTER): Set the user_token_number of | |
4886 | characters to themselves. | |
4887 | ||
4888 | * tests/reduce.at (Reduced Automaton): End the grammars with %% so | |
4889 | that the epilogue has a proper #line. | |
4890 | ||
4891 | * src/parse-gram.y: Handle precedence/associativity. | |
4892 | ||
4893 | * src/symtab.c (symbol_precedence_set): Requires the symbol to be | |
4894 | a terminal. | |
4895 | * src/scan-gram.l (SC_BRACED_CODE): Catch strings and characters. | |
4896 | * tests/calc.at: Do not use `%token "foo"' as it makes not sense | |
4897 | at all to define terminals that cannot be emitted. | |
4898 | ||
4899 | * src/scan-gram.l: Escape M4 characters. | |
4900 | ||
4901 | * src/scan-gram.l: Working properly with escapes in user | |
4902 | strings/characters. | |
4903 | ||
4904 | * tests/torture.at (AT_DATA_TRIANGULAR_GRAMMAR) | |
4905 | (AT_DATA_HORIZONTAL_GRAMMAR): Respect the `%token ID NUM STRING' | |
4906 | grammar. | |
4907 | Use more modest sizes, as for the time being the parser does not | |
4908 | release memory, and therefore the process swallows a huge amount | |
4909 | of memory. | |
4910 | ||
4911 | * tests/torture.at (AT_DATA_LOOKAHEADS_GRAMMAR): Adjust to the | |
4912 | stricter %token grammar. | |
4913 | ||
4914 | * src/symtab.h (associativity): Add `undef_assoc'. | |
4915 | (symbol_precedence_set): Do nothing when passed an undef_assoc. | |
4916 | * src/symtab.c (symbol_check_alias_consistence): Adjust. | |
4917 | ||
4918 | * tests/regression.at (Invalid %directive): Remove, as it is now | |
4919 | meaningless. | |
4920 | (Invalid inputs): Adjust to the new error messages. | |
4921 | (Token definitions): The new grammar doesn't allow too many | |
4922 | eccentricities. | |
4923 | ||
4924 | * src/lex.h, src/lex.c: Remove. | |
4925 | * src/reader.c (lastprec, skip_to_char, read_signed_integer) | |
4926 | (copy_character, copy_string2, copy_string, copy_identifier) | |
4927 | (copy_comment, parse_token_decl, parse_type_decl, parse_assoc_decl) | |
4928 | (parse_muscle_decl, parse_dquoted_param, parse_skel_decl) | |
4929 | (parse_action): Remove. | |
4930 | * po/POTFILES.in: Adjust. | |
4931 | ||
4932 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4933 | ||
4934 | * src/reader.c (parse_action): Don't store directly into the | |
4935 | rule's action member: return the action as a string. | |
4936 | Don't require `rule_length' as an argument: compute it. | |
4937 | (grammar_current_rule_symbol_append) | |
4938 | (grammar_current_rule_action_append): New, eved out from | |
4939 | (readgram): here. | |
4940 | Remove `action_flag', `rulelength', unused now. | |
4941 | ||
4942 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4943 | ||
4944 | * src/reader.c (grammar_current_rule_prec_set). | |
4945 | (grammar_current_rule_check): New, eved out from... | |
4946 | (readgram): here. | |
4947 | Remove `xaction', `first_rhs': useless. | |
4948 | * tests/input.at (Type clashes): New. | |
4949 | * tests/existing.at (GNU Cim Grammar): Adjust. | |
4950 | ||
4951 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4952 | ||
4953 | * src/reader.c (grammar_midrule_action): New, Eved out from | |
4954 | (readgram): here. | |
4955 | ||
4956 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4957 | ||
4958 | * src/reader.c (grammar_rule_begin, previous_rule, current_rule): | |
4959 | New. | |
4960 | (readgram): Use them as replacement of inlined code, crule and | |
4961 | crule1. | |
4962 | ||
4963 | 2002-06-11 Akim Demaille <akim@epita.fr> | |
4964 | ||
4965 | * src/reader.c (grammar_end, grammar_symbol_append): New. | |
4966 | (readgram): Use them. | |
4967 | Make the use of `p' as local as possible. | |
4968 | ||
4969 | 2002-06-10 Akim Demaille <akim@epita.fr> | |
4970 | ||
4971 | GCJ's parser requires the tokens to be defined before the prologue. | |
4972 | ||
4973 | * data/bison.simple: Output the token definition before the user's | |
4974 | prologue. | |
4975 | * tests/regression.at (Braces parsing, Duplicate string) | |
4976 | (Mixing %token styles): Check the output from bison. | |
4977 | (Early token definitions): New. | |
4978 | ||
4979 | 2002-06-10 Akim Demaille <akim@epita.fr> | |
4980 | ||
4981 | * src/symtab.c (symbol_user_token_number_set): Don't complain when | |
4982 | assigning twice the same user number to a token, so that we can | |
4983 | use it in... | |
4984 | * src/lex.c (lex): here. | |
4985 | Also use `symbol_class_set' instead of hand written code. | |
4986 | * src/reader.c (parse_assoc_decl): Likewise. | |
4987 | ||
4988 | 2002-06-10 Akim Demaille <akim@epita.fr> | |
4989 | ||
4990 | * src/symtab.c, src/symtab.c (symbol_class_set) | |
4991 | (symbol_user_token_number_set): New. | |
4992 | * src/reader.c (parse_token_decl): Use them. | |
4993 | Use a switch instead of ifs. | |
4994 | Use a single argument. | |
4995 | ||
4996 | 2002-06-10 Akim Demaille <akim@epita.fr> | |
4997 | ||
4998 | Remove `%thong' support as it is undocumented, unused, duplicates | |
4999 | `%token's job, and creates useless e-mail traffic with people who | |
5000 | want to know what it is, why it is undocumented, unused, and | |
5001 | duplicates `%token's job. | |
5002 | ||
5003 | * src/reader.c (parse_thong_decl): Remove. | |
5004 | * src/options.c (option_table): Remove "thong". | |
5005 | * src/lex.h (tok_thong): Remove. | |
5006 | ||
5007 | 2002-06-10 Akim Demaille <akim@epita.fr> | |
5008 | ||
5009 | * src/symtab.c, src/symtab.c (symbol_type_set) | |
5010 | (symbol_precedence_set): New. | |
5011 | * src/reader.c (parse_type_decl, parse_assoc_decl): Use them. | |
5012 | (value_components_used): Remove, unused. | |
5013 | ||
5014 | 2002-06-09 Akim Demaille <akim@epita.fr> | |
5015 | ||
5016 | Move symbols handling code out of the reader. | |
5017 | ||
5018 | * src/reader.h, src/reader.c (errtoken, undeftoken, eoftoken) | |
5019 | (axiom): Move to... | |
5020 | * src/symtab.h, src/symtab.c: here. | |
5021 | ||
5022 | * src/gram.c (start_symbol): Remove: use startsymbol->number. | |
5023 | * src/reader.c (startval): Rename as... | |
5024 | * src/symtab.h, src/symtab.c (startsymbol): this. | |
5025 | * src/reader.c: Adjust. | |
5026 | ||
5027 | * src/reader.c (symbol_check_defined, symbol_make_alias) | |
5028 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
5029 | (token_translations_init) | |
5030 | Move to... | |
5031 | * src/symtab.c: here. | |
5032 | * src/reader.c (packsymbols): Move to... | |
5033 | * src/symtab.h, src/symtab.c (symbols_pack): here. | |
5034 | * src/symtab.h, src/symtab.c (symbol_make_alias): Takes SYMVAL as | |
5035 | argument. | |
5036 | ||
5037 | 2002-06-03 Akim Demaille <akim@epita.fr> | |
5038 | ||
5039 | * src/muscle_tab.c (muscle_insert, muscle_find): Declarations, | |
5040 | then statements. | |
5041 | ||
5042 | 2002-06-03 Akim Demaille <akim@epita.fr> | |
5043 | ||
5044 | * src/muscle_tab.c (muscle_find, muscle_insert): Don't initialize | |
5045 | structs with non literals. | |
5046 | * src/scan-skel.l: never-interactive. | |
5047 | * src/conflicts.c (enum conflict_resolution_e): No trailing | |
5048 | comma. | |
5049 | * src/getargs.c (usage): Split long literal strings. | |
5050 | Reported by Hans Aberg. | |
5051 | ||
5052 | 2002-05-28 Akim Demaille <akim@epita.fr> | |
5053 | ||
5054 | * data/bison.c++: Use C++ ostreams. | |
5055 | (cdebug_): New member. | |
5056 | ||
5057 | 2002-05-28 Akim Demaille <akim@epita.fr> | |
5058 | ||
5059 | * src/output.c (output_skeleton): Be sure to allocate enough room | |
5060 | for `/' _and_ for `\0' in full_skeleton. | |
5061 | ||
5062 | 2002-05-28 Akim Demaille <akim@epita.fr> | |
5063 | ||
5064 | * data/bison.c++: Catch up with bison.simple: | |
5065 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5066 | and Paul Eggert <eggert@twinsun.com>: `error' handing. | |
5067 | 2002-05-26 Akim Demaille <akim@epita.fr>: stos_, token_number_, | |
5068 | and popping traces. | |
5069 | ||
5070 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5071 | ||
5072 | * src/output.c (output_skeleton): Put an explicit path in front of | |
5073 | the skeleton file name, rather than relying on the -I directory, | |
5074 | to partially alleviate effects of having a skeleton file lying around | |
5075 | in the current directory. | |
5076 | ||
5077 | 2002-05-27 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5078 | ||
5079 | * src/conflicts.c (log_resolution): Correct typo: | |
5080 | obstack_printf should be obstack_fgrow1. | |
5081 | ||
5082 | 2002-05-26 Akim Demaille <akim@epita.fr> | |
5083 | ||
5084 | * src/state.h (state_t): `solved_conflicts' is a new member. | |
5085 | * src/LR0.c (new_state): Set it to 0. | |
5086 | * src/conflicts.h, src/conflicts.c (print_conflicts) | |
5087 | (free_conflicts, solve_conflicts): Rename as... | |
5088 | (conflicts_print, conflicts_free, conflicts_solve): these. | |
5089 | Adjust callers. | |
5090 | * src/conflicts.c (enum conflict_resolution_e) | |
5091 | (solved_conflicts_obstack): New, used by... | |
5092 | (log_resolution): this. | |
5093 | Adjust to attach the conflict resolution to each state. | |
5094 | Complete the description with the precedence/associativity | |
5095 | information. | |
5096 | (resolve_sr_conflict): Adjust. | |
5097 | * src/print.c (print_state): Output its solved_conflicts. | |
5098 | * tests/conflicts.at (Unresolved SR Conflicts) | |
5099 | (Solved SR Conflicts): Exercise --report=all. | |
5100 | ||
5101 | 2002-05-26 Akim Demaille <akim@epita.fr> | |
5102 | ||
5103 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
5104 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
5105 | * src/reader.c, src/reduce.c, src/state.h, src/symtab.h | |
5106 | (token_number_t, item_number_as_token_number) | |
5107 | (token_number_as_item_number, muscle_insert_token_number_table): | |
5108 | Rename as... | |
5109 | (symbol_number_t, item_number_as_symbol_number) | |
5110 | (symbol_number_as_item_number, muscle_insert_symbol_number_table): | |
5111 | these, since it is more appropriate. | |
5112 | ||
5113 | 2002-05-26 Akim Demaille <akim@epita.fr> | |
5114 | ||
5115 | * tests/calc.at (AT_CHECK_CALC): Adjust: there are now additional | |
5116 | `Error:' lines. | |
5117 | * data/bison.simple (yystos) [YYDEBUG]: New. | |
5118 | (yyparse) [YYDEBUG]: Display the symbols which are popped during | |
5119 | error recovery. | |
5120 | * tests/regression.at (Web2c Actions): Adjust: yystos is output now. | |
5121 | ||
5122 | 2002-05-25 Akim Demaille <akim@epita.fr> | |
5123 | ||
5124 | * doc/bison.texinfo (Debugging): Split into... | |
5125 | (Tracing): this new section, its former contents, and... | |
5126 | (Understanding): this new section. | |
5127 | * src/getargs.h, src/getargs.c (verbose_flag): Remove, replaced | |
5128 | by... | |
5129 | (report_flag): this. | |
5130 | Adjust all dependencies. | |
5131 | (report_args, report_types, report_argmatch): New. | |
5132 | (usage, getargs): Report/support -r, --report. | |
5133 | * src/options.h | |
5134 | (struct option_table_struct): Rename as.., | |
5135 | (struct option_table_s): this. | |
5136 | Rename the `set_flag' member to `flag' to match with getopt_long's | |
5137 | struct. | |
5138 | * src/options.c (option_table): Split verbose into an entry for | |
5139 | %verbose, and another for --verbose. | |
5140 | Support --report/-r, so remove -r from the obsolete --raw. | |
5141 | * src/print.c: Attach full item sets and lookaheads reports to | |
5142 | report_flag instead of trace_flag. | |
5143 | * lib/argmatch.h, lib/argmatch.c: New, from Fileutils 4.1. | |
5144 | ||
5145 | 2002-05-24 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5146 | and Paul Eggert <eggert@twinsun.com> | |
5147 | ||
5148 | * data/bison.simple (yyparse): Correct error handling to conform to | |
5149 | POSIX and yacc. Specifically, after syntax error is discovered, | |
5150 | do not reduce further before shifting the error token. | |
5151 | Clean up the code a bit by removing the labels yyerrdefault, | |
5152 | yyerrhandle, yyerrpop. | |
5153 | * NEWS: Document the above. | |
5154 | ||
5155 | 2002-05-20 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5156 | ||
5157 | * data/bison.simple (yyr1): Don't use yy_token_number_type as element | |
5158 | type; it isn't always big enough, since it doesn't necessarily | |
5159 | include non-terminals. | |
5160 | (yytranslate): Expand definition of yy_token_number_type, so that | |
5161 | the latter can be removed. | |
5162 | (yy_token_number_type): Remove, only one use. | |
5163 | * data/bison.c++ (r1_): Parallel change to yyr1 in bison.simple--- | |
5164 | don't use TokenNumberType as element type. | |
5165 | ||
5166 | * tests/regression.at: Modify expected output to agree with change | |
5167 | to yyr1 and yytranslate. | |
5168 | ||
5169 | 2002-05-13 Florian Krohm <florian@edamail.fishkill.ibm.com> | |
5170 | ||
5171 | * src/reader.c (parse_action): Use copy_character instead of | |
5172 | obstack_1grow. | |
5173 | ||
5174 | 2002-05-13 Akim Demaille <akim@epita.fr> | |
5175 | ||
5176 | * tests/regression.at (Token definitions): Prototype yylex and | |
5177 | yyerror. | |
5178 | ||
5179 | 2002-05-12 Paul Hilfinger <Hilfinger@CS.Berkeley.EDU> | |
5180 | ||
5181 | * src/scan-skel.l: Correct off-by-one error in handling of __oline__. | |
5182 | * data/bison.simple (b4_sint_type, b4_uint_type): Correct to reflect | |
5183 | 32-bit arithmetic. | |
5184 | * data/bison.c++ (b4_sint_type, b4_uint_type): Ditto. | |
5185 | ||
5186 | 2002-05-07 Akim Demaille <akim@epita.fr> | |
5187 | ||
5188 | * tests/synclines.at: Be sure to prototype yylex and yyerror to | |
5189 | avoid GCC warnings. | |
5190 | ||
5191 | 2002-05-07 Akim Demaille <akim@epita.fr> | |
5192 | ||
5193 | Kill GCC warnings. | |
5194 | ||
5195 | * src/reduce.c (nonterminals_reduce): Don't loop over RITEM: loop | |
5196 | over the RHS of each rule. | |
5197 | * src/gram.h, src/gram.c (nritems): Is `unsigned int', not int. | |
5198 | * src/state.h (state_t): Member `nitems' is unsigned short. | |
5199 | * src/LR0.c (get_state): Adjust. | |
5200 | * src/reader.c (packgram): Likewise. | |
5201 | * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): `max' is of type | |
5202 | `Type'. | |
5203 | (muscle_insert_int_table): Remove, unused. | |
5204 | (prepare_rules): Remove `max'. | |
5205 | ||
5206 | 2002-05-06 Akim Demaille <akim@epita.fr> | |
5207 | ||
5208 | * src/closure.c (print_firsts): Display of the symbol tags. | |
5209 | (bitmatrix_print): Move to... | |
5210 | * lib/bitsetv-print.h, lib/bitsetv-print.c (bitsetv_matrix_dump): | |
5211 | here. | |
5212 | * tests/sets.at (Nullable, Broken Closure, Firsts): Adjust. | |
5213 | ||
5214 | 2002-05-06 Akim Demaille <akim@epita.fr> | |
5215 | ||
5216 | * src/muscle_tab.c (muscle_m4_output): Must return TRUE for | |
5217 | hash_do_for_each. | |
5218 | ||
5219 | 2002-05-06 Akim Demaille <akim@epita.fr> | |
5220 | ||
5221 | * src/LR0.c (new_state, get_state): Instead of using the global | |
5222 | `kernel_size' and `kernel_base', have two new arguments: | |
5223 | `core_size' and `core'. | |
5224 | Adjust callers. | |
5225 | ||
5226 | 2002-05-06 Akim Demaille <akim@epita.fr> | |
5227 | ||
5228 | * src/reader.c (packgram): No longer end `ritem' with a 0 | |
5229 | sentinel: it is not used. | |
5230 | ||
5231 | 2002-05-05 Akim Demaille <akim@epita.fr> | |
5232 | ||
5233 | New experimental feature: display the lookaheads in the report and | |
5234 | graph. | |
5235 | ||
5236 | * src/print (print_core): When --trace-flag, display the rules | |
5237 | lookaheads. | |
5238 | * src/print_graph.c (print_core): Likewise. | |
5239 | Swap the arguments. | |
5240 | Adjust caller. | |
5241 | ||
5242 | 2002-05-05 Akim Demaille <akim@epita.fr> | |
5243 | ||
5244 | * tests/torture.at (Many lookaheads): New test. | |
5245 | ||
5246 | 2002-05-05 Akim Demaille <akim@epita.fr> | |
5247 | ||
5248 | * src/output.c (GENERATE_OUTPUT_TABLE): Replace with... | |
5249 | (GENERATE_MUSCLE_INSERT_TABLE): this. | |
5250 | (output_int_table, output_unsigned_int_table, output_short_table) | |
5251 | (output_token_number_table, output_item_number_table): Replace with... | |
5252 | (muscle_insert_int_table, muscle_insert_unsigned_int_table) | |
5253 | (muscle_insert_short_table, muscle_insert_token_number_table) | |
5254 | (muscle_insert_item_number_table): these. | |
5255 | Adjust all callers. | |
5256 | (prepare_tokens): Don't free `translations', since... | |
5257 | * src/reader.h, src/reader.c (grammar_free): do it. | |
5258 | Move to... | |
5259 | * src/gram.h, src/gram.c (grammar_free): here. | |
5260 | * data/bison.simple, data/bison.c++: b4_token_number_max is now | |
5261 | b4_translate_max. | |
5262 | ||
5263 | 2002-05-05 Akim Demaille <akim@epita.fr> | |
5264 | ||
5265 | * src/output.c (output_unsigned_int_table): New. | |
5266 | (prepare_rules): `i' is unsigned. | |
5267 | `prhs', `rline', `r2' are unsigned int. | |
5268 | Rename muscle `rhs_number_max' as `rhs_max'. | |
5269 | Output muscles `prhs_max', `rline_max', and `r2_max'. | |
5270 | Free rline and r1. | |
5271 | * data/bison.simple, data/bison.c++: Adjust to use these muscles | |
5272 | to compute types instead of constant types. | |
5273 | * tests/regression.at (Web2c Actions): Adjust. | |
5274 | ||
5275 | 2002-05-04 Akim Demaille <akim@epita.fr> | |
5276 | ||
5277 | * src/symtab.h (SALIAS, SUNDEF): Rename as... | |
5278 | (USER_NUMBER_ALIAS, USER_NUMBER_UNDEFINED): these. | |
5279 | Adjust dependencies. | |
5280 | * src/output.c (token_definitions_output): Be sure not to output a | |
5281 | `#define 'a'' when fed with `%token 'a' "a"'. | |
5282 | * tests/regression.at (Token definitions): New. | |
5283 | ||
5284 | 2002-05-03 Paul Eggert <eggert@twinsun.com> | |
5285 | ||
5286 | * data/bison.simple (b4_token_defines): Also define YYTOKENTYPE | |
5287 | for K&R C. | |
5288 | ||
5289 | 2002-05-03 gettextize <bug-gnu-gettext@gnu.org> | |
5290 | ||
5291 | * Makefile.am (SUBDIRS): Remove intl. | |
5292 | (EXTRA_DIST): Add config/config.rpath. | |
5293 | ||
5294 | 2002-05-03 Akim Demaille <akim@epita.fr> | |
5295 | ||
5296 | * data/bison.simple (m4_if): Don't output empty enums. | |
5297 | And actually, output valid enum definitions :(. | |
5298 | ||
5299 | 2002-05-03 Akim Demaille <akim@epita.fr> | |
5300 | ||
5301 | * configure.bat: Remove, completely obsolete. | |
5302 | * Makefile.am (EXTRA_DIST): Adjust. | |
5303 | Don't distribute config.rpath... | |
5304 | * config/Makefile.am (EXTRA_DIST): Do it. | |
5305 | ||
5306 | 2002-05-03 Akim Demaille <akim@epita.fr> | |
5307 | ||
5308 | * configure.in (GETTEXT_VERSION): New. | |
5309 | Suggested by Bruno Haible for the forthcoming Gettext 0.10.3. | |
5310 | ||
5311 | 2002-05-03 Akim Demaille <akim@epita.fr> | |
5312 | ||
5313 | * data/bison.simple (b4_token_enum): New. | |
5314 | (b4_token_defines): Use it to output tokens both as #define and | |
5315 | enums. | |
5316 | Suggested by Paul Eggert. | |
5317 | * src/output.c (token_definitions_output): Don't output spurious | |
5318 | white spaces. | |
5319 | ||
5320 | 2002-05-03 Akim Demaille <akim@epita.fr> | |
5321 | ||
5322 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
5323 | ||
5324 | 2002-05-02 Robert Anisko <robert@lrde.epita.fr> | |
5325 | ||
5326 | * data/bison.c++: Adapt expansion of $s and @s to the C++ parser. | |
5327 | Update the stack class, give a try to deque as the default container. | |
5328 | ||
5329 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5330 | ||
5331 | * data/bison.simple (yyparse): Do not implement @$ = @1. | |
5332 | (YYLLOC_DEFAULT): Adjust to do it. | |
5333 | * doc/bison.texinfo (Location Default Action): Fix. | |
5334 | ||
5335 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5336 | ||
5337 | * src/reader.c (parse_braces): Merge into... | |
5338 | (parse_action): this. | |
5339 | ||
5340 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5341 | ||
5342 | * configure.in (ALL_LINGUAS): Remove. | |
5343 | * po/LINGUAS, hr.po: New. | |
5344 | ||
5345 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5346 | ||
5347 | Remove the so called hairy (semantic) parsers. | |
5348 | ||
5349 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove. | |
5350 | * src/gram.h, src/gram.c (semantic_parser): Remove. | |
5351 | (rule_t): Remove the guard and guard_line members. | |
5352 | * src/lex.h (token_t): remove tok_guard. | |
5353 | * src/options.c (option_table): Remove %guard and %semantic_parser | |
5354 | support. | |
5355 | * src/output.c, src/output.h (guards_output): Remove. | |
5356 | (prepare): Adjust. | |
5357 | (token_definitions_output): Don't output the `T' | |
5358 | tokens (???). | |
5359 | (output_skeleton): Don't output the guards. | |
5360 | * src/files.c, src/files.c (attrsfile): Remove. | |
5361 | * src/reader.c (symbol_list): Remove the guard and guard_line | |
5362 | members. | |
5363 | Adjust dependencies. | |
5364 | (parse_guard): Remove. | |
5365 | * data/bison.hairy: Remove. | |
5366 | * doc/bison.texinfo (Environment Variables): Remove occurrences of | |
5367 | BISON_HAIRY. | |
5368 | ||
5369 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5370 | ||
5371 | * src/reader.c (copy_at, copy_dollarm parse_braces, parse_action) | |
5372 | (parse_guard): Rename the formal argument `stack_offset' as | |
5373 | `rule_length', which is more readable. | |
5374 | Adjust callers. | |
5375 | (copy_at, copy_dollar): Instead of outputting the hard coded | |
5376 | values of $$, $n and so forth, output invocation to b4_lhs_value, | |
5377 | b4_lhs_location, b4_rhs_value, and b4_rhs_location. | |
5378 | Note: this patch partially drops `semantic-parser' support: it | |
5379 | always does `rule_length - n', where semantic parsers ought to | |
5380 | always use `-n'. | |
5381 | * data/bison.simple, data/bison.c++ (b4_lhs_value) | |
5382 | (b4_lhs_location, b4_rhs_value, and b4_rhs_location: New. | |
5383 | ||
5384 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5385 | ||
5386 | * configure.in (AC_INIT): Bump to 1.49b. | |
5387 | (AM_INIT_AUTOMAKE): Short invocation. | |
5388 | ||
5389 | 2002-05-02 Akim Demaille <akim@epita.fr> | |
5390 | ||
5391 | Version 1.49a. | |
5392 | ||
5393 | 2002-05-01 Akim Demaille <akim@epita.fr> | |
5394 | ||
5395 | * src/skeleton.h: Remove. | |
5396 | ||
5397 | 2002-05-01 Akim Demaille <akim@epita.fr> | |
5398 | ||
5399 | * src/skeleton.h: Fix the #endif. | |
5400 | Reported by Magnus Fromreide. | |
5401 | ||
5402 | 2002-04-26 Paul Eggert <eggert@twinsun.com> | |
5403 | ||
5404 | * data/bison.simple (YYSTYPE_IS_TRIVIAL, YYLTYPE_IS_TRIVIAL): | |
5405 | Define if we define YYSTYPE and YYLTYPE, respectively. | |
5406 | (YYCOPY): Fix [] quoting problem in the non-GCC case. | |
5407 | ||
5408 | 2002-04-25 Robert Anisko <robert@lrde.epita.fr> | |
5409 | ||
5410 | * src/scan-skel.l: Postprocess quadrigraphs. | |
5411 | ||
5412 | * src/reader.c (copy_character): New function, used to output | |
5413 | single characters while replacing `[' and `]' with quadrigraphs, to | |
5414 | avoid troubles with M4 quotes. | |
5415 | (copy_comment): Output characters with copy_character. | |
5416 | (read_additionnal_code): Likewise. | |
5417 | (copy_string2): Likewise. | |
5418 | (copy_definition): Likewise. | |
5419 | ||
5420 | * tests/calc.at: Exercise M4 quoting. | |
5421 | ||
5422 | 2002-04-25 Akim Demaille <akim@epita.fr> | |
5423 | ||
5424 | * tests/sets.at (AT_EXTRACT_SETS): Sed portability issue: no space | |
5425 | between `!' and the command. | |
5426 | Reported by Paul Eggert. | |
5427 | ||
5428 | 2002-04-24 Robert Anisko <robert@lrde.epita.fr> | |
5429 | ||
5430 | * tests/calc.at: Exercise prologue splitting. | |
5431 | ||
5432 | * data/bison.simple, data/bison.c++: Use `b4_pre_prologue' and | |
5433 | `b4_post_prologue' instead of `b4_prologue'. | |
5434 | ||
5435 | * src/output.c (prepare): Add the `pre_prologue' and `post_prologue' | |
5436 | muscles. | |
5437 | (output): Free pre_prologue_obstack and post_prologue_obstack. | |
5438 | * src/files.h, src/files.c (attrs_obstack): Remove. | |
5439 | (pre_prologue_obstack, post_prologue_obstack): New. | |
5440 | * src/reader.c (copy_definition): Add a parameter to specify the | |
5441 | obstack to fill, instead of using attrs_obstack unconditionally. | |
5442 | (read_declarations): Pass pre_prologue_obstack to copy_definition if | |
5443 | `%union' has not yet been seen, pass post_prologue_obstack otherwise. | |
5444 | ||
5445 | 2002-04-23 Paul Eggert <eggert@twinsun.com> | |
5446 | ||
5447 | * data/bison.simple: Remove unnecessary commentary and white | |
5448 | space differences from 1_29-branch. | |
5449 | Depend on YYERROR_VERBOSE, not defined (YYERROR_VERBOSE). | |
5450 | ||
5451 | (union yyalloc, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYCOPY, | |
5452 | YYSTACK_RELOCATE): Do not define if yyoverflow is defined, or | |
5453 | if this is a C++ parser and YYSTYPE or YYLTYPE has nontrivial | |
5454 | constructors or destructors. | |
5455 | ||
5456 | (yyparse) [! defined YYSTACK_RELOCATE]: Do not relocate the stack. | |
5457 | ||
5458 | 2002-04-23 Akim Demaille <akim@epita.fr> | |
5459 | ||
5460 | * tests/sets.at (AT_EXTRACT_SETS): Don't use 8 char long sed labels. | |
5461 | * tests/synclines.at (AT_TEST_SYNCLINE): Be robust to GCC's | |
5462 | location with columns. | |
5463 | * tests/conflicts.at (%nonassoc and eof): Don't use `error.h'. | |
5464 | All reported by Paul Eggert. | |
5465 | ||
5466 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5467 | ||
5468 | * src/reduce.c (dump_grammar): Move to... | |
5469 | * src/gram.h, src/gram.c (grammar_dump): here. | |
5470 | Be sure to separate long item numbers. | |
5471 | Don't read the members of a rule's prec if its nil. | |
5472 | ||
5473 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5474 | ||
5475 | * src/output.c (table_size, table_grow): New. | |
5476 | (MAXTABLE): Remove, replace uses with table_size. | |
5477 | (pack_vector): Instead of dying when the table is too big, grow it. | |
5478 | ||
5479 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5480 | ||
5481 | * data/bison.simple (yyr1): Its type is that of a token number. | |
5482 | * data/bison.c++ (r1_): Likewise. | |
5483 | * tests/regression.at (Web2c Actions): Adjust. | |
5484 | ||
5485 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5486 | ||
5487 | * src/reader.c (token_translations_init): 256 is now the default | |
5488 | value for the error token, i.e., it will be assigned another | |
5489 | number if the user assigned 256 to one of her tokens. | |
5490 | (reader): Don't force 256 to error. | |
5491 | * doc/bison.texinfo (Symbols): Adjust. | |
5492 | * tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR) | |
5493 | (AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3 | |
5494 | etc. instead of 10, 20, 30 (which was used to `jump' over error | |
5495 | (256) and undefined (2)). | |
5496 | ||
5497 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5498 | ||
5499 | Propagate more token_number_t. | |
5500 | ||
5501 | * src/gram.h (token_number_as_item_number) | |
5502 | (item_number_as_token_number): New. | |
5503 | * src/output.c (GENERATE_OUTPUT_TABLE): New. | |
5504 | Use it to create output_item_number_table and | |
5505 | output_token_number_table. | |
5506 | * src/LR0.c, src/derives.c, src/gram.c, src/gram.h, src/lalr.c, | |
5507 | * src/lex.c, src/nullable.c, src/output.c, src/print.c, | |
5508 | * src/print_graph.c, src/reader.c, src/reduce.c, src/state.h, | |
5509 | * src/symtab.c, src/symtab.h: Use token_number_t instead of shorts. | |
5510 | ||
5511 | 2002-04-22 Akim Demaille <akim@epita.fr> | |
5512 | ||
5513 | * src/output.h, src/output.c (get_lines_number): Remove. | |
5514 | ||
5515 | 2002-04-19 Akim Demaille <akim@epita.fr> | |
5516 | ||
5517 | * doc/bison.texinfo (Actions): Make clear that `|' is not the same | |
5518 | as Lex/Flex'. | |
5519 | (Debugging): More details about enabling the debugging features. | |
5520 | (Table of Symbols): Describe $$, $n, @$, and @n. | |
5521 | Suggested by Tim Josling. | |
5522 | ||
5523 | 2002-04-19 Akim Demaille <akim@epita.fr> | |
5524 | ||
5525 | * doc/bison.texinfo: Remove the uses of the obsolete @refill. | |
5526 | ||
5527 | 2002-04-10 Akim Demaille <akim@epita.fr> | |
5528 | ||
5529 | * src/system.h: Rely on HAVE_LIMITS_H. | |
5530 | Suggested by Paul Eggert. | |
5531 | ||
5532 | 2002-04-09 Akim Demaille <akim@epita.fr> | |
5533 | ||
5534 | * tests/calc.at (_AT_CHECK_CALC_ERROR): Receive as argument the | |
5535 | full stderr, and strip it according to the bison options, instead | |
5536 | of composing the error message from different bits. | |
5537 | This makes it easier to check for several error messages. | |
5538 | Adjust all the invocations. | |
5539 | Add an invocation exercising the error token. | |
5540 | Add an invocation demonstrating a stupid error message. | |
5541 | (_AT_DATA_CALC_Y): Follow the GCS: initial column is 1, not 0. | |
5542 | Adjust the tests. | |
5543 | Error message are for stderr, not stdout. | |
5544 | ||
5545 | 2002-04-09 Akim Demaille <akim@epita.fr> | |
5546 | ||
5547 | * src/gram.h, src/gram.c (error_token_number): Remove, use | |
5548 | errtoken->number. | |
5549 | * src/reader.c (reader): Don't specify the user token number (2) | |
5550 | for $undefined, as it uselessly prevents using it. | |
5551 | * src/gram.h (token_number_t): Move to... | |
5552 | * src/symtab.h: here. | |
5553 | (state_t.number): Is a token_number_t. | |
5554 | * src/print.c, src/reader.c: Use undeftoken->number instead of | |
5555 | hard coded 2. | |
5556 | (Even though this 2 is not the same as above: the number of the | |
5557 | undeftoken remains being 2, it is its user token number which | |
5558 | might not be 2). | |
5559 | * src/output.c (prepare_tokens): Rename the `maxtok' muscle with | |
5560 | `user_token_number_max'. | |
5561 | Output `undef_token_number'. | |
5562 | * data/bison.simple, data/bison.c++: Use them. | |
5563 | Be sure to map invalid yylex return values to | |
5564 | `undef_token_number'. This saves us from gratuitous SEGV. | |
5565 | ||
5566 | * tests/conflicts.at (Solved SR Conflicts) | |
5567 | (Unresolved SR Conflicts): Adjust. | |
5568 | * tests/regression.at (Web2c Actions): Adjust. | |
5569 | ||
5570 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
5571 | ||
5572 | * data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/. | |
5573 | Adding #line. | |
5574 | Remove the duplicate `typedefs'. | |
5575 | (RhsNumberType): Fix the declaration and various other typos. | |
5576 | Use __ofile__. | |
5577 | * data/bison.simple: Use __ofile__. | |
5578 | * src/scan-skel.l: Handle __ofile__. | |
5579 | ||
5580 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
5581 | ||
5582 | * src/gram.h (item_number_t): New, the type of item numbers in | |
5583 | RITEM. Note that it must be able to code symbol numbers as | |
5584 | positive number, and the negation of rule numbers as negative | |
5585 | numbers. | |
5586 | Adjust all dependencies (pretty many). | |
5587 | * src/reduce.c (rule): Remove this `short *' pointer: use | |
5588 | item_number_t. | |
5589 | * src/system.h (MINSHORT, MAXSHORT): Remove. | |
5590 | Include `limits.h'. | |
5591 | Adjust dependencies to using SHRT_MAX and SHRT_MIN. | |
5592 | (shortcpy): Remove. | |
5593 | (MAXTABLE): Move to... | |
5594 | * src/output.c (MAXTABLE): here. | |
5595 | (prepare_rules): Use output_int_table to output rhs. | |
5596 | * data/bison.simple, data/bison.c++: Adjust. | |
5597 | * tests/torture.at (Big triangle): Move the limit from 254 to | |
5598 | 500. | |
5599 | * tests/regression.at (Web2c Actions): Ajust. | |
5600 | ||
5601 | Trying with bigger grammars shows various phenomena: at 3000 (28Mb | |
5602 | of grammar file) bison is killed by my system, at 2000 (12Mb) bison | |
5603 | passes, but produces negative #line number, once fixed, GCC is | |
5604 | killed while compiling 14Mb, at 1500 (6.7 Mb of grammar, 8.2Mb of | |
5605 | C), it passes. | |
5606 | * src/state.h (state_h): Code input lines on ints, not shorts. | |
5607 | ||
5608 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
5609 | ||
5610 | * src/reduce.c (reduce_grammar): First reduce the nonterminals, | |
5611 | and then the grammar. | |
5612 | ||
5613 | 2002-04-08 Akim Demaille <akim@epita.fr> | |
5614 | ||
5615 | * src/system.h: No longer using strndup. | |
5616 | ||
5617 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5618 | ||
5619 | * src/muscle_tab.h (MUSCLE_INSERT_LONG_INT): New. | |
5620 | * src/output.c (output_table_data): Return the longest number. | |
5621 | (prepare_tokens): Output `token_number_max'). | |
5622 | * data/bison.simple, data/bison.c++ (b4_sint_type, b4_uint_type): | |
5623 | New. | |
5624 | Use them to define yy_token_number_type/TokenNumberType. | |
5625 | Use this type for yytranslate. | |
5626 | * tests/torture.at (Big triangle): Push the limit from 124 to | |
5627 | 253. | |
5628 | * tests/regression.at (Web2c Actions): Adjust. | |
5629 | ||
5630 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5631 | ||
5632 | * tests/torture.at (Big triangle): New. | |
5633 | (GNU AWK Grammar, GNU Cim Grammar): Move to... | |
5634 | * tests/existing.at: here. | |
5635 | ||
5636 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5637 | ||
5638 | * src/gram.h, src/gram.c (nitems): Remove, it is an alias of | |
5639 | nritems. | |
5640 | Adjust dependencies. | |
5641 | ||
5642 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5643 | ||
5644 | * src/reader.c: Normalize increments to prefix form. | |
5645 | ||
5646 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5647 | ||
5648 | * src/reader.c, symtab.c: Remove debugging code. | |
5649 | ||
5650 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5651 | ||
5652 | Rename all the `bucket's as `symbol_t'. | |
5653 | ||
5654 | * src/gram.c, src/gram.h, src/lex.c, src/lex.h, src/output.c, | |
5655 | * src/reader.c, src/reader.h, src/reduce.c, src/state.h, | |
5656 | * src/symtab.c, src/symtab.h (bucket): Rename as... | |
5657 | (symbol_t): this. | |
5658 | (symbol_list_new, bucket_check_defined, bucket_make_alias) | |
5659 | (bucket_check_alias_consistence, bucket_pack, bucket_translation) | |
5660 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
5661 | (buckets_new, buckets_free, buckets_do): Rename as... | |
5662 | (symbol_list_new, symbol_check_defined, symbol_make_alias) | |
5663 | (symbol_check_alias_consistence, symbol_pack, symbol_translation) | |
5664 | (symbol_new, symbol_free, hash_compare_symbol_t, hash_symbol_t) | |
5665 | (symbols_new, symbols_free, symbols_do): these. | |
5666 | ||
5667 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5668 | ||
5669 | Use lib/hash for the symbol table. | |
5670 | ||
5671 | * src/gram.c (ntokens): Initialize to 1, to reserve a slot for | |
5672 | EOF. | |
5673 | * src/lex.c (lex): Set the `number' member of new terminals. | |
5674 | * src/reader.c (bucket_check_defined, bucket_make_alias) | |
5675 | (bucket_check_alias_consistence, bucket_translation): New. | |
5676 | (reader, grammar_free, readgram, token_translations_init) | |
5677 | (packsymbols): Adjust. | |
5678 | (reader): Number the predefined tokens. | |
5679 | * src/reduce.c (inaccessable_symbols): Just use hard coded numbers | |
5680 | for predefined tokens. | |
5681 | * src/symtab.h (bucket): Remove all the hash table related | |
5682 | members. | |
5683 | * src/symtab.c (symtab): Replace by... | |
5684 | (bucket_table): this. | |
5685 | (bucket_new, bucket_free, hash_compare_bucket, hash_bucket) | |
5686 | (buckets_new, buckets_do): New. | |
5687 | ||
5688 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5689 | ||
5690 | * src/gram.c (nitems, nrules, nsyms, ntokens, nvars, nritems) | |
5691 | (start_symbol, max_user_token_number, semantic_parser) | |
5692 | (error_token_number): Initialize. | |
5693 | * src/reader.c (grammar, start_flag, startval, typed, lastprec): | |
5694 | Initialize. | |
5695 | (reader): Don't. | |
5696 | (errtoken, eoftoken, undeftoken, axiom): Extern. | |
5697 | ||
5698 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5699 | ||
5700 | * src/gram.h (rule_s): prec and precsym are now pointers | |
5701 | to the bucket giving the priority/associativity. | |
5702 | Member `associativity' removed: useless. | |
5703 | * src/reduce.c, src/conflicts.c: Adjust. | |
5704 | ||
5705 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5706 | ||
5707 | * src/lalr.c, src/LR0.c, src/closure.c, src/gram.c, src/reduce.c: | |
5708 | Properly escape the symbols' TAG when outputting them. | |
5709 | ||
5710 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5711 | ||
5712 | * src/lalr.h (LA): Is a bitsetv, not bitset*. | |
5713 | ||
5714 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5715 | ||
5716 | * src/lalr.h, src/lalr.c (LAruleno): Replace with... | |
5717 | (LArule): this, which is an array to rule_t*. | |
5718 | * src/print.c, src/conflicts.c: Adjust. | |
5719 | ||
5720 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5721 | ||
5722 | * src/gram.h (rule_t): Rename `number' as `user_number'. | |
5723 | `number' is a new member. | |
5724 | Adjust dependencies. | |
5725 | * src/reduce.c (reduce_grammar_tables): Renumber rule_t.number. | |
5726 | ||
5727 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5728 | ||
5729 | As a result of the previous patch, it is no longer needed | |
5730 | to reorder ritem itself. | |
5731 | ||
5732 | * src/reduce.c (reduce_grammar_tables): Don't sort RITEM. | |
5733 | ||
5734 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5735 | ||
5736 | Be sure never to walk through RITEMS, but use only data related to | |
5737 | the rules themselves. RITEMS should be banished. | |
5738 | ||
5739 | * src/output.c (output_token_translations): Rename as... | |
5740 | (prepare_tokens): this. | |
5741 | In addition to `translate', prepare the muscles `tname' and | |
5742 | `toknum', which were handled by... | |
5743 | (output_rule_data): this. | |
5744 | Remove, and move the remainder of its outputs into... | |
5745 | (prepare_rules): this new routines, which also merges content from | |
5746 | (output_gram): this. | |
5747 | (prepare_rules): Be sure never to walk through RITEMS. | |
5748 | (output_stos): Rename as... | |
5749 | (prepare_stos): this. | |
5750 | (output): Always invoke prepare_states, after all, just don't use it | |
5751 | in the output if you don't need it. | |
5752 | ||
5753 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5754 | ||
5755 | * src/LR0.c (new_state): Display `nstates' as the name of the | |
5756 | newly created state. | |
5757 | Adjust to initialize first_state and last_state if needed. | |
5758 | Be sure to distinguish the initial from the final state. | |
5759 | (new_states): Create the itemset of the initial state, and use | |
5760 | new_state. | |
5761 | * src/closure.c (closure): Now that the initial state has its | |
5762 | items properly set, there is no need for a special case when | |
5763 | creating `ruleset'. | |
5764 | ||
5765 | As a result, now the rule 0, reducing to $axiom, is visible in the | |
5766 | outputs. Adjust the test suite. | |
5767 | ||
5768 | * tests/conflicts.at (Solved SR Conflicts) | |
5769 | (Unresolved SR Conflicts): Adjust. | |
5770 | * tests/regression.at (Web2c Report, Rule Line Numbers): Idem. | |
5771 | * tests/conflicts.at (S/R in initial): New. | |
5772 | ||
5773 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5774 | ||
5775 | * src/LR0.c (allocate_itemsets): Don't loop over ritem: loop over | |
5776 | the RHS of the rules. | |
5777 | * src/output.c (output_gram): Likewise. | |
5778 | ||
5779 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5780 | ||
5781 | * src/gram.h (rule_t): `lhs' is now a pointer to the symbol's | |
5782 | bucket. | |
5783 | Adjust all dependencies. | |
5784 | * src/reduce.c (nonterminals_reduce): Don't forget to renumber the | |
5785 | `number' of the buckets too. | |
5786 | * src/gram.h: Include `symtab.h'. | |
5787 | (associativity): Move to... | |
5788 | * src/symtab.h: here. | |
5789 | No longer include `gram.h'. | |
5790 | ||
5791 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5792 | ||
5793 | * src/gram.h, src/gram.c (rules_rhs_length): New. | |
5794 | (ritem_longest_rhs): Use it. | |
5795 | * src/gram.h (rule_t): `number' is a new member. | |
5796 | * src/reader.c (packgram): Set it. | |
5797 | * src/reduce.c (reduce_grammar_tables): Move the useless rules at | |
5798 | the end of `rules', and count them out of `nrules'. | |
5799 | (reduce_output, dump_grammar): Adjust. | |
5800 | * src/print.c (print_grammar): It is no longer needed to check for | |
5801 | the usefulness of a rule, as useless rules are beyond `nrules + 1'. | |
5802 | * tests/reduce.at (Reduced Automaton): New test. | |
5803 | ||
5804 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5805 | ||
5806 | * src/reduce.c (inaccessable_symbols): Fix a buglet: because of a | |
5807 | lacking `+ 1' to nrules, Bison reported as useless a token if it | |
5808 | was used solely to set the precedence of the last rule... | |
5809 | ||
5810 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5811 | ||
5812 | * data/bison.c++, data/bison.simple: Don't output the current file | |
5813 | name in #line, to avoid useless diffs between two identical | |
5814 | outputs under different names. | |
5815 | ||
5816 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5817 | ||
5818 | * src/closure.c, src/print.c, src/reader.c, src/reduce.c: | |
5819 | Normalize loops to using `< nrules + 1', not `<= nrules'. | |
5820 | ||
5821 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5822 | ||
5823 | * TODO: Update. | |
5824 | ||
5825 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5826 | ||
5827 | * src/output.c, src/reader.c, src/symtab.c, src/symtab.h: Rename | |
5828 | bucket.value as bucket.number. | |
5829 | ||
5830 | 2002-04-07 Akim Demaille <akim@epita.fr> | |
5831 | ||
5832 | * src/closure.c, src/derives.c, src/gram.h, src/lalr.c, | |
5833 | * src/nullable.c, src/output.c, src/print.c, src/print_graph.c, | |
5834 | * src/reader.c, src/reduce.c: Let rule_t.rhs point directly to the | |
5835 | RHS, instead of being an index in RITEMS. | |
5836 | ||
5837 | 2002-04-04 Paul Eggert <eggert@twinsun.com> | |
5838 | ||
5839 | * doc/bison.texinfo: Update copyright date. | |
5840 | (Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII. | |
5841 | (Symbols): Warn about running Bison in one character set, | |
5842 | but compiling and/or running in an incompatible one. | |
5843 | Warn about character code 256, too. | |
5844 | ||
5845 | 2002-04-03 Paul Eggert <eggert@twinsun.com> | |
5846 | ||
5847 | * src/bison.data (YYSTACK_ALLOC): Depend on whether | |
5848 | YYERROR_VERBOSE is nonzero, not whether it is defined. | |
5849 | ||
5850 | Merge changes from bison-1_29-branch. | |
5851 | ||
5852 | 2002-03-20 Paul Eggert <eggert@twinsun.com> | |
5853 | ||
5854 | Merge fixes from Debian bison_1.34-1.diff. | |
5855 | ||
5856 | * configure.in (AC_PREREQ): 2.53. | |
5857 | ||
5858 | 2002-03-20 Akim Demaille <akim@epita.fr> | |
5859 | ||
5860 | * src/conflicts.c (log_resolution): Argument `resolution' is const. | |
5861 | ||
5862 | 2002-03-19 Paul Eggert <eggert@twinsun.com> | |
5863 | ||
5864 | * src/bison.simple (YYCOPY): New macro. | |
5865 | (YYSTACK_RELOCATE): Use it. | |
5866 | Remove Type arg; no longer needed. All callers changed. | |
5867 | (yymemcpy): Remove; no longer needed. | |
5868 | ||
5869 | * Makefile.am (AUTOMAKE_OPTIONS): 1.6. | |
5870 | * doc/Makefile.am (AUTOMAKE_OPTIONS): Remove. | |
5871 | ||
5872 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
5873 | ||
5874 | Test and fix the #line outputs. | |
5875 | ||
5876 | * tests/atlocal.at (GCC): New. | |
5877 | * tests/synclines.at (AT_TEST_SYNCLINE): New macro. | |
5878 | (Prologue synch line, ,%union synch line, Postprologue synch line) | |
5879 | (Action synch line, Epilogue synch line): New tests. | |
5880 | * src/reader.c (parse_union_decl): Define the muscle stype_line. | |
5881 | * data/bison.simple, data/bison.c++: Use it. | |
5882 | ||
5883 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
5884 | ||
5885 | * tests/regression.at (%nonassoc and eof, Unresolved SR Conflicts) | |
5886 | (Solved SR Conflicts, %expect not enough, %expect right) | |
5887 | (%expect too much): Move to... | |
5888 | * tests/conflicts.at: this new file. | |
5889 | ||
5890 | 2002-03-19 Akim Demaille <akim@epita.fr> | |
5891 | ||
5892 | * data/m4sugar/m4sugar.m4: Update from CVS Autoconf. | |
5893 | * data/bison.simple, data/bison.c++: Handle the `#define' part, so | |
5894 | that we can move to enums for instance. | |
5895 | * src/output.c (token_definitions_output): Output a list of | |
5896 | `token-name, token-number' instead of the #define. | |
5897 | (output_skeleton): Name this list `b4_tokens', not `b4_tokendefs'. | |
5898 | ||
5899 | 2002-03-14 Akim Demaille <akim@epita.fr> | |
5900 | ||
5901 | Use Gettext 0.11.1. | |
5902 | ||
5903 | 2002-03-09 Robert Anisko <robert@lrde.epita.fr> | |
5904 | ||
5905 | * data/bison.c++: Make the user able to add members to the generated | |
5906 | parser by subclassing. | |
5907 | ||
5908 | 2002-03-05 Robert Anisko <robert@lrde.epita.fr> | |
5909 | ||
5910 | * src/reader.c (read_additionnal_code): `c' should be an integer, not | |
5911 | a character. | |
5912 | Reported by Nicolas Tisserand and Nicolas Burrus. | |
5913 | ||
5914 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
5915 | ||
5916 | * src/reader.c: Warn about lacking semi-colons, do not complain. | |
5917 | ||
5918 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
5919 | ||
5920 | * data/bison.c++: Remove a debug line. | |
5921 | ||
5922 | 2002-03-04 Robert Anisko <robert@lrde.epita.fr> | |
5923 | ||
5924 | * data/bison.c++: Unmerge value as yylval and value as yyval. Unmerge | |
5925 | location as yylloc and location as yyloc. Use YYLLOC_DEFAULT, and | |
5926 | provide a default implementation. | |
5927 | ||
5928 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5929 | ||
5930 | * tests/input.at (Invalid $n, Invalid @n): Add the ending `;'. | |
5931 | * tests/output.at (AT_CHECK_OUTPUT): Likewise. | |
5932 | * tests/headers.at (AT_TEST_CPP_GUARD_H): Ditto. | |
5933 | * tests/semantic.at (Parsing Guards): Similarly. | |
5934 | * src/reader.at (readgram): Complain if the last rule is not ended | |
5935 | with a semi-colon. | |
5936 | ||
5937 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5938 | ||
5939 | * src/warshall.h, src/warshall.c (bitmatrix_print): Move to... | |
5940 | * src/closure.c: here. | |
5941 | (set_firsts): Use bitsetv_reflexive_transitive_closure instead of | |
5942 | RTC. | |
5943 | * src/warshall.h, src/warshall.c: Remove. | |
5944 | * tests/sets.at (Broken Closure): Adjust. | |
5945 | ||
5946 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5947 | ||
5948 | * src/output.c (output_skeleton): tempdir is const. | |
5949 | bytes_read is unused. | |
5950 | ||
5951 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5952 | ||
5953 | * lib/bbitset.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
5954 | * lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/sbitset.c: | |
5955 | Update. | |
5956 | From Michael Hayes. | |
5957 | ||
5958 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5959 | ||
5960 | * src/closure.c (closure): `r' is unused. | |
5961 | ||
5962 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5963 | ||
5964 | * tests/sets.at (Broken Closure): Add the ending `;'. | |
5965 | * src/reader.at (readgram): Complain if a rule is not ended with a | |
5966 | semi-colon. | |
5967 | ||
5968 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5969 | ||
5970 | * src/conflicts.c (set_conflicts): Use bitset_disjoint_p. | |
5971 | (count_sr_conflicts): Use bitset_count. | |
5972 | * src/reduce.c (inaccessable_symbols): Ditto. | |
5973 | (bits_size): Remove. | |
5974 | * src/warshall.h, src/warshall.c: Convert to bitsetv. | |
5975 | ||
5976 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5977 | ||
5978 | * src/closure.c, src/conflicts.c, src/lalr.c, src/print.c, | |
5979 | * src/reduce.c: Remove the `bitset_zero's following the | |
5980 | `bitset_create's, as now it is performed by the latter. | |
5981 | ||
5982 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5983 | ||
5984 | * lib/bitset.c, lib/bitset.h, lib/bitsetv.c, lib/bitsetv.h, | |
5985 | * lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, lib/lbitset.h, | |
5986 | * lib/sbitset.c, lib/sbitset.h, lib/bbitset.h: Update from the | |
5987 | latest sources from Michael. | |
5988 | ||
5989 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5990 | ||
5991 | * src/output.c (output): Don't free the grammar. | |
5992 | * src/reader.c (grammar_free): New. | |
5993 | * src/main.c (main): Call it and don't free symtab here. | |
5994 | ||
5995 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
5996 | ||
5997 | * src/lex.c (parse_percent_token): Be sure to 0-end token_buffer | |
5998 | before returning. | |
5999 | Reported by Benoit Perrot. | |
6000 | ||
6001 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6002 | ||
6003 | Use bitset operations when possible, not loops over bits. | |
6004 | ||
6005 | * src/conflicts.c (set_conflicts, count_sr_conflicts): Use | |
6006 | bitset_or. | |
6007 | * src/print.c (print_reductions): Use bitset_and, bitset_andn. | |
6008 | * src/reduce.c (useless_nonterminals): Formatting changes. | |
6009 | * src/warshall.c (TC): Use bitset_or. | |
6010 | ||
6011 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6012 | ||
6013 | * src/lalr.h, src/lalr.c (tokensetsize): Remove, unused. | |
6014 | * src/system.h (BITS_PER_WORD, WORDSIZE, SETBIT, RESETBIT, BITISSET): | |
6015 | Ditto. | |
6016 | ||
6017 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6018 | ||
6019 | * src/lalr.c (F): Now a bitset*. | |
6020 | Adjust all dependencies. | |
6021 | ||
6022 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6023 | ||
6024 | * src/conflicts.c (shiftset, lookaheadset): Now bitset. | |
6025 | Adjust all dependencies. | |
6026 | ||
6027 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6028 | ||
6029 | * src/L0.c, src/LR0.h (nstates): Be size_t. | |
6030 | Adjust comparisons (signed vs unsigned). | |
6031 | * src/conflics.c, src/lalr.c, src/lalr.h, src/output.c (LA): Now a | |
6032 | bitset*. | |
6033 | Adjust all dependencies. | |
6034 | ||
6035 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6036 | ||
6037 | * src/closure.c (firsts): Now, also a bitset. | |
6038 | Adjust all dependencies. | |
6039 | (varsetsize): Remove, now unused. | |
6040 | * src/warshall.h, src/warshall.c: Now work on arrays of bitsets. | |
6041 | ||
6042 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6043 | ||
6044 | * src/print.c: Convert to use bitset.h, not hand coded iterations | |
6045 | over ints. | |
6046 | ||
6047 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6048 | ||
6049 | * src/reduce.c: Convert to use bitset.h, not hand coded BSet. | |
6050 | ||
6051 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6052 | ||
6053 | * src/closure.c (ruleset): Be a bitset. | |
6054 | (rulesetsize): Remove. | |
6055 | ||
6056 | 2002-03-04 Akim Demaille <akim@epita.fr> | |
6057 | ||
6058 | * lib/bitset-int.h, lib/bitset.c, lib/bitset.h, lib/bitsetv.c, | |
6059 | * lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/lbitset.c, | |
6060 | * lib/lbitset.h, lib/sbitset.c, lib/sbitset.h: New. | |
6061 | * src/closure.c (fderives): Be an array of bitsets. | |
6062 | ||
6063 | 2002-02-28 Robert Anisko <robert@lrde.epita.fr> | |
6064 | ||
6065 | * data/bison.c++: Merge the two generated headers. Insert a copyright | |
6066 | notice in each output file. | |
6067 | ||
6068 | 2002-02-28 Akim Demaille <akim@epita.fr> | |
6069 | ||
6070 | * data/bison.c++: Copy the prologue of bison.simple to fetch | |
6071 | useful M4 definitions, such as b4_header_guard. | |
6072 | ||
6073 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
6074 | ||
6075 | * src/getargs.c (version): Give the name of the authors, and use a | |
6076 | translator friendly scheme for the bgr | |
6077 | copyright notice. | |
6078 | ||
6079 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
6080 | ||
6081 | * src/output.c (header_output): Remove, now handled completely via | |
6082 | M4. | |
6083 | ||
6084 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
6085 | ||
6086 | * m4/m4.m4: New, from CVS Autoconf. | |
6087 | * configure.in: Invoke it. | |
6088 | * src/output.c (output_skeleton): Use its result instead of the | |
6089 | hard coded name. | |
6090 | ||
6091 | 2002-02-25 Akim Demaille <akim@epita.fr> | |
6092 | ||
6093 | * lib/tempname.c, lib/mkstemp.c, m4/mkstemp.m4: New, stolen from | |
6094 | Fileutils 4.1.5. | |
6095 | * configure.in: Invoke UTILS_FUNC_MKSTEMP. | |
6096 | * src/output.c (output_skeleton): Use mkstemp to create a real | |
6097 | temporary file. | |
6098 | Move the filling of `skeleton' and its muscle to... | |
6099 | (prepare): here. | |
6100 | (output): Move the definition of the prologue muscle to... | |
6101 | (prepare): here. | |
6102 | * src/system.h (DEFAULT_TMPDIR): New. | |
6103 | ||
6104 | 2002-02-14 Paul Eggert <eggert@twinsun.com> | |
6105 | ||
6106 | Remove the support for C++ namespace cleanliness; it was | |
6107 | causing more problems than it was curing, since it didn't work | |
6108 | properly on some nonstandard C++ compilers. This can wait | |
6109 | for a proper C++ parser. | |
6110 | ||
6111 | * NEWS: Document this. | |
6112 | * doc/bison.texinfo (Bison Parser, Debugging): Remove special mention | |
6113 | of C++, as it's treated like C now. | |
6114 | * src/bison.simple (YYSTD): Remove. | |
6115 | (YYSIZE_T, YYFPRINTF, YYPARSE_PARAM_ARG, YYPARSE_PARAM_DECL): | |
6116 | Treat C++ just like Standard C instead of trying to support | |
6117 | namespace cleanliness. | |
6118 | ||
6119 | 2002-02-14 Akim Demaille <akim@epita.fr> | |
6120 | ||
6121 | * tests/regression.at (else): Adjust to Andreas' change. | |
6122 | ||
6123 | 2002-02-14 Akim Demaille <akim@epita.fr> | |
6124 | ||
6125 | * lib/Makefile.am (EXTRA_DIST): Ship strnlen.c. | |
6126 | ||
6127 | 2002-02-13 Andreas Schwab <schwab@suse.de> | |
6128 | ||
6129 | * src/output.c (output_rule_data): Don't output NULL, it might | |
6130 | not be defined yet. | |
6131 | ||
6132 | 2002-02-11 Robert Anisko <robert@lrde.epita.fr> | |
6133 | ||
6134 | * data/bison.c++ (YYDEBUG, YYERROR_VERBOSE): After the prologue. | |
6135 | (Copyright notice): Update. | |
6136 | ||
6137 | 2002-02-11 Akim Demaille <akim@epita.fr> | |
6138 | ||
6139 | * tests/regression.at (%nonassoc and eof): Don't include | |
6140 | nonportable headers. | |
6141 | ||
6142 | 2002-02-08 Robert Anisko <robert@lrde.epita.fr> | |
6143 | ||
6144 | * data/bison.c++: Correct error recovery. Make the user able to | |
6145 | initialize the starting location. | |
6146 | ||
6147 | 2002-02-07 Akim Demaille <akim@epita.fr> | |
6148 | ||
6149 | * tests/input.at: New. | |
6150 | ||
6151 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
6152 | ||
6153 | * data/bison.c++: Replace some direct m4 expansions by constants. Be | |
6154 | more consistent when naming methods and variables. Put preprocessor | |
6155 | directives around tables only needed for debugging. | |
6156 | ||
6157 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
6158 | ||
6159 | * data/bison.c++ (yy::b4_name::print_): New method, replaces yyprint in | |
6160 | C++ parsers. | |
6161 | (yy::b4_name::parse): Use print_. | |
6162 | ||
6163 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
6164 | ||
6165 | * data/bison.c++ (yy::b4_name::parse): Error recovery is back. | |
6166 | ||
6167 | 2002-02-07 Robert Anisko <robert@lrde.epita.fr> | |
6168 | ||
6169 | * data/bison.c++ (yy::b4_name::error_): New method, replaces yyerror in | |
6170 | C++ parsers. | |
6171 | (yy::b4_name::parse): Build verbose error messages, and use error_. | |
6172 | ||
6173 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> | |
6174 | ||
6175 | * data/bison.c++: Fix m4 quoting in comments. | |
6176 | ||
6177 | 2002-02-06 Robert Anisko <robert@lrde.epita.fr> | |
6178 | ||
6179 | * data/bison.c++: Adjust the parser code. Fix some muscles that were | |
6180 | not expanded by m4. | |
6181 | ||
6182 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
6183 | ||
6184 | * data/bison.c++: Adjust to the M4 back end. | |
6185 | More is certainly needed. | |
6186 | ||
6187 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
6188 | ||
6189 | Give a try to M4 as a back end. | |
6190 | ||
6191 | * lib/readpipe.c: New, from wdiff. | |
6192 | * src/Makefile.am (DEFS): Define PKGDATADIR, not BISON_SIMPLE and | |
6193 | BISON_HAIRY. | |
6194 | * src/system.h (BISON_HAIRY, BISON_SIMPLE): Remove the DOS and VMS | |
6195 | specific values. Now it is m4 that performs the lookup. | |
6196 | * src/parse-skel.y: Remove. | |
6197 | * src/muscle_tab.c, src/muscle_tab.h (muscles_m4_output): New. | |
6198 | * src/output.c (actions_output, guards_output) | |
6199 | (token_definitions_output): No longer keeps track of the output | |
6200 | line number, hence remove the second argument. | |
6201 | (guards_output): Check against the guard member of a rule, not the | |
6202 | action member. | |
6203 | Adjust callers. | |
6204 | (output_skeleton): Don't look for the skeleton location, let m4 do | |
6205 | that. | |
6206 | Create `/tmp/muscles.m4'. This is temporary, a proper temporary | |
6207 | file will be used. | |
6208 | Invoke `m4' on m4sugar.m4, muscles.m4, and the skeleton. | |
6209 | (prepare): Given that for the time being changesyntax is not | |
6210 | usable in M4, rename the muscles using `-' to `_'. | |
6211 | Define `defines_flag', `output_parser_name' and `output_header_name'. | |
6212 | * src/output.h (actions_output, guards_output) | |
6213 | (token_definitions_output): Adjust prototypes. | |
6214 | * src/scan-skel.l: Instead of scanning the skeletons, it now | |
6215 | processes the output of m4: `__oline__' and `#output'. | |
6216 | * data/bison.simple: Adjust to be used by M4(sugar). | |
6217 | * tests/Makefile.am: Use check_SCRIPTS to make sure `bison' is up | |
6218 | to date. | |
6219 | * tests/bison.in: Use the secrete envvar `BISON_PKGDATADIR' | |
6220 | instead of the dead `BISON_SIMPLE' and `BISON_HAIRY'. | |
6221 | * data/m4sugar/m4sugar.m4, data/m4sugar/version.m4: New, | |
6222 | shamelessly stolen from CVS Autoconf. | |
6223 | ||
6224 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
6225 | ||
6226 | * lib/hash.c, lib/hash.h: Replace with Fileutils 4.1's version. | |
6227 | * configure.in: Check for the declarations of free and malloc. | |
6228 | * src/muscle_tab.c: Adjust. | |
6229 | ||
6230 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
6231 | ||
6232 | * src/muscle_tab.c (muscle_init): Don't default to NULL muscle | |
6233 | which have no values. | |
6234 | ||
6235 | 2002-02-05 Akim Demaille <akim@epita.fr> | |
6236 | ||
6237 | * src/bison.simple, src/bison.hairy, src/bison.c++: Move to... | |
6238 | * data/: here. | |
6239 | ||
6240 | 2002-01-29 Paul Eggert <eggert@twinsun.com> | |
6241 | ||
6242 | * src/bison.simple (YYSIZE_T): Do not define merely because | |
6243 | YYSTACK_USE_ALLOCA is nonzero or alloca or _ALLOCA_H are defined. | |
6244 | On some platforms, <alloca.h> does not declare YYSTD (size_t). | |
6245 | ||
6246 | 2002-01-27 Akim Demaille <akim@epita.fr> | |
6247 | ||
6248 | Fix `%nonassoc and eof'. | |
6249 | ||
6250 | * src/state.c (errs_dup): Aaaah! The failure was due to bytes | |
6251 | which were not properly copied! Replace | |
6252 | memcpy (res->errs, src->errs, src->nerrs); | |
6253 | with | |
6254 | memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0])); | |
6255 | !!! | |
6256 | * tests/regression.at (%nonassoc and eof): Adjust to newest | |
6257 | Autotest: `.' is not in the PATH. | |
6258 | ||
6259 | 2002-01-27 Akim Demaille <akim@epita.fr> | |
6260 | ||
6261 | * tests/sets.at (AT_EXTRACT_SETS): New. | |
6262 | (Nullable): Use it. | |
6263 | (Firsts): New. | |
6264 | ||
6265 | 2002-01-26 Akim Demaille <akim@epita.fr> | |
6266 | ||
6267 | * tests/actions.at, tests/calc.at, tests/headers.at, | |
6268 | * tests/torture.at: Adjust to the newest Autotest which no longer | |
6269 | forces `.' in the PATH. | |
6270 | ||
6271 | 2002-01-25 Akim Demaille <akim@epita.fr> | |
6272 | ||
6273 | * tests/regression.at (%nonassoc and eof): New. | |
6274 | Suggested by Robert Anisko. | |
6275 | ||
6276 | 2002-01-24 Akim Demaille <akim@epita.fr> | |
6277 | ||
6278 | Bison dumps core when trying to complain about broken input files. | |
6279 | Reported by Cris van Pelt. | |
6280 | ||
6281 | * src/lex.c (parse_percent_token): Be sure to set token_buffer. | |
6282 | * tests/regression.at (Invalid input: 1, Invalid input: 2): Merge | |
6283 | into... | |
6284 | (Invalid inputs): Strengthen: exercise parse_percent_token. | |
6285 | ||
6286 | 2002-01-24 Robert Anisko <robert.anisko@epita.fr> | |
6287 | ||
6288 | * src/Makefile.am: Add bison.c++. | |
6289 | * src/bison.c++: New skeleton. | |
6290 | ||
6291 | 2002-01-21 Paolo Bonzini <bonzini@gnu.org> | |
6292 | ||
6293 | * po/it.po: New. | |
6294 | ||
6295 | 2002-01-21 Kees Zeelenberg <kzlg@users.sourceforge.net> | |
6296 | ||
6297 | * src/files.c (skeleton_find) [MSDOS]: Fix cp definition. | |
6298 | ||
6299 | 2002-01-20 Marc Autret <marc@gnu.org> | |
6300 | ||
6301 | * src/files.c (compute_output_file_names): Fix | |
6302 | ||
6303 | 2002-01-20 Marc Autret <marc@gnu.org> | |
6304 | ||
6305 | * tests/output.at: New test. | |
6306 | * src/files.c (compute_base_names): Don't map extensions when | |
6307 | the YACC flag is set, use defaults. | |
6308 | Reported by Evgeny Stambulchik. | |
6309 | ||
6310 | 2002-01-20 Marc Autret <marc@gnu.org> | |
6311 | ||
6312 | * src/system.h: Need to define __attribute__ away for non-GCC | |
6313 | compilers as well (i.e. the vendor C compiler). | |
6314 | Suggested by Albert Chin-A-Young. | |
6315 | ||
6316 | 2002-01-11 Tim Van Holder <tim.van.holder@pandora.be> | |
6317 | ||
6318 | * lib/hash.h, lib/hash.c: Renamed __P to PARAMS and used the | |
6319 | canonical definition. | |
6320 | * src/system.h: Use the canonical definition for PARAMS (avoids | |
6321 | a conflict with the macro from lib/hash.h). | |
6322 | ||
6323 | 2002-01-11 Akim Demaille <akim@epita.fr> | |
6324 | ||
6325 | * configure.in: Use AC_FUNC_STRNLEN. | |
6326 | Fixes the failures observed on AIX 4.3 by H.Merijn Brand. | |
6327 | ||
6328 | 2002-01-09 Akim Demaille <akim@epita.fr> | |
6329 | ||
6330 | * src/files.c, src/files.h (output_infix): New. | |
6331 | (tab_extension): Remove. | |
6332 | (compute_base_names): Compute the former, drop the latter. | |
6333 | * src/output.c (prepare): Insert the muscles `output-infix', and | |
6334 | `output-suffix'. | |
6335 | * src/parse-skel.y (string, string.1): New. | |
6336 | (section.header): Use it. | |
6337 | (section.yacc): Remove. | |
6338 | (prefix): Remove too. | |
6339 | * src/scan-skel.l: Adjust. | |
6340 | * src/bison.simple, src/bison.hairy: Adjust. | |
6341 | ||
6342 | 2002-01-09 Akim Demaille <akim@epita.fr> | |
6343 | ||
6344 | * configure.in (WERROR_CFLAGS): Compute it. | |
6345 | * src/Makefile.am (CFLAGS): Pass it. | |
6346 | * tests/atlocal.in (CFLAGS): Idem. | |
6347 | * src/files.c: Fix a few warnings. | |
6348 | (get_extension_index): Remove, unused. | |
6349 | ||
6350 | 2002-01-08 Akim Demaille <akim@epita.fr> | |
6351 | ||
6352 | * src/getargs.c (AS_FILE_NAME): New. | |
6353 | (getargs): Use it to convert DOSish file names. | |
6354 | * src/files.c (base_name): Rename as full_base_name to avoid | |
6355 | clashes with `base_name ()'. | |
6356 | (filename_split): New. | |
6357 | (compute_base_names): N-th rewrite, using filename_split. | |
6358 | ||
6359 | 2002-01-08 Akim Demaille <akim@epita.fr> | |
6360 | ||
6361 | * lib/basename.c, lib/dirname.h, lib/dirname.c, lib/memrchr.c: | |
6362 | New, stolen from the Fileutils 4.1. | |
6363 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
6364 | * configure.in: Check for the presence of memrchr, and of its | |
6365 | prototype. | |
6366 | ||
6367 | 2002-01-07 Tim Van Holder <tim.van.holder@pandora.be> | |
6368 | ||
6369 | * lib/hash.h (__P): Added definition for this macro. | |
6370 | * src/Makefile.am: Add parse-skel.c and scan-skel.c to | |
6371 | BUILT_SOURCES, to ensure they are generated first. | |
6372 | * src/parse-skel.y: Use YYERROR_VERBOSE instead of | |
6373 | %error-verbose to allow bootstrapping with bison 1.30x. | |
6374 | ||
6375 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
6376 | ||
6377 | * src/reader.c (parse_braces): Don't fetch the next char, the | |
6378 | convention is to fetch on entry. | |
6379 | * tests/torture.at (GNU Cim Grammar): Reintroduce their weird | |
6380 | 'switch' without a following semicolon. | |
6381 | * tests/regression.at (braces parsing): New. | |
6382 | ||
6383 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
6384 | ||
6385 | Bison is dead wrong in its RR conflict reports. | |
6386 | ||
6387 | * tests/torture.at (GNU Cim Grammar): New. | |
6388 | * src/conflicts.c (count_rr_conflicts): Fix. | |
6389 | ||
6390 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
6391 | ||
6392 | Creating package.m4 from configure.ac causes too many problems. | |
6393 | ||
6394 | * tests/Makefile.am (package.m4): Create it by hand, | |
6395 | AC_CONFIG_TESTDIR no longer does in the most recent CVS Autoconf. | |
6396 | ||
6397 | 2002-01-06 Akim Demaille <akim@epita.fr> | |
6398 | ||
6399 | * src/Makefile.am (bison_SOURCES): Add parse-skel.h and | |
6400 | skeleton.h. | |
6401 | ||
6402 | 2002-01-04 Paul Eggert <eggert@twinsun.com> | |
6403 | ||
6404 | * doc/bison.texinfo (Debugging): | |
6405 | Remove YYSTDERR; it's no longer defined or used. | |
6406 | Also, s/cstdio.h/cstdio/. | |
6407 | ||
6408 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
6409 | ||
6410 | * tests/bison.in, tests/atlocal.in: Adjust to CVS Autoconf. | |
6411 | ||
6412 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
6413 | ||
6414 | * src/parse-skel.y (process_skeleton): Don't bind the parser's | |
6415 | tracing code to --trace, wait for a better --trace option, with | |
6416 | args. | |
6417 | ||
6418 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
6419 | ||
6420 | * src/bison.simple (YYSTDERR): Remove, replace `stderr'. | |
6421 | The ISO C++ standard is extremely clear about it: stderr is | |
6422 | considered a macro, not a regular symbol (see table 94 `Header | |
6423 | <cstdio> synopsis', [lib.c.files] 27.8.2 C Library files). | |
6424 | Therefore std:: does not apply to it. It still does with fprintf. | |
6425 | Also, s/cstdio.h/cstdio/. | |
6426 | ||
6427 | 2002-01-03 Akim Demaille <akim@epita.fr> | |
6428 | ||
6429 | * lib/quotearg.c: Use `#include "..."' instead of `#include <...>' | |
6430 | for non system headers. | |
6431 | ||
6432 | 2002-01-02 Akim Demaille <akim@epita.fr> | |
6433 | ||
6434 | Equip the skeleton chain with location tracking, runtime trace, | |
6435 | pure parser and scanner. | |
6436 | ||
6437 | * src/parse-skel.y: Request a pure parser, locations, and prefix | |
6438 | renaming. | |
6439 | (%union): Having several members with the same type does not help | |
6440 | type mismatches, simplify. | |
6441 | (YYPRINT, yyprint): New. | |
6442 | (yyerror): ``Rename'' (there is a #define yyerror skel_error) as... | |
6443 | (skel_error): this. | |
6444 | Handle locations. | |
6445 | * src/scan-skel.l: Adjust to these changes. | |
6446 | * src/skeleton.h (LOCATION_RESET, LOCATION_LINES, LOCATION_STEP) | |
6447 | (LOCATION_PRINT, skel_control_t): New. | |
6448 | ||
6449 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
6450 | ||
6451 | * src/parse-skel.y: Get rid of the shift/reduce conflict: | |
6452 | replace `gb' with BLANKS. | |
6453 | * src/scan-skel.l: Adjust. | |
6454 | ||
6455 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
6456 | ||
6457 | * src/system.h: We don't need nor want bcopy. | |
6458 | Throw away MS-DOS crap: we don't need getpid. | |
6459 | * configure.in: We don't need strndup. It was even causing | |
6460 | problems: because Flex includes the headers *before* us, | |
6461 | _GNU_SOURCE is not defined by config.h, and therefore strndup was | |
6462 | not visible. | |
6463 | * lib/xstrndup.c: New. | |
6464 | * src/scan-skel.l: Use it. | |
6465 | Be sure to initialize yylval.muscle member when scanning a MUSCLE. | |
6466 | * src/parse-skel.y: Use %directives instead of #defines. | |
6467 | ||
6468 | 2001-12-30 Akim Demaille <akim@epita.fr> | |
6469 | ||
6470 | * src/skeleton.h: New. | |
6471 | * src/output.c (output_parser, output_master_parser): Remove, dead | |
6472 | code. | |
6473 | * src/output.h (get_lines_number, actions_output, guards_output) | |
6474 | (token_definitions_output): Prototype them. | |
6475 | * src/parse-skel.y: Add the license notice. | |
6476 | Include output.h and skeleton.h. | |
6477 | (process_skeleton): Returns void, and takes a single parameter. | |
6478 | * src/scan-skel.l: Add the license notice. | |
6479 | Include skeleton.h. | |
6480 | Don't use %option yylineno: it seems that then Flex imagines | |
6481 | REJECT has been used, and therefore it won't reallocate its | |
6482 | buffers (which makes no other sense to me than a bug). It results | |
6483 | in warnings for `unused: yy_flex_realloc'. | |
6484 | ||
6485 | 2001-12-30 Robert Anisko <robert.anisko@epita.fr> | |
6486 | ||
6487 | * src/muscle_tab.h (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
6488 | (MUSCLE_INSERT_PREFIX): ...to there. | |
6489 | * src/output.c (MUSCLE_INSERT_INT, MUSCLE_INSERT_STRING) | |
6490 | (MUSCLE_INSERT_PREFIX): Move from here... | |
6491 | ||
6492 | * src/bison.hairy: Add a section directive. Put braces around muscle | |
6493 | names. This parser skeleton is still broken, but Bison should not | |
6494 | choke on a bad muscle 'syntax'. | |
6495 | * src/bison.simple: Add a section directive. Put braces around muscle | |
6496 | names. | |
6497 | ||
6498 | * src/files.h (strsuffix, stringappend): Add declarations. | |
6499 | (tab_extension): Add declaration. | |
6500 | (short_base_name): Add declaration. | |
6501 | ||
6502 | * src/files.c (strsuffix, stringappend): No longer static. These | |
6503 | functions are used in the skeleton parser. | |
6504 | (tab_extension): New. | |
6505 | (compute_base_names): Use the computations done in this function | |
6506 | to guess if the generated parsers should have '.tab' in their | |
6507 | names. | |
6508 | (short_base_name): No longer static. | |
6509 | ||
6510 | * src/output.c (output_skeleton): New. | |
6511 | (output): Disable call to output_master_parser, and give a try to | |
6512 | a new skeleton handling system. | |
6513 | (guards_output, actions_output): No longer static. | |
6514 | (token_definitions_output, get_lines_number): No longer static. | |
6515 | ||
6516 | * configure.in: Use AM_PROG_LEX and AC_PROG_YACC. | |
6517 | ||
6518 | * src/Makefile.am (bison_SOURCES): Add scan-skel.l and | |
6519 | parse-skel.y. | |
6520 | ||
6521 | * src/parse-skel.y: New file. | |
6522 | * src/scan-skel.l: New file. | |
6523 | ||
6524 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6525 | ||
6526 | %name-prefix is broken. | |
6527 | ||
6528 | * src/files.c (spec_name_prefix): Initialize to NULL, not to "yy". | |
6529 | Adjust all dependencies. | |
6530 | * tests/headers.at (export YYLTYPE): Strengthen this test: use | |
6531 | %name-prefix. | |
6532 | ||
6533 | Renaming yylval but not yylloc is not consistent. Now we do. | |
6534 | ||
6535 | * src/bison.simple: Prefix yylloc if used. | |
6536 | * doc/bison.texinfo (Decl Summary): Document that. | |
6537 | ||
6538 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6539 | ||
6540 | * doc/bison.texinfo: Promote `%long-directive' over | |
6541 | `%long_directive'. | |
6542 | Remove all references to fixed-output-files, yacc is enough. | |
6543 | ||
6544 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6545 | ||
6546 | * src/bison.simple: Define YYDEBUG and YYERROR_VERBOSE *after* the | |
6547 | user prologue. These are defaults. | |
6548 | * tests/actions.at (Mid-rule actions): Make sure the user can | |
6549 | define YYDEBUG and YYERROR_VERBOSE. | |
6550 | ||
6551 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6552 | ||
6553 | * src/output.c (header_output): Don't forget to export YYLTYPE and | |
6554 | yylloc. | |
6555 | * tests/headers.at (export YYLTYPE): New, make sure it does. | |
6556 | * tests/regression.at (%union and --defines, Invalid CPP headers): | |
6557 | Move to... | |
6558 | * tests/headers.at: here. | |
6559 | ||
6560 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6561 | ||
6562 | * src/gram.h (rule_s): Member `assoc' is of type `associativity'. | |
6563 | ||
6564 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6565 | ||
6566 | * tests/actions.at (Mid-rule actions): Output on a single line | |
6567 | instead of several. | |
6568 | ||
6569 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6570 | ||
6571 | * doc/bison.texinfo: Formatting changes. | |
6572 | ||
6573 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6574 | ||
6575 | Don't store the token defs in a muscle, just be ready to output it | |
6576 | on command. Now possible via `symbols'. Fixes a memory leak. | |
6577 | ||
6578 | * src/output.c (token_definitions_output): New. | |
6579 | (output_parser, header_output): Use it. | |
6580 | * src/reader.c (symbols_save): Remove. | |
6581 | ||
6582 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6583 | ||
6584 | * src/bison.simple: Do not provide a default for YYSTYPE and | |
6585 | YYLTYPE before the user's prologue. Otherwise it's hardly... a | |
6586 | default. | |
6587 | ||
6588 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6589 | ||
6590 | Mid-rule actions are simply... ignored! | |
6591 | ||
6592 | * src/reader.c (readgram): Be sure to attach mid-rule actions to | |
6593 | the empty-rule associated to the dummy symbol, not to the host | |
6594 | rule. | |
6595 | * tests/actions.at (Mid-rule actions): New. | |
6596 | ||
6597 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6598 | ||
6599 | Memory leak. | |
6600 | ||
6601 | * src/reader.c (reader): Free grammar. | |
6602 | ||
6603 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6604 | ||
6605 | Memory leak. | |
6606 | ||
6607 | * src/LR0.c (new_itemsets): Don't allocate `shift_symbol' here, | |
6608 | since it allocates it for each state, although only one is needed. | |
6609 | (allocate_storage): Do it here. | |
6610 | ||
6611 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6612 | ||
6613 | * src/options.h, src/options.c (create_long_option_table): Rename | |
6614 | as... | |
6615 | (long_option_table_new): this, with a clearer prototype. | |
6616 | (percent_table): Remove, unused, | |
6617 | * src/getargs.c (getargs): Adjust. | |
6618 | ||
6619 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6620 | ||
6621 | * src/LR0.c, src/conflicts.c, src/lalr.c, src/lalr.h, src/output.c | |
6622 | * src/print.c, src/print_graph.c, src/state.h: Rename state_table | |
6623 | as states. | |
6624 | ||
6625 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6626 | ||
6627 | * src/lalr.c (build_relations): Rename `states' as `states1'. | |
6628 | Sorry, I don't understand exactly what it is, no better name... | |
6629 | ||
6630 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6631 | ||
6632 | * src/closure.c, src/conflicts.c, src/derives.c, src/gram.c | |
6633 | * src/gram.h, src/lalr.c, src/nullable.c, src/output.c, src/print.c | |
6634 | * src/print_graph.c, src/reader.c, src/reduce.c: Rename rule_table | |
6635 | as rules. | |
6636 | ||
6637 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6638 | ||
6639 | * src/gram.c (rprec, rprecsym, rassoc): Remove, unused since long | |
6640 | ago. | |
6641 | ||
6642 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6643 | ||
6644 | * src/reader.c, src/reader.h (user_toknums): Remove. | |
6645 | Adjust all users to use symbols[i]->user_token_number. | |
6646 | ||
6647 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6648 | ||
6649 | * src/gram.c, src/gram.h (sprec, sassoc): Remove. | |
6650 | Adjust all users to use symbols[i]->prec or ->assoc. | |
6651 | ||
6652 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6653 | ||
6654 | * src/reader.c, src/reader.h (tags): Remove. | |
6655 | Adjust all users to use symbols[i]->tag. | |
6656 | ||
6657 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6658 | ||
6659 | * src/gram.h, src/gram.c (symbols): New, similar to state_table | |
6660 | and rule_table. | |
6661 | * src/reader.c (packsymbols): Fill this table. | |
6662 | Drop sprec. | |
6663 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
6664 | * src/reduce.c (reduce_grammar): Adjust: just sort symbols, a | |
6665 | single table. | |
6666 | Use symbols[i]->tag instead of tags[i]. | |
6667 | ||
6668 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6669 | ||
6670 | * tests/calc.at (_AT_DATA_CALC_Y): Also use %union. | |
6671 | In addition, put a comment in there, to replace... | |
6672 | * tests/regression.at (%union and C comments): Remove. | |
6673 | ||
6674 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6675 | ||
6676 | * tests/regression.at (Web2c Actions): Blindly move the actual | |
6677 | output as expected output. The contents *seem* right to me, but I | |
6678 | can't pretend reading perfectly parser tables... Nonetheless, all | |
6679 | the other tests pass correctly, the table look OK, even though the | |
6680 | presence of `$axiom' is to be noted: AFAICS it is useless (but | |
6681 | harmless). | |
6682 | ||
6683 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6684 | ||
6685 | * src/reader.c (readgram): Don't add the rule 0 if there were no | |
6686 | rules read. In other words, add it _after_ having performed | |
6687 | grammar sanity checks. | |
6688 | Fixes the `tests/regression.at (Invalid input: 1)' Failure. | |
6689 | ||
6690 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6691 | ||
6692 | * tests/regression.at (Web2c Report): Catch up: the rule 0 is now | |
6693 | visible, and some states have now a different number. | |
6694 | ||
6695 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6696 | ||
6697 | * src/reader.c (readgram): Bind the initial rule's lineno to that | |
6698 | of the first rule. | |
6699 | * tests/regression.at (Rule Line Numbers, Unresolved SR Conflicts): | |
6700 | (Solved SR Conflicts): Adjust rule 0's line number. | |
6701 | ||
6702 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6703 | ||
6704 | Fix the `GAWK Grammar' failure. | |
6705 | ||
6706 | * src/LR0.c (final_state): Initialize to -1 so that we do compute | |
6707 | the reductions of the first state which was mistakenly confused | |
6708 | with the final state because precisely final_state was initialized | |
6709 | to 0. | |
6710 | * tests/sets.at (Nullable): Adjust: state 0 does have lookaheads, | |
6711 | now noticed by Bison. | |
6712 | * tests/regression.at (Rule Line Numbers): Adjust: state 0 does | |
6713 | have a reduction on $default. | |
6714 | ||
6715 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6716 | ||
6717 | * src/gram.c (ritem_print): Be sure to subtract 1 when displaying | |
6718 | rule line numbers. | |
6719 | * src/closure.c (print_closure): Likewise. | |
6720 | * src/derives.c (print_derives): Likewise. | |
6721 | * tests/sets.at (Nullable): Adjust: the rule numbers are correct | |
6722 | now. | |
6723 | ||
6724 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6725 | ||
6726 | * src/lalr.c (lookaheads_print): New. | |
6727 | (lalr): Call it when --trace-flag. | |
6728 | * tests/sets.at (Nullable): Adjust: when tracing, the lookaheads | |
6729 | are dumped. | |
6730 | ||
6731 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6732 | ||
6733 | * src/derives.c (print_derives): Be sure to use `>= 0', not `> 0', | |
6734 | when walking through ritem, even via rule->rhs. | |
6735 | * src/reduce.c (dump_grammar, useful_production, reduce_output) | |
6736 | (useful_production, useless_nonterminals): Likewise. | |
6737 | (reduce_grammar_tables): Likewise, plus update nritems. | |
6738 | * src/nullable.c (set_nullable): Likewise. | |
6739 | * src/lalr.c (build_relations): Likewise. | |
6740 | * tests/sets.at (Nullable): Adjust. | |
6741 | Fortunately, now, the $axiom is no longer nullable. | |
6742 | ||
6743 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6744 | ||
6745 | * src/LR0.c (generate_states): Use nritems, not nitems, nor using | |
6746 | the 0-sentinel. | |
6747 | * src/gram.c (ritem_longest_rhs): Likewise. | |
6748 | * src/reduce.c (nonterminals_reduce): Likewise. | |
6749 | * src/print_graph.c (print_graph): Likewise. | |
6750 | * src/output.c (output_rule_data): Likewise. | |
6751 | * src/nullable.c (set_nullable): Likewise. | |
6752 | ||
6753 | 2001-12-29 Akim Demaille <akim@epita.fr> | |
6754 | ||
6755 | * src/output.c: Comment changes. | |
6756 | ||
6757 | 2001-12-27 Paul Eggert <eggert@twinsun.com> | |
6758 | ||
6759 | * src/bison.simple (YYSTACK_ALLOC, YYSIZE_T): Remove special | |
6760 | cases for non-GNU systems like AIX, HP-UX, SGI, Sun, and | |
6761 | Sparc, as they were causing more porting problems than the | |
6762 | (minor) performance improvement was worth. | |
6763 | ||
6764 | Also, catch up with 1.31's YYSTD. | |
6765 | ||
6766 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6767 | ||
6768 | * src/output.c (output_gram): Rely on nritems, not the | |
6769 | 0-sentinel. See below. | |
6770 | Use -1 as separator, not 0. | |
6771 | * src/bison.simple (yyparse): Subtract 1 to the rule numbers. | |
6772 | Rely on -1 as separator in yyrhs, instead of 0. | |
6773 | * tests/calc.at (AT_CHECK_CALC): Now, the parsers no longer issue | |
6774 | twice `Now at end of input', therefore there are two lines less to | |
6775 | expect. | |
6776 | ||
6777 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6778 | ||
6779 | * tests/regression.at (Unresolved SR Conflicts): | |
6780 | (Solved SR Conflicts, Rule Line Numbers): Adjust to the changes | |
6781 | below. | |
6782 | ||
6783 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6784 | ||
6785 | * src/LR0.c (new_state): Recognize the final state by the fact it | |
6786 | is reached by eoftoken. | |
6787 | (insert_start_shifting_state, insert_eof_shifting_state) | |
6788 | (insert_accepting_state, augment_automaton): Remove, since now | |
6789 | these states are automatically computed from the initial state. | |
6790 | (generate_states): Adjust. | |
6791 | * src/print.c: When reporting a rule number to the user, substract | |
6792 | 1, so that the axiom rule is rule 0, and the first user rule is 1. | |
6793 | * src/reduce.c: Likewise. | |
6794 | * src/print_graph.c (print_core): For the time being, just as for | |
6795 | the report, depend upon --trace-flags to dump the full set of | |
6796 | items. | |
6797 | * src/reader.c (readgram): Once the grammar read, insert the rule | |
6798 | 0: `$axiom: START-SYMBOL $'. | |
6799 | * tests/set.at: Adjust: rule 0 is now displayed, and since the | |
6800 | number of the states has changed (the final state is no longer | |
6801 | necessarily the last), catch up. | |
6802 | ||
6803 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6804 | ||
6805 | Try to make the use of the eoftoken valid. Given that its value | |
6806 | is 0 which was also used as a sentinel in ritem, (i) make sure >= 0 | |
6807 | is used instead of > 0 where appropriate, (ii), depend upon nritems | |
6808 | instead of the 0-sentinel. | |
6809 | ||
6810 | * src/gram.h, src/gram.c (nritems): New. | |
6811 | Expected to be duplication of nitems, but for the time being... | |
6812 | * src/reader.c (packgram): Assert nritems and nitems are equal. | |
6813 | * src/LR0.c (allocate_itemsets, new_itemsets): Adjust. | |
6814 | * src/closure.c (print_closure, print_fderives): Likewise. | |
6815 | * src/gram.c (ritem_print): Likewise. | |
6816 | * src/print.c (print_core, print_grammar): Likewise. | |
6817 | * src/print_graph.c: Likewise. | |
6818 | ||
6819 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6820 | ||
6821 | * src/main.c (main): If there are complains after grammar | |
6822 | reductions, then output the report anyway if requested, then die. | |
6823 | * src/symtab.c (bucket_new): Initialize `value' to -1, not 0. | |
6824 | * src/reader.c (eoftoken): New. | |
6825 | (parse_token_decl): If the token being defined has value `0', it | |
6826 | is the eoftoken. | |
6827 | (packsymbols): No longer hack `tags' to insert `$' by hand. | |
6828 | Be sure to preserve the value of the eoftoken. | |
6829 | (reader): Make sure eoftoken is defined. | |
6830 | Initialize nsyms to 0: now eoftoken is created just like the others. | |
6831 | * src/print.c (print_grammar): Don't special case the eof token. | |
6832 | * src/regression.at: Adjust: `$' has value 0, not -1, which was a | |
6833 | lie anyway, albeit pleasant. | |
6834 | * tests/calc.at: Exercise error messages with eoftoken. | |
6835 | Change the grammar so that empty input is invalid. | |
6836 | Adjust expectations. | |
6837 | When yyungeting, be sure to use a valid yylloc: use last_yylloc. | |
6838 | ||
6839 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6840 | ||
6841 | * configure.in: Check the protos of strchr ans strspn. | |
6842 | Replace strchr if needed. | |
6843 | * src/system.h: Provide the protos of strchr, strspn and memchr if | |
6844 | missing. | |
6845 | * lib/strchr.c: New. | |
6846 | * src/reader.c (symbols_save): Use strchr. | |
6847 | ||
6848 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6849 | ||
6850 | * src/print.c, src/print_graph.c (escape): New. | |
6851 | Use it to quote the TAGS outputs. | |
6852 | * src/print_graph.c (print_state): Now errors are in red, and | |
6853 | reductions in green. | |
6854 | Prefer high to wide: output the state number on a line of its own. | |
6855 | ||
6856 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6857 | ||
6858 | * src/state.h, src/state.c (reductions_new): New. | |
6859 | * src/LR0.c (set_state_table): Let all the states have a | |
6860 | `reductions', even if reduced to 0. | |
6861 | (save_reductions): Adjust. | |
6862 | * src/lalr.c (initialize_LA, initialize_lookaheads): Adjust. | |
6863 | * src/print.c (print_reductions, print_actions): Adjust. | |
6864 | * src/output.c (action_row): Adjust. | |
6865 | ||
6866 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6867 | ||
6868 | * src/state.h, src/state.c (errs_new, errs_dup): New. | |
6869 | * src/LR0.c (set_state_table): Let all the states have an errs, | |
6870 | even if reduced to 0. | |
6871 | * src/print.c (print_errs, print_reductions): Adjust. | |
6872 | * src/output.c (output_actions, action_row): Adjust. | |
6873 | * src/conflicts.c (resolve_sr_conflict): Adjust. | |
6874 | ||
6875 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6876 | ||
6877 | * src/lalr.c (set_goto_map, initialize_F): Use SHIFT_SYMBOL. | |
6878 | ||
6879 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6880 | ||
6881 | * src/conflicts.c, src/conflicts.h (print_reductions): Move to... | |
6882 | * src/print.c: here. | |
6883 | (lookaheadset, shiftset): New, used as additional storage by | |
6884 | print_reductions. | |
6885 | (print_results): Adjust. | |
6886 | (print_shifts, print_gotos, print_errs): New, extracted from... | |
6887 | (print_actions): here. | |
6888 | * src/print_graph.c (print_actions): Remove dead code. | |
6889 | ||
6890 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6891 | ||
6892 | * src/reader.c (copy_dollar, copy_at): Better checking of `n' in | |
6893 | `$n' and `@n'. | |
6894 | ||
6895 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6896 | ||
6897 | * src/lalr.c (add_lookback_edge): Use state_t instead of ints. | |
6898 | (build_relations): Adjust. | |
6899 | ||
6900 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6901 | ||
6902 | * src/lalr.c (set_goto_map): Remove a wrong but benign loop | |
6903 | duplication. | |
6904 | ||
6905 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6906 | ||
6907 | * src/reader.c (packgram): Catch nitems overflows. | |
6908 | ||
6909 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6910 | ||
6911 | * src/files.c, src/files.h (guard_obstack): Remove. | |
6912 | * src/output.c (output): Adjust. | |
6913 | * src/reader.c (parse_braces): New, factoring... | |
6914 | (copy_action, copy_guard): these two which are renamed as... | |
6915 | (parse_action, parse_guard): these. | |
6916 | As a voluntary consequence, using braces around guards is now | |
6917 | mandatory. | |
6918 | ||
6919 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6920 | ||
6921 | * src/gram.h (rule_t): `guard' and `guard_line' are new members. | |
6922 | * src/reader.c (symbol_list): `guard' and `guard_line' are new | |
6923 | members. | |
6924 | (symbol_list_new): Adjust. | |
6925 | (copy_action): action_line is the first line, not the last. | |
6926 | (copy_guard): Just as for actions, store the `action' only, not | |
6927 | the switch/case/break flesh. | |
6928 | Don't parse the user action that might follow the guard, let... | |
6929 | (readgram): do it, i.e., now, there can be an action after a | |
6930 | guard. | |
6931 | In other words the guard is just explicitly optional. | |
6932 | (packgram): Adjust. | |
6933 | * src/output.c (guards_output): New. | |
6934 | (output_parser): Call it when needed. | |
6935 | (output): Also free the guard and attrs obstacks. | |
6936 | * src/files.c, src/files.h (obstack_save): Remove. | |
6937 | (output_files): Remove. | |
6938 | As a result, if one needs the former `.act' file, using an | |
6939 | appropriate skeleton which requires actions and guards is now | |
6940 | required. | |
6941 | * src/main.c (main): Adjust. | |
6942 | * tests/semantic.at: New. | |
6943 | * tests/regression.at: Use `input.y' as input file name. | |
6944 | Avoid 8+3 problems by requiring input.c when the test needs the | |
6945 | parser. | |
6946 | ||
6947 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6948 | ||
6949 | * src/reader.c (symbol_list_new): Be sure to initialize all the | |
6950 | fields. | |
6951 | ||
6952 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6953 | ||
6954 | All the hacks using a final pseudo state are now useless. | |
6955 | ||
6956 | * src/LR0.c (set_state_table): state_table holds exactly nstates. | |
6957 | * src/lalr.c (nLA): New. | |
6958 | (initialize_LA, compute_lookaheads, initialize_lookaheads): Use it | |
6959 | instead of lookaheadsp from the pseudo state (nstate + 1). | |
6960 | ||
6961 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6962 | ||
6963 | * src/output.c (action_row, token_actions): Use a state_t instead | |
6964 | of a integer, and nlookaheads instead of the following state's | |
6965 | lookaheadsp. | |
6966 | ||
6967 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6968 | ||
6969 | * src/conflicts.c (log_resolution, flush_shift) | |
6970 | (resolve_sr_conflict, set_conflicts, solve_conflicts) | |
6971 | (count_sr_conflicts, count_rr_conflicts, conflicts_output) | |
6972 | (conflicts_print, print_reductions): Use a state_t instead of an | |
6973 | integer when referring to a state. | |
6974 | As much as possible, depend upon nlookaheads, instead of the | |
6975 | `lookaheadsp' member of the following state (since lookaheads of | |
6976 | successive states are successive, the difference between state n + 1 | |
6977 | and n served as the number of lookaheads for state n). | |
6978 | * src/lalr.c (add_lookback_edge): Likewise. | |
6979 | * src/print.c (print_core, print_actions, print_state) | |
6980 | (print_results): Likewise. | |
6981 | * src/print_graph.c (print_core, print_actions, print_state) | |
6982 | (print_graph): Likewise. | |
6983 | * src/conflicts.h: Adjust. | |
6984 | ||
6985 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6986 | ||
6987 | * src/bison.hairy: Formatting/comment changes. | |
6988 | ANSIfy. | |
6989 | Remove `register' indications. | |
6990 | Add plenty of `static'. | |
6991 | ||
6992 | 2001-12-27 Akim Demaille <akim@epita.fr> | |
6993 | ||
6994 | * src/output.c (prepare): Drop the muscle `ntbase' which | |
6995 | duplicates ntokens. | |
6996 | * src/bison.simple: Formatting/comment changes. | |
6997 | Use YYNTOKENS only, which is documented, but not YYNTBASE, which | |
6998 | is an undocumented synonym. | |
6999 | ||
7000 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
7001 | ||
7002 | * src/output.c (output_table_data): Change the prototype to use | |
7003 | `int' for array ranges: some invocations do pass an int, not a | |
7004 | short. | |
7005 | Reported by Wayne Green. | |
7006 | ||
7007 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
7008 | ||
7009 | Some actions of web2c.y are improperly triggered. | |
7010 | Reported by Mike Castle. | |
7011 | ||
7012 | * src/lalr.c (traverse): s/F (i)[k] = F (j)[k]/F (j)[k] = F (i)[k]/. | |
7013 | * tests/regression.at (Web2c): Rename as... | |
7014 | (Web2c Report): this. | |
7015 | (Web2c Actions): New. | |
7016 | ||
7017 | 2001-12-22 Akim Demaille <akim@epita.fr> | |
7018 | ||
7019 | Reductions in web2c.y are improperly reported. | |
7020 | Reported by Mike Castle. | |
7021 | ||
7022 | * src/conflicts.c (print_reductions): Fix. | |
7023 | * tests/regression.at (Web2c): New. | |
7024 | ||
7025 | 2001-12-18 Akim Demaille <akim@epita.fr> | |
7026 | ||
7027 | Some host fail on `assert (!"foo")', which expands to | |
7028 | ((!"foo") ? (void)0 : __assert("!"foo."", __FILE__, __LINE__)) | |
7029 | Reported by Nelson Beebee. | |
7030 | ||
7031 | * src/output.c, src/vcg.c: Replace `assert (!"it succeeded")' with | |
7032 | `#define it_succeeded 0' and `assert (it_succeeded)'. | |
7033 | ||
7034 | 2001-12-17 Marc Autret <autret_m@epita.fr> | |
7035 | ||
7036 | * src/bison.simple: Don't hard code the skeleton line and filename. | |
7037 | * src/output.c (output_parser): Rename 'line' as 'output_line'. | |
7038 | New line counter 'skeleton_line' (skeleton-line muscle). | |
7039 | ||
7040 | 2001-12-17 Paul Eggert <eggert@twinsun.com> | |
7041 | ||
7042 | * NEWS, doc/bison.texinfo, doc/bison.1, doc/bison.rnh: Document that | |
7043 | YYDEBUG must be defined to a nonzero value. | |
7044 | ||
7045 | * src/bison.simple (yytname): Do not assume that the user defines | |
7046 | YYDEBUG to a properly parenthesized expression. | |
7047 | ||
7048 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7049 | ||
7050 | * src/state.h (state_t): Rename lookaheads as lookaheadsp. | |
7051 | nlookaheads is a new member. | |
7052 | Adjust all users. | |
7053 | * src/lalr.h (nlookaheads): Remove this orphan declaration. | |
7054 | * src/lalr.c (initialize_lookaheads): Set nlookaheads for each | |
7055 | state. | |
7056 | ||
7057 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7058 | ||
7059 | * src/files.h, src/files.c (open_files, close_files): Remove. | |
7060 | * src/main.c (main): Don't open/close files, nor invoke lex_free, | |
7061 | let... | |
7062 | * src/reader.c (reader): Do it. | |
7063 | ||
7064 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7065 | ||
7066 | * src/conflicts.c (print_reductions): Formatting changes. | |
7067 | ||
7068 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7069 | ||
7070 | * src/conflicts.c (flush_shift): Also adjust lookaheadset. | |
7071 | (flush_reduce): New. | |
7072 | (resolve_sr_conflict): Adjust. | |
7073 | ||
7074 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7075 | ||
7076 | * src/output.c (output_obstack): Be static and rename as... | |
7077 | (format_obstack): this, to avoid any confusion with files.c's | |
7078 | output_obstack. | |
7079 | * src/reader.h (muscle_obstack): Move to... | |
7080 | * src/output.h: here, since it's defined in output.c. | |
7081 | ||
7082 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7083 | ||
7084 | * src/output.c (action_row, save_column, default_goto) | |
7085 | (sort_actions, matching_state, pack_vector): Better variable | |
7086 | locality. | |
7087 | ||
7088 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7089 | ||
7090 | * src/output.c: Various formatting changes. | |
7091 | ||
7092 | 2001-12-17 Akim Demaille <akim@epita.fr> | |
7093 | ||
7094 | * src/files.c (output_files): Free the output_obstack. | |
7095 | * src/main.c (main): Call print and print_graph conditionally. | |
7096 | * src/print.c (print): Work unconditionally. | |
7097 | * src/print_graph.c (print_graph): Work unconditionally. | |
7098 | * src/conflicts.c (log_resolution): Output only if verbose_flag. | |
7099 | ||
7100 | 2001-12-16 Marc Autret <autret_m@epita.fr> | |
7101 | ||
7102 | * src/output.c (actions_output): Fix. When we use %no-lines, | |
7103 | there is one less line per action. | |
7104 | ||
7105 | 2001-12-16 Marc Autret <autret_m@epita.fr> | |
7106 | ||
7107 | * src/bison.simple: Remove a useless #line directive. | |
7108 | s/#line %%line %%skeleton/#line %%line "%%parser-file-name"/'. | |
7109 | * src/output.c (get_lines_number): New. | |
7110 | (output_parser): Adjust, now takes care about the lines of a | |
7111 | output muscles. | |
7112 | Fix line numbering. | |
7113 | (actions_output): Computes the number of lines taken by actions. | |
7114 | (output_master_parser): Insert new skeleton which is the name of | |
7115 | the output parser file name. | |
7116 | ||
7117 | 2001-12-15 Marc Autret <autret_m@epita.fr> | |
7118 | ||
7119 | * src/bison.simple [YYERROR_VERBOSE]: Restore backward compatibility. | |
7120 | ||
7121 | 2001-12-15 Marc Autret <autret_m@epita.fr> | |
7122 | ||
7123 | * src/output.c (output_gram): Keep track of the hairy one. | |
7124 | ||
7125 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7126 | ||
7127 | Make `make distcheck' work. | |
7128 | ||
7129 | * lib/Makefile.am (INCLUDES): Add top_srcdir/intl, since hash uses | |
7130 | system.h which uses libgettext.h. | |
7131 | ||
7132 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7133 | ||
7134 | * src/nullable.c (set_nullable): Useless rules must be skipped, | |
7135 | otherwise, since we range over their symbols, we might look at a | |
7136 | nonterminal which no longer ``exists'', i.e., it is not counted in | |
7137 | `nvars', hence we overflow our arrays. | |
7138 | ||
7139 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7140 | ||
7141 | The header can also be produced directly, without any obstack! | |
7142 | Yahoo! | |
7143 | ||
7144 | * src/files.c, src/files.h (defines_obstack): Remove. | |
7145 | (compute_header_macro): Global. | |
7146 | (defines_obstack_save): Remove. | |
7147 | * src/reader.c (parse_union_decl): No longer output to | |
7148 | defines_obstack: its content can be found in the `stype' muscle | |
7149 | anyway. | |
7150 | (output_token_translations): Merge into... | |
7151 | (symbols_output): this. | |
7152 | Rename as... | |
7153 | (symbols_save): this. | |
7154 | (reader): Adjust. | |
7155 | * src/output.c (header_output): New. | |
7156 | (output): Call it. | |
7157 | ||
7158 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7159 | ||
7160 | * src/reader.c (parse_union_decl): Instead of handling two obstack | |
7161 | simultaneously, use one to define the `stype' muscle, and use the | |
7162 | value of the latter to fill defines_obstack. | |
7163 | (copy_comment): Remove. | |
7164 | (copy_comment2): Work for a single obstack. | |
7165 | Rename as... | |
7166 | (copy_comment): this. | |
7167 | ||
7168 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7169 | ||
7170 | * src/lex.c, src/lex.h (xgetc): No longer static. | |
7171 | * src/reader.c (parse_union_decl): Revamp. | |
7172 | ||
7173 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7174 | ||
7175 | Still making progress in separating Bison into (i) input, (ii) | |
7176 | process, (iii) output: now we can directly output the parser file | |
7177 | without using table_obstack at all. | |
7178 | ||
7179 | * src/files.c, src/files.h (table_obstack): Bye bye. | |
7180 | (parser_file_name): New. | |
7181 | * src/files.c (compute_output_file_names): Compute it. | |
7182 | * src/output.c (actions_output, output_parser) | |
7183 | (output_master_parser): To a file instead of an obstack. | |
7184 | ||
7185 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7186 | ||
7187 | Attach actions to rules, instead of pre-outputting them to | |
7188 | actions_obstack. | |
7189 | ||
7190 | * src/gram.h (rule_t): action and action_line are new members. | |
7191 | * src/reader.c (symbol_list): Likewise. | |
7192 | (copy_action): Save the actions within the rule. | |
7193 | (packgram): Save them in rule_table. | |
7194 | * src/output.c (actions_output): New. | |
7195 | (output_parser): Use it on `%%actions'. | |
7196 | (output_rule_data): Don't free rule_table. | |
7197 | (output): Do it. | |
7198 | (prepare): Don't save the `action' muscle. | |
7199 | * src/bison.simple: s/%%action/%%actions/. | |
7200 | ||
7201 | 2001-12-15 Akim Demaille <akim@epita.fr> | |
7202 | ||
7203 | * src/reader.c (copy_action): When --yacc, don't append a `;' | |
7204 | to the user action: let it fail if lacking. | |
7205 | Suggested by Arnold Robbins and Tom Tromey. | |
7206 | ||
7207 | 2001-12-14 Akim Demaille <akim@epita.fr> | |
7208 | ||
7209 | * src/lex.c (literalchar): Simply return the char you decoded, non | |
7210 | longer mess around with obstacks and int pointers. | |
7211 | Adjust all callers. | |
7212 | ||
7213 | 2001-12-14 Akim Demaille <akim@epita.fr> | |
7214 | ||
7215 | * src/lex.c (literalchar): Don't escape the special characters, | |
7216 | just decode them, and keep them as char (before, eol was output as | |
7217 | the 2 char string `\n' etc.). | |
7218 | * src/output.c (output_rule_data): Use quotearg to output the | |
7219 | token strings. | |
7220 | ||
7221 | 2001-12-13 Paul Eggert <eggert@twinsun.com> | |
7222 | ||
7223 | * src/bison.simple (YYSIZE_T, YYSTACK_ALLOC, YYSTACK_FREE): | |
7224 | Do not infringe on the global user namespace when using C++. | |
7225 | (YYFPRINTF, YYSTDERR): New macros, needed for the above. | |
7226 | All uses of `fprintf' and `stderr' changed. | |
7227 | ||
7228 | * doc/bison.texinfo: Document YYFPRINTF, YYSTDERR. | |
7229 | ||
7230 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
7231 | ||
7232 | The computation of nullable is broken: it doesn't handle empty | |
7233 | RHS's properly. | |
7234 | ||
7235 | * tests/torture.at (GNU AWK Grammar): New. | |
7236 | * tests/sets.at (Nullable): New. | |
7237 | * src/nullable.c (set_nullable): Instead of blindly looping over | |
7238 | `ritems', loop over the rules, and then over their rhs's. | |
7239 | ||
7240 | Work around Autotest bugs. | |
7241 | ||
7242 | * src/warshall.c (bitmatrix_print): Don't use `+--+' as table | |
7243 | frame, because Autotest understand lines starting with a `+' as | |
7244 | traces from the shell. Then, they are not processed properly. | |
7245 | Admittedly an Autotest bug, but we don't have time to wait for | |
7246 | Autotest to catch up. | |
7247 | * tests/regression.at (Broken Closure): Adjust to the new table | |
7248 | frames. | |
7249 | Move to... | |
7250 | * tests/sets.at: here. | |
7251 | ||
7252 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
7253 | ||
7254 | * src/closure.c (closure): Use nrules instead of playing tricks | |
7255 | with BITS_PER_WORD. | |
7256 | ||
7257 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
7258 | ||
7259 | * src/print.c (print_actions): Output the handling of `$' as the | |
7260 | traces do: shifting the token EOF. Before EOF was treated as a | |
7261 | nonterminal. | |
7262 | * tests/regression.at: Adjust some tests. | |
7263 | * src/print_graph.c (print_core): Complete the set of items via | |
7264 | closure. The next-to-final and final states are still unsatisfying, | |
7265 | but that's to be addressed elsewhere. | |
7266 | No longer output the rule numbers, but do output the state number. | |
7267 | A single loop for the shifts + gotos is enough, but picked a | |
7268 | distinct color for each. | |
7269 | (print_graph): Initialize and finalize closure. | |
7270 | ||
7271 | 2001-12-13 Akim Demaille <akim@epita.fr> | |
7272 | ||
7273 | * src/reader.c (readgram): Remove dead code, an strip useless | |
7274 | braces. | |
7275 | (get_type): Remove, unused. | |
7276 | ||
7277 | 2001-12-12 Akim Demaille <akim@epita.fr> | |
7278 | ||
7279 | * src/complain.h, src/complain.c: Remove error_one_per_line, rely | |
7280 | on that of lib/error.c. | |
7281 | ||
7282 | 2001-12-12 Akim Demaille <akim@epita.fr> | |
7283 | ||
7284 | Some hosts don't like `/' in includes. | |
7285 | ||
7286 | * src/system.h: Include libgettext.h without qualifying the path. | |
7287 | * src/Makefile.am (INCLUDES): Add $(top_srcdir)/intl, remove | |
7288 | $(top_srcdir). | |
7289 | ||
7290 | 2001-12-11 Marc Autret <autret_m@epita.fr> | |
7291 | ||
7292 | * src/output.c (output_parser): Remove useless muscle. | |
7293 | ||
7294 | 2001-12-11 Marc Autret <autret_m@epita.fr> | |
7295 | ||
7296 | * src/bison.simple: Remove #line just before %%epilogue. It | |
7297 | is now handled in ... | |
7298 | * src/reader.c (read_additionnal_code): Add the output of a | |
7299 | #line for the epilogue. | |
7300 | ||
7301 | 2001-12-10 Marc Autret <autret_m@epita.fr> | |
7302 | ||
7303 | * src/reader.c (copy_definition): Re-use CPP-outed code which | |
7304 | replace precedent remove. | |
7305 | * src/bison.simple: Remove #line before %%prologue because | |
7306 | %%input-line is wrong at this time. | |
7307 | ||
7308 | 2001-12-10 Marc Autret <autret_m@epita.fr> | |
7309 | ||
7310 | * src/reader.c (symbols_output): Clean up. | |
7311 | * src/output.c (output_gram, output): Clean up. | |
7312 | ||
7313 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7314 | ||
7315 | * src/lalr.c (initialize_lookaheads): New. Extracted from... | |
7316 | * src/LR0.c (set_state_table): here. | |
7317 | * src/lalr.c (lalr): Call it. | |
7318 | ||
7319 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7320 | ||
7321 | * src/state.h (shifts): Remove the `number' member: shifts are | |
7322 | attached to state, hence no longer need to be labelled with a | |
7323 | state number. | |
7324 | ||
7325 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7326 | ||
7327 | Now that states have a complete set of members, the linked list of | |
7328 | shifts is useless: just fill directly the state's shifts member. | |
7329 | ||
7330 | * src/state.h (shifts): Remove the `next' member. | |
7331 | * src/LR0.c (first_state, last_state): Remove. | |
7332 | Adjust the callers. | |
7333 | (augment_automaton): Don't look for the shifts that must be added | |
7334 | a shift on EOF: it is those of the state we looked for! But now, | |
7335 | since shifts are attached, it is no longer needed to looking | |
7336 | merely by its id: its number. | |
7337 | ||
7338 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7339 | ||
7340 | * src/LR0.c (augment_automaton): Better variable locality. | |
7341 | Remove an impossible branch: if there is a state corresponding to | |
7342 | the start symbol being shifted, then there is shift for the start | |
7343 | symbol from the initial state. | |
7344 | ||
7345 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7346 | ||
7347 | * src/LR0.c (augment_automaton): Call `insert_eof_shifting_state' | |
7348 | only when appropriate: when insert_start_shifting_state' is not | |
7349 | invoked. | |
7350 | * tests/regression.at (Rule Line Numbers): Adjust. | |
7351 | ||
7352 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7353 | ||
7354 | * src/LR0.c (augment_automaton): Now that all states have shifts, | |
7355 | merge the two cases addition shifts to the initial state. | |
7356 | ||
7357 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7358 | ||
7359 | * src/lalr.c (set_state_table): Move to... | |
7360 | * src/LR0.c: here. | |
7361 | * src/lalr.c (lalr): Don't call it... | |
7362 | * src/LR0.c (generate_states): do it. | |
7363 | * src/LR0.h (first_state): Remove, only the table is used. | |
7364 | ||
7365 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7366 | ||
7367 | * src/LR0.h (first_shift, first_reduction): Remove. | |
7368 | * src/lalr.c: Don't use first_shift: find shifts through the | |
7369 | states. | |
7370 | ||
7371 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7372 | ||
7373 | * src/LR0.c: Attach shifts to states as soon as they are | |
7374 | computed. | |
7375 | * src/lalr.c (set_state_table): Instead of assigning shifts to | |
7376 | state, just assert that the mapping was properly done. | |
7377 | ||
7378 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7379 | ||
7380 | * src/LR0.c (insert_start_shift): Rename as... | |
7381 | (insert_start_shifting_state): this. | |
7382 | (insert_eof_shifting_state, insert_accepting_state): New. | |
7383 | (augment_automaton): Adjust. | |
7384 | Better locality of the variables. | |
7385 | When looking if the start_symbol is shifted from the initial | |
7386 | state, using `while (... symbol != start_symbol ...)' sounds | |
7387 | better than `while (... symbol < start_symbol ...)': If fail | |
7388 | to see how the order between symbols could be relevant! | |
7389 | ||
7390 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7391 | ||
7392 | * src/getargs.h: Don't declare `spec_name_prefix' and | |
7393 | `spec_file_prefix', declared by src/files.h. | |
7394 | * src/files.c, src/files.h: Default for spec_name_prefix is "yy". | |
7395 | * src/muscle_tab.c (muscle_init): Default prefix to NULL. | |
7396 | * src/output.c (prepare): Adjust. | |
7397 | * src/reader.c (symbols_output): Likewise. | |
7398 | * src/vmsgetargs.c: Vaguely adjust, but who cares? | |
7399 | ||
7400 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7401 | ||
7402 | * src/muscle_tab.c (muscle_init): NULL is a better default than | |
7403 | `"0"'. | |
7404 | ||
7405 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7406 | ||
7407 | * src/reader.c (reader): Calling symbols_output once is enough. | |
7408 | ||
7409 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7410 | ||
7411 | Now that states have a complete set of members, the linked list of | |
7412 | reductions is useless: just fill directly the state's reductions | |
7413 | member. | |
7414 | ||
7415 | * src/state.h (struct reductions): Remove member `number' and | |
7416 | `next'. | |
7417 | * src/LR0.c (first_reduction, last_reduction): Remove. | |
7418 | (save_reductions): Don't link the new reductions, store them in | |
7419 | this_state. | |
7420 | * src/lalr.c (set_state_table): No need to attach reductions to | |
7421 | states, it's already done. | |
7422 | * src/output.c (output_actions): No longer free the shifts, then | |
7423 | the reductions, then the states: free all the states and their | |
7424 | members. | |
7425 | ||
7426 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7427 | ||
7428 | * src/options.c (OPTN, DRTV, BOTH): New. | |
7429 | (option_table): Use them. | |
7430 | ||
7431 | * src/muscle_tab.c: Don't include xalloc.h and string.h: that's | |
7432 | the job of system.h. | |
7433 | * src/options.c: Don't include stdio.h and xalloc.h for the same | |
7434 | reasons. | |
7435 | ||
7436 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7437 | ||
7438 | * src/output.c (output, prepare): Make sure the values of the | |
7439 | muscles `action' and `prologue' are 0-terminated. | |
7440 | ||
7441 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7442 | ||
7443 | Clean up GCC warnings. | |
7444 | ||
7445 | * src/reader.c (copy_action): `buf' is not used. | |
7446 | (parse_skel_decl): Be static. | |
7447 | * src/muscle_tab.c (mhash1, mhash2, muscle_insert): Preserve `const'. | |
7448 | * src/options.h (create_long_option_table): Have a real prototype. | |
7449 | * lib/hash.c, lib/hash.h (hash_insert, hash_insert_at, hash_delete) | |
7450 | (hash_delete_at): Return const void *. | |
7451 | Adjust casts to preserve the const. | |
7452 | ||
7453 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7454 | ||
7455 | * configure.in: Require 2.52g. | |
7456 | M4 is not needed, but AUTOM4TE is. | |
7457 | * m4/m4.m4: Remove. | |
7458 | * tests/Makefile.am: Adjust. | |
7459 | ||
7460 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7461 | ||
7462 | One structure for states is enough, even though theoretically | |
7463 | there are LR(0) states and LALR(1) states. | |
7464 | ||
7465 | * src/lalr.h (state_t): Remove. | |
7466 | (state_table): Be state_t **, not state_t *. | |
7467 | * src/state.h (core, CORE_ALLOC): Rename as... | |
7468 | (state_t, STATE_ALLOC): this. | |
7469 | Add the LALR(1) members: shifts, reductions, errs. | |
7470 | * src/LR0.c (state_table): Rename as... | |
7471 | (state_hash): this, to avoid name clashes with the global | |
7472 | `state_table'. | |
7473 | * src/print_graph.c, src/LR0.c, src/LR0.h, src/conflicts.c | |
7474 | * src/lalr.c, src/lalr.h, src/output.c, src/print.c: Adjust. | |
7475 | ||
7476 | 2001-12-10 Akim Demaille <akim@epita.fr> | |
7477 | ||
7478 | Bison dumps core on bash.y. | |
7479 | Reported by Pascal Bart. | |
7480 | ||
7481 | * src/warshall.c (bitmatrix_print): New. | |
7482 | (TC): Use it. | |
7483 | When performing a transitive closure R(i, j) && R(j, k) => R(i, k), | |
7484 | j must be the outer loop. | |
7485 | * tests/regression.at (Broken Closure): New. | |
7486 | ||
7487 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7488 | ||
7489 | * tests/atlocal.in (CPPFLAGS): Do not leave a space between -I and | |
7490 | its argument. | |
7491 | Reported by Peter Hamorsky. | |
7492 | ||
7493 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7494 | ||
7495 | * src/conflicts.c (err_table): Remove. | |
7496 | (resolve_sr_conflict): Adjust. | |
7497 | * src/lalr.h (state_t.reduction_table, state_t.shift_table): | |
7498 | Rename as... | |
7499 | (state_t.reductions, state_t.shifts): this. | |
7500 | ||
7501 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7502 | ||
7503 | * src/reduce.c (reduce_grammar_tables): No longer disable the | |
7504 | removal of useless rules via CPP but via `if (0)', so that the | |
7505 | compiler still check the code is valid. | |
7506 | For instance, it should have noticed `rline' no longer exists: use | |
7507 | the `line' member of rule_t. | |
7508 | * src/gram.c (dummy, rline): Remove, unused. | |
7509 | ||
7510 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7511 | ||
7512 | * src/output.c (pack_vector): Use assert, not berror. | |
7513 | * src/main.c (berror): Remove, unused. | |
7514 | ||
7515 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7516 | ||
7517 | New experimental feature: if --verbose --trace output all the | |
7518 | items of a state, not only its kernel. | |
7519 | ||
7520 | * src/print.c (print_core): If `trace_flag', then invoke closure | |
7521 | before outputting the items of the state (print_core is no longer | |
7522 | a correct name them). | |
7523 | (print_results): Invoke new_closure/free_closure if needed. | |
7524 | ||
7525 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7526 | ||
7527 | * src/LR0.c (new_itemsets): Use nshifts only, not shiftcount. | |
7528 | * src/closure.c, src/closure.h (itemsetsize): Rename as... | |
7529 | (nitemset): for consistency with the rest of the project. | |
7530 | ||
7531 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7532 | ||
7533 | * src/closure.c (print_closure): Improve. | |
7534 | (closure): Use it for printing input and output. | |
7535 | ||
7536 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7537 | ||
7538 | * src/closure.c (FIRSTS, FDERIVES): Adjust to reality: they are | |
7539 | indexed by nonterminals. | |
7540 | ||
7541 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7542 | ||
7543 | * src/warshall.c (TC, RTC): De-obsfucate (source reduced to 22% of | |
7544 | what it was!). | |
7545 | * src/warshall.h: Remove accidental duplication of the content. | |
7546 | ||
7547 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7548 | ||
7549 | * src/closure.c (set_fderives): De-obfuscate. | |
7550 | ||
7551 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7552 | ||
7553 | * src/closure.c (print_firsts, print_fderives): De-obfuscate. | |
7554 | ||
7555 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7556 | ||
7557 | * src/closure.c (set_firsts): De-obfuscate. | |
7558 | ||
7559 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7560 | ||
7561 | * src/output.c (action_row): De-obfuscate | |
7562 | using the good o' techniques: arrays not pointers, variable | |
7563 | locality, BITISSET, RESETBIT etc. | |
7564 | ||
7565 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7566 | ||
7567 | Pessimize the code to simplify it: from now on, all the states | |
7568 | have a valid SHIFTS, which NSHIFTS is possibly 0. | |
7569 | ||
7570 | * src/LR0.c (shifts_new): Be global and move to.. | |
7571 | * src/state.c, src/state.h: here. | |
7572 | * src/conflicts, src/lalr.c, src/output.c, src/print.c, | |
7573 | * src/print_graph: Adjust. | |
7574 | ||
7575 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7576 | ||
7577 | * src/state.h (SHIFT_DISABLE, SHIFT_IS_DISABLED): New. | |
7578 | * src/conflicts.c: Use it. | |
7579 | Restore a few missing `if (!SHIFT_IS_DISABLED)' which were | |
7580 | incorrectly ``simplified''. | |
7581 | ||
7582 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7583 | ||
7584 | * src/conflicts.c (flush_shift, resolve_sr_conflict): De-obfuscate | |
7585 | using the good o' techniques: arrays not pointers, variable | |
7586 | locality, BITISSET, RESETBIT etc. | |
7587 | ||
7588 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7589 | ||
7590 | * src/state.h (SHIFT_SYMBOL): New. | |
7591 | * src/conflicts.c: Use it to deobfuscate. | |
7592 | ||
7593 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7594 | ||
7595 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts) | |
7596 | (print_reductions): De-obfuscate using the good o' techniques: | |
7597 | arrays not pointers, variable locality, BITISSET. | |
7598 | ||
7599 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7600 | ||
7601 | * src/conflicts.c (print_reductions): Arrays, not pointers. | |
7602 | Use BITISSET. | |
7603 | ||
7604 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7605 | ||
7606 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
7607 | ||
7608 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7609 | ||
7610 | * src/conflicts.c (print_reductions): Improve variable locality. | |
7611 | ||
7612 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7613 | ||
7614 | * src/conflicts.c (print_reductions): Pessimize, but clarify. | |
7615 | ||
7616 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7617 | ||
7618 | * src/conflicts.c (print_reductions): Improve variable locality. | |
7619 | ||
7620 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7621 | ||
7622 | * src/state.h (SHIFT_IS_ERROR, SHIFT_IS_GOTO, SHIFT_IS_SHIFT): New. | |
7623 | * src/lalr.c: Use them. | |
7624 | ||
7625 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7626 | ||
7627 | * src/LR0.c (augment_automaton): Formatting changes. | |
7628 | Better variable locality. | |
7629 | ||
7630 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7631 | ||
7632 | * src/lalr.c (matrix_print): New. | |
7633 | (transpose): Use it. | |
7634 | Use arrays instead of pointers. | |
7635 | ||
7636 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7637 | ||
7638 | * src/lalr.c (maxrhs): Move to... | |
7639 | * src/gram.c, src/gram.h (ritem_longest_rhs): here. | |
7640 | * src/lalr.c (build_relations): Adjust. | |
7641 | ||
7642 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7643 | ||
7644 | * src/lalr.c (transpose): Free the memory allocated to the | |
7645 | argument, as it is replaced by the results by the unique caller. | |
7646 | (build_relations): Merely invoke transpose: it handles the memory | |
7647 | deallocation. | |
7648 | Improve variable locality. | |
7649 | Avoid variables used as mere abbreviations. | |
7650 | (compute_lookaheads): Use arrays instead of pointers. | |
7651 | ||
7652 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7653 | ||
7654 | * src/lalr.c (initialize_F): Improve variable locality. | |
7655 | Avoid variables used as mere abbreviations. | |
7656 | ||
7657 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7658 | ||
7659 | * src/derives.c (print_derives): Display the ruleno. | |
7660 | * src/lalr.c (initialize_F, transpose): Better variable locality | |
7661 | to improve readability. | |
7662 | Avoid variables used as mere abbreviations. | |
7663 | ||
7664 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7665 | ||
7666 | * src/lalr.c (traverse): Use arrays instead of pointers. | |
7667 | ||
7668 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7669 | ||
7670 | * src/nullable.c (set_nullable): Use a for loop to de-obfuscate | |
7671 | the handling of squeue. | |
7672 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
7673 | ||
7674 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7675 | ||
7676 | Because useless nonterminals are now kept alive (instead of being | |
7677 | `destroyed'), we now sometimes examine them, and store information | |
7678 | related to them. Hence we need to know their number, and adjust | |
7679 | memory allocations. | |
7680 | ||
7681 | * src/reduce.c, src/reduce.h (nuseless_nonterminals): No longer | |
7682 | static. | |
7683 | * src/LR0.c (allocate_itemsets): The memory allocated to | |
7684 | `symbol_count' was used for two different purpose: once to count | |
7685 | the number of occurrences of each symbol, and later reassigned to | |
7686 | `shift_symbol', containing the symbol that can be shifted from a | |
7687 | given state. | |
7688 | Deobfuscate, i.e., allocate, use and free `symbol_count' here | |
7689 | only, and... | |
7690 | (new_itemsets): Allocate `shift_symbol' here. | |
7691 | (allocate_itemsets): symbol_count includes useless nonterminals. | |
7692 | Make room for them. | |
7693 | (free_storage): Use `free', not `XFREE', for pointers that cannot | |
7694 | be null. | |
7695 | ||
7696 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7697 | ||
7698 | * src/nullable.c (set_nullable): Deobfuscate the handling of | |
7699 | ritem. | |
7700 | `symbol >= 0' is wrong now, use `rule_table[ruleno].useful'. | |
7701 | ||
7702 | 2001-12-05 Akim Demaille <akim@epita.fr> | |
7703 | ||
7704 | * src/gram.c, src/gram.h (ritem_print): New. | |
7705 | * src/gram.c (dummy): Remove, now there is actual code in gram.c. | |
7706 | (This useless function was defined only to work around VMS linkers | |
7707 | that can't handle compilation units with variables only). | |
7708 | * src/reduce.c (dump_grammar): Use it to trace the construction of | |
7709 | ritem. | |
7710 | ||
7711 | 2001-12-04 Paul Eggert <eggert@twinsun.com> | |
7712 | ||
7713 | * src/bison.simple (union yyalloc): Change member names | |
7714 | to be the same as the stack names. | |
7715 | (yyparse): yyptr is now union yyalloc *, not char *. | |
7716 | (YYSTACK_RELOCATE): Likewise. This avoids a GCC warning, | |
7717 | and may generate better code on some machines. | |
7718 | (yystpcpy): Use prototype if __STDC__ is defined, not just | |
7719 | if __cplusplus is defined. | |
7720 | ||
7721 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7722 | ||
7723 | * configure.in (WARNING_CFLAGS): Add -Werror when possible. | |
7724 | (CFLAGS): Do not include the WARNING_CFLAGS here, since GNU | |
7725 | Gettext doesn't compile cleanly, and dies with -Werror. | |
7726 | * src/Makefile.am, lib/Makefile.am, tests/atlocal.in (CFLAGS): | |
7727 | Include WARNING_CFLAGS here. | |
7728 | * lib/xstrdup.c: Include xalloc.h, so that xstrdup be declared | |
7729 | before being defined. | |
7730 | ||
7731 | 2001-11-27 Paul Eggert <eggert@twinsun.com> | |
7732 | ||
7733 | * lib/quotearg.h (quotearg_n, quotearg_n_style): | |
7734 | First arg is int, not unsigned. | |
7735 | * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise. | |
7736 | (SIZE_MAX, UINT_MAX): New macros. | |
7737 | (quotearg_n_options): Abort if N is negative. | |
7738 | Avoid overflow check on hosts where size_t is 64 bits and int | |
7739 | is 32 bits, as overflow is impossible there. | |
7740 | Fix off-by-one typo that caused unnecessary reallocation. | |
7741 | ||
7742 | 2001-11-29 Paul Eggert <eggert@twinsun.com> | |
7743 | ||
7744 | Name space cleanup in generated parser. | |
7745 | ||
7746 | * doc/bison.texinfo (Bison Parser): Discuss system headers | |
7747 | and their effect on the user name space. | |
7748 | ||
7749 | * src/bison.simple: | |
7750 | (YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX, | |
7751 | YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary, | |
7752 | i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE). | |
7753 | ||
7754 | (YYSIZE_T): New macro. Use it instead of size_t, to avoid infringing | |
7755 | on user names when possible. | |
7756 | ||
7757 | (YYSTACK_USE_ALLOCA): Do not define; just use any existing defn. | |
7758 | Simplify test for whather <alloca.h> exists. | |
7759 | ||
7760 | (<stdlib.h>): Include if we will use malloc, and if standard C or C++. | |
7761 | ||
7762 | (<stdio.h>): Include if YYDEBUG. | |
7763 | ||
7764 | (yymemcpy): Renamed from __yy_memcpy. Do not define unless | |
7765 | ! defined (yyoverflow) && ! defined (yymemcpy). | |
7766 | ||
7767 | (yymemcpy, yyparse): Rename local variables as needed so that | |
7768 | they all begin with 'yy'. | |
7769 | ||
7770 | (yystrlen, yystpcpy): New functions. | |
7771 | ||
7772 | (YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES. | |
7773 | All uses changed. | |
7774 | ||
7775 | (yyparse): size_t -> YYSIZE_T. Use yystrlen and yystpcpy | |
7776 | instead of relying on string.h functions. Use YYSTACK_ALLOC | |
7777 | and YYSTACK_FREE instead of malloc and free. | |
7778 | ||
7779 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7780 | ||
7781 | * src/bison.simple (YYSTYPE, YYLTYPE): Move their definitions | |
7782 | before their first uses. | |
7783 | (YYBISON, YYPURE): Move to the top of the output. | |
7784 | ||
7785 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7786 | ||
7787 | * tests/reduce.at (Useless Nonterminals): Fix. | |
7788 | ||
7789 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7790 | ||
7791 | * src/bison.simple (YYSTACK_FREE): Use `do {;} while (0)' as empty | |
7792 | if body instead of `;' to pacify GCC's warnings. | |
7793 | ||
7794 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7795 | ||
7796 | Instead of mapping the LHS of unused rules to -1, keep the LHS | |
7797 | valid, but flag the rules as invalid. | |
7798 | ||
7799 | * src/gram.h (rule_t): `useful' is a new member. | |
7800 | * src/print.c (print_grammar): Adjust. | |
7801 | * src/derives.c (set_derives): Likewise. | |
7802 | * src/reader.c (packgram, reduce_output): Likewise. | |
7803 | * src/reduce.c (reduce_grammar_tables): Likewise. | |
7804 | * tests/reduce.at (Underivable Rules, Useless Rules): New. | |
7805 | ||
7806 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7807 | ||
7808 | * src/reduce.c (reduce_output): Formatting changes. | |
7809 | * src/print.c (print_results, print_grammar): Likewise. | |
7810 | * tests/regression.at (Rule Line Numbers) | |
7811 | (Solved SR Conflicts, Unresolved SR Conflicts): Adjust. | |
7812 | ||
7813 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7814 | ||
7815 | * src/reduce.c (nonterminals_reduce): Instead of throwing away | |
7816 | useless nonterminals, move them at the end of the symbol arrays. | |
7817 | (reduce_output): Adjust. | |
7818 | * tests/reduce.at (Useless Nonterminals): Adjust. | |
7819 | ||
7820 | 2001-11-30 Akim Demaille <akim@epita.fr> | |
7821 | ||
7822 | * src/reduce.c: Various comment/formatting changes. | |
7823 | (nonterminals_reduce): New, extracted from... | |
7824 | (reduce_grammar_tables): here. | |
7825 | (reduce_grammar): Call nonterminals_reduce. | |
7826 | ||
7827 | 2001-11-29 Paul Eggert <eggert@twinsun.com> | |
7828 | ||
7829 | * src/bison.simple (YYSTACK_REALLOC): Remove. | |
7830 | (YYSTACK_ALLOC): Resurrect this macro, with its old meaning. | |
7831 | (YYSTACK_FREE, YYSTACK_GAP_MAX, YYSTACK_BYTES, YYSTACK_RELOCATE): | |
7832 | New macros. | |
7833 | (union yyalloc): New type. | |
7834 | (__yy_memcpy): Last arg is size_t, not unsigned int, to remove | |
7835 | an arbitrary restriction on hosts where size_t is wider than int. | |
7836 | ||
7837 | (yyparse): Don't dump core if alloca or malloc fails; instead, report | |
7838 | a parser stack overflow. Allocate just one block of memory for all | |
7839 | three stacks, instead of allocating three blocks; this typically is | |
7840 | faster and reduces fragmentation. | |
7841 | ||
7842 | Do not limit the number of items in the stack to a value that fits | |
7843 | in 'int', as this is an arbitrary limit on hosts with 64-bit | |
7844 | size_t and 32-bit int. | |
7845 | ||
7846 | 2001-11-29 Marc Autret <autret_m@epita.fr> | |
7847 | ||
7848 | * tests/calc.at [AT_DATA_CALC_Y]: Use %error-verbose instead | |
7849 | of defining YYERROR_VERBOSE. | |
7850 | [AT_DATA]: $4 is now out of C declarations in the prologue. | |
7851 | ||
7852 | 2001-11-28 Marc Autret <autret_m@epita.fr> | |
7853 | ||
7854 | * src/reader.c (parse_dquoted_param): New. | |
7855 | (parse_skel_decl): Use it. | |
7856 | * src/lex.h: Add its prototype. | |
7857 | * src/lex.c (literalchar): Become not static. | |
7858 | ||
7859 | 2001-11-28 Marc Autret <autret_m@epita.fr> | |
7860 | ||
7861 | * src/output.h: And put its extern declaration here. | |
7862 | * src/output.c (error_verbose): Define here. | |
7863 | (prepare): Echo name modification. | |
7864 | * src/getargs.h: Clean its extern declaration. | |
7865 | * src/getargs.c (error_verbose_flag): Remove. | |
7866 | (getargs): Remove case 'e'. | |
7867 | * src/options.c (option_table): 'error-verbose' is now seen as simple | |
7868 | percent option. | |
7869 | Include output.h. | |
7870 | ||
7871 | * src/reader.c (read_declarations): Remove case tok_include. | |
7872 | (parse_include_decl): Remove. | |
7873 | * src/lex.h (token_t): Remove tok_include. | |
7874 | * src/options.c (option_table): 'include' is now a simple command line | |
7875 | option. | |
7876 | ||
7877 | 2001-11-28 Marc Autret <autret_m@epita.fr> | |
7878 | ||
7879 | * src/bison.simple: Adjust muscle names. | |
7880 | * src/muscle_tab.c (muscle_init): Also rename the muscles. | |
7881 | * src/output.c (prepare): s/_/-/ for the muscles names. | |
7882 | (output_parser): When scanning for a muscle, allow '-' instead of '_'. | |
7883 | ||
7884 | 2001-11-28 Marc Autret <autret_m@epita.fr> | |
7885 | ||
7886 | * src/bison.simple: Fix debug. | |
7887 | [YYERROR_VERBOSE]: Re-integrate as an internal macro. | |
7888 | ||
7889 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7890 | ||
7891 | * src/LR0.c (shifts_new): New. | |
7892 | (save_shifts, insert_start_shift, augment_automaton): Use it. | |
7893 | ||
7894 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7895 | ||
7896 | * src/closure.c (closure): `b' and `ruleno' denote the same value: | |
7897 | keep ruleno only. | |
7898 | ||
7899 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7900 | ||
7901 | * src/closure.c (closure): Instead of looping over word in array | |
7902 | then bits in words, loop over bits in array. | |
7903 | ||
7904 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7905 | ||
7906 | * src/closure.c (closure): No longer optimize the special case | |
7907 | where all the bits of `ruleset[r]' are set to 0, to make the code | |
7908 | clearer. | |
7909 | ||
7910 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7911 | ||
7912 | * src/closure.c (closure): `r' and `c' are new variables, used to | |
7913 | de-obfuscate accesses to RULESET and CORE. | |
7914 | ||
7915 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7916 | ||
7917 | * src/reduce.c (reduce_print): Use ngettext. | |
7918 | (dump_grammar): Improve the trace accuracy. | |
7919 | ||
7920 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7921 | ||
7922 | * src/reduce.c (dump_grammar): Don't translate trace messages. | |
7923 | ||
7924 | 2001-11-28 Akim Demaille <akim@epita.fr> | |
7925 | ||
7926 | * tests/reduce.at (Useless Terminals, Useless Nonterminals): New. | |
7927 | * src/reduce.c (reduce_grammar_tables): Do not free useless tags, | |
7928 | as all tags are free'ed afterwards. | |
7929 | From Enrico Scholz. | |
7930 | ||
7931 | 2001-11-27 Paul Eggert <eggert@twinsun.com> | |
7932 | ||
7933 | * src/bison.simple (YYSTACK_REALLOC): Fix typo that caused us to | |
7934 | use alloca when we didn't want to, and vice versa. | |
7935 | ||
7936 | 2001-11-27 Marc Autret <autret_m@epita.fr> | |
7937 | ||
7938 | * src/muscle_tab.c (muscle_init): Remove 'verbose' muscle | |
7939 | initialization. | |
7940 | * src/output.c (prepare): Remove its update. | |
7941 | ||
7942 | 2001-11-27 Marc Autret <autret_m@epita.fr> | |
7943 | ||
7944 | * tests/torture.at [AT_DATA]: Remove YYERROR_VERBOSE definition. | |
7945 | Use %error-verbose. | |
7946 | ||
7947 | 2001-11-27 Marc Autret <autret_m@epita.fr> | |
7948 | ||
7949 | * src/bison.simple: Remove YYERROR_VERBOSE using. | |
7950 | Use %%error_verbose. | |
7951 | (yyparse): Likewise. | |
7952 | * src/output.c (prepare): Give its final value. | |
7953 | * src/muscle_tab.c (muscle_init): Init new muscle 'error_verbose'. | |
7954 | * src/getargs.h: Add its extern declaration. | |
7955 | * src/getargs.c (error_verbose_flag): New int. | |
7956 | (getargs): Update to catch new case. | |
7957 | * src/options.c (option_table): 'error-verbose' is a new option. | |
7958 | (shortopts): Update. | |
7959 | ||
7960 | 2001-11-27 Akim Demaille <akim@epita.fr> | |
7961 | ||
7962 | * src/system.h: Use intl/libgettext.h. | |
7963 | * src/Makefile.am (INCLUDES): Add -I $(top_srcdir). | |
7964 | ||
7965 | 2001-11-27 Akim Demaille <akim@epita.fr> | |
7966 | ||
7967 | * tests/torture.at (Exploding the Stack Size with Malloc): | |
7968 | s/YYSTACK_USE_ALLOCA_ALLOCA/YYSTACK_USE_ALLOCA/. | |
7969 | ||
7970 | 2001-11-27 Akim Demaille <akim@epita.fr> | |
7971 | ||
7972 | * src/files.c: Include error.h. | |
7973 | Reported by Hans Aberg. | |
7974 | ||
7975 | 2001-11-26 Marc Autret <autret_m@epita.fr> | |
7976 | ||
7977 | * src/reader.c (parse_include_decl): New, not yet implemented. | |
7978 | (read_declarations): Add case tok_include. | |
7979 | * src/getargs.h (include): Add its extern definition. | |
7980 | * src/getargs.c (include): New const char *. | |
7981 | (getargs): Add case '-I'. | |
7982 | * src/options.c (option_table): Add include as command line and | |
7983 | percent option. | |
7984 | * src/lex.h (token_t): Add tok_include. | |
7985 | ||
7986 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
7987 | ||
7988 | * src/reader.c (readgram): Make sure rules for mid-rule actions | |
7989 | have a lineno equal to that of their host rule. | |
7990 | Reported by Hans Aberg. | |
7991 | * tests/regression.at (Rule Line Numbers): New. | |
7992 | ||
7993 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
7994 | ||
7995 | * src/LR0.c (allocate_itemsets): kernel_size contains ints, not | |
7996 | size_ts. | |
7997 | ||
7998 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
7999 | ||
8000 | * src/complain.c, src/complain.h (error): Remove, provided by | |
8001 | lib/error.[ch]. | |
8002 | ||
8003 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
8004 | ||
8005 | * src/reader.c (read_declarations): Don't abort on tok_illegal, | |
8006 | issue an error message. | |
8007 | * tests/regression.at (Invalid %directive): New. | |
8008 | Reported by Hans Aberg. | |
8009 | ||
8010 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
8011 | ||
8012 | * configure.in: Invoke AC_FUNC_OBSTACK and AC_FUNC_ERROR_AT_LINE. | |
8013 | * lib/Makefile.am (libbison_a_SOURCES): Adjust. | |
8014 | ||
8015 | 2001-11-26 Akim Demaille <akim@epita.fr> | |
8016 | ||
8017 | * src/conflicts.c (conflicts_print): Don't complain at all when | |
8018 | there are no reduce/reduce conflicts, and as many shift/reduce | |
8019 | conflicts as expected. | |
8020 | * tests/regression.at (%expect right): Adjust. | |
8021 | ||
8022 | 2001-11-23 Akim Demaille <akim@epita.fr> | |
8023 | ||
8024 | * lib/alloca.c: Update, from fileutils. | |
8025 | ||
8026 | 2001-11-23 Akim Demaille <akim@epita.fr> | |
8027 | ||
8028 | * lib/Makefile.am (libbison_a_LIBADD): Add @ALLOCA@. | |
8029 | ||
8030 | 2001-11-23 Akim Demaille <akim@epita.fr> | |
8031 | ||
8032 | * src/system.h: Include alloca.h. | |
8033 | * src/main.c (main) [C_ALLOCA]: Call alloca (0). | |
8034 | ||
8035 | 2001-11-23 Akim Demaille <akim@epita.fr> | |
8036 | ||
8037 | * src/print_graph.c (print_actions): Remove `rule', unused. | |
8038 | * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to | |
8039 | pacify GCC's signed < unsigned warnings. | |
8040 | * src/closure.c (itemsetsize): Likewise. | |
8041 | * src/reader.c (symbol_list_new): Static. | |
8042 | ||
8043 | 2001-11-23 Akim Demaille <akim@epita.fr> | |
8044 | ||
8045 | Attaching lineno to buckets is stupid, since only one copy of each | |
8046 | symbol is kept, only the line of the first occurrence is kept too. | |
8047 | ||
8048 | * src/symtab.h, src/symtab.c (bucket): Remove the line member. | |
8049 | * src/reader.c (rline_allocated): Remove, unused. | |
8050 | (symbol_list): Have a `line' member. | |
8051 | (symbol_list_new): New. | |
8052 | (readgram): Use it. | |
8053 | * src/print.c (print_grammar): Output the rule line numbers. | |
8054 | * tests/regression.at (Solved SR Conflicts) | |
8055 | (Unresolved SR Conflicts): Adjust. | |
8056 | Reported by Hans Aberg. | |
8057 | ||
8058 | 2001-11-22 Marc Autret <autret_m@epita.fr> | |
8059 | ||
8060 | * src/bison.simple [YYERROR_VERBOSE]: Force its value to be 1 or 0. | |
8061 | ||
8062 | 2001-11-22 Marc Autret <autret_m@epita.fr> | |
8063 | ||
8064 | * src/muscle_tab.c (muscle_init): Remove initialization of | |
8065 | skeleton muscle. | |
8066 | * src/output.c (output_master_parser): Do it here. | |
8067 | ||
8068 | 2001-11-20 Akim Demaille <akim@epita.fr> | |
8069 | ||
8070 | * po/sv.po: New. | |
8071 | * configure.in (ALL_LINGUAS): Adjust. | |
8072 | * po/POTFILE.in: Remove `nullable.c' and `derives.c' which no | |
8073 | longer contains strings to translate. | |
8074 | ||
8075 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8076 | ||
8077 | * src/conflicts.c (conflicts_print): Add a missing \n. | |
8078 | ||
8079 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8080 | ||
8081 | * src/nullable.c (nullable_print): New. | |
8082 | (set_nullable): Call it when tracing. | |
8083 | Better locality of variables. | |
8084 | ||
8085 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8086 | ||
8087 | * src/print.c (print_actions): Better locality of variables. | |
8088 | ||
8089 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8090 | ||
8091 | * src/derives.c (print_derives): Fix and enrich. | |
8092 | * src/closure.c (print_fderives): Likewise. | |
8093 | ||
8094 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8095 | ||
8096 | * src/closure.c (itemsetend): Remove, replaced with... | |
8097 | (itemsetsize): new. | |
8098 | ||
8099 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8100 | ||
8101 | * src/LR0.c (kernel_end): Remove, replaced with... | |
8102 | (kernel_size): new. | |
8103 | ||
8104 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8105 | ||
8106 | * src/conflicts.c (set_conflicts): Use arrays instead of pointers | |
8107 | to clarify. | |
8108 | ||
8109 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8110 | ||
8111 | * src/closure.c (closure): Use arrays instead of pointers to clarify. | |
8112 | ||
8113 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8114 | ||
8115 | * src/closure.c, src/derives.c, src/nullable.c: Adjust various | |
8116 | trace messages. | |
8117 | * src/LR0.c: Likewise. | |
8118 | (allocate_itemsets): Use arrays instead of pointers to clarify. | |
8119 | ||
8120 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8121 | ||
8122 | * src/getargs.c (statistics_flag): Replace with... | |
8123 | (trace_flag): New. | |
8124 | (longopts): Accept --trace instead of --statistics. | |
8125 | * src/getargs.h, src/options.c: Adjust. | |
8126 | * src/LR0.c, src/closure.c, src/derives.c, src/nullable.c, | |
8127 | * src/reduce.c: Use trace_flags instead of the CPP conditional TRACE. | |
8128 | ||
8129 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8130 | ||
8131 | * src/LR0.c (new_itemsets, get_state): Use more arrays and fewer | |
8132 | pointers to clarify the code. | |
8133 | (save_reductions, save_shifts): Factor common parts of alternatives. | |
8134 | ||
8135 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8136 | ||
8137 | * src/LR0.c (new_state, get_state): Complete TRACE code. | |
8138 | * src/closure.c: Include `reader.h' to get `tags', needed by the | |
8139 | trace code. | |
8140 | Rename the conditional DEBUG as TRACE. | |
8141 | Output consistently TRACEs to stderr, not stdout. | |
8142 | * src/derives.c: Likewise. | |
8143 | * src/reduce.c: (inaccessable_symbols): Using if is better style | |
8144 | than goto. | |
8145 | Use `#if TRACE' instead of `#if 0' for tracing code. | |
8146 | ||
8147 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8148 | ||
8149 | * src/system.h (LIST_FREE, shortcpy): New. | |
8150 | * src/LR0.c: Use them. | |
8151 | * src/output.c (free_itemsets, free_reductions, free_shifts): | |
8152 | Remove, replaced by LIST_FREE. | |
8153 | ||
8154 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8155 | ||
8156 | * src/state.h (CORE_ALLOC, SHIFTS_ALLOC, ERRS_ALLOC) | |
8157 | (REDUCTIONS_ALLOC): New. | |
8158 | * src/LR0.c, src/conflicts.c: Use them to de-obfuscate memory | |
8159 | allocation. | |
8160 | ||
8161 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8162 | ||
8163 | * src/LR0.c (new_state): Complete trace code. | |
8164 | * src/nullable.c (set_nullable): Don't translate traces. | |
8165 | ||
8166 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8167 | ||
8168 | * src/print_graph.c (print_core): Better locality of variables. | |
8169 | * src/print.c (print_core): Likewise. | |
8170 | ||
8171 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8172 | ||
8173 | * src/vcg.c: You do the output, so you are responsible of the | |
8174 | handling of VCG syntax, in particular: use quotearg. | |
8175 | * src/print_graph.c: Don't. | |
8176 | (print_actions): Don't output the actions as part of the nodes, | |
8177 | since that's the job of the edges. | |
8178 | (print_state): Don't output by hand: fill the node description, | |
8179 | and ask for its output. | |
8180 | ||
8181 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8182 | ||
8183 | * src/bison.simple (yyparse): When verbosely reporting an error, | |
8184 | no longer put additional quotes around token names. | |
8185 | * tests/calc.at: Adjust. | |
8186 | ||
8187 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8188 | ||
8189 | * src/symtab.h, src/symtab.c: `line' is a new member of `bucket'. | |
8190 | * src/reader.c (record_rule_lines, rline, rline_allocated): Remove. | |
8191 | * src/output.c: Adjust. | |
8192 | ||
8193 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8194 | ||
8195 | * src/gram.h (rprec, rprecsym, rassoc): Remove, now part of... | |
8196 | (rule_t): this. | |
8197 | * src/conflicts.c, src/reader.c, src/reduce.c: Adjust. | |
8198 | ||
8199 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8200 | ||
8201 | * src/gram.h (rule_t): New. | |
8202 | (rule_table): New. | |
8203 | (rrhs, rlhs): Remove, part of state_t. | |
8204 | * src/print_graph.c, src/closure.c, src/conflicts.c, src/derives.c, | |
8205 | * src/lalr.c, src/nullable.c, src/output.c, src/print.c, | |
8206 | * src/reader.c, src/reduce.c: Adjust. | |
8207 | ||
8208 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8209 | ||
8210 | * src/reader.c (symbols_output): New, extracted from... | |
8211 | (packsymbols): Here. | |
8212 | (reader): Call it. | |
8213 | ||
8214 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8215 | ||
8216 | * src/lalr.c (set_maxrhs, maxrhs): Remove, replaced with... | |
8217 | (maxrhs): this new function. | |
8218 | ||
8219 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8220 | ||
8221 | * src/lalr.c (F): New macro to access the variable F. | |
8222 | Adjust. | |
8223 | ||
8224 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8225 | ||
8226 | * src/lalr.h (LA): New macro to access the variable LA. | |
8227 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
8228 | * src/lalr.c: Adjust. | |
8229 | ||
8230 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8231 | ||
8232 | * src/lalr.c (initialize_LA): Only initialize LA. Let... | |
8233 | (set_state_table): handle the `lookaheads' members. | |
8234 | ||
8235 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8236 | ||
8237 | * src/lalr.h (lookaheads): Removed array, whose contents is now | |
8238 | a member of... | |
8239 | (state_t): this structure. | |
8240 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
8241 | Adjust. | |
8242 | ||
8243 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8244 | ||
8245 | * src/lalr.h (consistent): Removed array, whose contents is now | |
8246 | a member of... | |
8247 | (state_t): this structure. | |
8248 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
8249 | Adjust. | |
8250 | ||
8251 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8252 | ||
8253 | * src/lalr.h (reduction_table, shift_table): Removed arrays, whose | |
8254 | contents are now members of... | |
8255 | (state_t): this structure. | |
8256 | * src/output.c, src/lalr.c, src/print_graph.c, src/conflicts.c: | |
8257 | Adjust. | |
8258 | ||
8259 | 2001-11-19 Akim Demaille <akim@epita.fr> | |
8260 | ||
8261 | * src/lalr.h (state_t): New. | |
8262 | (state_table): Be a state_t * instead of a core **. | |
8263 | (accessing_symbol): Remove, part of state_t. | |
8264 | * src/lalr.c: Adjust. | |
8265 | (set_accessing_symbol): Merge into... | |
8266 | (set_state_table): this. | |
8267 | * src/print_graph.c, src/conflicts.c: Adjust. | |
8268 | ||
8269 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
8270 | ||
8271 | * tests/calc.at, tests/output.at, tests/regression.at, | |
8272 | * tests/testsuite.at, tests/torture.at: Rely on Autotest 2.52g: | |
8273 | now the tests are run in private dirs, therefore AC_CLEANUP and | |
8274 | family can be simplified to 0-ary. | |
8275 | * tests/atlocal.in: Now that we run `elsewhere' than in tests/, | |
8276 | use abs. path to find config.h. | |
8277 | * tests/calc.at (AT_CHECK_CALC): Don't try to check the compiler's | |
8278 | stderr, there can be way too much random noise. | |
8279 | Instead pass -Werror to GCC and rely on the exit status. | |
8280 | Reported by Wolfram Wagner. | |
8281 | ||
8282 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
8283 | ||
8284 | * src/bison.simple (yyparse): Let yyls1, yyss1 and yyvs1 be | |
8285 | defined only if yyoverflow is defined, to avoid `warning: unused | |
8286 | variable `yyvs1''. | |
8287 | Reported by The Test Suite. | |
8288 | ||
8289 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
8290 | ||
8291 | * src/print.c: Include reduce.h. | |
8292 | Reported by Hans Aberg. | |
8293 | ||
8294 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
8295 | ||
8296 | * src/lex.c, src/lex.h (token_buffer, unlexed_token_buffer): | |
8297 | Revert a previous patch: these are really const. | |
8298 | * src/conflicts.c (conflict_report): Additional useless pair of | |
8299 | braces to pacify GCC's warnings for `if () if () {} else {}'. | |
8300 | * src/lex.c (parse_percent_token): Replace equal_offset with | |
8301 | arg_offset. | |
8302 | arg is const. | |
8303 | Be sure to strdup `arg' when used, since there is no reason for | |
8304 | token_buffer not to change. | |
8305 | ||
8306 | 2001-11-14 Akim Demaille <akim@epita.fr> | |
8307 | ||
8308 | * src/system.h (EXIT_SUCCESS, EXIT_FAILURE): Ensure a proper | |
8309 | definition. | |
8310 | * src/main.c (main): Use them. | |
8311 | Suggested by Hans Aberg. | |
8312 | ||
8313 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8314 | ||
8315 | * src/system.h (ngettext): Now that we use ngettext, be sure to | |
8316 | provide a default definition when NLS are not used. | |
8317 | ||
8318 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8319 | ||
8320 | * doc/bison.texinfo: Use `$' as shell prompt, not `%'. | |
8321 | Use @kbd to denote user input. | |
8322 | (Language and Grammar): ANSIfy the example. | |
8323 | Adjust its layout for info/notinfo. | |
8324 | (Location Tracking Calc): Output error messages to stderr. | |
8325 | Output locations in a more GNUtically correct way. | |
8326 | Fix a couple of Englishos. | |
8327 | Adjust @group/@end group pairs. | |
8328 | ||
8329 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8330 | ||
8331 | %expect was not functioning at all. | |
8332 | ||
8333 | * src/conflicts.c (expected_conflicts): Set to -1. | |
8334 | (conflict_report): Use ngettext. | |
8335 | (conflicts_print): Check %expect and make its violation an error. | |
8336 | * doc/bison.texinfo (Expect Decl): Adjust. | |
8337 | * configure.in (AM_GNU_GETTEXT): Ask for ngettext. | |
8338 | * tests/regression.at (%expect not enough, %expect right) | |
8339 | (%expect too much): New. | |
8340 | ||
8341 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8342 | ||
8343 | * tests/regression.at (Conflicts): Rename as... | |
8344 | (Unresolved SR Conflicts): this. | |
8345 | (Solved SR Conflicts): New. | |
8346 | ||
8347 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8348 | ||
8349 | * src/reduce.c (print_results): Rename as... | |
8350 | (reduce_output): This. | |
8351 | Output to OUT, passed as argument, instead of output_obstack. | |
8352 | (dump_grammar): Likewise. | |
8353 | (reduce_free): New. | |
8354 | Also free V1. | |
8355 | (reduce_grammar): No longer call reduce_output, since... | |
8356 | * src/print.c (print_results): do it. | |
8357 | * src/main.c (main): Call reduce_free; | |
8358 | ||
8359 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8360 | ||
8361 | * src/conflicts.c (print_reductions): Accept OUT as argument. | |
8362 | Output to it, not to output_obstack. | |
8363 | * src/print.c (print_actions): Adjust. | |
8364 | ||
8365 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8366 | ||
8367 | * src/conflicts.c (count_sr_conflicts, count_rr_conflicts): Return | |
8368 | the result instead of using... | |
8369 | (src_total, rrc_total, src_count, rrc_count): Remove. | |
8370 | (any_conflicts): Remove. | |
8371 | (print_conflicts): Split into... | |
8372 | (conflicts_print, conflicts_output): New. | |
8373 | * src/conflicts.h: Adjust. | |
8374 | * src/main.c (main): Invoke both conflicts_output and conflicts_print. | |
8375 | * src/print.c (print_grammar): Issue `\n' between two rules. | |
8376 | * tests/regression.at (Conflicts): New. | |
8377 | Reported by Tom Lane. | |
8378 | ||
8379 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8380 | ||
8381 | * tests/regression.at (Invalid input): Remove, duplicate with | |
8382 | ``Invalid input: 1''. | |
8383 | ||
8384 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8385 | ||
8386 | * tests/torture.at (AT_DATA_STACK_TORTURE) | |
8387 | (Exploding the Stack Size with Alloca) | |
8388 | (Exploding the Stack Size with Malloc): New. | |
8389 | ||
8390 | 2001-11-12 Akim Demaille <akim@epita.fr> | |
8391 | ||
8392 | * src/bison.simple (YYSTACK_REALLOC): New. | |
8393 | (yyparse) [!yyoverflow]: Use it and free the old stack. | |
8394 | Reported by Per Allansson. | |
8395 | ||
8396 | 2001-11-12 Pascal Bart <pascal.bart@epita.fr> | |
8397 | ||
8398 | * src/bison.simple: Define type yystype instead of YYSTYPE, and | |
8399 | define CPP macro, which substitute YYSTYPE by yystype. | |
8400 | * src/reader.c (parse_union_decl): Output yystype/YYSTYPE as we do | |
8401 | with yyltype/YYLTYPE. This allows inclusion of the generated | |
8402 | header within the parser if the compiler, such as GGC, accepts | |
8403 | multiple equivalent #defines. | |
8404 | From Akim. | |
8405 | ||
8406 | 2001-11-05 Akim Demaille <akim@epita.fr> | |
8407 | ||
8408 | * src/reader.c (symbols_output): New, extracted from... | |
8409 | (packsymbols): here. | |
8410 | (reader): Adjust. | |
8411 | ||
8412 | 2001-11-05 Akim Demaille <akim@epita.fr> | |
8413 | ||
8414 | * src/lex.c (parse_percent_token): s/quotearg/quote/. | |
8415 | ||
8416 | 2001-11-05 Akim Demaille <akim@epita.fr> | |
8417 | ||
8418 | * tests/regression.at (AT_TEST_CPP_GUARD_H): Adjust the clean up | |
8419 | pattern. | |
8420 | ||
8421 | 2001-11-05 Akim Demaille <akim@epita.fr> | |
8422 | ||
8423 | * src/options.h (struct option_table_struct): set_flags is void*. | |
8424 | * src/options.c (longopts): Support `--output' and `%output'. | |
8425 | (usage): Adjust. | |
8426 | * src/lex.h (tok_setopt): Remove, replaced with... | |
8427 | (tok_intopt, tok_stropt): these new guys. | |
8428 | * src/lex.c (getopt.h): Not needed. | |
8429 | (token_buffer, unlexed_token_buffer): Not const. | |
8430 | (percent_table): Promote `-' over `_' in directive names. | |
8431 | Active `%name-prefix', `file-prefix', and `output'. | |
8432 | (parse_percent_token): Accept possible arguments to directives. | |
8433 | Promote `-' over `_' in directive names. | |
8434 | ||
8435 | 2001-11-04 Akim Demaille <akim@epita.fr> | |
8436 | ||
8437 | * doc/bison.texinfo (Decl Summary): Split the list into | |
8438 | `directives for grammars' and `directives for bison'. | |
8439 | Sort'em. | |
8440 | Add description of `%name-prefix', `file-prefix', and `output'. | |
8441 | Promote `-' over `_' in directive names. | |
8442 | (Bison Options): s/%locactions/%locations/. Nice Freudian slip. | |
8443 | Simplify the description of `--name-prefix'. | |
8444 | Promote `-' over `_' in directive names. | |
8445 | Promote `--output' over `--output-file'. | |
8446 | Fix the description of `--defines'. | |
8447 | * tests/output.at: Exercise %file-prefix and %output. | |
8448 | ||
8449 | 2001-11-02 Akim Demaille <akim@epita.fr> | |
8450 | ||
8451 | * doc/refcard.tex: Update. | |
8452 | ||
8453 | 2001-11-02 Akim Demaille <akim@epita.fr> | |
8454 | ||
8455 | * src/symtab.h (SUNDEF): New. | |
8456 | * src/symtab.c (bucket_new): Init user_token_number to SUNDEF to | |
8457 | stand for `uninitialized', instead of 0. | |
8458 | * src/reader.c (packsymbols, parse_thong_decl): Adjust. | |
8459 | * src/lex.c (lex): Adjust. | |
8460 | ||
8461 | * tests/calc.at (_AT_DATA_CALC_Y): Declare a token for EOF. | |
8462 | Number it 0. | |
8463 | Let yylex return it instead of a plain 0. | |
8464 | Reported by Dick Streefland. | |
8465 | ||
8466 | 2001-11-02 Akim Demaille <akim@epita.fr> | |
8467 | ||
8468 | * tests/regression.at (Mixing %token styles): New test. | |
8469 | ||
8470 | 2001-11-02 Akim Demaille <akim@epita.fr> | |
8471 | ||
8472 | * src/reader.c (parse_thong_decl): Formatting changes. | |
8473 | (token_translations_init): New, extracted from... | |
8474 | (packsymbols): Here. | |
8475 | Adjust. | |
8476 | ||
8477 | 2001-11-01 Akim Demaille <akim@epita.fr> | |
8478 | ||
8479 | * tests/regression.at (AT_TEST_CPP_GUARD_H): New. | |
8480 | Check that `9foo.y' produces correct cpp guards. | |
8481 | * src/files.c (compute_header_macro): Prepend `BISON_' to CPP | |
8482 | guards. | |
8483 | Reported by Wwp. | |
8484 | ||
8485 | 2001-11-01 Akim Demaille <akim@epita.fr> | |
8486 | ||
8487 | * tests/regression.at (Invalid input: 2): New. | |
8488 | * src/lex.c (unlexed_token_buffer): New. | |
8489 | (lex, unlex): Adjust: when unlexing, be sure to save token_buffer | |
8490 | too. | |
8491 | Reported by Wwp. | |
8492 | ||
8493 | 2001-11-01 Akim Demaille <akim@epita.fr> | |
8494 | ||
8495 | * tests/calc.at: Catch up with 1.30. | |
8496 | * configure.in: Bump to 1.49a. | |
8497 | Adjust to newer Autotest. | |
8498 | ||
8499 | 2001-10-19 Pascal Bart <pascal.bart@epita.fr> | |
8500 | ||
8501 | * src/conflicts.c: Move global variables rrc_total and src_total ... | |
8502 | (print_conflicts): here. | |
8503 | * src/output.c (output): Free global variable user_toknums. | |
8504 | * src/lex.c (token_obstack): Become static. | |
8505 | ||
8506 | 2001-10-18 Akim Demaille <akim@epita.fr> | |
8507 | ||
8508 | * tests/atlocal.in (GCC): Add. | |
8509 | * tests/calc.at: s/m4_match/m4_bmatch/. | |
8510 | s/m4_patsubst/m4_bpatsubst/. | |
8511 | (AT_CHECK_CALC): Check the compiler's stderr only if it's GCC. | |
8512 | * configure.in: AC_SUBST(GCC). | |
8513 | ||
8514 | 2001-10-14 Marc Autret <autret_m@epita.fr> | |
8515 | ||
8516 | * src/options.c (create_long_option_table): Fix. | |
8517 | ||
8518 | 2001-10-10 Akim Demaille <akim@epita.fr> | |
8519 | ||
8520 | * src/bison.simple: Be sure to set YYSTACK_USE_ALLOCA. | |
8521 | ||
8522 | 2001-10-04 Akim Demaille <akim@epita.fr> | |
8523 | ||
8524 | * src/reader.c (parse_union_decl): Push the caracters in | |
8525 | union_obstack, not attrs_obstack. | |
8526 | ||
8527 | 2001-10-04 Akim Demaille <akim@epita.fr> | |
8528 | ||
8529 | Merge in the branch 1.29. | |
8530 | ||
8531 | * src/reader.c (packsymbols): Use a temporary obstack for | |
8532 | `%%tokendef', since output_stack is already used elsewhere. | |
8533 | ||
8534 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8535 | ||
8536 | Bump 1.29d. | |
8537 | ||
8538 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8539 | ||
8540 | Version 1.29c. | |
8541 | ||
8542 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8543 | ||
8544 | * tests/regression.at (Invalid CPP headers): New. | |
8545 | From Alexander Belopolsky. | |
8546 | * src/files.c (compute_header_macro): Map non alnum chars to `_'. | |
8547 | ||
8548 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8549 | ||
8550 | * tests/regression.at (Invalid input): New. | |
8551 | * src/lex.c (lex): Be sure to set `token_buffer' in any case. | |
8552 | Reported by Shura. | |
8553 | ||
8554 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8555 | ||
8556 | * tests/calc.at: Now that --debug works, the tests must be adjusted. | |
8557 | ||
8558 | 2001-10-02 Akim Demaille <akim@epita.fr> | |
8559 | ||
8560 | * src/output.c (output_parser): Assert `skeleton'. | |
8561 | * src/files.c (skeleton_find): Look harder for skeletons on DOSish | |
8562 | systems. | |
8563 | From Shura. | |
8564 | ||
8565 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
8566 | ||
8567 | * src/lex.h: Echo modifications. | |
8568 | * src/lex.c (unlex): Parameter is now token_t. | |
8569 | From Hans Aberg. | |
8570 | ||
8571 | 2001-10-01 Marc Autret <autret_m@epita.fr> | |
8572 | ||
8573 | * src/main.c: Include lex.h. | |
8574 | From Hans Aberg. | |
8575 | ||
8576 | 2001-09-29 Akim Demaille <akim@epita.fr> | |
8577 | ||
8578 | * src/getargs.c (longopts): `--debug' is `-t', not `-d'. | |
8579 | ||
8580 | 2001-09-28 Akim Demaille <akim@epita.fr> | |
8581 | ||
8582 | * tests/testsuite.at: Update to newer Autotest. | |
8583 | * tests/Makefile.am (EXTRA_DIST): bison is not to be shipped. | |
8584 | ||
8585 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
8586 | ||
8587 | Position independent wrapper. | |
8588 | ||
8589 | * tests/bison: Remove. | |
8590 | * tests/bison.in: New. | |
8591 | * configure.in: Adjust. | |
8592 | ||
8593 | 2001-09-27 Paul Eggert <eggert@twinsun.com> | |
8594 | ||
8595 | Port quotearg fixes from tar 1.13.24. | |
8596 | ||
8597 | * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct | |
8598 | tm to be declared. | |
8599 | (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC. | |
8600 | (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT. | |
8601 | ||
8602 | * m4/Makefile.am (EXTRA_DIST): Add mbrtowc.m4. | |
8603 | * m4/mbrtowc.m4: New file. | |
8604 | * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for mbsinit and stddef.h. | |
8605 | Use jm_FUNC_MBRTOWC instead of AC_CHECK_FUNCS(mbrtowc). | |
8606 | ||
8607 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
8608 | ||
8609 | Bump to 1.29c. | |
8610 | ||
8611 | 2001-09-27 Akim Demaille <akim@epita.fr> | |
8612 | ||
8613 | Version 1.29b. | |
8614 | ||
8615 | 2001-09-25 Akim Demaille <akim@epita.fr> | |
8616 | ||
8617 | * src/system.h: Include `xalloc.h'. | |
8618 | Remove it from the C files. | |
8619 | * src/files.c (output_files): Free the obstacks. | |
8620 | * src/lex.c (init_lex): Rename as... | |
8621 | (lex_init): this. | |
8622 | (lex_free): New. | |
8623 | * src/main.c (main): Use it. | |
8624 | ||
8625 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
8626 | ||
8627 | * src/vcg.c (open_edge, close_edge, open_node, close_node): Change | |
8628 | to output informations in fout (FILE*). | |
8629 | (open_graph, close_graph): Likewise. | |
8630 | (output_graph, output_edge, output_node): Likewise. | |
8631 | * src/vcg.h: Update function prototypes. | |
8632 | * src/print_graph.c (print_graph): Open output graph file. | |
8633 | (print_actions): Adjust. | |
8634 | * src/files.h: Remove extern declaration. | |
8635 | * src/files.c: Remove graph_obstack declaration. | |
8636 | (open_files): Remove graph_obstack initialization. | |
8637 | (output_files): Remove graph_obstack saving. | |
8638 | ||
8639 | 2001-09-24 Marc Autret <autret_m@epita.fr> | |
8640 | ||
8641 | * src/files.c (compute_output_file_names): Fix. | |
8642 | ||
8643 | 2001-09-24 Marc Autret <autret_m@epita.fr>, | |
8644 | Akim Demaille <akim@epita.fr> | |
8645 | ||
8646 | * src/reader.c (reader): Remove call to free_symtab (). | |
8647 | * src/main.c (main): Call it here. | |
8648 | Include symtab.h. | |
8649 | * src/conflicts.c (initialize_conflicts): Rename as... | |
8650 | (solve_conflicts): this. | |
8651 | * src/print.c (print_core, print_actions, print_state) | |
8652 | (print_grammar): Dump to a file instead a `output_obstack'. | |
8653 | (print_results): Dump `output_obstack', and then proceed with the | |
8654 | FILE *. | |
8655 | * src/files.c (compute_output_file_names, close_files): New. | |
8656 | (output_files): Adjust. | |
8657 | * src/main.c (main): Adjust. | |
8658 | ||
8659 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
8660 | ||
8661 | * src/files.c (compute_header_macro): Computes header macro name | |
8662 | from spec_defines_file when given. | |
8663 | ||
8664 | 2001-09-23 Marc Autret <autret_m@epita.fr> | |
8665 | ||
8666 | * src/files.c (output_files): Add default extensions. | |
8667 | ||
8668 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
8669 | ||
8670 | * src/conflicts.c (finalize_conflicts): Rename as... | |
8671 | (free_conflicts): this. | |
8672 | ||
8673 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
8674 | ||
8675 | * src/gram.c (gram_free): Rename back as... | |
8676 | (dummy): this. | |
8677 | (output_token_translations): Free `token_translations'. | |
8678 | * src/symtab.c (free_symtab): Free the tag field. | |
8679 | ||
8680 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
8681 | ||
8682 | Remove `translations' as it is always set to true. | |
8683 | ||
8684 | * src/gram.h: Adjust. | |
8685 | * src/reader.c (packsymbols, parse_token_decl): Adjust | |
8686 | * src/print.c (print_grammar): Adjust. | |
8687 | * src/output.c (output_token_translations): Adjust. | |
8688 | * src/lex.c (lex): Adjust. | |
8689 | * src/gram.c: Be sure the set pointers to NULL. | |
8690 | (dummy): Rename as... | |
8691 | (gram_free): this. | |
8692 | ||
8693 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
8694 | ||
8695 | * configure.in: Invoke AM_LIB_DMALLOC. | |
8696 | * src/system.h: Use dmalloc. | |
8697 | * src/LR0.c: Be sure to have pointers initialized to NULL. | |
8698 | (allocate_itemsets): Allocate kernel_items only if needed. | |
8699 | ||
8700 | 2001-09-22 Akim Demaille <akim@epita.fr> | |
8701 | ||
8702 | * configure.in: Bump to 1.29b. | |
8703 | * tests/Makefile.am (DISTCLEANFILES): Add package.m4. | |
8704 | * tests/calc.at (_AT_DATA_CALC_Y): #undef malloc so that we don't | |
8705 | need xmalloc.c in calc.y. | |
8706 | From Pascal Bart. | |
8707 | ||
8708 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
8709 | ||
8710 | Version 1.29a. | |
8711 | * Makefile.maint, config/config.guess, config/config.sub, | |
8712 | * config/missing: Update from masters. | |
8713 | * tests/Makefile.am ($(srcdir)/$(TESTSUITE)): No longer depend | |
8714 | upon package.m4. | |
8715 | * configure.in (ALL_LINGUAS): Add `tr'. | |
8716 | ||
8717 | 2001-09-21 Akim Demaille <akim@epita.fr> | |
8718 | ||
8719 | * tests/Makefile.am (package.m4): Move to... | |
8720 | ($(srcdir)/$(TESTSUITE)): here. | |
8721 | ||
8722 | 2001-09-20 Akim Demaille <akim@epita.fr> | |
8723 | ||
8724 | * src/complain.c: No longer try to be standalone: use system.h. | |
8725 | Don't assume __STDC__ is defined to 1. Just test if it is defined. | |
8726 | * src/complain.h: Likewise. | |
8727 | * src/reduce.c (useless_nonterminals, inaccessable_symbols): | |
8728 | Remove the unused variable `n'. | |
8729 | From Albert Chin-A-Young. | |
8730 | ||
8731 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8732 | ||
8733 | * doc/bison.1: Update. | |
8734 | * doc/bison.texinfo (Bison Options): Update --defines and --graph | |
8735 | descriptions. | |
8736 | (Option Cross Key): Update. | |
8737 | Add --graph. | |
8738 | ||
8739 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8740 | ||
8741 | * tests/regression.at: New test (comment in %union). | |
8742 | ||
8743 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8744 | ||
8745 | * src/reader.c (parse_union_decl): Do not output '/'. Let copy_comment | |
8746 | do that. | |
8747 | Reported by Keith Browne. | |
8748 | ||
8749 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8750 | ||
8751 | * tests/output.at: Add tests for --defines and --graph. | |
8752 | ||
8753 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8754 | ||
8755 | * tests/output.at: Removes tests of %{header,src}_extension features. | |
8756 | ||
8757 | 2001-09-18 Akim Demaille <akim@epita.fr> | |
8758 | ||
8759 | * tests/Makefile.am (package.m4): New. | |
8760 | * tests/calc.at (_AT_CHECK_CALC): Just run `calc input'. | |
8761 | (_AT_CHECK_CALC_ERROR): Likewise. | |
8762 | Factor the `, ' part of verbose error messages. | |
8763 | ||
8764 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8765 | ||
8766 | * src/getargs.c (longopts): Declare --defines and --graph as options | |
8767 | with optional arguments. | |
8768 | * src/files.h: Add extern declarations. | |
8769 | * src/files.c (spec_graph_file, spec_defines_file): New. | |
8770 | (output_files): Update. | |
8771 | Remove CPP-outed code. | |
8772 | ||
8773 | 2001-09-18 Marc Autret <autret_m@epita.fr> | |
8774 | ||
8775 | Turn off %{source,header}_extension feature. | |
8776 | ||
8777 | * src/files.c (compute_exts_from_gf): Update. | |
8778 | (compute_exts_from_src): Update. | |
8779 | (output_files): CPP-out useless code. | |
8780 | * src/files.h: Remove {header,source}_extension extern declarations. | |
8781 | * src/reader.c (parse_dquoted_param): CPP-out. | |
8782 | (parse_header_extension_decl): Remove. | |
8783 | (parse_source_extension_decl): Remove. | |
8784 | (read_declarations): Remove cases tok_{hdrext,srcext}. | |
8785 | * src/lex.c (percent_table): Remove {header,source}_extension entries. | |
8786 | * src/lex.h (token_t): Remove tok_hdrext and tok_srcext. | |
8787 | ||
8788 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
8789 | ||
8790 | * tests/output.at (AT_CHECK_BISON_FLAGS, AT_CHECK_BISON_PERCENT): | |
8791 | (AT_CHECK_BISON_PERCENT_FLAGS): Merge into... | |
8792 | (AT_CHECK_OUTPUT): this. | |
8793 | Merely check ls' exit status, its output is useless. | |
8794 | ||
8795 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
8796 | ||
8797 | * tests/calc.at: Use m4_match. | |
8798 | (_AT_DATA_CALC_Y): Check `yyin != NULL', not `stdin != NULL'. | |
8799 | ||
8800 | 2001-09-10 Marc Autret <autret_m@epita.fr>, | |
8801 | Akim Demaille <akim@epita.fr> | |
8802 | ||
8803 | * src/vcg.h (graph_s): color, textcolor, bordercolor are now | |
8804 | enum color_e. | |
8805 | * src/print_graph.c (print_graph): Initalize graph.layoutalgorithm | |
8806 | to `normal'. | |
8807 | * src/reader.c (parse_token_decl): Initialize token with tok_eof. | |
8808 | * src/lex.h: Adjust prototype. | |
8809 | (token_t): Add `tok_undef'. | |
8810 | * src/lex.c (struct percent_table_struct): Retval is now a token_t. | |
8811 | (parse_percent_token): Now returns token_t. | |
8812 | Add default statement in switch. | |
8813 | (lex): Separate `c' as an input variable, from the token_t result | |
8814 | part. | |
8815 | (unlexed): Is a token_t. | |
8816 | ||
8817 | 2001-09-10 Akim Demaille <akim@epita.fr> | |
8818 | ||
8819 | * configure.in: Bump to 1.29a. | |
8820 | ||
8821 | 2001-09-07 Akim Demaille <akim@epita.fr> | |
8822 | ||
8823 | Version 1.29. | |
8824 | ||
8825 | 2001-08-30 Akim Demaille <akim@epita.fr> | |
8826 | ||
8827 | * tests/atgeneral.m4, tests/atconfig.in, tests/suite.at: Remove. | |
8828 | * m4/atconfig.m4: Remove. | |
8829 | * tests/testsuite.at, tests/atlocal.in, tests/output.at, | |
8830 | * tests/bison: New. | |
8831 | * tests/regression.at, tests/calc.at: Use m4_define, AT_BANNER, | |
8832 | m4_if, m4_patsubst, and m4_regexp. | |
8833 | * tests/calc.at (_AT_CHECK_CALC, _AT_CHECK_CALC_ERROR): Use an | |
8834 | `input' file instead of echo. | |
8835 | ||
8836 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
8837 | ||
8838 | Bump to 1.28e. | |
8839 | ||
8840 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
8841 | ||
8842 | Version 1.28d. | |
8843 | ||
8844 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
8845 | ||
8846 | * src/bison.simple (yyparse): Don't take the address of an | |
8847 | item before the start of an array, as that doesn't conform to | |
8848 | the C Standard. | |
8849 | ||
8850 | 2001-08-29 Robert Anisko <anisko_r@epita.fr> | |
8851 | ||
8852 | * doc/bison.texinfo (Location Tracking Calc): New node. | |
8853 | ||
8854 | 2001-08-29 Paul Eggert <eggert@twinsun.com> | |
8855 | ||
8856 | * src/output.c (output): Do not define const, as this now | |
8857 | causes more problems than it cures. | |
8858 | ||
8859 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
8860 | ||
8861 | * doc/bison.texinfo: Modernize `@node' and `@top' use: just name | |
8862 | the nodes. | |
8863 | Be sure to tag the `detailmenu'. | |
8864 | ||
8865 | 2001-08-29 Akim Demaille <akim@epita.fr> | |
8866 | ||
8867 | * Makefile.maint (do-po-update): Wget refuses to overwrite files: | |
8868 | download in a tmp dir. | |
8869 | ||
8870 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
8871 | ||
8872 | * config/depcomp: New file. | |
8873 | ||
8874 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
8875 | ||
8876 | * doc/bison.1 (mandoc): Adjust. | |
8877 | From Juan Manuel Guerrero. | |
8878 | ||
8879 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
8880 | ||
8881 | * src/print_graph.c (print_state): Fix. | |
8882 | ||
8883 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
8884 | ||
8885 | * src/vcg.h (classname_s, infoname_s, node_s): Constify the | |
8886 | char * members. | |
8887 | Echo modifications to the functions prototypes. | |
8888 | * src/vcg.c (add_classname, add_infoname): Adjust arguments. | |
8889 | ||
8890 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
8891 | ||
8892 | * src/vcg.c: Include `xalloc.h'. | |
8893 | (add_colorentry): New. | |
8894 | (add_classname): New. | |
8895 | (add_infoname): New. | |
8896 | * src/vcg.h: Add new prototypes. | |
8897 | ||
8898 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
8899 | ||
8900 | * Makefile.maint: Sync. again with CVS Autoconf. | |
8901 | ||
8902 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
8903 | ||
8904 | * Makefile.maint: Formatting changes. | |
8905 | (po-update, cvs-update, update): New targets. | |
8906 | (AMTAR): Remove. | |
8907 | ||
8908 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
8909 | ||
8910 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
8911 | * Makefile.maint: Sync. with CVS Autoconf. | |
8912 | ||
8913 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
8914 | ||
8915 | * src/vcg.h (struct infoname_s): New. | |
8916 | (struct colorentry_s): New. | |
8917 | (graph_s): New fields {vertical,horizontal}_order in structure. | |
8918 | Add `infoname' field. | |
8919 | Add `colorentry' field; | |
8920 | * src/vcg_defaults.h (G_VERTICAL_ORDER): New. | |
8921 | (G_HORIZONTAL_ORDER): New. | |
8922 | (G_INFONAME): New. | |
8923 | (G_COLORENTRY): New. | |
8924 | * src/vcg.c (output_graph): Add output of {vertical,horizontal}_order. | |
8925 | Add output of `infoname'. | |
8926 | Add output of `colorentry'. | |
8927 | ||
8928 | 2001-08-27 Marc Autret <autret_m@epita.fr> | |
8929 | ||
8930 | * src/reader.c (parse_dquoted_param): Rename variable `index' to `i'. | |
8931 | This one shadowed a global parameter. | |
8932 | ||
8933 | 2001-08-24 Marc Autret <autret_m@epita.fr> | |
8934 | ||
8935 | * src/print_graph.c (node_output_size): Declared POSIX `size_t' type, | |
8936 | instead of `unsigned'. | |
8937 | (print_state): Do not call obstack_object_size () in obstack_grow () | |
8938 | to avoid macro variables shadowing. | |
8939 | ||
8940 | 2001-08-23 Marc Autret <autret_m@epita.fr> | |
8941 | ||
8942 | * src/lex.c (percent_table): Typo: s/naem/name/. | |
8943 | Add graph option. | |
8944 | Normalize new options declarations. | |
8945 | ||
8946 | 2001-08-20 Pascal Bart <pascal.bart@epita.fr> | |
8947 | ||
8948 | * tests/suite.at: Exercise %header_extension and %source_extension. | |
8949 | ||
8950 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
8951 | ||
8952 | * src/reader.c (parse_dquoted_param): New. | |
8953 | (parse_header_extension_decl): Use it. | |
8954 | (parse_source_extension_decl): Likewise. | |
8955 | ||
8956 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
8957 | ||
8958 | * src/vcg.c: Remove includes of `complain.h' and `xalloc.h'. | |
8959 | (get_xxxx_str): Use assert () instead of complain (). | |
8960 | Remove return invokations in default cases. | |
8961 | (get_decision_str): Modify default behaviour. Remove second argument. | |
8962 | Echo modifications on calls. | |
8963 | (output_graph): Fix. | |
8964 | ||
8965 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
8966 | ||
8967 | * src/getargs.c (usage): Update with ``-g, --graph''. | |
8968 | ||
8969 | 2001-08-16 Marc Autret <autret_m@epita.fr> | |
8970 | ||
8971 | * doc/bison.texinfo (Bison Options): Add items `-g', `--graph'. | |
8972 | (Option Cross Key): Likewise. | |
8973 | * doc/bison.1: Update. | |
8974 | ||
8975 | 2001-09-25 Pascal Bart <pascal.bart@epita.fr> | |
8976 | ||
8977 | * src/output.c (output_master_parser): Don't finish action_obstack. | |
8978 | (output_parser): Don't care about the muscle action, here. | |
8979 | (prepare): Copy the action_obstack in the action muscle. | |
8980 | (output): Free action_obstack. | |
8981 | ||
8982 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> | |
8983 | ||
8984 | * src/reader.c (parse_union_decl): Add new obstack union_obstack. Which | |
8985 | will contain `%union' declaration. | |
8986 | (parse_union_decl): Delete #line directive output. | |
8987 | (parse_union_decl): Substitute /attrs_obstack/union_obstack for all | |
8988 | informations about %union. | |
8989 | (parse_union_decl): Copy the union_obstack in the muscle stype. | |
8990 | * src/bison.simple: Add new #line directive. | |
8991 | Add typdef %%stype YYSTYPE. | |
8992 | ||
8993 | 2001-09-23 Pascal Bart <pascal.bart@epita.fr> | |
8994 | ||
8995 | * src/bison.simple: Add new `#line' directive. | |
8996 | ||
8997 | 2001-09-22 Pascal Bart <pascal.bart@epita.fr> | |
8998 | ||
8999 | * src/bison.simple: New `#line' directive. | |
9000 | * src/output.c (output_parser): Support new dynamic muscle input_line. | |
9001 | ||
9002 | 2001-09-22 Marc Autret <autret_m@epita.fr> | |
9003 | ||
9004 | * src/output.c (output_master_parser): New. | |
9005 | (output_parser): Be more re-entrant. | |
9006 | ||
9007 | 2001-09-21 Marc Autret <autret_m@epita.fr> | |
9008 | ||
9009 | * src/reader.c (copy_definition, parse_union_decl): Update and use | |
9010 | `linef' muscle. | |
9011 | (copy_action): Likewise. | |
9012 | Use obstack_1grow (). | |
9013 | * src/muscle_tab.c (muscle_init): Add muscle `linef'. | |
9014 | ||
9015 | 2001-09-21 Marc Autret <autret_m@epita.fr> | |
9016 | ||
9017 | * src/options.c (option_table): Adjust. | |
9018 | * src/lex.c (parse_percent_token): Fix. | |
9019 | ||
9020 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> | |
9021 | ||
9022 | * src/options.c (symtab.h): Include it, need by lex.h. | |
9023 | ||
9024 | 2001-09-20 Pascal Bart <pascal.bart@epita.fr> | |
9025 | ||
9026 | * src/lex.c (parse_percent_token): Change type of variable `tx', which | |
9027 | is now an option_table_struct*. | |
9028 | (option_strcmp): New function option_strcmp. | |
9029 | (parse_percent_token): Call option_strcmp. | |
9030 | * src/getargs.c (xalloc.h, options.h): Include it. | |
9031 | (getargs): Call create_long_option_table. | |
9032 | (getargs): Free longopts at the end of the function. | |
9033 | (shortopts): Move in options.c. | |
9034 | * src/options.c (create_long_option_table): New function. Convert | |
9035 | information from option_table to option structure. | |
9036 | * src/reader.c (options.h): Include it. | |
9037 | ||
9038 | * src/Makefile.am: Adjust. | |
9039 | * src/options.c (option_table): Create from longopts and percent_table. | |
9040 | * src/getargs.c (longopts): Delete. | |
9041 | * src/lex.c (struct percent_table_struct): Delete. | |
9042 | (percent_table): Delete. | |
9043 | (options.h): Include it. | |
9044 | * src/options.c: Create. | |
9045 | * src/options.h: Create. | |
9046 | Declare enum opt_access_e. | |
9047 | Define struct option_table_struct. | |
9048 | ||
9049 | 2001-09-20 Marc Autret <autret_m@epita.fr> | |
9050 | ||
9051 | * doc/bison.texinfo: Adjust terminologies about prologue and epilogue | |
9052 | sections of Bison. | |
9053 | ||
9054 | 2001-09-19 Pascal Bart <pascal.bart@epita.fr> | |
9055 | ||
9056 | * src/bison.simple: s/%%filename/%%skeleton. | |
9057 | * src/muscle_tab.c (getargs.h): Include it. | |
9058 | (muscle_init): Insert new muscle skeleton. | |
9059 | ||
9060 | 2001-09-18 Pascal Bart <pascal.bart@epita.fr> | |
9061 | ||
9062 | * src/output.c (output_parser): Delete unused variable actions_dumped. | |
9063 | ||
9064 | 2001-09-07 Pascal Bart <pascal.bart@epita.fr> | |
9065 | ||
9066 | * src/output.c (output): Delete call to reader_output_yylsp. | |
9067 | * src/reader.c (reader): Likewise. | |
9068 | * src/reader.h: Delete declaration of reader_output_yylsp. | |
9069 | ||
9070 | 2001-09-02 Marc Autret <autret_m@epita.fr> | |
9071 | ||
9072 | * src/reader.c: Include muscle_tab.h. | |
9073 | (parse_union_decl): Update. | |
9074 | (parse_macro_decl): Rename parse_muscle_decl. | |
9075 | Update to use renamed functions and variable. | |
9076 | (read_declarations, copy_action, read_additionnal_code, : Updated | |
9077 | with correct variables and functions names. | |
9078 | (packsymbols, reader): Likewise. | |
9079 | ||
9080 | * src/reader.h (muscle_obstack): Extern declaration update. | |
9081 | ||
9082 | * src/output.c: Include muscle_tab.h | |
9083 | In all functions using macro_insert, change by using muscle_insert (). | |
9084 | (macro_obstack): Rename muscle_obstack. | |
9085 | Echo modifications in the whole file. | |
9086 | (MACRO_INSERT_INT): Rename MUSCLE_INSERT_INT. | |
9087 | (MACRO_INSERT_STRING): Rename MUSCLE_INSERT_STRING. | |
9088 | (MACRO_INSERT_PREFIX): Rename MUSCLE_INSERT_PREFIX. | |
9089 | ||
9090 | * src/muscle_tab.h: Update double inclusion macros. | |
9091 | (macro_entry_s): Rename muscle_entry_s. | |
9092 | Update prototypes. | |
9093 | ||
9094 | * src/muscle_tab.c: Include muscle_tab.h. | |
9095 | Rename macro_tabble to muscle_table. | |
9096 | (mhash1, mhash2, mcmp): Use muscle_entry. | |
9097 | (macro_init): Rename muscle_init. Update. | |
9098 | (macro_insert): Rename muscle_insert. Update. | |
9099 | (macro_find): Rename muscle_find. Update. | |
9100 | ||
9101 | * src/main.c: Include muscle_tab.h. | |
9102 | (main): Call muscle_init (). | |
9103 | * src/Makefile.am (bison_SOURCES): Echo modifications. | |
9104 | ||
9105 | 2001-09-02 Marc Autret <autret_m@epita.fr> | |
9106 | ||
9107 | Now the files macro_tab.[ch] are named muscle_tab.[ch]. | |
9108 | ||
9109 | * src/muscle_tab.c, src/muscle_tab.h: Add files. | |
9110 | ||
9111 | 2001-09-02 Marc Autret <autret_m@epita.fr> | |
9112 | ||
9113 | * src/macrotab.c, src/macrotab.h: Remove. | |
9114 | ||
9115 | 2001-09-01 Pascal Bart <pascal.bart@epita.fr> | |
9116 | ||
9117 | * src/reader.c (copy_guard): Use muscle to specify the `#line' | |
9118 | filename. | |
9119 | ||
9120 | 2001-09-01 Marc Autret <autret_m@epita.fr> | |
9121 | ||
9122 | * tests/calc.at (exp): Now, YYERROR_VERBOSE need to be set | |
9123 | to an explicit value to activate the feature. We do it here. | |
9124 | ||
9125 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> | |
9126 | ||
9127 | * src/output.c (prepare): Delete the `filename' muscule insertion. | |
9128 | * src/reader.c (copy_action): Use `filename' muscule with `#line'. | |
9129 | (parse_union_decl): Likewise. | |
9130 | * src/macrotab.c (macro_init): Initialize filename by infile. | |
9131 | ||
9132 | 2001-08-31 Marc Autret <autret_m@epita.fr> | |
9133 | ||
9134 | * src/bison.simple (YYLSP_NEEDED): New definition. | |
9135 | * src/output.c (prepare): Add macro insertion of `locations_flag' | |
9136 | ||
9137 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> | |
9138 | ||
9139 | * src/output.c (prepare): Delete insertion of previous muscles, | |
9140 | and insert the `prefix' muscles. | |
9141 | * src/macrotab.c (macro_init): Likewise. | |
9142 | (macro_init): Initialization prefix directive by `yy'. | |
9143 | * src/bison.simple: Substitute all %%yylex, %%yychar, %%yylval, | |
9144 | %%yydebug, %%yyerror, %%yynerrs and %%yyparse by yylex, yychar, | |
9145 | yylval, yydebug, yyerror, yynerrs and yyparse. | |
9146 | New directive `#define' to substitute yydebug, ... with option | |
9147 | name_prefix. | |
9148 | ||
9149 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> | |
9150 | ||
9151 | * src/main.c (main): Standardize. | |
9152 | * src/output.c (output_table_data, output_parser): Likewise. | |
9153 | * src/macrotab.h, src/macrotab.c, src/bison.simple: Likewise. | |
9154 | ||
9155 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr>, Marc Autret <autret_m@epita.fr> | |
9156 | ||
9157 | * src/reader.c (read_additionnal_code): Rename %%user_code to | |
9158 | %%epilogue. | |
9159 | * src/output.c (output): Rename %%declarations to %%prologue. | |
9160 | * src/bison.simple: Echo modifications. | |
9161 | ||
9162 | 2001-08-31 Marc Autret <autret_m@epita.fr> | |
9163 | ||
9164 | * src/reader.c (readgram): CleanUp. | |
9165 | (output_token_defines): Likewise. | |
9166 | (packsymbols): Likewise. | |
9167 | (reader): Likewise. | |
9168 | * src/output.c (output): CPP-out useless code. | |
9169 | ||
9170 | 2001-08-31 Pascal Bart <pascal.bart@epita.fr> | |
9171 | ||
9172 | * src/reader.c (reader): Delete obsolete call to function | |
9173 | output_trailers and output_headers. | |
9174 | * src/output.h: Remove obsolete functions prototypes of output_headers | |
9175 | and output_trailers. | |
9176 | ||
9177 | 2001-08-30 Pascal Bart <pascal.bart@epita.fr> | |
9178 | ||
9179 | * src/main.c: Include macrotab.h. | |
9180 | * src/macrotab.h (macro_entry_s): Constify fields. | |
9181 | Adjust functions prototypes. | |
9182 | * src/macrotab.c (macro_insert): Constify key and value. | |
9183 | (macro_find): Constify key. | |
9184 | (macro_insert): Include 'xalloc.h' | |
9185 | (macro_insert): Use XMALLOC. | |
9186 | (macro_find): Constify return value. | |
9187 | * src/output.c (output_table_data): Rename table to table_data. | |
9188 | (output_parser): Constify macro_key, macro_value. | |
9189 | ||
9190 | 2001-08-30 Marc Autret <autret_m@epita.fr> | |
9191 | ||
9192 | * src/reader.c (parse_skel_decl): New. | |
9193 | (read_declarations): Add case `tok_skel', call parse_skel_decl (). | |
9194 | * src/lex.h (token_t): New token `tok_skel'. | |
9195 | * src/lex.c (percent_table): Add skeleton option entry. | |
9196 | Standardize. | |
9197 | ||
9198 | 2001-08-29 Marc Autret <autret_m@epita.fr> | |
9199 | ||
9200 | * src/bison.simple: Add %%user_code directive at the end. | |
9201 | * src/reader.c (read_additionnal_code): New. | |
9202 | (reader): Use it. | |
9203 | * src/output.c (output_program): Remove. | |
9204 | (output): Update. | |
9205 | ||
9206 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
9207 | ||
9208 | * src/output.c (output_actions): Clean up. | |
9209 | (output_gram): CPP-out useless code. | |
9210 | * src/reader.c (reader): Clean up, CPP-out useless code. | |
9211 | ||
9212 | 2001-08-28 Pascal Bart <pascal.bart@epita.fr> | |
9213 | ||
9214 | * src/output.c (output): Copy attrs_obstack in the '%%definitions' | |
9215 | directive. | |
9216 | * src/bison.simple: Add `%%definitions'. | |
9217 | ||
9218 | 2001-08-28 Marc Autret <autret_m@epita.fr> | |
9219 | ||
9220 | * config/depcomp: New file. | |
9221 | ||
9222 | 2001-08-27 Paul Eggert <eggert@twinsun.com> | |
9223 | ||
9224 | * src/bison.simple (yyparse): Don't take the address of an | |
9225 | item before the start of an array, as that doesn't conform to | |
9226 | the C Standard. | |
9227 | ||
9228 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> | |
9229 | ||
9230 | * src/output.c (output): Remove the initialization of the macro | |
9231 | obstack. It was done too late here. | |
9232 | ||
9233 | * src/reader.c (parse_macro_decl): Fix. Use of the macro obstack was | |
9234 | completely wrong. | |
9235 | (reader): Initialize the macro obstack here, since we need it to grow | |
9236 | '%define' directives. | |
9237 | ||
9238 | * src/reader.h: Declare the macro obstack as extern. | |
9239 | ||
9240 | 2001-08-27 Robert Anisko <robert.anisko@epita.fr> | |
9241 | ||
9242 | * src/output.c (output_parser): Fix. Store single '%' characters in | |
9243 | the output obstack instead of throwing them away. | |
9244 | ||
9245 | 2001-08-27 Akim Demaille <akim@epita.fr> | |
9246 | ||
9247 | * Makefile.am (AUTOMAKE_OPTIONS): 1.5. | |
9248 | ||
9249 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9250 | ||
9251 | * lib/Makefile.am: Adjust. | |
9252 | ||
9253 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9254 | ||
9255 | * src/bison.simple: Update and add '%%' directives. | |
9256 | ||
9257 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9258 | ||
9259 | * src/reader.c (reader): Remove calls to 'output_headers' and | |
9260 | 'output_trailers'. Remove some C output. | |
9261 | (readgram): Disable a piece of code that was writing a default | |
9262 | definition for 'YYSTYPE'. | |
9263 | (reader_output_yylsp): Remove. | |
9264 | (packsymbols): Output token defintions to a macro. | |
9265 | (copy_definition): Disable C output. | |
9266 | ||
9267 | * src/reader.c (parse_macro_decl): New function used to parse macro | |
9268 | declarations. | |
9269 | (copy_string2): Put the body of copy_string into this new function. | |
9270 | Add a parameter to let the caller choose whether he wants to copy the | |
9271 | string delimiters or not. | |
9272 | (copy_string): Be a simple call to copy_string2 with the last argument | |
9273 | bound to true. | |
9274 | (read_declarations): Add case for macro definition. | |
9275 | (copy_identifier): New. | |
9276 | (parse_macro_decl): Read macro identifiers using copy_identifier | |
9277 | rather than lex. | |
9278 | ||
9279 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9280 | ||
9281 | * src/output.c (prepare): Add prefixed names. | |
9282 | (output_parser): Output semantic actions. | |
9283 | (output_parser): Fix bug on '%%line' directives. | |
9284 | ||
9285 | * src/output.c (output_headers): Remove. The C code printed by this | |
9286 | function should now be in the skeletons. | |
9287 | (output_trailers): Remove. | |
9288 | (output): Disable call to 'reader_output_yylsp'. | |
9289 | (output_rule_data): Do not output tables to the table obstack. | |
9290 | ||
9291 | * src/output.c: Remove some C dedicated output. | |
9292 | Improve the use of macro and output obstacks. | |
9293 | (output_defines): Remove. | |
9294 | ||
9295 | * src/output.c (output_token_translations): Associate 'translate' | |
9296 | table with a macro. No output to the table obstack. | |
9297 | (output_gram): Same for 'rhs' and 'prhs'. | |
9298 | (output_stos): Same for 'stos'. | |
9299 | (output_rule_data): Same for 'r1' and 'r2'. | |
9300 | (token_actions): Same for 'defact'. | |
9301 | (goto_actions): Same for 'defgoto'. | |
9302 | (output_base): Same for 'pact' and 'pgoto'. | |
9303 | (output_table): Same for 'table'. | |
9304 | (output_check): Same for 'check'. | |
9305 | ||
9306 | * src/output.c (output_table_data): New function. | |
9307 | (output_short_table): Remove. | |
9308 | (output_short_or_char_table): Remove. | |
9309 | ||
9310 | * src/output.c (output_parser): Replace most of the skeleton copy code | |
9311 | with something new. Skeletons are now processed character by character | |
9312 | rather than line by line, and Bison looks for '%%' macros. This is the | |
9313 | first step in making Bison's output process (a lot) more flexible. | |
9314 | (output_parser): Use the macro table. | |
9315 | ||
9316 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9317 | ||
9318 | * src/main.c (main): Initialize the macro table. | |
9319 | ||
9320 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9321 | ||
9322 | * src/lex.c (percent_table): Add tok_define. | |
9323 | * src/lex.h: Add tok_define. | |
9324 | ||
9325 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9326 | ||
9327 | * src/macrotab.c: New file. | |
9328 | * src/macrotab.h: New file. | |
9329 | * src/Makefile.am: Update. | |
9330 | ||
9331 | 2001-08-25 Robert Anisko <robert.anisko@epita.fr> | |
9332 | ||
9333 | * lib/hash.c: New file. | |
9334 | * lib/hash.h: New file. | |
9335 | * lib/Makefile.am: Update. | |
9336 | ||
9337 | 2001-08-15 Akim Demaille <akim@epita.fr> | |
9338 | ||
9339 | Version 1.28c. | |
9340 | ||
9341 | 2001-08-15 Marc Autret <autret_m@epita.fr> | |
9342 | ||
9343 | * src/reader.c (readgram): Indent output macro YYSTYPE. | |
9344 | (packsymbols): Likewise. | |
9345 | (output_token_defines): Likewise. | |
9346 | * src/files.c: Standardize. | |
9347 | (compute_header_macro): New. | |
9348 | (defines_obstack_save): New. Use compute_header_macro. | |
9349 | (output_files): Update. Use defines_obstack_save. | |
9350 | ||
9351 | 2001-08-15 Akim Demaille <akim@epita.fr> | |
9352 | ||
9353 | * doc/bison.texinfo (Table of Symbols): Document | |
9354 | YYSTACK_USE_ALLOCA. | |
9355 | ||
9356 | 2001-08-15 Akim Demaille <akim@epita.fr> | |
9357 | ||
9358 | * missing: Update from CVS Automake. | |
9359 | * config/config.guess, config/config.sub, config/texinfo.tex: | |
9360 | Update from gnu.org. | |
9361 | ||
9362 | 2001-08-15 Akim Demaille <akim@epita.fr> | |
9363 | ||
9364 | * Makefile.maint: Sync with CVS Autoconf. | |
9365 | ||
9366 | 2001-08-14 Pascal Bart <pascal.bart@epita.fr> | |
9367 | ||
9368 | * doc/bison.texinfo: Include GNU Free Documentation License from | |
9369 | `fdl.texi'. | |
9370 | * doc/fdl.texi: Add to package. | |
9371 | ||
9372 | 2001-08-14 Marc Autret <autret_m@epita.fr> | |
9373 | ||
9374 | Turn on %{source,header}_extension features. | |
9375 | ||
9376 | * src/lex.c (percent_table): Un-CPP out header_extension and | |
9377 | source_extension. | |
9378 | * src/files.c (compute_exts_from_gf): Compare pointers with NULL. | |
9379 | (compute_exts_from_src): Remove conditions. It restores priorities | |
9380 | between options. | |
9381 | ||
9382 | 2001-08-14 Marc Autret <autret_m@epita.fr> | |
9383 | ||
9384 | * src/files.c (compute_base_names): Add extensions computing when | |
9385 | `--file-prefix' used. | |
9386 | Standardize function calls. | |
9387 | ||
9388 | 2001-08-13 Marc Autret <autret_m@epita.fr> | |
9389 | ||
9390 | * src/bison.simple (YYSTACK_USE_ALLOCA): Changed to allow users | |
9391 | defining it (defined but null disables alloca). | |
9392 | ||
9393 | 2001-08-13 Marc Autret <autret_m@epita.fr> | |
9394 | ||
9395 | * src/bison.simple (_yy_memcpy): CPP reformat. | |
9396 | ||
9397 | 2001-08-13 Pascal Bart <pascal.bart@epita.fr> | |
9398 | ||
9399 | * tests/atconfig.in (CPPFLAGS): Fix. | |
9400 | ||
9401 | 2001-08-10 Pascal Bart <pascal.bart@epita.fr> | |
9402 | ||
9403 | * doc/bison.texinfo: Include GNU General Public License from | |
9404 | `gpl.texi'. | |
9405 | * doc/gpl.texi: Add to package. | |
9406 | ||
9407 | 2001-08-10 Marc Autret <autret_m@epita.fr> | |
9408 | ||
9409 | * src/print_graph.h: Fix. | |
9410 | * src/reader.c (read_declarations): Use parse_header_extension_decl (). | |
9411 | ||
9412 | 2001-08-10 Akim Demaille <akim@epita.fr> | |
9413 | ||
9414 | * src/system.h: Provide default declarations for stpcpy, strndup, | |
9415 | and strnlen. | |
9416 | ||
9417 | 2001-08-10 Robert Anisko <anisko_r@epita.fr> | |
9418 | ||
9419 | * doc/bison.texinfo (Locations): Update @$ stuff. | |
9420 | ||
9421 | 2001-08-09 Robert Anisko <anisko_r@epita.fr> | |
9422 | ||
9423 | * src/bison.simple (YYLLOC_DEFAULT): Update. | |
9424 | (yyparse): Adjust. | |
9425 | ||
9426 | 2001-08-08 Marc Autret <autret_m@epita.fr> | |
9427 | ||
9428 | * doc/bison.texinfo: Change @samp{$<@dots{}>} to | |
9429 | @samp{$<@dots{}>@var{n}} in Section Actions in Mid-Rule. | |
9430 | Reported by Fabrice Bauzac. | |
9431 | ||
9432 | 2001-08-08 Marc Autret <autret_m@epita.fr> | |
9433 | ||
9434 | * src/vcg_default.h: Use NULL instead of 0 to initialize pointers. | |
9435 | * src/vcg.c (output_node): Fix. | |
9436 | * src/vcg.h: Cleanup. | |
9437 | * src/print_graph.c: Add comments. | |
9438 | (node_output_size): New global variable. Simplify the formatting of | |
9439 | the VCG graph output. | |
9440 | (print_actions): Unused code is now used. It notifies the final state | |
9441 | and no action states in the VCG graph. It also give the reduce actions. | |
9442 | The `shift and goto' edges are red and the `go to state' edges are | |
9443 | blue. | |
9444 | Get the current node name and node_obstack by argument. | |
9445 | (node_obstack): New variable. | |
9446 | (print_state): Manage node_obstack. | |
9447 | (print_core): Use node_obstack given by argument. | |
9448 | A node is not only computed here but in print_actions also. | |
9449 | (print_graph): CPP out useless code instead of commenting it. | |
9450 | ||
9451 | 2001-08-07 Pascal Bart <pascal.bart@epita.fr> | |
9452 | ||
9453 | * tests/atconfig.in (CPPFLAGS): Fix. | |
9454 | ||
9455 | 2001-08-07 Akim Demaille <akim@epita.fr> | |
9456 | ||
9457 | * src/print_graph.c (quote): New. | |
9458 | (print_core): Use it. | |
9459 | ||
9460 | 2001-08-06 Akim Demaille <akim@epita.fr>, Marc Autret <autret_m@epita.fr> | |
9461 | ||
9462 | * src/vcg.c (complain.h): Include it. | |
9463 | Unepitaize `return' invocations. | |
9464 | [NDEBUG] (main): Remove. | |
9465 | * src/vcg.h (node_t, edge_t, graph_t): Constify the char * members. | |
9466 | * src/files.c (open_files): Initialize graph_obstack. | |
9467 | * src/print_graph.c (print_actions): CPP out useless code. | |
9468 | (print_core): Don't output the last `\n' in labels. | |
9469 | Use `quote'. | |
9470 | * src/files.c (output_files): Output the VCG file. | |
9471 | * src/main.c (main): Invoke print_graph (); | |
9472 | ||
9473 | 2001-08-06 Marc Autret <autret_m@epita.fr> | |
9474 | ||
9475 | Automaton VCG graph output. | |
9476 | Using option ``-g'' or long option ``--graph'', you can generate | |
9477 | a gram_filename.vcg file containing a VCG description of the LALR (1) | |
9478 | automaton of your grammar. | |
9479 | ||
9480 | * src/main.c: Call to print_graph() function. | |
9481 | * src/getargs.h: Update. | |
9482 | * src/getargs.c (options): Update to catch `-g' and `--graph' options. | |
9483 | (graph_flag): New flag. | |
9484 | (longopts): Update. | |
9485 | (getargs): Add case `g'. | |
9486 | * src/files.c (graph_obstack): New obstack struct. | |
9487 | (open_files): Initialize new obstack. | |
9488 | (output_files): Saves graph_obstack if required. | |
9489 | * src/files.h (graph_obstack): New extern declaration. | |
9490 | * src/Makefile.am: Add new source files. | |
9491 | ||
9492 | 2001-08-06 Marc Autret <autret_m@epita.fr> | |
9493 | ||
9494 | * src/print_graph.c, src/print_graph.h (graph): New. | |
9495 | * src/vcg.h: New file. | |
9496 | * src/vcg.c: New file, VCG graph handling. | |
9497 | ||
9498 | 2001-08-06 Marc Autret <autret_m@epita.fr> | |
9499 | ||
9500 | Add of %source_extension and %header_extension which specify | |
9501 | the source or/and the header output file extension. | |
9502 | ||
9503 | * src/files.c (compute_base_names): Remove initialisation of | |
9504 | src_extension and header_extension. | |
9505 | (compute_exts_from_gf): Update. | |
9506 | (compute_exts_from_src): Update. | |
9507 | (output_files): Update. | |
9508 | * src/reader.c (parse_header_extension_decl): New. | |
9509 | (parse_source_extension_decl): New. | |
9510 | (read_declarations): New case statements for the new tokens. | |
9511 | * src/lex.c (percent_table): Add entries for %source_extension | |
9512 | and %header_extension. | |
9513 | * src/lex.h (token_e): New tokens tok_hdrext and tok_srcext. | |
9514 | ||
9515 | 2001-08-06 Marc Autret <autret_m@epita.fr> | |
9516 | ||
9517 | * configure.in: Bump to 1.28c. | |
9518 | * doc/bison.texinfo: Texinfo thingies. | |
9519 | ||
9520 | 2001-08-04 Pascal Bart <pascal.bart@epita.fr> | |
9521 | ||
9522 | * tests/atconfig.in (CPPFLAGS): Add. | |
9523 | * tests/calc.at (AT_CHECK): Use CPPFLAGS. | |
9524 | ||
9525 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9526 | ||
9527 | Version 1.28b. | |
9528 | ||
9529 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9530 | ||
9531 | * tests/Makefile.am (check-local): Ship testsuite. | |
9532 | * tests/calc.at (_AT_DATA_CALC_Y): Prototype all the functions. | |
9533 | Include `string.h'. | |
9534 | ||
9535 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9536 | ||
9537 | * configure.in: Try using -Wformat when compiling. | |
9538 | ||
9539 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9540 | ||
9541 | * configure.in: Bump to 1.28b. | |
9542 | ||
9543 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9544 | ||
9545 | * src/complain.c: Adjust strerror_r portability issues. | |
9546 | ||
9547 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9548 | ||
9549 | Version 1.28a. | |
9550 | ||
9551 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9552 | ||
9553 | * src/getargs.c, src/getarg.h (skeleton)): Constify. | |
9554 | * src/lex.c (literalchar): Avoid name clashes on `buf'. | |
9555 | * src/getargs.c: Include complain.h. | |
9556 | * src/files.c, src/files.h (skeleton_find): Avoid name clashes. | |
9557 | * lib/quotearg.c, lib/quotearg.h: Update from fileutils 4.1. | |
9558 | ||
9559 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9560 | ||
9561 | * src/reader.c (readgram): Display hidden chars in error messages. | |
9562 | ||
9563 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9564 | ||
9565 | Update to gettext 0.10.39. | |
9566 | ||
9567 | 2001-08-03 Akim Demaille <akim@epita.fr> | |
9568 | ||
9569 | * lib/strspn.c: New. | |
9570 | ||
9571 | 2001-08-01 Marc Autret <autret_m@epita.fr> | |
9572 | ||
9573 | * doc/bison.texinfo: Update. | |
9574 | * doc/bison.1 (mandoc): Update. | |
9575 | * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h. | |
9576 | * src/files.c: Support output files extensions computing. | |
9577 | (src_extension): New static variable. | |
9578 | (header_extension): New static variable. | |
9579 | (tr): New function. | |
9580 | (get_extension_index): New function, gets the index of an extension | |
9581 | filename in a string. | |
9582 | (compute_exts_from_gf): New function, computes extensions from the | |
9583 | grammar file extension. | |
9584 | (compute_exts_from_src): New functions, computes extensions from the | |
9585 | C source file extension, file given by ``-o'' option. | |
9586 | (compute_base_names): Update. | |
9587 | (output_files): Update. | |
9588 | ||
9589 | 2001-08-01 Robert Anisko <anisko_r@epita.fr> | |
9590 | ||
9591 | * doc/bison.texi: Document @$. | |
9592 | (Locations): New section. | |
9593 | ||
9594 | 2001-07-18 Akim Demaille <akim@epita.fr> | |
9595 | ||
9596 | * Makefile.maint, GNUmakefile: New, from Autoconf 2.52. | |
9597 | * config/prev-version.txt, config/move-if-change: New. | |
9598 | * Makefile.am: Adjust. | |
9599 | ||
9600 | 2001-07-08 Pascal Bart <pascal.bart@epita.fr> | |
9601 | ||
9602 | * src/bison.simple (yyparse): Suppress warning `comparaison | |
9603 | between signed and unsigned'. | |
9604 | ||
9605 | 2001-07-05 Pascal Bart <pascal.bart@epita.fr> | |
9606 | ||
9607 | * src/getargs.h (raw_flag): Remove. | |
9608 | * src/getargs.c: Die on `-r'/`--raw'. | |
9609 | * src/lex.c (parse_percent_token): Die on `%raw'. | |
9610 | * src/reader.c (output_token_defines): Suppress call to `raw_flag'. | |
9611 | * tests/calc.at: Suppress test with option `--raw'. | |
9612 | ||
9613 | 2001-07-14 Akim Demaille <akim@epita.fr> | |
9614 | ||
9615 | * config/: New. | |
9616 | * configure.in: Require Autoconf 2.50. | |
9617 | Update to gettext 0.10.38. | |
9618 | ||
9619 | 2001-03-16 Akim Demaille <akim@epita.fr> | |
9620 | ||
9621 | * doc/bison.texinfo: ANSIfy the examples. | |
9622 | ||
9623 | 2001-03-16 Akim Demaille <akim@epita.fr> | |
9624 | ||
9625 | * getargs.c (skeleton): New variable. | |
9626 | (longopts): --skeleton is a new option. | |
9627 | (shortopts, getargs): -S is a new option. | |
9628 | * getargs.h: Declare skeleton. | |
9629 | * output.c (output_parser): Use it. | |
9630 | ||
9631 | 2001-03-16 Akim Demaille <akim@epita.fr> | |
9632 | ||
9633 | * m4/strerror_r.m4: New. | |
9634 | * m4/error.m4: Run AC_FUNC_STRERROR_R. | |
9635 | * lib/error.h, lib/error.c: Update. | |
9636 | ||
9637 | 2001-03-16 Akim Demaille <akim@epita.fr> | |
9638 | ||
9639 | * src/getargs.c (longopts): Clean up. | |
9640 | ||
9641 | 2001-02-21 Akim Demaille <akim@epita.fr> | |
9642 | ||
9643 | * src/reader.c (gensym): `gensym_count' is your own. | |
9644 | Use a static buf to create the symbol name, as token_buffer is no | |
9645 | longer a buffer. | |
9646 | ||
9647 | 2001-02-08 Akim Demaille <akim@epita.fr> | |
9648 | ||
9649 | * src/conflicts.c (conflict_report): Be sure not to append to res | |
9650 | between two calls, which could happen if both first sprintf were | |
9651 | skipped, but not the first cp += strlen. | |
9652 | ||
9653 | 2001-02-08 Akim Demaille <akim@epita.fr> | |
9654 | ||
9655 | * lib/memchr.c, lib/stpcpy.c, lib/strndup.c, lib/strnlen.c: | |
9656 | New, from fileutils 4.0.37. | |
9657 | * configure.in: Require Autoconf 2.49c. I took some time before | |
9658 | making this decision. This is the only way out for portability | |
9659 | issues in Bison, it would mean way too much duplicate effort to | |
9660 | import in Bison features implemented in 2.49c since 2.13. | |
9661 | AC_REPLACE_FUNCS and AC_CHECK_DECLS the functions above. | |
9662 | ||
9663 | 2001-02-02 Akim Demaille <akim@epita.fr> | |
9664 | ||
9665 | * lib/malloc.c, lib/realloc.c: New, from the fileutils 4.0.37. | |
9666 | * lib/xalloc.h, lib/xmalloc.c: Update. | |
9667 | ||
9668 | 2001-01-19 Akim Demaille <akim@epita.fr> | |
9669 | ||
9670 | Get rid of the ad hoc handling of token_buffer in the scanner: use | |
9671 | the obstacks. | |
9672 | ||
9673 | * src/lex.c (token_obstack): New. | |
9674 | (init_lex): Initialize it. No longer call... | |
9675 | (grow_token_buffer): this. Remove it. | |
9676 | Adjust all the places which used it to use the obstack. | |
9677 | ||
9678 | 2001-01-19 Akim Demaille <akim@epita.fr> | |
9679 | ||
9680 | * src/lex.h: Rename all the tokens: | |
9681 | s/\bENDFILE\b/tok_eof/g; | |
9682 | s/\bIDENTIFIER\b/tok_identifier/g; | |
9683 | etc. | |
9684 | Let them be enums, not #define, to ease debugging. | |
9685 | Adjust all the code. | |
9686 | ||
9687 | 2001-01-18 Akim Demaille <akim@epita.fr> | |
9688 | ||
9689 | * src/lex.h (MAXTOKEN, maxtoken, grow_token_buffer): Remove, private. | |
9690 | * src/lex.c (maxtoken, grow_token_buffer): Static. | |
9691 | ||
9692 | 2001-01-18 Akim Demaille <akim@epita.fr> | |
9693 | ||
9694 | Since we now use obstacks, more % directives can be enabled. | |
9695 | ||
9696 | * src/lex.c (percent_table): Also accept `%yacc', | |
9697 | `%fixed_output_files', `%defines', `%no_parser', `%verbose', and | |
9698 | `%debug'. | |
9699 | Handle the actions for `%semantic_parser' and `%pure_parser' here, | |
9700 | instead of returning a token. | |
9701 | * src/lex.h (SEMANTIC_PARSER, PURE_PARSER): Remove, unused. | |
9702 | * src/reader.c (read_declarations): Adjust. | |
9703 | * src/files.c (open_files): Don't call `compute_base_names', don't | |
9704 | compute `attrsfile' since they depend upon data which might be | |
9705 | *in* the input file now. | |
9706 | (output_files): Do it here. | |
9707 | * src/output.c (output_headers): Document the fact that this patch | |
9708 | introduces a guaranteed SEGV for semantic parsers. | |
9709 | * doc/bison.texinfo: Document them. | |
9710 | * tests/suite.at: Exercise these %options. | |
9711 | ||
9712 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9713 | ||
9714 | Also handle the output file (--verbose) with obstacks. | |
9715 | ||
9716 | * files.c (foutput): Remove. | |
9717 | (output_obstack): New. | |
9718 | Adjust all dependencies. | |
9719 | * src/conflicts.c: Return a string. | |
9720 | * src/system.h (obstack_grow_string): Rename as... | |
9721 | (obstack_sgrow): this. Be ready to work with non literals. | |
9722 | (obstack_fgrow4): New. | |
9723 | ||
9724 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9725 | ||
9726 | * src/files.c (open_files): Fix the computation of short_base_name | |
9727 | in the case of `-o foo.tab.c'. | |
9728 | ||
9729 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9730 | ||
9731 | * src/reader.c (copy_string, copy_comment, copy_comment2, copy_at) | |
9732 | (copy_dollar): Now that everything uses obstacks, get rid of the | |
9733 | FILE * parameters. | |
9734 | ||
9735 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9736 | ||
9737 | * src/files.c (open_files): Actually the `.output' file is based | |
9738 | on the short_base_name, not base_name. | |
9739 | * tests/suite.at (Checking output file names): Adjust. | |
9740 | ||
9741 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9742 | ||
9743 | * src/bison.s1: Remove, we now use directly... | |
9744 | * src/bison.simple: this. | |
9745 | * src/Makefile.am: Use pkgdata instead of data. | |
9746 | ||
9747 | 2000-12-20 Akim Demaille <akim@epita.fr> | |
9748 | ||
9749 | * src/files.c (guard_obstack): New. | |
9750 | (open_files): Initialize it. | |
9751 | (output_files): Dump it... | |
9752 | * src/files.h: Export it. | |
9753 | * src/reader.c (copy_guard): Use it. | |
9754 | ||
9755 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9756 | ||
9757 | * src/files.c (outfile, defsfile, actfile): Removed as global | |
9758 | vars. | |
9759 | (open_files): Don't compute them. | |
9760 | (output_files): Adjust. | |
9761 | (base_name, short_base_name): Be global. | |
9762 | Adjust dependencies. | |
9763 | ||
9764 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9765 | ||
9766 | * src/files.c (strsuffix): New. | |
9767 | (stringappend): Be just like strcat but allocate. | |
9768 | (base_names): Eve out from open_files. | |
9769 | Try to simplify the rather hairy computation of base_name and | |
9770 | short_base_name. | |
9771 | (open_files): Use it. | |
9772 | * tests/suite.at (Checking output file names): New test. | |
9773 | ||
9774 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9775 | ||
9776 | * src/system.h (obstack_grow_literal_string): Rename as... | |
9777 | (obstack_grow_string): this. | |
9778 | * src/output.c (output_parser): Recognize `%% actions' instead of | |
9779 | `$'. | |
9780 | * src/bison.s1: s/$/%% actions/. | |
9781 | * src/bison.hairy: Likewise. | |
9782 | ||
9783 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9784 | ||
9785 | * src/output.c (output_parser): Compute the `#line' lines when | |
9786 | there are. | |
9787 | * src/Makefile.am (bison.simple): Be a simple copy of bison.s1. | |
9788 | Suggested by Hans Aberg. | |
9789 | ||
9790 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9791 | ||
9792 | Let the handling of the skeleton files be local to the procedures | |
9793 | that use it. | |
9794 | ||
9795 | * src/files.c (xfopen, xfclose, skeleton_find, guardfile): No | |
9796 | longer static. | |
9797 | (fparser, open_extra_files): Remove. | |
9798 | (open_files, output_files): Don't take care of fparser. | |
9799 | * src/files.h: Adjust. | |
9800 | * src/output.c (output_parser): Open and close the file to the | |
9801 | skeleton. | |
9802 | * src/reader.c (read_declarations): When %semantic_parser, open | |
9803 | fguard. | |
9804 | ||
9805 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9806 | ||
9807 | * src/file.h (BISON_SIMPLE, BISON_HAIRY): Move from here... | |
9808 | * src/system.h (BISON_SIMPLE, BISON_HAIRY): ... to here. | |
9809 | ||
9810 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9811 | ||
9812 | * src/files.c (open_files): Yipee! We no longer need all the code | |
9813 | looking for `/tmp' since we have no tmp file. | |
9814 | ||
9815 | 2000-12-19 Akim Demaille <akim@epita.fr> | |
9816 | ||
9817 | * src/system.h (EXT_TAB, EXT_OUTPUT, EXT_STYPE_H, EXT_GUARD_C): | |
9818 | New macros. | |
9819 | * src/files.c (open_files): Less dependency on MSDOS etc. | |
9820 | ||
9821 | 2000-12-14 Akim Demaille <akim@epita.fr> | |
9822 | ||
9823 | * src/bison.s1 (YYLLOC_DEFAULT): New macro. | |
9824 | Provide a default definition. | |
9825 | Use it when executing the default @ action. | |
9826 | * src/reader.c (reader_output_yylsp): No longer include | |
9827 | `timestamp' and `text' in the default YYLTYPE. | |
9828 | ||
9829 | 2000-12-12 Akim Demaille <akim@epita.fr> | |
9830 | ||
9831 | * src/reader.c (copy_definition, parse_union_decl, copy_action) | |
9832 | (copy_guard): Quote the file names. | |
9833 | Reported by Laurent Mascherpa. | |
9834 | ||
9835 | 2000-12-12 Akim Demaille <akim@epita.fr> | |
9836 | ||
9837 | * src/output.c (output_headers, output_program, output): Be sure | |
9838 | to escape special characters when outputting filenames. | |
9839 | (ACTSTR_PROLOGUE, ACTSTR_EPILOGUE): Remove. | |
9840 | (output_headers): Don't depend on them, Use ACTSTR. | |
9841 | ||
9842 | 2000-11-17 Akim Demaille <akim@epita.fr> | |
9843 | ||
9844 | * lib/obstack.h: Formatting changes. | |
9845 | (obstack_grow, obstack_grow0): Don't cast WHERE at all: it | |
9846 | prevents type checking. | |
9847 | (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't | |
9848 | cast the value to (void *): assigning a `foo *' to a `void *' | |
9849 | variable is valid. | |
9850 | (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int. | |
9851 | * src/reader.c (parse_union_decl): Typo: use obstack_1grow to | |
9852 | append characters. | |
9853 | ||
9854 | 2000-11-17 Akim Demaille <akim@epita.fr> | |
9855 | ||
9856 | * tests/Makefile.am (suite.m4, regression.m4, calc.m4): Rename | |
9857 | as... | |
9858 | (suite.m4, regression.m4, calc.m4): these. | |
9859 | * tests/atgeneral.m4: Update from CVS Autoconf. | |
9860 | ||
9861 | 2000-11-17 Akim Demaille <akim@epita.fr> | |
9862 | ||
9863 | * tests/regression.m4 (%union and --defines): New test, | |
9864 | demonstrating a current bug in the obstack implementation. | |
9865 | ||
9866 | 2000-11-17 Akim Demaille <akim@epita.fr> | |
9867 | ||
9868 | * src/bison.s1 (_YY_DECL_VARIABLES, YY_DECL_VARIABLES): New | |
9869 | macros. | |
9870 | Use them to declare the variables which are global or local to | |
9871 | `yyparse'. | |
9872 | ||
9873 | 2000-11-17 Akim Demaille <akim@epita.fr> | |
9874 | ||
9875 | * acconfig.h: Remove, no longer used. | |
9876 | ||
9877 | 2000-11-07 Akim Demaille <akim@epita.fr> | |
9878 | ||
9879 | * src: s/Copyright (C)/Copyright/g. | |
9880 | ||
9881 | 2000-11-07 Akim Demaille <akim@epita.fr> | |
9882 | ||
9883 | * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just | |
9884 | defining. | |
9885 | * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/. | |
9886 | ||
9887 | 2000-11-07 Akim Demaille <akim@epita.fr> | |
9888 | ||
9889 | * src/bison.s1 (YYLEX): Use #if instead of #ifdef. | |
9890 | Merge in a single CPP if/else. | |
9891 | ||
9892 | 2000-11-07 Akim Demaille <akim@epita.fr> | |
9893 | ||
9894 | * src/output.c (output): Remove useless variables. | |
9895 | * lib/obstack.c (obstack_grow, obstack_grow0): Rename the second | |
9896 | argument `data' for consistency with the prototypes. | |
9897 | Qualify it `const'. | |
9898 | (obstack_copy, obstack_copy0): Rename the second argument as | |
9899 | `address' for consistency. Qualify it `const'. | |
9900 | * lib/obstack.h (obstack_copy, obstack_copy0, obstack_grow) | |
9901 | (obstack_grow0, obstack_ptr_grow, obstack_ptr_grow_fast): Qualify | |
9902 | `const' their input argument (`data' or `address'). | |
9903 | Adjust the corresponding macros to include `const' in casts. | |
9904 | ||
9905 | 2000-11-03 Akim Demaille <akim@epita.fr> | |
9906 | ||
9907 | * src/Makefile.am (INCLUDES): s/PFILE/BISON_SIMPLE/. | |
9908 | s/PFILE1/BISON_HAIRY/. | |
9909 | Adjust dependencies. | |
9910 | ||
9911 | 2000-11-03 Akim Demaille <akim@epita.fr> | |
9912 | ||
9913 | For some reason, this was not applied. | |
9914 | ||
9915 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
9916 | `unlink': it's no longer used. | |
9917 | ||
9918 | 2000-11-03 Akim Demaille <akim@epita.fr> | |
9919 | ||
9920 | * src/files.c (skeleton_find): New function, eved out of... | |
9921 | (open_files, open_extra_files): here. | |
9922 | ||
9923 | 2000-11-03 Akim Demaille <akim@epita.fr> | |
9924 | ||
9925 | Don't use `atexit'. | |
9926 | ||
9927 | * src/files.c (obstack_save): New function. | |
9928 | (done): Rename as... | |
9929 | (output_files): this. | |
9930 | Use `obstack_save'. | |
9931 | * src/main.c (main): Don't use `atexit' to register `done', since | |
9932 | it no longer has to remove tmp files, just call `output_files' | |
9933 | when there are no errors. | |
9934 | ||
9935 | 2000-11-02 Akim Demaille <akim@epita.fr> | |
9936 | ||
9937 | * src/files.c [VMS]: No longer include `ssdef.h', no longer define | |
9938 | `unlink': it's no longer used. | |
9939 | * src/files.h: Formatting changes. | |
9940 | ||
9941 | 2000-11-02 Akim Demaille <akim@epita.fr> | |
9942 | ||
9943 | Remove the last uses of mktemp and unlink/delete. | |
9944 | ||
9945 | * src/files.c (fdefines, ftable): Removed. | |
9946 | (defines_ostack, table_obstack): New. | |
9947 | Adjust dependencies of the former into uses of the latter. | |
9948 | * src/output.c (output_short_or_char_table, output_short_table): | |
9949 | Convert to using obstacks. | |
9950 | * src/reader.c (copy_comment2): Accept one FILE * and two | |
9951 | obstacks. | |
9952 | (output_token_defines, reader_output_yylsp): Use obstacks. | |
9953 | * src/system.h (obstack_fgrow3): New. | |
9954 | ||
9955 | 2000-11-01 Akim Demaille <akim@epita.fr> | |
9956 | ||
9957 | Change each use of `fattrs' into a use of `attrs_obstack'. | |
9958 | ||
9959 | * src/reader.c (copy_at): Typo: s/yylloc/yyloc/. | |
9960 | * src/files.c (fattrs): Remove. | |
9961 | (attrs_obstack): New. | |
9962 | Adjust all dependencies. | |
9963 | (done): If SEMANTIC_PARSER, dump attrs_obstack into attrsfile. | |
9964 | ||
9965 | 2000-11-01 Akim Demaille <akim@epita.fr> | |
9966 | ||
9967 | Introduce obstacks. | |
9968 | Change each use of `faction' into a use of `action_obstack'. | |
9969 | ||
9970 | * lib/obstack.h, lib/obstack.c: New files. | |
9971 | * src/files.c (faction): Remove. | |
9972 | (action_obstack): New. | |
9973 | Adjust all dependencies. | |
9974 | ||
9975 | 2000-10-20 Akim Demaille <akim@epita.fr> | |
9976 | ||
9977 | * lib/quote.h (PARAMS): New macro. Use it. | |
9978 | ||
9979 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
9980 | ||
9981 | * src/output.c (output_short_or_char_table): New function. | |
9982 | (output_short_table, output_token_translations): Use it. | |
9983 | (goto_actions): Use output_short_table. | |
9984 | ||
9985 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
9986 | ||
9987 | * src/symtab.c (bucket_new): New function. | |
9988 | (getsym): Use it. | |
9989 | ||
9990 | * src/output.c (output_short_table): New argument to display the | |
9991 | comment associated with the table. | |
9992 | Adjust dependencies. | |
9993 | (output_gram): Use it. | |
9994 | (output_rule_data): Nicer output layout for YYTNAME. | |
9995 | ||
9996 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
9997 | ||
9998 | * src/lex.c (read_typename): New function. | |
9999 | (lex): Use it. | |
10000 | * src/reader.c (copy_dollar): Likewise. | |
10001 | ||
10002 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
10003 | ||
10004 | * src/reader.c (copy_comment2): Expect the input stream to be on | |
10005 | the `/' which is suspected to open a comment, instead of being | |
10006 | called after `//' or `/*' was read. | |
10007 | (copy_comment, copy_definition, parse_union_decl, copy_action) | |
10008 | (copy_guard): Adjust. | |
10009 | ||
10010 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
10011 | ||
10012 | * src/reader.c (parse_expect_decl): Use `skip_white_space' and | |
10013 | `read_signed_integer'. | |
10014 | ||
10015 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
10016 | ||
10017 | * src/reader.c (copy_dollar): New function. | |
10018 | (copy_guard, copy_action): Use it. | |
10019 | ||
10020 | 2000-10-16 Akim Demaille <akim@epita.fr> | |
10021 | ||
10022 | * lib/quote.h, lib/quote.c, lib/quotearg.h, lib/quotearg.c: | |
10023 | * m4/prereq.m4, m4/c-bs-a.m4, m4/mbstate.m4: | |
10024 | New files, from Fileutils 4.0.27. | |
10025 | * src/main.c (printable_version): Remove. | |
10026 | * src/lex.c, src/reader.c: Use `quote'. | |
10027 | ||
10028 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
10029 | ||
10030 | * lib/error.c, lib/error.h: New files, needed by xmalloc.c. | |
10031 | ||
10032 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
10033 | ||
10034 | * doc/bison.texinfo: Various typos spotted by Neil Booth. | |
10035 | ||
10036 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
10037 | ||
10038 | When a literal string is used to define two different tokens, | |
10039 | `bison -v' segfaults. | |
10040 | Reported by Piotr Gackiewicz, and fixed by Neil Booth. | |
10041 | ||
10042 | * tests/regression.m4: New file. | |
10043 | Include the core of the sample provided by Piotr Gackiewicz. | |
10044 | * src/reader.c (parse_token_decl): Diagnose bad cases, and proceed | |
10045 | properly. | |
10046 | ||
10047 | 2000-10-04 Akim Demaille <akim@epita.fr> | |
10048 | ||
10049 | * src/reader.c (parse_expect_decl): Keep `count' within the size | |
10050 | of `buffer'. | |
10051 | From Neil Booth. | |
10052 | ||
10053 | 2000-10-02 Paul Eggert <eggert@twinsun.com> | |
10054 | ||
10055 | * bison.s1 (yyparse): Assign the default value | |
10056 | unconditionally, to avoid a GCC warning and make the parser a | |
10057 | tad smaller. | |
10058 | ||
10059 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10060 | ||
10061 | * src/getargs.c (getargs): Don't dump `--help' on unrecognized | |
10062 | options. | |
10063 | ||
10064 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10065 | ||
10066 | * src/derives.c, src/print.c, src/reduce.c: To ease the | |
10067 | translation, move some `\n' out of the translated strings. | |
10068 | ||
10069 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10070 | ||
10071 | The location tracking mechanism is precious for parse error | |
10072 | messages. Nevertheless, it is enabled only when `@n' is used in | |
10073 | the grammar, which is a different issue (you can use it in error | |
10074 | message, but not in the grammar per se). Therefore, there should | |
10075 | be another means to enable it. | |
10076 | ||
10077 | * src/getargs.c (getargs): Support `--locations'. | |
10078 | (usage): Report it. | |
10079 | * src/getargs.h (locationsflag): Export it. | |
10080 | * src/lex.c (percent_table): Support `%locations'. | |
10081 | * src/reader.c (yylsp_needed): Remove this variable, now replaced | |
10082 | with `locationsflag'. | |
10083 | * doc/bison.texinfo: Document `--locations' and `%locations'. | |
10084 | Sort the options. | |
10085 | * tests/calc.m4: Test it. | |
10086 | ||
10087 | For regularity of the names, replace each | |
10088 | (nolineflag, toknumflag, rawtokenumflag, noparserflag): with... | |
10089 | (no_lineflag, token_tableflag, rawflag, no_parserflag): this. | |
10090 | In addition replace each `flag' with `_flag'. | |
10091 | ||
10092 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10093 | ||
10094 | Also test parse error messages, including with YYERROR_VERBOSE. | |
10095 | ||
10096 | * tests/calc.m4 (calc.y): Add support for `exp = exp' (non | |
10097 | associative). | |
10098 | Use it to check the computations. | |
10099 | Use it to check `nonassoc' is honored. | |
10100 | (AT_DATA_CALC_Y): Equip `calc.y' with YYERROR_VERBOSE when passed | |
10101 | `--yyerror-verbose'. | |
10102 | (_AT_CHECK_CALC): Adjust to this option. | |
10103 | (_AT_CHECK_CALC_ERROR): New macro to check parse error messages. | |
10104 | ||
10105 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10106 | ||
10107 | Test also `--verbose', `--defines' and `--name-prefix'. Testing | |
10108 | the latter demonstrates a flaw in the handling of non debugging | |
10109 | parsers introduced by myself on 2000-03-16: `#define yydebug 0' | |
10110 | was used in order to simplify: | |
10111 | ||
10112 | #if YYDEBUG | |
10113 | if (yydebug) | |
10114 | { | |
10115 | ... | |
10116 | } | |
10117 | #endif | |
10118 | ||
10119 | into | |
10120 | ||
10121 | if (yydebug) | |
10122 | { | |
10123 | ... | |
10124 | } | |
10125 | ||
10126 | unfortunately this leads to a CPP conflict when | |
10127 | `--name-prefix=foo' is used since it produces `#define yydebug | |
10128 | foodebug'. | |
10129 | ||
10130 | * src/bison.s1 [!YYDEBUG]: Do not define yydebug. | |
10131 | (YYDPRINTF): New macro. | |
10132 | Spread its use. | |
10133 | * tests/calc.m4 (AT_CHECK_CALC): Do require a title, build it from | |
10134 | the bison options. | |
10135 | Also test `--verbose', `--defines' and `--name-prefix'. | |
10136 | ||
10137 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10138 | ||
10139 | Improve the readability of the produced parsers. | |
10140 | ||
10141 | * src/bison.s1: Formatting changes. | |
10142 | Improve the comment related to the `$' mark. | |
10143 | (yydefault): Don't fall through to `yyresume': `goto' there. | |
10144 | * src/output.c (output_parser): When the `$' is met, skip the end | |
10145 | of its line. | |
10146 | New variable, `number_of_dollar_signs', to check there's exactly | |
10147 | one `$' in the parser skeleton. | |
10148 | ||
10149 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10150 | ||
10151 | * lib/xstrdup.c: New file, from the fileutils. | |
10152 | * src/reader.c (parse_token_decl, get_type_name, parse_type_decl) | |
10153 | (parse_assoc_decl, parse_thong_decl, get_type): Use `xstrdup' | |
10154 | instead of strlen + xmalloc + strcpy. | |
10155 | * src/symtab.c (copys): Remove, use xstrdup instead. | |
10156 | ||
10157 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10158 | ||
10159 | * src/gram.h (associativity): New enum type which replaces the | |
10160 | former CPP macros `RIGHT_ASSOC', `LEFT_ASSOC' and `NON_ASSOC' with | |
10161 | `right_assoc', `left_assoc' and `non_assoc'. | |
10162 | Adjust all dependencies. | |
10163 | * src/reader.c: Formatting changes. | |
10164 | (LTYPESTR): Don't define it, use it as a literal in | |
10165 | `reader_output_yylsp'. | |
10166 | * src/symtab.h (symbol_class): New enum type which replaces the | |
10167 | former CPP macros `SUNKNOWN', `STOKEN and `SNTERM' with | |
10168 | `sunknown', `stoken and `snterm'. | |
10169 | ||
10170 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10171 | ||
10172 | * src/getargs.c (fixed_outfiles): Rename as... | |
10173 | (yaccflag): for consistency and accuracy. | |
10174 | Adjust dependencies. | |
10175 | ||
10176 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10177 | ||
10178 | Use the more standard files `xalloc.h' and `xmalloc.c' instead of | |
10179 | Bison's `allocate.c' and `alloc.h'. This patch was surprisingly | |
10180 | difficult and introduced a lot of core dump. It turns out that | |
10181 | Bison used an implementation of `xmalloc' based on `calloc', and | |
10182 | at various places it does depend upon the initialization to 0. I | |
10183 | have not tried to isolate the pertinent places, and all the former | |
10184 | calls to Bison's `xmalloc' are now using `XCALLOC'. Someday, | |
10185 | someone should address this issue. | |
10186 | ||
10187 | * src/allocate.c, src/alloc.h, m4/bison-decl.m4: Remove. | |
10188 | * lib/xmalloc.c, lib/xalloc.h, m4/malloc.m4, m4/realloc.m4: New | |
10189 | files. | |
10190 | Adjust dependencies. | |
10191 | * src/warshall.h: New file. | |
10192 | Propagate. | |
10193 | ||
10194 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10195 | ||
10196 | Various anti-`extern in *.c' changes. | |
10197 | ||
10198 | * src/system.h: Include `assert.h'. | |
10199 | ||
10200 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10201 | ||
10202 | * src/state.h (nstates, final_state, first_state, first_shift) | |
10203 | (first_reduction): Move their exportation from here... | |
10204 | * src/LR0.h: to here. | |
10205 | Adjust dependencies. | |
10206 | * src/getargs.c (statisticsflag): New variable. | |
10207 | Add support for `--statistics'. | |
10208 | Adjust dependencies. | |
10209 | ||
10210 | Remove a lot of now useless `extern' statements in most files. | |
10211 | ||
10212 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10213 | ||
10214 | * src/LR0.h: New file. | |
10215 | Propagate its use. | |
10216 | ||
10217 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10218 | ||
10219 | * src/print.h: New file. | |
10220 | Propagate its use. | |
10221 | * src/print.c: Formatting and ordering changes. | |
10222 | (verbose, terse): Replace with... | |
10223 | (print_results): this new function. | |
10224 | Adjust dependencies. | |
10225 | ||
10226 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10227 | ||
10228 | * src/conflicts.c (conflict_report): New function. | |
10229 | (conflict_log, verbose_conflict_log): Replace with... | |
10230 | (print_conflicts): this function. | |
10231 | Adjust dependencies. | |
10232 | * src/conflicts.h: New file. | |
10233 | Propagate its inclusion. | |
10234 | ||
10235 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10236 | ||
10237 | * src/nullable.h: New file. | |
10238 | Propagate its inclusion. | |
10239 | * src/nullable.c: Formatting changes. | |
10240 | ||
10241 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10242 | ||
10243 | * src/reduce.h: New file. | |
10244 | Propagate its inclusion. | |
10245 | * src/reduce.c: Topological sort and other formatting changes. | |
10246 | (bool, TRUE, FALSE): Move their definition to... | |
10247 | * src/system.h: here. | |
10248 | ||
10249 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10250 | ||
10251 | * src/files.c: Formatting changes. | |
10252 | (tryopen, tryclose, openfiles): Rename as... | |
10253 | (xfopen, xfclose, open_files): this. | |
10254 | (stringappend): static. | |
10255 | * src/files.h: Complete the list of exported symbols. | |
10256 | Propagate its use. | |
10257 | ||
10258 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10259 | ||
10260 | * src/reader.h: New file. | |
10261 | Propagate its use instead of tedious list of `extern' and | |
10262 | prototypes. | |
10263 | * src/reader.c: Formatting changes, topological sort, | |
10264 | s/register//. | |
10265 | ||
10266 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10267 | ||
10268 | * src/lex.h: Prototype `lex.c' exported functions. | |
10269 | * src/reader.c: Adjust. | |
10270 | * src/lex.c: Formatting changes. | |
10271 | (safegetc): Rename as... | |
10272 | (xgetc): this. | |
10273 | ||
10274 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10275 | ||
10276 | * src/lalr.h: New file. | |
10277 | Propagate its inclusion instead of prototypes and `extern'. | |
10278 | * src/lalr.c: Formatting changes, topological sorting etc. | |
10279 | ||
10280 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10281 | ||
10282 | * src/output.c (token_actions): Introduce a temporary array, | |
10283 | YYDEFACT, that makes it possible for this function to use | |
10284 | output_short_table. | |
10285 | ||
10286 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10287 | ||
10288 | `user_toknums' is output as a `short[]' in `output.c', while it is | |
10289 | defined as a `int[]' in `reader.c'. For consistency with the | |
10290 | other output tables, `user_toknums' is now defined as a table of | |
10291 | shorts. | |
10292 | ||
10293 | * src/reader.c (user_toknums): Be a short table instead of an int | |
10294 | table. | |
10295 | Adjust dependencies. | |
10296 | ||
10297 | Factor the short table outputs. | |
10298 | ||
10299 | * src/output.c (output_short_table): New function. | |
10300 | * src/output.c (output_gram, output_stos, output_rule_data) | |
10301 | (output_base, output_table, output_check): Use it. | |
10302 | ||
10303 | 2000-10-02 Akim Demaille <akim@epita.fr> | |
10304 | ||
10305 | * src/output.c (output): Topological sort of the functions, in | |
10306 | order to get rid of the `static' prototypes. | |
10307 | No longer use `register'. | |
10308 | * src/output.h: New file. | |
10309 | Propagate its inclusion in files explicitly prototyping functions | |
10310 | from output.c. | |
10311 | ||
10312 | 2000-09-21 Akim Demaille <akim@epita.fr> | |
10313 | ||
10314 | * src/atgeneral.m4: Update from Autoconf. | |
10315 | ||
10316 | 2000-09-21 Akim Demaille <akim@epita.fr> | |
10317 | ||
10318 | * src/closure.h: New file. | |
10319 | * src/closure.c: Formatting changes, topological sort over the | |
10320 | functions, use of closure.h. | |
10321 | (initialize_closure, finalize_closure): Rename as... | |
10322 | (new_closure, free_closure): these. Adjust dependencies. | |
10323 | * src/LR0.c: Formatting changes, topological sort, use of | |
10324 | cloture.h. | |
10325 | (initialize_states): Rename as... | |
10326 | (new_states): this. | |
10327 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
10328 | ||
10329 | 2000-09-20 Akim Demaille <akim@epita.fr> | |
10330 | ||
10331 | * src/acconfig.h: Don't protect config.h against multiple | |
10332 | inclusion. | |
10333 | Don't define PARAMS. | |
10334 | * src/system.h: Define PARAMS. | |
10335 | Remove some of the ad-hoc CPP magic for DOS, VMS etc.: this is the | |
10336 | purpose of config.h. system.h must not try to fix wrong | |
10337 | definitions in config.h. | |
10338 | ||
10339 | 2000-09-20 Akim Demaille <akim@epita.fr> | |
10340 | ||
10341 | * src/derives.h: New file. | |
10342 | * src/main.c, src/derives.h: Use it. | |
10343 | Formatting changes. | |
10344 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
10345 | ||
10346 | 2000-09-20 Akim Demaille <akim@epita.fr> | |
10347 | ||
10348 | * tests/atgeneral.m4: Update from Autoconf. | |
10349 | * tests/calc.m4 (_AT_DATA_CALC_Y, AT_DATA_CALC_Y, _AT_CHECK_CALC) | |
10350 | (AT_CHECK_CALC): New macros. | |
10351 | Use these macros to test bison with options `', `--raw', | |
10352 | `--debug', `--yacc', `--yacc --debug'. | |
10353 | ||
10354 | 2000-09-19 Akim Demaille <akim@epita.fr> | |
10355 | ||
10356 | * src/output.c: Formatting changes. | |
10357 | * src/machine.h: Remove, leaving its contents in... | |
10358 | * src/system.h: here. | |
10359 | Include stdio.h. | |
10360 | Adjust all dependencies on stdio.h and machine.h. | |
10361 | * src/getargs.h: New file. | |
10362 | Let all `extern' declarations about getargs.c be replaced with | |
10363 | inclusion of `getargs.h'. | |
10364 | * src/Makefile.am (noinst_HEADERS): Adjust. | |
10365 | ||
10366 | * tests/calc.m4 (yyin): Be initialized in main, not on the global | |
10367 | scope. | |
10368 | (yyerror): Returns void, not int. | |
10369 | * doc/bison.texinfo: Formatting changes. | |
10370 | ||
10371 | 2000-09-19 Akim Demaille <akim@epita.fr> | |
10372 | ||
10373 | * tests/calc.m4 (calc.y): Do not assign to stdin, as it's not | |
10374 | portable. | |
10375 | ||
10376 | 2000-09-18 Akim Demaille <akim@epita.fr> | |
10377 | ||
10378 | * configure.in: Append WARNING_CFLAGS to CFLAGS. | |
10379 | * src/Makefile.am (INCLUDES): Don't. | |
10380 | Be ready to fetch headers in lib/. | |
10381 | ||
10382 | 2000-09-18 Akim Demaille <akim@epita.fr> | |
10383 | ||
10384 | * doc/bison.texinfo: Update the copyright. | |
10385 | ANSIfy and GNUify the examples. | |
10386 | Remove the old menu. | |
10387 | ||
10388 | 2000-09-18 Akim Demaille <akim@epita.fr> | |
10389 | ||
10390 | First set of tests: use the `calc' example from the documentation. | |
10391 | ||
10392 | * src/bison.s1 (yyparse): Condition the code using `yytname' which | |
10393 | is defined only when YYDEBUG is. | |
10394 | * m4/atconfig.m4 (AT_CONFIG): Adjust to Autoconf 2.13. | |
10395 | * src/files.c (tryopen, tryclose): Formatting changes. | |
10396 | Move to the top and be static. | |
10397 | * src/reader.c (read_signed_integer): Likewise. | |
10398 | * tests/calc.m4: New file. | |
10399 | * Makefile.am, suite.m4: Adjust. | |
10400 | * m4/atconfig.m4: Set BISON_SIMPLE and BISON_HAIRY. | |
10401 | ||
10402 | 2000-09-18 Akim Demaille <akim@epita.fr> | |
10403 | ||
10404 | Add support for an Autotest test suite for Bison. | |
10405 | ||
10406 | * m4/m4.m4, m4/atconfig.m4: New files. | |
10407 | * m4/Makefile.am (EXTRA_DIST): Adjust. | |
10408 | * tests/suite.m4, tests/Makefile.am, tests/atgeneral.m4: New | |
10409 | files. | |
10410 | * src/getargs.c: Display a more standard --version message. | |
10411 | * src/reader.c (reader): Formatting changes. | |
10412 | No longer depend upon VERSION_STRING. | |
10413 | * configure.in: No longer use `dnl'. | |
10414 | Set up the test suite and the new directory `tests/. | |
10415 | (VERSION_STRING): Remove. | |
10416 | ||
10417 | 2000-04-14 Akim Demaille <akim@epita.fr> | |
10418 | ||
10419 | * src/reader.c (copy_comment2): New function, same as former | |
10420 | `copy_comment', but outputs into two FILE *. | |
10421 | (copy_comment): Use it. | |
10422 | (parse_union_decl): Use it. | |
10423 | (get_type, parse_start_decl): Use the same `invalid' message. | |
10424 | (parse_start_decl, parse_union_decl): Use the same `multiple' | |
10425 | message. | |
10426 | (parse_union_decl, copy_guard, copy_action): Use the same | |
10427 | `unmatched' message. | |
10428 | * m4/Makefile.am (EXTRA_DIST): Add `warning.m4'. | |
10429 | ||
10430 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
10431 | ||
10432 | * src/files.c (tryopen, tryclose): Move to the top. | |
10433 | Be static. | |
10434 | ||
10435 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
10436 | ||
10437 | * src/main.c (main): Don't call `done', exit does it. | |
10438 | ||
10439 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
10440 | ||
10441 | * allocate.c: s/return (foo)/return foo/. | |
10442 | * lalr.c: Likewise. | |
10443 | * LR0.c: Likewise. | |
10444 | * output.c: Likewise. | |
10445 | * reader.c: Likewise. | |
10446 | * symtab.c: Likewise. | |
10447 | * vmsgetargs.c: Likewise. | |
10448 | ||
10449 | 2000-03-31 Akim Demaille <akim@epita.fr> | |
10450 | ||
10451 | Clean up the error reporting functions. | |
10452 | ||
10453 | * src/report.c: New file. | |
10454 | * src/report.h: Likewise. | |
10455 | * src/Makefile.am: Adjust. | |
10456 | * m4/error.m4: New file. | |
10457 | * m4/Makefile.am: Adjust. | |
10458 | * configure.in (jm_PREREQ_ERROR): Call it. | |
10459 | * src/main.c (int_to_string, banner, fatal_banner, warn_banner): | |
10460 | Remove. | |
10461 | (fatal, fatals): Remove. All callers use complain.c::fatal. | |
10462 | (warn, warni, warns, warnss, warnss): Remove. All callers use | |
10463 | complain.c::complain. | |
10464 | (toomany): Remove, use fatal instead. | |
10465 | * src/files.c (done): No argument, use complain_message_count. | |
10466 | * src/main.c (main): Register `done' to `atexit'. | |
10467 | ||
10468 | * src/getargs.c (usage): More `fputs', less `fprintf'. | |
10469 | ||
10470 | 2000-03-28 Akim Demaille <akim@epita.fr> | |
10471 | ||
10472 | * lib/: New directory. | |
10473 | * Makefile.am (SUBDIRS): Adjust. | |
10474 | * configure.in: Adjust. | |
10475 | (LIBOBJS): Although not used yet, AC_SUBST it, otherwise it's | |
10476 | useless. | |
10477 | * src/alloca.c: Moved to lib/. | |
10478 | * src/getopt.c: Likewise. | |
10479 | * src/getopt1.c: Likewise. | |
10480 | * src/getopt.h: Likewise. | |
10481 | * src/ansi2knr.c: Likewise. | |
10482 | * src/ansi2knr.1: Likewise. | |
10483 | * src/Makefile.am: Adjust. | |
10484 | * lib/Makefile.am: New file. | |
10485 | ||
10486 | 2000-03-28 Akim Demaille <akim@epita.fr> | |
10487 | ||
10488 | * src/getargs.c (usage): Refresh the help message. | |
10489 | ||
10490 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10491 | ||
10492 | * src/getopt1.c: Updated from textutils 2.0e | |
10493 | * src/getopt.c: Likewise. | |
10494 | * src/getopt.h: Likewise. | |
10495 | ||
10496 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10497 | ||
10498 | * src/Makefile.am (bison.simple): Fix the awk program: quote only | |
10499 | the file name, not the whole `#line LINE FILE'. | |
10500 | ||
10501 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10502 | ||
10503 | On syntax errors, report the token on which we choked. | |
10504 | ||
10505 | * src/bison.s1 (yyparse): In the label yyerrlab, when | |
10506 | YYERROR_VERBOSE, add yychar in msg. | |
10507 | ||
10508 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10509 | ||
10510 | * src/reader.c (copy_at): New function. | |
10511 | (copy_guard): Use it. | |
10512 | (copy_action): Use it. | |
10513 | ||
10514 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10515 | ||
10516 | Be kind to translators, save some useless translations. | |
10517 | ||
10518 | * src/main.c (banner): New function. | |
10519 | (fatal_banner): Use it. | |
10520 | (warn_banner): Use it. | |
10521 | ||
10522 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10523 | ||
10524 | * src/reader.c (copy_definition): Use copy_string and | |
10525 | copy_comment. Removed now unused `match', `ended', | |
10526 | `cplus_comment'. | |
10527 | (copy_comment, copy_string): Moved, to be visible from | |
10528 | copy_definition. | |
10529 | ||
10530 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10531 | ||
10532 | * src/reader.c (copy_string): Declare `static inline'. No | |
10533 | problems with inline, since it is checked by configure. | |
10534 | (copy_comment): Likewise. | |
10535 | ||
10536 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10537 | ||
10538 | * src/reader.c (packsymbols): Formatting changes. | |
10539 | ||
10540 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10541 | ||
10542 | * src/reader.c (copy_comment): New function, factored out from: | |
10543 | (copy_action): Use it. Removed now unused `match', `ended', | |
10544 | `cplus_comment'. | |
10545 | (copy_guard): Likewise. | |
10546 | ||
10547 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10548 | ||
10549 | * src/reader.c (copy_string): New function, factored out from: | |
10550 | (copy_action): Use it. | |
10551 | (copy_guard): Likewise. | |
10552 | ||
10553 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10554 | ||
10555 | Change the handling of @s so that they behave exactly like $s. | |
10556 | There is now a pseudo variable @$ (readble and writable), location | |
10557 | of the lhs of the rule (by default ranging from the location of | |
10558 | the first symbol of the rhs, to the location of the last symbol, | |
10559 | or, if the rhs is empty, YYLLOC). | |
10560 | ||
10561 | * src/bison.s1 [YYLSP_NEEDED] (yyloc): New variable, twin of | |
10562 | yyval. | |
10563 | (yyparse): When providing a default semantic action, provide a | |
10564 | default location action. | |
10565 | (after the $): No longer change `*YYLSP', just stack YYLOC the | |
10566 | same way you stack YYVAL. | |
10567 | * src/reader.c (read_declarations): Use warns. | |
10568 | (copy_guard, case '@'): Also recognize `@$', expanded as `YYLOC'. | |
10569 | (copy_action, case '@'): Likewise. | |
10570 | Use a standard error message, to save useless work from | |
10571 | translators. | |
10572 | ||
10573 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10574 | ||
10575 | * src/bison.s1: Formatting and cosmetics changes. | |
10576 | * src/reader.c: Likewise. | |
10577 | Update the Copyright notice. | |
10578 | ||
10579 | 2000-03-17 Akim Demaille <akim@epita.fr> | |
10580 | ||
10581 | * src/bison.s1 (#line): All set to `#line' only, since the | |
10582 | Makefile now handles them. | |
10583 | ||
10584 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10585 | ||
10586 | * src/output.c (output_rule_data): Output the documentation of | |
10587 | some of the tables. | |
10588 | (Copyright notice): Update. | |
10589 | Formatting changes. | |
10590 | ||
10591 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10592 | ||
10593 | * src/bison.s1 [!YYDEBUG]: Define yydebug to 0. This allows to | |
10594 | remove most `#if YYDEBUG != 0', since `if (yydebug)' is enough. | |
10595 | One `#if YYDEBUG' remains, since it uses variables which are | |
10596 | defined only if `YYDEBUG != 0'. | |
10597 | ||
10598 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10599 | ||
10600 | * src/bison.s1 (yyparse): Reorganize the definitions of the stacks | |
10601 | and related variables so that the similarities are highlighted. | |
10602 | ||
10603 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10604 | ||
10605 | * src/bison.s1: Properly indent CPP directives. | |
10606 | ||
10607 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10608 | ||
10609 | * src/bison.s1: Properly indent the `alloca' CPP section. | |
10610 | ||
10611 | 2000-03-16 Akim Demaille <akim@epita.fr> | |
10612 | ||
10613 | Do not hard code values of directories in `configure.in'. | |
10614 | Update the `configure' tool chain. | |
10615 | ||
10616 | * configure.in (XPFILE, XPFILE1, LOCALEDIR): Remove, handled by | |
10617 | src/makefile.am. | |
10618 | (VERSION_STRING): Use the third arg of AC_DEFINE_UNQUOTED. | |
10619 | (AC_OUTPUT): Add m4/Makefile. | |
10620 | Bump to bison 1.28a, 1.29 has never been released. | |
10621 | * acconfig.h (XPFILE, XPFILE1, LOCALEDIR): Remove, since they are | |
10622 | handled via src/Makefile.am. | |
10623 | (VERSION_STRING, PROTOTYPES, ENABLE_NLS, HAVE_CATGETS, | |
10624 | HAVE_GETTEXT, HAVE_LC_MESSAGES, HAVE_STPCPY): Remove, handled by | |
10625 | autoheader. | |
10626 | * Makefile.am (SUBDIRS): Add m4. | |
10627 | (ACLOCAL_AM_FLAGS): New variable. | |
10628 | (AUTOMAKE_OPTIONS): Add check-news. | |
10629 | * src/Makefile.am (bison.simple): Use awk to replace #line lines with | |
10630 | the proper line number and file name. | |
10631 | (DEFS): Propagate the location of bison library files and of the | |
10632 | locale files. | |
10633 | (INCLUDES): Added `-I ..' so that one can compile with srcdir != | |
10634 | builddir. | |
10635 | * acinclude.m4: Remove, replaced by the directory m4. | |
10636 | * m4/Makefile.am (EXTRA_DIST): New variable. | |
10637 | * m4/gettext.m4: New file, from the fileutils. | |
10638 | * m4/lcmessage.m4: Likewise | |
10639 | * m4/progtest.m4: Likewise. | |
10640 | * m4/bison-decl.m4: New file, extracted from former acinclude.m4. | |
10641 | ||
10642 | 2000-03-10 Akim Demaille <akim@epita.fr> | |
10643 | ||
10644 | * src/closure.c: | |
10645 | Formatting changes of various comments. | |
10646 | Respect the GNU coding standards at various places. | |
10647 | Don't use `_()' when no translation is needed. | |
10648 | ||
10649 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
10650 | ||
10651 | * src/files.c: | |
10652 | OS/2 honors TMPDIR environment variable. | |
10653 | ||
10654 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
10655 | ||
10656 | * doc/bison.texinfo: Tweaked spelling and grammar. | |
10657 | Updated ISBN. | |
10658 | Removed reference to price of printed copy. | |
10659 | Mention BISON_SIMPLE and BISON_HAIRY. | |
10660 | ||
10661 | 1999-12-13 Jesse Thilo <jthilo@gnu.org> | |
10662 | ||
10663 | * configure.in, NEWS: | |
10664 | Bison 1.29 released. | |
10665 | ||
10666 | 1999-10-27 Jesse Thilo <jthilo@gnu.org> | |
10667 | ||
10668 | * doc/.cvsignore, doc/Makefile.am, doc/refcard.tex: | |
10669 | Added reference card. | |
10670 | ||
10671 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
10672 | ||
10673 | * po/ru.po: Added Russian translation. | |
10674 | ||
10675 | 1999-07-26 Jesse Thilo <jthilo@gnu.org> | |
10676 | ||
10677 | * configure.in: Added Russian translation. | |
10678 | ||
10679 | 1999-07-06 Jesse Thilo <jthilo@gnu.org> | |
10680 | ||
10681 | * configure.in, NEWS, README: | |
10682 | Released version 1.28. | |
10683 | ||
10684 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
10685 | ||
10686 | * src/system.h: | |
10687 | Squashed redefinition warning on some systems. | |
10688 | ||
10689 | * src/getargs.c, src/Makefile.am, src/reader.c, src/version.c: | |
10690 | Have configure build version string instead of relying on ANSI string | |
10691 | concatentation. | |
10692 | ||
10693 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
10694 | ||
10695 | * po/POTFILES.in: Got rid of version.c. | |
10696 | ||
10697 | 1999-06-14 Jesse Thilo <jthilo@gnu.org> | |
10698 | ||
10699 | * acconfig.h, configure.in: | |
10700 | Have configure build version string instead of relying on ANSI string | |
10701 | concatentation. | |
10702 | ||
10703 | 1999-06-08 Jesse Thilo <jthilo@gnu.org> | |
10704 | ||
10705 | * doc/bison.1: | |
10706 | Dropped mention of `+' for long-named options. | |
10707 | ||
10708 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
10709 | ||
10710 | * src/files.c: Added <unistd.h> for unlink(). | |
10711 | ||
10712 | * src/Makefile.am, src/system.h: | |
10713 | I18n fixes. | |
10714 | ||
10715 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
10716 | ||
10717 | * README: Added a FAQ list. | |
10718 | ||
10719 | * configure.in, acconfig.h: | |
10720 | I18n fixes. | |
10721 | ||
10722 | 1999-05-30 Jesse Thilo <jthilo@gnu.org> | |
10723 | ||
10724 | * doc/FAQ, doc/Makefile.am: | |
10725 | Added a FAQ list. | |
10726 | ||
10727 | 1999-05-19 Jesse Thilo <jthilo@gnu.org> | |
10728 | ||
10729 | * src/alloc.h, src/symtab.h, src/version.c: | |
10730 | Protected inclusion of "config.h" with HAVE_CONFIG_H. | |
10731 | ||
10732 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
10733 | ||
10734 | * src/.cvsignore, src/Makefile.am: | |
10735 | Reorganized: sources in `src', documentation in `doc'. | |
10736 | ||
10737 | * src/lex.c (literalchar): | |
10738 | fixed the code for escaping double quotes (thanks | |
10739 | Jonathan Czisny.) | |
10740 | ||
10741 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
10742 | ||
10743 | * po/de.po, po/es.po, po/fr.po, po/nl.po, po/POTFILES.in: | |
10744 | Adjusted paths to reflect directory reorganization. | |
10745 | ||
10746 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
10747 | ||
10748 | * doc/.cvsignore, doc/Makefile.am: | |
10749 | Reorganized: sources in `src', documentation in `doc'. | |
10750 | ||
10751 | 1999-04-18 Jesse Thilo <jthilo@gnu.org> | |
10752 | ||
10753 | * configure.in: | |
10754 | Updated AC_INIT file to reflect directory reorganization. | |
10755 | ||
10756 | * configure.in, .cvsignore, Makefile.am, POTFILES.in: | |
10757 | Reorganized: sources in `src', documentation in `doc'. | |
10758 | ||
10759 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
10760 | ||
10761 | * src/allocate.c: | |
10762 | Don't declare calloc() and realloc() if not necessary. | |
10763 | ||
10764 | 1999-04-13 Jesse Thilo <jthilo@gnu.org> | |
10765 | ||
10766 | * configure.in, acconfig.h, acinclude.m4: | |
10767 | Don't declare calloc() and realloc() if not necessary. | |
10768 | ||
10769 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
10770 | ||
10771 | * po/.cvsignore: Added i18n support. | |
10772 | ||
10773 | 1999-03-23 Jesse Thilo <jthilo@gnu.org> | |
10774 | ||
10775 | * acconfig.h, configure.in, Makefile.am: | |
10776 | Added i18n support. | |
10777 | ||
10778 | 1999-03-22 Jesse Thilo <jthilo@gnu.org> | |
10779 | ||
10780 | * src/bison.s1: Fixed #line numbers. | |
10781 | ||
10782 | 1999-03-15 Jesse Thilo <jthilo@gnu.org> | |
10783 | ||
10784 | * po/es.po, po/fr.po, po/nl.po, po/de.po: | |
10785 | Added PO files from Translation Project. | |
10786 | ||
10787 | 1999-03-03 Jesse Thilo <jthilo@gnu.org> | |
10788 | ||
10789 | * Makefile.am: | |
10790 | Added support for non-ANSI compilers (ansi2knr). | |
10791 | ||
10792 | 1999-02-16 Jesse Thilo <jthilo@gnu.org> | |
10793 | ||
10794 | * configure.in: Bumped version number to 1.27. | |
10795 | ||
10796 | * Makefile.am: | |
10797 | Added `bison.simple' to list of files removed by `make distclean'. | |
10798 | ||
10799 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
10800 | ||
10801 | * src/files.c, src/files.h: | |
10802 | Defined locations of parser files in config.h instead of Makefile. | |
10803 | ||
10804 | 1999-02-12 Jesse Thilo <jthilo@gnu.org> | |
10805 | ||
10806 | * acconfig.h, acinclude.m4, configure.in, Makefile.am: | |
10807 | Defined locations of parser files in config.h instead of Makefile. | |
10808 | ||
10809 | 1999-02-09 Jesse Thilo <jthilo@gnu.org> | |
10810 | ||
10811 | * Makefile.am: | |
10812 | Removed inappropriate use of $< macro. | |
10813 | ||
10814 | 1999-02-05 Jesse Thilo <jthilo@gnu.org> | |
10815 | ||
10816 | * po/Makefile.in.in, po/POTFILES.in: | |
10817 | Add `po' directory skeleton. | |
10818 | ||
10819 | 1999-01-27 Jesse Thilo <jthilo@gnu.org> | |
10820 | ||
10821 | * README: Document help-bison list. | |
10822 | ||
10823 | * configure.in: Add check for mkstemp(). | |
10824 | ||
10825 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
10826 | ||
10827 | * src/conflicts.c, src/LR0.c, src/output.c, src/reader.c: | |
10828 | Hush a few compiler warnings. | |
10829 | ||
10830 | * src/files.c: | |
10831 | Add tryclose(), which verifies that fclose was successful. | |
10832 | Hush a couple of compiler warnings. | |
10833 | ||
10834 | 1999-01-20 Jesse Thilo <jthilo@gnu.org> | |
10835 | ||
10836 | * Makefile.am, OChangeLog: | |
10837 | ChangeLog is now automatically generated. Include the old version as | |
10838 | OChangeLog. | |
10839 | ||
10840 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
10841 | ||
10842 | * 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: | |
10843 | Update FSF address. | |
10844 | ||
10845 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
10846 | ||
10847 | * doc/bison.texinfo: Fix formatting glitch. | |
10848 | ||
10849 | * doc/bison.texinfo: Update FSF address. | |
10850 | ||
10851 | 1999-01-14 Jesse Thilo <jthilo@gnu.org> | |
10852 | ||
10853 | * acconfig.h: Update FSF address. | |
10854 | ||
10855 | 1999-01-08 Jesse Thilo <jthilo@gnu.org> | |
10856 | ||
10857 | * src/system.h: | |
10858 | Don't define PACKAGE here, since config.h defines it. | |
10859 | ||
10860 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
10861 | ||
10862 | * src/reader.c: Update copyright date. | |
10863 | ||
10864 | * src/main.c: | |
10865 | Ditch sprintf to statically-sized buffers in fatal/warn functions in | |
10866 | favor of output directly to stderr (avoids buffer overruns). | |
10867 | ||
10868 | * src/reader.c: Some checks for premature EOF. | |
10869 | ||
10870 | * 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: | |
10871 | Use prototypes if the compiler understands them. | |
10872 | ||
10873 | * src/files.c: Honor TMPDIR on Unix hosts. | |
10874 | Use prototypes if the compiler understands them. | |
10875 | ||
10876 | * src/reader.c: | |
10877 | Fix a couple of buffer overrun bugs. | |
10878 | Use prototypes if the compiler understands them. | |
10879 | ||
10880 | * src/system.h: Include unistd.h and ctype.h. | |
10881 | Use #ifdef instead of #if for NLS symbols. | |
10882 | ||
10883 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
10884 | ||
10885 | * doc/bison.texinfo: | |
10886 | Delete comment "consider using @set for edition number, etc..." since | |
10887 | we now are doing so. | |
10888 | ||
10889 | 1998-12-30 Jesse Thilo <jthilo@gnu.org> | |
10890 | ||
10891 | * configure.in: | |
10892 | Use prototypes if the compiler understands them. | |
10893 | ||
10894 | * NEWS: Document 1.26 highlights. | |
10895 | ||
10896 | * Makefile.am: Require Automake 1.3 or later. | |
10897 | ||
10898 | * acconfig.h: | |
10899 | Use prototypes if the compiler understands them. | |
10900 | ||
10901 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
10902 | ||
10903 | * src/version.c: | |
10904 | Use VERSION symbol from automake for version number. | |
10905 | ||
10906 | 1998-12-29 Jesse Thilo <jthilo@gnu.org> | |
10907 | ||
10908 | * acconfig.h, configure.in, version.cin: | |
10909 | Use VERSION symbol from automake for version number. | |
10910 | ||
10911 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
10912 | ||
10913 | * Makefile.am: | |
10914 | Distribute original version of simple parser (bison.s1), not built | |
10915 | version (bison.simple). | |
10916 | ||
10917 | 1998-11-28 Jesse Thilo <jthilo@gnu.org> | |
10918 | ||
10919 | * doc/bison.texinfo: Add info dir entry. | |
10920 | ||
10921 | * doc/bison.texinfo: | |
10922 | Let automake put version number into documentation. | |
10923 | ||
10924 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
10925 | ||
10926 | * src/bison.cld, src/build.com, src/vmshlp.mar: | |
10927 | Add non-RCS files from /gd/gnu/bison. | |
10928 | ||
10929 | 1998-11-26 Jesse Thilo <jthilo@gnu.org> | |
10930 | ||
10931 | * doc/bison.1: | |
10932 | Document the BISON_HAIRY and BISON_SIMPLE variables. | |
10933 | ||
10934 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
10935 | ||
10936 | * src/version.c: Build version.c automatically. | |
10937 | ||
10938 | * src/reader.c: | |
10939 | Fix token numbering (used to start at 258, not 257). | |
10940 | ||
10941 | * src/system.h: Include config.h. | |
10942 | ||
10943 | * src/getargs.c: Update bug report address. | |
10944 | ||
10945 | * src/alloca.c, src/getopt1.c, src/getopt.c, src/getopt.h: | |
10946 | Get latest copies of alloca.c, getopt.c, getopt.h, getopt1.c from gnu.org. | |
10947 | ||
10948 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
10949 | ||
10950 | * Makefile.am: | |
10951 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
10952 | ||
10953 | * configure.in, version.cin: | |
10954 | Build version.c automatically. | |
10955 | ||
10956 | * AUTHORS: Add AUTHORS file. | |
10957 | ||
10958 | * README: Update bug report address. | |
10959 | ||
10960 | * bison.simple: | |
10961 | Rename bison.simple to bison.s1 (bison.simple is then built from bison.s1). | |
10962 | ||
10963 | * configure.in, Makefile.am, Makefile.in, stamp-h.in: | |
10964 | Add automake stuff. | |
10965 | ||
10966 | 1998-11-25 Jesse Thilo <jthilo@gnu.org> | |
10967 | ||
10968 | * doc/bison.texinfo: Clean up some formatting. | |
10969 | ||
10970 | 1998-05-05 Richard Stallman <rms@gnu.org> | |
10971 | ||
10972 | * doc/bison.texinfo: | |
10973 | Explain better why to make a pure parser. | |
10974 | ||
10975 | 1998-01-05 Richard Stallman <rms@gnu.org> | |
10976 | ||
10977 | * src/files.c (openfiles): | |
10978 | [_WIN32 && !__CYGWIN32__] Use TEMP or Temp to | |
10979 | find a temporary directory, if possible. Do not unlink files while | |
10980 | they are open. | |
10981 | ||
10982 | 1997-08-25 Richard Stallman <rms@gnu.org> | |
10983 | ||
10984 | * src/reader.c (stack_offset;): | |
10985 | Change some warni to warns. | |
10986 | ||
10987 | * src/lex.c (literalchar): Use warns, not warni. | |
10988 | ||
10989 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
10990 | ||
10991 | * src/bison.s1: Add a Bison version comment. | |
10992 | ||
10993 | * src/main.c (fatal, warn, berror): | |
10994 | Use program_name. | |
10995 | ||
10996 | 1997-06-28 Richard Stallman <rms@gnu.org> | |
10997 | ||
10998 | * Makefile.in (bison_version): New variable. | |
10999 | (dist): Use that variable. | |
11000 | (bison.s1): Substitute the Bison version into bison.simple. | |
11001 | ||
11002 | * bison.simple: Add a Bison version comment. | |
11003 | ||
11004 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
11005 | ||
11006 | * src/main.c (fatal, warn, berror): | |
11007 | Make error messages standard. | |
11008 | (toomany): Improve error message text. | |
11009 | ||
11010 | * 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: | |
11011 | new.h renamed to alloc.h. | |
11012 | ||
11013 | 1997-06-18 Richard Stallman <rms@gnu.org> | |
11014 | ||
11015 | * Makefile.in: new.h renamed to alloc.h. | |
11016 | ||
11017 | 1997-05-24 Richard Stallman <rms@gnu.org> | |
11018 | ||
11019 | * src/lex.c (literalchar): | |
11020 | Fix the code for escaping \, " and '. | |
11021 | ||
11022 | (lex): Avoid trouble when there are many chars | |
11023 | to discard in a char literal with just several chars in it. | |
11024 | ||
11025 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
11026 | ||
11027 | * src/bison.s1: | |
11028 | Use malloc, if using alloca is troublesome. | |
11029 | (YYSTACK_USE_ALLOCA): New flag macro. | |
11030 | Define it for some systems and compilers. | |
11031 | (YYSTACK_ALLOC): New macro. | |
11032 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
11033 | If it was malloc'd, free it. | |
11034 | ||
11035 | 1997-05-17 Richard Stallman <rms@gnu.org> | |
11036 | ||
11037 | * bison.simple: | |
11038 | Use malloc, if using alloca is troublesome. | |
11039 | (YYSTACK_USE_ALLOCA): New flag macro. | |
11040 | Define it for some systems and compilers. | |
11041 | (YYSTACK_ALLOC): New macro. | |
11042 | (yyparse): Use YYSTACK_ALLOC to allocate stack. | |
11043 | If it was malloc'd, free it. | |
11044 | ||
11045 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
11046 | ||
11047 | * src/bison.s1: | |
11048 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
11049 | ||
11050 | 1997-04-23 Richard Stallman <rms@gnu.org> | |
11051 | ||
11052 | * bison.simple: | |
11053 | (alloca) [__hpux]: Always define as __builtin_alloca. | |
11054 | ||
11055 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
11056 | ||
11057 | * src/bison.s1: | |
11058 | [__hpux]: Include alloca.h (right for HPUX 10) | |
11059 | instead of declaring alloca (right for HPUX 9). | |
11060 | ||
11061 | * src/bison.s1 (__yy_memcpy): | |
11062 | Declare arg `count' as unsigned int. | |
11063 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
11064 | ||
11065 | 1997-04-22 Richard Stallman <rms@gnu.org> | |
11066 | ||
11067 | * bison.simple: | |
11068 | [__hpux]: Include alloca.h (right for HPUX 10) | |
11069 | instead of declaring alloca (right for HPUX 9). | |
11070 | ||
11071 | * bison.simple (__yy_memcpy): | |
11072 | Declare arg `count' as unsigned int. | |
11073 | (yyparse): Cast third arg to __yy_memcpy to unsigned int. | |
11074 | ||
11075 | 1997-01-03 Richard Stallman <rms@gnu.org> | |
11076 | ||
11077 | * src/allocate.c: [__STDC__ or _MSC_VER]: | |
11078 | Declare calloc and realloc to return void *. | |
11079 | ||
11080 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
11081 | ||
11082 | * src/system.h: | |
11083 | [_MSC_VER]: Include stdlib.h and process.h. | |
11084 | [_MSC_VER] (getpid): Define as macro--translate it to _getpid. | |
11085 | ||
11086 | * src/main.c (main): Return FAILURE as a value. | |
11087 | (printable_version): Declare arg as int, not char. | |
11088 | ||
11089 | 1997-01-02 Richard Stallman <rms@gnu.org> | |
11090 | ||
11091 | * Makefile.in (dist): | |
11092 | Explicitly check for symlinks, and copy them. | |
11093 | ||
11094 | 1996-12-19 Richard Stallman <rms@gnu.org> | |
11095 | ||
11096 | * src/files.c: | |
11097 | [_MSC_VER] (XPFILE, XPFILE1): Define, if not already defined. | |
11098 | ||
11099 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
11100 | ||
11101 | * src/bison.s1 (yyparse): | |
11102 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
11103 | declare yyparse to have a void * argument. | |
11104 | ||
11105 | 1996-12-18 Paul Eggert <eggert@gnu.org> | |
11106 | ||
11107 | * bison.simple (yyparse): | |
11108 | If __GNUC__ and YYPARSE_PARAM are both defined, | |
11109 | declare yyparse to have a void * argument. | |
11110 | ||
11111 | 1996-12-17 Richard Stallman <rms@gnu.org> | |
11112 | ||
11113 | * src/reduce.c (nbits): Add some casts. | |
11114 | ||
11115 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
11116 | ||
11117 | * src/bison.s1: Test _MSDOS as well as _MSDOS_. | |
11118 | ||
11119 | 1996-08-12 Richard Stallman <rms@gnu.org> | |
11120 | ||
11121 | * bison.simple: Test _MSDOS as well as _MSDOS_. | |
11122 | ||
11123 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
11124 | ||
11125 | * src/bison.s1: | |
11126 | [__sun && __i386]: Include alloca.h. | |
11127 | ||
11128 | 1996-07-31 Richard Stallman <rms@gnu.org> | |
11129 | ||
11130 | * bison.simple: | |
11131 | [__sun && __i386]: Include alloca.h. | |
11132 | ||
11133 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
11134 | ||
11135 | * src/bison.s1: Comment change. | |
11136 | ||
11137 | * src/bison.s1: Test _MSDOS_, not MSDOS. | |
11138 | ||
11139 | 1996-07-30 Richard Stallman <rms@gnu.org> | |
11140 | ||
11141 | * bison.simple: Comment change. | |
11142 | ||
11143 | * bison.simple: Test _MSDOS_, not MSDOS. | |
11144 | ||
11145 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
11146 | ||
11147 | * 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: | |
11148 | Insert `_' macro around many string constants. | |
11149 | ||
11150 | * src/main.c: | |
11151 | Insert `_' macro around many string constants. | |
11152 | ||
11153 | (main): Call setlocale, bindtextdomain and textdomain. | |
11154 | ||
11155 | * src/system.h: [HAVE_LOCALE_H]: Include locale.h. | |
11156 | [! HAVE_LOCALE_H] (setlocale): Define as no-op. | |
11157 | [ENABLE_NLS]: Include libintl.h. | |
11158 | [ENABLE_NLS] (gettext): Define. | |
11159 | [! ENABLE_NLS] (bintextdomain, textdomain, _): Consolation definitions. | |
11160 | (N_, PACKAGE, LOCALEDIR): New macros. | |
11161 | ||
11162 | 1996-06-01 Richard Stallman <rms@gnu.org> | |
11163 | ||
11164 | * POTFILES.in: New file. | |
11165 | ||
11166 | * Makefile.in (allocate.o): | |
11167 | Define target explicitly. | |
11168 | ||
11169 | * Makefile.in (CFLAGS): Set to @CFLAGS@. | |
11170 | (LDFLAGS): Set to @LDFLAGS@. | |
11171 | (configure): Run autoconf only if preceding `cd' succeeds. | |
11172 | (bison.s1): Redirect output to temporary file then move the | |
11173 | temporary to the target, rather than redirecting directly to bison.s1. | |
11174 | (clean): Remove config.status and config.log. | |
11175 | (distclean): Don't remove config.status here. | |
11176 | ||
11177 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
11178 | ||
11179 | * src/bison.s1: | |
11180 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
11181 | ||
11182 | 1996-05-12 Richard Stallman <rms@gnu.org> | |
11183 | ||
11184 | * bison.simple: | |
11185 | (__yy_memcpy) [__cplusplus]: Reorder declarations of variables f and t. | |
11186 | ||
11187 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
11188 | ||
11189 | * src/bison.s1 (__yy_memcpy): | |
11190 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
11191 | (yyparse): Calls changed accordingly. | |
11192 | ||
11193 | 1996-05-11 Richard Stallman <rms@gnu.org> | |
11194 | ||
11195 | * Makefile.in (dist): Don't use $(srcdir). | |
11196 | ||
11197 | * bison.simple (__yy_memcpy): | |
11198 | Really reorder the args, as was supposedly done on Feb 14 1995. | |
11199 | (yyparse): Calls changed accordingly. | |
11200 | ||
11201 | 1996-01-27 Richard Stallman <rms@gnu.org> | |
11202 | ||
11203 | * src/output.c (output_rule_data): | |
11204 | Test YYERROR_VERBOSE in the conditional | |
11205 | around the definition of ttyname. | |
11206 | ||
11207 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
11208 | ||
11209 | * src/bison.s1: | |
11210 | Fix line numbers in #line commands. | |
11211 | ||
11212 | 1995-12-29 Richard Stallman <rms@gnu.org> | |
11213 | ||
11214 | * bison.simple: | |
11215 | Fix line numbers in #line commands. | |
11216 | ||
11217 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
11218 | ||
11219 | * src/bison.s1 (YYPARSE_PARAM_DECL): | |
11220 | In C++, make it always null. | |
11221 | (YYPARSE_PARAM_ARG): New macro. | |
11222 | (yyparse): Use YYPARSE_PARAM_ARG. | |
11223 | ||
11224 | 1995-12-27 Richard Stallman <rms@gnu.org> | |
11225 | ||
11226 | * bison.simple (YYPARSE_PARAM_DECL): | |
11227 | In C++, make it always null. | |
11228 | (YYPARSE_PARAM_ARG): New macro. | |
11229 | (yyparse): Use YYPARSE_PARAM_ARG. | |
11230 | ||
11231 | 1995-11-29 Richard Stallman <rms@gnu.org> | |
11232 | ||
11233 | * doc/bison.texinfo: | |
11234 | Describe literal string tokens, %raw, %no_lines, %token_table. | |
11235 | ||
11236 | 1995-11-29 Daniel Hagerty <hag@gnu.org> | |
11237 | ||
11238 | * doc/bison.texinfo: Fixed update date | |
11239 | ||
11240 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
11241 | ||
11242 | * src/version.c: Version 1.25. | |
11243 | ||
11244 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
11245 | ||
11246 | * NEWS: *** empty log message *** | |
11247 | ||
11248 | 1995-10-16 Richard Stallman <rms@gnu.org> | |
11249 | ||
11250 | * doc/bison.1, doc/bison.rnh: | |
11251 | Add new options. | |
11252 | ||
11253 | 1995-10-15 Richard Stallman <rms@gnu.org> | |
11254 | ||
11255 | * src/vmsgetargs.c, src/getargs.c: | |
11256 | Added -n, -k, and -raw switches. | |
11257 | (noparserflag, toknumflag, rawtoknumflag): New variables. | |
11258 | ||
11259 | * src/symtab.h (SALIAS): | |
11260 | New #define for adding aliases to %token. | |
11261 | (struct bucket): Added `alias' field. | |
11262 | ||
11263 | * src/reduce.c (reduce_grammar): | |
11264 | Revise error message. | |
11265 | (print_notices): Remove final `.' from error message. | |
11266 | ||
11267 | * src/reader.c (reader_output_yylsp): | |
11268 | New function. | |
11269 | (readgram): Use `#if 0' around code that accepted %command | |
11270 | inside grammar rules: The documentation doesn't allow it, | |
11271 | and it will fail since the %command processors scan for the next %. | |
11272 | (parse_token_decl): Extended the %token | |
11273 | declaration to allow a multi-character symbol as an alias. | |
11274 | (parse_thong_decl): New function. | |
11275 | (read_declarations): Added %thong declarations. | |
11276 | (read_declarations): Handle NOOP to deal with allowing | |
11277 | % declarations as another means to specify the flags. | |
11278 | (readgram): Allow %prec prior to semantics embedded in a rule. | |
11279 | (skip_to_char, read_declarations, copy_definition) | |
11280 | (parse_token_decl, parse_start_decl, parse_type_decl) | |
11281 | (parse_assoc_decl, parse_union_decl, parse_expect_decl) | |
11282 | (get_type_name, copy_guard, copy_action, readgram) | |
11283 | (get_type, packsymbols): Revised most error messages. | |
11284 | Changed `fatal' to `warnxxx' to avoid aborting for error. | |
11285 | Revised and use multiple warnxxx functions to avoid using VARARGS1. | |
11286 | (read_declarations): Improve the error message for | |
11287 | an invalid character. Do not abort. | |
11288 | (read_declarations, copy_guard, copy_action): Use | |
11289 | printable_version to avoid unprintable characters in printed output. | |
11290 | (parse_expect_decl): Error if argument to %expect exceeds 10 digits. | |
11291 | (parse_token_decl, parse_assoc_decl, parse_type_decl, get_type): | |
11292 | Allow the type of a non-terminal can be given | |
11293 | more than once, as long as all specifications give the same type. | |
11294 | ||
11295 | * src/output.c: | |
11296 | (output_headers, output_trailers, output, output_gram) | |
11297 | (output_rule_data): Implement noparserflag variable. | |
11298 | Implement toknumflag variable. | |
11299 | (output): Call reader_output_yylsp to output LTYPESTR. | |
11300 | ||
11301 | * src/main.c (main): | |
11302 | If reader sees an error, don't process the grammar. | |
11303 | (fatals): Updated to not use VARARGS1. | |
11304 | (printable_version, int_to_string, warn, warni, warns, warnss) | |
11305 | (warnsss): New error reporting functions. Avoid abort for error. | |
11306 | ||
11307 | * src/lex.h: | |
11308 | Added THONG and NOOP for alias processing. | |
11309 | Added SETOPT for the new code that allows setting options with %flags. | |
11310 | ||
11311 | * src/lex.c: | |
11312 | Include getopt.h. Add some extern decls. | |
11313 | (safegetc): New function to deal with EOF gracefully. | |
11314 | (literalchar); new function to deal with reading \ escapes. | |
11315 | (lex): Use literalchar. | |
11316 | (lex): Implemented "..." tokens. | |
11317 | (literalchar, lex, parse_percent_token): Made tokenbuffer | |
11318 | always contain the token. This includes growing the token | |
11319 | buffer while reading an integer. | |
11320 | (parse_percent_token): Replaced if-else statement with percent_table. | |
11321 | (parse_percent_token): Added % declarations as another | |
11322 | way to specify the flags -n, -l, and -r. Also added hooks for | |
11323 | -d, -k, -y, -v, -t, -p, -b, -o, but implementation requires | |
11324 | major changes to files.c. | |
11325 | (lex) Retain in the incoming stream a character following | |
11326 | an incorrect '/'. | |
11327 | (skip_white_space, lex): Revised most error messages | |
11328 | and changed fatal to warn to avoid aborting. | |
11329 | (percent_table): Added %thong declarations. | |
11330 | ||
11331 | * src/gram.h: Comment changes. | |
11332 | ||
11333 | * src/files.c (openfiles, open_extra_files, done): | |
11334 | Add faction flag | |
11335 | and actfile file. Handle noparserflag. Both for -n switch. | |
11336 | ||
11337 | * src/conflicts.c (resolve_sr_conflict): | |
11338 | Remove use of alloca. | |
11339 | ||
11340 | 1995-06-01 Jim Meyering <meyering@gnu.org> | |
11341 | ||
11342 | * doc/bison.texinfo: *** empty log message *** | |
11343 | ||
11344 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
11345 | ||
11346 | * src/bison.s1: Comment change. | |
11347 | ||
11348 | 1995-05-06 Richard Stallman <rms@gnu.org> | |
11349 | ||
11350 | * bison.simple: Comment change. | |
11351 | ||
11352 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
11353 | ||
11354 | * src/version.c: Version now 1.24. | |
11355 | ||
11356 | * src/bison.s1: Change distribution terms. | |
11357 | ||
11358 | * src/version.c: Version now 1.23. | |
11359 | ||
11360 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
11361 | ||
11362 | * doc/bison.texinfo: | |
11363 | Rewrite "Conditions for Using Bison". | |
11364 | Update version to 1.24. | |
11365 | ||
11366 | 1995-05-03 Richard Stallman <rms@gnu.org> | |
11367 | ||
11368 | * bison.simple: Change distribution terms. | |
11369 | ||
11370 | 1995-02-23 Richard Stallman <rms@gnu.org> | |
11371 | ||
11372 | * src/files.c: Test __VMS_POSIX as well as VMS. | |
11373 | ||
11374 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
11375 | ||
11376 | * src/bison.s1 (__yy_memcpy): | |
11377 | Renamed from __yy_bcopy to avoid | |
11378 | confusion. Reverse FROM and TO arguments to be consistent with | |
11379 | those of memcpy. | |
11380 | ||
11381 | 1995-02-14 Jim Meyering <meyering@gnu.org> | |
11382 | ||
11383 | * bison.simple (__yy_memcpy): | |
11384 | Renamed from __yy_bcopy to avoid | |
11385 | confusion. Reverse FROM and TO arguments to be consistent with | |
11386 | those of memcpy. | |
11387 | ||
11388 | 1994-11-10 David J. MacKenzie <djm@gnu.org> | |
11389 | ||
11390 | * NEWS: reformat | |
11391 | ||
11392 | * NEWS: New file. | |
11393 | ||
11394 | * Makefile.in (DISTFILES): Include NEWS. | |
11395 | ||
11396 | * Makefile.in (DISTFILES): | |
11397 | Include install-sh, not install.sh. | |
11398 | ||
11399 | * configure.in: Update to Autoconf v2 macro names. | |
11400 | ||
11401 | 1994-10-05 David J. MacKenzie <djm@gnu.org> | |
11402 | ||
11403 | * Makefile.in: fix typo | |
11404 | ||
11405 | * Makefile.in (prefix, exec_prefix): | |
11406 | Let configure set them. | |
11407 | ||
11408 | 1994-09-28 David J. MacKenzie <djm@gnu.org> | |
11409 | ||
11410 | * Makefile.in: Set datadir to $(prefix)/share. | |
11411 | ||
11412 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
11413 | ||
11414 | * src/bison.s1: | |
11415 | Update copyright notice and GPL version. | |
11416 | ||
11417 | 1994-09-15 Richard Stallman <rms@gnu.org> | |
11418 | ||
11419 | * bison.simple: | |
11420 | Update copyright notice and GPL version. | |
11421 | ||
11422 | 1994-07-12 Richard Stallman <rms@gnu.org> | |
11423 | ||
11424 | * src/reduce.c, src/reader.c: | |
11425 | entered into RCS | |
11426 | ||
11427 | 1994-05-05 David J. MacKenzie <djm@gnu.org> | |
11428 | ||
11429 | * Makefile.in: entered into RCS | |
11430 | ||
11431 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
11432 | ||
11433 | * src/bison.s1: entered into RCS | |
11434 | ||
11435 | 1994-03-26 Richard Stallman <rms@gnu.org> | |
11436 | ||
11437 | * bison.simple: entered into RCS | |
11438 | ||
11439 | 1994-03-25 Richard Stallman <rms@gnu.org> | |
11440 | ||
11441 | * src/main.c: entered into RCS | |
11442 | ||
11443 | 1994-03-24 Richard Stallman <rms@gnu.org> | |
11444 | ||
11445 | * src/conflicts.c: entered into RCS | |
11446 | ||
11447 | 1994-01-02 Richard Stallman <rms@gnu.org> | |
11448 | ||
11449 | * Makefile.in: *** empty log message *** | |
11450 | ||
11451 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
11452 | ||
11453 | * src/bison.s1: *** empty log message *** | |
11454 | ||
11455 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
11456 | ||
11457 | * doc/bison.texinfo: entered into RCS | |
11458 | ||
11459 | * doc/bison.texinfo: *** empty log message *** | |
11460 | ||
11461 | 1993-11-21 Richard Stallman <rms@gnu.org> | |
11462 | ||
11463 | * bison.simple: *** empty log message *** | |
11464 | ||
11465 | 1993-10-25 David J. MacKenzie <djm@gnu.org> | |
11466 | ||
11467 | * doc/bison.texinfo: *** empty log message *** | |
11468 | ||
11469 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
11470 | ||
11471 | * src/bison.s1: *** empty log message *** | |
11472 | ||
11473 | 1993-10-19 Richard Stallman <rms@gnu.org> | |
11474 | ||
11475 | * bison.simple: *** empty log message *** | |
11476 | ||
11477 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
11478 | ||
11479 | * src/bison.s1: *** empty log message *** | |
11480 | ||
11481 | 1993-10-14 Richard Stallman <rms@gnu.org> | |
11482 | ||
11483 | * bison.simple: *** empty log message *** | |
11484 | ||
11485 | 1993-09-14 David J. MacKenzie <djm@gnu.org> | |
11486 | ||
11487 | * doc/bison.texinfo: *** empty log message *** | |
11488 | ||
11489 | 1993-09-13 Noah Friedman <friedman@gnu.org> | |
11490 | ||
11491 | * Makefile.in: *** empty log message *** | |
11492 | ||
11493 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
11494 | ||
11495 | * src/conflicts.c: *** empty log message *** | |
11496 | ||
11497 | * src/system.h: entered into RCS | |
11498 | ||
11499 | 1993-09-10 Richard Stallman <rms@gnu.org> | |
11500 | ||
11501 | * doc/bison.1: entered into RCS | |
11502 | ||
11503 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
11504 | ||
11505 | * src/version.c: entered into RCS | |
11506 | ||
11507 | 1993-09-06 Noah Friedman <friedman@gnu.org> | |
11508 | ||
11509 | * Makefile.in: *** empty log message *** | |
11510 | ||
11511 | 1993-07-30 David J. MacKenzie <djm@gnu.org> | |
11512 | ||
11513 | * Makefile.in: *** empty log message *** | |
11514 | ||
11515 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
11516 | ||
11517 | * src/bison.s1: *** empty log message *** | |
11518 | ||
11519 | 1993-07-24 Richard Stallman <rms@gnu.org> | |
11520 | ||
11521 | * bison.simple: *** empty log message *** | |
11522 | ||
11523 | 1993-07-08 David J. MacKenzie <djm@gnu.org> | |
11524 | ||
11525 | * Makefile.in: *** empty log message *** | |
11526 | ||
11527 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
11528 | ||
11529 | * src/bison.s1: *** empty log message *** | |
11530 | ||
11531 | 1993-07-04 Richard Stallman <rms@gnu.org> | |
11532 | ||
11533 | * bison.simple: *** empty log message *** | |
11534 | ||
11535 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
11536 | ||
11537 | * src/getargs.c: entered into RCS | |
11538 | ||
11539 | 1993-06-26 David J. MacKenzie <djm@gnu.org> | |
11540 | ||
11541 | * doc/bison.texinfo: *** empty log message *** | |
11542 | ||
11543 | * doc/bison.1: New file. | |
11544 | ||
11545 | 1993-06-25 Richard Stallman <rms@gnu.org> | |
11546 | ||
11547 | * src/getargs.c: New file. | |
11548 | ||
11549 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
11550 | ||
11551 | * src/bison.s1: *** empty log message *** | |
11552 | ||
11553 | 1993-06-16 Richard Stallman <rms@gnu.org> | |
11554 | ||
11555 | * bison.simple: *** empty log message *** | |
11556 | ||
11557 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
11558 | ||
11559 | * src/bison.s1: New file. | |
11560 | ||
11561 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
11562 | ||
11563 | * doc/bison.texinfo: *** empty log message *** | |
11564 | ||
11565 | 1993-06-03 Richard Stallman <rms@gnu.org> | |
11566 | ||
11567 | * bison.simple: New file. | |
11568 | ||
11569 | 1993-05-19 Richard Stallman <rms@gnu.org> | |
11570 | ||
11571 | * doc/bison.texinfo: New file. | |
11572 | ||
11573 | 1993-05-07 Noah Friedman <friedman@gnu.org> | |
11574 | ||
11575 | * Makefile.in: *** empty log message *** | |
11576 | ||
11577 | 1993-04-28 Noah Friedman <friedman@gnu.org> | |
11578 | ||
11579 | * src/reader.c: *** empty log message *** | |
11580 | ||
11581 | 1993-04-23 Noah Friedman <friedman@gnu.org> | |
11582 | ||
11583 | * src/alloc.h: entered into RCS | |
11584 | ||
11585 | 1993-04-20 David J. MacKenzie <djm@gnu.org> | |
11586 | ||
11587 | * src/version.c: *** empty log message *** | |
11588 | ||
11589 | * src/files.c, src/allocate.c: | |
11590 | entered into RCS | |
11591 | ||
11592 | * src/reader.c: *** empty log message *** | |
11593 | ||
11594 | * src/lex.c: entered into RCS | |
11595 | ||
11596 | * src/conflicts.c: New file. | |
11597 | ||
11598 | * src/symtab.c: entered into RCS | |
11599 | ||
11600 | * src/alloc.h: New file. | |
11601 | ||
11602 | * src/LR0.c: entered into RCS | |
11603 | ||
11604 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
11605 | ||
11606 | * src/reader.c: New file. | |
11607 | ||
11608 | * src/version.c: *** empty log message *** | |
11609 | ||
11610 | 1993-04-18 Noah Friedman <friedman@gnu.org> | |
11611 | ||
11612 | * Makefile.in: *** empty log message *** | |
11613 | ||
11614 | 1993-04-17 Noah Friedman <friedman@gnu.org> | |
11615 | ||
11616 | * Makefile.in: *** empty log message *** | |
11617 | ||
11618 | 1993-04-15 Richard Stallman <rms@gnu.org> | |
11619 | ||
11620 | * src/main.c, src/files.c: | |
11621 | New file. | |
11622 | ||
11623 | 1993-04-15 Noah Friedman <friedman@gnu.org> | |
11624 | ||
11625 | * configure.in: entered into RCS | |
11626 | ||
11627 | * configure.in: *** empty log message *** | |
11628 | ||
11629 | * configure.in: New file. | |
11630 | ||
11631 | 1993-04-14 Richard Stallman <rms@gnu.org> | |
11632 | ||
11633 | * Makefile.in: New file. | |
11634 | ||
11635 | 1993-04-13 Richard Stallman <rms@gnu.org> | |
11636 | ||
11637 | * src/version.c: New file. | |
11638 | ||
11639 | 1993-03-25 Richard Stallman <rms@gnu.org> | |
11640 | ||
11641 | * src/output.c: entered into RCS | |
11642 | ||
11643 | 1992-09-25 Richard Stallman <rms@gnu.org> | |
11644 | ||
11645 | * configure.bat: entered into RCS | |
11646 | ||
11647 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
11648 | ||
11649 | * src/vmsgetargs.c: entered into RCS | |
11650 | ||
11651 | 1992-06-22 Richard Stallman <rms@gnu.org> | |
11652 | ||
11653 | * doc/bison.rnh: entered into RCS | |
11654 | ||
11655 | 1992-04-20 David J. MacKenzie <djm@gnu.org> | |
11656 | ||
11657 | * README: entered into RCS | |
11658 | ||
11659 | 1992-01-22 Richard Stallman <rms@gnu.org> | |
11660 | ||
11661 | * src/machine.h: entered into RCS | |
11662 | ||
11663 | 1991-12-21 Richard Stallman <rms@gnu.org> | |
11664 | ||
11665 | * src/lalr.c, src/closure.c: | |
11666 | entered into RCS | |
11667 | ||
11668 | 1991-12-20 Richard Stallman <rms@gnu.org> | |
11669 | ||
11670 | * src/state.h: entered into RCS | |
11671 | ||
11672 | 1991-12-18 Richard Stallman <rms@gnu.org> | |
11673 | ||
11674 | * src/print.c, src/nullable.c, src/derives.c: | |
11675 | entered into RCS | |
11676 | ||
11677 | 1991-11-03 David J. MacKenzie <djm@gnu.org> | |
11678 | ||
11679 | * src/warshall.c, src/types.h, src/symtab.h, src/lex.h, src/gram.c, src/gram.h, src/files.h: | |
11680 | entered into RCS | |
11681 | ||
11682 | 1988-09-09 Richard Stallman <rms@gnu.org> | |
11683 | ||
11684 | * src/bison.hairy: entered into RCS | |
11685 | ||
11686 | 1987-12-16 Richard Stallman <rms@gnu.org> | |
11687 | ||
11688 | * REFERENCES: entered into RCS | |
11689 | ||
11690 | ----- | |
11691 | ||
11692 | Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996, 1997, | |
11693 | 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. | |
11694 | ||
11695 | This file is part of Bison, the GNU Compiler Compiler. | |
11696 | ||
11697 | Bison is free software; you can redistribute it and/or modify | |
11698 | it under the terms of the GNU General Public License as published by | |
11699 | the Free Software Foundation; either version 2, or (at your option) | |
11700 | any later version. | |
11701 | ||
11702 | Bison is distributed in the hope that it will be useful, | |
11703 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11704 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
11705 | GNU General Public License for more details. | |
11706 | ||
11707 | You should have received a copy of the GNU General Public License | |
11708 | along with Bison; see the file COPYING. If not, write to | |
11709 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
11710 | Boston, MA 02111-1307, USA. |