Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r76286 - in trunk/libs/proto: doc doc/reference doc/reference/concepts doc/reference/context doc/reference/functional doc/reference/functional/fusion doc/reference/functional/std doc/reference/transform example
From: eric_at_[hidden]
Date: 2012-01-02 19:38:42


Author: eric_niebler
Date: 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
New Revision: 76286
URL: http://svn.boost.org/trac/boost/changeset/76286

Log:
add user docs for per-domain as_child, missing copyrights on BoostBook files, typos in examples
Added:
   trunk/libs/proto/doc/reference/context.xml (contents, props changed)
   trunk/libs/proto/doc/reference/transform.xml (contents, props changed)
Text files modified:
   trunk/libs/proto/doc/front_end.qbk | 361 ++++++++++++++++++++++++++++-----------
   trunk/libs/proto/doc/reference.xml | 2
   trunk/libs/proto/doc/reference/args.xml | 7
   trunk/libs/proto/doc/reference/concepts/CallableTransform.xml | 4
   trunk/libs/proto/doc/reference/concepts/Domain.xml | 4
   trunk/libs/proto/doc/reference/concepts/Expr.xml | 4
   trunk/libs/proto/doc/reference/concepts/ObjectTransform.xml | 2
   trunk/libs/proto/doc/reference/concepts/PolymorphicFunctionObject.xml | 4
   trunk/libs/proto/doc/reference/concepts/PrimitiveTransform.xml | 4
   trunk/libs/proto/doc/reference/concepts/Transform.xml | 4
   trunk/libs/proto/doc/reference/context/callable.xml | 7
   trunk/libs/proto/doc/reference/context/default.xml | 7
   trunk/libs/proto/doc/reference/context/null.xml | 7
   trunk/libs/proto/doc/reference/core.xml | 7
   trunk/libs/proto/doc/reference/debug.xml | 7
   trunk/libs/proto/doc/reference/deep_copy.xml | 7
   trunk/libs/proto/doc/reference/domain.xml | 7
   trunk/libs/proto/doc/reference/eval.xml | 7
   trunk/libs/proto/doc/reference/expr.xml | 7
   trunk/libs/proto/doc/reference/extends.xml | 7
   trunk/libs/proto/doc/reference/functional.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/at.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/pop_back.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/pop_front.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/push_back.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/push_front.xml | 7
   trunk/libs/proto/doc/reference/functional/fusion/reverse.xml | 7
   trunk/libs/proto/doc/reference/functional/std.xml | 7
   trunk/libs/proto/doc/reference/functional/std/utility.xml | 7
   trunk/libs/proto/doc/reference/fusion.xml | 7
   trunk/libs/proto/doc/reference/generate.xml | 7
   trunk/libs/proto/doc/reference/literal.xml | 7
   trunk/libs/proto/doc/reference/make_expr.xml | 7
   trunk/libs/proto/doc/reference/matches.xml | 16 +
   trunk/libs/proto/doc/reference/operators.xml | 7
   trunk/libs/proto/doc/reference/proto.xml | 7
   trunk/libs/proto/doc/reference/proto_fwd.xml | 7
   trunk/libs/proto/doc/reference/proto_typeof.xml | 7
   trunk/libs/proto/doc/reference/repeat.xml | 7
   trunk/libs/proto/doc/reference/tags.xml | 7
   trunk/libs/proto/doc/reference/traits.xml | 7
   trunk/libs/proto/doc/reference/transform/arg.xml | 7
   trunk/libs/proto/doc/reference/transform/call.xml | 7
   trunk/libs/proto/doc/reference/transform/default.xml | 7
   trunk/libs/proto/doc/reference/transform/fold.xml | 7
   trunk/libs/proto/doc/reference/transform/fold_tree.xml | 7
   trunk/libs/proto/doc/reference/transform/impl.xml | 7
   trunk/libs/proto/doc/reference/transform/integral_c.xml | 7
   trunk/libs/proto/doc/reference/transform/lazy.xml | 7
   trunk/libs/proto/doc/reference/transform/make.xml | 7
   trunk/libs/proto/doc/reference/transform/pass_through.xml | 7
   trunk/libs/proto/doc/reference/transform/when.xml | 7
   trunk/libs/proto/example/lambda.hpp | 2
   trunk/libs/proto/example/mini_lambda.cpp | 2
   55 files changed, 585 insertions(+), 125 deletions(-)

Modified: trunk/libs/proto/doc/front_end.qbk
==============================================================================
--- trunk/libs/proto/doc/front_end.qbk (original)
+++ trunk/libs/proto/doc/front_end.qbk 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -272,11 +272,18 @@
 
 [endsect]
 
-[/==============================================]
-[section Adding Members by Extending Expressions]
-[/==============================================]
-
-In this section, we'll see how to associate Proto expressions with a /domain/, how to add members to expressions within a domain, and how to control which operators are overloaded in a domain.
+[/=============================================]
+[section Customizing Expressions in Your Domain]
+[/=============================================]
+
+In this section, we'll learn all about /domains/. In particular, we'll learn:
+
+* How to associate Proto expressions with a domain,
+* How to add members to expressions within a domain,
+* How to use a /generator/ to post-process all new expressions created in your domain,
+* How to control which operators are overloaded in a domain,
+* How to specify capturing policies for child expressions and non-Proto objects, and
+* How to make expressions from separate domains interoperate.
 
 [/==============]
 [section Domains]
@@ -591,6 +598,249 @@
 
 [endsect]
 
+[/=========================================================================]
+[section:per_domain_as_child Controlling How Child Expressions Are Captured]
+[/=========================================================================]
+
+Proto's operator overloads build expressions from sub-expressions. The sub-expressions become children of the new expression. By default, the children are stored in the parent by reference. This section describes how to change that default.
+
+[/-----------------------------------------]
+[heading Primer: [^as_child] vs. [^as_expr]]
+[/-----------------------------------------]
+
+Proto lets you independently customize the behavior of _as_child_ and _as_expr_. Both accept an object [^x] and return a Proto expression by turning [^x] it into a Proto terminal if necessary. Although similar, the two functions are used in different situations and have subtly different behavior by default. It's important to understand the difference so that you know which to customize to achieve the behavior you want.
+
+To wit: _as_expr_ is typically used by /you/ to turn an object into a Proto expression that is to be held in a local variable, as so:
+
+ auto l = proto::as_expr(x); // Turn x into a Proto expression, hold the result in a local
+
+The above works regardless of whether `x` is already a Proto expression or not. The object `l` is guaranteed to be a valid Proto expression. If `x` is a non-Proto object, it is turned into terminal expression that hold `x` /by value/.[footnote It's not always possible to hold something by value. By default, _as_expr_ makes an exception for functions, abstract types, and iostreams (types derived from `std::ios_base`). These objects are held by reference. All others are held by value, even arrays.] If `x` is a Proto object already, _as_expr_ returns it /by value/ unmodified.
+
+In contrast, _as_child_ is used internally by Proto to pre-process some object before making it a child of another expression. Since it's internal to Proto, you don't see it explicitly, but it's there behind the scenes in expressions like this:
+
+ x + y; // Consider that y is a Proto expression, but x may or may not be.
+
+In this case, Proto builds a plus node from the two children. Both are pre-processed by passing them to _as_child_ before making them children of the new node. If `x` is not a Proto expression, it becomes one by being wrapped in a Proto terminal that holds it /by reference/. If `x` is already a Proto expression, _as_child_ returns it /by reference/ unmodified. Contrast this with the above description for _as_expr_.
+
+The table below summarizes the above description.
+
+[table proto::as_expr() vs. proto::as_child()
+[[[*Function]] [[*When [^t] is not a Proto expr...]] [[*When [^t] is a Proto expr...]]]
+[[[^proto::as_expr(t)]] [Return (by value) a new Proto terminal holding [^t] by value.] [Return [^t] by value unmodified.]]
+[[[^proto::as_child(t)]] [Return (by value) a new Proto terminal holding [^t] by reference.] [Return [^t] by reference unmodified.]]
+]
+
+Now that you know what _as_child_ and _as_expr_ are, where they are used, and what they do by default, you may decide that one or both of these functions should have different behavior for your domain. For instance, given the above description of _as_child_, the following code is always wrong:
+
+ proto::literal<int> i(0);
+ auto l = i + 42; // This is WRONG! Don't do this.
+
+Why is this wrong? Because _as_child_ will turn the integer literal 42 into a Proto terminal that holds a reference to a temporary integer initialized with 42. The lifetime of that temporary ends at the semicolon, guaranteeing that the local `l` is left holding a dangling reference to a deceased integer. What to do? One answer is to use _deep_copy_. Another is to customize the behavior of _as_child_ for your domain. Read on for the details.
+
+[/-----------------------------]
+[heading Per-Domain [^as_child]]
+[/-----------------------------]
+
+To control how Proto builds expressions out of sub-expressions in your domain, define your domain as usual, and then define a nested `as_child<>` class template within it, as follows:
+
+[def __unspecified_expression_type__ ['[^unspecified-Proto-expr-type]]]
+[def __unspecified_expression__ ['[^unspecified-Proto-expr-object]]]
+
+ class my_domain
+ : proto::domain< my_generator, my_grammar >
+ {
+ // Here is where you define how Proto should handle
+ // sub-expressions that are about to be glommed into
+ // a larger expression.
+ template< typename T >
+ struct as_child
+ {
+ typedef __unspecified_expression_type__ result_type;
+
+ result_type operator()( T & t ) const
+ {
+ return __unspecified_expression__;
+ }
+ };
+ };
+
+There's one important thing to note: in the above code, the template parameter [^T] may or may not be a Proto expression type, but the result /must/ be a Proto expression type, or a reference to one. That means that most user-defined [^as_child<>] templates will need to check whether [^T] is an expression or not (using _is_expr_), and then turn non-expressions into Proto terminals by wrapping them as `proto::terminal< /* ... */ >::type` or equivalent.
+
+[/----------------------------]
+[heading Per-Domain [^as_expr]]
+[/----------------------------]
+
+Although less common, Proto also lets you customize the behavior of _as_expr_ on a per-domain basis. The technique is identical to that for [^as_child]. See below:
+
+ class my_domain
+ : proto::domain< my_generator, my_grammar >
+ {
+ // Here is where you define how Proto should handle
+ // objects that are to be turned into expressions
+ // fit for storage in local variables.
+ template< typename T >
+ struct as_expr
+ {
+ typedef __unspecified_expression_type__ result_type;
+
+ result_type operator()( T & t ) const
+ {
+ return __unspecified_expression__;
+ }
+ };
+ };
+
+
+[/--------------------------------------------]
+[heading Making Proto Expressions [^auto]-safe]
+[/--------------------------------------------]
+
+Let's look again at the problem described above involving the C++11 `auto` keyword and the default behavior of _as_child_.
+
+ proto::literal<int> i(0);
+ auto l = i + 42; // This is WRONG! Don't do this.
+
+Recall that the problem is the lifetime of the temporary integer created to hold the value 42. The local `l` will be left holding a dangling reference to it after its lifetime is over. What if we want Proto to make expressions safe to store this way in local variables? We can do so very easily by making _as_child_ behave just like _as_expr_. The following code achieves this:
+
+ template< typename E >
+ struct my_expr;
+
+ struct my_generator
+ : proto::pod_generator< my_expr >
+ {};
+
+ struct my_domain
+ : proto::domain< my_generator >
+ {
+ // Make as_child() behave like as_expr() in my_domain.
+ // (proto_base_domain is a typedef for proto::domain< my_generator >
+ // that is defined in proto::domain<>.)
+ template< typename T >
+ struct as_child
+ : proto_base_domain::as_expr< T >
+ {};
+ };
+
+ template< typename E >
+ struct my_expr
+ {
+ BOOST_PROTO_EXTENDS( E, my_expr< E >, my_domain )
+ };
+
+ /* ... */
+
+ proto::literal< int, my_domain > i(0);
+ auto l = i + 42; // OK! Everything is stored by value here.
+
+Notice that `my_domain::as_child<>` simply defers to the default implementation of `as_expr<>` found in _domain_. By simply cross-wiring our domain's `as_child<>` to `as_expr<>`, we guarantee that all terminals that can be held by value are, and that all child expressions are also held by value. This increases copying and may incur a runtime performance cost, but it eliminates any spector of lifetime management issues.
+
+For another example, see the definition of `lldomain` in [^libs/proto/example/lambda.hpp]. That example is a complete reimplementation of the Boost Lambda Library (BLL) on top of Boost.Proto. The function objects the BLL generates are safe to be stored in local variables. To emulate this with Proto, the `lldomain` cross-wires `as_child<>` to `as_expr<>` as above, but with one extra twist: objects with array type are also stored by reference. Check it out.
+
+[endsect]
+
+[/======================================================]
+[section:subdomains EDSL Interoperatability: Sub-Domains]
+[/======================================================]
+
+The ability to /compose/ different EDSLs is one of their most exciting features. Consider how you build a parser using yacc. You write your grammar rules in yacc's domain-specific language. Then you embed semantic actions written in C within your grammar. Boost's Spirit parser generator gives you the same ability. You write grammar rules using Spirit.Qi and embed semantic actions using the Phoenix library. Phoenix and Spirit are both Proto-based domain-specific languages with their own distinct syntax and semantics. But you can freely embed Phoenix expressions within Spirit expressions. This section describes Proto's /sub-domain/ feature that lets you define famalies of interoperable domains.
+
+[/======================]
+[heading Dueling Domains]
+[/======================]
+
+Sub-domains solve a specific problem that only comes up when you try to create an expression from two sub-expressions in different domains: what is the domain of the resulting expression? Consider the following code:
+
+ #include <boost/proto/proto.hpp>
+ namespace proto = boost::proto;
+
+ // Forward-declare two expression wrappers
+ template<typename E> struct spirit_expr;
+ template<typename E> struct phoenix_expr;
+
+ // Define two domains
+ struct spirit_domain : proto::domain<proto::generator<spirit_expr> > {};
+ struct phoenix_domain : proto::domain<proto::generator<phoenix_expr> > {};
+
+ // Implement the two expresison wrappers
+ template<typename E>
+ struct spirit_expr
+ : proto::extends<E, spirit_expr<E>, spirit_domain>
+ {
+ spirit_expr(E const &e = E()) : spirit_expr::proto_extends(e) {}
+ };
+
+ template<typename E>
+ struct phoenix_expr
+ : proto::extends<E, phoenix_expr<E>, phoenix_domain>
+ {
+ phoenix_expr(E const &e = E()) : phoenix_expr::proto_extends(e) {}
+ };
+
+ int main()
+ {
+ proto::literal<int, spirit_domain> sp(0);
+ proto::literal<int, phoenix_domain> phx(0);
+
+ // Whoops! What does it mean to add two expression in different domains?
+ sp + phx; // ERROR
+ }
+
+Above, we define two domains called `spirit_domain` and `phoenix_domain` and declare two int literals in each. Then we try to compose them into a larger expression using Proto's binary plus operator, and it fails. Proto can't figure out whether the resulting expression should be in the Spirit domain or the Phoenix domain, and thus whether it should be an instance of `spirit_expr<>` or `phoenix_expr<>`. We have to tell Proto how to resolve the conflict. We can do that by declaring that Phoenix is a sub-domain of Spirit as in the following definition of `phoenix_domain`:
+
+[def __spirit_domain__ [*spirit_domain]]
+
+ // Declare that phoenix_domain is a sub-somain of spirit_domain
+ struct phoenix_domain
+ : proto::domain<proto::generator<phoenix_expr>, proto::_, __spirit_domain__>
+ {};
+
+The third template parameter to _domain_ is the super-domain. By defining `phoenix_domain` as above, we are saying that Phoenix expressions can be combined with Spirit expressions, and that when that happens, the resulting expression should be a Spirit expression.
+
+[note If you are wondering what the purpose of `proto::_` is in the definition of `phoenix_domain` above, recall that the second template parameter to _domain_ is the domain's grammar. ["`proto::_`] is the default and signifies that the domain places no restrictions on the expressions that are valid within it.]
+
+[/------------------------]
+[heading Domain Resolution]
+[/------------------------]
+
+When there are multiple domains in play within a given expression, Proto uses some rules to figure out which domain "wins". The rules are loosly modeled on the rules for C++ inheritance. `Phoenix_domain` is a sub-domain of `spirit_domain`. You can liken that to a derived/base relationship that gives Phoenix expressions a kind of implicit conversion to Spirit expressions. And since Phoenix expressions can be "converted" to Spirit expressions, they can be freely combined with Spirit expressions and the result is a Spirit expression.
+
+[note Super- and sub-domains are not actually implemented using inheritance. This is only a helpful mental model.]
+
+The analogy with inheritance holds even in the case of three domains when two are sub-domains of the third. Imagine another domain called `foobar_domain` that was also a sub-domain of `spirit_domain`. Expressions in the `foobar_domain` could be combined with expressions in the `phoenix_domain` and the resulting expression would be in the `spirit_domain`. That's because expressions in the two sub-domains both have "conversions" to the super-domain, so the operation is allowed and the super-domain wins.
+
+[/-------------------------]
+[heading The Default Domain]
+[/-------------------------]
+
+When you don't assign a Proto expression to a particular domain, Proto considers it a member of the so-called default domain, `proto::default_domain`. Even non-Proto objects are treated as terminals in the default domain. Consider:
+
+ int main()
+ {
+ proto::literal<int, spirit_domain> sp(0);
+
+ // Add 1 to a spirit expression. Result is a spirit expression.
+ sp + 1;
+ }
+
+In light of the above discussion about sub-domains, one could think of `proto::default_domain` as a sub-domain of /every other domain/. Expressions in the default domain have a kind of implicit conversion to every other domain type. That's exactly how Proto sees it! What's more, you can define your domain to be a sub-domain of the default domain. In so doing, you give expression in your domain conversions to expressions in every other domain. This is like a "free love" domain, because it will freely mix with all other domains.
+
+Let's think again about the Phoenix EDSL. Since it provides generally useful lambda functionionality, it's reasonable to assume that lots of other EDSLs besides Spirit might want the ability to embed Phoenix expressions. In other words, `phoenix_domain` should be a sub-domain of `proto::default_domain`, not `spirit_domain`:
+
+ // Declare that phoenix_domain is a sub-somain of proto::default_domain
+ struct phoenix_domain
+ : proto::domain<proto::generator<phoenix_expr>, proto::_, proto::default_domain>
+ {};
+
+That's much better. Phoenix expressions can now be put anywhere.
+
+[/-------------------------]
+[heading Sub-Domain Summary]
+[/-------------------------]
+
+Use Proto sub-domains to make it possible to mix expressions from multiple domains. And when you want expressions in your domain to freely combine with /all/ expressions, make it a sub-domain of `proto::default_domain`.
+
+[endsect]
+
 [endsect]
 
 [section:define_operators Adapting Existing Types to Proto]
@@ -732,105 +982,4 @@
 
 [endsect]
 
-[/======================================================]
-[section:subdomains EDSL Interoperatability: Sub-Domains]
-[/======================================================]
-
-The ability to /compose/ different EDSLs is one of their most exciting features. Consider how you build a parser using yacc. You write your grammar rules in yacc's domain-specific language. Then you embed semantic actions written in C within your grammar. Boost's Spirit parser generator gives you the same ability. You write grammar rules using Spirit and embed semantic actions using the Phoenix library. Phoenix and Spirit are both Proto-based domain-specific languages with their own distinct syntax and semantics. But you can freely embed Phoenix expressions within Spirit expressions. This section describes Proto's /sub-domain/ feature that lets you define famalies of interoperable domains.
-
-[/======================]
-[heading Dueling Domains]
-[/======================]
-
-Sub-domains solve a specific problem that only comes up when you try to create an expression from two sub-expressions in different domains: what is the domain of the resulting expression? Consider the following code:
-
- #include <boost/proto/proto.hpp>
- namespace proto = boost::proto;
-
- // Forward-declare two expression wrappers
- template<typename E> struct spirit_expr;
- template<typename E> struct phoenix_expr;
-
- // Define two domains
- struct spirit_domain : proto::domain<proto::generator<spirit_expr> > {};
- struct phoenix_domain : proto::domain<proto::generator<phoenix_expr> > {};
-
- // Implement the two expresison wrappers
- template<typename E>
- struct spirit_expr
- : proto::extends<E, spirit_expr<E>, spirit_domain>
- {
- spirit_expr(E const &e = E()) : spirit_expr::proto_extends(e) {}
- };
-
- template<typename E>
- struct phoenix_expr
- : proto::extends<E, phoenix_expr<E>, phoenix_domain>
- {
- phoenix_expr(E const &e = E()) : phoenix_expr::proto_extends(e) {}
- };
-
- int main()
- {
- proto::literal<int, spirit_domain> sp(0);
- proto::literal<int, phoenix_domain> phx(0);
-
- // Whoops! What does it mean to add two expression in different domains?
- sp + phx; // ERROR
- }
-
-Above, we define two domains called `spirit_domain` and `phoenix_domain` and declare two int literals in each. Then we try to compose them into a larger expression using Proto's binary plus operator, and it fails. Proto can't figure out whether the resulting expression should be in the Spirit domain or the Phoenix domain, and thus whether it should be an instance of `spirit_expr<>` or `pheonix_expr<>`. We have to tell Proto how to resolve the conflict. We can do that by declaring that Phoenix is a sub-domain of Spirit as in the following definition of `phoenix_domain`:
-
- // Declare that phoenix_domain is a sub-somain of spirit_domain
- struct phoenix_domain
- : proto::domain<proto::generator<phoenix_expr>, proto::_, spirit_domain>
- {};
-
-The third template parameter to _domain_ is the super-domain. By defining `phoenix_domain` as above, we are saying that Phoenix expressions can be combined with Spirit expressions, and that when that happens, the resulting expression should be a Spirit expression.
-
-[note If you are wondering what the purpose of `proto::_` is in the definition of `phoenix_domain` above, recall that the second template parameter to _domain_ is the domain's grammar. ["`proto::_`] is the default and signifies that the domain places no restrictions on the expressions that are valid within it.]
-
-[/------------------------]
-[heading Domain Resolution]
-[/------------------------]
-
-When there are multiple domains in play within a given expression, Proto uses some rules to figure out which domain "wins". The rules are loosly modeled on the rules for C++ inheritance. `Phoenix_domain` is a sub-domain of `spirit_domain`. You can liken that to a derived/base relationship that gives Phoenix expressions a kind of implicit conversion to Spirit expressions. And since Phoenix expressions can be "converted" to Spirit expressions, they can be freely combined with Spirit expressions and the result is a Spirit expression.
-
-[note Super- and sub-domains are not actually implemented using inheritance. This is only a helpful mental model.]
-
-The analogy with inheritance holds even in the case of three domains when two are sub-domains of the third. Imagine another domain called `foobar_domain` that was also a sub-domain of `spirit_domain`. Expressions in the `foobar_domain` could be combined with expressions in the `phoenix_domain` and the resulting expression would be in the `spirit_domain`. That's because expressions in the two sub-domains both have "conversions" to the super-domain, so the operation is allowed and the super-domain wins.
-
-[/-------------------------]
-[heading The Default Domain]
-[/-------------------------]
-
-When you don't assign a Proto expression to a particular domain, Proto considers it a member of the so-called default domain, `proto::default_domain`. Even non-Proto objects are treated as terminals in the default domain. Consider:
-
- int main()
- {
- proto::literal<int, spirit_domain> sp(0);
-
- // Add 1 to a spirit expression. Result is a spirit expression.
- sp + 1;
- }
-
-In light of the above discussion about sub-domains, you might consider `proto::default_domain` as a sub-domain of every other domain. Expressions in the default domain have a kind of implicit conversion to every other domain type. That's exactly how Proto sees it! What's more, you can define your domain to be a sub-domain of the default domain. In so doing, you give expression in your domain conversions to expressions in /every other domain/. This is like a "free love" domain, because it will freely mix with all other domains.
-
-Let's think again about the Phoenix EDSL. Since it provides generally useful lambda functionionality, it's reasonable to assume that lots of other EDSLs besides Spirit might want the ability to embed Phoenix expressions. In other words, `phoenix_domain` should be a sub-domain of `proto::default_domain`, not `spirit_domain`:
-
- // Declare that phoenix_domain is a sub-somain of proto::default_domain
- struct phoenix_domain
- : proto::domain<proto::generator<phoenix_expr>, proto::_, proto::default_domain>
- {};
-
-That's much better. Phoenix expressions can now be put anywhere.
-
-[/-------------------------]
-[heading Sub-Domain Summary]
-[/-------------------------]
-
-Use Proto sub-domains to make it possible to mix expressions from multiple domains. And when you want expressions in your domain to freely combine with /all/ expressions, make it a sub-domain of `proto::default_domain`.
-
-[endsect]
-
 [endsect]

Modified: trunk/libs/proto/doc/reference.xml
==============================================================================
--- trunk/libs/proto/doc/reference.xml (original)
+++ trunk/libs/proto/doc/reference.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1160,6 +1160,7 @@
   <xi:include href="reference/repeat.xml"/>
   <xi:include href="reference/tags.xml"/>
   <xi:include href="reference/traits.xml"/>
+ <xi:include href="reference/transform.xml"/>
   <xi:include href="reference/transform/arg.xml"/>
   <xi:include href="reference/transform/call.xml"/>
   <xi:include href="reference/transform/default.xml"/>
@@ -1171,6 +1172,7 @@
   <xi:include href="reference/transform/make.xml"/>
   <xi:include href="reference/transform/pass_through.xml"/>
   <xi:include href="reference/transform/when.xml"/>
+ <xi:include href="reference/context.xml"/>
   <xi:include href="reference/context/callable.xml"/>
   <xi:include href="reference/context/default.xml"/>
   <xi:include href="reference/context/null.xml"/>

Modified: trunk/libs/proto/doc/reference/args.xml
==============================================================================
--- trunk/libs/proto/doc/reference/args.xml (original)
+++ trunk/libs/proto/doc/reference/args.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/args.hpp">
   <para>
     Contains definitions of the <computeroutput>

Modified: trunk/libs/proto/doc/reference/concepts/CallableTransform.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/CallableTransform.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/CallableTransform.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="CallableTransform" category="utility">
- <!--
+<!--
   Copyright 2008 Eric Niebler
 
   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)
   -->
+<concept name="CallableTransform" category="utility">
   <param name="Fn" role="polymorphic-function-object-type" />
   <param name="Tn" role="transform-type" />
   <param name="Expr" role="expression-type" />

Modified: trunk/libs/proto/doc/reference/concepts/Domain.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/Domain.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/Domain.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="Domain" category="utility">
- <!--
+<!--
   Copyright 2010 Eric Niebler
 
   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)
   -->
+<concept name="Domain" category="utility">
   <param name="Domain" role="domain-type" />
   <param name="Expr" role="expression-type" />
   <param name="Object" role="object-type" />

Modified: trunk/libs/proto/doc/reference/concepts/Expr.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/Expr.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/Expr.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="Expr" category="utility">
- <!--
+<!--
   Copyright 2010 Eric Niebler
 
   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)
   -->
+<concept name="Expr" category="utility">
   <param name="Expr" role="expession-type"/>
   <param name="Tag" role="tag-type"/>
   <param name="Domain" role="domain-type"/>

Modified: trunk/libs/proto/doc/reference/concepts/ObjectTransform.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/ObjectTransform.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/ObjectTransform.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,5 +1,4 @@
 <?xml version="1.0" ?>
-<concept name="ObjectTransform" category="utility">
   <!--
   Copyright 2008 Eric Niebler
 
@@ -7,6 +6,7 @@
   Software License, Version 1.0. (See accompanying
   file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
   -->
+<concept name="ObjectTransform" category="utility">
   <param name="Obj" role="object-type" />
   <param name="Tn" role="transform-type" />
   <param name="Expr" role="expression-type" />

Modified: trunk/libs/proto/doc/reference/concepts/PolymorphicFunctionObject.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/PolymorphicFunctionObject.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/PolymorphicFunctionObject.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="PolymorphicFunctionObject" category="utility">
- <!--
+<!--
   Copyright 2008 Eric Niebler
 
   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)
   -->
+<concept name="PolymorphicFunctionObject" category="utility">
   <param name="Fn" role="polymorphic-function-object-type" />
 
   <models-sentence>

Modified: trunk/libs/proto/doc/reference/concepts/PrimitiveTransform.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/PrimitiveTransform.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/PrimitiveTransform.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="PrimitiveTransform" category="utility">
- <!--
+<!--
   Copyright 2008 Eric Niebler
 
   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)
   -->
+<concept name="PrimitiveTransform" category="utility">
   <param name="Fn" role="primitive-transform-type" />
   <param name="Expr" role="expression-type" />
   <param name="State" role="state-type" />

Modified: trunk/libs/proto/doc/reference/concepts/Transform.xml
==============================================================================
--- trunk/libs/proto/doc/reference/concepts/Transform.xml (original)
+++ trunk/libs/proto/doc/reference/concepts/Transform.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,12 +1,12 @@
 <?xml version="1.0" ?>
-<concept name="Transform" category="utility">
- <!--
+<!--
   Copyright 2008 Eric Niebler
 
   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)
   -->
+<concept name="Transform" category="utility">
   <param name="Tn" role="transform-type" />
   <param name="Expr" role="expression-type" />
   <param name="State" role="state-type" />

Added: trunk/libs/proto/doc/reference/context.xml
==============================================================================
--- (empty file)
+++ trunk/libs/proto/doc/reference/context.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
+<header name="boost/proto/context.hpp">
+ <para>Includes all the built-in evaluation contexts of Proto.</para>
+</header>

Modified: trunk/libs/proto/doc/reference/context/callable.xml
==============================================================================
--- trunk/libs/proto/doc/reference/context/callable.xml (original)
+++ trunk/libs/proto/doc/reference/context/callable.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/context/callable.hpp">
   <para>Definintion of <computeroutput><classname alt="boost::proto::context::callable_context">proto::context::callable_context&lt;&gt;</classname></computeroutput>,
     an evaluation context for <computeroutput><functionname alt="boost::proto::eval">proto::eval()</functionname></computeroutput>

Modified: trunk/libs/proto/doc/reference/context/default.xml
==============================================================================
--- trunk/libs/proto/doc/reference/context/default.xml (original)
+++ trunk/libs/proto/doc/reference/context/default.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/context/default.hpp">
   <namespace name="boost">
     <namespace name="proto">

Modified: trunk/libs/proto/doc/reference/context/null.xml
==============================================================================
--- trunk/libs/proto/doc/reference/context/null.xml (original)
+++ trunk/libs/proto/doc/reference/context/null.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/context/null.hpp">
   <para>
     Definintion of

Modified: trunk/libs/proto/doc/reference/core.xml
==============================================================================
--- trunk/libs/proto/doc/reference/core.xml (original)
+++ trunk/libs/proto/doc/reference/core.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/core.hpp">
   <para>Includes all of Proto, except the contexts, transforms, debug utilities and Boost.Typeof registrations.</para>
 </header>

Modified: trunk/libs/proto/doc/reference/debug.xml
==============================================================================
--- trunk/libs/proto/doc/reference/debug.xml (original)
+++ trunk/libs/proto/doc/reference/debug.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/debug.hpp">
   <para>Utilities for debugging Proto expression trees </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/deep_copy.xml
==============================================================================
--- trunk/libs/proto/doc/reference/deep_copy.xml (original)
+++ trunk/libs/proto/doc/reference/deep_copy.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/deep_copy.hpp">
   <para>Replace all nodes stored by reference by nodes stored by value.</para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/domain.xml
==============================================================================
--- trunk/libs/proto/doc/reference/domain.xml (original)
+++ trunk/libs/proto/doc/reference/domain.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/domain.hpp">
   <para>
     Contains definition of the <computeroutput><classname alt="boost::proto::domain">proto::domain&lt;&gt;</classname>

Modified: trunk/libs/proto/doc/reference/eval.xml
==============================================================================
--- trunk/libs/proto/doc/reference/eval.xml (original)
+++ trunk/libs/proto/doc/reference/eval.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/eval.hpp">
   <para>
     Contains the

Modified: trunk/libs/proto/doc/reference/expr.xml
==============================================================================
--- trunk/libs/proto/doc/reference/expr.xml (original)
+++ trunk/libs/proto/doc/reference/expr.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/expr.hpp">
   <namespace name="boost">
     <namespace name="proto">

Modified: trunk/libs/proto/doc/reference/extends.xml
==============================================================================
--- trunk/libs/proto/doc/reference/extends.xml (original)
+++ trunk/libs/proto/doc/reference/extends.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/extends.hpp">
   <para>Macros and a base class for defining end-user expression types </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/functional.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional.xml (original)
+++ trunk/libs/proto/doc/reference/functional.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional.hpp">
   <para>Includes all the functional extensions of Proto.</para>
 </header>

Modified: trunk/libs/proto/doc/reference/functional/fusion.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion.hpp">
   <para>Includes all the functional extensions to Proto for the Boost.Fusion library.</para>
 </header>

Modified: trunk/libs/proto/doc/reference/functional/fusion/at.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/at.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/at.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/at.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::at</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/fusion/pop_back.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/pop_back.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/pop_back.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/pop_back.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::pop_back</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/fusion/pop_front.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/pop_front.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/pop_front.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/pop_front.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::pop_front</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/fusion/push_back.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/push_back.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/push_back.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/push_back.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::push_back</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/fusion/push_front.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/push_front.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/push_front.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/push_front.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::push_front</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/fusion/reverse.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/fusion/reverse.xml (original)
+++ trunk/libs/proto/doc/reference/functional/fusion/reverse.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/fusion/reverse.hpp">
   <para>Includes Proto callable <computeroutput><classname>boost::proto::functional::reverse</classname></computeroutput>.</para>
 

Modified: trunk/libs/proto/doc/reference/functional/std.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/std.xml (original)
+++ trunk/libs/proto/doc/reference/functional/std.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/std.hpp">
   <para>Includes all the functional extensions to Proto for the standard library.</para>
 </header>

Modified: trunk/libs/proto/doc/reference/functional/std/utility.xml
==============================================================================
--- trunk/libs/proto/doc/reference/functional/std/utility.xml (original)
+++ trunk/libs/proto/doc/reference/functional/std/utility.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/functional/std/utility.hpp">
   <para>Defines Proto callables <computeroutput><classname>boost::proto::functional::make_pair</classname></computeroutput>,
   <computeroutput><classname>boost::proto::functional::first</classname></computeroutput> and

Modified: trunk/libs/proto/doc/reference/fusion.xml
==============================================================================
--- trunk/libs/proto/doc/reference/fusion.xml (original)
+++ trunk/libs/proto/doc/reference/fusion.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/fusion.hpp">
   <para>Make any Proto expression a valid Fusion sequence </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/generate.xml
==============================================================================
--- trunk/libs/proto/doc/reference/generate.xml (original)
+++ trunk/libs/proto/doc/reference/generate.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/generate.hpp">
   <para>Contains definition of
     <computeroutput><classname alt="boost::proto::default_generator">proto::default_generator</classname></computeroutput>,

Modified: trunk/libs/proto/doc/reference/literal.xml
==============================================================================
--- trunk/libs/proto/doc/reference/literal.xml (original)
+++ trunk/libs/proto/doc/reference/literal.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/literal.hpp">
   <para>
     The

Modified: trunk/libs/proto/doc/reference/make_expr.xml
==============================================================================
--- trunk/libs/proto/doc/reference/make_expr.xml (original)
+++ trunk/libs/proto/doc/reference/make_expr.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/make_expr.hpp">
   <para>
     Definition of the <computeroutput><functionname alt="boost::proto::make_expr">proto::make_expr()</functionname>

Modified: trunk/libs/proto/doc/reference/matches.xml
==============================================================================
--- trunk/libs/proto/doc/reference/matches.xml (original)
+++ trunk/libs/proto/doc/reference/matches.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/matches.hpp">
   <para>
     Contains definition of the
@@ -441,7 +448,7 @@
           An expression type <computeroutput>E</computeroutput> matches
             <computeroutput>proto::switch_&lt;C,T&gt;</computeroutput> if
           <computeroutput>E</computeroutput> matches
- <computeroutput>C::case_&lt;boost::result_of&lt;T(E)&gt;::type&gt;</computeroutput>.
+ <computeroutput>C::case_&lt;boost::result_of&lt;<classname>proto::when</classname>&lt;<classname>proto::_</classname>,T&gt;(E)&gt;::type&gt;</computeroutput>.
           </para>
         <para>
           When applying <computeroutput>proto::switch_&lt;C,T&gt;</computeroutput> as a
@@ -449,7 +456,7 @@
             <computeroutput>E</computeroutput>, state <computeroutput>s</computeroutput> of
             type <computeroutput>S</computeroutput> and data <computeroutput>d</computeroutput>
             of type <computeroutput>D</computeroutput>, it is equivalent to
- <computeroutput>C::case_&lt;boost::result_of&lt;T(E,S,D)&gt;::type&gt;()(e, s, d)</computeroutput>.
+ <computeroutput>C::case_&lt;boost::result_of&lt;<classname>proto::when</classname>&lt;<classname>proto::_</classname>,T&gt;(E,S,D)&gt;::type&gt;()(e, s, d)</computeroutput>.
           </para>
         </description>
         <struct name="impl">
@@ -699,14 +706,15 @@
                   <computeroutput>
                     <classname>proto::switch_</classname>&lt;C, T&gt;
                   </computeroutput> if
- <computeroutput>E</computeroutput> matches <computeroutput>C::case_&lt;boost::result_of&lt;T(E)&gt;::type&gt;</computeroutput>.
+ <computeroutput>E</computeroutput> matches <computeroutput>C::case_&lt;boost::result_of&lt;<classname>proto::when</classname>&lt;<classname>proto::_</classname>,T&gt;(E)&gt;::type&gt;</computeroutput>.
                   Note: <computeroutput>T</computeroutput> defaults to <computeroutput><classname>proto::tag_of</classname>&lt;<classname>proto::_</classname>&gt;()</computeroutput>
                 </para>
               </listitem>
             </itemizedlist>
           </para>
           <para>
- A terminal expression
+ A terminal expression can trivially match the grammar <classname>proto::_</classname>. In addition,
+ a terminal expression
             <computeroutput>
               <classname>proto::basic_expr</classname>&lt;AT,
               <classname>proto::term</classname>&lt;A&gt; &gt;

Modified: trunk/libs/proto/doc/reference/operators.xml
==============================================================================
--- trunk/libs/proto/doc/reference/operators.xml (original)
+++ trunk/libs/proto/doc/reference/operators.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/operators.hpp">
   <para>Contains all the overloaded operators that make it possible to build Proto expression trees. </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/proto.xml
==============================================================================
--- trunk/libs/proto/doc/reference/proto.xml (original)
+++ trunk/libs/proto/doc/reference/proto.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/proto.hpp">
   <para>Includes all of Proto, except the Boost.Typeof registrations.</para>
 </header>

Modified: trunk/libs/proto/doc/reference/proto_fwd.xml
==============================================================================
--- trunk/libs/proto/doc/reference/proto_fwd.xml (original)
+++ trunk/libs/proto/doc/reference/proto_fwd.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/proto_fwd.hpp">
   <para>Forward declarations of all of proto's public types and functions. </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/proto_typeof.xml
==============================================================================
--- trunk/libs/proto/doc/reference/proto_typeof.xml (original)
+++ trunk/libs/proto/doc/reference/proto_typeof.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/proto_typeof.hpp">
   <para>Boost.Typeof registrations for Proto's types, and definition of the
     <computeroutput><macroname>BOOST_PROTO_AUTO</macroname>()</computeroutput> macro.</para>

Modified: trunk/libs/proto/doc/reference/repeat.xml
==============================================================================
--- trunk/libs/proto/doc/reference/repeat.xml (original)
+++ trunk/libs/proto/doc/reference/repeat.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/repeat.hpp">
   <para>
     Contains macros to ease the generation of repetitious code constructs.

Modified: trunk/libs/proto/doc/reference/tags.xml
==============================================================================
--- trunk/libs/proto/doc/reference/tags.xml (original)
+++ trunk/libs/proto/doc/reference/tags.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/tags.hpp">
   <para>Contains the tags for all the overloadable operators in C++ </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/traits.xml
==============================================================================
--- trunk/libs/proto/doc/reference/traits.xml (original)
+++ trunk/libs/proto/doc/reference/traits.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 ï»¿<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/traits.hpp">
   <para>
     Contains definitions for various expression traits and utilities like

Added: trunk/libs/proto/doc/reference/transform.xml
==============================================================================
--- (empty file)
+++ trunk/libs/proto/doc/reference/transform.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
+<header name="boost/proto/transform.hpp">
+ <para>Includes all the built-in transforms of Proto.</para>
+</header>

Modified: trunk/libs/proto/doc/reference/transform/arg.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/arg.xml (original)
+++ trunk/libs/proto/doc/reference/transform/arg.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/arg.hpp">
   <para>Contains definition of the childN transforms and friends.</para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/transform/call.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/call.xml (original)
+++ trunk/libs/proto/doc/reference/transform/call.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/call.hpp">
   <para>Contains definition of the call&lt;&gt; transform. </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/transform/default.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/default.xml (original)
+++ trunk/libs/proto/doc/reference/transform/default.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/default.hpp">
   <namespace name="boost">
     <namespace name="proto">

Modified: trunk/libs/proto/doc/reference/transform/fold.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/fold.xml (original)
+++ trunk/libs/proto/doc/reference/transform/fold.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/fold.hpp">
   <para>Contains definition of the
     <computeroutput>

Modified: trunk/libs/proto/doc/reference/transform/fold_tree.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/fold_tree.xml (original)
+++ trunk/libs/proto/doc/reference/transform/fold_tree.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/fold_tree.hpp">
   <para>
     Contains definition of the

Modified: trunk/libs/proto/doc/reference/transform/impl.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/impl.xml (original)
+++ trunk/libs/proto/doc/reference/transform/impl.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/impl.hpp">
   <para>Contains definition of transform&lt;&gt; and transform_impl&lt;&gt; helpers. </para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/transform/integral_c.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/integral_c.xml (original)
+++ trunk/libs/proto/doc/reference/transform/integral_c.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/integral_c.hpp">
   <para>Contains definition of the integral_c transform and friends.</para>
   <namespace name="boost">

Modified: trunk/libs/proto/doc/reference/transform/lazy.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/lazy.xml (original)
+++ trunk/libs/proto/doc/reference/transform/lazy.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/lazy.hpp">
   <para>
     Contains definition of the

Modified: trunk/libs/proto/doc/reference/transform/make.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/make.xml (original)
+++ trunk/libs/proto/doc/reference/transform/make.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/make.hpp">
   <para>
     Contains definition of the

Modified: trunk/libs/proto/doc/reference/transform/pass_through.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/pass_through.xml (original)
+++ trunk/libs/proto/doc/reference/transform/pass_through.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/pass_through.hpp">
   <para>Definition of the
     <computeroutput><classname alt="boost::proto::pass_through">proto::pass_through&lt;&gt;</classname></computeroutput>

Modified: trunk/libs/proto/doc/reference/transform/when.xml
==============================================================================
--- trunk/libs/proto/doc/reference/transform/when.xml (original)
+++ trunk/libs/proto/doc/reference/transform/when.xml 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -1,4 +1,11 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright 2012 Eric Niebler
+
+ 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)
+ -->
 <header name="boost/proto/transform/when.hpp">
   <para>
     Definition of the

Modified: trunk/libs/proto/example/lambda.hpp
==============================================================================
--- trunk/libs/proto/example/lambda.hpp (original)
+++ trunk/libs/proto/example/lambda.hpp 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -477,7 +477,7 @@
           : proto::pod_generator<llexpr>
         {};
 
- // The domain for the lambda library. It
+ // The domain for the lambda library.
         struct lldomain
           : proto::domain<Generator, Grammar, proto::default_domain>
         {

Modified: trunk/libs/proto/example/mini_lambda.cpp
==============================================================================
--- trunk/libs/proto/example/mini_lambda.cpp (original)
+++ trunk/libs/proto/example/mini_lambda.cpp 2012-01-02 19:38:37 EST (Mon, 02 Jan 2012)
@@ -183,7 +183,7 @@
     { return T(); }
 
     // Generate BOOST_PROTO_MAX_ARITY overloads of the
- // followig function call operator.
+ // following function call operator.
 #define BOOST_PROTO_LOCAL_MACRO(N, typename_A, A_const_ref, A_const_ref_a, a)\
     template<typename_A(N)> \
     T operator()(A_const_ref_a(N)) const \


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