examples: don't demonstrate multistart, which is not part of 3.8
[bison.git] / examples / c / reccalc / README.md
blobb89911af2e80f1ee14aae304ea2006c835db3800
1 # reccalc - recursive calculator with Flex and Bison
3 In this example the generated parser is pure and reentrant: it can be used
4 concurrently in different threads, or recursively.  As a proof of this
5 reentrancy, expressions in parenthesis are tokenized as strings, and then
6 recursively parsed from the parser:
8 ```
9 exp: STR
10   {
11     result r = parse_string ($1);
12     free ($1);
13     if (r.nerrs)
14       {
15         res->nerrs += r.nerrs;
16         YYERROR;
17       }
18     else
19       $$ = r.value;
20   }
21 ```
23 <!---
24 Local Variables:
25 fill-column: 76
26 ispell-dictionary: "american"
27 End:
29 Copyright (C) 2018-2021 Free Software Foundation, Inc.
31 Permission is granted to copy, distribute and/or modify this document
32 under the terms of the GNU Free Documentation License, Version 1.3 or
33 any later version published by the Free Software Foundation; with no
34 Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
35 Texts.  A copy of the license is included in the "GNU Free
36 Documentation License" file as part of this distribution.
38 --->