|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r55869 - in trunk/libs/spirit: doc doc/html doc/html/spirit doc/html/spirit/abstracts doc/html/spirit/karma doc/html/spirit/karma/performance_measurements doc/html/spirit/karma/performance_measurements/numeric_performance doc/html/spirit/karma/quick_reference doc/html/spirit/karma/quick_reference/primitive_generators doc/html/spirit/karma/reference doc/html/spirit/karma/reference/auxiliary doc/html/spirit/karma/reference/binary doc/html/spirit/karma/reference/char doc/html/spirit/karma/reference/directive doc/html/spirit/karma/reference/generator_concepts doc/html/spirit/karma/reference/numeric doc/html/spirit/karma/reference/operator doc/html/spirit/karma/tutorials doc/html/spirit/lex doc/html/spirit/lex/abstracts doc/html/spirit/lex/abstracts/lexer_primitives doc/html/spirit/lex/reference doc/html/spirit/lex/reference/concepts doc/html/spirit/lex/tutorials doc/html/spirit/notes doc/html/spirit/qi doc/html/spirit/qi/quick_reference doc/html/spirit/qi/quick_reference/qi_parsers doc/html/spirit/qi/reference doc/html/spirit/qi/reference/auxiliary doc/html/spirit/qi/reference/char doc/html/spirit/qi/reference/directive doc/html/spirit/qi/reference/parser_concepts doc/html/spirit/qi/reference/string doc/html/spirit/qi/tutorials doc/html/spirit/structure doc/html/spirit/support doc/karma example/karma
From: hartmut.kaiser_at_[hidden]
Date: 2009-08-29 17:02:15
Author: hkaiser
Date: 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
New Revision: 55869
URL: http://svn.boost.org/trac/boost/changeset/55869
Log:
Spirit: added more docs
Added:
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/stream.html (contents, props changed)
trunk/libs/spirit/doc/html/spirit/karma/reference/binary/
trunk/libs/spirit/doc/html/spirit/karma/reference/binary.html (contents, props changed)
trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_big.html (contents, props changed)
trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_little.html (contents, props changed)
trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_native.html (contents, props changed)
Text files modified:
trunk/libs/spirit/doc/html/index.html | 20
trunk/libs/spirit/doc/html/spirit/abstracts.html | 15
trunk/libs/spirit/doc/html/spirit/abstracts/parsing_expression_grammar.html | 105 +-
trunk/libs/spirit/doc/html/spirit/abstracts/syntax_diagram.html | 76 +-
trunk/libs/spirit/doc/html/spirit/acknowledgments.html | 117 +--
trunk/libs/spirit/doc/html/spirit/faq.html | 89 +-
trunk/libs/spirit/doc/html/spirit/introduction.html | 303 +++++----
trunk/libs/spirit/doc/html/spirit/karma.html | 24
trunk/libs/spirit/doc/html/spirit/karma/performance_measurements.html | 24
trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance.html | 22
trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/double_performance.html | 257 +++++---
trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/format_performance.html | 255 +++++---
trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/int_performance.html | 257 +++++---
trunk/libs/spirit/doc/html/spirit/karma/quick_reference.html | 23
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/common_notation.html | 102 +-
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/compound_attribute_rules.html | 193 +++---
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/non_terminals.html | 303 ++++++----
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/phoenix.html | 40
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators.html | 31
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/auxiliary.html | 204 ++++--
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/binary.html | 269 +++++---
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/char.html | 637 ++++++++++++---------
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/directives.html | 684 +++++++++++++---------
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/floating_point.html | 302 +++++----
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/operators.html | 272 +++++----
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/signed_int.html | 296 +++++----
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/string.html | 138 ++-
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/unsigned_int.html | 393 +++++++-----
trunk/libs/spirit/doc/html/spirit/karma/quick_reference/semantic_actions.html | 25
trunk/libs/spirit/doc/html/spirit/karma/reference.html | 25
trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary.html | 34
trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eol.html | 112 ++-
trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eps.html | 189 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/lazy.html | 177 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/char.html | 38
trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_class.html | 596 +++++++++++--------
trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_generator.html | 612 ++++++++++++--------
trunk/libs/spirit/doc/html/spirit/karma/reference/directive.html | 56
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/alignment.html | 550 ++++++++++--------
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/buffer.html | 140 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/delimit.html | 205 +++---
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/maxwidth.html | 169 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/omit.html | 128 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/repeat.html | 258 ++++----
trunk/libs/spirit/doc/html/spirit/karma/reference/directive/upperlower.html | 183 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts.html | 19
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/binarygenerator.html | 198 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/generator.html | 235 ++++---
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/narygenerator.html | 166 +++--
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/primitivegenerator.html | 97 +-
trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/unarygenerator.html | 240 ++++----
trunk/libs/spirit/doc/html/spirit/karma/reference/karma_basics.html | 181 ++++-
trunk/libs/spirit/doc/html/spirit/karma/reference/numeric.html | 31
trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/floating_point.html | 1166 +++++++++++++++++++++++----------------
trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/signed_int.html | 874 ++++++++++++++++++-----------
trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/unsigned_int.html | 1009 +++++++++++++++++++++-------------
trunk/libs/spirit/doc/html/spirit/karma/reference/operator.html | 58 -
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/alternative.html | 131 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/and_predicate.html | 123 ++-
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/kleene.html | 136 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/list.html | 151 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/not_predicate.html | 126 ++-
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/optional.html | 129 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/plus.html | 135 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/operator/sequence.html | 137 ++--
trunk/libs/spirit/doc/html/spirit/karma/reference/stream.html | 581 ++++++++++++-------
trunk/libs/spirit/doc/html/spirit/karma/reference/string.html | 362 +++++++-----
trunk/libs/spirit/doc/html/spirit/karma/tutorials.html | 17
trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_attributes.html | 195 +++---
trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_complex.html | 46
trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_easier_complex.html | 20
trunk/libs/spirit/doc/html/spirit/karma/tutorials/quick_start.html | 32
trunk/libs/spirit/doc/html/spirit/karma/tutorials/semantic_actions.html | 86 +-
trunk/libs/spirit/doc/html/spirit/karma/tutorials/warming_up.html | 173 ++---
trunk/libs/spirit/doc/html/spirit/lex.html | 20
trunk/libs/spirit/doc/html/spirit/lex/abstracts.html | 20
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_attributes.html | 20
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_parsing.html | 22
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives.html | 20
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_primitives.html | 20
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_definition.html | 21
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_values.html | 138 ++--
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_semantic_actions.html | 448 +++++++++------
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_states.html | 45
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_static_model.html | 59 -
trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_tokenizing.html | 83 +-
trunk/libs/spirit/doc/html/spirit/lex/lexer_introduction.html | 88 +-
trunk/libs/spirit/doc/html/spirit/lex/quick_reference.html | 19
trunk/libs/spirit/doc/html/spirit/lex/reference.html | 21
trunk/libs/spirit/doc/html/spirit/lex/reference/concepts.html | 19
trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/lexer.html | 679 ++++++++++++++---------
trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/token.html | 15
trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/tokendef.html | 15
trunk/libs/spirit/doc/html/spirit/lex/reference/lexer_class.html | 49
trunk/libs/spirit/doc/html/spirit/lex/reference/token_class.html | 15
trunk/libs/spirit/doc/html/spirit/lex/reference/tokendef_class.html | 17
trunk/libs/spirit/doc/html/spirit/lex/tutorials.html | 24
trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart1.html | 108 +-
trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart2.html | 125 +--
trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart3.html | 196 +++---
trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_tutorials.html | 51 -
trunk/libs/spirit/doc/html/spirit/notes.html | 18
trunk/libs/spirit/doc/html/spirit/notes/porting_from_spirit_1_8_x.html | 327 ++++++----
trunk/libs/spirit/doc/html/spirit/notes/style_guide.html | 52
trunk/libs/spirit/doc/html/spirit/preface.html | 223 ++++---
trunk/libs/spirit/doc/html/spirit/qi.html | 18
trunk/libs/spirit/doc/html/spirit/qi/quick_reference.html | 18
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/common_notation.html | 89 +-
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/compound_attribute_rules.html | 216 ++++---
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/non_terminals.html | 313 ++++++----
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/phoenix.html | 40
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers.html | 15
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/action.html | 60 +
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/auxiliary.html | 211 ++++--
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/binary.html | 233 +++++--
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/char.html | 581 +++++++++++-------
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/directive.html | 297 ++++++----
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/numeric.html | 381 ++++++++-----
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/operator.html | 385 +++++++-----
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/string.html | 189 +++--
trunk/libs/spirit/doc/html/spirit/qi/quick_reference/semantic_actions.html | 25
trunk/libs/spirit/doc/html/spirit/qi/reference.html | 17
trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary.html | 31
trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary/attr.html | 187 +++--
trunk/libs/spirit/doc/html/spirit/qi/reference/basics.html | 87 +-
trunk/libs/spirit/doc/html/spirit/qi/reference/char.html | 35
trunk/libs/spirit/doc/html/spirit/qi/reference/char/lit_char_.html | 765 +++++++++++++++-----------
trunk/libs/spirit/doc/html/spirit/qi/reference/directive.html | 35
trunk/libs/spirit/doc/html/spirit/qi/reference/directive/no_case.html | 157 +++--
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts.html | 15
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/binaryparser.html | 189 +++--
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/naryparser.html | 147 ++--
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/parser.html | 227 ++++---
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/primitiveparser.html | 77 +-
trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/unaryparser.html | 143 ++--
trunk/libs/spirit/doc/html/spirit/qi/reference/string.html | 25
trunk/libs/spirit/doc/html/spirit/qi/reference/string/lit_string.html | 417 ++++++++------
trunk/libs/spirit/doc/html/spirit/qi/reference/string/symbols.html | 583 +++++++++++--------
trunk/libs/spirit/doc/html/spirit/qi/tutorials.html | 17
trunk/libs/spirit/doc/html/spirit/qi/tutorials/complex___our_first_complex_parser.html | 50
trunk/libs/spirit/doc/html/spirit/qi/tutorials/employee___parsing_into_structs.html | 187 +++---
trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___asts_.html | 267 ++++----
trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___error_handling.html | 185 +++--
trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list___stuffing_numbers_into_a_std__vector.html | 33
trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_attribute___one_more__with_style.html | 44
trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_redux___list_syntax.html | 25
trunk/libs/spirit/doc/html/spirit/qi/tutorials/quick_start.html | 23
trunk/libs/spirit/doc/html/spirit/qi/tutorials/roman_numerals.html | 153 ++--
trunk/libs/spirit/doc/html/spirit/qi/tutorials/semantic_actions.html | 68 +-
trunk/libs/spirit/doc/html/spirit/qi/tutorials/sum___adding_numbers.html | 113 ++-
trunk/libs/spirit/doc/html/spirit/qi/tutorials/warming_up.html | 151 ++--
trunk/libs/spirit/doc/html/spirit/references.html | 447 ++++++++++-----
trunk/libs/spirit/doc/html/spirit/repository.html | 17
trunk/libs/spirit/doc/html/spirit/structure.html | 15
trunk/libs/spirit/doc/html/spirit/structure/include.html | 77 +-
trunk/libs/spirit/doc/html/spirit/support.html | 19
trunk/libs/spirit/doc/html/spirit/support/multi_pass.html | 717 +++++++++++++-----------
trunk/libs/spirit/doc/html/spirit/what_s_new.html | 271 ++++----
trunk/libs/spirit/doc/karma.qbk | 6
trunk/libs/spirit/doc/karma/auxiliary.qbk | 2
trunk/libs/spirit/doc/karma/basics.qbk | 22
trunk/libs/spirit/doc/karma/binary.qbk | 425 ++++++++++++++
trunk/libs/spirit/doc/karma/char.qbk | 6
trunk/libs/spirit/doc/karma/directive.qbk | 2
trunk/libs/spirit/doc/karma/numeric.qbk | 96 ++
trunk/libs/spirit/doc/karma/operator.qbk | 2
trunk/libs/spirit/doc/karma/quick_reference.qbk | 105 ++-
trunk/libs/spirit/doc/karma/stream.qbk | 9
trunk/libs/spirit/doc/spirit2.qbk | 10
trunk/libs/spirit/example/karma/reference.cpp | 90 +++
170 files changed, 16376 insertions(+), 12265 deletions(-)
Modified: trunk/libs/spirit/doc/html/index.html
==============================================================================
--- trunk/libs/spirit/doc/html/index.html (original)
+++ trunk/libs/spirit/doc/html/index.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,7 +3,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Spirit 2.1</title>
<link rel="stylesheet" href="../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="index.html" title="Spirit 2.1">
<link rel="next" href="spirit/preface.html" title="Preface">
</head>
@@ -18,7 +18,7 @@
</tr></table>
<hr>
<div class="spirit-nav"><a accesskey="n" href="spirit/preface.html"><img src="../../../../doc/html/images/next.png" alt="Next"></a></div>
-<div class="article" lang="en">
+<div class="article" title="Spirit 2.1">
<div class="titlepage">
<div>
<div><h2 class="title">
@@ -33,12 +33,13 @@
</div></div>
<div><p class="copyright">Copyright © 2001-2009 Joel
de Guzman, Hartmut Kaiser</p></div>
-<div><div class="legalnotice"><p>
+<div><div class="legalnotice" title="Legal Notice">
+<a name="id1096626"></a><p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
- </p></div></div>
+ </p>
+</div></div>
</div>
-<div></div>
<hr>
</div>
<div class="toc">
@@ -119,7 +120,7 @@
<dt><span class="section"><a href="spirit/karma/quick_reference/common_notation.html">Common
Notation</a></span></dt>
<dt><span class="section"><a href="spirit/karma/quick_reference/primitive_generators.html">
- Primitive Generators</a></span></dt>
+ Karma Generators</a></span></dt>
<dt><span class="section"><a href="spirit/karma/quick_reference/compound_attribute_rules.html">Compound
Attribute Rules</a></span></dt>
<dt><span class="section">Non-terminals</span></dt>
@@ -135,10 +136,11 @@
<dt><span class="section"> Char</span></dt>
<dt><span class="section"> String</span></dt>
<dt><span class="section"> Numeric</span></dt>
-<dt><span class="section">Directive</span></dt>
-<dt><span class="section">Operator</span></dt>
<dt><span class="section">Stream</span></dt>
+<dt><span class="section"> Binary</span></dt>
<dt><span class="section">Auxiliary</span></dt>
+<dt><span class="section">Directive</span></dt>
+<dt><span class="section">Operator</span></dt>
</dl></dd>
<dt><span class="section">Performance Measurements</span></dt>
<dd><dl><dt><span class="section"><a href="spirit/karma/performance_measurements/numeric_performance.html">
@@ -198,7 +200,7 @@
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
-<td align="left"><p><small>Last revised: August 28, 2009 at 04:12:46 GMT</small></p></td>
+<td align="left"><p><small>Last revised: August 29, 2009 at 20:58:33 GMT</small></p></td>
<td align="right"><div class="copyright-footer"></div></td>
</tr></table>
<hr>
Modified: trunk/libs/spirit/doc/html/spirit/abstracts.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/abstracts.html (original)
+++ trunk/libs/spirit/doc/html/spirit/abstracts.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Abstracts</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="structure/include.html" title="Include">
+<link rel="prev" href="structure/include.html" title="Include">
<link rel="next" href="abstracts/syntax_diagram.html" title="Syntax Diagram">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="structure/include.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="abstracts/syntax_diagram.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.abstracts"></a>Abstracts
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Abstracts">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.abstracts"></a><a class="link" href="abstracts.html" title="Abstracts">Abstracts</a>
+</h2></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Syntax Diagram</span></dt>
<dt><span class="section"><a href="abstracts/parsing_expression_grammar.html">Parsing
Modified: trunk/libs/spirit/doc/html/spirit/abstracts/parsing_expression_grammar.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/abstracts/parsing_expression_grammar.html (original)
+++ trunk/libs/spirit/doc/html/spirit/abstracts/parsing_expression_grammar.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Parsing
- Expression Grammar</title>
+<title>Parsing Expression Grammar</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
<link rel="up" href="../abstracts.html" title="Abstracts">
-<link rel="previous" href="syntax_diagram.html" title="Syntax Diagram">
-<link rel="next" href="../qi.html" title=" Qi - Writing Parsers">
+<link rel="prev" href="syntax_diagram.html" title="Syntax Diagram">
+<link rel="next" href="../qi.html" title="Qi - Writing Parsers">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,20 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="syntax_diagram.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../qi.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.abstracts.parsing_expression_grammar"></a><a href="parsing_expression_grammar.html" title="Parsing
- Expression Grammar">Parsing
+<div class="section" title="Parsing Expression Grammar">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.abstracts.parsing_expression_grammar"></a><a class="link" href="parsing_expression_grammar.html" title="Parsing Expression Grammar">Parsing
Expression Grammar</a>
-</h3></div></div>
-<div></div>
-</div>
+</h3></div></div></div>
<p>
Parsing Expression Grammars (PEG)
- <sup>[<a name="id415209" href="#ftn.id415209">5</a>]</sup>
+ <sup>[<a name="id1106762" href="#ftn.id1106762" class="footnote">5</a>]</sup>
are a derivative of Extended Backus-Naur Form (EBNF)
- <sup>[<a name="id415226" href="#ftn.id415226">6</a>]</sup>
+ <sup>[<a name="id1106774" href="#ftn.id1106774" class="footnote">6</a>]</sup>
with a different interpretation, designed to represent a recursive descent
parser. A PEG can be directly represented as a recursive-descent parser.
</p>
@@ -46,24 +41,24 @@
PEGs have an exact interpretation. There is only one valid parse tree (see
Abstract Syntax Tree) for each PEG grammar.
</p>
-<a name="spirit.abstracts.parsing_expression_grammar.sequences"></a><h4>
-<a name="id415263"></a>
- Sequences
- </h4>
+<a name="spirit.abstracts.parsing_expression_grammar.sequences"></a><h5>
+<a name="id1106795"></a>
+ <a class="link" href="parsing_expression_grammar.html#spirit.abstracts.parsing_expression_grammar.sequences">Sequences</a>
+ </h5>
<p>
Sequences are represented by juxtaposition like in EBNF:
</p>
<pre class="programlisting"><span class="identifier">a</span> <span class="identifier">b</span>
</pre>
<p>
- The PEG expression above states that, in order for this to succeed, <tt class="computeroutput"><span class="identifier">a</span></tt> must follow <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ The PEG expression above states that, in order for this to succeed, <code class="computeroutput"><span class="identifier">a</span></code> must follow <code class="computeroutput"><span class="identifier">b</span></code>.
Here's the syntax diagram:
</p>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/sequence.png" alt="sequence"></span>
+ <span class="inlinemediaobject"><img src="../../images/sequence.png" alt="sequence"></span>
</p>
<p>
</p>
@@ -74,66 +69,66 @@
<pre class="programlisting"><span class="char">'x'</span> <span class="identifier">digit</span>
</pre>
<p>
- which means the character <tt class="computeroutput"><span class="identifier">x</span></tt>
+ which means the character <code class="computeroutput"><span class="identifier">x</span></code>
must be followed by a digit.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- In Spirit.Qi, we use the <tt class="computeroutput"><span class="special">>></span></tt>
+<tr><td align="left" valign="top"><p>
+ In Spirit.Qi, we use the <code class="computeroutput"><span class="special">>></span></code>
for sequences since C++ does not allow juxtaposition
</p></td></tr>
</table></div>
-<a name="spirit.abstracts.parsing_expression_grammar.alternatives"></a><h4>
-<a name="id415413"></a>
- Alternatives
- </h4>
+<a name="spirit.abstracts.parsing_expression_grammar.alternatives"></a><h5>
+<a name="id1106912"></a>
+ <a class="link" href="parsing_expression_grammar.html#spirit.abstracts.parsing_expression_grammar.alternatives">Alternatives</a>
+ </h5>
<p>
Alternatives are represented in PEG using the slash:
</p>
<pre class="programlisting"><span class="identifier">a</span> <span class="special">/</span> <span class="identifier">b</span>
</pre>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- In Spirit.Qi, we use the <tt class="computeroutput"><span class="special">|</span></tt>
+<tr><td align="left" valign="top"><p>
+ In Spirit.Qi, we use the <code class="computeroutput"><span class="special">|</span></code>
for alternatives just as in EBNF
</p></td></tr>
</table></div>
<p>
Alternatives allow for choices. The expression above reads: try to match
- <tt class="computeroutput"><span class="identifier">a</span></tt>. If <tt class="computeroutput"><span class="identifier">a</span></tt>
- succeeds, success, if not try to match <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ <code class="computeroutput"><span class="identifier">a</span></code>. If <code class="computeroutput"><span class="identifier">a</span></code>
+ succeeds, success, if not try to match <code class="computeroutput"><span class="identifier">b</span></code>.
This is a bit of a deviation from the usual EBNF interpretation where you
- simply match <tt class="computeroutput"><span class="identifier">a</span></tt> <span class="bold"><b>or</b></span> <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ simply match <code class="computeroutput"><span class="identifier">a</span></code> <span class="bold"><strong>or</strong></span> <code class="computeroutput"><span class="identifier">b</span></code>.
Here's the syntax diagram:
</p>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/alternative.png" alt="alternative"></span>
+ <span class="inlinemediaobject"><img src="../../images/alternative.png" alt="alternative"></span>
</p>
<p>
</p>
</blockquote></div>
<p>
PEGs allow for ambiguity in the alternatives. In the expression above, both
- <tt class="computeroutput"><span class="identifier">a</span></tt> or <tt class="computeroutput"><span class="identifier">b</span></tt>
+ <code class="computeroutput"><span class="identifier">a</span></code> or <code class="computeroutput"><span class="identifier">b</span></code>
can both match an input string. However, only the first matching alternative
is valid. As noted, there can only be one valid parse tree ($$$ explain more
about this $$$).
</p>
-<a name="spirit.abstracts.parsing_expression_grammar.loops"></a><h4>
-<a name="id415598"></a>
- Loops
- </h4>
+<a name="spirit.abstracts.parsing_expression_grammar.loops"></a><h5>
+<a name="id1107052"></a>
+ <a class="link" href="parsing_expression_grammar.html#spirit.abstracts.parsing_expression_grammar.loops">Loops</a>
+ </h5>
<p>
Again, like EBNF, PEG uses the regular-expression Kleene star and the plus
loops:
@@ -141,12 +136,12 @@
<pre class="programlisting"><span class="identifier">a</span><span class="special">*</span>
<span class="identifier">a</span><span class="special">+</span>
</pre>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
Spirit.Qi uses the prefix star and plus since there is no postfix star
or plus in C++.
</p></td></tr>
@@ -158,7 +153,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/kleene.png" alt="kleene"></span>
+ <span class="inlinemediaobject"><img src="../../images/kleene.png" alt="kleene"></span>
</p>
<p>
</p>
@@ -167,14 +162,14 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/plus.png" alt="plus"></span>
+ <span class="inlinemediaobject"><img src="../../images/plus.png" alt="plus"></span>
</p>
<p>
</p>
</blockquote></div>
<p>
- The first, called the Kleene star, matches zero or more of its subject <tt class="computeroutput"><span class="identifier">a</span></tt>. The second, plus, matches one ore more
- of its subject <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ The first, called the Kleene star, matches zero or more of its subject <code class="computeroutput"><span class="identifier">a</span></code>. The second, plus, matches one ore more
+ of its subject <code class="computeroutput"><span class="identifier">a</span></code>.
</p>
<p>
Unlike EBNF, PEGs have greedy loops. It will match as much as it can until
@@ -193,10 +188,10 @@
a major gotcha. PEG provides a couple of other mechanisms to circumvent this.
We will see more of these other mechanisms shortly.
</p>
-<a name="spirit.abstracts.parsing_expression_grammar.difference"></a><h4>
-<a name="id415770"></a>
- Difference
- </h4>
+<a name="spirit.abstracts.parsing_expression_grammar.difference"></a><h5>
+<a name="id1107192"></a>
+ <a class="link" href="parsing_expression_grammar.html#spirit.abstracts.parsing_expression_grammar.difference">Difference</a>
+ </h5>
<p>
In certain cases, you may want to restrict a certain expression. You can
think of a PEG expression as a match for a potentially infinite set of strings.
@@ -205,16 +200,16 @@
<pre class="programlisting"><span class="identifier">a</span> <span class="special">-</span> <span class="identifier">b</span>
</pre>
<p>
- The expression reads: match <tt class="computeroutput"><span class="identifier">a</span></tt>
- but not <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ The expression reads: match <code class="computeroutput"><span class="identifier">a</span></code>
+ but not <code class="computeroutput"><span class="identifier">b</span></code>.
</p>
<div class="footnotes">
<br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a name="ftn.id415209" href="#id415209">5</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1106762" href="#id1106762" class="para">5</a>] </sup>
Bryan Ford: Parsing Expression Grammars: A Recognition-Based Syntactic
Foundation, http://pdos.csail.mit.edu/~baford/packrat/popl04/
</p></div>
-<div class="footnote"><p><sup>[<a name="ftn.id415226" href="#id415226">6</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1106774" href="#id1106774" class="para">6</a>] </sup>
Richard E. Pattis: EBNF: A Notation to Describe Syntax, http://www.cs.cmu.edu/~pattis/misc/ebnf.pdf
</p></div>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/abstracts/syntax_diagram.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/abstracts/syntax_diagram.html (original)
+++ trunk/libs/spirit/doc/html/spirit/abstracts/syntax_diagram.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Syntax Diagram</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
<link rel="up" href="../abstracts.html" title="Abstracts">
-<link rel="previous" href="../abstracts.html" title="Abstracts">
-<link rel="next" href="parsing_expression_grammar.html" title="Parsing
- Expression Grammar">
+<link rel="prev" href="../abstracts.html" title="Abstracts">
+<link rel="next" href="parsing_expression_grammar.html" title="Parsing Expression Grammar">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,31 +22,28 @@
<div class="spirit-nav">
<a accesskey="p" href="../abstracts.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="parsing_expression_grammar.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.abstracts.syntax_diagram"></a>Syntax Diagram
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Syntax Diagram">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.abstracts.syntax_diagram"></a><a class="link" href="syntax_diagram.html" title="Syntax Diagram">Syntax Diagram</a>
+</h3></div></div></div>
<p>
In the next section, we will deal with Parsing Expression Grammars (PEG)
- <sup>[<a name="id414688" href="#ftn.id414688">2</a>]</sup>
+ <sup>[<a name="id1106335" href="#ftn.id1106335" class="footnote">2</a>]</sup>
, a variant of Extended Backus-Naur Form (EBNF)
- <sup>[<a name="id414706" href="#ftn.id414706">3</a>]</sup>
+ <sup>[<a name="id1106347" href="#ftn.id1106347" class="footnote">3</a>]</sup>
with a different interpretation. It is easier to understand PEG using Syntax
Diagrams. Syntax diagrams represent a grammar graphically. It was used extensibly
by Niklaus Wirth
- <sup>[<a name="id414726" href="#ftn.id414726">4</a>]</sup>
+ <sup>[<a name="id1106359" href="#ftn.id1106359" class="footnote">4</a>]</sup>
in the "Pascal User Manual". Syntax Diagrams are easily understandable
with programmers due to its similarity to flow charts. The isomorphism of
the diagrams and functions make it ideal for representing Recursive Descent
parsers which are essentially mutually recursive functions.
</p>
-<a name="spirit.abstracts.syntax_diagram.elements"></a><h4>
-<a name="id414749"></a>
- Elements
- </h4>
+<a name="spirit.abstracts.syntax_diagram.elements"></a><h5>
+<a name="id1106371"></a>
+ <a class="link" href="syntax_diagram.html#spirit.abstracts.syntax_diagram.elements">Elements</a>
+ </h5>
<p>
All diagrams have one entry and exit point. Arrows connect all possible paths
through the grammar from the entry point to the exit point.
@@ -56,7 +52,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/start_stop.png" alt="start_stop"></span>
+ <span class="inlinemediaobject"><img src="../../images/start_stop.png" alt="start_stop"></span>
</p>
<p>
</p>
@@ -69,7 +65,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/terminal.png" alt="terminal"></span>
+ <span class="inlinemediaobject"><img src="../../images/terminal.png" alt="terminal"></span>
</p>
<p>
</p>
@@ -83,15 +79,15 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/non-terminal.png" alt="non-terminal"></span>
+ <span class="inlinemediaobject"><img src="../../images/non-terminal.png" alt="non-terminal"></span>
</p>
<p>
</p>
</blockquote></div>
-<a name="spirit.abstracts.syntax_diagram.constructs"></a><h4>
-<a name="id414868"></a>
- Constructs
- </h4>
+<a name="spirit.abstracts.syntax_diagram.constructs"></a><h5>
+<a name="id1106471"></a>
+ <a class="link" href="syntax_diagram.html#spirit.abstracts.syntax_diagram.constructs">Constructs</a>
+ </h5>
<p>
The most basic composition is the Sequence. B follows A:
</p>
@@ -99,7 +95,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/sequence.png" alt="sequence"></span>
+ <span class="inlinemediaobject"><img src="../../images/sequence.png" alt="sequence"></span>
</p>
<p>
</p>
@@ -114,7 +110,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/alternative.png" alt="alternative"></span>
+ <span class="inlinemediaobject"><img src="../../images/alternative.png" alt="alternative"></span>
</p>
<p>
</p>
@@ -126,7 +122,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/optional.png" alt="optional"></span>
+ <span class="inlinemediaobject"><img src="../../images/optional.png" alt="optional"></span>
</p>
<p>
</p>
@@ -138,7 +134,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/kleene.png" alt="kleene"></span>
+ <span class="inlinemediaobject"><img src="../../images/kleene.png" alt="kleene"></span>
</p>
<p>
</p>
@@ -147,7 +143,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/plus.png" alt="plus"></span>
+ <span class="inlinemediaobject"><img src="../../images/plus.png" alt="plus"></span>
</p>
<p>
</p>
@@ -159,10 +155,10 @@
is a crucial difference between PEG and general Context Free Grammars (CFGs).
This behavior is quite obvious with syntax diagrams as they resemble flow-charts.
</p>
-<a name="spirit.abstracts.syntax_diagram.predicates"></a><h4>
-<a name="id415049"></a>
- Predicates
- </h4>
+<a name="spirit.abstracts.syntax_diagram.predicates"></a><h5>
+<a name="id1106632"></a>
+ <a class="link" href="syntax_diagram.html#spirit.abstracts.syntax_diagram.predicates">Predicates</a>
+ </h5>
<p>
Now, the following are Syntax Diagram versions of PEG predicates. These are
not traditionally found in Syntax Diagrams. These are special extensions
@@ -175,7 +171,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/predicate.png" alt="predicate"></span>
+ <span class="inlinemediaobject"><img src="../../images/predicate.png" alt="predicate"></span>
</p>
<p>
</p>
@@ -192,7 +188,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/and_predicate.png" alt="and_predicate"></span>
+ <span class="inlinemediaobject"><img src="../../images/and_predicate.png" alt="and_predicate"></span>
</p>
<p>
</p>
@@ -201,7 +197,7 @@
<p>
</p>
<p>
- <span class="inlinemediaobject"><img src="images/not_predicate.png" alt="not_predicate"></span>
+ <span class="inlinemediaobject"><img src="../../images/not_predicate.png" alt="not_predicate"></span>
</p>
<p>
</p>
@@ -215,14 +211,14 @@
</p>
<div class="footnotes">
<br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a name="ftn.id414688" href="#id414688">2</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1106335" href="#id1106335" class="para">2</a>] </sup>
Bryan Ford: Parsing Expression Grammars: A Recognition-Based Syntactic
Foundation, http://pdos.csail.mit.edu/~baford/packrat/popl04/
</p></div>
-<div class="footnote"><p><sup>[<a name="ftn.id414706" href="#id414706">3</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1106347" href="#id1106347" class="para">3</a>] </sup>
Richard E. Pattis: EBNF: A Notation to Describe Syntax, http://www.cs.cmu.edu/~pattis/misc/ebnf.pdf
</p></div>
-<div class="footnote"><p><sup>[<a name="ftn.id414726" href="#id414726">4</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1106359" href="#id1106359" class="para">4</a>] </sup>
Niklaus Wirth: The Programming Language Pascal. (July 1973)
</p></div>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/acknowledgments.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/acknowledgments.html (original)
+++ trunk/libs/spirit/doc/html/spirit/acknowledgments.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Acknowledgments</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="repository.html" title=" Spirit Repository">
+<link rel="prev" href="repository.html" title="Spirit Repository">
<link rel="next" href="references.html" title="References">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="repository.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="references.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.acknowledgments"></a>Acknowledgments
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Acknowledgments">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.acknowledgments"></a><a class="link" href="acknowledgments.html" title="Acknowledgments">Acknowledgments</a>
+</h2></div></div></div>
<p>
This version of Spirit is a complete rewrite of the <span class="emphasis"><em>classic</em></span>
Spirit many people have been contributing to (see below). But there are a couple
@@ -36,52 +33,52 @@
would like to express our special acknowledgement to:
</p>
<p>
- <span class="bold"><b>Eric Niebler</b></span> for writing Boost.Proto, without
+ <span class="bold"><strong>Eric Niebler</strong></span> for writing Boost.Proto, without
which this rewrite wouldn't have been possible, and helping with examples,
advices, and suggestions on how to use Boost.Proto in the best possible way.
</p>
<p>
- <span class="bold"><b>Ben Hanson</b></span> for providing us with an early
+ <span class="bold"><strong>Ben Hanson</strong></span> for providing us with an early
version of his Lexertl library, which is proposed to be included into Boost
(as Boost.Lexer), but at the time of this writing the Boost review for this
library is still pending.
</p>
<p>
- <span class="bold"><b>FIXME</b></span>: Add more people
+ <span class="bold"><strong>FIXME</strong></span>: Add more people
</p>
-<a name="spirit.acknowledgments.acknowledgements_from_the_spirit_v1__emphasis_classic__emphasis__documentation"></a><h3>
-<a name="id641312"></a>
- <a href="acknowledgments.html#spirit.acknowledgments.acknowledgements_from_the_spirit_v1__emphasis_classic__emphasis__documentation">Acknowledgements
+<a name="spirit.acknowledgments.acknowledgements_from_the_spirit_v1__emphasis_classic__emphasis__documentation"></a><h4>
+<a name="id1347289"></a>
+ <a class="link" href="acknowledgments.html#spirit.acknowledgments.acknowledgements_from_the_spirit_v1__emphasis_classic__emphasis__documentation">Acknowledgements
from the Spirit V1 <span class="emphasis"><em>classic</em></span> Documentation</a>
- </h3>
+ </h4>
<p>
Special thanks for working on Spirit <span class="emphasis"><em>classic</em></span> to:
</p>
<p>
- <span class="bold"><b>Dan Nuffer</b></span> for his work on lexers, parse trees,
+ <span class="bold"><strong>Dan Nuffer</strong></span> for his work on lexers, parse trees,
ASTs, XML parsers, the multi-pass iterator as well as administering Spirit's
site, editing, maintaining the CVS and doing the releases plus a zillion of
other chores that were almost taken for granted.
</p>
<p>
- <span class="bold"><b>Hartmut Kaiser</b></span> for his work on the C parser,
+ <span class="bold"><strong>Hartmut Kaiser</strong></span> for his work on the C parser,
the work on the C/C++ preprocessor, utility parsers, the original port to Intel
5.0, various work on Phoenix, porting to v1.5, the meta-parsers, the grouping-parsers,
extensive testing and painstaking attention to details.
</p>
<p>
- <span class="bold"><b>Martin Wille</b></span> who improved grammar multi thread
+ <span class="bold"><strong>Martin Wille</strong></span> who improved grammar multi thread
safety, contributed the eol_p parser, the dynamic parsers, documentation and
for taking an active role in almost every aspect from brainstorming and design
to coding. And, as always, helps keep the regression tests for g++ on Linux
as green as ever :-).
</p>
<p>
- <span class="bold"><b>Martijn W. Van Der Lee</b></span> our Web site administrator
+ <span class="bold"><strong>Martijn W. Van Der Lee</strong></span> our Web site administrator
and for contributing the RFC821 parser.
</p>
<p>
- <span class="bold"><b>Giovanni Bajo</b></span> for last minute tweaks of Spirit
+ <span class="bold"><strong>Giovanni Bajo</strong></span> for last minute tweaks of Spirit
1.8.0 for CodeWarrior 8.3. Actually, I'm ashamed Giovanni was not in this list
already. He's done a lot since Spirit 1.5, the first Boost.Spirit release.
He's instrumental in the porting of the Spirit iterators stuff to the new Boost
@@ -89,107 +86,107 @@
tests here and there.
</p>
<p>
- <span class="bold"><b>Juan Carlos Arevalo-Baeza (JCAB)*</b></span> for his
+ <span class="bold"><strong>Juan Carlos Arevalo-Baeza (JCAB)*</strong></span> for his
work on the C++ parser, the position iterator, ports to v1.5 and keeping the
mailing list discussions alive and kicking.
</p>
<p>
- <span class="bold"><b>Vaclav Vesely</b></span>, lots of stuff, the no_actions
+ <span class="bold"><strong>Vaclav Vesely</strong></span>, lots of stuff, the no_actions
directive, various patches fixes, the distinct parsers, the lazy parser, some
phoenix tweaks and add-ons (e.g. new_). Also, *Stefan Slapeta] and wife for
editing Vaclav's distinct parser doc.
</p>
<p>
- <span class="bold"><b>Raghavendra Satish</b></span> for doing the original
+ <span class="bold"><strong>Raghavendra Satish</strong></span> for doing the original
v1.3 port to VC++ and his work on Phoenix.
</p>
<p>
- <span class="bold"><b>Noah Stein</b></span> for following up and helping Ragav
+ <span class="bold"><strong>Noah Stein</strong></span> for following up and helping Ragav
on the VC++ ports.
</p>
<p>
- <span class="bold"><b>Hakki Dogusan</b></span>, for his original v1.0 Pascal
+ <span class="bold"><strong>Hakki Dogusan</strong></span>, for his original v1.0 Pascal
parser.
</p>
<p>
- <span class="bold"><b>John (EBo) David</b></span> for his work on the VM and
+ <span class="bold"><strong>John (EBo) David</strong></span> for his work on the VM and
watching over my shoulder as I code giving the impression of distance eXtreme
programming.
</p>
<p>
- <span class="bold"><b>Chris Uzdavinis</b></span> for feeding in comments and
+ <span class="bold"><strong>Chris Uzdavinis</strong></span> for feeding in comments and
valuable suggestions as well as editing the documentation.
</p>
<p>
- <span class="bold"><b>Carsten Stoll</b></span>, for his work on dynamic parsers.
+ <span class="bold"><strong>Carsten Stoll</strong></span>, for his work on dynamic parsers.
</p>
<p>
- <span class="bold"><b>Andy Elvey</b></span> and his conifer parser.
+ <span class="bold"><strong>Andy Elvey</strong></span> and his conifer parser.
</p>
<p>
- <span class="bold"><b>Bruce Florman</b></span>, who did the original v1.0 port
+ <span class="bold"><strong>Bruce Florman</strong></span>, who did the original v1.0 port
to VC++.
</p>
<p>
- <span class="bold"><b>Jeff Westfahl</b></span> for porting the loop parsers
+ <span class="bold"><strong>Jeff Westfahl</strong></span> for porting the loop parsers
to v1.5 and contributing the file iterator.
</p>
<p>
- <span class="bold"><b>Peter Simons</b></span> for the RFC date parser example
+ <span class="bold"><strong>Peter Simons</strong></span> for the RFC date parser example
and tutorial plus helping out with some nitty gritty details.
</p>
<p>
- <span class="bold"><b>Markus Schöpflin</b></span> for suggesting the end_p parser
+ <span class="bold"><strong>Markus Schöpflin</strong></span> for suggesting the end_p parser
and lots of other nifty things and his active presence in the mailing list.
</p>
<p>
- <span class="bold"><b>Doug Gregor</b></span> for mentoring and his ability
+ <span class="bold"><strong>Doug Gregor</strong></span> for mentoring and his ability
to see things that others don't.
</p>
<p>
- <span class="bold"><b>David Abrahams</b></span> for giving Joel a job that
+ <span class="bold"><strong>David Abrahams</strong></span> for giving Joel a job that
allows him to still work on Spirit, plus countless advice and help on C++ and
specifically template metaprogramming.
</p>
<p>
- <span class="bold"><b>Aleksey Gurtovoy</b></span> for his MPL library from
+ <span class="bold"><strong>Aleksey Gurtovoy</strong></span> for his MPL library from
which we stole many metaprogramming tricks especially for less conforming compilers
such as Borland and VC6/7.
</p>
<p>
- <span class="bold"><b>Gustavo Guerra</b></span> for his last minute review
+ <span class="bold"><strong>Gustavo Guerra</strong></span> for his last minute review
of Spirit and constant feedback, plus patches here and there (e.g. proposing
the new dot behavior of the real numerics parsers).
</p>
<p>
- <span class="bold"><b>Nicola Musatti</b></span>, <span class="bold"><b>Paul
- Snively</b></span>, <span class="bold"><b>Alisdair Meredith</b></span> and
- <span class="bold"><b>Hugo Duncan</b></span> for testing and sending in various
+ <span class="bold"><strong>Nicola Musatti</strong></span>, <span class="bold"><strong>Paul
+ Snively</strong></span>, <span class="bold"><strong>Alisdair Meredith</strong></span> and
+ <span class="bold"><strong>Hugo Duncan</strong></span> for testing and sending in various
patches.
</p>
<p>
- <span class="bold"><b>Steve Rowe</b></span> for his splendid work on the TSTs
+ <span class="bold"><strong>Steve Rowe</strong></span> for his splendid work on the TSTs
that will soon be taken into Spirit.
</p>
<p>
- <span class="bold"><b>Jonathan de Halleux</b></span> for his work on actors.
+ <span class="bold"><strong>Jonathan de Halleux</strong></span> for his work on actors.
</p>
<p>
- <span class="bold"><b>Angus Leeming</b></span> for last minute editing work
+ <span class="bold"><strong>Angus Leeming</strong></span> for last minute editing work
on the 1.8.0 release documentation, his work on Phoenix and his active presence
in the Spirit mailing list.
</p>
<p>
- <span class="bold"><b>Joao Abecasis</b></span> for his active presence in the
+ <span class="bold"><strong>Joao Abecasis</strong></span> for his active presence in the
Spirit mailing list, providing user support, participating in the discussions
and so on.
</p>
<p>
- <span class="bold"><b>Guillaume Melquiond</b></span> for a last minute patch
+ <span class="bold"><strong>Guillaume Melquiond</strong></span> for a last minute patch
to multi_pass for 1.8.1.
</p>
<p>
- <span class="bold"><b>Peder Holt</b></span> for his porting work on Phoenix,
+ <span class="bold"><strong>Peder Holt</strong></span> for his porting work on Phoenix,
Fusion and Spirit to VC6.
</p>
<p>
@@ -206,19 +203,19 @@
in the review:
</p>
<p>
- <span class="bold"><b>John Maddock</b></span>, our review manager, <span class="bold"><b>Aleksey Gurtovoy</b></span>, <span class="bold"><b>Andre Hentz</b></span>,
- <span class="bold"><b>Beman Dawes</b></span>, <span class="bold"><b>Carl Daniel</b></span>,
- <span class="bold"><b>Christopher Currie</b></span>, <span class="bold"><b>Dan
- Gohman</b></span>, <span class="bold"><b>Dan Nuffer</b></span>, <span class="bold"><b>Daryle
- Walker</b></span>, <span class="bold"><b>David Abrahams</b></span>, <span class="bold"><b>David B. Held</b></span>, <span class="bold"><b>Dirk Gerrits</b></span>,
- <span class="bold"><b>Douglas Gregor</b></span>, <span class="bold"><b>Hartmut
- Kaiser</b></span>, <span class="bold"><b>Iain K.Hanson</b></span>, <span class="bold"><b>Juan Carlos Arevalo-Baeza</b></span>, <span class="bold"><b>Larry
- Evans</b></span>, <span class="bold"><b>Martin Wille</b></span>, <span class="bold"><b>Mattias Flodin</b></span>, <span class="bold"><b>Noah Stein</b></span>,
- <span class="bold"><b>Nuno Lucas</b></span>, <span class="bold"><b>Peter Dimov</b></span>,
- <span class="bold"><b>Peter Simons</b></span>, <span class="bold"><b>Petr Kocmid</b></span>,
- <span class="bold"><b>Ross Smith</b></span>, <span class="bold"><b>Scott Kirkwood</b></span>,
- <span class="bold"><b>Steve Cleary</b></span>, <span class="bold"><b>Thorsten
- Ottosen</b></span>, <span class="bold"><b>Tom Wenisch</b></span>, <span class="bold"><b>Vladimir Prus</b></span>
+ <span class="bold"><strong>John Maddock</strong></span>, our review manager, <span class="bold"><strong>Aleksey Gurtovoy</strong></span>, <span class="bold"><strong>Andre Hentz</strong></span>,
+ <span class="bold"><strong>Beman Dawes</strong></span>, <span class="bold"><strong>Carl Daniel</strong></span>,
+ <span class="bold"><strong>Christopher Currie</strong></span>, <span class="bold"><strong>Dan
+ Gohman</strong></span>, <span class="bold"><strong>Dan Nuffer</strong></span>, <span class="bold"><strong>Daryle
+ Walker</strong></span>, <span class="bold"><strong>David Abrahams</strong></span>, <span class="bold"><strong>David B. Held</strong></span>, <span class="bold"><strong>Dirk Gerrits</strong></span>,
+ <span class="bold"><strong>Douglas Gregor</strong></span>, <span class="bold"><strong>Hartmut
+ Kaiser</strong></span>, <span class="bold"><strong>Iain K.Hanson</strong></span>, <span class="bold"><strong>Juan Carlos Arevalo-Baeza</strong></span>, <span class="bold"><strong>Larry
+ Evans</strong></span>, <span class="bold"><strong>Martin Wille</strong></span>, <span class="bold"><strong>Mattias Flodin</strong></span>, <span class="bold"><strong>Noah Stein</strong></span>,
+ <span class="bold"><strong>Nuno Lucas</strong></span>, <span class="bold"><strong>Peter Dimov</strong></span>,
+ <span class="bold"><strong>Peter Simons</strong></span>, <span class="bold"><strong>Petr Kocmid</strong></span>,
+ <span class="bold"><strong>Ross Smith</strong></span>, <span class="bold"><strong>Scott Kirkwood</strong></span>,
+ <span class="bold"><strong>Steve Cleary</strong></span>, <span class="bold"><strong>Thorsten
+ Ottosen</strong></span>, <span class="bold"><strong>Tom Wenisch</strong></span>, <span class="bold"><strong>Vladimir Prus</strong></span>
</p>
<p>
Finally thanks to SourceForge for hosting the Spirit project and Boost: a C++
Modified: trunk/libs/spirit/doc/html/spirit/faq.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/faq.html (original)
+++ trunk/libs/spirit/doc/html/spirit/faq.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,12 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Spirit FAQ</title>
+<title>Spirit FAQ</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="support/multi_pass.html" title=" The multi pass iterator">
+<link rel="prev" href="support/multi_pass.html" title="The multi pass iterator">
<link rel="next" href="notes.html" title="Notes">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,33 +22,30 @@
<div class="spirit-nav">
<a accesskey="p" href="support/multi_pass.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="notes.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.faq"></a> Spirit FAQ
-</h2></div></div>
-<div></div>
-</div>
-<a name="spirit.faq.i_m_getting_multiple_symbol_definition_errors_while_using_visual_c____anything_i_could_do_about_that_"></a><h3>
-<a name="id630861"></a>
- <a href="faq.html#spirit.faq.i_m_getting_multiple_symbol_definition_errors_while_using_visual_c____anything_i_could_do_about_that_">I'm
+<div class="section" title="Spirit FAQ">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.faq"></a><a class="link" href="faq.html" title="Spirit FAQ"> Spirit FAQ</a>
+</h2></div></div></div>
+<a name="spirit.faq.i_m_getting_multiple_symbol_definition_errors_while_using_visual_c____anything_i_could_do_about_that_"></a><h4>
+<a name="id1338004"></a>
+ <a class="link" href="faq.html#spirit.faq.i_m_getting_multiple_symbol_definition_errors_while_using_visual_c____anything_i_could_do_about_that_">I'm
getting multiple symbol definition errors while using Visual C++. Anything
I could do about that?</a>
- </h3>
+ </h4>
<p>
- Do you see strange multiple symbol definition linker errors mentioning <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">failed</span></tt>
- and <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span></tt>?
+ Do you see strange multiple symbol definition linker errors mentioning <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">failed</span></code>
+ and <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span></code>?
Then this FAQ entry might be for you.
</p>
<p>
<a href="http://www.boost.org/libs/mpl/index.html" target="_top">Boost.Mpl</a> implements
- a macro <tt class="computeroutput"><span class="identifier">BOOST_MPL_ASSERT_MSG</span><span class="special">()</span></tt> which essentially is a more powerfull version
+ a macro <code class="computeroutput"><span class="identifier">BOOST_MPL_ASSERT_MSG</span><span class="special">()</span></code> which essentially is a more powerfull version
of static_assert. Unfortunately under certain circumstances using this macro
may lead to the aformentioned linker errors.
</p>
<p>
<a href="http://spirit.sourceforge.net" target="_top">Spirit</a> allows you to define
- a preprocessor constant disabling the usage of <tt class="computeroutput"><span class="identifier">BOOST_MPL_ASSERT_MSG</span><span class="special">()</span></tt>, while switching to <tt class="computeroutput"><span class="identifier">BOOST_STATIC_ASSERT</span><span class="special">()</span></tt> instead. For that you need define BOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG=1
+ a preprocessor constant disabling the usage of <code class="computeroutput"><span class="identifier">BOOST_MPL_ASSERT_MSG</span><span class="special">()</span></code>, while switching to <code class="computeroutput"><span class="identifier">BOOST_STATIC_ASSERT</span><span class="special">()</span></code> instead. For that you need define BOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG=1
(either by adding
</p>
<pre class="programlisting"><span class="special">-</span><span class="identifier">DBOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG</span><span class="special">=</span><span class="number">1</span>
@@ -66,12 +63,12 @@
see while using this workaround are less verbose error messages generated from
static_assert.
</p>
-<a name="spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_"></a><h3>
-<a name="id631125"></a>
- <a href="faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">I'm
+<a name="spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_"></a><h4>
+<a name="id1338174"></a>
+ <a class="link" href="faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">I'm
very confused about the header hell in my boost/spirit directory. What's all
this about?</a>
- </h3>
+ </h4>
<p>
The boost/spirit directory currently holds two versions of the Spirit library:
<span class="emphasis"><em>Spirit.Classic</em></span> (former V1.8.x) and SpiritV2. Both are
@@ -174,24 +171,24 @@
as we will probably redirect to the Boost.Phoenix headers as soon as these
are available.
</p>
-<a name="spirit.faq.why_doesn_t_my_symbol_table_work_in_a__code__phrase_role__identifier__no_case__phrase___code__directive_"></a><h3>
-<a name="id631896"></a>
- <a href="faq.html#spirit.faq.why_doesn_t_my_symbol_table_work_in_a__code__phrase_role__identifier__no_case__phrase___code__directive_">Why
- doesn't my symbol table work in a <tt class="computeroutput"><span class="identifier">no_case</span></tt>
+<a name="spirit.faq.why_doesn_t_my_symbol_table_work_in_a__code__phrase_role__identifier__no_case__phrase___code__directive_"></a><h4>
+<a name="id1338684"></a>
+ <a class="link" href="faq.html#spirit.faq.why_doesn_t_my_symbol_table_work_in_a__code__phrase_role__identifier__no_case__phrase___code__directive_">Why
+ doesn't my symbol table work in a <code class="computeroutput"><span class="identifier">no_case</span></code>
directive?</a>
- </h3>
+ </h4>
<p>
- In order to perform case-insensitive parsing (using no_case[a])
- with a symbol table (i.e. use a symbols<Ch, T> parser in a <tt class="computeroutput"><span class="identifier">no_case</span></tt>
+ In order to perform case-insensitive parsing (using <a class="link" href="qi/reference/directive/no_case.html" title="no_case"><code class="computeroutput"><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>)
+ with a symbol table (i.e. use a <a class="link" href="qi/reference/string/symbols.html" title="symbols"><code class="computeroutput"><span class="identifier">symbols</span><span class="special"><</span><span class="identifier">Ch</span><span class="special">,</span> <span class="identifier">T</span><span class="special">></span></code></a> parser in a <code class="computeroutput"><span class="identifier">no_case</span></code>
directive), that symbol table needs to be filled with all-lowercase contents.
Entries containing one or more uppercase characters will not match any input.
</p>
-<a name="spirit.faq.i_m_getting_a_compilation_error_mentioning__code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function__phrase___code__and_or___________code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function4__phrase___code___what_does_this_mean_"></a><h3>
-<a name="id632048"></a>
- <a href="faq.html#spirit.faq.i_m_getting_a_compilation_error_mentioning__code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function__phrase___code__and_or___________code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function4__phrase___code___what_does_this_mean_">I'm
- getting a compilation error mentioning <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span></tt>
- and/or <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function4</span></tt>. What does this mean?</a>
- </h3>
+<a name="spirit.faq.i_m_getting_a_compilation_error_mentioning__code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function__phrase___code__and_or___________code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function4__phrase___code___what_does_this_mean_"></a><h4>
+<a name="id1338766"></a>
+ <a class="link" href="faq.html#spirit.faq.i_m_getting_a_compilation_error_mentioning__code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function__phrase___code__and_or___________code__phrase_role__identifier__boost__phrase__phrase_role__special______phrase__phrase_role__identifier__function4__phrase___code___what_does_this_mean_">I'm
+ getting a compilation error mentioning <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span></code>
+ and/or <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function4</span></code>. What does this mean?</a>
+ </h4>
<p>
If you are using Visual C++ and have an error like:
</p>
@@ -212,30 +209,30 @@
it means that non-terminal can only be used with a skip parser of a compatible
type. The error above arises when this is not the case, i.e.:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
a non-terminal defined with a skip parser type is used without a skip parser
- (for example, a rule with a skip parser type is used inside a <tt class="computeroutput"><span class="identifier">lexeme</span></tt> directive, or a grammar with a skip
- parser type is used in <tt class="computeroutput"><span class="identifier">parse</span></tt>
- instead of <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>),
+ (for example, a rule with a skip parser type is used inside a <code class="computeroutput"><span class="identifier">lexeme</span></code> directive, or a grammar with a skip
+ parser type is used in <code class="computeroutput"><span class="identifier">parse</span></code>
+ instead of <code class="computeroutput"><span class="identifier">phrase_parse</span></code>),
</li>
-<li>
+<li class="listitem">
or a non-terminal is used with a skip parser of an incompatible type (for
example, a rule defined with one skip parser type calls a second rule defined
with another, incompatible skip parser type).
</li>
</ul></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
The same applies to <span class="emphasis"><em>Spirit.Karma</em></span>, replacing 'skip parser'
- and <tt class="computeroutput"><span class="identifier">lexeme</span></tt> by 'delimit generator'
- and <tt class="computeroutput"><span class="identifier">verbatim</span></tt>. Similarily,
+ and <code class="computeroutput"><span class="identifier">lexeme</span></code> by 'delimit generator'
+ and <code class="computeroutput"><span class="identifier">verbatim</span></code>. Similarily,
corresponding error messages in <span class="emphasis"><em>Spirit.Karma</em></span> reference
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function3</span></tt> and the 3rd parameter (instead
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function3</span></code> and the 3rd parameter (instead
of the 4th).
</p></td></tr>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/introduction.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/introduction.html (original)
+++ trunk/libs/spirit/doc/html/spirit/introduction.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Introduction</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="what_s_new.html" title="What's New">
+<link rel="prev" href="what_s_new.html" title="What's New">
<link rel="next" href="structure.html" title="Structure">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,18 +22,15 @@
<div class="spirit-nav">
<a accesskey="p" href="what_s_new.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="structure.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.introduction"></a>Introduction
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Introduction">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.introduction"></a><a class="link" href="introduction.html" title="Introduction">Introduction</a>
+</h2></div></div></div>
<p>
Boost Spirit is an object-oriented, recursive-descent parser and output generation
library for C++. It allows you to write grammars and format descriptions using
a format similar to Extended Backus Naur Form (EBNF)
- <sup>[<a name="id411217" href="#ftn.id411217">1</a>]</sup>
+ <sup>[<a name="id1101419" href="#ftn.id1101419" class="footnote">1</a>]</sup>
directly in C++. These inline grammar specifications can mix freely with other
C++ code and, thanks to the generative power of C++ templates, are immediately
executable. In retrospect, conventional compiler-compilers or parser-generators
@@ -45,14 +42,14 @@
embedded languages (DSEL). In fact, Spirit exposes 3 different DSELs to the
user:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
one for creating parser grammars,
</li>
-<li>
+<li class="listitem">
one for the specification of the required tokens to be used for parsing,
</li>
-<li>
+<li class="listitem">
and one for the description of the required output formats.
</li>
</ul></div>
@@ -70,31 +67,31 @@
can directly be used to generate arbitrarily-formatted output.
</p>
<p>
- The figure below depicts the
+ The <a class="link" href="introduction.html#spirit.spiritstructure" title="Figure 1. The overall structure of the Boost Spirit library">figure</a> below depicts the
overall structure of the Boost Spirit library. The library consists of 4 major
parts:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
<span class="emphasis"><em>Spirit.Classic</em></span>: This is the almost-unchanged code base
taken from the former Boost Spirit V1.8 distribution. It has been moved into
the namespace boost::spirit::classic. A special compatibility layer has been
added to ensure complete compatibility with existing code using Spirit V1.8.
</li>
-<li>
+<li class="listitem">
<span class="emphasis"><em>Spirit.Qi</em></span>: This is the parser library allowing you to
build recursive descent parsers. The exposed domain-specific language can
be used to describe the grammars to implement, and the rules for storing
the parsed information.
</li>
-<li>
+<li class="listitem">
<span class="emphasis"><em>Spirit.Lex</em></span>: This is the library usable to create tokenizers
(lexers). The domain-specific language exposed by <span class="emphasis"><em>Spirit.Lex</em></span>
allows to define regular expressions used to match tokens (create token definitions),
associate these regular expressions with code to be executed whenever they
are matched, and to add the token definitions to the lexical analyzer.
</li>
-<li>
+<li class="listitem">
<span class="emphasis"><em>Spirit.Karma</em></span>: This is the generator library allowing
you to create code for recursive descent, data type-driven output formatting.
The exposed domain-specific language is almost equivalent to the parser description
@@ -106,10 +103,9 @@
</p>
<div class="figure">
<a name="spirit.spiritstructure"></a><p class="title"><b>Figure 1. The overall structure of the Boost Spirit library</b></p>
-<span class="inlinemediaobject"><img src="./images/spiritstructure.png" alt="The
- overall structure of the Boost Spirit library"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src=".././images/spiritstructure.png" alt="The overall structure of the Boost Spirit library"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
<p>
The separate sublibraries <span class="emphasis"><em>Spirit.Qi</em></span>, <span class="emphasis"><em>Spirit.Karma</em></span>
@@ -122,8 +118,7 @@
the input for a parser generated by <span class="emphasis"><em>Spirit.Qi</em></span>.
</p>
<p>
- The <a href="introduction.html#spirit.spiritkarmaflow" title="Figure 2. The place of Spirit.Qi and Spirit.Karma
- in a data transformation flow of a typical application">figure</a> below shows the typical
+ The <a class="link" href="introduction.html#spirit.spiritkarmaflow" title="Figure 2. The place of Spirit.Qi and Spirit.Karma in a data transformation flow of a typical application">figure</a> below shows the typical
data flow of some input being converted to some internal representation. After
some (optional) transformation these data are converted back into some different,
external representation. The picture highlights Spirit's place in this data
@@ -134,17 +129,15 @@
<div class="figure">
<a name="spirit.spiritkarmaflow"></a><p class="title"><b>Figure 2. The place of <span class="emphasis"><em>Spirit.Qi</em></span> and <span class="emphasis"><em>Spirit.Karma</em></span>
in a data transformation flow of a typical application</b></p>
-<span class="inlinemediaobject"><img src="./images/spiritkarmaflow.png" alt="The
- place of Spirit.Qi and Spirit.Karma
- in a data transformation flow of a typical application"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src=".././images/spiritkarmaflow.png" alt="The place of Spirit.Qi and Spirit.Karma in a data transformation flow of a typical application"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
-<a name="spirit.introduction.a_quick_overview_of_parsing_with__emphasis_spirit_qi__emphasis_"></a><h3>
-<a name="id411501"></a>
- <a href="introduction.html#spirit.introduction.a_quick_overview_of_parsing_with__emphasis_spirit_qi__emphasis_">A
+<a name="spirit.introduction.a_quick_overview_of_parsing_with__emphasis_spirit_qi__emphasis_"></a><h4>
+<a name="id1101632"></a>
+ <a class="link" href="introduction.html#spirit.introduction.a_quick_overview_of_parsing_with__emphasis_spirit_qi__emphasis_">A
Quick Overview of Parsing with <span class="emphasis"><em>Spirit.Qi</em></span></a>
- </h3>
+ </h4>
<p>
<span class="emphasis"><em>Spirit.Qi</em></span> is Spirit's sublibrary dealing with generating
parsers based on a given target grammar (essentially a format description of
@@ -169,14 +162,14 @@
</pre>
<p>
Through the magic of expression templates, this is perfectly valid and executable
- C++ code. The production rule <tt class="computeroutput"><span class="identifier">expression</span></tt>
- is, in fact, an object that has a member function <tt class="computeroutput"><span class="identifier">parse</span></tt>
+ C++ code. The production rule <code class="computeroutput"><span class="identifier">expression</span></code>
+ is, in fact, an object that has a member function <code class="computeroutput"><span class="identifier">parse</span></code>
that does the work given a source code written in the grammar that we have
just declared. Yes, it's a calculator. We shall simplify for now by skipping
- the type declarations and the definition of the rule <tt class="computeroutput"><span class="identifier">integer</span></tt>
- invoked by <tt class="computeroutput"><span class="identifier">factor</span></tt>. Now, the
- production rule <tt class="computeroutput"><span class="identifier">expression</span></tt>
- in our grammar specification, traditionally called the <tt class="computeroutput"><span class="identifier">start</span></tt>
+ the type declarations and the definition of the rule <code class="computeroutput"><span class="identifier">integer</span></code>
+ invoked by <code class="computeroutput"><span class="identifier">factor</span></code>. Now, the
+ production rule <code class="computeroutput"><span class="identifier">expression</span></code>
+ in our grammar specification, traditionally called the <code class="computeroutput"><span class="identifier">start</span></code>
symbol, can recognize inputs such as:
</p>
<pre class="programlisting"><span class="number">12345</span>
@@ -203,19 +196,19 @@
<p>
as seen in math syntax, for example, to mean multiplication or, in our case,
as seen in EBNF syntax to mean sequencing (b should follow a). <span class="emphasis"><em>Spirit.Qi</em></span>
- uses the shift <tt class="computeroutput"><span class="special">>></span></tt> operator
- instead for this purpose. We take the <tt class="computeroutput"><span class="special">>></span></tt>
+ uses the shift <code class="computeroutput"><span class="special">>></span></code> operator
+ instead for this purpose. We take the <code class="computeroutput"><span class="special">>></span></code>
operator, with arrows pointing to the right, to mean "is followed by".
Thus we write:
</p>
<pre class="programlisting"><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span>
</pre>
<p>
- The alternative operator <tt class="computeroutput"><span class="special">|</span></tt> and
- the parentheses <tt class="computeroutput"><span class="special">()</span></tt> remain as is.
- The assignment operator <tt class="computeroutput"><span class="special">=</span></tt> is used
- in place of EBNF's <tt class="computeroutput"><span class="special">::=</span></tt>. Last but
- not least, the Kleene star <tt class="computeroutput"><span class="special">*</span></tt> which
+ The alternative operator <code class="computeroutput"><span class="special">|</span></code> and
+ the parentheses <code class="computeroutput"><span class="special">()</span></code> remain as is.
+ The assignment operator <code class="computeroutput"><span class="special">=</span></code> is used
+ in place of EBNF's <code class="computeroutput"><span class="special">::=</span></code>. Last but
+ not least, the Kleene star <code class="computeroutput"><span class="special">*</span></code> which
used to be a postfix operator in EBNF becomes a prefix. Instead of:
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">*</span> <span class="comment">//... in EBNF syntax,
@@ -226,15 +219,15 @@
<pre class="programlisting"><span class="special">*</span><span class="identifier">a</span> <span class="comment">//... in Spirit.
</span></pre>
<p>
- since there are no postfix stars, <tt class="computeroutput"><span class="special">*</span></tt>,
+ since there are no postfix stars, <code class="computeroutput"><span class="special">*</span></code>,
in C/C++. Finally, we terminate each rule with the ubiquitous semi-colon,
- <tt class="computeroutput"><span class="special">;</span></tt>.
+ <code class="computeroutput"><span class="special">;</span></code>.
</p>
-<a name="spirit.introduction.a_quick_overview_of_output_generation_with__emphasis_spirit_karma__emphasis_"></a><h3>
-<a name="id412711"></a>
- <a href="introduction.html#spirit.introduction.a_quick_overview_of_output_generation_with__emphasis_spirit_karma__emphasis_">A
+<a name="spirit.introduction.a_quick_overview_of_output_generation_with__emphasis_spirit_karma__emphasis_"></a><h4>
+<a name="id1102589"></a>
+ <a class="link" href="introduction.html#spirit.introduction.a_quick_overview_of_output_generation_with__emphasis_spirit_karma__emphasis_">A
Quick Overview of Output Generation with <span class="emphasis"><em>Spirit.Karma</em></span></a>
- </h3>
+ </h4>
<p>
Spirit not only allows you to describe the structure of the input. Starting
with Version 2.0 it enables the specification of the output format for your
@@ -242,7 +235,7 @@
</p>
<p>
Let's assume we need to generate a textual representation from a simple data
- structure such as a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></tt>. Conventional
+ structure such as a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code>. Conventional
code probably would look like:
</p>
<pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span> <span class="identifier">v</span> <span class="special">(</span><span class="identifier">initialize_and_fill</span><span class="special">());</span>
@@ -261,88 +254,118 @@
</pre>
<p>
Here are some more examples of format descriptions for different output representations
- of the same <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></tt>:
+ of the same <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code>:
</p>
<div class="table">
-<a name="id413148"></a><p class="title"><b>Table 2. Different output formats for `std::vector<int>`</b></p>
-<table class="table" summary="Different output formats for `std::vector<int>`">
+<a name="id1105115"></a><p class="title"><b>Table 2. Different output formats for `std::vector<int>`</b></p>
+<div class="table-contents"><table class="table" summary="Different output formats for `std::vector<int>`">
<colgroup>
<col>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Format
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Example
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="char">'['</span> <span class="special"><<</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="char">'['</span> <span class="special"><<</span>
<span class="special">*(</span><span class="identifier">int_</span>
- <span class="special"><<</span> <span class="char">','</span><span class="special">)</span> <span class="special"><<</span> <span class="char">']'</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="special">[</span><span class="number">1</span><span class="special">,</span><span class="number">8</span><span class="special">,</span><span class="number">10</span><span class="special">,]</span></tt>
- </p></td>
-<td><p>
+ <span class="special"><<</span> <span class="char">','</span><span class="special">)</span> <span class="special"><<</span> <span class="char">']'</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">[</span><span class="number">1</span><span class="special">,</span><span class="number">8</span><span class="special">,</span><span class="number">10</span><span class="special">,]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Comma separated list of integers
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">*(</span><span class="char">'('</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">*(</span><span class="char">'('</span>
<span class="special"><<</span> <span class="identifier">int_</span>
<span class="special"><<</span> <span class="char">')'</span>
- <span class="special"><<</span> <span class="char">','</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="special">(</span><span class="number">1</span><span class="special">),(</span><span class="number">8</span><span class="special">),(</span><span class="number">10</span><span class="special">),</span></tt>
- </p></td>
-<td><p>
+ <span class="special"><<</span> <span class="char">','</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">(</span><span class="number">1</span><span class="special">),(</span><span class="number">8</span><span class="special">),(</span><span class="number">10</span><span class="special">),</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Comma separated list of integers in parenthesis
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">*</span><span class="identifier">hex</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="number">18</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">*</span><span class="identifier">hex</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="number">18</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A list of hexadecimal numbers
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">*(</span><span class="identifier">double_</span>
- <span class="special"><<</span> <span class="char">','</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="number">1.0</span><span class="special">,</span><span class="number">8.0</span><span class="special">,</span><span class="number">10.0</span><span class="special">,</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">*(</span><span class="identifier">double_</span>
+ <span class="special"><<</span> <span class="char">','</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="number">1.0</span><span class="special">,</span><span class="number">8.0</span><span class="special">,</span><span class="number">10.0</span><span class="special">,</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A list of floating point numbers
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
We will see later in this documentation how it is possible to avoid printing
- the trailing <tt class="computeroutput"><span class="char">','</span></tt>.
+ the trailing <code class="computeroutput"><span class="char">','</span></code>.
</p>
<p>
Overall, the syntax is similar to <span class="emphasis"><em>Spirit.Qi</em></span> with the exception
- that we use the <tt class="computeroutput"><span class="special"><<</span></tt> operator
+ that we use the <code class="computeroutput"><span class="special"><<</span></code> operator
for output concatenation. This should be easy to understand as it follows the
conventions used in the Standard's I/O streams.
</p>
@@ -353,61 +376,81 @@
next table gives some related examples.
</p>
<div class="table">
-<a name="id413607"></a><p class="title"><b>Table 3. Different data types usable with the output format
+<a name="id1105499"></a><p class="title"><b>Table 3. Different data types usable with the output format
`*(int_ << eol)`</b></p>
-<table class="table" summary="Different data types usable with the output format
+<div class="table-contents"><table class="table" summary="Different data types usable with the output format
`*(int_ << eol)`">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Data type
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span> <span class="identifier">i</span><span class="special">[</span><span class="number">4</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span> <span class="identifier">i</span><span class="special">[</span><span class="number">4</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
C style arrays
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
Standard vector
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">list</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">list</span><span class="special"><</span><span class="keyword">int</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
Standard list
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">array</span><span class="special"><</span><span class="keyword">long</span><span class="special">,</span> <span class="number">20</span><span class="special">></span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">array</span><span class="special"><</span><span class="keyword">long</span><span class="special">,</span> <span class="number">20</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
Boost array
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<div class="footnotes">
+<br class="table-break"><div class="footnotes">
<br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a name="ftn.id411217" href="#id411217">1</a>] </sup>
+<div class="footnote"><p><sup>[<a name="ftn.id1101419" href="#id1101419" class="para">1</a>] </sup>
<a href="http://www.cl.cam.ac.uk/%7Emgk25/iso-14977.pdf" target="_top">ISO-EBNF</a>
</p></div>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,12 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Karma - Writing Generators</title>
+<title>Karma - Writing Generators</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="qi/reference/string/symbols.html" title="symbols">
+<link rel="prev" href="qi/reference/string/symbols.html" title="symbols">
<link rel="next" href="karma/tutorials.html" title="Tutorials">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="qi/reference/string/symbols.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="karma/tutorials.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.karma"></a> Karma - Writing Generators
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Karma - Writing Generators">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.karma"></a><a class="link" href="karma.html" title="Karma - Writing Generators"> Karma - Writing Generators</a>
+</h2></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Tutorials</span></dt>
<dd><dl>
@@ -47,7 +44,7 @@
<dt><span class="section"><a href="karma/quick_reference/common_notation.html">Common
Notation</a></span></dt>
<dt><span class="section"><a href="karma/quick_reference/primitive_generators.html">
- Primitive Generators</a></span></dt>
+ Karma Generators</a></span></dt>
<dt><span class="section"><a href="karma/quick_reference/compound_attribute_rules.html">Compound
Attribute Rules</a></span></dt>
<dt><span class="section">Non-terminals</span></dt>
@@ -63,10 +60,11 @@
<dt><span class="section"> Char</span></dt>
<dt><span class="section"> String</span></dt>
<dt><span class="section"> Numeric</span></dt>
-<dt><span class="section">Directive</span></dt>
-<dt><span class="section">Operator</span></dt>
<dt><span class="section">Stream</span></dt>
+<dt><span class="section"> Binary</span></dt>
<dt><span class="section">Auxiliary</span></dt>
+<dt><span class="section">Directive</span></dt>
+<dt><span class="section">Operator</span></dt>
</dl></dd>
<dt><span class="section">Performance Measurements</span></dt>
<dd><dl><dt><span class="section"><a href="karma/performance_measurements/numeric_performance.html">
Modified: trunk/libs/spirit/doc/html/spirit/karma/performance_measurements.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/performance_measurements.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/performance_measurements.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Performance Measurements</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../karma.html" title=" Karma - Writing Generators">
-<link rel="previous" href="reference/auxiliary/lazy.html" title="lazy">
-<link rel="next" href="performance_measurements/numeric_performance.html" title="
- Performance of Numeric Generators">
+<link rel="up" href="../karma.html" title="Karma - Writing Generators">
+<link rel="prev" href="reference/operator/not_predicate.html" title="Not Predicate (unary operator!())">
+<link rel="next" href="performance_measurements/numeric_performance.html" title="Performance of Numeric Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -21,15 +20,12 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="reference/auxiliary/lazy.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="performance_measurements/numeric_performance.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.karma.performance_measurements"></a>Performance Measurements
-</h3></div></div>
-<div></div>
+<a accesskey="p" href="reference/operator/not_predicate.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="performance_measurements/numeric_performance.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="Performance Measurements">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.karma.performance_measurements"></a><a class="link" href="performance_measurements.html" title="Performance Measurements">Performance Measurements</a>
+</h3></div></div></div>
<div class="toc"><dl><dt><span class="section"><a href="performance_measurements/numeric_performance.html">
Performance of Numeric Generators</a></span></dt></dl></div>
</div>
@@ -44,7 +40,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="reference/auxiliary/lazy.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="performance_measurements/numeric_performance.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="reference/operator/not_predicate.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="performance_measurements/numeric_performance.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Performance of Numeric Generators</title>
+<title>Performance of Numeric Generators</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../performance_measurements.html" title="Performance Measurements">
-<link rel="previous" href="../performance_measurements.html" title="Performance Measurements">
-<link rel="next" href="numeric_performance/int_performance.html" title="
- Comparing the performance of a single int_ generator">
+<link rel="prev" href="../performance_measurements.html" title="Performance Measurements">
+<link rel="next" href="numeric_performance/int_performance.html" title="Comparing the performance of a single int_ generator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="../performance_measurements.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../performance_measurements.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="numeric_performance/int_performance.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.performance_measurements.numeric_performance"></a><a href="numeric_performance.html" title="
- Performance of Numeric Generators">
+<div class="section" title="Performance of Numeric Generators">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.performance_measurements.numeric_performance"></a><a class="link" href="numeric_performance.html" title="Performance of Numeric Generators">
Performance of Numeric Generators</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="numeric_performance/int_performance.html">
Comparing the performance of a single int_ generator</a></span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/double_performance.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/double_performance.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/double_performance.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Comparing the performance of a single double_ generator</title>
+<title>Comparing the performance of a single double_ generator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric_performance.html" title="
- Performance of Numeric Generators">
-<link rel="previous" href="int_performance.html" title="
- Comparing the performance of a single int_ generator">
-<link rel="next" href="format_performance.html" title="
- Comparing the performance of a sequence of several generators">
+<link rel="up" href="../numeric_performance.html" title="Performance of Numeric Generators">
+<link rel="prev" href="int_performance.html" title="Comparing the performance of a single int_ generator">
+<link rel="next" href="format_performance.html" title="Comparing the performance of a sequence of several generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,20 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="int_performance.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric_performance.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="format_performance.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.performance_measurements.numeric_performance.double_performance"></a><a href="double_performance.html" title="
- Comparing the performance of a single double_ generator">
+<div class="section" title="Comparing the performance of a single double_ generator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.performance_measurements.numeric_performance.double_performance"></a><a class="link" href="double_performance.html" title="Comparing the performance of a single double_ generator">
Comparing the performance of a single double_ generator</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
This performance measurements are centered around default formatting
- of a single <tt class="computeroutput"><span class="keyword">double</span></tt> floating
+ of a single <code class="computeroutput"><span class="keyword">double</span></code> floating
point number using different libraries and methods. The overall execution
- times for those examples are compared below. We compare using <tt class="computeroutput"><span class="identifier">sprintf</span></tt>, C++ iostreams, Boost.Format,
+ times for those examples are compared below. We compare using <code class="computeroutput"><span class="identifier">sprintf</span></code>, C++ iostreams, Boost.Format,
and <span class="emphasis"><em>Spirit.Karma</em></span>.
</p>
<p>
@@ -49,7 +41,7 @@
below).
</p>
<p>
- Code used to measure the performance for <tt class="computeroutput"><span class="identifier">sprintf</span></tt>:
+ Code used to measure the performance for <code class="computeroutput"><span class="identifier">sprintf</span></code>:
</p>
<p>
</p>
@@ -140,12 +132,12 @@
using different compilers. All times are in seconds measured for 1000000
iterations (platform: Windows7, Intel Core Duo(tm) Processor, 2.8GHz,
4GByte RAM). For a more readable comparison of the results see this
- figure.
+ <a class="link" href="double_performance.html#spirit.karma.double_performance" title="Figure 4. Performance comparison for a single double">figure</a>.
</p>
<div class="table">
-<a name="id589032"></a><p class="title"><b>Table 7. Performance comparison for a single double (all
+<a name="id1299464"></a><p class="title"><b>Table 7. Performance comparison for a single double (all
times in [s], 1000000 iterations)</b></p>
-<table class="table" summary="Performance comparison for a single double (all
+<div class="table-contents"><table class="table" summary="Performance comparison for a single double (all
times in [s], 1000000 iterations)">
<colgroup>
<col>
@@ -157,132 +149,201 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Library
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (64 bit)
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
sprintf
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.755
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.965
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.880
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.713
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.807
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.694
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
iostreams
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.316
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.624
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.964
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.634
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.468
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.354
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<a href="http://www.boost.org/doc/libs/1_39_0/libs/format/index.html" target="_top">Boost.Format</a>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.188
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.737
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.878
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.217
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.672
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.011
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<span class="emphasis"><em>Spirit.Karma</em></span> double_
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.813
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.561
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.368
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.426
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.260
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.218
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
</p>
<div class="figure">
<a name="spirit.karma.double_performance"></a><p class="title"><b>Figure 4. Performance comparison for a single double</b></p>
-<span class="inlinemediaobject"><img src="./images/double_performance.png" alt="Performance
- comparison for a single double"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../../../.././images/double_performance.png" alt="Performance comparison for a single double"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/format_performance.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/format_performance.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/format_performance.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Comparing the performance of a sequence of several generators</title>
+<title>Comparing the performance of a sequence of several generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric_performance.html" title="
- Performance of Numeric Generators">
-<link rel="previous" href="double_performance.html" title="
- Comparing the performance of a single double_ generator">
-<link rel="next" href="../../../lex.html" title=" Lex - Writing Lexical Analyzers">
+<link rel="up" href="../numeric_performance.html" title="Performance of Numeric Generators">
+<link rel="prev" href="double_performance.html" title="Comparing the performance of a single double_ generator">
+<link rel="next" href="../../../lex.html" title="Lex - Writing Lexical Analyzers">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,21 +22,17 @@
<div class="spirit-nav">
<a accesskey="p" href="double_performance.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric_performance.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../../lex.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.performance_measurements.numeric_performance.format_performance"></a><a href="format_performance.html" title="
- Comparing the performance of a sequence of several generators">
+<div class="section" title="Comparing the performance of a sequence of several generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.performance_measurements.numeric_performance.format_performance"></a><a class="link" href="format_performance.html" title="Comparing the performance of a sequence of several generators">
Comparing the performance of a sequence of several generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
This performance measurements are centered around formatting of a sequence
- of different items, including 2 <tt class="computeroutput"><span class="keyword">double</span></tt>
+ of different items, including 2 <code class="computeroutput"><span class="keyword">double</span></code>
floating point numbers using different libraries and methods. The overall
execution times for those examples are compared below. We compare using
- <tt class="computeroutput"><span class="identifier">sprintf</span></tt>, C++ iostreams,
+ <code class="computeroutput"><span class="identifier">sprintf</span></code>, C++ iostreams,
<a href="http://www.boost.org/doc/libs/1_39_0/libs/format/index.html" target="_top">Boost.Format</a>,
and <span class="emphasis"><em>Spirit.Karma</em></span>.
</p>
@@ -159,13 +152,12 @@
using different compilers. All times are in seconds measured for 1000000
iterations (platform: Windows7, Intel Core Duo(tm) Processor, 2.8GHz,
4GByte RAM). For a more readable comparison of the results see this
- <a href="format_performance.html#spirit.karma.format_performance" title="Figure 5. Performance comparison for a sequence
- of several items">figure</a>.
+ <a class="link" href="format_performance.html#spirit.karma.format_performance" title="Figure 5. Performance comparison for a sequence of several items">figure</a>.
</p>
<div class="table">
-<a name="id591023"></a><p class="title"><b>Table 8. Performance comparison for a sequence of several
+<a name="id1301017"></a><p class="title"><b>Table 8. Performance comparison for a sequence of several
items (all times in [s], 1000000 iterations)</b></p>
-<table class="table" summary="Performance comparison for a sequence of several
+<div class="table-contents"><table class="table" summary="Performance comparison for a sequence of several
items (all times in [s], 1000000 iterations)">
<colgroup>
<col>
@@ -177,133 +169,202 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Library
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (64 bit)
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
sprintf
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.725
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.892
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.903
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.469
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.608
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.493
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
iostreams
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
4.827
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
5.287
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
4.444
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.112
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.319
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
2.877
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<a href="http://www.boost.org/doc/libs/1_39_0/libs/format/index.html" target="_top">Boost.Format</a>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
5.881
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
7.089
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
5.801
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
5.455
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
5.254
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
4.164
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<span class="emphasis"><em>Spirit.Karma</em></span>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.942
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.242
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.999
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.334
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.758
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.686
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
</p>
<div class="figure">
<a name="spirit.karma.format_performance"></a><p class="title"><b>Figure 5. Performance comparison for a sequence
of several items</b></p>
-<span class="inlinemediaobject"><img src="./images/format_performance.png" alt="Performance comparison
- for a sequence of several items"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../../../.././images/format_performance.png" alt="Performance comparison for a sequence of several items"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/int_performance.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/int_performance.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/performance_measurements/numeric_performance/int_performance.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Comparing the performance of a single int_ generator</title>
+<title>Comparing the performance of a single int_ generator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric_performance.html" title="
- Performance of Numeric Generators">
-<link rel="previous" href="../numeric_performance.html" title="
- Performance of Numeric Generators">
-<link rel="next" href="double_performance.html" title="
- Comparing the performance of a single double_ generator">
+<link rel="up" href="../numeric_performance.html" title="Performance of Numeric Generators">
+<link rel="prev" href="../numeric_performance.html" title="Performance of Numeric Generators">
+<link rel="next" href="double_performance.html" title="Comparing the performance of a single double_ generator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,20 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="../numeric_performance.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric_performance.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="double_performance.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.performance_measurements.numeric_performance.int_performance"></a><a href="int_performance.html" title="
- Comparing the performance of a single int_ generator">
+<div class="section" title="Comparing the performance of a single int_ generator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.performance_measurements.numeric_performance.int_performance"></a><a class="link" href="int_performance.html" title="Comparing the performance of a single int_ generator">
Comparing the performance of a single int_ generator</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
This performance measurements are centered around default formatting
- of a single <tt class="computeroutput"><span class="keyword">int</span></tt> integer
+ of a single <code class="computeroutput"><span class="keyword">int</span></code> integer
number using different libraries and methods. The overall execution times
- for those examples are compared below. We compare using <tt class="computeroutput"><span class="identifier">sprintf</span></tt>, C++ iostreams, Boost.Format,
+ for those examples are compared below. We compare using <code class="computeroutput"><span class="identifier">sprintf</span></code>, C++ iostreams, Boost.Format,
and <span class="emphasis"><em>Spirit.Karma</em></span>.
</p>
<p>
@@ -49,7 +41,7 @@
shown below).
</p>
<p>
- Code used to measure the performance for <tt class="computeroutput"><span class="identifier">ltoa</span></tt>:
+ Code used to measure the performance for <code class="computeroutput"><span class="identifier">ltoa</span></code>:
</p>
<p>
</p>
@@ -130,12 +122,12 @@
using different compilers. All times are in seconds measured for 10000000
iterations (platform: Windows7, Intel Core Duo(tm) Processor, 2.8GHz,
4GByte RAM). For a more readable comparison of the results see this
- figure.
+ <a class="link" href="int_performance.html#spirit.karma.int_performance" title="Figure 3. Performance comparison for a single int">figure</a>.
</p>
<div class="table">
-<a name="id587659"></a><p class="title"><b>Table 6. Performance comparison for a single int (all
+<a name="id1298407"></a><p class="title"><b>Table 6. Performance comparison for a single int (all
times in [s], 10000000 iterations)</b></p>
-<table class="table" summary="Performance comparison for a single int (all
+<div class="table-contents"><table class="table" summary="Performance comparison for a single int (all
times in [s], 10000000 iterations)">
<colgroup>
<col>
@@ -147,132 +139,201 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Library
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (32 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
gcc 4.4.0 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
VC++ 10 (64 bit)
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Intel 11.1 (64 bit)
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
ltoa
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.542
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.895
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.884
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.163
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.099
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.906
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
iostreams
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
6.548
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
13.727
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
11.898
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
3.464
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
8.316
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
8.115
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<a href="http://www.boost.org/doc/libs/1_39_0/libs/format/index.html" target="_top">Boost.Format</a>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
16.998
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
21.813
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
20.477
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
17.464
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
14.662
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
13.646
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
<span class="emphasis"><em>Spirit.Karma</em></span> int_
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.421
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.744
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.697
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
1.072
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.953
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
0.606
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
</p>
<div class="figure">
<a name="spirit.karma.int_performance"></a><p class="title"><b>Figure 3. Performance comparison for a single int</b></p>
-<span class="inlinemediaobject"><img src="./images/int_performance.png" alt="Performance
- comparison for a single int"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../../../.././images/int_performance.png" alt="Performance comparison for a single int"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Quick Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../karma.html" title=" Karma - Writing Generators">
-<link rel="previous" href="tutorials/karma_easier_complex.html" title=" Complex
- - Made easier">
-<link rel="next" href="quick_reference/common_notation.html" title="Common
- Notation">
+<link rel="up" href="../karma.html" title="Karma - Writing Generators">
+<link rel="prev" href="tutorials/karma_easier_complex.html" title="Complex - Made easier">
+<link rel="next" href="quick_reference/common_notation.html" title="Common Notation">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,15 @@
<div class="spirit-nav">
<a accesskey="p" href="tutorials/karma_easier_complex.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="quick_reference/common_notation.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.karma.quick_reference"></a>Quick Reference
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Quick Reference">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.karma.quick_reference"></a><a class="link" href="quick_reference.html" title="Quick Reference">Quick Reference</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="quick_reference/common_notation.html">Common
Notation</a></span></dt>
<dt><span class="section"><a href="quick_reference/primitive_generators.html">
- Primitive Generators</a></span></dt>
+ Karma Generators</a></span></dt>
<dt><span class="section"><a href="quick_reference/compound_attribute_rules.html">Compound
Attribute Rules</a></span></dt>
<dt><span class="section">Non-terminals</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/common_notation.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/common_notation.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/common_notation.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Common
- Notation</title>
+<title>Common Notation</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="../quick_reference.html" title="Quick Reference">
-<link rel="next" href="primitive_generators.html" title="
- Primitive Generators">
+<link rel="prev" href="../quick_reference.html" title="Quick Reference">
+<link rel="next" href="primitive_generators.html" title="Karma Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,126 +22,122 @@
<div class="spirit-nav">
<a accesskey="p" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="primitive_generators.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.common_notation"></a><a href="common_notation.html" title="Common
- Notation">Common
+<div class="section" title="Common Notation">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.common_notation"></a><a class="link" href="common_notation.html" title="Common Notation">Common
Notation</a>
-</h4></div></div>
-<div></div>
-</div>
-<div class="variablelist">
+</h4></div></div></div>
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">G</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">G</span></code></span></dt>
<dd><p>
Generator type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span><span class="special">,</span> <span class="identifier">a</span><span class="special">,</span>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span><span class="special">,</span> <span class="identifier">a</span><span class="special">,</span>
<span class="identifier">b</span><span class="special">,</span>
<span class="identifier">c</span><span class="special">,</span>
- <span class="identifier">d</span></tt></span></dt>
+ <span class="identifier">d</span></code></span></dt>
<dd><p>
Generator objects
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">,</span>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">,</span>
<span class="identifier">C</span><span class="special">,</span>
- <span class="identifier">D</span></tt></span></dt>
+ <span class="identifier">D</span></code></span></dt>
<dd><p>
- Attribute types of generators <tt class="computeroutput"><span class="identifier">a</span></tt>,
- <tt class="computeroutput"><span class="identifier">b</span></tt>, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- and <tt class="computeroutput"><span class="identifier">d</span></tt>
+ Attribute types of generators <code class="computeroutput"><span class="identifier">a</span></code>,
+ <code class="computeroutput"><span class="identifier">b</span></code>, <code class="computeroutput"><span class="identifier">c</span></code>,
+ and <code class="computeroutput"><span class="identifier">d</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">I</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">I</span></code></span></dt>
<dd><p>
The iterator type used for generation
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Unused</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Unused</span></code></span></dt>
<dd><p>
- An <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ An <code class="computeroutput"><span class="identifier">unused_type</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Context</span></code></span></dt>
<dd><p>
- The enclosing rule's <tt class="computeroutput"><span class="identifier">Context</span></tt>
+ The enclosing rule's <code class="computeroutput"><span class="identifier">Context</span></code>
type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">attrib</span></code></span></dt>
<dd><p>
A attribute value
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Attrib</span></code></span></dt>
<dd><p>
An attribute type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">b</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">b</span></code></span></dt>
<dd><p>
A boolean expression
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fg</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fg</span></code></span></dt>
<dd><p>
- A (lazy generator) function with signature <tt class="computeroutput"><span class="identifier">G</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span></tt>
+ A (lazy generator) function with signature <code class="computeroutput"><span class="identifier">G</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fa</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fa</span></code></span></dt>
<dd><p>
- A (semantic action) function with signature <tt class="computeroutput"><span class="keyword">void</span><span class="special">(</span><span class="identifier">Attr</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">,</span> <span class="keyword">bool</span><span class="special">&)</span></tt>. The third parameter is a boolean
+ A (semantic action) function with signature <code class="computeroutput"><span class="keyword">void</span><span class="special">(</span><span class="identifier">Attr</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">,</span> <span class="keyword">bool</span><span class="special">&)</span></code>. The third parameter is a boolean
flag that can be set to false to force the generator to fail. Both
- <tt class="computeroutput"><span class="identifier">Context</span></tt> and the boolean
+ <code class="computeroutput"><span class="identifier">Context</span></code> and the boolean
flag are optional.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">outiter</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">outiter</span></code></span></dt>
<dd><p>
An output iterator to receive the generated output
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Ch</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Ch</span></code></span></dt>
<dd><p>
Character-class specific character type (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ch</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ch</span></code></span></dt>
<dd><p>
Character-class specific character (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ch2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ch2</span></code></span></dt>
<dd><p>
Character-class specific character (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">charset</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">charset</span></code></span></dt>
<dd><p>
Character-set specifier string (example: "a-z0-9")
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">str</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">str</span></code></span></dt>
<dd><p>
Character-class specific string (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Str</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Str</span></code></span></dt>
<dd><p>
- Attribute of <tt class="computeroutput"><span class="identifier">str</span></tt>:
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the underlying
- character type of <tt class="computeroutput"><span class="identifier">str</span></tt>
+ Attribute of <code class="computeroutput"><span class="identifier">str</span></code>:
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the underlying
+ character type of <code class="computeroutput"><span class="identifier">str</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span></code></span></dt>
<dd><p>
Numeric literal, any integer or floating point type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Num</span></code></span></dt>
<dd><p>
- Attribute of <tt class="computeroutput"><span class="identifier">num</span></tt>: any
+ Attribute of <code class="computeroutput"><span class="identifier">num</span></code>: any
integer or floating point type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">tuple</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a fusion sequence
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">vector</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">vector</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for an STL container
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a boost::variant
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">optional</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">optional</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a boost::optional
</p></dd>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/compound_attribute_rules.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/compound_attribute_rules.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/compound_attribute_rules.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Compound
- Attribute Rules</title>
+<title>Compound Attribute Rules</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="primitive_generators/directives.html" title="
- Generator Directives">
+<link rel="prev" href="primitive_generators/directives.html" title="Generator Directives">
<link rel="next" href="non_terminals.html" title="Non-terminals">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -24,52 +22,53 @@
<div class="spirit-nav">
<a accesskey="p" href="primitive_generators/directives.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="non_terminals.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.compound_attribute_rules"></a><a href="compound_attribute_rules.html" title="Compound
- Attribute Rules">Compound
+<div class="section" title="Compound Attribute Rules">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.compound_attribute_rules"></a><a class="link" href="compound_attribute_rules.html" title="Compound Attribute Rules">Compound
Attribute Rules</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The notation will be for instance:
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
</pre>
<p>
- which reads as: given, <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> are generators, and
- <tt class="computeroutput"><span class="identifier">A</span></tt> is the type of the attribute
- of <tt class="computeroutput"><span class="identifier">a</span></tt>, and <tt class="computeroutput"><span class="identifier">B</span></tt> is the type of the attribute of <tt class="computeroutput"><span class="identifier">b</span></tt>, then the type of the attribute of
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
- <span class="identifier">b</span></tt> will be <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>.
+ which reads as: given, <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> are generators, and
+ <code class="computeroutput"><span class="identifier">A</span></code> is the type of the attribute
+ of <code class="computeroutput"><span class="identifier">a</span></code>, and <code class="computeroutput"><span class="identifier">B</span></code> is the type of the attribute of <code class="computeroutput"><span class="identifier">b</span></code>, then the type of the attribute of
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
+ <span class="identifier">b</span></code> will be <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>.
</p>
<div class="table">
-<a name="id492156"></a><p class="title"><b>Table 5. Spirit.Karma compound generator attribute types</b></p>
-<table class="table" summary="Spirit.Karma compound generator attribute types">
+<a name="id1184139"></a><p class="title"><b>Table 5. Spirit.Karma compound generator attribute types</b></p>
+<div class="table-contents"><table class="table" summary="Spirit.Karma compound generator attribute types">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../reference/operator/sequence.html" title=" Sequences
- (operator<<())">sequence
- (<tt class="computeroutput"><span class="special"><<</span></tt>)</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/sequence.html" title="Sequences (operator<<())">sequence
+ (<code class="computeroutput"><span class="special"><<</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -83,16 +82,17 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/alternative.html" title=" Alternatives
- (operator|())">alternative
- (<tt class="computeroutput"><span class="special">|</span></tt>)</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/alternative.html" title="Alternatives (operator|())">alternative
+ (<code class="computeroutput"><span class="special">|</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -102,112 +102,125 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">A</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/kleene.html" title=" Kleene Star
- (unary operator*())">kleene (unary
- <tt class="computeroutput"><span class="special">*</span></tt>)</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/kleene.html" title="Kleene Star (unary operator*())">kleene (unary
+ <code class="computeroutput"><span class="special">*</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/plus.html" title=" Plus (unary
- operator+())">plus (unary
- <tt class="computeroutput"><span class="special">+</span></tt>)</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/plus.html" title="Plus (unary operator+())">plus (unary
+ <code class="computeroutput"><span class="special">+</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- list (%)
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/list.html" title="Lists (operator%())">list (<code class="computeroutput"><span class="special">%</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/directive/repeat.html" title=" Repetition
- Directive (repeat[])">repetition</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/directive/repeat.html" title="Repetition Directive (repeat[])">repetition</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(...,...)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(...,...)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/optional.html" title=" Optional
- (unary operator-())">optional
- (unary <tt class="computeroutput"><span class="special">-</span></tt>)</a>
- </p></td>
<td>
-<p>
+ <p>
+ <a class="link" href="../reference/operator/optional.html" title="Optional (unary operator-())">optional
+ (unary <code class="computeroutput"><span class="special">-</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/and_predicate.html" title=" And
- Predicate (unary operator&())">and
- predicate (unary <tt class="computeroutput"><span class="special">&</span></tt>)</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ <a class="link" href="../reference/operator/and_predicate.html" title="And Predicate (unary operator&())">and
+ predicate (unary <code class="computeroutput"><span class="special">&</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></tt>
- </p></td>
+ <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../reference/operator/not_predicate.html" title=" Not
- Predicate (unary operator!())">not
- predicate (unary <tt class="computeroutput"><span class="special">!</span></tt>)</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ <a class="link" href="../reference/operator/not_predicate.html" title="Not Predicate (unary operator!())">not
+ predicate (unary <code class="computeroutput"><span class="special">!</span></code>)</a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></tt>
- </p></td>
+ <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></code>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
+<br class="table-break">
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/non_terminals.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/non_terminals.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/non_terminals.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Non-terminals</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="compound_attribute_rules.html" title="Compound
- Attribute Rules">
-<link rel="next" href="semantic_actions.html" title="Semantic
- Actions">
+<link rel="prev" href="compound_attribute_rules.html" title="Compound Attribute Rules">
+<link rel="next" href="semantic_actions.html" title="Semantic Actions">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,61 +22,58 @@
<div class="spirit-nav">
<a accesskey="p" href="compound_attribute_rules.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.non_terminals"></a>Non-terminals
-</h4></div></div>
-<div></div>
-</div>
-<div class="variablelist">
+<div class="section" title="Non-terminals">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.non_terminals"></a><a class="link" href="non_terminals.html" title="Non-terminals">Non-terminals</a>
+</h4></div></div></div>
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">RT</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">RT</span></code></span></dt>
<dd><p>
Synthesized attribute. The rule or grammar's return type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Arg1</span></tt>,
- <tt class="computeroutput"><span class="identifier">Arg2</span></tt>, <tt class="computeroutput"><span class="identifier">ArgN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Arg1</span></code>,
+ <code class="computeroutput"><span class="identifier">Arg2</span></code>, <code class="computeroutput"><span class="identifier">ArgN</span></code></span></dt>
<dd><p>
Inherited attributes. Zero or more arguments.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">L1</span></tt>,
- <tt class="computeroutput"><span class="identifier">L2</span></tt>, <tt class="computeroutput"><span class="identifier">LN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">L1</span></code>,
+ <code class="computeroutput"><span class="identifier">L2</span></code>, <code class="computeroutput"><span class="identifier">LN</span></code></span></dt>
<dd><p>
Zero or more local variables.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">r</span><span class="special">,</span> <span class="identifier">r2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">r</span><span class="special">,</span> <span class="identifier">r2</span></code></span></dt>
<dd><p>
Rules
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
A grammar
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A generator expression
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">my_grammar</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">my_grammar</span></code></span></dt>
<dd><p>
A user defined grammar
</p></dd>
</dl>
</div>
-<div class="variablelist">
+<div class="variablelist" title="Terminology">
<p class="title"><b>Terminology</b></p>
<dl>
<dt><span class="term">Signature</span></dt>
<dd><p>
- <tt class="computeroutput"><span class="identifier">RT</span><span class="special">(</span><span class="identifier">Arg1</span><span class="special">,</span> <span class="identifier">Arg2</span> <span class="special">...</span>
- <span class="special">,</span><span class="identifier">ArgN</span><span class="special">)</span></tt>. The signature specifies the synthesized
+ <code class="computeroutput"><span class="identifier">RT</span><span class="special">(</span><span class="identifier">Arg1</span><span class="special">,</span> <span class="identifier">Arg2</span> <span class="special">...</span>
+ <span class="special">,</span><span class="identifier">ArgN</span><span class="special">)</span></code>. The signature specifies the synthesized
(return value) and inherited (arguments) attributes.
</p></dd>
<dt><span class="term">Locals</span></dt>
<dd><p>
- <tt class="computeroutput"><span class="identifier">locals</span><span class="special"><</span><span class="identifier">L1</span><span class="special">,</span> <span class="identifier">L2</span> <span class="special">...,</span>
- <span class="identifier">LN</span><span class="special">></span></tt>.
+ <code class="computeroutput"><span class="identifier">locals</span><span class="special"><</span><span class="identifier">L1</span><span class="special">,</span> <span class="identifier">L2</span> <span class="special">...,</span>
+ <span class="identifier">LN</span><span class="special">></span></code>.
The local variables.
</p></dd>
<dt><span class="term">Delimiter</span></dt>
@@ -87,15 +82,15 @@
</p></dd>
</dl>
</div>
-<div class="variablelist">
+<div class="variablelist" title="Template Arguments">
<p class="title"><b>Template Arguments</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Iterator</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Iterator</span></code></span></dt>
<dd><p>
The iterator type you will use for parsing.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A1</span></tt>,
- <tt class="computeroutput"><span class="identifier">A2</span></tt>, <tt class="computeroutput"><span class="identifier">A3</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A1</span></code>,
+ <code class="computeroutput"><span class="identifier">A2</span></code>, <code class="computeroutput"><span class="identifier">A3</span></code></span></dt>
<dd><p>
Can be one of 1)Signature 2)Locals 3)Skipper.
</p></dd>
@@ -107,111 +102,151 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
<span class="identifier">A1</span><span class="special">,</span>
<span class="identifier">A2</span><span class="special">,</span>
<span class="identifier">A3</span><span class="special">></span>
- <span class="identifier">r</span><span class="special">(</span><span class="identifier">name</span><span class="special">);</span></tt>
- </p></td>
-<td><p>
- Rule declaration. <tt class="computeroutput"><span class="identifier">Iterator</span></tt>
- is required. <tt class="computeroutput"><span class="identifier">A1</span><span class="special">,</span> <span class="identifier">A2</span><span class="special">,</span> <span class="identifier">A3</span></tt>
- are optional and can be specified in any order. <tt class="computeroutput"><span class="identifier">name</span></tt>
+ <span class="identifier">r</span><span class="special">(</span><span class="identifier">name</span><span class="special">);</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Rule declaration. <code class="computeroutput"><span class="identifier">Iterator</span></code>
+ is required. <code class="computeroutput"><span class="identifier">A1</span><span class="special">,</span> <span class="identifier">A2</span><span class="special">,</span> <span class="identifier">A3</span></code>
+ are optional and can be specified in any order. <code class="computeroutput"><span class="identifier">name</span></code>
is an optional string that gives the rule its name, useful for
debugging and error handling.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
<span class="identifier">A1</span><span class="special">,</span>
<span class="identifier">A2</span><span class="special">,</span>
<span class="identifier">A3</span><span class="special">></span>
- <span class="identifier">r</span><span class="special">(</span><span class="identifier">r2</span><span class="special">);</span></tt>
- </p></td>
-<td><p>
- Copy construct rule <tt class="computeroutput"><span class="identifier">r</span></tt>
- from rule <tt class="computeroutput"><span class="identifier">r2</span></tt>.
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
- <span class="identifier">r2</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
- Assign rule <tt class="computeroutput"><span class="identifier">r2</span></tt>
- to <tt class="computeroutput"><span class="identifier">r</span></tt>. <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">alias</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- return an alias of <tt class="computeroutput"><span class="identifier">r</span></tt>.
- The alias is a generator that holds a reference to <tt class="computeroutput"><span class="identifier">r</span></tt>. Reference semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">copy</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- Get a copy of <tt class="computeroutput"><span class="identifier">r</span></tt>.
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+ <span class="identifier">r</span><span class="special">(</span><span class="identifier">r2</span><span class="special">);</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Copy construct rule <code class="computeroutput"><span class="identifier">r</span></code>
+ from rule <code class="computeroutput"><span class="identifier">r2</span></code>.
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
+ <span class="identifier">r2</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Assign rule <code class="computeroutput"><span class="identifier">r2</span></code>
+ to <code class="computeroutput"><span class="identifier">r</span></code>. <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">alias</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ return an alias of <code class="computeroutput"><span class="identifier">r</span></code>.
+ The alias is a generator that holds a reference to <code class="computeroutput"><span class="identifier">r</span></code>. Reference semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">copy</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Get a copy of <code class="computeroutput"><span class="identifier">r</span></code>.
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Naming a rule
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Getting the name of a rule
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
- <span class="identifier">g</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
+ <span class="identifier">g</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Rule definition
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">%=</span>
- <span class="identifier">g</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
- Auto-rule definition. The attribute of <tt class="computeroutput"><span class="identifier">g</span></tt>
- should be compatible with the synthesized attribute of <tt class="computeroutput"><span class="identifier">r</span></tt>. When <tt class="computeroutput"><span class="identifier">g</span></tt>
- is successful, its attribute is automatically propagated to <tt class="computeroutput"><span class="identifier">r</span></tt>'s synthesized attribute.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">%=</span>
+ <span class="identifier">g</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Auto-rule definition. The attribute of <code class="computeroutput"><span class="identifier">g</span></code>
+ should be compatible with the synthesized attribute of <code class="computeroutput"><span class="identifier">r</span></code>. When <code class="computeroutput"><span class="identifier">g</span></code>
+ is successful, its attribute is automatically propagated to <code class="computeroutput"><span class="identifier">r</span></code>'s synthesized attribute.
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Iterator</span><span class="special">></span>
@@ -229,36 +264,50 @@
</pre>
<p>
</p>
-</td>
-<td><p>
- Grammar definition. <tt class="computeroutput"><span class="identifier">name</span></tt>
+ </td>
+<td>
+ <p>
+ Grammar definition. <code class="computeroutput"><span class="identifier">name</span></code>
is an optional string that gives the grammar its name, useful for
debugging and error handling.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
my_grammar<Iterator> g
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Instantiating a grammar
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Naming a grammar
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Getting the name of a grammar
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/phoenix.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/phoenix.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/phoenix.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Phoenix</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="semantic_actions.html" title="Semantic
- Actions">
+<link rel="prev" href="semantic_actions.html" title="Semantic Actions">
<link rel="next" href="../reference.html" title="Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../reference.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.phoenix"></a>Phoenix
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Phoenix">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.phoenix"></a><a class="link" href="phoenix.html" title="Phoenix">Phoenix</a>
+</h4></div></div></div>
<p>
<a href="../../../../../phoenix/doc/html/index.html" target="_top">Boost.Phoenix</a> makes
it easier to attach semantic actions. You just inline your lambda expressions:
@@ -38,37 +34,37 @@
</pre>
<p>
<span class="emphasis"><em>Spirit.Karma</em></span> provides some Boost.Phoenix
- placeholders to access important information from the <tt class="computeroutput"><span class="identifier">Attrib</span></tt>
- and <tt class="computeroutput"><span class="identifier">Context</span></tt> that are otherwise
+ placeholders to access important information from the <code class="computeroutput"><span class="identifier">Attrib</span></code>
+ and <code class="computeroutput"><span class="identifier">Context</span></code> that are otherwise
fiddly to extract.
</p>
-<div class="variablelist">
+<div class="variablelist" title="Spirit.Karma specific Phoenix placeholders">
<p class="title"><b>Spirit.Karma specific Phoenix placeholders</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_1</span><span class="special">,</span> <span class="identifier">_2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_N</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_1</span><span class="special">,</span> <span class="identifier">_2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_N</span></code></span></dt>
<dd><p>
- Nth attribute of <tt class="computeroutput"><span class="identifier">g</span></tt>
+ Nth attribute of <code class="computeroutput"><span class="identifier">g</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_val</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_val</span></code></span></dt>
<dd><p>
The enclosing rule's synthesized attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_r1</span><span class="special">,</span> <span class="identifier">_r2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_rN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_r1</span><span class="special">,</span> <span class="identifier">_r2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_rN</span></code></span></dt>
<dd><p>
The enclosing rule's Nth inherited attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_a</span><span class="special">,</span> <span class="identifier">_b</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_j</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_a</span><span class="special">,</span> <span class="identifier">_b</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_j</span></code></span></dt>
<dd><p>
- The enclosing rule's local variables (<tt class="computeroutput"><span class="identifier">_a</span></tt>
+ The enclosing rule's local variables (<code class="computeroutput"><span class="identifier">_a</span></code>
refers to the first).
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_val</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_val</span></code></span></dt>
<dd><p>
The enclosing rule's synthesized attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_pass</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_pass</span></code></span></dt>
<dd><p>
- Assign <tt class="computeroutput"><span class="keyword">false</span></tt> to <tt class="computeroutput"><span class="identifier">_pass</span></tt> to force a generator failure.
+ Assign <code class="computeroutput"><span class="keyword">false</span></code> to <code class="computeroutput"><span class="identifier">_pass</span></code> to force a generator failure.
</p></dd>
</dl>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Primitive Generators</title>
+<title>Karma Generators</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="common_notation.html" title="Common
- Notation">
-<link rel="next" href="primitive_generators/char.html" title="
- Character Generators">
+<link rel="prev" href="common_notation.html" title="Common Notation">
+<link rel="next" href="primitive_generators/char.html" title="Character Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="common_notation.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="primitive_generators/char.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators"></a><a href="primitive_generators.html" title="
- Primitive Generators">
- Primitive Generators</a>
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Karma Generators">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators"></a><a class="link" href="primitive_generators.html" title="Karma Generators">
+ Karma Generators</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="primitive_generators/char.html">
Character Generators</a></span></dt>
@@ -41,10 +34,12 @@
String Generators</a></span></dt>
<dt><span class="section"><a href="primitive_generators/floating_point.html">
Floating Point Number Generators</a></span></dt>
-<dt><span class="section"><a href="primitive_generators/unsigned_int.html">
- Unsigned Integer Generators</a></span></dt>
<dt><span class="section"><a href="primitive_generators/signed_int.html">
Integer Generators</a></span></dt>
+<dt><span class="section"><a href="primitive_generators/unsigned_int.html">
+ Unsigned Integer Generators</a></span></dt>
+<dt><span class="section"><a href="primitive_generators/stream.html">
+ Stream Generators</a></span></dt>
<dt><span class="section"><a href="primitive_generators/binary.html">
Binary Generators</a></span></dt>
<dt><span class="section"><a href="primitive_generators/auxiliary.html">
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/auxiliary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/auxiliary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/auxiliary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Auxiliary Generators</title>
+<title>Auxiliary Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="binary.html" title="
- Binary Generators">
-<link rel="next" href="operators.html" title="
- Generator Operators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="binary.html" title="Binary Generators">
+<link rel="next" href="operators.html" title="Generator Operators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,17 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="binary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="operators.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.auxiliary"></a><a href="auxiliary.html" title="
- Auxiliary Generators">
+<div class="section" title="Auxiliary Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.auxiliary"></a><a class="link" href="auxiliary.html" title="Auxiliary Generators">
Auxiliary Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about <a href="../../reference/auxiliary.html" title="Auxiliary">Auxiliary
+ See here for more information about <a class="link" href="../../reference/auxiliary.html" title="Auxiliary">Auxiliary
Generators</a>.
</p>
<div class="informaltable"><table class="table">
@@ -46,89 +38,131 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- eol
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates the end of line (<tt class="computeroutput"><span class="special">\</span><span class="identifier">n</span></tt>)
- </p></td>
-</tr>
-<tr>
-<td><p>
- eps
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/eol.html" title="eol"><code class="computeroutput"><span class="identifier">eol</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the end of line (<code class="computeroutput"><span class="special">\</span><span class="identifier">n</span></code>)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/eps.html" title="eps"><code class="computeroutput"><span class="identifier">eps</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an empty string
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- eps(b)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- If <tt class="computeroutput"><span class="identifier">b</span></tt> is true,
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/eps.html" title="eps"><code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If <code class="computeroutput"><span class="identifier">b</span></code> is true,
generate an empty string
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- lazy(fg)
- </p></td>
-<td><p>
- Attribute of <tt class="computeroutput"><span class="identifier">G</span></tt>
- where <tt class="computeroutput"><span class="identifier">G</span></tt> is the
- return type of <tt class="computeroutput"><span class="identifier">fg</span></tt>
- </p></td>
-<td><p>
- Invoke <tt class="computeroutput"><span class="identifier">fg</span></tt> at
- generation time, returning a generator <tt class="computeroutput"><span class="identifier">g</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/lazy.html" title="lazy"><code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ Attribute of <code class="computeroutput"><span class="identifier">G</span></code>
+ where <code class="computeroutput"><span class="identifier">G</span></code> is the
+ return type of <code class="computeroutput"><span class="identifier">fg</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Invoke <code class="computeroutput"><span class="identifier">fg</span></code> at
+ generation time, returning a generator <code class="computeroutput"><span class="identifier">g</span></code>
which is then called to generate.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- fg
- </p></td>
-<td><p>
- see lazy(fg)
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/lazy.html" title="lazy"><code class="computeroutput"><span class="identifier">fg</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ see <a class="link" href="../../reference/auxiliary/lazy.html" title="lazy"><code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></code></a>
above
- </p></td>
-<td><p>
- Equivalent to lazy(fg)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">[</span><span class="identifier">fa</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Attribute of <tt class="computeroutput"><span class="identifier">g</span></tt>
- </p></td>
-<td><p>
- Call semantic action <tt class="computeroutput"><span class="identifier">fa</span></tt>
- (before executing <tt class="computeroutput"><span class="identifier">g</span></tt>).
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ Equivalent to <a class="link" href="../../reference/auxiliary/lazy.html" title="lazy"><code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">[</span><span class="identifier">fa</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Attribute of <code class="computeroutput"><span class="identifier">g</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call semantic action <code class="computeroutput"><span class="identifier">fa</span></code>
+ (before executing <code class="computeroutput"><span class="identifier">g</span></code>).
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/binary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/binary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/binary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Binary Generators</title>
+<title>Binary Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="signed_int.html" title="
- Integer Generators">
-<link rel="next" href="auxiliary.html" title="
- Auxiliary Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="stream.html" title="Stream Generators">
+<link rel="next" href="auxiliary.html" title="Auxiliary Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,19 +20,16 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="signed_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="stream.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.binary"></a><a href="binary.html" title="
- Binary Generators">
+<div class="section" title="Binary Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.binary"></a><a class="link" href="binary.html" title="Binary Generators">
Binary Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about Binary Generators .
+ See here for more information about <a class="link" href="../../reference/binary.html" title="Binary">Binary
+ Generators</a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -45,126 +38,210 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">byte_</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_native.html" title="Binary Native Endianness Generators"><code class="computeroutput"><span class="identifier">byte_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
8 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates an 8 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_native.html" title="Binary Native Endianness Generators"><code class="computeroutput"><span class="identifier">word</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
16 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 16 bit binary in native endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_big.html" title="Binary Big Endianness Generators"><code class="computeroutput"><span class="identifier">big_word</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
16 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 16 bit binary in big endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_little.html" title="Binary Little Endianness Generators"><code class="computeroutput"><span class="identifier">little_word</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
16 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 16 bit binary in little endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_native.html" title="Binary Native Endianness Generators"><code class="computeroutput"><span class="identifier">dword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
32 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 32 bit binary in native endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_big.html" title="Binary Big Endianness Generators"><code class="computeroutput"><span class="identifier">big_dword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
32 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 32 bit binary in big endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_little.html" title="Binary Little Endianness Generators"><code class="computeroutput"><span class="identifier">little_dword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
32 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 32 bit binary in little endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_native.html" title="Binary Native Endianness Generators"><code class="computeroutput"><span class="identifier">qword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
64 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 64 bit binary in native endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_big.html" title="Binary Big Endianness Generators"><code class="computeroutput"><span class="identifier">big_qword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
64 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 64 bit binary in big endian representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/binary/binary_little.html" title="Binary Little Endianness Generators"><code class="computeroutput"><span class="identifier">little_qword</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
64 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generates a 64 bit binary in little endian representation
- </p></td>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">pad</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate additional null bytes allowing to align generated output
+ with memory addresses divisible by <code class="computeroutput"><span class="identifier">num</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -180,7 +257,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="signed_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="stream.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/char.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/char.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/char.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Character Generators</title>
+<title>Character Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="next" href="string.html" title="
- String Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="../primitive_generators.html" title="Karma Generators">
+<link rel="next" href="string.html" title="String Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,17 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="string.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.char"></a><a href="char.html" title="
- Character Generators">
+<div class="section" title="Character Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.char"></a><a class="link" href="char.html" title="Character Generators">
Character Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about <a href="../../reference/char.html" title=" Char">Character
+ See here for more information about <a class="link" href="../../reference/char.html" title="Char">Character
Generators</a>.
</p>
<div class="informaltable"><table class="table">
@@ -46,277 +38,378 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">ch</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">ch</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates character supplied as the attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>,
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates a single char string literal, <tt class="computeroutput"><span class="identifier">c</span></tt>,
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates a single char string literal, <code class="computeroutput"><span class="identifier">c</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates a single char string literal, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- if <tt class="computeroutput"><span class="identifier">c</span></tt> belongs
- to the chracter range from <tt class="computeroutput"><span class="identifier">ch</span></tt>
- to <tt class="computeroutput"><span class="identifier">ch2</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates a single char string literal, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- if <tt class="computeroutput"><span class="identifier">c</span></tt> belongs
- to the chracter set <tt class="computeroutput"><span class="identifier">charset</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">alnum</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">alpha</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">blank</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">cntrl</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">digit</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">graph</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">print</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">punct</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">space</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates a single char string literal, <code class="computeroutput"><span class="identifier">c</span></code>,
+ if <code class="computeroutput"><span class="identifier">c</span></code> belongs
+ to the chracter range from <code class="computeroutput"><span class="identifier">ch</span></code>
+ to <code class="computeroutput"><span class="identifier">ch2</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates a single char string literal, <code class="computeroutput"><span class="identifier">c</span></code>,
+ if <code class="computeroutput"><span class="identifier">c</span></code> belongs
+ to the chracter set <code class="computeroutput"><span class="identifier">charset</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">alnum</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">alpha</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">blank</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">cntrl</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">digit</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">graph</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">print</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">punct</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">space</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></tt>,
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></code>,
or a single space character in the character set defined by
- <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">xdigit</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">lower</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/char/char_class.html" title=" Character
- Class Generators"><tt class="computeroutput"><span class="identifier">upper</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">NS</span></tt>
- </p></td>
+ <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">xdigit</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">lower</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/char/char_class.html" title="Character Class Generators"><code class="computeroutput"><span class="identifier">upper</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">NS</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/directives.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/directives.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/directives.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Generator Directives</title>
+<title>Generator Directives</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="operators.html" title="
- Generator Operators">
-<link rel="next" href="../compound_attribute_rules.html" title="Compound
- Attribute Rules">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="operators.html" title="Generator Operators">
+<link rel="next" href="../compound_attribute_rules.html" title="Compound Attribute Rules">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,17 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="operators.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../compound_attribute_rules.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.directives"></a><a href="directives.html" title="
- Generator Directives">
+<div class="section" title="Generator Directives">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.directives"></a><a class="link" href="directives.html" title="Generator Directives">
Generator Directives</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about <a href="../../reference/directive.html" title="Directive">Generator
+ See here for more information about <a class="link" href="../../reference/directive.html" title="Directive">Generator
Directives</a>.
</p>
<div class="informaltable"><table class="table">
@@ -46,309 +38,425 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../../reference/directive/upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])"><tt class="computeroutput"><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> as
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])"><code class="computeroutput"><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> as
lower case
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])"><tt class="computeroutput"><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> as
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])"><code class="computeroutput"><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> as
upper case
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
- aligned in column of width <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
- aligned in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
- aligned in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- while using <tt class="computeroutput"><span class="identifier">g</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
+ aligned in column of width <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
+ aligned in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
+ aligned in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ while using <code class="computeroutput"><span class="identifier">g</span></code>
to generate the necesssary padding
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
- in column of width <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
- in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
- in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- while using <tt class="computeroutput"><span class="identifier">g</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
+ in column of width <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
+ in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
+ in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ while using <code class="computeroutput"><span class="identifier">g</span></code>
to generate the necesssary padding
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
- aligned in column of width <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
- aligned in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
- aligned in column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- while using <tt class="computeroutput"><span class="identifier">g</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
+ aligned in column of width <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
+ aligned in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">g</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
+ aligned in column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ while using <code class="computeroutput"><span class="identifier">g</span></code>
to generate the necesssary padding
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])"><tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> truncated
- to column of width <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_MAXWIDTH</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])"><tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> truncated
- to column of width <tt class="computeroutput"><span class="identifier">num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/repeat.html" title=" Repetition
- Directive (repeat[])"><tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> zero
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])"><code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> truncated
+ to column of width <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_MAXWIDTH</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])"><code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> truncated
+ to column of width <code class="computeroutput"><span class="identifier">num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/repeat.html" title="Repetition Directive (repeat[])"><code class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> zero
or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/repeat.html" title=" Repetition
- Directive (repeat[])"><tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">num</span></tt> times
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/repeat.html" title=" Repetition
- Directive (repeat[])"><tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
- <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">num1</span></tt> to <tt class="computeroutput"><span class="identifier">num2</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/repeat.html" title="Repetition Directive (repeat[])"><code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">num</span></code> times
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/repeat.html" title="Repetition Directive (repeat[])"><code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
+ <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">num1</span></code> to <code class="computeroutput"><span class="identifier">num2</span></code>
times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/repeat.html" title=" Repetition
- Directive (repeat[])"><tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">num</span></tt> or more times
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"><tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Disable delimited generation for <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"><tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/repeat.html" title="Repetition Directive (repeat[])"><code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">num</span></code> or more times
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"><code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Disable delimited generation for <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"><code class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Reestablish the delimiter that got inhibited by verbatim
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"><tt class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Use <tt class="computeroutput"><span class="identifier">d</span></tt> as a delimiter
- for generating <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/directive/omit.html" title=" Consume Attribute
- (omit[])"><tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Consumes the attribute type of <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"><code class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Use <code class="computeroutput"><span class="identifier">d</span></code> as a delimiter
+ for generating <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/omit.html" title="Consume Attribute (omit[])"><code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Consumes the attribute type of <code class="computeroutput"><span class="identifier">a</span></code>
without generating anything
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Temporarily intercepts the output generated by <tt class="computeroutput"><span class="identifier">a</span></tt>, flushing it only after
- <tt class="computeroutput"><span class="identifier">a</span></tt> succeeded.
- </p></td>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Temporarily intercepts the output generated by <code class="computeroutput"><span class="identifier">a</span></code>, flushing it only after
+ <code class="computeroutput"><span class="identifier">a</span></code> succeeded.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/floating_point.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/floating_point.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/floating_point.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Floating Point Number Generators</title>
+<title>Floating Point Number Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="string.html" title="
- String Generators">
-<link rel="next" href="unsigned_int.html" title="
- Unsigned Integer Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="string.html" title="String Generators">
+<link rel="next" href="signed_int.html" title="Integer Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,19 +20,15 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="signed_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.floating_point"></a><a href="floating_point.html" title="
- Floating Point Number Generators">
+<div class="section" title="Floating Point Number Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.floating_point"></a><a class="link" href="floating_point.html" title="Floating Point Number Generators">
Floating Point Number Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about <a href="../../reference/numeric.html" title=" Numeric">Numeric
+ See here for more information about <a class="link" href="../../reference/numeric.html" title="Numeric">Numeric
Generators</a>.
</p>
<div class="informaltable"><table class="table">
@@ -46,143 +38,195 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- lit(num)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">float_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-<td><p>
- Generate a floating point number from a <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a floating point number from a <tt class="computeroutput"><span class="keyword">float</span></tt>,
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric.html" title="Numeric"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">float_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a floating point number from a <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a floating point number from a <code class="computeroutput"><span class="keyword">float</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">double_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate a floating point number from a <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a floating point number from a <tt class="computeroutput"><span class="keyword">double</span></tt>,
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">double_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a floating point number from a <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="identifier">num</span></code>
+ as a floating point number from a <code class="computeroutput"><span class="keyword">double</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">long_double</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate a floating point number from a <tt class="computeroutput"><span class="keyword">long</span>
- <span class="keyword">double</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators"><tt class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a floating point number from a <tt class="computeroutput"><span class="keyword">long</span>
- <span class="keyword">double</span></tt>, if an attribute
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">long_double</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a floating point number from a <code class="computeroutput"><span class="keyword">long</span>
+ <span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators"><code class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a floating point number from a <code class="computeroutput"><span class="keyword">long</span>
+ <span class="keyword">double</span></code>, if an attribute
is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators">
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span>
<span class="special">>()</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate a floating point number <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a floating point number <code class="computeroutput"><span class="identifier">Num</span></code>
using the supplied floating point formatting policies
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/floating_point.html" title=" Floating
- Point Number Generators">
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/floating_point.html" title="Floating Point Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span>
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate floating point number <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt> using
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate floating point number <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code> using
the supplied floating point formatting policies, if an attribute
is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -198,7 +242,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="signed_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/operators.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/operators.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/operators.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Generator Operators</title>
+<title>Generator Operators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="auxiliary.html" title="
- Auxiliary Generators">
-<link rel="next" href="directives.html" title="
- Generator Directives">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="auxiliary.html" title="Auxiliary Generators">
+<link rel="next" href="directives.html" title="Generator Directives">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,17 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directives.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.operators"></a><a href="operators.html" title="
- Generator Operators">
+<div class="section" title="Generator Operators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.operators"></a><a class="link" href="operators.html" title="Generator Operators">
Generator Operators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
- See here for more information about <a href="../../reference/operator.html" title="Operator">Generator
+ See here for more information about <a class="link" href="../../reference/operator.html" title="Operator">Generator
Operators</a>.
</p>
<div class="informaltable"><table class="table">
@@ -46,125 +38,172 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../../reference/operator/not_predicate.html" title=" Not
- Predicate (unary operator!())"><tt class="computeroutput"><span class="special">!</span><span class="identifier">a</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Not predicate. Ensure that <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/not_predicate.html" title="Not Predicate (unary operator!())"><code class="computeroutput"><span class="special">!</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Not predicate. Ensure that <code class="computeroutput"><span class="identifier">a</span></code>
does not succeed generating, but don't create any output
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/operator/not_predicate.html" title=" Not
- Predicate (unary operator!())"><tt class="computeroutput"><span class="special">&</span><span class="identifier">a</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- And predicate. Ensure that <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/not_predicate.html" title="Not Predicate (unary operator!())"><code class="computeroutput"><span class="special">&</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ And predicate. Ensure that <code class="computeroutput"><span class="identifier">a</span></code>
does succeed generating, but don't create any output
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/operator/optional.html" title=" Optional
- (unary operator-())"><tt class="computeroutput"><span class="special">-</span><span class="identifier">a</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Optional. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/optional.html" title="Optional (unary operator-())"><code class="computeroutput"><span class="special">-</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Optional. Generate <code class="computeroutput"><span class="identifier">a</span></code>
zero or one time
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/operator/kleene.html" title=" Kleene Star
- (unary operator*())"><tt class="computeroutput"><span class="special">*</span><span class="identifier">a</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Kleene. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/kleene.html" title="Kleene Star (unary operator*())"><code class="computeroutput"><span class="special">*</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Kleene. Generate <code class="computeroutput"><span class="identifier">a</span></code>
zero or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/operator/plus.html" title=" Plus (unary
- operator+())"><tt class="computeroutput"><span class="special">+</span><span class="identifier">a</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Plus. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/plus.html" title="Plus (unary operator+())"><code class="computeroutput"><span class="special">+</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Plus. Generate <code class="computeroutput"><span class="identifier">a</span></code>
one or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/operator/alternative.html" title=" Alternatives
- (operator|())"><tt class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
- <span class="identifier">b</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Alternative. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
- or <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/operator/sequence.html" title=" Sequences
- (operator<<())"><tt class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
- <span class="identifier">b</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Sequence. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
- followed by <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/operator/list.html" title=" Lists (operator%())"><tt class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
- <span class="identifier">b</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- List. Generate <tt class="computeroutput"><span class="identifier">a</span></tt>
- delimited <tt class="computeroutput"><span class="identifier">b</span></tt> one
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/alternative.html" title="Alternatives (operator|())"><code class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
+ <span class="identifier">b</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Alternative. Generate <code class="computeroutput"><span class="identifier">a</span></code>
+ or <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/sequence.html" title="Sequences (operator<<())"><code class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
+ <span class="identifier">b</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Sequence. Generate <code class="computeroutput"><span class="identifier">a</span></code>
+ followed by <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/operator/list.html" title="Lists (operator%())"><code class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
+ <span class="identifier">b</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ List. Generate <code class="computeroutput"><span class="identifier">a</span></code>
+ delimited <code class="computeroutput"><span class="identifier">b</span></code> one
or more times
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -173,8 +212,7 @@
</p>
<p>
For more information about the attribute propagation rules implemented
- by the compound generators please see <a href="../compound_attribute_rules.html" title="Compound
- Attribute Rules">Compound
+ by the compound generators please see <a class="link" href="../compound_attribute_rules.html" title="Compound Attribute Rules">Compound
Attribute Rules</a>.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/signed_int.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/signed_int.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/signed_int.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Integer Generators</title>
+<title>Integer Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="unsigned_int.html" title="
- Unsigned Integer Generators">
-<link rel="next" href="binary.html" title="
- Binary Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="floating_point.html" title="Floating Point Number Generators">
+<link rel="next" href="unsigned_int.html" title="Unsigned Integer Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,17 +20,13 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="floating_point.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.signed_int"></a><a href="signed_int.html" title="
- Integer Generators">
+<div class="section" title="Integer Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.signed_int"></a><a class="link" href="signed_int.html" title="Integer Generators">
Integer Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -42,150 +34,206 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">short_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">short_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a short integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as a short integer, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">int_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">int_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an int
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an int, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">long_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">long_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a long integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as long integer, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">long_long</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">long_long</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a long long
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an long long, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators">
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span>
<span class="special">>()</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators">
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/signed_int.html" title="Signed Integer Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span>
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt>, if
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -201,7 +249,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="floating_point.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Added: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/stream.html
==============================================================================
--- (empty file)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/stream.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -0,0 +1,194 @@
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Stream Generators</title>
+<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
+<link rel="home" href="../../../../index.html" title="Spirit 2.1">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="unsigned_int.html" title="Unsigned Integer Generators">
+<link rel="next" href="binary.html" title="Binary Generators">
+</head>
+<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
+<table cellpadding="2" width="100%"><tr>
+<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
+<td align="center">Home</td>
+<td align="center">Libraries</td>
+<td align="center">People</td>
+<td align="center">FAQ</td>
+<td align="center">More</td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+<div class="section" title="Stream Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.stream"></a><a class="link" href="stream.html" title="Stream Generators">
+ Stream Generators</a>
+</h5></div></div></div>
+<p>
+ See here for more information about <a class="link" href="../../reference/stream.html" title="Stream">Stream
+ Generators</a>.
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Attribute
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream"><code class="computeroutput"><span class="identifier">stream</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates narrow character (<code class="computeroutput"><span class="keyword">char</span></code>)
+ based output using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream"><code class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates narrow character (<code class="computeroutput"><span class="keyword">char</span></code>)
+ based output from the immediate argument <code class="computeroutput"><span class="identifier">s</span></code>
+ using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream"><code class="computeroutput"><span class="identifier">wstream</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates narrow character (<code class="computeroutput"><span class="keyword">wchar_t</span></code>)
+ based output using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream"><code class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates wide character (<code class="computeroutput"><span class="keyword">wchar_t</span></code>)
+ based output from the immediate argument <code class="computeroutput"><span class="identifier">s</span></code>
+ using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream">
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
+ <span class="identifier">Char</span>
+<span class="special">>()</span></pre>
+ </a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates output based on the given character type (<code class="computeroutput"><span class="identifier">Char</span></code>) using the matching streaming
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/stream.html" title="Stream">
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
+ <span class="identifier">Char</span>
+<span class="special">>()(</span><span class="identifier">s</span><span class="special">)</span></pre>
+ </a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates output based on the given character type <code class="computeroutput"><span class="identifier">Char</span></code> from the immediate argument
+ <code class="computeroutput"><span class="identifier">s</span></code> using the matching
+ streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+</div>
+<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
+<td align="left"></td>
+<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
+ de Guzman, Hartmut Kaiser<p>
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
+ file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ </p>
+</div></td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+</body>
+</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/string.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/string.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/string.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- String Generators</title>
+<title>String Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="char.html" title="
- Character Generators">
-<link rel="next" href="floating_point.html" title="
- Floating Point Number Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="char.html" title="Character Generators">
+<link rel="next" href="floating_point.html" title="Floating Point Number Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="char.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="floating_point.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.string"></a><a href="string.html" title="
- String Generators">
+<div class="section" title="String Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.string"></a><a class="link" href="string.html" title="String Generators">
String Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
See here for more information about String Generators .
</p>
@@ -45,61 +37,91 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- str
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
+<td>
+ <p>
+ <a class="link" href="../../reference/string.html" title="String"><code class="computeroutput"><span class="identifier">str</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- lit(str)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
+<td>
+ <p>
+ <a class="link" href="../../reference/string.html" title="String"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- string
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Str</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/string.html" title="String"><code class="computeroutput"><span class="identifier">string</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates string supplied as the attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- string(str)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Str</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt>,
+<td>
+ <p>
+ <a class="link" href="../../reference/string.html" title="String"><code class="computeroutput"><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/unsigned_int.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/unsigned_int.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/primitive_generators/unsigned_int.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Unsigned Integer Generators</title>
+<title>Unsigned Integer Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../primitive_generators.html" title="
- Primitive Generators">
-<link rel="previous" href="floating_point.html" title="
- Floating Point Number Generators">
-<link rel="next" href="signed_int.html" title="
- Integer Generators">
+<link rel="up" href="../primitive_generators.html" title="Karma Generators">
+<link rel="prev" href="signed_int.html" title="Integer Generators">
+<link rel="next" href="stream.html" title="Stream Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,17 +20,13 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="floating_point.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="signed_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="signed_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.quick_reference.primitive_generators.unsigned_int"></a><a href="unsigned_int.html" title="
- Unsigned Integer Generators">
+<div class="section" title="Unsigned Integer Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.quick_reference.primitive_generators.unsigned_int"></a><a class="link" href="unsigned_int.html" title="Unsigned Integer Generators">
Unsigned Integer Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -42,194 +34,265 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ushort_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ushort_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned short integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ushort_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ushort_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned short integer, if an attribute is supplied it
must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">uint_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">uint_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned int
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">uint_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">uint_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned int, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ulong_</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ulong_</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned long integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ulong_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ulong_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned long integer, if an attribute is supplied it must
match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ulong_long</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ulong_long</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned long long
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned long long, if an attribute is supplied it must
match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">bin</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate a binary integer from an <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="keyword">int</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">oct</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate an octal integer from an <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="keyword">int</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">hex</span></tt></a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate a hexadecimal integer from an <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="keyword">int</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators">
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">bin</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a binary integer from an <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">int</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">oct</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an octal integer from an <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">int</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators"><code class="computeroutput"><span class="identifier">hex</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a hexadecimal integer from an <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">int</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span>
<span class="special">>()</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate an unsigned <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/numeric/unsigned_int.html" title=" Unsigned
- Integer Number Generators">
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an unsigned <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/numeric/unsigned_int.html" title="Unsigned Integer Number Generators">
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
<span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span>
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
</a>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate an unsigned <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt>, if
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an unsigned <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -245,7 +308,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="floating_point.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="signed_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="signed_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../primitive_generators.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/quick_reference/semantic_actions.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/quick_reference/semantic_actions.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/quick_reference/semantic_actions.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Semantic
- Actions</title>
+<title>Semantic Actions</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="non_terminals.html" title="Non-terminals">
+<link rel="prev" href="non_terminals.html" title="Non-terminals">
<link rel="next" href="phoenix.html" title="Phoenix">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,22 +22,18 @@
<div class="spirit-nav">
<a accesskey="p" href="non_terminals.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="phoenix.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.quick_reference.semantic_actions"></a><a href="semantic_actions.html" title="Semantic
- Actions">Semantic
+<div class="section" title="Semantic Actions">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.quick_reference.semantic_actions"></a><a class="link" href="semantic_actions.html" title="Semantic Actions">Semantic
Actions</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
Has the form:
</p>
<pre class="programlisting"><span class="identifier">g</span><span class="special">[</span><span class="identifier">f</span><span class="special">]</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">f</span></tt> is a function with
+ where <code class="computeroutput"><span class="identifier">f</span></code> is a function with
the signatures:
</p>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Attr</span><span class="special">&);</span>
@@ -46,7 +41,7 @@
<span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Attr</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">&,</span> <span class="keyword">bool</span><span class="special">&);</span>
</pre>
<p>
- You can use <tt class="computeroutput">Boost.Bind</tt>
+ You can use <code class="computeroutput">Boost.Bind</code>
to bind member functions. For function objects, the allowed signatures
are:
</p>
@@ -55,7 +50,7 @@
<span class="keyword">void</span> <span class="keyword">operator</span><span class="special">()(</span><span class="identifier">Attr</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">&,</span> <span class="keyword">bool</span><span class="special">&)</span> <span class="keyword">const</span><span class="special">;</span>
</pre>
<p>
- The <tt class="computeroutput"><span class="identifier">unused_type</span></tt> is used
+ The <code class="computeroutput"><span class="identifier">unused_type</span></code> is used
in the signatures above to signify 'don't care'.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../karma.html" title=" Karma - Writing Generators">
-<link rel="previous" href="quick_reference/phoenix.html" title="Phoenix">
-<link rel="next" href="reference/generator_concepts.html" title="Generator
- Concepts">
+<link rel="up" href="../karma.html" title="Karma - Writing Generators">
+<link rel="prev" href="quick_reference/phoenix.html" title="Phoenix">
+<link rel="next" href="reference/generator_concepts.html" title="Generator Concepts">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="quick_reference/phoenix.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="reference/generator_concepts.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.karma.reference"></a>Reference
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Reference">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.karma.reference"></a><a class="link" href="reference.html" title="Reference">Reference</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="reference/generator_concepts.html">Generator
Concepts</a></span></dt>
@@ -37,10 +33,11 @@
<dt><span class="section"> Char</span></dt>
<dt><span class="section"> String</span></dt>
<dt><span class="section"> Numeric</span></dt>
-<dt><span class="section">Directive</span></dt>
-<dt><span class="section">Operator</span></dt>
<dt><span class="section">Stream</span></dt>
+<dt><span class="section"> Binary</span></dt>
<dt><span class="section">Auxiliary</span></dt>
+<dt><span class="section">Directive</span></dt>
+<dt><span class="section">Operator</span></dt>
</dl></div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Auxiliary</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="stream.html" title="Stream">
+<link rel="prev" href="binary/binary_big.html" title="Binary Big Endianness Generators">
<link rel="next" href="auxiliary/eol.html" title="eol">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -20,15 +20,12 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="stream.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary/eol.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.auxiliary"></a>Auxiliary
-</h4></div></div>
-<div></div>
+<a accesskey="p" href="binary/binary_big.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary/eol.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="Auxiliary">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.auxiliary"></a><a class="link" href="auxiliary.html" title="Auxiliary">Auxiliary</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">eol</span></dt>
<dt><span class="section">eps</span></dt>
@@ -36,16 +33,19 @@
</dl></div>
<p>
This module includes different auxiliary generators not fitting into any
- of the other categories. It includes the <tt class="computeroutput"><span class="identifier">eol</span></tt>
- and <tt class="computeroutput"><span class="identifier">eps</span></tt>, <tt class="computeroutput"><span class="identifier">lazy</span></tt> generators.
+ of the other categories. It includes the <code class="computeroutput"><span class="identifier">eol</span></code>
+ and <code class="computeroutput"><span class="identifier">eps</span></code>, <code class="computeroutput"><span class="identifier">lazy</span></code> generators.
</p>
-<a name="spirit.karma.reference.auxiliary.module_header"></a><h5>
-<a name="id580344"></a>
- Module Header
- </h5>
+<a name="spirit.karma.reference.auxiliary.module_header"></a><h6>
+<a name="id1244870"></a>
+ <a class="link" href="auxiliary.html#spirit.karma.reference.auxiliary.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/auxiliary.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_auxiliary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
@@ -58,7 +58,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="stream.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary/eol.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="binary/binary_big.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary/eol.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eol.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eol.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eol.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>eol</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../auxiliary.html" title="Auxiliary">
-<link rel="previous" href="../auxiliary.html" title="Auxiliary">
+<link rel="prev" href="../auxiliary.html" title="Auxiliary">
<link rel="next" href="eps.html" title="eps">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,55 +22,51 @@
<div class="spirit-nav">
<a accesskey="p" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="eps.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.auxiliary.eol"></a>eol
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="eol">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.auxiliary.eol"></a><a class="link" href="eol.html" title="eol">eol</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.auxiliary.eol.description"></a><h6>
-<a name="id580461"></a>
- Description
+<a name="id1244954"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">eol</span></tt> component generates
- a single newline character. It is equivalent to <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">'\n'</span><span class="special">)</span></tt>
- or simply '\n' (please see the <a href="../char/char_generator.html" title=" Character
- Generators"><tt class="computeroutput"><span class="identifier">char_</span></tt></a> generator module for more
+ The <code class="computeroutput"><span class="identifier">eol</span></code> component generates
+ a single newline character. It is equivalent to <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">'\n'</span><span class="special">)</span></code>
+ or simply '\n' (please see the <a class="link" href="../char/char_generator.html" title="Character Generators"><code class="computeroutput"><span class="identifier">char_</span></code></a> generator module for more
details).
</p>
<a name="spirit.karma.reference.auxiliary.eol.header"></a><h6>
-<a name="id580549"></a>
- Header
+<a name="id1245007"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/auxiliary/eol.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_eol</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.auxiliary.eol.model_of"></a><h6>
-<a name="id580663"></a>
- Model of
+<a name="id1245081"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.auxiliary.eol.expression_semantics"></a><h6>
-<a name="id580716"></a>
- <a href="eol.html#spirit.karma.reference.auxiliary.eol.expression_semantics">Expression
+<a name="id1245120"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -78,27 +74,35 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eol</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eol</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Create a component generating a single end of line character
in the output. This generator never fails (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.eol.attributes"></a><h6>
-<a name="id580834"></a>
- Attributes
+<a name="id1245209"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -106,25 +110,33 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eol</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eol</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.eol.complexity"></a><h6>
-<a name="id580935"></a>
- Complexity
+<a name="id1245287"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -140,8 +152,8 @@
output.
</p>
<a name="spirit.karma.reference.auxiliary.eol.example"></a><h6>
-<a name="id580976"></a>
- Example
+<a name="id1245314"></a>
+ <a class="link" href="eol.html#spirit.karma.reference.auxiliary.eol.example">Example</a>
</h6>
<p>
Some includes:
@@ -201,7 +213,7 @@
<p>
</p>
<p>
- Basic usage of the <tt class="computeroutput"><span class="identifier">eol</span></tt>
+ Basic usage of the <code class="computeroutput"><span class="identifier">eol</span></code>
generator:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eps.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eps.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/eps.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>eps</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../auxiliary.html" title="Auxiliary">
-<link rel="previous" href="eol.html" title="eol">
+<link rel="prev" href="eol.html" title="eol">
<link rel="next" href="lazy.html" title="lazy">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,76 +22,73 @@
<div class="spirit-nav">
<a accesskey="p" href="eol.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lazy.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.auxiliary.eps"></a>eps
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="eps">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.auxiliary.eps"></a><a class="link" href="eps.html" title="eps">eps</a>
+</h5></div></div></div>
<p>
- The family of <tt class="computeroutput"><span class="identifier">eps</span></tt> components
+ The family of <code class="computeroutput"><span class="identifier">eps</span></code> components
allows to create pseudo generators generating an empty string. This feature
is sometimes useful either to force a generator to fail or to succeed
or to insert semantic actions into the generation process.
</p>
<a name="spirit.karma.reference.auxiliary.eps.description"></a><h6>
-<a name="id582019"></a>
- Description
+<a name="id1246694"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">eps</span></tt> creates a component
- generating an empty string while always succeeding. The <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></tt>
- component generates an empty string as well, but succeeds only if <tt class="computeroutput"><span class="identifier">b</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt>
- and fails otherwise. It's lazy variant <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></tt> is equivalent to <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></tt> except it evaluates the supplied function
- <tt class="computeroutput"><span class="identifier">fb</span></tt> at generate time,
+ The <code class="computeroutput"><span class="identifier">eps</span></code> creates a component
+ generating an empty string while always succeeding. The <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ component generates an empty string as well, but succeeds only if <code class="computeroutput"><span class="identifier">b</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>
+ and fails otherwise. It's lazy variant <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></code> is equivalent to <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code> except it evaluates the supplied function
+ <code class="computeroutput"><span class="identifier">fb</span></code> at generate time,
while using the return value as the criteria to succeed.
</p>
<a name="spirit.karma.reference.auxiliary.eps.header"></a><h6>
-<a name="id582178"></a>
- Header
+<a name="id1246794"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/auxiliary/eps.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_eps</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.auxiliary.eps.model_of"></a><h6>
-<a name="id582292"></a>
- Model of
+<a name="id1246868"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">b</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">b</span></code></span></dt>
<dd><p>
A boolean value.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fb</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fb</span></code></span></dt>
<dd><p>
- A <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ A <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a boolean value.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.auxiliary.eps.expression_semantics"></a><h6>
-<a name="id582408"></a>
- <a href="eps.html#spirit.karma.reference.auxiliary.eps.expression_semantics">Expression
+<a name="id1246955"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -99,47 +96,63 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Creates a component generating an empty string. Succeeds always.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Creates a component generating an empty string. Succeeds if
- <tt class="computeroutput"><span class="identifier">b</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt> (except if the underlying
+ <code class="computeroutput"><span class="identifier">b</span></code> is <code class="computeroutput"><span class="keyword">true</span></code> (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Creates a component generating an empty string. Succeeds if
- <tt class="computeroutput"><span class="identifier">fb</span></tt> returns <tt class="computeroutput"><span class="keyword">true</span></tt> at generate time (except
+ <code class="computeroutput"><span class="identifier">fb</span></code> returns <code class="computeroutput"><span class="keyword">true</span></code> at generate time (except
if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.eps.attributes"></a><h6>
-<a name="id582664"></a>
- Attributes
+<a name="id1247142"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -147,43 +160,59 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">fb</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.eps.complexity"></a><h6>
-<a name="id582872"></a>
- Complexity
+<a name="id1247304"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -198,8 +227,8 @@
The complexity is constant as no output is generated.
</p>
<a name="spirit.karma.reference.auxiliary.eps.example"></a><h6>
-<a name="id582912"></a>
- Example
+<a name="id1247331"></a>
+ <a class="link" href="eps.html#spirit.karma.reference.auxiliary.eps.example">Example</a>
</h6>
<p>
Some includes:
@@ -259,7 +288,7 @@
<p>
</p>
<p>
- Basic usage of the <tt class="computeroutput"><span class="identifier">eps</span></tt>
+ Basic usage of the <code class="computeroutput"><span class="identifier">eps</span></code>
generator:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/lazy.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/lazy.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/auxiliary/lazy.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>lazy</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../auxiliary.html" title="Auxiliary">
-<link rel="previous" href="eps.html" title="eps">
-<link rel="next" href="../../performance_measurements.html" title="Performance Measurements">
+<link rel="prev" href="eps.html" title="eps">
+<link rel="next" href="../directive.html" title="Directive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -20,53 +20,50 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="eps.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../performance_measurements.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.auxiliary.lazy"></a>lazy
-</h5></div></div>
-<div></div>
+<a accesskey="p" href="eps.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="lazy">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.auxiliary.lazy"></a><a class="link" href="lazy.html" title="lazy">lazy</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.auxiliary.lazy.description"></a><h6>
-<a name="id584054"></a>
- Description
+<a name="id1248170"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.description">Description</a>
</h6>
<p>
- The familiy of <tt class="computeroutput"><span class="identifier">lazy</span></tt> components
+ The familiy of <code class="computeroutput"><span class="identifier">lazy</span></code> components
allows to use a dynamically returned generator component for output generation.
It calls the provided function or function object at generate time using
its return value as the actual generator to produce the output.
</p>
<a name="spirit.karma.reference.auxiliary.lazy.header"></a><h6>
-<a name="id584100"></a>
- Header
+<a name="id1248194"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/auxiliary/lazy.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_lazy</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.auxiliary.lazy.model_of"></a><h6>
-<a name="id584214"></a>
- <a href="lazy.html#spirit.karma.reference.auxiliary.lazy.model_of">Model
+<a name="id1248269"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Generator
+ <a class="link" href="../generator_concepts/generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fg</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fg</span></code></span></dt>
<dd><p>
A function or function object that evaluates to a generator object.
This function will be invoked at generate time.
@@ -74,27 +71,27 @@
</dl>
</div>
<p>
- The signature of <tt class="computeroutput"><span class="identifier">fg</span></tt> is
+ The signature of <code class="computeroutput"><span class="identifier">fg</span></code> is
expected to be
</p>
<pre class="programlisting"><span class="identifier">G</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">G</span></tt>, the function's
- return value, is the type of the generator to be invoked, and <tt class="computeroutput"><span class="identifier">Context</span></tt> is the generators's Context
- type (The first argument is <tt class="computeroutput"><span class="identifier">unused</span></tt>
- to make the <tt class="computeroutput"><span class="identifier">Context</span></tt> the
- second argument. This is done for uniformity with <a href="../../tutorials/semantic_actions.html" title="Semantic Actions">Semantic
+ where <code class="computeroutput"><span class="identifier">G</span></code>, the function's
+ return value, is the type of the generator to be invoked, and <code class="computeroutput"><span class="identifier">Context</span></code> is the generators's Context
+ type (The first argument is <code class="computeroutput"><span class="identifier">unused</span></code>
+ to make the <code class="computeroutput"><span class="identifier">Context</span></code> the
+ second argument. This is done for uniformity with <a class="link" href="../../tutorials/semantic_actions.html" title="Semantic Actions">Semantic
Actions</a>).
</p>
<a name="spirit.karma.reference.auxiliary.lazy.expression_semantics"></a><h6>
-<a name="id584423"></a>
- <a href="lazy.html#spirit.karma.reference.auxiliary.lazy.expression_semantics">Expression
+<a name="id1248410"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in Generator.
+ is not defined in <a class="link" href="../generator_concepts/generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -102,49 +99,61 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fg</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fg</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The Boost.Phoenix
- function object <tt class="computeroutput"><span class="identifier">fg</span></tt>
+ function object <code class="computeroutput"><span class="identifier">fg</span></code>
will be invoked at generate time. It is expected to return a
generator instance. This generator is then invoked in order to
generate the output. This generator will succeed as long as the
invoked generated succeeds as well (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The function or function object will be invoked at generate time.
It is expected to return a generator instance (note this version
- of <tt class="computeroutput"><span class="identifier">lazy</span></tt> does
- not require <tt class="computeroutput"><span class="identifier">fg</span></tt>
+ of <code class="computeroutput"><span class="identifier">lazy</span></code> does
+ not require <code class="computeroutput"><span class="identifier">fg</span></code>
to be a Boost.Phoenix
function object). This generator is then invoked in order to
generate the output. This generator will succeed as long as the
invoked generated succeeds as well (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.lazy.attributes"></a><h6>
-<a name="id584646"></a>
- Attributes
+<a name="id1248563"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -152,48 +161,60 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fg</span></tt>
- </p></td>
-<td><p>
- The attribute type <tt class="computeroutput"><span class="identifier">G</span></tt>
- as exposed by the generator <tt class="computeroutput"><span class="identifier">g</span></tt>
- returned from <tt class="computeroutput"><span class="identifier">fg</span></tt>.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fg</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The attribute type <code class="computeroutput"><span class="identifier">G</span></code>
+ as exposed by the generator <code class="computeroutput"><span class="identifier">g</span></code>
+ returned from <code class="computeroutput"><span class="identifier">fg</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The attribute type <tt class="computeroutput"><span class="identifier">G</span></tt>
- as exposed by the generator <tt class="computeroutput"><span class="identifier">g</span></tt>
- returned from <tt class="computeroutput"><span class="identifier">fg</span></tt>.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fg</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The attribute type <code class="computeroutput"><span class="identifier">G</span></code>
+ as exposed by the generator <code class="computeroutput"><span class="identifier">g</span></code>
+ returned from <code class="computeroutput"><span class="identifier">fg</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.auxiliary.lazy.complexity"></a><h6>
-<a name="id584854"></a>
- Complexity
+<a name="id1249957"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.complexity">Complexity</a>
</h6>
<p>
- The complexity of the <tt class="computeroutput"><span class="identifier">lazy</span></tt>
+ The complexity of the <code class="computeroutput"><span class="identifier">lazy</span></code>
component is determined by the complexity of the generator returned from
- <tt class="computeroutput"><span class="identifier">fg</span></tt>.
+ <code class="computeroutput"><span class="identifier">fg</span></code>.
</p>
<a name="spirit.karma.reference.auxiliary.lazy.example"></a><h6>
-<a name="id584908"></a>
- Example
+<a name="id1249988"></a>
+ <a class="link" href="lazy.html#spirit.karma.reference.auxiliary.lazy.example">Example</a>
</h6>
<p>
Some includes:
@@ -274,7 +295,7 @@
<p>
</p>
<p>
- Basic usage of the <tt class="computeroutput"><span class="identifier">lazy</span></tt>
+ Basic usage of the <code class="computeroutput"><span class="identifier">lazy</span></code>
generator:
</p>
<p>
@@ -301,7 +322,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="eps.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../performance_measurements.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="eps.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Added: trunk/libs/spirit/doc/html/spirit/karma/reference/binary.html
==============================================================================
--- (empty file)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/binary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -0,0 +1,68 @@
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Binary</title>
+<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
+<link rel="home" href="../../../index.html" title="Spirit 2.1">
+<link rel="up" href="../reference.html" title="Reference">
+<link rel="prev" href="stream.html" title="Stream">
+<link rel="next" href="binary/binary_native.html" title="Binary Native Endianness Generators">
+</head>
+<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
+<table cellpadding="2" width="100%"><tr>
+<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../boost.png"></td>
+<td align="center">Home</td>
+<td align="center">Libraries</td>
+<td align="center">People</td>
+<td align="center">FAQ</td>
+<td align="center">More</td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="stream.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary/binary_native.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+<div class="section" title="Binary">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.binary"></a><a class="link" href="binary.html" title="Binary"> Binary</a>
+</h4></div></div></div>
+<div class="toc"><dl>
+<dt><span class="section"><a href="binary/binary_native.html"> Binary
+ Native Endianness Generators</a></span></dt>
+<dt><span class="section"><a href="binary/binary_little.html"> Binary
+ Little Endianness Generators</a></span></dt>
+<dt><span class="section"><a href="binary/binary_big.html"> Binary
+ Big Endianness Generators</a></span></dt>
+</dl></div>
+<p>
+ This module includes different generators allowing to output binary data.
+ It includes generators for default, little, and big endian binary output
+ and a <code class="computeroutput"><span class="identifier">pad</span></code> generator allowing
+ to control padding of the generated output stream.
+ </p>
+<a name="spirit.karma.reference.binary.module_header"></a><h6>
+<a name="id1233632"></a>
+ <a class="link" href="binary.html#spirit.karma.reference.binary.module_header">Module Header</a>
+ </h6>
+<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/binary.hpp>
+</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_binary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
+</div>
+<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
+<td align="left"></td>
+<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
+ de Guzman, Hartmut Kaiser<p>
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
+ file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ </p>
+</div></td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="stream.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary/binary_native.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+</body>
+</html>
Added: trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_big.html
==============================================================================
--- (empty file)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_big.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -0,0 +1,540 @@
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Binary Big Endianness Generators</title>
+<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
+<link rel="home" href="../../../../index.html" title="Spirit 2.1">
+<link rel="up" href="../binary.html" title="Binary">
+<link rel="prev" href="binary_little.html" title="Binary Little Endianness Generators">
+<link rel="next" href="../auxiliary.html" title="Auxiliary">
+</head>
+<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
+<table cellpadding="2" width="100%"><tr>
+<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
+<td align="center">Home</td>
+<td align="center">Libraries</td>
+<td align="center">People</td>
+<td align="center">FAQ</td>
+<td align="center">More</td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="binary_little.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+<div class="section" title="Binary Big Endianness Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.binary.binary_big"></a><a class="link" href="binary_big.html" title="Binary Big Endianness Generators"> Binary
+ Big Endianness Generators</a>
+</h5></div></div></div>
+<a name="spirit.karma.reference.binary.binary_big.description"></a><h6>
+<a name="id1241353"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.description">Description</a>
+ </h6>
+<p>
+ The binary generators described in this section are:
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 16 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 32 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 64 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 16 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 32 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 64 bit binary value using
+ big endian representation
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<div class="note" title="Note"><table border="0" summary="Note">
+<tr>
+<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
+<th align="left">Note</th>
+</tr>
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">big_qword</span></code>
+ and <code class="computeroutput"><span class="identifier">big_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ are only available on platforms where the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></code> is defined (i.e.
+ on platforms having native support for <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">long</span> <span class="keyword">long</span></code>
+ (64 bit) integer types).
+ </p></td></tr>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_big.header"></a><h6>
+<a name="id1241637"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.header">Header</a>
+ </h6>
+<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/binary.hpp>
+</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_binary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+</pre>
+<p>
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
+<a name="spirit.karma.reference.binary.binary_big.model_of"></a><h6>
+<a name="id1241711"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.model_of">Model
+ of</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<div class="variablelist" title="Notation">
+<p class="title"><b>Notation</b></p>
+<dl>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">w</span></code></span></dt>
+<dd><p>
+ A 16 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">dw</span></code></span></dt>
+<dd><p>
+ A 32 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">qw</span></code></span></dt>
+<dd><p>
+ A 64 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+</dl>
+</div>
+<a name="spirit.karma.reference.binary.binary_big.expression_semantics"></a><h6>
+<a name="id1241825"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.expression_semantics">Expression
+ Semantics</a>
+ </h6>
+<p>
+ Semantics of an expression is defined only where it differs from, or
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the mandatory attribute in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the mandatory attribute in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the mandatory attribute in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the immediate parameter in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the immediate parameter in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the immediate parameter in big endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_big.attributes"></a><h6>
+<a name="id1242066"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.attributes">Attributes</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Attribute
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least16_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least32_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least64_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_big.complexity"></a><h6>
+<a name="id1242354"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.complexity">Complexity</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ O(N), where N is the number of bytes emitted by the binary generator
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<a name="spirit.karma.reference.binary.binary_big.example"></a><h6>
+<a name="id1242378"></a>
+ <a class="link" href="binary_big.html#spirit.karma.reference.binary.binary_big.example">Example</a>
+ </h6>
+<p>
+ Some includes:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_core</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_operator</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">std_pair</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">iostream</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">string</span><span class="special">></span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ All code snippets below use these common test functions:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">T</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Some using declarations:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">using</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">;</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Basic usage of the big binary generators:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x02\x01"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">big_word</span><span class="special">(</span><span class="number">0x0201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">big_dword</span><span class="special">(</span><span class="number">0x04030201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x08\x07\x06\x05\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">big_qword</span><span class="special">(</span><span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">));</span>
+
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x02\x01"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">big_word</span><span class="special">,</span> <span class="number">0x0201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">big_dword</span><span class="special">,</span> <span class="number">0x04030201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x08\x07\x06\x05\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">big_qword</span><span class="special">,</span> <span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">);</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+</div>
+<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
+<td align="left"></td>
+<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
+ de Guzman, Hartmut Kaiser<p>
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
+ file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ </p>
+</div></td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="binary_little.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+</body>
+</html>
Added: trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_little.html
==============================================================================
--- (empty file)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_little.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -0,0 +1,540 @@
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Binary Little Endianness Generators</title>
+<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
+<link rel="home" href="../../../../index.html" title="Spirit 2.1">
+<link rel="up" href="../binary.html" title="Binary">
+<link rel="prev" href="binary_native.html" title="Binary Native Endianness Generators">
+<link rel="next" href="binary_big.html" title="Binary Big Endianness Generators">
+</head>
+<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
+<table cellpadding="2" width="100%"><tr>
+<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
+<td align="center">Home</td>
+<td align="center">Libraries</td>
+<td align="center">People</td>
+<td align="center">FAQ</td>
+<td align="center">More</td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="binary_native.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary_big.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+<div class="section" title="Binary Little Endianness Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.binary.binary_little"></a><a class="link" href="binary_little.html" title="Binary Little Endianness Generators"> Binary
+ Little Endianness Generators</a>
+</h5></div></div></div>
+<a name="spirit.karma.reference.binary.binary_little.description"></a><h6>
+<a name="id1238960"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.description">Description</a>
+ </h6>
+<p>
+ The binary generators described in this section are:
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 16 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 32 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 64 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 16 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 32 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 64 bit binary value using
+ little endian representation
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<div class="note" title="Note"><table border="0" summary="Note">
+<tr>
+<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
+<th align="left">Note</th>
+</tr>
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">little_qword</span></code>
+ and <code class="computeroutput"><span class="identifier">little_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ are only available on platforms where the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></code> is defined (i.e.
+ on platforms having native support for <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">long</span> <span class="keyword">long</span></code>
+ (64 bit) integer types).
+ </p></td></tr>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_little.header"></a><h6>
+<a name="id1239243"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.header">Header</a>
+ </h6>
+<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/binary.hpp>
+</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_binary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+</pre>
+<p>
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
+<a name="spirit.karma.reference.binary.binary_little.model_of"></a><h6>
+<a name="id1239318"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.model_of">Model
+ of</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<div class="variablelist" title="Notation">
+<p class="title"><b>Notation</b></p>
+<dl>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">w</span></code></span></dt>
+<dd><p>
+ A 16 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">dw</span></code></span></dt>
+<dd><p>
+ A 32 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">qw</span></code></span></dt>
+<dd><p>
+ A 64 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+</dl>
+</div>
+<a name="spirit.karma.reference.binary.binary_little.expression_semantics"></a><h6>
+<a name="id1239429"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.expression_semantics">Expression
+ Semantics</a>
+ </h6>
+<p>
+ Semantics of an expression is defined only where it differs from, or
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the mandatory attribute in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the mandatory attribute in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the mandatory attribute in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the immediate parameter in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the immediate parameter in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the immediate parameter in little endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_little.attributes"></a><h6>
+<a name="id1239668"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.attributes">Attributes</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Attribute
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least16_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least32_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least64_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_little.complexity"></a><h6>
+<a name="id1239956"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.complexity">Complexity</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ O(N), where N is the number of bytes emitted by the binary generator
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<a name="spirit.karma.reference.binary.binary_little.example"></a><h6>
+<a name="id1239980"></a>
+ <a class="link" href="binary_little.html#spirit.karma.reference.binary.binary_little.example">Example</a>
+ </h6>
+<p>
+ Some includes:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_core</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_operator</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">std_pair</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">iostream</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">string</span><span class="special">></span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ All code snippets below use these common test functions:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">T</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Some using declarations:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">using</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">;</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Basic usage of the little binary generators:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">little_word</span><span class="special">(</span><span class="number">0x0201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">little_dword</span><span class="special">(</span><span class="number">0x04030201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04\x05\x06\x07\x08"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">little_qword</span><span class="special">(</span><span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">));</span>
+
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">little_word</span><span class="special">,</span> <span class="number">0x0201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">little_dword</span><span class="special">,</span> <span class="number">0x04030201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04\x05\x06\x07\x08"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">little_qword</span><span class="special">,</span> <span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">);</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+</div>
+<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
+<td align="left"></td>
+<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
+ de Guzman, Hartmut Kaiser<p>
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
+ file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ </p>
+</div></td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="binary_native.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary_big.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+</body>
+</html>
Added: trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_native.html
==============================================================================
--- (empty file)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/binary/binary_native.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -0,0 +1,650 @@
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+<title>Binary Native Endianness Generators</title>
+<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
+<link rel="home" href="../../../../index.html" title="Spirit 2.1">
+<link rel="up" href="../binary.html" title="Binary">
+<link rel="prev" href="../binary.html" title="Binary">
+<link rel="next" href="binary_little.html" title="Binary Little Endianness Generators">
+</head>
+<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
+<table cellpadding="2" width="100%"><tr>
+<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
+<td align="center">Home</td>
+<td align="center">Libraries</td>
+<td align="center">People</td>
+<td align="center">FAQ</td>
+<td align="center">More</td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="../binary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary_little.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+<div class="section" title="Binary Native Endianness Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.binary.binary_native"></a><a class="link" href="binary_native.html" title="Binary Native Endianness Generators"> Binary
+ Native Endianness Generators</a>
+</h5></div></div></div>
+<a name="spirit.karma.reference.binary.binary_native.description"></a><h6>
+<a name="id1233716"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.description">Description</a>
+ </h6>
+<p>
+ The binary generators described in this section are:
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a single byte (8 bit binary
+ value) using native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 16 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 32 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the mandatory attribute as a 64 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a single byte (8 bit binary
+ value) using native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 16 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 32 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the immediate parameter as a 64 bit binary value using
+ native endian representation
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<div class="note" title="Note"><table border="0" summary="Note">
+<tr>
+<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
+<th align="left">Note</th>
+</tr>
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">qword</span></code>
+ and <code class="computeroutput"><span class="identifier">qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ are only available on platforms where the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></code> is defined (i.e.
+ on platforms having native support for <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">long</span> <span class="keyword">long</span></code>
+ (64 bit) integer types).
+ </p></td></tr>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_native.header"></a><h6>
+<a name="id1235151"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.header">Header</a>
+ </h6>
+<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/binary.hpp>
+</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_binary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+</pre>
+<p>
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
+<a name="spirit.karma.reference.binary.binary_native.model_of"></a><h6>
+<a name="id1235226"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.model_of">Model
+ of</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<div class="variablelist" title="Notation">
+<p class="title"><b>Notation</b></p>
+<dl>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">b</span></code></span></dt>
+<dd><p>
+ A single byte (8 bit binary value) or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a single byte
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">w</span></code></span></dt>
+<dd><p>
+ A 16 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">dw</span></code></span></dt>
+<dd><p>
+ A 32 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">qw</span></code></span></dt>
+<dd><p>
+ A 64 bit binary value or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Argument</a> that evaluates to a 16 bit binary value. This value
+ is always interpreted using native endianness.
+ </p></dd>
+</dl>
+</div>
+<a name="spirit.karma.reference.binary.binary_native.expression_semantics"></a><h6>
+<a name="id1235361"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.expression_semantics">Expression
+ Semantics</a>
+ </h6>
+<p>
+ Semantics of an expression is defined only where it differs from, or
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant byte
+ of the mandatory attribute. This generator never fails (except
+ if the underlying output stream reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the mandatory attribute in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the mandatory attribute in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the mandatory attribute in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant byte
+ of the immediate parameter. This generator never fails (except
+ if the underlying output stream reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 16
+ bits of the immediate parameter in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 32
+ bits of the immediate parameter in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Output the binary representation of the least significant 64
+ bits of the immediate parameter in native endian representation.
+ This generator never fails (except if the underlying output stream
+ reports an error).
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_native.attributes"></a><h6>
+<a name="id1235659"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.attributes">Attributes</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Expression
+ </p>
+ </th>
+<th>
+ <p>
+ Attribute
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least8_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least16_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least32_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint_least64_t</span></code>, attribute is
+ mandatory (otherwise compilation will fail)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span><span class="special">(</span><span class="identifier">w</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span><span class="special">(</span><span class="identifier">dw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span><span class="special">(</span><span class="identifier">qw</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.binary.binary_native.complexity"></a><h6>
+<a name="id1236027"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.complexity">Complexity</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ O(N), where N is the number of bytes emitted by the binary generator
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<a name="spirit.karma.reference.binary.binary_native.example"></a><h6>
+<a name="id1236051"></a>
+ <a class="link" href="binary_native.html#spirit.karma.reference.binary.binary_native.example">Example</a>
+ </h6>
+<p>
+ Some includes:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_core</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_operator</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">std_pair</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">iostream</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">string</span><span class="special">></span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ All code snippets below use these common test functions:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">size</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">T</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span> <span class="special">&&</span> <span class="special">!</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">memcmp</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">(),</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">size</span><span class="special">))</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Some using declarations:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">using</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">;</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Basic usage of the native binary generators with some results for little
+ endian platforms:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01"</span><span class="special">,</span> <span class="number">1</span><span class="special">,</span> <span class="identifier">byte_</span><span class="special">(</span><span class="number">0x01</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">word</span><span class="special">(</span><span class="number">0x0201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">dword</span><span class="special">(</span><span class="number">0x04030201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04\x05\x06\x07\x08"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">qword</span><span class="special">(</span><span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">));</span>
+
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01"</span><span class="special">,</span> <span class="number">1</span><span class="special">,</span> <span class="identifier">byte_</span><span class="special">,</span> <span class="number">0x01</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">word</span><span class="special">,</span> <span class="number">0x0201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">dword</span><span class="special">,</span> <span class="number">0x04030201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01\x02\x03\x04\x05\x06\x07\x08"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">qword</span><span class="special">,</span> <span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">);</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Basic usage of the native binary generators with some results for big
+ endian platforms:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x01"</span><span class="special">,</span> <span class="number">1</span><span class="special">,</span> <span class="identifier">byte_</span><span class="special">(</span><span class="number">0x01</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x02\x01"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">word</span><span class="special">(</span><span class="number">0x0201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">dword</span><span class="special">(</span><span class="number">0x04030201</span><span class="special">));</span>
+<span class="identifier">test_binary_generator</span><span class="special">(</span><span class="string">"\x08\x07\x06\x05\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">qword</span><span class="special">(</span><span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">));</span>
+
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x01"</span><span class="special">,</span> <span class="number">1</span><span class="special">,</span> <span class="identifier">byte_</span><span class="special">,</span> <span class="number">0x01</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x02\x01"</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="identifier">word</span><span class="special">,</span> <span class="number">0x0201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">4</span><span class="special">,</span> <span class="identifier">dword</span><span class="special">,</span> <span class="number">0x04030201</span><span class="special">);</span>
+<span class="identifier">test_binary_generator_attr</span><span class="special">(</span><span class="string">"\x08\x07\x06\x05\x04\x03\x02\x01"</span><span class="special">,</span> <span class="number">8</span><span class="special">,</span> <span class="identifier">qword</span><span class="special">,</span> <span class="number">0</span><span class="identifier">x0807060504030201LL</span><span class="special">);</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+</div>
+<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
+<td align="left"></td>
+<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
+ de Guzman, Hartmut Kaiser<p>
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
+ file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ </p>
+</div></td>
+</tr></table>
+<hr>
+<div class="spirit-nav">
+<a accesskey="p" href="../binary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../binary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary_little.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+</div>
+</body>
+</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/char.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/char.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/char.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Char</title>
+<title>Char</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="karma_basics.html" title=" Basics">
-<link rel="next" href="char/char_generator.html" title=" Character
- Generators">
+<link rel="prev" href="karma_basics.html" title="Basics">
+<link rel="next" href="char/char_generator.html" title="Character Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="karma_basics.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="char/char_generator.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.char"></a> Char
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Char">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.char"></a><a class="link" href="char.html" title="Char"> Char</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="char/char_generator.html"> Character
Generators</a></span></dt>
@@ -38,16 +34,22 @@
</dl></div>
<p>
This module includes different character oriented generators allowing to
- output single characters. It includes the character and character class
- generators.
+ output single characters. Currently, it includes literal chars (e.g. <code class="computeroutput"><span class="char">'x'</span></code>, <code class="computeroutput"><span class="identifier">L</span><span class="char">'x'</span></code>), <code class="computeroutput"><span class="identifier">char_</span></code>
+ (single characters, ranges and character sets) and the encoding specific
+ character classifiers (<code class="computeroutput"><span class="identifier">alnum</span></code>,
+ <code class="computeroutput"><span class="identifier">alpha</span></code>, <code class="computeroutput"><span class="identifier">digit</span></code>,
+ <code class="computeroutput"><span class="identifier">xdigit</span></code>, etc.).
</p>
-<a name="spirit.karma.reference.char.module_header"></a><h5>
-<a name="id502345"></a>
- Module Header
- </h5>
+<a name="spirit.karma.reference.char.module_header"></a><h6>
+<a name="id1195882"></a>
+ <a class="link" href="char.html#spirit.karma.reference.char.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/char.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_char</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_class.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_class.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_class.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Character
- Class Generators</title>
+<title>Character Class Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../char.html" title=" Char">
-<link rel="previous" href="char_generator.html" title=" Character
- Generators">
-<link rel="next" href="../string.html" title=" String">
+<link rel="up" href="../char.html" title="Char">
+<link rel="prev" href="char_generator.html" title="Character Generators">
+<link rel="next" href="../string.html" title="String">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="char_generator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../char.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../string.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.char.char_class"></a><a href="char_class.html" title=" Character
- Class Generators"> Character
+<div class="section" title="Character Class Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.char.char_class"></a><a class="link" href="char_class.html" title="Character Class Generators"> Character
Class Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<a name="spirit.karma.reference.char.char_class.description"></a><h6>
-<a name="id507291"></a>
- Description
+<a name="id1200024"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.description">Description</a>
</h6>
<p>
The character class generators described in this section are:
@@ -46,186 +40,238 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alnum</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alpha</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- thh concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">blank</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">cntrl</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">digit</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">graph</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">print</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">punct</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">xdigit</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span></tt>
- </p></td>
-<td><p>
- Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></tt>
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">space</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alnum</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alpha</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ thh concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">blank</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">cntrl</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">digit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">graph</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">print</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">punct</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">xdigit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates the character supplied as the attribute if it satisfies
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></code>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">space</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the character supplied as the attribute if it satisfies
- the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></tt>
+ the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></code>
in or a single space character the character set defined by
- <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- In the table above, <tt class="computeroutput"><span class="identifier">ns</span></tt>
- is a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
+ In the table above, <code class="computeroutput"><span class="identifier">ns</span></code>
+ is a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
Encoding Namespace</a> used by the corresponding character class generator.
- All listed generators have a mandatory attribute <tt class="computeroutput"><span class="identifier">Ch</span></tt>
+ All listed generators have a mandatory attribute <code class="computeroutput"><span class="identifier">Ch</span></code>
and will not compile if no attribute is associated.
</p>
<a name="spirit.karma.reference.char.char_class.header"></a><h6>
-<a name="id508287"></a>
- Header
+<a name="id1200731"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/char/char_class.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_char_class</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.char.char_class.model_of"></a><h6>
-<a name="id508401"></a>
- <a href="char_class.html#spirit.karma.reference.char.char_class.model_of">Model
+<a name="id1200805"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.char.char_class.expression_semantics"></a><h6>
-<a name="id508494"></a>
- <a href="char_class.html#spirit.karma.reference.char.char_class.expression_semantics">Expression
+<a name="id1200874"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -233,167 +279,219 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alnum</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alnum</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alpha</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">alpha</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">blank</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">blank</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">cntrl</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">cntrl</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">digit</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">digit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">graph</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">graph</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">print</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">print</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">punct</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">punct</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">xdigit</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">xdigit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span></tt>
- </p></td>
-<td><p>
- If the mandatory attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the mandatory attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">space</span></tt>
- </p></td>
-<td><p>
- If the optional attribute satisfies the concept of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></tt> the generator succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">space</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If the optional attribute satisfies the concept of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></code> the generator succeeds
after emitting its attribute (except if the underlying output
stream reports an error). This generator fails otherwise while
not generating anything.If no attribute is supplied this generator
emits a single space character in the character set defined by
- <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- Possible values for <tt class="computeroutput"><span class="identifier">ns</span></tt>
- are described in the section <a href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
+ Possible values for <code class="computeroutput"><span class="identifier">ns</span></code>
+ are described in the section <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- The generators <tt class="computeroutput"><span class="identifier">alpha</span></tt>
- and <tt class="computeroutput"><span class="identifier">alnum</span></tt> might seem
- to behave unexpected if used inside a <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt> or <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> directive. Both directives additionally
- apply the semanitics of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></tt>
- or <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></tt> to the respective character
+ The generators <code class="computeroutput"><span class="identifier">alpha</span></code>
+ and <code class="computeroutput"><span class="identifier">alnum</span></code> might seem
+ to behave unexpected if used inside a <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code> or <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> directive. Both directives additionally
+ apply the semanitics of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></code>
+ or <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></code> to the respective character
class. Some examples:
</p>
<pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
@@ -402,28 +500,28 @@
</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">lower</span><span class="special">[</span><span class="identifier">alpha</span><span class="special">],</span> <span class="char">'A'</span><span class="special">);</span> <span class="comment">// fails
</span></pre>
<p>
- The generator directive <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> behaves correspondingly.
+ The generator directive <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> behaves correspondingly.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.char.char_class.attributes"></a><h6>
-<a name="id509744"></a>
- Attributes
+<a name="id1201747"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.attributes">Attributes</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- All listed character class generators can take any attribute <tt class="computeroutput"><span class="identifier">Ch</span></tt>. All character class generators
- (except <tt class="computeroutput"><span class="identifier">space</span></tt>) require
+ All listed character class generators can take any attribute <code class="computeroutput"><span class="identifier">Ch</span></code>. All character class generators
+ (except <code class="computeroutput"><span class="identifier">space</span></code>) require
an attribute and will fail compiling otherwise.
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.char.char_class.complexity"></a><h6>
-<a name="id509806"></a>
- Complexity
+<a name="id1201787"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -439,8 +537,8 @@
per invocation.
</p>
<a name="spirit.karma.reference.char.char_class.example"></a><h6>
-<a name="id509849"></a>
- Example
+<a name="id1201814"></a>
+ <a class="link" href="char_class.html#spirit.karma.reference.char.char_class.example">Example</a>
</h6>
<p>
Some includes:
@@ -500,7 +598,7 @@
<p>
</p>
<p>
- Basic usage of an <tt class="computeroutput"><span class="identifier">alpha</span></tt>
+ Basic usage of an <code class="computeroutput"><span class="identifier">alpha</span></code>
generator:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_generator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_generator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/char/char_generator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Character
- Generators</title>
+<title>Character Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../char.html" title=" Char">
-<link rel="previous" href="../char.html" title=" Char">
-<link rel="next" href="char_class.html" title=" Character
- Class Generators">
+<link rel="up" href="../char.html" title="Char">
+<link rel="prev" href="../char.html" title="Char">
+<link rel="next" href="char_class.html" title="Character Class Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="../char.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../char.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="char_class.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.char.char_generator"></a><a href="char_generator.html" title=" Character
- Generators"> Character
+<div class="section" title="Character Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.char.char_generator"></a><a class="link" href="char_generator.html" title="Character Generators"> Character
Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<a name="spirit.karma.reference.char.char_generator.description"></a><h6>
-<a name="id502462"></a>
- Description
+<a name="id1195966"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.description">Description</a>
</h6>
<p>
The character generators described in this section are:
@@ -46,145 +40,177 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>,
- same as <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>,
+ same as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the mandatory attribute as a single character interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">ch</span></tt>
- as a character interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>, if an attribute is supplied
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">ch</span></code>
+ as a character interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>, if an attribute is supplied
it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">c</span></tt> as
- a character interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>, if an attribute is supplied
- it must match, equivalent to <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">'c'</span><span class="special">)</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">c</span></code> as
+ a character interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>, if an attribute is supplied
+ it must match, equivalent to <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">'c'</span><span class="special">)</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the character supplied as the attribute if it belongs
to the character range interpreted in the character set defined
- by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the character supplied as the attribute if it belongs
- to <tt class="computeroutput"><span class="identifier">charset</span></tt> interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ to <code class="computeroutput"><span class="identifier">charset</span></code> interpreted
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- In the table above, <tt class="computeroutput"><span class="identifier">ns</span></tt>
- is a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
+ In the table above, <code class="computeroutput"><span class="identifier">ns</span></code>
+ is a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
Encoding Namespace</a> used by the corresponding character generator.
</p>
<a name="spirit.karma.reference.char.char_generator.header"></a><h6>
-<a name="id503086"></a>
- Header
+<a name="id1196418"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/char/char.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_char_</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.char.char_generator.model_of"></a><h6>
-<a name="id503200"></a>
- <a href="char_generator.html#spirit.karma.reference.char.char_generator.model_of">Model
+<a name="id1196493"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ch</span></tt>,
- <tt class="computeroutput"><span class="identifier">ch1</span></tt>, <tt class="computeroutput"><span class="identifier">ch2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ch</span></code>,
+ <code class="computeroutput"><span class="identifier">ch1</span></code>, <code class="computeroutput"><span class="identifier">ch2</span></code></span></dt>
<dd><p>
Character-class specific character (See Character Class Types), or
- a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a character-class specific character
value
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">charset</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">charset</span></code></span></dt>
<dd><p>
Character-set specifier string (See Character Class Types), or a
- <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a character-set specifier string,
or a pointer/reference to a null-terminated array of characters.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.char.char_generator.expression_semantics"></a><h6>
-<a name="id503389"></a>
- <a href="char_generator.html#spirit.karma.reference.char.char_generator.expression_semantics">Expression
+<a name="id1196621"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -192,123 +218,155 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-<td><p>
- Generate the character literal <tt class="computeroutput"><span class="identifier">ch</span></tt>.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the character literal <code class="computeroutput"><span class="identifier">ch</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the character literal <tt class="computeroutput"><span class="identifier">ch</span></tt>.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the character literal <code class="computeroutput"><span class="identifier">ch</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate the character provided by a mandatory attribute interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>.
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the character <tt class="computeroutput"><span class="identifier">ch</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the character <code class="computeroutput"><span class="identifier">ch</span></code>
as provided by the immediate literal value the generator is initialized
from. If this generator has an associated attribute it succeeds
only as long as the attribute is equal to the immediate literal
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the character <tt class="computeroutput"><span class="identifier">c</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the character <code class="computeroutput"><span class="identifier">c</span></code>
as provided by the immediate literal value the generator is initialized
from. If this generator has an associated attribute it succeeds
only as long as the attribute is equal to the immediate literal
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate the character provided by a mandatory attribute interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>.
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>.
The generator succeeds as long as the attribute belongs to the
- character range <tt class="computeroutput"><span class="special">[</span><span class="identifier">ch1</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">]</span></tt>
+ character range <code class="computeroutput"><span class="special">[</span><span class="identifier">ch1</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">]</span></code>
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate the character provided by a mandatory attribute interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>.
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>.
The generator succeeds as long as the attribute belongs to the
- character set <tt class="computeroutput"><span class="identifier">charset</span></tt>
+ character set <code class="computeroutput"><span class="identifier">charset</span></code>
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- A character <tt class="computeroutput"><span class="identifier">ch</span></tt> is assumed
- to belong to the character range defined by <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">)</span></tt> if its character value (binary representation)
- interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- is not smaller than the character value of <tt class="computeroutput"><span class="identifier">ch1</span></tt>
- and not larger then the character value of <tt class="computeroutput"><span class="identifier">ch2</span></tt>
- (i.e. <tt class="computeroutput"><span class="identifier">ch1</span> <span class="special"><=</span>
+ A character <code class="computeroutput"><span class="identifier">ch</span></code> is assumed
+ to belong to the character range defined by <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">)</span></code> if its character value (binary representation)
+ interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ is not smaller than the character value of <code class="computeroutput"><span class="identifier">ch1</span></code>
+ and not larger then the character value of <code class="computeroutput"><span class="identifier">ch2</span></code>
+ (i.e. <code class="computeroutput"><span class="identifier">ch1</span> <span class="special"><=</span>
<span class="identifier">ch</span> <span class="special"><=</span>
- <span class="identifier">ch2</span></tt>).
+ <span class="identifier">ch2</span></code>).
</p>
<p>
- The <tt class="computeroutput"><span class="identifier">charset</span></tt> parameter
- passed to <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>
+ The <code class="computeroutput"><span class="identifier">charset</span></code> parameter
+ passed to <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>
must be a string containing more than one character. Every single character
in this string is assumed to belong to the character set defined by this
- expression. An exception to this is the <tt class="computeroutput"><span class="char">'-'</span></tt>
+ expression. An exception to this is the <code class="computeroutput"><span class="char">'-'</span></code>
character which has a special meaning if it is not specified as the first
- and not the last character in <tt class="computeroutput"><span class="identifier">charset</span></tt>.
- If the <tt class="computeroutput"><span class="char">'-'</span></tt> is used in between
+ and not the last character in <code class="computeroutput"><span class="identifier">charset</span></code>.
+ If the <code class="computeroutput"><span class="char">'-'</span></code> is used in between
to characters it is interpreted as spanning a character range. A character
- <tt class="computeroutput"><span class="identifier">ch</span></tt> is considered to belong
- to the defined character set <tt class="computeroutput"><span class="identifier">charset</span></tt>
+ <code class="computeroutput"><span class="identifier">ch</span></code> is considered to belong
+ to the defined character set <code class="computeroutput"><span class="identifier">charset</span></code>
if it matches one of the characters as specified by the string parameter
described above. For example
</p>
@@ -318,51 +376,71 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Example
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"abc"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"abc"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
'a', 'b', and 'c'
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"a-z"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"a-z"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
all characters (and including) from 'a' to 'z'
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"a-zA-Z"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"a-zA-Z"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
all characters (and including) from 'a' to 'z' and 'A' and 'Z'
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"-1-9"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"-1-9"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
'-' and all characters (and including) from '1' to '9'
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.char.char_generator.attributes"></a><h6>
-<a name="id504441"></a>
- Attributes
+<a name="id1197389"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -370,89 +448,121 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">ch</span></tt> and succeeds
+ with <code class="computeroutput"><span class="identifier">ch</span></code> and succeeds
only if both are equal, failing otherwise
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">c</span></tt> and succeeds
+ with <code class="computeroutput"><span class="identifier">c</span></code> and succeeds
only if both are equal, failing otherwise
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>, attribute
is mandatory (otherwise compilation will fail), the generator
- succeeds if the attribute belongs to the character range <tt class="computeroutput"><span class="special">[</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">]</span></tt> interpreted in the character
- set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ succeeds if the attribute belongs to the character range <code class="computeroutput"><span class="special">[</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">]</span></code> interpreted in the character
+ set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>, attribute
is mandatory (otherwise compilation will fail), the generator
- succeeds if the attribute belongs to the character set <tt class="computeroutput"><span class="identifier">charset</span></tt>, interpreted in the
- character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ succeeds if the attribute belongs to the character set <code class="computeroutput"><span class="identifier">charset</span></code>, interpreted in the
+ character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.char.char_generator.complexity"></a><h6>
-<a name="id505018"></a>
- Complexity
+<a name="id1197812"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -464,24 +574,24 @@
</p>
</blockquote></div>
<p>
- The complexity of <tt class="computeroutput"><span class="identifier">ch</span></tt>,
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>,
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>, <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>, and <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt> is constant as all generators emit exactly
+ The complexity of <code class="computeroutput"><span class="identifier">ch</span></code>,
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>,
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>, <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>, and <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code> is constant as all generators emit exactly
one character per invocation.
</p>
<p>
- The character range generator (<tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">)</span></tt>) additionally requires constant lookup
+ The character range generator (<code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch1</span><span class="special">,</span> <span class="identifier">ch2</span><span class="special">)</span></code>) additionally requires constant lookup
time for the verification whether the attribute belongs to the character
range.
</p>
<p>
- The character set generator (<tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>) additionally requires O(log N) lookup
+ The character set generator (<code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>) additionally requires O(log N) lookup
time for the verification whether the attribute belongs to the character
set, where N is the number of characters in the character set.
</p>
<a name="spirit.karma.reference.char.char_generator.example"></a><h6>
-<a name="id505289"></a>
- Example
+<a name="id1197995"></a>
+ <a class="link" href="char_generator.html#spirit.karma.reference.char.char_generator.example">Example</a>
</h6>
<p>
Some includes:
@@ -560,7 +670,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">char_</span></tt>
+ Basic usage of <code class="computeroutput"><span class="identifier">char_</span></code>
generators:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Directive</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="numeric/floating_point.html" title=" Floating
- Point Number Generators">
-<link rel="next" href="directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])">
+<link rel="prev" href="auxiliary/lazy.html" title="lazy">
+<link rel="next" href="directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,45 +20,45 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="numeric/floating_point.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive/alignment.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.directive"></a>Directive
-</h4></div></div>
-<div></div>
+<a accesskey="p" href="auxiliary/lazy.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive/alignment.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="Directive">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.directive"></a><a class="link" href="directive.html" title="Directive">Directive</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="directive/alignment.html"> Alignment
- Directives (<tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></tt>, <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>, and <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>)</a></span></dt>
+ Directives (<code class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></code>, <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>, and <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/repeat.html"> Repetition
- Directive (<tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></tt>)</a></span></dt>
+ Directive (<code class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/delimit.html"> Directives
- Controlling Automatic Delimiting (<tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt>)</a></span></dt>
+ Controlling Automatic Delimiting (<code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/upperlower.html"> Directives
- Controlling Case Sensitivity (<tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>)</a></span></dt>
+ Controlling Case Sensitivity (<code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/maxwidth.html"> Controlling
- the Maximum Field Wield (<tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>)</a></span></dt>
+ the Maximum Field Wield (<code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/buffer.html"> Temporary
- Output Buffering (<tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></tt>)</a></span></dt>
+ Output Buffering (<code class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></code>)</a></span></dt>
<dt><span class="section"><a href="directive/omit.html"> Consume Attribute
- (<tt class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></tt>)</a></span></dt>
+ (<code class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></code>)</a></span></dt>
</dl></div>
<p>
This module includes different generator directives. It includes alignement
- directives (<tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></tt>, <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>, and <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>), repetition (<tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></tt>), directives controlling automatic delimiting
- (<tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt>
- and <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt>),
- controlling case sensitivity (<tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>), field width (<tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>), buffering (<tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></tt>), and attribute handling (<tt class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></tt>).
+ directives (<code class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></code>, <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>, and <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>), repetition (<code class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></code>), directives controlling automatic delimiting
+ (<code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code>
+ and <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code>),
+ controlling case sensitivity (<code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>), field width (<code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>), buffering (<code class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></code>), and attribute handling (<code class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></code>).
</p>
-<a name="spirit.karma.reference.directive.module_header"></a><h5>
-<a name="id535422"></a>
- Module Header
- </h5>
+<a name="spirit.karma.reference.directive.module_header"></a><h6>
+<a name="id1251373"></a>
+ <a class="link" href="directive.html#spirit.karma.reference.directive.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_directive</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
@@ -73,7 +71,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="numeric/floating_point.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive/alignment.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="auxiliary/lazy.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive/alignment.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/alignment.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/alignment.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/alignment.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Alignment
- Directives (left_align[], center[], and right_align[])</title>
+<title>Alignment Directives (left_align[], center[], and right_align[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="../directive.html" title="Directive">
-<link rel="next" href="repeat.html" title=" Repetition
- Directive (repeat[])">
+<link rel="prev" href="../directive.html" title="Directive">
+<link rel="next" href="repeat.html" title="Repetition Directive (repeat[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="../directive.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="repeat.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.alignment"></a><a href="alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"> Alignment
- Directives (<tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></tt>, <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>, and <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Alignment Directives (left_align[], center[], and right_align[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.alignment"></a><a class="link" href="alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"> Alignment
+ Directives (<code class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></code>, <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>, and <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.alignment.description"></a><h6>
-<a name="id535589"></a>
- Description
+<a name="id1251489"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.description">Description</a>
</h6>
<p>
The alignment directives allow to left align, right align or center output
@@ -43,80 +37,80 @@
an arbitrary generator to create the padding.
</p>
<a name="spirit.karma.reference.directive.alignment.header"></a><h6>
-<a name="id535622"></a>
- Header
+<a name="id1251506"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.header">Header</a>
</h6>
<p>
- For the <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></tt>
+ For the <code class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></code>
directive:
</p>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/left_alignment.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_left_alignment</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- For the <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>
+ For the <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>
directive:
</p>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/center_alignment.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_center_alignment</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- For the <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>
+ For the <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>
directive:
</p>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/right_alignment.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_right_alignment</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.alignment.model_of"></a><h6>
-<a name="id535956"></a>
- <a href="alignment.html#spirit.karma.reference.directive.alignment.model_of">Model
+<a name="id1251729"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">pad</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">pad</span></code></span></dt>
<dd><p>
- A generator object, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ A generator object, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt>,
- <tt class="computeroutput"><span class="identifier">Pad</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code>,
+ <code class="computeroutput"><span class="identifier">Pad</span></code></span></dt>
<dd><p>
- Attribute types of the generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt>
+ Attribute types of the generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">width</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">width</span></code></span></dt>
<dd><p>
- Numeric literal, any unsigned integer value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literal, any unsigned integer value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to an unsigned integer value
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.alignment.expression_semantics"></a><h6>
-<a name="id536167"></a>
- <a href="alignment.html#spirit.karma.reference.directive.alignment.expression_semantics">Expression
+<a name="id1251879"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -124,199 +118,251 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
aligned in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
- aligned in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
+ aligned in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
aligned in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> left
- aligned in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> left
+ aligned in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
- in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
+ in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> centered
- in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> centered
+ in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
aligned in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
- aligned in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using <tt class="computeroutput"><span class="identifier">space</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
+ aligned in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using <code class="computeroutput"><span class="identifier">space</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail (except if the underlying output stream reports
an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
aligned in a column of width as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></tt>
- (default: 10), while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_LENGTH</span></code>
+ (default: 10), while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> right
- aligned in a column of the given <tt class="computeroutput"><span class="identifier">width</span></tt>,
- while using the generator <tt class="computeroutput"><span class="identifier">pad</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> right
+ aligned in a column of the given <code class="computeroutput"><span class="identifier">width</span></code>,
+ while using the generator <code class="computeroutput"><span class="identifier">pad</span></code>
to emit the necessary padding. This generator succeeds as long
- as its embedded and padding generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">pad</span></tt> do not
+ as its embedded and padding generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">pad</span></code> do not
fail (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
None of the generator directives listed above limit the emitted output
to the respective column width. If the emitted output is longer than
@@ -325,20 +371,20 @@
</p>
<p>
If the output needs to be limitted to a specified column width, use
- the <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>
+ the <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>
directive, for instance:
</p>
<pre class="programlisting"><span class="identifier">maxwidth</span><span class="special">(</span><span class="number">8</span><span class="special">)[</span><span class="identifier">right_align</span><span class="special">(</span><span class="number">12</span><span class="special">)[</span><span class="string">"1234567890"</span><span class="special">]]</span>
</pre>
<p>
- which will output: <tt class="computeroutput"><span class="string">" 123456"</span></tt>
+ which will output: <code class="computeroutput"><span class="string">" 123456"</span></code>
(without the quotes).
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.directive.alignment.attributes"></a><h6>
-<a name="id537711"></a>
- Attributes
+<a name="id1253738"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -346,190 +392,218 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">left_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">center</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
- <span class="identifier">width</span><span class="special">)[]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span>
+ <span class="identifier">width</span><span class="special">)[]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">pad</span><span class="special">:</span> <span class="identifier">Pad</span> <span class="special">--></span> <span class="identifier">right_align</span><span class="special">(</span><span class="identifier">pad</span><span class="special">,</span> <span class="identifier">width</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.alignment.complexity"></a><h6>
-<a name="id540080"></a>
- Complexity
+<a name="id1255539"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -539,15 +613,15 @@
by the complexity of its embedded and padding generator. The complexity
of the left alignment directive generator itself is O(1). The complexity
of the center and right alignment directive generators itself is
- O(N). where <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ O(N). where <code class="computeroutput"><span class="identifier">N</span></code> is
the number of characters emitted by the embedded and padding generators.
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.alignment.example"></a><h6>
-<a name="id540134"></a>
- Example
+<a name="id1255570"></a>
+ <a class="link" href="alignment.html#spirit.karma.reference.directive.alignment.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/buffer.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/buffer.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/buffer.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Temporary
- Output Buffering (buffer[])</title>
+<title>Temporary Output Buffering (buffer[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])">
-<link rel="next" href="omit.html" title=" Consume Attribute
- (omit[])">
+<link rel="prev" href="maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])">
+<link rel="next" href="omit.html" title="Consume Attribute (omit[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,23 +22,18 @@
<div class="spirit-nav">
<a accesskey="p" href="maxwidth.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="omit.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.buffer"></a><a href="buffer.html" title=" Temporary
- Output Buffering (buffer[])"> Temporary
- Output Buffering (<tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Temporary Output Buffering (buffer[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.buffer"></a><a class="link" href="buffer.html" title="Temporary Output Buffering (buffer[])"> Temporary
+ Output Buffering (<code class="computeroutput"><span class="identifier">buffer</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.buffer.description"></a><h6>
-<a name="id552960"></a>
- Description
+<a name="id1269595"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.description">Description</a>
</h6>
<p>
- All generator components (except the <a href="../operator/alternative.html" title=" Alternatives
- (operator|())">alternative
- (<tt class="computeroutput"><span class="special">|</span></tt>)</a> generator) pass
+ All generator components (except the <a class="link" href="../operator/alternative.html" title="Alternatives (operator|())">alternative
+ (<code class="computeroutput"><span class="special">|</span></code>)</a> generator) pass
their generated output directly to the underlying output stream. If a
generator fails halfway through, the output generated so far is not 'rolled
back'. The buffering generator directive allows to avoid this unwanted
@@ -50,50 +42,50 @@
underlying stream only after the embedded generator succeeded.
</p>
<a name="spirit.karma.reference.directive.buffer.header"></a><h6>
-<a name="id553010"></a>
- Header
+<a name="id1269624"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/buffer.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_buffer</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.buffer.model_of"></a><h6>
-<a name="id553124"></a>
- <a href="buffer.html#spirit.karma.reference.directive.buffer.model_of">Model
+<a name="id1269698"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code></span></dt>
<dd><p>
- Attribute type of generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ Attribute type of generator <code class="computeroutput"><span class="identifier">a</span></code>
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.buffer.expression_semantics"></a><h6>
-<a name="id553241"></a>
- <a href="buffer.html#spirit.karma.reference.directive.buffer.expression_semantics">Expression
+<a name="id1269787"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -101,43 +93,50 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- The embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
is invoked but its output is temporarily intercepted and stored
- in an internal buffer. If <tt class="computeroutput"><span class="identifier">a</span></tt>
+ in an internal buffer. If <code class="computeroutput"><span class="identifier">a</span></code>
succeeds the buffer content is flushed to the underlying output
stream, otherwise the buffer content is discarded. The buffer
directive succeeds as long as the embedded generator succeeded
(except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
If you want to make the buffered generator succeed regardless of the
- outcome of the embedded generator, simply wrap the <tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt> into an additional optional: <tt class="computeroutput"><span class="special">-</span><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt> (see <a href="../operator/optional.html" title=" Optional
- (unary operator-())">optional
- (unary <tt class="computeroutput"><span class="special">-</span></tt>)</a>).
+ outcome of the embedded generator, simply wrap the <code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code> into an additional optional: <code class="computeroutput"><span class="special">-</span><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code> (see <a class="link" href="../operator/optional.html" title="Optional (unary operator-())">optional
+ (unary <code class="computeroutput"><span class="special">-</span></code>)</a>).
</p></td></tr>
</table></div>
<a name="spirit.karma.reference.directive.buffer.attributes"></a><h6>
-<a name="id553492"></a>
- Attributes
+<a name="id1269960"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -145,31 +144,37 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.directive.buffer.complexity"></a><h6>
-<a name="id553703"></a>
- Complexity
+<a name="id1270121"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -183,8 +188,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.buffer.example"></a><h6>
-<a name="id553744"></a>
- Example
+<a name="id1270145"></a>
+ <a class="link" href="buffer.html#spirit.karma.reference.directive.buffer.example">Example</a>
</h6>
<p>
Some includes:
@@ -247,9 +252,8 @@
<p>
Basic usage of a buffering generator directive. It shows how the partial
output generated in the first example does not show up in the generated
- output as the plus generator fails (no data is available, see <a href="../operator/plus.html" title=" Plus (unary
- operator+())">plus
- (unary <tt class="computeroutput"><span class="special">+</span></tt>)</a>).
+ output as the plus generator fails (no data is available, see <a class="link" href="../operator/plus.html" title="Plus (unary operator+())">plus
+ (unary <code class="computeroutput"><span class="special">+</span></code>)</a>).
</p>
<p>
</p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/delimit.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/delimit.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/delimit.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])</title>
+<title>Directives Controlling Automatic Delimiting (verbatim[] and delimit[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="repeat.html" title=" Repetition
- Directive (repeat[])">
-<link rel="next" href="upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])">
+<link rel="prev" href="repeat.html" title="Repetition Directive (repeat[])">
+<link rel="next" href="upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,87 +22,83 @@
<div class="spirit-nav">
<a accesskey="p" href="repeat.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="upperlower.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.delimit"></a><a href="delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"> Directives
- Controlling Automatic Delimiting (<tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.delimit"></a><a class="link" href="delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"> Directives
+ Controlling Automatic Delimiting (<code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.delimit.description"></a><h6>
-<a name="id545001"></a>
- Description
+<a name="id1260775"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.description">Description</a>
</h6>
<p>
- The directives <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> can be used to control automatic delimiting.
- The directive <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> disabled any automatic delimiting,
- while the directive <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt> (re-)enable automatic delimiting.
+ The directives <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> can be used to control automatic delimiting.
+ The directive <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> disabled any automatic delimiting,
+ while the directive <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code> (re-)enable automatic delimiting.
</p>
<a name="spirit.karma.reference.directive.delimit.header"></a><h6>
-<a name="id545099"></a>
- Header
+<a name="id1260835"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.header">Header</a>
</h6>
<p>
- For the <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt>
+ For the <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code>
directive:
</p>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/verbatim.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_verbatim</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- For the <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt>
+ For the <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code>
directive:
</p>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/delimit.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_delimit</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.delimit.model_of"></a><h6>
-<a name="id545332"></a>
- <a href="delimit.html#spirit.karma.reference.directive.delimit.model_of">Model
+<a name="id1260991"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">d</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">d</span></code></span></dt>
<dd><p>
- A generator object, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ A generator object, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt>,
- <tt class="computeroutput"><span class="identifier">D</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code>,
+ <code class="computeroutput"><span class="identifier">D</span></code></span></dt>
<dd><p>
- Attribute types of the generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">d</span></tt>
+ Attribute types of the generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">d</span></code>
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.delimit.expression_semantics"></a><h6>
-<a name="id545506"></a>
- <a href="delimit.html#spirit.karma.reference.directive.delimit.expression_semantics">Expression
+<a name="id1261190"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -113,54 +106,70 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Enable automatic delimiting for the embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt> while using the <tt class="computeroutput"><span class="identifier">space</span></tt> generator as the delimiting
- generator. If used inside a <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> directive it re-enables the
- delimiter generator as used outside of this <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt> instead. The directive succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Enable automatic delimiting for the embedded generator <code class="computeroutput"><span class="identifier">a</span></code> while using the <code class="computeroutput"><span class="identifier">space</span></code> generator as the delimiting
+ generator. If used inside a <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> directive it re-enables the
+ delimiter generator as used outside of this <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code> instead. The directive succeeds
as long as the embedded generator succeeded (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Enable automatic delimiting for the embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt> while using the generator
- <tt class="computeroutput"><span class="identifier">d</span></tt> as the delimiting
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Enable automatic delimiting for the embedded generator <code class="computeroutput"><span class="identifier">a</span></code> while using the generator
+ <code class="computeroutput"><span class="identifier">d</span></code> as the delimiting
generator. The directive succeeds as long as the embedded generator
succeeded (except if the underlying output stream reports an
error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Disable automatic delimiting for the embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>. The directive succeeds as
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Disable automatic delimiting for the embedded generator <code class="computeroutput"><span class="identifier">a</span></code>. The directive succeeds as
long as the embedded generator succeeded (except if the underlying
output stream reports an error). This directive it has no effect
if it is used when no delimiting is active.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.delimit.attributes"></a><h6>
-<a name="id545843"></a>
- Attributes
+<a name="id1261424"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -168,68 +177,78 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">delimit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">d</span><span class="special">:</span> <span class="identifier">D</span> <span class="special">--></span> <span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">d</span><span class="special">:</span> <span class="identifier">D</span> <span class="special">--></span> <span class="identifier">delimit</span><span class="special">(</span><span class="identifier">d</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.delimit.complexity"></a><h6>
-<a name="id546426"></a>
- Complexity
+<a name="id1261868"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- The overall complexity of the generator directives <tt class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></tt>
- and <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt>
+ The overall complexity of the generator directives <code class="computeroutput"><span class="identifier">delimit</span><span class="special">[]</span></code>
+ and <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code>
is defined by the complexity of its embedded generators. The complexity
of the directives themselves is O(1).
</p>
@@ -237,8 +256,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.delimit.example"></a><h6>
-<a name="id546498"></a>
- Example
+<a name="id1261914"></a>
+ <a class="link" href="delimit.html#spirit.karma.reference.directive.delimit.example">Example</a>
</h6>
<p>
Some includes:
@@ -298,7 +317,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">delimit</span></tt>
+ Basic usage of <code class="computeroutput"><span class="identifier">delimit</span></code>
generator directive:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/maxwidth.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/maxwidth.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/maxwidth.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Controlling
- the Maximum Field Wield (maxwidth[])</title>
+<title>Controlling the Maximum Field Wield (maxwidth[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])">
-<link rel="next" href="buffer.html" title=" Temporary
- Output Buffering (buffer[])">
+<link rel="prev" href="upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])">
+<link rel="next" href="buffer.html" title="Temporary Output Buffering (buffer[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,74 +22,70 @@
<div class="spirit-nav">
<a accesskey="p" href="upperlower.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="buffer.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.maxwidth"></a><a href="maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])"> Controlling
- the Maximum Field Wield (<tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Controlling the Maximum Field Wield (maxwidth[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.maxwidth"></a><a class="link" href="maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])"> Controlling
+ the Maximum Field Wield (<code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.maxwidth.description"></a><h6>
-<a name="id550687"></a>
- Description
+<a name="id1266318"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>
+ The <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>
directive allows to limit (truncate) the overall length of the output
generated by the embedded generator.
</p>
<a name="spirit.karma.reference.directive.maxwidth.header"></a><h6>
-<a name="id550734"></a>
- Header
+<a name="id1266346"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/maxwidth.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_maxwidth</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.maxwidth.model_of"></a><h6>
-<a name="id550848"></a>
- <a href="maxwidth.html#spirit.karma.reference.directive.maxwidth.model_of">Model
+<a name="id1266420"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code></span></dt>
<dd><p>
- Attribute type of the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ Attribute type of the generator <code class="computeroutput"><span class="identifier">a</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span></code></span></dt>
<dd><p>
- Numeric literal, any unsigned integer value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literal, any unsigned integer value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to an unsigned integer value
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.maxwidth.expression_semantics"></a><h6>
-<a name="id551000"></a>
- <a href="maxwidth.html#spirit.karma.reference.directive.maxwidth.expression_semantics">Expression
+<a name="id1266533"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -100,51 +93,63 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Limit the overall length of the emitted output of the embedded
generator (including characters generated by automatic delimiting)
to the number of characters as defined by the preprocessor constant
- <tt class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_MAXWIDTH</span></tt>.
+ <code class="computeroutput"><span class="identifier">BOOST_KARMA_DEFAULT_FIELD_MAXWIDTH</span></code>.
Any additional output is truncated. The directive succeeds as
long as the embedded generator succeeded (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Limit the overall length of the emitted output of the embedded
generator (including characters generated by automatic delimiting)
- to the number of characters as defined by <tt class="computeroutput"><span class="identifier">num</span></tt>.
+ to the number of characters as defined by <code class="computeroutput"><span class="identifier">num</span></code>.
Any additional output is truncated. The directive succeeds as
long as the embedded generator succeeded (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- The <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt>
+ The <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code>
generator directive does not pads the generated output to fill the
specified column width. If the emitted output is shorter than the specified
(or implied) column width, the generated output will be more narrow
@@ -152,19 +157,19 @@
</p>
<p>
If the output needs to always be equal to a specified column width,
- use one of the alignment directives <tt class="computeroutput"><span class="identifier">left</span><span class="special">-</span><span class="identifier">align</span><span class="special">[]</span></tt>, <tt class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></tt>, or <tt class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></tt>, for instance:
+ use one of the alignment directives <code class="computeroutput"><span class="identifier">left</span><span class="special">-</span><span class="identifier">align</span><span class="special">[]</span></code>, <code class="computeroutput"><span class="identifier">center</span><span class="special">[]</span></code>, or <code class="computeroutput"><span class="identifier">right_align</span><span class="special">[]</span></code>, for instance:
</p>
<pre class="programlisting"><span class="identifier">maxwidth</span><span class="special">(</span><span class="number">8</span><span class="special">)[</span><span class="identifier">left_align</span><span class="special">(</span><span class="number">8</span><span class="special">)[</span><span class="string">"1234"</span><span class="special">]]</span>
</pre>
<p>
- which will output: <tt class="computeroutput"><span class="string">"1234 "</span></tt>
+ which will output: <code class="computeroutput"><span class="string">"1234 "</span></code>
(without the quotes).
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.directive.maxwidth.attributes"></a><h6>
-<a name="id551389"></a>
- Attributes
+<a name="id1266798"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -172,63 +177,71 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">maxwidth</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">maxwidth</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.maxwidth.complexity"></a><h6>
-<a name="id551779"></a>
- Complexity
+<a name="id1268738"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- The overall complexity of the generator directive <tt class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></tt> is defined by the complexity of
+ The overall complexity of the generator directive <code class="computeroutput"><span class="identifier">maxwidth</span><span class="special">[]</span></code> is defined by the complexity of
its embedded generator. The complexity of the directive itself is
- O(N), where <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ O(N), where <code class="computeroutput"><span class="identifier">N</span></code> is
the number of characters generated by the maxwidth directive.
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.maxwidth.example"></a><h6>
-<a name="id551849"></a>
- Example
+<a name="id1268780"></a>
+ <a class="link" href="maxwidth.html#spirit.karma.reference.directive.maxwidth.example">Example</a>
</h6>
<p>
Some includes:
@@ -288,7 +301,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">maxwidth</span></tt>
+ Basic usage of <code class="computeroutput"><span class="identifier">maxwidth</span></code>
generator directive:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/omit.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/omit.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/omit.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Consume Attribute
- (omit[])</title>
+<title>Consume Attribute (omit[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="buffer.html" title=" Temporary
- Output Buffering (buffer[])">
+<link rel="prev" href="buffer.html" title="Temporary Output Buffering (buffer[])">
<link rel="next" href="../operator.html" title="Operator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -24,68 +22,64 @@
<div class="spirit-nav">
<a accesskey="p" href="buffer.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../operator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.omit"></a><a href="omit.html" title=" Consume Attribute
- (omit[])"> Consume Attribute
- (<tt class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Consume Attribute (omit[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.omit"></a><a class="link" href="omit.html" title="Consume Attribute (omit[])"> Consume Attribute
+ (<code class="computeroutput"><span class="identifier">omit</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.omit.description"></a><h6>
-<a name="id555107"></a>
- Description
+<a name="id1272387"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.description">Description</a>
</h6>
<p>
Consumes the attribute type of the embedded generator without generating
any output.
</p>
<a name="spirit.karma.reference.directive.omit.header"></a><h6>
-<a name="id555137"></a>
- Header
+<a name="id1272404"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/omit.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_omit</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.omit.model_of"></a><h6>
-<a name="id555252"></a>
- <a href="omit.html#spirit.karma.reference.directive.omit.model_of">Model
+<a name="id1272479"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code></span></dt>
<dd><p>
- Attribute type of generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ Attribute type of generator <code class="computeroutput"><span class="identifier">a</span></code>
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.omit.expression_semantics"></a><h6>
-<a name="id555368"></a>
- <a href="omit.html#spirit.karma.reference.directive.omit.expression_semantics">Expression
+<a name="id1272567"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -93,27 +87,35 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- The <tt class="computeroutput"><span class="identifier">omit</span></tt> directive
- consumes the attribute type of the embedded generator <tt class="computeroutput"><span class="identifier">A</span></tt> without generating any output.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The <code class="computeroutput"><span class="identifier">omit</span></code> directive
+ consumes the attribute type of the embedded generator <code class="computeroutput"><span class="identifier">A</span></code> without generating any output.
It succeeds always.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.directive.omit.attributes"></a><h6>
-<a name="id555525"></a>
- Attributes
+<a name="id1272681"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -121,45 +123,51 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.directive.omit.complexity"></a><h6>
-<a name="id555736"></a>
- Complexity
+<a name="id1272842"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- The overall complexity of the <tt class="computeroutput"><span class="identifier">omit</span></tt>
+ The overall complexity of the <code class="computeroutput"><span class="identifier">omit</span></code>
generator directive is O(1) as it does not generate any output.
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.omit.example"></a><h6>
-<a name="id555786"></a>
- Example
+<a name="id1272873"></a>
+ <a class="link" href="omit.html#spirit.karma.reference.directive.omit.example">Example</a>
</h6>
<p>
Some includes:
@@ -220,10 +228,10 @@
<p>
</p>
<p>
- Basic usage of a <tt class="computeroutput"><span class="identifier">omit</span></tt>
+ Basic usage of a <code class="computeroutput"><span class="identifier">omit</span></code>
generator directive. It shows how it consumes the first element of the
provided attribute without generating anything, leaving the second element
- of the attribute to the non-wrapped <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ of the attribute to the non-wrapped <code class="computeroutput"><span class="identifier">double_</span></code>
generator.
</p>
<p>
@@ -243,7 +251,7 @@
type contains more information (elements) than need to be used to generate
the required output. Normally in such situations we would resolve to
use semantic actions to explicitly pass the correct parts of the overall
- attribute to the generators. The <tt class="computeroutput"><span class="identifier">omit</span></tt>
+ attribute to the generators. The <code class="computeroutput"><span class="identifier">omit</span></code>
directive helps achieving the same without having to use semantic actions.
</p>
<p>
@@ -265,7 +273,7 @@
</span></pre>
<p>
This is error prone and not really readable. The same can be achieved
- by using the <tt class="computeroutput"><span class="identifier">omit</span></tt> directive:
+ by using the <code class="computeroutput"><span class="identifier">omit</span></code> directive:
</p>
<pre class="programlisting"><span class="identifier">r</span> <span class="special">=</span> <span class="identifier">int_</span> <span class="special"><<</span> <span class="identifier">omit</span><span class="special">[</span><span class="identifier">double_</span><span class="special">]</span> <span class="special"><<</span> <span class="identifier">string</span><span class="special">;</span>
</pre>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/repeat.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/repeat.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/repeat.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Repetition
- Directive (repeat[])</title>
+<title>Repetition Directive (repeat[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])">
-<link rel="next" href="delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])">
+<link rel="prev" href="alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])">
+<link rel="next" href="delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,73 +22,69 @@
<div class="spirit-nav">
<a accesskey="p" href="alignment.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="delimit.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.repeat"></a><a href="repeat.html" title=" Repetition
- Directive (repeat[])"> Repetition
- Directive (<tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Repetition Directive (repeat[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.repeat"></a><a class="link" href="repeat.html" title="Repetition Directive (repeat[])"> Repetition
+ Directive (<code class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.repeat.description"></a><h6>
-<a name="id541638"></a>
- Description
+<a name="id1256679"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.description">Description</a>
</h6>
<p>
The repetition directive allows to repeat an arbitrary generator expression
while optionally specifying the lower and upper repetition counts.
</p>
<a name="spirit.karma.reference.directive.repeat.header"></a><h6>
-<a name="id541670"></a>
- Header
+<a name="id1256696"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/repeat.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_repeat</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.repeat.model_of"></a><h6>
-<a name="id541783"></a>
- <a href="repeat.html#spirit.karma.reference.directive.repeat.model_of">Model
+<a name="id1256770"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span><span class="special">,</span> <span class="identifier">num1</span><span class="special">,</span> <span class="identifier">num2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span><span class="special">,</span> <span class="identifier">num1</span><span class="special">,</span> <span class="identifier">num2</span></code></span></dt>
<dd><p>
- Numeric literals, any unsigned integer value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literals, any unsigned integer value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to an unsigned integer value
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">inf</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">inf</span></code></span></dt>
<dd><p>
Placeholder expression standing for 'no upper repeat limit'
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.repeat.expression_semantics"></a><h6>
-<a name="id541947"></a>
- <a href="repeat.html#spirit.karma.reference.directive.repeat.expression_semantics">Expression
+<a name="id1256892"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -99,80 +92,99 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Repeat the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat the generator <code class="computeroutput"><span class="identifier">a</span></code>
zero or more times. This generator succeeds as long as its embedded
- generator <tt class="computeroutput"><span class="identifier">a</span></tt> does
+ generator <code class="computeroutput"><span class="identifier">a</span></code> does
not fail (except if the underlying output stream reports an error).
- This variant of <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></tt> is semantically equivalent
- to the <a href="../operator/kleene.html" title=" Kleene Star
- (unary operator*())">Kleene
- Star operator <tt class="computeroutput"><span class="special">*</span><span class="identifier">a</span></tt></a>
- </p></td>
+ This variant of <code class="computeroutput"><span class="identifier">repeat</span><span class="special">[]</span></code> is semantically equivalent
+ to the <a class="link" href="../operator/kleene.html" title="Kleene Star (unary operator*())">Kleene
+ Star operator <code class="computeroutput"><span class="special">*</span><span class="identifier">a</span></code></a>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Repeat the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
- exactly <tt class="computeroutput"><span class="identifier">num</span></tt> times.
- This generator succeeds as long as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt> does not fail and as long
- as the associated attribute (container) contains at least <tt class="computeroutput"><span class="identifier">num</span></tt> elements (except if the
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat the generator <code class="computeroutput"><span class="identifier">a</span></code>
+ exactly <code class="computeroutput"><span class="identifier">num</span></code> times.
+ This generator succeeds as long as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code> does not fail and as long
+ as the associated attribute (container) contains at least <code class="computeroutput"><span class="identifier">num</span></code> elements (except if the
underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
- <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Repeat the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
- at least <tt class="computeroutput"><span class="identifier">num1</span></tt>
- times but not more than <tt class="computeroutput"><span class="identifier">num2</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
+ <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat the generator <code class="computeroutput"><span class="identifier">a</span></code>
+ at least <code class="computeroutput"><span class="identifier">num1</span></code>
+ times but not more than <code class="computeroutput"><span class="identifier">num2</span></code>
times. This generator succeeds as long as its embedded generator
- <tt class="computeroutput"><span class="identifier">a</span></tt> does not fail
+ <code class="computeroutput"><span class="identifier">a</span></code> does not fail
and as long as the associated attribute (container) contains
- at least <tt class="computeroutput"><span class="identifier">num1</span></tt>
+ at least <code class="computeroutput"><span class="identifier">num1</span></code>
elements (except if the underlying output stream reports an error).
If the associated attribute (container) does contain more than
- <tt class="computeroutput"><span class="identifier">num2</span></tt> elements,
- this directive limits the repeat count to <tt class="computeroutput"><span class="identifier">num2</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="identifier">num2</span></code> elements,
+ this directive limits the repeat count to <code class="computeroutput"><span class="identifier">num2</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Repeat the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
- at least <tt class="computeroutput"><span class="identifier">num1</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat the generator <code class="computeroutput"><span class="identifier">a</span></code>
+ at least <code class="computeroutput"><span class="identifier">num1</span></code>
times. No upper limit for the repeat count is set. This generator
- succeeds as long as its embedded generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ succeeds as long as its embedded generator <code class="computeroutput"><span class="identifier">a</span></code>
does not fail and as long as the associated attribute (container)
- contains at least <tt class="computeroutput"><span class="identifier">num</span></tt>
+ contains at least <code class="computeroutput"><span class="identifier">num</span></code>
elements (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.repeat.attributes"></a><h6>
-<a name="id542524"></a>
- Attributes
+<a name="id1258945"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -180,92 +192,104 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
- <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span>
+ <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span> <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num1</span><span class="special">,</span> <span class="identifier">num2</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
- <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span>
+ <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span> <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(</span><span class="identifier">num</span><span class="special">,</span> <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- The table above uses <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as placeholders only.
+ The table above uses <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as placeholders only.
</p>
<p>
- The notation of <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> stands for <span class="emphasis"><em>any STL container</em></span>
- holding elements of type <tt class="computeroutput"><span class="identifier">A</span></tt>.
+ The notation of <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> stands for <span class="emphasis"><em>any STL container</em></span>
+ holding elements of type <code class="computeroutput"><span class="identifier">A</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.directive.repeat.complexity"></a><h6>
-<a name="id543482"></a>
- Complexity
+<a name="id1259664"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -279,8 +303,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.repeat.example"></a><h6>
-<a name="id543523"></a>
- Example
+<a name="id1259688"></a>
+ <a class="link" href="repeat.html#spirit.karma.reference.directive.repeat.example">Example</a>
</h6>
<p>
Some includes:
@@ -341,7 +365,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">repeat</span></tt>
+ Basic usage of <code class="computeroutput"><span class="identifier">repeat</span></code>
generator directive:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/directive/upperlower.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/directive/upperlower.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/directive/upperlower.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Directives
- Controlling Case Sensitivity (upper[] and lower[])</title>
+<title>Directives Controlling Case Sensitivity (upper[] and lower[])</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../directive.html" title="Directive">
-<link rel="previous" href="delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])">
-<link rel="next" href="maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])">
+<link rel="prev" href="delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])">
+<link rel="next" href="maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,80 +22,76 @@
<div class="spirit-nav">
<a accesskey="p" href="delimit.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="maxwidth.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.directive.upperlower"></a><a href="upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])"> Directives
- Controlling Case Sensitivity (<tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Directives Controlling Case Sensitivity (upper[] and lower[])">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.directive.upperlower"></a><a class="link" href="upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])"> Directives
+ Controlling Case Sensitivity (<code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.directive.upperlower.description"></a><h6>
-<a name="id547865"></a>
- Description
+<a name="id1262924"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.description">Description</a>
</h6>
<p>
- The generator directives <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[]</span></tt> force their embedded generators to
+ The generator directives <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[]</span></code> force their embedded generators to
emit lower case or upper case only characters based on the interpretation
- of the generated characters in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt> (see <a href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ of the generated characters in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code> (see <a class="link" href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>).
</p>
<a name="spirit.karma.reference.directive.upperlower.header"></a><h6>
-<a name="id547970"></a>
- Header
+<a name="id1262989"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/directive/upper_lower_case.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_upper_lower_case</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.directive.upperlower.model_of"></a><h6>
-<a name="id548084"></a>
- <a href="upperlower.html#spirit.karma.reference.directive.upperlower.model_of">Model
+<a name="id1263064"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- The model of <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt> and <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt> is the model of its subject generator.
+ The model of <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code> and <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code> is the model of its subject generator.
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">a</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">a</span></code></span></dt>
<dd><p>
A generator object
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span></code></span></dt>
<dd><p>
- Attribute type of the generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+ Attribute type of the generator <code class="computeroutput"><span class="identifier">a</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.directive.upperlower.expression_semantics"></a><h6>
-<a name="id548252"></a>
- <a href="upperlower.html#spirit.karma.reference.directive.upperlower.expression_semantics">Expression
+<a name="id1263182"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.expression_semantics">Expression
Semantics</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>
- and <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt>
+ The <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>
+ and <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code>
directives have no special generator semantics. They are pure modifier
directives. They indirectly influence the way all subject generators
- work. They add information (the <tt class="computeroutput"><span class="identifier">tag</span><span class="special">::</span><span class="identifier">upper</span></tt>
- or <tt class="computeroutput"><span class="identifier">tag</span><span class="special">::</span><span class="identifier">lower</span></tt>) to the <tt class="computeroutput"><span class="identifier">Modifier</span></tt>
- template parameter used while tranforming the <tt class="computeroutput"><span class="identifier">proto</span><span class="special">::</span><span class="identifier">expr</span></tt>
+ work. They add information (the <code class="computeroutput"><span class="identifier">tag</span><span class="special">::</span><span class="identifier">upper</span></code>
+ or <code class="computeroutput"><span class="identifier">tag</span><span class="special">::</span><span class="identifier">lower</span></code>) to the <code class="computeroutput"><span class="identifier">Modifier</span></code>
+ template parameter used while tranforming the <code class="computeroutput"><span class="identifier">proto</span><span class="special">::</span><span class="identifier">expr</span></code>
into the corresponding generator expression. This is achieved by the
following specializations:
</p>
@@ -129,44 +122,56 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> as
- lower case, interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>. The directive succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> as
+ lower case, interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>. The directive succeeds
as long as the embedded generator succeeded (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">a</span></tt> as
- upper case, interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>. The directive succeeds
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">a</span></code> as
+ upper case, interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>. The directive succeeds
as long as the embedded generator succeeded (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
If both directives are 'active' with regard to a generator, the innermost
of those directives takes precendence. For instance:
@@ -174,19 +179,19 @@
<pre class="programlisting"><span class="identifier">generate</span><span class="special">(</span><span class="identifier">sink</span><span class="special">,</span> <span class="identifier">ascii</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[</span><span class="char">'A'</span> <span class="special"><<</span> <span class="identifier">ascii</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[</span><span class="char">'b'</span><span class="special">]])</span>
</pre>
<p>
- will generate <tt class="computeroutput"><span class="string">"aB"</span></tt>
+ will generate <code class="computeroutput"><span class="string">"aB"</span></code>
(without the quotes).
</p>
<p>
Further, the directives will have no effect on generators not emitting
characters having an upper case or lower case equivalent in the character
- set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>.
+ set defined by <code class="computeroutput"><span class="identifier">ns</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.directive.upperlower.attributes"></a><h6>
-<a name="id549106"></a>
- Attributes
+<a name="id1265156"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -194,54 +199,62 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">:</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">:</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">ns</span><span class="special">:</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">ns</span><span class="special">:</span><span class="identifier">lower</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">:</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
<td>
-<p>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">:</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">ns</span><span class="special">:</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">ns</span><span class="special">:</span><span class="identifier">upper</span><span class="special">[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.directive.upperlower.complexity"></a><h6>
-<a name="id549524"></a>
- Complexity
+<a name="id1265474"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- The overall complexity of the generator directives <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[]</span></tt>
- and <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[]</span></tt>
+ The overall complexity of the generator directives <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">lower</span><span class="special">[]</span></code>
+ and <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">upper</span><span class="special">[]</span></code>
is defined by the complexity of its embedded generators. The directives
themselves are compile time only directives, having no impact on
runtime performance.
@@ -250,8 +263,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.directive.upperlower.example"></a><h6>
-<a name="id549615"></a>
- Example
+<a name="id1265534"></a>
+ <a class="link" href="upperlower.html#spirit.karma.reference.directive.upperlower.example">Example</a>
</h6>
<p>
Some includes:
@@ -310,8 +323,8 @@
<p>
</p>
<p>
- Basic usage of the <tt class="computeroutput"><span class="identifier">upper</span></tt>
- and <tt class="computeroutput"><span class="identifier">lower</span></tt> generator directives:
+ Basic usage of the <code class="computeroutput"><span class="identifier">upper</span></code>
+ and <code class="computeroutput"><span class="identifier">lower</span></code> generator directives:
</p>
<p>
</p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Generator
- Concepts</title>
+<title>Generator Concepts</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="../reference.html" title="Reference">
+<link rel="prev" href="../reference.html" title="Reference">
<link rel="next" href="generator_concepts/generator.html" title="Generator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="../reference.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="generator_concepts/generator.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.generator_concepts"></a><a href="generator_concepts.html" title="Generator
- Concepts">Generator
+<div class="section" title="Generator Concepts">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.generator_concepts"></a><a class="link" href="generator_concepts.html" title="Generator Concepts">Generator
Concepts</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Generator</span></dt>
<dt><span class="section">PrimitiveGenerator</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/binarygenerator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/binarygenerator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/binarygenerator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>BinaryGenerator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../generator_concepts.html" title="Generator
- Concepts">
-<link rel="previous" href="unarygenerator.html" title="UnaryGenerator">
+<link rel="up" href="../generator_concepts.html" title="Generator Concepts">
+<link rel="prev" href="unarygenerator.html" title="UnaryGenerator">
<link rel="next" href="narygenerator.html" title="NaryGenerator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,59 +22,56 @@
<div class="spirit-nav">
<a accesskey="p" href="unarygenerator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="narygenerator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.generator_concepts.binarygenerator"></a>BinaryGenerator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="BinaryGenerator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.generator_concepts.binarygenerator"></a><a class="link" href="binarygenerator.html" title="BinaryGenerator">BinaryGenerator</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.description"></a><h6>
-<a name="id500062"></a>
- Description
+<a name="id1191586"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>BinaryGenerator</em></span> is a composite parser that has a
- two subjects, <tt class="computeroutput"><span class="identifier">left</span></tt> and
- <tt class="computeroutput"><span class="identifier">right</span></tt>. The BinaryGenerator
+ two subjects, <code class="computeroutput"><span class="identifier">left</span></code> and
+ <code class="computeroutput"><span class="identifier">right</span></code>. The BinaryGenerator
allows its subjects to be treated in the same way as a single instance
- of a Generator following the Composite
+ of a <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a> following the Composite
Design Pattern.
</p>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.refinement_of"></a><h6>
-<a name="id500142"></a>
- <a href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.refinement_of">Refinement
+<a name="id1191633"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Generator
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
A BinaryGenerator.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">G</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">G</span></code></span></dt>
<dd><p>
A BinaryGenerator type.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.valid_expressions"></a><h6>
-<a name="id500252"></a>
- <a href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.valid_expressions">Valid
+<a name="id1191710"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Generator, for any BinaryGenerator
+ In addition to the requirements defined in <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>, for any BinaryGenerator
the following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -85,44 +81,62 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">left</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">left</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Left generator.
- </p></td>
-<td><p>
- Generator
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">right</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">right</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Right generator.
- </p></td>
-<td><p>
- Generator
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.type_expressions"></a><h6>
-<a name="id500474"></a>
- <a href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.type_expressions">Type
+<a name="id1191872"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -131,72 +145,88 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">left_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">left_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The left parser type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">right_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">right_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The right parser type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_binary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">G</span></tt>
- is a BinaryGenerator, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_binary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">G</span></code>
+ is a BinaryGenerator, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.invariants"></a><h6>
-<a name="id500739"></a>
- Invariants
+<a name="id1192071"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.invariants">Invariants</a>
</h6>
<p>
- For any BinaryGenerator, <tt class="computeroutput"><span class="identifier">G</span></tt>,
+ For any BinaryGenerator, <code class="computeroutput"><span class="identifier">G</span></code>,
the following invariants always hold:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">left_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">left_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">right_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">right_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li>
</ul></div>
<a name="spirit.karma.reference.generator_concepts.binarygenerator.models"></a><h6>
-<a name="id500939"></a>
- Models
+<a name="id1192208"></a>
+ <a class="link" href="binarygenerator.html#spirit.karma.reference.generator_concepts.binarygenerator.models">Models</a>
</h6>
<p>
The following generators conform to this model:
</p>
-<div class="itemizedlist"><ul type="disc"><li>
-list (%).
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
+<a class="link" href="../operator/list.html" title="Lists (operator%())">list (<code class="computeroutput"><span class="special">%</span></code>)</a>.
</li></ul></div>
<p>
- <span class="bold"><b>FIXME</b></span> Add more links to models of BinaryGenerator
+ <span class="bold"><strong>FIXME</strong></span> Add more links to models of BinaryGenerator
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/generator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/generator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/generator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Generator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../generator_concepts.html" title="Generator
- Concepts">
-<link rel="previous" href="../generator_concepts.html" title="Generator
- Concepts">
+<link rel="up" href="../generator_concepts.html" title="Generator Concepts">
+<link rel="prev" href="../generator_concepts.html" title="Generator Concepts">
<link rel="next" href="primitivegenerator.html" title="PrimitiveGenerator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -24,77 +22,74 @@
<div class="spirit-nav">
<a accesskey="p" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="primitivegenerator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.generator_concepts.generator"></a>Generator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Generator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.generator_concepts.generator"></a><a class="link" href="generator.html" title="Generator">Generator</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.generator_concepts.generator.description"></a><h6>
-<a name="id497147"></a>
- Description
+<a name="id1189522"></a>
+ <a class="link" href="generator.html#spirit.karma.reference.generator_concepts.generator.description">Description</a>
</h6>
<p>
The <span class="emphasis"><em>Generator</em></span> is the most fundamental concept. A
- Generator has a member function, <tt class="computeroutput"><span class="identifier">generate</span></tt>,
- that accepts an <tt class="computeroutput"><span class="identifier">OutputIterator</span></tt>
+ Generator has a member function, <code class="computeroutput"><span class="identifier">generate</span></code>,
+ that accepts an <code class="computeroutput"><span class="identifier">OutputIterator</span></code>
and returns bool as its result. The iterator receives the data being
- generated. The Generator's <tt class="computeroutput"><span class="identifier">generate</span></tt>
- member function returns <tt class="computeroutput"><span class="keyword">true</span></tt>
+ generated. The Generator's <code class="computeroutput"><span class="identifier">generate</span></code>
+ member function returns <code class="computeroutput"><span class="keyword">true</span></code>
if the generator succeeds. Each Generator can represent a specific pattern
or algorithm, or it can be a more complex generator formed as a composition
of other Generator's.
</p>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">Generator</span></tt>.
+ A <code class="computeroutput"><span class="identifier">Generator</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">G</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">G</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">Generator</span></tt> type.
+ A <code class="computeroutput"><span class="identifier">Generator</span></code> type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">OutIter</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">OutIter</span></code></span></dt>
<dd><p>
- An <tt class="computeroutput"><span class="identifier">OutputIterator</span></tt>
+ An <code class="computeroutput"><span class="identifier">OutputIterator</span></code>
type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">sink</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">sink</span></code></span></dt>
<dd><p>
- An <tt class="computeroutput"><span class="identifier">OutputIterator</span></tt>
+ An <code class="computeroutput"><span class="identifier">OutputIterator</span></code>
instance.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Context</span></code></span></dt>
<dd><p>
The generator's Context type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">context</span></code></span></dt>
<dd><p>
- The generator's Context, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ The generator's Context, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">delimit</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">delimit</span></code></span></dt>
<dd><p>
- A delimiter Generator, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ A delimiter Generator, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">attrib</span></code></span></dt>
<dd><p>
- A Compatible Attributes, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ A Compatible Attributes, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.generator_concepts.generator.valid_expressions"></a><h6>
-<a name="id497514"></a>
- <a href="generator.html#spirit.karma.reference.generator_concepts.generator.valid_expressions">Valid
+<a name="id1189776"></a>
+ <a class="link" href="generator.html#spirit.karma.reference.generator_concepts.generator.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In the expressions below, the behavior of the generator, <tt class="computeroutput"><span class="identifier">g</span></tt>, as well as how <tt class="computeroutput"><span class="identifier">delimit</span></tt>
- and <tt class="computeroutput"><span class="identifier">attrib</span></tt> are handled
- by <tt class="computeroutput"><span class="identifier">g</span></tt>, are left unspecified
- in the base <tt class="computeroutput"><span class="identifier">Generator</span></tt>
+ In the expressions below, the behavior of the generator, <code class="computeroutput"><span class="identifier">g</span></code>, as well as how <code class="computeroutput"><span class="identifier">delimit</span></code>
+ and <code class="computeroutput"><span class="identifier">attrib</span></code> are handled
+ by <code class="computeroutput"><span class="identifier">g</span></code>, are left unspecified
+ in the base <code class="computeroutput"><span class="identifier">Generator</span></code>
concept. These are specified in subsequent, more refined concepts and
by the actual models therof.
</p>
@@ -108,53 +103,69 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">g</span><span class="special">.</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">sink</span><span class="special">,</span> <span class="identifier">context</span><span class="special">,</span> <span class="identifier">delimit</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the output sequence by inserting the generated characters/tokens
- into <tt class="computeroutput"><span class="identifier">sink</span></tt>. Use
- the <tt class="computeroutput"><span class="identifier">delimit</span></tt> generator
- for delimiting. Return <tt class="computeroutput"><span class="keyword">true</span></tt>
- if successful, otherwise return <tt class="computeroutput"><span class="keyword">false</span></tt>.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">bool</span></tt>
- </p></td>
+ into <code class="computeroutput"><span class="identifier">sink</span></code>. Use
+ the <code class="computeroutput"><span class="identifier">delimit</span></code> generator
+ for delimiting. Return <code class="computeroutput"><span class="keyword">true</span></code>
+ if successful, otherwise return <code class="computeroutput"><span class="keyword">false</span></code>.
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">bool</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">what</span><span class="special">(</span><span class="identifier">context</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">what</span><span class="special">(</span><span class="identifier">context</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Get information about a Generator.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">info</span></tt>
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">info</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.generator.type_expressions"></a><h6>
-<a name="id497882"></a>
- <a href="generator.html#spirit.karma.reference.generator_concepts.generator.type_expressions">Type
+<a name="id1190036"></a>
+ <a class="link" href="generator.html#spirit.karma.reference.generator_concepts.generator.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -163,71 +174,87 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="keyword">template</span> <span class="identifier">attribute</span><span class="special"><</span><span class="identifier">Context</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="keyword">template</span> <span class="identifier">attribute</span><span class="special"><</span><span class="identifier">Context</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The Generator's attribute.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">G</span></tt>
- is a Generator, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">G</span></code>
+ is a Generator, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">properties</span></tt>
- </p></td>
-<td><p>
- A <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">int_</span></tt> (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
- Integral Constant</a>) holding a value from the <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generator_properties</span></tt> enumeration.
- The default value is <tt class="computeroutput"><span class="identifier">generator_properties</span><span class="special">::</span><span class="identifier">no_properties</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">properties</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">int_</span></code> (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
+ Integral Constant</a>) holding a value from the <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generator_properties</span></code> enumeration.
+ The default value is <code class="computeroutput"><span class="identifier">generator_properties</span><span class="special">::</span><span class="identifier">no_properties</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.generator.postcondition"></a><h6>
-<a name="id498249"></a>
- Postcondition
+<a name="id1190302"></a>
+ <a class="link" href="generator.html#spirit.karma.reference.generator_concepts.generator.postcondition">Postcondition</a>
</h6>
<p>
- Upon return from <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">generate</span></tt> the following post conditions
+ Upon return from <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">generate</span></code> the following post conditions
should hold:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- On successful generation, <tt class="computeroutput"><span class="identifier">sink</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ On successful generation, <code class="computeroutput"><span class="identifier">sink</span></code>
receives the generated characters/tokens sequence.
</li>
-<li>
- No pre-delimits: <tt class="computeroutput"><span class="identifier">delimit</span></tt>
+<li class="listitem">
+ No pre-delimits: <code class="computeroutput"><span class="identifier">delimit</span></code>
characters/tokens will not be emitted in front of any other output.
</li>
-<li>
- The attribute <tt class="computeroutput"><span class="identifier">attrib</span></tt>
+<li class="listitem">
+ The attribute <code class="computeroutput"><span class="identifier">attrib</span></code>
has not been modified.
</li>
</ul></div>
<a name="spirit.karma.reference.generator_concepts.generator.models"></a><h6>
-<a name="id498355"></a>
- Models
+<a name="id1190371"></a>
+ <a class="link" href="generator.html#spirit.karma.reference.generator_concepts.generator.models">Models</a>
</h6>
<p>
All generators in <span class="emphasis"><em>Spirit.Karma</em></span> are models of the
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/narygenerator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/narygenerator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/narygenerator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>NaryGenerator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../generator_concepts.html" title="Generator
- Concepts">
-<link rel="previous" href="binarygenerator.html" title="BinaryGenerator">
-<link rel="next" href="../karma_basics.html" title=" Basics">
+<link rel="up" href="../generator_concepts.html" title="Generator Concepts">
+<link rel="prev" href="binarygenerator.html" title="BinaryGenerator">
+<link rel="next" href="../karma_basics.html" title="Basics">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,57 +22,54 @@
<div class="spirit-nav">
<a accesskey="p" href="binarygenerator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../karma_basics.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.generator_concepts.narygenerator"></a>NaryGenerator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="NaryGenerator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.generator_concepts.narygenerator"></a><a class="link" href="narygenerator.html" title="NaryGenerator">NaryGenerator</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.generator_concepts.narygenerator.description"></a><h6>
-<a name="id501028"></a>
- Description
+<a name="id1192263"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>NaryGenerator</em></span> is a composite generator that has
one or more subjects. The NaryGenerator allows its subjects to be treated
- in the same way as a single instance of a Generator following the Composite
+ in the same way as a single instance of a <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a> following the Composite
Design Pattern.
</p>
<a name="spirit.karma.reference.generator_concepts.narygenerator.refinement_of"></a><h6>
-<a name="id501083"></a>
- <a href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.refinement_of">Refinement
+<a name="id1192294"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Generator
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
A NaryGenerator.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">G</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">G</span></code></span></dt>
<dd><p>
A NaryGenerator type.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.generator_concepts.narygenerator.valid_expressions"></a><h6>
-<a name="id501192"></a>
- <a href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.valid_expressions">Valid
+<a name="id1192371"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Generator, for any NaryGenerator
+ In addition to the requirements defined in <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>, for any NaryGenerator
the following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -83,32 +79,44 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">elements</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">elements</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The tuple of elements.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
A Fusion
- Sequence of Generator types.
- </p></td>
+ Sequence of <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a> types.
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.narygenerator.type_expressions"></a><h6>
-<a name="id501360"></a>
- <a href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.type_expressions">Type
+<a name="id1192491"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -117,68 +125,78 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">elements_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">elements_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Elements tuple type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_nary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">G</span></tt>
- is a NaryGenerator, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_nary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">G</span></code>
+ is a NaryGenerator, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.narygenerator.invariants"></a><h6>
-<a name="id501586"></a>
- Invariants
+<a name="id1192658"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.invariants">Invariants</a>
</h6>
<p>
- For each element, <tt class="computeroutput"><span class="identifier">E</span></tt>,
- in any NaryGenerator, <tt class="computeroutput"><span class="identifier">G</span></tt>,
+ For each element, <code class="computeroutput"><span class="identifier">E</span></code>,
+ in any NaryGenerator, <code class="computeroutput"><span class="identifier">G</span></code>,
the following invariant always holds:
</p>
-<div class="itemizedlist"><ul type="disc"><li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">E</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">E</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li></ul></div>
<a name="spirit.karma.reference.generator_concepts.narygenerator.models"></a><h6>
-<a name="id501710"></a>
- Models
+<a name="id1192743"></a>
+ <a class="link" href="narygenerator.html#spirit.karma.reference.generator_concepts.narygenerator.models">Models</a>
</h6>
<p>
The following generators conform to this model:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<a href="../operator/sequence.html" title=" Sequences
- (operator<<())">sequence (<tt class="computeroutput"><span class="special"><<</span></tt>)</a>,
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<a class="link" href="../operator/sequence.html" title="Sequences (operator<<())">sequence (<code class="computeroutput"><span class="special"><<</span></code>)</a>,
</li>
-<li>
-<a href="../operator/alternative.html" title=" Alternatives
- (operator|())">alternative
- (<tt class="computeroutput"><span class="special">|</span></tt>)</a>.
+<li class="listitem">
+<a class="link" href="../operator/alternative.html" title="Alternatives (operator|())">alternative
+ (<code class="computeroutput"><span class="special">|</span></code>)</a>.
</li>
</ul></div>
<p>
- <span class="bold"><b>FIXME</b></span> Add more links to models of NaryGenerator
+ <span class="bold"><strong>FIXME</strong></span> Add more links to models of NaryGenerator
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/primitivegenerator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/primitivegenerator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/primitivegenerator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>PrimitiveGenerator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../generator_concepts.html" title="Generator
- Concepts">
-<link rel="previous" href="generator.html" title="Generator">
+<link rel="up" href="../generator_concepts.html" title="Generator Concepts">
+<link rel="prev" href="generator.html" title="Generator">
<link rel="next" href="unarygenerator.html" title="UnaryGenerator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,51 +22,48 @@
<div class="spirit-nav">
<a accesskey="p" href="generator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unarygenerator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.generator_concepts.primitivegenerator"></a>PrimitiveGenerator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="PrimitiveGenerator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.generator_concepts.primitivegenerator"></a><a class="link" href="primitivegenerator.html" title="PrimitiveGenerator">PrimitiveGenerator</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.generator_concepts.primitivegenerator.description"></a><h6>
-<a name="id498416"></a>
- Description
+<a name="id1190413"></a>
+ <a class="link" href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>PrimitiveGenerator</em></span> is the most basic building block
that the client uses to build more complex generators.
</p>
<a name="spirit.karma.reference.generator_concepts.primitivegenerator.refinement_of"></a><h6>
-<a name="id498451"></a>
- <a href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.refinement_of">Refinement
+<a name="id1190434"></a>
+ <a class="link" href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Generator
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.generator_concepts.primitivegenerator.post_delimit"></a><h6>
-<a name="id498508"></a>
- Post-delimit
+<a name="id1190467"></a>
+ <a class="link" href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.post_delimit">Post-delimit</a>
</h6>
<p>
- Before exiting the <tt class="computeroutput"><span class="identifier">generate</span></tt>
+ Before exiting the <code class="computeroutput"><span class="identifier">generate</span></code>
member function, a PrimitiveGenerator is required to do a post-delimit.
This will generate a single delimiting character/token sequence. Only
PrimitiveGenerator's are required to perform this post-delimit. This
- is typically carried out through a call to <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">delimit_out</span></tt>:
+ is typically carried out through a call to <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">delimit_out</span></code>:
</p>
<pre class="programlisting"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">delimit_out</span><span class="special">(</span><span class="identifier">sink</span><span class="special">,</span> <span class="identifier">delimit</span><span class="special">);</span>
</pre>
<a name="spirit.karma.reference.generator_concepts.primitivegenerator.type_expressions"></a><h6>
-<a name="id498626"></a>
- <a href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.type_expressions">Type
+<a name="id1190540"></a>
+ <a class="link" href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -76,51 +72,58 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_primitive_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">G</span></tt>,
- is a PrimitiveGenerator, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_primitive_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">G</span></code>,
+ is a PrimitiveGenerator, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.primitivegenerator.models"></a><h6>
-<a name="id498815"></a>
- Models
+<a name="id1190675"></a>
+ <a class="link" href="primitivegenerator.html#spirit.karma.reference.generator_concepts.primitivegenerator.models">Models</a>
</h6>
<p>
The following generators conform to this model:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-eol ,
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<a class="link" href="../auxiliary/eol.html" title="eol"><code class="computeroutput"><span class="identifier">eol</span></code></a> ,
</li>
-<li>
-eps,
+<li class="listitem">
+<a class="link" href="../auxiliary/eps.html" title="eps"><code class="computeroutput"><span class="identifier">eps</span></code></a>,
</li>
-<li>
-Numeric generators,
+<li class="listitem">
+<a class="link" href="../numeric.html" title="Numeric">Numeric generators</a>,
</li>
-<li>
-<a href="../char/char_generator.html" title=" Character
- Generators">Character
+<li class="listitem">
+<a class="link" href="../char/char_generator.html" title="Character Generators">Character
generators</a>.
</li>
</ul></div>
<p>
- <span class="bold"><b>FIXME</b></span> Add more links to <span class="emphasis"><em>PrimitiveGenerator</em></span>
+ <span class="bold"><strong>FIXME</strong></span> Add more links to <span class="emphasis"><em>PrimitiveGenerator</em></span>
models here.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/unarygenerator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/unarygenerator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/generator_concepts/unarygenerator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>UnaryGenerator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../generator_concepts.html" title="Generator
- Concepts">
-<link rel="previous" href="primitivegenerator.html" title="PrimitiveGenerator">
+<link rel="up" href="../generator_concepts.html" title="Generator Concepts">
+<link rel="prev" href="primitivegenerator.html" title="PrimitiveGenerator">
<link rel="next" href="binarygenerator.html" title="BinaryGenerator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,16 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="primitivegenerator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../generator_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binarygenerator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.generator_concepts.unarygenerator"></a>UnaryGenerator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="UnaryGenerator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.generator_concepts.unarygenerator"></a><a class="link" href="unarygenerator.html" title="UnaryGenerator">UnaryGenerator</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.description"></a><h6>
-<a name="id498953"></a>
- Description
+<a name="id1190766"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>UnaryGenerator</em></span> is a composite generator that has
@@ -40,39 +36,39 @@
following the Delegate Design Pattern.
</p>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.refinement_of"></a><h6>
-<a name="id498989"></a>
- <a href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.refinement_of">Refinement
+<a name="id1190786"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Generator
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
A UnaryGenerator.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">G</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">G</span></code></span></dt>
<dd><p>
A UnaryGenerator type.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.valid_expressions"></a><h6>
-<a name="id499098"></a>
- <a href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.valid_expressions">Valid
+<a name="id1190863"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Generator, for any UnaryGenerator
+ In addition to the requirements defined in <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>, for any UnaryGenerator
the following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -82,31 +78,43 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">subject</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">subject</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Subject generator.
- </p></td>
-<td><p>
- Generator
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="generator.html" title="Generator"><code class="computeroutput"><span class="identifier">Generator</span></code></a>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.type_expressions"></a><h6>
-<a name="id499256"></a>
- <a href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.type_expressions">Type
+<a name="id1190978"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -115,118 +123,114 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">subject_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">G</span><span class="special">::</span><span class="identifier">subject_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The subject generator type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_unary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">G</span></tt>
- is a UnaryGenerator, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_unary_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">G</span></code>
+ is a UnaryGenerator, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.invariants"></a><h6>
-<a name="id499483"></a>
- Invariants
+<a name="id1191144"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.invariants">Invariants</a>
</h6>
<p>
- For any UnaryGenerator, <tt class="computeroutput"><span class="identifier">G</span></tt>,
+ For any UnaryGenerator, <code class="computeroutput"><span class="identifier">G</span></code>,
the following invariant always holds:
</p>
-<div class="itemizedlist"><ul type="disc"><li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">subject_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_generator</span><span class="special"><</span><span class="identifier">G</span><span class="special">::</span><span class="identifier">subject_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li></ul></div>
<a name="spirit.karma.reference.generator_concepts.unarygenerator.models"></a><h6>
-<a name="id499607"></a>
- Models
+<a name="id1191229"></a>
+ <a class="link" href="unarygenerator.html#spirit.karma.reference.generator_concepts.unarygenerator.models">Models</a>
</h6>
<p>
The following generators conform to this model:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<a href="../operator/kleene.html" title=" Kleene Star
- (unary operator*())">Kleene Star
- (unary <tt class="computeroutput"><span class="special">*</span></tt>)</a>,
- </li>
-<li>
-<a href="../operator/plus.html" title=" Plus (unary
- operator+())">plus (unary <tt class="computeroutput"><span class="special">+</span></tt>)</a> operator,
- </li>
-<li>
-<a href="../operator/optional.html" title=" Optional
- (unary operator-())">optional (unary
- <tt class="computeroutput"><span class="special">-</span></tt>)</a> operator,
- </li>
-<li>
-<a href="../operator/and_predicate.html" title=" And
- Predicate (unary operator&())">and predicate
- (unary <tt class="computeroutput"><span class="special">&</span></tt>)</a> and
- <a href="../operator/not_predicate.html" title=" Not
- Predicate (unary operator!())">not predicate
- (unary <tt class="computeroutput"><span class="special">!</span></tt>)</a> operators,
- </li>
-<li>
-<a href="../directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">left_align</span></tt></a>, <a href="../directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">center</span></tt></a>, and <a href="../directive/alignment.html" title=" Alignment
- Directives (left_align[], center[], and right_align[])"><tt class="computeroutput"><span class="identifier">right_align</span></tt></a> directives,
- </li>
-<li>
-<a href="../directive/repeat.html" title=" Repetition
- Directive (repeat[])"><tt class="computeroutput"><span class="identifier">repeat</span></tt></a> directive,
- </li>
-<li>
-<a href="../directive/delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"><tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<a class="link" href="../operator/kleene.html" title="Kleene Star (unary operator*())">Kleene Star
+ (unary <code class="computeroutput"><span class="special">*</span></code>)</a>,
+ </li>
+<li class="listitem">
+<a class="link" href="../operator/plus.html" title="Plus (unary operator+())">plus (unary <code class="computeroutput"><span class="special">+</span></code>)</a> operator,
+ </li>
+<li class="listitem">
+<a class="link" href="../operator/optional.html" title="Optional (unary operator-())">optional (unary
+ <code class="computeroutput"><span class="special">-</span></code>)</a> operator,
+ </li>
+<li class="listitem">
+<a class="link" href="../operator/and_predicate.html" title="And Predicate (unary operator&())">and predicate
+ (unary <code class="computeroutput"><span class="special">&</span></code>)</a> and
+ <a class="link" href="../operator/not_predicate.html" title="Not Predicate (unary operator!())">not predicate
+ (unary <code class="computeroutput"><span class="special">!</span></code>)</a> operators,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">left_align</span></code></a>, <a class="link" href="../directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">center</span></code></a>, and <a class="link" href="../directive/alignment.html" title="Alignment Directives (left_align[], center[], and right_align[])"><code class="computeroutput"><span class="identifier">right_align</span></code></a> directives,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/repeat.html" title="Repetition Directive (repeat[])"><code class="computeroutput"><span class="identifier">repeat</span></code></a> directive,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"><code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
directive,
</li>
-<li>
-<a href="../directive/delimit.html" title=" Directives
- Controlling Automatic Delimiting (verbatim[] and delimit[])"><tt class="computeroutput"><span class="identifier">delimit</span></tt></a> directive,
- </li>
-<li>
-<a href="../directive/upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])"><tt class="computeroutput"><span class="identifier">lower</span></tt></a> and <a href="../directive/upperlower.html" title=" Directives
- Controlling Case Sensitivity (upper[] and lower[])"><tt class="computeroutput"><span class="identifier">upper</span></tt></a> directives,
- </li>
-<li>
-<a href="../directive/maxwidth.html" title=" Controlling
- the Maximum Field Wield (maxwidth[])"><tt class="computeroutput"><span class="identifier">maxwidth</span></tt></a> directive,
- </li>
-<li>
-<a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
+<li class="listitem">
+<a class="link" href="../directive/delimit.html" title="Directives Controlling Automatic Delimiting (verbatim[] and delimit[])"><code class="computeroutput"><span class="identifier">delimit</span></code></a> directive,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])"><code class="computeroutput"><span class="identifier">lower</span></code></a> and <a class="link" href="../directive/upperlower.html" title="Directives Controlling Case Sensitivity (upper[] and lower[])"><code class="computeroutput"><span class="identifier">upper</span></code></a> directives,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/maxwidth.html" title="Controlling the Maximum Field Wield (maxwidth[])"><code class="computeroutput"><span class="identifier">maxwidth</span></code></a> directive,
+ </li>
+<li class="listitem">
+<a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
directive,
</li>
-<li>
-<a href="../directive/omit.html" title=" Consume Attribute
- (omit[])"><tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>
+<li class="listitem">
+<a class="link" href="../directive/omit.html" title="Consume Attribute (omit[])"><code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
directive.
</li>
</ul></div>
<p>
- <span class="bold"><b>FIXME</b></span> Add more links to models of UnaryGenerator
+ <span class="bold"><strong>FIXME</strong></span> Add more links to models of UnaryGenerator
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/karma_basics.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/karma_basics.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/karma_basics.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Basics</title>
+<title>Basics</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="generator_concepts/narygenerator.html" title="NaryGenerator">
-<link rel="next" href="char.html" title=" Char">
+<link rel="prev" href="generator_concepts/narygenerator.html" title="NaryGenerator">
+<link rel="next" href="char.html" title="Char">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,18 +22,15 @@
<div class="spirit-nav">
<a accesskey="p" href="generator_concepts/narygenerator.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="char.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.karma_basics"></a> Basics
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.karma.reference.karma_basics.lazy_argument"></a><h5>
-<a name="id501823"></a>
- <a href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+<div class="section" title="Basics">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.karma_basics"></a><a class="link" href="karma_basics.html" title="Basics"> Basics</a>
+</h4></div></div></div>
+<a name="spirit.karma.reference.karma_basics.lazy_argument"></a><h6>
+<a name="id1192817"></a>
+ <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a>
- </h5>
+ </h6>
<p>
Some generators (e.g. primitives and non-terminals) may take in additional
attributes. Such generators take the form:
@@ -41,40 +38,40 @@
<pre class="programlisting"><span class="identifier">g</span><span class="special">(</span><span class="identifier">a1</span><span class="special">,</span> <span class="identifier">a2</span><span class="special">,...</span> <span class="identifier">aN</span><span class="special">)</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">g</span></tt> is a parser. Each
+ where <code class="computeroutput"><span class="identifier">g</span></code> is a parser. Each
of the arguments (a1...aN) can either be an immediate value, or a function,
- <tt class="computeroutput"><span class="identifier">f</span></tt>, with signature:
+ <code class="computeroutput"><span class="identifier">f</span></code>, with signature:
</p>
<pre class="programlisting"><span class="identifier">T</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">T</span></tt>, the function's
- return value, is compatible with the argument type expected and <tt class="computeroutput"><span class="identifier">Context</span></tt> is the generators's Context type
- (The first argument is <tt class="computeroutput"><span class="identifier">unused</span></tt>
- to make the <tt class="computeroutput"><span class="identifier">Context</span></tt> the
- second argument. This is done for uniformity with <a href="../tutorials/semantic_actions.html" title="Semantic Actions">Semantic
+ where <code class="computeroutput"><span class="identifier">T</span></code>, the function's
+ return value, is compatible with the argument type expected and <code class="computeroutput"><span class="identifier">Context</span></code> is the generators's Context type
+ (The first argument is <code class="computeroutput"><span class="identifier">unused</span></code>
+ to make the <code class="computeroutput"><span class="identifier">Context</span></code> the
+ second argument. This is done for uniformity with <a class="link" href="../tutorials/semantic_actions.html" title="Semantic Actions">Semantic
Actions</a>).
</p>
-<a name="spirit.karma.reference.karma_basics.character_encoding_namespace"></a><h5>
-<a name="id502043"></a>
- <a href="karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
+<a name="spirit.karma.reference.karma_basics.character_encoding_namespace"></a><h6>
+<a name="id1192958"></a>
+ <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
Encoding Namespace</a>
- </h5>
+ </h6>
<p>
- Some generators need to know which character set a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt> is operating on.
- For example, the <tt class="computeroutput"><span class="identifier">alnum</span></tt>
+ Some generators need to know which character set a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code> is operating on.
+ For example, the <code class="computeroutput"><span class="identifier">alnum</span></code>
generator works differently with ISO8859.1 and ASCII encodings. Where necessary,
Spirit encodes (tags) the generator with the character set.
</p>
<p>
We have a namespace for each character set Spirit will be supporting. That
- includes <tt class="computeroutput"><span class="identifier">ascii</span></tt>, <tt class="computeroutput"><span class="identifier">iso8859_1</span></tt>, <tt class="computeroutput"><span class="identifier">standard</span></tt>
- and <tt class="computeroutput"><span class="identifier">standard_wide</span></tt> (and
- in the future, <tt class="computeroutput"><span class="identifier">unicode</span></tt>).
+ includes <code class="computeroutput"><span class="identifier">ascii</span></code>, <code class="computeroutput"><span class="identifier">iso8859_1</span></code>, <code class="computeroutput"><span class="identifier">standard</span></code>
+ and <code class="computeroutput"><span class="identifier">standard_wide</span></code> (and
+ in the future, <code class="computeroutput"><span class="identifier">unicode</span></code>).
In each of the character encoding namespaces, we place tagged versions
- of generators such as <tt class="computeroutput"><span class="identifier">alnum</span></tt>,
- <tt class="computeroutput"><span class="identifier">space</span></tt> etc.
+ of generators such as <code class="computeroutput"><span class="identifier">alnum</span></code>,
+ <code class="computeroutput"><span class="identifier">space</span></code> etc.
</p>
<p>
Example:
@@ -84,17 +81,17 @@
<p>
Namespaces:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
boost::spirit::ascii
</li>
-<li>
+<li class="listitem">
boost::spirit::iso8859_1
</li>
-<li>
+<li class="listitem">
boost::spirit::standard
</li>
-<li>
+<li class="listitem">
boost::spirit::standard_wide
</li>
</ul></div>
@@ -102,20 +99,116 @@
For ease of use, the components in this namespaces are also brought into
the karma sub-namespaces with the same names:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
boost::spirit::karma::ascii
</li>
-<li>
+<li class="listitem">
boost::spirit::karma::iso8859_1
</li>
-<li>
+<li class="listitem">
boost::spirit::karma::standard
</li>
-<li>
+<li class="listitem">
boost::spirit::karma::standard_wide
</li>
</ul></div>
+<a name="spirit.karma.reference.karma_basics.examples"></a><h6>
+<a name="id1193141"></a>
+ <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.examples">Examples</a>
+ </h6>
+<p>
+ All sections in the reference present some real world examples. The examples
+ use a common test harness to keep the example code as minimal and direct
+ to the point as possible. The test harness is presented below.
+ </p>
+<p>
+ Some includes:
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_core</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">phoenix_operator</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">std_pair</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">iostream</span><span class="special">></span>
+<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">string</span><span class="special">></span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ Our test functions:
+ </p>
+<p>
+ This one tests the generators without attributes.
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_generator</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">)</span> <span class="special">&&</span> <span class="identifier">str</span> <span class="special">==</span> <span class="identifier">expected</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+ These test the generators with one or more user supplied attributes.
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_generator_attr</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">T</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span> <span class="special">&&</span> <span class="identifier">str</span> <span class="special">==</span> <span class="identifier">expected</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
+<p>
+
+</p>
+<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">G</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T1</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T2</span><span class="special">></span>
+<span class="keyword">void</span> <span class="identifier">test_generator_attr</span><span class="special">(</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">expected</span><span class="special">,</span> <span class="identifier">G</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">T1</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr1</span><span class="special">,</span>
+ <span class="identifier">T2</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">attr2</span><span class="special">)</span>
+<span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">s</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">s</span><span class="special">);</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">g</span><span class="special">,</span> <span class="identifier">attr1</span><span class="special">,</span> <span class="identifier">attr2</span><span class="special">)</span> <span class="special">&&</span> <span class="identifier">str</span> <span class="special">==</span> <span class="identifier">expected</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"ok"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="keyword">else</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"fail"</span> <span class="special"><<</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+<p>
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/numeric.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/numeric.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/numeric.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Numeric</title>
+<title>Numeric</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="string.html" title=" String">
-<link rel="next" href="numeric/signed_int.html" title=" Signed
- Integer Number Generators">
+<link rel="prev" href="string.html" title="String">
+<link rel="next" href="numeric/signed_int.html" title="Signed Integer Number Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="string.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="numeric/signed_int.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.numeric"></a> Numeric
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Numeric">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.numeric"></a><a class="link" href="numeric.html" title="Numeric"> Numeric</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="numeric/signed_int.html"> Signed
Integer Number Generators</a></span></dt>
@@ -43,13 +39,16 @@
integer and floating point types. It includes the signed integer, unsigned
integer, and floating point number generators.
</p>
-<a name="spirit.karma.reference.numeric.module_header"></a><h5>
-<a name="id514368"></a>
- Module Header
- </h5>
+<a name="spirit.karma.reference.numeric.module_header"></a><h6>
+<a name="id1206905"></a>
+ <a class="link" href="numeric.html#spirit.karma.reference.numeric.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/numeric.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_numeric</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/floating_point.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/floating_point.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/floating_point.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Floating
- Point Number Generators</title>
+<title>Floating Point Number Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric.html" title=" Numeric">
-<link rel="previous" href="unsigned_int.html" title=" Unsigned
- Integer Number Generators">
-<link rel="next" href="../directive.html" title="Directive">
+<link rel="up" href="../numeric.html" title="Numeric">
+<link rel="prev" href="unsigned_int.html" title="Unsigned Integer Number Generators">
+<link rel="next" href="../stream.html" title="Stream">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,20 +20,16 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.numeric.floating_point"></a><a href="floating_point.html" title=" Floating
- Point Number Generators"> Floating
+<div class="section" title="Floating Point Number Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.numeric.floating_point"></a><a class="link" href="floating_point.html" title="Floating Point Number Generators"> Floating
Point Number Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<a name="spirit.karma.reference.numeric.floating_point.description"></a><h6>
-<a name="id526254"></a>
- Description
+<a name="id1222239"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.description">Description</a>
</h6>
<p>
The floating point number generators described in this section are:
@@ -47,109 +41,157 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">num</span></tt>,
- where <tt class="computeroutput"><span class="identifier">num</span></tt> can
- be a <tt class="computeroutput"><span class="keyword">float</span></tt>, <tt class="computeroutput"><span class="keyword">double</span></tt>, or <tt class="computeroutput"><span class="keyword">long</span>
- <span class="keyword">double</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">float</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">num</span></code>,
+ where <code class="computeroutput"><span class="identifier">num</span></code> can
+ be a <code class="computeroutput"><span class="keyword">float</span></code>, <code class="computeroutput"><span class="keyword">double</span></code>, or <code class="computeroutput"><span class="keyword">long</span>
+ <span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">float</span></code>
as given by the mandatory attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="keyword">float</span></tt>, if an
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="keyword">float</span></code>, if an
attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">double_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">double</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">double_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">double</span></code>
as given by the mandatory attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="keyword">double</span></tt>, if
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="keyword">double</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_double</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">double</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">double</span></code>
as given by the mandatory attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="keyword">double</span></tt>, if
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="keyword">double</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
@@ -157,18 +199,22 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="identifier">Num</span></tt>
- using the provided policies <tt class="computeroutput"><span class="identifier">Policies</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="identifier">Num</span></code>
+ using the provided policies <code class="computeroutput"><span class="identifier">Policies</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
@@ -176,79 +222,82 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt> using
- the provided policies <tt class="computeroutput"><span class="identifier">Policies</span></tt>,
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code> using
+ the provided policies <code class="computeroutput"><span class="identifier">Policies</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
These can be used to flexibly format any floating point number of any
- compatible type (for more information about the requirements, see below).
+ compatible type (for more information about the requirements, see <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.additional_requirements">below</a>).
</p>
<p>
The floating point number generators are very fast. For measurement results
comparing the <span class="emphasis"><em>Spirit.Karma</em></span> floating point number
generators with equivalent constructs provided by other libraries see
- the section <a href="../../performance_measurements/numeric_performance/double_performance.html" title="
- Comparing the performance of a single double_ generator">Performance
+ the section <a class="link" href="../../performance_measurements/numeric_performance/double_performance.html" title="Comparing the performance of a single double_ generator">Performance
of Floating Point Numeric Generators</a>
</p>
<a name="spirit.karma.reference.numeric.floating_point.header"></a><h6>
-<a name="id527168"></a>
- Header
+<a name="id1222899"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/numeric/real.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_real</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.numeric.floating_point.model_of"></a><h6>
-<a name="id527283"></a>
- <a href="floating_point.html#spirit.karma.reference.numeric.floating_point.model_of">Model
+<a name="id1222973"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span></code></span></dt>
<dd><p>
- Numeric literal, any floating point value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literal, any floating point value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a floating point value of type
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Num</span></code></span></dt>
<dd><p>
- Type of <tt class="computeroutput"><span class="identifier">num</span></tt>: any
+ Type of <code class="computeroutput"><span class="identifier">num</span></code>: any
floating point type
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.numeric.floating_point.expression_semantics"></a><h6>
-<a name="id527424"></a>
- <a href="floating_point.html#spirit.karma.reference.numeric.floating_point.expression_semantics">Expression
+<a name="id1223073"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -256,33 +305,41 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the floating point literal <tt class="computeroutput"><span class="identifier">num</span></tt>
- using the default formatting (no trailing zeros, <tt class="computeroutput"><span class="identifier">fixed</span></tt> representation for numbers
- <tt class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the floating point literal <code class="computeroutput"><span class="identifier">num</span></code>
+ using the default formatting (no trailing zeros, <code class="computeroutput"><span class="identifier">fixed</span></code> representation for numbers
+ <code class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span>
<span class="special"><=</span> <span class="number">1e5</span>
<span class="special">&&</span> <span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special">></span>
- <span class="number">1e-3</span></tt>, scientific representation
+ <span class="number">1e-3</span></code>, scientific representation
otherwise, 3 fractional digits, sign is only printed for negative
literals). This generator never fails (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">float_</span>
@@ -290,22 +347,24 @@
<span class="identifier">long_double</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the floating point number provided by a mandatory attribute
- using the default formatting (no trailing zeros, <tt class="computeroutput"><span class="identifier">fixed</span></tt> representation for numbers
- <tt class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span>
+ using the default formatting (no trailing zeros, <code class="computeroutput"><span class="identifier">fixed</span></code> representation for numbers
+ <code class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span>
<span class="special"><=</span> <span class="number">1e5</span>
<span class="special">&&</span> <span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special">></span>
- <span class="number">1e-3</span></tt>, scientific representation
+ <span class="number">1e-3</span></code>, scientific representation
otherwise, 3 fractional digits, sign is only printed for negative
literals). This generator never fails (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span>
@@ -313,28 +372,30 @@
<span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the floating point number provided by the immediate
literal value the generator is initialized from using the default
- formatting (no trailing zeros, <tt class="computeroutput"><span class="identifier">fixed</span></tt>
- representation for numbers <tt class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special"><=</span>
+ formatting (no trailing zeros, <code class="computeroutput"><span class="identifier">fixed</span></code>
+ representation for numbers <code class="computeroutput"><span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special"><=</span>
<span class="number">1e5</span> <span class="special">&&</span>
<span class="identifier">fabs</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span>
- <span class="special">></span> <span class="number">1e-3</span></tt>,
+ <span class="special">></span> <span class="number">1e-3</span></code>,
scientific representation otherwise, 3 fractional digits, sign
is only printed for negative literals). If this generator has
an associated attribute it succeeds only as long as the attribute
is equal to the immediate literal (except if the underlying output
stream reports an error). Otherwise this generator fails and
does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- All generators listed in the table above (except <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>) are predefined specializations of the
- <tt class="computeroutput"><span class="identifier">real_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span><span class="special">></span></tt>
+ All generators listed in the table above (except <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>) are predefined specializations of the
+ <code class="computeroutput"><span class="identifier">real_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span><span class="special">></span></code>
basic floating point number generator type described below. It is possible
to directly use this type to create floating point generators using a
wide range of formatting options.
@@ -345,16 +406,20 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
@@ -362,60 +427,127 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generate the floating point number of type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- provided by a mandatory attribute using the specified <tt class="computeroutput"><span class="identifier">Policies</span></tt>. This generator never
+ </td>
+<td>
+ <p>
+ Generate the floating point number of type <code class="computeroutput"><span class="identifier">Num</span></code>
+ provided by a mandatory attribute using the specified <code class="computeroutput"><span class="identifier">Policies</span></code>. This generator never
fails (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
+<a name="spirit.karma.reference.numeric.floating_point.template_parameters"></a><h6>
+<a name="id1223616"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.template_parameters">Template
+ parameters</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Parameter
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+<th>
+ <p>
+ Default
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The type of the floating point number to generate
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Policies</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The policies to use while converting the floatng point number
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">real_policies</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span></code>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
<p>
- For more information about the type <tt class="computeroutput"><span class="identifier">Policies</span></tt>
- see below).
+ For more information about the type <code class="computeroutput"><span class="identifier">Policies</span></code>
+ see <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.floating_point_formatting_policies">below</a>).
</p>
<a name="spirit.karma.reference.numeric.floating_point.additional_requirements"></a><h6>
-<a name="id528214"></a>
- <a href="floating_point.html#spirit.karma.reference.numeric.floating_point.additional_requirements">Additional
+<a name="id1223769"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.additional_requirements">Additional
Requirements</a>
</h6>
<p>
The following list enumerate the requirements which must be met in order
- to use a certain type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- to instantiate a <tt class="computeroutput"><span class="identifier">real_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span><span class="special">></span></tt>.
+ to use a certain type <code class="computeroutput"><span class="identifier">Num</span></code>
+ to instantiate a <code class="computeroutput"><span class="identifier">real_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Policies</span><span class="special">></span></code>.
</p>
<p>
- In order to be usable as the first template parameter for <tt class="computeroutput"><span class="identifier">real_generator</span><span class="special"><></span></tt>
- the type <tt class="computeroutput"><span class="identifier">Num</span></tt> must have
+ In order to be usable as the first template parameter for <code class="computeroutput"><span class="identifier">real_generator</span><span class="special"><></span></code>
+ the type <code class="computeroutput"><span class="identifier">Num</span></code> must have
defined:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- comparison operators for: <tt class="computeroutput"><span class="special"><</span></tt>,
- <tt class="computeroutput"><span class="special"><=</span></tt>, <tt class="computeroutput"><span class="special">==</span></tt>,
- <tt class="computeroutput"><span class="special">!=</span></tt>, <tt class="computeroutput"><span class="special">></span></tt>,
- and <tt class="computeroutput"><span class="special">>=</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ comparison operators for: <code class="computeroutput"><span class="special"><</span></code>,
+ <code class="computeroutput"><span class="special"><=</span></code>, <code class="computeroutput"><span class="special">==</span></code>,
+ <code class="computeroutput"><span class="special">!=</span></code>, <code class="computeroutput"><span class="special">></span></code>,
+ and <code class="computeroutput"><span class="special">>=</span></code>
</li>
-<li>
- numeric operators for: <tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, <tt class="computeroutput"><span class="special">/</span></tt>,
- <tt class="computeroutput"><span class="special">*</span></tt>, and <tt class="computeroutput"><span class="special">%</span></tt>
+<li class="listitem">
+ numeric operators for: <code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, <code class="computeroutput"><span class="special">/</span></code>,
+ <code class="computeroutput"><span class="special">*</span></code>, and <code class="computeroutput"><span class="special">%</span></code>
</li>
-<li>
- functions implementing the interface and the semantics of: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">log10</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">modf</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></tt>, and <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></tt>.
+<li class="listitem">
+ functions implementing the interface and the semantics of: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">log10</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">modf</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></code>, and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></code>.
These need to be defined in a way so that they will be found using
argument dependent lookup (ADL).
</li>
-<li>
- a valid specialization of the type <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">numeric_limits</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span></tt> allowing for numeric property inspection.
+<li class="listitem">
+ a valid specialization of the type <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">numeric_limits</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span></code> allowing for numeric property inspection.
</li>
</ul></div>
<a name="spirit.karma.reference.numeric.floating_point.attributes"></a><h6>
-<a name="id528687"></a>
- Attributes
+<a name="id1224081"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -423,85 +555,117 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">double_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">double_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">double_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_double</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_double</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
@@ -509,15 +673,17 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">real_generator</span><span class="special"><</span>
@@ -525,33 +691,35 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.numeric.floating_point.floating_point_formatting_policies"></a><h6>
-<a name="id529314"></a>
- <a href="floating_point.html#spirit.karma.reference.numeric.floating_point.floating_point_formatting_policies">Floating
+<a name="id1224543"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.floating_point_formatting_policies">Floating
Point Formatting Policies</a>
</h6>
<p>
- If special formatting of a floating point number is needed, just overload
- the policy class <tt class="computeroutput"><span class="identifier">real_policies</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span></tt> and use it as a template parameter
- to the <tt class="computeroutput"><span class="identifier">real_generator</span><span class="special"><></span></tt> floating point generator. For
+ If special formatting of a floating point number is needed, overload
+ the policy class <code class="computeroutput"><span class="identifier">real_policies</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span></code> and use it as a template parameter
+ to the <code class="computeroutput"><span class="identifier">real_generator</span><span class="special"><></span></code> floating point generator. For
instance:
</p>
<pre class="programlisting"><span class="comment">// define a new floating point formatting policy
-</span><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">T</span><span class="special">></span>
-<span class="keyword">struct</span> <span class="identifier">scientific_policy</span> <span class="special">:</span> <span class="identifier">real_policies</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span>
+</span><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Num</span><span class="special">></span>
+<span class="keyword">struct</span> <span class="identifier">scientific_policy</span> <span class="special">:</span> <span class="identifier">real_policies</span><span class="special"><</span><span class="identifier">Num</span><span class="special">></span>
<span class="special">{</span>
<span class="comment">// we want the numbers always to be in scientific format
-</span> <span class="keyword">static</span> <span class="keyword">int</span> <span class="identifier">floatfield</span><span class="special">(</span><span class="identifier">T</span> <span class="identifier">n</span><span class="special">)</span> <span class="special">{</span> <span class="keyword">return</span> <span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span><span class="special">;</span> <span class="special">}</span>
+</span> <span class="keyword">static</span> <span class="keyword">int</span> <span class="identifier">floatfield</span><span class="special">(</span><span class="identifier">Num</span> <span class="identifier">n</span><span class="special">)</span> <span class="special">{</span> <span class="keyword">return</span> <span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span><span class="special">;</span> <span class="special">}</span>
<span class="special">};</span>
<span class="comment">// define a new generator type based on the new policy
@@ -563,14 +731,14 @@
</span><span class="identifier">generate</span><span class="special">(</span><span class="identifier">sink</span><span class="special">,</span> <span class="identifier">scientific</span><span class="special">,</span> <span class="number">0.1</span><span class="special">);</span> <span class="comment">// will output: 1.0e-01
</span></pre>
<p>
- The template parameter <tt class="computeroutput"><span class="identifier">T</span></tt>
+ The template parameter <code class="computeroutput"><span class="identifier">Num</span></code>
should be the type to be formatted using the overloaded policy type.
- At the same time <tt class="computeroutput"><span class="identifier">T</span></tt> will
- be used as the attribute type of the created floating point generator.
+ At the same time <code class="computeroutput"><span class="identifier">Num</span></code>
+ will be used as the attribute type of the created floating point generator.
</p>
<a name="spirit.karma.reference.numeric.floating_point.floating_point_formatting_policy_expression_semantics"></a><h6>
-<a name="id529818"></a>
- <a href="floating_point.html#spirit.karma.reference.numeric.floating_point.floating_point_formatting_policy_expression_semantics">Floating
+<a name="id1224899"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.floating_point_formatting_policy_expression_semantics">Floating
Point Formatting Policy Expression Semantics</a>
</h6>
<p>
@@ -583,355 +751,359 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Inserter</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">OutputIterator</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Policies</span><span class="special">></span>
-<span class="keyword">bool</span> <span class="identifier">call</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span>
+<span class="keyword">bool</span> <span class="identifier">call</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span>
<span class="special">,</span> <span class="identifier">Policies</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">p</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This is the main function used to generate the output for a floating
point number. It is called by the real generator in order to
perform the conversion. In theory all of the work can be implemented
here, but it is the easiest to use existing functionality provided
- by the type specified by the template parameter <tt class="computeroutput"><span class="identifier">Inserter</span></tt>. The default implementation
+ by the type specified by the template parameter <code class="computeroutput"><span class="identifier">Inserter</span></code>. The default implementation
of this functions is:
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Inserter</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">OutputIterator</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Policies</span><span class="special">></span>
<span class="keyword">static</span> <span class="keyword">bool</span>
-<span class="identifier">call</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span><span class="special">,</span> <span class="identifier">Policies</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">p</span><span class="special">)</span>
+<span class="identifier">call</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span><span class="special">,</span> <span class="identifier">Policies</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">p</span><span class="special">)</span>
<span class="special">{</span>
<span class="keyword">return</span> <span class="identifier">Inserter</span><span class="special">::</span><span class="identifier">call_n</span><span class="special">(</span><span class="identifier">sink</span><span class="special">,</span> <span class="identifier">n</span><span class="special">,</span> <span class="identifier">p</span><span class="special">);</span>
<span class="special">}</span>
</pre>
<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the floating
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the floating
point number to convert
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">p</span></tt>: the instance
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span></code>: the instance
of the policy type used to instantiate this floating point generator.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
-<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">(</span><span class="identifier">T</span> <span class="identifier">n</span><span class="special">);</span>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">(</span><span class="identifier">Num</span> <span class="identifier">n</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
The default behavior is to not to require generating a sign.
- If the function <tt class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></tt> returns true, then all generated
- numbers will have a sign (<tt class="computeroutput"><span class="char">'+'</span></tt>
- or <tt class="computeroutput"><span class="char">'-'</span></tt>, zeros will
+ If the function <code class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></code> returns true, then all generated
+ numbers will have a sign (<code class="computeroutput"><span class="char">'+'</span></code>
+ or <code class="computeroutput"><span class="char">'-'</span></code>, zeros will
have a space instead of a sign).
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt> is the floating
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code> is the floating
point number to output. This can be used to adjust the required
behavior depending on the value of this number.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
-<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">bool</span> <span class="identifier">trailing_zeros</span><span class="special">(</span><span class="identifier">T</span> <span class="identifier">n</span><span class="special">);</span>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">bool</span> <span class="identifier">trailing_zeros</span><span class="special">(</span><span class="identifier">Num</span> <span class="identifier">n</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
Return whether trailing zero digits have to be emitted in the
fractional part of the output. If set, this flag instructs the
floating point generator to emit trailing zeros up to the required
- precision digits (as returned by the <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt> function).
+ precision digits (as returned by the <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code> function).
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt> is the floating
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code> is the floating
point number to output. This can be used to adjust the required
behavior depending on the value of this number.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
-<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">int</span> <span class="identifier">floatfield</span><span class="special">(</span><span class="identifier">T</span> <span class="identifier">n</span><span class="special">);</span>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">int</span> <span class="identifier">floatfield</span><span class="special">(</span><span class="identifier">Num</span> <span class="identifier">n</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
Decide, which representation type to use in the generated output.
</p>
-<p>
+ <p>
By default all numbers having an absolute value of zero or in
- between <tt class="computeroutput"><span class="number">0.001</span></tt> and
- <tt class="computeroutput"><span class="number">100000</span></tt> will be generated
+ between <code class="computeroutput"><span class="number">0.001</span></code> and
+ <code class="computeroutput"><span class="number">100000</span></code> will be generated
using the fixed format, all others will be generated using the
scientific representation.
</p>
-<p>
- The <tt class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></tt> can be used to force the output
+ <p>
+ The <code class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></code> can be used to force the output
of trailing zeros in the fractional part up to the number of
- digits returned by the <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt> member function. The default
+ digits returned by the <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code> member function. The default
is not to generate the trailing zeros.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the floating
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the floating
point number to output. This can be used to adjust the formatting
flags depending on the value of this number.
</p>
-<p>
- The return value has to be either <tt class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span></tt>
- (generate floating point values in scientific notation) or <tt class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">fixed</span></tt> (generate floating point
+ <p>
+ The return value has to be either <code class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span></code>
+ (generate floating point values in scientific notation) or <code class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">fixed</span></code> (generate floating point
values in fixed-point notation).
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
-<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">unsigned</span> <span class="identifier">precision</span><span class="special">(</span><span class="identifier">T</span> <span class="identifier">n</span><span class="special">);</span>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">unsigned</span> <span class="identifier">precision</span><span class="special">(</span><span class="identifier">Num</span> <span class="identifier">n</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
Return the maximum number of decimal digits to generate in the
fractional part of the output.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the floating
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the floating
point number to output. This can be used to adjust the required
precision depending on the value of this number. If the trailing
zeros flag is specified the fractional part of the output will
be 'filled' with zeros, if appropriate.
</p>
-<p>
- <span class="bold"><b>Note:</b></span> If the trailing_zeros
+ <p>
+ <span class="bold"><strong>Note:</strong></span> If the trailing_zeros
flag is not in effect additional semantics apply. See the description
- for the <tt class="computeroutput"><span class="identifier">fraction_part</span><span class="special">()</span></tt> function below. Moreover, this
- precision will be limited to the value of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">numeric_limits</span><span class="special"><</span><span class="identifier">T</span><span class="special">>::</span><span class="identifier">digits10</span>
- <span class="special">+</span> <span class="number">1</span></tt>.
+ for the <code class="computeroutput"><span class="identifier">fraction_part</span><span class="special">()</span></code> function below. Moreover, this
+ precision will be limited to the value of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">numeric_limits</span><span class="special"><</span><span class="identifier">T</span><span class="special">>::</span><span class="identifier">digits10</span>
+ <span class="special">+</span> <span class="number">1</span></code>.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">bool</span> <span class="identifier">ForceSign</span><span class="special">,</span>
<span class="keyword">typename</span> <span class="identifier">OutputIterator</span><span class="special">></span>
<span class="keyword">bool</span> <span class="identifier">integer_part</span><span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span>
- <span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span><span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">sign</span><span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">);</span>
+ <span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span><span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">sign</span><span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called to generate the integer part of the floating
point number.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the absolute
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the absolute
value of the integer part of the floating point number to convert
(always non-negative)
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sign</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sign</span></code>: is the
sign of the overall floating point number to convert.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">force_sign</span></tt>: is
+ <p>
+ <code class="computeroutput"><span class="identifier">force_sign</span></code>: is
a flag whether a sign has to be generated even for non- negative
numbers (this is the same as has been returned from the function
- <tt class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></tt>
+ <code class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></code>
described above)
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">OutputIterator</span><span class="special">></span>
-<span class="keyword">bool</span> <span class="identifier">dot</span><span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span><span class="special">,</span>
+<span class="keyword">bool</span> <span class="identifier">dot</span><span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span><span class="special">,</span>
<span class="keyword">unsigned</span> <span class="identifier">precision</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called to generate the decimal point.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: The fractional
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: The fractional
part of the floating point number to convert. Note that this
number is scaled such, that it represents the number of units
- which correspond to the value returned from the <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt>
- function earlier. I.e. a fractional part of <tt class="computeroutput"><span class="number">0.01234</span></tt>
- is represented as <tt class="computeroutput"><span class="number">1234</span></tt>
- when the function <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt> returned <tt class="computeroutput"><span class="number">5</span></tt>.
- </p>
-<p>
- <tt class="computeroutput"><span class="identifier">precision</span></tt>: The
- number of digits to emit as returned by the function <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt>
+ which correspond to the value returned from the <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code>
+ function earlier. I.e. a fractional part of <code class="computeroutput"><span class="number">0.01234</span></code>
+ is represented as <code class="computeroutput"><span class="number">1234</span></code>
+ when the function <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code> returned <code class="computeroutput"><span class="number">5</span></code>.
+ </p>
+ <p>
+ <code class="computeroutput"><span class="identifier">precision</span></code>: The
+ number of digits to emit as returned by the function <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code>
described above
</p>
-<p>
+ <p>
This is given to allow to decide, whether a decimal point has
to be generated at all.
</p>
-<p>
- <span class="bold"><b>Note:</b></span> If the <tt class="computeroutput"><span class="identifier">trailing_zeros</span></tt>
+ <p>
+ <span class="bold"><strong>Note:</strong></span> If the <code class="computeroutput"><span class="identifier">trailing_zeros</span></code>
flag is not in effect additional comments apply. See the description
- for the <tt class="computeroutput"><span class="identifier">fraction_part</span><span class="special">()</span></tt> function below.
+ for the <code class="computeroutput"><span class="identifier">fraction_part</span><span class="special">()</span></code> function below.
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">OutputIterator</span><span class="special">></span>
-<span class="keyword">bool</span> <span class="identifier">fraction_part</span><span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span>
+<span class="keyword">bool</span> <span class="identifier">fraction_part</span><span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span>
<span class="special">,</span> <span class="keyword">unsigned</span> <span class="identifier">adjprec</span><span class="special">,</span> <span class="keyword">unsigned</span> <span class="identifier">precision</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called to generate the fractional part of the
number.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: The fractional
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: The fractional
part of the floating point number to convert. Note that this
number is scaled such, that it represents the number of units
- which correspond to the value returned from the <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt>
- function earlier. I.e. a fractional part of <tt class="computeroutput"><span class="number">0.01234</span></tt>
- is represented as <tt class="computeroutput"><span class="number">1234</span></tt>
- when the function <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt> returned <tt class="computeroutput"><span class="number">5</span></tt>.
+ which correspond to the value returned from the <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code>
+ function earlier. I.e. a fractional part of <code class="computeroutput"><span class="number">0.01234</span></code>
+ is represented as <code class="computeroutput"><span class="number">1234</span></code>
+ when the function <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code> returned <code class="computeroutput"><span class="number">5</span></code>.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">adjprec</span></tt>: The
+ <p>
+ <code class="computeroutput"><span class="identifier">adjprec</span></code>: The
corrected number of digits to emit (see note below)
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">precision</span></tt>: The
- number of digits to emit as returned by the function <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt>
+ <p>
+ <code class="computeroutput"><span class="identifier">precision</span></code>: The
+ number of digits to emit as returned by the function <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code>
described above
</p>
-<p>
- <span class="bold"><b>Note:</b></span> If <tt class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></tt> returns <tt class="computeroutput"><span class="keyword">false</span></tt>
- the <tt class="computeroutput"><span class="identifier">adjprec</span></tt> parameter
- will have been corrected from the value the <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt> function returned earlier (defining
+ <p>
+ <span class="bold"><strong>Note:</strong></span> If <code class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></code> returns <code class="computeroutput"><span class="keyword">false</span></code>
+ the <code class="computeroutput"><span class="identifier">adjprec</span></code> parameter
+ will have been corrected from the value the <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code> function returned earlier (defining
the maximal number of fractional digits) in the sense, that it
takes into account trailing zeros. I.e. a floating point number
- <tt class="computeroutput"><span class="number">0.0123</span></tt> and a value
- of <tt class="computeroutput"><span class="number">5</span></tt> returned from
- <tt class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></tt>
+ <code class="computeroutput"><span class="number">0.0123</span></code> and a value
+ of <code class="computeroutput"><span class="number">5</span></code> returned from
+ <code class="computeroutput"><span class="identifier">precision</span><span class="special">()</span></code>
will result in:
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></tt> returned <tt class="computeroutput"><span class="keyword">false</span></tt>:
- <tt class="computeroutput"><span class="identifier">n</span></tt> will be <tt class="computeroutput"><span class="number">123</span></tt>, and <tt class="computeroutput"><span class="identifier">adjprec</span></tt>
- will be <tt class="computeroutput"><span class="number">4</span></tt> (as we
- need to print <tt class="computeroutput"><span class="number">0123</span></tt>)
- </p>
-<p>
- <tt class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></tt> returned <tt class="computeroutput"><span class="keyword">true</span></tt>:
- <tt class="computeroutput"><span class="identifier">n</span></tt> will be <tt class="computeroutput"><span class="number">1230</span></tt>, and <tt class="computeroutput"><span class="identifier">adjprec</span></tt>
- will be <tt class="computeroutput"><span class="number">5</span></tt> (as we
- need to print <tt class="computeroutput"><span class="number">01230</span></tt>)
+ <p>
+ <code class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></code> returned <code class="computeroutput"><span class="keyword">false</span></code>:
+ <code class="computeroutput"><span class="identifier">n</span></code> will be <code class="computeroutput"><span class="number">123</span></code>, and <code class="computeroutput"><span class="identifier">adjprec</span></code>
+ will be <code class="computeroutput"><span class="number">4</span></code> (as we
+ need to print <code class="computeroutput"><span class="number">0123</span></code>)
+ </p>
+ <p>
+ <code class="computeroutput"><span class="identifier">trailing_zeros</span><span class="special">()</span></code> returned <code class="computeroutput"><span class="keyword">true</span></code>:
+ <code class="computeroutput"><span class="identifier">n</span></code> will be <code class="computeroutput"><span class="number">1230</span></code>, and <code class="computeroutput"><span class="identifier">adjprec</span></code>
+ will be <code class="computeroutput"><span class="number">5</span></code> (as we
+ need to print <code class="computeroutput"><span class="number">01230</span></code>)
</p>
-<p>
+ <p>
The missing preceding zeros in the fractional part have to be
supplied by the implementation of this policy function.
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">CharEncoding</span><span class="special">,</span>
@@ -941,156 +1113,162 @@
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called to generate the exponential part of the
- number (this is called only if the <tt class="computeroutput"><span class="identifier">floatfield</span><span class="special">()</span></tt> function returned the <tt class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span></tt> flag).
+ number (this is called only if the <code class="computeroutput"><span class="identifier">floatfield</span><span class="special">()</span></code> function returned the <code class="computeroutput"><span class="identifier">fmtflags</span><span class="special">::</span><span class="identifier">scientific</span></code> flag).
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: The (signed)
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: The (signed)
exponential part of the floating point number to convert.
</p>
-<p>
- The template parameters <tt class="computeroutput"><span class="identifier">CharEncoding</span></tt>
- and <tt class="computeroutput"><span class="identifier">Tag</span></tt> are either
- of the type <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ <p>
+ The template parameters <code class="computeroutput"><span class="identifier">CharEncoding</span></code>
+ and <code class="computeroutput"><span class="identifier">Tag</span></code> are either
+ of the type <code class="computeroutput"><span class="identifier">unused_type</span></code>
or describe the character class and conversion to be applied
- to any output possibly influenced by either the <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>
- or <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt>
+ to any output possibly influenced by either the <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>
+ or <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code>
directives.
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">CharEncoding</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Tag</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">OutputIterator</span><span class="special">></span>
-<span class="keyword">bool</span> <span class="identifier">nan</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span>
+<span class="keyword">bool</span> <span class="identifier">nan</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span>
<span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called whenever the number to print is a non-normal
- floats of type NaN.
+ floating point number of type <code class="computeroutput"><span class="identifier">NaN</span></code>.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the (signed)
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the (signed)
floating point number to convert
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">force_sign</span></tt>: is
+ <p>
+ <code class="computeroutput"><span class="identifier">force_sign</span></code>: is
a flag whether a sign has to be generated even for non- negative
numbers (this is the same as has been returned from the function
- <tt class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></tt>
+ <code class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></code>
described above)
</p>
-<p>
- The template parameters <tt class="computeroutput"><span class="identifier">CharEncoding</span></tt>
- and <tt class="computeroutput"><span class="identifier">Tag</span></tt> are either
- of the type <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ <p>
+ The template parameters <code class="computeroutput"><span class="identifier">CharEncoding</span></code>
+ and <code class="computeroutput"><span class="identifier">Tag</span></code> are either
+ of the type <code class="computeroutput"><span class="identifier">unused_type</span></code>
or describe the character class and conversion to be applied
- to any output possibly influenced by either the <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>
- or <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt>
+ to any output possibly influenced by either the <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>
+ or <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code>
directives.
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">CharEncoding</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Tag</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">OutputIterator</span><span class="special">></span>
-<span class="keyword">bool</span> <span class="identifier">inf</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">T</span> <span class="identifier">n</span>
+<span class="keyword">bool</span> <span class="identifier">inf</span> <span class="special">(</span><span class="identifier">OutputIterator</span><span class="special">&</span> <span class="identifier">sink</span><span class="special">,</span> <span class="identifier">Num</span> <span class="identifier">n</span>
<span class="special">,</span> <span class="keyword">bool</span> <span class="identifier">force_sign</span><span class="special">);</span>
</pre>
<p>
</p>
-</td>
+ </td>
<td>
-<p>
+ <p>
This function is called whenever the number to print is a non-normal
- floats of type Inf.
+ floating point number of type <code class="computeroutput"><span class="identifier">Inf</span></code>.
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">sink</span></tt>: is the
+ <p>
+ <code class="computeroutput"><span class="identifier">sink</span></code>: is the
output iterator to use for generation
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">n</span></tt>: is the (signed)
+ <p>
+ <code class="computeroutput"><span class="identifier">n</span></code>: is the (signed)
floating point number to convert
</p>
-<p>
- <tt class="computeroutput"><span class="identifier">force_sign</span></tt>: is
+ <p>
+ <code class="computeroutput"><span class="identifier">force_sign</span></code>: is
a flag whether a sign has to be generated even for non- negative
numbers (this is the same as has been returned from the function
- <tt class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></tt>
+ <code class="computeroutput"><span class="identifier">force_sign</span><span class="special">()</span></code>
described above)
</p>
-<p>
- The template parameters <tt class="computeroutput"><span class="identifier">CharEncoding</span></tt>
- and <tt class="computeroutput"><span class="identifier">Tag</span></tt> are either
- of the type <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ <p>
+ The template parameters <code class="computeroutput"><span class="identifier">CharEncoding</span></code>
+ and <code class="computeroutput"><span class="identifier">Tag</span></code> are either
+ of the type <code class="computeroutput"><span class="identifier">unused_type</span></code>
or describe the character class and conversion to be applied
- to any output possibly influenced by either the <tt class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></tt>
- or <tt class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></tt>
+ to any output possibly influenced by either the <code class="computeroutput"><span class="identifier">lower</span><span class="special">[]</span></code>
+ or <code class="computeroutput"><span class="identifier">upper</span><span class="special">[]</span></code>
directives.
</p>
-<p>
+ <p>
The return value defines the outcome of the whole generator.
- If it is <tt class="computeroutput"><span class="keyword">false</span></tt>,
- no further output is generated, imediatly returning <tt class="computeroutput"><span class="keyword">false</span></tt> from the calling <tt class="computeroutput"><span class="identifier">real_generator</span></tt> as well. If
- it is <tt class="computeroutput"><span class="keyword">true</span></tt>, normal
+ If it is <code class="computeroutput"><span class="keyword">false</span></code>,
+ no further output is generated, immediatly returning <code class="computeroutput"><span class="keyword">false</span></code> from the calling <code class="computeroutput"><span class="identifier">real_generator</span></code> as well. If
+ it is <code class="computeroutput"><span class="keyword">true</span></code>, normal
output generation continues.
</p>
-</td>
+ </td>
</tr>
</tbody>
</table></div>
-<p>
- The easiest way to implement a proper floating point formatting policy
- is to derive a new type from the the type <tt class="computeroutput"><span class="identifier">real_policies</span><span class="special"><></span></tt> while overriding the aspects
- of the formatting which need to be changed.
- </p>
+<div class="tip" title="Tip"><table border="0" summary="Tip">
+<tr>
+<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
+<th align="left">Tip</th>
+</tr>
+<tr><td align="left" valign="top"><p>
+ The easiest way to implement a proper floating point formatting policy
+ is to derive a new type from the the type <code class="computeroutput"><span class="identifier">real_policies</span><span class="special"><></span></code> while overriding the aspects
+ of the formatting which need to be changed.
+ </p></td></tr>
+</table></div>
<a name="spirit.karma.reference.numeric.floating_point.complexity"></a><h6>
-<a name="id533411"></a>
- Complexity
+<a name="id1227368"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- O(N), where <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ O(N), where <code class="computeroutput"><span class="identifier">N</span></code> is
the number of digits needed to represent the generated floating point
number.
</p>
@@ -1098,8 +1276,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.numeric.floating_point.example"></a><h6>
-<a name="id533462"></a>
- Example
+<a name="id1227402"></a>
+ <a class="link" href="floating_point.html#spirit.karma.reference.numeric.floating_point.example">Example</a>
</h6>
<p>
Some includes:
@@ -1177,7 +1355,7 @@
<p>
</p>
<p>
- Basic usage of an <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ Basic usage of an <code class="computeroutput"><span class="identifier">double_</span></code>
generator:
</p>
<p>
@@ -1210,7 +1388,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/signed_int.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/signed_int.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/signed_int.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Signed
- Integer Number Generators</title>
+<title>Signed Integer Number Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric.html" title=" Numeric">
-<link rel="previous" href="../numeric.html" title=" Numeric">
-<link rel="next" href="unsigned_int.html" title=" Unsigned
- Integer Number Generators">
+<link rel="up" href="../numeric.html" title="Numeric">
+<link rel="prev" href="../numeric.html" title="Numeric">
+<link rel="next" href="unsigned_int.html" title="Unsigned Integer Number Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="../numeric.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unsigned_int.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.numeric.signed_int"></a><a href="signed_int.html" title=" Signed
- Integer Number Generators"> Signed
+<div class="section" title="Signed Integer Number Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.numeric.signed_int"></a><a class="link" href="signed_int.html" title="Signed Integer Number Generators"> Signed
Integer Number Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<a name="spirit.karma.reference.numeric.signed_int.description"></a><h6>
-<a name="id514484"></a>
- Description
+<a name="id1206989"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.description">Description</a>
</h6>
<p>
The signed integer number generators described in this section are:
@@ -47,134 +41,194 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">num</span></tt>,
- where <tt class="computeroutput"><span class="identifier">num</span></tt> can
- be a <tt class="computeroutput"><span class="keyword">short</span></tt>, <tt class="computeroutput"><span class="keyword">int</span></tt>, <tt class="computeroutput"><span class="keyword">long</span></tt>,
- or <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">short_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">short</span> <span class="keyword">int</span></tt> as given by the mandatory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">num</span></code>,
+ where <code class="computeroutput"><span class="identifier">num</span></code> can
+ be a <code class="computeroutput"><span class="keyword">short</span></code>, <code class="computeroutput"><span class="keyword">int</span></code>, <code class="computeroutput"><span class="keyword">long</span></code>,
+ or <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">short_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">short</span> <span class="keyword">int</span></code> as given by the mandatory
attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="keyword">short</span> <span class="keyword">int</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="keyword">short</span> <span class="keyword">int</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">int_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate an <tt class="computeroutput"><span class="keyword">int</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">int_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an <code class="computeroutput"><span class="keyword">int</span></code>
as given by the mandatory attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as an <tt class="computeroutput"><span class="keyword">int</span></tt>, if an
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as an <code class="computeroutput"><span class="keyword">int</span></code>, if an
attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">int</span></tt> as given by the mandatory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">int</span></code> as given by the mandatory
attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">int</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">int</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt> as given by the mandatory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code> as given by the mandatory
attribute
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as an <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as an <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -182,17 +236,21 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate a <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -200,105 +258,108 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt>, if
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
These can be used to flexibly format any integer number of any compatible
- type (for more information about the requirements, see below).
+ type (for more information about the requirements, see <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.additional_requirements">below</a>).
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The generators <tt class="computeroutput"><span class="identifier">long_long</span></tt>
- and <tt class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- are only available on platforms where the preprocessor constant <tt class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></tt> is defined (i.e.
- on platforms having native support for <tt class="computeroutput"><span class="keyword">long</span>
- <span class="keyword">long</span></tt> (64 bit) integer types).
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">long_long</span></code>
+ and <code class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ are only available on platforms where the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></code> is defined (i.e.
+ on platforms having native support for <code class="computeroutput"><span class="keyword">long</span>
+ <span class="keyword">long</span></code> (64 bit) integer types).
</p></td></tr>
</table></div>
<p>
The integer number generators are very fast. For measurement results
comparing the <span class="emphasis"><em>Spirit.Karma</em></span> integer number generators
with equivalent constructs provided by other libraries see the section
- <a href="../../performance_measurements/numeric_performance/int_performance.html" title="
- Comparing the performance of a single int_ generator">Performance
+ <a class="link" href="../../performance_measurements/numeric_performance/int_performance.html" title="Comparing the performance of a single int_ generator">Performance
of Numeric Generators</a>
</p>
<a name="spirit.karma.reference.numeric.signed_int.header"></a><h6>
-<a name="id515663"></a>
- Header
+<a name="id1207842"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/numeric/int.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_int</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.numeric.signed_int.model_of"></a><h6>
-<a name="id515778"></a>
- <a href="signed_int.html#spirit.karma.reference.numeric.signed_int.model_of">Model
+<a name="id1207916"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span></code></span></dt>
<dd><p>
- Numeric literal, any signed integer value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literal, any signed integer value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a signed integer value of type
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Num</span></code></span></dt>
<dd><p>
- Type of <tt class="computeroutput"><span class="identifier">num</span></tt>: any
+ Type of <code class="computeroutput"><span class="identifier">num</span></code>: any
signed integer type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Radix</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Radix</span></code></span></dt>
<dd><p>
A constant integer literal specifying the required radix for the
- output conversion. Valid values are <tt class="computeroutput"><span class="number">2</span></tt>,
- <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>,
- and <tt class="computeroutput"><span class="number">16</span></tt>.
+ output conversion. Valid values are <code class="computeroutput"><span class="number">2</span></code>,
+ <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>,
+ and <code class="computeroutput"><span class="number">16</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">force_sign</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">force_sign</span></code></span></dt>
<dd><p>
A constant boolean literal specifying whether the generated number
- should always have a sign (<tt class="computeroutput"><span class="char">'+'</span></tt>
- for positive numbers, <tt class="computeroutput"><span class="char">'-'</span></tt>
- for negative numbers and a '<tt class="computeroutput"> </tt>' for zero).
+ should always have a sign (<code class="computeroutput"><span class="char">'+'</span></code>
+ for positive numbers, <code class="computeroutput"><span class="char">'-'</span></code>
+ for negative numbers and a '<code class="computeroutput"> </code>' for zero).
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.numeric.signed_int.expression_semantics"></a><h6>
-<a name="id516047"></a>
- <a href="signed_int.html#spirit.karma.reference.numeric.signed_int.expression_semantics">Expression
+<a name="id1210360"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -306,28 +367,36 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the integer literal <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the integer literal <code class="computeroutput"><span class="identifier">num</span></code>
using the default formatting (radix is 10, sign is only printed
for negative literals). This generator never fails (except if
the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">short_</span>
@@ -336,17 +405,19 @@
<span class="identifier">long_long</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the integer provided by a mandatory attribute using
the default formatting (radix is 10, sign is only printed for
negative literals). This generator never fails (except if the
underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span>
@@ -355,8 +426,9 @@
<span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the integer provided by the immediate literal value
the generator is initialized from using the default formatting
(radix is 10, sign is only printed for negative literals). If
@@ -364,13 +436,14 @@
long as the attribute is equal to the immediate literal (except
if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- All generators listed in the table above (except <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>) are predefined specializations of the
- <tt class="computeroutput"><span class="identifier">int_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span><span class="special">></span></tt>
+ All generators listed in the table above (except <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>) are predefined specializations of the
+ <code class="computeroutput"><span class="identifier">int_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span><span class="special">></span></code>
basic integer number generator type described below. It is possible to
directly use this type to create integer generators using a wide range
of formatting options.
@@ -381,17 +454,21 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -399,26 +476,28 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generate the integer of type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- provided by a mandatory attribute using the specified <tt class="computeroutput"><span class="identifier">Radix</span></tt> (possible values are
- <tt class="computeroutput"><span class="number">2</span></tt>, <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>,
- and <tt class="computeroutput"><span class="number">16</span></tt>, the default
- value is <tt class="computeroutput"><span class="number">10</span></tt>). If
- <tt class="computeroutput"><span class="identifier">force_sign</span></tt> is
- <tt class="computeroutput"><span class="keyword">false</span></tt> (the default),
- a sign is only printed for negative literals. If <tt class="computeroutput"><span class="identifier">force_sign</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt>, all numbers will be printed
- using a sign, i.e. <tt class="computeroutput"><span class="char">'-'</span></tt>
- for negative numbers, <tt class="computeroutput"><span class="char">'+'</span></tt>
- for positive numbers, and <tt class="computeroutput"><span class="char">' '</span></tt>
+ </td>
+<td>
+ <p>
+ Generate the integer of type <code class="computeroutput"><span class="identifier">Num</span></code>
+ provided by a mandatory attribute using the specified <code class="computeroutput"><span class="identifier">Radix</span></code> (possible values are
+ <code class="computeroutput"><span class="number">2</span></code>, <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>,
+ and <code class="computeroutput"><span class="number">16</span></code>, the default
+ value is <code class="computeroutput"><span class="number">10</span></code>). If
+ <code class="computeroutput"><span class="identifier">force_sign</span></code> is
+ <code class="computeroutput"><span class="keyword">false</span></code> (the default),
+ a sign is only printed for negative literals. If <code class="computeroutput"><span class="identifier">force_sign</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>, all numbers will be printed
+ using a sign, i.e. <code class="computeroutput"><span class="char">'-'</span></code>
+ for negative numbers, <code class="computeroutput"><span class="char">'+'</span></code>
+ for positive numbers, and <code class="computeroutput"><span class="char">' '</span></code>
for zeros. This generator never fails (except if the underlying
output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -426,87 +505,172 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generate the integer of type <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ </td>
+<td>
+ <p>
+ Generate the integer of type <code class="computeroutput"><span class="identifier">Num</span></code>
provided by the immediate literal value the generator is initialized
- from, using the specified <tt class="computeroutput"><span class="identifier">Radix</span></tt>
- (possible values are <tt class="computeroutput"><span class="number">2</span></tt>,
- <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>, and <tt class="computeroutput"><span class="number">16</span></tt>,
- the default value is <tt class="computeroutput"><span class="number">10</span></tt>).
- If <tt class="computeroutput"><span class="identifier">force_sign</span></tt>
- is <tt class="computeroutput"><span class="keyword">false</span></tt> (the default),
- a sign is only printed for negative literals. If <tt class="computeroutput"><span class="identifier">force_sign</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt>, all numbers will be printed
- using a sign, i.e. <tt class="computeroutput"><span class="char">'-'</span></tt>
- for negative numbers, <tt class="computeroutput"><span class="char">'+'</span></tt>
- for positive numbers, and <tt class="computeroutput"><span class="char">' '</span></tt>
+ from, using the specified <code class="computeroutput"><span class="identifier">Radix</span></code>
+ (possible values are <code class="computeroutput"><span class="number">2</span></code>,
+ <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>, and <code class="computeroutput"><span class="number">16</span></code>,
+ the default value is <code class="computeroutput"><span class="number">10</span></code>).
+ If <code class="computeroutput"><span class="identifier">force_sign</span></code>
+ is <code class="computeroutput"><span class="keyword">false</span></code> (the default),
+ a sign is only printed for negative literals. If <code class="computeroutput"><span class="identifier">force_sign</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>, all numbers will be printed
+ using a sign, i.e. <code class="computeroutput"><span class="char">'-'</span></code>
+ for negative numbers, <code class="computeroutput"><span class="char">'+'</span></code>
+ for positive numbers, and <code class="computeroutput"><span class="char">' '</span></code>
for zeros. If this generator has an associated attribute it succeeds
only as long as the attribute is equal to the immediate literal
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.numeric.signed_int.template_parameters"></a><h6>
+<a name="id1210997"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.template_parameters">Template
+ parameters</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Parameter
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+<th>
+ <p>
+ Default
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The type of the integer to generate
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Radix</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The radix to use while converting the integer
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="number">10</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">force_sign</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If <code class="computeroutput"><span class="keyword">true</span></code>, all numbers
+ will have a sign (space for zero)
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">false</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.numeric.signed_int.additional_requirements"></a><h6>
-<a name="id516978"></a>
- <a href="signed_int.html#spirit.karma.reference.numeric.signed_int.additional_requirements">Additional
+<a name="id1211171"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.additional_requirements">Additional
Requirements</a>
</h6>
<p>
The following lists enumerate the requirements which must be met in order
- to use a certain type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- to instantiate and use a <tt class="computeroutput"><span class="identifier">int_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span><span class="special">></span></tt>.
+ to use a certain type <code class="computeroutput"><span class="identifier">Num</span></code>
+ to instantiate and use a <code class="computeroutput"><span class="identifier">int_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">,</span> <span class="identifier">force_sign</span><span class="special">></span></code>.
</p>
<p>
- If <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt>
- the type <tt class="computeroutput"><span class="identifier">Num</span></tt> must have
+ If <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>
+ the type <code class="computeroutput"><span class="identifier">Num</span></code> must have
defined:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- comparison operators for: <tt class="computeroutput"><span class="special"><</span></tt>,
- <tt class="computeroutput"><span class="special"><=</span></tt>, <tt class="computeroutput"><span class="special">==</span></tt>,
- <tt class="computeroutput"><span class="special">!=</span></tt>, <tt class="computeroutput"><span class="special">></span></tt>,
- and <tt class="computeroutput"><span class="special">>=</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ comparison operators for: <code class="computeroutput"><span class="special"><</span></code>,
+ <code class="computeroutput"><span class="special"><=</span></code>, <code class="computeroutput"><span class="special">==</span></code>,
+ <code class="computeroutput"><span class="special">!=</span></code>, <code class="computeroutput"><span class="special">></span></code>,
+ and <code class="computeroutput"><span class="special">>=</span></code>
</li>
-<li>
- numeric operators for: <tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, <tt class="computeroutput"><span class="special">/</span></tt>,
- <tt class="computeroutput"><span class="special">*</span></tt>, <tt class="computeroutput"><span class="special">%</span></tt>,
- and unary <tt class="computeroutput"><span class="special">-</span></tt>
+<li class="listitem">
+ numeric operators for: <code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, <code class="computeroutput"><span class="special">/</span></code>,
+ <code class="computeroutput"><span class="special">*</span></code>, <code class="computeroutput"><span class="special">%</span></code>,
+ and unary <code class="computeroutput"><span class="special">-</span></code>
</li>
</ul></div>
<p>
- If <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></tt> is <tt class="computeroutput"><span class="keyword">false</span></tt>
- the type <tt class="computeroutput"><span class="identifier">Num</span></tt> must have
+ If <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></code> is <code class="computeroutput"><span class="keyword">false</span></code>
+ the type <code class="computeroutput"><span class="identifier">Num</span></code> must have
defined:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- comparison operators for: <tt class="computeroutput"><span class="special"><</span></tt>,
- <tt class="computeroutput"><span class="special"><=</span></tt>, <tt class="computeroutput"><span class="special">==</span></tt>,
- <tt class="computeroutput"><span class="special">!=</span></tt>, <tt class="computeroutput"><span class="special">></span></tt>,
- and <tt class="computeroutput"><span class="special">>=</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ comparison operators for: <code class="computeroutput"><span class="special"><</span></code>,
+ <code class="computeroutput"><span class="special"><=</span></code>, <code class="computeroutput"><span class="special">==</span></code>,
+ <code class="computeroutput"><span class="special">!=</span></code>, <code class="computeroutput"><span class="special">></span></code>,
+ and <code class="computeroutput"><span class="special">>=</span></code>
</li>
-<li>
- numeric operators for: <tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, <tt class="computeroutput"><span class="special">/</span></tt>,
- <tt class="computeroutput"><span class="special">*</span></tt>, <tt class="computeroutput"><span class="special">%</span></tt>,
- and unary <tt class="computeroutput"><span class="special">-</span></tt>
+<li class="listitem">
+ numeric operators for: <code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, <code class="computeroutput"><span class="special">/</span></code>,
+ <code class="computeroutput"><span class="special">*</span></code>, <code class="computeroutput"><span class="special">%</span></code>,
+ and unary <code class="computeroutput"><span class="special">-</span></code>
</li>
-<li>
+<li class="listitem">
helper functions implementing the interface and the semantics of:
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fabs</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></tt>,
- and <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></tt>. These need to be defined in
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fabs</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></code>,
+ and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></code>. These need to be defined in
a way so that they will be found using argument dependent lookup (ADL).
</li>
</ul></div>
<a name="spirit.karma.reference.numeric.signed_int.attributes"></a><h6>
-<a name="id517668"></a>
- Attributes
+<a name="id1211622"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -514,105 +678,145 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">short_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">short_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">short_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">int_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>, attribute is
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">int_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>, attribute is
mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>, attribute is
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">int_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>, attribute is
optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -620,15 +824,17 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">int_generator</span><span class="special"><</span>
@@ -636,33 +842,35 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.numeric.signed_int.complexity"></a><h6>
-<a name="id518427"></a>
- Complexity
+<a name="id1212179"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- O(N), where <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ O(N), where <code class="computeroutput"><span class="identifier">N</span></code> is
the number of digits needed to represent the generated integer number
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.numeric.signed_int.example"></a><h6>
-<a name="id518476"></a>
- Example
+<a name="id1212210"></a>
+ <a class="link" href="signed_int.html#spirit.karma.reference.numeric.signed_int.example">Example</a>
</h6>
<p>
Some includes:
@@ -740,7 +948,7 @@
<p>
</p>
<p>
- Basic usage of an <tt class="computeroutput"><span class="identifier">int_</span></tt>
+ Basic usage of an <code class="computeroutput"><span class="identifier">int_</span></code>
generator:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/unsigned_int.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/unsigned_int.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/numeric/unsigned_int.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Unsigned
- Integer Number Generators</title>
+<title>Unsigned Integer Number Generators</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../numeric.html" title=" Numeric">
-<link rel="previous" href="signed_int.html" title=" Signed
- Integer Number Generators">
-<link rel="next" href="floating_point.html" title=" Floating
- Point Number Generators">
+<link rel="up" href="../numeric.html" title="Numeric">
+<link rel="prev" href="signed_int.html" title="Signed Integer Number Generators">
+<link rel="next" href="floating_point.html" title="Floating Point Number Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="signed_int.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../numeric.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="floating_point.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.numeric.unsigned_int"></a><a href="unsigned_int.html" title=" Unsigned
- Integer Number Generators"> Unsigned
+<div class="section" title="Unsigned Integer Number Generators">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.numeric.unsigned_int"></a><a class="link" href="unsigned_int.html" title="Unsigned Integer Number Generators"> Unsigned
Integer Number Generators</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<a name="spirit.karma.reference.numeric.unsigned_int.description"></a><h6>
-<a name="id520161"></a>
- Description
+<a name="id1213478"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.description">Description</a>
</h6>
<p>
The signed integer number generators described in this section are:
@@ -48,131 +41,191 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">num</span></tt>,
- where <tt class="computeroutput"><span class="identifier">num</span></tt> can
- be a <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>,
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>,
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>,
- or <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ushort</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">num</span></code>,
+ where <code class="computeroutput"><span class="identifier">num</span></code> can
+ be a <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>,
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>,
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>,
+ or <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ushort</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a short integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ushort</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ushort</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as a short integer, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">uint</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">uint</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an int
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">uint</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">uint</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an int, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a long integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as long integer, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a long long
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an long long, if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -180,17 +233,21 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate an unsigned <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an unsigned <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -198,105 +255,145 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
- </p></td>
-<td><p>
- Generate an unsigned <tt class="computeroutput"><span class="identifier">num</span></tt>
- as a <tt class="computeroutput"><span class="identifier">Num</span></tt>, if
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate an unsigned <code class="computeroutput"><span class="identifier">num</span></code>
+ as a <code class="computeroutput"><span class="identifier">Num</span></code>, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">bin</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">bin</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned integer in binary (base 2) representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">bin</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">bin</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned integer in binary (base 2) representation, if
an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">oct</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">oct</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned integer in octal (base 8) representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">oct</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">oct</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned integer in octal (base 8) representation, if an
attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hex</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hex</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate an unsigned integer in hexadecimal (base 16) representation
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hex</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
- Generate <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hex</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate <code class="computeroutput"><span class="identifier">num</span></code>
as an unsigned integer in hexadecimal (base 16) representation,
if an attribute is supplied it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
These can be used to flexibly format any unsigned integer number of any
- compatible type (for more information about the requirements, see below).
+ compatible type (for more information about the requirements, see <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.additional_requirements">below</a>).
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The generators <tt class="computeroutput"><span class="identifier">ulong_long</span></tt>
- and <tt class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- are only available on platforms where the preprocessor constant <tt class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></tt> is defined (i.e.
- on platforms having native support for <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="keyword">long</span> <span class="keyword">long</span></tt>
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">ulong_long</span></code>
+ and <code class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ are only available on platforms where the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_HAS_LONG_LONG</span></code> is defined (i.e.
+ on platforms having native support for <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">long</span> <span class="keyword">long</span></code>
(64 bit) unsigned integer types).
</p></td></tr>
</table></div>
@@ -304,65 +401,64 @@
The integer number generators are very fast. For measurement results
comparing the <span class="emphasis"><em>Spirit.Karma</em></span> integer number generators
with equivalent constructs provided by other libraries see the section
- <a href="../../performance_measurements/numeric_performance/int_performance.html" title="
- Comparing the performance of a single int_ generator">Performance
+ <a class="link" href="../../performance_measurements/numeric_performance/int_performance.html" title="Comparing the performance of a single int_ generator">Performance
of Numeric Generators</a>
</p>
<a name="spirit.karma.reference.numeric.unsigned_int.header"></a><h6>
-<a name="id521671"></a>
- Header
+<a name="id1214600"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/numeric/uint.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_uint</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.numeric.unsigned_int.model_of"></a><h6>
-<a name="id521785"></a>
- <a href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.model_of">Model
+<a name="id1214675"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">num</span></code></span></dt>
<dd><p>
- Numeric literal, any unsigned integer value, or a <a href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ Numeric literal, any unsigned integer value, or a <a class="link" href="../karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to an unsigned integer value of type
- <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Num</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Num</span></code></span></dt>
<dd><p>
- Type of <tt class="computeroutput"><span class="identifier">num</span></tt>: any
+ Type of <code class="computeroutput"><span class="identifier">num</span></code>: any
unsigned integer type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Radix</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Radix</span></code></span></dt>
<dd><p>
A integer literal specifying the required radix for the output conversion.
- Valid values are <tt class="computeroutput"><span class="number">2</span></tt>,
- <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>,
- and <tt class="computeroutput"><span class="number">16</span></tt>.
+ Valid values are <code class="computeroutput"><span class="number">2</span></code>,
+ <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>,
+ and <code class="computeroutput"><span class="number">16</span></code>.
</p></dd>
</dl>
</div>
<a name="spirit.karma.reference.numeric.unsigned_int.expression_semantics"></a><h6>
-<a name="id522000"></a>
- <a href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.expression_semantics">Expression
+<a name="id1215504"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveGenerator.
+ is not defined in <a class="link" href="../generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -370,28 +466,36 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the integer literal <tt class="computeroutput"><span class="identifier">num</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the integer literal <code class="computeroutput"><span class="identifier">num</span></code>
using the default formatting (radix is 10, sign is only printed
for negative literals). This generator never fails (except if
the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">ushort</span>
@@ -400,16 +504,18 @@
<span class="identifier">ulong_long</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the unsigned integer provided by a mandatory attribute
using the default formatting (radix is 10). This generator never
fails (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">ushort</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span>
@@ -418,19 +524,21 @@
<span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the unsigned integer provided by the immediate literal
value the generator is initialized from using the default formatting
(radix is 10). If this generator has an associated attribute
it succeeds only as long as the attribute is equal to the immediate
literal (except if the underlying output stream reports an error).
Otherwise this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">bin</span>
@@ -438,17 +546,19 @@
<span class="identifier">hex</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the unsigned integer provided by a mandatory attribute
- using the default formatting and the corresponding radix (<tt class="computeroutput"><span class="identifier">bin</span></tt>: radix is 2, <tt class="computeroutput"><span class="identifier">oct</span></tt>: radix is 8, <tt class="computeroutput"><span class="identifier">hex</span></tt>: radix is 16). This generator
+ using the default formatting and the corresponding radix (<code class="computeroutput"><span class="identifier">bin</span></code>: radix is 2, <code class="computeroutput"><span class="identifier">oct</span></code>: radix is 8, <code class="computeroutput"><span class="identifier">hex</span></code>: radix is 16). This generator
never fails (except if the underlying output stream reports an
error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">bin</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span>
@@ -456,24 +566,26 @@
<span class="identifier">hex</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
Generate the unsigned integer provided by the immediate literal
value the generator is initialized from using the default formatting
- and the corresponding radix (<tt class="computeroutput"><span class="identifier">bin</span></tt>:
- radix is 2, <tt class="computeroutput"><span class="identifier">oct</span></tt>:
- radix is 8, <tt class="computeroutput"><span class="identifier">hex</span></tt>:
+ and the corresponding radix (<code class="computeroutput"><span class="identifier">bin</span></code>:
+ radix is 2, <code class="computeroutput"><span class="identifier">oct</span></code>:
+ radix is 8, <code class="computeroutput"><span class="identifier">hex</span></code>:
radix is 16). If this generator has an associated attribute it
succeeds only as long as the attribute is equal to the immediate
literal (except if the underlying output stream reports an error).
Otherwise this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- All generators listed in the table above (except <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>) are predefined specializations of the
- <tt class="computeroutput"><span class="identifier">uint_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">></span></tt>
+ All generators listed in the table above (except <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>) are predefined specializations of the
+ <code class="computeroutput"><span class="identifier">uint_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">></span></code>
basic unsigned integer number generator type described below. It is possible
to directly use this type to create unsigned integer generators using
a wide range of formatting options.
@@ -484,17 +596,21 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -502,20 +618,22 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generate the unsigned integer of type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- provided by a mandatory attribute using the specified <tt class="computeroutput"><span class="identifier">Radix</span></tt> (possible values are
- <tt class="computeroutput"><span class="number">2</span></tt>, <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>,
- and <tt class="computeroutput"><span class="number">16</span></tt>, the default
- value is <tt class="computeroutput"><span class="number">10</span></tt>).This
+ </td>
+<td>
+ <p>
+ Generate the unsigned integer of type <code class="computeroutput"><span class="identifier">Num</span></code>
+ provided by a mandatory attribute using the specified <code class="computeroutput"><span class="identifier">Radix</span></code> (possible values are
+ <code class="computeroutput"><span class="number">2</span></code>, <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>,
+ and <code class="computeroutput"><span class="number">16</span></code>, the default
+ value is <code class="computeroutput"><span class="number">10</span></code>).This
generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -523,79 +641,146 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generate the unsigned integer of type <tt class="computeroutput"><span class="identifier">Num</span></tt>
+ </td>
+<td>
+ <p>
+ Generate the unsigned integer of type <code class="computeroutput"><span class="identifier">Num</span></code>
provided by the immediate literal value the generator is initialized
- from, using the specified <tt class="computeroutput"><span class="identifier">Radix</span></tt>
- (possible values are <tt class="computeroutput"><span class="number">2</span></tt>,
- <tt class="computeroutput"><span class="number">8</span></tt>, <tt class="computeroutput"><span class="number">10</span></tt>, and <tt class="computeroutput"><span class="number">16</span></tt>,
- the default value is <tt class="computeroutput"><span class="number">10</span></tt>).
+ from, using the specified <code class="computeroutput"><span class="identifier">Radix</span></code>
+ (possible values are <code class="computeroutput"><span class="number">2</span></code>,
+ <code class="computeroutput"><span class="number">8</span></code>, <code class="computeroutput"><span class="number">10</span></code>, and <code class="computeroutput"><span class="number">16</span></code>,
+ the default value is <code class="computeroutput"><span class="number">10</span></code>).
If this generator has an associated attribute it succeeds only
as long as the attribute is equal to the immediate literal (except
if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
+</tr>
+</tbody>
+</table></div>
+<a name="spirit.karma.reference.numeric.unsigned_int.template_parameters"></a><h6>
+<a name="id1216158"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.template_parameters">Template
+ parameters</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Parameter
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+<th>
+ <p>
+ Default
+ </p>
+ </th>
+</tr></thead>
+<tbody>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The type of the integer to generate
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Radix</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The radix to use while converting the integer
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="number">10</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.numeric.unsigned_int.additional_requirements"></a><h6>
-<a name="id522934"></a>
- <a href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.additional_requirements">Additional
+<a name="id1216293"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.additional_requirements">Additional
Requirements</a>
</h6>
<p>
The following lists enumerate the requirements which must be met in order
- to use a certain type <tt class="computeroutput"><span class="identifier">Num</span></tt>
- to instantiate and use a <tt class="computeroutput"><span class="identifier">uint_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">></span></tt>.
+ to use a certain type <code class="computeroutput"><span class="identifier">Num</span></code>
+ to instantiate and use a <code class="computeroutput"><span class="identifier">uint_generator</span><span class="special"><</span><span class="identifier">Num</span><span class="special">,</span> <span class="identifier">Radix</span><span class="special">></span></code>.
</p>
<p>
- If <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></tt> is <tt class="computeroutput"><span class="keyword">true</span></tt>
- the type <tt class="computeroutput"><span class="identifier">Num</span></tt> must have
+ If <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></code> is <code class="computeroutput"><span class="keyword">true</span></code>
+ the type <code class="computeroutput"><span class="identifier">Num</span></code> must have
defined:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- comparison operators for: <tt class="computeroutput"><span class="special"><</span></tt>,
- <tt class="computeroutput"><span class="special"><=</span></tt>, <tt class="computeroutput"><span class="special">==</span></tt>,
- <tt class="computeroutput"><span class="special">!=</span></tt>, <tt class="computeroutput"><span class="special">></span></tt>,
- and <tt class="computeroutput"><span class="special">>=</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ comparison operators for: <code class="computeroutput"><span class="special"><</span></code>,
+ <code class="computeroutput"><span class="special"><=</span></code>, <code class="computeroutput"><span class="special">==</span></code>,
+ <code class="computeroutput"><span class="special">!=</span></code>, <code class="computeroutput"><span class="special">></span></code>,
+ and <code class="computeroutput"><span class="special">>=</span></code>
</li>
-<li>
- numeric operators for: <tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, <tt class="computeroutput"><span class="special">/</span></tt>,
- <tt class="computeroutput"><span class="special">*</span></tt>, and <tt class="computeroutput"><span class="special">%</span></tt>
+<li class="listitem">
+ numeric operators for: <code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, <code class="computeroutput"><span class="special">/</span></code>,
+ <code class="computeroutput"><span class="special">*</span></code>, and <code class="computeroutput"><span class="special">%</span></code>
</li>
</ul></div>
<p>
- If <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></tt> is <tt class="computeroutput"><span class="keyword">false</span></tt>
- the type <tt class="computeroutput"><span class="identifier">Num</span></tt> must have
+ If <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">is_integral</span><span class="special"><</span><span class="identifier">Num</span><span class="special">>::</span><span class="identifier">value</span></code> is <code class="computeroutput"><span class="keyword">false</span></code>
+ the type <code class="computeroutput"><span class="identifier">Num</span></code> must have
defined:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- comparison operators for: <tt class="computeroutput"><span class="special"><</span></tt>,
- <tt class="computeroutput"><span class="special"><=</span></tt>, <tt class="computeroutput"><span class="special">==</span></tt>,
- <tt class="computeroutput"><span class="special">!=</span></tt>, <tt class="computeroutput"><span class="special">></span></tt>,
- and <tt class="computeroutput"><span class="special">>=</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ comparison operators for: <code class="computeroutput"><span class="special"><</span></code>,
+ <code class="computeroutput"><span class="special"><=</span></code>, <code class="computeroutput"><span class="special">==</span></code>,
+ <code class="computeroutput"><span class="special">!=</span></code>, <code class="computeroutput"><span class="special">></span></code>,
+ and <code class="computeroutput"><span class="special">>=</span></code>
</li>
-<li>
- numeric operators for: <tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, <tt class="computeroutput"><span class="special">/</span></tt>,
- <tt class="computeroutput"><span class="special">*</span></tt>, and <tt class="computeroutput"><span class="special">%</span></tt>
+<li class="listitem">
+ numeric operators for: <code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, <code class="computeroutput"><span class="special">/</span></code>,
+ <code class="computeroutput"><span class="special">*</span></code>, and <code class="computeroutput"><span class="special">%</span></code>
</li>
-<li>
+<li class="listitem">
helper functions implementing the interface and the semantics of:
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></tt>, <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></tt>,
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></tt>, and <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></tt>.
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">fmod</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pow</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">lround</span></code>, <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ltrunc</span></code>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">floor</span></code>, and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ceil</span></code>.
These need to be defined in a way so that they will be found using
argument dependent lookup (ADL).
</li>
</ul></div>
<a name="spirit.karma.reference.numeric.unsigned_int.attributes"></a><h6>
-<a name="id523567"></a>
- Attributes
+<a name="id1216707"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -603,107 +788,147 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ushort</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ushort</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ushort</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ushort</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">uint</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">uint</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">uint</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">uint</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>, attribute is mandatory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>, attribute is mandatory
(otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>, attribute is optional,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_long</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>, attribute is optional,
if it is supplied, the generator compares the attribute with
- <tt class="computeroutput"><span class="identifier">num</span></tt> and succeeds
+ <code class="computeroutput"><span class="identifier">num</span></code> and succeeds
only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">bin</span>
@@ -711,15 +936,17 @@
<span class="identifier">hex</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>,
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>,
attribute is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">bin</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span>
@@ -727,17 +954,19 @@
<span class="identifier">hex</span><span class="special">(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>,
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>,
attribute is optional, if it is supplied, the generator compares
- the attribute with <tt class="computeroutput"><span class="identifier">num</span></tt>
+ the attribute with <code class="computeroutput"><span class="identifier">num</span></code>
and succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -745,15 +974,17 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">uint_generator</span><span class="special"><</span>
@@ -761,33 +992,35 @@
<span class="special">>()(</span><span class="identifier">num</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Num</span></tt>, attribute
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Num</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">num</span></tt> and
+ with <code class="computeroutput"><span class="identifier">num</span></code> and
succeeds only if both are equal, failing otherwise.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.karma.reference.numeric.unsigned_int.complexity"></a><h6>
-<a name="id524530"></a>
- Complexity
+<a name="id1217416"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- O(N), where <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ O(N), where <code class="computeroutput"><span class="identifier">N</span></code> is
the number of digits needed to represent the generated integer number
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.numeric.unsigned_int.example"></a><h6>
-<a name="id524579"></a>
- Example
+<a name="id1217447"></a>
+ <a class="link" href="unsigned_int.html#spirit.karma.reference.numeric.unsigned_int.example">Example</a>
</h6>
<p>
Some includes:
@@ -865,7 +1098,7 @@
<p>
</p>
<p>
- Basic usage of an <tt class="computeroutput"><span class="identifier">uint</span></tt>
+ Basic usage of an <code class="computeroutput"><span class="identifier">uint</span></code>
generator:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Operator</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="directive/omit.html" title=" Consume Attribute
- (omit[])">
-<link rel="next" href="operator/sequence.html" title=" Sequences
- (operator<<())">
+<link rel="prev" href="directive/omit.html" title="Consume Attribute (omit[])">
+<link rel="next" href="operator/sequence.html" title="Sequences (operator<<())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,47 +22,47 @@
<div class="spirit-nav">
<a accesskey="p" href="directive/omit.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="operator/sequence.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.operator"></a>Operator
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Operator">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.operator"></a><a class="link" href="operator.html" title="Operator">Operator</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="operator/sequence.html"> Sequences
- (<tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>)</a></span></dt>
+ (<code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>)</a></span></dt>
<dt><span class="section"><a href="operator/alternative.html"> Alternatives
- (<tt class="computeroutput"><span class="keyword">operator</span><span class="special">|()</span></tt>)</a></span></dt>
+ (<code class="computeroutput"><span class="keyword">operator</span><span class="special">|()</span></code>)</a></span></dt>
<dt><span class="section"><a href="operator/kleene.html"> Kleene Star
- (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">*()</span></tt>)</a></span></dt>
+ (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">*()</span></code>)</a></span></dt>
<dt><span class="section"><a href="operator/plus.html"> Plus (unary
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span></tt>)</a></span></dt>
-<dt><span class="section"> Lists (operator%())</span></dt>
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span></code>)</a></span></dt>
+<dt><span class="section"> Lists (operator%()
)</span></dt>
<dt><span class="section"><a href="operator/optional.html"> Optional
- (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">-()</span></tt>)</a></span></dt>
+ (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">-()</span></code>)</a></span></dt>
<dt><span class="section"><a href="operator/and_predicate.html"> And
- Predicate (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></tt>)</a></span></dt>
+ Predicate (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></code>)</a></span></dt>
<dt><span class="section"><a href="operator/not_predicate.html"> Not
- Predicate (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></tt>)</a></span></dt>
+ Predicate (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></code>)</a></span></dt>
</dl></div>
<p>
This module includes different generators which get instantiated if one
of the overloaded operators is used with more primitive generator constructs.
- It includes sequences (<tt class="computeroutput"><span class="special"><<</span></tt>),
- alternatives (<tt class="computeroutput"><span class="special">|</span></tt>), Kleene star
- (unary <tt class="computeroutput"><span class="special">*</span></tt>), plus (unary <tt class="computeroutput"><span class="special">+</span></tt>), optional (unary <tt class="computeroutput"><span class="special">-</span></tt>),
- lists (<tt class="computeroutput"><span class="special">%</span></tt>), and the two predicates,
- the <span class="emphasis"><em>and</em></span> predicate (unary <tt class="computeroutput"><span class="special">&</span></tt>)
- and the <span class="emphasis"><em>not</em></span> predicate (unary <tt class="computeroutput"><span class="special">!</span></tt>).
+ It includes sequences (<code class="computeroutput"><span class="special"><<</span></code>),
+ alternatives (<code class="computeroutput"><span class="special">|</span></code>), Kleene star
+ (unary <code class="computeroutput"><span class="special">*</span></code>), plus (unary <code class="computeroutput"><span class="special">+</span></code>), optional (unary <code class="computeroutput"><span class="special">-</span></code>),
+ lists (<code class="computeroutput"><span class="special">%</span></code>), and the two predicates,
+ the <span class="emphasis"><em>and</em></span> predicate (unary <code class="computeroutput"><span class="special">&</span></code>)
+ and the <span class="emphasis"><em>not</em></span> predicate (unary <code class="computeroutput"><span class="special">!</span></code>).
</p>
-<a name="spirit.karma.reference.operator.module_header"></a><h5>
-<a name="id557730"></a>
- Module Header
- </h5>
+<a name="spirit.karma.reference.operator.module_header"></a><h6>
+<a name="id1274833"></a>
+ <a class="link" href="operator.html#spirit.karma.reference.operator.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_operator</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
+<p>
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
+ </p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/alternative.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/alternative.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/alternative.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Alternatives
- (operator|())</title>
+<title>Alternatives (operator|())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="sequence.html" title=" Sequences
- (operator<<())">
-<link rel="next" href="kleene.html" title=" Kleene Star
- (unary operator*())">
+<link rel="prev" href="sequence.html" title="Sequences (operator<<())">
+<link rel="next" href="kleene.html" title="Kleene Star (unary operator*())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="sequence.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="kleene.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.alternative"></a><a href="alternative.html" title=" Alternatives
- (operator|())"> Alternatives
- (<tt class="computeroutput"><span class="keyword">operator</span><span class="special">|()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Alternatives (operator|())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.alternative"></a><a class="link" href="alternative.html" title="Alternatives (operator|())"> Alternatives
+ (<code class="computeroutput"><span class="keyword">operator</span><span class="special">|()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.alternative.description"></a><h6>
-<a name="id560561"></a>
- Description
+<a name="id1277032"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.description">Description</a>
</h6>
<p>
Generator alternatives are used to combine different, more primitive
@@ -44,37 +37,37 @@
from left to right until one of them succeeds.
</p>
<a name="spirit.karma.reference.operator.alternative.header"></a><h6>
-<a name="id560594"></a>
- Header
+<a name="id1277049"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/alternative.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_alternative</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.alternative.model_of"></a><h6>
-<a name="id560709"></a>
- <a href="alternative.html#spirit.karma.reference.operator.alternative.model_of">Model
+<a name="id1277123"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- NaryGenerator
+ <a class="link" href="../generator_concepts/narygenerator.html" title="NaryGenerator"><code class="computeroutput"><span class="identifier">NaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.alternative.expression_semantics"></a><h6>
-<a name="id560762"></a>
- <a href="alternative.html#spirit.karma.reference.operator.alternative.expression_semantics">Expression
+<a name="id1277157"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in NaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/narygenerator.html" title="NaryGenerator"><code class="computeroutput"><span class="identifier">NaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -82,27 +75,35 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- The generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> are executed
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> are executed
sequentially from left to right and until one of them succeeds.
A failed generator forces the alternative generator to try the
next one. The alternative fails as a whole only if all elements
of the alternative fail. Each element of the alternative gets
passed the whole attribute of the alternative.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<p>
@@ -112,8 +113,8 @@
an element succeeded.
</p>
<a name="spirit.karma.reference.operator.alternative.attributes"></a><h6>
-<a name="id560935"></a>
- Attributes
+<a name="id1277268"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -121,19 +122,25 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- alternative (<tt class="computeroutput"><span class="special">|</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ alternative (<code class="computeroutput"><span class="special">|</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -143,18 +150,18 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">A</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The table above uses <tt class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt> as a placeholder only. The notation
- <tt class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>
- stands for the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>.
+<tr><td align="left" valign="top"><p>
+ The table above uses <code class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code> as a placeholder only. The notation
+ <code class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>
+ stands for the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>.
</p></td></tr>
</table></div>
<p>
@@ -168,8 +175,8 @@
an example of this behavior.
</p>
<a name="spirit.karma.reference.operator.alternative.complexity"></a><h6>
-<a name="id561606"></a>
- Complexity
+<a name="id1277768"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -184,8 +191,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.alternative.example"></a><h6>
-<a name="id561646"></a>
- Example
+<a name="id1277792"></a>
+ <a class="link" href="alternative.html#spirit.karma.reference.operator.alternative.example">Example</a>
</h6>
<p>
Some includes:
@@ -247,9 +254,9 @@
</p>
<p>
Basic usage of an alternative. While being only the second alternative,
- the <tt class="computeroutput"><span class="identifier">double_</span></tt> generator
+ the <code class="computeroutput"><span class="identifier">double_</span></code> generator
is chosen for output formatting because the supplied attribute type is
- not compatible (i.e. not convertible) to the attribute type of the <tt class="computeroutput"><span class="identifier">string</span></tt> alternative.
+ not compatible (i.e. not convertible) to the attribute type of the <code class="computeroutput"><span class="identifier">string</span></code> alternative.
</p>
<p>
</p>
@@ -266,7 +273,7 @@
</p>
<p>
The same formatting rules may be used to output a string. This time we
- supply the string <tt class="computeroutput"><span class="string">"example"</span></tt>,
+ supply the string <code class="computeroutput"><span class="string">"example"</span></code>,
resulting in the first alternative to be chosen for the generated output.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/and_predicate.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/and_predicate.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/and_predicate.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> And
- Predicate (unary operator&())</title>
+<title>And Predicate (unary operator&())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="optional.html" title=" Optional
- (unary operator-())">
-<link rel="next" href="not_predicate.html" title=" Not
- Predicate (unary operator!())">
+<link rel="prev" href="optional.html" title="Optional (unary operator-())">
+<link rel="next" href="not_predicate.html" title="Not Predicate (unary operator!())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="optional.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="not_predicate.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.and_predicate"></a><a href="and_predicate.html" title=" And
- Predicate (unary operator&())"> And
- Predicate (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="And Predicate (unary operator&())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.and_predicate"></a><a class="link" href="and_predicate.html" title="And Predicate (unary operator&())"> And
+ Predicate (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.and_predicate.description"></a><h6>
-<a name="id571838"></a>
- Description
+<a name="id1288483"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.description">Description</a>
</h6>
<p>
The and predicate generator is used to test, whether the embedded generator
@@ -44,37 +37,37 @@
succeeds.
</p>
<a name="spirit.karma.reference.operator.and_predicate.header"></a><h6>
-<a name="id571871"></a>
- Header
+<a name="id1288502"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/and_predicate.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_and_predicate</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.and_predicate.model_of"></a><h6>
-<a name="id571986"></a>
- <a href="and_predicate.html#spirit.karma.reference.operator.and_predicate.model_of">Model
+<a name="id1288577"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.and_predicate.expression_semantics"></a><h6>
-<a name="id572041"></a>
- <a href="and_predicate.html#spirit.karma.reference.operator.and_predicate.expression_semantics">Expression
+<a name="id1288613"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -82,24 +75,32 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="special">&</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">&</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed for the sole purpose of testing whether it succeeds.
The and predicate generator succeeds as long as its embedded
generator succeeds (except if the underlying output stream reports
an error). The and predicate never produces any output.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<p>
@@ -107,8 +108,8 @@
its embedded generator into a discarding device.
</p>
<a name="spirit.karma.reference.operator.and_predicate.attributes"></a><h6>
-<a name="id572185"></a>
- Attributes
+<a name="id1288716"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -116,39 +117,47 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- and predicate (unary <tt class="computeroutput"><span class="special">&</span></tt>)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ and predicate (unary <code class="computeroutput"><span class="special">&</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></tt>
- </p></td>
+ <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></code>
+ </p>
+ </td>
</tr></tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The attribute of the and predicate is not always <tt class="computeroutput"><span class="identifier">Unused</span></tt>,
+<tr><td align="left" valign="top"><p>
+ The attribute of the and predicate is not always <code class="computeroutput"><span class="identifier">Unused</span></code>,
which is different from Qi's and predicate. This is necessary as the
generator the and predicate is attached to most of the time needs an
attribute.
</p></td></tr>
</table></div>
<a name="spirit.karma.reference.operator.and_predicate.complexity"></a><h6>
-<a name="id572351"></a>
- Complexity
+<a name="id1288843"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -162,8 +171,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.and_predicate.example"></a><h6>
-<a name="id572391"></a>
- Example
+<a name="id1288869"></a>
+ <a class="link" href="and_predicate.html#spirit.karma.reference.operator.and_predicate.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/kleene.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/kleene.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/kleene.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Kleene Star
- (unary operator*())</title>
+<title>Kleene Star (unary operator*())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="alternative.html" title=" Alternatives
- (operator|())">
-<link rel="next" href="plus.html" title=" Plus (unary
- operator+())">
+<link rel="prev" href="alternative.html" title="Alternatives (operator|())">
+<link rel="next" href="plus.html" title="Plus (unary operator+())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="alternative.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="plus.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.kleene"></a><a href="kleene.html" title=" Kleene Star
- (unary operator*())"> Kleene Star
- (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">*()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Kleene Star (unary operator*())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.kleene"></a><a class="link" href="kleene.html" title="Kleene Star (unary operator*())"> Kleene Star
+ (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">*()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.kleene.description"></a><h6>
-<a name="id563142"></a>
- Description
+<a name="id1278885"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.description">Description</a>
</h6>
<p>
Kleene star generators are used to repeat the execution of an embedded
@@ -44,37 +37,37 @@
generator, the Kleene star generator always succeeds.
</p>
<a name="spirit.karma.reference.operator.kleene.header"></a><h6>
-<a name="id563175"></a>
- Header
+<a name="id1278902"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/kleene.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_kleene</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.kleene.model_of"></a><h6>
-<a name="id563289"></a>
- <a href="kleene.html#spirit.karma.reference.operator.kleene.model_of">Model
+<a name="id1278976"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.kleene.expression_semantics"></a><h6>
-<a name="id563340"></a>
- <a href="kleene.html#spirit.karma.reference.operator.kleene.expression_semantics">Expression
+<a name="id1279014"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -82,30 +75,38 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="special">*</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">*</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed zero or more times depending on the availability
- of an attribute. The execution of <tt class="computeroutput"><span class="identifier">a</span></tt>
+ of an attribute. The execution of <code class="computeroutput"><span class="identifier">a</span></code>
stops after the attribute values passed to the Kleene star generator
are exhausted. The Kleene star always succeeds (except if the
underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.operator.kleene.attributes"></a><h6>
-<a name="id563489"></a>
- Attributes
+<a name="id1279121"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -113,38 +114,44 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- kleene (unary <tt class="computeroutput"><span class="special">*</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ kleene (unary <code class="computeroutput"><span class="special">*</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The table above uses <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as a placeholder only. The notation
- of <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
+<tr><td align="left" valign="top"><p>
+ The table above uses <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as a placeholder only. The notation
+ of <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
stands for <span class="emphasis"><em>any STL container</em></span> holding elements
- of type <tt class="computeroutput"><span class="identifier">A</span></tt>.
+ of type <code class="computeroutput"><span class="identifier">A</span></code>.
</p></td></tr>
</table></div>
<p>
@@ -162,16 +169,15 @@
failing element generator might have already generated some output, which
is <span class="emphasis"><em>not</em></span> rolled back.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
The simplest way to force a Kleene star to behave as if it did buffering
- is to wrap it into a buffering directive (see <a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>):
+ is to wrap it into a buffering directive (see <a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>):
</p>
<p>
@@ -181,7 +187,7 @@
</p>
<p>
which will <span class="emphasis"><em>not</em></span> generate any output in case of
- a failing generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ a failing generator <code class="computeroutput"><span class="identifier">a</span></code>.
The expression:
</p>
<p>
@@ -191,15 +197,15 @@
<p>
</p>
<p>
- will not generate any partial output from a generator <tt class="computeroutput"><span class="identifier">a</span></tt> if it fails generating in the middle
+ will not generate any partial output from a generator <code class="computeroutput"><span class="identifier">a</span></code> if it fails generating in the middle
of its output. The overall expression will still generate the output
- as produced by all succeeded invocations of the generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ as produced by all succeeded invocations of the generator <code class="computeroutput"><span class="identifier">a</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.operator.kleene.complexity"></a><h6>
-<a name="id563956"></a>
- Complexity
+<a name="id1281107"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -215,8 +221,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.kleene.example"></a><h6>
-<a name="id563999"></a>
- Example
+<a name="id1281131"></a>
+ <a class="link" href="kleene.html#spirit.karma.reference.operator.kleene.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/list.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/list.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/list.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Lists (operator%())</title>
+<title>Lists (operator%())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="plus.html" title=" Plus (unary
- operator+())">
-<link rel="next" href="optional.html" title=" Optional
- (unary operator-())">
+<link rel="prev" href="plus.html" title="Plus (unary operator+())">
+<link rel="next" href="optional.html" title="Optional (unary operator-())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,16 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="plus.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="optional.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.list"></a> Lists (operator%())
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Lists (operator%())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.list"></a><a class="link" href="list.html" title="Lists (operator%())"> Lists (<code class="computeroutput"><span class="keyword">operator</span><span class="special">%()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.list.description"></a><h6>
-<a name="id567476"></a>
- Description
+<a name="id1284239"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.description">Description</a>
</h6>
<p>
The list generator is used to repeat the execution of an embedded generator
@@ -42,36 +37,36 @@
at least once.
</p>
<a name="spirit.karma.reference.operator.list.header"></a><h6>
-<a name="id567510"></a>
- Header
+<a name="id1284256"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/list.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_list</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.list.model_of"></a><h6>
-<a name="id567624"></a>
- Model of
+<a name="id1284330"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- BinaryGenerator
+ <a class="link" href="../generator_concepts/binarygenerator.html" title="BinaryGenerator"><code class="computeroutput"><span class="identifier">BinaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.list.expression_semantics"></a><h6>
-<a name="id567676"></a>
- <a href="list.html#spirit.karma.reference.operator.list.expression_semantics">Expression
+<a name="id1284368"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in BinaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/binarygenerator.html" title="BinaryGenerator"><code class="computeroutput"><span class="identifier">BinaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -79,39 +74,47 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed one or more times depending on the availability of
- an attribute. The output generated by <tt class="computeroutput"><span class="identifier">a</span></tt>
- is interspaced with the output generated by <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ an attribute. The output generated by <code class="computeroutput"><span class="identifier">a</span></code>
+ is interspaced with the output generated by <code class="computeroutput"><span class="identifier">b</span></code>.
The list generator succeeds as long as both its first embedded
generator has been successfully executed at least once (except
if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<p>
- The list expression <tt class="computeroutput"><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span></tt>
- is a shortcut for <tt class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span> <span class="special">*(</span><span class="identifier">b</span> <span class="special"><<</span>
- <span class="identifier">a</span><span class="special">)</span></tt>.
- It is almost semantically equivalent, except for the attribute of <tt class="computeroutput"><span class="identifier">b</span></tt>, which gets ignored in the case of
+ The list expression <code class="computeroutput"><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span></code>
+ is a shortcut for <code class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span> <span class="special">*(</span><span class="identifier">b</span> <span class="special"><<</span>
+ <span class="identifier">a</span><span class="special">)</span></code>.
+ It is almost semantically equivalent, except for the attribute of <code class="computeroutput"><span class="identifier">b</span></code>, which gets ignored in the case of
the list generator.
</p>
<a name="spirit.karma.reference.operator.list.attributes"></a><h6>
-<a name="id567933"></a>
- Attributes
+<a name="id1284550"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -119,38 +122,44 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- list (<tt class="computeroutput"><span class="special">%</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ list (<code class="computeroutput"><span class="special">%</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The table above uses <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as a placeholder only. The notation
- of <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
+<tr><td align="left" valign="top"><p>
+ The table above uses <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as a placeholder only. The notation
+ of <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
stands for <span class="emphasis"><em>any STL container</em></span> holding elements
- of type <tt class="computeroutput"><span class="identifier">A</span></tt>.
+ of type <code class="computeroutput"><span class="identifier">A</span></code>.
</p></td></tr>
</table></div>
<p>
@@ -160,22 +169,21 @@
be interspaced by the output generated by the second generator. On each
iteration it will pass the next consecutive element from the container
attribute to the first embedded generator. The second embedded generator
- does not get passed any attributes (it gets invoked using an <tt class="computeroutput"><span class="identifier">unused_type</span></tt> as its attribute). Therefor
+ does not get passed any attributes (it gets invoked using an <code class="computeroutput"><span class="identifier">unused_type</span></code> as its attribute). Therefor
the number of iterations will not be larger than the number of elements
in the container passed as its attribute. An empty container will make
the list generator fail.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
If you want to use the list generator and still allow for an empty
- attribute, you can use the optional operator (see <a href="optional.html" title=" Optional
- (unary operator-())">optional
- (unary <tt class="computeroutput"><span class="special">-</span></tt>)</a>):
+ attribute, you can use the optional operator (see <a class="link" href="optional.html" title="Optional (unary operator-())">optional
+ (unary <code class="computeroutput"><span class="special">-</span></code>)</a>):
</p>
<p>
@@ -195,16 +203,15 @@
that any failing element generator might have already generated some
output, which is <span class="emphasis"><em>not</em></span> rolled back.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
The simplest way to force a list generator to behave as if it did buffering
- is to wrap it into a buffering directive (see <a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>):
+ is to wrap it into a buffering directive (see <a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>):
</p>
<p>
@@ -214,13 +221,13 @@
</p>
<p>
which will <span class="emphasis"><em>not</em></span> generate any output in case of
- a failing generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ a failing generator <code class="computeroutput"><span class="identifier">a</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.operator.list.complexity"></a><h6>
-<a name="id568513"></a>
- Complexity
+<a name="id1284952"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -235,8 +242,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.list.example"></a><h6>
-<a name="id568554"></a>
- Example
+<a name="id1284976"></a>
+ <a class="link" href="list.html#spirit.karma.reference.operator.list.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/not_predicate.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/not_predicate.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/not_predicate.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Not
- Predicate (unary operator!())</title>
+<title>Not Predicate (unary operator!())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="and_predicate.html" title=" And
- Predicate (unary operator&())">
-<link rel="next" href="../stream.html" title="Stream">
+<link rel="prev" href="and_predicate.html" title="And Predicate (unary operator&())">
+<link rel="next" href="../../performance_measurements.html" title="Performance Measurements">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,20 +20,16 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="and_predicate.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.not_predicate"></a><a href="not_predicate.html" title=" Not
- Predicate (unary operator!())"> Not
- Predicate (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></tt>)</a>
-</h5></div></div>
-<div></div>
+<a accesskey="p" href="and_predicate.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../performance_measurements.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="Not Predicate (unary operator!())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.not_predicate"></a><a class="link" href="not_predicate.html" title="Not Predicate (unary operator!())"> Not
+ Predicate (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.not_predicate.description"></a><h6>
-<a name="id573843"></a>
- Description
+<a name="id1290501"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.description">Description</a>
</h6>
<p>
The not predicate generator is used to test, whether the embedded generator
@@ -43,37 +37,37 @@
fails.
</p>
<a name="spirit.karma.reference.operator.not_predicate.header"></a><h6>
-<a name="id573876"></a>
- Header
+<a name="id1290520"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/not_predicate.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_not_predicate</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.not_predicate.model_of"></a><h6>
-<a name="id573990"></a>
- <a href="not_predicate.html#spirit.karma.reference.operator.not_predicate.model_of">Model
+<a name="id1290594"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.not_predicate.expression_semantics"></a><h6>
-<a name="id574045"></a>
- <a href="not_predicate.html#spirit.karma.reference.operator.not_predicate.expression_semantics">Expression
+<a name="id1290630"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -81,24 +75,32 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="special">!</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">!</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed for the sole purpose of testing whether it succeeds.
The not predicate generator succeeds as long as its embedded
generator fails (except if the underlying output stream reports
an error). The not predicate never produces any output.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<p>
@@ -106,8 +108,8 @@
its embedded generator into a discarding device.
</p>
<a name="spirit.karma.reference.operator.not_predicate.attributes"></a><h6>
-<a name="id574190"></a>
- Attributes
+<a name="id1290734"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -115,39 +117,47 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- not predicate (unary <tt class="computeroutput"><span class="special">!</span></tt>)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ not predicate (unary <code class="computeroutput"><span class="special">!</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></tt>
- </p></td>
+ <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span></code>
+ </p>
+ </td>
</tr></tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The attribute of the and predicate is not always <tt class="computeroutput"><span class="identifier">Unused</span></tt>,
+<tr><td align="left" valign="top"><p>
+ The attribute of the and predicate is not always <code class="computeroutput"><span class="identifier">Unused</span></code>,
which is different from Qi's and predicate. This is necessary as the
generator the and predicate is attached to most of the time needs an
attribute.
</p></td></tr>
</table></div>
<a name="spirit.karma.reference.operator.not_predicate.complexity"></a><h6>
-<a name="id574354"></a>
- Complexity
+<a name="id1290861"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -161,8 +171,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.not_predicate.example"></a><h6>
-<a name="id574395"></a>
- Example
+<a name="id1290887"></a>
+ <a class="link" href="not_predicate.html#spirit.karma.reference.operator.not_predicate.example">Example</a>
</h6>
<p>
Some includes:
@@ -254,7 +264,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="and_predicate.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../stream.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="and_predicate.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../performance_measurements.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/optional.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/optional.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/optional.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Optional
- (unary operator-())</title>
+<title>Optional (unary operator-())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="list.html" title=" Lists (operator%())">
-<link rel="next" href="and_predicate.html" title=" And
- Predicate (unary operator&())">
+<link rel="prev" href="list.html" title="Lists (operator%())">
+<link rel="next" href="and_predicate.html" title="And Predicate (unary operator&())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,55 +22,51 @@
<div class="spirit-nav">
<a accesskey="p" href="list.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="and_predicate.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.optional"></a><a href="optional.html" title=" Optional
- (unary operator-())"> Optional
- (unary <tt class="computeroutput"><span class="keyword">operator</span><span class="special">-()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Optional (unary operator-())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.optional"></a><a class="link" href="optional.html" title="Optional (unary operator-())"> Optional
+ (unary <code class="computeroutput"><span class="keyword">operator</span><span class="special">-()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.optional.description"></a><h6>
-<a name="id569777"></a>
- Description
+<a name="id1286995"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.description">Description</a>
</h6>
<p>
The optional generator is used to conditionally execute an embedded generator.
It succeeds always.
</p>
<a name="spirit.karma.reference.operator.optional.header"></a><h6>
-<a name="id569808"></a>
- Header
+<a name="id1287012"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/optional.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_optional</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.optional.model_of"></a><h6>
-<a name="id569922"></a>
- <a href="optional.html#spirit.karma.reference.operator.optional.model_of">Model
+<a name="id1287086"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.optional.expression_semantics"></a><h6>
-<a name="id569975"></a>
- <a href="optional.html#spirit.karma.reference.operator.optional.expression_semantics">Expression
+<a name="id1287125"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -80,28 +74,36 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="special">-</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">-</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed depending on the availability of an attribute. The
optional generator succeeds as long as its embedded generator
succeeds (except if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.operator.optional.attributes"></a><h6>
-<a name="id570112"></a>
- Attributes
+<a name="id1287224"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -109,37 +111,43 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- optional (unary <tt class="computeroutput"><span class="special">-</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ optional (unary <code class="computeroutput"><span class="special">-</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The table above uses <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as a placeholder only. The notation
- of <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- stands for the data type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>.
+<tr><td align="left" valign="top"><p>
+ The table above uses <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as a placeholder only. The notation
+ of <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ stands for the data type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>.
</p></td></tr>
</table></div>
<p>
@@ -153,16 +161,15 @@
means that any failing element might have already generated some output,
which is <span class="emphasis"><em>not</em></span> rolled back.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
The simplest way to force a optional generator to behave as if it did
- buffering is to wrap it into a buffering directive (see <a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>):
+ buffering is to wrap it into a buffering directive (see <a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>):
</p>
<p>
@@ -172,13 +179,13 @@
</p>
<p>
which will <span class="emphasis"><em>not</em></span> generate any output in case of
- a failing generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ a failing generator <code class="computeroutput"><span class="identifier">a</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.operator.optional.complexity"></a><h6>
-<a name="id570529"></a>
- Complexity
+<a name="id1287521"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -192,8 +199,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.optional.example"></a><h6>
-<a name="id570568"></a>
- Example
+<a name="id1287545"></a>
+ <a class="link" href="optional.html#spirit.karma.reference.operator.optional.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/plus.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/plus.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/plus.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Plus (unary
- operator+())</title>
+<title>Plus (unary operator+())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="kleene.html" title=" Kleene Star
- (unary operator*())">
-<link rel="next" href="list.html" title=" Lists (operator%())">
+<link rel="prev" href="kleene.html" title="Kleene Star (unary operator*())">
+<link rel="next" href="list.html" title="Lists (operator%())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="kleene.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="list.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.plus"></a><a href="plus.html" title=" Plus (unary
- operator+())"> Plus (unary
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Plus (unary operator+())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.plus"></a><a class="link" href="plus.html" title="Plus (unary operator+())"> Plus (unary
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special">+()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.plus.description"></a><h6>
-<a name="id565247"></a>
- Description
+<a name="id1282050"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.description">Description</a>
</h6>
<p>
The plus generator is used to repeat the execution of an embedded generator
@@ -43,36 +37,36 @@
executed at least once.
</p>
<a name="spirit.karma.reference.operator.plus.header"></a><h6>
-<a name="id565280"></a>
- Header
+<a name="id1282067"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/plus.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_plus</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.plus.model_of"></a><h6>
-<a name="id565394"></a>
- Model of
+<a name="id1282141"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- UnaryGenerator
+ <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.plus.expression_semantics"></a><h6>
-<a name="id565445"></a>
- <a href="plus.html#spirit.karma.reference.operator.plus.expression_semantics">Expression
+<a name="id1282180"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in UnaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/unarygenerator.html" title="UnaryGenerator"><code class="computeroutput"><span class="identifier">UnaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -80,31 +74,39 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="special">+</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- The generator <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">+</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generator <code class="computeroutput"><span class="identifier">a</span></code>
is executed one or more times depending on the availability of
- an attribute. The execution of <tt class="computeroutput"><span class="identifier">a</span></tt>
+ an attribute. The execution of <code class="computeroutput"><span class="identifier">a</span></code>
stops after the attribute values passed to the plus generator
are exhausted. The plus generator succeeds as long as its embedded
generator has been successfully executed at least once (except
if the underlying output stream reports an error).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.karma.reference.operator.plus.attributes"></a><h6>
-<a name="id565590"></a>
- Attributes
+<a name="id1282286"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -112,38 +114,44 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- plus (unary <tt class="computeroutput"><span class="special">+</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ plus (unary <code class="computeroutput"><span class="special">+</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The table above uses <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as a placeholder only. The notation
- of <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
+<tr><td align="left" valign="top"><p>
+ The table above uses <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as a placeholder only. The notation
+ of <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
stands for <span class="emphasis"><em>any STL container</em></span> holding elements
- of type <tt class="computeroutput"><span class="identifier">A</span></tt>.
+ of type <code class="computeroutput"><span class="identifier">A</span></code>.
</p></td></tr>
</table></div>
<p>
@@ -161,16 +169,15 @@
that any failing element generator might have already generated some
output, which is <span class="emphasis"><em>not</em></span> rolled back.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
The simplest way to force a plus generator to behave as if it did buffering
- is to wrap it into a buffering directive (see <a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>):
+ is to wrap it into a buffering directive (see <a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>):
</p>
<p>
@@ -180,7 +187,7 @@
</p>
<p>
which will <span class="emphasis"><em>not</em></span> generate any output in case of
- a failing generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ a failing generator <code class="computeroutput"><span class="identifier">a</span></code>.
The expression:
</p>
<p>
@@ -190,15 +197,15 @@
<p>
</p>
<p>
- will not generate any partial output from a generator <tt class="computeroutput"><span class="identifier">a</span></tt> if it fails generating in the middle
+ will not generate any partial output from a generator <code class="computeroutput"><span class="identifier">a</span></code> if it fails generating in the middle
of its output. The overall expression will still generate the output
- as produced by all succeeded invocations of the generator <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ as produced by all succeeded invocations of the generator <code class="computeroutput"><span class="identifier">a</span></code>.
</p>
</td></tr>
</table></div>
<a name="spirit.karma.reference.operator.plus.complexity"></a><h6>
-<a name="id566057"></a>
- Complexity
+<a name="id1282612"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -213,8 +220,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.plus.example"></a><h6>
-<a name="id566098"></a>
- Example
+<a name="id1282636"></a>
+ <a class="link" href="plus.html#spirit.karma.reference.operator.plus.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/operator/sequence.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/operator/sequence.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/operator/sequence.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Sequences
- (operator<<())</title>
+<title>Sequences (operator<<())</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../operator.html" title="Operator">
-<link rel="previous" href="../operator.html" title="Operator">
-<link rel="next" href="alternative.html" title=" Alternatives
- (operator|())">
+<link rel="prev" href="../operator.html" title="Operator">
+<link rel="next" href="alternative.html" title="Alternatives (operator|())">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="../operator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="alternative.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.karma.reference.operator.sequence"></a><a href="sequence.html" title=" Sequences
- (operator<<())"> Sequences
- (<tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>)</a>
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Sequences (operator<<())">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.karma.reference.operator.sequence"></a><a class="link" href="sequence.html" title="Sequences (operator<<())"> Sequences
+ (<code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>)</a>
+</h5></div></div></div>
<a name="spirit.karma.reference.operator.sequence.description"></a><h6>
-<a name="id557865"></a>
- Description
+<a name="id1274928"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.description">Description</a>
</h6>
<p>
Generator sequences are used to consecutively combine different, more
@@ -43,37 +37,37 @@
to right as long as they succeed.
</p>
<a name="spirit.karma.reference.operator.sequence.header"></a><h6>
-<a name="id557898"></a>
- Header
+<a name="id1274945"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/operator/sequence.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_sequence</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.karma.reference.operator.sequence.model_of"></a><h6>
-<a name="id558012"></a>
- <a href="sequence.html#spirit.karma.reference.operator.sequence.model_of">Model
+<a name="id1275019"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- NaryGenerator
+ <a class="link" href="../generator_concepts/narygenerator.html" title="NaryGenerator"><code class="computeroutput"><span class="identifier">NaryGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.sequence.expression_semantics"></a><h6>
-<a name="id558065"></a>
- <a href="sequence.html#spirit.karma.reference.operator.sequence.expression_semantics">Expression
+<a name="id1275055"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in NaryGenerator.
+ is not defined in <a class="link" href="../generator_concepts/narygenerator.html" title="NaryGenerator"><code class="computeroutput"><span class="identifier">NaryGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -81,25 +75,33 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- The generators <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> are executed
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special"><<</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The generators <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> are executed
sequentially from left to right and as long as they succeed.
A failed generator stops the execution of the entire sequence
and makes the sequence fail as well.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<p>
@@ -108,16 +110,15 @@
might have already generated some output, which is <span class="emphasis"><em>not</em></span>
rolled back.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
The simplest way to force a sequence to behave as if it did buffering
- is to wrap it into a buffering directive (see <a href="../directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>):
+ is to wrap it into a buffering directive (see <a class="link" href="../directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>):
</p>
<p>
@@ -132,8 +133,8 @@
</td></tr>
</table></div>
<a name="spirit.karma.reference.operator.sequence.attributes"></a><h6>
-<a name="id558339"></a>
- Attributes
+<a name="id1275248"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -141,19 +142,25 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- sequence (<tt class="computeroutput"><span class="special"><<</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ sequence (<code class="computeroutput"><span class="special"><<</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -167,27 +174,27 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></pre>
<p>
</p>
-</td>
+ </td>
</tr></tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- The table above uses <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt> and <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> as placeholders only.
+ The table above uses <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code> and <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> as placeholders only.
</p>
<p>
- The notation <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt> stands for <span class="emphasis"><em>any fusion
- sequence of two elements</em></span>, where <tt class="computeroutput"><span class="identifier">A</span></tt>
- is the type of its first element and <tt class="computeroutput"><span class="identifier">B</span></tt>
+ The notation <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code> stands for <span class="emphasis"><em>any fusion
+ sequence of two elements</em></span>, where <code class="computeroutput"><span class="identifier">A</span></code>
+ is the type of its first element and <code class="computeroutput"><span class="identifier">B</span></code>
is the type of its second element.
</p>
<p>
- The notation of <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> stands for <span class="emphasis"><em>any STL container</em></span>
- holding elements of type <tt class="computeroutput"><span class="identifier">A</span></tt>.
+ The notation of <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> stands for <span class="emphasis"><em>any STL container</em></span>
+ holding elements of type <code class="computeroutput"><span class="identifier">A</span></code>.
</p>
</td></tr>
</table></div>
@@ -199,8 +206,8 @@
the attribute supplied
</p>
<a name="spirit.karma.reference.operator.sequence.complexity"></a><h6>
-<a name="id559415"></a>
- Complexity
+<a name="id1276046"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -214,8 +221,8 @@
</p>
</blockquote></div>
<a name="spirit.karma.reference.operator.sequence.example"></a><h6>
-<a name="id559454"></a>
- Example
+<a name="id1276070"></a>
+ <a class="link" href="sequence.html#spirit.karma.reference.operator.sequence.example">Example</a>
</h6>
<p>
Some includes:
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/stream.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/stream.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/stream.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Stream</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="operator/not_predicate.html" title=" Not
- Predicate (unary operator!())">
-<link rel="next" href="auxiliary.html" title="Auxiliary">
+<link rel="prev" href="numeric/floating_point.html" title="Floating Point Number Generators">
+<link rel="next" href="binary.html" title="Binary">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -21,24 +20,21 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="operator/not_predicate.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
-</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.stream"></a>Stream
-</h4></div></div>
-<div></div>
+<a accesskey="p" href="numeric/floating_point.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
+<div class="section" title="Stream">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.stream"></a><a class="link" href="stream.html" title="Stream">Stream</a>
+</h4></div></div></div>
<p>
This module includes the description of the different variants of the
- <tt class="computeroutput"><span class="identifier">stream</span></tt> generator. It can
- be used to utilize existing streaming operators (<tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>) for output generation.
+ <code class="computeroutput"><span class="identifier">stream</span></code> generator. It can
+ be used to utilize existing streaming operators (<code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>) for output generation.
</p>
-<a name="spirit.karma.reference.stream.description"></a><h5>
-<a name="id575924"></a>
- Description
- </h5>
+<a name="spirit.karma.reference.stream.description"></a><h6>
+<a name="id1229830"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.description">Description</a>
+ </h6>
<p>
The stream generators described in this section are:
</p>
@@ -48,57 +44,77 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span></tt>
- </p></td>
-<td><p>
- Generates narrow character (<tt class="computeroutput"><span class="keyword">char</span></tt>)
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates narrow character (<code class="computeroutput"><span class="keyword">char</span></code>)
based output from the mandatory attribute using the matching streaming
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates narrow character (<tt class="computeroutput"><span class="keyword">char</span></tt>)
- based output from the immediate argument <tt class="computeroutput"><span class="identifier">s</span></tt>
- using the matching streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span></tt>
- </p></td>
-<td><p>
- Generates wide character (<tt class="computeroutput"><span class="keyword">wchar_t</span></tt>)
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates narrow character (<code class="computeroutput"><span class="keyword">char</span></code>)
+ based output from the immediate argument <code class="computeroutput"><span class="identifier">s</span></code>
+ using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates wide character (<code class="computeroutput"><span class="keyword">wchar_t</span></code>)
based output from the mandatory attribute using the matching streaming
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates wide character (<tt class="computeroutput"><span class="keyword">wchar_t</span></tt>)
- based output from the immediate argument <tt class="computeroutput"><span class="identifier">s</span></tt>
- using the matching streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates wide character (<code class="computeroutput"><span class="keyword">wchar_t</span></code>)
+ based output from the immediate argument <code class="computeroutput"><span class="identifier">s</span></code>
+ using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
@@ -106,15 +122,17 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generates output based on the given character type <tt class="computeroutput"><span class="identifier">Char</span></tt> from the mandatory attribute
- using the matching streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ Generates output based on the given character type <code class="computeroutput"><span class="identifier">Char</span></code> from the mandatory attribute
+ using the matching streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
@@ -122,50 +140,52 @@
<span class="special">>()(</span><span class="identifier">s</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- Generates output based on the given character type <tt class="computeroutput"><span class="identifier">Char</span></tt> from the immediate argument
- <tt class="computeroutput"><span class="identifier">s</span></tt> using the matching
- streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ Generates output based on the given character type <code class="computeroutput"><span class="identifier">Char</span></code> from the immediate argument
+ <code class="computeroutput"><span class="identifier">s</span></code> using the matching
+ streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<a name="spirit.karma.reference.stream.header"></a><h5>
-<a name="id576454"></a>
- Header
- </h5>
+<a name="spirit.karma.reference.stream.header"></a><h6>
+<a name="id1230212"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.header">Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/stream.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_stream</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
-<a name="spirit.karma.reference.stream.model_of"></a><h5>
-<a name="id576568"></a>
- Model of
- </h5>
+<a name="spirit.karma.reference.stream.model_of"></a><h6>
+<a name="id1230286"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.model_of">Model of</a>
+ </h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">s</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">s</span></code></span></dt>
<dd><p>
A variable instance of any type with a defined matching streaming
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
- or a <a href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
+ or a <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to any type with a defined matching
- streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>.
+ streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Char</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Char</span></code></span></dt>
<dd><p>
The character type to use to generate the output. This type will be
used while assigning the generated characters to the underlying output
@@ -173,14 +193,14 @@
</p></dd>
</dl>
</div>
-<a name="spirit.karma.reference.stream.expression_semantics"></a><h5>
-<a name="id576724"></a>
- <a href="stream.html#spirit.karma.reference.stream.expression_semantics">Expression
+<a name="spirit.karma.reference.stream.expression_semantics"></a><h6>
+<a name="id1230392"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.expression_semantics">Expression
Semantics</a>
- </h5>
+ </h6>
<p>
Semantics of an expression is defined only where it differs from, or is
- not defined in PrimitiveGenerator.
+ not defined in <a class="link" href="generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -188,71 +208,91 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span></tt>
- </p></td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the mandory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the mandory
attribute. The output emitted by this operator will be the result
- of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator.
+ of the <code class="computeroutput"><span class="identifier">stream</span></code> generator.
This generator never fails (except if the underlying output stream
reports an error). The character type of the I/O ostream is assumed
- to be <tt class="computeroutput"><span class="keyword">char</span></tt>.
- </p></td>
+ to be <code class="computeroutput"><span class="keyword">char</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the immediate
- value <tt class="computeroutput"><span class="identifier">s</span></tt>. The output
- emitted by this operator will be the result of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator. This generator
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the immediate
+ value <code class="computeroutput"><span class="identifier">s</span></code>. The output
+ emitted by this operator will be the result of the <code class="computeroutput"><span class="identifier">stream</span></code> generator. This generator
never fails (except if the underlying output stream reports an
error). The character type of the I/O ostream is assumed to be
- <tt class="computeroutput"><span class="keyword">char</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="keyword">char</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span></tt>
- </p></td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the mandory
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the mandory
attribute. The output emitted by this operator will be the result
- of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator.
+ of the <code class="computeroutput"><span class="identifier">stream</span></code> generator.
This generator never fails (except if the underlying output stream
reports an error). The character type of the I/O ostream is assumed
- to be <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>.
- </p></td>
+ to be <code class="computeroutput"><span class="keyword">wchar_t</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the immediate
- value <tt class="computeroutput"><span class="identifier">s</span></tt>. The output
- emitted by this operator will be the result of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator. This generator
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the immediate
+ value <code class="computeroutput"><span class="identifier">s</span></code>. The output
+ emitted by this operator will be the result of the <code class="computeroutput"><span class="identifier">stream</span></code> generator. This generator
never fails (except if the underlying output stream reports an
error). The character type of the I/O ostream is assumed to be
- <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="keyword">wchar_t</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
All generators listed in the table above are predefined specializations
- of the <tt class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">></span></tt> basic stream generator type described
+ of the <code class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">></span></code> basic stream generator type described
below. It is possible to directly use this type to create stream generators
using an arbitrary underlying character type.
</p>
@@ -262,17 +302,21 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
@@ -280,19 +324,21 @@
<span class="special">>()</span></pre>
<p>
</p>
-</td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the mandory
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the mandory
attribute. The output emitted by this operator will be the result
- of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator.
+ of the <code class="computeroutput"><span class="identifier">stream</span></code> generator.
This generator never fails (except if the underlying output stream
reports an error). The character type of the I/O ostream is assumed
- to be <tt class="computeroutput"><span class="identifier">Char</span></tt>
- </p></td>
+ to be <code class="computeroutput"><span class="identifier">Char</span></code>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">stream_generator</span><span class="special"><</span>
@@ -300,28 +346,76 @@
<span class="special">>()(</span><span class="identifier">s</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- Call the streaming <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt> for the type of the immediate
- value <tt class="computeroutput"><span class="identifier">s</span></tt>. The output
- emitted by this operator will be the result of the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator. This generator
+ </td>
+<td>
+ <p>
+ Call the streaming <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code> for the type of the immediate
+ value <code class="computeroutput"><span class="identifier">s</span></code>. The output
+ emitted by this operator will be the result of the <code class="computeroutput"><span class="identifier">stream</span></code> generator. This generator
never fails (except if the underlying output stream reports an
error). The character type of the I/O ostream is assumed to be
- <tt class="computeroutput"><span class="identifier">Char</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="identifier">Char</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<a name="spirit.karma.reference.stream.additional_requirements"></a><h5>
-<a name="id577443"></a>
- <a href="stream.html#spirit.karma.reference.stream.additional_requirements">Additional
+<a name="spirit.karma.reference.stream.template_parameters"></a><h6>
+<a name="id1230881"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.template_parameters">Template
+ parameters</a>
+ </h6>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Parameter
+ </p>
+ </th>
+<th>
+ <p>
+ Description
+ </p>
+ </th>
+<th>
+ <p>
+ Default
+ </p>
+ </th>
+</tr></thead>
+<tbody><tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Char</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type used by the underlying ostream
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">char</span></code>
+ </p>
+ </td>
+</tr></tbody>
+</table></div>
+<a name="spirit.karma.reference.stream.additional_requirements"></a><h6>
+<a name="id1230971"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.additional_requirements">Additional
Requirements</a>
- </h5>
+ </h6>
<p>
All of the stream generators listed above require the type of the value
to generate output for (either the immediate value or the associated attribute)
to implement a streaming operator conforming to the usual I/O streams conventions
- (where <tt class="computeroutput"><span class="identifier">attribute_type</span></tt> is
+ (where <code class="computeroutput"><span class="identifier">attribute_type</span></code> is
the type of the value to generate output for):
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Ostream</span><span class="special">></span>
@@ -333,120 +427,157 @@
</pre>
<p>
This operator will be called by the stream generators to gather the output
- for the attribute of type <tt class="computeroutput"><span class="identifier">attribute_type</span></tt>.
- All data streamed into the given <tt class="computeroutput"><span class="identifier">Ostream</span></tt>
+ for the attribute of type <code class="computeroutput"><span class="identifier">attribute_type</span></code>.
+ All data streamed into the given <code class="computeroutput"><span class="identifier">Ostream</span></code>
will end up being generated by the corresponding stream generator instance.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- If the <tt class="computeroutput"><span class="identifier">stream</span></tt> generator
- is invoked inside a <tt class="computeroutput"><span class="identifier">format</span></tt>
- (or <tt class="computeroutput"><span class="identifier">format_delimited</span></tt>
- ) stream manipulator the <tt class="computeroutput"><span class="identifier">Ostream</span></tt>
- passed to the <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></tt>
+<tr><td align="left" valign="top"><p>
+ If the <code class="computeroutput"><span class="identifier">stream</span></code> generator
+ is invoked inside a <code class="computeroutput"><span class="identifier">format</span></code>
+ (or <code class="computeroutput"><span class="identifier">format_delimited</span></code>
+ ) stream manipulator the <code class="computeroutput"><span class="identifier">Ostream</span></code>
+ passed to the <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<()</span></code>
will have registered (imbued) the same standard locale instance as the
- stream the <tt class="computeroutput"><span class="identifier">format</span></tt> (or
- <tt class="computeroutput"><span class="identifier">format_delimited</span></tt> ) manipulator
+ stream the <code class="computeroutput"><span class="identifier">format</span></code> (or
+ <code class="computeroutput"><span class="identifier">format_delimited</span></code> ) manipulator
has been used with. This ensures all facets registered (imbued) with
the original I/O stream object are used during output generation.
</p></td></tr>
</table></div>
-<a name="spirit.karma.reference.stream.attributes"></a><h5>
-<a name="id577775"></a>
- Attributes
- </h5>
+<a name="spirit.karma.reference.stream.attributes"></a><h6>
+<a name="id1231738"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.attributes">Attributes</a>
+ </h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hold_any</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hold_any</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">wstream</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">>()</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hold_any</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">>()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hold_any</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">>()(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">stream_generator</span><span class="special"><</span><span class="identifier">Char</span><span class="special">>()(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The attribute type <tt class="computeroutput"><span class="identifier">hold_any</span></tt>
+<tr><td align="left" valign="top"><p>
+ The attribute type <code class="computeroutput"><span class="identifier">hold_any</span></code>
exposed by some of the stream generators is semantically and syntactically
- equivalent to the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">any</span></tt>.
+ equivalent to the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">any</span></code>.
It has been added to <span class="emphasis"><em>Spirit</em></span> as it has better a performance
- and a smaller footprint if compared to <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">any</span></tt>.
+ and a smaller footprint if compared to <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">any</span></code>.
</p></td></tr>
</table></div>
-<a name="spirit.karma.reference.stream.complexity"></a><h5>
-<a name="id578221"></a>
- Complexity
- </h5>
-<a name="spirit.karma.reference.stream.example"></a><h5>
-<a name="id578244"></a>
- Example
- </h5>
+<a name="spirit.karma.reference.stream.complexity"></a><h6>
+<a name="id1232069"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.complexity">Complexity</a>
+ </h6>
+<div class="blockquote"><blockquote class="blockquote">
+<p>
+ </p>
+<p>
+ O(N), where N is the number of characters emitted by the stream generator
+ </p>
+<p>
+ </p>
+</blockquote></div>
+<a name="spirit.karma.reference.stream.example"></a><h6>
+<a name="id1232093"></a>
+ <a class="link" href="stream.html#spirit.karma.reference.stream.example">Example</a>
+ </h6>
<p>
Some includes:
</p>
@@ -554,7 +685,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">stream</span></tt> generators:
+ Basic usage of <code class="computeroutput"><span class="identifier">stream</span></code> generators:
</p>
<p>
</p>
@@ -582,7 +713,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
-<a accesskey="p" href="operator/not_predicate.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
+<a accesskey="p" href="numeric/floating_point.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
Modified: trunk/libs/spirit/doc/html/spirit/karma/reference/string.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/reference/string.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/reference/string.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> String</title>
+<title>String</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="char/char_class.html" title=" Character
- Class Generators">
-<link rel="next" href="numeric.html" title=" Numeric">
+<link rel="prev" href="char/char_class.html" title="Character Class Generators">
+<link rel="next" href="numeric.html" title="Numeric">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,22 +22,19 @@
<div class="spirit-nav">
<a accesskey="p" href="char/char_class.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="numeric.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.reference.string"></a> String
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="String">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.reference.string"></a><a class="link" href="string.html" title="String"> String</a>
+</h4></div></div></div>
<p>
This module includes different string oriented generators allowing to output
- character sequences. It includes variants of the <tt class="computeroutput"><span class="identifier">string</span></tt>
+ character sequences. It includes variants of the <code class="computeroutput"><span class="identifier">string</span></code>
generator.
</p>
-<a name="spirit.karma.reference.string.description"></a><h5>
-<a name="id511117"></a>
- Description
- </h5>
+<a name="spirit.karma.reference.string.description"></a><h6>
+<a name="id1204536"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.description">Description</a>
+ </h6>
<p>
The string generators described in this section are:
</p>
@@ -48,105 +44,125 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt>,
- same as <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code>,
+ same as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generates the mandatory attribute as a string interpreted in the
- character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>
- </p></td>
+ character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generates <tt class="computeroutput"><span class="identifier">str</span></tt> as
- a character interpreted in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>, if an attribute is supplied
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generates <code class="computeroutput"><span class="identifier">str</span></code> as
+ a character interpreted in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>, if an attribute is supplied
it must match
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- In the table above, <tt class="computeroutput"><span class="identifier">ns</span></tt>
- is a <a href="karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
+ In the table above, <code class="computeroutput"><span class="identifier">ns</span></code>
+ is a <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.character_encoding_namespace">Character
Encoding Namespace</a> used by the corresponding string generator.
</p>
-<a name="spirit.karma.reference.string.header"></a><h5>
-<a name="id511477"></a>
- Header
- </h5>
+<a name="spirit.karma.reference.string.header"></a><h6>
+<a name="id1204799"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.header">Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/karma/string/lit.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">karma_string</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
-<a name="spirit.karma.reference.string.model_of"></a><h5>
-<a name="id511591"></a>
- Model of
- </h5>
+<a name="spirit.karma.reference.string.model_of"></a><h6>
+<a name="id1204874"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.model_of">Model of</a>
+ </h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveGenerator
+ <a class="link" href="generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">str</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">str</span></code></span></dt>
<dd><p>
Character-class specific string (See Character Class Types), or a
- <a href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
+ <a class="link" href="karma_basics.html#spirit.karma.reference.karma_basics.lazy_argument">Lazy
Argument</a> that evaluates to a character-class specific string
value
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
-<a name="spirit.karma.reference.string.expression_semantics"></a><h5>
-<a name="id511719"></a>
- <a href="string.html#spirit.karma.reference.string.expression_semantics">Expression
+<a name="spirit.karma.reference.string.expression_semantics"></a><h6>
+<a name="id1204962"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.expression_semantics">Expression
Semantics</a>
- </h5>
+ </h6>
<p>
Semantics of an expression is defined only where it differs from, or is
- not defined in PrimitiveGenerator.
+ not defined in <a class="link" href="generator_concepts/primitivegenerator.html" title="PrimitiveGenerator"><code class="computeroutput"><span class="identifier">PrimitiveGenerator</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -154,133 +170,173 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-<td><p>
- Generate the string literal <tt class="computeroutput"><span class="identifier">str</span></tt>.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the string literal <code class="computeroutput"><span class="identifier">str</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the string literal <tt class="computeroutput"><span class="identifier">str</span></tt>.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the string literal <code class="computeroutput"><span class="identifier">str</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate the string provided by a mandatory attribute interpreted
- in the character set defined by <tt class="computeroutput"><span class="identifier">ns</span></tt>.
+ in the character set defined by <code class="computeroutput"><span class="identifier">ns</span></code>.
This generator never fails (except if the underlying output stream
reports an error).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate the string <tt class="computeroutput"><span class="identifier">str</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate the string <code class="computeroutput"><span class="identifier">str</span></code>
as provided by the immediate literal value the generator is initialized
from. If this generator has an associated attribute it succeeds
only as long as the attribute is equal to the immediate literal
(except if the underlying output stream reports an error). Otherwise
this generator fails and does not generate any output.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The generators <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- and <tt class="computeroutput"><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- can be initialized either using a string literal value (i.e. <tt class="computeroutput"><span class="string">"abc"</span></tt>), or using a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">char_type</span><span class="special">,</span>
- <span class="special">...></span></tt>, where <tt class="computeroutput"><span class="identifier">char_type</span></tt>
+<tr><td align="left" valign="top"><p>
+ The generators <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ and <code class="computeroutput"><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ can be initialized either using a string literal value (i.e. <code class="computeroutput"><span class="string">"abc"</span></code>), or using a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">char_type</span><span class="special">,</span>
+ <span class="special">...></span></code>, where <code class="computeroutput"><span class="identifier">char_type</span></code>
is the required value type of the underlying character sequence.
</p></td></tr>
</table></div>
-<a name="spirit.karma.reference.string.attributes"></a><h5>
-<a name="id512160"></a>
- Attributes
- </h5>
+<a name="spirit.karma.reference.string.attributes"></a><h6>
+<a name="id1205273"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.attributes">Attributes</a>
+ </h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Str</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Str</span></code>, attribute
is mandatory (otherwise compilation will fail)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Str</span></tt>, attribute
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Str</span></code>, attribute
is optional, if it is supplied, the generator compares the attribute
- with <tt class="computeroutput"><span class="identifier">str</span></tt> and succeeds
+ with <code class="computeroutput"><span class="identifier">str</span></code> and succeeds
only if both are equal, failing otherwise
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<a name="spirit.karma.reference.string.complexity"></a><h5>
-<a name="id512445"></a>
- Complexity
- </h5>
+<a name="spirit.karma.reference.string.complexity"></a><h6>
+<a name="id1205488"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.complexity">Complexity</a>
+ </h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
@@ -290,10 +346,10 @@
<p>
</p>
</blockquote></div>
-<a name="spirit.karma.reference.string.example"></a><h5>
-<a name="id512481"></a>
- Example
- </h5>
+<a name="spirit.karma.reference.string.example"></a><h6>
+<a name="id1205512"></a>
+ <a class="link" href="string.html#spirit.karma.reference.string.example">Example</a>
+ </h6>
<p>
Some includes:
</p>
@@ -371,7 +427,7 @@
<p>
</p>
<p>
- Basic usage of <tt class="computeroutput"><span class="identifier">string</span></tt> generators:
+ Basic usage of <code class="computeroutput"><span class="identifier">string</span></code> generators:
</p>
<p>
</p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Tutorials</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../karma.html" title=" Karma - Writing Generators">
-<link rel="previous" href="../karma.html" title=" Karma - Writing Generators">
+<link rel="up" href="../karma.html" title="Karma - Writing Generators">
+<link rel="prev" href="../karma.html" title="Karma - Writing Generators">
<link rel="next" href="tutorials/quick_start.html" title="Quick Start">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../karma.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../karma.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tutorials/quick_start.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.karma.tutorials"></a>Tutorials
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Tutorials">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.karma.tutorials"></a><a class="link" href="tutorials.html" title="Tutorials">Tutorials</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Quick Start</span></dt>
<dt><span class="section">Warming up</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_attributes.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_attributes.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_attributes.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Understanding
- Generator Attributes</title>
+<title>Understanding Generator Attributes</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="karma_complex.html" title=" Complex - A
- first more complex generator">
-<link rel="next" href="karma_easier_complex.html" title=" Complex
- - Made easier">
+<link rel="prev" href="karma_complex.html" title="Complex - A first more complex generator">
+<link rel="next" href="karma_easier_complex.html" title="Complex - Made easier">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,31 +22,26 @@
<div class="spirit-nav">
<a accesskey="p" href="karma_complex.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="karma_easier_complex.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.karma_attributes"></a><a href="karma_attributes.html" title=" Understanding
- Generator Attributes"> Understanding
+<div class="section" title="Understanding Generator Attributes">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.karma_attributes"></a><a class="link" href="karma_attributes.html" title="Understanding Generator Attributes"> Understanding
Generator Attributes</a>
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.karma.tutorials.karma_attributes.attributes_of_primitive_generators"></a><h5>
-<a name="id479008"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_primitive_generators">Attributes
+</h4></div></div></div>
+<a name="spirit.karma.tutorials.karma_attributes.attributes_of_primitive_generators"></a><h6>
+<a name="id1168917"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_primitive_generators">Attributes
of Primitive Generators</a>
- </h5>
+ </h6>
<p>
Before we can start simplifying the complex number example from the previous
section we need to introduce the notion of generator attributes. Every
generator component in <span class="emphasis"><em>Spirit.Karma</em></span> exposes a specific
- attribute type. We have already seen that the attribute type of the <tt class="computeroutput"><span class="identifier">double_</span></tt> generator is <tt class="computeroutput"><span class="keyword">double</span></tt>.
+ attribute type. We have already seen that the attribute type of the <code class="computeroutput"><span class="identifier">double_</span></code> generator is <code class="computeroutput"><span class="keyword">double</span></code>.
Other primitive generator components have other intuitive attribute types,
- such as for instance <tt class="computeroutput"><span class="identifier">int_</span></tt>
- which has <tt class="computeroutput"><span class="keyword">int</span></tt>, or <tt class="computeroutput"><span class="identifier">ascii</span><span class="special">::</span><span class="identifier">char_</span></tt> which has <tt class="computeroutput"><span class="keyword">char</span></tt>.
+ such as for instance <code class="computeroutput"><span class="identifier">int_</span></code>
+ which has <code class="computeroutput"><span class="keyword">int</span></code>, or <code class="computeroutput"><span class="identifier">ascii</span><span class="special">::</span><span class="identifier">char_</span></code> which has <code class="computeroutput"><span class="keyword">char</span></code>.
For a full list of available generator primitives and their attribute types
- please see the section <a href="../quick_reference/primitive_generators.html" title="
- Primitive Generators">Primitive
+ please see the section <a class="link" href="../quick_reference/primitive_generators.html" title="Karma Generators">Primitive
Generators</a>.
</p>
<p>
@@ -58,7 +50,7 @@
the normal C++ convertibility rules apply. Any data type convertible to
the attribute type of a primitive generator can be used to provide the
data to generate. As an example, it is possible to use an integer value
- in conjunction with a <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ in conjunction with a <code class="computeroutput"><span class="identifier">double_</span></code>
generator:
</p>
<pre class="programlisting"><span class="comment">// the following generates: 1.0
@@ -66,11 +58,11 @@
<span class="identifier">std</span><span class="special">::</span><span class="identifier">back_insert_iterator</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">out</span><span class="special">(</span><span class="identifier">str</span><span class="special">);</span>
<span class="identifier">generate</span><span class="special">(</span><span class="identifier">out</span><span class="special">,</span> <span class="identifier">double_</span><span class="special">,</span> <span class="number">1</span><span class="special">);</span>
</pre>
-<a name="spirit.karma.tutorials.karma_attributes.attributes_of_compound_generators"></a><h5>
-<a name="id479304"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_compound_generators">Attributes
+<a name="spirit.karma.tutorials.karma_attributes.attributes_of_compound_generators"></a><h6>
+<a name="id1172035"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_compound_generators">Attributes
of Compound Generators</a>
- </h5>
+ </h6>
<p>
<span class="emphasis"><em>Spirit.Karma</em></span> implements well defined attribute type
propagation rules for all compound generators, such as sequences, alternatives,
@@ -86,35 +78,35 @@
<p>
</p>
<p>
- Given <tt class="computeroutput"><span class="identifier">a</span></tt> and <tt class="computeroutput"><span class="identifier">b</span></tt> are generators, and <tt class="computeroutput"><span class="identifier">A</span></tt> is the attribute type of <tt class="computeroutput"><span class="identifier">a</span></tt>, and <tt class="computeroutput"><span class="identifier">B</span></tt>
- is the attribute type of <tt class="computeroutput"><span class="identifier">b</span></tt>,
- then the attribute type of <tt class="computeroutput"><span class="identifier">a</span>
- <span class="special"><<</span> <span class="identifier">b</span></tt>
- will be <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>.
+ Given <code class="computeroutput"><span class="identifier">a</span></code> and <code class="computeroutput"><span class="identifier">b</span></code> are generators, and <code class="computeroutput"><span class="identifier">A</span></code> is the attribute type of <code class="computeroutput"><span class="identifier">a</span></code>, and <code class="computeroutput"><span class="identifier">B</span></code>
+ is the attribute type of <code class="computeroutput"><span class="identifier">b</span></code>,
+ then the attribute type of <code class="computeroutput"><span class="identifier">a</span>
+ <span class="special"><<</span> <span class="identifier">b</span></code>
+ will be <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>.
</p>
<p>
</p>
</blockquote></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- The notation <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>
+<tr><td align="left" valign="top"><p>
+ The notation <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>
is used as a placeholder expression for any fusion sequence holding the
- types A and B, such as <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt> or <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pair</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt> (for more information see Fusion).
+ types A and B, such as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code> or <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pair</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code> (for more information see Fusion).
</p></td></tr>
</table></div>
<p>
As you can see, in order for a type to be compatible with the attribute
type of a <span class="emphasis"><em>Spirit.Karma</em></span> compound generator it has to
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
either be convertible to the attribute type,
</li>
-<li>
+<li class="listitem">
or it has to expose certain functionalities, i.e. it needs to conform
to a concept compatible with the generator.
</li>
@@ -122,15 +114,14 @@
<p>
Each compound generator implements its own set of attribute propagation
rules. For a full list of how the different compound generators consume
- attributes see the section <a href="../quick_reference/compound_attribute_rules.html" title="Compound
- Attribute Rules">Compound
+ attributes see the section <a class="link" href="../quick_reference/compound_attribute_rules.html" title="Compound Attribute Rules">Compound
Attribute Rules</a>.
</p>
-<a name="spirit.karma.tutorials.karma_attributes.the_attribute_of_sequence_generators"></a><h5>
-<a name="id479809"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.the_attribute_of_sequence_generators">The
+<a name="spirit.karma.tutorials.karma_attributes.the_attribute_of_sequence_generators"></a><h6>
+<a name="id1172380"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.the_attribute_of_sequence_generators">The
Attribute of Sequence Generators</a>
- </h5>
+ </h6>
<p>
Sequences require an attribute type to expose the concept of a fusion sequence,
where all elements of that fusion sequence have to be compatible with the
@@ -141,14 +132,14 @@
</pre>
<p>
is able to consume any fusion sequence holding two types, where both types
- have to be convertible to <tt class="computeroutput"><span class="keyword">double</span></tt>.
+ have to be convertible to <code class="computeroutput"><span class="keyword">double</span></code>.
The first element of the fusion sequence has to be compatible with the
- attribute of the first <tt class="computeroutput"><span class="identifier">double_</span></tt>
- (i.e. it needs to be convertible to a <tt class="computeroutput"><span class="keyword">double</span></tt>),
+ attribute of the first <code class="computeroutput"><span class="identifier">double_</span></code>
+ (i.e. it needs to be convertible to a <code class="computeroutput"><span class="keyword">double</span></code>),
and the second element of the fusion sequence has to be compatible with
- the attribute of the second <tt class="computeroutput"><span class="identifier">double_</span></tt>
- (i.e. convertible to a <tt class="computeroutput"><span class="keyword">double</span></tt>
- as well). If we assume to have an instance of a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pair</span><span class="special"><</span><span class="keyword">double</span><span class="special">,</span> <span class="keyword">double</span><span class="special">></span></tt>, we can directly use the expression
+ the attribute of the second <code class="computeroutput"><span class="identifier">double_</span></code>
+ (i.e. convertible to a <code class="computeroutput"><span class="keyword">double</span></code>
+ as well). If we assume to have an instance of a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">pair</span><span class="special"><</span><span class="keyword">double</span><span class="special">,</span> <span class="keyword">double</span><span class="special">></span></code>, we can directly use the expression
above to generate output for it:
</p>
<pre class="programlisting"><span class="comment">// the following generates: 1.0 2.0
@@ -160,23 +151,23 @@
</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">make_pair</span><span class="special">(</span><span class="number">1.0</span><span class="special">,</span> <span class="number">2.0</span><span class="special">));</span> <span class="comment">// data to use as the attribute
</span></pre>
<p>
- (where the <tt class="computeroutput"><span class="identifier">space</span></tt> generator
+ (where the <code class="computeroutput"><span class="identifier">space</span></code> generator
is used as the delimiter, allowing to automatically insert delimiting spaces
in between all primitives).
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- <span class="bold"><b>For sequences only:</b></span> <span class="emphasis"><em>Spirit.Karma</em></span>
+ <span class="bold"><strong>For sequences only:</strong></span> <span class="emphasis"><em>Spirit.Karma</em></span>
exposes a set of API functions usable mainly with sequences. Very much
- like the functions of the <tt class="computeroutput"><span class="identifier">printf</span></tt>
+ like the functions of the <code class="computeroutput"><span class="identifier">printf</span></code>
family these functions allow to pass the attributes for each of the elements
of the sequence separately. Using the corresponding overload of <span class="emphasis"><em>Karma's</em></span>
- <tt class="computeroutput"><span class="identifier">generate</span><span class="special">()</span></tt>
+ <code class="computeroutput"><span class="identifier">generate</span><span class="special">()</span></code>
the expression above could be rewritten as:
</p>
<p>
@@ -186,18 +177,18 @@
<p>
</p>
<p>
- where the first attribute (<tt class="computeroutput"><span class="number">1.0</span></tt>)
- is used for the first <tt class="computeroutput"><span class="identifier">double_</span></tt>,
- and the second attribute (<tt class="computeroutput"><span class="number">2.0</span></tt>)
- is used for the second <tt class="computeroutput"><span class="identifier">double_</span></tt>.
+ where the first attribute (<code class="computeroutput"><span class="number">1.0</span></code>)
+ is used for the first <code class="computeroutput"><span class="identifier">double_</span></code>,
+ and the second attribute (<code class="computeroutput"><span class="number">2.0</span></code>)
+ is used for the second <code class="computeroutput"><span class="identifier">double_</span></code>.
</p>
</td></tr>
</table></div>
-<a name="spirit.karma.tutorials.karma_attributes.the_attribute_of_alternative_generators"></a><h5>
-<a name="id480424"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.the_attribute_of_alternative_generators">The
+<a name="spirit.karma.tutorials.karma_attributes.the_attribute_of_alternative_generators"></a><h6>
+<a name="id1172797"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.the_attribute_of_alternative_generators">The
Attribute of Alternative Generators</a>
- </h5>
+ </h6>
<p>
Alternative generators are all about - well - alternatives. In order to
store possibly different result (attribute) types from the different alternatives
@@ -207,7 +198,7 @@
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
</pre>
<p>
- where the <tt class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></tt>
+ where the <code class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></code>
is again a placeholder for the concept of a Boost.Variant.
Any other data type exposing the required concepts can be used instead
(for more information about attribute compatibility and attribute concepts
@@ -222,25 +213,25 @@
type, the overall alternative will expose exactly the attribute type as
well. We will apply this rule later for our complex number generators.
</p>
-<a name="spirit.karma.tutorials.karma_attributes.more_about_attributes_of_compound_generators"></a><h5>
-<a name="id480710"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.more_about_attributes_of_compound_generators">More
+<a name="spirit.karma.tutorials.karma_attributes.more_about_attributes_of_compound_generators"></a><h6>
+<a name="id1172994"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.more_about_attributes_of_compound_generators">More
About Attributes of Compound Generators</a>
- </h5>
+ </h6>
<p>
While generating output it is often desirable to combine some constant
elements with variable parts. For instance, if we go back to our example
- of formatting a complex number, we need to write it as <tt class="computeroutput"><span class="special">(</span><span class="identifier">real</span><span class="special">,</span> <span class="identifier">imag</span><span class="special">)</span></tt>,
- where <tt class="computeroutput"><span class="identifier">real</span></tt> and <tt class="computeroutput"><span class="identifier">imag</span> </tt> are the variables representing
+ of formatting a complex number, we need to write it as <code class="computeroutput"><span class="special">(</span><span class="identifier">real</span><span class="special">,</span> <span class="identifier">imag</span><span class="special">)</span></code>,
+ where <code class="computeroutput"><span class="identifier">real</span></code> and <code class="computeroutput"><span class="identifier">imag</span> </code> are the variables representing
the real and imaginary parts of our complex number. As we have already
seen, this can be achieved by writing
</p>
<pre class="programlisting"><span class="char">'('</span> <span class="special"><<</span> <span class="identifier">double_</span> <span class="special"><<</span> <span class="string">", "</span> <span class="special"><<</span> <span class="identifier">double_</span> <span class="special"><<</span> <span class="char">')'</span>
</pre>
<p>
- Fortunately, literals (such as <tt class="computeroutput"><span class="char">'('</span></tt>
- and <tt class="computeroutput"><span class="string">", "</span></tt>) do <span class="emphasis"><em>not</em></span>
- expose any attribute (well actually, they do expose the special type <tt class="computeroutput"><span class="identifier">unused_type</span></tt>, but in this context <tt class="computeroutput"><span class="identifier">unused_type</span></tt> is interpreted as if the
+ Fortunately, literals (such as <code class="computeroutput"><span class="char">'('</span></code>
+ and <code class="computeroutput"><span class="string">", "</span></code>) do <span class="emphasis"><em>not</em></span>
+ expose any attribute (well actually, they do expose the special type <code class="computeroutput"><span class="identifier">unused_type</span></code>, but in this context <code class="computeroutput"><span class="identifier">unused_type</span></code> is interpreted as if the
generator does not expose any attribute at all). It is very important to
understand that the literals don't consume any of the elements of a fusion
sequence passed to this generator sequence. As said, they just don't expose
@@ -255,24 +246,24 @@
</span></pre>
<p>
where the first element of the pair passed in as the data to generate is
- still associated with the first <tt class="computeroutput"><span class="identifier">double_</span></tt>,
- and the second element is associated with the second <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ still associated with the first <code class="computeroutput"><span class="identifier">double_</span></code>,
+ and the second element is associated with the second <code class="computeroutput"><span class="identifier">double_</span></code>
generator.
</p>
<p>
This behavior should be familiar as it conforms to the way other output
- formatting libraries such as <tt class="computeroutput"><span class="identifier">printf</span></tt>
- or <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">format</span></tt> are handling their variable parts.
+ formatting libraries such as <code class="computeroutput"><span class="identifier">printf</span></code>
+ or <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">format</span></code> are handling their variable parts.
In this context you can think about <span class="emphasis"><em>Spirit.Karma</em></span>'s
- primitive generators (such as the <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ primitive generators (such as the <code class="computeroutput"><span class="identifier">double_</span></code>
above) as of being typesafe placeholders for the attribute values to print.
</p>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
Similarly to the tip provided above, this example could be rewritten
using <span class="emphasis"><em>Karma's</em></span> multi-attribute API function:
@@ -285,15 +276,15 @@
</p>
<p>
which provides a clear and comfortable syntax, more similar to the placeholder
- based syntax as exposed by <tt class="computeroutput"><span class="identifier">printf</span></tt>
- or <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">format</span></tt>.
+ based syntax as exposed by <code class="computeroutput"><span class="identifier">printf</span></code>
+ or <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">format</span></code>.
</p>
</td></tr>
</table></div>
<p>
Let's take a look at this from a more formal perspective. The sequence
attribute propagation rules define a special behavior if generators exposing
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt> as their attribute
+ <code class="computeroutput"><span class="identifier">unused_type</span></code> as their attribute
are involved:
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special"><<</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">A</span>
@@ -305,13 +296,13 @@
<p>
</p>
<p>
- Given <tt class="computeroutput"><span class="identifier">a</span></tt> and <tt class="computeroutput"><span class="identifier">b</span></tt> are generators, and <tt class="computeroutput"><span class="identifier">A</span></tt> is the attribute type of <tt class="computeroutput"><span class="identifier">a</span></tt>, and <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
- is the attribute type of <tt class="computeroutput"><span class="identifier">b</span></tt>,
- then the attribute type of <tt class="computeroutput"><span class="identifier">a</span>
- <span class="special"><<</span> <span class="identifier">b</span></tt>
- will be <tt class="computeroutput"><span class="identifier">A</span></tt> as well.
+ Given <code class="computeroutput"><span class="identifier">a</span></code> and <code class="computeroutput"><span class="identifier">b</span></code> are generators, and <code class="computeroutput"><span class="identifier">A</span></code> is the attribute type of <code class="computeroutput"><span class="identifier">a</span></code>, and <code class="computeroutput"><span class="identifier">unused_type</span></code>
+ is the attribute type of <code class="computeroutput"><span class="identifier">b</span></code>,
+ then the attribute type of <code class="computeroutput"><span class="identifier">a</span>
+ <span class="special"><<</span> <span class="identifier">b</span></code>
+ will be <code class="computeroutput"><span class="identifier">A</span></code> as well.
This rule applies regardless of the position the element exposing the
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt> is at.
+ <code class="computeroutput"><span class="identifier">unused_type</span></code> is at.
</p>
<p>
</p>
@@ -319,7 +310,7 @@
<p>
This rule is the key to the understanding of the attribute handling in
sequences as soon as literals are involved. It is as if elements with
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt> attributes
+ <code class="computeroutput"><span class="identifier">unused_type</span></code> attributes
'disappeared' during attribute propagation. Notably, this is not only true
for sequences but for any compound generator in <span class="emphasis"><em>Spirit.Karma</em></span>.
For instance, for alternative generators the corresponding rule is:
@@ -329,18 +320,18 @@
<p>
again, allowing to simplify the overall attribute type of an expression.
</p>
-<a name="spirit.karma.tutorials.karma_attributes.attributes_of_rules_and_grammars"></a><h5>
-<a name="id481784"></a>
- <a href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_rules_and_grammars">Attributes
+<a name="spirit.karma.tutorials.karma_attributes.attributes_of_rules_and_grammars"></a><h6>
+<a name="id1173730"></a>
+ <a class="link" href="karma_attributes.html#spirit.karma.tutorials.karma_attributes.attributes_of_rules_and_grammars">Attributes
of Rules and Grammars</a>
- </h5>
-<div class="itemizedlist"><ul type="disc">
-<li>
+ </h6>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
explicit attribute type
</li>
-<li>
+<li class="listitem">
attribute propagation
- <div class="itemizedlist"><ul type="circle"><li>
+ <div class="itemizedlist"><ul class="itemizedlist" type="circle"><li class="listitem">
explicit and operator%=
</li></ul></div>
</li>
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_complex.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_complex.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_complex.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Complex - A
- first more complex generator</title>
+<title>Complex - A first more complex generator</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="semantic_actions.html" title="Semantic Actions">
-<link rel="next" href="karma_attributes.html" title=" Understanding
- Generator Attributes">
+<link rel="prev" href="semantic_actions.html" title="Semantic Actions">
+<link rel="next" href="karma_attributes.html" title="Understanding Generator Attributes">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,20 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="karma_attributes.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.karma_complex"></a><a href="karma_complex.html" title=" Complex - A
- first more complex generator"> Complex - A
+<div class="section" title="Complex - A first more complex generator">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.karma_complex"></a><a class="link" href="karma_complex.html" title="Complex - A first more complex generator"> Complex - A
first more complex generator</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
In this section we will develop a generator for complex numbers, allowing
- to represent a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">complex</span></tt> either as <tt class="computeroutput"><span class="special">(</span><span class="identifier">real</span><span class="special">,</span> <span class="identifier">imag</span><span class="special">)</span></tt>
- (where <tt class="computeroutput"><span class="identifier">real</span></tt> and <tt class="computeroutput"><span class="identifier">imag</span></tt> are the real and imaginary parts
- of the complex number) or as a simple <tt class="computeroutput"><span class="identifier">real</span></tt>
+ to represent a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">complex</span></code> either as <code class="computeroutput"><span class="special">(</span><span class="identifier">real</span><span class="special">,</span> <span class="identifier">imag</span><span class="special">)</span></code>
+ (where <code class="computeroutput"><span class="identifier">real</span></code> and <code class="computeroutput"><span class="identifier">imag</span></code> are the real and imaginary parts
+ of the complex number) or as a simple <code class="computeroutput"><span class="identifier">real</span></code>
if the imaginary part happens to be equal to zero. This example will highlight
the power of <span class="emphasis"><em>Spirit.Karma</em></span> allowing to combine compile
time definition of formatting rules with runtime based decisions which
@@ -56,7 +50,7 @@
where the first alternative should be used for numbers having a non-zero
imaginary part, while the second is for real numbers. Generally, alternatives
are tried in the sequence of their definition as long until one of the
- expressions (as delimited by <tt class="computeroutput"><span class="char">'|'</span></tt>)
+ expressions (as delimited by <code class="computeroutput"><span class="char">'|'</span></code>)
succeeds. If no generator expression succeeds the whole alternative fails.
</p>
<p>
@@ -66,7 +60,7 @@
alternative will be chosen instead. The decision about whether to choose
the first alternative has to be made at runtime as only then we actually
know the value of the imaginary part of the complex number. <span class="emphasis"><em>Spirit.Karma</em></span>
- provides us with with a primitive generator <tt class="computeroutput"><span class="identifier">eps</span><span class="special">()</span></tt>, which is usable as a semantic predicate.
+ provides us with with a primitive generator <code class="computeroutput"><span class="identifier">eps</span><span class="special">()</span></code>, which is usable as a semantic predicate.
It has the property to 'succeed' generating only if its argument is true
(while it never generates any output on its own).
</p>
@@ -85,7 +79,7 @@
(The full cpp file for this example can be found here: complex_number.cpp).
</p>
<p>
- We will use the <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">complex</span></tt> type for this and all subsequent
+ We will use the <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">complex</span></code> type for this and all subsequent
related examples. And here you can see the full code of the generator allowing
to output a complex number either as a pair of numbers (if the imaginary
part is non-zero) or as a single number (if the complex is a real number):
@@ -119,23 +113,23 @@
<p>
</p>
<p>
- The <tt class="computeroutput"><span class="identifier">double_</span></tt> generators
+ The <code class="computeroutput"><span class="identifier">double_</span></code> generators
have this semantic action attached:
</p>
<pre class="programlisting"><span class="identifier">_1</span> <span class="special">=</span> <span class="identifier">n</span>
</pre>
<p>
- which passes <tt class="computeroutput"><span class="identifier">n</span></tt> to the first
+ which passes <code class="computeroutput"><span class="identifier">n</span></code> to the first
element of the generator the semantic action is attached to. Remember,
semantic actions in <span class="emphasis"><em>Spirit.Karma</em></span> are called before
the corresponding generator is invoked and they are expected to provide
the generator with the data to be used. The semantic action above assigns
- the value to be generated (<tt class="computeroutput"><span class="identifier">n</span></tt>)
- to the generator (actually, the attribute of <tt class="computeroutput"><span class="identifier">double_</span></tt>).
- <tt class="computeroutput"><span class="identifier">_1</span></tt> is a Phoenix placeholder
+ the value to be generated (<code class="computeroutput"><span class="identifier">n</span></code>)
+ to the generator (actually, the attribute of <code class="computeroutput"><span class="identifier">double_</span></code>).
+ <code class="computeroutput"><span class="identifier">_1</span></code> is a Phoenix placeholder
referring to the attribute of the generator the semantic action is attached
to. If you need more information about semantic actions, you may want to
- read about those in this section: <a href="semantic_actions.html" title="Semantic Actions">Semantic
+ read about those in this section: <a class="link" href="semantic_actions.html" title="Semantic Actions">Semantic
Actions</a>.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_easier_complex.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_easier_complex.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/karma_easier_complex.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Complex
- - Made easier</title>
+<title>Complex - Made easier</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="karma_attributes.html" title=" Understanding
- Generator Attributes">
+<link rel="prev" href="karma_attributes.html" title="Understanding Generator Attributes">
<link rel="next" href="../quick_reference.html" title="Quick Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -24,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="karma_attributes.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.karma_easier_complex"></a><a href="karma_easier_complex.html" title=" Complex
- - Made easier"> Complex
+<div class="section" title="Complex - Made easier">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.karma_easier_complex"></a><a class="link" href="karma_easier_complex.html" title="Complex - Made easier"> Complex
- Made easier</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
In one of the previous sections we showed how to format a complex number
(i.e. a pair of doubles). In this section we will build on this example
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/quick_start.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/quick_start.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/quick_start.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Quick Start</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="../tutorials.html" title="Tutorials">
+<link rel="prev" href="../tutorials.html" title="Tutorials">
<link rel="next" href="warming_up.html" title="Warming up">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,32 +22,29 @@
<div class="spirit-nav">
<a accesskey="p" href="../tutorials.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="warming_up.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.quick_start"></a>Quick Start
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.karma.tutorials.quick_start.spirit_karma___what_s_that_"></a><h5>
-<a name="id474209"></a>
- <a href="quick_start.html#spirit.karma.tutorials.quick_start.spirit_karma___what_s_that_">Spirit.Karma
+<div class="section" title="Quick Start">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.quick_start"></a><a class="link" href="quick_start.html" title="Quick Start">Quick Start</a>
+</h4></div></div></div>
+<a name="spirit.karma.tutorials.quick_start.spirit_karma___what_s_that_"></a><h6>
+<a name="id1165333"></a>
+ <a class="link" href="quick_start.html#spirit.karma.tutorials.quick_start.spirit_karma___what_s_that_">Spirit.Karma
- what's that?</a>
- </h5>
+ </h6>
<p>
Throughout the description of <span class="emphasis"><em>Spirit.Karma</em></span> we will
try to align ourselves very much with the documentation for <span class="emphasis"><em>Spirit.Qi</em></span>.
The reasons are manyfold:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
<span class="emphasis"><em>Spirit.Karma</em></span> is the counterpart to <span class="emphasis"><em>Spirit.Qi</em></span>.
Some people say it's the Yin to <span class="emphasis"><em>Spirit.Qi</em></span>'s Yang.
<span class="emphasis"><em>Spirit.Karma</em></span> is to generating byte sequences from
internal data structures as <span class="emphasis"><em>Spirit.Qi</em></span> is parsing
byte sequences into those (very same) internal data structures.
</li>
-<li>
+<li class="listitem">
Both libraries have an almost identical structure, very similar semantics,
and are both built using identical tools. Both libraries implement a
language casting the specifics of their domain (parsing and generating)
@@ -64,8 +61,7 @@
maintainabilty, and flexibility of the code. Last, but not least, it turns
out that code using <span class="emphasis"><em>Spirit.Karma</em></span> runs much faster
than equivalent code using either of the 'straight' methods mentioned above
- (see here for some numbers: <a href="../performance_measurements/numeric_performance.html" title="
- Performance of Numeric Generators">Performance
+ (see here for some numbers: <a class="link" href="../performance_measurements/numeric_performance.html" title="Performance of Numeric Generators">Performance
of Numeric Generators</a>)
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/semantic_actions.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/semantic_actions.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/semantic_actions.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Semantic Actions</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="warming_up.html" title="Warming up">
-<link rel="next" href="karma_complex.html" title=" Complex - A
- first more complex generator">
+<link rel="prev" href="warming_up.html" title="Warming up">
+<link rel="next" href="karma_complex.html" title="Complex - A first more complex generator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,19 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="warming_up.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="karma_complex.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.semantic_actions"></a>Semantic Actions
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Semantic Actions">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.semantic_actions"></a><a class="link" href="semantic_actions.html" title="Semantic Actions">Semantic Actions</a>
+</h4></div></div></div>
<p>
In the previous section we mentioned a very important difference between
parsers and generators. While parsers may be used without 'producing' any
data, generators alsways need data to generate the output from. We mentioned
one way of passing data to the generator by supplying it as a parameter
- to one of the main API functions (for instance <tt class="computeroutput"><span class="identifier">generate</span><span class="special">()</span></tt> or <tt class="computeroutput"><span class="identifier">generate_delimited</span><span class="special">()</span></tt>). But sometimes this is not possible
+ to one of the main API functions (for instance <code class="computeroutput"><span class="identifier">generate</span><span class="special">()</span></code> or <code class="computeroutput"><span class="identifier">generate_delimited</span><span class="special">()</span></code>). But sometimes this is not possible
or not desireable.
</p>
<p>
@@ -43,16 +39,16 @@
in <span class="emphasis"><em>Spirit.Karma</em></span> as well. Semantic actions may be attached
to any point in the grammar specification. These actions are C++ functions
or function objects that are called whenever a part of the generator is
- about to be invoked. Say you have a generator <tt class="computeroutput"><span class="identifier">G</span></tt>,
- and a C++ function <tt class="computeroutput"><span class="identifier">F</span></tt>, you
- can make the generator call <tt class="computeroutput"><span class="identifier">F</span></tt>
- just before it gets invoked by attaching <tt class="computeroutput"><span class="identifier">F</span></tt>:
+ about to be invoked. Say you have a generator <code class="computeroutput"><span class="identifier">G</span></code>,
+ and a C++ function <code class="computeroutput"><span class="identifier">F</span></code>, you
+ can make the generator call <code class="computeroutput"><span class="identifier">F</span></code>
+ just before it gets invoked by attaching <code class="computeroutput"><span class="identifier">F</span></code>:
</p>
<pre class="programlisting"><span class="identifier">G</span><span class="special">[</span><span class="identifier">F</span><span class="special">]</span>
</pre>
<p>
- The expression above links <tt class="computeroutput"><span class="identifier">F</span></tt>
- to the generator, <tt class="computeroutput"><span class="identifier">G</span></tt>.
+ The expression above links <code class="computeroutput"><span class="identifier">F</span></code>
+ to the generator, <code class="computeroutput"><span class="identifier">G</span></code>.
</p>
<p>
Semantic actions in <span class="emphasis"><em>Spirit.Qi</em></span> are invoked after a
@@ -63,34 +59,34 @@
</p>
<p>
The function/function object signature depends on the type of the generator
- to which it is attached. The generator <tt class="computeroutput"><span class="identifier">double_</span></tt>
+ to which it is attached. The generator <code class="computeroutput"><span class="identifier">double_</span></code>
expects the number to generate. Thus, if we were to attach a function
- <tt class="computeroutput"><span class="identifier">F</span></tt> to <tt class="computeroutput"><span class="identifier">double_</span></tt>,
- we need <tt class="computeroutput"><span class="identifier">F</span></tt> to be declared
+ <code class="computeroutput"><span class="identifier">F</span></code> to <code class="computeroutput"><span class="identifier">double_</span></code>,
+ we need <code class="computeroutput"><span class="identifier">F</span></code> to be declared
as:
</p>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">F</span><span class="special">(</span><span class="keyword">double</span><span class="special">&</span> <span class="identifier">n</span><span class="special">);</span>
</pre>
<p>
- where the function is expected to initialize the parameter <tt class="computeroutput"><span class="identifier">n</span></tt> with the value to generate.
+ where the function is expected to initialize the parameter <code class="computeroutput"><span class="identifier">n</span></code> with the value to generate.
</p>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- Generally, and more formally, the semantic action <tt class="computeroutput"><span class="identifier">F</span></tt>
- attached to a generator <tt class="computeroutput"><span class="identifier">G</span></tt>
+ Generally, and more formally, the semantic action <code class="computeroutput"><span class="identifier">F</span></code>
+ attached to a generator <code class="computeroutput"><span class="identifier">G</span></code>
needs to take a reference to the generators attribute type as its first
parameter. For more information about generatpor attributes please see
the section Generator Attributes.
</p>
<p>
- In the example above the function F takes a <tt class="computeroutput"><span class="keyword">double</span><span class="special">&</span></tt> as its first parameter as the attribute
- of the <tt class="computeroutput"><span class="identifier">double_</span></tt> generator
- happens to be a <tt class="computeroutput"><span class="keyword">double</span></tt>.
+ In the example above the function F takes a <code class="computeroutput"><span class="keyword">double</span><span class="special">&</span></code> as its first parameter as the attribute
+ of the <code class="computeroutput"><span class="identifier">double_</span></code> generator
+ happens to be a <code class="computeroutput"><span class="keyword">double</span></code>.
</p>
</td></tr>
</table></div>
@@ -104,22 +100,22 @@
<p>
In the follwoing example we present various ways to attach semantic actions:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Using plain function pointer
</li>
-<li>
+<li class="listitem">
Using simple function object
</li>
-<li>
+<li class="listitem">
Using Boost.Bind
with a plain function
</li>
-<li>
+<li class="listitem">
Using Boost.Bind
with a member function
</li>
-<li>
+<li class="listitem">
Using Boost.Lambda
</li>
</ul></div>
@@ -165,11 +161,11 @@
<p>
</p>
<p>
- Take note that with function objects, we need to have an <tt class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></tt>
+ Take note that with function objects, we need to have an <code class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></code>
with 3 arguments. Since we don't care about the other two, we can use
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt> for these.
- We'll see more of <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
- elsewhere. Get used to it. <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ <code class="computeroutput"><span class="identifier">unused_type</span></code> for these.
+ We'll see more of <code class="computeroutput"><span class="identifier">unused_type</span></code>
+ elsewhere. Get used to it. <code class="computeroutput"><span class="identifier">unused_type</span></code>
is a Spirit supplied support class. Most of the time it stands for 'I don't
care, just use the appropriate default'.
</p>
@@ -196,8 +192,8 @@
<p>
</p>
<p>
- What's new? Well <tt class="computeroutput"><span class="identifier">int_</span></tt> is
- the sibbling of <tt class="computeroutput"><span class="identifier">double_</span></tt>.
+ What's new? Well <code class="computeroutput"><span class="identifier">int_</span></code> is
+ the sibbling of <code class="computeroutput"><span class="identifier">double_</span></code>.
I'm sure you can guess what this generator does and what type of attribute
it expects.
</p>
@@ -272,10 +268,10 @@
<p>
The examples above can be found here: actions.cpp
</p>
-<a name="spirit.karma.tutorials.semantic_actions.phoenix"></a><h5>
-<a name="id477700"></a>
- Phoenix
- </h5>
+<a name="spirit.karma.tutorials.semantic_actions.phoenix"></a><h6>
+<a name="id1168023"></a>
+ <a class="link" href="semantic_actions.html#spirit.karma.tutorials.semantic_actions.phoenix">Phoenix</a>
+ </h6>
<p>
<a href="../../../../../phoenix/doc/html/index.html" target="_top">Phoenix</a>, a companion
library bundled with Spirit, is specifically suited for binding semantic
Modified: trunk/libs/spirit/doc/html/spirit/karma/tutorials/warming_up.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/karma/tutorials/warming_up.html (original)
+++ trunk/libs/spirit/doc/html/spirit/karma/tutorials/warming_up.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Warming up</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="quick_start.html" title="Quick Start">
+<link rel="prev" href="quick_start.html" title="Quick Start">
<link rel="next" href="semantic_actions.html" title="Semantic Actions">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,22 +22,19 @@
<div class="spirit-nav">
<a accesskey="p" href="quick_start.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.karma.tutorials.warming_up"></a>Warming up
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Warming up">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.karma.tutorials.warming_up"></a><a class="link" href="warming_up.html" title="Warming up">Warming up</a>
+</h4></div></div></div>
<p>
Learning how to use <span class="emphasis"><em>Spirit.Karma</em></span> is really simple.
We will start from trivial examples, ramping up as we go.
</p>
-<a name="spirit.karma.tutorials.warming_up.trivial_example__1_generating_a_number"></a><h5>
-<a name="id474414"></a>
- <a href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__1_generating_a_number">Trivial
+<a name="spirit.karma.tutorials.warming_up.trivial_example__1_generating_a_number"></a><h6>
+<a name="id1165459"></a>
+ <a class="link" href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__1_generating_a_number">Trivial
Example #1 Generating a number</a>
- </h5>
+ </h6>
<p>
Let's create a generator that will output a floating-point number:
</p>
@@ -51,13 +48,13 @@
entities (as in this case, floating point numbers) are named identically
in <span class="emphasis"><em>Spirit.Karma</em></span> and in <span class="emphasis"><em>Spirit.Qi</em></span>.
Actually, both libraries are using the very same variable instance to refer
- to a floating point generator or parser: <tt class="computeroutput"><span class="identifier">double_</span></tt>.
+ to a floating point generator or parser: <code class="computeroutput"><span class="identifier">double_</span></code>.
</p>
-<a name="spirit.karma.tutorials.warming_up.trivial_example__2_generating_two_numbers"></a><h5>
-<a name="id474485"></a>
- <a href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__2_generating_two_numbers">Trivial
+<a name="spirit.karma.tutorials.warming_up.trivial_example__2_generating_two_numbers"></a><h6>
+<a name="id1165502"></a>
+ <a class="link" href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__2_generating_two_numbers">Trivial
Example #2 Generating two numbers</a>
- </h5>
+ </h6>
<p>
Now, let's create a generator that will output a line consisting of two
floating-point numbers.
@@ -65,37 +62,37 @@
<pre class="programlisting"><span class="identifier">double_</span> <span class="special"><<</span> <span class="identifier">double_</span>
</pre>
<p>
- Here you see the familiar floating-point numeric generator <tt class="computeroutput"><span class="identifier">double_</span></tt> used twice, once for each number.
- If you are used to see the <tt class="computeroutput"><span class="char">'>>'</span></tt>
+ Here you see the familiar floating-point numeric generator <code class="computeroutput"><span class="identifier">double_</span></code> used twice, once for each number.
+ If you are used to see the <code class="computeroutput"><span class="char">'>>'</span></code>
operator for concatenating two parsers in <span class="emphasis"><em>Spirit.Qi</em></span>
- you might wonder, what's that <tt class="computeroutput"><span class="char">'<<'</span></tt>
+ you might wonder, what's that <code class="computeroutput"><span class="char">'<<'</span></code>
operator doing in there? We decided to distinguish generating and parsing
of sequences the same way as the std::stream libraries do: we use operator
- <tt class="computeroutput"><span class="char">'>>'</span></tt> for input (parsing),
- and operator <tt class="computeroutput"><span class="char">'<<'</span></tt> for output
+ <code class="computeroutput"><span class="char">'>>'</span></code> for input (parsing),
+ and operator <code class="computeroutput"><span class="char">'<<'</span></code> for output
(generating). Other than that there is no significant difference. The above
program creates a generator from two simpler generators, glueing them together
with the sequence operator. The result is a generator that is a composition
of smaller generators. Whitespace between numbers can implicitly be inserted
depending on how the generator is invoked (see below).
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
When we combine generators, we end up with a "bigger" generator,
but it's still a generator. Generators can get bigger and bigger, nesting
more and more, but whenever you glue two generators together, you end
up with one bigger generator. This is an important concept.
</p></td></tr>
</table></div>
-<a name="spirit.karma.tutorials.warming_up.trivial_example__3_generating_one_or_more_numbers"></a><h5>
-<a name="id474633"></a>
- <a href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__3_generating_one_or_more_numbers">Trivial
+<a name="spirit.karma.tutorials.warming_up.trivial_example__3_generating_one_or_more_numbers"></a><h6>
+<a name="id1165587"></a>
+ <a class="link" href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__3_generating_one_or_more_numbers">Trivial
Example #3 Generating one or more numbers</a>
- </h5>
+ </h6>
<p>
Now, creating output for two numbers is not too interesting. Let's create
a generator that will output zero or more floating-point numbers in a row.
@@ -103,7 +100,7 @@
<pre class="programlisting"><span class="special">*</span><span class="identifier">double_</span>
</pre>
<p>
- This is like a regular-expression Kleene Star. We moved the <tt class="computeroutput"><span class="special">*</span></tt> to the front for the same reasons we did
+ This is like a regular-expression Kleene Star. We moved the <code class="computeroutput"><span class="special">*</span></code> to the front for the same reasons we did
in <span class="emphasis"><em>Spirit.Qi</em></span>: we must work with the syntax rules of
C++. But if you know regular expressions (and for sure you remember those
C++ syntax rules) it will start to look very familiar in a matter of a
@@ -116,11 +113,11 @@
As above, whitespace can be inserted implicitely in between the generated
numbers, if needed.
</p>
-<a name="spirit.karma.tutorials.warming_up.trivial_example__4_generating_a_comma_delimited_list_of_numbers"></a><h5>
-<a name="id474715"></a>
- <a href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__4_generating_a_comma_delimited_list_of_numbers">Trivial
+<a name="spirit.karma.tutorials.warming_up.trivial_example__4_generating_a_comma_delimited_list_of_numbers"></a><h6>
+<a name="id1165635"></a>
+ <a class="link" href="warming_up.html#spirit.karma.tutorials.warming_up.trivial_example__4_generating_a_comma_delimited_list_of_numbers">Trivial
Example #4 Generating a comma-delimited list of numbers</a>
- </h5>
+ </h6>
<p>
We follow the lead of <span class="emphasis"><em>Spirit.Qi</em></span>'s warming up section
and will create a generator that produces a comma-delimited list of numbers.
@@ -128,8 +125,8 @@
<pre class="programlisting"><span class="identifier">double_</span> <span class="special"><<</span> <span class="special">*(</span><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span> <span class="special"><<</span> <span class="identifier">double_</span><span class="special">)</span>
</pre>
<p>
- Notice <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></tt>. It is
- a literal character generator that simply generates the comma <tt class="computeroutput"><span class="char">','</span></tt>. In this case, the Kleene Star is modifying
+ Notice <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></code>. It is
+ a literal character generator that simply generates the comma <code class="computeroutput"><span class="char">','</span></code>. In this case, the Kleene Star is modifying
a more complex generator, namely, the one generated by the expression:
</p>
<pre class="programlisting"><span class="special">(</span><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span> <span class="special"><<</span> <span class="identifier">double_</span><span class="special">)</span>
@@ -139,27 +136,27 @@
Star encloses the complete expression above, repeating the whole pattern
in the generated output zero or more times.
</p>
-<a name="spirit.karma.tutorials.warming_up.let_s_generate_"></a><h5>
-<a name="id474913"></a>
- <a href="warming_up.html#spirit.karma.tutorials.warming_up.let_s_generate_">Let's
+<a name="spirit.karma.tutorials.warming_up.let_s_generate_"></a><h6>
+<a name="id1165770"></a>
+ <a class="link" href="warming_up.html#spirit.karma.tutorials.warming_up.let_s_generate_">Let's
Generate!</a>
- </h5>
+ </h6>
<p>
We're done with defining the generator. All what's left is to invoke the
- generator to do its work. For now, we will use the <tt class="computeroutput"><span class="identifier">generate_delimited</span></tt>
+ generator to do its work. For now, we will use the <code class="computeroutput"><span class="identifier">generate_delimited</span></code>
function. One overload of this function accepts four arguments:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
An output iterator accepting the generated characters
</li>
-<li>
+<li class="listitem">
The generator expression
</li>
-<li>
+<li class="listitem">
Another generator called the delimiting generator
</li>
-<li>
+<li class="listitem">
The data to format and output
</li>
</ol></div>
@@ -173,22 +170,22 @@
For generators this mode doesn't make any sense. What is output generation
without generating any output? So we always will have to supply the data
the output should be generated from. In our example we supply a vector
- of <tt class="computeroutput"><span class="keyword">double</span></tt> numbers as the last
- parameter to the function <tt class="computeroutput"><span class="identifier">generate_delimited</span></tt>
+ of <code class="computeroutput"><span class="keyword">double</span></code> numbers as the last
+ parameter to the function <code class="computeroutput"><span class="identifier">generate_delimited</span></code>
(see code below).
</p>
<p>
In this example, we wish to delimit the generated numbers by spaces. Another
- generator named <tt class="computeroutput"><span class="identifier">space</span></tt> is
+ generator named <code class="computeroutput"><span class="identifier">space</span></code> is
included in Spirit's repertoire of predefined generators. It is a very
trivial generator that simply produces spaces. It is the equivalent to
- writing <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">' '</span><span class="special">)</span></tt>, or simply
- <tt class="computeroutput"><span class="char">' '</span></tt>. It has been implemented
- for similarity with the corresponding predefined <tt class="computeroutput"><span class="identifier">space</span></tt>
- parser. We will use <tt class="computeroutput"><span class="identifier">space</span></tt>
+ writing <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">' '</span><span class="special">)</span></code>, or simply
+ <code class="computeroutput"><span class="char">' '</span></code>. It has been implemented
+ for similarity with the corresponding predefined <code class="computeroutput"><span class="identifier">space</span></code>
+ parser. We will use <code class="computeroutput"><span class="identifier">space</span></code>
as our delimiter. The delimiter is the one responsible for inserting characters
- in between generator elements such as the <tt class="computeroutput"><span class="identifier">double_</span></tt>
- and <tt class="computeroutput"><span class="identifier">lit</span></tt>.
+ in between generator elements such as the <code class="computeroutput"><span class="identifier">double_</span></code>
+ and <code class="computeroutput"><span class="identifier">lit</span></code>.
</p>
<p>
Ok, so now let's generate (for the complete source code of this example
@@ -207,10 +204,10 @@
<span class="keyword">using</span> <span class="identifier">ascii</span><span class="special">::</span><span class="identifier">space</span><span class="special">;</span>
<span class="keyword">bool</span> <span class="identifier">r</span> <span class="special">=</span> <span class="identifier">generate_delimited</span><span class="special">(</span>
- <span class="identifier">sink</span><span class="special">,</span> <span class="callout_bug"><a name="spirit4co" href="warming_up.html#spirit4"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span>
- <span class="identifier">double_</span> <span class="special"><<</span> <span class="special">*(</span><span class="char">','</span> <span class="special"><<</span> <span class="identifier">double_</span><span class="special">),</span> <span class="callout_bug"><a name="spirit5co" href="warming_up.html#spirit5"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span>
- <span class="identifier">space</span><span class="special">,</span> <span class="callout_bug"><a name="spirit6co" href="warming_up.html#spirit6"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span>
- <span class="identifier">v</span> <span class="callout_bug"><a name="spirit7co" href="warming_up.html#spirit7"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span>
+ <span class="identifier">sink</span><span class="special">,</span> <span class="callout_bug"><a class="co" name="spirit4co" href="warming_up.html#spirit4"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span>
+ <span class="identifier">double_</span> <span class="special"><<</span> <span class="special">*(</span><span class="char">','</span> <span class="special"><<</span> <span class="identifier">double_</span><span class="special">),</span> <span class="callout_bug"><a class="co" name="spirit5co" href="warming_up.html#spirit5"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span>
+ <span class="identifier">space</span><span class="special">,</span> <span class="callout_bug"><a class="co" name="spirit6co" href="warming_up.html#spirit6"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span>
+ <span class="identifier">v</span> <span class="callout_bug"><a class="co" name="spirit7co" href="warming_up.html#spirit7"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span>
<span class="special">);</span>
<span class="keyword">return</span> <span class="identifier">r</span><span class="special">;</span>
<span class="special">}</span>
@@ -223,23 +220,19 @@
</p>
<div class="calloutlist"><table border="0" summary="Callout list">
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit4"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit4"></a> </p></td>
<td valign="top" align="left"><p> destination: output iterator </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit5"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit5"></a> </p></td>
<td valign="top" align="left"><p> the generator </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit6"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit6"></a> </p></td>
<td valign="top" align="left"><p> the delimiter-generator </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit7"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit7"></a> </p></td>
<td valign="top" align="left"><p> the
data to output </p></td>
</tr>
@@ -249,55 +242,55 @@
<p>
</p>
<p>
- The generate function returns <tt class="computeroutput"><span class="keyword">true</span></tt>
- or <tt class="computeroutput"><span class="keyword">false</span></tt> depending on the
+ The generate function returns <code class="computeroutput"><span class="keyword">true</span></code>
+ or <code class="computeroutput"><span class="keyword">false</span></code> depending on the
result of the output generation. As outlined in different places of this
documentation, a generator may fail for different reasons. One of the possible
reasons is an error in the underlying output iterator (memory exhausted
or disk full, etc.). Another reason might be that the data doesn't match
the requirements of a particular generator.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- <tt class="computeroutput"><span class="keyword">char</span></tt> and <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>
+ <code class="computeroutput"><span class="keyword">char</span></code> and <code class="computeroutput"><span class="keyword">wchar_t</span></code>
operands
</p>
<p>
- The careful reader may notice that the parser expression has <tt class="computeroutput"><span class="char">','</span></tt> instead of <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></tt>
+ The careful reader may notice that the parser expression has <code class="computeroutput"><span class="char">','</span></code> instead of <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></code>
as the previous examples did. This is ok due to C++ syntax rules of conversion.
- Spirit provides <tt class="computeroutput"><span class="special"><<</span></tt>
- operators that are overloaded to accept a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt> argument on its
+ Spirit provides <code class="computeroutput"><span class="special"><<</span></code>
+ operators that are overloaded to accept a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code> argument on its
left or right (but not both). An operator may be overloaded if at least
- one of its parameters is a user-defined type. In this case, the <tt class="computeroutput"><span class="identifier">double_</span></tt> is the 2nd argument to <tt class="computeroutput"><span class="keyword">operator</span><span class="special"><<</span></tt>,
- and so the proper overload of <tt class="computeroutput"><span class="special"><<</span></tt>
- is used, converting <tt class="computeroutput"><span class="char">','</span></tt> into
+ one of its parameters is a user-defined type. In this case, the <code class="computeroutput"><span class="identifier">double_</span></code> is the 2nd argument to <code class="computeroutput"><span class="keyword">operator</span><span class="special"><<</span></code>,
+ and so the proper overload of <code class="computeroutput"><span class="special"><<</span></code>
+ is used, converting <code class="computeroutput"><span class="char">','</span></code> into
a character literal parser.
</p>
<p>
- The problem with omiting the <tt class="computeroutput"><span class="identifier">lit</span></tt>
- should be obvious: <tt class="computeroutput"><span class="char">'a'</span> <span class="special"><<</span>
- <span class="char">'b'</span></tt> is not a spirit generator, it
+ The problem with omiting the <code class="computeroutput"><span class="identifier">lit</span></code>
+ should be obvious: <code class="computeroutput"><span class="char">'a'</span> <span class="special"><<</span>
+ <span class="char">'b'</span></code> is not a spirit generator, it
is a numeric expression, left-shifting the ASCII (or another encoding)
- value of <tt class="computeroutput"><span class="char">'a'</span></tt> by the ASCII value
- of <tt class="computeroutput"><span class="char">'b'</span></tt>. However, both <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">'a'</span><span class="special">)</span> <span class="special"><<</span>
- <span class="char">'b'</span></tt> and <tt class="computeroutput"><span class="char">'a'</span>
- <span class="special"><<</span> <span class="identifier">lit</span><span class="special">(</span><span class="char">'b'</span><span class="special">)</span></tt>
- are Spirit sequence generators for the letter <tt class="computeroutput"><span class="char">'a'</span></tt>
- followed by <tt class="computeroutput"><span class="char">'b'</span></tt>. You'll get
+ value of <code class="computeroutput"><span class="char">'a'</span></code> by the ASCII value
+ of <code class="computeroutput"><span class="char">'b'</span></code>. However, both <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="char">'a'</span><span class="special">)</span> <span class="special"><<</span>
+ <span class="char">'b'</span></code> and <code class="computeroutput"><span class="char">'a'</span>
+ <span class="special"><<</span> <span class="identifier">lit</span><span class="special">(</span><span class="char">'b'</span><span class="special">)</span></code>
+ are Spirit sequence generators for the letter <code class="computeroutput"><span class="char">'a'</span></code>
+ followed by <code class="computeroutput"><span class="char">'b'</span></code>. You'll get
used to it, sooner or later.
</p>
</td></tr>
</table></div>
<p>
- Note that we inlined the generator directly in the call to <tt class="computeroutput"><span class="identifier">generate_delimited</span></tt>. Upon calling this
+ Note that we inlined the generator directly in the call to <code class="computeroutput"><span class="identifier">generate_delimited</span></code>. Upon calling this
function, the expression evaluates into a temporary, unnamed generator
- which is passed into the <tt class="computeroutput"><span class="identifier">generate_delimited</span></tt>
+ which is passed into the <code class="computeroutput"><span class="identifier">generate_delimited</span></code>
function, used, and then destroyed.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/lex.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Lex - Writing Lexical Analyzers</title>
+<title>Lex - Writing Lexical Analyzers</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="karma/performance_measurements/numeric_performance/format_performance.html" title="
- Comparing the performance of a sequence of several generators">
-<link rel="next" href="lex/lexer_introduction.html" title=" Introduction to Spirit.Lex">
+<link rel="prev" href="karma/performance_measurements/numeric_performance/format_performance.html" title="Comparing the performance of a sequence of several generators">
+<link rel="next" href="lex/lexer_introduction.html" title="Introduction to Spirit.Lex">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="karma/performance_measurements/numeric_performance/format_performance.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lex/lexer_introduction.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.lex"></a> Lex - Writing Lexical Analyzers
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Lex - Writing Lexical Analyzers">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.lex"></a><a class="link" href="lex.html" title="Lex - Writing Lexical Analyzers"> Lex - Writing Lexical Analyzers</a>
+</h2></div></div></div>
<div class="toc"><dl>
<dt><span class="section"> Introduction to Spirit.Lex</span></dt>
<dt><span class="section"><a href="lex/tutorials.html"> <span class="emphasis"><em>Spirit.Lex</em></span>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Abstracts</title>
+<title>Abstracts</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="previous" href="tutorials/lexer_quickstart3.html" title=" Quickstart
- 3 - Counting Words Using a Parser">
+<link rel="up" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="prev" href="tutorials/lexer_quickstart3.html" title="Quickstart 3 - Counting Words Using a Parser">
<link rel="next" href="abstracts/lexer_primitives.html" title="Lexer Primitives">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="tutorials/lexer_quickstart3.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lex.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="abstracts/lexer_primitives.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.lex.abstracts"></a> Abstracts
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Abstracts">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.lex.abstracts"></a><a class="link" href="abstracts.html" title="Abstracts"> Abstracts</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Lexer Primitives</span></dt>
<dt><span class="section"><a href="abstracts/lexer_tokenizing.html"> Tokenizing
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_attributes.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_attributes.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_attributes.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Lexer Attributes</title>
+<title>Lexer Attributes</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_parsing.html" title=" Parsing using
- a Lexer">
-<link rel="next" href="lexer_states.html" title=" Lexer States">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_parsing.html" title="Parsing using a Lexer">
+<link rel="next" href="lexer_states.html" title="Lexer States">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_parsing.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_states.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_attributes"></a> Lexer Attributes
-</h4></div></div>
-<div></div>
-</div></div>
+<div class="section" title="Lexer Attributes"><div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_attributes"></a><a class="link" href="lexer_attributes.html" title="Lexer Attributes"> Lexer Attributes</a>
+</h4></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_parsing.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_parsing.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_parsing.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Parsing using
- a Lexer</title>
+<title>Parsing using a Lexer</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_static_model.html" title=" The Static
- Lexer Model">
-<link rel="next" href="lexer_attributes.html" title=" Lexer Attributes">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_static_model.html" title="The Static Lexer Model">
+<link rel="next" href="lexer_attributes.html" title="Lexer Attributes">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,14 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_static_model.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_attributes.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_parsing"></a><a href="lexer_parsing.html" title=" Parsing using
- a Lexer"> Parsing using
+<div class="section" title="Parsing using a Lexer"><div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_parsing"></a><a class="link" href="lexer_parsing.html" title="Parsing using a Lexer"> Parsing using
a Lexer</a>
-</h4></div></div>
-<div></div>
-</div></div>
+</h4></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Lexer Primitives</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="../abstracts.html" title=" Abstracts">
-<link rel="next" href="lexer_primitives/lexer_primitives.html" title="
- Lexer Primitives">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="../abstracts.html" title="Abstracts">
+<link rel="next" href="lexer_primitives/lexer_primitives.html" title="Lexer Primitives">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../abstracts.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_primitives/lexer_primitives.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_primitives"></a>Lexer Primitives
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Lexer Primitives">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_primitives"></a><a class="link" href="lexer_primitives.html" title="Lexer Primitives">Lexer Primitives</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="lexer_primitives/lexer_primitives.html">
Lexer Primitives</a></span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_primitives.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_primitives.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_primitives.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Lexer Primitives</title>
+<title>Lexer Primitives</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../lexer_primitives.html" title="Lexer Primitives">
-<link rel="previous" href="../lexer_primitives.html" title="Lexer Primitives">
-<link rel="next" href="lexer_token_values.html" title="
- About Tokens and Token Values">
+<link rel="prev" href="../lexer_primitives.html" title="Lexer Primitives">
+<link rel="next" href="lexer_token_values.html" title="About Tokens and Token Values">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,14 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../lexer_primitives.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lexer_primitives.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_token_values.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.abstracts.lexer_primitives.lexer_primitives"></a><a href="lexer_primitives.html" title="
- Lexer Primitives">
+<div class="section" title="Lexer Primitives"><div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.abstracts.lexer_primitives.lexer_primitives"></a><a class="link" href="lexer_primitives.html" title="Lexer Primitives">
Lexer Primitives</a>
-</h5></div></div>
-<div></div>
-</div></div>
+</h5></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_definition.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_definition.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_definition.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- Ways to define Tokens</title>
+<title>Ways to define Tokens</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../lexer_primitives.html" title="Lexer Primitives">
-<link rel="previous" href="lexer_token_values.html" title="
- About Tokens and Token Values">
-<link rel="next" href="../lexer_tokenizing.html" title=" Tokenizing
- Input Data">
+<link rel="prev" href="lexer_token_values.html" title="About Tokens and Token Values">
+<link rel="next" href="../lexer_tokenizing.html" title="Tokenizing Input Data">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,14 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_token_values.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lexer_primitives.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../lexer_tokenizing.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_definition"></a><a href="lexer_token_definition.html" title="
- Ways to define Tokens">
+<div class="section" title="Ways to define Tokens"><div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_definition"></a><a class="link" href="lexer_token_definition.html" title="Ways to define Tokens">
Ways to define Tokens</a>
-</h5></div></div>
-<div></div>
-</div></div>
+</h5></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_values.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_values.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_primitives/lexer_token_values.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>
- About Tokens and Token Values</title>
+<title>About Tokens and Token Values</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../lexer_primitives.html" title="Lexer Primitives">
-<link rel="previous" href="lexer_primitives.html" title="
- Lexer Primitives">
-<link rel="next" href="lexer_token_definition.html" title="
- Ways to define Tokens">
+<link rel="prev" href="lexer_primitives.html" title="Lexer Primitives">
+<link rel="next" href="lexer_token_definition.html" title="Ways to define Tokens">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_primitives.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lexer_primitives.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_token_definition.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_values"></a><a href="lexer_token_values.html" title="
- About Tokens and Token Values">
+<div class="section" title="About Tokens and Token Values">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_values"></a><a class="link" href="lexer_token_values.html" title="About Tokens and Token Values">
About Tokens and Token Values</a>
-</h5></div></div>
-<div></div>
-</div>
+</h5></div></div></div>
<p>
As already discussed, lexical scanning is the process of analyzing the
stream of input characters and separating it into strings called tokens,
@@ -49,45 +42,45 @@
class to the user. The only real limitation posed on this token class
is consequently, that it has to carry at least the token id of the token
it represents. For more information about the interface a user defined
- token type has to expose please look at the <a href="../../reference/concepts/token.html" title="Token">Token
+ token type has to expose please look at the <a class="link" href="../../reference/concepts/token.html" title="Token">Token
Reference</a> reference. The library provides a default token type
based on the Lexertl
- library which should be sufficient in most use cases: the lexertl_token<>
+ library which should be sufficient in most use cases: the <a class="link" href="../../reference/token_class.html" title="Token Class"><code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><></span></code></a>
type. This section focusses on the description of general features a
token class may implement and how this integrates with the other parts
of the <span class="emphasis"><em>Spirit.Lex</em></span> library.
</p>
<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_anatomy_of_a_token"></a><h6>
-<a name="id608018"></a>
- <a href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_anatomy_of_a_token">The
+<a name="id1312372"></a>
+ <a class="link" href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_anatomy_of_a_token">The
Anatomy of a Token</a>
</h6>
<p>
It is very important to understand the difference between a token definition
- (represented by the token_def<>
- template) and a token itself (for instance represented by the lexertl_token<>
+ (represented by the <a class="link" href="../../reference/tokendef_class.html" title="TokenDef Class"><code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code></a>
+ template) and a token itself (for instance represented by the <a class="link" href="../../reference/token_class.html" title="Token Class"><code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><></span></code></a>
template).
</p>
<p>
The token definition is used to describe the main features of a particular
token type, especially:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
to simplify the definition of a token type using a regular expression
pattern applied while matching this token type,
</li>
-<li>
+<li class="listitem">
to associate a token type with a particular lexer state,
</li>
-<li>
+<li class="listitem">
to optionally assign a token id to a token type,
</li>
-<li>
+<li class="listitem">
to optionally associate some code to execute whenever an instance of
this token type has been matched,
</li>
-<li>
+<li class="listitem">
and to optionally specify the attribute type of the token value.
</li>
</ul></div>
@@ -101,23 +94,22 @@
data structure contains at least the token id of the matched token type,
allowing to identify the matched character sequence. Optionally, the
token instance may contain a token value and/or the lexer state this
- token instance was matched in. The following figure
+ token instance was matched in. The following <a class="link" href="lexer_token_values.html#spirit.lex.tokenstructure" title="Figure 8. The structure of a token">figure</a>
shows the schematic structure of a token.
</p>
<p>
</p>
<div class="figure">
<a name="spirit.lex.tokenstructure"></a><p class="title"><b>Figure 8. The structure of a token</b></p>
-<span class="inlinemediaobject"><img src="./images/tokenstructure.png" alt="The
- structure of a token"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../../../.././images/tokenstructure.png" alt="The structure of a token"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
<p>
The token value and the lexer state the token has been recogniyed in
may be omitted for optimization reasons, avoiding the token to carry
more data than actually required. This configuration can be achieved
- by supplying appropriate template parameters for the lexertl_token<>
+ by supplying appropriate template parameters for the <a class="link" href="../../reference/token_class.html" title="Token Class"><code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><></span></code></a>
template while defining the token type.
</p>
<p>
@@ -126,18 +118,18 @@
<span class="emphasis"><em>value</em></span> types exposed by the various token types (token
definitions), the general type of the token value is a Boost.Variant.
As a minimum (for the default configuration) this token value variant
- will be configured to always hold a boost::iterator_range<>
+ will be configured to always hold a boost::iterator_range<>
containing the pair of iterators pointing to the matched input sequence
for this token instance.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
If the lexical analyzer is used in conjunction with a <span class="emphasis"><em>Spirit.Qi</em></span>
- parser, the stored boost::iterator_range<>
+ parser, the stored boost::iterator_range<>
token value will be converted to the requested token type (parser attribute)
exactly once. This happens at the time of the first access to the token
value requiring the corresponding type conversion. The converted token
@@ -149,7 +141,7 @@
</p></td></tr>
</table></div>
<p>
- Here is the template prototype of the lexertl_token<>
+ Here is the template prototype of the <a class="link" href="../../reference/token_class.html" title="Token Class"><code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><></span></code></a>
template:
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span>
@@ -159,28 +151,28 @@
<span class="special">></span>
<span class="keyword">struct</span> <span class="identifier">lexertl_token</span><span class="special">;</span>
</pre>
-<div class="variablelist">
+<div class="variablelist" title="where:">
<p class="title"><b>where:</b></p>
<dl>
<dt><span class="term">Iterator</span></dt>
<dd><p>
This is the type of the iterator used to access the underlying input
- stream. It defaults to a plain <tt class="computeroutput"><span class="keyword">char</span>
- <span class="keyword">const</span><span class="special">*</span></tt>.
+ stream. It defaults to a plain <code class="computeroutput"><span class="keyword">char</span>
+ <span class="keyword">const</span><span class="special">*</span></code>.
</p></dd>
<dt><span class="term">AttributeTypes</span></dt>
<dd><p>
This is either a mpl sequence containing all attribute types used
- for the token definitions or the type <tt class="computeroutput"><span class="identifier">omitted</span></tt>.
+ for the token definitions or the type <code class="computeroutput"><span class="identifier">omitted</span></code>.
If the mpl sequence is empty (which is the default), all token instances
- will store a <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">></span></tt> pointing to the start and the
- end of the matched section in the input stream. If the type is <tt class="computeroutput"><span class="identifier">omitted</span></tt>, the generated tokens will
+ will store a <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">></span></code> pointing to the start and the
+ end of the matched section in the input stream. If the type is <code class="computeroutput"><span class="identifier">omitted</span></code>, the generated tokens will
contain no token value (attribute) at all.
</p></dd>
<dt><span class="term">HasState</span></dt>
<dd><p>
- This is either <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- or <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>, allowing to control whether
+ This is either <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ or <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>, allowing to control whether
the generated token instances will contain the lexer state they were
generated in. The default is mpl::true_, so all token instances will
contain the lexer state.
@@ -189,18 +181,18 @@
</div>
<p>
Normally, during its construction, a token instance always holds the
- boost::iterator_range<>
- as its token value (except, if it has been defined using the <tt class="computeroutput"><span class="identifier">omitted</span></tt> token value type). This iterator
+ boost::iterator_range<>
+ as its token value (except, if it has been defined using the <code class="computeroutput"><span class="identifier">omitted</span></code> token value type). This iterator
range then is converted in place to the requested token value type (attribute)
when it is requested for the first time.
</p>
<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_physiognomy_of_a_token_definition"></a><h6>
-<a name="id608657"></a>
- <a href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_physiognomy_of_a_token_definition">The
+<a name="id1312866"></a>
+ <a class="link" href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.the_physiognomy_of_a_token_definition">The
Physiognomy of a Token Definition</a>
</h6>
<p>
- The token definitions (represented by the token_def<>
+ The token definitions (represented by the <a class="link" href="../../reference/tokendef_class.html" title="TokenDef Class"><code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code></a>
template) are normally used as part of the definition of the lexical
analyzer. At the same time a token definition instance may be used as
a parser component in <span class="emphasis"><em>Spirit.Qi</em></span>.
@@ -214,7 +206,7 @@
<span class="special">></span>
<span class="keyword">class</span> <span class="identifier">token_def</span><span class="special">;</span>
</pre>
-<div class="variablelist">
+<div class="variablelist" title="where:">
<p class="title"><b>where:</b></p>
<dl>
<dt><span class="term">Attribute</span></dt>
@@ -223,17 +215,17 @@
instances representing this token type. This attribute type is exposed
to the <span class="emphasis"><em>Spirit.Qi</em></span> library, whenever this token
definition is used as a parser component. The default attribute type
- is <tt class="computeroutput"><span class="identifier">unused_type</span></tt>, which
- means the token instance holds a boost::iterator_range<>
+ is <code class="computeroutput"><span class="identifier">unused_type</span></code>, which
+ means the token instance holds a boost::iterator_range<>
pointing to the start and the end of the matched section in the input
- stream. If the attribute is <tt class="computeroutput"><span class="identifier">omitted</span></tt>
+ stream. If the attribute is <code class="computeroutput"><span class="identifier">omitted</span></code>
the token instance will expose no token type at all. Any other type
will be used directly as the token value type.
</p></dd>
<dt><span class="term">Char</span></dt>
<dd><p>
This is the value type of the iterator for the underlying input sequence.
- It defaults to <tt class="computeroutput"><span class="keyword">char</span></tt>.
+ It defaults to <code class="computeroutput"><span class="keyword">char</span></code>.
</p></dd>
</dl>
</div>
@@ -241,36 +233,36 @@
The semantics of the template parameters for the token type and the token
definition type are very similar and interdependent. As a rule of thumb
you can think of the token definition type as the means of specifying
- everything related to a single specific token type (such as <tt class="computeroutput"><span class="identifier">identifier</span></tt> or <tt class="computeroutput"><span class="identifier">integer</span></tt>).
+ everything related to a single specific token type (such as <code class="computeroutput"><span class="identifier">identifier</span></code> or <code class="computeroutput"><span class="identifier">integer</span></code>).
On the other hand the token type is used to define the general proerties
of all token instances generated by the <span class="emphasis"><em>Spirit.Lex</em></span>
library.
</p>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
If you don't list any token value types in the token type definition
- declaration (resulting in the usage of the default boost::iterator_range<>
+ declaration (resulting in the usage of the default boost::iterator_range<>
token type) everything will compile and work just fine, just a bit
less efficient. This is because the token value will be converted from
the matched input sequence every time it is requested.
</p>
<p>
But as soon as you specify at least one token value type while defining
- the token type you'll have to list all value types used for token_def<>
+ the token type you'll have to list all value types used for <a class="link" href="../../reference/tokendef_class.html" title="TokenDef Class"><code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code></a>
declarations in the token definition class, otherwise compilation errors
will occur.
</p>
</td></tr>
</table></div>
<a name="spirit.lex.abstracts.lexer_primitives.lexer_token_values.examples_of_using__link_linkend__spirit_lex_reference_token_class___code__phrase_role__identifier__lexertl_token__phrase__phrase_role__special___lt__gt___phrase___code___link_"></a><h6>
-<a name="id609068"></a>
- <a href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.examples_of_using__link_linkend__spirit_lex_reference_token_class___code__phrase_role__identifier__lexertl_token__phrase__phrase_role__special___lt__gt___phrase___code___link_">Examples
- of using lexertl_token<></a>
+<a name="id1313122"></a>
+ <a class="link" href="lexer_token_values.html#spirit.lex.abstracts.lexer_primitives.lexer_token_values.examples_of_using__link_linkend__spirit_lex_reference_token_class___code__phrase_role__identifier__lexertl_token__phrase__phrase_role__special___lt__gt___phrase___code___link_">Examples
+ of using <a class="link" href="../../reference/token_class.html" title="Token Class"><code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><></span></code></a></a>
</h6>
<p>
Let's start with some examples. We refer to one of the <span class="emphasis"><em>Spirit.Lex</em></span>
@@ -279,13 +271,13 @@
<p>
The first code snippet shows an excerpt of the token definition class,
the definition of a couple of token types. Some of the token types do
- not expose a special token value (<tt class="computeroutput"><span class="identifier">if_</span></tt>,
- <tt class="computeroutput"><span class="identifier">else_</span></tt>, and <tt class="computeroutput"><span class="identifier">while_</span></tt>). Their token value will always
+ not expose a special token value (<code class="computeroutput"><span class="identifier">if_</span></code>,
+ <code class="computeroutput"><span class="identifier">else_</span></code>, and <code class="computeroutput"><span class="identifier">while_</span></code>). Their token value will always
hold the iterator range of the matched input sequence only. The token
- definitions for the <tt class="computeroutput"><span class="identifier">identifier</span></tt>
- and the integer <tt class="computeroutput"><span class="identifier">constant</span></tt>
- are specialized to expose an explicit token type each: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt> and <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="keyword">int</span></tt>.
+ definitions for the <code class="computeroutput"><span class="identifier">identifier</span></code>
+ and the integer <code class="computeroutput"><span class="identifier">constant</span></code>
+ are specialized to expose an explicit token type each: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code> and <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="keyword">int</span></code>.
</p>
<p>
</p>
@@ -318,7 +310,7 @@
<p>
As the parsers generated by <span class="emphasis"><em>Spirit.Qi</em></span> are fully
attributed, any <span class="emphasis"><em>Spirit.Qi</em></span> parser component needs
- to expose a certain type as its parser attribute. Naturally, the token_def<> exposes the token value
+ to expose a certain type as its parser attribute. Naturally, the <a class="link" href="../../reference/tokendef_class.html" title="TokenDef Class"><code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code></a> exposes the token value
type as its parser attribute, enabling a smooth integration with <span class="emphasis"><em>Spirit.Qi</em></span>.
</p>
<p>
@@ -354,9 +346,9 @@
<p>
</p>
<p>
- To avoid the token to have a token value at all, the special tag <tt class="computeroutput"><span class="identifier">omitted</span></tt> can be used: <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><</span><span class="identifier">omitted</span><span class="special">></span></tt>
- and <tt class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><</span><span class="identifier">base_iterator_type</span><span class="special">,</span>
- <span class="identifier">omitted</span><span class="special">></span></tt>.
+ To avoid the token to have a token value at all, the special tag <code class="computeroutput"><span class="identifier">omitted</span></code> can be used: <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><</span><span class="identifier">omitted</span><span class="special">></span></code>
+ and <code class="computeroutput"><span class="identifier">lexertl_token</span><span class="special"><</span><span class="identifier">base_iterator_type</span><span class="special">,</span>
+ <span class="identifier">omitted</span><span class="special">></span></code>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_semantic_actions.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_semantic_actions.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_semantic_actions.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Lexer
- Semantic Actions</title>
+<title>Lexer Semantic Actions</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_tokenizing.html" title=" Tokenizing
- Input Data">
-<link rel="next" href="lexer_static_model.html" title=" The Static
- Lexer Model">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_tokenizing.html" title="Tokenizing Input Data">
+<link rel="next" href="lexer_static_model.html" title="The Static Lexer Model">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_tokenizing.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_static_model.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_semantic_actions"></a><a href="lexer_semantic_actions.html" title=" Lexer
- Semantic Actions"> Lexer
+<div class="section" title="Lexer Semantic Actions">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_semantic_actions"></a><a class="link" href="lexer_semantic_actions.html" title="Lexer Semantic Actions"> Lexer
Semantic Actions</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The main task of a lexer normally is to recognize tokens in the input.
Traditionally this has been complemented with the possibility to execute
@@ -43,57 +36,57 @@
and generators (<span class="emphasis"><em>Spirit.Karma</em></span>). Lexer semantic actions
may be attached to any token definition. These are C++ functions or function
objects that are called whenever a token definition successfully recognizes
- a portion of the input. Say you have a token definition <tt class="computeroutput"><span class="identifier">D</span></tt>,
- and a C++ function <tt class="computeroutput"><span class="identifier">f</span></tt>, you
- can make the lexer call <tt class="computeroutput"><span class="identifier">f</span></tt>
- whenever it matches an input by attaching <tt class="computeroutput"><span class="identifier">f</span></tt>:
+ a portion of the input. Say you have a token definition <code class="computeroutput"><span class="identifier">D</span></code>,
+ and a C++ function <code class="computeroutput"><span class="identifier">f</span></code>, you
+ can make the lexer call <code class="computeroutput"><span class="identifier">f</span></code>
+ whenever it matches an input by attaching <code class="computeroutput"><span class="identifier">f</span></code>:
</p>
<pre class="programlisting"><span class="identifier">D</span><span class="special">[</span><span class="identifier">f</span><span class="special">]</span>
</pre>
<p>
- The expression above links <tt class="computeroutput"><span class="identifier">f</span></tt>
- to the token definition, <tt class="computeroutput"><span class="identifier">D</span></tt>.
- The required prototype of <tt class="computeroutput"><span class="identifier">f</span></tt>
+ The expression above links <code class="computeroutput"><span class="identifier">f</span></code>
+ to the token definition, <code class="computeroutput"><span class="identifier">D</span></code>.
+ The required prototype of <code class="computeroutput"><span class="identifier">f</span></code>
is:
</p>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">f</span> <span class="special">(</span><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">start</span><span class="special">,</span> <span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">end</span><span class="special">,</span> <span class="identifier">pass_flag</span><span class="special">&</span> <span class="identifier">matched</span><span class="special">,</span> <span class="identifier">Idtype</span><span class="special">&</span> <span class="identifier">id</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">&</span> <span class="identifier">ctx</span><span class="special">);</span>
</pre>
-<div class="variablelist">
+<div class="variablelist" title="where:">
<p class="title"><b>where:</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">start</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">start</span></code></span></dt>
<dd><p>
This is a the iterator pointing to the begin of the matched range in
the underlying input sequence. The type of the iterator is the same
- as specified while defining the type of the <tt class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><...></span></tt> (its first template parameter).
+ as specified while defining the type of the <code class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><...></span></code> (its first template parameter).
The semantic action is allowed to change the value of this iterator
influencing, the matched input sequence.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">end</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">end</span></code></span></dt>
<dd><p>
This is a the iterator pointing to the end of the matched range in
the underlying input sequence. The type of the iterator is the same
- as specified while defining the type of the <tt class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><...></span></tt> (its first template parameter).
+ as specified while defining the type of the <code class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><...></span></code> (its first template parameter).
The semantic action is allowed to change the value of this iterator
influencing, the matched input sequence.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">pass_flag</span><span class="special">&</span> <span class="identifier">matched</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">pass_flag</span><span class="special">&</span> <span class="identifier">matched</span></code></span></dt>
<dd><p>
- This value is pre/initialized to <tt class="computeroutput"><span class="identifier">pass_normal</span></tt>.
- If the semantic action sets it to <tt class="computeroutput"><span class="identifier">pass_fail</span></tt>
+ This value is pre/initialized to <code class="computeroutput"><span class="identifier">pass_normal</span></code>.
+ If the semantic action sets it to <code class="computeroutput"><span class="identifier">pass_fail</span></code>
the behaves as if the token has not been matched in the first place.
- If the semantic action sets this to <tt class="computeroutput"><span class="identifier">pass_ignore</span></tt>
+ If the semantic action sets this to <code class="computeroutput"><span class="identifier">pass_ignore</span></code>
the lexer ignores the current token and tries to match a next token
from the input.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Idtype</span><span class="special">&</span> <span class="identifier">id</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Idtype</span><span class="special">&</span> <span class="identifier">id</span></code></span></dt>
<dd><p>
This is the token id of the type Idtype (most of the time this will
- be a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span></tt>) for the matched token. The
+ be a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span></code>) for the matched token. The
semantic action is allowed to change the value of this token id, influencing
the if of the created token.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Context</span><span class="special">&</span> <span class="identifier">ctx</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Context</span><span class="special">&</span> <span class="identifier">ctx</span></code></span></dt>
<dd><p>
This is a reference to a lexer specific, unspecified type, providing
the context for the current lexer state. It can be used to access different
@@ -111,14 +104,14 @@
<span class="keyword">void</span> <span class="identifier">f</span> <span class="special">(</span><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">start</span><span class="special">,</span> <span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">end</span><span class="special">);</span>
<span class="keyword">void</span> <span class="identifier">f</span> <span class="special">();</span>
</pre>
-<a name="spirit.lex.abstracts.lexer_semantic_actions.the_context_of_a_lexer_semantic_action"></a><h5>
-<a name="id613785"></a>
- <a href="lexer_semantic_actions.html#spirit.lex.abstracts.lexer_semantic_actions.the_context_of_a_lexer_semantic_action">The
+<a name="spirit.lex.abstracts.lexer_semantic_actions.the_context_of_a_lexer_semantic_action"></a><h6>
+<a name="id1317831"></a>
+ <a class="link" href="lexer_semantic_actions.html#spirit.lex.abstracts.lexer_semantic_actions.the_context_of_a_lexer_semantic_action">The
context of a lexer semantic action</a>
- </h5>
+ </h6>
<p>
The last parameter passed to any lexer semantic action is a reference to
- an unspecified type (see the <tt class="computeroutput"><span class="identifier">Context</span></tt>
+ an unspecified type (see the <code class="computeroutput"><span class="identifier">Context</span></code>
type in the table above). This type is unspecified because it depends on
the token type returned by the lexer. It is implemented in the internals
of the iterator type exposed by the lexer. Nevertheless, any context type
@@ -127,103 +120,131 @@
of the available functionality.
</p>
<div class="table">
-<a name="id613837"></a><p class="title"><b>Table 9. Functions exposed by any context passed to a lexer
+<a name="id1317851"></a><p class="title"><b>Table 9. Functions exposed by any context passed to a lexer
semantic action</b></p>
-<table class="table" summary="Functions exposed by any context passed to a lexer
+<div class="table-contents"><table class="table" summary="Functions exposed by any context passed to a lexer
semantic action">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Iterator</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">get_eoi</span><span class="special">()</span> <span class="keyword">const</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">get_eoi</span><span class="special">()</span></tt> may be used by to access the end
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Iterator</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">get_eoi</span><span class="special">()</span> <span class="keyword">const</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">get_eoi</span><span class="special">()</span></code> may be used by to access the end
iterator of the input stream the lexer has been initialized with
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="keyword">void</span> <span class="identifier">more</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">more</span><span class="special">()</span></tt> tells the lexer that the next time
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">void</span> <span class="identifier">more</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">more</span><span class="special">()</span></code> tells the lexer that the next time
it matches a rule, the corresponding token should be appended onto
the current token value rather than replacing it.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Iterator</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">less</span><span class="special">(</span><span class="identifier">Iterator</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Iterator</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">less</span><span class="special">(</span><span class="identifier">Iterator</span>
<span class="keyword">const</span><span class="special">&</span>
<span class="identifier">it</span><span class="special">,</span>
- <span class="keyword">int</span> <span class="identifier">n</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">less</span><span class="special">()</span></tt> returns an iterator positioned
+ <span class="keyword">int</span> <span class="identifier">n</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">less</span><span class="special">()</span></code> returns an iterator positioned
to the nth input character beyond the current token start iterator
- (i.e. by passing the return value to the parameter <tt class="computeroutput"><span class="identifier">end</span></tt> it is possible to return all
+ (i.e. by passing the return value to the parameter <code class="computeroutput"><span class="identifier">end</span></code> it is possible to return all
but the first n characters of the current token back to the input
stream.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="keyword">bool</span> <span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span>
- <span class="identifier">id</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">lookahead</span><span class="special">()</span></tt> can be for instance used to implement
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">bool</span> <span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span>
+ <span class="identifier">id</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">lookahead</span><span class="special">()</span></code> can be for instance used to implement
lookahead for lexer engines not supporting constructs like flex'
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">/</span><span class="identifier">b</span></tt> (match <tt class="computeroutput"><span class="identifier">a</span></tt>,
- but only when followed by <tt class="computeroutput"><span class="identifier">b</span></tt>).
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">/</span><span class="identifier">b</span></code> (match <code class="computeroutput"><span class="identifier">a</span></code>,
+ but only when followed by <code class="computeroutput"><span class="identifier">b</span></code>).
It invokes the lexer on the input following the current token without
actually moving forward in the input stream. The function returns
whether the lexer was able to match a token with the given token-id
- <tt class="computeroutput"><span class="identifier">id</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="identifier">id</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">get_state</span><span class="special">()</span> <span class="keyword">const</span></tt>
- and <tt class="computeroutput"><span class="keyword">void</span> <span class="identifier">set_state</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span>
- <span class="identifier">state</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The functions <tt class="computeroutput"><span class="identifier">get_state</span><span class="special">()</span></tt> and <tt class="computeroutput"><span class="identifier">set_state</span><span class="special">()</span></tt> may be used to introspect and change
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">get_state</span><span class="special">()</span> <span class="keyword">const</span></code>
+ and <code class="computeroutput"><span class="keyword">void</span> <span class="identifier">set_state</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span>
+ <span class="identifier">state</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The functions <code class="computeroutput"><span class="identifier">get_state</span><span class="special">()</span></code> and <code class="computeroutput"><span class="identifier">set_state</span><span class="special">()</span></code> may be used to introspect and change
the current lexer state.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">token_value_type</span> <span class="identifier">get_value</span><span class="special">()</span>
- <span class="keyword">const</span></tt> and <tt class="computeroutput"><span class="keyword">void</span>
- <span class="identifier">set_value</span><span class="special">(</span><span class="identifier">Value</span> <span class="keyword">const</span><span class="special">&)</span></tt>
- </p></td>
-<td><p>
- The functions <tt class="computeroutput"><span class="identifier">get_value</span><span class="special">()</span></tt> and <tt class="computeroutput"><span class="identifier">set_value</span><span class="special">()</span></tt> may be used to introspect and change
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">token_value_type</span> <span class="identifier">get_value</span><span class="special">()</span>
+ <span class="keyword">const</span></code> and <code class="computeroutput"><span class="keyword">void</span>
+ <span class="identifier">set_value</span><span class="special">(</span><span class="identifier">Value</span> <span class="keyword">const</span><span class="special">&)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The functions <code class="computeroutput"><span class="identifier">get_value</span><span class="special">()</span></code> and <code class="computeroutput"><span class="identifier">set_value</span><span class="special">()</span></code> may be used to introspect and change
the current token value.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<a name="spirit.lex.abstracts.lexer_semantic_actions.lexer_semantic_actions_using_phoenix"></a><h5>
-<a name="id614561"></a>
- <a href="lexer_semantic_actions.html#spirit.lex.abstracts.lexer_semantic_actions.lexer_semantic_actions_using_phoenix">Lexer
+<br class="table-break"><a name="spirit.lex.abstracts.lexer_semantic_actions.lexer_semantic_actions_using_phoenix"></a><h6>
+<a name="id1318370"></a>
+ <a class="link" href="lexer_semantic_actions.html#spirit.lex.abstracts.lexer_semantic_actions.lexer_semantic_actions_using_phoenix">Lexer
Semantic Actions Using Phoenix</a>
- </h5>
+ </h6>
<p>
Even if it is possible to write your own function object implementations
(i.e. using Boost.Lambda or Boost.Bind), the preferred way of defining
@@ -232,98 +253,130 @@
predefined Spirit placeholders:
</p>
<div class="table">
-<a name="id614603"></a><p class="title"><b>Table 10. Predefined Phoenix placeholders for lexer semantic
+<a name="id1318392"></a><p class="title"><b>Table 10. Predefined Phoenix placeholders for lexer semantic
actions</b></p>
-<table class="table" summary="Predefined Phoenix placeholders for lexer semantic
+<div class="table-contents"><table class="table" summary="Predefined Phoenix placeholders for lexer semantic
actions">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Placeholder
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_start</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_start</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Refers to the iterator pointing to the begin of the matched input
sequence. Any modifications to this iterator value will be reflected
in the generated token.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_end</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_end</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Refers to the iterator pointing past the end of the matched input
sequence. Any modifications to this iterator value will be reflected
in the generated token.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_pass</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_pass</span></code>
+ </p>
+ </td>
+<td>
+ <p>
References the value signaling the outcome of the semantic action.
- This is pre-initialized to <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_normal</span></tt>.
- If this is set to <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_fail</span></tt>,
+ This is pre-initialized to <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_normal</span></code>.
+ If this is set to <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_fail</span></code>,
the lexer will behave as if no token has been matched, if is set
- to <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_ignore</span></tt>, the lexer will ignore
+ to <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">pass_flags</span><span class="special">::</span><span class="identifier">pass_ignore</span></code>, the lexer will ignore
the current match and proceed trying to match tokens from the input.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_tokenid</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_tokenid</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Refers to the token id of the token to be generated. Any modifications
to this value will be reflected in the generated token.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_val</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_val</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Refers to the value the next token will be initialized from. Any
modifications to this value will be reflected in the generated token.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_state</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_state</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Refers to the lexer state the input has been match in. Any modifications
to this value will be reflected in the lexer itself (the next match
will start in the new state). The currently generated token is not
affected by changes to this variable.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">_eoi</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">_eoi</span></code>
+ </p>
+ </td>
+<td>
+ <p>
References the end iterator of the overall lexer input. This value
cannot be changed.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
The context object passed as the last parameter to any lexer semantic action
is not directly accessible while using Boost.Phoenix
expressions. We rather provide predefine Phoenix functions allowing to
@@ -331,9 +384,9 @@
table lists the available support functions and describes their functionality:
</p>
<div class="table">
-<a name="id614983"></a><p class="title"><b>Table 11. Support functions usable from Phoenix expressions
+<a name="id1318671"></a><p class="title"><b>Table 11. Support functions usable from Phoenix expressions
inside lexer semantic actions</b></p>
-<table class="table" summary="Support functions usable from Phoenix expressions
+<div class="table-contents"><table class="table" summary="Support functions usable from Phoenix expressions
inside lexer semantic actions">
<colgroup>
<col>
@@ -341,69 +394,94 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Plain function
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Phoenix function
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">more</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">more</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">more</span><span class="special">()</span></tt> tells the lexer that the next time
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">more</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">more</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">more</span><span class="special">()</span></code> tells the lexer that the next time
it matches a rule, the corresponding token should be appended onto
the current token value rather than replacing it.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">less</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">less</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">less</span><span class="special">()</span></tt> takes a single integer parameter
- <tt class="computeroutput"><span class="identifier">n</span></tt> and returns an
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">less</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">less</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">less</span><span class="special">()</span></code> takes a single integer parameter
+ <code class="computeroutput"><span class="identifier">n</span></code> and returns an
iterator positioned to the nth input character beyond the current
token start iterator (i.e. by assigning the return value to the placeholder
- <tt class="computeroutput"><span class="identifier">_end</span></tt> it is possible
- to return all but the first <tt class="computeroutput"><span class="identifier">n</span></tt>
+ <code class="computeroutput"><span class="identifier">_end</span></code> it is possible
+ to return all but the first <code class="computeroutput"><span class="identifier">n</span></code>
characters of the current token back to the input stream.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">lookahead</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span><span class="special">)</span></tt>
- or <tt class="computeroutput"><span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">token_def</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The function <tt class="computeroutput"><span class="identifier">lookahead</span><span class="special">()</span></tt> takes a single parameter specifying
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ctx</span><span class="special">.</span><span class="identifier">lookahead</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span><span class="special">)</span></code>
+ or <code class="computeroutput"><span class="identifier">lookahead</span><span class="special">(</span><span class="identifier">token_def</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The function <code class="computeroutput"><span class="identifier">lookahead</span><span class="special">()</span></code> takes a single parameter specifying
the token to match in the input. The function can be used for instance
to implement lookahead for lexer engines not supporting constructs
- like flex' <tt class="computeroutput"><span class="identifier">a</span><span class="special">/</span><span class="identifier">b</span></tt> (match <tt class="computeroutput"><span class="identifier">a</span></tt>,
- but only when followed by <tt class="computeroutput"><span class="identifier">b</span></tt>).
+ like flex' <code class="computeroutput"><span class="identifier">a</span><span class="special">/</span><span class="identifier">b</span></code> (match <code class="computeroutput"><span class="identifier">a</span></code>,
+ but only when followed by <code class="computeroutput"><span class="identifier">b</span></code>).
It invokes the lexer on the input following the current token without
actually moving forward in the input stream. The function returns
whether the lexer was able to match the specified token.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
+<br class="table-break">
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_states.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_states.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_states.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Lexer States</title>
+<title>Lexer States</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_attributes.html" title=" Lexer Attributes">
-<link rel="next" href="../quick_reference.html" title=" Quick Reference">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_attributes.html" title="Lexer Attributes">
+<link rel="next" href="../quick_reference.html" title="Quick Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,28 +22,25 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_attributes.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_states"></a> Lexer States
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_lexer_semantic_actions"></a><h5>
-<a name="id618886"></a>
- <a href="lexer_states.html#spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_lexer_semantic_actions">Controlling
+<div class="section" title="Lexer States">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_states"></a><a class="link" href="lexer_states.html" title="Lexer States"> Lexer States</a>
+</h4></div></div></div>
+<a name="spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_lexer_semantic_actions"></a><h6>
+<a name="id1323980"></a>
+ <a class="link" href="lexer_states.html#spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_lexer_semantic_actions">Controlling
the Lexer State from Lexer Semantic Actions</a>
- </h5>
-<a name="spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_parser_semantic_actions"></a><h5>
-<a name="id618914"></a>
- <a href="lexer_states.html#spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_parser_semantic_actions">Controlling
+ </h6>
+<a name="spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_parser_semantic_actions"></a><h6>
+<a name="id1323993"></a>
+ <a class="link" href="lexer_states.html#spirit.lex.abstracts.lexer_states.controlling_the_lexer_state_from_parser_semantic_actions">Controlling
the Lexer State from Parser Semantic Actions</a>
- </h5>
-<a name="spirit.lex.abstracts.lexer_states.using_a_lexer_state_for_the_skip_parser"></a><h5>
-<a name="id618943"></a>
- <a href="lexer_states.html#spirit.lex.abstracts.lexer_states.using_a_lexer_state_for_the_skip_parser">Using
+ </h6>
+<a name="spirit.lex.abstracts.lexer_states.using_a_lexer_state_for_the_skip_parser"></a><h6>
+<a name="id1324006"></a>
+ <a class="link" href="lexer_states.html#spirit.lex.abstracts.lexer_states.using_a_lexer_state_for_the_skip_parser">Using
a Lexer State for the Skip Parser</a>
- </h5>
+ </h6>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_static_model.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_static_model.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_static_model.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> The Static
- Lexer Model</title>
+<title>The Static Lexer Model</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">
-<link rel="next" href="lexer_parsing.html" title=" Parsing using
- a Lexer">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_semantic_actions.html" title="Lexer Semantic Actions">
+<link rel="next" href="lexer_parsing.html" title="Parsing using a Lexer">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_semantic_actions.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_parsing.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_static_model"></a><a href="lexer_static_model.html" title=" The Static
- Lexer Model"> The <span class="emphasis"><em>Static</em></span>
+<div class="section" title="The Static Lexer Model">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_static_model"></a><a class="link" href="lexer_static_model.html" title="The Static Lexer Model"> The <span class="emphasis"><em>Static</em></span>
Lexer Model</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The documentation of <span class="emphasis"><em>Spirit.Lex</em></span> so far mostly was
about describing the features of the <span class="emphasis"><em>dynamic</em></span> model,
@@ -57,12 +50,12 @@
Assuming you already built a dynamic lexer for your problem, there are
two more steps needed to create a static lexical analyzer using <span class="emphasis"><em>Spirit.Lex</em></span>:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
generating the C++ code for the static analyzer (including the tokenization
function and corresponding tables), and
</li>
-<li>
+<li class="listitem">
modifying the dynamic lexical anlyzer to use the generated code.
</li>
</ol></div>
@@ -132,8 +125,8 @@
<p>
The only thing changing between the three different use cases is the template
parameter used to instantiate a concrete token definition. Fot the dynamic
- model and the code generator you probably will use the lexertl_lexer<>
- template, where for the static model you will use the lexertl_static_lexer<>
+ model and the code generator you probably will use the <a class="link" href="../reference/lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model"><code class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><></span></code></a>
+ template, where for the static model you will use the <a class="link" href="../reference/lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model"><code class="computeroutput"><span class="identifier">lexertl_static_lexer</span><span class="special"><></span></code></a>
type as the template parameter.
</p>
<p>
@@ -182,17 +175,17 @@
</p>
<p>
</p>
-<a name="spirit.lex.abstracts.lexer_static_model.generating_the_static_analyzer"></a><h5>
-<a name="id617026"></a>
- <a href="lexer_static_model.html#spirit.lex.abstracts.lexer_static_model.generating_the_static_analyzer">Generating
+<a name="spirit.lex.abstracts.lexer_static_model.generating_the_static_analyzer"></a><h6>
+<a name="id1322533"></a>
+ <a class="link" href="lexer_static_model.html#spirit.lex.abstracts.lexer_static_model.generating_the_static_analyzer">Generating
the Static Analyzer</a>
- </h5>
+ </h6>
<p>
The first additional step to perform in order to create a static lexical
analyzer is to create a small standalone program for creating the lexer
tables and the corresponding tokenization function. For this purpose the
<span class="emphasis"><em>Spirit.Lex</em></span> library exposes a special API - the function
- generate_static().
+ <a class="link" href="../../../"><code class="computeroutput"><span class="identifier">generate_static</span><span class="special">()</span></code></a>.
It implements the whole code generator, no further code is needed. All
what it takes to invoke this function is to supply a token definition instance,
an output stream to use to generate the code to, and an optional string
@@ -231,20 +224,20 @@
a file for later inclusion into the static lexical analzyer as shown in
the next topic (the full generated code can be viewed here).
</p>
-<a name="spirit.lex.abstracts.lexer_static_model.modifying_the_dynamic_analyzer"></a><h5>
-<a name="id617490"></a>
- <a href="lexer_static_model.html#spirit.lex.abstracts.lexer_static_model.modifying_the_dynamic_analyzer">Modifying
+<a name="spirit.lex.abstracts.lexer_static_model.modifying_the_dynamic_analyzer"></a><h6>
+<a name="id1322861"></a>
+ <a class="link" href="lexer_static_model.html#spirit.lex.abstracts.lexer_static_model.modifying_the_dynamic_analyzer">Modifying
the Dynamic Analyzer</a>
- </h5>
+ </h6>
<p>
The second required step to convert an existing dynamic lexer into a static
one is to change your main program at two places. First, you need to change
the type of the used lexer (that is the template parameter used while instantiating
your token definition class). While in the dynamic model we have been using
- the lexertl_lexer<>
- template, we now need to change that to the lexertl_static_lexer<>
+ the <a class="link" href="../reference/lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model"><code class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><></span></code></a>
+ template, we now need to change that to the <a class="link" href="../reference/lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model"><code class="computeroutput"><span class="identifier">lexertl_static_lexer</span><span class="special"><></span></code></a>
type. The second change is tightly related to the first one and involves
- correcting the corresponding <tt class="computeroutput"><span class="preprocessor">#include</span></tt>
+ correcting the corresponding <code class="computeroutput"><span class="preprocessor">#include</span></code>
statement to:
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_tokenizing.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_tokenizing.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/abstracts/lexer_tokenizing.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Tokenizing
- Input Data</title>
+<title>Tokenizing Input Data</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../abstracts.html" title=" Abstracts">
-<link rel="previous" href="lexer_primitives/lexer_token_definition.html" title="
- Ways to define Tokens">
-<link rel="next" href="lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">
+<link rel="up" href="../abstracts.html" title="Abstracts">
+<link rel="prev" href="lexer_primitives/lexer_token_definition.html" title="Ways to define Tokens">
+<link rel="next" href="lexer_semantic_actions.html" title="Lexer Semantic Actions">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,28 +22,23 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_primitives/lexer_token_definition.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../abstracts.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_semantic_actions.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.abstracts.lexer_tokenizing"></a><a href="lexer_tokenizing.html" title=" Tokenizing
- Input Data"> Tokenizing
+<div class="section" title="Tokenizing Input Data">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.abstracts.lexer_tokenizing"></a><a class="link" href="lexer_tokenizing.html" title="Tokenizing Input Data"> Tokenizing
Input Data</a>
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.lex.abstracts.lexer_tokenizing.the_tokenize_function"></a><h5>
-<a name="id609875"></a>
- <a href="lexer_tokenizing.html#spirit.lex.abstracts.lexer_tokenizing.the_tokenize_function">The
+</h4></div></div></div>
+<a name="spirit.lex.abstracts.lexer_tokenizing.the_tokenize_function"></a><h6>
+<a name="id1314993"></a>
+ <a class="link" href="lexer_tokenizing.html#spirit.lex.abstracts.lexer_tokenizing.the_tokenize_function">The
tokenize function</a>
- </h5>
+ </h6>
<p>
- The <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt>
+ The <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code>
function is a helper function simplifying the usage of a lexer in a standalone
fashion. Consider you have a standalone lexer where all the required functionality
is implemented inside of lexer semantic actions. A good example for this
is the word_count_lexer
- described in more detail in the section <a href="../tutorials/lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">Lex
+ described in more detail in the section <a class="link" href="../tutorials/lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">Lex
Quickstart 2 - A better word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>.
As a reminder, here is the token definition class:
</p>
@@ -87,7 +79,7 @@
<p>
The construct used to tokenize the given input, while discarding all generated
tokens is a common application of the lexer. For this reason <span class="emphasis"><em>Spirit.Lex</em></span>
- exposes an API function <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt> minimizing the code required:
+ exposes an API function <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code> minimizing the code required:
</p>
<pre class="programlisting"><span class="comment">// Read input from the given file
</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">str</span> <span class="special">(</span><span class="identifier">read_from_file</span><span class="special">(</span><span class="number">1</span> <span class="special">==</span> <span class="identifier">argc</span> <span class="special">?</span> <span class="string">"word_count.input"</span> <span class="special">:</span> <span class="identifier">argv</span><span class="special">[</span><span class="number">1</span><span class="special">]));</span>
@@ -100,15 +92,14 @@
</pre>
<p>
This code is completely equivalent to the more verbose version as shown
- in the section <a href="../tutorials/lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">Lex
+ in the section <a class="link" href="../tutorials/lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">Lex
Quickstart 2 - A better word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>.
- The function <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt>
+ The function <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code>
will return either if the end of the input has been reached (in this case
- the return value will be <tt class="computeroutput"><span class="keyword">true</span></tt>),
+ the return value will be <code class="computeroutput"><span class="keyword">true</span></code>),
or if the lexer couldn't match any of the token definitions in the input
- (in this case the return value will be <tt class="computeroutput"><span class="keyword">false</span></tt>
- and the iterator <tt class="computeroutput"><span class="identifier">first</span></tt>
+ (in this case the return value will be <code class="computeroutput"><span class="keyword">false</span></code>
+ and the iterator <code class="computeroutput"><span class="identifier">first</span></code>
will point to the first not matched character in the input sequence).
</p>
<p>
@@ -118,7 +109,7 @@
<span class="keyword">bool</span> <span class="identifier">tokenize</span><span class="special">(</span><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">first</span><span class="special">,</span> <span class="identifier">Iterator</span> <span class="identifier">last</span><span class="special">,</span> <span class="identifier">Lexer</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">lex</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Lexer</span><span class="special">::</span><span class="identifier">char_type</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">initial_state</span> <span class="special">=</span> <span class="number">0</span><span class="special">);</span>
</pre>
-<div class="variablelist">
+<div class="variablelist" title="where:">
<p class="title"><b>where:</b></p>
<dl>
<dt><span class="term">Iterator& first</span></dt>
@@ -143,7 +134,7 @@
</dl>
</div>
<p>
- A second overload of the <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt> function allows to specify any arbitrary
+ A second overload of the <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code> function allows to specify any arbitrary
function or function object to be called for each of the generated tokens.
For some applications this is very useful, as it might avoid having lexer
semantic actions. For an example of how to use this function, please have
@@ -152,10 +143,10 @@
<p>
</p>
<p>
- The main function simply loads the given file into memory (as a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>), instantiates an instance of
- the token definition template using the correct iterator type (<tt class="computeroutput"><span class="identifier">word_count_tokens</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*></span></tt>), and finally calls <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span></tt>, passing an instance of the
- counter function object. The return value of <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></tt> will be <tt class="computeroutput"><span class="keyword">true</span></tt>
- if the whole input sequence has been successfully tokenized, and <tt class="computeroutput"><span class="keyword">false</span></tt> otherwise.
+ The main function simply loads the given file into memory (as a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>), instantiates an instance of
+ the token definition template using the correct iterator type (<code class="computeroutput"><span class="identifier">word_count_tokens</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*></span></code>), and finally calls <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span></code>, passing an instance of the
+ counter function object. The return value of <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></code> will be <code class="computeroutput"><span class="keyword">true</span></code>
+ if the whole input sequence has been successfully tokenized, and <code class="computeroutput"><span class="keyword">false</span></code> otherwise.
</p>
<p>
</p>
@@ -198,13 +189,13 @@
<p>
</p>
<p>
- Here is the prototype of this <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt> function overload:
+ Here is the prototype of this <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code> function overload:
</p>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Iterator</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Lexer</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">F</span><span class="special">></span>
<span class="keyword">bool</span> <span class="identifier">tokenize</span><span class="special">(</span><span class="identifier">Iterator</span><span class="special">&</span> <span class="identifier">first</span><span class="special">,</span> <span class="identifier">Iterator</span> <span class="identifier">last</span><span class="special">,</span> <span class="identifier">Lexer</span> <span class="keyword">const</span><span class="special">&</span> <span class="identifier">lex</span><span class="special">,</span> <span class="identifier">F</span> <span class="identifier">f</span>
<span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Lexer</span><span class="special">::</span><span class="identifier">char_type</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">initial_state</span> <span class="special">=</span> <span class="number">0</span><span class="special">);</span>
</pre>
-<div class="variablelist">
+<div class="variablelist" title="where:">
<p class="title"><b>where:</b></p>
<dl>
<dt><span class="term">Iterator& first</span></dt>
@@ -224,10 +215,10 @@
<dt><span class="term">F f</span></dt>
<dd><p>
A function or function object to be called for each matched token.
- This function is expected to have the prototype: <tt class="computeroutput"><span class="keyword">bool</span>
- <span class="identifier">f</span><span class="special">(</span><span class="identifier">Lexer</span><span class="special">::</span><span class="identifier">token_type</span><span class="special">);</span></tt>
- and should return <tt class="computeroutput"><span class="keyword">false</span></tt>
- if the supplied token instance is invald (the <tt class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></tt> function will return immediatly).
+ This function is expected to have the prototype: <code class="computeroutput"><span class="keyword">bool</span>
+ <span class="identifier">f</span><span class="special">(</span><span class="identifier">Lexer</span><span class="special">::</span><span class="identifier">token_type</span><span class="special">);</span></code>
+ and should return <code class="computeroutput"><span class="keyword">false</span></code>
+ if the supplied token instance is invald (the <code class="computeroutput"><span class="identifier">tokenize</span><span class="special">()</span></code> function will return immediatly).
</p></dd>
<dt><span class="term">Lexer::char_type const* initial_state</span></dt>
<dd><p>
@@ -236,11 +227,11 @@
</p></dd>
</dl>
</div>
-<a name="spirit.lex.abstracts.lexer_tokenizing.the_generate_static_function"></a><h5>
-<a name="id612880"></a>
- <a href="lexer_tokenizing.html#spirit.lex.abstracts.lexer_tokenizing.the_generate_static_function">The
+<a name="spirit.lex.abstracts.lexer_tokenizing.the_generate_static_function"></a><h6>
+<a name="id1317209"></a>
+ <a class="link" href="lexer_tokenizing.html#spirit.lex.abstracts.lexer_tokenizing.the_generate_static_function">The
generate_static function</a>
- </h5>
+ </h6>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/lex/lexer_introduction.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/lexer_introduction.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/lexer_introduction.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Introduction to Spirit.Lex</title>
+<title>Introduction to Spirit.Lex</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="previous" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="next" href="tutorials.html" title=" Spirit.Lex
- Tutorials">
+<link rel="up" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="prev" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="next" href="tutorials.html" title="Spirit.Lex Tutorials">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../lex.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lex.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tutorials.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.lex.lexer_introduction"></a> Introduction to Spirit.Lex
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Introduction to Spirit.Lex">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.lex.lexer_introduction"></a><a class="link" href="lexer_introduction.html" title="Introduction to Spirit.Lex"> Introduction to <span class="emphasis"><em>Spirit.Lex</em></span></a>
+</h3></div></div></div>
<p>
Lexical scanning is the process of analyzing the stream of input characters
and separating it into strings called tokens, separated by whitespace. Most
@@ -41,29 +37,29 @@
set of patterns describing the different tokens you want to recognize in
the input. To make this a bit more formal, here are some definitions:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
A token is a sequence of consecutive characters having a collective meaning.
Tokens may have attributes specific to the token type, carrying additional
information about the matched character sequence.
</li>
-<li>
+<li class="listitem">
A pattern is a rule expressed as a regular expression and describing how
- a particular token can be formed. For example, <tt class="literal">[A-Za-z][A-Za-z_0-9]*</tt>
+ a particular token can be formed. For example, <code class="literal">[A-Za-z][A-Za-z_0-9]*</code>
is a pattern for a rule matching C++ identifiers.
</li>
-<li>
+<li class="listitem">
Characters between tokens are called whitespace; these include spaces,
tabs, newlines, and formfeeds. Many people also count comments as whitespace,
though since some tools such as lint look at comments, this conflation
is not perfect.
</li>
</ul></div>
-<a name="spirit.lex.lexer_introduction.why_use_a_separate_lexer_"></a><h4>
-<a name="id591471"></a>
- <a href="lexer_introduction.html#spirit.lex.lexer_introduction.why_use_a_separate_lexer_">Why
+<a name="spirit.lex.lexer_introduction.why_use_a_separate_lexer_"></a><h5>
+<a name="id1301370"></a>
+ <a class="link" href="lexer_introduction.html#spirit.lex.lexer_introduction.why_use_a_separate_lexer_">Why
Use a Separate Lexer?</a>
- </h4>
+ </h5>
<p>
Typically, lexical scanning is done in a separate module from the parser,
feeding the parser with a stream of input tokens only. Theoretically it is
@@ -79,17 +75,17 @@
to be very useful in practical applications. In 1956, Noam Chomsky defined
the "Chomsky Hierarchy" of grammars:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Type 0: Unrestricted grammars (e.g., natural languages)
</li>
-<li>
+<li class="listitem">
Type 1: Context-Sensitive grammars
</li>
-<li>
+<li class="listitem">
Type 2: Context-Free grammars
</li>
-<li>
+<li class="listitem">
Type 3: Regular grammars
</li>
</ul></div>
@@ -158,11 +154,11 @@
it is even possible to use the provided functionality to build more complex
grammar recognizers.
</p>
-<a name="spirit.lex.lexer_introduction.advantages_of_using__emphasis_spirit_lex__emphasis_"></a><h4>
-<a name="id591823"></a>
- <a href="lexer_introduction.html#spirit.lex.lexer_introduction.advantages_of_using__emphasis_spirit_lex__emphasis_">Advantages
+<a name="spirit.lex.lexer_introduction.advantages_of_using__emphasis_spirit_lex__emphasis_"></a><h5>
+<a name="id1301579"></a>
+ <a class="link" href="lexer_introduction.html#spirit.lex.lexer_introduction.advantages_of_using__emphasis_spirit_lex__emphasis_">Advantages
of using <span class="emphasis"><em>Spirit.Lex</em></span></a>
- </h4>
+ </h5>
<p>
The advantage of using <span class="emphasis"><em>Spirit.Lex</em></span> to create the lexical
analyzer over using more traditional tools such as Flex
@@ -175,18 +171,18 @@
gives you the vast majority of features you could get from a similar Flex program without the need
to leave C++ as a host language:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
The definition of tokens is done using regular expressions (patterns)
</li>
-<li>
+<li class="listitem">
The token definitions can refer to special substitution strings (pattern
macros) simplifying pattern definitions
</li>
-<li>
+<li class="listitem">
The generated lexical scanner may have multiple start states
</li>
-<li>
+<li class="listitem">
It is possible to attach code to any of the token definitions; this code
gets executed whenever the corresponding token pattern has been matched
</li>
@@ -195,8 +191,7 @@
Even if it is possible to use <span class="emphasis"><em>Spirit.Lex</em></span> to generate
C++ code representing the lexical analyzer (we will refer to that as the
<span class="emphasis"><em>static</em></span> model, described in more detail in the section
- <a href="abstracts/lexer_static_model.html" title=" The Static
- Lexer Model">The <span class="emphasis"><em>Static</em></span>
+ <a class="link" href="abstracts/lexer_static_model.html" title="The Static Lexer Model">The <span class="emphasis"><em>Static</em></span>
Model</a>) - a model very similar to the way Flex
operates - we will mainly focus on the opposite, the <span class="emphasis"><em>dynamic</em></span>
model. You can directly integrate the token definitions into your C++ program,
@@ -207,14 +202,13 @@
But it is very flexible and allows you to speed up the development of your
application.
</p>
-<a name="spirit.lex.lexer_introduction.the_library_structure_of__emphasis_spirit_lex__emphasis_"></a><h4>
-<a name="id592008"></a>
- <a href="lexer_introduction.html#spirit.lex.lexer_introduction.the_library_structure_of__emphasis_spirit_lex__emphasis_">The
+<a name="spirit.lex.lexer_introduction.the_library_structure_of__emphasis_spirit_lex__emphasis_"></a><h5>
+<a name="id1301682"></a>
+ <a class="link" href="lexer_introduction.html#spirit.lex.lexer_introduction.the_library_structure_of__emphasis_spirit_lex__emphasis_">The
Library Structure of <span class="emphasis"><em>Spirit.Lex</em></span></a>
- </h4>
+ </h5>
<p>
- The <a href="lexer_introduction.html#spirit.lexerflow" title="Figure 6. The Library structure and Common Flow of Information while
- using Spirit.Lex in an application">figure</a> below shows a high level
+ The <a class="link" href="lexer_introduction.html#spirit.lexerflow" title="Figure 6. The Library structure and Common Flow of Information while using Spirit.Lex in an application">figure</a> below shows a high level
overview of how the <span class="emphasis"><em>Spirit.Lex</em></span> library might be used
in an application. <span class="emphasis"><em>Spirit.Lex</em></span> allows to create lexical
analyzers based on patterns. These patterns are regular expression based
@@ -232,11 +226,9 @@
<div class="figure">
<a name="spirit.lexerflow"></a><p class="title"><b>Figure 6. The Library structure and Common Flow of Information while
using <span class="emphasis"><em>Spirit.Lex</em></span> in an application</b></p>
-<span class="inlinemediaobject"><img src="./images/lexerflow.png" alt="The
- Library structure and Common Flow of Information while using Spirit.Lex
- in an application"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../.././images/lexerflow.png" alt="The Library structure and Common Flow of Information while using Spirit.Lex in an application"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/lex/quick_reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/quick_reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/quick_reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Quick Reference</title>
+<title>Quick Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="previous" href="abstracts/lexer_states.html" title=" Lexer States">
-<link rel="next" href="reference.html" title=" Reference">
+<link rel="up" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="prev" href="abstracts/lexer_states.html" title="Lexer States">
+<link rel="next" href="reference.html" title="Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="abstracts/lexer_states.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lex.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="reference.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.lex.quick_reference"></a> Quick Reference
-</h3></div></div>
-<div></div>
-</div></div>
+<div class="section" title="Quick Reference"><div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.lex.quick_reference"></a><a class="link" href="quick_reference.html" title="Quick Reference"> Quick Reference</a>
+</h3></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Reference</title>
+<title>Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="previous" href="quick_reference.html" title=" Quick Reference">
-<link rel="next" href="reference/concepts.html" title=" Concepts">
+<link rel="up" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="prev" href="quick_reference.html" title="Quick Reference">
+<link rel="next" href="reference/concepts.html" title="Concepts">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="quick_reference.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lex.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="reference/concepts.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.lex.reference"></a> Reference
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Reference">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.lex.reference"></a><a class="link" href="reference.html" title="Reference"> Reference</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section"> Concepts</span></dt>
<dt><span class="section">Lexer Class</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/concepts.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/concepts.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/concepts.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,12 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Concepts</title>
+<title>Concepts</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../reference.html" title=" Reference">
-<link rel="previous" href="../reference.html" title=" Reference">
+<link rel="up" href="../reference.html" title="Reference">
+<link rel="prev" href="../reference.html" title="Reference">
<link rel="next" href="concepts/lexer.html" title="Lexer">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../reference.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="concepts/lexer.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.reference.concepts"></a> Concepts
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Concepts">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.reference.concepts"></a><a class="link" href="concepts.html" title="Concepts"> Concepts</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Lexer</span></dt>
<dt><span class="section">Token</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/lexer.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/lexer.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/lexer.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Lexer</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../concepts.html" title=" Concepts">
-<link rel="previous" href="../concepts.html" title=" Concepts">
+<link rel="up" href="../concepts.html" title="Concepts">
+<link rel="prev" href="../concepts.html" title="Concepts">
<link rel="next" href="token.html" title="Token">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,375 +22,516 @@
<div class="spirit-nav">
<a accesskey="p" href="../concepts.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="token.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.reference.concepts.lexer"></a>Lexer
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Lexer">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.reference.concepts.lexer"></a><a class="link" href="lexer.html" title="Lexer">Lexer</a>
+</h5></div></div></div>
<div class="table">
-<a name="id619039"></a><p class="title"><b>Table 12. Regular expressions support</b></p>
-<table class="table" summary="Regular expressions support">
+<a name="id1324058"></a><p class="title"><b>Table 12. Regular expressions support</b></p>
+<div class="table-contents"><table class="table" summary="Regular expressions support">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Meaning
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">x</span></tt>
- </p></td>
-<td><p>
- Match any character <tt class="computeroutput"><span class="identifier">x</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">.</span></tt>
- </p></td>
-<td><p>
- Match any except newline (or optionally <span class="bold"><b>any</b></span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">x</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Match any character <code class="computeroutput"><span class="identifier">x</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">.</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Match any except newline (or optionally <span class="bold"><strong>any</strong></span>
character)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">[</span><span class="identifier">xyz</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- A character class; in this case matches <tt class="computeroutput"><span class="identifier">x</span></tt>,
- <tt class="computeroutput"><span class="identifier">y</span></tt> or <tt class="computeroutput"><span class="identifier">z</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">[</span><span class="identifier">abj</span><span class="special">-</span><span class="identifier">oZ</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- A character class with a range in it; matches <tt class="computeroutput"><span class="identifier">a</span></tt>,
- <tt class="computeroutput"><span class="identifier">b</span></tt> any letter from
- <tt class="computeroutput"><span class="identifier">j</span></tt> through <tt class="computeroutput"><span class="identifier">o</span></tt> or a <tt class="computeroutput"><span class="identifier">Z</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">[^</span><span class="identifier">A</span><span class="special">-</span><span class="identifier">Z</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">[</span><span class="identifier">xyz</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A character class; in this case matches <code class="computeroutput"><span class="identifier">x</span></code>,
+ <code class="computeroutput"><span class="identifier">y</span></code> or <code class="computeroutput"><span class="identifier">z</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">[</span><span class="identifier">abj</span><span class="special">-</span><span class="identifier">oZ</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A character class with a range in it; matches <code class="computeroutput"><span class="identifier">a</span></code>,
+ <code class="computeroutput"><span class="identifier">b</span></code> any letter from
+ <code class="computeroutput"><span class="identifier">j</span></code> through <code class="computeroutput"><span class="identifier">o</span></code> or a <code class="computeroutput"><span class="identifier">Z</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">[^</span><span class="identifier">A</span><span class="special">-</span><span class="identifier">Z</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A negated character class i.e. any character but those in the class.
In this case, any character except an uppercase letter
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">*</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">*</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Zero or more r's (greedy), where r is any regular expression
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">*?</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">*?</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Zero or more r's (abstemious), where r is any regular expression
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">+</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">+</span></code>
+ </p>
+ </td>
+<td>
+ <p>
One or more r's (greedy)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">+?</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">+?</span></code>
+ </p>
+ </td>
+<td>
+ <p>
One or more r's (abstemious)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">?</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">?</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Zero or one r's (greedy), i.e. optional
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">??</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">??</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Zero or one r's (abstemious), i.e. optional
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,</span><span class="number">5</span><span class="special">}</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,</span><span class="number">5</span><span class="special">}</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Anywhere between two and five r's (greedy)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,</span><span class="number">5</span><span class="special">}?</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,</span><span class="number">5</span><span class="special">}?</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Anywhere between two and five r's (abstemious)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,}</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,}</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Two or more r's (greedy)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,}?</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">2</span><span class="special">,}?</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Two or more r's (abstemious)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">4</span><span class="special">}</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">{</span><span class="number">4</span><span class="special">}</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Exactly four r's
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">{</span><span class="identifier">NAME</span><span class="special">}</span></tt>
- </p></td>
-<td><p>
- The macro <tt class="computeroutput"><span class="identifier">NAME</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">{</span><span class="identifier">NAME</span><span class="special">}</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The macro <code class="computeroutput"><span class="identifier">NAME</span></code>
(see below)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="string">"[xyz]\"foo"</span></tt>
- </p></td>
-<td><p>
- The literal string <tt class="computeroutput"><span class="special">[</span><span class="identifier">xyz</span><span class="special">]\</span><span class="error">"</span><span class="identifier">foo</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">X</span></tt>
- </p></td>
-<td><p>
- If X is <tt class="computeroutput"><span class="identifier">a</span></tt>, <tt class="computeroutput"><span class="identifier">b</span></tt>, <tt class="computeroutput"><span class="identifier">e</span></tt>,
- <tt class="computeroutput"><span class="identifier">n</span></tt>, <tt class="computeroutput"><span class="identifier">r</span></tt>, <tt class="computeroutput"><span class="identifier">f</span></tt>,
- <tt class="computeroutput"><span class="identifier">t</span></tt>, <tt class="computeroutput"><span class="identifier">v</span></tt> then the ANSI-C interpretation
- of <tt class="computeroutput"><span class="special">\</span><span class="identifier">x</span></tt>.
- Otherwise a literal <tt class="computeroutput"><span class="identifier">X</span></tt>
- (used to escape operators such as <tt class="computeroutput"><span class="special">*</span></tt>)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="number">0</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="string">"[xyz]\"foo"</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The literal string <code class="computeroutput"><span class="special">[</span><span class="identifier">xyz</span><span class="special">]\</span><span class="error">"</span><span class="identifier">foo</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">X</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If X is <code class="computeroutput"><span class="identifier">a</span></code>, <code class="computeroutput"><span class="identifier">b</span></code>, <code class="computeroutput"><span class="identifier">e</span></code>,
+ <code class="computeroutput"><span class="identifier">n</span></code>, <code class="computeroutput"><span class="identifier">r</span></code>, <code class="computeroutput"><span class="identifier">f</span></code>,
+ <code class="computeroutput"><span class="identifier">t</span></code>, <code class="computeroutput"><span class="identifier">v</span></code> then the ANSI-C interpretation
+ of <code class="computeroutput"><span class="special">\</span><span class="identifier">x</span></code>.
+ Otherwise a literal <code class="computeroutput"><span class="identifier">X</span></code>
+ (used to escape operators such as <code class="computeroutput"><span class="special">*</span></code>)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="number">0</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A NUL character (ASCII code 0)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="number">123</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="number">123</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The character with octal value 123
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">x2a</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">x2a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The character with hexadecimal value 2a
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">cX</span></tt>
- </p></td>
-<td><p>
- A named control character <tt class="computeroutput"><span class="identifier">X</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">d</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[</span><span class="number">0</span><span class="special">-</span><span class="number">9</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">D</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[^</span><span class="number">0</span><span class="special">-</span><span class="number">9</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">s</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[\</span><span class="identifier">x20</span><span class="special">\</span><span class="identifier">t</span><span class="special">\</span><span class="identifier">n</span><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">f</span><span class="special">\</span><span class="identifier">v</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">S</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[^\</span><span class="identifier">x20</span><span class="special">\</span><span class="identifier">t</span><span class="special">\</span><span class="identifier">n</span><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">f</span><span class="special">\</span><span class="identifier">v</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">w</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[</span><span class="identifier">a</span><span class="special">-</span><span class="identifier">zA</span><span class="special">-</span><span class="identifier">Z0</span><span class="special">-</span><span class="number">9</span><span class="identifier">_</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">\</span><span class="identifier">W</span></tt>
- </p></td>
-<td><p>
- A shortcut for <tt class="computeroutput"><span class="special">[^</span><span class="identifier">a</span><span class="special">-</span><span class="identifier">zA</span><span class="special">-</span><span class="identifier">Z0</span><span class="special">-</span><span class="number">9</span><span class="identifier">_</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">(</span><span class="identifier">r</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Match an <tt class="computeroutput"><span class="identifier">r</span></tt>; parenthesis
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">cX</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A named control character <code class="computeroutput"><span class="identifier">X</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">d</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[</span><span class="number">0</span><span class="special">-</span><span class="number">9</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">D</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[^</span><span class="number">0</span><span class="special">-</span><span class="number">9</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">s</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[\</span><span class="identifier">x20</span><span class="special">\</span><span class="identifier">t</span><span class="special">\</span><span class="identifier">n</span><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">f</span><span class="special">\</span><span class="identifier">v</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">S</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[^\</span><span class="identifier">x20</span><span class="special">\</span><span class="identifier">t</span><span class="special">\</span><span class="identifier">n</span><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">f</span><span class="special">\</span><span class="identifier">v</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">w</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[</span><span class="identifier">a</span><span class="special">-</span><span class="identifier">zA</span><span class="special">-</span><span class="identifier">Z0</span><span class="special">-</span><span class="number">9</span><span class="identifier">_</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">\</span><span class="identifier">W</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A shortcut for <code class="computeroutput"><span class="special">[^</span><span class="identifier">a</span><span class="special">-</span><span class="identifier">zA</span><span class="special">-</span><span class="identifier">Z0</span><span class="special">-</span><span class="number">9</span><span class="identifier">_</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">(</span><span class="identifier">r</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Match an <code class="computeroutput"><span class="identifier">r</span></code>; parenthesis
are used to override precedence (see below)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">(?</span><span class="identifier">r</span><span class="special">-</span><span class="identifier">s</span><span class="special">:</span><span class="identifier">pattern</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">(?</span><span class="identifier">r</span><span class="special">-</span><span class="identifier">s</span><span class="special">:</span><span class="identifier">pattern</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
apply option 'r' and omit option 's' while interpreting pattern.
Options may be zero or more of the characters 'i' or 's'. 'i' means
case-insensitive. '-i' means case-sensitive. 's' alters the meaning
of the '.' syntax to match any single character whatsoever. '-s'
- alters the meaning of '.' to match any character except '<tt class="computeroutput"><span class="special">\</span><span class="identifier">n</span></tt>'.
- </p></td>
+ alters the meaning of '.' to match any character except '<code class="computeroutput"><span class="special">\</span><span class="identifier">n</span></code>'.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">rs</span></tt>
- </p></td>
-<td><p>
- The regular expression <tt class="computeroutput"><span class="identifier">r</span></tt>
- followed by the regular expression <tt class="computeroutput"><span class="identifier">s</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">rs</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The regular expression <code class="computeroutput"><span class="identifier">r</span></code>
+ followed by the regular expression <code class="computeroutput"><span class="identifier">s</span></code>
(a sequence)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">|</span><span class="identifier">s</span></tt>
- </p></td>
-<td><p>
- Either an <tt class="computeroutput"><span class="identifier">r</span></tt> or
- and <tt class="computeroutput"><span class="identifier">s</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">^</span><span class="identifier">r</span></tt>
- </p></td>
-<td><p>
- An <tt class="computeroutput"><span class="identifier">r</span></tt> but only at
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">|</span><span class="identifier">s</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Either an <code class="computeroutput"><span class="identifier">r</span></code> or
+ and <code class="computeroutput"><span class="identifier">s</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">^</span><span class="identifier">r</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ An <code class="computeroutput"><span class="identifier">r</span></code> but only at
the beginning of a line (i.e. when just starting to scan, or right
after a newline has been scanned)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span></tt>$
- </p></td>
-<td><p>
- An <tt class="computeroutput"><span class="identifier">r</span></tt> but only at
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span></code>$
+ </p>
+ </td>
+<td>
+ <p>
+ An <code class="computeroutput"><span class="identifier">r</span></code> but only at
the end of a line (i.e. just before a newline)
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<div class="note"><table border="0" summary="Note">
+<br class="table-break"><div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
POSIX character classes are not currently supported, due to performance
issues when creating them in wide character mode.
</p></td></tr>
</table></div>
<a name="spirit.lex.reference.concepts.lexer.regular_expression_precedence"></a><h6>
-<a name="id621128"></a>
- <a href="lexer.html#spirit.lex.reference.concepts.lexer.regular_expression_precedence">Regular
+<a name="id1325636"></a>
+ <a class="link" href="lexer.html#spirit.lex.reference.concepts.lexer.regular_expression_precedence">Regular
Expression Precedence</a>
</h6>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<tt class="computeroutput"><span class="identifier">rs</span></tt> has highest precedence
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">rs</span></code> has highest precedence
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">r</span><span class="special">*</span></tt>
- has next highest (<tt class="computeroutput"><span class="special">+</span></tt>,
- <tt class="computeroutput"><span class="special">?</span></tt>, <tt class="computeroutput"><span class="special">{</span><span class="identifier">n</span><span class="special">,</span><span class="identifier">m</span><span class="special">}</span></tt>
- have the same precedence as <tt class="computeroutput"><span class="special">*</span></tt>)
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">r</span><span class="special">*</span></code>
+ has next highest (<code class="computeroutput"><span class="special">+</span></code>,
+ <code class="computeroutput"><span class="special">?</span></code>, <code class="computeroutput"><span class="special">{</span><span class="identifier">n</span><span class="special">,</span><span class="identifier">m</span><span class="special">}</span></code>
+ have the same precedence as <code class="computeroutput"><span class="special">*</span></code>)
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">r</span><span class="special">|</span><span class="identifier">s</span></tt> has the lowest precedence
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">r</span><span class="special">|</span><span class="identifier">s</span></code> has the lowest precedence
</li>
</ul></div>
<a name="spirit.lex.reference.concepts.lexer.macros"></a><h6>
-<a name="id621285"></a>
- Macros
+<a name="id1325739"></a>
+ <a class="link" href="lexer.html#spirit.lex.reference.concepts.lexer.macros">Macros</a>
</h6>
<p>
Regular expressions can be given a name and referred to in rules using
- the syntax <tt class="computeroutput"><span class="special">{</span><span class="identifier">NAME</span><span class="special">}</span></tt> where <tt class="computeroutput"><span class="identifier">NAME</span></tt>
+ the syntax <code class="computeroutput"><span class="special">{</span><span class="identifier">NAME</span><span class="special">}</span></code> where <code class="computeroutput"><span class="identifier">NAME</span></code>
is the name you have given to the macro. A macro name can be at most
- 30 characters long and must start with a <tt class="computeroutput"><span class="identifier">_</span></tt>
- or a letter. Subsequent characters can be <tt class="computeroutput"><span class="identifier">_</span></tt>,
- <tt class="computeroutput"><span class="special">-</span></tt>, a letter or a decimal
- digit. Use the <tt class="computeroutput"><span class="identifier">rules</span><span class="special">::</span><span class="identifier">add_macro</span><span class="special">()</span></tt> method to define a macro.
+ 30 characters long and must start with a <code class="computeroutput"><span class="identifier">_</span></code>
+ or a letter. Subsequent characters can be <code class="computeroutput"><span class="identifier">_</span></code>,
+ <code class="computeroutput"><span class="special">-</span></code>, a letter or a decimal
+ digit. Use the <code class="computeroutput"><span class="identifier">rules</span><span class="special">::</span><span class="identifier">add_macro</span><span class="special">()</span></code> method to define a macro.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/token.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/token.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/token.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Token</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../concepts.html" title=" Concepts">
-<link rel="previous" href="lexer.html" title="Lexer">
+<link rel="up" href="../concepts.html" title="Concepts">
+<link rel="prev" href="lexer.html" title="Lexer">
<link rel="next" href="tokendef.html" title="TokenDef">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tokendef.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.reference.concepts.token"></a>Token
-</h5></div></div>
-<div></div>
-</div></div>
+<div class="section" title="Token"><div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.reference.concepts.token"></a><a class="link" href="token.html" title="Token">Token</a>
+</h5></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/tokendef.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/tokendef.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/concepts/tokendef.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>TokenDef</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../concepts.html" title=" Concepts">
-<link rel="previous" href="token.html" title="Token">
+<link rel="up" href="../concepts.html" title="Concepts">
+<link rel="prev" href="token.html" title="Token">
<link rel="next" href="../lexer_class.html" title="Lexer Class">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="token.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../lexer_class.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.lex.reference.concepts.tokendef"></a>TokenDef
-</h5></div></div>
-<div></div>
-</div></div>
+<div class="section" title="TokenDef"><div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.lex.reference.concepts.tokendef"></a><a class="link" href="tokendef.html" title="TokenDef">TokenDef</a>
+</h5></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/lexer_class.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/lexer_class.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/lexer_class.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Lexer Class</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../reference.html" title=" Reference">
-<link rel="previous" href="concepts/tokendef.html" title="TokenDef">
+<link rel="up" href="../reference.html" title="Reference">
+<link rel="prev" href="concepts/tokendef.html" title="TokenDef">
<link rel="next" href="token_class.html" title="Token Class">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,33 +22,30 @@
<div class="spirit-nav">
<a accesskey="p" href="concepts/tokendef.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="token_class.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.reference.lexer_class"></a>Lexer Class
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model"></a><h5>
-<a name="id621475"></a>
- <a href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model">The
+<div class="section" title="Lexer Class">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.reference.lexer_class"></a><a class="link" href="lexer_class.html" title="Lexer Class">Lexer Class</a>
+</h4></div></div></div>
+<a name="spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model"></a><h6>
+<a name="id1325850"></a>
+ <a class="link" href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_lexer_class_implementing_the_dynamic_model">The
lexertl_lexer Class Implementing the Dynamic Model</a>
- </h5>
-<a name="spirit.lex.reference.lexer_class.the_lexertl_actor_lexer_class_implementing_the_dynamic_model"></a><h5>
-<a name="id621502"></a>
- <a href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_actor_lexer_class_implementing_the_dynamic_model">The
+ </h6>
+<a name="spirit.lex.reference.lexer_class.the_lexertl_actor_lexer_class_implementing_the_dynamic_model"></a><h6>
+<a name="id1325864"></a>
+ <a class="link" href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_actor_lexer_class_implementing_the_dynamic_model">The
lexertl_actor_lexer Class Implementing the Dynamic Model</a>
- </h5>
-<a name="spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model"></a><h5>
-<a name="id621530"></a>
- <a href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model">The
+ </h6>
+<a name="spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model"></a><h6>
+<a name="id1327523"></a>
+ <a class="link" href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_lexer_class_implementing_the_static_model">The
lexertl_static_lexer Class Implementing the Static Model</a>
- </h5>
-<a name="spirit.lex.reference.lexer_class.the_lexertl_static_actor_lexer_class_implementing_the_static_model"></a><h5>
-<a name="id621559"></a>
- <a href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_actor_lexer_class_implementing_the_static_model">The
+ </h6>
+<a name="spirit.lex.reference.lexer_class.the_lexertl_static_actor_lexer_class_implementing_the_static_model"></a><h6>
+<a name="id1327536"></a>
+ <a class="link" href="lexer_class.html#spirit.lex.reference.lexer_class.the_lexertl_static_actor_lexer_class_implementing_the_static_model">The
lexertl_static_actor_lexer Class Implementing the Static Model</a>
- </h5>
+ </h6>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/token_class.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/token_class.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/token_class.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Token Class</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../reference.html" title=" Reference">
-<link rel="previous" href="lexer_class.html" title="Lexer Class">
+<link rel="up" href="../reference.html" title="Reference">
+<link rel="prev" href="lexer_class.html" title="Lexer Class">
<link rel="next" href="tokendef_class.html" title="TokenDef Class">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_class.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tokendef_class.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.reference.token_class"></a>Token Class
-</h4></div></div>
-<div></div>
-</div></div>
+<div class="section" title="Token Class"><div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.reference.token_class"></a><a class="link" href="token_class.html" title="Token Class">Token Class</a>
+</h4></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/reference/tokendef_class.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/reference/tokendef_class.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/reference/tokendef_class.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>TokenDef Class</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../reference.html" title=" Reference">
-<link rel="previous" href="token_class.html" title="Token Class">
-<link rel="next" href="../../support.html" title=" Supporting libraries">
+<link rel="up" href="../reference.html" title="Reference">
+<link rel="prev" href="token_class.html" title="Token Class">
+<link rel="next" href="../../support.html" title="Supporting libraries">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,12 +22,9 @@
<div class="spirit-nav">
<a accesskey="p" href="token_class.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../support.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en"><div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.reference.tokendef_class"></a>TokenDef Class
-</h4></div></div>
-<div></div>
-</div></div>
+<div class="section" title="TokenDef Class"><div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.reference.tokendef_class"></a><a class="link" href="tokendef_class.html" title="TokenDef Class">TokenDef Class</a>
+</h4></div></div></div></div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2009 Joel
Modified: trunk/libs/spirit/doc/html/spirit/lex/tutorials.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/tutorials.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/tutorials.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Spirit.Lex
- Tutorials</title>
+<title>Spirit.Lex Tutorials</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../lex.html" title=" Lex - Writing Lexical Analyzers">
-<link rel="previous" href="lexer_introduction.html" title=" Introduction to Spirit.Lex">
-<link rel="next" href="tutorials/lexer_tutorials.html" title=" Spirit.Lex
- Tutorials Overview">
+<link rel="up" href="../lex.html" title="Lex - Writing Lexical Analyzers">
+<link rel="prev" href="lexer_introduction.html" title="Introduction to Spirit.Lex">
+<link rel="next" href="tutorials/lexer_tutorials.html" title="Spirit.Lex Tutorials Overview">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_introduction.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lex.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tutorials/lexer_tutorials.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.lex.tutorials"></a><a href="tutorials.html" title=" Spirit.Lex
- Tutorials"> <span class="emphasis"><em>Spirit.Lex</em></span>
+<div class="section" title="Spirit.Lex Tutorials">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.lex.tutorials"></a><a class="link" href="tutorials.html" title="Spirit.Lex Tutorials"> <span class="emphasis"><em>Spirit.Lex</em></span>
Tutorials</a>
-</h3></div></div>
-<div></div>
-</div>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="tutorials/lexer_tutorials.html"> <span class="emphasis"><em>Spirit.Lex</em></span>
Tutorials Overview</a></span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart1.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart1.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart1.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Quickstart
- 1 - A word counter using Spirit.Lex</title>
+<title>Quickstart 1 - A word counter using Spirit.Lex</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../tutorials.html" title=" Spirit.Lex
- Tutorials">
-<link rel="previous" href="lexer_tutorials.html" title=" Spirit.Lex
- Tutorials Overview">
-<link rel="next" href="lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">
+<link rel="up" href="../tutorials.html" title="Spirit.Lex Tutorials">
+<link rel="prev" href="lexer_tutorials.html" title="Spirit.Lex Tutorials Overview">
+<link rel="next" href="lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_tutorials.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_quickstart2.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.tutorials.lexer_quickstart1"></a><a href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex"> Quickstart
+<div class="section" title="Quickstart 1 - A word counter using Spirit.Lex">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.tutorials.lexer_quickstart1"></a><a class="link" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex"> Quickstart
1 - A word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
<span class="emphasis"><em>Spirit.Lex</em></span> is very modular, which follows the general
building principle of the Spirit
@@ -43,20 +35,20 @@
but nevertheless can be used separately to build standalone lexical analyzers.
The first quick start example describes a standalone application: counting
characters, words, and lines in a file, very similar to what the well known
- Unix command <tt class="computeroutput"><span class="identifier">wc</span></tt> is doing
+ Unix command <code class="computeroutput"><span class="identifier">wc</span></code> is doing
(for the full example code see here: word_count_functor.cpp).
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart1.prerequisites"></a><h5>
-<a name="id592451"></a>
- Prerequisites
- </h5>
+<a name="spirit.lex.tutorials.lexer_quickstart1.prerequisites"></a><h6>
+<a name="id1302065"></a>
+ <a class="link" href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.prerequisites">Prerequisites</a>
+ </h6>
<p>
- The only required <tt class="computeroutput"><span class="preprocessor">#include</span></tt>
+ The only required <code class="computeroutput"><span class="preprocessor">#include</span></code>
specific to <span class="emphasis"><em>Spirit.Lex</em></span> follows. It is a wrapper for
all necessary definitions to use <span class="emphasis"><em>Spirit.Lex</em></span> in a standalone
fashion, and on top of the Lexertl
- library. Additionally we <tt class="computeroutput"><span class="preprocessor">#include</span></tt>
- two of the Boost headers to define <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">bind</span><span class="special">()</span></tt> and <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">ref</span><span class="special">()</span></tt>.
+ library. Additionally we <code class="computeroutput"><span class="preprocessor">#include</span></code>
+ two of the Boost headers to define <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">bind</span><span class="special">()</span></code> and <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">ref</span><span class="special">()</span></code>.
</p>
<p>
</p>
@@ -85,11 +77,11 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart1.defining_tokens"></a><h5>
-<a name="id592800"></a>
- <a href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.defining_tokens">Defining
+<a name="spirit.lex.tutorials.lexer_quickstart1.defining_tokens"></a><h6>
+<a name="id1302310"></a>
+ <a class="link" href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.defining_tokens">Defining
Tokens</a>
- </h5>
+ </h6>
<p>
The most important step while creating a lexer using <span class="emphasis"><em>Spirit.Lex</em></span>
is to define the tokens to be recognized in the input sequence. This is
@@ -102,16 +94,16 @@
<p>
</p>
<p>
- The template <tt class="computeroutput"><span class="identifier">word_count_tokens</span></tt>
- defines three different tokens: <tt class="computeroutput"><span class="identifier">ID_WORD</span></tt>,
- <tt class="computeroutput"><span class="identifier">ID_EOL</span></tt>, and <tt class="computeroutput"><span class="identifier">ID_CHAR</span></tt>, representing a word (anything
+ The template <code class="computeroutput"><span class="identifier">word_count_tokens</span></code>
+ defines three different tokens: <code class="computeroutput"><span class="identifier">ID_WORD</span></code>,
+ <code class="computeroutput"><span class="identifier">ID_EOL</span></code>, and <code class="computeroutput"><span class="identifier">ID_CHAR</span></code>, representing a word (anything
except a whitespace or a newline), a newline character, and any other
- character (<tt class="computeroutput"><span class="identifier">ID_WORD</span></tt>,
- <tt class="computeroutput"><span class="identifier">ID_EOL</span></tt>, and <tt class="computeroutput"><span class="identifier">ID_CHAR</span></tt> are enum values representing
+ character (<code class="computeroutput"><span class="identifier">ID_WORD</span></code>,
+ <code class="computeroutput"><span class="identifier">ID_EOL</span></code>, and <code class="computeroutput"><span class="identifier">ID_CHAR</span></code> are enum values representing
the token ids, but could be anything else convertible to an integer as
well). The direct base class of any token definition class needs to be
- the template <tt class="computeroutput"><span class="identifier">lexer_def</span><span class="special"><></span></tt>, where the corresponding template
- parameter (here: <tt class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><</span><span class="identifier">BaseIterator</span><span class="special">></span></tt>) defines which underlying lexer engine
+ the template <code class="computeroutput"><span class="identifier">lexer_def</span><span class="special"><></span></code>, where the corresponding template
+ parameter (here: <code class="computeroutput"><span class="identifier">lexertl_lexer</span><span class="special"><</span><span class="identifier">BaseIterator</span><span class="special">></span></code>) defines which underlying lexer engine
has to be used to provide the required state machine functionality. In
this example we use the Lexertl based lexer engine as the underlying
lexer type.
@@ -140,18 +132,18 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart1.doing_the_useful_work"></a><h5>
-<a name="id593249"></a>
- <a href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.doing_the_useful_work">Doing
+<a name="spirit.lex.tutorials.lexer_quickstart1.doing_the_useful_work"></a><h6>
+<a name="id1302618"></a>
+ <a class="link" href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.doing_the_useful_work">Doing
the Useful Work</a>
- </h5>
+ </h6>
<p>
We will use a setup, where we want the <span class="emphasis"><em>Spirit.Lex</em></span>
library to invoke a given function after any of of the generated tokens
is recognized. For this reason we need to implement a functor taking at
least the generated token as an argument and returning a boolean value
allowing to stop the tokenization process. The default token type used
- in this example carries a token value of the type <tt class="computeroutput"><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">BaseIterator</span><span class="special">></span></tt> pointing to the matched range in the
+ in this example carries a token value of the type <code class="computeroutput"><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">BaseIterator</span><span class="special">></span></code> pointing to the matched range in the
underlying input sequence.
</p>
<p>
@@ -198,25 +190,25 @@
</p>
<p>
All what's left is to write some boilerplate code helping to tie together
- the pieces described so far. To simplify this example we call the <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></tt>
+ the pieces described so far. To simplify this example we call the <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></code>
function implemented in <span class="emphasis"><em>Spirit.Lex</em></span> (for a more detailed
- description of this function see here: <span class="bold"><b>FIXME</b></span>),
+ description of this function see here: <span class="bold"><strong>FIXME</strong></span>),
even if we could have written a loop to iterate over the lexer iterators
- [<tt class="computeroutput"><span class="identifier">first</span></tt>, <tt class="computeroutput"><span class="identifier">last</span></tt>)
+ [<code class="computeroutput"><span class="identifier">first</span></code>, <code class="computeroutput"><span class="identifier">last</span></code>)
as well.
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart1.pulling_everything_together"></a><h5>
-<a name="id593947"></a>
- <a href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.pulling_everything_together">Pulling
+<a name="spirit.lex.tutorials.lexer_quickstart1.pulling_everything_together"></a><h6>
+<a name="id1303118"></a>
+ <a class="link" href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.pulling_everything_together">Pulling
Everything Together</a>
- </h5>
+ </h6>
<p>
</p>
<p>
- The main function simply loads the given file into memory (as a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>), instantiates an instance of
- the token definition template using the correct iterator type (<tt class="computeroutput"><span class="identifier">word_count_tokens</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*></span></tt>), and finally calls <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span></tt>, passing an instance of the
- counter function object. The return value of <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></tt> will be <tt class="computeroutput"><span class="keyword">true</span></tt>
- if the whole input sequence has been successfully tokenized, and <tt class="computeroutput"><span class="keyword">false</span></tt> otherwise.
+ The main function simply loads the given file into memory (as a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>), instantiates an instance of
+ the token definition template using the correct iterator type (<code class="computeroutput"><span class="identifier">word_count_tokens</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*></span></code>), and finally calls <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span></code>, passing an instance of the
+ counter function object. The return value of <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize</span><span class="special">()</span></code> will be <code class="computeroutput"><span class="keyword">true</span></code>
+ if the whole input sequence has been successfully tokenized, and <code class="computeroutput"><span class="keyword">false</span></code> otherwise.
</p>
<p>
</p>
@@ -258,23 +250,23 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart1.comparing__emphasis_spirit_lex__emphasis__with__ulink_url__http___flex_sourceforge_net___flex__ulink_"></a><h5>
-<a name="id595078"></a>
- <a href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.comparing__emphasis_spirit_lex__emphasis__with__ulink_url__http___flex_sourceforge_net___flex__ulink_">Comparing
+<a name="spirit.lex.tutorials.lexer_quickstart1.comparing__emphasis_spirit_lex__emphasis__with__ulink_url__http___flex_sourceforge_net___flex__ulink_"></a><h6>
+<a name="id1303944"></a>
+ <a class="link" href="lexer_quickstart1.html#spirit.lex.tutorials.lexer_quickstart1.comparing__emphasis_spirit_lex__emphasis__with__ulink_url__http___flex_sourceforge_net___flex__ulink_">Comparing
<span class="emphasis"><em>Spirit.Lex</em></span> with Flex</a>
- </h5>
+ </h6>
<p>
This example was deliberately chosen to be as much as possible similar
to the equivalent Flex
program (see below), which isn't too different from what has to be written
when using <span class="emphasis"><em>Spirit.Lex</em></span>.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
Interestingly enough, performance comparisons of lexical analyzers written
using <span class="emphasis"><em>Spirit.Lex</em></span> with equivalent programs generated
by Flex show that both
Modified: trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart2.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart2.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart2.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Quickstart
- 2 - A better word counter using Spirit.Lex</title>
+<title>Quickstart 2 - A better word counter using Spirit.Lex</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../tutorials.html" title=" Spirit.Lex
- Tutorials">
-<link rel="previous" href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">
-<link rel="next" href="lexer_quickstart3.html" title=" Quickstart
- 3 - Counting Words Using a Parser">
+<link rel="up" href="../tutorials.html" title="Spirit.Lex Tutorials">
+<link rel="prev" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">
+<link rel="next" href="lexer_quickstart3.html" title="Quickstart 3 - Counting Words Using a Parser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,19 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_quickstart1.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_quickstart3.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.tutorials.lexer_quickstart2"></a><a href="lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex"> Quickstart
+<div class="section" title="Quickstart 2 - A better word counter using Spirit.Lex">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.tutorials.lexer_quickstart2"></a><a class="link" href="lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex"> Quickstart
2 - A better word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
People knowing Flex will
- probably complain about the example from the section <a href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">Lex
+ probably complain about the example from the section <a class="link" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">Lex
Quickstart 1 - A word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
as being overly complex and not being written to leverage the possibilities
provided by this tool. In particular the previous example did not directly
@@ -48,12 +39,12 @@
to count text elements only it introduces other new concepts and configuration
options along the lines (for the full example code see here: word_count_lexer.cpp).
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart2.prerequisites"></a><h5>
-<a name="id596135"></a>
- Prerequisites
- </h5>
+<a name="spirit.lex.tutorials.lexer_quickstart2.prerequisites"></a><h6>
+<a name="id1306575"></a>
+ <a class="link" href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.prerequisites">Prerequisites</a>
+ </h6>
<p>
- In addition to the only required <tt class="computeroutput"><span class="preprocessor">#include</span></tt>
+ In addition to the only required <code class="computeroutput"><span class="preprocessor">#include</span></code>
specific to <span class="emphasis"><em>Spirit.Lex</em></span> this example needs to include
a couple of header files from the Boost.Phoenix
library. This example shows how to attach functors to token definitions,
@@ -122,18 +113,18 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart2.semantic_actions_in__emphasis_spirit_lex__emphasis_"></a><h5>
-<a name="id597025"></a>
- <a href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.semantic_actions_in__emphasis_spirit_lex__emphasis_">Semantic
+<a name="spirit.lex.tutorials.lexer_quickstart2.semantic_actions_in__emphasis_spirit_lex__emphasis_"></a><h6>
+<a name="id1307224"></a>
+ <a class="link" href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.semantic_actions_in__emphasis_spirit_lex__emphasis_">Semantic
Actions in <span class="emphasis"><em>Spirit.Lex</em></span></a>
- </h5>
+ </h6>
<p>
<span class="emphasis"><em>Spirit.Lex</em></span> uses a very similar way of associating
actions with the token definitions (which should look familiar to anybody
knowlegdeable with Spirit
- as well): specifying the operations to execute inside of a pair of <tt class="computeroutput"><span class="special">[]</span></tt> brackets. In order to be able to attach
+ as well): specifying the operations to execute inside of a pair of <code class="computeroutput"><span class="special">[]</span></code> brackets. In order to be able to attach
semantic actions to token definitions for each of them there is defined
- an instance of a <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt>.
+ an instance of a <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code>.
</p>
<p>
</p>
@@ -170,7 +161,7 @@
<p>
</p>
<p>
- The semantics of the shown code is as follows. The code inside the <tt class="computeroutput"><span class="special">[]</span></tt> brackets will be executed whenever the
+ The semantics of the shown code is as follows. The code inside the <code class="computeroutput"><span class="special">[]</span></code> brackets will be executed whenever the
corresponding token has been matched by the lexical analyzer. This is very
similar to Flex, where
the action code associated with a token definition gets executed after
@@ -178,24 +169,22 @@
objects constructed using Boost.Phoenix,
but it is possible to insert any C++ function or function object as long
as it exposes the proper interface. For more details on please refer to
- the section <a href="../abstracts/lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">Lexer
+ the section <a class="link" href="../abstracts/lexer_semantic_actions.html" title="Lexer Semantic Actions">Lexer
Semantic Actions</a>.
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart2.associating_token_definitions_with_the_lexer"></a><h5>
-<a name="id597882"></a>
- <a href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.associating_token_definitions_with_the_lexer">Associating
+<a name="spirit.lex.tutorials.lexer_quickstart2.associating_token_definitions_with_the_lexer"></a><h6>
+<a name="id1307842"></a>
+ <a class="link" href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.associating_token_definitions_with_the_lexer">Associating
Token Definitions with the Lexer</a>
- </h5>
+ </h6>
<p>
- If you compare this code to the code from <a href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">Lex
+ If you compare this code to the code from <a class="link" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">Lex
Quickstart 1 - A word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
with regard to the way how token definitions are associated with the lexer,
you will notice a different syntax being used here. In the previous example
- we have been using the <tt class="computeroutput"><span class="identifier">self</span><span class="special">.</span><span class="identifier">add</span><span class="special">()</span></tt> style of the API, while we here directly
- assign the token definitions to <tt class="computeroutput"><span class="identifier">self</span></tt>,
- combining the different token definitions using the <tt class="computeroutput"><span class="special">|</span></tt>
+ we have been using the <code class="computeroutput"><span class="identifier">self</span><span class="special">.</span><span class="identifier">add</span><span class="special">()</span></code> style of the API, while we here directly
+ assign the token definitions to <code class="computeroutput"><span class="identifier">self</span></code>,
+ combining the different token definitions using the <code class="computeroutput"><span class="special">|</span></code>
operator. Here is the code snippet again:
</p>
<pre class="programlisting"><span class="identifier">self</span> <span class="special">=</span> <span class="identifier">word</span> <span class="special">[++</span><span class="identifier">ref</span><span class="special">(</span><span class="identifier">w</span><span class="special">),</span> <span class="identifier">ref</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span> <span class="special">+=</span> <span class="identifier">distance</span><span class="special">(</span><span class="identifier">_1</span><span class="special">)]</span>
@@ -206,10 +195,10 @@
<p>
This way we have a very powerful and natural way of building the lexical
analyzer. If translated into English this may be read as: The lexical analyer
- will recognize ('<tt class="computeroutput"><span class="special">=</span></tt>') tokens
- as defined by any of ('<tt class="computeroutput"><span class="special">|</span></tt>')
- the token definitions <tt class="computeroutput"><span class="identifier">word</span></tt>,
- <tt class="computeroutput"><span class="identifier">eol</span></tt>, and <tt class="computeroutput"><span class="identifier">any</span></tt>.
+ will recognize ('<code class="computeroutput"><span class="special">=</span></code>') tokens
+ as defined by any of ('<code class="computeroutput"><span class="special">|</span></code>')
+ the token definitions <code class="computeroutput"><span class="identifier">word</span></code>,
+ <code class="computeroutput"><span class="identifier">eol</span></code>, and <code class="computeroutput"><span class="identifier">any</span></code>.
</p>
<p>
A second difference to the previous example is that we do not explicitly
@@ -217,13 +206,13 @@
to trigger some useful work has freed us from the need to define those.
To ensure every token gets assigned a id the <span class="emphasis"><em>Spirit.Lex</em></span>
library internally assigns unique numbers to the token definitions, starting
- with the constant defined by <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lex</span><span class="special">::</span><span class="identifier">min_token_id</span></tt>.
+ with the constant defined by <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lex</span><span class="special">::</span><span class="identifier">min_token_id</span></code>.
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart2.pulling_everything_together"></a><h5>
-<a name="id598308"></a>
- <a href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.pulling_everything_together">Pulling
+<a name="spirit.lex.tutorials.lexer_quickstart2.pulling_everything_together"></a><h6>
+<a name="id1308130"></a>
+ <a class="link" href="lexer_quickstart2.html#spirit.lex.tutorials.lexer_quickstart2.pulling_everything_together">Pulling
everything together</a>
- </h5>
+ </h6>
<p>
In order to execute the code defined above we still need to instantiate
an instance of the lexer type, feed it from some input sequence and create
@@ -238,20 +227,20 @@
<pre class="programlisting"><span class="keyword">int</span> <span class="identifier">main</span><span class="special">(</span><span class="keyword">int</span> <span class="identifier">argc</span><span class="special">,</span> <span class="keyword">char</span><span class="special">*</span> <span class="identifier">argv</span><span class="special">[])</span>
<span class="special">{</span>
-<span class="callout_bug"><a name="spirit8co" href="lexer_quickstart2.html#spirit8"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*,</span> <span class="identifier">omitted</span><span class="special">,</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span><span class="special">></span> <span class="identifier">token_type</span><span class="special">;</span>
+<span class="callout_bug"><a class="co" name="spirit8co" href="lexer_quickstart2.html#spirit8"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span><span class="special"><</span><span class="keyword">char</span> <span class="keyword">const</span><span class="special">*,</span> <span class="identifier">omitted</span><span class="special">,</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span><span class="special">></span> <span class="identifier">token_type</span><span class="special">;</span>
-<span class="callout_bug"><a name="spirit9co" href="lexer_quickstart2.html#spirit9"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">actor_lexer</span><span class="special"><</span><span class="identifier">token_type</span><span class="special">></span> <span class="identifier">lexer_type</span><span class="special">;</span>
+<span class="callout_bug"><a class="co" name="spirit9co" href="lexer_quickstart2.html#spirit9"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">actor_lexer</span><span class="special"><</span><span class="identifier">token_type</span><span class="special">></span> <span class="identifier">lexer_type</span><span class="special">;</span>
-<span class="callout_bug"><a name="spirit10co" href="lexer_quickstart2.html#spirit10"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span> <span class="identifier">word_count_tokens</span><span class="special"><</span><span class="identifier">lexer_type</span><span class="special">></span> <span class="identifier">word_count_lexer</span><span class="special">;</span>
+<span class="callout_bug"><a class="co" name="spirit10co" href="lexer_quickstart2.html#spirit10"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span> <span class="identifier">word_count_tokens</span><span class="special"><</span><span class="identifier">lexer_type</span><span class="special">></span> <span class="identifier">word_count_lexer</span><span class="special">;</span>
-<span class="callout_bug"><a name="spirit11co" href="lexer_quickstart2.html#spirit11"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">str</span> <span class="special">(</span><span class="identifier">read_from_file</span><span class="special">(</span><span class="number">1</span> <span class="special">==</span> <span class="identifier">argc</span> <span class="special">?</span> <span class="string">"word_count.input"</span> <span class="special">:</span> <span class="identifier">argv</span><span class="special">[</span><span class="number">1</span><span class="special">]));</span>
+<span class="callout_bug"><a class="co" name="spirit11co" href="lexer_quickstart2.html#spirit11"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <span class="identifier">str</span> <span class="special">(</span><span class="identifier">read_from_file</span><span class="special">(</span><span class="number">1</span> <span class="special">==</span> <span class="identifier">argc</span> <span class="special">?</span> <span class="string">"word_count.input"</span> <span class="special">:</span> <span class="identifier">argv</span><span class="special">[</span><span class="number">1</span><span class="special">]));</span>
<span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">first</span> <span class="special">=</span> <span class="identifier">str</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">();</span>
<span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">last</span> <span class="special">=</span> <span class="special">&</span><span class="identifier">first</span><span class="special">[</span><span class="identifier">str</span><span class="special">.</span><span class="identifier">size</span><span class="special">()];</span>
-<span class="callout_bug"><a name="spirit12co" href="lexer_quickstart2.html#spirit12"><img src="../../../../../../../doc/src/images/callouts/5.png" alt="5" border="0"></a></span> <span class="identifier">lexer_type</span><span class="special">::</span><span class="identifier">iterator_type</span> <span class="identifier">iter</span> <span class="special">=</span> <span class="identifier">word_count_lexer</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">);</span>
+<span class="callout_bug"><a class="co" name="spirit12co" href="lexer_quickstart2.html#spirit12"><img src="../../../../../../../doc/src/images/callouts/5.png" alt="5" border="0"></a></span> <span class="identifier">lexer_type</span><span class="special">::</span><span class="identifier">iterator_type</span> <span class="identifier">iter</span> <span class="special">=</span> <span class="identifier">word_count_lexer</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">);</span>
<span class="identifier">lexer_type</span><span class="special">::</span><span class="identifier">iterator_type</span> <span class="identifier">end</span> <span class="special">=</span> <span class="identifier">word_count_lexer</span><span class="special">.</span><span class="identifier">end</span><span class="special">();</span>
-<span class="callout_bug"><a name="spirit13co" href="lexer_quickstart2.html#spirit13"><img src="../../../../../../../doc/src/images/callouts/6.png" alt="6" border="0"></a></span> <span class="keyword">while</span> <span class="special">(</span><span class="identifier">iter</span> <span class="special">!=</span> <span class="identifier">end</span> <span class="special">&&</span> <span class="identifier">token_is_valid</span><span class="special">(*</span><span class="identifier">iter</span><span class="special">))</span>
+<span class="callout_bug"><a class="co" name="spirit13co" href="lexer_quickstart2.html#spirit13"><img src="../../../../../../../doc/src/images/callouts/6.png" alt="6" border="0"></a></span> <span class="keyword">while</span> <span class="special">(</span><span class="identifier">iter</span> <span class="special">!=</span> <span class="identifier">end</span> <span class="special">&&</span> <span class="identifier">token_is_valid</span><span class="special">(*</span><span class="identifier">iter</span><span class="special">))</span>
<span class="special">++</span><span class="identifier">iter</span><span class="special">;</span>
<span class="keyword">if</span> <span class="special">(</span><span class="identifier">iter</span> <span class="special">==</span> <span class="identifier">end</span><span class="special">)</span> <span class="special">{</span>
@@ -276,44 +265,38 @@
</p>
<div class="calloutlist"><table border="0" summary="Callout list">
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit8"></a> </td>
-<td valign="top" align="left"><p> Specifying <tt class="computeroutput"><span class="identifier">omitted</span></tt> as
+<td width="5%" valign="top" align="left"><p><a name="spirit8"></a> </p></td>
+<td valign="top" align="left"><p> Specifying <code class="computeroutput"><span class="identifier">omitted</span></code> as
the token attribute type generates a token class not holding any token
attribute at all (not even the iterator range of the matched input sequence),
therefore optimizing the token, the lexer, and possibly the parser implementation
- as much as possible. Specifying <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+ as much as possible. Specifying <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
as the 3rd template parameter generates a token type and an iterator,
both holding no lexer state, allowing for even more aggressive optimizations.
As a result the token instances contain the token ids as the only data
member. </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit9"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit9"></a> </p></td>
<td valign="top" align="left"><p> This defines the lexer type to use </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit10"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit10"></a> </p></td>
<td valign="top" align="left"><p> Create the lexer object instance
needed to invoke the lexical analysis </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit11"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit11"></a> </p></td>
<td valign="top" align="left"><p> Read input from the given file,
tokenize all the input, while discarding all generated tokens </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit12"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit12"></a> </p></td>
<td valign="top" align="left"><p> Create
a pair of iterators returning the sequence of generated tokens </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit13"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit13"></a> </p></td>
<td valign="top" align="left"><p> Here we
simply iterate over all tokens, making sure to break the loop if an invalid
token gets returned from the lexer </p></td>
Modified: trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart3.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart3.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_quickstart3.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Quickstart
- 3 - Counting Words Using a Parser</title>
+<title>Quickstart 3 - Counting Words Using a Parser</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../tutorials.html" title=" Spirit.Lex
- Tutorials">
-<link rel="previous" href="lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">
-<link rel="next" href="../abstracts.html" title=" Abstracts">
+<link rel="up" href="../tutorials.html" title="Spirit.Lex Tutorials">
+<link rel="prev" href="lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">
+<link rel="next" href="../abstracts.html" title="Abstracts">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="lexer_quickstart2.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../abstracts.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.tutorials.lexer_quickstart3"></a><a href="lexer_quickstart3.html" title=" Quickstart
- 3 - Counting Words Using a Parser"> Quickstart
+<div class="section" title="Quickstart 3 - Counting Words Using a Parser">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.tutorials.lexer_quickstart3"></a><a class="link" href="lexer_quickstart3.html" title="Quickstart 3 - Counting Words Using a Parser"> Quickstart
3 - Counting Words Using a Parser</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The whole purpose of integrating <span class="emphasis"><em>Spirit.Lex</em></span> as part
of the Spirit library
@@ -46,8 +39,7 @@
usage of possibly different lexical analyzer libraries. The utilization
of iterators seemed to be the right choice from this standpoint as well,
mainly because these can be used as an abstraction layer hiding implementation
- specifics of the used lexer library. The <a href="lexer_quickstart3.html#spirit.lex.flowcontrol" title="Figure 7. The common flow control implemented while parsing
- combined with lexical analysis">picture</a>
+ specifics of the used lexer library. The <a class="link" href="lexer_quickstart3.html#spirit.lex.flowcontrol" title="Figure 7. The common flow control implemented while parsing combined with lexical analysis">picture</a>
below shows the common flow control implemented while parsing combined
with lexical analysis.
</p>
@@ -56,16 +48,15 @@
<div class="figure">
<a name="spirit.lex.flowcontrol"></a><p class="title"><b>Figure 7. The common flow control implemented while parsing
combined with lexical analysis</b></p>
-<span class="inlinemediaobject"><img src="./images/flowofcontrol.png" alt="The common flow
- control implemented while parsing combined with lexical analysis"></span>
+<div class="figure-contents"><span class="inlinemediaobject"><img src="../../.././images/flowofcontrol.png" alt="The common flow control implemented while parsing combined with lexical analysis"></span></div>
</div>
-<p>
+<p><br class="figure-break">
</p>
<p>
Another problem related to the integration of the lexical analyzer with
the parser was to find a way how the defined tokens syntactically could
be blended with the grammar definition syntax of Spirit.
- For tokens defined as instances of the <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt> class the most natural way of integration
+ For tokens defined as instances of the <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code> class the most natural way of integration
was to allow to directly use these as parser components. Semantically these
parser components succeed matching their input whenever the corresponding
token type has been matched by the lexer. This quick start example will
@@ -73,14 +64,14 @@
the numbers inside of semantic actions of a parser (for the full example
code see here: word_count.cpp).
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart3.prerequisites"></a><h5>
-<a name="id604001"></a>
- Prerequisites
- </h5>
+<a name="spirit.lex.tutorials.lexer_quickstart3.prerequisites"></a><h6>
+<a name="id1309668"></a>
+ <a class="link" href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.prerequisites">Prerequisites</a>
+ </h6>
<p>
This example uses two of the Spirit
library components: <span class="emphasis"><em>Spirit.Lex</em></span> and <span class="emphasis"><em>Spirit.Qi</em></span>,
- consequently we have to <tt class="computeroutput"><span class="preprocessor">#include</span></tt>
+ consequently we have to <code class="computeroutput"><span class="preprocessor">#include</span></code>
the corresponding header files. Again, we need to include a couple of header
files from the Boost.Phoenix
library. This example shows how to attach functors to parser components,
@@ -123,22 +114,20 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart3.defining_tokens"></a><h5>
-<a name="id604607"></a>
- <a href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.defining_tokens">Defining
+<a name="spirit.lex.tutorials.lexer_quickstart3.defining_tokens"></a><h6>
+<a name="id1310099"></a>
+ <a class="link" href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.defining_tokens">Defining
Tokens</a>
- </h5>
+ </h6>
<p>
- If compared to the two previous quick start examples (<a href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">Lex
+ If compared to the two previous quick start examples (<a class="link" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">Lex
Quickstart 1 - A word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
- and <a href="lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">Lex Quickstart
+ and <a class="link" href="lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">Lex Quickstart
2 - A better word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>)
the token definition class for this example does not reveal any surprises.
However, it uses lexer token definition macros to simplify the composition
of the regular expressions, which will be described in more detail in the
- section <span class="bold"><b>FIXME</b></span>. Generally, any token definition
+ section <span class="bold"><strong>FIXME</strong></span>. Generally, any token definition
is usable without modification either for a standalone lexical analyzer
or in conjunction with a parser.
</p>
@@ -178,29 +167,29 @@
</p>
<p>
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart3.using_token_definition_instances_as_parsers"></a><h5>
-<a name="id605082"></a>
- <a href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.using_token_definition_instances_as_parsers">Using
+<a name="spirit.lex.tutorials.lexer_quickstart3.using_token_definition_instances_as_parsers"></a><h6>
+<a name="id1310436"></a>
+ <a class="link" href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.using_token_definition_instances_as_parsers">Using
Token Definition Instances as Parsers</a>
- </h5>
+ </h6>
<p>
While the integration of lexer and parser in the control flow is achieved
by using special iterators wrapping the lexical analyzer, we still nead
a means of expressing in the grammar what tokens to match and where. The
token definition class above uses three different ways of defining a token:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- Using an instance of a <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt>, which is handy whenever you
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ Using an instance of a <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code>, which is handy whenever you
need to specify a token attribute (for more information about lexer related
- attributes please look here: <a href="../abstracts/lexer_attributes.html" title=" Lexer Attributes">Lexer
+ attributes please look here: <a class="link" href="../abstracts/lexer_attributes.html" title="Lexer Attributes">Lexer
Attributes</a>).
</li>
-<li>
+<li class="listitem">
Using a single character as the token, in this case the character represents
itself as a token, where the token id is the ASCII character value.
</li>
-<li>
+<li class="listitem">
Using a regular expression represented as a string, where the token id
needs to be specified explicitly to make the token accessible from the
grammar level.
@@ -218,47 +207,63 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Token definition
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Parser integration
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt>
- </p></td>
-<td><p>
- The <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code>
instance is directly usable as a parser component. Parsing of this
component will succeed if the regular expression used to define
this has been matched successfully.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
single character
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
The single character is directly usable in the grammar, under certain
- circumstances it needs to be wrapped by a <tt class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></tt> parser component, though. Parsing
+ circumstances it needs to be wrapped by a <code class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></code> parser component, though. Parsing
of this component will succeed if the single character has been
matched.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
explicit token id
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
To use an explicit token id in a <span class="emphasis"><em>Spirit.Qi</em></span>
- grammar you are required to wrap it with the special <tt class="computeroutput"><span class="identifier">token</span><span class="special">()</span></tt>
+ grammar you are required to wrap it with the special <code class="computeroutput"><span class="identifier">token</span><span class="special">()</span></code>
parser component. Parsing of this component will succeed if the
current token has the same token id as specified in the expression
- <tt class="computeroutput"><span class="identifier">token</span><span class="special">(<</span><span class="identifier">id</span><span class="special">>)</span></tt>.
- </p></td>
+ <code class="computeroutput"><span class="identifier">token</span><span class="special">(<</span><span class="identifier">id</span><span class="special">>)</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
@@ -298,37 +303,36 @@
<p>
</p>
<p>
- As already described (see: Attributes),
+ As already described (see: <a class="link" href="../../../">Attributes</a>),
the <span class="emphasis"><em>Spirit.Qi</em></span> parser library builds upon a set of
of fully attributed parser components. Consequently, all the token definitions
do support the this attribute model as well. The most natural way of implementing
this was to use the token values as the attributes exposed by the parser
component corresponding to the token definition (you can read more about
- this topic here: <a href="../abstracts/lexer_primitives/lexer_token_values.html" title="
- About Tokens and Token Values">About
+ this topic here: <a class="link" href="../abstracts/lexer_primitives/lexer_token_values.html" title="About Tokens and Token Values">About
Tokens and Token Values</a>). The example above takes advantage of the
- full integration of the token values as the <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></tt>'s parser attributes: the <tt class="computeroutput"><span class="identifier">word</span></tt> token definition is declared as
- a <tt class="computeroutput"><span class="identifier">token_def</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span></tt>,
- making every instance of a <tt class="computeroutput"><span class="identifier">word</span></tt>
+ full integration of the token values as the <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><></span></code>'s parser attributes: the <code class="computeroutput"><span class="identifier">word</span></code> token definition is declared as
+ a <code class="computeroutput"><span class="identifier">token_def</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span></code>,
+ making every instance of a <code class="computeroutput"><span class="identifier">word</span></code>
token carry the string representation of the matched input sequence as
- its value. The semantic action attached to <tt class="computeroutput"><span class="identifier">tok</span><span class="special">.</span><span class="identifier">word</span></tt>
- receives this string (represented by the <tt class="computeroutput"><span class="identifier">_1</span></tt>
+ its value. The semantic action attached to <code class="computeroutput"><span class="identifier">tok</span><span class="special">.</span><span class="identifier">word</span></code>
+ receives this string (represented by the <code class="computeroutput"><span class="identifier">_1</span></code>
placeholder) and uses it to calculate the number of matched characters:
- <tt class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span> <span class="special">+=</span>
- <span class="identifier">size</span><span class="special">(</span><span class="identifier">_1</span><span class="special">)</span></tt>.
+ <code class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span> <span class="special">+=</span>
+ <span class="identifier">size</span><span class="special">(</span><span class="identifier">_1</span><span class="special">)</span></code>.
</p>
-<a name="spirit.lex.tutorials.lexer_quickstart3.pulling_everything_together"></a><h5>
-<a name="id606291"></a>
- <a href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.pulling_everything_together">Pulling
+<a name="spirit.lex.tutorials.lexer_quickstart3.pulling_everything_together"></a><h6>
+<a name="id1311387"></a>
+ <a class="link" href="lexer_quickstart3.html#spirit.lex.tutorials.lexer_quickstart3.pulling_everything_together">Pulling
Everything Together</a>
- </h5>
+ </h6>
<p>
The main function needs to implement a bit more logic now as we have to
initialize and start not only the lexical analysis but the parsing process
- as well. The three type definitions (<tt class="computeroutput"><span class="keyword">typedef</span></tt>
+ as well. The three type definitions (<code class="computeroutput"><span class="keyword">typedef</span></code>
statements) simplify the creation of the lexical analyzer and the grammar.
After reading the contents of the given file into memory it calls the function
- tokenize_and_parse()
+ <a class="link" href="../../../"><code class="computeroutput"><span class="identifier">tokenize_and_parse</span><span class="special">()</span></code></a>
to initialize the lexical analysis and parsing processes.
</p>
<p>
@@ -338,13 +342,13 @@
</p>
<pre class="programlisting"><span class="keyword">int</span> <span class="identifier">main</span><span class="special">(</span><span class="keyword">int</span> <span class="identifier">argc</span><span class="special">,</span> <span class="keyword">char</span><span class="special">*</span> <span class="identifier">argv</span><span class="special">[])</span>
<span class="special">{</span>
-<span class="callout_bug"><a name="spirit14co" href="lexer_quickstart3.html#spirit14"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span><span class="special"><</span>
+<span class="callout_bug"><a class="co" name="spirit14co" href="lexer_quickstart3.html#spirit14"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span><span class="special"><</span>
<span class="keyword">char</span> <span class="keyword">const</span><span class="special">*,</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span>
<span class="special">></span> <span class="identifier">token_type</span><span class="special">;</span>
-<span class="callout_bug"><a name="spirit15co" href="lexer_quickstart3.html#spirit15"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">lexer</span><span class="special"><</span><span class="identifier">token_type</span><span class="special">></span> <span class="identifier">lexer_type</span><span class="special">;</span>
+<span class="callout_bug"><a class="co" name="spirit15co" href="lexer_quickstart3.html#spirit15"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">lexer</span><span class="special"><</span><span class="identifier">token_type</span><span class="special">></span> <span class="identifier">lexer_type</span><span class="special">;</span>
-<span class="callout_bug"><a name="spirit16co" href="lexer_quickstart3.html#spirit16"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">word_count_tokens</span><span class="special"><</span><span class="identifier">lexer_type</span><span class="special">>::</span><span class="identifier">iterator_type</span> <span class="identifier">iterator_type</span><span class="special">;</span>
+<span class="callout_bug"><a class="co" name="spirit16co" href="lexer_quickstart3.html#spirit16"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span> <span class="keyword">typedef</span> <span class="identifier">word_count_tokens</span><span class="special"><</span><span class="identifier">lexer_type</span><span class="special">>::</span><span class="identifier">iterator_type</span> <span class="identifier">iterator_type</span><span class="special">;</span>
<span class="comment">// now we use the types defined above to create the lexer and grammar
</span> <span class="comment">// object instances needed to invoke the parsing process
@@ -356,7 +360,7 @@
<span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">first</span> <span class="special">=</span> <span class="identifier">str</span><span class="special">.</span><span class="identifier">c_str</span><span class="special">();</span>
<span class="keyword">char</span> <span class="keyword">const</span><span class="special">*</span> <span class="identifier">last</span> <span class="special">=</span> <span class="special">&</span><span class="identifier">first</span><span class="special">[</span><span class="identifier">str</span><span class="special">.</span><span class="identifier">size</span><span class="special">()];</span>
-<span class="callout_bug"><a name="spirit17co" href="lexer_quickstart3.html#spirit17"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span> <span class="keyword">bool</span> <span class="identifier">r</span> <span class="special">=</span> <span class="identifier">tokenize_and_parse</span><span class="special">(</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">,</span> <span class="identifier">word_count</span><span class="special">,</span> <span class="identifier">g</span><span class="special">);</span>
+<span class="callout_bug"><a class="co" name="spirit17co" href="lexer_quickstart3.html#spirit17"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span> <span class="keyword">bool</span> <span class="identifier">r</span> <span class="special">=</span> <span class="identifier">tokenize_and_parse</span><span class="special">(</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">,</span> <span class="identifier">word_count</span><span class="special">,</span> <span class="identifier">g</span><span class="special">);</span>
<span class="keyword">if</span> <span class="special">(</span><span class="identifier">r</span><span class="special">)</span> <span class="special">{</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special"><<</span> <span class="string">"lines: "</span> <span class="special"><<</span> <span class="identifier">g</span><span class="special">.</span><span class="identifier">l</span> <span class="special"><<</span> <span class="string">", words: "</span> <span class="special"><<</span> <span class="identifier">g</span><span class="special">.</span><span class="identifier">w</span>
@@ -378,29 +382,25 @@
</p>
<div class="calloutlist"><table border="0" summary="Callout list">
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit14"></a> </td>
-<td valign="top" align="left"><p> Define the token type to be used: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>
+<td width="5%" valign="top" align="left"><p><a name="spirit14"></a> </p></td>
+<td valign="top" align="left"><p> Define the token type to be used: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>
is available as the type of the token attribute </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit15"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit15"></a> </p></td>
<td valign="top" align="left"><p> Define the lexer type
to use implementing the state machine </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit16"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit16"></a> </p></td>
<td valign="top" align="left"><p> Define the iterator type exposed
by the lexer type </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit17"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit17"></a> </p></td>
<td valign="top" align="left"><p> Parsing is done based on the the token stream, not
- the character stream read from the input. The function <tt class="computeroutput"><span class="identifier">tokenize_and_parse</span><span class="special">()</span></tt>
- wraps the passed iterator range <tt class="computeroutput"><span class="special">[</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">)</span></tt>
+ the character stream read from the input. The function <code class="computeroutput"><span class="identifier">tokenize_and_parse</span><span class="special">()</span></code>
+ wraps the passed iterator range <code class="computeroutput"><span class="special">[</span><span class="identifier">first</span><span class="special">,</span> <span class="identifier">last</span><span class="special">)</span></code>
by the lexical analyzer and uses its exposed iterators to parse the toke
stream. </p></td>
</tr>
Modified: trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_tutorials.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_tutorials.html (original)
+++ trunk/libs/spirit/doc/html/spirit/lex/tutorials/lexer_tutorials.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,17 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Spirit.Lex
- Tutorials Overview</title>
+<title>Spirit.Lex Tutorials Overview</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../tutorials.html" title=" Spirit.Lex
- Tutorials">
-<link rel="previous" href="../tutorials.html" title=" Spirit.Lex
- Tutorials">
-<link rel="next" href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">
+<link rel="up" href="../tutorials.html" title="Spirit.Lex Tutorials">
+<link rel="prev" href="../tutorials.html" title="Spirit.Lex Tutorials">
+<link rel="next" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -26,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="../tutorials.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="lexer_quickstart1.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.lex.tutorials.lexer_tutorials"></a><a href="lexer_tutorials.html" title=" Spirit.Lex
- Tutorials Overview"> <span class="emphasis"><em>Spirit.Lex</em></span>
+<div class="section" title="Spirit.Lex Tutorials Overview">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.lex.tutorials.lexer_tutorials"></a><a class="link" href="lexer_tutorials.html" title="Spirit.Lex Tutorials Overview"> <span class="emphasis"><em>Spirit.Lex</em></span>
Tutorials Overview</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The <span class="emphasis"><em>Spirit.Lex</em></span> library implements several components
on top of possibly different lexer generator libraries. It exposes a pair
@@ -53,12 +45,12 @@
generator library, all what needs to be implemented is a set of wrapper
objects exposing a well defined interface as described in this documentation.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
For the sake of clarity all examples in this documentation assume <span class="emphasis"><em>Spirit.Lex</em></span>
to be used on top of Lexertl.
</p></td></tr>
@@ -71,23 +63,23 @@
Here is a (non-complete) list of features you can tweak to adjust the generated
lexer instance to the actual needs:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Select and customize the token type to be generated by the lexer instance.
</li>
-<li>
+<li class="listitem">
Select and customize the token value types the generated token instances
will be able to hold.
</li>
-<li>
+<li class="listitem">
Select the iterator type of the underlying input stream, which will be
used as the source for the character stream to tokenize.
</li>
-<li>
+<li class="listitem">
Customize the iterator type returned by the lexer to enable debug support,
special handling of certain input sequences, etc.
</li>
-<li>
+<li class="listitem">
Select the <span class="emphasis"><em>dynamic</em></span> or the <span class="emphasis"><em>static</em></span>
runtime model for the lexical analyzer.
</li>
@@ -100,17 +92,14 @@
<p>
The series of tutorial examples of this section will guide you through
some common use cases helping to understand the big picture. The first
- two quick start examples (<a href="lexer_quickstart1.html" title=" Quickstart
- 1 - A word counter using Spirit.Lex">Lex
+ two quick start examples (<a class="link" href="lexer_quickstart1.html" title="Quickstart 1 - A word counter using Spirit.Lex">Lex
Quickstart 1 - A word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>
- and <a href="lexer_quickstart2.html" title=" Quickstart
- 2 - A better word counter using Spirit.Lex">Lex Quickstart
+ and <a class="link" href="lexer_quickstart2.html" title="Quickstart 2 - A better word counter using Spirit.Lex">Lex Quickstart
2 - A better word counter using <span class="emphasis"><em>Spirit.Lex</em></span></a>)
introduce the <span class="emphasis"><em>Spirit.Lex</em></span> library while building two
standalone applications, not being connected to or depending on any other
part of Spirit. The
- section <a href="lexer_quickstart3.html" title=" Quickstart
- 3 - Counting Words Using a Parser">Lex Quickstart
+ section <a class="link" href="lexer_quickstart3.html" title="Quickstart 3 - Counting Words Using a Parser">Lex Quickstart
3 - Counting Words Using a Parser</a> demonstrates how to use a lexer
in conjunction with a parser (where obviously the parser is built using
<span class="emphasis"><em>Spirit.Qi</em></span>).
Modified: trunk/libs/spirit/doc/html/spirit/notes.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/notes.html (original)
+++ trunk/libs/spirit/doc/html/spirit/notes.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Notes</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="faq.html" title=" Spirit FAQ">
-<link rel="next" href="notes/porting_from_spirit_1_8_x.html" title="Porting from
- Spirit 1.8.x">
+<link rel="prev" href="faq.html" title="Spirit FAQ">
+<link rel="next" href="notes/porting_from_spirit_1_8_x.html" title="Porting from Spirit 1.8.x">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="faq.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="notes/porting_from_spirit_1_8_x.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.notes"></a>Notes
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Notes">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.notes"></a><a class="link" href="notes.html" title="Notes">Notes</a>
+</h2></div></div></div>
<div class="toc"><dl>
<dt><span class="section"><a href="notes/porting_from_spirit_1_8_x.html">Porting from
Spirit 1.8.x</a></span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/notes/porting_from_spirit_1_8_x.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/notes/porting_from_spirit_1_8_x.html (original)
+++ trunk/libs/spirit/doc/html/spirit/notes/porting_from_spirit_1_8_x.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Porting from
- Spirit 1.8.x</title>
+<title>Porting from Spirit 1.8.x</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
<link rel="up" href="../notes.html" title="Notes">
-<link rel="previous" href="../notes.html" title="Notes">
+<link rel="prev" href="../notes.html" title="Notes">
<link rel="next" href="style_guide.html" title="Style Guide">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="../notes.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../notes.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="style_guide.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.notes.porting_from_spirit_1_8_x"></a><a href="porting_from_spirit_1_8_x.html" title="Porting from
- Spirit 1.8.x">Porting from
+<div class="section" title="Porting from Spirit 1.8.x">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.notes.porting_from_spirit_1_8_x"></a><a class="link" href="porting_from_spirit_1_8_x.html" title="Porting from Spirit 1.8.x">Porting from
Spirit 1.8.x</a>
-</h3></div></div>
-<div></div>
-</div>
+</h3></div></div></div>
<p>
The current version of Spirit
is a complete rewrite of earlier versions (we refer to earlier versions as
@@ -44,17 +39,17 @@
on how to approach porting your older parsers to the current version of
<a href="http://spirit.sourceforge.net" target="_top">Spirit</a>.
</p>
-<a name="spirit.notes.porting_from_spirit_1_8_x.include_files"></a><h4>
-<a name="id632382"></a>
- <a href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.include_files">Include
+<a name="spirit.notes.porting_from_spirit_1_8_x.include_files"></a><h5>
+<a name="id1338964"></a>
+ <a class="link" href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.include_files">Include
Files</a>
- </h4>
+ </h5>
<p>
The overall directory structure of the Spirit
- directories is described in the section <a href="../structure/include.html" title="Include">Include
- Structure</a> and the FAQ entry <a href="../faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">Header
+ directories is described in the section <a class="link" href="../structure/include.html" title="Include">Include
+ Structure</a> and the FAQ entry <a class="link" href="../faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">Header
Hell</a>. This should give you a good overview on how to find the needed
- header files for your new parsers. Moreover, each section in the <a href="../qi/reference.html" title="Reference">Qi
+ header files for your new parsers. Moreover, each section in the <a class="link" href="../qi/reference.html" title="Reference">Qi
Reference</a> lists the required include files needed for any particular
component.
</p>
@@ -86,120 +81,164 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Include file in <span class="emphasis"><em>Spirit.Classic</em></span>
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Include file in <span class="emphasis"><em>Spirit.Qi</em></span>
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">qi</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_actor</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qi</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_actor</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
none, use Boost.Phoenix
for writing semantic actions
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_attribute</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_attribute</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
none, use local variables for rules instead of closures, the primitives
parsers now directly support lazy parametrization
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_core</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_debug</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">qi_debug</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_dynamic</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_core</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_debug</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qi_debug</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_dynamic</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
none, use <span class="emphasis"><em>Spirit.Qi</em></span> predicates instead of if_p,
- while_p, for_p (included by <tt class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></tt>),
- the equivalent for lazy_p is now included by <tt class="computeroutput"><span class="identifier">qi_auxiliary</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_error_handling</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
- none, included in <tt class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_meta</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
+ while_p, for_p (included by <code class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></code>),
+ the equivalent for lazy_p is now included by <code class="computeroutput"><span class="identifier">qi_auxiliary</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_error_handling</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ none, included in <code class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_meta</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
none
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_symbols</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
- none, included in <tt class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">classic_utility</span><span class="special">.</span><span class="identifier">hpp</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_symbols</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ none, included in <code class="computeroutput"><span class="identifier">qi_core</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">classic_utility</span><span class="special">.</span><span class="identifier">hpp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
none, not part of <span class="emphasis"><em>Spirit.Qi</em></span> anymore, these components
will be added over time to the Repository
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<a name="spirit.notes.porting_from_spirit_1_8_x.the_free_parse_functions"></a><h4>
-<a name="id633243"></a>
- <a href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.the_free_parse_functions">The
+<a name="spirit.notes.porting_from_spirit_1_8_x.the_free_parse_functions"></a><h5>
+<a name="id1339598"></a>
+ <a class="link" href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.the_free_parse_functions">The
Free Parse Functions</a>
- </h4>
+ </h5>
<p>
The free parse functions (i.e. the main parser API) has been changed. This
includes the names of the free functions as well as their interface. In
- <span class="emphasis"><em>Spirit.Classic</em></span> all free functions were named <tt class="computeroutput"><span class="identifier">parse</span></tt>. In <span class="emphasis"><em>Spirit.Qi</em></span>
- they are are named either <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></tt>
- or <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></tt> depending on whether the parsing
- should be done using a skipper (<tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></tt>)
- or not (<tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></tt>). All free functions now return a
- simple <tt class="computeroutput"><span class="keyword">bool</span></tt>. A returned <tt class="computeroutput"><span class="keyword">true</span></tt> means success (i.e. the parser has matched)
- or <tt class="computeroutput"><span class="keyword">false</span></tt> (i.e. the parser either
- didn't match). This is equivalent to the former old <tt class="computeroutput"><span class="identifier">parse_info</span></tt>
- member <tt class="computeroutput"><span class="identifier">hit</span></tt>. <span class="emphasis"><em>Spirit.Qi</em></span>
- doesn't support tracking of the matched input length anymore. The old <tt class="computeroutput"><span class="identifier">parse_info</span></tt> member <tt class="computeroutput"><span class="identifier">full</span></tt>
- can be emulated by comparing the iterators after <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></tt>
+ <span class="emphasis"><em>Spirit.Classic</em></span> all free functions were named <code class="computeroutput"><span class="identifier">parse</span></code>. In <span class="emphasis"><em>Spirit.Qi</em></span>
+ they are are named either <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></code>
+ or <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></code> depending on whether the parsing
+ should be done using a skipper (<code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></code>)
+ or not (<code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></code>). All free functions now return a
+ simple <code class="computeroutput"><span class="keyword">bool</span></code>. A returned <code class="computeroutput"><span class="keyword">true</span></code> means success (i.e. the parser has matched)
+ or <code class="computeroutput"><span class="keyword">false</span></code> (i.e. the parser either
+ didn't match). This is equivalent to the former old <code class="computeroutput"><span class="identifier">parse_info</span></code>
+ member <code class="computeroutput"><span class="identifier">hit</span></code>. <span class="emphasis"><em>Spirit.Qi</em></span>
+ doesn't support tracking of the matched input length anymore. The old <code class="computeroutput"><span class="identifier">parse_info</span></code> member <code class="computeroutput"><span class="identifier">full</span></code>
+ can be emulated by comparing the iterators after <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span></code>
returned.
</p>
<p>
@@ -362,55 +401,55 @@
<p>
</p>
<p>
- Note, how character parsers are in a separate namespace (here <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">ascii</span><span class="special">::</span><span class="identifier">space</span></tt>) as <span class="emphasis"><em>Spirit.Qi</em></span>
- now supports working with different character sets. See the section <a href="../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Note, how character parsers are in a separate namespace (here <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">ascii</span><span class="special">::</span><span class="identifier">space</span></code>) as <span class="emphasis"><em>Spirit.Qi</em></span>
+ now supports working with different character sets. See the section <a class="link" href="../qi/reference/basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a> for more information.
</p>
-<a name="spirit.notes.porting_from_spirit_1_8_x.naming_conventions"></a><h4>
-<a name="id636148"></a>
- <a href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.naming_conventions">Naming
+<a name="spirit.notes.porting_from_spirit_1_8_x.naming_conventions"></a><h5>
+<a name="id1342331"></a>
+ <a class="link" href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.naming_conventions">Naming
Conventions</a>
- </h4>
+ </h5>
<p>
In <span class="emphasis"><em>Spirit.Classic</em></span> all parser primitives have suffixes
- appended to their names, encoding their type: <tt class="computeroutput"><span class="string">"_p"</span></tt>
- for parsers, <tt class="computeroutput"><span class="string">"_a"</span></tt> for
- lazy actions, <tt class="computeroutput"><span class="string">"_d"</span></tt>
+ appended to their names, encoding their type: <code class="computeroutput"><span class="string">"_p"</span></code>
+ for parsers, <code class="computeroutput"><span class="string">"_a"</span></code> for
+ lazy actions, <code class="computeroutput"><span class="string">"_d"</span></code>
for directives, etc. In <span class="emphasis"><em>Spirit.Qi</em></span> we don't have anything
- similar. The only suffixes are single underscore letters <tt class="computeroutput"><span class="string">"_"</span></tt>
+ similar. The only suffixes are single underscore letters <code class="computeroutput"><span class="string">"_"</span></code>
applied where the name would otherwise conflict with a keyword or predefined
- name (such as <tt class="computeroutput"><span class="identifier">int_</span></tt> for the
+ name (such as <code class="computeroutput"><span class="identifier">int_</span></code> for the
integer parser). Overall, most, if not all primitive parsers and directives
- have been renamed. Please see the <a href="../qi/quick_reference.html" title="Quick Reference">Qi
+ have been renamed. Please see the <a class="link" href="../qi/quick_reference.html" title="Quick Reference">Qi
Quick Reference</a> for an overview on the names for the different available
parser primitives, directives and operators.
</p>
-<a name="spirit.notes.porting_from_spirit_1_8_x.parser_attributes"></a><h4>
-<a name="id636261"></a>
- <a href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.parser_attributes">Parser
+<a name="spirit.notes.porting_from_spirit_1_8_x.parser_attributes"></a><h5>
+<a name="id1342401"></a>
+ <a class="link" href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.parser_attributes">Parser
Attributes</a>
- </h4>
+ </h5>
<p>
In <span class="emphasis"><em>Spirit.Classic</em></span> most of the parser primitives don't
expose a specific attribute type. Most parsers expose the pair of iterators
pointing to the matched input sequence. As in <span class="emphasis"><em>Spirit.Qi</em></span>
all parsers expose a parser specific attribute type it introduces a special
- directive <tt class="computeroutput"><span class="identifier">raw</span><span class="special">[]</span></tt>
+ directive <code class="computeroutput"><span class="identifier">raw</span><span class="special">[]</span></code>
allowing to achieve a similar effect as in <span class="emphasis"><em>Spirit.Classic</em></span>.
- The <tt class="computeroutput"><span class="identifier">raw</span><span class="special">[]</span></tt>
+ The <code class="computeroutput"><span class="identifier">raw</span><span class="special">[]</span></code>
directive exposes the pair of iterators pointing to the matching sequence
of its embedded parser. Even if we very much encourage you to rewrite your
parsers to take advantage of the generates parser specific attributes, sometimes
it is helpful to get access to the underlying matched input sequence.
</p>
-<a name="spirit.notes.porting_from_spirit_1_8_x.grammars_and_rules"></a><h4>
-<a name="id636344"></a>
- <a href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.grammars_and_rules">Grammars
+<a name="spirit.notes.porting_from_spirit_1_8_x.grammars_and_rules"></a><h5>
+<a name="id1342455"></a>
+ <a class="link" href="porting_from_spirit_1_8_x.html#spirit.notes.porting_from_spirit_1_8_x.grammars_and_rules">Grammars
and Rules</a>
- </h4>
+ </h5>
<p>
- The <tt class="computeroutput"><span class="identifier">grammar</span><span class="special"><></span></tt>
- and <tt class="computeroutput"><span class="identifier">rule</span><span class="special"><></span></tt>
+ The <code class="computeroutput"><span class="identifier">grammar</span><span class="special"><></span></code>
+ and <code class="computeroutput"><span class="identifier">rule</span><span class="special"><></span></code>
types are of equal importance to <span class="emphasis"><em>Spirit.Qi</em></span> as they are
for <span class="emphasis"><em>Spirit.Classic</em></span>. Their main purpose is still the
same: they allow to define non-terminals and they are the main building blocks
@@ -543,21 +582,21 @@
Both versions look similarily enough, but we see several differences (we
will cover each of those differences in more detail below):
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Neither the grammars nor the rules depend on a scanner type anymore, both
depend only on the underlying iterator type. That means the dreaded scanner
business is no issue anymore!
</li>
-<li>
- Grammars have no embedded class <tt class="computeroutput"><span class="identifier">definition</span></tt>
+<li class="listitem">
+ Grammars have no embedded class <code class="computeroutput"><span class="identifier">definition</span></code>
anymore
</li>
-<li>
+<li class="listitem">
Grammars and rules may have an explicit attribute type specified in their
definition
</li>
-<li>
+<li class="listitem">
Grammars do not have any explicit start rules anymore. Instead one of the
contained rules is used as a start rule by default.
</li>
@@ -576,9 +615,9 @@
All <span class="emphasis"><em>Spirit.Qi</em></span> parser components have well defined attribute
types. Grammars and rules are no exception. But since both need to be generic
enough to be usable for any parser their attribute type has to be explicitely
- specified. In the example above the <tt class="computeroutput"><span class="identifier">roman</span></tt>
- grammar and the rule <tt class="computeroutput"><span class="identifier">first</span></tt>
- both have an <tt class="computeroutput"><span class="keyword">unsigned</span></tt> attribute:
+ specified. In the example above the <code class="computeroutput"><span class="identifier">roman</span></code>
+ grammar and the rule <code class="computeroutput"><span class="identifier">first</span></code>
+ both have an <code class="computeroutput"><span class="keyword">unsigned</span></code> attribute:
</p>
<pre class="programlisting"><span class="comment">// grammar definition
</span><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Iterator</span><span class="special">></span>
@@ -593,12 +632,12 @@
the rule as of its 'return value'. In fact the rule and the grammar both
'return' an unsigned value - the value they matched.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
The function type notation allows to specify parameters as well. These
are interpreted as the types of inherited attributes the rule or grammar
expect to be passed during parsing. For more information please see the
@@ -607,13 +646,13 @@
</table></div>
<p>
If no attribute is desired none needs to be specified. The default attrribute
- type for both, grammars and rules, is <tt class="computeroutput"><span class="identifier">unused_type</span></tt>,
+ type for both, grammars and rules, is <code class="computeroutput"><span class="identifier">unused_type</span></code>,
which is a special placeholder type.
</p>
<p>
The last difference might seem to be rather cosmetic and insignificant. But
it turns out that not having to specify which rule in a grammar is the start
- rule (by returning it from the function <tt class="computeroutput"><span class="identifier">start</span><span class="special">()</span></tt>) also means that any rule in a grammar
+ rule (by returning it from the function <code class="computeroutput"><span class="identifier">start</span><span class="special">()</span></code>) also means that any rule in a grammar
can be directly used as the start rule. Nevertheless, the grammar base class
gets initialized with the rule it has to use as the start rule in case the
grammar instance is directly used as a parser.
Modified: trunk/libs/spirit/doc/html/spirit/notes/style_guide.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/notes/style_guide.html (original)
+++ trunk/libs/spirit/doc/html/spirit/notes/style_guide.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Style Guide</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
<link rel="up" href="../notes.html" title="Notes">
-<link rel="previous" href="porting_from_spirit_1_8_x.html" title="Porting from
- Spirit 1.8.x">
-<link rel="next" href="../repository.html" title=" Spirit Repository">
+<link rel="prev" href="porting_from_spirit_1_8_x.html" title="Porting from Spirit 1.8.x">
+<link rel="next" href="../repository.html" title="Spirit Repository">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="porting_from_spirit_1_8_x.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../notes.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../repository.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.notes.style_guide"></a>Style Guide
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Style Guide">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.notes.style_guide"></a><a class="link" href="style_guide.html" title="Style Guide">Style Guide</a>
+</h3></div></div></div>
<p>
At some point, especially when there are lots of semantic actions attached
to various points, the grammar tends to be quite difficult to follow. In
@@ -42,22 +38,22 @@
Requirements and Guidelines</a> and is the combined work of Joel de Guzman,
Chris Uzdavinis, and Hartmut Kaiser.
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Rule names use std C++ (Boost) convention. The rule name may be very long.
</li>
-<li>
+<li class="listitem">
The '=' is neatly indented 4 spaces below. Like in Boost, use spaces instead
of tabs.
</li>
-<li>
+<li class="listitem">
Breaking the operands into separate lines puts the semantic actions neatly
to the right.
</li>
-<li>
+<li class="listitem">
Semicolon at the last line terminates the rule.
</li>
-<li>
+<li class="listitem">
The adjacent parts of a sequence should be indented accordingly to have
all, what belongs to one level, at one indentation level.
</li>
@@ -70,20 +66,20 @@
<span class="special">>></span> <span class="identifier">etc</span>
<span class="special">;</span>
</pre>
-<div class="itemizedlist"><ul type="disc">
-<li>
- Prefer literals in the grammar instead of identifiers. e.g. <tt class="computeroutput"><span class="string">"program"</span></tt> instead of <tt class="computeroutput"><span class="identifier">PROGRAM</span></tt>, <tt class="computeroutput"><span class="char">'>='</span></tt>
- instead of <tt class="computeroutput"><span class="identifier">GTE</span></tt> and <tt class="computeroutput"><span class="char">'.'</span></tt> instead of <tt class="computeroutput"><span class="identifier">DOT</span></tt>.
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ Prefer literals in the grammar instead of identifiers. e.g. <code class="computeroutput"><span class="string">"program"</span></code> instead of <code class="computeroutput"><span class="identifier">PROGRAM</span></code>, <code class="computeroutput"><span class="char">'>='</span></code>
+ instead of <code class="computeroutput"><span class="identifier">GTE</span></code> and <code class="computeroutput"><span class="char">'.'</span></code> instead of <code class="computeroutput"><span class="identifier">DOT</span></code>.
This makes it much easier to read. If this isn't possible (for instance
where the used tokens must be identified through integers) capitalized
identifiers should be used instead.
</li>
-<li>
- Breaking the operands may not be needed for short expressions. e.g. <tt class="computeroutput"><span class="special">*(</span><span class="char">','</span> <span class="special">>></span>
- <span class="identifier">file_identifier</span><span class="special">)</span></tt>
+<li class="listitem">
+ Breaking the operands may not be needed for short expressions. e.g. <code class="computeroutput"><span class="special">*(</span><span class="char">','</span> <span class="special">>></span>
+ <span class="identifier">file_identifier</span><span class="special">)</span></code>
as long as the line does not exceed 80 characters.
</li>
-<li>
+<li class="listitem">
If a sequence fits on one line, put spaces inside the parentheses to clearly
separate them from the rules.
</li>
@@ -98,7 +94,7 @@
<span class="special">>></span> <span class="char">';'</span>
<span class="special">;</span>
</pre>
-<div class="itemizedlist"><ul type="disc"><li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
Nesting directives: If a rule does not fit on one line (80 characters)
it should be continued on the next line intended by one level. The brackets
of directives, semantic expressions (using Phoenix or LL lambda expressions)
@@ -114,9 +110,9 @@
<span class="special">]</span>
<span class="special">;</span>
</pre>
-<div class="itemizedlist"><ul type="disc"><li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
Nesting unary operators (e.g.Kleene star): Unary rule operators (Kleene
- star, <tt class="computeroutput"><span class="char">'!'</span></tt>, <tt class="computeroutput"><span class="char">'+'</span></tt>
+ star, <code class="computeroutput"><span class="char">'!'</span></code>, <code class="computeroutput"><span class="char">'+'</span></code>
etc.) should be moved out one space before the corresponding indentation
level, if this rule has a body or a sequence after it, which does not fit
on on line. This makes the formatting more consistent and moves the rule
Modified: trunk/libs/spirit/doc/html/spirit/preface.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/preface.html (original)
+++ trunk/libs/spirit/doc/html/spirit/preface.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Preface</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="../index.html" title="Spirit 2.1">
+<link rel="prev" href="../index.html" title="Spirit 2.1">
<link rel="next" href="what_s_new.html" title="What's New">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,35 +22,32 @@
<div class="spirit-nav">
<a accesskey="p" href="../index.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="what_s_new.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.preface"></a>Preface
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Preface">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.preface"></a><a class="link" href="preface.html" title="Preface">Preface</a>
+</h2></div></div></div>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- <span class="emphasis"><em>“<span class="quote">Examples of designs that meet most of the criteria for
+ <span class="emphasis"><em><span class="quote">“<span class="quote">Examples of designs that meet most of the criteria for
"goodness" (easy to understand, flexible, efficient) are a recursive-descent
parser, which is traditional procedural code. Another example is the STL,
which is a generic library of containers and algorithms depending crucially
- on both traditional procedural code and on parametric polymorphism.</span>”</em></span>
- <span class="bold"><b>--Bjarne Stroustrup</b></span>
+ on both traditional procedural code and on parametric polymorphism.</span>”</span></em></span>
+ <span class="bold"><strong>--Bjarne Stroustrup</strong></span>
</p>
<p>
</p>
</blockquote></div>
-<a name="spirit.preface.history"></a><h3>
-<a name="id355261"></a>
- History
- </h3>
-<a name="spirit.preface._emphasis_80s__emphasis_"></a><h3>
-<a name="id355274"></a>
- 80s
- </h3>
+<a name="spirit.preface.history"></a><h4>
+<a name="id1096676"></a>
+ <a class="link" href="preface.html#spirit.preface.history">History</a>
+ </h4>
+<a name="spirit.preface._emphasis_80s__emphasis_"></a><h4>
+<a name="id1096689"></a>
+ <a class="link" href="preface.html#spirit.preface._emphasis_80s__emphasis_"><span class="emphasis"><em>80s</em></span></a>
+ </h4>
<p>
In the mid-80s, Joel wrote his first calculator in Pascal. It was an unforgettable
coding experience. He was amazed at how a mutually recursive set of functions
@@ -61,10 +58,10 @@
a grammar using Pascal-like syntax diagrams and then a corresponding recursive-descent
parser. This worked very well.
</p>
-<a name="spirit.preface._emphasis_90s__emphasis_"></a><h3>
-<a name="id353693"></a>
- 90s
- </h3>
+<a name="spirit.preface._emphasis_90s__emphasis_"></a><h4>
+<a name="id1096707"></a>
+ <a class="link" href="preface.html#spirit.preface._emphasis_90s__emphasis_"><span class="emphasis"><em>90s</em></span></a>
+ </h4>
<p>
The arrival of the Internet and the World Wide Web magnified this thousand-fold.
At one point Joel had to write an HTML parser for a Web browser project. He
@@ -99,11 +96,11 @@
objects and linking semantic actions on the fly. A very early text can be found
here: pre-Spirit.
</p>
-<a name="spirit.preface._emphasis_2001_to_2006__emphasis_"></a><h3>
-<a name="id353766"></a>
- <a href="preface.html#spirit.preface._emphasis_2001_to_2006__emphasis_"><span class="emphasis"><em>2001
+<a name="spirit.preface._emphasis_2001_to_2006__emphasis_"></a><h4>
+<a name="id1096749"></a>
+ <a class="link" href="preface.html#spirit.preface._emphasis_2001_to_2006__emphasis_"><span class="emphasis"><em>2001
to 2006</em></span></a>
- </h3>
+ </h4>
<p>
Version 1.0 to 1.8 was a complete rewrite of the original Spirit parser using
expression templates and static polymorphism, inspired by the works of Todd
@@ -129,13 +126,13 @@
of domains. The Boost Libraries have become widely known as an industry standard
for design and implementation quality, robustness, and reusability.
</p>
-<a name="spirit.preface._emphasis_2007__emphasis_"></a><h3>
-<a name="id353815"></a>
- 2007
- </h3>
+<a name="spirit.preface._emphasis_2007__emphasis_"></a><h4>
+<a name="id1096784"></a>
+ <a class="link" href="preface.html#spirit.preface._emphasis_2007__emphasis_"><span class="emphasis"><em>2007</em></span></a>
+ </h4>
<p>
Over the years, especially after Spirit was accepted into Boost, Spirit has
- served its purpose quite admirably. The focus of what we'll now call <span class="bold"><b><span class="emphasis"><em>Classic-Spirit</em></span></b></span> (versions prior
+ served its purpose quite admirably. The focus of what we'll now call <span class="bold"><strong><span class="emphasis"><em>Classic-Spirit</em></span></strong></span> (versions prior
to 2.0) was on transduction parsing where the input string is merely translated
to an output string. A lot of parsers are of the transduction type. When the
time came to add attributes to the parser library, it was done in a rather
@@ -166,10 +163,10 @@
its modularity and extensibility. Instead of giving you a sledgehammer, it
gives you the right ingredients to create a sledgehammer easily.
</p>
-<a name="spirit.preface.new_ideas__spirit_v2"></a><h3>
-<a name="id355437"></a>
- New Ideas: Spirit V2
- </h3>
+<a name="spirit.preface.new_ideas__spirit_v2"></a><h4>
+<a name="id1096860"></a>
+ <a class="link" href="preface.html#spirit.preface.new_ideas__spirit_v2">New Ideas: Spirit V2</a>
+ </h4>
<p>
Just before the development of Spirit V2 began, Hartmut came across the StringTemplate library which is
a part of the ANTLR parser framework. It is a Java template engine (with ports
@@ -204,27 +201,27 @@
parser grammars. Again, Spirit's modular structure allowed us to reuse the
same underlying component library as for the parser and generator libraries.
</p>
-<a name="spirit.preface.how_to_use_this_manual"></a><h3>
-<a name="id355514"></a>
- How to use this manual
- </h3>
+<a name="spirit.preface.how_to_use_this_manual"></a><h4>
+<a name="id1096910"></a>
+ <a class="link" href="preface.html#spirit.preface.how_to_use_this_manual">How to use this manual</a>
+ </h4>
<p>
- Each major section (there are 3: Qi, Karma, and Lex)
+ Each major section (there are 3: <a class="link" href="qi.html" title="Qi - Writing Parsers">Qi</a>, <a class="link" href="karma.html" title="Karma - Writing Generators">Karma</a>, and <a class="link" href="lex.html" title="Lex - Writing Lexical Analyzers">Lex</a>)
is roughly divided into 3 parts:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
Tutorials: A step by step guide with heavily annotated code. These are meant
to get the user acquainted with the library as quickly as possible. The objective
is to build the confidence of the user in using the library through abundant
examples and detailed instructions. Examples speak volumes and we have volumes
of examples!
</li>
-<li>
+<li class="listitem">
Abstracts: A high level summary of key topics. The objective is to give the
user a high level view of the library, the key concepts, background and theories.
</li>
-<li>
+<li class="listitem">
Reference: Detailed formal technical reference. We start with a quick reference
-- an easy to use table that maps into the reference proper. The reference
proper starts with C++ Concepts
@@ -236,94 +233,130 @@
icons precede some text to indicate:
</p>
<div class="table">
-<a name="id355586"></a><p class="title"><b>Table 1. Icons</b></p>
-<table class="table" summary="Icons">
+<a name="id1096963"></a><p class="title"><b>Table 1. Icons</b></p>
+<div class="table-contents"><table class="table" summary="Icons">
<colgroup>
<col>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Icon
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Meaning
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <span class="inlinemediaobject"><img src="../images/note.png" alt="note"></span>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <span class="inlinemediaobject"><img src="../../images/note.png" alt="note"></span>
+ </p>
+ </td>
+<td>
+ <p>
Note
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Generally useful information (an aside that doesn't fit in the flow of
the text)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="inlinemediaobject"><img src="../images/tip.png" alt="tip"></span>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <span class="inlinemediaobject"><img src="../../images/tip.png" alt="tip"></span>
+ </p>
+ </td>
+<td>
+ <p>
Tip
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Suggestion on how to do something (especially something that not be obvious)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="inlinemediaobject"><img src="../images/important.png" alt="important"></span>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <span class="inlinemediaobject"><img src="../../images/important.png" alt="important"></span>
+ </p>
+ </td>
+<td>
+ <p>
Important
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Important note on something to take particular notice of
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="inlinemediaobject"><img src="../images/caution.png" alt="caution"></span>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <span class="inlinemediaobject"><img src="../../images/caution.png" alt="caution"></span>
+ </p>
+ </td>
+<td>
+ <p>
Caution
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Take special care with this - it may not be what you expect and may cause
bad results
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="inlinemediaobject"><img src="../images/alert.png" alt="alert"></span>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <span class="inlinemediaobject"><img src="../../images/alert.png" alt="alert"></span>
+ </p>
+ </td>
+<td>
+ <p>
Danger
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
This is likely to cause serious trouble if ignored
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
+<br class="table-break"><p>
This documentation is automatically generated by Boost QuickBook documentation
tool. QuickBook can be found in the <a href="http://www.boost.org/tools/index.html" target="_top">Boost
Tools</a>.
</p>
-<a name="spirit.preface.support"></a><h3>
-<a name="id353354"></a>
- Support
- </h3>
+<a name="spirit.preface.support"></a><h4>
+<a name="id1097204"></a>
+ <a class="link" href="preface.html#spirit.preface.support">Support</a>
+ </h4>
<p>
Please direct all questions to Spirit's mailing list. You can subscribe to
the <a href="http://www.nabble.com/The-Spirit-Parser-Library-f3430.html" target="_top">Spirit
Modified: trunk/libs/spirit/doc/html/spirit/qi.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Qi - Writing Parsers</title>
+<title>Qi - Writing Parsers</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="abstracts/parsing_expression_grammar.html" title="Parsing
- Expression Grammar">
+<link rel="prev" href="abstracts/parsing_expression_grammar.html" title="Parsing Expression Grammar">
<link rel="next" href="qi/tutorials.html" title="Tutorials">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="abstracts/parsing_expression_grammar.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="qi/tutorials.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.qi"></a> Qi - Writing Parsers
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Qi - Writing Parsers">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.qi"></a><a class="link" href="qi.html" title="Qi - Writing Parsers"> Qi - Writing Parsers</a>
+</h2></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Tutorials</span></dt>
<dd><dl>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Quick Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../qi.html" title=" Qi - Writing Parsers">
-<link rel="previous" href="tutorials/mini_xml___error_handling.html" title="Mini
- XML - Error Handling">
+<link rel="up" href="../qi.html" title="Qi - Writing Parsers">
+<link rel="prev" href="tutorials/mini_xml___error_handling.html" title="Mini XML - Error Handling">
<link rel="next" href="quick_reference/common_notation.html" title="Common Notation">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="tutorials/mini_xml___error_handling.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="quick_reference/common_notation.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.qi.quick_reference"></a>Quick Reference
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Quick Reference">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.qi.quick_reference"></a><a class="link" href="quick_reference.html" title="Quick Reference">Quick Reference</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Common Notation</span></dt>
<dt><span class="section">Qi Parsers</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/common_notation.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/common_notation.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/common_notation.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Common Notation</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="../quick_reference.html" title="Quick Reference">
+<link rel="prev" href="../quick_reference.html" title="Quick Reference">
<link rel="next" href="qi_parsers.html" title="Qi Parsers">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,115 +22,112 @@
<div class="spirit-nav">
<a accesskey="p" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="qi_parsers.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.common_notation"></a>Common Notation
-</h4></div></div>
-<div></div>
-</div>
-<div class="variablelist">
+<div class="section" title="Common Notation">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.common_notation"></a><a class="link" href="common_notation.html" title="Common Notation">Common Notation</a>
+</h4></div></div></div>
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
Parser type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span><span class="special">,</span> <span class="identifier">a</span><span class="special">,</span>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span><span class="special">,</span> <span class="identifier">a</span><span class="special">,</span>
<span class="identifier">b</span><span class="special">,</span>
- <span class="identifier">c</span></tt></span></dt>
+ <span class="identifier">c</span></code></span></dt>
<dd><p>
Parser objects
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">,</span>
- <span class="identifier">C</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">,</span>
+ <span class="identifier">C</span></code></span></dt>
<dd><p>
- Attribute types of parsers <tt class="computeroutput"><span class="identifier">a</span></tt>,
- <tt class="computeroutput"><span class="identifier">b</span></tt> and <tt class="computeroutput"><span class="identifier">c</span></tt>
+ Attribute types of parsers <code class="computeroutput"><span class="identifier">a</span></code>,
+ <code class="computeroutput"><span class="identifier">b</span></code> and <code class="computeroutput"><span class="identifier">c</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">I</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">I</span></code></span></dt>
<dd><p>
The iterator type used for parsing
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Unused</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Unused</span></code></span></dt>
<dd><p>
- An <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ An <code class="computeroutput"><span class="identifier">unused_type</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Context</span></code></span></dt>
<dd><p>
- The enclosing rule's <tt class="computeroutput"><span class="identifier">Context</span></tt>
+ The enclosing rule's <code class="computeroutput"><span class="identifier">Context</span></code>
type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">attrib</span></code></span></dt>
<dd><p>
An attribute value
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Attrib</span></code></span></dt>
<dd><p>
An attribute type
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">b</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">b</span></code></span></dt>
<dd><p>
A boolean expression
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fp</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fp</span></code></span></dt>
<dd><p>
- A (lazy parser) function with signature <tt class="computeroutput"><span class="identifier">P</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span></tt>
+ A (lazy parser) function with signature <code class="computeroutput"><span class="identifier">P</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fa</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fa</span></code></span></dt>
<dd><p>
- A (semantic action) function with signature <tt class="computeroutput"><span class="keyword">void</span><span class="special">(</span><span class="identifier">Attrib</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">,</span> <span class="keyword">bool</span><span class="special">&)</span></tt>. The third parameter is a boolean
- flag that can be set to false to force the parse to fail. Both <tt class="computeroutput"><span class="identifier">Context</span></tt> and the boolean flag are
+ A (semantic action) function with signature <code class="computeroutput"><span class="keyword">void</span><span class="special">(</span><span class="identifier">Attrib</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">,</span> <span class="keyword">bool</span><span class="special">&)</span></code>. The third parameter is a boolean
+ flag that can be set to false to force the parse to fail. Both <code class="computeroutput"><span class="identifier">Context</span></code> and the boolean flag are
optional.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">first</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">first</span></code></span></dt>
<dd><p>
An iterator pointing to the start of input
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">last</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">last</span></code></span></dt>
<dd><p>
An iterator pointing to the end of input
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Ch</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Ch</span></code></span></dt>
<dd><p>
Character-class specific character type (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ch</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ch</span></code></span></dt>
<dd><p>
Character-class specific character (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ch2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ch2</span></code></span></dt>
<dd><p>
Character-class specific character (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">charset</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">charset</span></code></span></dt>
<dd><p>
Character-set specifier string (example: "a-z0-9")
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">str</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">str</span></code></span></dt>
<dd><p>
Character-class specific string (See Character Class Types)
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Str</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Str</span></code></span></dt>
<dd><p>
- Attribute of <tt class="computeroutput"><span class="identifier">str</span></tt>:
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the underlying
- character type of <tt class="computeroutput"><span class="identifier">str</span></tt>
+ Attribute of <code class="computeroutput"><span class="identifier">str</span></code>:
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the underlying
+ character type of <code class="computeroutput"><span class="identifier">str</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">tuple</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a fusion sequence
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">vector</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">vector</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for an STL container
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">variant</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a boost::variant
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">optional</span><span class="special"><></span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">optional</span><span class="special"><></span></code></span></dt>
<dd><p>
Used as a placeholder for a boost::optional
</p></dd>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/compound_attribute_rules.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/compound_attribute_rules.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/compound_attribute_rules.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Compound
- Attribute Rules</title>
+<title>Compound Attribute Rules</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="qi_parsers/action.html" title="action">
+<link rel="prev" href="qi_parsers/action.html" title="action">
<link rel="next" href="non_terminals.html" title="Non-terminals">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,50 +22,52 @@
<div class="spirit-nav">
<a accesskey="p" href="qi_parsers/action.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="non_terminals.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.compound_attribute_rules"></a><a href="compound_attribute_rules.html" title="Compound
- Attribute Rules">Compound
+<div class="section" title="Compound Attribute Rules">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.compound_attribute_rules"></a><a class="link" href="compound_attribute_rules.html" title="Compound Attribute Rules">Compound
Attribute Rules</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
The notation will be for instance:
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
</pre>
<p>
- which reads as: given, <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> are parsers/generators,
- and <tt class="computeroutput"><span class="identifier">A</span></tt> is the type of the
- attribute of <tt class="computeroutput"><span class="identifier">a</span></tt>, and <tt class="computeroutput"><span class="identifier">B</span></tt> is the type of the attribute of <tt class="computeroutput"><span class="identifier">b</span></tt>, then the type of the attribute of
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">>></span>
- <span class="identifier">b</span></tt> will be <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></tt>.
+ which reads as: given, <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> are parsers/generators,
+ and <code class="computeroutput"><span class="identifier">A</span></code> is the type of the
+ attribute of <code class="computeroutput"><span class="identifier">a</span></code>, and <code class="computeroutput"><span class="identifier">B</span></code> is the type of the attribute of <code class="computeroutput"><span class="identifier">b</span></code>, then the type of the attribute of
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">>></span>
+ <span class="identifier">b</span></code> will be <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span></code>.
</p>
<div class="table">
-<a name="id446297"></a><p class="title"><b>Table 4. compound parser attribute types</b></p>
-<table class="table" summary="compound parser attribute types">
+<a name="id1136685"></a><p class="title"><b>Table 4. compound parser attribute types</b></p>
+<div class="table-contents"><table class="table" summary="compound parser attribute types">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- sequence (<tt class="computeroutput"><span class="special">>></span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ sequence (<code class="computeroutput"><span class="special">>></span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -80,14 +81,16 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- expect (<tt class="computeroutput"><span class="special">></span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ expect (<code class="computeroutput"><span class="special">></span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">></span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -101,14 +104,16 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">></span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- alternative (<tt class="computeroutput"><span class="special">|</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ alternative (<code class="computeroutput"><span class="special">|</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
@@ -118,84 +123,96 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">A</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- difference (<tt class="computeroutput"><span class="special">-</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ difference (<code class="computeroutput"><span class="special">-</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">-</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">A</span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">-</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- kleene (unary <tt class="computeroutput"><span class="special">*</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ kleene (unary <code class="computeroutput"><span class="special">*</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">*</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- plus (unary <tt class="computeroutput"><span class="special">+</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ plus (unary <code class="computeroutput"><span class="special">+</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">+</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- list (<tt class="computeroutput"><span class="special">%</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ list (<code class="computeroutput"><span class="special">%</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">%</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
repetition
- </p></td>
+ </p>
+ </td>
<td>
-<p>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(...,...)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="identifier">repeat</span><span class="special">(...,...)[</span><span class="identifier">a</span><span class="special">]:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- sequential or (<tt class="computeroutput"><span class="special">||</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ sequential or (<code class="computeroutput"><span class="special">||</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">||</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">optional</span><span class="special"><</span><span class="identifier">B</span><span class="special">></span> <span class="special">></span>
@@ -204,48 +221,60 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">||</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- optional (unary <tt class="computeroutput"><span class="special">-</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ optional (unary <code class="computeroutput"><span class="special">-</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span>
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">-</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
<tr>
-<td><p>
- and predicate (<tt class="computeroutput"><span class="special">&</span></tt>)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ and predicate (<code class="computeroutput"><span class="special">&</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></tt>
- </p></td>
+ <span class="special">&</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- not predicate (<tt class="computeroutput"><span class="special">!</span></tt>)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
+<td>
+ <p>
+ not predicate (<code class="computeroutput"><span class="special">!</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span><span class="special">:</span>
<span class="identifier">A</span> <span class="special">--></span>
- <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></tt>
- </p></td>
+ <span class="special">!</span><span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- permutation (<tt class="computeroutput"><span class="special">^</span></tt>)
- </p></td>
<td>
-<p>
+ <p>
+ permutation (<code class="computeroutput"><span class="special">^</span></code>)
+ </p>
+ </td>
+<td>
+ <p>
</p>
<pre class="programlisting"><span class="identifier">a</span><span class="special">:</span> <span class="identifier">A</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">B</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">^</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">tuple</span><span class="special"><</span><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span> <span class="identifier">optional</span><span class="special"><</span><span class="identifier">B</span><span class="special">></span> <span class="special">></span>
@@ -254,11 +283,12 @@
<span class="identifier">a</span><span class="special">:</span> <span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">b</span><span class="special">:</span> <span class="identifier">Unused</span> <span class="special">--></span> <span class="special">(</span><span class="identifier">a</span> <span class="special">^</span> <span class="identifier">b</span><span class="special">):</span> <span class="identifier">Unused</span></pre>
<p>
</p>
-</td>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
+<br class="table-break">
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/non_terminals.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/non_terminals.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/non_terminals.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Non-terminals</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="compound_attribute_rules.html" title="Compound
- Attribute Rules">
-<link rel="next" href="semantic_actions.html" title="Semantic
- Actions">
+<link rel="prev" href="compound_attribute_rules.html" title="Compound Attribute Rules">
+<link rel="next" href="semantic_actions.html" title="Semantic Actions">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,61 +22,58 @@
<div class="spirit-nav">
<a accesskey="p" href="compound_attribute_rules.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.non_terminals"></a>Non-terminals
-</h4></div></div>
-<div></div>
-</div>
-<div class="variablelist">
+<div class="section" title="Non-terminals">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.non_terminals"></a><a class="link" href="non_terminals.html" title="Non-terminals">Non-terminals</a>
+</h4></div></div></div>
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">RT</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">RT</span></code></span></dt>
<dd><p>
Synthesized attribute. The rule or grammar's return type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Arg1</span></tt>,
- <tt class="computeroutput"><span class="identifier">Arg2</span></tt>, <tt class="computeroutput"><span class="identifier">ArgN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Arg1</span></code>,
+ <code class="computeroutput"><span class="identifier">Arg2</span></code>, <code class="computeroutput"><span class="identifier">ArgN</span></code></span></dt>
<dd><p>
Inherited attributes. Zero or more arguments.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">L1</span></tt>,
- <tt class="computeroutput"><span class="identifier">L2</span></tt>, <tt class="computeroutput"><span class="identifier">LN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">L1</span></code>,
+ <code class="computeroutput"><span class="identifier">L2</span></code>, <code class="computeroutput"><span class="identifier">LN</span></code></span></dt>
<dd><p>
Zero or more local variables.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">r</span><span class="special">,</span> <span class="identifier">r2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">r</span><span class="special">,</span> <span class="identifier">r2</span></code></span></dt>
<dd><p>
Rules
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">g</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">g</span></code></span></dt>
<dd><p>
A grammar
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A parser expression
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">my_grammar</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">my_grammar</span></code></span></dt>
<dd><p>
A user defined grammar
</p></dd>
</dl>
</div>
-<div class="variablelist">
+<div class="variablelist" title="Terminology">
<p class="title"><b>Terminology</b></p>
<dl>
<dt><span class="term">Signature</span></dt>
<dd><p>
- <tt class="computeroutput"><span class="identifier">RT</span><span class="special">(</span><span class="identifier">Arg1</span><span class="special">,</span> <span class="identifier">Arg2</span> <span class="special">...</span>
- <span class="special">,</span><span class="identifier">ArgN</span><span class="special">)</span></tt>. The signature specifies the synthesized
+ <code class="computeroutput"><span class="identifier">RT</span><span class="special">(</span><span class="identifier">Arg1</span><span class="special">,</span> <span class="identifier">Arg2</span> <span class="special">...</span>
+ <span class="special">,</span><span class="identifier">ArgN</span><span class="special">)</span></code>. The signature specifies the synthesized
(return value) and inherited (arguments) attributes.
</p></dd>
<dt><span class="term">Locals</span></dt>
<dd><p>
- <tt class="computeroutput"><span class="identifier">locals</span><span class="special"><</span><span class="identifier">L1</span><span class="special">,</span> <span class="identifier">L2</span> <span class="special">...,</span>
- <span class="identifier">LN</span><span class="special">></span></tt>.
+ <code class="computeroutput"><span class="identifier">locals</span><span class="special"><</span><span class="identifier">L1</span><span class="special">,</span> <span class="identifier">L2</span> <span class="special">...,</span>
+ <span class="identifier">LN</span><span class="special">></span></code>.
The local variables.
</p></dd>
<dt><span class="term">Skipper</span></dt>
@@ -87,15 +82,15 @@
</p></dd>
</dl>
</div>
-<div class="variablelist">
+<div class="variablelist" title="Template Arguments">
<p class="title"><b>Template Arguments</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Iterator</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Iterator</span></code></span></dt>
<dd><p>
The iterator type you will use for parsing.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">A1</span></tt>,
- <tt class="computeroutput"><span class="identifier">A2</span></tt>, <tt class="computeroutput"><span class="identifier">A3</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">A1</span></code>,
+ <code class="computeroutput"><span class="identifier">A2</span></code>, <code class="computeroutput"><span class="identifier">A3</span></code></span></dt>
<dd><p>
Can be one of 1)Signature 2)Locals 3)Skipper.
</p></dd>
@@ -107,120 +102,164 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
<span class="identifier">A1</span><span class="special">,</span>
<span class="identifier">A2</span><span class="special">,</span>
<span class="identifier">A3</span><span class="special">></span>
- <span class="identifier">r</span><span class="special">(</span><span class="identifier">name</span><span class="special">);</span></tt>
- </p></td>
-<td><p>
- Rule declaration. <tt class="computeroutput"><span class="identifier">Iterator</span></tt>
- is required. <tt class="computeroutput"><span class="identifier">A1</span><span class="special">,</span> <span class="identifier">A2</span><span class="special">,</span> <span class="identifier">A3</span></tt>
- are optional and can be specified in any order. <tt class="computeroutput"><span class="identifier">name</span></tt>
+ <span class="identifier">r</span><span class="special">(</span><span class="identifier">name</span><span class="special">);</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Rule declaration. <code class="computeroutput"><span class="identifier">Iterator</span></code>
+ is required. <code class="computeroutput"><span class="identifier">A1</span><span class="special">,</span> <span class="identifier">A2</span><span class="special">,</span> <span class="identifier">A3</span></code>
+ are optional and can be specified in any order. <code class="computeroutput"><span class="identifier">name</span></code>
is an optional string that gives the rule its name, useful for
debugging and error handling.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
<span class="identifier">A1</span><span class="special">,</span>
<span class="identifier">A2</span><span class="special">,</span>
<span class="identifier">A3</span><span class="special">></span>
- <span class="identifier">r</span><span class="special">(</span><span class="identifier">r2</span><span class="special">);</span></tt>
- </p></td>
-<td><p>
- Copy construct rule <tt class="computeroutput"><span class="identifier">r</span></tt>
- from rule <tt class="computeroutput"><span class="identifier">r2</span></tt>.
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
- <span class="identifier">r2</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
- Assign rule <tt class="computeroutput"><span class="identifier">r2</span></tt>
- to <tt class="computeroutput"><span class="identifier">r</span></tt>. <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">alias</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- return an alias of <tt class="computeroutput"><span class="identifier">r</span></tt>.
- The alias is a parser that holds a reference to <tt class="computeroutput"><span class="identifier">r</span></tt>.
+ <span class="identifier">r</span><span class="special">(</span><span class="identifier">r2</span><span class="special">);</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Copy construct rule <code class="computeroutput"><span class="identifier">r</span></code>
+ from rule <code class="computeroutput"><span class="identifier">r2</span></code>.
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
+ <span class="identifier">r2</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Assign rule <code class="computeroutput"><span class="identifier">r2</span></code>
+ to <code class="computeroutput"><span class="identifier">r</span></code>. <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">alias</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ return an alias of <code class="computeroutput"><span class="identifier">r</span></code>.
+ The alias is a parser that holds a reference to <code class="computeroutput"><span class="identifier">r</span></code>.
Reference semantics.
- </p></td>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">copy</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Get a copy of <code class="computeroutput"><span class="identifier">r</span></code>.
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></code> semantics.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">copy</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- Get a copy of <tt class="computeroutput"><span class="identifier">r</span></tt>.
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span></tt> semantics.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Naming a rule
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Getting the name of a rule
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
debug(r)
- </p></td>
-<td><p>
- Debug rule <tt class="computeroutput"><span class="identifier">r</span></tt>
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ Debug rule <code class="computeroutput"><span class="identifier">r</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
- <span class="identifier">p</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">=</span>
+ <span class="identifier">p</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Rule definition
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">r</span> <span class="special">%=</span>
- <span class="identifier">p</span><span class="special">;</span></tt>
- </p></td>
-<td><p>
- Auto-rule definition. The attribute of <tt class="computeroutput"><span class="identifier">p</span></tt>
- should be compatible with the synthesized attribute of <tt class="computeroutput"><span class="identifier">r</span></tt>. When <tt class="computeroutput"><span class="identifier">p</span></tt>
- is successful, its attribute is automatically propagated to <tt class="computeroutput"><span class="identifier">r</span></tt>'s synthesized attribute.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">r</span> <span class="special">%=</span>
+ <span class="identifier">p</span><span class="special">;</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Auto-rule definition. The attribute of <code class="computeroutput"><span class="identifier">p</span></code>
+ should be compatible with the synthesized attribute of <code class="computeroutput"><span class="identifier">r</span></code>. When <code class="computeroutput"><span class="identifier">p</span></code>
+ is successful, its attribute is automatically propagated to <code class="computeroutput"><span class="identifier">r</span></code>'s synthesized attribute.
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Iterator</span><span class="special">></span>
@@ -238,36 +277,50 @@
</pre>
<p>
</p>
-</td>
-<td><p>
- Grammar definition. <tt class="computeroutput"><span class="identifier">name</span></tt>
+ </td>
+<td>
+ <p>
+ Grammar definition. <code class="computeroutput"><span class="identifier">name</span></code>
is an optional string that gives the grammar its name, useful for
debugging and error handling.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
my_grammar<Iterator> g
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Instantiating a grammar
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="identifier">name</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Naming a grammar
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">g</span><span class="special">.</span><span class="identifier">name</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Getting the name of a grammar
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/phoenix.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/phoenix.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/phoenix.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Phoenix</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="semantic_actions.html" title="Semantic
- Actions">
+<link rel="prev" href="semantic_actions.html" title="Semantic Actions">
<link rel="next" href="../reference.html" title="Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../reference.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.phoenix"></a>Phoenix
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Phoenix">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.phoenix"></a><a class="link" href="phoenix.html" title="Phoenix">Phoenix</a>
+</h4></div></div></div>
<p>
<a href="../../../../../phoenix/doc/html/index.html" target="_top">Boost.Phoenix</a> makes
it easier to attach semantic actions. You just inline your lambda expressions:
@@ -38,37 +34,37 @@
</pre>
<p>
Spirit.Qi provides some Boost.Phoenix
- placeholders to important information from the <tt class="computeroutput"><span class="identifier">Attrib</span></tt>
- and <tt class="computeroutput"><span class="identifier">Context</span></tt> that are otherwise
+ placeholders to important information from the <code class="computeroutput"><span class="identifier">Attrib</span></code>
+ and <code class="computeroutput"><span class="identifier">Context</span></code> that are otherwise
fiddly to extract.
</p>
-<div class="variablelist">
+<div class="variablelist" title="Spirit.Qi specific Phoenix placeholders">
<p class="title"><b>Spirit.Qi specific Phoenix placeholders</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_1</span><span class="special">,</span> <span class="identifier">_2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_N</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_1</span><span class="special">,</span> <span class="identifier">_2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_N</span></code></span></dt>
<dd><p>
- Nth attribute of <tt class="computeroutput"><span class="identifier">p</span></tt>
+ Nth attribute of <code class="computeroutput"><span class="identifier">p</span></code>
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_val</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_val</span></code></span></dt>
<dd><p>
The enclosing rule's synthesized attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_r1</span><span class="special">,</span> <span class="identifier">_r2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_rN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_r1</span><span class="special">,</span> <span class="identifier">_r2</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_rN</span></code></span></dt>
<dd><p>
The enclosing rule's Nth inherited attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_a</span><span class="special">,</span> <span class="identifier">_b</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_j</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_a</span><span class="special">,</span> <span class="identifier">_b</span><span class="special">...</span> <span class="special">,</span> <span class="identifier">_j</span></code></span></dt>
<dd><p>
- The enclosing rule's local variables (<tt class="computeroutput"><span class="identifier">_a</span></tt>
+ The enclosing rule's local variables (<code class="computeroutput"><span class="identifier">_a</span></code>
refers to the first).
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_val</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_val</span></code></span></dt>
<dd><p>
The enclosing rule's synthesized attribute.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">_pass</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">_pass</span></code></span></dt>
<dd><p>
- Assign <tt class="computeroutput"><span class="keyword">false</span></tt> to <tt class="computeroutput"><span class="identifier">_pass</span></tt> to force a parser failure.
+ Assign <code class="computeroutput"><span class="keyword">false</span></code> to <code class="computeroutput"><span class="identifier">_pass</span></code> to force a parser failure.
</p></dd>
</dl>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Qi Parsers</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="common_notation.html" title="Common Notation">
+<link rel="prev" href="common_notation.html" title="Common Notation">
<link rel="next" href="qi_parsers/char.html" title="char">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="common_notation.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="qi_parsers/char.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers"></a>Qi Parsers
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Qi Parsers">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers"></a><a class="link" href="qi_parsers.html" title="Qi Parsers">Qi Parsers</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">char</span></dt>
<dt><span class="section">numeric</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/action.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/action.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/action.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>action</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="operator.html" title="operator">
-<link rel="next" href="../compound_attribute_rules.html" title="Compound
- Attribute Rules">
+<link rel="prev" href="operator.html" title="operator">
+<link rel="next" href="../compound_attribute_rules.html" title="Compound Attribute Rules">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="operator.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../compound_attribute_rules.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.action"></a>action
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="action">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.action"></a><a class="link" href="action.html" title="action">action</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -37,27 +33,39 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">[</span><span class="identifier">fa</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Attribute of <tt class="computeroutput"><span class="identifier">p</span></tt>
- </p></td>
-<td><p>
- Call semantic action, <tt class="computeroutput"><span class="identifier">fa</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">[</span><span class="identifier">fa</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Attribute of <code class="computeroutput"><span class="identifier">p</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Call semantic action, <code class="computeroutput"><span class="identifier">fa</span></code>
if p succeeds.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/auxiliary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/auxiliary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/auxiliary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>auxiliary</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="string.html" title="string">
+<link rel="prev" href="string.html" title="string">
<link rel="next" href="binary.html" title="binary">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.auxiliary"></a>auxiliary
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="auxiliary">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.auxiliary"></a><a class="link" href="auxiliary.html" title="auxiliary">auxiliary</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,99 +33,147 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eol</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Matches the end of line (<tt class="computeroutput"><span class="special">\</span><span class="identifier">r</span></tt> or <tt class="computeroutput"><span class="special">\</span><span class="identifier">n</span></tt> or <tt class="computeroutput"><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">n</span></tt>)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eoi</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eol</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches the end of line (<code class="computeroutput"><span class="special">\</span><span class="identifier">r</span></code> or <code class="computeroutput"><span class="special">\</span><span class="identifier">n</span></code> or <code class="computeroutput"><span class="special">\</span><span class="identifier">r</span><span class="special">\</span><span class="identifier">n</span></code>)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eoi</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Matches the end of input (first == last)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Match an empty string
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- If <tt class="computeroutput"><span class="identifier">b</span></tt> is true,
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">eps</span><span class="special">(</span><span class="identifier">b</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ If <code class="computeroutput"><span class="identifier">b</span></code> is true,
match an empty string
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fp</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Attribute of <tt class="computeroutput"><span class="identifier">P</span></tt>
- where <tt class="computeroutput"><span class="identifier">P</span></tt> is the
- return type of <tt class="computeroutput"><span class="identifier">fp</span></tt>
- </p></td>
-<td><p>
- Invoke <tt class="computeroutput"><span class="identifier">fp</span></tt> at
- parse time, returning a parser <tt class="computeroutput"><span class="identifier">p</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fp</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Attribute of <code class="computeroutput"><span class="identifier">P</span></code>
+ where <code class="computeroutput"><span class="identifier">P</span></code> is the
+ return type of <code class="computeroutput"><span class="identifier">fp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Invoke <code class="computeroutput"><span class="identifier">fp</span></code> at
+ parse time, returning a parser <code class="computeroutput"><span class="identifier">p</span></code>
which is then called to parse.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fp</span></tt>
- </p></td>
-<td><p>
- see <tt class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fp</span><span class="special">)</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ see <code class="computeroutput"><span class="identifier">lazy</span><span class="special">(</span><span class="identifier">fp</span><span class="special">)</span></code>
above
- </p></td>
-<td><p>
- Equivalent to <tt class="computeroutput"><span class="identifier">lazy</span><span class="special">[</span><span class="identifier">fp</span><span class="special">]</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- attr(attrib)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Attrib</span></tt>
- </p></td>
-<td><p>
- Doesn't consume/parse any input, but exposes the argument <tt class="computeroutput"><span class="identifier">attrib</span></tt> as its attribute.
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ Equivalent to <code class="computeroutput"><span class="identifier">lazy</span><span class="special">[</span><span class="identifier">fp</span><span class="special">]</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/auxiliary/attr.html" title="attr"><code class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">attrib</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Attrib</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Doesn't consume/parse any input, but exposes the argument <code class="computeroutput"><span class="identifier">attrib</span></code> as its attribute.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/binary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/binary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/binary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>binary</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="auxiliary.html" title="auxiliary">
+<link rel="prev" href="auxiliary.html" title="auxiliary">
<link rel="next" href="directive.html" title="directive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.binary"></a>binary
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="binary">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.binary"></a><a class="link" href="binary.html" title="binary">binary</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,126 +33,192 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">byte_</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">byte_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
8 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches an 8 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
16 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 16 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
16 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 16 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_word</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_word</span></code>
+ </p>
+ </td>
+<td>
+ <p>
16 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 16 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
32 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 32 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
32 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 32 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_dword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_dword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
32 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 32 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
64 bits native endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 64 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">big_qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">big_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
64 bits big endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 64 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">little_qword</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">little_qword</span></code>
+ </p>
+ </td>
+<td>
+ <p>
64 bits little endian
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Matches a 64 bit binary
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/char.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/char.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/char.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>char</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="../qi_parsers.html" title="Qi Parsers">
+<link rel="prev" href="../qi_parsers.html" title="Qi Parsers">
<link rel="next" href="numeric.html" title="numeric">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="numeric.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.char"></a>char
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="char">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.char"></a><a class="link" href="char.html" title="char">char</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,239 +33,359 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- ch
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- lit(ch)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/lit_string.html" title="lit/string"><code class="computeroutput"><span class="identifier">ch</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/lit_string.html" title="lit/string"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Matches any character
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">ch</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a single char string literal, <tt class="computeroutput"><span class="identifier">c</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">,</span>
- <span class="identifier">ch2</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a range of chars from <tt class="computeroutput"><span class="identifier">ch</span></tt>
- to <tt class="computeroutput"><span class="identifier">ch2</span></tt> (inclusive)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character set <tt class="computeroutput"><span class="identifier">charset</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">alnum</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">alpha</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">blank</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">cntrl</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">digit</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">graph</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">print</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">punct</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">space</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">xdigit</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lower</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></tt> in the current character
- set
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">upper</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Ch</span></tt>
- </p></td>
-<td><p>
- Matches a character based on the equivalent of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></tt> in the current character
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">ch</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="string">"c"</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a single char string literal, <code class="computeroutput"><span class="identifier">c</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">,</span>
+ <span class="identifier">ch2</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a range of chars from <code class="computeroutput"><span class="identifier">ch</span></code>
+ to <code class="computeroutput"><span class="identifier">ch2</span></code> (inclusive)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">charset</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character set <code class="computeroutput"><span class="identifier">charset</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">alnum</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalnum</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">alpha</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isalpha</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">blank</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isblank</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">cntrl</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">iscntrl</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">digit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isdigit</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">graph</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isgraph</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">print</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isprint</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">punct</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">ispunct</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">space</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isspace</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">xdigit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isxdigit</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lower</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">islower</span></code> in the current character
+ set
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">upper</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Ch</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches a character based on the equivalent of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">isupper</span></code> in the current character
set
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/directive.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/directive.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/directive.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>directive</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="binary.html" title="binary">
+<link rel="prev" href="binary.html" title="binary">
<link rel="next" href="operator.html" title="operator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="binary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="operator.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.directive"></a>directive
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="directive">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.directive"></a><a class="link" href="directive.html" title="directive">directive</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,132 +33,198 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lexeme</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Disable skip parsing for <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- no_case[a]
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Inhibits case-sensitivity for <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Ignores the attribute type of <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">raw</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">I</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Presents the transduction of <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lexeme</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Disable skip parsing for <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/directive/no_case.html" title="no_case"><code class="computeroutput"><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Inhibits case-sensitivity for <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Ignores the attribute type of <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">raw</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">iterator_range</span><span class="special"><</span><span class="identifier">I</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Presents the transduction of <code class="computeroutput"><span class="identifier">a</span></code>
as an iterator range
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> zero
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> zero
or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">N</span></tt> times
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">,</span>
- <span class="identifier">M</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">N</span></tt> to <tt class="computeroutput"><span class="identifier">M</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">N</span></code> times
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">,</span>
+ <span class="identifier">M</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">N</span></code> to <code class="computeroutput"><span class="identifier">M</span></code>
times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">,</span>
- <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Repeat <tt class="computeroutput"><span class="identifier">a</span></tt> <tt class="computeroutput"><span class="identifier">N</span></tt> or more times
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">skip</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">repeat</span><span class="special">(</span><span class="identifier">N</span><span class="special">,</span>
+ <span class="identifier">inf</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Repeat <code class="computeroutput"><span class="identifier">a</span></code> <code class="computeroutput"><span class="identifier">N</span></code> or more times
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">skip</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Reestablish the skipper that got inhibited by lexeme
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">skip</span><span class="special">(</span><span class="identifier">p</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Use <tt class="computeroutput"><span class="identifier">p</span></tt> as a skipper
- for parsing <tt class="computeroutput"><span class="identifier">a</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">skip</span><span class="special">(</span><span class="identifier">p</span><span class="special">)[</span><span class="identifier">a</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Use <code class="computeroutput"><span class="identifier">p</span></code> as a skipper
+ for parsing <code class="computeroutput"><span class="identifier">a</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/numeric.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/numeric.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/numeric.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>numeric</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="char.html" title="char">
+<link rel="prev" href="char.html" title="char">
<link rel="next" href="string.html" title="string">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="char.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="string.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.numeric"></a>numeric
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="numeric">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.numeric"></a><a class="link" href="numeric.html" title="numeric">numeric</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,172 +33,262 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">float_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-<td><p>
- Parse a floating point number into a <tt class="computeroutput"><span class="keyword">float</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">double_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Parse a floating point number into a <tt class="computeroutput"><span class="keyword">double</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_double</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></tt>
- </p></td>
-<td><p>
- Parse a floating point number into a <tt class="computeroutput"><span class="keyword">long</span>
- <span class="keyword">double</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">bin</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-<td><p>
- Parse a binary integer into an <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">oct</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-<td><p>
- Parse an octal integer into an <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">hex</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-<td><p>
- Parse a hexadecimal integer into an <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ushort_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">float_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse a floating point number into a <code class="computeroutput"><span class="keyword">float</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">double_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse a floating point number into a <code class="computeroutput"><span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse a floating point number into a <code class="computeroutput"><span class="keyword">long</span>
+ <span class="keyword">double</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">bin</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse a binary integer into an <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">oct</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse an octal integer into an <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">hex</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Parse a hexadecimal integer into an <code class="computeroutput"><span class="keyword">unsigned</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ushort_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse an unsigned short integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse an unsigned long integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">uint_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">uint_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse an unsigned int
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ulong_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
- <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ulong_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">unsigned</span> <span class="keyword">long</span>
+ <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse an unsigned long long
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">short_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">short</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">short_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">short</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse a short integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse a long integer
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">int_</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">int</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">int_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">int</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse an int
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">long_long</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">long_long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parse a long long
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/operator.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/operator.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/operator.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>operator</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="directive.html" title="directive">
+<link rel="prev" href="directive.html" title="directive">
<link rel="next" href="action.html" title="action">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="directive.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="action.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.operator"></a>operator
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="operator">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.operator"></a><a class="link" href="operator.html" title="operator">operator</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,180 +33,258 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">!</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Not predicate. Ensure that <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">!</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Not predicate. Ensure that <code class="computeroutput"><span class="identifier">a</span></code>
does not match but don't move the iterator position
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">&</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- And predicate. Ensure that <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">&</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ And predicate. Ensure that <code class="computeroutput"><span class="identifier">a</span></code>
matches but don't move the iterator position
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">-</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Optional. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">-</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Optional. Parse <code class="computeroutput"><span class="identifier">a</span></code>
zero or one time
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">*</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Kleene. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">*</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Kleene. Parse <code class="computeroutput"><span class="identifier">a</span></code>
zero or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">+</span><span class="identifier">a</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Plus. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">+</span><span class="identifier">a</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Plus. Parse <code class="computeroutput"><span class="identifier">a</span></code>
one or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Alternative. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- or <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">>></span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Sequence. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- followed by <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">></span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Expect. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- followed by <tt class="computeroutput"><span class="identifier">b</span></tt>.
- <tt class="computeroutput"><span class="identifier">b</span></tt> is expected
- to match when <tt class="computeroutput"><span class="identifier">a</span></tt>
- matches, otherwise, an <tt class="computeroutput"><span class="identifier">expectation_failure</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Alternative. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ or <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">>></span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Sequence. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ followed by <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">></span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Expect. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ followed by <code class="computeroutput"><span class="identifier">b</span></code>.
+ <code class="computeroutput"><span class="identifier">b</span></code> is expected
+ to match when <code class="computeroutput"><span class="identifier">a</span></code>
+ matches, otherwise, an <code class="computeroutput"><span class="identifier">expectation_failure</span></code>
is thrown.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">-</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">A</span></tt>
- </p></td>
-<td><p>
- Difference. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- but not <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">||</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
- <span class="identifier">B</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- Sequential Or. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- or <tt class="computeroutput"><span class="identifier">b</span></tt> or <tt class="computeroutput"><span class="identifier">a</span></tt> followed by <tt class="computeroutput"><span class="identifier">b</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- List. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- delimited <tt class="computeroutput"><span class="identifier">b</span></tt> one
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">-</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">A</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Difference. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ but not <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">||</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span>
+ <span class="identifier">B</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Sequential Or. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ or <code class="computeroutput"><span class="identifier">b</span></code> or <code class="computeroutput"><span class="identifier">a</span></code> followed by <code class="computeroutput"><span class="identifier">b</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">%</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ List. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ delimited <code class="computeroutput"><span class="identifier">b</span></code> one
or more times
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">a</span> <span class="special">^</span>
- <span class="identifier">b</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span></tt>
- <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span></tt>
- <tt class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">B</span><span class="special">></span>
- <span class="special">></span></tt>
- </p></td>
-<td><p>
- Permutation. Parse <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> in any
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">a</span> <span class="special">^</span>
+ <span class="identifier">b</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tuple</span><span class="special"><</span></code>
+ <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">A</span><span class="special">>,</span></code>
+ <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">B</span><span class="special">></span>
+ <span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Permutation. Parse <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> in any
order
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/string.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/string.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/qi_parsers/string.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>string</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../qi_parsers.html" title="Qi Parsers">
-<link rel="previous" href="numeric.html" title="numeric">
+<link rel="prev" href="numeric.html" title="numeric">
<link rel="next" href="auxiliary.html" title="auxiliary">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="numeric.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi_parsers.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.quick_reference.qi_parsers.string"></a>string
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="string">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.quick_reference.qi_parsers.string"></a><a class="link" href="string.html" title="string">string</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -36,68 +33,98 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- str
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- lit(str)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Unused</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- string(str)
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Str</span></tt>
- </p></td>
-<td><p>
- Matches <tt class="computeroutput"><span class="identifier">str</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <a href="../../reference/string/symbols.html" title="symbols"><tt class="computeroutput"><span class="identifier">symbols</span><span class="special"><</span><span class="identifier">Ch</span><span class="special">,</span>
- <span class="identifier">T</span><span class="special">></span></tt></a>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/lit_string.html" title="lit/string"><code class="computeroutput"><span class="identifier">str</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/lit_string.html" title="lit/string"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Unused</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/lit_string.html" title="lit/string"><code class="computeroutput"><span class="identifier">string</span><span class="special">(</span><span class="identifier">str</span><span class="special">)</span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Str</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches <code class="computeroutput"><span class="identifier">str</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <a class="link" href="../../reference/string/symbols.html" title="symbols"><code class="computeroutput"><span class="identifier">symbols</span><span class="special"><</span><span class="identifier">Ch</span><span class="special">,</span>
+ <span class="identifier">T</span><span class="special">></span></code></a>
+ </p>
+ </td>
+<td>
+ <p>
N/A
- </p></td>
-<td><p>
- Declare a symbol table, <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- <tt class="computeroutput"><span class="identifier">Ch</span></tt> is the underlying
- char type of the symbol table keys. <tt class="computeroutput"><span class="identifier">T</span></tt>
+ </p>
+ </td>
+<td>
+ <p>
+ Declare a symbol table, <code class="computeroutput"><span class="identifier">sym</span></code>.
+ <code class="computeroutput"><span class="identifier">Ch</span></code> is the underlying
+ char type of the symbol table keys. <code class="computeroutput"><span class="identifier">T</span></code>
is the data type associated with each key.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">add</span>
@@ -108,27 +135,37 @@
</pre>
<p>
</p>
-</td>
-<td><p>
+ </td>
+<td>
+ <p>
N/A
- </p></td>
-<td><p>
- Add symbols into a symbol table, <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- val1 and val2 are optional data of type <tt class="computeroutput"><span class="identifier">T</span></tt>,
+ </p>
+ </td>
+<td>
+ <p>
+ Add symbols into a symbol table, <code class="computeroutput"><span class="identifier">sym</span></code>.
+ val1 and val2 are optional data of type <code class="computeroutput"><span class="identifier">T</span></code>,
the data type associated with each key.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">T</span></tt>
- </p></td>
-<td><p>
- Matches entries in the symbol table, <tt class="computeroutput"><span class="identifier">sym</span></tt>.
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">T</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Matches entries in the symbol table, <code class="computeroutput"><span class="identifier">sym</span></code>.
If successful, returns the data associated with the key
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/quick_reference/semantic_actions.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/quick_reference/semantic_actions.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/quick_reference/semantic_actions.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Semantic
- Actions</title>
+<title>Semantic Actions</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../quick_reference.html" title="Quick Reference">
-<link rel="previous" href="non_terminals.html" title="Non-terminals">
+<link rel="prev" href="non_terminals.html" title="Non-terminals">
<link rel="next" href="phoenix.html" title="Phoenix">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,22 +22,18 @@
<div class="spirit-nav">
<a accesskey="p" href="non_terminals.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="phoenix.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.quick_reference.semantic_actions"></a><a href="semantic_actions.html" title="Semantic
- Actions">Semantic
+<div class="section" title="Semantic Actions">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.quick_reference.semantic_actions"></a><a class="link" href="semantic_actions.html" title="Semantic Actions">Semantic
Actions</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
Has the form:
</p>
<pre class="programlisting"><span class="identifier">p</span><span class="special">[</span><span class="identifier">f</span><span class="special">]</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">f</span></tt> is a function with
+ where <code class="computeroutput"><span class="identifier">f</span></code> is a function with
the signatures:
</p>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Attrib</span> <span class="keyword">const</span><span class="special">&);</span>
@@ -46,7 +41,7 @@
<span class="keyword">void</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Attrib</span> <span class="keyword">const</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">&,</span> <span class="keyword">bool</span><span class="special">&);</span>
</pre>
<p>
- You can use <tt class="computeroutput">Boost.Bind</tt>
+ You can use <code class="computeroutput">Boost.Bind</code>
to bind member functions. For function objects, the allowed signatures
are:
</p>
@@ -55,7 +50,7 @@
<span class="keyword">void</span> <span class="keyword">operator</span><span class="special">()(</span><span class="identifier">Attrib</span> <span class="keyword">const</span><span class="special">&,</span> <span class="identifier">Context</span><span class="special">&,</span> <span class="keyword">bool</span><span class="special">&)</span> <span class="keyword">const</span><span class="special">;</span>
</pre>
<p>
- The <tt class="computeroutput"><span class="identifier">unused_type</span></tt> is used
+ The <code class="computeroutput"><span class="identifier">unused_type</span></code> is used
in the signatures above to signify 'don't care'.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Reference</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../qi.html" title=" Qi - Writing Parsers">
-<link rel="previous" href="quick_reference/phoenix.html" title="Phoenix">
+<link rel="up" href="../qi.html" title="Qi - Writing Parsers">
+<link rel="prev" href="quick_reference/phoenix.html" title="Phoenix">
<link rel="next" href="reference/parser_concepts.html" title="Parser Concepts">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="quick_reference/phoenix.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="reference/parser_concepts.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.qi.reference"></a>Reference
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Reference">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.qi.reference"></a><a class="link" href="reference.html" title="Reference">Reference</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Parser Concepts</span></dt>
<dt><span class="section">Basics</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Auxiliary</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="basics.html" title="Basics">
+<link rel="prev" href="basics.html" title="Basics">
<link rel="next" href="auxiliary/attr.html" title="attr">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,29 +22,26 @@
<div class="spirit-nav">
<a accesskey="p" href="basics.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary/attr.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.auxiliary"></a>Auxiliary
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Auxiliary">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.auxiliary"></a><a class="link" href="auxiliary.html" title="Auxiliary">Auxiliary</a>
+</h4></div></div></div>
<div class="toc"><dl><dt><span class="section">attr</span></dt></dl></div>
<p>
This module includes different auxiliary parsers not fitting into any of
- the other categories. This module includes the <tt class="computeroutput"><span class="identifier">attr</span></tt>,
- <tt class="computeroutput"><span class="identifier">eoi</span></tt>, <tt class="computeroutput"><span class="identifier">eol</span></tt>,
- <tt class="computeroutput"><span class="identifier">eps</span></tt>, and <tt class="computeroutput"><span class="identifier">lazy</span></tt> parsers.
+ the other categories. This module includes the <code class="computeroutput"><span class="identifier">attr</span></code>,
+ <code class="computeroutput"><span class="identifier">eoi</span></code>, <code class="computeroutput"><span class="identifier">eol</span></code>,
+ <code class="computeroutput"><span class="identifier">eps</span></code>, and <code class="computeroutput"><span class="identifier">lazy</span></code> parsers.
</p>
-<a name="spirit.qi.reference.auxiliary.module_header"></a><h5>
-<a name="id459032"></a>
- Module Header
- </h5>
+<a name="spirit.qi.reference.auxiliary.module_header"></a><h6>
+<a name="id1149447"></a>
+ <a class="link" href="auxiliary.html#spirit.qi.reference.auxiliary.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/auxiliary.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_auxiliary</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary/attr.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary/attr.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/auxiliary/attr.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>attr</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../auxiliary.html" title="Auxiliary">
-<link rel="previous" href="../auxiliary.html" title="Auxiliary">
+<link rel="prev" href="../auxiliary.html" title="Auxiliary">
<link rel="next" href="../char.html" title="Char">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,93 +22,98 @@
<div class="spirit-nav">
<a accesskey="p" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../auxiliary.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../char.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.auxiliary.attr"></a>attr
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="attr">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.auxiliary.attr"></a><a class="link" href="attr.html" title="attr">attr</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">attr</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">attr</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A pseudo parser that injects an attribute but does not consume
any input.
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.auxiliary.attr.description"></a><h6>
-<a name="id459249"></a>
- Description
+<a name="id1149603"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">attr</span></tt> parser does
+ The <code class="computeroutput"><span class="identifier">attr</span></code> parser does
not consume any input, for this reason it always matches an empty string.
- The parser generated by <tt class="computeroutput"><span class="identifier">attr</span></tt>
+ The parser generated by <code class="computeroutput"><span class="identifier">attr</span></code>
always succeeds. It's purpose is to expose its specified parameter as
an attribute.
</p>
<a name="spirit.qi.reference.auxiliary.attr.header"></a><h6>
-<a name="id459304"></a>
- Header
+<a name="id1149635"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/auxiliary/attr.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_attr</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.qi.reference.auxiliary.attr.model_of"></a><h6>
-<a name="id459418"></a>
- Model of
+<a name="id1149709"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Parser
+ <a class="link" href="../parser_concepts/parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">attrib</span></code></span></dt>
<dd><p>
A arbitrary typed constant value, e.g. 0.0, "Hello", or
a variable of arbitrary type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fattrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fattrib</span></code></span></dt>
<dd><p>
- A Lazy Argument
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy Argument</a>
that evaluates to an arbitrary type.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.auxiliary.attr.expression_semantics"></a><h6>
-<a name="id459535"></a>
- <a href="attr.html#spirit.qi.reference.auxiliary.attr.expression_semantics">Expression
+<a name="id1149791"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.expression_semantics">Expression
Semantics</a>
</h6>
<p>
- Semantics of an <tt class="computeroutput"><span class="identifier">attr</span><span class="special">()</span></tt> expression are fully defined by the
- Parser concept.
+ Semantics of an <code class="computeroutput"><span class="identifier">attr</span><span class="special">()</span></code> expression are fully defined by the
+ <a class="link" href="../parser_concepts/parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a> concept.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -116,39 +121,51 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">attrib</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Generate a pseudo parser exposing the current value of <tt class="computeroutput"><span class="identifier">attrib</span></tt> as its attribute value
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">attrib</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Generate a pseudo parser exposing the current value of <code class="computeroutput"><span class="identifier">attrib</span></code> as its attribute value
while not consuming any input at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">fattrib</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">fattrib</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Generate a pseudo parser exposing as its attribute the value
- returned by invoking <tt class="computeroutput"><span class="identifier">fattrib</span></tt>
- at parse time, while not consuming any input. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+ returned by invoking <code class="computeroutput"><span class="identifier">fattrib</span></code>
+ at parse time, while not consuming any input. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.auxiliary.attr.attributes"></a><h6>
-<a name="id459762"></a>
- Attributes
+<a name="id1149950"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -156,37 +173,49 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">attrib</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Attrib</span></tt>, which
- is the type of <tt class="computeroutput"><span class="identifier">attrib</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">attrib</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Attrib</span></code>, which
+ is the type of <code class="computeroutput"><span class="identifier">attrib</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">fattrib</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Attrib</span></tt>, which
- is the return type of <tt class="computeroutput"><span class="identifier">fattrib</span></tt>
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">attr</span><span class="special">(</span><span class="identifier">fattrib</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Attrib</span></code>, which
+ is the return type of <code class="computeroutput"><span class="identifier">fattrib</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.auxiliary.attr.complexity"></a><h6>
-<a name="id459958"></a>
- Complexity
+<a name="id1150095"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -202,8 +231,8 @@
done.
</p>
<a name="spirit.qi.reference.auxiliary.attr.example"></a><h6>
-<a name="id459999"></a>
- Example
+<a name="id1150123"></a>
+ <a class="link" href="attr.html#spirit.qi.reference.auxiliary.attr.example">Example</a>
</h6>
<p>
Some using declarations:
@@ -221,7 +250,7 @@
<p>
</p>
<p>
- Using <tt class="computeroutput"><span class="identifier">attr</span></tt> with literals:
+ Using <code class="computeroutput"><span class="identifier">attr</span></code> with literals:
</p>
<p>
</p>
@@ -241,7 +270,7 @@
<p>
</p>
<p>
- Using <tt class="computeroutput"><span class="identifier">attr</span></tt> with Phoenix function objects:
+ Using <code class="computeroutput"><span class="identifier">attr</span></code> with Phoenix function objects:
</p>
<p>
</p>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/basics.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/basics.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/basics.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Basics</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="parser_concepts/naryparser.html" title="NaryParser">
+<link rel="prev" href="parser_concepts/naryparser.html" title="NaryParser">
<link rel="next" href="auxiliary.html" title="Auxiliary">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,17 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="parser_concepts/naryparser.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="auxiliary.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.basics"></a>Basics
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.qi.reference.basics.lazy_argument"></a><h5>
-<a name="id457248"></a>
- Lazy Argument
- </h5>
+<div class="section" title="Basics">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.basics"></a><a class="link" href="basics.html" title="Basics">Basics</a>
+</h4></div></div></div>
+<a name="spirit.qi.reference.basics.lazy_argument"></a><h6>
+<a name="id1146468"></a>
+ <a class="link" href="basics.html#spirit.qi.reference.basics.lazy_argument">Lazy Argument</a>
+ </h6>
<p>
Some parsers (e.g. primitives and non-terminals) may take in additional
attributes. Such parsers take the form:
@@ -40,39 +37,39 @@
<pre class="programlisting"><span class="identifier">p</span><span class="special">(</span><span class="identifier">a1</span><span class="special">,</span> <span class="identifier">a2</span><span class="special">,...</span> <span class="identifier">aN</span><span class="special">)</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">p</span></tt> is a parser. Each
+ where <code class="computeroutput"><span class="identifier">p</span></code> is a parser. Each
of the arguments (a1...aN) can either be an immediate value, or a function,
- <tt class="computeroutput"><span class="identifier">f</span></tt>, with signature:
+ <code class="computeroutput"><span class="identifier">f</span></code>, with signature:
</p>
<pre class="programlisting"><span class="identifier">T</span> <span class="identifier">f</span><span class="special">(</span><span class="identifier">Unused</span><span class="special">,</span> <span class="identifier">Context</span><span class="special">)</span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">T</span></tt>, the function's
- return value, is compatible with the argument type expected and <tt class="computeroutput"><span class="identifier">Context</span></tt> is the parser's Context type
- (The first argument is <tt class="computeroutput"><span class="identifier">unused</span></tt>
- to make the <tt class="computeroutput"><span class="identifier">Context</span></tt> the
+ where <code class="computeroutput"><span class="identifier">T</span></code>, the function's
+ return value, is compatible with the argument type expected and <code class="computeroutput"><span class="identifier">Context</span></code> is the parser's Context type
+ (The first argument is <code class="computeroutput"><span class="identifier">unused</span></code>
+ to make the <code class="computeroutput"><span class="identifier">Context</span></code> the
second argument. This is done for uniformity with Semantic Actions).
</p>
-<a name="spirit.qi.reference.basics.character_encoding_namespace"></a><h5>
-<a name="id457456"></a>
- <a href="basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+<a name="spirit.qi.reference.basics.character_encoding_namespace"></a><h6>
+<a name="id1146605"></a>
+ <a class="link" href="basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>
- </h5>
+ </h6>
<p>
- Some parsers need to know which character set a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt> is operating on.
- For example, the <tt class="computeroutput"><span class="identifier">alnum</span></tt>
+ Some parsers need to know which character set a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code> is operating on.
+ For example, the <code class="computeroutput"><span class="identifier">alnum</span></code>
parser works differently with ISO8859.1 and ASCII encodings. Where necessary,
Spirit encodes (tags) the parser with the character set.
</p>
<p>
We have a namespace for each character set Spirit will be supporting. That
- includes <tt class="computeroutput"><span class="identifier">ascii</span></tt>, <tt class="computeroutput"><span class="identifier">iso8859_1</span></tt>, <tt class="computeroutput"><span class="identifier">standard</span></tt>
- and <tt class="computeroutput"><span class="identifier">standard_wide</span></tt> (and
- in the future, <tt class="computeroutput"><span class="identifier">unicode</span></tt>).
+ includes <code class="computeroutput"><span class="identifier">ascii</span></code>, <code class="computeroutput"><span class="identifier">iso8859_1</span></code>, <code class="computeroutput"><span class="identifier">standard</span></code>
+ and <code class="computeroutput"><span class="identifier">standard_wide</span></code> (and
+ in the future, <code class="computeroutput"><span class="identifier">unicode</span></code>).
In each of the character encoding namespaces, we place tagged versions
- of parsers such as <tt class="computeroutput"><span class="identifier">alnum</span></tt>,
- <tt class="computeroutput"><span class="identifier">space</span></tt> etc.
+ of parsers such as <code class="computeroutput"><span class="identifier">alnum</span></code>,
+ <code class="computeroutput"><span class="identifier">space</span></code> etc.
</p>
<p>
Example:
@@ -82,17 +79,17 @@
<p>
Namespaces:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
boost::spirit::ascii
</li>
-<li>
+<li class="listitem">
boost::spirit::iso8859_1
</li>
-<li>
+<li class="listitem">
boost::spirit::standard
</li>
-<li>
+<li class="listitem">
boost::spirit::standard_wide
</li>
</ul></div>
@@ -100,24 +97,24 @@
For ease of use, the components in this namespaces are also brought into
the qi sub-namespaces with the same names:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
boost::spirit::qi::ascii
</li>
-<li>
+<li class="listitem">
boost::spirit::qi::iso8859_1
</li>
-<li>
+<li class="listitem">
boost::spirit::qi::standard
</li>
-<li>
+<li class="listitem">
boost::spirit::qi::standard_wide
</li>
</ul></div>
-<a name="spirit.qi.reference.basics.examples"></a><h5>
-<a name="id457731"></a>
- Examples
- </h5>
+<a name="spirit.qi.reference.basics.examples"></a><h6>
+<a name="id1148496"></a>
+ <a class="link" href="basics.html#spirit.qi.reference.basics.examples">Examples</a>
+ </h6>
<p>
All sections in the reference present some real world examples. The examples
use a common test harness to keep the example code as minimal and direct
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/char.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/char.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/char.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Char</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="auxiliary/attr.html" title="attr">
+<link rel="prev" href="auxiliary/attr.html" title="attr">
<link rel="next" href="char/lit_char_.html" title="lit/char_">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,33 +22,30 @@
<div class="spirit-nav">
<a accesskey="p" href="auxiliary/attr.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="char/lit_char_.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.char"></a>Char
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Char">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.char"></a><a class="link" href="char.html" title="Char">Char</a>
+</h4></div></div></div>
<div class="toc"><dl><dt><span class="section">lit/char_</span></dt></dl></div>
<p>
This module includes parsers for single characters. Currently, this module
- includes literal chars (e.g. <tt class="computeroutput"><span class="char">'x'</span></tt>,
- <tt class="computeroutput"><span class="identifier">L</span><span class="char">'x'</span></tt>),
- <tt class="computeroutput"><span class="identifier">char_</span></tt> (single characters,
+ includes literal chars (e.g. <code class="computeroutput"><span class="char">'x'</span></code>,
+ <code class="computeroutput"><span class="identifier">L</span><span class="char">'x'</span></code>),
+ <code class="computeroutput"><span class="identifier">char_</span></code> (single characters,
ranges and character sets) and the encoding specific character classifiers
- (<tt class="computeroutput"><span class="identifier">alnum</span></tt>, <tt class="computeroutput"><span class="identifier">alpha</span></tt>,
- <tt class="computeroutput"><span class="identifier">digit</span></tt>, <tt class="computeroutput"><span class="identifier">xdigit</span></tt>,
+ (<code class="computeroutput"><span class="identifier">alnum</span></code>, <code class="computeroutput"><span class="identifier">alpha</span></code>,
+ <code class="computeroutput"><span class="identifier">digit</span></code>, <code class="computeroutput"><span class="identifier">xdigit</span></code>,
etc.).
</p>
-<a name="spirit.qi.reference.char.module_header"></a><h5>
-<a name="id460771"></a>
- Module Header
- </h5>
+<a name="spirit.qi.reference.char.module_header"></a><h6>
+<a name="id1150752"></a>
+ <a class="link" href="char.html#spirit.qi.reference.char.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/char.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_char</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/char/lit_char_.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/char/lit_char_.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/char/lit_char_.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>lit/char_</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../char.html" title="Char">
-<link rel="previous" href="../char.html" title="Char">
-<link rel="next" href="../directive.html" title=" Directive">
+<link rel="prev" href="../char.html" title="Char">
+<link rel="next" href="../directive.html" title="Directive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,78 +22,87 @@
<div class="spirit-nav">
<a accesskey="p" href="../char.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../char.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../directive.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.char.lit_char_"></a>lit/char_
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="lit/char_">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.char.lit_char_"></a><a class="link" href="lit_char_.html" title="lit/char_">lit/char_</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lit</span></tt>
- </p></td>
-<td><p>
- Char parser (Same as <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">lit</span></tt>)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">NS</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
- Char parser for the character encoding. <tt class="computeroutput"><span class="identifier">NS</span></tt>
- is a <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Char parser (Same as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">lit</span></code>)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">NS</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Char parser for the character encoding. <code class="computeroutput"><span class="identifier">NS</span></code>
+ is a <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.char.lit_char_.description"></a><h6>
-<a name="id461091"></a>
- Description
+<a name="id1150981"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">char_</span></tt> parser matches
- a single characters. The <tt class="computeroutput"><span class="identifier">char_</span></tt>
- parser has an associated <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ The <code class="computeroutput"><span class="identifier">char_</span></code> parser matches
+ a single characters. The <code class="computeroutput"><span class="identifier">char_</span></code>
+ parser has an associated <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>. This is needed when doing basic operations
such as inhibiting case sensitivity and dealing with character ranges.
</p>
<p>
- There are various forms of <tt class="computeroutput"><span class="identifier">char_</span></tt>.
+ There are various forms of <code class="computeroutput"><span class="identifier">char_</span></code>.
</p>
<a name="spirit.qi.reference.char.lit_char_.char_"></a><h6>
-<a name="id461173"></a>
- char_
+<a name="id1151028"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.char_">char_</a>
</h6>
<p>
- The no argument form of <tt class="computeroutput"><span class="identifier">char_</span></tt>
- matches any character in the assocaiated <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ The no argument form of <code class="computeroutput"><span class="identifier">char_</span></code>
+ matches any character in the assocaiated <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p>
<pre class="programlisting"><span class="identifier">char_</span> <span class="comment">// matches any character
</span></pre>
<a name="spirit.qi.reference.char.lit_char_._code__phrase_role__identifier__char___phrase__phrase_role__special_____phrase__phrase_role__identifier__ch__phrase__phrase_role__special_____phrase___code_"></a><h6>
-<a name="id461248"></a>
- char_(ch)
+<a name="id1151069"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_._code__phrase_role__identifier__char___phrase__phrase_role__special_____phrase__phrase_role__identifier__ch__phrase__phrase_role__special_____phrase___code_"><code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ch</span><span class="special">)</span></code></a>
</h6>
<p>
- The single argument form of <tt class="computeroutput"><span class="identifier">char_</span></tt>
+ The single argument form of <code class="computeroutput"><span class="identifier">char_</span></code>
(with a character argument) matches the supplied character.
</p>
<pre class="programlisting"><span class="identifier">char_</span><span class="special">(</span><span class="char">'x'</span><span class="special">)</span> <span class="comment">// matches `x`
@@ -101,12 +110,12 @@
</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">x</span><span class="special">)</span> <span class="comment">// matches `x` (a char)
</span></pre>
<a name="spirit.qi.reference.char.lit_char_.char__first__last_"></a><h6>
-<a name="id461408"></a>
- <a href="lit_char_.html#spirit.qi.reference.char.lit_char_.char__first__last_">char_(first,
+<a name="id1151173"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.char__first__last_">char_(first,
last)</a>
</h6>
<p>
- <tt class="computeroutput"><span class="identifier">char_</span></tt> with two arguments,
+ <code class="computeroutput"><span class="identifier">char_</span></code> with two arguments,
matches a range of characters.
</p>
<pre class="programlisting"><span class="identifier">char_</span><span class="special">(</span><span class="char">'a'</span><span class="special">,</span><span class="char">'z'</span><span class="special">)</span> <span class="comment">// alphabetic characters
@@ -116,36 +125,36 @@
A range of characters is created from a low-high character pair. Such
a parser matches a single character that is in the range, including both
endpoints. Note, the first character must be <span class="emphasis"><em>before</em></span>
- the second, according to the underlying <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ the second, according to the underlying <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p>
<p>
Character mapping is inherently platform dependent. It is not guaranteed
- in the standard for example that <tt class="computeroutput"><span class="char">'A'</span>
- <span class="special"><</span> <span class="char">'Z'</span></tt>,
- that is why in Spirit2, we purposely attach a specific <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a> (such as ASCII, ISO-8859-1) to the <tt class="computeroutput"><span class="identifier">char_</span></tt> parser to eliminate such ambiguities.
+ in the standard for example that <code class="computeroutput"><span class="char">'A'</span>
+ <span class="special"><</span> <span class="char">'Z'</span></code>,
+ that is why in Spirit2, we purposely attach a specific <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a> (such as ASCII, ISO-8859-1) to the <code class="computeroutput"><span class="identifier">char_</span></code> parser to eliminate such ambiguities.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- <span class="bold"><b>Sparse bit vectors</b></span>
+ <span class="bold"><strong>Sparse bit vectors</strong></span>
</p>
<p>
To accomodate 16/32 and 64 bit characters, the char-set statically
- switches from a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">bitset</span></tt>
+ switches from a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">bitset</span></code>
implementation when the character type is not greater than 8 bits,
to a sparse bit/boolean set which uses a sorted vector of disjoint
- ranges (<tt class="computeroutput"><span class="identifier">range_run</span></tt>).
+ ranges (<code class="computeroutput"><span class="identifier">range_run</span></code>).
The set is constructed from ranges such that adjacent or overlapping
ranges are coalesced.
</p>
<p>
- <tt class="computeroutput"><span class="identifier">range_runs</span></tt> are very
+ <code class="computeroutput"><span class="identifier">range_runs</span></code> are very
space-economical in situations where there are lots of ranges and a
few individual disjoint values. Searching is O(log n) where n is the
number of ranges.
@@ -153,11 +162,11 @@
</td></tr>
</table></div>
<a name="spirit.qi.reference.char.lit_char_.char__def_"></a><h6>
-<a name="id461688"></a>
- char_(def)
+<a name="id1151353"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.char__def_">char_(def)</a>
</h6>
<p>
- Lastly, when given a string (a plain C string, a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>,
+ Lastly, when given a string (a plain C string, a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>,
etc.), the string is regarded as a char-set definition string following
a syntax that resembles posix style regular expression character sets
(except that double quotes delimit the set elements instead of square
@@ -169,29 +178,29 @@
</span><span class="identifier">char_</span><span class="special">(</span><span class="string">"\x7f\x7e"</span><span class="special">)</span> <span class="comment">// Hexadecimal 0x7F and 0x7E
</span></pre>
<a name="spirit.qi.reference.char.lit_char_.lit_ch_"></a><h6>
-<a name="id461851"></a>
- lit(ch)
+<a name="id1151466"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.lit_ch_">lit(ch)</a>
</h6>
<p>
- <tt class="computeroutput"><span class="identifier">lit</span></tt>, when passed a single
- character, behaves like the single argument <tt class="computeroutput"><span class="identifier">char_</span></tt>
- except that <tt class="computeroutput"><span class="identifier">lit</span></tt> does
- not synthesize an attribute. A plain <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt> is equivalent
- to a <tt class="computeroutput"><span class="identifier">lit</span></tt>.
+ <code class="computeroutput"><span class="identifier">lit</span></code>, when passed a single
+ character, behaves like the single argument <code class="computeroutput"><span class="identifier">char_</span></code>
+ except that <code class="computeroutput"><span class="identifier">lit</span></code> does
+ not synthesize an attribute. A plain <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code> is equivalent
+ to a <code class="computeroutput"><span class="identifier">lit</span></code>.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- <tt class="computeroutput"><span class="identifier">lit</span></tt> is reused by both
- the string parsers
+<tr><td align="left" valign="top"><p>
+ <code class="computeroutput"><span class="identifier">lit</span></code> is reused by both
+ the <a class="link" href="../string/lit_string.html" title="lit/string">string parsers</a>
and the char parsers. In general, a char parser is created when you
pass in a character and a string parser is created when you pass in
a string. The exception is when you pass a single element literal string,
- e.g. <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"x"</span><span class="special">)</span></tt>.
+ e.g. <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"x"</span><span class="special">)</span></code>.
In this case, we optimize this to create a char parser instead of a
string parser.
</p></td></tr>
@@ -205,82 +214,82 @@
<span class="identifier">lit</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span> <span class="comment">// c is a char
</span></pre>
<a name="spirit.qi.reference.char.lit_char_.header"></a><h6>
-<a name="id462101"></a>
- Header
+<a name="id1151629"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/char/char.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">qi_char</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.qi.reference.char.lit_char_.model_of"></a><h6>
-<a name="id462205"></a>
- Model of
+<a name="id1151696"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveParser
+ <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">c</span></tt>,
- <tt class="computeroutput"><span class="identifier">f</span></tt>, <tt class="computeroutput"><span class="identifier">l</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">c</span></code>,
+ <code class="computeroutput"><span class="identifier">f</span></code>, <code class="computeroutput"><span class="identifier">l</span></code></span></dt>
<dd><p>
- A literal char, e.g. <tt class="computeroutput"><span class="char">'x'</span></tt>,
- <tt class="computeroutput"><span class="identifier">L</span><span class="char">'x'</span></tt>
- or anything that can be converted to a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>.
+ A literal char, e.g. <code class="computeroutput"><span class="char">'x'</span></code>,
+ <code class="computeroutput"><span class="identifier">L</span><span class="char">'x'</span></code>
+ or anything that can be converted to a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fc</span></tt>,
- <tt class="computeroutput"><span class="identifier">ff</span></tt>, <tt class="computeroutput"><span class="identifier">fl</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fc</span></code>,
+ <code class="computeroutput"><span class="identifier">ff</span></code>, <code class="computeroutput"><span class="identifier">fl</span></code></span></dt>
<dd><p>
- A Lazy Argument
- that evaluates to a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>.
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy Argument</a>
+ that evaluates to a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">cs</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">cs</span></code></span></dt>
<dd><p>
A literal string, e.g. "a-zA-Z", or a pointer/reference
- to a null-terminated array of characters or a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>
+ to a null-terminated array of characters or a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>
that specifies a char-set definition string following a syntax that
resembles posix style regular expression character sets (without
- the square brackets and the negation <tt class="computeroutput"><span class="special">^</span></tt>
+ the square brackets and the negation <code class="computeroutput"><span class="special">^</span></code>
character).
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fcs</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fcs</span></code></span></dt>
<dd><p>
- A Lazy Argument
- that evaluates to a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy Argument</a>
+ that evaluates to a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>
or a pointer/reference to a null-terminated array of characters that
- specifies a char-set definition string (see <tt class="computeroutput"><span class="identifier">cs</span></tt>
+ specifies a char-set definition string (see <code class="computeroutput"><span class="identifier">cs</span></code>
above).
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">cp</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">cp</span></code></span></dt>
<dd><p>
A char parser, a char range parser or a char set parser.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.char.lit_char_.expression_semantics"></a><h6>
-<a name="id462631"></a>
- <a href="lit_char_.html#spirit.qi.reference.char.lit_char_.expression_semantics">Expression
+<a name="id1151979"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveParser.
+ is not defined in <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -288,142 +297,194 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">c</span></tt>
- </p></td>
-<td><p>
- Create char parser from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char parser from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
- Create a char parser that matches any character in the <tt class="computeroutput"><span class="identifier">ns</span></tt> encoding.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char parser with <tt class="computeroutput"><span class="identifier">ns</span></tt>
- encoding from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span>
- <span class="identifier">l</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">c</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create char parser from a char, <code class="computeroutput"><span class="identifier">c</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser from a char, <code class="computeroutput"><span class="identifier">c</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser that matches any character in the <code class="computeroutput"><span class="identifier">ns</span></code> encoding.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser with <code class="computeroutput"><span class="identifier">ns</span></code>
+ encoding from a char, <code class="computeroutput"><span class="identifier">c</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span>
+ <span class="identifier">l</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Create a char-range parser that matches characters from range
- (<tt class="computeroutput"><span class="identifier">f</span></tt> to <tt class="computeroutput"><span class="identifier">l</span></tt>, inclusive) with <tt class="computeroutput"><span class="identifier">ns</span></tt> encoding.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">cs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char-set parser with <tt class="computeroutput"><span class="identifier">ns</span></tt>
- encoding from a char-set definition string, <tt class="computeroutput"><span class="identifier">cs</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fc</span></tt>
- </p></td>
-<td><p>
- Create a char parser from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fc</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+ (<code class="computeroutput"><span class="identifier">f</span></code> to <code class="computeroutput"><span class="identifier">l</span></code>, inclusive) with <code class="computeroutput"><span class="identifier">ns</span></code> encoding.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">cs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char-set parser with <code class="computeroutput"><span class="identifier">ns</span></code>
+ encoding from a char-set definition string, <code class="computeroutput"><span class="identifier">cs</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fc</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser from a char, <code class="computeroutput"><span class="identifier">c</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fc</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char parser from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fc</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser from a char, <code class="computeroutput"><span class="identifier">c</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fc</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char parser from a char, <tt class="computeroutput"><span class="identifier">c</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fc</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char parser from a char, <code class="computeroutput"><span class="identifier">c</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fc</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ff</span><span class="special">,</span>
- <span class="identifier">fl</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ff</span><span class="special">,</span>
+ <span class="identifier">fl</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Create a char-range parser that matches characters from range
- (<tt class="computeroutput"><span class="identifier">f</span></tt> to <tt class="computeroutput"><span class="identifier">l</span></tt>, inclusive), returned by
- invoking <tt class="computeroutput"><span class="identifier">ff</span></tt> and
- <tt class="computeroutput"><span class="identifier">fl</span></tt>, respectively,
- with <tt class="computeroutput"><span class="identifier">ns</span></tt> encoding.
- See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+ (<code class="computeroutput"><span class="identifier">f</span></code> to <code class="computeroutput"><span class="identifier">l</span></code>, inclusive), returned by
+ invoking <code class="computeroutput"><span class="identifier">ff</span></code> and
+ <code class="computeroutput"><span class="identifier">fl</span></code>, respectively,
+ with <code class="computeroutput"><span class="identifier">ns</span></code> encoding.
+ See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fcs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a char-set parser with <tt class="computeroutput"><span class="identifier">ns</span></tt>
- encoding from a char-set definition string, <tt class="computeroutput"><span class="identifier">cs</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fcs</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fcs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a char-set parser with <code class="computeroutput"><span class="identifier">ns</span></code>
+ encoding from a char-set definition string, <code class="computeroutput"><span class="identifier">cs</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fcs</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">~</span><span class="identifier">cp</span></tt>
- </p></td>
-<td><p>
- Negate <tt class="computeroutput"><span class="identifier">cp</span></tt>. The
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">~</span><span class="identifier">cp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Negate <code class="computeroutput"><span class="identifier">cp</span></code>. The
result is a negated char parser that matches any character in
- the <tt class="computeroutput"><span class="identifier">ns</span></tt> encoding
- except the characters matched by <tt class="computeroutput"><span class="identifier">cp</span></tt>.
- </p></td>
+ the <code class="computeroutput"><span class="identifier">ns</span></code> encoding
+ except the characters matched by <code class="computeroutput"><span class="identifier">cp</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.char.lit_char_.attributes"></a><h6>
-<a name="id463653"></a>
- Attributes
+<a name="id1152704"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -431,146 +492,198 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">c</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span>
- <span class="identifier">l</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">cs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fc</span></tt>
- </p></td>
-<td><p>
- The character type of <tt class="computeroutput"><span class="identifier">c</span></tt>,
- where <tt class="computeroutput"><span class="identifier">c</span></tt> is returned
- by invoking <tt class="computeroutput"><span class="identifier">fc</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">c</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">c</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span>
+ <span class="identifier">l</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">cs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fc</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of <code class="computeroutput"><span class="identifier">c</span></code>,
+ where <code class="computeroutput"><span class="identifier">c</span></code> is returned
+ by invoking <code class="computeroutput"><span class="identifier">fc</span></code>
at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of <tt class="computeroutput"><span class="identifier">c</span></tt>,
- where <tt class="computeroutput"><span class="identifier">c</span></tt> is returned
- by invoking <tt class="computeroutput"><span class="identifier">fc</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of <code class="computeroutput"><span class="identifier">c</span></code>,
+ where <code class="computeroutput"><span class="identifier">c</span></code> is returned
+ by invoking <code class="computeroutput"><span class="identifier">fc</span></code>
at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ff</span><span class="special">,</span>
- <span class="identifier">fl</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fcs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- The character type of the <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
- Encoding Namespace</a>, <tt class="computeroutput"><span class="identifier">ns</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="special">~</span><span class="identifier">cp</span></tt>
- </p></td>
-<td><p>
- The attribute of <tt class="computeroutput"><span class="identifier">cp</span></tt>.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fc</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">ff</span><span class="special">,</span>
+ <span class="identifier">fl</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">char_</span><span class="special">(</span><span class="identifier">fcs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The character type of the <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ Encoding Namespace</a>, <code class="computeroutput"><span class="identifier">ns</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="special">~</span><span class="identifier">cp</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The attribute of <code class="computeroutput"><span class="identifier">cp</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.char.lit_char_.complexity"></a><h6>
-<a name="id464532"></a>
- Complexity
+<a name="id1155237"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- <span class="bold"><b>O(N)</b></span>, except for char-sets with
- 16-bit (or more) characters (e.g. <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>).
- These have <span class="bold"><b>O(log N)</b></span> complexity,
+ <span class="bold"><strong>O(N)</strong></span>, except for char-sets with
+ 16-bit (or more) characters (e.g. <code class="computeroutput"><span class="keyword">wchar_t</span></code>).
+ These have <span class="bold"><strong>O(log N)</strong></span> complexity,
where N is the number of distinct character ranges in the set.
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.qi.reference.char.lit_char_.example"></a><h6>
-<a name="id464594"></a>
- Example
+<a name="id1155278"></a>
+ <a class="link" href="lit_char_.html#spirit.qi.reference.char.lit_char_.example">Example</a>
</h6>
<p>
Some using declarations:
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/directive.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/directive.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/directive.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Directive</title>
+<title>Directive</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="char/lit_char_.html" title="lit/char_">
-<link rel="next" href="directive/no_case.html" title=" no_case">
+<link rel="prev" href="char/lit_char_.html" title="lit/char_">
+<link rel="next" href="directive/no_case.html" title="no_case">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,29 +22,26 @@
<div class="spirit-nav">
<a accesskey="p" href="char/lit_char_.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="directive/no_case.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.directive"></a> Directive
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Directive">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.directive"></a><a class="link" href="directive.html" title="Directive"> Directive</a>
+</h4></div></div></div>
<div class="toc"><dl><dt><span class="section"> no_case</span></dt></dl></div>
<p>
This module includes different directives usable to augment and parametrize
- other parsers. It includes the <tt class="computeroutput"><span class="identifier">no_case</span></tt>,
- <tt class="computeroutput"><span class="identifier">lexeme</span></tt>, <tt class="computeroutput"><span class="identifier">omit</span></tt>,
- <tt class="computeroutput"><span class="identifier">raw</span></tt>, and <tt class="computeroutput"><span class="identifier">skip</span></tt> directives.
+ other parsers. It includes the <code class="computeroutput"><span class="identifier">no_case</span></code>,
+ <code class="computeroutput"><span class="identifier">lexeme</span></code>, <code class="computeroutput"><span class="identifier">omit</span></code>,
+ <code class="computeroutput"><span class="identifier">raw</span></code>, and <code class="computeroutput"><span class="identifier">skip</span></code> directives.
</p>
-<a name="spirit.qi.reference.directive.module_header"></a><h5>
-<a name="id465532"></a>
- Module Header
- </h5>
+<a name="spirit.qi.reference.directive.module_header"></a><h6>
+<a name="id1155962"></a>
+ <a class="link" href="directive.html#spirit.qi.reference.directive.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/directive.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_directive</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/directive/no_case.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/directive/no_case.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/directive/no_case.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,12 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> no_case</title>
+<title>no_case</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
-<link rel="up" href="../directive.html" title=" Directive">
-<link rel="previous" href="../directive.html" title=" Directive">
+<link rel="up" href="../directive.html" title="Directive">
+<link rel="prev" href="../directive.html" title="Directive">
<link rel="next" href="../string.html" title="String">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,88 +22,93 @@
<div class="spirit-nav">
<a accesskey="p" href="../directive.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../directive.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../string.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.directive.no_case"></a> no_case
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="no_case">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.directive.no_case"></a><a class="link" href="no_case.html" title="no_case"> no_case</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">NS</span><span class="special">::</span><span class="identifier">no_case</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">NS</span><span class="special">::</span><span class="identifier">no_case</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Parser directive that forces its subject parser (and all its
- children) to do case insensitive matching. <tt class="computeroutput"><span class="identifier">NS</span></tt>
- is a <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ children) to do case insensitive matching. <code class="computeroutput"><span class="identifier">NS</span></code>
+ is a <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.directive.no_case.description"></a><h6>
-<a name="id465782"></a>
- Description
+<a name="id1156137"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></tt>
+ The <code class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></code>
directive does not consume any input. The actual matching is done by
its subject parser. It's purpose is to force matching of the subject
parser (and all its children) to be case insensitive.
</p>
<a name="spirit.qi.reference.directive.no_case.header"></a><h6>
-<a name="id465832"></a>
- Header
+<a name="id1156165"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/directive/no_case.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_no_case</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.qi.reference.directive.no_case.model_of"></a><h6>
-<a name="id465945"></a>
- <a href="no_case.html#spirit.qi.reference.directive.no_case.model_of">Model
+<a name="id1156239"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.model_of">Model
of</a>
</h6>
<p>
- The model of <tt class="computeroutput"><span class="identifier">no_case</span></tt>
+ The model of <code class="computeroutput"><span class="identifier">no_case</span></code>
is the model of its subject parser.
</p>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A parser.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
A Parser type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.directive.no_case.expression_semantics"></a><h6>
-<a name="id466070"></a>
- <a href="no_case.html#spirit.qi.reference.directive.no_case.expression_semantics">Expression
+<a name="id1156333"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.expression_semantics">Expression
Semantics</a>
</h6>
<p>
@@ -116,26 +121,34 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">p</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- Force matching of the subject parser, <tt class="computeroutput"><span class="identifier">p</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">p</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Force matching of the subject parser, <code class="computeroutput"><span class="identifier">p</span></code>
(and all its children) to be case insensitive
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.directive.no_case.attributes"></a><h6>
-<a name="id466205"></a>
- Attributes
+<a name="id1156436"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -143,39 +156,47 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">p</span><span class="special">]</span></tt>
- </p></td>
-<td><p>
- The attribute of subject parser, <tt class="computeroutput"><span class="identifier">P</span></tt>.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">p</span><span class="special">]</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The attribute of subject parser, <code class="computeroutput"><span class="identifier">P</span></code>.
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.directive.no_case.complexity"></a><h6>
-<a name="id466332"></a>
- Complexity
+<a name="id1156532"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
The complexity is defined by the complexity of the subject parser,
- <tt class="computeroutput"><span class="identifier">P</span></tt>
+ <code class="computeroutput"><span class="identifier">P</span></code>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.qi.reference.directive.no_case.example"></a><h6>
-<a name="id466381"></a>
- Example
+<a name="id1156563"></a>
+ <a class="link" href="no_case.html#spirit.qi.reference.directive.no_case.example">Example</a>
</h6>
<p>
Some using declarations:
@@ -196,7 +217,7 @@
<p>
</p>
<p>
- Simple usage of <tt class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></tt>:
+ Simple usage of <code class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></code>:
</p>
<p>
</p>
@@ -211,8 +232,8 @@
<p>
</p>
<p>
- A more sophisticated use case of <tt class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></tt> in conjunction with a symbol table
- (see symbols<Ch, T>
+ A more sophisticated use case of <code class="computeroutput"><span class="identifier">no_case</span><span class="special">[]</span></code> in conjunction with a symbol table
+ (see <a class="link" href="../string/symbols.html" title="symbols"><code class="computeroutput"><span class="identifier">symbols</span><span class="special"><</span><span class="identifier">Ch</span><span class="special">,</span> <span class="identifier">T</span><span class="special">></span></code></a>
for more details):
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Parser Concepts</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="../reference.html" title="Reference">
+<link rel="prev" href="../reference.html" title="Reference">
<link rel="next" href="parser_concepts/parser.html" title="Parser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../reference.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="parser_concepts/parser.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.parser_concepts"></a>Parser Concepts
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Parser Concepts">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.parser_concepts"></a><a class="link" href="parser_concepts.html" title="Parser Concepts">Parser Concepts</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Parser</span></dt>
<dt><span class="section">PrimitiveParser</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/binaryparser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/binaryparser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/binaryparser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>BinaryParser</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../parser_concepts.html" title="Parser Concepts">
-<link rel="previous" href="unaryparser.html" title="UnaryParser">
+<link rel="prev" href="unaryparser.html" title="UnaryParser">
<link rel="next" href="naryparser.html" title="NaryParser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,57 +22,54 @@
<div class="spirit-nav">
<a accesskey="p" href="unaryparser.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="naryparser.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.parser_concepts.binaryparser"></a>BinaryParser
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="BinaryParser">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.parser_concepts.binaryparser"></a><a class="link" href="binaryparser.html" title="BinaryParser">BinaryParser</a>
+</h5></div></div></div>
<a name="spirit.qi.reference.parser_concepts.binaryparser.description"></a><h6>
-<a name="id455589"></a>
- Description
+<a name="id1145273"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>BinaryParser</em></span> is a composite parser that has a two
- subjects, <tt class="computeroutput"><span class="identifier">left</span></tt> and <tt class="computeroutput"><span class="identifier">right</span></tt>. The BinaryParser allows its
- subjects to be treated in the same way as a single instance of a Parser
+ subjects, <code class="computeroutput"><span class="identifier">left</span></code> and <code class="computeroutput"><span class="identifier">right</span></code>. The BinaryParser allows its
+ subjects to be treated in the same way as a single instance of a <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
following the Composite Design Pattern.
</p>
<a name="spirit.qi.reference.parser_concepts.binaryparser.refinement_of"></a><h6>
-<a name="id455668"></a>
- <a href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.refinement_of">Refinement
+<a name="id1145325"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Parser
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A BinaryParser.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
A BinaryParser type.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.parser_concepts.binaryparser.valid_expressions"></a><h6>
-<a name="id455776"></a>
- <a href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.valid_expressions">Valid
+<a name="id1145404"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Parser, for any BinaryParser
+ In addition to the requirements defined in <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>, for any BinaryParser
the following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -82,44 +79,62 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">left</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">left</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Left parser.
- </p></td>
-<td><p>
- Parser
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">right</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">right</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Right parser.
- </p></td>
-<td><p>
- Parser
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.binaryparser.type_expressions"></a><h6>
-<a name="id455996"></a>
- <a href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.type_expressions">Type
+<a name="id1145565"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -128,66 +143,82 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">left_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">left_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The left parser type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">right_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">right_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The right parser type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_binary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">P</span></tt>
- is a BinaryParser, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_binary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">P</span></code>
+ is a BinaryParser, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.binaryparser.invariants"></a><h6>
-<a name="id456262"></a>
- Invariants
+<a name="id1145766"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.invariants">Invariants</a>
</h6>
<p>
- For any BinaryParser, <tt class="computeroutput"><span class="identifier">P</span></tt>,
+ For any BinaryParser, <code class="computeroutput"><span class="identifier">P</span></code>,
the following invariants always hold:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">left_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">left_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">right_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">right_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li>
</ul></div>
<a name="spirit.qi.reference.parser_concepts.binaryparser.models"></a><h6>
-<a name="id456462"></a>
- Models
+<a name="id1145905"></a>
+ <a class="link" href="binaryparser.html#spirit.qi.reference.parser_concepts.binaryparser.models">Models</a>
</h6>
<p>
- <span class="bold"><b>FIXME</b></span> Add links to models of BinaryParser
+ <span class="bold"><strong>FIXME</strong></span> Add links to models of BinaryParser
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/naryparser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/naryparser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/naryparser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>NaryParser</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../parser_concepts.html" title="Parser Concepts">
-<link rel="previous" href="binaryparser.html" title="BinaryParser">
+<link rel="prev" href="binaryparser.html" title="BinaryParser">
<link rel="next" href="../basics.html" title="Basics">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,57 +22,54 @@
<div class="spirit-nav">
<a accesskey="p" href="binaryparser.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../basics.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.parser_concepts.naryparser"></a>NaryParser
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="NaryParser">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.parser_concepts.naryparser"></a><a class="link" href="naryparser.html" title="NaryParser">NaryParser</a>
+</h5></div></div></div>
<a name="spirit.qi.reference.parser_concepts.naryparser.description"></a><h6>
-<a name="id456516"></a>
- Description
+<a name="id1145940"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>NaryParser</em></span> is a composite parser that has one or
more subjects. The NaryParser allows its subjects to be treated in the
- same way as a single instance of a Parser following the Composite
+ same way as a single instance of a <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a> following the Composite
Design Pattern.
</p>
<a name="spirit.qi.reference.parser_concepts.naryparser.refinement_of"></a><h6>
-<a name="id456570"></a>
- <a href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.refinement_of">Refinement
+<a name="id1145976"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Parser
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A NaryParser.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
A NaryParser type.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.parser_concepts.naryparser.valid_expressions"></a><h6>
-<a name="id456677"></a>
- <a href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.valid_expressions">Valid
+<a name="id1146055"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Parser, for any NaryParser the
+ In addition to the requirements defined in <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>, for any NaryParser the
following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -82,32 +79,44 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">elements</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">elements</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The tuple of elements.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
A Fusion
- Sequence of Parser types.
- </p></td>
+ Sequence of <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a> types.
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.naryparser.type_expressions"></a><h6>
-<a name="id456842"></a>
- <a href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.type_expressions">Type
+<a name="id1146178"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -116,54 +125,66 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">elements_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">elements_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Elements tuple type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_nary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">P</span></tt>
- is a NaryParser, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_nary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">P</span></code>
+ is a NaryParser, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.naryparser.invariants"></a><h6>
-<a name="id457067"></a>
- Invariants
+<a name="id1146349"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.invariants">Invariants</a>
</h6>
<p>
- For each element, <tt class="computeroutput"><span class="identifier">E</span></tt>,
- in any NaryParser, <tt class="computeroutput"><span class="identifier">P</span></tt>,
+ For each element, <code class="computeroutput"><span class="identifier">E</span></code>,
+ in any NaryParser, <code class="computeroutput"><span class="identifier">P</span></code>,
the following invariant always holds:
</p>
-<div class="itemizedlist"><ul type="disc"><li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">E</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">E</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li></ul></div>
<a name="spirit.qi.reference.parser_concepts.naryparser.models"></a><h6>
-<a name="id457193"></a>
- Models
+<a name="id1146435"></a>
+ <a class="link" href="naryparser.html#spirit.qi.reference.parser_concepts.naryparser.models">Models</a>
</h6>
<p>
- <span class="bold"><b>FIXME</b></span> Add links to models of NaryParser
+ <span class="bold"><strong>FIXME</strong></span> Add links to models of NaryParser
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/parser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/parser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/parser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Parser</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../parser_concepts.html" title="Parser Concepts">
-<link rel="previous" href="../parser_concepts.html" title="Parser Concepts">
+<link rel="prev" href="../parser_concepts.html" title="Parser Concepts">
<link rel="next" href="primitiveparser.html" title="PrimitiveParser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,77 +22,74 @@
<div class="spirit-nav">
<a accesskey="p" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="primitiveparser.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.parser_concepts.parser"></a>Parser
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="Parser">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.parser_concepts.parser"></a><a class="link" href="parser.html" title="Parser">Parser</a>
+</h5></div></div></div>
<a name="spirit.qi.reference.parser_concepts.parser.description"></a><h6>
-<a name="id453153"></a>
- Description
+<a name="id1143475"></a>
+ <a class="link" href="parser.html#spirit.qi.reference.parser_concepts.parser.description">Description</a>
</h6>
<p>
The <span class="emphasis"><em>Parser</em></span> is the most fundamental concept. A Parser
- has a member function, <tt class="computeroutput"><span class="identifier">parse</span></tt>,
- that accepts a first-last <tt class="computeroutput"><span class="identifier">ForwardIterator</span></tt>
+ has a member function, <code class="computeroutput"><span class="identifier">parse</span></code>,
+ that accepts a first-last <code class="computeroutput"><span class="identifier">ForwardIterator</span></code>
pair and returns bool as its result. The iterators delimit the data being
- parsed. The Parser's <tt class="computeroutput"><span class="identifier">parse</span></tt>
- member function returns <tt class="computeroutput"><span class="keyword">true</span></tt>
+ parsed. The Parser's <code class="computeroutput"><span class="identifier">parse</span></code>
+ member function returns <code class="computeroutput"><span class="keyword">true</span></code>
if the parse succeeds, in which case the first iterator is advanced accordingly.
Each Parser can represent a specific pattern or algorithm, or it can
be a more complex parser formed as a composition of other Parsers.
</p>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">Parser</span></tt>.
+ A <code class="computeroutput"><span class="identifier">Parser</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">Parser</span></tt> type.
+ A <code class="computeroutput"><span class="identifier">Parser</span></code> type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Iter</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Iter</span></code></span></dt>
<dd><p>
- a <tt class="computeroutput"><span class="identifier">ForwardIterator</span></tt>
+ a <code class="computeroutput"><span class="identifier">ForwardIterator</span></code>
type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">f</span></tt>,
- <tt class="computeroutput"><span class="identifier">l</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">f</span></code>,
+ <code class="computeroutput"><span class="identifier">l</span></code></span></dt>
<dd><p>
- <tt class="computeroutput"><span class="identifier">ForwardIterator</span></tt>.
+ <code class="computeroutput"><span class="identifier">ForwardIterator</span></code>.
first/last iterator pair.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Context</span></code></span></dt>
<dd><p>
The parser's Context type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">context</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">context</span></code></span></dt>
<dd><p>
- The parser's Context, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ The parser's Context, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">skip</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">skip</span></code></span></dt>
<dd><p>
- A skip Parser, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ A skip Parser, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">attrib</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">attrib</span></code></span></dt>
<dd><p>
- A Compatible Attribute, or <tt class="computeroutput"><span class="identifier">unused</span></tt>.
+ A Compatible Attribute, or <code class="computeroutput"><span class="identifier">unused</span></code>.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.parser_concepts.parser.valid_expressions"></a><h6>
-<a name="id453528"></a>
- <a href="parser.html#spirit.qi.reference.parser_concepts.parser.valid_expressions">Valid
+<a name="id1143738"></a>
+ <a class="link" href="parser.html#spirit.qi.reference.parser_concepts.parser.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In the expressions below, the behavior of the parser, <tt class="computeroutput"><span class="identifier">p</span></tt>,
- how <tt class="computeroutput"><span class="identifier">skip</span></tt> and <tt class="computeroutput"><span class="identifier">attrib</span></tt> are handled by <tt class="computeroutput"><span class="identifier">p</span></tt>, are left unspecified in the base
- <tt class="computeroutput"><span class="identifier">Parser</span></tt> concept. These
+ In the expressions below, the behavior of the parser, <code class="computeroutput"><span class="identifier">p</span></code>,
+ how <code class="computeroutput"><span class="identifier">skip</span></code> and <code class="computeroutput"><span class="identifier">attrib</span></code> are handled by <code class="computeroutput"><span class="identifier">p</span></code>, are left unspecified in the base
+ <code class="computeroutput"><span class="identifier">Parser</span></code> concept. These
are specified in subsequent, more refined concepts and by the actual
models therof.
</p>
@@ -106,51 +103,67 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
<td>
-<p>
+ <p>
</p>
<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">p</span><span class="special">.</span><span class="identifier">parse</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span> <span class="identifier">l</span><span class="special">,</span> <span class="identifier">context</span><span class="special">,</span> <span class="identifier">skip</span><span class="special">,</span> <span class="identifier">attr</span><span class="special">)</span></pre>
<p>
</p>
-</td>
-<td><p>
- Match the input sequence starting from <tt class="computeroutput"><span class="identifier">f</span></tt>.
- Return <tt class="computeroutput"><span class="keyword">true</span></tt> if successful,
- otherwise return <tt class="computeroutput"><span class="keyword">false</span></tt>.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">bool</span></tt>
- </p></td>
+ </td>
+<td>
+ <p>
+ Match the input sequence starting from <code class="computeroutput"><span class="identifier">f</span></code>.
+ Return <code class="computeroutput"><span class="keyword">true</span></code> if successful,
+ otherwise return <code class="computeroutput"><span class="keyword">false</span></code>.
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">bool</span></code>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">what</span><span class="special">(</span><span class="identifier">context</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">what</span><span class="special">(</span><span class="identifier">context</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Get information about a Parser.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">info</span></tt>
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">info</span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.parser.type_expressions"></a><h6>
-<a name="id453891"></a>
- <a href="parser.html#spirit.qi.reference.parser_concepts.parser.type_expressions">Type
+<a name="id1144006"></a>
+ <a class="link" href="parser.html#spirit.qi.reference.parser_concepts.parser.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -159,73 +172,85 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="keyword">template</span> <span class="identifier">attribute</span><span class="special"><</span><span class="identifier">Context</span><span class="special">,</span> <span class="identifier">Iter</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="keyword">template</span> <span class="identifier">attribute</span><span class="special"><</span><span class="identifier">Context</span><span class="special">,</span> <span class="identifier">Iter</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The Parser's expected attribute.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">P</span></tt>
- is a Parser, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">P</span></code>
+ is a Parser, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.parser.postcondition"></a><h6>
-<a name="id454156"></a>
- Postcondition
+<a name="id1144204"></a>
+ <a class="link" href="parser.html#spirit.qi.reference.parser_concepts.parser.postcondition">Postcondition</a>
</h6>
<p>
- Upon return from <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">parse</span></tt> the following post conditions
+ Upon return from <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">parse</span></code> the following post conditions
should hold:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- On a successful match, <tt class="computeroutput"><span class="identifier">f</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ On a successful match, <code class="computeroutput"><span class="identifier">f</span></code>
is positioned one past the first non-matching character/token.
</li>
-<li>
- On a failed match, if a <tt class="computeroutput"><span class="identifier">skip</span></tt>
- parser is <tt class="computeroutput"><span class="identifier">unused</span></tt>,
- <tt class="computeroutput"><span class="identifier">f</span></tt> is restored to its
+<li class="listitem">
+ On a failed match, if a <code class="computeroutput"><span class="identifier">skip</span></code>
+ parser is <code class="computeroutput"><span class="identifier">unused</span></code>,
+ <code class="computeroutput"><span class="identifier">f</span></code> is restored to its
original position prior to entry.
</li>
-<li>
- On a failed match, if a <tt class="computeroutput"><span class="identifier">skip</span></tt>
- parser is not <tt class="computeroutput"><span class="identifier">unused</span></tt>,
- <tt class="computeroutput"><span class="identifier">f</span></tt> is positioned one
- past the first character/token not matching <tt class="computeroutput"><span class="identifier">skip</span></tt>.
+<li class="listitem">
+ On a failed match, if a <code class="computeroutput"><span class="identifier">skip</span></code>
+ parser is not <code class="computeroutput"><span class="identifier">unused</span></code>,
+ <code class="computeroutput"><span class="identifier">f</span></code> is positioned one
+ past the first character/token not matching <code class="computeroutput"><span class="identifier">skip</span></code>.
</li>
-<li>
- On a failed match, <tt class="computeroutput"><span class="identifier">attrib</span></tt>
+<li class="listitem">
+ On a failed match, <code class="computeroutput"><span class="identifier">attrib</span></code>
is left untouched.
</li>
-<li>
- No post-skips: trailing <tt class="computeroutput"><span class="identifier">skip</span></tt>
+<li class="listitem">
+ No post-skips: trailing <code class="computeroutput"><span class="identifier">skip</span></code>
characters/tokens will not be skipped.
</li>
</ul></div>
<a name="spirit.qi.reference.parser_concepts.parser.models"></a><h6>
-<a name="id454358"></a>
- Models
+<a name="id1144331"></a>
+ <a class="link" href="parser.html#spirit.qi.reference.parser_concepts.parser.models">Models</a>
</h6>
<p>
All parsers in Spirit.Qi are models of the <span class="emphasis"><em>Parser</em></span>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/primitiveparser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/primitiveparser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/primitiveparser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>PrimitiveParser</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../parser_concepts.html" title="Parser Concepts">
-<link rel="previous" href="parser.html" title="Parser">
+<link rel="prev" href="parser.html" title="Parser">
<link rel="next" href="unaryparser.html" title="UnaryParser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,52 +22,49 @@
<div class="spirit-nav">
<a accesskey="p" href="parser.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="unaryparser.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.parser_concepts.primitiveparser"></a>PrimitiveParser
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="PrimitiveParser">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.parser_concepts.primitiveparser"></a><a class="link" href="primitiveparser.html" title="PrimitiveParser">PrimitiveParser</a>
+</h5></div></div></div>
<a name="spirit.qi.reference.parser_concepts.primitiveparser.description"></a><h6>
-<a name="id454412"></a>
- Description
+<a name="id1144366"></a>
+ <a class="link" href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>PrimitiveParser</em></span> is the most basic building block
that the client uses to build more complex parsers.
</p>
<a name="spirit.qi.reference.parser_concepts.primitiveparser.refinement_of"></a><h6>
-<a name="id454448"></a>
- <a href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.refinement_of">Refinement
+<a name="id1144388"></a>
+ <a class="link" href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Parser
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
<a name="spirit.qi.reference.parser_concepts.primitiveparser.pre_skip"></a><h6>
-<a name="id454502"></a>
- Pre-skip
+<a name="id1144498"></a>
+ <a class="link" href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.pre_skip">Pre-skip</a>
</h6>
<p>
- Upon entry to the <tt class="computeroutput"><span class="identifier">parse</span></tt>
+ Upon entry to the <code class="computeroutput"><span class="identifier">parse</span></code>
member function, a PrimitiveParser is required to do a pre-skip. Leading
- <tt class="computeroutput"><span class="identifier">skip</span></tt> characters/tokens
+ <code class="computeroutput"><span class="identifier">skip</span></code> characters/tokens
will be skipped prior to parsing. Only PrimitiveParsers are required
to perform this pre-skip. This is typically carried out through a call
- to <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">skip_over</span></tt>:
+ to <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">skip_over</span></code>:
</p>
<pre class="programlisting"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">skip_over</span><span class="special">(</span><span class="identifier">f</span><span class="special">,</span> <span class="identifier">l</span><span class="special">,</span> <span class="identifier">skip</span><span class="special">);</span>
</pre>
<a name="spirit.qi.reference.parser_concepts.primitiveparser.type_expressions"></a><h6>
-<a name="id454641"></a>
- <a href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.type_expressions">Type
+<a name="id1144589"></a>
+ <a class="link" href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -76,32 +73,40 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_primitive_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">P</span></tt>,
- is a PrimitiveParser, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_primitive_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">P</span></code>,
+ is a PrimitiveParser, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.primitiveparser.models"></a><h6>
-<a name="id454828"></a>
- Models
+<a name="id1144726"></a>
+ <a class="link" href="primitiveparser.html#spirit.qi.reference.parser_concepts.primitiveparser.models">Models</a>
</h6>
<p>
- <span class="bold"><b>FIXME</b></span> Add links to <span class="emphasis"><em>PrimitiveParser</em></span>
+ <span class="bold"><strong>FIXME</strong></span> Add links to <span class="emphasis"><em>PrimitiveParser</em></span>
models here.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/unaryparser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/unaryparser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/parser_concepts/unaryparser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>UnaryParser</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../parser_concepts.html" title="Parser Concepts">
-<link rel="previous" href="primitiveparser.html" title="PrimitiveParser">
+<link rel="prev" href="primitiveparser.html" title="PrimitiveParser">
<link rel="next" href="binaryparser.html" title="BinaryParser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,16 +22,13 @@
<div class="spirit-nav">
<a accesskey="p" href="primitiveparser.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../parser_concepts.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="binaryparser.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.parser_concepts.unaryparser"></a>UnaryParser
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="UnaryParser">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.parser_concepts.unaryparser"></a><a class="link" href="unaryparser.html" title="UnaryParser">UnaryParser</a>
+</h5></div></div></div>
<a name="spirit.qi.reference.parser_concepts.unaryparser.description"></a><h6>
-<a name="id454887"></a>
- Description
+<a name="id1144767"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.description">Description</a>
</h6>
<p>
<span class="emphasis"><em>UnaryParser</em></span> is a composite parser that has a single
@@ -39,39 +36,39 @@
the Delegate Design Pattern.
</p>
<a name="spirit.qi.reference.parser_concepts.unaryparser.refinement_of"></a><h6>
-<a name="id454923"></a>
- <a href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.refinement_of">Refinement
+<a name="id1144792"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.refinement_of">Refinement
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- Parser
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">p</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">p</span></code></span></dt>
<dd><p>
A UnaryParser.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">P</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">P</span></code></span></dt>
<dd><p>
A UnaryParser type.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.parser_concepts.unaryparser.valid_expressions"></a><h6>
-<a name="id455030"></a>
- <a href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.valid_expressions">Valid
+<a name="id1144871"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.valid_expressions">Valid
Expressions</a>
</h6>
<p>
- In addition to the requirements defined in Parser, for any UnaryParser
+ In addition to the requirements defined in <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>, for any UnaryParser
the following must be met:
</p>
<div class="informaltable"><table class="table">
@@ -81,31 +78,43 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Return type
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody><tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">subject</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">p</span><span class="special">.</span><span class="identifier">subject</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Subject parser.
- </p></td>
-<td><p>
- Parser
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <a class="link" href="parser.html" title="Parser"><code class="computeroutput"><span class="identifier">Parser</span></code></a>
+ </p>
+ </td>
</tr></tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.unaryparser.type_expressions"></a><h6>
-<a name="id455186"></a>
- <a href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.type_expressions">Type
+<a name="id1144985"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.type_expressions">Type
Expressions</a>
</h6>
<div class="informaltable"><table class="table">
@@ -114,53 +123,65 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">subject_type</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">P</span><span class="special">::</span><span class="identifier">subject_type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The subject parser type.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_unary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></tt>
- </p></td>
-<td><p>
- Metafunction that evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
- if a certain type, <tt class="computeroutput"><span class="identifier">P</span></tt>
- is a UnaryParser, <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_unary_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">>::</span><span class="identifier">type</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Metafunction that evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
+ if a certain type, <code class="computeroutput"><span class="identifier">P</span></code>
+ is a UnaryParser, <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span></code>
otherwise (See <a href="../../../../../../../../libs/mpl/doc/refmanual/integral-constant.html" target="_top">MPL
Boolean Constant</a>).
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.parser_concepts.unaryparser.invariants"></a><h6>
-<a name="id455410"></a>
- Invariants
+<a name="id1145153"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.invariants">Invariants</a>
</h6>
<p>
- For any UnaryParser, <tt class="computeroutput"><span class="identifier">P</span></tt>,
+ For any UnaryParser, <code class="computeroutput"><span class="identifier">P</span></code>,
the following invariant always holds:
</p>
-<div class="itemizedlist"><ul type="disc"><li>
-<tt class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">subject_type</span><span class="special">>::</span><span class="identifier">type</span></tt> evaluates to <tt class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
+<code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><span class="identifier">is_parser</span><span class="special"><</span><span class="identifier">P</span><span class="special">::</span><span class="identifier">subject_type</span><span class="special">>::</span><span class="identifier">type</span></code> evaluates to <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">true_</span></code>
</li></ul></div>
<a name="spirit.qi.reference.parser_concepts.unaryparser.models"></a><h6>
-<a name="id455533"></a>
- Models
+<a name="id1145238"></a>
+ <a class="link" href="unaryparser.html#spirit.qi.reference.parser_concepts.unaryparser.models">Models</a>
</h6>
<p>
- <span class="bold"><b>FIXME</b></span> Add links to models of UnaryParser
+ <span class="bold"><strong>FIXME</strong></span> Add links to models of UnaryParser
concept
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/string.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/string.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/string.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>String</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../reference.html" title="Reference">
-<link rel="previous" href="directive/no_case.html" title=" no_case">
+<link rel="prev" href="directive/no_case.html" title="no_case">
<link rel="next" href="string/lit_string.html" title="lit/string">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="directive/no_case.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../reference.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="string/lit_string.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.reference.string"></a>String
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="String">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.reference.string"></a><a class="link" href="string.html" title="String">String</a>
+</h4></div></div></div>
<div class="toc"><dl>
<dt><span class="section">lit/string</span></dt>
<dt><span class="section">symbols</span></dt>
@@ -37,15 +34,15 @@
This module includes parsers for strings. Currently, this module includes
the literal and string parsers and the symbol table.
</p>
-<a name="spirit.qi.reference.string.module_header"></a><h5>
-<a name="id467292"></a>
- Module Header
- </h5>
+<a name="spirit.qi.reference.string.module_header"></a><h6>
+<a name="id1157298"></a>
+ <a class="link" href="string.html#spirit.qi.reference.string.module_header">Module Header</a>
+ </h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/string.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_string</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../structure/include.html" title="Include">Include Structure</a>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/string/lit_string.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/string/lit_string.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/string/lit_string.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>lit/string</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../string.html" title="String">
-<link rel="previous" href="../string.html" title="String">
+<link rel="prev" href="../string.html" title="String">
<link rel="next" href="symbols.html" title="symbols">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,56 +22,65 @@
<div class="spirit-nav">
<a accesskey="p" href="../string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../string.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="symbols.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.string.lit_string"></a>lit/string
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="lit/string">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.string.lit_string"></a><a class="link" href="lit_string.html" title="lit/string">lit/string</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lit</span></tt>
- </p></td>
-<td><p>
- String parser (Same as <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">lit</span></tt>)
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">NS</span><span class="special">::</span><span class="identifier">string</span></tt>
- </p></td>
-<td><p>
- String parser for the character encoding. <tt class="computeroutput"><span class="identifier">NS</span></tt>
- is a <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lit</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ String parser (Same as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">lit</span></code>)
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">NS</span><span class="special">::</span><span class="identifier">string</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ String parser for the character encoding. <code class="computeroutput"><span class="identifier">NS</span></code>
+ is a <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.lit_string.description"></a><h6>
-<a name="id467610"></a>
- Description
+<a name="id1157527"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.description">Description</a>
</h6>
<p>
- The <tt class="computeroutput"><span class="identifier">string</span></tt> parser matches
- a string of characters. The <tt class="computeroutput"><span class="identifier">string</span></tt>
- parser is an implicit lexeme: the <tt class="computeroutput"><span class="identifier">skip</span></tt>
- parser is not applied in between characters of the string. The <tt class="computeroutput"><span class="identifier">string</span></tt> parser has an assocaiated <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ The <code class="computeroutput"><span class="identifier">string</span></code> parser matches
+ a string of characters. The <code class="computeroutput"><span class="identifier">string</span></code>
+ parser is an implicit lexeme: the <code class="computeroutput"><span class="identifier">skip</span></code>
+ parser is not applied in between characters of the string. The <code class="computeroutput"><span class="identifier">string</span></code> parser has an assocaiated <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>. This is needed when doing basic operations
such as inhibiting case sensitivity. Examples:
</p>
@@ -80,10 +89,10 @@
<span class="identifier">string</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span> <span class="comment">// s is a std::string
</span></pre>
<p>
- <tt class="computeroutput"><span class="identifier">lit</span></tt>, like <tt class="computeroutput"><span class="identifier">string</span></tt>, also matches a string of characters.
- The main difference is that <tt class="computeroutput"><span class="identifier">lit</span></tt>
- does not synthesize an attribute. A plain string like <tt class="computeroutput"><span class="string">"hello"</span></tt>
- or a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt> is equivalent to a <tt class="computeroutput"><span class="identifier">lit</span></tt>. Examples:
+ <code class="computeroutput"><span class="identifier">lit</span></code>, like <code class="computeroutput"><span class="identifier">string</span></code>, also matches a string of characters.
+ The main difference is that <code class="computeroutput"><span class="identifier">lit</span></code>
+ does not synthesize an attribute. A plain string like <code class="computeroutput"><span class="string">"hello"</span></code>
+ or a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code> is equivalent to a <code class="computeroutput"><span class="identifier">lit</span></code>. Examples:
</p>
<pre class="programlisting"><span class="string">"Hello"</span>
<span class="identifier">lit</span><span class="special">(</span><span class="string">"Hello"</span><span class="special">)</span>
@@ -91,58 +100,58 @@
<span class="identifier">lit</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span> <span class="comment">// s is a std::string
</span></pre>
<a name="spirit.qi.reference.string.lit_string.header"></a><h6>
-<a name="id467952"></a>
- Header
+<a name="id1157753"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/string/lit.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_lit</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.qi.reference.string.lit_string.model_of"></a><h6>
-<a name="id468065"></a>
- <a href="lit_string.html#spirit.qi.reference.string.lit_string.model_of">Model
+<a name="id1157827"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.model_of">Model
of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveParser
+ <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">s</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">s</span></code></span></dt>
<dd><p>
A literal string, e.g. "Hello", or a pointer/reference
- to a null-terminated array of characters or a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>.
+ to a null-terminated array of characters or a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">fs</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">fs</span></code></span></dt>
<dd><p>
- A Lazy Argument
- that evaluates to a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy Argument</a>
+ that evaluates to a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>
or a pointer/reference to a null-terminated array of characters.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">ns</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">ns</span></code></span></dt>
<dd><p>
- A <a href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
+ A <a class="link" href="../basics.html#spirit.qi.reference.basics.character_encoding_namespace">Character
Encoding Namespace</a>.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.string.lit_string.expression_semantics"></a><h6>
-<a name="id468258"></a>
- <a href="lit_string.html#spirit.qi.reference.string.lit_string.expression_semantics">Expression
+<a name="id1157963"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveParser.
+ is not defined in <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -150,77 +159,105 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">s</span></tt>
- </p></td>
-<td><p>
- Create string parser from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a string parser from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a string parser with <tt class="computeroutput"><span class="identifier">ns</span></tt>
- encoding from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fs</span></tt>
- </p></td>
-<td><p>
- Create a string parser from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">s</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create string parser from a string, <code class="computeroutput"><span class="identifier">s</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a string parser from a string, <code class="computeroutput"><span class="identifier">s</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a string parser with <code class="computeroutput"><span class="identifier">ns</span></code>
+ encoding from a string, <code class="computeroutput"><span class="identifier">s</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fs</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a string parser from a string, <code class="computeroutput"><span class="identifier">s</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a string parser from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a string parser from a string, <code class="computeroutput"><span class="identifier">s</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Create a string parser from a string, <tt class="computeroutput"><span class="identifier">s</span></tt>,
- returned by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
- at parse time. See <a href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Create a string parser from a string, <code class="computeroutput"><span class="identifier">s</span></code>,
+ returned by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
+ at parse time. See <a class="link" href="../basics.html#spirit.qi.reference.basics.lazy_argument">Lazy
Argument</a>.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.lit_string.attributes"></a><h6>
-<a name="id468747"></a>
- Attributes
+<a name="id1158319"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.attributes">Attributes</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
@@ -228,84 +265,112 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Attribute
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">s</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the
- underlying character type of <tt class="computeroutput"><span class="identifier">s</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fs</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the
- underlying character type of <tt class="computeroutput"><span class="identifier">s</span></tt>,
- where <tt class="computeroutput"><span class="identifier">s</span></tt> is returned
- by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">s</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the
+ underlying character type of <code class="computeroutput"><span class="identifier">s</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fs</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the
+ underlying character type of <code class="computeroutput"><span class="identifier">s</span></code>,
+ where <code class="computeroutput"><span class="identifier">s</span></code> is returned
+ by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the
- underlying character type of <tt class="computeroutput"><span class="identifier">s</span></tt>,
- where <tt class="computeroutput"><span class="identifier">s</span></tt> is returned
- by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the
+ underlying character type of <code class="computeroutput"><span class="identifier">s</span></code>,
+ where <code class="computeroutput"><span class="identifier">s</span></code> is returned
+ by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></tt>
- where <tt class="computeroutput"><span class="identifier">T</span></tt> is the
- underlying character type of <tt class="computeroutput"><span class="identifier">s</span></tt>,
- where <tt class="computeroutput"><span class="identifier">s</span></tt> is returned
- by invoking <tt class="computeroutput"><span class="identifier">fs</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ns</span><span class="special">::</span><span class="identifier">string</span><span class="special">(</span><span class="identifier">fs</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
+ where <code class="computeroutput"><span class="identifier">T</span></code> is the
+ underlying character type of <code class="computeroutput"><span class="identifier">s</span></code>,
+ where <code class="computeroutput"><span class="identifier">s</span></code> is returned
+ by invoking <code class="computeroutput"><span class="identifier">fs</span></code>
at parse time.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.lit_string.complexity"></a><h6>
-<a name="id469397"></a>
- Complexity
+<a name="id1158788"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.complexity">Complexity</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
@@ -317,12 +382,12 @@
</p>
</blockquote></div>
<p>
- where <tt class="computeroutput"><span class="identifier">N</span></tt> is the number
+ where <code class="computeroutput"><span class="identifier">N</span></code> is the number
of characters in the string to be parsed.
</p>
<a name="spirit.qi.reference.string.lit_string.example"></a><h6>
-<a name="id469450"></a>
- Example
+<a name="id1158823"></a>
+ <a class="link" href="lit_string.html#spirit.qi.reference.string.lit_string.example">Example</a>
</h6>
<p>
Some using declarations:
@@ -357,7 +422,7 @@
<p>
</p>
<p>
- From a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>
+ From a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>
</p>
<p>
</p>
Modified: trunk/libs/spirit/doc/html/spirit/qi/reference/string/symbols.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/reference/string/symbols.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/reference/string/symbols.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,11 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>symbols</title>
<link rel="stylesheet" href="../../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../../index.html" title="Spirit 2.1">
<link rel="up" href="../string.html" title="String">
-<link rel="previous" href="lit_string.html" title="lit/string">
-<link rel="next" href="../../../karma.html" title=" Karma - Writing Generators">
+<link rel="prev" href="lit_string.html" title="lit/string">
+<link rel="next" href="../../../karma.html" title="Karma - Writing Generators">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,61 +22,74 @@
<div class="spirit-nav">
<a accesskey="p" href="lit_string.html"><img src="../../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../string.html"><img src="../../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../../../karma.html"><img src="../../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h5 class="title">
-<a name="spirit.qi.reference.string.symbols"></a>symbols
-</h5></div></div>
-<div></div>
-</div>
+<div class="section" title="symbols">
+<div class="titlepage"><div><div><h5 class="title">
+<a name="spirit.qi.reference.string.symbols"></a><a class="link" href="symbols.html" title="symbols">symbols</a>
+</h5></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">symbols</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">symbols</span></code>
+ </p>
+ </td>
+<td>
+ <p>
A template class for creating, managing and using symbol tables.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">tst</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">tst</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Search implementation using a Ternary State Tree (TST).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">tst_map</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span><span class="special">::</span><span class="identifier">tst_map</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Search implementation using a Hash map and TST hybrid.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.symbols.description"></a><h6>
-<a name="id470482"></a>
- Description
+<a name="id1159728"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.description">Description</a>
</h6>
<p>
- This class <tt class="computeroutput"><span class="identifier">symbols</span></tt> implements
+ This class <code class="computeroutput"><span class="identifier">symbols</span></code> implements
a symbol table: an associative container (or map) of key-value pairs
- where the keys are strings. The <tt class="computeroutput"><span class="identifier">symbols</span></tt>
+ where the keys are strings. The <code class="computeroutput"><span class="identifier">symbols</span></code>
class can work efficiently with 8, 16, 32 and even 64 bit characters.
</p>
<p>
@@ -90,25 +103,25 @@
its behavior.
</p>
<a name="spirit.qi.reference.string.symbols.header"></a><h6>
-<a name="id470551"></a>
- Header
+<a name="id1159763"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.header">Header</a>
</h6>
<pre class="programlisting"><span class="comment">// forwards to <boost/spirit/home/qi/string/symbols.hpp>
</span><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">spirit</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">qi_symbols</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
</pre>
<p>
- Also, see Include Structure.
+ Also, see <a class="link" href="../../../structure/include.html" title="Include">Include Structure</a>.
</p>
<a name="spirit.qi.reference.string.symbols.synopsis"></a><h6>
-<a name="id470665"></a>
- Synopsis
+<a name="id1159837"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.synopsis">Synopsis</a>
</h6>
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Char</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">T</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Lookup</span><span class="special">></span>
<span class="keyword">struct</span> <span class="identifier">symbols</span><span class="special">;</span>
</pre>
<a name="spirit.qi.reference.string.symbols.template_parameters"></a><h6>
-<a name="id470777"></a>
- <a href="symbols.html#spirit.qi.reference.string.symbols.template_parameters">Template
+<a name="id1159915"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.template_parameters">Template
parameters</a>
</h6>
<div class="informaltable"><table class="table">
@@ -118,123 +131,147 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Parameter
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Default
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Char</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Char</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The character type of the symbol strings.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="keyword">char</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">T</span></tt>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="keyword">char</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">T</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The data type associated with each symbol.
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Lookup</span></tt>
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">unused_type</span></code>
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Lookup</span></code>
+ </p>
+ </td>
+<td>
+ <p>
The symbol search implementation
- </p></td>
-<td><p>
- <tt class="computeroutput"><span class="identifier">tst</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span>
- <span class="identifier">T</span><span class="special">></span></tt>
- </p></td>
+ </p>
+ </td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">tst</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span>
+ <span class="identifier">T</span><span class="special">></span></code>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.symbols.model_of"></a><h6>
-<a name="id471013"></a>
- Model of
+<a name="id1160099"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.model_of">Model of</a>
</h6>
<div class="blockquote"><blockquote class="blockquote">
<p>
</p>
<p>
- PrimitiveParser
+ <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>
</p>
<p>
</p>
</blockquote></div>
-<div class="variablelist">
+<div class="variablelist" title="Notation">
<p class="title"><b>Notation</b></p>
<dl>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Sym</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Sym</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">symbols</span></tt> type.
+ A <code class="computeroutput"><span class="identifier">symbols</span></code> type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">Char</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">Char</span></code></span></dt>
<dd><p>
A character type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">T</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">T</span></code></span></dt>
<dd><p>
A data type.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">sym</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">sym</span></code></span></dt>
<dd><p>
- A <tt class="computeroutput"><span class="identifier">symbols</span></tt> object.
+ A <code class="computeroutput"><span class="identifier">symbols</span></code> object.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">sym2</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">sym2</span></code></span></dt>
<dd><p>
- Another <tt class="computeroutput"><span class="identifier">symbols</span></tt> object.
+ Another <code class="computeroutput"><span class="identifier">symbols</span></code> object.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">sseq</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">sseq</span></code></span></dt>
<dd><p>
An STL container
of strings.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">dseq</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">dseq</span></code></span></dt>
<dd><p>
An STL container
- of data with <tt class="computeroutput"><span class="identifier">value_type</span></tt>
- <tt class="computeroutput"><span class="identifier">T</span></tt>.
+ of data with <code class="computeroutput"><span class="identifier">value_type</span></code>
+ <code class="computeroutput"><span class="identifier">T</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code></span></dt>
<dd><p>
A literal string, e.g. "Hello", or a pointer/reference
- to a null-terminated array of characters or a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></tt>.
+ to a null-terminated array of characters or a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">d1</span></tt>...<tt class="computeroutput"><span class="identifier">dN</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">d1</span></code>...<code class="computeroutput"><span class="identifier">dN</span></code></span></dt>
<dd><p>
- Objects of type <tt class="computeroutput"><span class="identifier">T</span></tt>.
+ Objects of type <code class="computeroutput"><span class="identifier">T</span></code>.
</p></dd>
-<dt><span class="term"><tt class="computeroutput"><span class="identifier">f</span></tt></span></dt>
+<dt><span class="term"><code class="computeroutput"><span class="identifier">f</span></code></span></dt>
<dd><p>
A callable function or function object.
</p></dd>
</dl>
</div>
<a name="spirit.qi.reference.string.symbols.expression_semantics"></a><h6>
-<a name="id471436"></a>
- <a href="symbols.html#spirit.qi.reference.string.symbols.expression_semantics">Expression
+<a name="id1160401"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.expression_semantics">Expression
Semantics</a>
</h6>
<p>
Semantics of an expression is defined only where it differs from, or
- is not defined in PrimitiveParser.
+ is not defined in <a class="link" href="../parser_concepts/primitiveparser.html" title="PrimitiveParser"><code class="computeroutput"><span class="identifier">PrimitiveParser</span></code></a>.
</p>
<div class="informaltable"><table class="table">
<colgroup>
@@ -242,180 +279,244 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Expression
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Semantics
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Sym</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Sym</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
Construct an empty symbols.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sym</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Copy construct a symbols from <tt class="computeroutput"><span class="identifier">sym2</span></tt>
- (Another <tt class="computeroutput"><span class="identifier">symbols</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sym</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Copy construct a symbols from <code class="computeroutput"><span class="identifier">sym2</span></code>
+ (Another <code class="computeroutput"><span class="identifier">symbols</span></code>
object).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sseq</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Construct symbols from <tt class="computeroutput"><span class="identifier">sseq</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sseq</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Construct symbols from <code class="computeroutput"><span class="identifier">sseq</span></code>
(An STL container
of strings).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sseq</span><span class="special">,</span>
- <span class="identifier">dseq</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Construct symbols from <tt class="computeroutput"><span class="identifier">sseq</span></tt>
- and <tt class="computeroutput"><span class="identifier">dseq</span></tt> (An
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">Sym</span><span class="special">(</span><span class="identifier">sseq</span><span class="special">,</span>
+ <span class="identifier">dseq</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Construct symbols from <code class="computeroutput"><span class="identifier">sseq</span></code>
+ and <code class="computeroutput"><span class="identifier">dseq</span></code> (An
<a href="http://www.sgi.com/tech/stl/" target="_top">STL</a> container
of strings and an STL
- container of data with <tt class="computeroutput"><span class="identifier">value_type</span></tt>
- <tt class="computeroutput"><span class="identifier">T</span></tt>).
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span> <span class="special">=</span>
- <span class="identifier">sym</span></tt>
- </p></td>
-<td><p>
- Assign <tt class="computeroutput"><span class="identifier">sym2</span></tt> to
- <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span> <span class="special">=</span>
+ container of data with <code class="computeroutput"><span class="identifier">value_type</span></code>
+ <code class="computeroutput"><span class="identifier">T</span></code>).
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span> <span class="special">=</span>
+ <span class="identifier">sym</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Assign <code class="computeroutput"><span class="identifier">sym2</span></code> to
+ <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span> <span class="special">=</span>
<span class="identifier">s1</span><span class="special">,</span>
<span class="identifier">s2</span><span class="special">,...</span>
- <span class="identifier">sN</span></tt>
- </p></td>
-<td><p>
- Assigns one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) to <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
+ <span class="identifier">sN</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Assigns one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) to <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span> <span class="special">+=</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span> <span class="special">+=</span>
<span class="identifier">s1</span><span class="special">,</span>
<span class="identifier">s2</span><span class="special">,...</span>
- <span class="identifier">sN</span></tt>
- </p></td>
-<td><p>
- Adds one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) to <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">add</span><span class="special">(</span><span class="identifier">s1</span><span class="special">)(</span><span class="identifier">s2</span><span class="special">)...(</span><span class="identifier">sN</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Adds one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) to <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">add</span><span class="special">(</span><span class="identifier">s1</span><span class="special">,</span>
+ <span class="identifier">sN</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Adds one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) to <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">add</span><span class="special">(</span><span class="identifier">s1</span><span class="special">)(</span><span class="identifier">s2</span><span class="special">)...(</span><span class="identifier">sN</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Adds one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) to <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">add</span><span class="special">(</span><span class="identifier">s1</span><span class="special">,</span>
<span class="identifier">d1</span><span class="special">)(</span><span class="identifier">s2</span><span class="special">,</span>
<span class="identifier">d2</span><span class="special">)...(</span><span class="identifier">sN</span><span class="special">,</span>
- <span class="identifier">dN</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Adds one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) with associated data (<tt class="computeroutput"><span class="identifier">d1</span></tt>...<tt class="computeroutput"><span class="identifier">dN</span></tt>)
- to <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
+ <span class="identifier">dN</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Adds one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) with associated data (<code class="computeroutput"><span class="identifier">d1</span></code>...<code class="computeroutput"><span class="identifier">dN</span></code>)
+ to <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span> <span class="special">-=</span>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span> <span class="special">-=</span>
<span class="identifier">s1</span><span class="special">,</span>
<span class="identifier">s2</span><span class="special">,...</span>
- <span class="identifier">sN</span></tt>
- </p></td>
-<td><p>
- Remove one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) from <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">remove</span><span class="special">(</span><span class="identifier">s1</span><span class="special">)(</span><span class="identifier">s2</span><span class="special">)...(</span><span class="identifier">sN</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Remove one or more symbols (<tt class="computeroutput"><span class="identifier">s1</span></tt>...<tt class="computeroutput"><span class="identifier">sN</span></tt>) from <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">clear</span><span class="special">()</span></tt>
- </p></td>
-<td><p>
- Erase all of the symbols in <tt class="computeroutput"><span class="identifier">sym</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">at</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Returns a reference to the object associated with symbol, <tt class="computeroutput"><span class="identifier">s</span></tt>. If <tt class="computeroutput"><span class="identifier">sym</span></tt>
- does not already contain such an object, <tt class="computeroutput"><span class="identifier">at</span></tt>
- inserts the default object <tt class="computeroutput"><span class="identifier">T</span><span class="special">()</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">find</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- Returns a pointer to the object associated with symbol, <tt class="computeroutput"><span class="identifier">s</span></tt>. If <tt class="computeroutput"><span class="identifier">sym</span></tt>
- does not already contain such an object, <tt class="computeroutput"><span class="identifier">find</span></tt>
+ <span class="identifier">sN</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Remove one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) from <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">remove</span><span class="special">(</span><span class="identifier">s1</span><span class="special">)(</span><span class="identifier">s2</span><span class="special">)...(</span><span class="identifier">sN</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Remove one or more symbols (<code class="computeroutput"><span class="identifier">s1</span></code>...<code class="computeroutput"><span class="identifier">sN</span></code>) from <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">clear</span><span class="special">()</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Erase all of the symbols in <code class="computeroutput"><span class="identifier">sym</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">at</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Returns a reference to the object associated with symbol, <code class="computeroutput"><span class="identifier">s</span></code>. If <code class="computeroutput"><span class="identifier">sym</span></code>
+ does not already contain such an object, <code class="computeroutput"><span class="identifier">at</span></code>
+ inserts the default object <code class="computeroutput"><span class="identifier">T</span><span class="special">()</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">find</span><span class="special">(</span><span class="identifier">s</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Returns a pointer to the object associated with symbol, <code class="computeroutput"><span class="identifier">s</span></code>. If <code class="computeroutput"><span class="identifier">sym</span></code>
+ does not already contain such an object, <code class="computeroutput"><span class="identifier">find</span></code>
returns a null pointer.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">f</span><span class="special">)</span></tt>
- </p></td>
-<td><p>
- For each symbol in <tt class="computeroutput"><span class="identifier">sym</span></tt>,
- <tt class="computeroutput"><span class="identifier">s</span></tt>, a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">Char</span><span class="special">></span></tt>
- with associated data, <tt class="computeroutput"><span class="identifier">d</span></tt>,
- an object of type <tt class="computeroutput"><span class="identifier">T</span></tt>,
- invoke <tt class="computeroutput"><span class="identifier">f</span><span class="special">(</span><span class="identifier">s</span><span class="special">,</span>
- <span class="identifier">d</span><span class="special">)</span></tt>.
- </p></td>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">sym</span><span class="special">.</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">f</span><span class="special">)</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ For each symbol in <code class="computeroutput"><span class="identifier">sym</span></code>,
+ <code class="computeroutput"><span class="identifier">s</span></code>, a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special"><</span><span class="identifier">Char</span><span class="special">></span></code>
+ with associated data, <code class="computeroutput"><span class="identifier">d</span></code>,
+ an object of type <code class="computeroutput"><span class="identifier">T</span></code>,
+ invoke <code class="computeroutput"><span class="identifier">f</span><span class="special">(</span><span class="identifier">s</span><span class="special">,</span>
+ <span class="identifier">d</span><span class="special">)</span></code>.
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<a name="spirit.qi.reference.string.symbols.attributes"></a><h6>
-<a name="id472972"></a>
- Attributes
+<a name="id1164447"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.attributes">Attributes</a>
</h6>
<p>
- The attribute of <tt class="computeroutput"><span class="identifier">symbol</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span> <span class="identifier">T</span><span class="special">></span></tt> is <tt class="computeroutput"><span class="identifier">T</span></tt>.
+ The attribute of <code class="computeroutput"><span class="identifier">symbol</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span> <span class="identifier">T</span><span class="special">></span></code> is <code class="computeroutput"><span class="identifier">T</span></code>.
</p>
<a name="spirit.qi.reference.string.symbols.complexity"></a><h6>
-<a name="id473050"></a>
- Complexity
+<a name="id1164498"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.complexity">Complexity</a>
</h6>
<p>
The default implementation uses a Ternary Search Tree (TST) with complexity:
@@ -442,7 +543,7 @@
</p>
<p>
An alternative implementation uses a hybrid hash-map front end (for the
- first character) plus a TST: <tt class="computeroutput"><span class="identifier">tst_map</span></tt>.
+ first character) plus a TST: <code class="computeroutput"><span class="identifier">tst_map</span></code>.
This gives us a complexity of
</p>
<div class="blockquote"><blockquote class="blockquote">
@@ -457,15 +558,15 @@
<p>
This is found to be significantly faster than plain TST, albeit with
a bit more memory usage requirements (each slot in the hash-map is a
- TST node). If you require a lot of symbols to be searched, use the <tt class="computeroutput"><span class="identifier">tst_map</span></tt> implementation. This can be
- done by using <tt class="computeroutput"><span class="identifier">tst_map</span></tt>
+ TST node). If you require a lot of symbols to be searched, use the <code class="computeroutput"><span class="identifier">tst_map</span></code> implementation. This can be
+ done by using <code class="computeroutput"><span class="identifier">tst_map</span></code>
as the third template parameter to the symbols class:
</p>
<pre class="programlisting"><span class="identifier">symbols</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span> <span class="identifier">T</span><span class="special">,</span> <span class="identifier">tst_map</span><span class="special"><</span><span class="identifier">Char</span><span class="special">,</span> <span class="identifier">T</span><span class="special">></span> <span class="special">></span> <span class="identifier">sym</span><span class="special">;</span>
</pre>
<a name="spirit.qi.reference.string.symbols.example"></a><h6>
-<a name="id473261"></a>
- Example
+<a name="id1164637"></a>
+ <a class="link" href="symbols.html#spirit.qi.reference.string.symbols.example">Example</a>
</h6>
<p>
Some using declarations:
@@ -507,11 +608,11 @@
<p>
</p>
<p>
- When <tt class="computeroutput"><span class="identifier">symbols</span></tt> is used
- for case-insensitive parsing (in a no_case[a]
+ When <code class="computeroutput"><span class="identifier">symbols</span></code> is used
+ for case-insensitive parsing (in a <a class="link" href="../directive/no_case.html" title="no_case"><code class="computeroutput"><span class="identifier">no_case</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>
directive), added symbol strings should be in lowercase. Symbol strings
containing one or more uppercase characters will not match any input
- when symbols is used in a <tt class="computeroutput"><span class="identifier">no_case</span></tt>
+ when symbols is used in a <code class="computeroutput"><span class="identifier">no_case</span></code>
directive.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Tutorials</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../qi.html" title=" Qi - Writing Parsers">
-<link rel="previous" href="../qi.html" title=" Qi - Writing Parsers">
+<link rel="up" href="../qi.html" title="Qi - Writing Parsers">
+<link rel="prev" href="../qi.html" title="Qi - Writing Parsers">
<link rel="next" href="tutorials/quick_start.html" title="Quick Start">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../qi.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../qi.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="tutorials/quick_start.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.qi.tutorials"></a>Tutorials
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Tutorials">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.qi.tutorials"></a><a class="link" href="tutorials.html" title="Tutorials">Tutorials</a>
+</h3></div></div></div>
<div class="toc"><dl>
<dt><span class="section">Quick Start</span></dt>
<dt><span class="section">Warming up</span></dt>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/complex___our_first_complex_parser.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/complex___our_first_complex_parser.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/complex___our_first_complex_parser.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,15 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Complex
- - Our first complex parser</title>
+<title>Complex - Our first complex parser</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="semantic_actions.html" title="Semantic Actions">
-<link rel="next" href="sum___adding_numbers.html" title="Sum - adding
- numbers">
+<link rel="prev" href="semantic_actions.html" title="Semantic Actions">
+<link rel="next" href="sum___adding_numbers.html" title="Sum - adding numbers">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="sum___adding_numbers.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.complex___our_first_complex_parser"></a><a href="complex___our_first_complex_parser.html" title="Complex
- - Our first complex parser">Complex
+<div class="section" title="Complex - Our first complex parser">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.complex___our_first_complex_parser"></a><a class="link" href="complex___our_first_complex_parser.html" title="Complex - Our first complex parser">Complex
- Our first complex parser</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
Well, not really a complex parser, but a parser that parses complex numbers.
This time, we're using Phoenix
@@ -47,26 +41,26 @@
<p>
What's new? Well, we have:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
- Alternates: e.g. <tt class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
- <span class="identifier">b</span></tt>. Try <tt class="computeroutput"><span class="identifier">a</span></tt>
- first. If it succeeds, good. If not, try the next alternative, <tt class="computeroutput"><span class="identifier">b</span></tt>.
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
+ Alternates: e.g. <code class="computeroutput"><span class="identifier">a</span> <span class="special">|</span>
+ <span class="identifier">b</span></code>. Try <code class="computeroutput"><span class="identifier">a</span></code>
+ first. If it succeeds, good. If not, try the next alternative, <code class="computeroutput"><span class="identifier">b</span></code>.
</li>
-<li>
+<li class="listitem">
Optionals: e.g. -p. Match the parser p zero or one time.
</li>
</ol></div>
<p>
The complex parser presented above reads as:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
One or two real number in parantheses, separated by comma (the second
number is optional)
</li>
-<li>
-<span class="bold"><b>OR</b></span> a single real number.
+<li class="listitem">
+<span class="bold"><strong>OR</strong></span> a single real number.
</li>
</ul></div>
<p>
@@ -124,15 +118,15 @@
The full cpp file for this example can be found here: ../../example/qi/complex_number.cpp
</p>
<p>
- The <tt class="computeroutput"><span class="identifier">double_</span></tt> parser attaches
+ The <code class="computeroutput"><span class="identifier">double_</span></code> parser attaches
this action:
</p>
<pre class="programlisting"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special">=</span> <span class="identifier">_1</span>
</pre>
<p>
- This assigns the parsed result (actually, the attribute of <tt class="computeroutput"><span class="identifier">double_</span></tt>) to n. <tt class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></tt>
- tells Phoenix that <tt class="computeroutput"><span class="identifier">n</span></tt> is
- a mutable reference. <tt class="computeroutput"><span class="identifier">_1</span></tt>
+ This assigns the parsed result (actually, the attribute of <code class="computeroutput"><span class="identifier">double_</span></code>) to n. <code class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></code>
+ tells Phoenix that <code class="computeroutput"><span class="identifier">n</span></code> is
+ a mutable reference. <code class="computeroutput"><span class="identifier">_1</span></code>
is a Phoenix placeholder for the parsed result attribute.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/employee___parsing_into_structs.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/employee___parsing_into_structs.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/employee___parsing_into_structs.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Employee
- - Parsing into structs</title>
+<title>Employee - Parsing into structs</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="roman_numerals.html" title="Roman Numerals">
+<link rel="prev" href="roman_numerals.html" title="Roman Numerals">
<link rel="next" href="mini_xml___asts_.html" title="Mini XML - ASTs!">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="roman_numerals.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="mini_xml___asts_.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.employee___parsing_into_structs"></a><a href="employee___parsing_into_structs.html" title="Employee
- - Parsing into structs">Employee
+<div class="section" title="Employee - Parsing into structs">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.employee___parsing_into_structs"></a><a class="link" href="employee___parsing_into_structs.html" title="Employee - Parsing into structs">Employee
- Parsing into structs</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
It's a common question in the <a href="http://www.nabble.com/The-Spirit-Parser-Library-f3430.html" target="_top">Spirit
General List</a>: how do I parse and place the results into a C++ struct?
@@ -40,17 +35,17 @@
attributed, makes it even easier. The next example demonstrates some features
of Spirit2 that makes this easy. In the process, you'll learn about:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
More about attributes
</li>
-<li>
+<li class="listitem">
Auto rules
</li>
-<li>
+<li class="listitem">
Some more built-in parsers
</li>
-<li>
+<li class="listitem">
Directives
</li>
</ul></div>
@@ -158,15 +153,15 @@
<span class="keyword">struct</span> <span class="identifier">employee_parser</span> <span class="special">:</span> <span class="identifier">grammar</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">employee</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span>
</pre>
<p>
- <tt class="computeroutput"><span class="identifier">employee_parser</span></tt> is a grammar.
+ <code class="computeroutput"><span class="identifier">employee_parser</span></code> is a grammar.
Like before, we make it a template so that we can reuse it for different
iterator types. The grammar's signature is:
</p>
<pre class="programlisting"><span class="identifier">employee</span><span class="special">()</span>
</pre>
<p>
- meaning, the parser generates employee structs. <tt class="computeroutput"><span class="identifier">employee_parser</span></tt>
- skips white spaces using <tt class="computeroutput"><span class="identifier">space_type</span></tt>
+ meaning, the parser generates employee structs. <code class="computeroutput"><span class="identifier">employee_parser</span></code>
+ skips white spaces using <code class="computeroutput"><span class="identifier">space_type</span></code>
as its skip parser.
</p>
<pre class="programlisting"><span class="identifier">employee_parser</span><span class="special">()</span> <span class="special">:</span> <span class="identifier">employee_parser</span><span class="special">::</span><span class="identifier">base_type</span><span class="special">(</span><span class="identifier">start</span><span class="special">)</span>
@@ -178,19 +173,19 @@
<span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">employee</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">start</span><span class="special">;</span>
</pre>
<p>
- Declares two rules: <tt class="computeroutput"><span class="identifier">quoted_string</span></tt>
- and <tt class="computeroutput"><span class="identifier">start</span></tt>. <tt class="computeroutput"><span class="identifier">start</span></tt> has the same template parameters
- as the grammar itself. <tt class="computeroutput"><span class="identifier">quoted_string</span></tt>
- has a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt> attribute.
- </p>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.lexeme"></a><h5>
-<a name="id429124"></a>
- Lexeme
- </h5>
+ Declares two rules: <code class="computeroutput"><span class="identifier">quoted_string</span></code>
+ and <code class="computeroutput"><span class="identifier">start</span></code>. <code class="computeroutput"><span class="identifier">start</span></code> has the same template parameters
+ as the grammar itself. <code class="computeroutput"><span class="identifier">quoted_string</span></code>
+ has a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code> attribute.
+ </p>
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.lexeme"></a><h6>
+<a name="id1120363"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.lexeme">Lexeme</a>
+ </h6>
<pre class="programlisting"><span class="identifier">lexeme</span><span class="special">[</span><span class="char">'"'</span> <span class="special">>></span> <span class="special">+(</span><span class="identifier">char_</span> <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span> <span class="special">>></span> <span class="char">'"'</span><span class="special">];</span>
</pre>
<p>
- <tt class="computeroutput"><span class="identifier">lexeme</span></tt> inhibits space skipping
+ <code class="computeroutput"><span class="identifier">lexeme</span></code> inhibits space skipping
from the open brace to the closing brace. The expression parses quoted
strings.
</p>
@@ -200,35 +195,35 @@
parses one or more chars, except the double quote. It stops when it sees
a double quote.
</p>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.difference"></a><h5>
-<a name="id429280"></a>
- Difference
- </h5>
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.difference"></a><h6>
+<a name="id1120476"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.difference">Difference</a>
+ </h6>
<p>
The expression:
</p>
<pre class="programlisting"><span class="identifier">a</span> <span class="special">-</span> <span class="identifier">b</span>
</pre>
<p>
- parses <tt class="computeroutput"><span class="identifier">a</span></tt> but not <tt class="computeroutput"><span class="identifier">b</span></tt>. Its attribute is just <tt class="computeroutput"><span class="identifier">A</span></tt>, the attribute of <tt class="computeroutput"><span class="identifier">a</span></tt>.
- <tt class="computeroutput"><span class="identifier">b</span></tt>'s attribute is ignored.
+ parses <code class="computeroutput"><span class="identifier">a</span></code> but not <code class="computeroutput"><span class="identifier">b</span></code>. Its attribute is just <code class="computeroutput"><span class="identifier">A</span></code>, the attribute of <code class="computeroutput"><span class="identifier">a</span></code>.
+ <code class="computeroutput"><span class="identifier">b</span></code>'s attribute is ignored.
Hence, the attribute of:
</p>
<pre class="programlisting"><span class="identifier">char_</span> <span class="special">-</span> <span class="char">'"'</span>
</pre>
<p>
- is just <tt class="computeroutput"><span class="keyword">char</span></tt>.
+ is just <code class="computeroutput"><span class="keyword">char</span></code>.
</p>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.plus"></a><h5>
-<a name="id429438"></a>
- Plus
- </h5>
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.plus"></a><h6>
+<a name="id1120584"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.plus">Plus</a>
+ </h6>
<pre class="programlisting"><span class="special">+</span><span class="identifier">a</span>
</pre>
<p>
is the close kin of the kleene star we got so used to in our tutorial.
- Like it's kin, the kleene star, its attribute is a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></tt> where <tt class="computeroutput"><span class="identifier">A</span></tt>
- is the attribute of <tt class="computeroutput"><span class="identifier">a</span></tt>.
+ Like it's kin, the kleene star, its attribute is a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">></span></code> where <code class="computeroutput"><span class="identifier">A</span></code>
+ is the attribute of <code class="computeroutput"><span class="identifier">a</span></code>.
So, putting all these together, the attribute of
</p>
<pre class="programlisting"><span class="special">+(</span><span class="identifier">char_</span> <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span>
@@ -238,11 +233,11 @@
</p>
<pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span>
</pre>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.sequence_attribute"></a><h5>
-<a name="id429624"></a>
- <a href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.sequence_attribute">Sequence
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.sequence_attribute"></a><h6>
+<a name="id1120710"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.sequence_attribute">Sequence
Attribute</a>
- </h5>
+ </h6>
<p>
Now what's the attribute of
</p>
@@ -262,45 +257,45 @@
<pre class="programlisting"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">,</span> <span class="identifier">C</span><span class="special">></span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">A</span></tt> is the attribute
- of <tt class="computeroutput"><span class="identifier">a</span></tt>, <tt class="computeroutput"><span class="identifier">B</span></tt>
- is the attribute of <tt class="computeroutput"><span class="identifier">b</span></tt> and
- <tt class="computeroutput"><span class="identifier">C</span></tt> is the attribute of
- <tt class="computeroutput"><span class="identifier">c</span></tt>. What is <tt class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span></tt>? - a tuple.
+ where <code class="computeroutput"><span class="identifier">A</span></code> is the attribute
+ of <code class="computeroutput"><span class="identifier">a</span></code>, <code class="computeroutput"><span class="identifier">B</span></code>
+ is the attribute of <code class="computeroutput"><span class="identifier">b</span></code> and
+ <code class="computeroutput"><span class="identifier">C</span></code> is the attribute of
+ <code class="computeroutput"><span class="identifier">c</span></code>. What is <code class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span></code>? - a tuple.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
If you don't know what I am talking about, see: <a href="http://tinyurl.com/6xun4j" target="_top">Fusion
Vector</a>. It might be a good idea to have a look into Fusion
at this point. You'll definitely see more of it in the coming pages.
</p></td></tr>
</table></div>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.attribute_collapsing"></a><h5>
-<a name="id429947"></a>
- <a href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.attribute_collapsing">Attribute
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.attribute_collapsing"></a><h6>
+<a name="id1120932"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.attribute_collapsing">Attribute
Collapsing</a>
- </h5>
+ </h6>
<p>
Some parsers, especially those very little literal parsers you see, like
- <tt class="computeroutput"><span class="char">'"'</span></tt>, do not have attributes.
+ <code class="computeroutput"><span class="char">'"'</span></code>, do not have attributes.
</p>
<p>
Nodes without attributes are disregarded. In a sequence, like above, all
- nodes with no attributes are filtered out of the <tt class="computeroutput"><span class="identifier">fusion</span><span class="special">:</span><span class="identifier">vector</span></tt>.
- So, since <tt class="computeroutput"><span class="char">'"'</span></tt> has no attribute,
- and <tt class="computeroutput"><span class="special">+(</span><span class="identifier">char_</span>
- <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span></tt> has a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></tt> attribute, the whole expression's attribute
+ nodes with no attributes are filtered out of the <code class="computeroutput"><span class="identifier">fusion</span><span class="special">:</span><span class="identifier">vector</span></code>.
+ So, since <code class="computeroutput"><span class="char">'"'</span></code> has no attribute,
+ and <code class="computeroutput"><span class="special">+(</span><span class="identifier">char_</span>
+ <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span></code> has a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></code> attribute, the whole expression's attribute
should have been:
</p>
<pre class="programlisting"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span> <span class="special">></span>
</pre>
<p>
But wait, there's one more collapsing rule: If after the attribute is a
- single element <tt class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span></tt>, The element is stripped naked
+ single element <code class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span></code>, The element is stripped naked
from its container. So, to make a long story short, the attribute of the
expression:
</p>
@@ -311,11 +306,11 @@
</p>
<pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span>
</pre>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.auto_rules"></a><h5>
-<a name="id430296"></a>
- <a href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.auto_rules">Auto
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.auto_rules"></a><h6>
+<a name="id1121170"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.auto_rules">Auto
Rules</a>
- </h5>
+ </h6>
<p>
It is typical to see rules like:
</p>
@@ -329,11 +324,11 @@
<pre class="programlisting"><span class="identifier">r</span> <span class="special">%=</span> <span class="identifier">p</span><span class="special">;</span>
</pre>
<p>
- The attribute of <tt class="computeroutput"><span class="identifier">p</span></tt> automatically
- uses the attribute of <tt class="computeroutput"><span class="identifier">r</span></tt>.
+ The attribute of <code class="computeroutput"><span class="identifier">p</span></code> automatically
+ uses the attribute of <code class="computeroutput"><span class="identifier">r</span></code>.
</p>
<p>
- So, going back to our <tt class="computeroutput"><span class="identifier">quoted_string</span></tt>
+ So, going back to our <code class="computeroutput"><span class="identifier">quoted_string</span></code>
rule:
</p>
<pre class="programlisting"><span class="identifier">quoted_string</span> <span class="special">%=</span> <span class="identifier">lexeme</span><span class="special">[</span><span class="char">'"'</span> <span class="special">>></span> <span class="special">+(</span><span class="identifier">char_</span> <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span> <span class="special">>></span> <span class="char">'"'</span><span class="special">];</span>
@@ -344,15 +339,15 @@
<pre class="programlisting"><span class="identifier">quoted_string</span> <span class="special">=</span> <span class="identifier">lexeme</span><span class="special">[</span><span class="char">'"'</span> <span class="special">>></span> <span class="special">+(</span><span class="identifier">char_</span> <span class="special">-</span> <span class="char">'"'</span><span class="special">)</span> <span class="special">>></span> <span class="char">'"'</span><span class="special">][</span><span class="identifier">val_</span> <span class="special">=</span> <span class="identifier">_1</span><span class="special">];</span>
</pre>
<p>
- The attribute of the <tt class="computeroutput"><span class="identifier">quoted_string</span></tt>
- rule: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt> <span class="bold"><b>is compatible</b></span>
- with the attribute of the RHS: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></tt>. The RHS extracts the parsed attribute
+ The attribute of the <code class="computeroutput"><span class="identifier">quoted_string</span></code>
+ rule: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code> <span class="bold"><strong>is compatible</strong></span>
+ with the attribute of the RHS: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></code>. The RHS extracts the parsed attribute
directly into the rule's attribute, in-situ.
</p>
-<a name="spirit.qi.tutorials.employee___parsing_into_structs.finally"></a><h5>
-<a name="id430740"></a>
- Finally
- </h5>
+<a name="spirit.qi.tutorials.employee___parsing_into_structs.finally"></a><h6>
+<a name="id1121490"></a>
+ <a class="link" href="employee___parsing_into_structs.html#spirit.qi.tutorials.employee___parsing_into_structs.finally">Finally</a>
+ </h6>
<p>
We're down to one rule, the start rule:
</p>
@@ -374,28 +369,28 @@
<p>
These nodes do not have an attribute:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li><tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"employee"</span><span class="special">)</span></tt></li>
-<li><tt class="computeroutput"><span class="char">'{'</span></tt></li>
-<li><tt class="computeroutput"><span class="char">'}'</span></tt></li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem"><code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"employee"</span><span class="special">)</span></code></li>
+<li class="listitem"><code class="computeroutput"><span class="char">'{'</span></code></li>
+<li class="listitem"><code class="computeroutput"><span class="char">'}'</span></code></li>
</ul></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
- In case you are wondering, <tt class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"employee"</span><span class="special">)</span></tt> is the same as "employee".
- We had to wrap it inside <tt class="computeroutput"><span class="identifier">lit</span></tt>
- because immediately after it is <tt class="computeroutput"><span class="special">>></span>
- <span class="char">'{'</span></tt>. You can't right-shift a <tt class="computeroutput"><span class="keyword">char</span><span class="special">[]</span></tt>
- and a <tt class="computeroutput"><span class="keyword">char</span></tt> - you know, C++
+<tr><td align="left" valign="top"><p>
+ In case you are wondering, <code class="computeroutput"><span class="identifier">lit</span><span class="special">(</span><span class="string">"employee"</span><span class="special">)</span></code> is the same as "employee".
+ We had to wrap it inside <code class="computeroutput"><span class="identifier">lit</span></code>
+ because immediately after it is <code class="computeroutput"><span class="special">>></span>
+ <span class="char">'{'</span></code>. You can't right-shift a <code class="computeroutput"><span class="keyword">char</span><span class="special">[]</span></code>
+ and a <code class="computeroutput"><span class="keyword">char</span></code> - you know, C++
syntax rules.
</p></td></tr>
</table></div>
<p>
- Recall that the attribute of <tt class="computeroutput"><span class="identifier">start</span></tt>
- is the <tt class="computeroutput"><span class="identifier">employee</span></tt> struct:
+ Recall that the attribute of <code class="computeroutput"><span class="identifier">start</span></code>
+ is the <code class="computeroutput"><span class="identifier">employee</span></code> struct:
</p>
<p>
</p>
@@ -415,11 +410,11 @@
<p>
</p>
<p>
- Now everything is clear, right? The <tt class="computeroutput"><span class="keyword">struct</span>
- <span class="identifier">employee</span></tt> <span class="bold"><b>IS</b></span>
- compatible with <tt class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">,</span> <span class="keyword">double</span><span class="special">></span></tt>. So, the RHS of <tt class="computeroutput"><span class="identifier">start</span></tt>
- uses start's attribute (a <tt class="computeroutput"><span class="keyword">struct</span>
- <span class="identifier">employee</span></tt>) in-situ when it does
+ Now everything is clear, right? The <code class="computeroutput"><span class="keyword">struct</span>
+ <span class="identifier">employee</span></code> <span class="bold"><strong>IS</strong></span>
+ compatible with <code class="computeroutput"><span class="identifier">fusion</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">int</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">,</span> <span class="keyword">double</span><span class="special">></span></code>. So, the RHS of <code class="computeroutput"><span class="identifier">start</span></code>
+ uses start's attribute (a <code class="computeroutput"><span class="keyword">struct</span>
+ <span class="identifier">employee</span></code>) in-situ when it does
its work.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___asts_.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___asts_.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___asts_.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Mini XML - ASTs!</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="employee___parsing_into_structs.html" title="Employee
- - Parsing into structs">
-<link rel="next" href="mini_xml___error_handling.html" title="Mini
- XML - Error Handling">
+<link rel="prev" href="employee___parsing_into_structs.html" title="Employee - Parsing into structs">
+<link rel="next" href="mini_xml___error_handling.html" title="Mini XML - Error Handling">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,19 +22,16 @@
<div class="spirit-nav">
<a accesskey="p" href="employee___parsing_into_structs.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="mini_xml___error_handling.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.mini_xml___asts_"></a>Mini XML - ASTs!
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Mini XML - ASTs!">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.mini_xml___asts_"></a><a class="link" href="mini_xml___asts_.html" title="Mini XML - ASTs!">Mini XML - ASTs!</a>
+</h4></div></div></div>
<p>
Stop and think about it... We've come very close to generating an AST in
our last example. We parsed a single structure and generated an in-memory
- representation of it in the form of a struct: the <tt class="computeroutput"><span class="keyword">struct</span>
- <span class="identifier">employee</span></tt>. If we changed the implementation
- to parse one or more employees, the result would be a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">employee</span><span class="special">></span></tt>. We can go on and add more hierarchy:
+ representation of it in the form of a struct: the <code class="computeroutput"><span class="keyword">struct</span>
+ <span class="identifier">employee</span></code>. If we changed the implementation
+ to parse one or more employees, the result would be a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">employee</span><span class="special">></span></code>. We can go on and add more hierarchy:
teams, departments, corporations. Then we'll have an AST representation
of it all.
</p>
@@ -48,20 +43,20 @@
<p>
Along the way, we'll see new features:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Inherited attributes
</li>
-<li>
+<li class="listitem">
Variant attributes
</li>
-<li>
+<li class="listitem">
Local Variables
</li>
-<li>
+<li class="listitem">
Not Predicate
</li>
-<li>
+<li class="listitem">
Lazy Lit
</li>
</ul></div>
@@ -73,10 +68,10 @@
There are a couple of sample toy-xml files in: ../../example/qi/mini_xml_samples
for testing purposes. "4.toyxml" has an error in it.
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.first_cut"></a><h5>
-<a name="id431646"></a>
- First Cut
- </h5>
+<a name="spirit.qi.tutorials.mini_xml___asts_.first_cut"></a><h6>
+<a name="id1122484"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.first_cut">First Cut</a>
+ </h6>
<p>
Without further delay, here's the first version of the XML grammar:
</p>
@@ -134,7 +129,7 @@
<p>
</p>
<p>
- Going bottom up, let's examine the <tt class="computeroutput"><span class="identifier">text</span></tt>
+ Going bottom up, let's examine the <code class="computeroutput"><span class="identifier">text</span></code>
rule:
</p>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">text</span><span class="special">;</span>
@@ -146,13 +141,13 @@
</pre>
<p>
The semantic action collects the chars and appends them (via +=) to the
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt> attribute of the rule (represented
- by the placeholder <tt class="computeroutput"><span class="identifier">_val</span></tt>).
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code> attribute of the rule (represented
+ by the placeholder <code class="computeroutput"><span class="identifier">_val</span></code>).
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.alternates"></a><h5>
-<a name="id433247"></a>
- Alternates
- </h5>
+<a name="spirit.qi.tutorials.mini_xml___asts_.alternates"></a><h6>
+<a name="id1123664"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.alternates">Alternates</a>
+ </h6>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">mini_xml_node</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">node</span><span class="special">;</span>
</pre>
<p>
@@ -161,15 +156,15 @@
<pre class="programlisting"><span class="identifier">node</span> <span class="special">=</span> <span class="special">(</span><span class="identifier">xml</span> <span class="special">|</span> <span class="identifier">text</span><span class="special">)</span> <span class="special">[</span><span class="identifier">_val</span> <span class="special">=</span> <span class="identifier">_1</span><span class="special">];</span>
</pre>
<p>
- We'll see what a <tt class="computeroutput"><span class="identifier">mini_xml_node</span></tt>
+ We'll see what a <code class="computeroutput"><span class="identifier">mini_xml_node</span></code>
structure later. Looking at the rule definition, we see some alternation
- goiing on here. An xml <tt class="computeroutput"><span class="identifier">node</span></tt>
- is either an <tt class="computeroutput"><span class="identifier">xml</span></tt> OR <tt class="computeroutput"><span class="identifier">text</span></tt>. Hmmm... hold on to that thought...
+ goiing on here. An xml <code class="computeroutput"><span class="identifier">node</span></code>
+ is either an <code class="computeroutput"><span class="identifier">xml</span></code> OR <code class="computeroutput"><span class="identifier">text</span></code>. Hmmm... hold on to that thought...
</p>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">start_tag</span><span class="special">;</span>
</pre>
<p>
- Again, with an attribute of <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>.
+ Again, with an attribute of <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>.
Then, it's definition:
</p>
<pre class="programlisting"><span class="identifier">start_tag</span> <span class="special">=</span>
@@ -179,46 +174,46 @@
<span class="special">>></span> <span class="char">'>'</span>
<span class="special">;</span>
</pre>
-<a name="spirit.qi.tutorials.mini_xml___asts_.not_predicate"></a><h5>
-<a name="id433708"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.not_predicate">Not
+<a name="spirit.qi.tutorials.mini_xml___asts_.not_predicate"></a><h6>
+<a name="id1123992"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.not_predicate">Not
Predicate</a>
- </h5>
+ </h6>
<p>
- <tt class="computeroutput"><span class="identifier">start_tag</span></tt> is similar to
- the <tt class="computeroutput"><span class="identifier">text</span></tt> rule apart from
- the added <tt class="computeroutput"><span class="char">'<'</span></tt> and <tt class="computeroutput"><span class="char">'>'</span></tt>. But wait, to make sure that the <tt class="computeroutput"><span class="identifier">start_tag</span></tt> does not parse <tt class="computeroutput"><span class="identifier">end_tag</span></tt>s too, we add: <tt class="computeroutput"><span class="special">!</span><span class="identifier">char_</span><span class="special">(</span><span class="char">'/'</span><span class="special">)</span></tt>. This
+ <code class="computeroutput"><span class="identifier">start_tag</span></code> is similar to
+ the <code class="computeroutput"><span class="identifier">text</span></code> rule apart from
+ the added <code class="computeroutput"><span class="char">'<'</span></code> and <code class="computeroutput"><span class="char">'>'</span></code>. But wait, to make sure that the <code class="computeroutput"><span class="identifier">start_tag</span></code> does not parse <code class="computeroutput"><span class="identifier">end_tag</span></code>s too, we add: <code class="computeroutput"><span class="special">!</span><span class="identifier">char_</span><span class="special">(</span><span class="char">'/'</span><span class="special">)</span></code>. This
is a "Not Predicate":
</p>
<pre class="programlisting"><span class="special">!</span><span class="identifier">p</span>
</pre>
<p>
- It will try the parser, <tt class="computeroutput"><span class="identifier">p</span></tt>.
+ It will try the parser, <code class="computeroutput"><span class="identifier">p</span></code>.
If it is successful, fail, otherwise, pass. In other words, it negates
- the result of <tt class="computeroutput"><span class="identifier">p</span></tt>. Like the
- <tt class="computeroutput"><span class="identifier">eps</span></tt>, it does not consume
+ the result of <code class="computeroutput"><span class="identifier">p</span></code>. Like the
+ <code class="computeroutput"><span class="identifier">eps</span></code>, it does not consume
any input though. It will always rewind the iterator position to where
it was upon entry. So, the expression:
</p>
<pre class="programlisting"><span class="special">!</span><span class="identifier">char_</span><span class="special">(</span><span class="char">'/'</span><span class="special">)</span>
</pre>
<p>
- basically says: we should not have a <tt class="computeroutput"><span class="char">'/'</span></tt>
+ basically says: we should not have a <code class="computeroutput"><span class="char">'/'</span></code>
at this point.
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.inherited_attribute"></a><h5>
-<a name="id433949"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.inherited_attribute">Inherited
+<a name="spirit.qi.tutorials.mini_xml___asts_.inherited_attribute"></a><h6>
+<a name="id1125794"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.inherited_attribute">Inherited
Attribute</a>
- </h5>
+ </h6>
<p>
- The <tt class="computeroutput"><span class="identifier">end_tag</span></tt>:
+ The <code class="computeroutput"><span class="identifier">end_tag</span></code>:
</p>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="keyword">void</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">end_tag</span><span class="special">;</span>
</pre>
<p>
- Ohh! Now we see an inherited attribute there: <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>.
- The <tt class="computeroutput"><span class="identifier">end_tag</span></tt> does not have
+ Ohh! Now we see an inherited attribute there: <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>.
+ The <code class="computeroutput"><span class="identifier">end_tag</span></code> does not have
a synthesized attribute. Let's see its definition:
</p>
<pre class="programlisting"><span class="identifier">end_tag</span> <span class="special">=</span>
@@ -228,28 +223,28 @@
<span class="special">;</span>
</pre>
<p>
- <tt class="computeroutput"><span class="identifier">_r1</span></tt> is yet another Phoenix placeholder for
- the 1st inherited attribute (we have only one, use <tt class="computeroutput"><span class="identifier">_r2</span></tt>,
- <tt class="computeroutput"><span class="identifier">_r3</span></tt>, etc. if you have more).
- </p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.a_lazy_lit"></a><h5>
-<a name="id434229"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.a_lazy_lit">A Lazy
+ <code class="computeroutput"><span class="identifier">_r1</span></code> is yet another Phoenix placeholder for
+ the 1st inherited attribute (we have only one, use <code class="computeroutput"><span class="identifier">_r2</span></code>,
+ <code class="computeroutput"><span class="identifier">_r3</span></code>, etc. if you have more).
+ </p>
+<a name="spirit.qi.tutorials.mini_xml___asts_.a_lazy_lit"></a><h6>
+<a name="id1125988"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.a_lazy_lit">A Lazy
Lit</a>
- </h5>
+ </h6>
<p>
- Check out how we used <tt class="computeroutput"><span class="identifier">lit</span></tt>
+ Check out how we used <code class="computeroutput"><span class="identifier">lit</span></code>
here, this time, not with a literal string, but with the value of the 1st
- inherited attribute, which is specified as <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></tt>
+ inherited attribute, which is specified as <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span></code>
in our rule declaration.
</p>
<p>
- Finally, our <tt class="computeroutput"><span class="identifier">xml</span></tt> rule:
+ Finally, our <code class="computeroutput"><span class="identifier">xml</span></code> rule:
</p>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">mini_xml</span><span class="special">(),</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">xml</span><span class="special">;</span>
</pre>
<p>
- <tt class="computeroutput"><span class="identifier">mini_xml</span></tt> is our attribute
+ <code class="computeroutput"><span class="identifier">mini_xml</span></code> is our attribute
here. We'll see later what it is. Let's see its definition:
</p>
<pre class="programlisting"><span class="identifier">xml</span> <span class="special">=</span>
@@ -260,37 +255,37 @@
</pre>
<p>
Those who know Fusion
- now will notice <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">></span></tt> and
- <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">1</span><span class="special">></span></tt>. This
- gives us a hint that <tt class="computeroutput"><span class="identifier">mini_xml</span></tt>
- is a sort of a tuple - a fusion sequence. <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></tt> here is a lazy version of the tuple
+ now will notice <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">></span></code> and
+ <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">1</span><span class="special">></span></code>. This
+ gives us a hint that <code class="computeroutput"><span class="identifier">mini_xml</span></code>
+ is a sort of a tuple - a fusion sequence. <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></code> here is a lazy version of the tuple
accessors, provided by Phoenix.
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.how_it_all_works"></a><h5>
-<a name="id434709"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.how_it_all_works">How
+<a name="spirit.qi.tutorials.mini_xml___asts_.how_it_all_works"></a><h6>
+<a name="id1126320"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.how_it_all_works">How
it all works</a>
- </h5>
+ </h6>
<p>
So, what's happening?
</p>
-<div class="orderedlist"><ol type="1">
-<li>
- Upon parsing <tt class="computeroutput"><span class="identifier">start_tag</span></tt>,
- the parsed start-tag string is placed in <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></tt>.
- </li>
-<li>
- Then we parse zero or more <tt class="computeroutput"><span class="identifier">node</span></tt>s.
- At each step, we <tt class="computeroutput"><span class="identifier">push_back</span></tt>
- the result into <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">1</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></tt>.
- </li>
-<li>
- Finally, we parse the <tt class="computeroutput"><span class="identifier">end_tag</span></tt>
- giving it an inherited attribute: <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></tt>.
- This is the string we obtained from the <tt class="computeroutput"><span class="identifier">start_tag</span></tt>.
- Investigate <tt class="computeroutput"><span class="identifier">end_tag</span></tt> above.
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
+ Upon parsing <code class="computeroutput"><span class="identifier">start_tag</span></code>,
+ the parsed start-tag string is placed in <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></code>.
+ </li>
+<li class="listitem">
+ Then we parse zero or more <code class="computeroutput"><span class="identifier">node</span></code>s.
+ At each step, we <code class="computeroutput"><span class="identifier">push_back</span></code>
+ the result into <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">1</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></code>.
+ </li>
+<li class="listitem">
+ Finally, we parse the <code class="computeroutput"><span class="identifier">end_tag</span></code>
+ giving it an inherited attribute: <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></code>.
+ This is the string we obtained from the <code class="computeroutput"><span class="identifier">start_tag</span></code>.
+ Investigate <code class="computeroutput"><span class="identifier">end_tag</span></code> above.
It will fail to parse if it gets something different from what we got
- from the <tt class="computeroutput"><span class="identifier">start_tag</span></tt>. This
+ from the <code class="computeroutput"><span class="identifier">start_tag</span></code>. This
ensures that our tags are balanced.
</li>
</ol></div>
@@ -309,15 +304,15 @@
<span class="special">;</span>
</pre>
<p>
- passing in <tt class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></tt>, the string from start tag. This is referred
- to in the <tt class="computeroutput"><span class="identifier">end_tag</span></tt> body
- as <tt class="computeroutput"><span class="identifier">_r1</span></tt>.
- </p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.the_structures"></a><h5>
-<a name="id435152"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.the_structures">The
+ passing in <code class="computeroutput"><span class="identifier">at_c</span><span class="special"><</span><span class="number">0</span><span class="special">>(</span><span class="identifier">_val</span><span class="special">)</span></code>, the string from start tag. This is referred
+ to in the <code class="computeroutput"><span class="identifier">end_tag</span></code> body
+ as <code class="computeroutput"><span class="identifier">_r1</span></code>.
+ </p>
+<a name="spirit.qi.tutorials.mini_xml___asts_.the_structures"></a><h6>
+<a name="id1126616"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.the_structures">The
Structures</a>
- </h5>
+ </h6>
<p>
Let's see our structures. It will definitely be hierarchical: xml is hierarchical.
It will also be recursive: xml is recursive.
@@ -346,17 +341,17 @@
</p>
<p>
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.of_alternates_and_variants"></a><h5>
-<a name="id435420"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.of_alternates_and_variants">Of
+<a name="spirit.qi.tutorials.mini_xml___asts_.of_alternates_and_variants"></a><h6>
+<a name="id1126812"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.of_alternates_and_variants">Of
Alternates and Variants</a>
- </h5>
+ </h6>
<p>
- So that's how a <tt class="computeroutput"><span class="identifier">mini_xml_node</span></tt>
- looks like. We had a hint that it is either a <tt class="computeroutput"><span class="identifier">string</span></tt>
- or a <tt class="computeroutput"><span class="identifier">mini_xml</span></tt>. For this,
+ So that's how a <code class="computeroutput"><span class="identifier">mini_xml_node</span></code>
+ looks like. We had a hint that it is either a <code class="computeroutput"><span class="identifier">string</span></code>
+ or a <code class="computeroutput"><span class="identifier">mini_xml</span></code>. For this,
we use Boost.Variant.
- <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">recursive_wrapper</span></tt> wraps <tt class="computeroutput"><span class="identifier">mini_xml</span></tt>, making it a recursive data
+ <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">recursive_wrapper</span></code> wraps <code class="computeroutput"><span class="identifier">mini_xml</span></code>, making it a recursive data
structure.
</p>
<p>
@@ -370,16 +365,16 @@
<pre class="programlisting"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">variant</span><span class="special"><</span><span class="identifier">A</span><span class="special">,</span> <span class="identifier">B</span><span class="special">></span>
</pre>
<p>
- where <tt class="computeroutput"><span class="identifier">A</span></tt> is the attribute
- of <tt class="computeroutput"><span class="identifier">a</span></tt> and <tt class="computeroutput"><span class="identifier">B</span></tt> is the attribute of <tt class="computeroutput"><span class="identifier">b</span></tt>.
+ where <code class="computeroutput"><span class="identifier">A</span></code> is the attribute
+ of <code class="computeroutput"><span class="identifier">a</span></code> and <code class="computeroutput"><span class="identifier">B</span></code> is the attribute of <code class="computeroutput"><span class="identifier">b</span></code>.
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.adapting_structs_again"></a><h5>
-<a name="id435663"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.adapting_structs_again">Adapting
+<a name="spirit.qi.tutorials.mini_xml___asts_.adapting_structs_again"></a><h6>
+<a name="id1126976"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.adapting_structs_again">Adapting
structs again</a>
- </h5>
+ </h6>
<p>
- <tt class="computeroutput"><span class="identifier">mini_xml</span></tt> is no brainier.
+ <code class="computeroutput"><span class="identifier">mini_xml</span></code> is no brainier.
It is a plain ol' struct. But as we've seen in our employee example, we
can adapt that to be a Fusion
sequence:
@@ -399,11 +394,11 @@
</p>
<p>
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.one_more_take"></a><h5>
-<a name="id435861"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.one_more_take">One
+<a name="spirit.qi.tutorials.mini_xml___asts_.one_more_take"></a><h6>
+<a name="id1127116"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.one_more_take">One
More Take</a>
- </h5>
+ </h6>
<p>
Here's another version. The AST structure remains the same, but this time,
you'll see that we make use of auto-rules making the grammar semantic-action-
@@ -466,19 +461,19 @@
the first xml parser example. The rules are almost the same, except that,
we got rid of semantic actions and used auto-rules (see the employee example
if you missed that). There are a couple of new stuff, though. It's all
- in the <tt class="computeroutput"><span class="identifier">xml</span></tt> rule:
+ in the <code class="computeroutput"><span class="identifier">xml</span></code> rule:
</p>
-<a name="spirit.qi.tutorials.mini_xml___asts_.local_variables"></a><h5>
-<a name="id437105"></a>
- <a href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.local_variables">Local
+<a name="spirit.qi.tutorials.mini_xml___asts_.local_variables"></a><h6>
+<a name="id1128579"></a>
+ <a class="link" href="mini_xml___asts_.html#spirit.qi.tutorials.mini_xml___asts_.local_variables">Local
Variables</a>
- </h5>
+ </h6>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">mini_xml</span><span class="special">(),</span> <span class="identifier">locals</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">>,</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">xml</span><span class="special">;</span>
</pre>
<p>
- Wow, we have four template parameters now. What's that <tt class="computeroutput"><span class="identifier">locals</span></tt>
- guy doing there? Well, it declares that the rule <tt class="computeroutput"><span class="identifier">xml</span></tt>
- will have one local variable: a <tt class="computeroutput"><span class="identifier">string</span></tt>.
+ Wow, we have four template parameters now. What's that <code class="computeroutput"><span class="identifier">locals</span></code>
+ guy doing there? Well, it declares that the rule <code class="computeroutput"><span class="identifier">xml</span></code>
+ will have one local variable: a <code class="computeroutput"><span class="identifier">string</span></code>.
Let's see how this is used in action:
</p>
<pre class="programlisting"><span class="identifier">xml</span> <span class="special">%=</span>
@@ -487,25 +482,25 @@
<span class="special">>></span> <span class="identifier">end_tag</span><span class="special">(</span><span class="identifier">_a</span><span class="special">)</span>
<span class="special">;</span>
</pre>
-<div class="orderedlist"><ol type="1">
-<li>
- Upon parsing <tt class="computeroutput"><span class="identifier">start_tag</span></tt>,
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
+ Upon parsing <code class="computeroutput"><span class="identifier">start_tag</span></code>,
the parsed start-tag string is placed in the local variable specified
by (yet another) Phoenix
- placeholder: <tt class="computeroutput"><span class="identifier">_a</span></tt>. We have
- only one local variable. If we had more, these are designated by <tt class="computeroutput"><span class="identifier">_b</span></tt>..<tt class="computeroutput"><span class="identifier">_z</span></tt>.
+ placeholder: <code class="computeroutput"><span class="identifier">_a</span></code>. We have
+ only one local variable. If we had more, these are designated by <code class="computeroutput"><span class="identifier">_b</span></code>..<code class="computeroutput"><span class="identifier">_z</span></code>.
</li>
-<li>
- Then we parse zero or more <tt class="computeroutput"><span class="identifier">node</span></tt>s.
+<li class="listitem">
+ Then we parse zero or more <code class="computeroutput"><span class="identifier">node</span></code>s.
</li>
-<li>
- Finally, we parse the <tt class="computeroutput"><span class="identifier">end_tag</span></tt>
- giving it an inherited attribute: <tt class="computeroutput"><span class="identifier">_a</span></tt>,
+<li class="listitem">
+ Finally, we parse the <code class="computeroutput"><span class="identifier">end_tag</span></code>
+ giving it an inherited attribute: <code class="computeroutput"><span class="identifier">_a</span></code>,
our local variable.
</li>
</ol></div>
<p>
- There are no actions involved in stuffing data into our <tt class="computeroutput"><span class="identifier">xml</span></tt>
+ There are no actions involved in stuffing data into our <code class="computeroutput"><span class="identifier">xml</span></code>
attribute. It's all taken cared of thatnks to the auto-rule.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___error_handling.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___error_handling.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/mini_xml___error_handling.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Mini
- XML - Error Handling</title>
+<title>Mini XML - Error Handling</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="mini_xml___asts_.html" title="Mini XML - ASTs!">
+<link rel="prev" href="mini_xml___asts_.html" title="Mini XML - ASTs!">
<link rel="next" href="../quick_reference.html" title="Quick Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -23,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="mini_xml___asts_.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../quick_reference.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.mini_xml___error_handling"></a><a href="mini_xml___error_handling.html" title="Mini
- XML - Error Handling">Mini
+<div class="section" title="Mini XML - Error Handling">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.mini_xml___error_handling"></a><a class="link" href="mini_xml___error_handling.html" title="Mini XML - Error Handling">Mini
XML - Error Handling</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
A parser will not be complete without error handling. Spirit2 provides
some facilities to make it easy to adapt a grammar for error handling.
@@ -48,11 +43,11 @@
<p>
What's new?
</p>
-<a name="spirit.qi.tutorials.mini_xml___error_handling.readable_names"></a><h5>
-<a name="id437558"></a>
- <a href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.readable_names">Readable
+<a name="spirit.qi.tutorials.mini_xml___error_handling.readable_names"></a><h6>
+<a name="id1128883"></a>
+ <a class="link" href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.readable_names">Readable
Names</a>
- </h5>
+ </h6>
<p>
First, when we call the base class, we give the grammar a name:
</p>
@@ -67,13 +62,13 @@
<span class="identifier">start_tag</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="string">"start_tag"</span><span class="special">);</span>
<span class="identifier">end_tag</span><span class="special">.</span><span class="identifier">name</span><span class="special">(</span><span class="string">"end_tag"</span><span class="special">);</span>
</pre>
-<a name="spirit.qi.tutorials.mini_xml___error_handling.on_error"></a><h5>
-<a name="id437809"></a>
- <a href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.on_error">On
+<a name="spirit.qi.tutorials.mini_xml___error_handling.on_error"></a><h6>
+<a name="id1129063"></a>
+ <a class="link" href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.on_error">On
Error</a>
- </h5>
+ </h6>
<p>
- <tt class="computeroutput"><span class="identifier">on_error</span></tt> declares our error
+ <code class="computeroutput"><span class="identifier">on_error</span></code> declares our error
handler:
</p>
<pre class="programlisting"><span class="identifier">on_error</span><span class="special"><</span><span class="identifier">Action</span><span class="special">>(</span><span class="identifier">rule</span><span class="special">,</span> <span class="identifier">handler</span><span class="special">)</span>
@@ -95,8 +90,8 @@
<span class="special">);</span>
</pre>
<p>
- we choose to <tt class="computeroutput"><span class="identifier">fail</span></tt> in our
- example for the <tt class="computeroutput"><span class="identifier">Action</span></tt>:
+ we choose to <code class="computeroutput"><span class="identifier">fail</span></code> in our
+ example for the <code class="computeroutput"><span class="identifier">Action</span></code>:
Quit and fail. Return a no_match (false). It can be one of:
</p>
<div class="informaltable"><table class="table">
@@ -105,55 +100,75 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
- <tt class="computeroutput"><span class="identifier">Action</span></tt>
- </p></th>
-<th><p>
+<th>
+ <p>
+ <code class="computeroutput"><span class="identifier">Action</span></code>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
fail
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Quit and fail. Return a no_match.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
retry
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Attempt error recovery, possibly moving the iterator position.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
accept
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Force success, moving the iterator position appropriately.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
rethrow
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Rethrows the error.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
<p>
- <tt class="computeroutput"><span class="identifier">rule</span></tt> is the rule we attach
- the handler to. In our case, we are attaching to the <tt class="computeroutput"><span class="identifier">xml</span></tt>
+ <code class="computeroutput"><span class="identifier">rule</span></code> is the rule we attach
+ the handler to. In our case, we are attaching to the <code class="computeroutput"><span class="identifier">xml</span></code>
rule.
</p>
<p>
- <tt class="computeroutput"><span class="identifier">handler</span></tt> is the actual error
+ <code class="computeroutput"><span class="identifier">handler</span></code> is the actual error
handling function. It expects 4 arguments:
</p>
<div class="informaltable"><table class="table">
@@ -162,57 +177,77 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Arg
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
first
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
The position of the iterator when the rule with the handler was
entered.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
last
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
The end of input.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
error-pos
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
The actual position of the iterator where the error occurred.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
what
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
What failed: a string decribing the failure.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<a name="spirit.qi.tutorials.mini_xml___error_handling.expectation_points"></a><h5>
-<a name="id438480"></a>
- <a href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.expectation_points">Expectation
+<a name="spirit.qi.tutorials.mini_xml___error_handling.expectation_points"></a><h6>
+<a name="id1129572"></a>
+ <a class="link" href="mini_xml___error_handling.html#spirit.qi.tutorials.mini_xml___error_handling.expectation_points">Expectation
Points</a>
- </h5>
+ </h6>
<p>
You might not have noticed it, but some of our expressions changed from
- using the <tt class="computeroutput"><span class="special">>></span></tt> to <tt class="computeroutput"><span class="special">></span></tt>. Look, for example:
+ using the <code class="computeroutput"><span class="special">>></span></code> to <code class="computeroutput"><span class="special">></span></code>. Look, for example:
</p>
<pre class="programlisting"><span class="identifier">end_tag</span> <span class="special">=</span>
<span class="string">"</"</span>
@@ -223,10 +258,10 @@
<p>
What is it? It's the <span class="emphasis"><em>expectation</em></span> operator. You will
have some "deterministic points" in the grammar. Those are the
- places where backtracking <span class="bold"><b>cannot</b></span> occur.
- For our example above, when you get a <tt class="computeroutput"><span class="string">"</"</span></tt>,
+ places where backtracking <span class="bold"><strong>cannot</strong></span> occur.
+ For our example above, when you get a <code class="computeroutput"><span class="string">"</"</span></code>,
you definitely must see a valid end-tag label next. It should be the one
- you got from the start-tag. After that, you definitely must have a <tt class="computeroutput"><span class="char">'>'</span></tt> next. Otherwise, there is no point in
+ you got from the start-tag. After that, you definitely must have a <code class="computeroutput"><span class="char">'>'</span></code> next. Otherwise, there is no point in
proceeding forward and trying other branches, regardless where they are.
The input is definitely erroneous. When this happens, an expectation_failure
exception is thrown. Somewhere outward, the error handler will catch the
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list___stuffing_numbers_into_a_std__vector.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list___stuffing_numbers_into_a_std__vector.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list___stuffing_numbers_into_a_std__vector.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Number
- List - stuffing numbers into a std::vector</title>
+<title>Number List - stuffing numbers into a std::vector</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="sum___adding_numbers.html" title="Sum - adding
- numbers">
-<link rel="next" href="number_list_redux___list_syntax.html" title="Number
- List Redux - list syntax">
+<link rel="prev" href="sum___adding_numbers.html" title="Sum - adding numbers">
+<link rel="next" href="number_list_redux___list_syntax.html" title="Number List Redux - list syntax">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="sum___adding_numbers.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="number_list_redux___list_syntax.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.number_list___stuffing_numbers_into_a_std__vector"></a><a href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number
- List - stuffing numbers into a std::vector">Number
+<div class="section" title="Number List - stuffing numbers into a std::vector">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.number_list___stuffing_numbers_into_a_std__vector"></a><a class="link" href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number List - stuffing numbers into a std::vector">Number
List - stuffing numbers into a std::vector</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
This sample demontrates a parser for a comma separated list of numbers.
The numbers are inserted in a vector using phoenix.
@@ -79,18 +72,18 @@
</p>
<p>
This, again, is the same parser as before. This time, instead of summing
- up the numbers, we stuff them in a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></tt>.
- <tt class="computeroutput"><span class="identifier">push_back</span></tt> is supplied by
+ up the numbers, we stuff them in a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></code>.
+ <code class="computeroutput"><span class="identifier">push_back</span></code> is supplied by
<a href="../../../../../phoenix/doc/html/index.html" target="_top">Phoenix</a>. The expression:
</p>
<pre class="programlisting"><span class="identifier">push_back</span><span class="special">(</span><span class="identifier">ref</span><span class="special">(</span><span class="identifier">v</span><span class="special">),</span> <span class="identifier">_1</span><span class="special">)</span>
</pre>
<p>
- appends the parsed number. Like before, <tt class="computeroutput"><span class="identifier">_1</span></tt>
+ appends the parsed number. Like before, <code class="computeroutput"><span class="identifier">_1</span></code>
is a Phoenix placeholder
- for the parsed result attribute. Also, like before, <tt class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">v</span><span class="special">)</span></tt>
+ for the parsed result attribute. Also, like before, <code class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">v</span><span class="special">)</span></code>
tells Phoenix that
- <tt class="computeroutput"><span class="identifier">v</span></tt>, the <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></tt>,
+ <code class="computeroutput"><span class="identifier">v</span></code>, the <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></code>,
is a mutable reference.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_attribute___one_more__with_style.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_attribute___one_more__with_style.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_attribute___one_more__with_style.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,14 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Number
- List Attribute - one more, with style</title>
+<title>Number List Attribute - one more, with style</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="number_list_redux___list_syntax.html" title="Number
- List Redux - list syntax">
+<link rel="prev" href="number_list_redux___list_syntax.html" title="Number List Redux - list syntax">
<link rel="next" href="roman_numerals.html" title="Roman Numerals">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -24,18 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="number_list_redux___list_syntax.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="roman_numerals.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.number_list_attribute___one_more__with_style"></a><a href="number_list_attribute___one_more__with_style.html" title="Number
- List Attribute - one more, with style">Number
+<div class="section" title="Number List Attribute - one more, with style">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.number_list_attribute___one_more__with_style"></a><a class="link" href="number_list_attribute___one_more__with_style.html" title="Number List Attribute - one more, with style">Number
List Attribute - one more, with style</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
- You've seen that the <tt class="computeroutput"><span class="identifier">double_</span></tt>
- parser has a <tt class="computeroutput"><span class="keyword">double</span></tt> attribute.
+ You've seen that the <code class="computeroutput"><span class="identifier">double_</span></code>
+ parser has a <code class="computeroutput"><span class="keyword">double</span></code> attribute.
All parsers have an attribute, even complex parsers, those that are composed
from primitives using operators, like the list parser, also have an attribute.
It so happens that the the attribute of a list parser:
@@ -43,7 +37,7 @@
<pre class="programlisting"><span class="identifier">p</span> <span class="special">%</span> <span class="identifier">d</span>
</pre>
<p>
- is a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></tt> of the attribute of <tt class="computeroutput"><span class="identifier">p</span></tt>. So, for our parser:
+ is a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></code> of the attribute of <code class="computeroutput"><span class="identifier">p</span></code>. So, for our parser:
</p>
<pre class="programlisting"><span class="identifier">double_</span> <span class="special">%</span> <span class="char">','</span>
</pre>
@@ -53,25 +47,25 @@
<pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span>
</pre>
<p>
- So, what does this give us? Well, we can simply pass in a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></tt>
+ So, what does this give us? Well, we can simply pass in a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="keyword">double</span><span class="special">></span></code>
to our number list parser and it will happily churn out our result in our
- vector. For that to happen, we'll use a variation of the <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt> with an additional argument:
+ vector. For that to happen, we'll use a variation of the <code class="computeroutput"><span class="identifier">phrase_parse</span></code> with an additional argument:
the parser's attribute:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
An iterator pointing to the start of the input
</li>
-<li>
+<li class="listitem">
An iterator pointing to one past the end of the input
</li>
-<li>
+<li class="listitem">
The parser object
</li>
-<li>
+<li class="listitem">
The parser's attribute
</li>
-<li>
+<li class="listitem">
Another parser called the skip parser
</li>
</ol></div>
@@ -115,7 +109,7 @@
The full cpp file for this example can be found here: ../../example/qi/num_list4.cpp
</p>
<p>
- <span class="bold"><b>Hey, no more actions!!!</b></span> Now we're entering
+ <span class="bold"><strong>Hey, no more actions!!!</strong></span> Now we're entering
the realm of attribute grammars. Cool eh?
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_redux___list_syntax.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_redux___list_syntax.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/number_list_redux___list_syntax.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Number
- List Redux - list syntax</title>
+<title>Number List Redux - list syntax</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number
- List - stuffing numbers into a std::vector">
-<link rel="next" href="number_list_attribute___one_more__with_style.html" title="Number
- List Attribute - one more, with style">
+<link rel="prev" href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number List - stuffing numbers into a std::vector">
+<link rel="next" href="number_list_attribute___one_more__with_style.html" title="Number List Attribute - one more, with style">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="number_list___stuffing_numbers_into_a_std__vector.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="number_list_attribute___one_more__with_style.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.number_list_redux___list_syntax"></a><a href="number_list_redux___list_syntax.html" title="Number
- List Redux - list syntax">Number
+<div class="section" title="Number List Redux - list syntax">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.number_list_redux___list_syntax"></a><a class="link" href="number_list_redux___list_syntax.html" title="Number List Redux - list syntax">Number
List Redux - list syntax</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
So far, we've been using the syntax:
</p>
@@ -47,7 +40,7 @@
<pre class="programlisting"><span class="identifier">double_</span> <span class="special">%</span> <span class="char">','</span>
</pre>
<p>
- read as: a list of doubles separated by <tt class="computeroutput"><span class="char">','</span></tt>.
+ read as: a list of doubles separated by <code class="computeroutput"><span class="char">','</span></code>.
</p>
<p>
This sample, again a variation of our previous example, demonstrates just
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/quick_start.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/quick_start.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/quick_start.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Quick Start</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="../tutorials.html" title="Tutorials">
+<link rel="prev" href="../tutorials.html" title="Tutorials">
<link rel="next" href="warming_up.html" title="Warming up">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,18 +22,15 @@
<div class="spirit-nav">
<a accesskey="p" href="../tutorials.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="warming_up.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.quick_start"></a>Quick Start
-</h4></div></div>
-<div></div>
-</div>
-<a name="spirit.qi.tutorials.quick_start.why_would_you_want_to_use_spirit_qi_"></a><h5>
-<a name="id415886"></a>
- <a href="quick_start.html#spirit.qi.tutorials.quick_start.why_would_you_want_to_use_spirit_qi_">Why
+<div class="section" title="Quick Start">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.quick_start"></a><a class="link" href="quick_start.html" title="Quick Start">Quick Start</a>
+</h4></div></div></div>
+<a name="spirit.qi.tutorials.quick_start.why_would_you_want_to_use_spirit_qi_"></a><h6>
+<a name="id1107276"></a>
+ <a class="link" href="quick_start.html#spirit.qi.tutorials.quick_start.why_would_you_want_to_use_spirit_qi_">Why
would you want to use Spirit.Qi?</a>
- </h5>
+ </h6>
<p>
Spirit.Qi is designed to be a practical parsing tool. The ability to generate
a fully-working parser from a formal EBNF specification inlined in C++
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/roman_numerals.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/roman_numerals.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/roman_numerals.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,13 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Roman Numerals</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="number_list_attribute___one_more__with_style.html" title="Number
- List Attribute - one more, with style">
-<link rel="next" href="employee___parsing_into_structs.html" title="Employee
- - Parsing into structs">
+<link rel="prev" href="number_list_attribute___one_more__with_style.html" title="Number List Attribute - one more, with style">
+<link rel="next" href="employee___parsing_into_structs.html" title="Employee - Parsing into structs">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -24,35 +22,32 @@
<div class="spirit-nav">
<a accesskey="p" href="number_list_attribute___one_more__with_style.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="employee___parsing_into_structs.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.roman_numerals"></a>Roman Numerals
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Roman Numerals">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.roman_numerals"></a><a class="link" href="roman_numerals.html" title="Roman Numerals">Roman Numerals</a>
+</h4></div></div></div>
<p>
This example demonstrates:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
symbol table
</li>
-<li>
+<li class="listitem">
rule
</li>
-<li>
+<li class="listitem">
grammar
</li>
</ul></div>
-<a name="spirit.qi.tutorials.roman_numerals.symbol_table"></a><h5>
-<a name="id423932"></a>
- <a href="roman_numerals.html#spirit.qi.tutorials.roman_numerals.symbol_table">Symbol
+<a name="spirit.qi.tutorials.roman_numerals.symbol_table"></a><h6>
+<a name="id1115137"></a>
+ <a class="link" href="roman_numerals.html#spirit.qi.tutorials.roman_numerals.symbol_table">Symbol
Table</a>
- </h5>
+ </h6>
<p>
The symbol table holds a dictionary of symbols where each symbol is a sequence
- of characters (a <tt class="computeroutput"><span class="keyword">char</span></tt>, <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>, <tt class="computeroutput"><span class="keyword">int</span></tt>,
+ of characters (a <code class="computeroutput"><span class="keyword">char</span></code>, <code class="computeroutput"><span class="keyword">wchar_t</span></code>, <code class="computeroutput"><span class="keyword">int</span></code>,
enumeration etc.) . The template class, parameterized by the character
type, can work efficiently with 8, 16, 32 and even 64 bit characters. Mutable
data of type T is associated with each symbol.
@@ -173,19 +168,19 @@
<p>
</p>
<p>
- Now we can use <tt class="computeroutput"><span class="identifier">hundreds</span></tt>,
- <tt class="computeroutput"><span class="identifier">tens</span></tt> and <tt class="computeroutput"><span class="identifier">ones</span></tt> anywhere in our parser expressions.
+ Now we can use <code class="computeroutput"><span class="identifier">hundreds</span></code>,
+ <code class="computeroutput"><span class="identifier">tens</span></code> and <code class="computeroutput"><span class="identifier">ones</span></code> anywhere in our parser expressions.
They are all parsers.
</p>
-<a name="spirit.qi.tutorials.roman_numerals.rules"></a><h5>
-<a name="id425245"></a>
- Rules
- </h5>
+<a name="spirit.qi.tutorials.roman_numerals.rules"></a><h6>
+<a name="id1116476"></a>
+ <a class="link" href="roman_numerals.html#spirit.qi.tutorials.roman_numerals.rules">Rules</a>
+ </h6>
<p>
Up until now, we've been inlining our parser expressions, passing them
- directly to the <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>
+ directly to the <code class="computeroutput"><span class="identifier">phrase_parse</span></code>
function. The expression evaluates into a temporary, unnamed parser which
- is passed into the <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>
+ is passed into the <code class="computeroutput"><span class="identifier">phrase_parse</span></code>
function, used, and then destroyed. This is fine for small parsers. When
the expressions get complicated, you'd want to break the expressions into
smaller easier to understand pieces, name them, and refer to them from
@@ -199,8 +194,8 @@
</pre>
<p>
At the very least, the rule needs to know the iterator type it will be
- working on. This rule cannot be used with <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>.
- It can only be used with the <tt class="computeroutput"><span class="identifier">parse</span></tt>
+ working on. This rule cannot be used with <code class="computeroutput"><span class="identifier">phrase_parse</span></code>.
+ It can only be used with the <code class="computeroutput"><span class="identifier">parse</span></code>
function -- a version that does not do white space skipping (does not have
the skipper argument). If you want to have it skip white spaces, you need
to pass in the type skip parser, as in the next form:
@@ -213,8 +208,8 @@
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">::</span><span class="identifier">iterator</span><span class="special">,</span> <span class="identifier">space_type</span><span class="special">></span> <span class="identifier">r</span><span class="special">;</span>
</pre>
<p>
- This type of rule can be used for both <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>
- and <tt class="computeroutput"><span class="identifier">parse</span></tt>.
+ This type of rule can be used for both <code class="computeroutput"><span class="identifier">phrase_parse</span></code>
+ and <code class="computeroutput"><span class="identifier">parse</span></code>.
</p>
<p>
For our next example, there's one more rule form you should know about:
@@ -226,19 +221,19 @@
</p>
<pre class="programlisting"><span class="identifier">rule</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span> <span class="identifier">Signature</span><span class="special">,</span> <span class="identifier">Skipper</span><span class="special">></span> <span class="identifier">r</span><span class="special">;</span>
</pre>
-<div class="tip"><table border="0" summary="Tip">
+<div class="tip" title="Tip"><table border="0" summary="Tip">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="../../../images/tip.png"></td>
<th align="left">Tip</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
All rule template arguments after Iterator can be supplied in any order.
</p></td></tr>
</table></div>
<p>
The Signature specifies the attributes of the rule. You've seen that our
- parsers can have an attribute. Recall that the <tt class="computeroutput"><span class="identifier">double_</span></tt>
- parser has an attribute of <tt class="computeroutput"><span class="keyword">double</span></tt>.
+ parsers can have an attribute. Recall that the <code class="computeroutput"><span class="identifier">double_</span></code>
+ parser has an attribute of <code class="computeroutput"><span class="keyword">double</span></code>.
To be precise, these are <span class="emphasis"><em>synthesized</em></span> attributes. The
parser "synthesizes" the attribute value. Think of them as function
return values.
@@ -257,27 +252,27 @@
</p>
<pre class="programlisting"><span class="identifier">r</span> <span class="special">=</span> <span class="identifier">double_</span> <span class="special">>></span> <span class="special">*(</span><span class="char">','</span> <span class="special">>></span> <span class="identifier">double_</span><span class="special">);</span>
</pre>
-<a name="spirit.qi.tutorials.roman_numerals.grammars"></a><h5>
-<a name="id425828"></a>
- Grammars
- </h5>
+<a name="spirit.qi.tutorials.roman_numerals.grammars"></a><h6>
+<a name="id1116869"></a>
+ <a class="link" href="roman_numerals.html#spirit.qi.tutorials.roman_numerals.grammars">Grammars</a>
+ </h6>
<p>
A grammar encapsulates one or more rules. It has the same template parameters
as the rule. You declare a grammar by:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
- deriving a struct (or class) from the <tt class="computeroutput"><span class="identifier">grammar</span></tt>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
+ deriving a struct (or class) from the <code class="computeroutput"><span class="identifier">grammar</span></code>
class template
</li>
-<li>
+<li class="listitem">
declare one or more rules as member variables
</li>
-<li>
+<li class="listitem">
initialize the base grammar class by giving it the start rule (its the
first rule that gets called when the grammar starts parsing)
</li>
-<li>
+<li class="listitem">
initialize your rules in your constructor
</li>
</ol></div>
@@ -320,52 +315,52 @@
<p>
Things to take notice of:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
- The grammar and start rule signature is <tt class="computeroutput"><span class="keyword">unsigned</span><span class="special">()</span></tt>. It has a synthesized attribute (return
- value) of type <tt class="computeroutput"><span class="keyword">unsigned</span></tt>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+ The grammar and start rule signature is <code class="computeroutput"><span class="keyword">unsigned</span><span class="special">()</span></code>. It has a synthesized attribute (return
+ value) of type <code class="computeroutput"><span class="keyword">unsigned</span></code>
with no inherited attributes (arguments).
</li>
-<li>
+<li class="listitem">
We did not specify a skip-parser. We don't want to skip in between the
numerals.
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">roman</span><span class="special">::</span><span class="identifier">base_type</span></tt> is a typedef for <tt class="computeroutput"><span class="identifier">grammar</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
- <span class="keyword">unsigned</span><span class="special">()></span></tt>.
- If <tt class="computeroutput"><span class="identifier">roman</span></tt> was not a template,
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">roman</span><span class="special">::</span><span class="identifier">base_type</span></code> is a typedef for <code class="computeroutput"><span class="identifier">grammar</span><span class="special"><</span><span class="identifier">Iterator</span><span class="special">,</span>
+ <span class="keyword">unsigned</span><span class="special">()></span></code>.
+ If <code class="computeroutput"><span class="identifier">roman</span></code> was not a template,
you can simply write: base_type(start)
</li>
-<li>
+<li class="listitem">
But it's best to make your grammar templates, so that they can be reused
for different iterator types.
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">_val</span></tt> is another Phoenix placeholder representing
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">_val</span></code> is another Phoenix placeholder representing
the rule's synthesized attribute.
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">eps</span></tt> is a special spirit
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">eps</span></code> is a special spirit
parser that consumes no input but is always successful. We use it to
- initialize <tt class="computeroutput"><span class="identifier">_val</span></tt>, the
+ initialize <code class="computeroutput"><span class="identifier">_val</span></code>, the
rule's synthesized attribute, to zero before anything else. The actual
- parser starts at <tt class="computeroutput"><span class="special">+</span><span class="identifier">char_</span><span class="special">(</span><span class="char">'M'</span><span class="special">)</span></tt>,
- parsing roman thousands. Using <tt class="computeroutput"><span class="identifier">eps</span></tt>
+ parser starts at <code class="computeroutput"><span class="special">+</span><span class="identifier">char_</span><span class="special">(</span><span class="char">'M'</span><span class="special">)</span></code>,
+ parsing roman thousands. Using <code class="computeroutput"><span class="identifier">eps</span></code>
this way is good for doing pre and post initializations.
</li>
-<li>
- The expression <tt class="computeroutput"><span class="identifier">a</span> <span class="special">||</span>
- <span class="identifier">b</span></tt> reads: match a or b and in
- sequence. That is, if both <tt class="computeroutput"><span class="identifier">a</span></tt>
- and <tt class="computeroutput"><span class="identifier">b</span></tt> match, it must
- be in sequence; this is equivalent to <tt class="computeroutput"><span class="identifier">a</span>
- <span class="special">>></span> <span class="special">-</span><span class="identifier">b</span> <span class="special">|</span> <span class="identifier">b</span></tt>, but more efficient.
+<li class="listitem">
+ The expression <code class="computeroutput"><span class="identifier">a</span> <span class="special">||</span>
+ <span class="identifier">b</span></code> reads: match a or b and in
+ sequence. That is, if both <code class="computeroutput"><span class="identifier">a</span></code>
+ and <code class="computeroutput"><span class="identifier">b</span></code> match, it must
+ be in sequence; this is equivalent to <code class="computeroutput"><span class="identifier">a</span>
+ <span class="special">>></span> <span class="special">-</span><span class="identifier">b</span> <span class="special">|</span> <span class="identifier">b</span></code>, but more efficient.
</li>
</ul></div>
-<a name="spirit.qi.tutorials.roman_numerals.let_s_parse_"></a><h5>
-<a name="id426844"></a>
- Let's Parse!
- </h5>
+<a name="spirit.qi.tutorials.roman_numerals.let_s_parse_"></a><h6>
+<a name="id1117596"></a>
+ <a class="link" href="roman_numerals.html#spirit.qi.tutorials.roman_numerals.let_s_parse_">Let's Parse!</a>
+ </h6>
<p>
</p>
<p>
@@ -394,12 +389,12 @@
<p>
</p>
<p>
- <tt class="computeroutput"><span class="identifier">roman_parser</span></tt> is an object
- of type <tt class="computeroutput"><span class="identifier">roman</span></tt> -our roman
+ <code class="computeroutput"><span class="identifier">roman_parser</span></code> is an object
+ of type <code class="computeroutput"><span class="identifier">roman</span></code> -our roman
numeral parser. This time around, we are using the no-skipping version
of the parse functions. We do not want to skip any spaces! We are also
- passing in an attribute, <tt class="computeroutput"><span class="keyword">unsigned</span>
- <span class="identifier">result</span></tt>, which will receive the
+ passing in an attribute, <code class="computeroutput"><span class="keyword">unsigned</span>
+ <span class="identifier">result</span></code>, which will receive the
parsed value.
</p>
<p>
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/semantic_actions.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/semantic_actions.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/semantic_actions.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,12 +3,11 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Semantic Actions</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="warming_up.html" title="Warming up">
-<link rel="next" href="complex___our_first_complex_parser.html" title="Complex
- - Our first complex parser">
+<link rel="prev" href="warming_up.html" title="Warming up">
+<link rel="next" href="complex___our_first_complex_parser.html" title="Complex - Our first complex parser">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -23,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="warming_up.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="complex___our_first_complex_parser.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.semantic_actions"></a>Semantic Actions
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Semantic Actions">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.semantic_actions"></a><a class="link" href="semantic_actions.html" title="Semantic Actions">Semantic Actions</a>
+</h4></div></div></div>
<p>
Our parser above is really nothing but a recognizer. It answers the question
"did the input match our grammar?", but it does not do anything
@@ -41,22 +37,22 @@
Enter Semantic actions. Semantic actions may be attached to any point in
the grammar specification. These actions are C++ functions or function
objects that are called whenever a part of the parser successfully recognizes
- a portion of the input. Say you have a parser <tt class="computeroutput"><span class="identifier">P</span></tt>,
- and a C++ function <tt class="computeroutput"><span class="identifier">F</span></tt>, you
- can make the parser call <tt class="computeroutput"><span class="identifier">F</span></tt>
- whenever it matches an input by attaching <tt class="computeroutput"><span class="identifier">F</span></tt>:
+ a portion of the input. Say you have a parser <code class="computeroutput"><span class="identifier">P</span></code>,
+ and a C++ function <code class="computeroutput"><span class="identifier">F</span></code>, you
+ can make the parser call <code class="computeroutput"><span class="identifier">F</span></code>
+ whenever it matches an input by attaching <code class="computeroutput"><span class="identifier">F</span></code>:
</p>
<pre class="programlisting"><span class="identifier">P</span><span class="special">[</span><span class="identifier">F</span><span class="special">]</span>
</pre>
<p>
- The expression above links <tt class="computeroutput"><span class="identifier">F</span></tt>
- to the parser, <tt class="computeroutput"><span class="identifier">P</span></tt>.
+ The expression above links <code class="computeroutput"><span class="identifier">F</span></code>
+ to the parser, <code class="computeroutput"><span class="identifier">P</span></code>.
</p>
<p>
The function/function object signature depends on the type of the parser
- to which it is attached. The parser <tt class="computeroutput"><span class="identifier">double_</span></tt>
- passes the parsed number. Thus, if we were to attach a function <tt class="computeroutput"><span class="identifier">F</span></tt> to <tt class="computeroutput"><span class="identifier">double_</span></tt>,
- we need <tt class="computeroutput"><span class="identifier">F</span></tt> to be declared
+ to which it is attached. The parser <code class="computeroutput"><span class="identifier">double_</span></code>
+ passes the parsed number. Thus, if we were to attach a function <code class="computeroutput"><span class="identifier">F</span></code> to <code class="computeroutput"><span class="identifier">double_</span></code>,
+ we need <code class="computeroutput"><span class="identifier">F</span></code> to be declared
as:
</p>
<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">F</span><span class="special">(</span><span class="keyword">double</span> <span class="identifier">n</span><span class="special">);</span>
@@ -71,22 +67,22 @@
<p>
Presented are various ways to attach semantic actions:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Using plain function pointer
</li>
-<li>
+<li class="listitem">
Using simple function object
</li>
-<li>
+<li class="listitem">
Using Boost.Bind
with a plain function
</li>
-<li>
+<li class="listitem">
Using Boost.Bind
with a member function
</li>
-<li>
+<li class="listitem">
Using Boost.Lambda
</li>
</ul></div>
@@ -132,11 +128,11 @@
<p>
</p>
<p>
- Take note that with function objects, we need to have an <tt class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></tt>
+ Take note that with function objects, we need to have an <code class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></code>
with 3 arguments. Since we don't care about the other two, we can use
- <tt class="computeroutput"><span class="identifier">unused_type</span></tt> for these.
- We'll see more of <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
- elsewhere. Get used to it. <tt class="computeroutput"><span class="identifier">unused_type</span></tt>
+ <code class="computeroutput"><span class="identifier">unused_type</span></code> for these.
+ We'll see more of <code class="computeroutput"><span class="identifier">unused_type</span></code>
+ elsewhere. Get used to it. <code class="computeroutput"><span class="identifier">unused_type</span></code>
is a Spirit supplied support class.
</p>
<p>
@@ -162,8 +158,8 @@
<p>
</p>
<p>
- What's new? Well <tt class="computeroutput"><span class="identifier">int_</span></tt> is
- the sibbling of <tt class="computeroutput"><span class="identifier">double_</span></tt>.
+ What's new? Well <code class="computeroutput"><span class="identifier">int_</span></code> is
+ the sibbling of <code class="computeroutput"><span class="identifier">double_</span></code>.
I'm sure you can guess what this parser does.
</p>
<p>
@@ -236,10 +232,10 @@
<p>
The examples above can be found here: ../../example/qi/actions.cpp
</p>
-<a name="spirit.qi.tutorials.semantic_actions.phoenix"></a><h5>
-<a name="id418880"></a>
- Phoenix
- </h5>
+<a name="spirit.qi.tutorials.semantic_actions.phoenix"></a><h6>
+<a name="id1110591"></a>
+ <a class="link" href="semantic_actions.html#spirit.qi.tutorials.semantic_actions.phoenix">Phoenix</a>
+ </h6>
<p>
<a href="../../../../../phoenix/doc/html/index.html" target="_top">Phoenix</a>, a companion
library bundled with Spirit, is specifically suited for binding semantic
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/sum___adding_numbers.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/sum___adding_numbers.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/sum___adding_numbers.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,16 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Sum - adding
- numbers</title>
+<title>Sum - adding numbers</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="complex___our_first_complex_parser.html" title="Complex
- - Our first complex parser">
-<link rel="next" href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number
- List - stuffing numbers into a std::vector">
+<link rel="prev" href="complex___our_first_complex_parser.html" title="Complex - Our first complex parser">
+<link rel="next" href="number_list___stuffing_numbers_into_a_std__vector.html" title="Number List - stuffing numbers into a std::vector">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -25,15 +22,11 @@
<div class="spirit-nav">
<a accesskey="p" href="complex___our_first_complex_parser.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="number_list___stuffing_numbers_into_a_std__vector.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.sum___adding_numbers"></a><a href="sum___adding_numbers.html" title="Sum - adding
- numbers">Sum - adding
+<div class="section" title="Sum - adding numbers">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.sum___adding_numbers"></a><a class="link" href="sum___adding_numbers.html" title="Sum - adding numbers">Sum - adding
numbers</a>
-</h4></div></div>
-<div></div>
-</div>
+</h4></div></div></div>
<p>
Here's a parser that sums a comma-separated list of numbers.
</p>
@@ -83,64 +76,88 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Namespace
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
boost::phoenix
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
All of phoenix
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
boost::spirit
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
All of spirit
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
boost::spirit::qi
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
All of spirit.qi
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
boost::spirit::ascii
- </p></td>
-<td><p>
- ASCII version of <tt class="computeroutput"><span class="identifier">char_</span></tt>
+ </p>
+ </td>
+<td>
+ <p>
+ ASCII version of <code class="computeroutput"><span class="identifier">char_</span></code>
and all char related parsers. Other encodings are also provided
(e.g. also an ISO8859.1)
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
boost::spirit::arg_names
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Special phoenix placeholders for spirit
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
If you feel uneasy with using whole namespaces, feel free to qualify
your code, use namespace aliases, etc. For the purpose of this tutorial,
we will be presenting unqualified names for both Spirit and Phoenix.
@@ -192,25 +209,25 @@
the sum of all the parsed numbers.
</p>
<p>
- The first <tt class="computeroutput"><span class="identifier">double_</span></tt> parser
+ The first <code class="computeroutput"><span class="identifier">double_</span></code> parser
attaches this action:
</p>
<pre class="programlisting"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special">=</span> <span class="identifier">_1</span>
</pre>
<p>
- This assigns the parsed result (actually, the attribute of <tt class="computeroutput"><span class="identifier">double_</span></tt>) to <tt class="computeroutput"><span class="identifier">n</span></tt>.
- <tt class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></tt> tells
- Phoenix that <tt class="computeroutput"><span class="identifier">n</span></tt> is a mutable reference. <tt class="computeroutput"><span class="identifier">_1</span></tt> is a Phoenix
+ This assigns the parsed result (actually, the attribute of <code class="computeroutput"><span class="identifier">double_</span></code>) to <code class="computeroutput"><span class="identifier">n</span></code>.
+ <code class="computeroutput"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span></code> tells
+ Phoenix that <code class="computeroutput"><span class="identifier">n</span></code> is a mutable reference. <code class="computeroutput"><span class="identifier">_1</span></code> is a Phoenix
placeholder for the parsed result attribute.
</p>
<p>
- The second <tt class="computeroutput"><span class="identifier">double_</span></tt> parser
+ The second <code class="computeroutput"><span class="identifier">double_</span></code> parser
attaches this action:
</p>
<pre class="programlisting"><span class="identifier">ref</span><span class="special">(</span><span class="identifier">n</span><span class="special">)</span> <span class="special">+=</span> <span class="identifier">_1</span>
</pre>
<p>
- So, subsequent numbers add into <tt class="computeroutput"><span class="identifier">n</span></tt>.
+ So, subsequent numbers add into <code class="computeroutput"><span class="identifier">n</span></code>.
</p>
<p>
That wasn't too bad, was it :-) ?
Modified: trunk/libs/spirit/doc/html/spirit/qi/tutorials/warming_up.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/qi/tutorials/warming_up.html (original)
+++ trunk/libs/spirit/doc/html/spirit/qi/tutorials/warming_up.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Warming up</title>
<link rel="stylesheet" href="../../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../../index.html" title="Spirit 2.1">
<link rel="up" href="../tutorials.html" title="Tutorials">
-<link rel="previous" href="quick_start.html" title="Quick Start">
+<link rel="prev" href="quick_start.html" title="Quick Start">
<link rel="next" href="semantic_actions.html" title="Semantic Actions">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,22 +22,19 @@
<div class="spirit-nav">
<a accesskey="p" href="quick_start.html"><img src="../../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../tutorials.html"><img src="../../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="semantic_actions.html"><img src="../../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h4 class="title">
-<a name="spirit.qi.tutorials.warming_up"></a>Warming up
-</h4></div></div>
-<div></div>
-</div>
+<div class="section" title="Warming up">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="spirit.qi.tutorials.warming_up"></a><a class="link" href="warming_up.html" title="Warming up">Warming up</a>
+</h4></div></div></div>
<p>
We'll start by showing examples of parser expressions to give you a feel
on how to build parsers from the simplest parser, building up as we go.
</p>
-<a name="spirit.qi.tutorials.warming_up.trivial_example__1_parsing_a_number"></a><h5>
-<a name="id415970"></a>
- <a href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__1_parsing_a_number">Trivial
+<a name="spirit.qi.tutorials.warming_up.trivial_example__1_parsing_a_number"></a><h6>
+<a name="id1107322"></a>
+ <a class="link" href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__1_parsing_a_number">Trivial
Example #1 Parsing a number</a>
- </h5>
+ </h6>
<p>
Create a parser that will parse a floating-point number.
</p>
@@ -48,11 +45,11 @@
a Spirit floating point parser (a built-in parser). Spirit has many pre-defined
parsers and consistent naming conventions help you keep from going insane!
</p>
-<a name="spirit.qi.tutorials.warming_up.trivial_example__2_parsing_two_numbers"></a><h5>
-<a name="id416016"></a>
- <a href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__2_parsing_two_numbers">Trivial
+<a name="spirit.qi.tutorials.warming_up.trivial_example__2_parsing_two_numbers"></a><h6>
+<a name="id1107351"></a>
+ <a class="link" href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__2_parsing_two_numbers">Trivial
Example #2 Parsing two numbers</a>
- </h5>
+ </h6>
<p>
Create a parser that will accept a line consisting of two floating-point
numbers.
@@ -60,8 +57,8 @@
<pre class="programlisting"><span class="identifier">double_</span> <span class="special">>></span> <span class="identifier">double_</span>
</pre>
<p>
- Here you see the familiar floating-point numeric parser <tt class="computeroutput"><span class="identifier">double_</span></tt>
- used twice, once for each number. What's that <tt class="computeroutput"><span class="special">>></span></tt>
+ Here you see the familiar floating-point numeric parser <code class="computeroutput"><span class="identifier">double_</span></code>
+ used twice, once for each number. What's that <code class="computeroutput"><span class="special">>></span></code>
operator doing in there? Well, they had to be separated by something, and
this was chosen as the "followed by" sequence operator. The above
program creates a parser from two simpler parsers, glueing them together
@@ -69,23 +66,23 @@
of smaller parsers. Whitespace between numbers can implicitly be consumed
depending on how the parser is invoked (see below).
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
When we combine parsers, we end up with a "bigger" parser,
but it's still a parser. Parsers can get bigger and bigger, nesting more
and more, but whenever you glue two parsers together, you end up with
one bigger parser. This is an important concept.
</p></td></tr>
</table></div>
-<a name="spirit.qi.tutorials.warming_up.trivial_example__3_parsing_one_or_more_numbers"></a><h5>
-<a name="id416104"></a>
- <a href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__3_parsing_one_or_more_numbers">Trivial
+<a name="spirit.qi.tutorials.warming_up.trivial_example__3_parsing_one_or_more_numbers"></a><h6>
+<a name="id1107412"></a>
+ <a class="link" href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__3_parsing_one_or_more_numbers">Trivial
Example #3 Parsing one or more numbers</a>
- </h5>
+ </h6>
<p>
Create a parser that will accept zero or more floating-point numbers.
</p>
@@ -93,7 +90,7 @@
</pre>
<p>
This is like a regular-expression Kleene Star, though the syntax might
- look a bit odd for a C++ programmer not used to seeing the <tt class="computeroutput"><span class="special">*</span></tt> operator overloaded like this. Actually,
+ look a bit odd for a C++ programmer not used to seeing the <code class="computeroutput"><span class="special">*</span></code> operator overloaded like this. Actually,
if you know regular expressions it may look odd too since the star is before
the expression it modifies. C'est la vie. Blame it on the fact that we
must work with the syntax rules of C++.
@@ -105,11 +102,11 @@
Kleene Star is also known as a Kleene Closure, but we call it the Star
in most places.
</p>
-<a name="spirit.qi.tutorials.warming_up.trivial_example__4_parsing_a_comma_delimited_list_of_numbers"></a><h5>
-<a name="id416181"></a>
- <a href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__4_parsing_a_comma_delimited_list_of_numbers">Trivial
+<a name="spirit.qi.tutorials.warming_up.trivial_example__4_parsing_a_comma_delimited_list_of_numbers"></a><h6>
+<a name="id1107456"></a>
+ <a class="link" href="warming_up.html#spirit.qi.tutorials.warming_up.trivial_example__4_parsing_a_comma_delimited_list_of_numbers">Trivial
Example #4 Parsing a comma-delimited list of numbers</a>
- </h5>
+ </h6>
<p>
This example will create a parser that accepts a comma-delimited list of
numbers.
@@ -117,8 +114,8 @@
<pre class="programlisting"><span class="identifier">double_</span> <span class="special">>></span> <span class="special">*(</span><span class="identifier">char_</span><span class="special">(</span><span class="char">','</span><span class="special">)</span> <span class="special">>></span> <span class="identifier">double_</span><span class="special">)</span>
</pre>
<p>
- Notice <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></tt>. It is
- a literal character parser that can recognize the comma <tt class="computeroutput"><span class="char">','</span></tt>.
+ Notice <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></code>. It is
+ a literal character parser that can recognize the comma <code class="computeroutput"><span class="char">','</span></code>.
In this case, the Kleene Star is modifying a more complex parser, namely,
the one generated by the expression:
</p>
@@ -128,38 +125,38 @@
Note that this is a case where the parentheses are necessary. The Kleene
star encloses the complete expression above.
</p>
-<a name="spirit.qi.tutorials.warming_up.let_s_parse_"></a><h5>
-<a name="id416357"></a>
- Let's Parse!
- </h5>
+<a name="spirit.qi.tutorials.warming_up.let_s_parse_"></a><h6>
+<a name="id1107587"></a>
+ <a class="link" href="warming_up.html#spirit.qi.tutorials.warming_up.let_s_parse_">Let's Parse!</a>
+ </h6>
<p>
We're done with defining the parser. So the next step is now invoking this
parser to do its work. There are a couple of ways to do this. For now,
- we will use the <tt class="computeroutput"><span class="identifier">phrase_parse</span></tt>
+ we will use the <code class="computeroutput"><span class="identifier">phrase_parse</span></code>
function. One overload of this function accepts four arguments:
</p>
-<div class="orderedlist"><ol type="1">
-<li>
+<div class="orderedlist"><ol class="orderedlist" type="1">
+<li class="listitem">
An iterator pointing to the start of the input
</li>
-<li>
+<li class="listitem">
An iterator pointing to one past the end of the input
</li>
-<li>
+<li class="listitem">
The parser object
</li>
-<li>
+<li class="listitem">
Another parser called the skip parser
</li>
</ol></div>
<p>
In our example, we wish to skip spaces and tabs. Another parser named
- <tt class="computeroutput"><span class="identifier">space</span></tt> is included in Spirit's
+ <code class="computeroutput"><span class="identifier">space</span></code> is included in Spirit's
repertoire of predefined parsers. It is a very simple parser that simply
- recognizes whitespace. We will use <tt class="computeroutput"><span class="identifier">space</span></tt>
+ recognizes whitespace. We will use <code class="computeroutput"><span class="identifier">space</span></code>
as our skip parser. The skip parser is the one responsible for skipping
- characters in between parser elements such as the <tt class="computeroutput"><span class="identifier">double_</span></tt>
- and <tt class="computeroutput"><span class="identifier">char_</span></tt>.
+ characters in between parser elements such as the <code class="computeroutput"><span class="identifier">double_</span></code>
+ and <code class="computeroutput"><span class="identifier">char_</span></code>.
</p>
<p>
Ok, so now let's parse!
@@ -177,10 +174,10 @@
<span class="keyword">using</span> <span class="identifier">ascii</span><span class="special">::</span><span class="identifier">space</span><span class="special">;</span>
<span class="keyword">bool</span> <span class="identifier">r</span> <span class="special">=</span> <span class="identifier">phrase_parse</span><span class="special">(</span>
- <span class="identifier">first</span><span class="special">,</span> <span class="callout_bug"><a name="spirit0co" href="warming_up.html#spirit0"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span>
- <span class="identifier">last</span><span class="special">,</span> <span class="callout_bug"><a name="spirit1co" href="warming_up.html#spirit1"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span>
- <span class="identifier">double_</span> <span class="special">>></span> <span class="special">*(</span><span class="char">','</span> <span class="special">>></span> <span class="identifier">double_</span><span class="special">),</span> <span class="callout_bug"><a name="spirit2co" href="warming_up.html#spirit2"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span>
- <span class="identifier">space</span> <span class="callout_bug"><a name="spirit3co" href="warming_up.html#spirit3"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span>
+ <span class="identifier">first</span><span class="special">,</span> <span class="callout_bug"><a class="co" name="spirit0co" href="warming_up.html#spirit0"><img src="../../../../../../../doc/src/images/callouts/1.png" alt="1" border="0"></a></span>
+ <span class="identifier">last</span><span class="special">,</span> <span class="callout_bug"><a class="co" name="spirit1co" href="warming_up.html#spirit1"><img src="../../../../../../../doc/src/images/callouts/2.png" alt="2" border="0"></a></span>
+ <span class="identifier">double_</span> <span class="special">>></span> <span class="special">*(</span><span class="char">','</span> <span class="special">>></span> <span class="identifier">double_</span><span class="special">),</span> <span class="callout_bug"><a class="co" name="spirit2co" href="warming_up.html#spirit2"><img src="../../../../../../../doc/src/images/callouts/3.png" alt="3" border="0"></a></span>
+ <span class="identifier">space</span> <span class="callout_bug"><a class="co" name="spirit3co" href="warming_up.html#spirit3"><img src="../../../../../../../doc/src/images/callouts/4.png" alt="4" border="0"></a></span>
<span class="special">);</span>
<span class="keyword">if</span> <span class="special">(</span><span class="identifier">first</span> <span class="special">!=</span> <span class="identifier">last</span><span class="special">)</span> <span class="comment">// fail if we did not get a full match
</span> <span class="keyword">return</span> <span class="keyword">false</span><span class="special">;</span>
@@ -195,23 +192,19 @@
</p>
<div class="calloutlist"><table border="0" summary="Callout list">
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit0"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit0"></a> </p></td>
<td valign="top" align="left"><p> start iterator </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit1"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit1"></a> </p></td>
<td valign="top" align="left"><p> end iterator </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit2"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit2"></a> </p></td>
<td valign="top" align="left"><p> the parser </p></td>
</tr>
<tr>
-<td width="5%" valign="top" align="left">
-<a name="spirit3"></a> </td>
+<td width="5%" valign="top" align="left"><p><a name="spirit3"></a> </p></td>
<td valign="top" align="left"><p> the skip-parser </p></td>
</tr>
</table></div>
@@ -220,8 +213,8 @@
<p>
</p>
<p>
- The parse function returns <tt class="computeroutput"><span class="keyword">true</span></tt>
- or <tt class="computeroutput"><span class="keyword">false</span></tt> depending on the
+ The parse function returns <code class="computeroutput"><span class="keyword">true</span></code>
+ or <code class="computeroutput"><span class="keyword">false</span></code> depending on the
result of the parse. The first iterator is passed by reference. On a successful
parse, this iterator is repositioned to the rightmost position consumed
by the parser. If this becomes equal to str.end(), then we have a full
@@ -241,39 +234,39 @@
<p>
You can find the full cpp file here: ../../example/qi/num_list1.cpp
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- <tt class="computeroutput"><span class="keyword">char</span></tt> and <tt class="computeroutput"><span class="keyword">wchar_t</span></tt>
+ <code class="computeroutput"><span class="keyword">char</span></code> and <code class="computeroutput"><span class="keyword">wchar_t</span></code>
operands
</p>
<p>
- The careful reader may notice that the parser expression has <tt class="computeroutput"><span class="char">','</span></tt> instead of <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></tt>
+ The careful reader may notice that the parser expression has <code class="computeroutput"><span class="char">','</span></code> instead of <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">','</span><span class="special">)</span></code>
as the previous examples did. This is ok due to C++ syntax rules of conversion.
- There are <tt class="computeroutput"><span class="special">>></span></tt> operators
- that are overloaded to accept a <tt class="computeroutput"><span class="keyword">char</span></tt>
- or <tt class="computeroutput"><span class="keyword">wchar_t</span></tt> argument on its
+ There are <code class="computeroutput"><span class="special">>></span></code> operators
+ that are overloaded to accept a <code class="computeroutput"><span class="keyword">char</span></code>
+ or <code class="computeroutput"><span class="keyword">wchar_t</span></code> argument on its
left or right (but not both). An operator may be overloaded if at least
- one of its parameters is a user-defined type. In this case, the <tt class="computeroutput"><span class="identifier">double_</span></tt> is the 2nd argument to <tt class="computeroutput"><span class="keyword">operator</span><span class="special">>></span></tt>,
- and so the proper overload of <tt class="computeroutput"><span class="special">>></span></tt>
- is used, converting <tt class="computeroutput"><span class="char">','</span></tt> into
+ one of its parameters is a user-defined type. In this case, the <code class="computeroutput"><span class="identifier">double_</span></code> is the 2nd argument to <code class="computeroutput"><span class="keyword">operator</span><span class="special">>></span></code>,
+ and so the proper overload of <code class="computeroutput"><span class="special">>></span></code>
+ is used, converting <code class="computeroutput"><span class="char">','</span></code> into
a character literal parser.
</p>
<p>
- The problem with omiting the <tt class="computeroutput"><span class="identifier">char_</span></tt>
- should be obvious: <tt class="computeroutput"><span class="char">'a'</span> <span class="special">>></span>
- <span class="char">'b'</span></tt> is not a spirit parser, it is
+ The problem with omiting the <code class="computeroutput"><span class="identifier">char_</span></code>
+ should be obvious: <code class="computeroutput"><span class="char">'a'</span> <span class="special">>></span>
+ <span class="char">'b'</span></code> is not a spirit parser, it is
a numeric expression, right-shifting the ASCII (or another encoding)
- value of <tt class="computeroutput"><span class="char">'a'</span></tt> by the ASCII value
- of <tt class="computeroutput"><span class="char">'b'</span></tt>. However, both <tt class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">'a'</span><span class="special">)</span> <span class="special">>></span>
- <span class="char">'b'</span></tt> and <tt class="computeroutput"><span class="char">'a'</span>
- <span class="special">>></span> <span class="identifier">char_</span><span class="special">(</span><span class="char">'b'</span><span class="special">)</span></tt>
- are Spirit sequence parsers for the letter <tt class="computeroutput"><span class="char">'a'</span></tt>
- followed by <tt class="computeroutput"><span class="char">'b'</span></tt>. You'll get
+ value of <code class="computeroutput"><span class="char">'a'</span></code> by the ASCII value
+ of <code class="computeroutput"><span class="char">'b'</span></code>. However, both <code class="computeroutput"><span class="identifier">char_</span><span class="special">(</span><span class="char">'a'</span><span class="special">)</span> <span class="special">>></span>
+ <span class="char">'b'</span></code> and <code class="computeroutput"><span class="char">'a'</span>
+ <span class="special">>></span> <span class="identifier">char_</span><span class="special">(</span><span class="char">'b'</span><span class="special">)</span></code>
+ are Spirit sequence parsers for the letter <code class="computeroutput"><span class="char">'a'</span></code>
+ followed by <code class="computeroutput"><span class="char">'b'</span></code>. You'll get
used to it, sooner or later.
</p>
</td></tr>
Modified: trunk/libs/spirit/doc/html/spirit/references.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/references.html (original)
+++ trunk/libs/spirit/doc/html/spirit/references.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>References</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="acknowledgments.html" title="Acknowledgments">
+<link rel="prev" href="acknowledgments.html" title="Acknowledgments">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -21,13 +21,10 @@
<div class="spirit-nav">
<a accesskey="p" href="acknowledgments.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.references"></a>References
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="References">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.references"></a><a class="link" href="references.html" title="References">References</a>
+</h2></div></div></div>
<div class="informaltable"><table class="table">
<colgroup>
<col>
@@ -35,300 +32,444 @@
<col>
</colgroup>
<thead><tr>
-<th><p>
- </p></th>
-<th><p>
+<th>
+ <p>
+ </p>
+ </th>
+<th>
+ <p>
Authors
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Title, Publisher/link, Date Published
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
+<td>
+ <p>
1.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Todd Veldhuizen
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.extreme.indiana.edu/%7Etveldhui/papers/Expression-Templates/exprtmpl.html" target="_top">"Expression
Templates"</a>. C++ Report, June 1995.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
2.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Peter Naur (ed.)
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.masswerk.at/algol60/report.htm" target="_top">"Report
on the Algorithmic Language ALGOL 60"</a>. CACM, May 1960.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
3.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
ISO/IEC
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.cl.cam.ac.uk/%7Emgk25/iso-14977.pdf" target="_top">"ISO-EBNF"</a>,
ISO/IEC 14977: 1996(E).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
4.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Richard J.Botting, Ph.D.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.csci.csusb.edu/dick/maths/intro_ebnf.html" target="_top">"XBNF"</a>
(citing Leu-Weiner, 1973). California State University, San Bernardino,
1998.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
5.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
James Coplien.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
"Curiously Recurring Template Pattern". C++ Report, Feb.
1995.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
6.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Thierry Geraud and Alexandre Duret-Lutz
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.coldewey.com/europlop2000/papers/geraud%2Bduret.zip" target="_top">Generic
Programming Redesign of Patterns</a> Proceedings of the 5th European
Conference on Pattern Languages of Programs(EuroPLoP'2000) Irsee, Germany,
July 2000.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
7.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Geoffrey Furnish
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.adtmag.com/joop/carticle.aspx?ID=627" target="_top">"Disambiguated
Glommable Expression Templates Reintroduced"</a> C++ Report,
May 2000
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
8.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Erich Gamma, Richard Helm, Ralph Jhonson, and John Vlissides
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Design Patterns, Elements of Reusable Object-Oriented Software. Addison-Wesley,
1995.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
9.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Alfred V. Aho, Revi Sethi, Feffrey D. Ulman
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Compilers, Principles, Techniques and Tools Addison-Wesley, June 1987.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
10.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Dick Grune and Ceriel Jacobs
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.cs.vu.nl/%7Edick/PTAPG.html" target="_top">Parsing Techniques:
A Practical Guide.</a> Ellis Horwood Ltd.: West Sussex, England,
1990. (electronic copy, 1998).
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
11.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
T. J. Parr, H. G. Dietz, and W. E. Cohen
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://citeseer.ist.psu.edu/6885.html" target="_top">PCCTS Reference
Manual (Version 1.00)</a>. School of Electrical Engineering, Purdue
University, West Lafayette, August 1991.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
12.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Adrian Johnstone and Elizabeth Scott.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="ftp://ftp.cs.rhul.ac.uk/pub/rdp" target="_top">RDP, A Recursive Descent
Compiler Compiler</a>. Technical Report CSD TR 97 25, Dept. of
Computer Science, Egham, Surrey, England, Dec. 20, 1997.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
13.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Adrian Johnstone
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.cs.rhul.ac.uk/research/languages/projects/lookahead_backtrack.shtml" target="_top">Languages
and Architectures, Parser generators with backtrack or extended lookahead
capability</a> Department of Computer Science, Royal Holloway,
University of London, Egham, Surrey, England
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
14.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Damian Conway
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.csse.monash.edu.au/%7Edamian/papers/#Embedded_Input_Parsing_for_C" target="_top">Parsing
with C++ Classes</a>. ACM SIGPLAN Notices, 29:1, 1994.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
15.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Joel de Guzman
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://spirit.sourceforge.net/distrib/spirit_1_8_5/libs/spirit/index.html" target="_top">"Spirit
Version 1.8"</a>, 1998-2003.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
16.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
S. Doaitse Swierstra and Luc Duponcheel
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://citeseer.ist.psu.edu/448665.html" target="_top">Deterministic,
Error-Correcting Combinator Parsers</a> Dept. of Computer Science,
Utrecht University P.O.Box 80.089, 3508 TB Utrecht, The Netherland
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
17.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Bjarne Stroustrup
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.research.att.com/%7Ebs/whitespace98.pdf" target="_top">Generalizing
Overloading for C++2000</a> Overload, Issue 25. April 1, 1998.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
18.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Dr. John Maddock
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.boost.org/libs/regex/index.html" target="_top">Regex++ Documentation</a>
http://www.boost.org/libs/regex/index.htm
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
19.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Anonymous Edited by Graham Hutton
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.cs.nott.ac.uk/~gmh//faq.html" target="_top">Frequently Asked
Questions for comp.lang.functional</a>. Edited by Graham Hutton,
University of Nottingham.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
20.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Hewlett-Packard
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.sgi.com/tech/stl/" target="_top">Standard Template Library
Programmer's Guide.</a>, Hewlett-Packard Company, 1994
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
21.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Boost Libraries
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://boost.org/libs/libraries.htm" target="_top">Boost Libraries Documentation</a>.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
22.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Brian McNamara and Yannis Smaragdakis
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="http://www.cc.gatech.edu/~yannis/fc++/" target="_top">FC++:Functional
Programming in C++</a>.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
23.
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
Todd Veldhuizen
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
<a href="ftp://ftp.cs.indiana.edu/pub/techreports/TR542.pdf" target="_top">Techniques
for Scientic C++.</a>
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
</table></div>
Modified: trunk/libs/spirit/doc/html/spirit/repository.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/repository.html (original)
+++ trunk/libs/spirit/doc/html/spirit/repository.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,12 +1,12 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Spirit Repository</title>
+<title>Spirit Repository</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="notes/style_guide.html" title="Style Guide">
+<link rel="prev" href="notes/style_guide.html" title="Style Guide">
<link rel="next" href="acknowledgments.html" title="Acknowledgments">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="notes/style_guide.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="acknowledgments.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.repository"></a> Spirit Repository
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Spirit Repository">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.repository"></a><a class="link" href="repository.html" title="Spirit Repository"> Spirit Repository</a>
+</h2></div></div></div>
<p>
The Spirit repository is
a community effort collecting different reusable components (primitives, directives,
Modified: trunk/libs/spirit/doc/html/spirit/structure.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/structure.html (original)
+++ trunk/libs/spirit/doc/html/spirit/structure.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Structure</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="introduction.html" title="Introduction">
+<link rel="prev" href="introduction.html" title="Introduction">
<link rel="next" href="structure/include.html" title="Include">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="introduction.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="structure/include.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.structure"></a>Structure
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Structure">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.structure"></a><a class="link" href="structure.html" title="Structure">Structure</a>
+</h2></div></div></div>
<div class="toc"><dl><dt><span class="section">Include</span></dt></dl></div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/structure/include.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/structure/include.html (original)
+++ trunk/libs/spirit/doc/html/spirit/structure/include.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Include</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
<link rel="up" href="../structure.html" title="Structure">
-<link rel="previous" href="../structure.html" title="Structure">
+<link rel="prev" href="../structure.html" title="Structure">
<link rel="next" href="../abstracts.html" title="Abstracts">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="../structure.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../structure.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../abstracts.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.structure.include"></a>Include
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="Include">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.structure.include"></a><a class="link" href="include.html" title="Include">Include</a>
+</h3></div></div></div>
<p>
Spirit is a header file only library. There are no libraries to link to.
This section documents the structure of the Spirit headers.
@@ -37,23 +34,23 @@
Spirit contains five sub-libraries plus a 'support' module where common support
classes are placed:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
Classic
</li>
-<li>
+<li class="listitem">
Qi
</li>
-<li>
+<li class="listitem">
Karma
</li>
-<li>
+<li class="listitem">
Lex
</li>
-<li>
+<li class="listitem">
Phoenix
</li>
-<li>
+<li class="listitem">
Support
</li>
</ul></div>
@@ -109,26 +106,26 @@
is a special flat directory that contains all the spirit headers. To accomodate
the flat structure, the headers are prefixed with the sub-library name:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
classic_
</li>
-<li>
+<li class="listitem">
karma_
</li>
-<li>
+<li class="listitem">
lex_
</li>
-<li>
+<li class="listitem">
phoenix1_
</li>
-<li>
+<li class="listitem">
phoenix_
</li>
-<li>
+<li class="listitem">
qi_
</li>
-<li>
+<li class="listitem">
support_
</li>
</ul></div>
@@ -139,26 +136,26 @@
<p>
If you want to simply include the main sub-library name, then you can include:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
<boost/spirit/include/classic.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/karma.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/lex.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/phoenix1.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/phoenix.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/qi.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/include/support.hpp>
</li>
</ul></div>
@@ -177,23 +174,23 @@
<p>
As usual, these directories have their corresponding include files:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
<boost/spirit/home/classic.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/home/karma.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/home/lex.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/home/phoenix.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/home/qi.hpp>
</li>
-<li>
+<li class="listitem">
<boost/spirit/home/support.hpp>
</li>
</ul></div>
@@ -208,7 +205,7 @@
</p>
<p>
For some additional information about the rationale you might want to have
- a look at the FAQ entry <a href="../faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">Header
+ a look at the FAQ entry <a class="link" href="../faq.html#spirit.faq.i_m_very_confused_about_the_header_hell_in_my_boost_spirit_directory__what_s_all_this_about_">Header
Hell</a>.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/support.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/support.html (original)
+++ trunk/libs/spirit/doc/html/spirit/support.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> Supporting libraries</title>
+<title>Supporting libraries</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="lex/reference/tokendef_class.html" title="TokenDef Class">
-<link rel="next" href="support/multi_pass.html" title=" The multi pass iterator">
+<link rel="prev" href="lex/reference/tokendef_class.html" title="TokenDef Class">
+<link rel="next" href="support/multi_pass.html" title="The multi pass iterator">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,13 +22,10 @@
<div class="spirit-nav">
<a accesskey="p" href="lex/reference/tokendef_class.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="support/multi_pass.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.support"></a> Supporting libraries
-</h2></div></div>
-<div></div>
-</div>
+<div class="section" title="Supporting libraries">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.support"></a><a class="link" href="support.html" title="Supporting libraries"> Supporting libraries</a>
+</h2></div></div></div>
<div class="toc"><dl><dt><span class="section"> The multi pass iterator</span></dt></dl></div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
Modified: trunk/libs/spirit/doc/html/spirit/support/multi_pass.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/support/multi_pass.html (original)
+++ trunk/libs/spirit/doc/html/spirit/support/multi_pass.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -1,13 +1,13 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title> The multi pass iterator</title>
+<title>The multi pass iterator</title>
<link rel="stylesheet" href="../../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../../index.html" title="Spirit 2.1">
-<link rel="up" href="../support.html" title=" Supporting libraries">
-<link rel="previous" href="../support.html" title=" Supporting libraries">
-<link rel="next" href="../faq.html" title=" Spirit FAQ">
+<link rel="up" href="../support.html" title="Supporting libraries">
+<link rel="prev" href="../support.html" title="Supporting libraries">
+<link rel="next" href="../faq.html" title="Spirit FAQ">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -22,34 +22,31 @@
<div class="spirit-nav">
<a accesskey="p" href="../support.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../support.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../faq.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h3 class="title">
-<a name="spirit.support.multi_pass"></a> The multi pass iterator
-</h3></div></div>
-<div></div>
-</div>
+<div class="section" title="The multi pass iterator">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="spirit.support.multi_pass"></a><a class="link" href="multi_pass.html" title="The multi pass iterator"> The multi pass iterator</a>
+</h3></div></div></div>
<p>
Backtracking in <span class="emphasis"><em>Spirit.Qi</em></span> requires the use of the following
types of iterator: forward, bidirectional, or random access. Because of backtracking,
input iterators cannot be used. Therefore, the standard library classes
- <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span></tt> and <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span></tt>,
+ <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span></code> and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span></code>,
that fall under the category of input iterators, cannot be used. Another
input iterator that is of interest is one that wraps a lexer, such as LEX.
</p>
-<div class="note"><table border="0" summary="Note">
+<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../images/note.png"></td>
<th align="left">Note</th>
</tr>
-<tr><td colspan="2" align="left" valign="top"><p>
+<tr><td align="left" valign="top"><p>
In general, <span class="emphasis"><em>Spirit.Qi</em></span> generates recursive descent
parser which require backtracking parsers by design. For this reason we
need to provide at least forward iterators to any of <span class="emphasis"><em>Spirit.Qi</em></span>'s
API functions. This is not an absolute requirement though. In the future,
we shall see more deterministic parsers that require no more than 1 character
(token) of lookahead. Such parsers allow us to use input iterators such
- as the <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span></tt> as is.
+ as the <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span></code> as is.
</p></td></tr>
</table></div>
<p>
@@ -60,53 +57,53 @@
to this problem is to simply load all the data to be parsed into a container,
such as a vector or deque, and then pass the begin and end of the container
to <span class="emphasis"><em>Spirit.Qi</em></span>. This method can be too memory intensive
- for certain applications, which is why the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ for certain applications, which is why the <code class="computeroutput"><span class="identifier">multi_pass</span></code>
iterator was created.
</p>
-<a name="spirit.support.multi_pass.using_the_multi_pass"></a><h4>
-<a name="id621798"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.using_the_multi_pass">Using the
+<a name="spirit.support.multi_pass.using_the_multi_pass"></a><h5>
+<a name="id1327676"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.using_the_multi_pass">Using the
multi_pass</a>
- </h4>
+ </h5>
<p>
- The <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> iterator will
+ The <code class="computeroutput"><span class="identifier">multi_pass</span></code> iterator will
convert any input iterator into a forward iterator suitable for use with
- <span class="emphasis"><em>Spirit.Qi</em></span>. <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ <span class="emphasis"><em>Spirit.Qi</em></span>. <code class="computeroutput"><span class="identifier">multi_pass</span></code>
will buffer data when needed and will discard the buffer when its contents
is not needed anymore. This happens either if only one copy of the iterator
exists or if no backtracking can occur.
</p>
<p>
- A grammar must be designed with care if the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ A grammar must be designed with care if the <code class="computeroutput"><span class="identifier">multi_pass</span></code>
iterator is used. Any rule that may need to backtrack, such as one that contains
an alternative, will cause data to be buffered. The rules that are optimal
to use are repetition constructs (as kleene and plus).
</p>
<p>
- Sequences of the form <tt class="computeroutput"><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span></tt>
+ Sequences of the form <code class="computeroutput"><span class="identifier">a</span> <span class="special">>></span> <span class="identifier">b</span></code>
will buffer data as well. This is different from the behaviour of <span class="emphasis"><em>Spirit.Classic</em></span>
but for a good reason. Sequences need to reset the current iterator to its
initial state if one of the components of a seqeunce fails to match. To compensate
- for this behaviour we added functionality to the <tt class="computeroutput"><span class="identifier">expect</span></tt>
- parsers (i.e. constructs like <tt class="computeroutput"><span class="identifier">a</span>
- <span class="special">></span> <span class="identifier">b</span></tt>).
+ for this behaviour we added functionality to the <code class="computeroutput"><span class="identifier">expect</span></code>
+ parsers (i.e. constructs like <code class="computeroutput"><span class="identifier">a</span>
+ <span class="special">></span> <span class="identifier">b</span></code>).
Expectation points introduce deterministic points into the grammar ensuring
no backtracking can occur if they match. For this reason we clear the buffers
of any multi_pass iterator on each expectation point, ensuring minimal buffer
content even for large grammars.
</p>
-<div class="important"><table border="0" summary="Important">
+<div class="important" title="Important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../images/important.png"></td>
<th align="left">Important</th>
</tr>
-<tr><td colspan="2" align="left" valign="top">
+<tr><td align="left" valign="top">
<p>
- If you use an error handler in conjunction with the <tt class="computeroutput"><span class="identifier">expect</span></tt>
- parser while utilizing a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- iterator and you intend to use the error handler to force a <tt class="computeroutput"><span class="identifier">retry</span></tt> or a <tt class="computeroutput"><span class="identifier">fail</span></tt>
- (see the description of error handlers - <span class="bold"><b>FIXME</b></span>:
- insert link), then you need to instantiate the error handler using <tt class="computeroutput"><span class="identifier">retry</span></tt> or <tt class="computeroutput"><span class="identifier">fail</span></tt>,
+ If you use an error handler in conjunction with the <code class="computeroutput"><span class="identifier">expect</span></code>
+ parser while utilizing a <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ iterator and you intend to use the error handler to force a <code class="computeroutput"><span class="identifier">retry</span></code> or a <code class="computeroutput"><span class="identifier">fail</span></code>
+ (see the description of error handlers - <span class="bold"><strong>FIXME</strong></span>:
+ insert link), then you need to instantiate the error handler using <code class="computeroutput"><span class="identifier">retry</span></code> or <code class="computeroutput"><span class="identifier">fail</span></code>,
for instance:
</p>
<pre class="programlisting"><span class="identifier">rule</span> <span class="identifier">r</span><span class="special"><</span><span class="identifier">iterator_type</span><span class="special">></span> <span class="identifier">r</span><span class="special">;</span>
@@ -119,7 +116,7 @@
</td></tr>
</table></div>
<p>
- Any rule that repeats, such as kleene_star (<tt class="computeroutput"><span class="special">*</span><span class="identifier">a</span></tt>) or positive such as (<tt class="computeroutput"><span class="special">+</span><span class="identifier">a</span></tt>), will only buffer the data for the current
+ Any rule that repeats, such as kleene_star (<code class="computeroutput"><span class="special">*</span><span class="identifier">a</span></code>) or positive such as (<code class="computeroutput"><span class="special">+</span><span class="identifier">a</span></code>), will only buffer the data for the current
repetition.
</p>
<p>
@@ -127,8 +124,8 @@
In fact, many well designed languages are fully deterministic and require
no lookahead at all. Peeking at the first character from the input will immediately
determine the alternative branch to take. Yet, even with highly ambiguous
- grammars, alternatives are often of the form <tt class="computeroutput"><span class="special">*(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span>
- <span class="special">|</span> <span class="identifier">c</span> <span class="special">|</span> <span class="identifier">d</span><span class="special">)</span></tt>.
+ grammars, alternatives are often of the form <code class="computeroutput"><span class="special">*(</span><span class="identifier">a</span> <span class="special">|</span> <span class="identifier">b</span>
+ <span class="special">|</span> <span class="identifier">c</span> <span class="special">|</span> <span class="identifier">d</span><span class="special">)</span></code>.
The input iterator moves on and is never stuck at the beginning. Let's look
at a Pascal snippet for example:
</p>
@@ -155,17 +152,17 @@
star moves on to the next.
</p>
<p>
- Now, after the lecture on the features to be careful with when using <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>, you may think that <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> is way too restrictive to use.
+ Now, after the lecture on the features to be careful with when using <code class="computeroutput"><span class="identifier">multi_pass</span></code>, you may think that <code class="computeroutput"><span class="identifier">multi_pass</span></code> is way too restrictive to use.
That's not the case. If your grammar is deterministic, you can make use of
- the <tt class="computeroutput"><span class="identifier">flush_multi_pass</span></tt> pseudo
+ the <code class="computeroutput"><span class="identifier">flush_multi_pass</span></code> pseudo
parser in your grammar to ensure that data is not buffered when unnecessary
- (<tt class="computeroutput"><span class="identifier">flush_multi_pass</span></tt> is available
+ (<code class="computeroutput"><span class="identifier">flush_multi_pass</span></code> is available
from the <span class="emphasis"><em>Spirit.Qi</em></span> parser Repository).
</p>
<p>
- Here we present a minimal example showing a minimal use case. The <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> iterator is highly configurable,
+ Here we present a minimal example showing a minimal use case. The <code class="computeroutput"><span class="identifier">multi_pass</span></code> iterator is highly configurable,
but the default policies have been chosen so that its easily usable with
- input iterators such as <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span></tt>.
+ input iterators such as <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span></code>.
For the complete source code of this example please refer to multi_pass.cpp.
</p>
<p>
@@ -211,46 +208,46 @@
</p>
<p>
</p>
-<a name="spirit.support.multi_pass.using_the_flush_multi_pass_parser"></a><h4>
-<a name="id623590"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.using_the_flush_multi_pass_parser">Using
+<a name="spirit.support.multi_pass.using_the_flush_multi_pass_parser"></a><h5>
+<a name="id1328945"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.using_the_flush_multi_pass_parser">Using
the flush_multi_pass parser</a>
- </h4>
+ </h5>
<p>
The Spirit Repository
- contains the <tt class="computeroutput"><span class="identifier">flush_multi_pass</span></tt>
- parser component. This is usable in conjunction with the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ contains the <code class="computeroutput"><span class="identifier">flush_multi_pass</span></code>
+ parser component. This is usable in conjunction with the <code class="computeroutput"><span class="identifier">multi_pass</span></code>
iterator to minimize the buffering. It allows to insert explicit synchronization
points into your grammar where it is safe to clear any stored input as it
is ensured that no backtracking can occur at this point anymore.
</p>
<p>
- When the <tt class="computeroutput"><span class="identifier">flush_multi_pass</span></tt>
- parser is used with <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>,
- it will call <tt class="computeroutput"><span class="identifier">multi_pass</span><span class="special">::</span><span class="identifier">clear_queue</span><span class="special">()</span></tt>.
+ When the <code class="computeroutput"><span class="identifier">flush_multi_pass</span></code>
+ parser is used with <code class="computeroutput"><span class="identifier">multi_pass</span></code>,
+ it will call <code class="computeroutput"><span class="identifier">multi_pass</span><span class="special">::</span><span class="identifier">clear_queue</span><span class="special">()</span></code>.
This will cause any buffered data to be erased. This also will invalidate
all other copies of multi_pass and they should not be used. If they are,
- an <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">illegal_backtracking</span></tt> exception will be
+ an <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">illegal_backtracking</span></code> exception will be
thrown.
</p>
-<a name="spirit.support.multi_pass.the_multi_pass_policies"></a><h4>
-<a name="id623745"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.the_multi_pass_policies">The multi_pass
+<a name="spirit.support.multi_pass.the_multi_pass_policies"></a><h5>
+<a name="id1329038"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.the_multi_pass_policies">The multi_pass
Policies</a>
- </h4>
+ </h5>
<p>
- The <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> iterator is
- a templated class configurable using policies. The description of <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> above is how it was originally
+ The <code class="computeroutput"><span class="identifier">multi_pass</span></code> iterator is
+ a templated class configurable using policies. The description of <code class="computeroutput"><span class="identifier">multi_pass</span></code> above is how it was originally
implemented (before it used policies), and is the default configuration now.
- But, <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> is capable
+ But, <code class="computeroutput"><span class="identifier">multi_pass</span></code> is capable
of much more. Because of the open-ended nature of policies, you can write
- your own policy to make <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ your own policy to make <code class="computeroutput"><span class="identifier">multi_pass</span></code>
behave in a way that we never before imagined.
</p>
<p>
The multi_pass class has two template parameters:
</p>
-<div class="variablelist">
+<div class="variablelist" title="The multi_pass template parameters">
<p class="title"><b>The multi_pass template parameters</b></p>
<dl>
<dt><span class="term">Input</span></dt>
@@ -269,276 +266,352 @@
It is possible to implement all of the required functionality of the combinded
policy in a single class. But it has shown to be more convenient to split
this into four different groups of functions, i.e. four separate, but well
- coordinated policies. For this reason the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- framework implements a template <tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">default_policy</span></tt>
+ coordinated policies. For this reason the <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ framework implements a template <code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">default_policy</span></code>
allowing to combine several different policies, each implementing one of
the functionality groups:
</p>
<div class="table">
-<a name="id623908"></a><p class="title"><b>Table 13. Policies needed for default_policy template</b></p>
-<table class="table" summary="Policies needed for default_policy template">
+<a name="id1329144"></a><p class="title"><b>Table 13. Policies needed for default_policy template</b></p>
+<div class="table-contents"><table class="table" summary="Policies needed for default_policy template">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Template Parameter
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">OwnershipPolicy</span></tt>
- </p></td>
-<td><p>
- This policy determines how <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">OwnershipPolicy</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This policy determines how <code class="computeroutput"><span class="identifier">multi_pass</span></code>
deals with it's shared components.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">CheckingPolicy</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">CheckingPolicy</span></code>
+ </p>
+ </td>
+<td>
+ <p>
This policy determines how checking for invalid iterators is done.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">InputPolicy</span></tt>
- </p></td>
-<td><p>
- A class that defines how <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- acquires its input. The <tt class="computeroutput"><span class="identifier">InputPolicy</span></tt>
- is parameterized by the <tt class="computeroutput"><span class="identifier">Input</span></tt>
- template parameter to the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">StoragePolicy</span></tt>
- </p></td>
-<td><p>
- The buffering scheme used by <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">InputPolicy</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ A class that defines how <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ acquires its input. The <code class="computeroutput"><span class="identifier">InputPolicy</span></code>
+ is parameterized by the <code class="computeroutput"><span class="identifier">Input</span></code>
+ template parameter to the <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">StoragePolicy</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ The buffering scheme used by <code class="computeroutput"><span class="identifier">multi_pass</span></code>
is determined and managed by the StoragePolicy.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<p>
- The <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> framework
+<br class="table-break"><p>
+ The <code class="computeroutput"><span class="identifier">multi_pass</span></code> framework
contains several predefined policy implementations for each of the policy
types as described above. First we will describe those predefined types.
Afterwards we will give some guidelines how you can write your own policy
implementations.
</p>
-<a name="spirit.support.multi_pass.predefined_policies"></a><h4>
-<a name="id624173"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.predefined_policies">Predefined
+<a name="spirit.support.multi_pass.predefined_policies"></a><h5>
+<a name="id1329336"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.predefined_policies">Predefined
policies</a>
- </h4>
+ </h5>
<p>
- All predefined <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- policies are defined in the namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">iterator_policies</span></tt>.
+ All predefined <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ policies are defined in the namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">iterator_policies</span></code>.
</p>
<div class="table">
-<a name="id624238"></a><p class="title"><b>Table 14. Predefined policy classes</b></p>
-<table class="table" summary="Predefined policy classes">
+<a name="id1329378"></a><p class="title"><b>Table 14. Predefined policy classes</b></p>
+<div class="table-contents"><table class="table" summary="Predefined policy classes">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
-<th><p>
+<th>
+ <p>
Class name
- </p></th>
-<th><p>
+ </p>
+ </th>
+<th>
+ <p>
Description
- </p></th>
+ </p>
+ </th>
</tr></thead>
<tbody>
<tr>
-<td><p>
- <span class="bold"><b>InputPolicy</b></span> classes
- </p></td>
+<td>
+ <p>
+ <span class="bold"><strong>InputPolicy</strong></span> classes
+ </p>
+ </td>
<td class="auto-generated"> </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">input_iterator</span></tt>
- </p></td>
-<td><p>
- This policy directs <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- to read from an input iterator of type <tt class="computeroutput"><span class="identifier">Input</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">lex_input</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">input_iterator</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This policy directs <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ to read from an input iterator of type <code class="computeroutput"><span class="identifier">Input</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">lex_input</span></code>
+ </p>
+ </td>
+<td>
+ <p>
This policy obtains it's input by calling yylex(), which would typically
be provided by a scanner generated by Flex.
If you use this policy your code must link against a Flex
generated scanner.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">functor_input</span></tt>
- </p></td>
-<td><p>
- This input policy obtains it's data by calling a functor of type <tt class="computeroutput"><span class="identifier">Input</span></tt>. The functor must meet certain
- requirements. It must have a typedef called <tt class="computeroutput"><span class="identifier">result_type</span></tt>
- which should be the type returned from <tt class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></tt>. Also, since an input policy needs
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">functor_input</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This input policy obtains it's data by calling a functor of type <code class="computeroutput"><span class="identifier">Input</span></code>. The functor must meet certain
+ requirements. It must have a typedef called <code class="computeroutput"><span class="identifier">result_type</span></code>
+ which should be the type returned from <code class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></code>. Also, since an input policy needs
a way to determine when the end of input has been reached, the functor
- must contain a static variable named <tt class="computeroutput"><span class="identifier">eof</span></tt>
- which is comparable to a variable of <tt class="computeroutput"><span class="identifier">result_type</span></tt>.
- </p></td>
+ must contain a static variable named <code class="computeroutput"><span class="identifier">eof</span></code>
+ which is comparable to a variable of <code class="computeroutput"><span class="identifier">result_type</span></code>.
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">split_functor_input</span></tt>
- </p></td>
-<td><p>
- This is essentially the same as the <tt class="computeroutput"><span class="identifier">functor_input</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">split_functor_input</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This is essentially the same as the <code class="computeroutput"><span class="identifier">functor_input</span></code>
policy except that the (user supplied) funtion object exposes separate
- <tt class="computeroutput"><span class="identifier">unique</span></tt> and <tt class="computeroutput"><span class="identifier">shared</span></tt> sub classes, allowing to integrate
- the functors <span class="emphasis"><em>unique</em></span> data members with the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> data items held by each
+ <code class="computeroutput"><span class="identifier">unique</span></code> and <code class="computeroutput"><span class="identifier">shared</span></code> sub classes, allowing to integrate
+ the functors <span class="emphasis"><em>unique</em></span> data members with the <code class="computeroutput"><span class="identifier">multi_pass</span></code> data items held by each
instance and its <span class="emphasis"><em>shared</em></span> data members will be integrated
- with the <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ with the <code class="computeroutput"><span class="identifier">multi_pass</span></code>
members shared by all copies.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="bold"><b>OwnershipPolicy</b></span> classes
- </p></td>
+<td>
+ <p>
+ <span class="bold"><strong>OwnershipPolicy</strong></span> classes
+ </p>
+ </td>
<td class="auto-generated"> </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">ref_counted</span></tt>
- </p></td>
-<td><p>
- This class uses a reference counting scheme. The <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">ref_counted</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This class uses a reference counting scheme. The <code class="computeroutput"><span class="identifier">multi_pass</span></code>
will delete it's shared components when the count reaches zero.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">first_owner</span></tt>
- </p></td>
-<td><p>
- When this policy is used, the first <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">first_owner</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ When this policy is used, the first <code class="computeroutput"><span class="identifier">multi_pass</span></code>
created will be the one that deletes the shared data. Each copy will
not take ownership of the shared data. This works well for Spirit,
since no dynamic allocation of iterators is done. All copies are made
on the stack, so the original iterator has the longest lifespan.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="bold"><b>CheckingPolicy</b></span> classes
- </p></td>
+<td>
+ <p>
+ <span class="bold"><strong>CheckingPolicy</strong></span> classes
+ </p>
+ </td>
<td class="auto-generated"> </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">no_check</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">no_check</span></code>
+ </p>
+ </td>
+<td>
+ <p>
This policy does no checking at all.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">buf_id_check</span></tt>
- </p></td>
-<td><p>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">buf_id_check</span></code>
+ </p>
+ </td>
+<td>
+ <p>
This policy keeps around a buffer id, or a buffer age. Every time
- <tt class="computeroutput"><span class="identifier">clear_queue</span><span class="special">()</span></tt>
- is called on a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
+ <code class="computeroutput"><span class="identifier">clear_queue</span><span class="special">()</span></code>
+ is called on a <code class="computeroutput"><span class="identifier">multi_pass</span></code>
iterator, it is possible that all other iterators become invalid. When
- <tt class="computeroutput"><span class="identifier">clear_queue</span><span class="special">()</span></tt>
- is called, <tt class="computeroutput"><span class="identifier">buf_id_check</span></tt>
+ <code class="computeroutput"><span class="identifier">clear_queue</span><span class="special">()</span></code>
+ is called, <code class="computeroutput"><span class="identifier">buf_id_check</span></code>
increments the buffer id. When an iterator is dereferenced, this policy
checks that the buffer id of the iterator matches the shared buffer
- id. This policy is most effective when used together with the <tt class="computeroutput"><span class="identifier">split_std_deque</span></tt> StoragePolicy. It
- should not be used with the <tt class="computeroutput"><span class="identifier">fixed_size_queue</span></tt>
+ id. This policy is most effective when used together with the <code class="computeroutput"><span class="identifier">split_std_deque</span></code> StoragePolicy. It
+ should not be used with the <code class="computeroutput"><span class="identifier">fixed_size_queue</span></code>
StoragePolicy, because it will not detect iterator dereferences that
are out of range.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
+<td>
+ <p>
full_check
- </p></td>
-<td><p>
+ </p>
+ </td>
+<td>
+ <p>
This policy has not been implemented yet. When it is, it will keep
track of all iterators and make sure that they are all valid. This
will be mostly useful for debugging purposes as it will incur significant
overhead.
- </p></td>
+ </p>
+ </td>
</tr>
<tr>
-<td><p>
- <span class="bold"><b>StoragePolicy</b></span> classes
- </p></td>
+<td>
+ <p>
+ <span class="bold"><strong>StoragePolicy</strong></span> classes
+ </p>
+ </td>
<td class="auto-generated"> </td>
</tr>
<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">split_std_deque</span></tt>
- </p></td>
-<td><p>
- Despite its name this policy keeps all buffered data in a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></tt>. All data is stored as long
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">split_std_deque</span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ Despite its name this policy keeps all buffered data in a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span></code>. All data is stored as long
as there is more than one iterator. Once the iterator count goes down
to one, and the queue is no longer needed, it is cleared, freeing up
- memory. The queue can also be forcibly cleared by calling <tt class="computeroutput"><span class="identifier">multi_pass</span><span class="special">::</span><span class="identifier">clear_queue</span><span class="special">()</span></tt>.
- </p></td>
-</tr>
-<tr>
-<td><p>
- <tt class="computeroutput"><span class="identifier">fixed_size_queue</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></tt>
- </p></td>
-<td><p>
- This policy keeps a circular buffer that is size <tt class="computeroutput"><span class="identifier">N</span><span class="special">+</span><span class="number">1</span></tt> and
- stores <tt class="computeroutput"><span class="identifier">N</span></tt> elements.
- <tt class="computeroutput"><span class="identifier">fixed_size_queue</span></tt> is
- a template with a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span></tt>
+ memory. The queue can also be forcibly cleared by calling <code class="computeroutput"><span class="identifier">multi_pass</span><span class="special">::</span><span class="identifier">clear_queue</span><span class="special">()</span></code>.
+ </p>
+ </td>
+</tr>
+<tr>
+<td>
+ <p>
+ <code class="computeroutput"><span class="identifier">fixed_size_queue</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></code>
+ </p>
+ </td>
+<td>
+ <p>
+ This policy keeps a circular buffer that is size <code class="computeroutput"><span class="identifier">N</span><span class="special">+</span><span class="number">1</span></code> and
+ stores <code class="computeroutput"><span class="identifier">N</span></code> elements.
+ <code class="computeroutput"><span class="identifier">fixed_size_queue</span></code> is
+ a template with a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span></code>
parameter that specified the queue size. It is your responsibility
- to ensure that <tt class="computeroutput"><span class="identifier">N</span></tt> is
+ to ensure that <code class="computeroutput"><span class="identifier">N</span></code> is
big enough for your parser. Whenever the foremost iterator is incremented,
the last character of the buffer is automatically erased. Currently
there is no way to tell if an iterator is trailing too far behind and
has become invalid. No dynamic allocation is done by this policy during
normal iterator operation, only on initial construction. The memory
- usage of this <tt class="computeroutput"><span class="identifier">StoragePolicy</span></tt>
- is set at <tt class="computeroutput"><span class="identifier">N</span><span class="special">+</span><span class="number">1</span></tt> bytes, unlike <tt class="computeroutput"><span class="identifier">split_std_deque</span></tt>,
+ usage of this <code class="computeroutput"><span class="identifier">StoragePolicy</span></code>
+ is set at <code class="computeroutput"><span class="identifier">N</span><span class="special">+</span><span class="number">1</span></code> bytes, unlike <code class="computeroutput"><span class="identifier">split_std_deque</span></code>,
which is unbounded.
- </p></td>
+ </p>
+ </td>
</tr>
</tbody>
-</table>
+</table></div>
</div>
-<a name="spirit.support.multi_pass.combinations__how_to_specify_your_own_custom_multi_pass"></a><h4>
-<a name="id625185"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.combinations__how_to_specify_your_own_custom_multi_pass">Combinations:
+<br class="table-break"><a name="spirit.support.multi_pass.combinations__how_to_specify_your_own_custom_multi_pass"></a><h5>
+<a name="id1331154"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.combinations__how_to_specify_your_own_custom_multi_pass">Combinations:
How to specify your own custom multi_pass</a>
- </h4>
+ </h5>
<p>
The beauty of policy based designs is that you can mix and match policies
to create your own custom iterator by selecting the policies you want. Here's
- an example of how to specify a custom <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- that wraps an <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></tt>,
- and is slightly more efficient than the default <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- (as generated by the <tt class="computeroutput"><span class="identifier">make_default_multi_pass</span><span class="special">()</span></tt> API function) because it uses the <tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">first_owner</span></tt> OwnershipPolicy and the <tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">no_check</span></tt> CheckingPolicy:
+ an example of how to specify a custom <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ that wraps an <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></code>,
+ and is slightly more efficient than the default <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ (as generated by the <code class="computeroutput"><span class="identifier">make_default_multi_pass</span><span class="special">()</span></code> API function) because it uses the <code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">first_owner</span></code> OwnershipPolicy and the <code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">no_check</span></code> CheckingPolicy:
</p>
<pre class="programlisting"><span class="keyword">typedef</span> <span class="identifier">multi_pass</span><span class="special"><</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span>
@@ -551,60 +624,60 @@
<span class="special">></span> <span class="identifier">first_owner_multi_pass_type</span><span class="special">;</span>
</pre>
<p>
- The default template parameters for <tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">default_policy</span></tt>
+ The default template parameters for <code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">default_policy</span></code>
are:
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
-<tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">ref_counted</span></tt> OwnershipPolicy
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">ref_counted</span></code> OwnershipPolicy
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">no_check</span></tt> CheckingPolicy, if <tt class="computeroutput"><span class="identifier">BOOST_SPIRIT_DEBUG</span></tt> is defined: <tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">buf_id_check</span></tt> CheckingPolicy
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">no_check</span></code> CheckingPolicy, if <code class="computeroutput"><span class="identifier">BOOST_SPIRIT_DEBUG</span></code> is defined: <code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">buf_id_check</span></code> CheckingPolicy
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">input_iterator</span></tt> InputPolicy, and
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">input_iterator</span></code> InputPolicy, and
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">split_std_deque</span></tt> StoragePolicy.
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">iterator_policies</span><span class="special">::</span><span class="identifier">split_std_deque</span></code> StoragePolicy.
</li>
</ul></div>
<p>
- So if you use <tt class="computeroutput"><span class="identifier">multi_pass</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span>
- <span class="special">></span></tt> you will get those pre-defined
- behaviors while wrapping an <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></tt>.
- </p>
-<a name="spirit.support.multi_pass.dealing_with_constant_look_ahead"></a><h4>
-<a name="id625802"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.dealing_with_constant_look_ahead">Dealing
+ So if you use <code class="computeroutput"><span class="identifier">multi_pass</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span>
+ <span class="special">></span></code> you will get those pre-defined
+ behaviors while wrapping an <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">istream_iterator</span><span class="special"><</span><span class="keyword">char</span><span class="special">></span></code>.
+ </p>
+<a name="spirit.support.multi_pass.dealing_with_constant_look_ahead"></a><h5>
+<a name="id1331576"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.dealing_with_constant_look_ahead">Dealing
with constant look ahead</a>
- </h4>
+ </h5>
<p>
- There is one other pre-defined class called <tt class="computeroutput"><span class="identifier">look_ahead</span></tt>.
- The class <tt class="computeroutput"><span class="identifier">look_ahead</span></tt> is another
- predefine <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> iterator
- type. It has two template parameters: <tt class="computeroutput"><span class="identifier">Input</span></tt>,
- the type of the input iterator to wrap, and a <tt class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">N</span></tt>, which specifies the size of the buffer
- to the <tt class="computeroutput"><span class="identifier">fixed_size_queue</span></tt> policy.
- While the default multi_pass configuration is designed for safey, <tt class="computeroutput"><span class="identifier">look_ahead</span></tt> is designed for speed. <tt class="computeroutput"><span class="identifier">look_ahead</span></tt> is derived from a multi_pass
- with the following policies: <tt class="computeroutput"><span class="identifier">input_iterator</span></tt>
- InputPolicy, <tt class="computeroutput"><span class="identifier">first_owner</span></tt>
- OwnershipPolicy, <tt class="computeroutput"><span class="identifier">no_check</span></tt>
- CheckingPolicy, and <tt class="computeroutput"><span class="identifier">fixed_size_queue</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></tt>
+ There is one other pre-defined class called <code class="computeroutput"><span class="identifier">look_ahead</span></code>.
+ The class <code class="computeroutput"><span class="identifier">look_ahead</span></code> is another
+ predefine <code class="computeroutput"><span class="identifier">multi_pass</span></code> iterator
+ type. It has two template parameters: <code class="computeroutput"><span class="identifier">Input</span></code>,
+ the type of the input iterator to wrap, and a <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">N</span></code>, which specifies the size of the buffer
+ to the <code class="computeroutput"><span class="identifier">fixed_size_queue</span></code> policy.
+ While the default multi_pass configuration is designed for safey, <code class="computeroutput"><span class="identifier">look_ahead</span></code> is designed for speed. <code class="computeroutput"><span class="identifier">look_ahead</span></code> is derived from a multi_pass
+ with the following policies: <code class="computeroutput"><span class="identifier">input_iterator</span></code>
+ InputPolicy, <code class="computeroutput"><span class="identifier">first_owner</span></code>
+ OwnershipPolicy, <code class="computeroutput"><span class="identifier">no_check</span></code>
+ CheckingPolicy, and <code class="computeroutput"><span class="identifier">fixed_size_queue</span><span class="special"><</span><span class="identifier">N</span><span class="special">></span></code>
StoragePolicy.
</p>
-<a name="spirit.support.multi_pass.how_to_write_a_functor_for_use_with_the__code__phrase_role__identifier__functor_input__phrase___code__inputpolicy"></a><h4>
-<a name="id626017"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.how_to_write_a_functor_for_use_with_the__code__phrase_role__identifier__functor_input__phrase___code__inputpolicy">How
- to write a functor for use with the <tt class="computeroutput"><span class="identifier">functor_input</span></tt>
+<a name="spirit.support.multi_pass.how_to_write_a_functor_for_use_with_the__code__phrase_role__identifier__functor_input__phrase___code__inputpolicy"></a><h5>
+<a name="id1331708"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.how_to_write_a_functor_for_use_with_the__code__phrase_role__identifier__functor_input__phrase___code__inputpolicy">How
+ to write a functor for use with the <code class="computeroutput"><span class="identifier">functor_input</span></code>
InputPolicy</a>
- </h4>
+ </h5>
<p>
- If you want to use the <tt class="computeroutput"><span class="identifier">functor_input</span></tt>
+ If you want to use the <code class="computeroutput"><span class="identifier">functor_input</span></code>
InputPolicy, you can write your own function object that will supply the
- input to <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>. The
+ input to <code class="computeroutput"><span class="identifier">multi_pass</span></code>. The
function object must satisfy several requirements. It must have a typedef
- <tt class="computeroutput"><span class="identifier">result_type</span></tt> which specifies
- the return type of its <tt class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></tt>. This is standard practice in the STL.
+ <code class="computeroutput"><span class="identifier">result_type</span></code> which specifies
+ the return type of its <code class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></code>. This is standard practice in the STL.
Also, it must supply a static variable called eof which is compared against
to know whether the input has reached the end. Last but not least the function
object must be default constructible. Here is an example:
@@ -651,29 +724,29 @@
<span class="special">++</span><span class="identifier">first</span><span class="special">;</span>
<span class="special">}</span>
</pre>
-<a name="spirit.support.multi_pass.how_to_write_policies_for_use_with_multi_pass"></a><h4>
-<a name="id626836"></a>
- <a href="multi_pass.html#spirit.support.multi_pass.how_to_write_policies_for_use_with_multi_pass">How
+<a name="spirit.support.multi_pass.how_to_write_policies_for_use_with_multi_pass"></a><h5>
+<a name="id1332295"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.how_to_write_policies_for_use_with_multi_pass">How
to write policies for use with multi_pass</a>
- </h4>
+ </h5>
<p>
- All policies to be used with the <tt class="computeroutput"><span class="identifier">default_policy</span></tt>
- template need to have two embedded classes: <tt class="computeroutput"><span class="identifier">unique</span></tt>
- and <tt class="computeroutput"><span class="identifier">shared</span></tt>. The <tt class="computeroutput"><span class="identifier">unique</span></tt> class needs to implement all required
+ All policies to be used with the <code class="computeroutput"><span class="identifier">default_policy</span></code>
+ template need to have two embedded classes: <code class="computeroutput"><span class="identifier">unique</span></code>
+ and <code class="computeroutput"><span class="identifier">shared</span></code>. The <code class="computeroutput"><span class="identifier">unique</span></code> class needs to implement all required
functions for a particular policy type. In addition it may hold all member
data items being <span class="emphasis"><em>unique</em></span> for a particular instance of
- a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt> (hence the name).
- The <tt class="computeroutput"><span class="identifier">shared</span></tt> class does not
+ a <code class="computeroutput"><span class="identifier">multi_pass</span></code> (hence the name).
+ The <code class="computeroutput"><span class="identifier">shared</span></code> class does not
expose any member functions (except sometimes a constructor), but it may
hold all member data items to be <span class="emphasis"><em>shared</em></span> between all
- copies of a particular <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
+ copies of a particular <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
</p>
-<a name="spirit.support.multi_pass.inputpolicy"></a><h4>
-<a name="id626962"></a>
- InputPolicy
- </h4>
+<a name="spirit.support.multi_pass.inputpolicy"></a><h5>
+<a name="id1332369"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.inputpolicy">InputPolicy</a>
+ </h5>
<p>
- An <tt class="computeroutput"><span class="identifier">InputPolicy</span></tt> must have
+ An <code class="computeroutput"><span class="identifier">InputPolicy</span></code> must have
the following interface:
</p>
<pre class="programlisting"><span class="keyword">struct</span> <span class="identifier">input_policy</span>
@@ -749,27 +822,27 @@
<span class="special">};</span>
</pre>
<p>
- It is possible to derive the struct <tt class="computeroutput"><span class="identifier">unique</span></tt>
- from the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_input_policy</span></tt>. This type implements
+ It is possible to derive the struct <code class="computeroutput"><span class="identifier">unique</span></code>
+ from the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_input_policy</span></code>. This type implements
a minimal sufficient interface for some of the required functions, simplifying
the task of writing a new input policy.
</p>
<p>
- This class may implement a function <tt class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></tt> being called during destruction of the
- last copy of a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
+ This class may implement a function <code class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></code> being called during destruction of the
+ last copy of a <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
This function should be used to free any of the shared data items the policy
- might have allocated during construction of its <tt class="computeroutput"><span class="identifier">shared</span></tt>
- part. Because of the way <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- is implemented any allocated data members in <tt class="computeroutput"><span class="identifier">shared</span></tt>
+ might have allocated during construction of its <code class="computeroutput"><span class="identifier">shared</span></code>
+ part. Because of the way <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ is implemented any allocated data members in <code class="computeroutput"><span class="identifier">shared</span></code>
should <span class="underline">not</span> be deep copied in a copy
- constructor of <tt class="computeroutput"><span class="identifier">shared</span></tt>.
+ constructor of <code class="computeroutput"><span class="identifier">shared</span></code>.
</p>
-<a name="spirit.support.multi_pass.ownershippolicy"></a><h4>
-<a name="id628170"></a>
- OwnershipPolicy
- </h4>
+<a name="spirit.support.multi_pass.ownershippolicy"></a><h5>
+<a name="id1334351"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.ownershippolicy">OwnershipPolicy</a>
+ </h5>
<p>
- The <tt class="computeroutput"><span class="identifier">OwnershipPolicy</span></tt> must
+ The <code class="computeroutput"><span class="identifier">OwnershipPolicy</span></code> must
have the following interface:
</p>
<pre class="programlisting"><span class="keyword">struct</span> <span class="identifier">ownership_policy</span>
@@ -816,27 +889,27 @@
<span class="special">};</span>
</pre>
<p>
- It is possible to derive the struct <tt class="computeroutput"><span class="identifier">unique</span></tt>
- from the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_ownership_policy</span></tt>. This type implements
+ It is possible to derive the struct <code class="computeroutput"><span class="identifier">unique</span></code>
+ from the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_ownership_policy</span></code>. This type implements
a minimal sufficient interface for some of the required functions, simplifying
the task of writing a new ownership policy.
</p>
<p>
- This class may implement a function <tt class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></tt> being called during destruction of the
- last copy of a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
+ This class may implement a function <code class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></code> being called during destruction of the
+ last copy of a <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
This function should be used to free any of the shared data items the policy
- might have allocated during construction of its <tt class="computeroutput"><span class="identifier">shared</span></tt>
- part. Because of the way <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- is implemented any allocated data members in <tt class="computeroutput"><span class="identifier">shared</span></tt>
+ might have allocated during construction of its <code class="computeroutput"><span class="identifier">shared</span></code>
+ part. Because of the way <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ is implemented any allocated data members in <code class="computeroutput"><span class="identifier">shared</span></code>
should <span class="underline">not</span> be deep copied in a copy
- constructor of <tt class="computeroutput"><span class="identifier">shared</span></tt>.
+ constructor of <code class="computeroutput"><span class="identifier">shared</span></code>.
</p>
-<a name="spirit.support.multi_pass.checkingpolicy"></a><h4>
-<a name="id628914"></a>
- CheckingPolicy
- </h4>
+<a name="spirit.support.multi_pass.checkingpolicy"></a><h5>
+<a name="id1334885"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.checkingpolicy">CheckingPolicy</a>
+ </h5>
<p>
- The <tt class="computeroutput"><span class="identifier">CheckingPolicy</span></tt> must have
+ The <code class="computeroutput"><span class="identifier">CheckingPolicy</span></code> must have
the following interface:
</p>
<pre class="programlisting"><span class="keyword">struct</span> <span class="identifier">checking_policy</span>
@@ -875,27 +948,27 @@
<span class="special">};</span>
</pre>
<p>
- It is possible to derive the struct <tt class="computeroutput"><span class="identifier">unique</span></tt>
- from the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_checking_policy</span></tt>. This type implements
+ It is possible to derive the struct <code class="computeroutput"><span class="identifier">unique</span></code>
+ from the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_checking_policy</span></code>. This type implements
a minimal sufficient interface for some of the required functions, simplifying
the task of writing a new checking policy.
</p>
<p>
- This class may implement a function <tt class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></tt> being called during destruction of the
- last copy of a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
+ This class may implement a function <code class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></code> being called during destruction of the
+ last copy of a <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
This function should be used to free any of the shared data items the policy
- might have allocated during construction of its <tt class="computeroutput"><span class="identifier">shared</span></tt>
- part. Because of the way <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- is implemented any allocated data members in <tt class="computeroutput"><span class="identifier">shared</span></tt>
+ might have allocated during construction of its <code class="computeroutput"><span class="identifier">shared</span></code>
+ part. Because of the way <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ is implemented any allocated data members in <code class="computeroutput"><span class="identifier">shared</span></code>
should <span class="underline">not</span> be deep copied in a copy
- constructor of <tt class="computeroutput"><span class="identifier">shared</span></tt>.
+ constructor of <code class="computeroutput"><span class="identifier">shared</span></code>.
</p>
-<a name="spirit.support.multi_pass.storagepolicy"></a><h4>
-<a name="id629550"></a>
- StoragePolicy
- </h4>
+<a name="spirit.support.multi_pass.storagepolicy"></a><h5>
+<a name="id1335337"></a>
+ <a class="link" href="multi_pass.html#spirit.support.multi_pass.storagepolicy">StoragePolicy</a>
+ </h5>
<p>
- A <tt class="computeroutput"><span class="identifier">StoragePolicy</span></tt> must have
+ A <code class="computeroutput"><span class="identifier">StoragePolicy</span></code> must have
the following interface:
</p>
<pre class="programlisting"><span class="keyword">struct</span> <span class="identifier">storage_policy</span>
@@ -973,25 +1046,25 @@
<span class="special">};</span>
</pre>
<p>
- It is possible to derive the struct <tt class="computeroutput"><span class="identifier">unique</span></tt>
- from the type <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_storage_policy</span></tt>. This type implements
+ It is possible to derive the struct <code class="computeroutput"><span class="identifier">unique</span></code>
+ from the type <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">detail</span><span class="special">::</span><span class="identifier">default_storage_policy</span></code>. This type implements
a minimal sufficient interface for some of the required functions, simplifying
the task of writing a new storage policy.
</p>
<p>
- This class may implement a function <tt class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></tt> being called during destruction of the
- last copy of a <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>.
+ This class may implement a function <code class="computeroutput"><span class="identifier">destroy</span><span class="special">()</span></code> being called during destruction of the
+ last copy of a <code class="computeroutput"><span class="identifier">multi_pass</span></code>.
This function should be used to free any of the shared data items the policy
- might have allocated during construction of its <tt class="computeroutput"><span class="identifier">shared</span></tt>
- part. Because of the way <tt class="computeroutput"><span class="identifier">multi_pass</span></tt>
- is implemented any allocated data members in <tt class="computeroutput"><span class="identifier">shared</span></tt>
+ might have allocated during construction of its <code class="computeroutput"><span class="identifier">shared</span></code>
+ part. Because of the way <code class="computeroutput"><span class="identifier">multi_pass</span></code>
+ is implemented any allocated data members in <code class="computeroutput"><span class="identifier">shared</span></code>
should <span class="underline">not</span> be deep copied in a copy
- constructor of <tt class="computeroutput"><span class="identifier">shared</span></tt>.
+ constructor of <code class="computeroutput"><span class="identifier">shared</span></code>.
</p>
<p>
- Generally, a <tt class="computeroutput"><span class="identifier">StoragePolicy</span></tt>
+ Generally, a <code class="computeroutput"><span class="identifier">StoragePolicy</span></code>
is the trickiest policy to implement. You should study and understand the
- existing <tt class="computeroutput"><span class="identifier">StoragePolicy</span></tt> classes
+ existing <code class="computeroutput"><span class="identifier">StoragePolicy</span></code> classes
before you try and write your own.
</p>
</div>
Modified: trunk/libs/spirit/doc/html/spirit/what_s_new.html
==============================================================================
--- trunk/libs/spirit/doc/html/spirit/what_s_new.html (original)
+++ trunk/libs/spirit/doc/html/spirit/what_s_new.html 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -3,10 +3,10 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>What's New</title>
<link rel="stylesheet" href="../../../../../doc/html/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.65.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.75.0">
<link rel="home" href="../index.html" title="Spirit 2.1">
<link rel="up" href="../index.html" title="Spirit 2.1">
-<link rel="previous" href="preface.html" title="Preface">
+<link rel="prev" href="preface.html" title="Preface">
<link rel="next" href="introduction.html" title="Introduction">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -22,17 +22,14 @@
<div class="spirit-nav">
<a accesskey="p" href="preface.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="introduction.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
-<div class="section" lang="en">
-<div class="titlepage">
-<div><div><h2 class="title" style="clear: both">
-<a name="spirit.what_s_new"></a>What's New
-</h2></div></div>
-<div></div>
-</div>
-<a name="spirit.what_s_new.spirit_classic"></a><h3>
-<a name="id353429"></a>
- Spirit Classic
- </h3>
+<div class="section" title="What's New">
+<div class="titlepage"><div><div><h2 class="title" style="clear: both">
+<a name="spirit.what_s_new"></a><a class="link" href="what_s_new.html" title="What's New">What's New</a>
+</h2></div></div></div>
+<a name="spirit.what_s_new.spirit_classic"></a><h4>
+<a name="id1097257"></a>
+ <a class="link" href="what_s_new.html#spirit.what_s_new.spirit_classic">Spirit Classic</a>
+ </h4>
<p>
The Spirit V1.8.x code base has been integrated with Spirit V2. It is now called
<span class="emphasis"><em>Spirit.Classic</em></span>. Since the directory structure has changed
@@ -56,11 +53,11 @@
</pre>
<p>
To avoid namespace conflicts with the new Spirit V2 library we moved Spirit
- Classic into the namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">classic</span></tt>.
- All references to the former namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></tt>
+ Classic into the namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">classic</span></code>.
+ All references to the former namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></code>
need to be adjusted as soon as the header names are corrected as described
- above. As an alternative you can define the preprocessor constant <tt class="computeroutput"><span class="identifier">BOOST_SPIRIT_USE_OLD_NAMESPACE</span></tt>, which will
- force the Spirit Classic code to be in the namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></tt>
+ above. As an alternative you can define the preprocessor constant <code class="computeroutput"><span class="identifier">BOOST_SPIRIT_USE_OLD_NAMESPACE</span></code>, which will
+ force the Spirit Classic code to be in the namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></code>
as before. This is not recommended, though, as it may result in naming clashes.
</p>
<p>
@@ -68,138 +65,135 @@
deprecated include files are being used. This ensures full backwards compatibility
for existing applications.
</p>
-<a name="spirit.what_s_new.spirit_v2_1"></a><h3>
-<a name="id409193"></a>
- Spirit V2.1
- </h3>
-<a name="spirit.what_s_new.what_s_changed_in__emphasis_spirit_qi__emphasis__and__emphasis_spirit_karma__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_"></a><h3>
-<a name="id409218"></a>
- <a href="what_s_new.html#spirit.what_s_new.what_s_changed_in__emphasis_spirit_qi__emphasis__and__emphasis_spirit_karma__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_">What's
+<a name="spirit.what_s_new.spirit_v2_1"></a><h4>
+<a name="id1097448"></a>
+ <a class="link" href="what_s_new.html#spirit.what_s_new.spirit_v2_1">Spirit V2.1</a>
+ </h4>
+<a name="spirit.what_s_new.what_s_changed_in__emphasis_spirit_qi__emphasis__and__emphasis_spirit_karma__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_"></a><h4>
+<a name="id1097461"></a>
+ <a class="link" href="what_s_new.html#spirit.what_s_new.what_s_changed_in__emphasis_spirit_qi__emphasis__and__emphasis_spirit_karma__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_">What's
changed in <span class="emphasis"><em>Spirit.Qi</em></span> and <span class="emphasis"><em>Spirit.Karma</em></span>
from V2.0 (Boost V1.37.0) to 2.x (Boost V1.41.0)</a>
- </h3>
-<div class="itemizedlist"><ul type="disc">
-<li>
+ </h4>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
<a href="http://spirit.sourceforge.net" target="_top">Spirit</a> is now based on
the newest version of Boost.Proto
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></tt>, <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_format</span></tt>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></code>, <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_format</span></code>
now post-skip by default.
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate_delimited</span></tt> and <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">format_delimited</span></tt>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate_delimited</span></code> and <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">format_delimited</span></code>
now don't do pre- delimiting by default.
</li>
-<li>
- Changed parameter sequence of <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></tt>,
- <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_match</span></tt>, <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate_delimited</span></tt>,
- and <tt class="computeroutput"><span class="identifier">match_delimited</span></tt>. The
+<li class="listitem">
+ Changed parameter sequence of <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span></code>,
+ <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_match</span></code>, <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">generate_delimited</span></code>,
+ and <code class="computeroutput"><span class="identifier">match_delimited</span></code>. The
attribute is now always the last parameter.
</li>
-<li>
+<li class="listitem">
Added new overloads of those functions allowing to explicitely specify the
post-skipping and pre-delimiting behavior.
</li>
-<li>
+<li class="listitem">
Added multi attribute API functions
</li>
-<li>
- Removed <tt class="computeroutput"><span class="identifier">grammar_def</span><span class="special"><></span></tt>
+<li class="listitem">
+ Removed <code class="computeroutput"><span class="identifier">grammar_def</span><span class="special"><></span></code>
</li>
-<li>
- Removed functions <tt class="computeroutput"><span class="identifier">make_parser</span><span class="special">()</span></tt> and <tt class="computeroutput"><span class="identifier">make_generator</span><span class="special">()</span></tt>
+<li class="listitem">
+ Removed functions <code class="computeroutput"><span class="identifier">make_parser</span><span class="special">()</span></code> and <code class="computeroutput"><span class="identifier">make_generator</span><span class="special">()</span></code>
</li>
-<li>
- Removed <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">none</span></tt> and <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">none</span></tt>
+<li class="listitem">
+ Removed <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">none</span></code> and <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">none</span></code>
</li>
-<li>
+<li class="listitem">
Sequences and lists now accept a standard container as their attribute
</li>
-<li>
+<li class="listitem">
The string placeholder terminal now can take other strings as its parameter
(i.e. std::string)
</li>
-<li>
+<li class="listitem">
All terminals taking literals now accept a (lazy) function object as well
</li>
-<li>
- All placeholders for terminals and directives (such as <tt class="computeroutput"><span class="identifier">int_</span></tt>,
- <tt class="computeroutput"><span class="identifier">double_</span></tt>, <tt class="computeroutput"><span class="identifier">verbatim</span></tt>,
- etc.) were previously defined in the namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></tt>
- only. Now these are additionally imported into the namespaces <tt class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span></tt>, <tt class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span></tt>,
- and <tt class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lex</span></tt> (if they are supported by the corresponding
+<li class="listitem">
+ All placeholders for terminals and directives (such as <code class="computeroutput"><span class="identifier">int_</span></code>,
+ <code class="computeroutput"><span class="identifier">double_</span></code>, <code class="computeroutput"><span class="identifier">verbatim</span></code>,
+ etc.) were previously defined in the namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></code>
+ only. Now these are additionally imported into the namespaces <code class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">qi</span></code>, <code class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">karma</span></code>,
+ and <code class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">lex</span></code> (if they are supported by the corresponding
sub-library).
</li>
-<li>
- The terminal placeholders <tt class="computeroutput"><span class="identifier">char_</span></tt>
- and <tt class="computeroutput"><span class="identifier">string</span></tt> are not defined
- in the namespace <tt class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></tt> anymore as they have been moved
+<li class="listitem">
+ The terminal placeholders <code class="computeroutput"><span class="identifier">char_</span></code>
+ and <code class="computeroutput"><span class="identifier">string</span></code> are not defined
+ in the namespace <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">spirit</span></code> anymore as they have been moved
to the character set namespaces, allowing to do proper character set handling
- based on the used namespace (as <tt class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">ascii</span></tt>,
+ based on the used namespace (as <code class="computeroutput"><span class="identifier">spirit</span><span class="special">::</span><span class="identifier">ascii</span></code>,
etc.)
</li>
-<li>
- The <tt class="computeroutput"><span class="identifier">uint</span></tt>, <tt class="computeroutput"><span class="identifier">ushort</span></tt>,
- <tt class="computeroutput"><span class="identifier">ulong</span></tt>, and <tt class="computeroutput"><span class="identifier">byte</span></tt> terminal placeholders have been renamed
- to <tt class="computeroutput"><span class="identifier">uint_</span></tt>, <tt class="computeroutput"><span class="identifier">ushort_</span></tt>,
- <tt class="computeroutput"><span class="identifier">ulong_</span></tt>, and <tt class="computeroutput"><span class="identifier">byte_</span></tt>.
- </li>
-<li>
-<tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">skip</span><span class="special">[]</span></tt>
- now re-enables outer skipper if used inside <tt class="computeroutput"><span class="identifier">lexeme</span><span class="special">[]</span></tt>
+<li class="listitem">
+ The <code class="computeroutput"><span class="identifier">uint</span></code>, <code class="computeroutput"><span class="identifier">ushort</span></code>,
+ <code class="computeroutput"><span class="identifier">ulong</span></code>, and <code class="computeroutput"><span class="identifier">byte</span></code> terminal placeholders have been renamed
+ to <code class="computeroutput"><span class="identifier">uint_</span></code>, <code class="computeroutput"><span class="identifier">ushort_</span></code>,
+ <code class="computeroutput"><span class="identifier">ulong_</span></code>, and <code class="computeroutput"><span class="identifier">byte_</span></code>.
+ </li>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">skip</span><span class="special">[]</span></code>
+ now re-enables outer skipper if used inside <code class="computeroutput"><span class="identifier">lexeme</span><span class="special">[]</span></code>
</li>
-<li>
- Added <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">maxwidth</span><span class="special">[]</span></tt>
+<li class="listitem">
+ Added <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">maxwidth</span><span class="special">[]</span></code>
directive
</li>
-<li>
- Added <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">omit</span><span class="special">[]</span></tt>
- directive (see <a href="karma/reference/directive/omit.html" title=" Consume Attribute
- (omit[])"><tt class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>)
- </li>
-<li>
- Added <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">buffer</span><span class="special">[]</span></tt>
- directive (see <a href="karma/reference/directive/buffer.html" title=" Temporary
- Output Buffering (buffer[])"><tt class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></tt></a>)
- </li>
-<li>
-<tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">delimit</span><span class="special">[]</span></tt>
- now re-enables outer delimiter if used inside <tt class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></tt>
+<li class="listitem">
+ Added <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">omit</span><span class="special">[]</span></code>
+ directive (see <a class="link" href="karma/reference/directive/omit.html" title="Consume Attribute (omit[])"><code class="computeroutput"><span class="identifier">omit</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>)
+ </li>
+<li class="listitem">
+ Added <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">buffer</span><span class="special">[]</span></code>
+ directive (see <a class="link" href="karma/reference/directive/buffer.html" title="Temporary Output Buffering (buffer[])"><code class="computeroutput"><span class="identifier">buffer</span><span class="special">[</span><span class="identifier">a</span><span class="special">]</span></code></a>)
+ </li>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">delimit</span><span class="special">[]</span></code>
+ now re-enables outer delimiter if used inside <code class="computeroutput"><span class="identifier">verbatim</span><span class="special">[]</span></code>
</li>
-<li>
- karma: added and-predicate (<tt class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></tt>) and not-predicate (<tt class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></tt>)
+<li class="listitem">
+ karma: added and-predicate (<code class="computeroutput"><span class="keyword">operator</span><span class="special">&()</span></code>) and not-predicate (<code class="computeroutput"><span class="keyword">operator</span><span class="special">!()</span></code>)
</li>
-<li>
- karma: changed semantics of <tt class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></tt>, <tt class="computeroutput"><span class="identifier">string</span><span class="special">()</span></tt>, <tt class="computeroutput"><span class="identifier">int_</span><span class="special">()</span></tt> et.al., and <tt class="computeroutput"><span class="identifier">double_</span><span class="special">()</span></tt> et.al.: all of these generators now always
+<li class="listitem">
+ karma: changed semantics of <code class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></code>, <code class="computeroutput"><span class="identifier">string</span><span class="special">()</span></code>, <code class="computeroutput"><span class="identifier">int_</span><span class="special">()</span></code> et.al., and <code class="computeroutput"><span class="identifier">double_</span><span class="special">()</span></code> et.al.: all of these generators now always
expose an attribute. If they do not have an associate attribute, they generate
their immediate literal. If they have an associated attribute, the generators
first test if the attribute value is equal to the immediate literal. They
fail not while generating anything if those are not equal. Otherwise they
generate their immediate literal. For more information see for instance
- <a href="karma/reference/numeric/signed_int.html" title=" Signed
- Integer Number Generators"><tt class="computeroutput"><span class="identifier">int_</span></tt></a>.
+ <a class="link" href="karma/reference/numeric/signed_int.html" title="Signed Integer Number Generators"><code class="computeroutput"><span class="identifier">int_</span></code></a>.
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span><span class="special">()</span></tt> can
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">lit</span><span class="special">()</span></code> can
now be used to generate integer and floating point numbers
</li>
-<li>
-<tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span></tt> and <tt class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">rule</span></tt>
+<li class="listitem">
+<code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span></code> and <code class="computeroutput"><span class="identifier">karma</span><span class="special">::</span><span class="identifier">rule</span></code>
now can be directly initialzed using their copy constructor. I.e. this works
- now: <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span><span class="special"><...></span>
- <span class="identifier">r</span> <span class="special">=</span> <span class="special">...</span><span class="identifier">some</span> <span class="identifier">parser</span><span class="special">...;</span></tt>.The
+ now: <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">rule</span><span class="special"><...></span>
+ <span class="identifier">r</span> <span class="special">=</span> <span class="special">...</span><span class="identifier">some</span> <span class="identifier">parser</span><span class="special">...;</span></code>.The
semantics of this initalization are equivalent to initializing them using
- <tt class="computeroutput"><span class="keyword">operator</span><span class="special">%=()</span></tt>
+ <code class="computeroutput"><span class="keyword">operator</span><span class="special">%=()</span></code>
(auto attribute propagation is enabled).
</li>
</ul></div>
-<a name="spirit.what_s_new.what_s_changed_in__emphasis_spirit_lex__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_"></a><h3>
-<a name="id410293"></a>
- <a href="what_s_new.html#spirit.what_s_new.what_s_changed_in__emphasis_spirit_lex__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_">What's
+<a name="spirit.what_s_new.what_s_changed_in__emphasis_spirit_lex__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_"></a><h4>
+<a name="id1100722"></a>
+ <a class="link" href="what_s_new.html#spirit.what_s_new.what_s_changed_in__emphasis_spirit_lex__emphasis__from_v2_0__boost_v1_37_0__to_2_x__boost_v1_41_0_">What's
changed in <span class="emphasis"><em>Spirit.Lex</em></span> from V2.0 (Boost V1.37.0) to 2.x
(Boost V1.41.0)</a>
- </h3>
+ </h4>
<p>
Here is a list of changes in <span class="emphasis"><em>Spirit.Lex</em></span> since version
2.0. <span class="emphasis"><em>Spirit.Lex</em></span> 2.x is a complete rewrite of the <span class="emphasis"><em>Spirit.Lex</em></span>
@@ -207,15 +201,15 @@
library it is usable either standalone or in conjunction with the other parts.
<span class="emphasis"><em>Spirit.Lex</em></span> now uses the infrastructure provided by Spirit version 2.1.
</p>
-<div class="itemizedlist"><ul type="disc">
-<li>
+<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<li class="listitem">
The lex::lexer_def class has been renamed to lex::lexer, while the original
class lex::lexer does not exist anymore. This simplifies the creation of
lexers.
</li>
-<li>
- The lex::lexer class does not have the function <tt class="computeroutput"><span class="identifier">def</span><span class="special">(</span><span class="identifier">Self</span><span class="special">&</span>
- <span class="identifier">self</span><span class="special">)</span></tt>
+<li class="listitem">
+ The lex::lexer class does not have the function <code class="computeroutput"><span class="identifier">def</span><span class="special">(</span><span class="identifier">Self</span><span class="special">&</span>
+ <span class="identifier">self</span><span class="special">)</span></code>
anymore, token definitions can be added to the lexer at any time, usually
in the constructor of the user defined lexer class:
<pre class="programlisting"><span class="keyword">template</span> <span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Lexer</span><span class="special">></span>
@@ -229,74 +223,71 @@
<span class="special">};</span>
</pre>
</li>
-<li>
+<li class="listitem">
The new lexer class now can be directly used, their is no need anymore to
- wrap it using the <tt class="computeroutput"><span class="identifier">make_lexer</span><span class="special">()</span></tt> template as before. Therefore the function
- <tt class="computeroutput"><span class="identifier">make_lexer</span><span class="special">()</span></tt>
+ wrap it using the <code class="computeroutput"><span class="identifier">make_lexer</span><span class="special">()</span></code> template as before. Therefore the function
+ <code class="computeroutput"><span class="identifier">make_lexer</span><span class="special">()</span></code>
has been removed.
</li>
-<li>
- The <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize_and_parse</span><span class="special">()</span></tt>
- and <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize_and_phrase_parse</span><span class="special">()</span></tt>
+<li class="listitem">
+ The <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize_and_parse</span><span class="special">()</span></code>
+ and <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">tokenize_and_phrase_parse</span><span class="special">()</span></code>
functions have been changed to match the parameter sequence as implemented
- by the <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span><span class="special">()</span></tt>
- and <tt class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span><span class="special">()</span></tt>
+ by the <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">parse</span><span class="special">()</span></code>
+ and <code class="computeroutput"><span class="identifier">qi</span><span class="special">::</span><span class="identifier">phrase_parse</span><span class="special">()</span></code>
functions. Both take a possibly arbitrary number of attribute arguments as
its last parameters (well, the number of attributes is limited by the macro
- <tt class="computeroutput"><span class="identifier">SPIRIT_ARGUMENTS_LIMIT</span></tt>, which
- defaults to <tt class="computeroutput"><span class="identifier">PHOENIX_LIMIT</span></tt>).
+ <code class="computeroutput"><span class="identifier">SPIRIT_ARGUMENTS_LIMIT</span></code>, which
+ defaults to <code class="computeroutput"><span class="identifier">PHOENIX_LIMIT</span></code>).
</li>
-<li>
- The <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_lexer</span></tt>, and <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_token</span></tt>
- classes have been moved to the <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span></tt>
- namespace and the names have been changed to <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">lexer</span></tt>,
- <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span></tt> (the same applies to the <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexert_actor_lexer</span></tt>,
- and the <tt class="computeroutput"><span class="identifier">static_lexertl_</span><span class="special">*</span></tt>
+<li class="listitem">
+ The <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_lexer</span></code>, and <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_token</span></code>
+ classes have been moved to the <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span></code>
+ namespace and the names have been changed to <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">lexer</span></code>,
+ <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl</span><span class="special">::</span><span class="identifier">token</span></code> (the same applies to the <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexert_actor_lexer</span></code>,
+ and the <code class="computeroutput"><span class="identifier">static_lexertl_</span><span class="special">*</span></code>
family of types).
</li>
-<li>
- The class <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_token_set</span></tt> has been removed alltogether
+<li class="listitem">
+ The class <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexertl_token_set</span></code> has been removed alltogether
as its complete functionality is available from the lexer class.
</li>
-<li>
+<li class="listitem">
The <span class="emphasis"><em>Spirit.Lex</em></span> library has been updated to use the newest
version of Ben Hansons Lexertl
lexer construction library (Boost review pending).
</li>
-<li>
- The <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexer</span><span class="special"><</span><span class="identifier">Lexer</span><span class="special">></span></tt>
- template constructor now takes an optional parameter specifying the <tt class="computeroutput"><span class="identifier">match_flags</span></tt> to be used for table generation.
+<li class="listitem">
+ The <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lexer</span><span class="special"><</span><span class="identifier">Lexer</span><span class="special">></span></code>
+ template constructor now takes an optional parameter specifying the <code class="computeroutput"><span class="identifier">match_flags</span></code> to be used for table generation.
Currently, there are the following flags available:
<pre class="programlisting"><span class="identifier">match_flags</span><span class="special">::</span><span class="identifier">match_default</span><span class="special">,</span> <span class="comment">// no flags
</span><span class="identifier">match_flags</span><span class="special">::</span><span class="identifier">match_not_dot_newline</span><span class="special">,</span> <span class="comment">// the regex '.' doesn't match newlines
</span><span class="identifier">match_flags</span><span class="special">::</span><span class="identifier">match_icase</span> <span class="comment">// all matching operations are case insensitive
</span></pre>
- If no parameter is passed to the constructor, <tt class="computeroutput"><span class="identifier">match_flags</span><span class="special">::</span><span class="identifier">match_default</span></tt>
- is used, i.e. the <tt class="computeroutput"><span class="special">.</span></tt> matches
+ If no parameter is passed to the constructor, <code class="computeroutput"><span class="identifier">match_flags</span><span class="special">::</span><span class="identifier">match_default</span></code>
+ is used, i.e. the <code class="computeroutput"><span class="special">.</span></code> matches
newlines and matching is case sensitive.
</li>
-<li>
- The <tt class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></tt>
- and <tt class="computeroutput"><span class="identifier">string</span><span class="special">()</span></tt>
+<li class="listitem">
+ The <code class="computeroutput"><span class="identifier">char_</span><span class="special">()</span></code>
+ and <code class="computeroutput"><span class="identifier">string</span><span class="special">()</span></code>
placeholders can now be used for token definitions as a replacement for
- <tt class="computeroutput"><span class="identifier">token_def</span></tt>, although it is
+ <code class="computeroutput"><span class="identifier">token_def</span></code>, although it is
still possible to use the latter.
</li>
-<li>
- Lexer semantic actions now have to conform to a changed interface (see <a href="lex/abstracts/lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">Lexer Semantic Actions</a>
+<li class="listitem">
+ Lexer semantic actions now have to conform to a changed interface (see <a class="link" href="lex/abstracts/lexer_semantic_actions.html" title="Lexer Semantic Actions">Lexer Semantic Actions</a>
for details).
</li>
-<li>
+<li class="listitem">
Added placeholder symbols usable from the inside of lexer semantic actions
- while using Phoenix: _start, _end, _eoi, _state, _val, and _pass (see <a href="lex/abstracts/lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">Lexer Semantic Actions</a>
+ while using Phoenix: _start, _end, _eoi, _state, _val, and _pass (see <a class="link" href="lex/abstracts/lexer_semantic_actions.html" title="Lexer Semantic Actions">Lexer Semantic Actions</a>
for more details).
</li>
-<li>
+<li class="listitem">
Added (lazy) support functions usable from the inside of lexer semantic actions
- while using Phoenix: <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">more</span><span class="special">()</span></tt>, <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">less</span><span class="special">()</span></tt>, and <tt class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lookahead</span><span class="special">()</span></tt> (see <a href="lex/abstracts/lexer_semantic_actions.html" title=" Lexer
- Semantic Actions">Lexer
+ while using Phoenix: <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">more</span><span class="special">()</span></code>, <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">less</span><span class="special">()</span></code>, and <code class="computeroutput"><span class="identifier">lex</span><span class="special">::</span><span class="identifier">lookahead</span><span class="special">()</span></code> (see <a class="link" href="lex/abstracts/lexer_semantic_actions.html" title="Lexer Semantic Actions">Lexer
Semantic Actions</a> for more details).
</li>
</ul></div>
Modified: trunk/libs/spirit/doc/karma.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma.qbk (original)
+++ trunk/libs/spirit/doc/karma.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -26,13 +26,13 @@
[include karma/char.qbk]
[include karma/string.qbk]
[include karma/numeric.qbk]
-[/include karma/binary.qbk]
-[include karma/directive.qbk]
[/include karma/action.qbk]
[/include karma/nonterminal.qbk]
-[include karma/operator.qbk]
[include karma/stream.qbk]
+[include karma/binary.qbk]
[include karma/auxiliary.qbk]
+[include karma/directive.qbk]
+[include karma/operator.qbk]
[/include karma/debug.qbk]
[endsect]
Modified: trunk/libs/spirit/doc/karma/auxiliary.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/auxiliary.qbk (original)
+++ trunk/libs/spirit/doc/karma/auxiliary.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -16,6 +16,8 @@
// forwards to <boost/spirit/home/karma/auxiliary.hpp>
#include <boost/spirit/include/karma_auxiliary.hpp>
+Also, see __include_structure__.
+
[/////////////////////////////////////////////////////////////////////////////]
[section eol]
Modified: trunk/libs/spirit/doc/karma/basics.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/basics.qbk (original)
+++ trunk/libs/spirit/doc/karma/basics.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -56,5 +56,27 @@
* boost::spirit::karma::standard
* boost::spirit::karma::standard_wide
+[heading Examples]
+
+All sections in the reference present some real world examples. The
+examples use a common test harness to keep the example code as minimal
+and direct to the point as possible. The test harness is presented
+below.
+
+Some includes:
+
+[reference_karma_includes]
+
+Our test functions:
+
+This one tests the generators without attributes.
+
+[reference_karma_test]
+
+These test the generators with one or more user supplied attributes.
+
+[reference_karma_test_attr]
+[reference_karma_test_attr2]
+
[endsect]
Modified: trunk/libs/spirit/doc/karma/binary.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/binary.qbk (original)
+++ trunk/libs/spirit/doc/karma/binary.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -8,6 +8,431 @@
[section:binary Binary]
+This module includes different generators allowing to output binary data.
+It includes generators for default, little, and big endian binary output and
+a `pad` generator allowing to control padding of the generated output
+stream.
+[heading Module Header]
+
+ // forwards to <boost/spirit/home/karma/binary.hpp>
+ #include <boost/spirit/include/karma_binary.hpp>
+
+Also, see __include_structure__.
+
+[/////////////////////////////////////////////////////////////////////////////]
+[section:binary_native Binary Native Endianness Generators]
+
+[heading Description]
+
+The binary generators described in this section are:
+
+[table
+ [[Expression] [Description]]
+ [[`byte_`] [Generates the mandatory attribute as a single byte
+ (8 bit binary value) using native endian
+ representation]]
+ [[`word`] [Generates the mandatory attribute as a 16 bit
+ binary value using native endian representation]]
+ [[`dword`] [Generates the mandatory attribute as a 32 bit
+ binary value using native endian representation]]
+ [[`qword`] [Generates the mandatory attribute as a 64 bit
+ binary value using native endian representation]]
+ [[`byte_(b)`] [Generates the immediate parameter as a single byte
+ (8 bit binary value) using native endian
+ representation]]
+ [[`word(w)`] [Generates the immediate parameter as a 16 bit
+ binary value using native endian representation]]
+ [[`dword(dw)`] [Generates the immediate parameter as a 32 bit
+ binary value using native endian representation]]
+ [[`qword(qw)`] [Generates the immediate parameter as a 64 bit
+ binary value using native endian representation]]
+]
+
+[note The generators `qword` and `qword(qw)` are only available on
+ platforms where the preprocessor constant `BOOST_HAS_LONG_LONG` is
+ defined (i.e. on platforms having native support for `unsigned long long`
+ (64 bit) integer types).]
+
+[heading Header]
+
+ // forwards to <boost/spirit/home/karma/binary.hpp>
+ #include <boost/spirit/include/karma_binary.hpp>
+
+Also, see __include_structure__.
+
+[heading Model of]
+
+[:__primitive_generator_concept__]
+
+[variablelist Notation
+ [[`b`] [A single byte (8 bit binary value) or a __karma_lazy_argument__
+ that evaluates to a single byte]]
+ [[`w`] [A 16 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`dw`] [A 32 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`qw`] [A 64 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+]
+
+[heading Expression Semantics]
+
+Semantics of an expression is defined only where it differs from, or is
+not defined in __primitive_generator_concept__.
+
+[table
+ [[Expression] [Description]]
+ [[`byte_`] [Output the binary representation of the least
+ significant byte of the mandatory attribute. This
+ generator never fails (except if the underlying
+ output stream reports an error).]]
+ [[`word`] [Output the binary representation of the least
+ significant 16 bits of the mandatory attribute
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`dword`] [Output the binary representation of the least
+ significant 32 bits of the mandatory attribute
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`qword`] [Output the binary representation of the least
+ significant 64 bits of the mandatory attribute
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`byte_(b)`] [Output the binary representation of the least
+ significant byte of the immediate parameter. This
+ generator never fails (except if the underlying
+ output stream reports an error).]]
+ [[`word(w)`] [Output the binary representation of the least
+ significant 16 bits of the immediate parameter
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`dword(dw)`] [Output the binary representation of the least
+ significant 32 bits of the immediate parameter
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`qword(qw)`] [Output the binary representation of the least
+ significant 64 bits of the immediate parameter
+ in native endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+]
+
+[heading Attributes]
+
+[table
+ [[Expression] [Attribute]]
+ [[`byte_`] [`boost::uint_least8_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`word`] [`boost::uint_least16_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`dword`] [`boost::uint_least32_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`qword`] [`boost::uint_least64_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`byte_(b)`] [__unused__]]
+ [[`word(w)`] [__unused__]]
+ [[`dword(dw)`] [__unused__]]
+ [[`qword(qw)`] [__unused__]]
+]
+
+[heading Complexity]
+
+[:O(N), where N is the number of bytes emitted by the binary generator]
+
+[heading Example]
+
+Some includes:
+
+[reference_karma_includes]
+
+All code snippets below use these common test functions:
+
+[reference_karma_binary_test]
+[reference_karma_binary_test_attr]
+
+Some using declarations:
+
+[reference_karma_using_declarations_native_binary]
+
+Basic usage of the native binary generators with some results for little endian
+platforms:
+
+[reference_karma_native_binary_little]
+
+Basic usage of the native binary generators with some results for big endian
+platforms:
+
+[reference_karma_native_binary_big]
+
+[endsect]
+
+[/////////////////////////////////////////////////////////////////////////////]
+[section:binary_little Binary Little Endianness Generators]
+
+[heading Description]
+
+The binary generators described in this section are:
+
+[table
+ [[Expression] [Description]]
+ [[`little_word`] [Generates the mandatory attribute as a 16 bit
+ binary value using little endian representation]]
+ [[`little_dword`] [Generates the mandatory attribute as a 32 bit
+ binary value using little endian representation]]
+ [[`little_qword`] [Generates the mandatory attribute as a 64 bit
+ binary value using little endian representation]]
+ [[`little_word(w)`] [Generates the immediate parameter as a 16 bit
+ binary value using little endian representation]]
+ [[`little_dword(dw)`] [Generates the immediate parameter as a 32 bit
+ binary value using little endian representation]]
+ [[`little_qword(qw)`] [Generates the immediate parameter as a 64 bit
+ binary value using little endian representation]]
+]
+
+[note The generators `little_qword` and `little_qword(qw)` are only available
+ on platforms where the preprocessor constant `BOOST_HAS_LONG_LONG` is
+ defined (i.e. on platforms having native support for `unsigned long long`
+ (64 bit) integer types).]
+
+[heading Header]
+
+ // forwards to <boost/spirit/home/karma/binary.hpp>
+ #include <boost/spirit/include/karma_binary.hpp>
+
+Also, see __include_structure__.
+
+[heading Model of]
+
+[:__primitive_generator_concept__]
+
+[variablelist Notation
+ [[`w`] [A 16 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`dw`] [A 32 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`qw`] [A 64 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+]
+
+[heading Expression Semantics]
+
+Semantics of an expression is defined only where it differs from, or is
+not defined in __primitive_generator_concept__.
+
+[table
+ [[Expression] [Description]]
+ [[`little_word`] [Output the binary representation of the least
+ significant 16 bits of the mandatory attribute
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`little_dword`] [Output the binary representation of the least
+ significant 32 bits of the mandatory attribute
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`little_qword`] [Output the binary representation of the least
+ significant 64 bits of the mandatory attribute
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`little_word(w)`] [Output the binary representation of the least
+ significant 16 bits of the immediate parameter
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`little_dword(dw)`] [Output the binary representation of the least
+ significant 32 bits of the immediate parameter
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`little_qword(qw)`] [Output the binary representation of the least
+ significant 64 bits of the immediate parameter
+ in little endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+]
+
+[heading Attributes]
+
+[table
+ [[Expression] [Attribute]]
+ [[`little_word`] [`boost::uint_least16_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`little_dword`] [`boost::uint_least32_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`little_qword`] [`boost::uint_least64_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`little_word(w)`] [__unused__]]
+ [[`little_dword(dw)`] [__unused__]]
+ [[`little_qword(qw)`] [__unused__]]
+]
+
+[heading Complexity]
+
+[:O(N), where N is the number of bytes emitted by the binary generator]
+
+[heading Example]
+
+Some includes:
+
+[reference_karma_includes]
+
+All code snippets below use these common test functions:
+
+[reference_karma_binary_test]
+[reference_karma_binary_test_attr]
+
+Some using declarations:
+
+[reference_karma_using_declarations_little_binary]
+
+Basic usage of the little binary generators:
+
+[reference_karma_little_binary]
+
+[endsect]
+
+[/////////////////////////////////////////////////////////////////////////////]
+[section:binary_big Binary Big Endianness Generators]
+
+[heading Description]
+
+The binary generators described in this section are:
+
+[table
+ [[Expression] [Description]]
+ [[`big_word`] [Generates the mandatory attribute as a 16 bit
+ binary value using big endian representation]]
+ [[`big_dword`] [Generates the mandatory attribute as a 32 bit
+ binary value using big endian representation]]
+ [[`big_qword`] [Generates the mandatory attribute as a 64 bit
+ binary value using big endian representation]]
+ [[`big_word(w)`] [Generates the immediate parameter as a 16 bit
+ binary value using big endian representation]]
+ [[`big_dword(dw)`] [Generates the immediate parameter as a 32 bit
+ binary value using big endian representation]]
+ [[`big_qword(qw)`] [Generates the immediate parameter as a 64 bit
+ binary value using big endian representation]]
+]
+
+[note The generators `big_qword` and `big_qword(qw)` are only available on
+ platforms where the preprocessor constant `BOOST_HAS_LONG_LONG` is
+ defined (i.e. on platforms having native support for `unsigned long long`
+ (64 bit) integer types).]
+
+[heading Header]
+
+ // forwards to <boost/spirit/home/karma/binary.hpp>
+ #include <boost/spirit/include/karma_binary.hpp>
+
+Also, see __include_structure__.
+
+[heading Model of]
+
+[:__primitive_generator_concept__]
+
+[variablelist Notation
+ [[`w`] [A 16 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`dw`] [A 32 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+ [[`qw`] [A 64 bit binary value or a __karma_lazy_argument__ that
+ evaluates to a 16 bit binary value. This value is always
+ interpreted using native endianness.]]
+]
+
+[heading Expression Semantics]
+
+Semantics of an expression is defined only where it differs from, or is
+not defined in __primitive_generator_concept__.
+
+[table
+ [[Expression] [Description]]
+ [[`big_word`] [Output the binary representation of the least
+ significant 16 bits of the mandatory attribute
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`big_dword`] [Output the binary representation of the least
+ significant 32 bits of the mandatory attribute
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`big_qword`] [Output the binary representation of the least
+ significant 64 bits of the mandatory attribute
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`big_word(w)`] [Output the binary representation of the least
+ significant 16 bits of the immediate parameter
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`big_dword(dw)`] [Output the binary representation of the least
+ significant 32 bits of the immediate parameter
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+ [[`big_qword(qw)`] [Output the binary representation of the least
+ significant 64 bits of the immediate parameter
+ in big endian representation. This generator
+ never fails (except if the underlying output stream
+ reports an error).]]
+]
+
+[heading Attributes]
+
+[table
+ [[Expression] [Attribute]]
+ [[`big_word`] [`boost::uint_least16_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`big_dword`] [`boost::uint_least32_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`big_qword`] [`boost::uint_least64_t`, attribute is mandatory
+ (otherwise compilation will fail)]]
+ [[`big_word(w)`] [__unused__]]
+ [[`big_dword(dw)`] [__unused__]]
+ [[`big_qword(qw)`] [__unused__]]
+]
+
+[heading Complexity]
+
+[:O(N), where N is the number of bytes emitted by the binary generator]
+
+[heading Example]
+
+Some includes:
+
+[reference_karma_includes]
+
+All code snippets below use these common test functions:
+
+[reference_karma_binary_test]
+[reference_karma_binary_test_attr]
+
+Some using declarations:
+
+[reference_karma_using_declarations_big_binary]
+
+Basic usage of the big binary generators:
+
+[reference_karma_big_binary]
+
+[endsect]
[endsect]
Modified: trunk/libs/spirit/doc/karma/char.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/char.qbk (original)
+++ trunk/libs/spirit/doc/karma/char.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -9,13 +9,17 @@
[section:char Char]
This module includes different character oriented generators allowing to output
-single characters. It includes the character and character class generators.
+single characters. Currently, it includes literal chars (e.g. `'x'`, `L'x'`),
+`char_` (single characters, ranges and character sets) and the encoding
+specific character classifiers (`alnum`, `alpha`, `digit`, `xdigit`, etc.).
[heading Module Header]
// forwards to <boost/spirit/home/karma/char.hpp>
#include <boost/spirit/include/karma_char.hpp>
+Also, see __include_structure__.
+
[/////////////////////////////////////////////////////////////////////////////]
[section:char_generator Character Generators]
Modified: trunk/libs/spirit/doc/karma/directive.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/directive.qbk (original)
+++ trunk/libs/spirit/doc/karma/directive.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -20,6 +20,8 @@
// forwards to <boost/spirit/home/karma/directive.hpp>
#include <boost/spirit/include/karma_directive.hpp>
+Also, see __include_structure__.
+
[/////////////////////////////////////////////////////////////////////////////]
[section:alignment Alignment Directives (`left_align[]`, `center[]`, and `right_align[]`)]
Modified: trunk/libs/spirit/doc/karma/numeric.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/numeric.qbk (original)
+++ trunk/libs/spirit/doc/karma/numeric.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -17,6 +17,8 @@
// forwards to <boost/spirit/home/karma/numeric.hpp>
#include <boost/spirit/include/karma_numeric.hpp>
+Also, see __include_structure__.
+
[/////////////////////////////////////////////////////////////////////////////]
[section:signed_int Signed Integer Number Generators]
@@ -172,6 +174,19 @@
any output.]]
]
+[heading Template parameters]
+
+[table
+ [[Parameter] [Description] [Default]]
+ [[`Num`] [The type of the integer
+ to generate] [`int`]]
+ [[`Radix`] [The radix to use while
+ converting the integer] [`10`]]
+ [[`force_sign`] [If `true`, all numbers will
+ have a sign (space for
+ zero)] [`false`]]
+]
+
[heading Additional Requirements]
The following lists enumerate the requirements which must be met in order to
@@ -432,6 +447,16 @@
any output.]]
]
+[heading Template parameters]
+
+[table
+ [[Parameter] [Description] [Default]]
+ [[`Num`] [The type of the integer
+ to generate] [`unsigned int`]]
+ [[`Radix`] [The radix to use while
+ converting the integer] [`10`]]
+]
+
[heading Additional Requirements]
The following lists enumerate the requirements which must be met in order to
@@ -662,6 +687,17 @@
error).]]
]
+[heading Template parameters]
+
+[table
+ [[Parameter] [Description] [Default]]
+ [[`Num`] [The type of the floating
+ point number to generate] [`double`]]
+ [[`Policies`] [The policies to use while
+ converting the floatng
+ point number] [`real_policies<Num>`]]
+]
+
For more information about the type `Policies` see
[link spirit.karma.reference.numeric.floating_point.floating_point_formatting_policies below]).
@@ -722,16 +758,16 @@
[heading Floating Point Formatting Policies]
-If special formatting of a floating point number is needed, just overload
+If special formatting of a floating point number is needed, overload
the policy class `real_policies<Num>` and use it as a template
parameter to the `real_generator<>` floating point generator. For instance:
// define a new floating point formatting policy
- template <typename T>
- struct scientific_policy : real_policies<T>
+ template <typename Num>
+ struct scientific_policy : real_policies<Num>
{
// we want the numbers always to be in scientific format
- static int floatfield(T n) { return fmtflags::scientific; }
+ static int floatfield(Num n) { return fmtflags::scientific; }
};
// define a new generator type based on the new policy
@@ -742,9 +778,10 @@
generate(sink, science_type(), 1.0); // will output: 1.0e00
generate(sink, scientific, 0.1); // will output: 1.0e-01
-The template parameter `T` should be the type to be formatted using the
-overloaded policy type. At the same time `T` will be used as the attribute type
-of the created floating point generator.
+The template parameter `Num` should be the type to be formatted using the
+overloaded policy type. At the same time `Num` will be used as the attribute
+type of the created floating point generator.
+
[heading Floating Point Formatting Policy Expression Semantics]
@@ -757,7 +794,7 @@
template <typename Inserter
, typename OutputIterator
, typename Policies>
- bool call (OutputIterator& sink, T n
+ bool call (OutputIterator& sink, Num n
, Policies const& p);
``]
[This is the main function used to generate the output for a floating point
@@ -770,7 +807,7 @@
template <typename Inserter, typename OutputIterator
, typename Policies>
static bool
- call (OutputIterator& sink, T n, Policies const& p)
+ call (OutputIterator& sink, Num n, Policies const& p)
{
return Inserter::call_n(sink, n, p);
}
@@ -783,7 +820,7 @@
point generator.
]]
[ [``
- bool force_sign(T n);
+ bool force_sign(Num n);
``]
[The default behavior is to not to require generating a sign. If the function
`force_sign()` returns true, then all generated numbers will have a
@@ -792,7 +829,7 @@
`n` is the floating point number to output. This can be used to
adjust the required behavior depending on the value of this number.]]
[ [``
- bool trailing_zeros(T n);
+ bool trailing_zeros(Num n);
``]
[Return whether trailing zero digits have to be emitted in the fractional
part of the output. If set, this flag instructs the floating point
@@ -802,7 +839,7 @@
`n` is the floating point number to output. This can be used to
adjust the required behavior depending on the value of this number.]]
[ [``
- int floatfield(T n);
+ int floatfield(Num n);
``]
[Decide, which representation type to use in the generated output.
@@ -824,7 +861,7 @@
floating point values in fixed-point notation).
]]
[ [``
- unsigned precision(T n);
+ unsigned precision(Num n);
``]
[Return the maximum number of decimal digits to generate in the
fractional part of the output.
@@ -842,7 +879,7 @@
template <bool ForceSign,
typename OutputIterator>
bool integer_part(OutputIterator& sink
- , T n, bool sign, bool force_sign);
+ , Num n, bool sign, bool force_sign);
``]
[This function is called to generate the integer part of the floating point
number.
@@ -859,12 +896,12 @@
the function `force_sign()` described above)
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
[ [``
template <typename OutputIterator>
- bool dot(OutputIterator& sink, T n,
+ bool dot(OutputIterator& sink, Num n,
unsigned precision);
``]
[This function is called to generate the decimal point.
@@ -887,12 +924,12 @@
apply. See the description for the `fraction_part()` function below.
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
[ [``
template <typename OutputIterator>
- bool fraction_part(OutputIterator& sink, T n
+ bool fraction_part(OutputIterator& sink, Num n
, unsigned adjprec, unsigned precision);
``]
[This function is called to generate the fractional part of the number.
@@ -927,7 +964,7 @@
by the implementation of this policy function.
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
[ [``
@@ -950,17 +987,17 @@
`upper[]` directives.
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
[ [``
template <typename CharEncoding
, typename Tag, typename OutputIterator>
- bool nan (OutputIterator& sink, T n
+ bool nan (OutputIterator& sink, Num n
, bool force_sign);
``]
[This function is called whenever the number to print is a non-normal
- floats of type NaN.
+ floating point number of type `NaN`.
`sink`: is the output iterator to use for generation
@@ -976,17 +1013,17 @@
`upper[]` directives.
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
[ [``
template <typename CharEncoding
, typename Tag, typename OutputIterator>
- bool inf (OutputIterator& sink, T n
+ bool inf (OutputIterator& sink, Num n
, bool force_sign);
``]
[This function is called whenever the number to print is a non-normal
- floats of type Inf.
+ floating point number of type `Inf`.
`sink`: is the output iterator to use for generation
@@ -1002,14 +1039,15 @@
`upper[]` directives.
The return value defines the outcome of the whole generator. If it is
- `false`, no further output is generated, imediatly returning `false` from
+ `false`, no further output is generated, immediatly returning `false` from
the calling `real_generator` as well. If it is `true`, normal output
generation continues.]]
]
-The easiest way to implement a proper floating point formatting policy is to
-derive a new type from the the type `real_policies<>` while overriding the
-aspects of the formatting which need to be changed.
+[tip The easiest way to implement a proper floating point formatting policy is
+ to derive a new type from the the type `real_policies<>` while overriding
+ the aspects of the formatting which need to be changed.]
+
[heading Complexity]
Modified: trunk/libs/spirit/doc/karma/operator.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/operator.qbk (original)
+++ trunk/libs/spirit/doc/karma/operator.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -19,6 +19,8 @@
// forwards to <boost/spirit/home/karma/operator.hpp>
#include <boost/spirit/include/karma_operator.hpp>
+Also, see __include_structure__.
+
[/////////////////////////////////////////////////////////////////////////////]
[section:sequence Sequences (`operator<<()`)]
Modified: trunk/libs/spirit/doc/karma/quick_reference.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/quick_reference.qbk (original)
+++ trunk/libs/spirit/doc/karma/quick_reference.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -48,7 +48,7 @@
[endsect]
[/////////////////////////////////////////////////////////////////////////////]
-[section:primitive_generators Primitive Generators]
+[section:primitive_generators Karma Generators]
[section:char Character Generators]
@@ -160,6 +160,36 @@
[endsect]
+[section:signed_int Integer Generators]
+
+[table
+ [[Expression] [Attribute] [Description]]
+ [[[signed_int `short_`]] [`short`] [Generate a short integer]]
+ [[[signed_int `short_(num)`]] [`short`] [Generate `num` as a short integer,
+ if an attribute is supplied it must match]]
+ [[[signed_int `int_`]] [`int`] [Generate an int]]
+ [[[signed_int `int_(num)`]] [`int`] [Generate `num` as an int,
+ if an attribute is supplied it must match]]
+ [[[signed_int `long_`]] [`long`] [Generate a long integer]]
+ [[[signed_int `long_(num)`]] [`long`] [Generate `num` as long integer,
+ if an attribute is supplied it must match]]
+ [[[signed_int `long_long`]] [`long long`] [Generate a long long]]
+ [[[signed_int `long_long(num)`]] [`long long`] [Generate `num` as an long long,
+ if an attribute is supplied it must match]]
+
+ [[[signed_int ``int_generator<
+ Num, Radix, force_sign
+>()``]]
+ [`Num`] [Generate a `Num`]]
+ [[[signed_int ``int_generator<
+ Num, Radix, force_sign
+>()(num)``]]
+ [`Num`] [Generate a `num` as a `Num`,
+ if an attribute is supplied it must match]]
+]
+
+[endsect]
+
[section:unsigned_int Unsigned Integer Generators]
[table
@@ -193,32 +223,33 @@
[endsect]
-[section:signed_int Integer Generators]
+[section:stream Stream Generators]
-[table
- [[Expression] [Attribute] [Description]]
- [[[signed_int `short_`]] [`short`] [Generate a short integer]]
- [[[signed_int `short_(num)`]] [`short`] [Generate `num` as a short integer,
- if an attribute is supplied it must match]]
- [[[signed_int `int_`]] [`int`] [Generate an int]]
- [[[signed_int `int_(num)`]] [`int`] [Generate `num` as an int,
- if an attribute is supplied it must match]]
- [[[signed_int `long_`]] [`long`] [Generate a long integer]]
- [[[signed_int `long_(num)`]] [`long`] [Generate `num` as long integer,
- if an attribute is supplied it must match]]
- [[[signed_int `long_long`]] [`long long`] [Generate a long long]]
- [[[signed_int `long_long(num)`]] [`long long`] [Generate `num` as an long long,
- if an attribute is supplied it must match]]
+See here for more information about __karma_stream__.
- [[[signed_int ``int_generator<
- Num, Radix, force_sign
->()``]]
- [`Num`] [Generate a `Num`]]
- [[[signed_int ``int_generator<
- Num, Radix, force_sign
->()(num)``]]
- [`Num`] [Generate a `num` as a `Num`,
- if an attribute is supplied it must match]]
+[table
+ [[Expression] [Attribute] [Description]]
+ [[[karma_stream `stream`]] [`hold_any`] [Generates narrow character (`char`) based output
+ using the matching streaming `operator<<()`]]
+ [[[karma_stream `stream(s)`]] [`Unused`] [Generates narrow character (`char`) based output
+ from the immediate argument `s` using the matching
+ streaming `operator<<()`]]
+ [[[karma_stream `wstream`]] [`hold_any`] [Generates narrow character (`wchar_t`) based output
+ using the matching streaming `operator<<()`]]
+ [[[karma_stream `wstream(s)`]] [`Unused`] [Generates wide character (`wchar_t`) based output
+ from the immediate argument `s` using the matching
+ streaming `operator<<()`]]
+ [
+[[karma_stream ``stream_generator<
+ Char
+>()``]] [`hold_any`] [Generates output based on the given character type
+ (`Char`) using the matching streaming `operator<<()`]]
+ [
+[[karma_stream ``stream_generator<
+ Char
+>()(s)``]] [`Unused`] [Generates output based on the given character type
+ `Char` from the immediate argument `s` using the
+ matching streaming `operator<<()`]]
]
[endsect]
@@ -228,17 +259,19 @@
See here for more information about __karma_binary__.
[table
- [[Expression] [Attribute] [Description]]
- [[`byte_`] [8 bits native endian] [Generates an 8 bit binary]]
- [[`word`] [16 bits native endian] [Generates a 16 bit binary in native endian representation]]
- [[`big_word`] [16 bits big endian] [Generates a 16 bit binary in big endian representation]]
- [[`little_word`] [16 bits little endian] [Generates a 16 bit binary in little endian representation]]
- [[`dword`] [32 bits native endian] [Generates a 32 bit binary in native endian representation]]
- [[`big_dword`] [32 bits big endian] [Generates a 32 bit binary in big endian representation]]
- [[`little_dword`] [32 bits little endian] [Generates a 32 bit binary in little endian representation]]
- [[`qword`] [64 bits native endian] [Generates a 64 bit binary in native endian representation]]
- [[`big_qword`] [64 bits big endian] [Generates a 64 bit binary in big endian representation]]
- [[`little_qword`] [64 bits little endian] [Generates a 64 bit binary in little endian representation]]
+ [[Expression] [Attribute] [Description]]
+ [[[karma_native_binary `byte_`]] [8 bits native endian] [Generates an 8 bit binary]]
+ [[[karma_native_binary `word`]] [16 bits native endian] [Generates a 16 bit binary in native endian representation]]
+ [[[karma_big_binary `big_word`]] [16 bits big endian] [Generates a 16 bit binary in big endian representation]]
+ [[[karma_little_binary `little_word`]] [16 bits little endian] [Generates a 16 bit binary in little endian representation]]
+ [[[karma_native_binary `dword`]] [32 bits native endian] [Generates a 32 bit binary in native endian representation]]
+ [[[karma_big_binary `big_dword`]] [32 bits big endian] [Generates a 32 bit binary in big endian representation]]
+ [[[karma_little_binary `little_dword`]][32 bits little endian] [Generates a 32 bit binary in little endian representation]]
+ [[[karma_native_binary `qword`]] [64 bits native endian] [Generates a 64 bit binary in native endian representation]]
+ [[[karma_big_binary `big_qword`]] [64 bits big endian] [Generates a 64 bit binary in big endian representation]]
+ [[[karma_little_binary `little_qword`]][64 bits little endian] [Generates a 64 bit binary in little endian representation]]
+ [[`pad(num)`] [`Unused`] [Generate additional null bytes allowing to align generated
+ output with memory addresses divisible by `num`.]]
]
[endsect]
Modified: trunk/libs/spirit/doc/karma/stream.qbk
==============================================================================
--- trunk/libs/spirit/doc/karma/stream.qbk (original)
+++ trunk/libs/spirit/doc/karma/stream.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -130,6 +130,14 @@
is assumed to be `Char`.]]
]
+[heading Template parameters]
+
+[table
+ [[Parameter] [Description] [Default]]
+ [[`Char`] [The character type used by
+ the underlying ostream] [`char`]]
+]
+
[heading Additional Requirements]
All of the stream generators listed above require the type of the value to
@@ -179,6 +187,7 @@
[heading Complexity]
+[:O(N), where N is the number of characters emitted by the stream generator]
[heading Example]
Modified: trunk/libs/spirit/doc/spirit2.qbk
==============================================================================
--- trunk/libs/spirit/doc/spirit2.qbk (original)
+++ trunk/libs/spirit/doc/spirit2.qbk 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -93,7 +93,8 @@
[def __karma_directive__ [link spirit.karma.reference.directive Generator Directives]]
[def __karma_operator__ [link spirit.karma.reference.operator Generator Operators]]
[def __karma_numeric__ [link spirit.karma.reference.numeric Numeric Generators]]
-[def __karma_binary__ Binary Generators [/link spirit.karma.reference.binary Binary Generators]]
+[def __karma_binary__ [link spirit.karma.reference.binary Binary Generators]]
+[def __karma_stream__ [link spirit.karma.reference.stream Stream Generators]]
[def __sec_lex__ [link spirit.lex Lex]]
[def __sec_lex_quickstart_1__ [link spirit.lex.tutorials.lexer_quickstart1 Lex Quickstart 1 - A word counter using __lex__]]
@@ -195,6 +196,12 @@
[template karma_string[str] [link spirit.karma.reference.string [str]]]
+[template karma_stream[str] [link spirit.karma.reference.stream [str]]]
+
+[template karma_native_binary[str] [link spirit.karma.reference.binary.binary_native [str]]]
+[template karma_little_binary[str] [link spirit.karma.reference.binary.binary_little [str]]]
+[template karma_big_binary[str] [link spirit.karma.reference.binary.binary_big [str]]]
+
[def __actions__ Semantic Actions] [/$$$ TODO: link me $$$]
[def __context__ Context] [/$$$ TODO: link me $$$]
[def __compatible__ Compatible] [/$$$ TODO: link me $$$]
@@ -274,4 +281,3 @@
[include acknowledgments.qbk]
[include references.qbk]
-
Modified: trunk/libs/spirit/example/karma/reference.cpp
==============================================================================
--- trunk/libs/spirit/example/karma/reference.cpp (original)
+++ trunk/libs/spirit/example/karma/reference.cpp 2009-08-29 17:01:56 EDT (Sat, 29 Aug 2009)
@@ -60,6 +60,32 @@
}
//]
+//[reference_karma_binary_test
+template <typename G>
+void test_binary_generator(char const* expected, std::size_t size, G const& g)
+{
+ std::string s;
+ std::back_insert_iterator<std::string> out(s);
+ if (boost::spirit::karma::generate(out, g) && !std::memcmp(s.c_str(), expected, size))
+ std::cout << "ok" << std::endl;
+ else
+ std::cout << "fail" << std::endl;
+}
+//]
+
+//[reference_karma_binary_test_attr
+template <typename G, typename T>
+void test_binary_generator_attr(char const* expected, std::size_t size, G const& g, T const& attr)
+{
+ std::string s;
+ std::back_insert_iterator<std::string> out(s);
+ if (boost::spirit::karma::generate(out, g, attr) && !std::memcmp(s.c_str(), expected, size))
+ std::cout << "ok" << std::endl;
+ else
+ std::cout << "fail" << std::endl;
+}
+//]
+
//[reference_karma_stream_complex
// a simple complex number representation z = a + bi
struct complex
@@ -511,5 +537,69 @@
//]
}
+ ///////////////////////////////////////////////////////////////////////////
+ // binary module
+ {
+ //[reference_karma_using_declarations_native_binary
+ using boost::spirit::karma::generate;
+ //]
+
+ //[reference_karma_native_binary_little
+ test_binary_generator("\x01", 1, byte_(0x01));
+ test_binary_generator("\x01\x02", 2, word(0x0201));
+ test_binary_generator("\x01\x02\x03\x04", 4, dword(0x04030201));
+ test_binary_generator("\x01\x02\x03\x04\x05\x06\x07\x08", 8, qword(0x0807060504030201LL));
+
+ test_binary_generator_attr("\x01", 1, byte_, 0x01);
+ test_binary_generator_attr("\x01\x02", 2, word, 0x0201);
+ test_binary_generator_attr("\x01\x02\x03\x04", 4, dword, 0x04030201);
+ test_binary_generator_attr("\x01\x02\x03\x04\x05\x06\x07\x08", 8, qword, 0x0807060504030201LL);
+ //]
+
+ //[reference_karma_native_binary_big
+ test_binary_generator("\x01", 1, byte_(0x01));
+ test_binary_generator("\x02\x01", 2, word(0x0201));
+ test_binary_generator("\x04\x03\x02\x01", 4, dword(0x04030201));
+ test_binary_generator("\x08\x07\x06\x05\x04\x03\x02\x01", 8, qword(0x0807060504030201LL));
+
+ test_binary_generator_attr("\x01", 1, byte_, 0x01);
+ test_binary_generator_attr("\x02\x01", 2, word, 0x0201);
+ test_binary_generator_attr("\x04\x03\x02\x01", 4, dword, 0x04030201);
+ test_binary_generator_attr("\x08\x07\x06\x05\x04\x03\x02\x01", 8, qword, 0x0807060504030201LL);
+ //]
+ }
+
+ {
+ //[reference_karma_using_declarations_little_binary
+ using boost::spirit::karma::generate;
+ //]
+
+ //[reference_karma_little_binary
+ test_binary_generator("\x01\x02", 2, little_word(0x0201));
+ test_binary_generator("\x01\x02\x03\x04", 4, little_dword(0x04030201));
+ test_binary_generator("\x01\x02\x03\x04\x05\x06\x07\x08", 8, little_qword(0x0807060504030201LL));
+
+ test_binary_generator_attr("\x01\x02", 2, little_word, 0x0201);
+ test_binary_generator_attr("\x01\x02\x03\x04", 4, little_dword, 0x04030201);
+ test_binary_generator_attr("\x01\x02\x03\x04\x05\x06\x07\x08", 8, little_qword, 0x0807060504030201LL);
+ //]
+ }
+
+ {
+ //[reference_karma_using_declarations_big_binary
+ using boost::spirit::karma::generate;
+ //]
+
+ //[reference_karma_big_binary
+ test_binary_generator("\x02\x01", 2, big_word(0x0201));
+ test_binary_generator("\x04\x03\x02\x01", 4, big_dword(0x04030201));
+ test_binary_generator("\x08\x07\x06\x05\x04\x03\x02\x01", 8, big_qword(0x0807060504030201LL));
+
+ test_binary_generator_attr("\x02\x01", 2, big_word, 0x0201);
+ test_binary_generator_attr("\x04\x03\x02\x01", 4, big_dword, 0x04030201);
+ test_binary_generator_attr("\x08\x07\x06\x05\x04\x03\x02\x01", 8, big_qword, 0x0807060504030201LL);
+ //]
+ }
+
return 0;
}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk