[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
10.1.6 A Complete C++ Example
This section demonstrates the use of a C++ parser with a simple but complete example. This example should be available on your system, ready to compile, in the directory .../bison/examples/calc++. It focuses on the use of Bison, therefore the design of the various C++ classes is very naive: no accessors, no encapsulation of members etc. We will use a Lex scanner, and more precisely, a Flex scanner, to demonstrate the various interactions. A hand-written scanner is actually easier to interface with.
10.1.6.1 Calc++ — C++ Calculator | The specifications | |
10.1.6.2 Calc++ Parsing Driver | An active parsing context | |
10.1.6.3 Calc++ Parser | A parser class | |
10.1.6.4 Calc++ Scanner | A pure C++ Flex scanner | |
10.1.6.5 Calc++ Top Level | Conducting the band |
This document was generated on August 25, 2013 using texi2html 5.0.