X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/035aa4a0bbf1847843c48312d892f79599ba7d8a..9ecafbbfe7a17aa3c2a5f370ffd2ef0616576fc1:/ChangeLog diff --git a/ChangeLog b/ChangeLog index c52dc0db..0036b898 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,306 @@ +2006-01-02 Joel E. Denny + + * data/glr.c: Reformat whitespace with tabs. + (b4_lpure_formals): Remove this unused m4 macro. + * tests/cxx-type.at: Reformat whitespace with tabs. + (_AT_TEST_GLR_CXXTYPES): In union Node, rename node_info to nodeInfo + since it's a member. Rename type to isNterm for clarity. + +2005-12-29 Akim + + Let glr.cc catch up with symbol_value_print. + * data/glr.cc (b4_yysymprint_generate): Replace by... + (b4_yy_symbol_print_generate): this. + (yy_symbol_print, yy_symbol_value_print): Declare them. + +2005-12-28 Paul Eggert + + * src/location.h (boundary): Note that a line or column equal + to INT_MAX indicates an overflow. + * src/scan-gram.l: Include verify.h. Don't include get-errno.h. + (rule_length_overflow, increment_rule_length, add_column_width): + New functions. + ({id}, "\"", "'"): + ("}"): + Use increment_rule_length rather than incrementing it by hand. + (adjust_location, handle_syncline): Diagnose overflow. + (handle_action_dollar, handle_action_at): + Fix bug with monstrosities like $-2147483648. + Remove now-unnecessary checks. + (scan_integer): Verify assumptions and remove now-unnecessary checks. + (convert_ucn_to_byte): Verify assumptions. + (handle_syncline): New arg LOC. All callers changed. + Don't store through a value derived from char const * pointer. + + * src/reader.c (grammar_rule_check): Rewrite slightly to avoid + GCC warnings. + +2005-12-27 Paul Eggert + + * src/reader.c (grammar_midrule_action, grammar_symbol_append): + Remove unnecessary forward static decls. + +2005-12-27 Akim Demaille + + * src/reader.c (grammar_current_rule_check): Also check that $$ + is used. + Take the rule to check as argument, hence rename as... + (grammar_rule_check): this. + * src/reader.h, src/reader.c (grammar_rule_begin, grammar_rule_end): + Rename as... + (grammar_rule_begin, grammar_rule_end): these, for consistency. + (grammar_midrule_action, grammar_symbol_append): Now static. + * tests/torture.at (input): Don't rely on the default action + being always performed. + * tests/calc.at: "Set" $$ even when the action is "cut" with + YYERROR or other. + * tests/actions.at (Exotic Dollars): Instead of using unused + values, check that the warning is issued. + +2005-12-22 Paul Eggert + + * NEWS: Improve wording for unused-value warnings. + +2005-12-22 Akim Demaille + + * data/lalr1.cc, data/yacc.c, data/glr.c, data/c.m4 + (b4_yysymprint_generate): Rename as... + (b4_yy_symbol_print_generate): this. + Generate yy_symbol_print instead of yysymprint. + Generate also yy_symbol_value_print, and use it. + +2005-12-22 Akim Demaille + + * NEWS: Warn about unused values. + * src/symlist.h, src/symlist.c (symbol_list, symbol_list_new): Add + a `used' member. + (symbol_list_n_get, symbol_list_n_used_set): New. + (symbol_list_n_type_name_get): Use symbol_list_n_get. + * src/scan-gram.l (handle_action_dollar): Flag used symbols. + * src/reader.c (grammar_current_rule_check): Check that values are + used. + * src/symtab.c (symbol_print): Accept 0. + * tests/existing.at: Remove the type information. + Empty the actions. + Remove useless actions (beware of mid-rule actions: perl -000 + -pi -e 's/\s*\{\}(?=[\n\s]*[|;])//g'). + * tests/actions.at (Exotic Dollars): Use unused values. + * tests/calc.at: Likewise. + * tests/glr-regression.at (No users destructors if stack 0 deleted): + Likewise. + + * src/gram.c (rule_useful_p, rule_never_reduced_p): Use + rule_useful_p. + +2005-12-21 Paul Eggert + + Undo 2005-12-01 tentative license wording change. The wording is + still being reviewed by the lawyers, and we don't want to wait for + them before publishing a test release. For now, revert to the + previous wording. + * NEWS: Undo 2005-12-01 change. + * data/glr.c: Revert to previous license wording. + * data/glr.cc: Likewise. + * data/lalr1.cc: Likewise. + * data/location.cc: Likewise. + * data/yacc.c: Likewise. + + * NEWS: Reword %destructor vs YYABORT etc. + * data/glr.c: Use American spacing, for consistency. + * data/glr.cc: Likewise. + * data/lalr1.cc: Likewise. + * data/yacc.c: Likewise. + * data/yacc.c: Reformat comments slightly. + * doc/bison.texinfo: Replace "non-" with "non" when that makes sense, + for consistency. Fix some spelling errors and reword recently-included + text slightly. + * tests/cxx-type.at: Cast results of malloc, for C++. + +2005-12-21 Joel E. Denny + + * tests/cxx-type.at: Construct a tree, count the parents of shared + nodes, and free each node once and only once. Previously, the memory + for semantic values was leaked instead. + +2005-12-21 Joel E. Denny + + * data/glr.c (struct yyGLRStack): If pure, add yyval and yyloc members. + (yylval, yylloc): If pure, #define to yystackp->yyval and + yystackp->yyloc similar to yychar and yynerrs. + (yyparse): If pure, remove local yylval and yylloc. Add local + yystackp to accommodate pure definitions of yylval and yylloc. + (b4_lex_param, b4_lyyerror_args, b4_lpure_args): If pure, change + yylvalp and yyllocp to &yylval and &yylloc. + (nerrs, char, lval, lloc): If pure, add #define's for b4_prefix[] + namespace. Previously, nerrs and char were missing, but lval and lloc + weren't necessary. + (yyprocessOneStack, yyreportSyntaxError, yyrecoverSyntaxError): Remove + yylvalp and yyllocp parameters since, if pure, these are now always + accessible through yystackp. If not pure, they are still accessible + globally. + * data/glr.c, data/yacc.c (YYLLOC_DEFAULT): Change `if (N)' to + `if (YYID (N))' to pacify lint. + +2005-12-21 Akim Demaille + + YYACCEPT, YYERROR, and YYABORT, as user actions, should not + destroy the RHS symbols of a rule. + * data/yacc.c (yylen): Initialize to 0. + Keep its value to the number of items to possibly shift. + In particular, a regular successful parse that ends on YYFINAL by + a (internal) YYACCEPT must not have yylen != 0. + (yyerrorlab, yyreturn): Pop the RHS. + Reorder a bit to emphasize the `shifting' bits of code. + (YYPOPSTACK): Now accept a number of items to pop. + * data/lalr1.cc: Likewise. + * data/glr.c: Formatting changes. + Use goto instead of fall through. + * doc/bison.texinfo (Destructor Decl): Complete. + +2005-12-20 Juan Manuel Guerrero + + * Makefile.am: DJGPP specific files added to EXTRA_DIST. + * djgpp/Makefile.maint: Fix PACKAGE variable computation. + * djgpp/config.bat: Replace every occurence of the file name + scan-gram-c.c with c-scan-gram.c. The same for scan-skel-c.c with + c-scan-skel.c to conform with the 8.3 file name restriction on MSDOS. + * djgpp/config.sed: Replace every occurence of the file name + scan-gram-c.c with c-scan-gram.c. The same for scan-skel-c.c with + c-scan-skel.c to conform with the 8.3 file name restriction on MSDOS. + * djgpp/djunpack.bat: DJGPP specific file. + * djgpp/fnchange.lst: DJGPP specific file. + * djgpp/README.in: Add new information about how to unpack the bison + source on MSDOS and other systems which have 8.3 file name restrictions + using djunpack.bat and fnchange.lst. + +2005-12-12 Paul Eggert + + * bootstrap (build_cvs_prefix): Remove; unused. + (CVS_PREFIX): Adjust to yesterday's Savannah reorganization + when getting gnulib. + +2005-12-12 "Joel E. Denny" + + * data/glr.c: Reorder typedef declarations for structs to match order + of struct declarations. + Rename yystack everywhere to yystackp except in yyparse where it's not + a pointer. + (yyglrShift): Change parameter YYSTYPE yysval to YYSTYPE* yyvalp for + consistency. + (yyis_table_ninf): Change 0 to YYID (0) to pacify lint. + (yyreportSyntaxError): Add /*ARGSUSED*/ to pacify lint. + (yyparse): Change while (yytrue) to while ( YYID (yytrue)) to pacify + lint. + +2005-12-09 Paul Eggert + + * tests/sets.at (Accept): Fix typos in regular expression used to + sed out the final state number. + + Work around portability problem on Solaris 10: flex-generated + files include before , which messes up + because the latter defines __EXTENSIONS__. Address the problem + by creating two new little files that include first, + then include the flex-generated files. Rewrite everyone else + to include first, as well. + * lib/timevar.c: Always include "config.h". + * src/Makefile.am (bison_SOURCES): Replace scan-gram.l with + scan-gram-c.c, and scan-skel.l with scan-skel-c.c. + (EXTRA_bison_SOURCES): New macro. + * src/scan-gram-c.c, src/scan-skel-c.c: New files. + * src/system.h: Don't include config.h. + * src/LR0.c: Include first. + * src/assoc.c: Likewise. + * src/closure.c: Likewise. + * src/complain.c: Likewise. + * src/conflicts.c: Likewise. + * src/derives.c: Likewise. + * src/files.c: Likewise. + * src/getargs.c: Likewise. + * src/gram.c: Likewise. + * src/lalr.c: Likewise. + * src/location.c: Likewise. + * src/main.c: Likewise. + * src/muscle_tab.c: Likewise. + * src/nullable.c: Likewise. + * src/output.c: Likewise. + * src/parse-gram.y: Likewise. + * src/print.c: Likewise. + * src/print_graph.c: Likewise. + * src/reader.c: Likewise. + * src/reduce.c: Likewise. + * src/relation.c: Likewise. + * src/state.c: Likewise. + * src/symlist.c: Likewise. + * src/symtab.c: Likewise. + * src/tables.c: Likewise. + * src/uniqstr.c: Likewise. + * src/vcg.c: Likewise. + + * src/parse-gram.y: Fix minor problems uncovered by lint. + (current_lhs, current_lhs_location): Now static. + (current_assoc): Remove unused variable. + + Cleanups so that Bison-generated parsers have less lint. + * data/c.m4 (b4_yydestruct_generate, b4_yysymprint_generate): + Prepend /*ARGSUSED*/, for lint's sake. + * data/glr.c (YYUSE): Properly parenthesize, and use an alternate + definition if 'lint' is defined. + (YYID): New macro (or function, if lint). + All uses of /*CONSTCOND*/0 replaced by YYID(0). + * data/yacc.c: Likewise. + * data/glr.c (yyuserAction, yyuserMerge, yy_reduce_print): + (yyrecoverSyntaxError): Prepend /*ARGSUSED*/. + * data/glr.cc (YYLLOC_DEFAULT): Omit /*CONSTCOND*/ since this code + is C++ only. + * data/lalr1.cc (YYUSE): Just use a cast, since this code is C++ only. + * data/yacc.c (YYSTACK_FREE) [defined YYSTACK_ALLOC]: + Use YYID(0) rather than 0, for lint. + (yystrlen): Rewrite to avoid lint warning about ptrdiff_t overflow. + (yysyntax_error): Rewrite to avoid lint warnings about parenthesization. + +2005-12-07 Paul Eggert + + * tests/glr-regression.at + (Improper handling of embedded actions and dollar(-N) in GLR parsers): + Close memory leak reported by twlevo. + +2005-12-06 "Joel E. Denny" + + * data/glr.c (yyprocessOneStack, yyparse): Synchronize the shift for + all stacks. + (yyparse): Iterate another stack in order to call user destructors. + * tests/glr-regression.at (No users destructors if stack 0 deleted): + New test case. + (Duplicated user destructor for lookahead): This test now is expected + to succeed. + +2005-12-01 Paul Eggert + + * NEWS: Document the following change. + * data/yacc.c: Say "parser skeleton" rather than "file", since + it's no longer just a file. + * data/glr.c: Grant a special exception for C GLR parsers, that + reads like the already-existing exception for C LALR(1) parsers. + * data/glr.cc: Likewise. + * data/lalr1.cc: Likewise. + * data/location.cc: Likewise. + * data/yacc.c: Reword the "written by" statement to clarify that + it was the parser skeleton, not the entire output file. + * data/glr.c: Written by Paul Hilfinger. + * data/glr.cc: Written by Akim Demaille. + * data/lalr1.cc: Likewise. + 2005-11-18 Paul Eggert + * data/yacc.c (yy_reduce_print, YY_REDUCE_PRINT): + Fix typos in previous change that broke 'make check'. + YY_REDUCE_PRINT cannot be a pseudo-varargs macro; that isn't + supported in C. + * tests/calc.at (_AT_CHECK_CALC,_AT_CHECK_CALC_ERROR): + Don't check NUM-STDERR-LINES, since the output format is fluctuating. + We can revert this once things settle down. + * src/conflicts.c (conflicts_print): Don't print file name twice when %expect fails because there were no conflicts. * doc/bison.texinfo (Expect Decl): Tighten up wording in previous