Update of /cvsroot/boost/boost/libs/xpressive/proto/doc
In directory 
sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv19904/libs/xpressive/proto/doc

Modified Files:
        grammars.qbk quick_start.qbk transforms.qbk 
Log Message:
rename left_shift to shift_left, non-terminals do not get non-const overloads 
for op=, op[] and op() for better compile times

Index: grammars.qbk
===================================================================
RCS file: /cvsroot/boost/boost/libs/xpressive/proto/doc/grammars.qbk,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- grammars.qbk        5 May 2007 06:27:40 -0000       1.9
+++ grammars.qbk        21 May 2007 03:21:34 -0000      1.10
@@ -31,16 +31,16 @@
 expressions of the form `cin_ >> i` and `cout_ << 1` we do this:
 
     struct Input
-      : right_shift< terminal< std::istream & >, _ >
+      : shift_right< terminal< std::istream & >, _ >
     {};
 
     struct Output
-      : left_shift< terminal< std::ostream & >, _ >
+      : shift_left< terminal< std::ostream & >, _ >
     {};
 
 We've seen the template `terminal<>` before, but here we're using it
 without accessing the nested `::type`. When used like this, it is a very simple
-pattern, as are `right_shift<>` and `left_shift<>`. The newcomer
+pattern, as are `shift_right<>` and `shift_left<>`. The newcomer
 here is `_` in the `proto` namespace. It is a wildcard that matches anything.
 The `Input` struct is a pattern that matches any right-shift expression that
 has a `std::istream` terminal as its left operand.
@@ -115,15 +115,15 @@
 
     struct Input
       : or_<
-            right_shift< terminal< std::istream & >, _ >
-          , right_shift< Input, _ >
+            shift_right< terminal< std::istream & >, _ >
+          , shift_right< Input, _ >
         >
     {};
 
     struct Output
       : or_<
-            left_shift< terminal< std::ostream & >, _ >
-          , left_shift< Output, _ >
+            shift_left< terminal< std::ostream & >, _ >
+          , shift_left< Output, _ >
         >
     {};
 
@@ -137,9 +137,9 @@
 When the `Output` pattern is evaluated against an expression like
 `cout_ << 1 << 2`, the first alternate of the _or_ is tried first. It will
 fail, because the expression `cout_ << 1 << 2` does not match the pattern
-`left_shift< terminal< std::ostream & >, _ >`. Then the second
+`shift_left< terminal< std::ostream & >, _ >`. Then the second
 alternate is tried. We match the expression against
-`left_shift< Output, _ >`. The expression is a left-shift, so we try
+`shift_left< Output, _ >`. The expression is a left-shift, so we try
 the operands. The right operand `2` matches `_` trivially. To see if
 the left operand `cout_ << 1` matches `Output`, we must recursively evaluate
 the `Output` pattern. This time we succeed, because `cout_ << 1` will match
@@ -245,7 +245,7 @@
 [h3 Other Valid Patterns]
 
 We've already seen how to use expression generators like `terminal<>` and
-`right_shift<>` as patterns. We've also seen _or_, which we can use to
+`shift_right<>` as patterns. We've also seen _or_, which we can use to
 express a set of alternate patterns. There are a few others of interest; in
 particular, _if_ and _and_.
 

Index: quick_start.qbk
===================================================================
RCS file: /cvsroot/boost/boost/libs/xpressive/proto/doc/quick_start.qbk,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- quick_start.qbk     5 May 2007 06:27:40 -0000       1.10
+++ quick_start.qbk     21 May 2007 03:21:34 -0000      1.11
@@ -114,7 +114,7 @@
                                     the argument is stored by reference.]]
     [[_terminal_, _unary_expr_,
         _binary_expr_, /etc./]  [Expression type generators. For example,
-                                    `right_shift<A, B>::type` is the type
+                                    `shift_right<A, B>::type` is the type
                                     of a right-shift expression with `A` and
                                     `B` as children. These are also used for
                                     specifying productions in meta-grammars.]]

Index: transforms.qbk
===================================================================
RCS file: /cvsroot/boost/boost/libs/xpressive/proto/doc/transforms.qbk,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- transforms.qbk      29 Apr 2007 03:38:49 -0000      1.4
+++ transforms.qbk      21 May 2007 03:21:34 -0000      1.5
@@ -36,7 +36,7 @@
 object called `expr` that matches the meta-grammar, and `state` and `visitor`
 objects of your choosing. What happens when you call
 `Grammar::call(expr, state, visitor)`? Well, if `Grammar` were defined as
-`right_shift< Rule1, Rule2 >`, for instance, it might transform the left
+`shift_right< Rule1, Rule2 >`, for instance, it might transform the left
 child of `expr` according to `Rule1`'s transform, do the same thing to the
 right child using `Rule2`, and combine the results somehow. Of course, `Rule1`
 and `Rule2` might be defined in terms of other rules with other transforms, so
@@ -172,7 +172,7 @@
 \n
 All the tools Proto provides for defining grammar rules have default transforms
 associated with them. Just as `unary_expr<>` has a pass-through transform,
-so too does `binary_expr<>`, `right_shift<>`, and all the others.
+so too does `binary_expr<>`, `shift_right<>`, and all the others.
 `proto::or_<>` has a default transform which evaluates the transform of the
 branch that matched. Even `proto::expr<>` and `proto::_` have no-op default
 transforms that simply return unmodified the expressions passed to them.


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs

Reply via email to