]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | [/============================================================================== |
2 | Copyright (C) 2001-2011 Joel de Guzman | |
3 | Copyright (C) 2001-2011 Hartmut Kaiser | |
4 | ||
5 | Distributed under the Boost Software License, Version 1.0. (See accompanying | |
6 | file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | |
7 | ===============================================================================/] | |
8 | ||
9 | [section Quick Start] | |
10 | ||
11 | [heading Why would you want to use Spirit.Qi?] | |
12 | ||
13 | Spirit.Qi is designed to be a practical parsing tool. The ability to generate a | |
14 | fully-working parser from a formal EBNF specification inlined in C++ | |
15 | significantly reduces development time. Programmers typically approach parsing | |
16 | using ad hoc hacks with primitive tools such as scanf. Even regular-expression | |
17 | libraries (such as boost regex) or scanners (such as Boost tokenizer) do not | |
18 | scale well when we need to write more elaborate parsers. Attempting to write | |
19 | even a moderately-complex parser using these tools leads to code that is hard to | |
20 | understand and maintain. | |
21 | ||
22 | One prime objective is to make the tool easy to use. When one thinks of a | |
23 | parser generator, the usual reaction is "it must be big and complex with a | |
24 | steep learning curve." Not so. Spirit is designed to be fully scalable. The | |
25 | library is structured in layers. This permits learning on an as-needed basis, | |
26 | after only learning the minimal core and basic concepts. | |
27 | ||
28 | For development simplicity and ease in deployment, the entire library | |
29 | consists of only header files, with no libraries to link against or build. | |
30 | Just put the Spirit distribution in your include path, compile and run. Code | |
31 | size? -very tight -essentially comparable to hand written recursive descent | |
32 | code. | |
33 | ||
34 | Our tutorials will walk you through the simplest Spirit examples, incrementally | |
35 | building on top of the earlier examples as we expose more and more features and | |
36 | techniques. We will try to be as gentle as possible with the learning curve. | |
37 | We will present the tutorials in a cookbook style approach. This style of | |
38 | presentation is based on our BoostCon '07 and BoostCon '08 slides. | |
39 | ||
40 | Have fun! | |
41 | ||
42 | [endsect] [/ Quickstart] |