Commit Graph

105 Commits

Author SHA1 Message Date
Paul Eggert
b56471a689 Say "bison -o foo.c foo.y", not "bison foo.y -o foo.c",
so that the commands still work even if POSIXLY_CORRECT is set.
2002-10-14 08:43:36 +00:00
Paul Eggert
68449b3ad3 (Calling Convention): Fix strncmp typo. 2002-10-11 21:19:27 +00:00
Paul Eggert
72d2299ca0 Minor spelling, grammar, and white space fixes.
(Symbols): Mention that any negative value returned from yylex
signifies end-of-input.  Warn about negative chars.  Mention
the portable Standard C character set.
2002-10-05 04:45:45 +00:00
Akim Demaille
d1a1114f7f * doc/bison.texinfo (Stack Overflow): xref to Recursion.
(Frequently Asked Questions, Parser Stack Overflow): New.
2002-09-24 12:32:36 +00:00
Paul Eggert
262aa8dd59 (Conditions): Say that the exceptions apply only to C LALR(1) parsers. 2002-09-07 06:33:29 +00:00
Akim Demaille
88bce5a2ef Use $accept and $end, as BYacc and BTYacc do, instead of $axiom and $.
* src/symtab.h, src/symtab.c (eoftoken, axiom): Rename as...
(endtoken, accept): these.
* src/reader.c (reader): Set endtoken's default tag to "$end".
Set undeftoken's tag to "$undefined" instead of "$undefined.".
* doc/bison.texinfo (Table of Symbols): Mention $accept and $end.
Adjust.
2002-07-29 17:30:33 +00:00
Akim Demaille
3650b4b8dd * src/output.c (prepare_tokens): Go up to ntokens, not ntokens + 1.
* doc/bison.texinfo (Decl Summary): s/$illegal/$undefined./.
* tests/regression.at (Web2c Actions): Adjust.
2002-07-26 06:24:11 +00:00
Akim Demaille
fae437e835 * doc/bison.texinfo: Properly set the ``header'' part.
Use @dircategory ``GNU programming tools'' as per Texinfo's
documentation.
Use @copying.
2002-07-09 17:01:42 +00:00
Paul Hilfinger
676385e29c Initial check-in introducing experimental GLR parsing. See entry in
ChangeLog dated 2002-06-27 from Paul Hilfinger for details.
2002-06-28 02:26:44 +00:00
Akim Demaille
60491a948b * data/bison.simple, data/bison.c++: Rename as...
* data/yacc.c, data/lalr1.cc: these.
* doc/bison.texinfo (Environment Variables): Remove.
2002-06-27 12:08:20 +00:00
Akim Demaille
c732d2c6dc * doc/bison.texinfo: Document ability to have multiple
prologue sections.
2002-06-19 07:46:11 +00:00
Akim Demaille
ec3bc3961d * doc/bison.texinfo (Debugging): Split into...
(Tracing): this new section, its former contents, and...
(Understanding): this new section.
* src/getargs.h, src/getargs.c (verbose_flag): Remove, replaced
by...
(report_flag): this.
Adjust all dependencies.
(report_args, report_types, report_argmatch): New.
(usage, getargs): Report/support -r, --report.
* src/options.h
(struct option_table_struct): Rename as..,
(struct option_table_s): this.
Rename the `set_flag' member to `flag' to match with getopt_long's
struct.
* src/options.c (option_table): Split verbose into an entry for
%verbose, and another for --verbose.
Support --report/-r, so remove -r from the obsolete --raw.
* src/print.c: Attach full item sets and lookaheads reports to
report_flag instead of trace_flag.
* lib/argmatch.h, lib/argmatch.c: New, from Fileutils 4.1.
2002-05-25 16:12:40 +00:00
Akim Demaille
b2d52318fa * data/bison.simple (yyparse): Do not implement @$ = @1.
(YYLLOC_DEFAULT): Adjust to do it.
* doc/bison.texinfo (Location Default Action): Fix.
2002-05-02 16:40:54 +00:00
Akim Demaille
fdbcd8e289 Remove the so called hairy (semantic) parsers.
* src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove.
* src/gram.h, src/gram.c (semantic_parser): Remove.
(rule_t): Remove the guard and guard_line members.
* src/lex.h (token_t): remove tok_guard.
* src/options.c (option_table): Remove %guard and %semantic_parser
support.
* src/output.c, src/output.h (guards_output): Remove.
(prepare): Adjust.
(token_definitions_output): Don't output the `T'
tokens (???).
(output_skeleton): Don't output the guards.
* src/files.c, src/files.c (attrsfile): Remove.
* src/reader.c (symbol_list): Remove the guard and guard_line
members.
Adjust dependencies.
(parse_guard): Remove.
* data/bison.hairy: Remove.
* doc/bison.texinfo (Environment Variables): Remove occurrences of
BISON_HAIRY.
2002-05-02 15:06:46 +00:00
Akim Demaille
5c0a0514da More. 2002-04-23 14:07:56 +00:00
Paul Eggert
08e49d20f0 Replace @var{...(...}} with something else, as Texinfo 4.2 warns
about that construct.
2002-04-22 22:10:22 +00:00
Akim Demaille
23c5a17453 * src/reader.c (token_translations_init): 256 is now the default
value for the error token, i.e., it will be assigned another
number if the user assigned 256 to one of her tokens.
(reader): Don't force 256 to error.
* doc/bison.texinfo (Symbols): Adjust.
* tests/torture.at (AT_DATA_HORIZONTAL_GRAMMAR)
(AT_DATA_TRIANGULAR_GRAMMAR): Number the tokens as 1, 2, 3
etc. instead of 10, 20, 30 (which was used to `jump' over error
(256) and undefined (2)).
2002-04-22 08:22:11 +00:00
Akim Demaille
3ded9a63e3 * doc/bison.texinfo (Actions): Make clear that `|' is not the same
as Lex/Flex'.
(Debugging): More details about enabling the debugging features.
(Table of Symbols): Describe $$, $n, @$, and @n.
Suggested by Tim Josling.
2002-04-19 14:04:31 +00:00
Akim Demaille
e0c471a9e6 * doc/bison.texinfo: Remove the uses of the obsolete @refill. 2002-04-19 13:35:08 +00:00
Paul Eggert
e966383bf4 * doc/bison.texinfo: Update copyright date.
(Rpcalc Lexer, Symbols, Token Decl): Don't assume ASCII.
(Symbols): Warn about running Bison in one character set,
but compiling and/or running in an incompatible one.
Warn about character code 256, too.
2002-04-04 21:34:34 +00:00
Paul Eggert
cf3b4b64d0 (AUTOMAKE_OPTIONS): Remove. 2002-03-20 07:02:15 +00:00
Paul Eggert
e4e1a4dcb4 (Bison Parser, Debugging): Remove special mention of C++, as it's
treated like C now.
2002-02-14 20:26:54 +00:00
Paul Eggert
e2742e46ba (Debugging): Remove YYSTDERR; it's no longer defined or used.
Also, s/cstdio.h/cstdio/.
2002-01-05 01:25:38 +00:00
Akim Demaille
b5b61c616b %name-prefix is broken.
* src/files.c (spec_name_prefix): Initialize to NULL, not to "yy".
Adjust all dependencies.
* tests/headers.at (export YYLTYPE): Strengthen this test: use
%name-prefix.
Renaming yylval but not yylloc is not consistent.  Now we do.
* src/bison.simple: Prefix yylloc if used.
* doc/bison.texinfo (Decl Summary): Document that.
2001-12-29 14:27:45 +00:00
Akim Demaille
8c9a50bee1 * doc/bison.texinfo: Promote `%long-directive' over
`%long_directive'.
Remove all references to fixed-output-files, yacc is enough.
2001-12-29 14:27:20 +00:00
Akim Demaille
704a47c475 * doc/bison.texinfo: Formatting changes. 2001-12-29 14:25:45 +00:00
Paul Eggert
4947ebdb4c Document that YYDEBUG must be defined to a nonzero value. 2001-12-17 19:43:23 +00:00
Paul Eggert
02a81e05f9 Document YYFPRINTF, YYSTDERR. 2001-12-14 01:51:33 +00:00
Akim Demaille
7093d0f541 Name space cleanup in generated parser.
* doc/bison.texinfo (Bison Parser): Discuss system headers
and their effect on the user name space.
* src/bison.simple:
(YYSTACK_ALLOC, YYSTACK_FREE, union yyalloc, YYSTACK_GAP_MAX,
YYSTACK_BYTES, YYSTACK_RELOCATE): Do not define unless necessary,
i.e. unless ! defined (yyoverflow) || defined (YYERROR_VERBOSE).
(YYSIZE_T): New macro.  Use it instead of size_t, to avoid infringing
on user names when possible.
(YYSTACK_USE_ALLOCA): Do not define; just use any existing defn.
Simplify test for whather <alloca.h> exists.
(<stdlib.h>): Include if we will use malloc, and if standard C or C++.
(<stdio.h>): Include if YYDEBUG.
(yymemcpy): Renamed from __yy_memcpy.  Do not define unless
! defined (yyoverflow) && ! defined (yymemcpy).
(yymemcpy, yyparse): Rename local variables as needed so that
they all begin with 'yy'.
(yystrlen, yystpcpy): New functions.
(YY_DECL_NON_LSP_VARIABLES): Renamed from _YY_DECL_VARIABLES.
All uses changed.
(yyparse): size_t -> YYSIZE_T.  Use yystrlen and yystpcpy
instead of relying on string.h functions.  Use YYSTACK_ALLOC
and YYSTACK_FREE instead of malloc and free.
2001-11-30 14:00:14 +00:00
Marc Autret
a220f55509 Revert doc patch. 2001-11-26 19:13:40 +00:00
Marc Autret
b83f0407c6 * doc/bison.texinfo (Mystery Conflicts): Hint '-v' use.
From Golubev I. N.
2001-11-25 13:02:55 +00:00
Akim Demaille
9edcd89542 * doc/bison.texinfo: Use $' as shell prompt, not %'.
Use @kbd to denote user input.
(Language and Grammar): ANSIfy the example.
Adjust its layout for info/notinfo.
(Location Tracking Calc): Output error messages to stderr.
Output locations in a more GNUtically correct way.
Fix a couple of Englishos.
Adjust @group/@end group pairs.
2001-11-12 09:36:31 +00:00
Akim Demaille
7da99edea7 %expext was not functioning at all.
* src/conflicts.c (expected_conflicts): Set to -1.
(conflict_report): Use ngettext.
(conflicts_print): Check %expect and make its violation an error.
* doc/bison.texinfo (Expect Decl): Adjust.
* configure.in (AM_GNU_GETTEXT): Ask for ngettext.
* tests/regression.at (%expect not enough, %expect right)
(%expect too much): New.
2001-11-12 09:33:38 +00:00
Akim Demaille
1964ad8c34 Formatting changes. 2001-11-05 09:14:55 +00:00
Akim Demaille
d8988b2fff * doc/bison.texinfo (Decl Summary): Split the list into
`directives for grammars' and `directives for bison'.
Sort'em.
Add description of `%name-prefix', `file-prefix', and `output'.
Promote `-' over `_' in directive names.
(Bison Options): s/%locactions/%locations/.  Nice Freudian slip.
Simplify the description of `--name-prefix'.
Promote `-' over `_' in directive names.
Promote `--output' over `--output-file'.
Fix the description of `--defines'.
* tests/output.at: Exercise %file-prefix and %output.
2001-11-05 08:50:46 +00:00
Akim Demaille
92fcb5efbe Really update refcard.tex... 2001-11-02 17:20:22 +00:00
Akim Demaille
ee006e3a4c Adjust. 2001-10-04 15:12:55 +00:00
Akim Demaille
c07c873533 Adjust. 2001-10-04 15:09:51 +00:00
Akim Demaille
342b8b6e21 Merge in branch-1_29. 2001-10-04 14:55:21 +00:00
Akim Demaille
8484abf02c Remove from repo. 2001-10-04 13:32:34 +00:00
Akim Demaille
bafbfdd24c Update. 2001-10-04 13:31:41 +00:00
Akim Demaille
3a7bc75ff7 Remove for the repo. 2001-10-04 13:21:02 +00:00
Akim Demaille
40b97583b8 Remove. 2001-10-04 13:20:00 +00:00
Pascal Bart
a474de9b9a Regen. 2001-09-20 19:11:28 +00:00
Marc Autret
75f5aaea27 * doc/bison.texinfo: Adjust terminologies about prologue and epilogue
sections of Bison.
2001-09-20 18:24:27 +00:00
Robert Anisko
bbb5bcc6f8 Revert to 1.28c 2001-08-25 13:13:14 +00:00
Pascal Bart
667a550e7b More cvsignore. 2001-08-23 22:51:37 +00:00
Akim Demaille
683e29a634 Regen. 2001-08-15 08:38:25 +00:00
Akim Demaille
f9a8293a3f * doc/bison.texinfo (Table of Symbols): Document
YYSTACK_USE_ALLOCA.
2001-08-15 08:25:10 +00:00
Pascal Bart
f2b5126e47 Apply GNU Free Documentation License to manual. 2001-08-14 14:13:16 +00:00