Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r71897 - in sandbox/local: boost/local boost/local/aux_/function_macros/code_ boost/local/aux_/preprocessor/sign boost/local/aux_/preprocessor/sign/parse_params_ boost/local/aux_/preprocessor/sign/parsed_params_ boost/local/aux_/preprocessor/sign/parsed_params_/validate_ boost/local/function libs/local/doc libs/local/doc/html libs/local/doc/html/boost_local libs/local/doc/qbk libs/local/example
From: lorcaminiti_at_[hidden]
Date: 2011-05-12 11:57:47


Author: lcaminiti
Date: 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
New Revision: 71897
URL: http://svn.boost.org/trac/boost/changeset/71897

Log:
Added overloading and typed bind to docs.
Added:
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind_this_type.hpp
      - copied, changed from r71847, /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind_this_type.hpp
      - copied, changed from r71847, /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp
Removed:
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp
Text files modified:
   sandbox/local/boost/local/aux_/function_macros/code_/binding.hpp | 122 ++++++++-
   sandbox/local/boost/local/aux_/function_macros/code_/functor.hpp | 12
   sandbox/local/boost/local/aux_/preprocessor/sign/params_any_bind.hpp | 14
   sandbox/local/boost/local/aux_/preprocessor/sign/params_bind.hpp | 27 +
   sandbox/local/boost/local/aux_/preprocessor/sign/params_const_bind.hpp | 27 +
   sandbox/local/boost/local/aux_/preprocessor/sign/parse_params_/seq_valid.hpp | 32 +
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind.hpp | 17
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind_this_type.hpp | 21
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind.hpp | 17
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind_this_type.hpp | 21
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind.hpp | 8
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind_default.hpp | 8
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/index.hpp | 18 -
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/nil.hpp | 11
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/set_error.hpp | 8
   sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/validate_/this_count.hpp | 13
   sandbox/local/boost/local/config.hpp | 8
   sandbox/local/boost/local/function.hpp | 2
   sandbox/local/boost/local/function/overload.hpp | 78 +++++
   sandbox/local/libs/local/doc/Jamfile.jam | 3
   sandbox/local/libs/local/doc/html/BOOST_IDENTITY_TYPE.html | 2
   sandbox/local/libs/local/doc/html/BOOST_IDENTITY_VALUE.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_END.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_TPL.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_COMPLIANT.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html | 10
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html | 10
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_END.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_TPL.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_NAME.html | 8
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS_TPL.html | 2
   sandbox/local/libs/local/doc/html/BOOST_LOCAL_TYPEOF.html | 8
   sandbox/local/libs/local/doc/html/boost_local/Advanced_Topics.html | 500 ++++++++++++++++++++++++++++++++++-----
   sandbox/local/libs/local/doc/html/boost_local/Getting_Started.html | 4
   sandbox/local/libs/local/doc/html/boost_local/Release_Notes.html | 18
   sandbox/local/libs/local/doc/html/boost_local/Tutorial.html | 75 +++--
   sandbox/local/libs/local/doc/html/index.html | 8
   sandbox/local/libs/local/doc/html/reference.html | 13 +
   sandbox/local/libs/local/doc/html/standalone_HTML.manifest | 2
   sandbox/local/libs/local/doc/qbk/advanced_topics.qbk | 121 +++++++--
   sandbox/local/libs/local/doc/qbk/local.qbk | 8
   sandbox/local/libs/local/doc/qbk/release_notes.qbk | 6
   sandbox/local/libs/local/doc/qbk/tutorial.qbk | 8
   sandbox/local/libs/local/example/Jamfile.jam | 9
   sandbox/local/libs/local/example/add_this.cpp | 2
   sandbox/local/libs/local/example/add_this_va.cpp | 2
   sandbox/local/libs/local/example/overload.cpp | 10
   sandbox/local/libs/local/example/overload_va.cpp | 10
   51 files changed, 997 insertions(+), 324 deletions(-)

Modified: sandbox/local/boost/local/aux_/function_macros/code_/binding.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/function_macros/code_/binding.hpp (original)
+++ sandbox/local/boost/local/aux_/function_macros/code_/binding.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -11,6 +11,8 @@
 #include "../../symbol.hpp"
 #include "../../scope_exit/scope_exit.hpp" // Use this lib's ScopeExit impl.
 #include "../../preprocessor/sign/params_any_bind.hpp"
+#include "../../preprocessor/sign/param_any_bind.hpp"
+#include <boost/type_traits.hpp>
 #include <boost/preprocessor/control/iif.hpp>
 #include <boost/preprocessor/control/expr_iif.hpp>
 #include <boost/preprocessor/list/adt.hpp> // For `IS_CONS`.
@@ -19,39 +21,125 @@
 
 // PRIVATE //
 
-// Adapted from `BOOST_SCOPE_EXIT_AUX_TAG_DECL()`.
-#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_TAG_DECL_(r, id, i, var) \
- typedef void (*BOOST_SCOPE_EXIT_AUX_TAG(id,i))(int \
- BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_RENAME(var));
+// Adapted from `BOOST_SCOPE_EXIT_AUX_TAG_DECL()` (not for `this`).
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_TAG_DECL_TYPED_( \
+ r, id, i, typed_var) \
+ typedef void (*BOOST_SCOPE_EXIT_AUX_TAG(id, i))(typed_var);
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_TAG_DECL_(r, id, i, bind) \
+ BOOST_SCOPE_EXIT_AUX_TAG_DECL(r, id, i, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE(bind))
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_CAPTURE_DECL()` (not for `this`).
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_CAPTURE_DECL_TYPED_( \
+ r, id_typename, i, bind) \
+ typedef \
+ /* remove ref because typed var can have & prefix */ \
+ BOOST_PP_TUPLE_ELEM(2, 1, id_typename) /* eventual typename */ \
+ ::boost::remove_reference< \
+ BOOST_PP_TUPLE_ELEM(2, 1, id_typename) /* eventual typename */ \
+ ::boost::function_traits< \
+ /* instead of using Boost.Typeof, get bind type from func */ \
+ /* type `void (bind_type [&] bind_name)` */ \
+ void (BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITH_TYPE(bind)) \
+ >::arg1_type \
+ >::type \
+ BOOST_SCOPE_EXIT_AUX_CAPTURE_T(BOOST_PP_TUPLE_ELEM(2, 0, id_typename), \
+ i, BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE(bind)) \
+ ; /* end typedef */
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_CAPTURE_DECL_( \
+ r, id_typename, i, bind) \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_HAS_TYPE(bind), \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_CAPTURE_DECL_TYPED_ \
+ , \
+ BOOST_SCOPE_EXIT_AUX_CAPTURE_DECL \
+ )(r, id_typename, i, \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_HAS_TYPE(bind), \
+ bind BOOST_PP_TUPLE_EAT(1) \
+ , \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE \
+ )(bind) \
+ )
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_PARAM_DECL_( \
+ r, id_typename, i, bind) \
+ BOOST_SCOPE_EXIT_AUX_PARAM_DECL(r, id_typename, i, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE(bind))
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_MEMBER_(r, id, i, bind) \
+ BOOST_SCOPE_EXIT_AUX_MEMBER(r, id, i, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE(bind))
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_PARAM_INIT_(r, id, i, bind) \
+ BOOST_SCOPE_EXIT_AUX_PARAM_INIT(r, id, i, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE(bind))
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_WITH_( \
+ id, all_bind_this_types) \
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_WITHOUT_( \
+ id, all_bind_this_types) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id);
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPEDEF_WITH_( \
+ all_bind_this_types) \
+ typedef BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_THIS_TYPE( \
+ BOOST_PP_LIST_FIRST(all_bind_this_types))
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPEDEF_WITHOUT_( \
+ all_bind_this_types) \
+ BOOST_SCOPE_EXIT_TYPEDEF_TYPEOF_THIS()
+
+// Precondition: all_bind_this_type is list with 1 elem (possibly PP_EMPTY).
+// Otherwise got a parsing error before getting here.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPE_( \
+ id, all_bind_this_types) \
+ /* typedef ... */ \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_THIS_HAS_TYPE( \
+ BOOST_PP_LIST_FIRST(all_bind_this_types)), \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPEDEF_WITH_ \
+ , \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPEDEF_WITHOUT_ \
+ )(all_bind_this_types) \
+ /* ... this_type ## id */ \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id) \
+ ; /* end typedef */
 
 // Adapted from `BOOST_SCOPE_EXIT_AUX_IMPL()`.
 #define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_WITH_TAGS_SEQ_( \
- all_binds, has_any_bind_this, id, typename_keyword) \
+ all_binds, all_bind_this_types, id, typename_keyword) \
     /* binding tags */ \
- BOOST_PP_EXPR_IIF(has_any_bind_this, \
- BOOST_SCOPE_EXIT_TYPEDEF_TYPEOF_THIS() \
- BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id); \
- ) \
+ BOOST_PP_IIF(BOOST_PP_LIST_IS_CONS(all_bind_this_types), \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_THIS_TYPE_ \
+ , \
+ BOOST_PP_TUPLE_EAT(2) \
+ )(id, all_bind_this_types) \
     BOOST_PP_LIST_FOR_EACH_I(BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_TAG_DECL_, \
             id, all_binds) \
- BOOST_PP_LIST_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_CAPTURE_DECL, \
+ BOOST_PP_LIST_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_CAPTURE_DECL_, \
             (id, typename_keyword), all_binds) \
     /* binding class */ \
     struct BOOST_SCOPE_EXIT_AUX_PARAMS_T(id) { \
- BOOST_PP_EXPR_IIF(has_any_bind_this, \
+ BOOST_PP_EXPR_IIF(BOOST_PP_LIST_IS_CONS(all_bind_this_types), \
             BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id) \
             BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_NAME; \
         ) \
- BOOST_PP_LIST_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_PARAM_DECL, \
+ BOOST_PP_LIST_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_PARAM_DECL_, \
                 (id, typename_keyword), all_binds) \
- BOOST_PP_LIST_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_MEMBER, \
+ BOOST_PP_LIST_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_MEMBER_, \
                 id, all_binds) \
     } BOOST_LOCAL_AUX_SYMBOL_PARAMS_LOCAL_VARIABLE_NAME(id) = { \
         /* initialize the struct with param values to bind */ \
- BOOST_PP_EXPR_IIF(has_any_bind_this, this) \
- BOOST_PP_COMMA_IF(BOOST_PP_BITAND(has_any_bind_this, \
+ BOOST_PP_EXPR_IIF(BOOST_PP_LIST_IS_CONS(all_bind_this_types), this) \
+ BOOST_PP_COMMA_IF(BOOST_PP_BITAND( \
+ BOOST_PP_LIST_IS_CONS(all_bind_this_types), \
                 BOOST_PP_LIST_IS_CONS(all_binds))) \
- BOOST_PP_LIST_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_PARAM_INIT, \
+ BOOST_PP_LIST_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_PARAM_INIT_, \
                 id, all_binds) \
     };
 
@@ -61,7 +149,7 @@
     /* has some bind param then all bind names is never empty nil-seq */ \
     BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_WITH_TAGS_SEQ_( \
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND_WITHOUT_THIS(sign_params), \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_ANY_BIND_THIS(sign_params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND_THIS_TYPE(sign_params), \
             id, typename_keyword)
 
 // PUBLIC //

Modified: sandbox/local/boost/local/aux_/function_macros/code_/functor.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/function_macros/code_/functor.hpp (original)
+++ sandbox/local/boost/local/aux_/function_macros/code_/functor.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -569,11 +569,14 @@
                 BOOST_PP_EXPR_IIF(has_const_bind_this, \
                     typename_keyword ::boost::local::aux::add_pointed_const< \
                         BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id) \
- >::type BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
+ >::type \
+ /* const pointer to const object */ \
+ const BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
                 ) \
                 BOOST_PP_EXPR_IIF(has_bind_this, \
                     BOOST_LOCAL_AUX_FUNCTION_CODE_BIND_THIS_TYPE(id) \
- BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
+ /* const pointer to non-const object */ \
+ const BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
                 ) \
                 /* unbind params (last because they can have defaults) */ \
                 BOOST_PP_COMMA_IF( \
@@ -608,11 +611,12 @@
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(sign_params), \
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_COUNT_DEFAULTS(sign_params), \
             /* const bind vars (without `this`) */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(sign_params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_WITHOUT_TYPE( \
+ sign_params), \
             /* eventual const bind `this` */ \
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_CONST_BIND_THIS(sign_params), \
             /* bind (not const) vars (without `this`) */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(sign_params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_WITHOUT_TYPE(sign_params), \
             /* eventual bind (not const) `this` */ \
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_BIND_THIS(sign_params), \
             /* etc */ \

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/params_any_bind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/params_any_bind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/params_any_bind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -41,14 +41,13 @@
         0 \
     ))))
 
-// Expand to nil-seq `(NIL) ([&]var) ...` with all binds (const or not) but
-// excluding `this`.
+// Expand to list with all binds (const or not) but excluding `this`.
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND_WITHOUT_THIS(params) \
     BOOST_PP_LIST_APPEND(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params), \
             BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params))
 
-// Expand to nil-seq `(NIL) ([&]var) ...` with all binds (const or not) and
-// including `this` if bound (const or not).
+// Expand to list with all binds (const or not) and including `this` if bound
+// (const or not).
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND(params) \
     BOOST_PP_LIST_APPEND(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND(params), \
         BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_ANY_BIND_THIS( \
@@ -59,5 +58,12 @@
         ) \
     )
 
+// Expand to list of all `this` types (const or not). There is at most 1 bind
+// `this` type if no parsing error.
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ALL_BIND_THIS_TYPE(params) \
+ BOOST_PP_LIST_APPEND( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params))
+
 #endif // #include guard
 

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/params_bind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/params_bind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/params_bind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,9 +7,18 @@
 #ifndef BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_HPP_
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_HPP_
 
+#include "param_any_bind.hpp"
 #include "parsed_params_/index.hpp"
 #include <boost/preprocessor/tuple/elem.hpp>
 #include <boost/preprocessor/list/adt.hpp> // For `IS_CONS`.
+#include <boost/preprocessor/list/transform.hpp>
+
+// PRIVATE //
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_TYPED_(d, macro, elem) \
+ macro(elem)
+
+// PUBLIC //
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
     BOOST_PP_TUPLE_ELEM(BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_MAX, \
@@ -19,14 +28,24 @@
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_BIND(params) \
     BOOST_PP_LIST_IS_CONS(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params))
 
-#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_WITHOUT_TYPE(params) \
+ BOOST_PP_LIST_TRANSFORM(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_TYPED_, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params))
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_WITH_TYPE(params) \
+ BOOST_PP_LIST_TRANSFORM(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_TYPED_, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITH_TYPE, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params))
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     BOOST_PP_TUPLE_ELEM(BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_MAX, \
- BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_BIND_THIS_COUNT, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_BIND_THIS_TYPE, \
             params)
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_BIND_THIS(params) \
- BOOST_PP_GREATER(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT( \
- params), 0)
+ BOOST_PP_LIST_IS_CONS(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE( \
+ params))
 
 #endif // #include guard
 

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/params_const_bind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/params_const_bind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/params_const_bind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,9 +7,18 @@
 #ifndef BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_HPP_
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_HPP_
 
+#include "param_any_bind.hpp"
 #include "parsed_params_/index.hpp"
 #include <boost/preprocessor/tuple/elem.hpp>
 #include <boost/preprocessor/list/adt.hpp> // For `IS_CONS`.
+#include <boost/preprocessor/list/transform.hpp>
+
+// PRIVATE //
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_TYPED_(d, macro, elem) \
+ macro(elem)
+
+// PUBLIC //
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
     BOOST_PP_TUPLE_ELEM(BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_MAX, \
@@ -19,14 +28,24 @@
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_CONST_BIND(params) \
     BOOST_PP_LIST_IS_CONS(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params))
 
-#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_WITHOUT_TYPE(params) \
+ BOOST_PP_LIST_TRANSFORM(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_TYPED_, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITHOUT_TYPE, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params))
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_WITH_TYPE(params) \
+ BOOST_PP_LIST_TRANSFORM(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_TYPED_, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAM_ANY_BIND_WITH_TYPE, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params))
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     BOOST_PP_TUPLE_ELEM(BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_MAX, \
- BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_CONST_BIND_THIS_COUNT, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_CONST_BIND_THIS_TYPE, \
             params)
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_CONST_BIND_THIS(params) \
- BOOST_PP_GREATER(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT( \
- params), 0)
+ BOOST_PP_LIST_IS_CONS(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(\
+ params))
 
 #endif // #include guard
 

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parse_params_/seq_valid.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parse_params_/seq_valid.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parse_params_/seq_valid.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,13 +7,14 @@
 #ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_HPP_
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_HPP_
 
+#include "any_bind_type.hpp"
 #include "../parsed_params_/nil.hpp"
 #include "../parsed_params_/append_unbind.hpp"
 #include "../parsed_params_/append_unbind_default.hpp"
 #include "../parsed_params_/append_const_bind.hpp"
-#include "../parsed_params_/inc_const_bind_this_count.hpp"
+#include "../parsed_params_/append_const_bind_this_type.hpp"
 #include "../parsed_params_/append_bind.hpp"
-#include "../parsed_params_/inc_bind_this_count.hpp"
+#include "../parsed_params_/append_bind_this_type.hpp"
 #include "../../keyword/const_bind.hpp"
 #include "../../keyword/bind.hpp"
 #include <boost/detail/preprocessor/keyword/default.hpp>
@@ -38,37 +39,44 @@
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_CONST_BIND_THIS_( \
         params, elem) \
- BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT(params)
+ BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND_THIS_TYPE(params, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_THIS_TYPE(elem))
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_CONST_BIND_VAR_( \
         params, elem) \
     BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND(params, \
- BOOST_LOCAL_AUX_PP_KEYWORD_CONST_BIND_REMOVE_FRONT(elem))
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITHOUT_TYPE(elem), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITH_TYPE(elem))
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_CONST_BIND_( \
         params, elem) \
     /* check from back because non `this` bounds might have `&` in front */ \
     BOOST_PP_IIF(BOOST_DETAIL_PP_KEYWORD_IS_THIS_BACK( \
- BOOST_LOCAL_AUX_PP_KEYWORD_CONST_BIND_REMOVE_FRONT(elem)), \
+ /* remove all leading symbols `[const] bind [(type)] ...` */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITHOUT_TYPE(elem)), \
         BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_CONST_BIND_THIS_ \
     , \
         BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_CONST_BIND_VAR_ \
     )(params, elem)
 
 // Parse binds.
-
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_VAR_(params, elem) \
- BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND(params, \
- BOOST_LOCAL_AUX_PP_KEYWORD_BIND_REMOVE_FRONT(elem))
-
+
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_THIS_( \
         params, elem) \
- BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT(params)
+ BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND_THIS_TYPE(params, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_THIS_TYPE(elem))
+
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_VAR_( \
+ params, elem) \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND(params, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITHOUT_TYPE(elem), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITH_TYPE(elem))
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_(params, elem) \
     /* check from back because non `this` bounds might have `&` in front */ \
     BOOST_PP_IIF(BOOST_DETAIL_PP_KEYWORD_IS_THIS_BACK( \
- BOOST_LOCAL_AUX_PP_KEYWORD_BIND_REMOVE_FRONT(elem)), \
+ /* remove all leading symbols `[const] bind [(type)] ...` */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_ANY_BIND_WITHOUT_TYPE(elem)), \
         BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_THIS_ \
     , \
         BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS_SEQ_VALID_BIND_VAR_ \

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -12,20 +12,21 @@
 #include "../params_const_bind.hpp"
 #include <boost/preprocessor/list/append.hpp>
 
-// bind_qualified_name: [&] name
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND( \
- params, bind_qualified_name) \
+// name_without_type: [&] name (name != `this`)
+// name_with_type: PP_EMPTY | type [&] name (name != `this`)
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND(params, \
+ name_without_type, name_with_type) \
     ( /* unbind params and defaults */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_PP_LIST_APPEND(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params), \
- (bind_qualified_name, BOOST_PP_NIL)) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ ( (name_without_type, name_with_type), BOOST_PP_NIL)) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Copied: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind_this_type.hpp (from r71847, /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp)
==============================================================================
--- /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_bind_this_type.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -4,26 +4,29 @@
 // License, Version 1.0 (see accompanying file LICENSE_1_0.txt or a
 // copy at http://www.boost.org/LICENSE_1_0.txt).
 
-#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT_HPP_
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT_HPP_
+#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND_THIS_TYPE_HPP_
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND_THIS_TYPE_HPP_
 
 #include "../params_unbind.hpp"
 #include "../params_bind.hpp"
 #include "../params_const_bind.hpp"
-#include <boost/preprocessor/arithmetic/inc.hpp>
+#include <boost/preprocessor/list/append.hpp>
 
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT(params) \
+// this_type: PP_EMPTY | type
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_BIND_THIS_TYPE(params, \
+ this_type) \
     ( /* unbind params and defaults */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_PP_INC(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT( \
- params)) /* increment */ \
+ , /* bind `this` */ \
+ BOOST_PP_LIST_APPEND( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params), \
+ ((this_type), BOOST_PP_NIL)) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -12,20 +12,21 @@
 #include "../params_const_bind.hpp"
 #include <boost/preprocessor/list/append.hpp>
 
-// const_bind_qualified_name: [&] name (with name != `this`)
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND( \
- params, const_bind_qualified_name) \
+// name_without_type: [&] name (name != `this`)
+// name_with_type: BOOST_PP_EMPTY | type [&] name (name != `this`)
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND(params, \
+ name_without_type, name_with_type) \
     ( /* unbind params and defaults */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
     , /* const-bind names */ \
         BOOST_PP_LIST_APPEND(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params),\
- (const_bind_qualified_name, BOOST_PP_NIL))\
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ ( (name_without_type, name_with_type), BOOST_PP_NIL))\
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Copied: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind_this_type.hpp (from r71847, /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp)
==============================================================================
--- /sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_const_bind_this_type.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -4,27 +4,28 @@
 // License, Version 1.0 (see accompanying file LICENSE_1_0.txt or a
 // copy at http://www.boost.org/LICENSE_1_0.txt).
 
-#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT_HPP_
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT_HPP_
+#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND_THIS_TYPE_HPP_
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND_THIS_TYPE_HPP_
 
 #include "../params_unbind.hpp"
 #include "../params_bind.hpp"
 #include "../params_const_bind.hpp"
-#include <boost/preprocessor/arithmetic/inc.hpp>
+#include <boost/preprocessor/list/append.hpp>
 
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT( \
- params) \
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_APPEND_CONST_BIND_THIS_TYPE( \
+ params, this_type) \
     ( /* unbind params and defaults */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_PP_INC(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT( \
- params)) /* increment */ \
+ , /* const-bind `this` types */ \
+ BOOST_PP_LIST_APPEND( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params), \
+ ((this_type), BOOST_PP_NIL)) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -23,12 +23,12 @@
                 BOOST_PP_NIL)) \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind_default.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind_default.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/append_unbind_default.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -50,12 +50,12 @@
                 default_value) /* append default to last added param */ \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
     )

Deleted: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_bind_this_count.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
+++ (empty file)
@@ -1,32 +0,0 @@
-
-// Copyright (C) 2009-2011 Lorenzo Caminiti
-// Use, modification, and distribution is subject to the Boost Software
-// License, Version 1.0 (see accompanying file LICENSE_1_0.txt or a
-// copy at http://www.boost.org/LICENSE_1_0.txt).
-
-#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT_HPP_
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT_HPP_
-
-#include "../params_unbind.hpp"
-#include "../params_bind.hpp"
-#include "../params_const_bind.hpp"
-#include <boost/preprocessor/arithmetic/inc.hpp>
-
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_BIND_THIS_COUNT(params) \
- ( /* unbind params and defaults */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
- , /* const-bind names */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
- , /* bind names */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_PP_INC(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT( \
- params)) /* increment */ \
- , /* error message (if any) */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
- )
-
-#endif // #include guard
-

Deleted: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/inc_const_bind_this_count.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
+++ (empty file)
@@ -1,33 +0,0 @@
-
-// Copyright (C) 2009-2011 Lorenzo Caminiti
-// Use, modification, and distribution is subject to the Boost Software
-// License, Version 1.0 (see accompanying file LICENSE_1_0.txt or a
-// copy at http://www.boost.org/LICENSE_1_0.txt).
-
-#ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT_HPP_
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT_HPP_
-
-#include "../params_unbind.hpp"
-#include "../params_bind.hpp"
-#include "../params_const_bind.hpp"
-#include <boost/preprocessor/arithmetic/inc.hpp>
-
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INC_CONST_BIND_THIS_COUNT( \
- params) \
- ( /* unbind params and defaults */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
- , /* const-bind names */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_PP_INC(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT( \
- params)) /* increment */ \
- , /* bind names */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
- , /* error message (if any) */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR(params) \
- )
-
-#endif // #include guard
-

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/index.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/index.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/index.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,25 +7,11 @@
 #ifndef BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_HPP_
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_HPP_
 
-// Parameter (unbound, const-bound, and bound) tuple internal representation:
-//
-// ( // Unbound params tuple.
-// ((NIL, NIL EMPTY)) (([auto | register] ptype pname, pdflt EMPTY)) ...
-// , (NIL) ([&] var) ... // Const bound params.
-// , const_bind_this_count // Number of const bound `this`.
-// , (NIL) ([&] var) ... // Bound params (not const).
-// , bind_this_count // Number of bound `this` (not const).
-//
-// )
-//
-// ptype, pname, pdflt: Parameter types, names, and default values.
-// var: Name of a variable in scope.
-
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_UNBIND 0
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_CONST_BIND 1
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_CONST_BIND_THIS_COUNT 2
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_CONST_BIND_THIS_TYPE 2
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_BIND 3
-#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_BIND_THIS_COUNT 4
+#define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_BIND_THIS_TYPE 4
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_ERROR 5
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_INDEX_MAX 6
 

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/nil.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/nil.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/nil.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -15,15 +15,18 @@
         /* unbound params: list of 2-tuples (classified_name, default) */ \
         BOOST_PP_NIL /* nil list */ \
     , \
- /* const-binds: nil-seq of 1-tuple `ref_name` */ \
+ /* const-binds: list of 2-tuple `(name_untyped, name_typed)` */ \
         BOOST_PP_NIL /* nil list */ \
     , \
- 0 /* number of const-bind `this` */ \
+ /* const-bind this: list of 1-tuple `(type)` */ \
+ BOOST_PP_NIL \
+ /* number of const-bind `this` */ \
     , \
- /* binds: nil-seq of 1-tuple `ref_name` */ \
+ /* binds: list of 2-tuple `(name_untyped, name_typed)` */ \
         BOOST_PP_NIL /* nil list */ \
     , \
- 0 /* number of bind `this` */ \
+ /* bind this: list of 1-type `(type)` */ \
+ BOOST_PP_NIL \
     , \
         BOOST_PP_EMPTY /* no error */ \
     )

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/set_error.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/set_error.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/set_error.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -17,12 +17,12 @@
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(params) \
     , /* const-bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(params) \
- , /* const-bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params) \
+ , /* const-bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_TYPE(params) \
     , /* bind names */ \
         BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND(params) \
- , /* bind `this` count */ \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params) \
+ , /* bind `this` types */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_TYPE(params) \
     , /* error message (if any) */ \
         error \
     )

Modified: sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/validate_/this_count.hpp
==============================================================================
--- sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/validate_/this_count.hpp (original)
+++ sandbox/local/boost/local/aux_/preprocessor/sign/parsed_params_/validate_/this_count.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -12,22 +12,21 @@
 #include "../../params_const_bind.hpp"
 #include "../../params_bind.hpp"
 #include <boost/preprocessor/control/iif.hpp>
-#include <boost/preprocessor/facilities/is_empty.hpp>
+#include <boost/preprocessor/facilities/empty.hpp>
 #include <boost/preprocessor/tuple/eat.hpp>
-#include <boost/preprocessor/comparison/greater.hpp>
-#include <boost/preprocessor/arithmetic/add.hpp>
+#include <boost/preprocessor/logical/bitand.hpp>
 
 // PRIVATE //
 
 #define BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_VALIDATE_THIS_COUNT_(params) \
- BOOST_PP_IIF(BOOST_PP_GREATER(BOOST_PP_ADD( \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND_THIS_COUNT(params), \
- BOOST_LOCAL_AUX_PP_SIGN_PARAMS_BIND_THIS_COUNT(params)), 1), \
+ BOOST_PP_IIF(BOOST_PP_BITAND( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_CONST_BIND_THIS(params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_BIND_THIS(params)), \
         BOOST_LOCAL_AUX_PP_SIGN_PARSED_PARAMS_SET_ERROR \
     , \
         params BOOST_PP_TUPLE_EAT(2) \
     )(params, /* trailing `EMPTY` because error might not be present */ \
- ERROR_object_this_cannot_be_bound_multiple_times BOOST_PP_EMPTY)
+ ERROR_cannot_bind_object_this_multiple_times BOOST_PP_EMPTY)
 
 // PUBLIC //
 

Modified: sandbox/local/boost/local/config.hpp
==============================================================================
--- sandbox/local/boost/local/config.hpp (original)
+++ sandbox/local/boost/local/config.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -98,11 +98,11 @@
  * @See @RefSect2{Advanced_Topics, Advanced Topics} section,
  * @RefSect2{Getting_Started, Getting Started} section.
  */
-#ifndef BOOST_LOCAL_CONFIG_OVERLOADS
-#define BOOST_LOCAL_CONFIG_OVERLOADS 6
+#ifndef BOOST_LOCAL_CONFIG_OVERLOAD_MAX
+#define BOOST_LOCAL_CONFIG_OVERLOAD_MAX 6
 #endif
-#if BOOST_LOCAL_CONFIG_OVERLOADS < 2
-#error "BOOST_LOCAL_CONFIG_OVERLOADS must be a number grater or equal than 2"
+#if BOOST_LOCAL_CONFIG_OVERLOAD_MAX < 2
+#error "BOOST_LOCAL_CONFIG_OVERLOAD_MAX must be grater or equal than 2"
 #endif
 
 /**

Modified: sandbox/local/boost/local/function.hpp
==============================================================================
--- sandbox/local/boost/local/function.hpp (original)
+++ sandbox/local/boost/local/function.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -161,7 +161,7 @@
  * The local function name can be prefixed by the "keyword" <c>inline</c>:
  * @code
  * ... BOOST_LOCAL_FUNCTION_NAME(inline name)
- * @endcode</c>
+ * @endcode
  * This increases the chances that the compiler will be able to inline the
  * local function calls (thus reducing their run-time).
  * However, inlined local functions cannot be passed as template parameters

Modified: sandbox/local/boost/local/function/overload.hpp
==============================================================================
--- sandbox/local/boost/local/function/overload.hpp (original)
+++ sandbox/local/boost/local/function/overload.hpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -1,4 +1,6 @@
 
+#ifndef DOXY // Doxygen documentation only.
+
 #if !BOOST_PP_IS_ITERATING
 # ifndef BOOST_LOCAL_FUNCTION_OVERLOAD_HPP_
 # define BOOST_LOCAL_FUNCTION_OVERLOAD_HPP_
@@ -69,21 +71,34 @@
 // Iterate within namespace.
 # define BOOST_PP_ITERATION_PARAMS_1 \
                 /* need at least 2 functors to overload so iter 2, 3, ... */ \
- (3, (0, BOOST_PP_SUB(BOOST_LOCAL_CONFIG_OVERLOADS, 2), \
+ (3, (0, BOOST_PP_SUB(BOOST_LOCAL_CONFIG_OVERLOAD_MAX, 2), \
                 BOOST_LOCAL_AUX_FILE_FUNCTION_OVERLOAD_HPP))
 # include BOOST_PP_ITERATE() // Iterate over function arity.
 
 }}} // namespace boost::local::function
 
+#undef BOOST_LOCAL_f_type
+#undef BOOST_LOCAL_f_tparam
+#undef BOOST_LOCAL_f_tparam_dflt
+#undef BOOST_LOCAL_g_arg_type
+#undef BOOST_LOCAL_g_arg_name
+#undef BOOST_LOCAL_g_arg_tparam
+#undef BOOST_LOCAL_g_arg
+#undef BOOST_LOCAL_overload_base
+#undef BOOST_LOCAL_overload_inherit
+#undef BOOST_LOCAL_overload_base_init
+#undef BOOST_LOCAL_using_operator_call
+
 # endif // #include guard
 
 #elif BOOST_PP_ITERATION_DEPTH() == 1
 # define BOOST_LOCAL_overloads \
         /* iterate as OVERLOADS, OVERLOADS-1, OVERLOADS-2, ... */ \
- BOOST_PP_SUB(BOOST_LOCAL_CONFIG_OVERLOADS, BOOST_PP_FRAME_ITERATION(1))
+ BOOST_PP_SUB(BOOST_LOCAL_CONFIG_OVERLOAD_MAX, \
+ BOOST_PP_FRAME_ITERATION(1))
 # define BOOST_LOCAL_is_tspec \
         /* if template specialization */ \
- BOOST_PP_LESS(BOOST_LOCAL_overloads, BOOST_LOCAL_CONFIG_OVERLOADS)
+ BOOST_PP_LESS(BOOST_LOCAL_overloads, BOOST_LOCAL_CONFIG_OVERLOAD_MAX)
 
 // Iterating within namespace boost::local::function.
 template<BOOST_PP_ENUM(BOOST_LOCAL_overloads, BOOST_LOCAL_f_tparam_dflt,
@@ -113,7 +128,62 @@
     BOOST_PP_REPEAT(BOOST_LOCAL_overloads, BOOST_LOCAL_using_operator_call, ~)
 };
 
-# undef BOOST_LOCAL_is_tspec
 # undef BOOST_LOCAL_AUX_overloads
+# undef BOOST_LOCAL_is_tspec
 #endif // iteration
 
+#else // DOXY: Doxygen documentation only.
+
+namespace boost { namespace local { namespace function {
+
+/**
+ * @brief Functor to overload local functions and other functors.
+ *
+ * This functor aggregates together calls to functions of all the specified
+ * types.
+ *
+ * The maximum number of overloaded function types is specified by the
+ * @RefMacro{BOOST_LOCAL_CONFIG_OVERLOAD_MAX} configuration macro.
+ * The maximum number of function parameters for each of the specified function
+ * type is specified by the @RefMacro{BOOST_LOCAL_CONFIG_OVERLOAD_MAX}
+ * configuration macro.
+ *
+ * @See @RefSect2{Advanced_Topics, Advanced Topics} section,
+ * @RefMacro{BOOST_LOCAL_CONFIG_OVERLOAD_MAX},
+ * @RefMacro{BOOST_LOCAL_CONFIG_OVERLOAD_MAX}.
+ */
+template<typename F0, typename F1, ...>
+class overload {
+public:
+ /**
+ * @brief Construct the overloading functor.
+ *
+ * Any functor that can be converted to a <c>boost::function</c> funcotr
+ * can be specified (local functions, function pointers, other functors,
+ * etc).
+ */
+ overload(const boost::function<F0>&, const boost::function<F1>&, ...);
+
+ /**
+ * @brief Call operator matching the signature of the first specified
+ * functor.
+ *
+ * This will in turn invoke the call operator of the first functor that was
+ * passed to the constructor.
+ */
+ result_type<F0> operator()(arg0_type<F0>, arg1_type<F0>, ...) const;
+
+ /**
+ * @brief Call operator matching the signature of the second specified
+ * functor.
+ *
+ * This will in turn invoke the call operator of the second functor that
+ * was passed to the constructor.
+ */
+ result_type<F1> operator()(arg0_type<F1>, arg1_type<F1>, ...) const;
+};
+
+}}} // namespace boost::local::function
+
+#endif // DOXY
+

Modified: sandbox/local/libs/local/doc/Jamfile.jam
==============================================================================
--- sandbox/local/libs/local/doc/Jamfile.jam (original)
+++ sandbox/local/libs/local/doc/Jamfile.jam 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -10,6 +10,7 @@
 doxygen reference
     :
         ../../../boost/local/function.hpp
+ ../../../boost/local/function/overload.hpp
         ../../../boost/local/block.hpp
         ../../../boost/local/exit.hpp
         ../../../boost/local/typeof.hpp
@@ -19,7 +20,7 @@
         <doxygen:param>QUIET=YES
         <doxygen:param>ALIASES=" Params=\"<b>Parameters:</b> <table border="0">\" Param{2}=\"<tr><td><b><tt>\\1</tt></b></td><td>\\2</td></tr>\" EndParams=\"</table>\" Returns=\"<b>Returns:</b>\" Note=\"<b>Note:</b>\" Warning=\"<b>Warning:</b>\" See=\"<b>See:</b>\" RefSect{1}=\"\\xmlonly<link linkend='boost_local.\\1'>\\1</link>\\endxmlonly\" RefSect2{2}=\"\\xmlonly<link linkend='boost_local.\\1'>\\2</link>\\endxmlonly\" RefClass{1}=\"\\xmlonly<computeroutput><classname alt='\\1'>\\1</classname></computeroutput>\\endxmlonly\" RefMacro{1}=\"\\xmlonly<computeroutput><macroname alt='\\1'>\\1</macroname></computeroutput>\\endxmlonly\" "
         # Extract Doxygen that comments non-variant macros.
- <doxygen:param>PREDEFINED=BOOST_LOCAL_CONFIG_COMPLIANT
+ <doxygen:param>PREDEFINED="BOOST_LOCAL_CONFIG_COMPLIANT DOXY"
         <reftitle>"Reference"
     ;
 

Modified: sandbox/local/libs/local/doc/html/BOOST_IDENTITY_TYPE.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_IDENTITY_TYPE.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_IDENTITY_TYPE.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_IDENTITY_TYPE(parenthesized_type)</pre></div>
 <div class="refsect1">
-<a name="id915526"></a><h2>Description</h2>
+<a name="id925188"></a><h2>Description</h2>
 <p>This macro expands to an expression that can be passed as a single macro parameter even if it contains commas and that evaluates to the specified type at compile-time (see the <a class="link" href="boost_local/Advanced_Topics.html" title="Advanced Topics"> Advanced Topics</a> section).</p>
 <p>For example <code class="computeroutput">BOOST_IDENTITY_TYPE((std::map&lt;int, double&gt;))</code> can be passed as a single macro parameter when instead <code class="computeroutput">std::map&lt;int, double&gt;</code> cannot (because it contains a comma not wrapped by round parenthesis so it will be interpreted as two separate macro parameters by the preprocessor).</p>
 <p><span class="bold"><strong>Parameters:</strong></span> </p>

Modified: sandbox/local/libs/local/doc/html/BOOST_IDENTITY_VALUE.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_IDENTITY_VALUE.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_IDENTITY_VALUE.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_IDENTITY_VALUE(parenthesized_value)</pre></div>
 <div class="refsect1">
-<a name="id915667"></a><h2>Description</h2>
+<a name="id925329"></a><h2>Description</h2>
 <p>This macro expands to an expression that can be passed as a single macro parameter even if it contains commas and that evaluates to the specified value at run-time (see the <a class="link" href="boost_local/Advanced_Topics.html" title="Advanced Topics"> Advanced Topics</a> section).</p>
 <p>For example <code class="computeroutput">BOOST_IDENTITY_VALUE((key_sizeof&lt;int, double&gt;::value))</code> can be passed as a single macro parameter when instead <code class="computeroutput">key_sizeof&lt;int, double&gt;::value</code> cannot (because it contains a comma not wrapped by round parenthesis so it will be interpreted as two separate macro parameters by the preprocessor).</p>
 <p><span class="bold"><strong>Parameters:</strong></span> </p>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_BLOCK(bindings)</pre></div>
 <div class="refsect1">
-<a name="id911625"></a><h2>Description</h2>
+<a name="id919879"></a><h2>Description</h2>
 <p>This macro must be used within a declarative context, it must be followed by the local block body code and then by the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_BLOCK_END.html" title="Macro BOOST_LOCAL_BLOCK_END">BOOST_LOCAL_BLOCK_END</a></code> macro (see the Tutorial section): </p>
 <pre class="programlisting"> <span class="special">{</span> <span class="comment">// Some declarative context.</span>
       <span class="special">...</span>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_END.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_END.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_END.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_BLOCK_END</pre></div>
 <div class="refsect1">
-<a name="id912363"></a><h2>Description</h2>
+<a name="id920618"></a><h2>Description</h2>
 <p>This macro must follow the local block body code <code class="computeroutput">{ ... }</code> as shown in the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_BLOCK.html" title="Macro BOOST_LOCAL_BLOCK">BOOST_LOCAL_BLOCK</a></code> documentation.</p>
 <p><span class="bold"><strong>Note:</strong></span> This macro cannot be used multiple times on the same line because it internally uses the line number <code class="computeroutput">__LINE__</code> to generate unique identifiers.</p>
 <p><span class="bold"><strong>See:</strong></span> <code class="computeroutput"><a class="link" href="BOOST_LOCAL_BLOCK.html" title="Macro BOOST_LOCAL_BLOCK">BOOST_LOCAL_BLOCK</a></code>, <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section. </p>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_TPL.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_TPL.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_BLOCK_TPL.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_BLOCK_TPL(bindings)</pre></div>
 <div class="refsect1">
-<a name="id912289"></a><h2>Description</h2>
+<a name="id920543"></a><h2>Description</h2>
 <p><span class="bold"><strong>See:</strong></span> <code class="computeroutput"><a class="link" href="BOOST_LOCAL_BLOCK.html" title="Macro BOOST_LOCAL_BLOCK">BOOST_LOCAL_BLOCK</a></code>, <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section. </p>
 </div>
 </div>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_COMPLIANT.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_COMPLIANT.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_COMPLIANT.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_CONFIG_COMPLIANT</pre></div>
 <div class="refsect1">
-<a name="id912530"></a><h2>Description</h2>
+<a name="id920790"></a><h2>Description</h2>
 <p>If programmers leave this configuration macro undefined, its default value is to be left not defined.</p>
 <p>If this macro is defined, variadic macros and empty macro parameters are not used by this library. Using variadic macros and empty macro parameters allows this library to provide the <span class="emphasis"><em>variadic macro</em></span> and <span class="emphasis"><em>empty macro</em></span> syntaxes which some programmers might find more readable than the <span class="emphasis"><em>sequencing macro</em></span> syntax (see <code class="computeroutput"><a class="link" href="BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code>, <code class="computeroutput"><a class="link" href="BOOST_LOCAL_BLOCK.html" title="Macro BOOST_LOCAL_BLOCK">BOOST_LOCAL_BLOCK</a></code>, and <code class="computeroutput"><a class="link" href="BOOST_LOCAL_EXIT.html" title="Macro BOOST_LOCAL_EXIT">BOOST_LOCAL_EXIT</a></code>). If this configuration macro is defined then only the sequencing macro syntax is allowed (regardless of whether the compiler supports variadic and e
mpty macros or not).</p>
 <p><span class="bold"><strong>Warning:</strong></span> The variadic and empty macro syntaxes are not supported by all C++ compilers so they should be used with care to avoid portability issues (and this configuration macro can be defined to disable them).</p>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,7 +7,7 @@
 <link rel="home" href="index.html" title="Boost.Local 0.2.0">
 <link rel="up" href="reference.html#header.boost.local.config_hpp" title="Header &lt;boost/local/config.hpp&gt;">
 <link rel="prev" href="BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">
-<link rel="next" href="BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html" title="Macro BOOST_LOCAL_CONFIG_THIS_PARAM_NAME">
+<link rel="next" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html" title="Macro BOOST_LOCAL_CONFIG_OVERLOAD_MAX">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
 <table cellpadding="2" width="100%"><tr>
@@ -20,7 +20,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_CONFIG_COMPLIANT.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_CONFIG_COMPLIANT.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 <div class="refentry">
 <a name="BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX"></a><div class="titlepage"></div>
@@ -33,11 +33,11 @@
 
 </span>BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX</pre></div>
 <div class="refsect1">
-<a name="id912735"></a><h2>Description</h2>
+<a name="id920995"></a><h2>Description</h2>
 <p>If programmers leave this configuration macro undefined, its default value is <code class="computeroutput">5</code>.</p>
 <p>This only refers to the number of local function parameters and not to the number of bound variables in scope (the limit on the number of bound variables is instead the maximum size allowed for a Boost.Preprocessor sequences).</p>
 <p><span class="bold"><strong>Warning:</strong></span> Increasing this number will increase compilation time.</p>
-<p><span class="bold"><strong>See:</strong></span> <a class="link" href="boost_local/Getting_Started.html" title="Getting Started"> Getting Started</a> section. </p>
+<p><span class="bold"><strong>See:</strong></span> <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section, <a class="link" href="boost_local/Getting_Started.html" title="Getting Started"> Getting Started</a> section. </p>
 </div>
 </div>
 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
@@ -50,7 +50,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_CONFIG_COMPLIANT.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_CONFIG_COMPLIANT.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 </body>
 </html>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -6,7 +6,7 @@
 <meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
 <link rel="home" href="index.html" title="Boost.Local 0.2.0">
 <link rel="up" href="reference.html#header.boost.local.config_hpp" title="Header &lt;boost/local/config.hpp&gt;">
-<link rel="prev" href="BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html" title="Macro BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX">
+<link rel="prev" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html" title="Macro BOOST_LOCAL_CONFIG_OVERLOAD_MAX">
 <link rel="next" href="BOOST_LOCAL_EXIT.html" title="Macro BOOST_LOCAL_EXIT">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -20,7 +20,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_EXIT.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_EXIT.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 <div class="refentry">
 <a name="BOOST_LOCAL_CONFIG_THIS_PARAM_NAME"></a><div class="titlepage"></div>
@@ -33,10 +33,10 @@
 
 </span>BOOST_LOCAL_CONFIG_THIS_PARAM_NAME</pre></div>
 <div class="refsect1">
-<a name="id912830"></a><h2>Description</h2>
+<a name="id921202"></a><h2>Description</h2>
 <p>If programmers leave this configuration macro undefined, the default symbol used is <code class="computeroutput">this_</code>.</p>
 <p><span class="bold"><strong>Warning:</strong></span> Programmers should not define this macro unless it is absolutely necessary (e.g., to avoid name clashes with another library which cannot be changed). Changing the symbol <code class="computeroutput">this_</code> effectively changes the public API of this library.</p>
-<p><span class="bold"><strong>See:</strong></span> <a class="link" href="boost_local/Getting_Started.html" title="Getting Started"> Getting Started</a> section. </p>
+<p><span class="bold"><strong>See:</strong></span> <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section, <a class="link" href="boost_local/Getting_Started.html" title="Getting Started"> Getting Started</a> section. </p>
 </div>
 </div>
 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
@@ -49,7 +49,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_EXIT.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.config_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_EXIT.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 </body>
 </html>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_EXIT(binding_list)</pre></div>
 <div class="refsect1">
-<a name="id912971"></a><h2>Description</h2>
+<a name="id921351"></a><h2>Description</h2>
 <p>This macro must be used within a declarative context, it must be followed by the local exit body code and then by the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_EXIT_END.html" title="Macro BOOST_LOCAL_EXIT_END">BOOST_LOCAL_EXIT_END</a></code> macro (see the <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section): </p>
 <pre class="programlisting"> <span class="special">{</span> <span class="comment">// Some declarative context.</span>
       <span class="special">...</span>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_END.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_END.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_END.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_EXIT_END</pre></div>
 <div class="refsect1">
-<a name="id913721"></a><h2>Description</h2>
+<a name="id922101"></a><h2>Description</h2>
 <p>This macro must follow the local exit body code <code class="computeroutput">{ ... }</code> as shown in the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_EXIT.html" title="Macro BOOST_LOCAL_EXIT">BOOST_LOCAL_EXIT</a></code> documentation.</p>
 <p><span class="bold"><strong>Note:</strong></span> This macro cannot be used multiple times on the same line because it internally uses the line number <code class="computeroutput">__LINE__</code> to generate unique identifiers.</p>
 <p><span class="bold"><strong>See:</strong></span> <code class="computeroutput"><a class="link" href="BOOST_LOCAL_EXIT.html" title="Macro BOOST_LOCAL_EXIT">BOOST_LOCAL_EXIT</a></code>, <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section. </p>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_TPL.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_TPL.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_EXIT_TPL.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_EXIT_TPL(binding_list)</pre></div>
 <div class="refsect1">
-<a name="id913647"></a><h2>Description</h2>
+<a name="id922027"></a><h2>Description</h2>
 <p><span class="bold"><strong>See:</strong></span> <code class="computeroutput"><a class="link" href="BOOST_LOCAL_EXIT.html" title="Macro BOOST_LOCAL_EXIT">BOOST_LOCAL_EXIT</a></code>, <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section. </p>
 </div>
 </div>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_NAME.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_NAME.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_NAME.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -7,7 +7,7 @@
 <link rel="home" href="index.html" title="Boost.Local 0.2.0">
 <link rel="up" href="reference.html#header.boost.local.function_hpp" title="Header &lt;boost/local/function.hpp&gt;">
 <link rel="prev" href="BOOST_LOCAL_FUNCTION_PARAMS_TPL.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS_TPL">
-<link rel="next" href="BOOST_LOCAL_TYPEOF.html" title="Macro BOOST_LOCAL_TYPEOF">
+<link rel="next" href="boost/local/function/overload.html" title="Class template overload">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
 <table cellpadding="2" width="100%"><tr>
@@ -20,7 +20,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_FUNCTION_PARAMS_TPL.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.function_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_TYPEOF.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_FUNCTION_PARAMS_TPL.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.function_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="boost/local/function/overload.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 <div class="refentry">
 <a name="BOOST_LOCAL_FUNCTION_NAME"></a><div class="titlepage"></div>
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_FUNCTION_NAME(name)</pre></div>
 <div class="refsect1">
-<a name="id914846"></a><h2>Description</h2>
+<a name="id923226"></a><h2>Description</h2>
 <p>This macro must follow the local function body code block <code class="computeroutput">{ ... }</code> as shown in the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code> documentation.</p>
 <p>The local function name can be prefixed by the "keyword" <code class="computeroutput">inline</code>: </p>
 <pre class="programlisting"> <span class="special">...</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="keyword">inline</span> <span class="identifier">name</span><span class="special">)</span>
@@ -71,7 +71,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_FUNCTION_PARAMS_TPL.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.function_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_LOCAL_TYPEOF.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="BOOST_LOCAL_FUNCTION_PARAMS_TPL.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.function_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="boost/local/function/overload.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 </body>
 </html>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_FUNCTION_PARAMS(parameters)</pre></div>
 <div class="refsect1">
-<a name="id913889"></a><h2>Description</h2>
+<a name="id922268"></a><h2>Description</h2>
 <p>This macro must be used within a declarative context, it must follow the local function result type, it must be followed by the local function body code and then by the <code class="computeroutput"><a class="link" href="BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code> macro (see the <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> and <a class="link" href="boost_local/Advanced_Topics.html" title="Advanced Topics"> Advanced Topics</a> sections): </p>
 <pre class="programlisting"> <span class="special">{</span> <span class="comment">// Some declarative context.</span>
       <span class="special">...</span>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS_TPL.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS_TPL.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_FUNCTION_PARAMS_TPL.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_FUNCTION_PARAMS_TPL(parameters)</pre></div>
 <div class="refsect1">
-<a name="id914772"></a><h2>Description</h2>
+<a name="id923151"></a><h2>Description</h2>
 <p><span class="bold"><strong>See:</strong></span> <code class="computeroutput"><a class="link" href="BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code>, <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a> section. </p>
 </div>
 </div>

Modified: sandbox/local/libs/local/doc/html/BOOST_LOCAL_TYPEOF.html
==============================================================================
--- sandbox/local/libs/local/doc/html/BOOST_LOCAL_TYPEOF.html (original)
+++ sandbox/local/libs/local/doc/html/BOOST_LOCAL_TYPEOF.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -6,7 +6,7 @@
 <meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
 <link rel="home" href="index.html" title="Boost.Local 0.2.0">
 <link rel="up" href="reference.html#header.boost.local.typeof_hpp" title="Header &lt;boost/local/typeof.hpp&gt;">
-<link rel="prev" href="BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">
+<link rel="prev" href="boost/local/function/overload.html" title="Class template overload">
 <link rel="next" href="BOOST_IDENTITY_TYPE.html" title="Macro BOOST_IDENTITY_TYPE">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -20,7 +20,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_FUNCTION_NAME.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.typeof_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_IDENTITY_TYPE.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="boost/local/function/overload.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.typeof_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_IDENTITY_TYPE.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 <div class="refentry">
 <a name="BOOST_LOCAL_TYPEOF"></a><div class="titlepage"></div>
@@ -33,7 +33,7 @@
 
 </span>BOOST_LOCAL_TYPEOF(bound_variable_name)</pre></div>
 <div class="refsect1">
-<a name="id915198"></a><h2>Description</h2>
+<a name="id924860"></a><h2>Description</h2>
 <p>The type is fully qualified in that it contains the extra constant and reference qualifiers when they are specified for binding by constant and by reference. For example, if a variable named <code class="computeroutput">t</code> of type <code class="computeroutput">T</code> is: </p>
 <div class="itemizedlist"><ul class="itemizedlist" type="disc">
 <li class="listitem"><p>Bound by value using <code class="computeroutput">bind t</code> then <code class="computeroutput">BOOST_LOCAL_TYPEOF(t)</code> is <code class="computeroutput">T</code>. </p></li>
@@ -70,7 +70,7 @@
 </tr></table>
 <hr>
 <div class="spirit-nav">
-<a accesskey="p" href="BOOST_LOCAL_FUNCTION_NAME.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.typeof_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_IDENTITY_TYPE.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
+<a accesskey="p" href="boost/local/function/overload.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="reference.html#header.boost.local.typeof_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="BOOST_IDENTITY_TYPE.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
 </div>
 </body>
 </html>

Modified: sandbox/local/libs/local/doc/html/boost_local/Advanced_Topics.html
==============================================================================
--- sandbox/local/libs/local/doc/html/boost_local/Advanced_Topics.html (original)
+++ sandbox/local/libs/local/doc/html/boost_local/Advanced_Topics.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -29,22 +29,26 @@
 <div class="toc"><dl>
 <dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.commas_and_symbols_in_macro_parameters">Commas
       and Symbols in Macro Parameters</a></span></dt>
-<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.passing_local_functions">Passing
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.assigning_local_functions">Assigning
       Local Functions</a></span></dt>
 <dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.deducing_bound_types__concepts__etc_">Deducing
       Bound Types (concepts, etc)</a></span></dt>
-<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.inlined_local_functions">Inlined
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.specifying_bound_types">Specifying
+ Bound Types</a></span></dt>
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.inlining_local_functions">Inlining
       Local Functions</a></span></dt>
 <dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.recursive_local_functions">Recursive
       Local Functions</a></span></dt>
-<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.nested_declarations">Nested
- Declarations</a></span></dt>
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.overloading_local_functions">Overloading
+ Local Functions</a></span></dt>
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.nesting_local_constructs">Nesting
+ Local Constructs</a></span></dt>
 <dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.exception_specifications">Exception
       Specifications</a></span></dt>
 <dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.storage_classifiers___auto__and__register__">Storage
       Classifiers (<code class="computeroutput"><span class="keyword">auto</span></code> and <code class="computeroutput"><span class="keyword">register</span></code>)</a></span></dt>
-<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__overloading__operators__etc_">Limitations
- (overloading, operators, etc)</a></span></dt>
+<dt><span class="section"><a href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__operators__etc_">Limitations
+ (operators, etc)</a></span></dt>
 </dl></div>
 <p>
       This section illustrates advanced usages of this library. At the end of this
@@ -82,7 +86,7 @@
 <p>
         In addition, local function parameter types cannot start with non-alphanumeric
         symbols (alphanumeric symbols are <code class="computeroutput"><span class="identifier">A</span><span class="special">-</span><span class="identifier">Z</span></code>, <code class="computeroutput"><span class="identifier">a</span><span class="special">-</span><span class="identifier">z</span></code>,
- and <code class="computeroutput"><span class="number">0</span><span class="special">-</span><span class="number">9</span></code>). <sup>[<a name="id881643" href="#ftn.id881643" class="footnote">16</a>]</sup> The library will generate (cryptic) preprocessor errors if a
+ and <code class="computeroutput"><span class="number">0</span><span class="special">-</span><span class="number">9</span></code>). <sup>[<a name="id881800" href="#ftn.id881800" class="footnote">16</a>]</sup> The library will generate (cryptic) preprocessor errors if a
         parameter type starts with a non-alphanumeric symbol.
       </p>
 <p>
@@ -221,7 +225,7 @@
 <li class="listitem">
             Parenthesis to wrap the type expression (and therefore any commas <code class="computeroutput"><span class="special">,</span></code> that it contains) passed as parameter
             to the <code class="computeroutput"><a class="link" href="../BOOST_IDENTITY_TYPE.html" title="Macro BOOST_IDENTITY_TYPE">BOOST_IDENTITY_TYPE</a></code>
- macro. <sup>[<a name="id883080" href="#ftn.id883080" class="footnote">17</a>]</sup>
+ macro. <sup>[<a name="id883236" href="#ftn.id883236" class="footnote">17</a>]</sup>
           </li>
 </ol></div>
 <div class="note"><table border="0" summary="Note">
@@ -591,7 +595,7 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Advanced_Topics.passing_local_functions"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.passing_local_functions" title="Passing Local Functions">Passing
+<a name="boost_local.Advanced_Topics.assigning_local_functions"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.assigning_local_functions" title="Assigning Local Functions">Assigning
       Local Functions</a>
 </h3></div></div></div>
 <p>
@@ -1155,7 +1159,186 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Advanced_Topics.inlined_local_functions"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.inlined_local_functions" title="Inlined Local Functions">Inlined
+<a name="boost_local.Advanced_Topics.specifying_bound_types"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.specifying_bound_types" title="Specifying Bound Types">Specifying
+ Bound Types</a>
+</h3></div></div></div>
+<p>
+ While not required, it is possible to explicitly specify the type of the
+ bound variables. When the bound variable type is explicitly specified by
+ the programmers, the library will not use Boost.Typeof
+ to automatically deduce such a type. However, the library implementation
+ will still internally use Boost.Typeof
+ to deduce the local function result and functor types (see the <a class="link" href="Implementation.html" title="Appendix: Implementation">Implementation</a>
+ section) even when Boost.Typeof
+ is not used to deduce any of the bound variable types.
+ </p>
+<p>
+ When specified, the bound variable type must follow the <code class="computeroutput"><span class="identifier">bind</span></code>
+ "keyword" and it must be wrapped within round parenthesis <code class="computeroutput"><span class="special">()</span></code>:
+ </p>
+<pre class="programlisting"><span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>variable-type</em></span><span class="special">)</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by value with explicit type.</span>
+<span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>variable-type</em></span><span class="special">)&amp;</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by reference with explicit type.</span>
+<span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>variable-type</em></span><span class="special">)</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by constant value with explicit type.</span>
+<span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>variable-type</em></span><span class="special">)&amp;</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by constant value with explicit type.</span>
+<span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>class-type</em></span><span class="special">*)</span> <span class="keyword">this</span> <span class="comment">// Bind object `this` with type.</span>
+<span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="emphasis"><em>class-type</em></span><span class="special">*)</span> <span class="keyword">this</span> <span class="comment">// Bind object `this` by constant with type.</span>
+</pre>
+<p>
+ The following example explicitly specifies the type of all bound variables
+ (it is also possible to explicitly specify the type only for some of the
+ bound variables in which case the library will automatically deduce the type
+ of the rest of the bound variables using Boost.Typeof
+ as usual):
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Variadic Macro Syntax (C99 and later compilers)
+ </p>
+ </th>
+<th>
+ <p>
+ Sequencing Macro Syntax (all C++ compilers)
+ </p>
+ </th>
+</tr></thead>
+<tbody><tr>
+<td>
+ <p>
+
+</p>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">block</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">exit</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">vector</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">algorithm</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">iostream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">sstream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">cassert</span><span class="special">&gt;</span>
+
+<span class="keyword">class</span> <span class="identifier">adder</span> <span class="special">{</span>
+<span class="keyword">public</span><span class="special">:</span>
+ <span class="identifier">adder</span><span class="special">():</span> <span class="identifier">sum_</span><span class="special">(</span><span class="number">0.0</span><span class="special">)</span> <span class="special">{}</span>
+
+ <span class="keyword">double</span> <span class="identifier">sum</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;&amp;</span> <span class="identifier">nums</span><span class="special">,</span> <span class="keyword">const</span> <span class="keyword">int</span><span class="special">&amp;</span> <span class="identifier">factor</span> <span class="special">=</span> <span class="number">10</span><span class="special">)</span> <span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span> <span class="identifier">out</span><span class="special">;</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span><span class="keyword">double</span> <span class="identifier">num</span><span class="special">,</span>
+ <span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="keyword">const</span> <span class="keyword">int</span><span class="special">&amp;)</span> <span class="identifier">factor</span><span class="special">,</span> <span class="comment">// Specify bind types</span>
+ <span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</span><span class="special">,</span> <span class="comment">// explicitly (so no</span>
+ <span class="identifier">bind</span><span class="special">(</span><span class="identifier">adder</span><span class="special">*)</span> <span class="keyword">this</span><span class="special">)</span> <span class="special">{</span> <span class="comment">// Boost.Typeof for binds).</span>
+ <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">+=</span> <span class="identifier">factor</span> <span class="special">*</span> <span class="identifier">num</span><span class="special">;</span>
+ <span class="identifier">out</span> <span class="special">&lt;&lt;</span> <span class="string">"Summed: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">add</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
+
+ <span class="identifier">BOOST_LOCAL_EXIT</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</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">&lt;&lt;</span> <span class="identifier">out</span><span class="special">.</span><span class="identifier">str</span><span class="special">();</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_EXIT_END</span>
+
+ <span class="identifier">BOOST_LOCAL_BLOCK</span><span class="special">(</span><span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</span><span class="special">,</span>
+ <span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="identifier">adder</span><span class="special">*)</span> <span class="keyword">this</span><span class="special">)</span> <span class="special">{</span>
+ <span class="identifier">out</span> <span class="special">&lt;&lt;</span> <span class="string">"Asserted: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="identifier">assert</span><span class="special">(</span><span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&gt;</span> <span class="number">0.0</span><span class="special">);</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_BLOCK_END</span>
+
+ <span class="keyword">return</span> <span class="identifier">sum_</span><span class="special">;</span>
+ <span class="special">}</span>
+
+<span class="keyword">private</span><span class="special">:</span>
+ <span class="keyword">double</span> <span class="identifier">sum_</span><span class="special">;</span>
+<span class="special">};</span>
+
+<span class="keyword">int</span> <span class="identifier">main</span><span class="special">()</span> <span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;</span> <span class="identifier">v</span><span class="special">(</span><span class="number">3</span><span class="special">);</span>
+ <span class="identifier">v</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="number">100.0</span><span class="special">;</span> <span class="identifier">v</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="number">90.5</span><span class="special">;</span> <span class="identifier">v</span><span class="special">[</span><span class="number">2</span><span class="special">]</span> <span class="special">=</span> <span class="number">7.0</span><span class="special">;</span>
+
+ <span class="identifier">adder</span> <span class="identifier">a</span><span class="special">;</span>
+ <span class="comment">// sum = 10 * 100.0 + 10 * 90.5 + 10 * 7.0 = 1975.0</span>
+ <span class="identifier">assert</span><span class="special">(</span><span class="identifier">a</span><span class="special">.</span><span class="identifier">sum</span><span class="special">(</span><span class="identifier">v</span><span class="special">)</span> <span class="special">==</span> <span class="number">1975.0</span><span class="special">);</span>
+
+ <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+ </td>
+<td>
+ <p>
+
+</p>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">block</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">exit</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">vector</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">algorithm</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">iostream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">sstream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">cassert</span><span class="special">&gt;</span>
+
+<span class="keyword">class</span> <span class="identifier">adder</span> <span class="special">{</span>
+<span class="keyword">public</span><span class="special">:</span>
+ <span class="identifier">adder</span><span class="special">():</span> <span class="identifier">sum_</span><span class="special">(</span><span class="number">0.0</span><span class="special">)</span> <span class="special">{}</span>
+
+ <span class="keyword">double</span> <span class="identifier">sum</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;&amp;</span> <span class="identifier">nums</span><span class="special">,</span> <span class="keyword">const</span> <span class="keyword">int</span><span class="special">&amp;</span> <span class="identifier">factor</span> <span class="special">=</span> <span class="number">10</span><span class="special">)</span> <span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span> <span class="identifier">out</span><span class="special">;</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span> <span class="special">(</span><span class="keyword">double</span> <span class="identifier">num</span><span class="special">)</span>
+ <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="keyword">const</span> <span class="keyword">int</span><span class="special">&amp;)</span> <span class="identifier">factor</span><span class="special">)</span> <span class="comment">// Specify bind types</span>
+ <span class="special">(</span><span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</span><span class="special">)</span> <span class="comment">// explicitly (so no</span>
+ <span class="special">(</span><span class="identifier">bind</span><span class="special">(</span><span class="identifier">adder</span><span class="special">*)</span> <span class="keyword">this</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span> <span class="comment">// Boost.Typeof for binds).</span>
+ <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">+=</span> <span class="identifier">factor</span> <span class="special">*</span> <span class="identifier">num</span><span class="special">;</span>
+ <span class="identifier">out</span> <span class="special">&lt;&lt;</span> <span class="string">"Summed: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">add</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
+
+ <span class="identifier">BOOST_LOCAL_EXIT</span><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</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">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">out</span><span class="special">.</span><span class="identifier">str</span><span class="special">();</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_EXIT_END</span>
+
+ <span class="identifier">BOOST_LOCAL_BLOCK</span><span class="special">(</span> <span class="special">(</span><span class="identifier">bind</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">ostringstream</span><span class="special">)&amp;</span> <span class="identifier">out</span><span class="special">)</span>
+ <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">(</span><span class="identifier">adder</span><span class="special">*)</span> <span class="keyword">this</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span>
+ <span class="identifier">out</span> <span class="special">&lt;&lt;</span> <span class="string">"Asserted: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
+ <span class="identifier">assert</span><span class="special">(</span><span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&gt;</span> <span class="number">0.0</span><span class="special">);</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_BLOCK_END</span>
+
+ <span class="keyword">return</span> <span class="identifier">sum_</span><span class="special">;</span>
+ <span class="special">}</span>
+
+<span class="keyword">private</span><span class="special">:</span>
+ <span class="keyword">double</span> <span class="identifier">sum_</span><span class="special">;</span>
+<span class="special">};</span>
+
+<span class="keyword">int</span> <span class="identifier">main</span><span class="special">()</span> <span class="special">{</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;</span> <span class="identifier">v</span><span class="special">(</span><span class="number">3</span><span class="special">);</span>
+ <span class="identifier">v</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="number">100.0</span><span class="special">;</span> <span class="identifier">v</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="number">90.5</span><span class="special">;</span> <span class="identifier">v</span><span class="special">[</span><span class="number">2</span><span class="special">]</span> <span class="special">=</span> <span class="number">7.0</span><span class="special">;</span>
+
+ <span class="identifier">adder</span> <span class="identifier">a</span><span class="special">;</span>
+ <span class="comment">// sum = 10 * 100.0 + 10 * 90.5 + 10 * 7.0 = 1975.0</span>
+ <span class="identifier">assert</span><span class="special">(</span><span class="identifier">a</span><span class="special">.</span><span class="identifier">sum</span><span class="special">(</span><span class="identifier">v</span><span class="special">)</span> <span class="special">==</span> <span class="number">1975.0</span><span class="special">);</span>
+
+ <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+ </td>
+</tr></tbody>
+</table></div>
+<p>
+ Within the local function, local block, and local exit body it is possible
+ to abstract the access to the type of a bound variable as usual using <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_TYPEOF.html" title="Macro BOOST_LOCAL_TYPEOF">BOOST_LOCAL_TYPEOF</a></code> (even if the
+ bound variable type is specified explicitly).
+ </p>
+</div>
+<div class="section">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="boost_local.Advanced_Topics.inlining_local_functions"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.inlining_local_functions" title="Inlining Local Functions">Inlining
       Local Functions</a>
 </h3></div></div></div>
 <p>
@@ -1170,17 +1353,18 @@
 <span class="special">}</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="keyword">inline</span> <span class="emphasis"><em>name</em></span><span class="special">)</span>
 </pre>
 <p>
- On ISO C++ compliant compilers (see <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">BOOST_LOCAL_CONFIG_COMPLIANT</a></code>),
- inlined local functions always have a run-time comparable to their equivalent
- implementation that uses local functors (see the <a class="link" href="Alternatives.html" title="Appendix: Alternatives">Alternatives</a>
- section). However, inlined local functions have the limitation that they
- cannot be assigned to other functors (like <code class="computeroutput">boost::function</code>)
- and they cannot be passed as template parameters. <sup>[<a name="id900110" href="#ftn.id900110" class="footnote">18</a>]</sup> On C++0x compilers, <code class="computeroutput"><span class="keyword">inline</span></code>
+ On ISO C++ compliant compilers, inlined local functions always have a run-time
+ comparable to their equivalent implementation that uses local functors (see
+ the <a class="link" href="Alternatives.html" title="Appendix: Alternatives">Alternatives</a> section).
+ However, inlined local functions have the limitation that they cannot be
+ assigned to other functors (like <code class="computeroutput">boost::function</code>)
+ and they cannot be passed as template parameters. <sup>[<a name="id903847" href="#ftn.id903847" class="footnote">18</a>]</sup> On C++0x compilers, <code class="computeroutput"><span class="keyword">inline</span></code>
         has no effect because this library will automatically generate code that
         uses C++0x specific features to inline the local function calls whenever
- possible even if the local function is not declared inlined. Furthermore,
- non C++0x local functions can always be passes as template parameters even
- when they are declared inlined.
+ possible even if the local function is not declared inlined (unless the
+ <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">BOOST_LOCAL_CONFIG_COMPLIANT</a></code>
+ configuration macro is defined). Furthermore, non C++0x local functions can
+ always be passes as template parameters even when they are declared inlined.
       </p>
 <div class="important"><table border="0" summary="Important">
 <tr>
@@ -1439,8 +1623,198 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Advanced_Topics.nested_declarations"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.nested_declarations" title="Nested Declarations">Nested
- Declarations</a>
+<a name="boost_local.Advanced_Topics.overloading_local_functions"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.overloading_local_functions" title="Overloading Local Functions">Overloading
+ Local Functions</a>
+</h3></div></div></div>
+<p>
+ It is possible to overload local functions by creating a <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor that aggregates together calls to different local functions with
+ different signatures. Note that the header file <code class="computeroutput"><span class="string">"boost/local/function/overload.hpp"</span></code>
+ needs to be included when using the <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor.
+ </p>
+<p>
+ In the following example, the overloaded functor <code class="computeroutput"><span class="identifier">print</span></code>
+ can be called with signatures from either the local function <code class="computeroutput"><span class="identifier">print_string</span></code>, or the local function <code class="computeroutput"><span class="identifier">print_double</span></code>, or the local function <code class="computeroutput"><span class="identifier">print_double</span></code> with the extra default parameter
+ <code class="computeroutput"><span class="identifier">name</span></code>, or the function pointer
+ <code class="computeroutput"><span class="identifier">print_add</span></code>:
+ </p>
+<div class="informaltable"><table class="table">
+<colgroup>
+<col>
+<col>
+</colgroup>
+<thead><tr>
+<th>
+ <p>
+ Variadic Macro Syntax (C99 and later compilers)
+ </p>
+ </th>
+<th>
+ <p>
+ Sequencing Macro Syntax (all C++ compilers)
+ </p>
+ </th>
+</tr></thead>
+<tbody><tr>
+<td>
+ <p>
+
+</p>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">/</span><span class="identifier">overload</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span> <span class="comment">// Include header for overloading.</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">vector</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">algorithm</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">iostream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">string</span><span class="special">&gt;</span>
+
+<span class="keyword">int</span> <span class="identifier">print_add</span><span class="special">(</span><span class="keyword">int</span> <span class="identifier">x</span><span class="special">,</span> <span class="keyword">int</span> <span class="identifier">y</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">&lt;&lt;</span> <span class="identifier">x</span> <span class="special">&lt;&lt;</span> <span class="string">" + "</span> <span class="special">&lt;&lt;</span> <span class="identifier">y</span> <span class="special">&lt;&lt;</span> <span class="string">" = "</span><span class="special">;</span>
+ <span class="keyword">return</span> <span class="identifier">x</span> <span class="special">+</span> <span class="identifier">y</span><span class="special">;</span>
+<span class="special">}</span>
+
+<span class="keyword">int</span> <span class="identifier">main</span><span class="special">()</span> <span class="special">{</span>
+ <span class="keyword">char</span> <span class="identifier">end</span> <span class="special">=</span> <span class="char">'\n'</span><span class="special">;</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&amp;</span> <span class="identifier">item</span><span class="special">,</span>
+ <span class="keyword">const</span> <span class="identifier">bind</span><span class="special">&amp;</span> <span class="identifier">end</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">&lt;&lt;</span> <span class="identifier">item</span> <span class="special">&lt;&lt;</span> <span class="string">" (string)"</span> <span class="special">&lt;&lt;</span> <span class="identifier">end</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">print_string</span><span class="special">)</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;</span> <span class="identifier">item</span><span class="special">,</span>
+ <span class="keyword">const</span> <span class="keyword">char</span><span class="special">*</span> <span class="identifier">name</span><span class="special">,</span> <span class="keyword">default</span> <span class="string">" (double)"</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">bind</span><span class="special">&amp;</span> <span class="identifier">end</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">&lt;&lt;</span> <span class="identifier">item</span> <span class="special">&lt;&lt;</span> <span class="identifier">name</span> <span class="special">&lt;&lt;</span> <span class="identifier">end</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">print_double</span><span class="special">)</span>
+
+ <span class="identifier">boost</span><span class="special">::</span><span class="identifier">local</span><span class="special">::</span><span class="identifier">function</span><span class="special">::</span><span class="identifier">overload</span><span class="special">&lt;</span>
+ <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&amp;)</span>
+ <span class="special">,</span> <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;)</span> <span class="comment">// Overload 1st param type.</span>
+ <span class="special">,</span> <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;,</span> <span class="keyword">const</span> <span class="keyword">char</span><span class="special">*)</span> <span class="comment">// Overload giving default param.</span>
+ <span class="special">,</span> <span class="keyword">int</span> <span class="special">(</span><span class="keyword">int</span><span class="special">,</span> <span class="keyword">int</span><span class="special">)</span> <span class="comment">// Overload giving 2 params (from function pointer).</span>
+ <span class="special">&gt;</span> <span class="identifier">print</span><span class="special">(</span><span class="identifier">print_string</span><span class="special">,</span> <span class="identifier">print_double</span><span class="special">,</span> <span class="identifier">print_double</span><span class="special">,</span> <span class="identifier">print_add</span><span class="special">);</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&gt;</span> <span class="identifier">s</span><span class="special">(</span><span class="number">3</span><span class="special">);</span>
+ <span class="identifier">s</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="string">"ab"</span><span class="special">;</span> <span class="identifier">s</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="string">"cd"</span><span class="special">;</span> <span class="identifier">s</span><span class="special">[</span><span class="number">2</span><span class="special">]</span> <span class="special">=</span> <span class="string">"ef"</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">s</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">print</span><span class="special">);</span> <span class="comment">// Call `print_string` 1-param.</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;</span> <span class="identifier">d</span><span class="special">(</span><span class="number">2</span><span class="special">);</span>
+ <span class="identifier">d</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="number">1.2</span><span class="special">;</span> <span class="identifier">d</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="number">3.4</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">d</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">d</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">print</span><span class="special">);</span> <span class="comment">// Call `print_double` 1-param.</span>
+
+ <span class="identifier">print</span><span class="special">(-</span><span class="number">1.234</span><span class="special">,</span> <span class="string">" (real)"</span><span class="special">);</span> <span class="comment">// Call `print_double` 2-params.</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">print</span><span class="special">(</span><span class="number">2</span><span class="special">,</span> <span class="number">3</span><span class="special">)</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span> <span class="comment">// Call `print_add`.</span>
+
+ <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+ </td>
+<td>
+ <p>
+
+</p>
+<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">/</span><span class="identifier">overload</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span> <span class="comment">// Include header for overloading.</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">local</span><span class="special">/</span><span class="identifier">function</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">vector</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">algorithm</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">iostream</span><span class="special">&gt;</span>
+<span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">string</span><span class="special">&gt;</span>
+
+<span class="keyword">int</span> <span class="identifier">print_add</span><span class="special">(</span><span class="keyword">int</span> <span class="identifier">x</span><span class="special">,</span> <span class="keyword">int</span> <span class="identifier">y</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">&lt;&lt;</span> <span class="identifier">x</span> <span class="special">&lt;&lt;</span> <span class="string">" + "</span> <span class="special">&lt;&lt;</span> <span class="identifier">y</span> <span class="special">&lt;&lt;</span> <span class="string">" = "</span><span class="special">;</span>
+ <span class="keyword">return</span> <span class="identifier">x</span> <span class="special">+</span> <span class="identifier">y</span><span class="special">;</span>
+<span class="special">}</span>
+
+<span class="keyword">int</span> <span class="identifier">main</span><span class="special">()</span> <span class="special">{</span>
+ <span class="keyword">char</span> <span class="identifier">end</span> <span class="special">=</span> <span class="char">'\n'</span><span class="special">;</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&amp;</span> <span class="identifier">item</span><span class="special">)</span>
+ <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">&amp;</span> <span class="identifier">end</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">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">item</span> <span class="special">&lt;&lt;</span> <span class="string">" (string)"</span> <span class="special">&lt;&lt;</span> <span class="identifier">end</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">print_string</span><span class="special">)</span>
+
+ <span class="keyword">void</span> <span class="identifier">BOOST_LOCAL_FUNCTION_PARAMS</span><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;</span> <span class="identifier">item</span><span class="special">)</span>
+ <span class="special">(</span><span class="keyword">const</span> <span class="keyword">char</span><span class="special">*</span> <span class="identifier">name</span><span class="special">)(</span><span class="keyword">default</span> <span class="string">" (double)"</span><span class="special">)</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span><span class="special">&amp;</span> <span class="identifier">end</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">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">item</span> <span class="special">&lt;&lt;</span> <span class="identifier">name</span> <span class="special">&lt;&lt;</span> <span class="identifier">end</span><span class="special">;</span>
+ <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">print_double</span><span class="special">)</span>
+
+ <span class="identifier">boost</span><span class="special">::</span><span class="identifier">local</span><span class="special">::</span><span class="identifier">function</span><span class="special">::</span><span class="identifier">overload</span><span class="special">&lt;</span>
+ <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&amp;)</span>
+ <span class="special">,</span> <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;)</span> <span class="comment">// Overload 1st param type.</span>
+ <span class="special">,</span> <span class="keyword">void</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;,</span> <span class="keyword">const</span> <span class="keyword">char</span><span class="special">*)</span> <span class="comment">// Overload giving default param.</span>
+ <span class="special">,</span> <span class="keyword">int</span> <span class="special">(</span><span class="keyword">int</span><span class="special">,</span> <span class="keyword">int</span><span class="special">)</span> <span class="comment">// Overload giving 2 params (from function pointer).</span>
+ <span class="special">&gt;</span> <span class="identifier">print</span><span class="special">(</span><span class="identifier">print_string</span><span class="special">,</span> <span class="identifier">print_double</span><span class="special">,</span> <span class="identifier">print_double</span><span class="special">,</span> <span class="identifier">print_add</span><span class="special">);</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">&gt;</span> <span class="identifier">s</span><span class="special">(</span><span class="number">3</span><span class="special">);</span>
+ <span class="identifier">s</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="string">"ab"</span><span class="special">;</span> <span class="identifier">s</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="string">"cd"</span><span class="special">;</span> <span class="identifier">s</span><span class="special">[</span><span class="number">2</span><span class="special">]</span> <span class="special">=</span> <span class="string">"ef"</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">s</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">s</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">print</span><span class="special">);</span> <span class="comment">// Call `print_string` 1-param.</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">&gt;</span> <span class="identifier">d</span><span class="special">(</span><span class="number">2</span><span class="special">);</span>
+ <span class="identifier">d</span><span class="special">[</span><span class="number">0</span><span class="special">]</span> <span class="special">=</span> <span class="number">1.2</span><span class="special">;</span> <span class="identifier">d</span><span class="special">[</span><span class="number">1</span><span class="special">]</span> <span class="special">=</span> <span class="number">3.4</span><span class="special">;</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">d</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">d</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">print</span><span class="special">);</span> <span class="comment">// Call `print_double` 1-param.</span>
+
+ <span class="identifier">print</span><span class="special">(-</span><span class="number">1.234</span><span class="special">,</span> <span class="string">" (real)"</span><span class="special">);</span> <span class="comment">// Call `print_double` 2-params.</span>
+
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">print</span><span class="special">(</span><span class="number">2</span><span class="special">,</span> <span class="number">3</span><span class="special">)</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span> <span class="comment">// Call `print_add`.</span>
+
+ <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
+<span class="special">}</span>
+</pre>
+<p>
+ </p>
+ </td>
+</tr></tbody>
+</table></div>
+<p>
+ The implementation of the <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor is equivalent to the following:
+ </p>
+<pre class="programlisting"><span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span> <span class="keyword">namespace</span> <span class="identifier">local</span> <span class="special">{</span> <span class="keyword">namespace</span> <span class="identifier">function</span> <span class="special">{</span>
+
+<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> <span class="identifier">F0</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">F1</span><span class="special">,</span> <span class="special">...&gt;</span>
+<span class="keyword">class</span> <span class="identifier">overload</span> <span class="special">{</span>
+<span class="keyword">public</span><span class="special">:</span>
+ <span class="identifier">overload</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span><span class="special">&lt;</span><span class="identifier">F0</span><span class="special">&gt;&amp;</span> <span class="identifier">f0</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span><span class="special">&lt;</span><span class="identifier">F1</span><span class="special">&gt;&amp;</span> <span class="identifier">f1</span><span class="special">,</span> <span class="special">...):</span>
+ <span class="identifier">f0_</span><span class="special">(</span><span class="identifier">f0</span><span class="special">),</span> <span class="identifier">f1_</span><span class="special">(</span><span class="identifier">f1</span><span class="special">),</span> <span class="special">...</span> <span class="special">{}</span>
+
+ <span class="identifier">result_type</span><span class="special">&lt;</span><span class="identifier">F0</span><span class="special">&gt;</span> <span class="keyword">operator</span><span class="special">()(</span><span class="identifier">arg0_type</span><span class="special">&lt;</span><span class="identifier">F0</span><span class="special">&gt;</span> <span class="identifier">a0</span><span class="special">,</span> <span class="identifier">arg1_type</span><span class="special">&lt;</span><span class="identifier">F0</span><span class="special">&gt;</span> <span class="identifier">a1</span><span class="special">,</span> <span class="special">...)</span> <span class="keyword">const</span> <span class="special">{</span>
+ <span class="keyword">return</span> <span class="identifier">f0_</span><span class="special">(</span><span class="identifier">a0</span><span class="special">,</span> <span class="identifier">a1</span><span class="special">,</span> <span class="special">...);</span>
+ <span class="special">}</span>
+ <span class="identifier">result_type</span><span class="special">&lt;</span><span class="identifier">F1</span><span class="special">&gt;</span> <span class="keyword">operator</span><span class="special">()(</span><span class="identifier">arg0_type</span><span class="special">&lt;</span><span class="identifier">F1</span><span class="special">&gt;</span> <span class="identifier">a0</span><span class="special">,</span> <span class="identifier">arg1_type</span><span class="special">&lt;</span><span class="identifier">F1</span><span class="special">&gt;</span> <span class="identifier">a1</span><span class="special">,</span> <span class="special">...)</span> <span class="keyword">const</span> <span class="special">{</span>
+ <span class="keyword">return</span> <span class="identifier">f1_</span><span class="special">(</span><span class="identifier">a0</span><span class="special">,</span> <span class="identifier">a1</span><span class="special">,</span> <span class="special">...);</span>
+ <span class="special">}</span>
+ <span class="special">...</span>
+
+<span class="keyword">private</span><span class="special">:</span>
+ <span class="keyword">const</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span><span class="special">&lt;</span><span class="identifier">F0</span><span class="special">&gt;</span> <span class="identifier">f0_</span><span class="special">;</span>
+ <span class="keyword">const</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span><span class="special">&lt;</span><span class="identifier">F1</span><span class="special">&gt;</span> <span class="identifier">f1_</span><span class="special">;</span>
+ <span class="special">...</span>
+<span class="special">};</span>
+
+<span class="special">}}}</span> <span class="comment">// namespace boost::local::function</span>
+</pre>
+<p>
+ A <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor can be constructed from any function type that can be converted to
+ a <code class="computeroutput">boost::function</code>
+ type (i.e., local functions but also function pointers and other function
+ objects). <sup>[<a name="id912742" href="#ftn.id912742" class="footnote">19</a>]</sup> The <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor provides overloaded call operators <code class="computeroutput"><span class="keyword">operator</span><span class="special">()</span></code> that match the signatures of all the specified
+ function types.
+ </p>
+<p>
+ The maximum number of function types that can be specified for overloading
+ is controlled at compile-time by the configuration macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html" title="Macro BOOST_LOCAL_CONFIG_OVERLOAD_MAX">BOOST_LOCAL_CONFIG_OVERLOAD_MAX</a></code>.
+ The maximum number of parameters that can be passed to each of the overloaded
+ function type is controlled at compile-time by the configuration macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html" title="Macro BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX">BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX</a></code>.
+ </p>
+</div>
+<div class="section">
+<div class="titlepage"><div><div><h3 class="title">
+<a name="boost_local.Advanced_Topics.nesting_local_constructs"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.nesting_local_constructs" title="Nesting Local Constructs">Nesting
+ Local Constructs</a>
 </h3></div></div></div>
 <p>
         It is possible to nest local function, local block, and local exit declarations
@@ -1706,7 +2080,7 @@
 <p>
         Local function parameters support the storage classifiers as usual in ISO
         C++. The <code class="computeroutput"><span class="keyword">auto</span></code> storage classifier
- is specified as: <sup>[<a name="id908921" href="#ftn.id908921" class="footnote">19</a>]</sup>
+ is specified as: <sup>[<a name="id917355" href="#ftn.id917355" class="footnote">20</a>]</sup>
       </p>
 <pre class="programlisting"><span class="keyword">auto</span> <span class="emphasis"><em>parameter-type parameter-name</em></span>
 </pre>
@@ -1782,8 +2156,8 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__overloading__operators__etc_" title="Limitations (overloading, operators, etc)">Limitations
- (overloading, operators, etc)</a>
+<a name="boost_local.Advanced_Topics.limitations__operators__etc_"></a><a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__operators__etc_" title="Limitations (operators, etc)">Limitations
+ (operators, etc)</a>
 </h3></div></div></div>
 <p>
         The following table summarizes all C++ function features indicating those
@@ -1936,7 +2310,7 @@
 <td>
                 <p>
                   This is not supported because local functions are not member functions.
- <sup>[<a name="id910174" href="#ftn.id910174" class="footnote">a</a>]</sup>
+ <sup>[<a name="id918607" href="#ftn.id918607" class="footnote">a</a>]</sup>
                 </p>
               </td>
 </tr>
@@ -2035,7 +2409,7 @@
               </td>
 </tr>
 </tbody>
-<tbody class="footnotes"><tr><td colspan="3"><div class="footnote"><p><sup>[<a id="ftn.id910174" href="#id910174" class="para">a</a>] </sup>
+<tbody class="footnotes"><tr><td colspan="3"><div class="footnote"><p><sup>[<a id="ftn.id918607" href="#id918607" class="para">a</a>] </sup>
                     <span class="bold"><strong>Rationale.</strong></span> In theory, it would
                     be possible for a local functor class to inherit from another
                     local functor class. However, this "inheritance" feature
@@ -2045,39 +2419,13 @@
                     to dynamic binding or base function call.
                   </p></div></td></tr></tbody>
 </table></div>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.overloading"></a><h6>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.overloading-heading"></a>
- <a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__overloading__operators__etc_.overloading">Overloading</a>
- </h6>
-<p>
- It is not possible to overload local functions. Declaring multiple local
- functions with the same name within the same enclosing scope generates a
- compile-time error (even if the different declarations specify different
- parameters). <sup>[<a name="id910511" href="#ftn.id910511" class="footnote">20</a>]</sup>
- </p>
-<p>
- For example, the following code will <span class="bold"><strong>not</strong></span>
- compile:
- </p>
-<pre class="programlisting"><span class="keyword">void</span> <span class="identifier">f</span><span class="special">()</span> <span class="special">{</span>
- <span class="keyword">void</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">int</span><span class="special">&amp;</span> <span class="identifier">i</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span>
- <span class="special">...</span>
- <span class="special">}</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="identifier">l</span><span class="special">)</span>
-
- <span class="keyword">void</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="keyword">double</span><span class="special">&amp;</span> <span class="identifier">d</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span>
- <span class="special">...</span>
- <span class="special">}</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="identifier">l</span><span class="special">)</span> <span class="comment">// Error: Cannot overload.</span>
-
- <span class="special">...</span>
-<span class="special">}</span>
-</pre>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.operators"></a><h6>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.operators-heading"></a>
- <a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__overloading__operators__etc_.operators">Operators</a>
+<a name="boost_local.Advanced_Topics.limitations__operators__etc_.operators"></a><h6>
+<a name="boost_local.Advanced_Topics.limitations__operators__etc_.operators-heading"></a>
+ <a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__operators__etc_.operators">Operators</a>
       </h6>
 <p>
         Local functions cannot be operators. Naming a local function <code class="computeroutput"><span class="keyword">operator</span><span class="special">...</span></code>
- will generate a compile-time error. <sup>[<a name="id910853" href="#ftn.id910853" class="footnote">21</a>]</sup>
+ will generate a compile-time error. <sup>[<a name="id918953" href="#ftn.id918953" class="footnote">21</a>]</sup>
       </p>
 <p>
         For example, the following code will <span class="bold"><strong>not</strong></span>
@@ -2092,14 +2440,14 @@
     <span class="keyword">bool</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code><span class="special">(</span>
             <span class="special">(</span><span class="keyword">const</span> <span class="identifier">point</span><span class="special">&amp;</span> <span class="identifier">p</span><span class="special">)</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">point</span><span class="special">&amp;</span> <span class="identifier">q</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span>
         <span class="keyword">return</span> <span class="identifier">p</span><span class="special">.</span><span class="identifier">x</span> <span class="special">==</span> <span class="identifier">q</span><span class="special">.</span><span class="identifier">x</span> <span class="special">&amp;&amp;</span> <span class="identifier">p</span><span class="special">.</span><span class="identifier">y</span> <span class="special">==</span> <span class="identifier">q</span><span class="special">.</span><span class="identifier">y</span><span class="special">;</span>
- <span class="special">)</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="keyword">operator</span><span class="special">==)</span> <span class="comment">// Error: Cannot be `operator==`.</span>
+ <span class="special">)</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="keyword">operator</span><span class="special">==)</span> <span class="comment">// Error: Cannot use `operator==`.</span>
 
     <span class="special">...</span>
 <span class="special">}</span>
 </pre>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.goto"></a><h6>
-<a name="boost_local.Advanced_Topics.limitations__overloading__operators__etc_.goto-heading"></a>
- <a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__overloading__operators__etc_.goto">Goto</a>
+<a name="boost_local.Advanced_Topics.limitations__operators__etc_.goto"></a><h6>
+<a name="boost_local.Advanced_Topics.limitations__operators__etc_.goto-heading"></a>
+ <a class="link" href="Advanced_Topics.html#boost_local.Advanced_Topics.limitations__operators__etc_.goto">Goto</a>
       </h6>
 <p>
         It is not possible to jump with a <code class="computeroutput"><span class="keyword">goto</span></code>
@@ -2111,34 +2459,39 @@
       </p>
 <pre class="programlisting"><span class="keyword">int</span> <span class="identifier">f</span><span class="special">()</span> <span class="special">{</span>
     <span class="keyword">void</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code><span class="special">(</span> <span class="special">(</span><span class="identifier">boost</span> <span class="identifier">error</span><span class="special">)</span> <span class="special">)</span> <span class="special">{</span>
- <span class="keyword">if</span> <span class="special">(</span><span class="identifier">error</span><span class="special">)</span> <span class="keyword">goto</span> <span class="identifier">failure</span><span class="special">;</span> <span class="comment">// Error: Cannot jump to enclosing label `failure`.</span>
+ <span class="keyword">if</span> <span class="special">(</span><span class="identifier">error</span><span class="special">)</span> <span class="keyword">goto</span> <span class="identifier">failure</span><span class="special">;</span> <span class="comment">// Error: Cannot jump to enclosing label `failure`.</span>
+ <span class="keyword">else</span> <span class="keyword">goto</span> <span class="identifier">success</span><span class="special">;</span> <span class="comment">// Ok: Can jump within enclosing scope.</span>
+
+ <span class="identifier">success</span><span class="special">:</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="string">"done"</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
     <span class="special">}</span> <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code><span class="special">(</span><span class="identifier">l</span><span class="special">)</span>
 
     <span class="identifier">l</span><span class="special">(</span><span class="keyword">true</span><span class="special">);</span>
 
     <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
 <span class="identifier">failure</span><span class="special">:</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="string">"error"</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
     <span class="keyword">return</span> <span class="special">-</span><span class="number">1</span><span class="special">;</span>
 <span class="special">}</span>
 </pre>
 </div>
 <div class="footnotes">
 <br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a id="ftn.id881643" href="#id881643" class="para">16</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id881800" href="#id881800" class="para">16</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> This limitation derives from
           the fact that <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS">BOOST_LOCAL_FUNCTION_PARAMS</a></code>
           uses preprocessor token concatenation to inspect the parameter type token
           to see if the token is a parameter or a bound variable. The C++ preprocessor
           does not allow to concatenate non-alphanumeric tokens.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id883080" href="#id883080" class="para">17</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id883236" href="#id883236" class="para">17</a>] </sup>
               <span class="bold"><strong>Rationale.</strong></span> Using variadic macros,
               this extra set of parenthesis could be eliminated requiring only the
               parenthesis to invoke the <code class="computeroutput"><a class="link" href="../BOOST_IDENTITY_TYPE.html" title="Macro BOOST_IDENTITY_TYPE">BOOST_IDENTITY_TYPE</a></code>
               macro. However, this feature is currently not implemented and the double
               parenthesis are always needed when invoking this macro.
             </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id900110" href="#id900110" class="para">18</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id903847" href="#id903847" class="para">18</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> This library uses an indirect
           function call via a function pointer in order to pass the local function
           as a template parameter (see the <a class="link" href="Implementation.html" title="Appendix: Implementation">Implementation</a>
@@ -2152,7 +2505,15 @@
           be inlined on C++0x compilers (even when the local function is not declared
           inlined).
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id908921" href="#id908921" class="para">19</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id912742" href="#id912742" class="para">19</a>] </sup>
+ The <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ functor can aggregate any functor and it is not at all specific to local
+ functions. Therefore, it might be preferable to move <code class="computeroutput"><a class="link" href="../boost/local/function/overload.html" title="Class template overload">boost::local::function::overload</a></code>
+ from Boost.Local
+ to Boost.Function
+ and to rename it as <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">function</span><span class="special">::</span><span class="identifier">overload</span></code>.
+ </p></div>
+<div class="footnote"><p><sup>[<a id="ftn.id917355" href="#id917355" class="para">20</a>] </sup>
           The <code class="computeroutput"><span class="keyword">auto</span></code> storage classifier
           is part of the ISO C++ standard and therefore supported by this library.
           However, the meaning and usage of the <code class="computeroutput"><span class="keyword">auto</span></code>
@@ -2160,14 +2521,7 @@
           storage classifier with the usual care in order to avoid writing ISO C++
           code that might not work on C++0x.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id910511" href="#id910511" class="para">20</a>] </sup>
- <span class="bold"><strong>Rationale.</strong></span> This is because a local function
- is a functor declared as a local variable within the enclosing scope. Therefore,
- declaring two local functions with the same name within the same enclosing
- scope declares two local variables with the same name within the same scope
- and that is not allowed in C++.
- </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id910853" href="#id910853" class="para">21</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id918953" href="#id918953" class="para">21</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> This is the because a local
           function name must be a valid local variable name (the local variable to
           hold the local functor) and operators cannot be used as local variable

Modified: sandbox/local/libs/local/doc/html/boost_local/Getting_Started.html
==============================================================================
--- sandbox/local/libs/local/doc/html/boost_local/Getting_Started.html (original)
+++ sandbox/local/libs/local/doc/html/boost_local/Getting_Started.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -122,7 +122,7 @@
 </pre>
 <p>
         The followings are part of the library private API, they are not documented,
- and they should not be directly used by programmers: <sup>[<a name="id866165" href="#ftn.id866165" class="footnote">2</a>]</sup>
+ and they should not be directly used by programmers: <sup>[<a name="id866222" href="#ftn.id866222" class="footnote">2</a>]</sup>
       </p>
 <div class="itemizedlist"><ul class="itemizedlist" type="disc">
 <li class="listitem">
@@ -160,7 +160,7 @@
 </div>
 <div class="footnotes">
 <br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a id="ftn.id866165" href="#id866165" class="para">2</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id866222" href="#id866222" class="para">2</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> This library concatenates symbols
           specified by the programmers (e.g., the local function name) with other
           symbols (e.g., special prefixes or preprocessor line numbers) to make internal

Modified: sandbox/local/libs/local/doc/html/boost_local/Release_Notes.html
==============================================================================
--- sandbox/local/libs/local/doc/html/boost_local/Release_Notes.html (original)
+++ sandbox/local/libs/local/doc/html/boost_local/Release_Notes.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -27,14 +27,18 @@
 <a name="boost_local.Release_Notes"></a><a class="link" href="Release_Notes.html" title="Release Notes">Release Notes</a>
 </h2></div></div></div>
 <div class="toc"><dl>
-<dt><span class="section">Version 0.1.1</span></dt>
-<dt><span class="section">Version 0.1.0</span></dt>
-<dt><span class="section">Version 0.0.1</span></dt>
+<dt><span class="section"><a href="Release_Notes.html#boost_local.Release_Notes.version_0_1_1__2011_01_10_">Version
+ 0.1.1 (2011-01-10)</a></span></dt>
+<dt><span class="section"><a href="Release_Notes.html#boost_local.Release_Notes.version_0_1_0__2011_01_03_">Version
+ 0.1.0 (2011-01-03)</a></span></dt>
+<dt><span class="section"><a href="Release_Notes.html#boost_local.Release_Notes.version_0_0_1__2010_12_15_">Version
+ 0.0.1 (2010-12-15)</a></span></dt>
 <dt><span class="section">TODO</span></dt>
 </dl></div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Release_Notes.version_0_1_1"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_1_1" title="Version 0.1.1">Version 0.1.1</a>
+<a name="boost_local.Release_Notes.version_0_1_1__2011_01_10_"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_1_1__2011_01_10_" title="Version 0.1.1 (2011-01-10)">Version
+ 0.1.1 (2011-01-10)</a>
 </h3></div></div></div>
 <div class="orderedlist"><ol class="orderedlist" type="1">
 <li class="listitem">
@@ -50,7 +54,8 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Release_Notes.version_0_1_0"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_1_0" title="Version 0.1.0">Version 0.1.0</a>
+<a name="boost_local.Release_Notes.version_0_1_0__2011_01_03_"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_1_0__2011_01_03_" title="Version 0.1.0 (2011-01-03)">Version
+ 0.1.0 (2011-01-03)</a>
 </h3></div></div></div>
 <div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">
             Shared with Boost for first round of comments.
@@ -58,7 +63,8 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="boost_local.Release_Notes.version_0_0_1"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_0_1" title="Version 0.0.1">Version 0.0.1</a>
+<a name="boost_local.Release_Notes.version_0_0_1__2010_12_15_"></a><a class="link" href="Release_Notes.html#boost_local.Release_Notes.version_0_0_1__2010_12_15_" title="Version 0.0.1 (2010-12-15)">Version
+ 0.0.1 (2010-12-15)</a>
 </h3></div></div></div>
 <div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">
             Completed development, examples, and documentation.

Modified: sandbox/local/libs/local/doc/html/boost_local/Tutorial.html
==============================================================================
--- sandbox/local/libs/local/doc/html/boost_local/Tutorial.html (original)
+++ sandbox/local/libs/local/doc/html/boost_local/Tutorial.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -115,12 +115,12 @@
         <span class="special">...</span> <span class="special">}</span></code>
         using the usual C++ syntax. The body is specified outside any of the macros
         so eventual compiler error messages and related line numbers retain their
- usual meaning and format. <sup>[<a name="id866866" href="#ftn.id866866" class="footnote">3</a>]</sup>
+ usual meaning and format. <sup>[<a name="id866922" href="#ftn.id866922" class="footnote">3</a>]</sup>
       </p>
 <p>
         The macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code>
         is used to end the local function definition and to specify the local function
- name. <sup>[<a name="id866902" href="#ftn.id866902" class="footnote">4</a>]</sup>
+ name. <sup>[<a name="id866959" href="#ftn.id866959" class="footnote">4</a>]</sup>
       </p>
 <p>
         For example, let's program a local function named <code class="computeroutput"><span class="identifier">add</span></code>
@@ -187,6 +187,14 @@
               </td>
 </tr></tbody>
 </table></div>
+<p>
+ The maximum number of parameters that can be passed to a local function (excluding
+ eventual bound variables) is controlled at compile-time by the configuration
+ macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html" title="Macro BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX">BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX</a></code>.
+ The variadic macro syntax is always disabled when the configuration macro
+ <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">BOOST_LOCAL_CONFIG_COMPLIANT</a></code>
+ is defined.
+ </p>
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
@@ -355,7 +363,9 @@
 </table></div>
 <p>
         Note that not all compilers that support variadic macros also support empty
- macro parameters.
+ macro parameters. Both the empty macro syntax and variadic macro syntax are
+ always disabled when the configuration macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">BOOST_LOCAL_CONFIG_COMPLIANT</a></code>
+ is defined.
       </p>
 </div>
 <div class="section">
@@ -366,7 +376,7 @@
         This library also allows to specify default values for the local function
         parameters. However, the usual C++ syntax for default parameters that uses
         the assignment symbol <code class="computeroutput"><span class="special">=</span></code> cannot
- be used. <sup>[<a name="id868966" href="#ftn.id868966" class="footnote">5</a>]</sup> The keyword <code class="computeroutput"><span class="keyword">default</span></code>
+ be used. <sup>[<a name="id869072" href="#ftn.id869072" class="footnote">5</a>]</sup> The keyword <code class="computeroutput"><span class="keyword">default</span></code>
         is used instead:
       </p>
 <div class="informaltable"><table class="table">
@@ -508,7 +518,7 @@
         variables, the object <code class="computeroutput"><span class="keyword">this</span></code>,
         etc) can be bound to a local function declaration. The types of bound variables
         are automatically deduced by this library using Boost.Typeof.
- <sup>[<a name="id870490" href="#ftn.id870490" class="footnote">6</a>]</sup>
+ <sup>[<a name="id870459" href="#ftn.id870459" class="footnote">6</a>]</sup>
       </p>
 <div class="important"><table border="0" summary="Important">
 <tr>
@@ -525,7 +535,7 @@
 </table></div>
 <p>
         This library introduces the new "keyword" <code class="computeroutput"><span class="identifier">bind</span></code>
- <sup>[<a name="id870572" href="#ftn.id870572" class="footnote">7</a>]</sup> which is used in place of the parameter type to specify the name
+ <sup>[<a name="id870541" href="#ftn.id870541" class="footnote">7</a>]</sup> which is used in place of the parameter type to specify the name
         of a variable in scope to bind. The variable can be bound by value:
       </p>
 <pre class="programlisting"><span class="identifier">bind</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by value.</span>
@@ -540,7 +550,7 @@
         can be prefixed by <code class="computeroutput"><span class="keyword">const</span></code> to
         bind the variable by constant value:
       </p>
-<pre class="programlisting"><span class="keyword">const</span> <span class="identifier">bind</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by value.</span>
+<pre class="programlisting"><span class="keyword">const</span> <span class="identifier">bind</span> <span class="emphasis"><em>variable-name</em></span> <span class="comment">// Bind by constant value.</span>
 </pre>
 <p>
         Or by constant reference:
@@ -571,7 +581,7 @@
         variable was not declared constant in the enclosing scope then it will not
         be bound as constant unless constant binding is forced using <code class="computeroutput"><span class="keyword">const</span> <span class="identifier">bind</span> <span class="special">...</span></code> (note that binding by constant reference
         is not supported by <a href="http://en.wikipedia.org/wiki/C%2B%2B0x#Lambda_functions_and_expressions" target="_top">C++0x
- lambda</a> functions but it is supported by this library). <sup>[<a name="id870878" href="#ftn.id870878" class="footnote">8</a>]</sup> As with passing parameters to usual C++ functions, programmers
+ lambda</a> functions but it is supported by this library). <sup>[<a name="id870847" href="#ftn.id870847" class="footnote">8</a>]</sup> As with passing parameters to usual C++ functions, programmers
         might want to bind variables of complex types by (constant) reference instead
         than by value to avoid expensive copy operations when these variables are
         bound to a local function.
@@ -661,7 +671,7 @@
         when it is in scope (e.g., from an enclosing member function). This is done
         by using <code class="computeroutput"><span class="keyword">this</span></code> as the name of
         the variable to bind in the local function declaration and by using the special
- symbol <code class="computeroutput"><span class="identifier">this_</span></code> <sup>[<a name="id871947" href="#ftn.id871947" class="footnote">9</a>]</sup> (instead of <code class="computeroutput"><span class="keyword">this</span></code>)
+ symbol <code class="computeroutput"><span class="identifier">this_</span></code> <sup>[<a name="id871910" href="#ftn.id871910" class="footnote">9</a>]</sup> (instead of <code class="computeroutput"><span class="keyword">this</span></code>)
         to access the object within the local function body.
       </p>
 <p>
@@ -704,12 +714,12 @@
 <p>
           When the object <code class="computeroutput"><span class="keyword">this</span></code> is bound
           to a local function, the local function body must use the special symbol
- <code class="computeroutput"><span class="identifier">this_</span></code> (instead of <code class="computeroutput"><span class="keyword">this</span></code>) to access the bound object. <sup>[<a name="id872256" href="#ftn.id872256" class="footnote">10</a>]</sup>
+ <code class="computeroutput"><span class="identifier">this_</span></code> (instead of <code class="computeroutput"><span class="keyword">this</span></code>) to access the bound object. <sup>[<a name="id872220" href="#ftn.id872220" class="footnote">10</a>]</sup>
         </p>
 <p>
           Unfortunately, mistakenly using <code class="computeroutput"><span class="keyword">this</span></code>
           within the local function body instead of <code class="computeroutput"><span class="identifier">this_</span></code>
- will not necessarily generate a compile-time error. <sup>[<a name="id872349" href="#ftn.id872349" class="footnote">11</a>]</sup> Programmers are responsible to make sure that <code class="computeroutput"><span class="keyword">this</span></code> is never used within a local function
+ will not necessarily generate a compile-time error. <sup>[<a name="id872314" href="#ftn.id872314" class="footnote">11</a>]</sup> Programmers are responsible to make sure that <code class="computeroutput"><span class="keyword">this</span></code> is never used within a local function
           body which should only use the special symbol <code class="computeroutput"><span class="identifier">this_</span></code>.
         </p>
 </td></tr>
@@ -760,6 +770,7 @@
             <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">+=</span> <span class="identifier">factor</span> <span class="special">*</span> <span class="identifier">num</span><span class="special">;</span> <span class="comment">// Use `this_` instead of `this`.</span>
             <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="string">"Summed: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
         <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">add</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
 
         <span class="identifier">BOOST_LOCAL_EXIT</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span> <span class="keyword">this</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">&lt;&lt;</span> <span class="string">"Exiting: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
@@ -770,7 +781,6 @@
             <span class="identifier">assert</span><span class="special">(</span><span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&gt;</span> <span class="number">0.0</span><span class="special">);</span>
         <span class="special">}</span> <span class="identifier">BOOST_LOCAL_BLOCK_END</span>
 
- <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
         <span class="keyword">return</span> <span class="identifier">sum_</span><span class="special">;</span>
     <span class="special">}</span>
 
@@ -814,6 +824,7 @@
             <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">+=</span> <span class="identifier">factor</span> <span class="special">*</span> <span class="identifier">num</span><span class="special">;</span> <span class="comment">// Use `this_` instead of `this`.</span>
             <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="string">"Summed: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
         <span class="special">}</span> <span class="identifier">BOOST_LOCAL_FUNCTION_NAME</span><span class="special">(</span><span class="identifier">add</span><span class="special">)</span>
+ <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
 
         <span class="identifier">BOOST_LOCAL_EXIT</span><span class="special">(</span> <span class="special">(</span><span class="keyword">const</span> <span class="identifier">bind</span> <span class="keyword">this</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">cout</span> <span class="special">&lt;&lt;</span> <span class="string">"Exiting: "</span> <span class="special">&lt;&lt;</span> <span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
@@ -824,7 +835,6 @@
             <span class="identifier">assert</span><span class="special">(</span><span class="identifier">this_</span><span class="special">-&gt;</span><span class="identifier">sum_</span> <span class="special">&gt;</span> <span class="number">0.0</span><span class="special">);</span>
         <span class="special">}</span> <span class="identifier">BOOST_LOCAL_BLOCK_END</span>
 
- <span class="identifier">std</span><span class="special">::</span><span class="identifier">for_each</span><span class="special">(</span><span class="identifier">nums</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">nums</span><span class="special">.</span><span class="identifier">end</span><span class="special">(),</span> <span class="identifier">add</span><span class="special">);</span>
         <span class="keyword">return</span> <span class="identifier">sum_</span><span class="special">;</span>
     <span class="special">}</span>
 
@@ -848,6 +858,11 @@
               </td>
 </tr></tbody>
 </table></div>
+<p>
+ The special name <code class="computeroutput"><span class="identifier">this_</span></code> used
+ to replace the bound object name <code class="computeroutput"><span class="keyword">this</span></code>
+ is controlled at compile-time by the configuration macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html" title="Macro BOOST_LOCAL_CONFIG_THIS_PARAM_NAME">BOOST_LOCAL_CONFIG_THIS_PARAM_NAME</a></code>.
+ </p>
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
@@ -891,7 +906,7 @@
 <tr><td align="left" valign="top"><p>
           A <code class="computeroutput"><span class="keyword">return</span><span class="special">;</span></code>
           instruction from within a local block jumps to the end of the local block
- body and it does not return the enclosing function. <sup>[<a name="id875690" href="#ftn.id875690" class="footnote">12</a>]</sup>
+ body and it does not return the enclosing function. <sup>[<a name="id875710" href="#ftn.id875710" class="footnote">12</a>]</sup>
         </p></td></tr>
 </table></div>
 <p>
@@ -1003,7 +1018,7 @@
 </tr>
 <tr><td align="left" valign="top"><p>
           The execution of the local exit body code is guaranteed only if the program
- does not terminate because of an uncaught exception. <sup>[<a name="id876927" href="#ftn.id876927" class="footnote">13</a>]</sup>
+ does not terminate because of an uncaught exception. <sup>[<a name="id876947" href="#ftn.id876947" class="footnote">13</a>]</sup>
         </p></td></tr>
 </table></div>
 <p>
@@ -1108,7 +1123,7 @@
         Local exits are very similar to the <span class="emphasis"><em>scope exits</em></span> provided
         by Boost.ScopeExit
         with the addition that they also support constant binding and binding of
- the object <code class="computeroutput"><span class="keyword">this</span></code>. <sup>[<a name="id878208" href="#ftn.id878208" class="footnote">14</a>]</sup> Local exits can be used to emulate the <a href="http://d.digitalmars.com" target="_top">D
+ the object <code class="computeroutput"><span class="keyword">this</span></code>. <sup>[<a name="id878365" href="#ftn.id878365" class="footnote">14</a>]</sup> Local exits can be used to emulate the <a href="http://d.digitalmars.com" target="_top">D
         Programming Language</a> <span class="emphasis"><em>scope guards</em></span> (see the
         <a class="link" href="Examples.html#boost_local.Examples.Emulating_Ds_Scope_Guards" title="Emulating D's Scope Guards">Emulating
         D's Scope Guards</a> example).
@@ -1122,7 +1137,7 @@
         When local functions, local blocks, and local exits are programmed within
         templates, they need to be declared using the following special macros ending
         with the <code class="computeroutput"><span class="identifier">TPL</span></code> postfix (see
- the Reference section): <sup>[<a name="id878504" href="#ftn.id878504" class="footnote">15</a>]</sup>
+ the Reference section): <sup>[<a name="id878661" href="#ftn.id878661" class="footnote">15</a>]</sup>
       </p>
 <pre class="programlisting"><code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_PARAMS_TPL.html" title="Macro BOOST_LOCAL_FUNCTION_PARAMS_TPL">BOOST_LOCAL_FUNCTION_PARAMS_TPL</a></code><span class="special">(</span><span class="emphasis"><em>parameters</em></span><span class="special">)</span>
 <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_BLOCK_TPL.html" title="Macro BOOST_LOCAL_BLOCK_TPL">BOOST_LOCAL_BLOCK_TPL</a></code><span class="special">(</span><span class="emphasis"><em>bindings</em></span><span class="special">)</span>
@@ -1257,20 +1272,20 @@
 </div>
 <div class="footnotes">
 <br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a id="ftn.id866866" href="#id866866" class="para">3</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id866922" href="#id866922" class="para">3</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> If the local function body
           were instead passed as a macro parameter, it would be expanded on a single
           line of code (because macros always expand as a single line of code). Therefore,
           eventual compiler error line numbers would all report the same value and
           would no longer be useful to pinpoint the error.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id866902" href="#id866902" class="para">4</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id866959" href="#id866959" class="para">4</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> The local function name must
           be passed to the macro <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code>
           ending the function definition so this macro can declare a local variable
           with the local function name to hold the local function object.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id868966" href="#id868966" class="para">5</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id869072" href="#id869072" class="para">5</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> The assignment symbol <code class="computeroutput"><span class="special">=</span></code> cannot be used to specify default parameter
           values because default values are not part of the parameter type so they
           cannot be handled using template metaprogamming. Default parameter values
@@ -1283,7 +1298,7 @@
           symbol cannot be detected by preprocessor metaprogramming because it cannot
           be concatenated by the preprocessor).
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id870490" href="#id870490" class="para">6</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id870459" href="#id870459" class="para">6</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> By binding a variable in scope,
           the local function declaration is specifying that such a variable should
           be accessible within the local function body regardless of its type. Semantically,
@@ -1296,7 +1311,7 @@
           For example, this is useful for maintenance because if a bound variable
           type is changed, the local function declaration does not have to change.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id870572" href="#id870572" class="para">7</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id870541" href="#id870541" class="para">7</a>] </sup>
           Obviously, the token <code class="computeroutput"><span class="identifier">bind</span></code>
           is not a keyword of the C++ language. This library parses the token <code class="computeroutput"><span class="identifier">bind</span></code> during macro expansion using preprocessor
           metaprogramming (see the <a class="link" href="Implementation.html" title="Appendix: Implementation">Implementation</a>
@@ -1305,7 +1320,7 @@
           level within the syntax defined by the macros of this library -- thus it
           is referred to as a "keyword" only within quotes.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id870878" href="#id870878" class="para">8</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id870847" href="#id870847" class="para">8</a>] </sup>
           An historical note: Constant binding of variables in scope was the main
           use case that originally motivated the authors in developing this library.
           The authors needed to locally create a chuck of code to assert some correctness
@@ -1320,13 +1335,13 @@
           generates an error because the bound variable is of <code class="computeroutput"><span class="keyword">const</span></code>
           type within the local function body.
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id871947" href="#id871947" class="para">9</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id871910" href="#id871910" class="para">9</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> The special name <code class="computeroutput"><span class="identifier">this_</span></code> was chosen following <a href="http://boost.2283326.n4.nabble.com/local-this-or-this-td3423912.html" target="_top">Boost
           practises</a> which postfix with an underscore identifiers that are
           named after keywords (the C++ keyword <code class="computeroutput"><span class="keyword">this</span></code>
           in this case).
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id872256" href="#id872256" class="para">10</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id872220" href="#id872220" class="para">10</a>] </sup>
             <span class="bold"><strong>Rationale.</strong></span> This limitation comes from
             the fact that <code class="computeroutput"><span class="keyword">this</span></code> is a
             reserved C++ keyword so it cannot be used as the name of the internal
@@ -1340,7 +1355,7 @@
             behaviour of <code class="computeroutput"><span class="keyword">static_cast</span></code></a>
             (which might not work on all platforms at the cost of portability).
           </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id872349" href="#id872349" class="para">11</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id872314" href="#id872314" class="para">11</a>] </sup>
             <span class="bold"><strong>Rationale.</strong></span> The local function body cannot
             be a static member function of the local functor object in order to support
             recursion (because the local function name is specified by the <code class="computeroutput"><a class="link" href="../BOOST_LOCAL_FUNCTION_NAME.html" title="Macro BOOST_LOCAL_FUNCTION_NAME">BOOST_LOCAL_FUNCTION_NAME</a></code>
@@ -1353,7 +1368,7 @@
             Therefore, from within the local function body the variable <code class="computeroutput"><span class="keyword">this</span></code> is visible but it refers to the local
             functor and not to the bound object.
           </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id875690" href="#id875690" class="para">12</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id875710" href="#id875710" class="para">12</a>] </sup>
             <span class="bold"><strong>Rationale.</strong></span> Programmers might expect
             <code class="computeroutput"><span class="keyword">return</span><span class="special">;</span></code>
             to exit the enclosing function instead of the local block (or local exit),
@@ -1371,7 +1386,7 @@
             <code class="computeroutput"><span class="identifier">BOOST_LOCAL_RETURN</span><span class="special">;</span></code>)
             to exit local blocks (and local exits).
           </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id876927" href="#id876927" class="para">13</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id876947" href="#id876947" class="para">13</a>] </sup>
             <span class="bold"><strong>Rationale.</strong></span> This library (as well as
             <a href="http://www.boost.org/doc/libs/release/libs/scope_exit/doc/html/index.html" target="_top">Boost.ScopeExit</a>)
             uses the destructor of a local variable to automatically execute the
@@ -1382,7 +1397,7 @@
             scope exit code even if the main program terminates because of an uncaught
             exception.)
           </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id878208" href="#id878208" class="para">14</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id878365" href="#id878365" class="para">14</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> This library could be merged
           together with Boost.ScopeExit
           into a new library named Boost.Scope (from the meaning of the word "scope"
@@ -1411,7 +1426,7 @@
           name of "<a href="http://gcc.gnu.org/onlinedocs/gcc/Nested-Functions.html" target="_top">nested
           functions</a>" (GCC compiler extension).
         </p></div>
-<div class="footnote"><p><sup>[<a id="ftn.id878504" href="#id878504" class="para">15</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id878661" href="#id878661" class="para">15</a>] </sup>
           <span class="bold"><strong>Rationale.</strong></span> Within templates, this library
           needs to use <code class="computeroutput"><span class="keyword">typename</span></code> to explicitly
           indicate that some expressions evaluate to a type. Because C++ does not

Modified: sandbox/local/libs/local/doc/html/index.html
==============================================================================
--- sandbox/local/libs/local/doc/html/index.html (original)
+++ sandbox/local/libs/local/doc/html/index.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -27,7 +27,7 @@
 </h3></div></div></div>
 <div><p class="copyright">Copyright &#169; 2009-2011 Lorenzo Caminiti</p></div>
 <div><div class="legalnotice">
-<a name="id808762"></a><p>
+<a name="id863775"></a><p>
         Use, modification, and distribution is subject to the Boost Software License,
         Version 1.0 (see accompanying file LICENSE_1_0.txt or a copy at http://www.boost.org/LICENSE_1_0.txt).
       </p>
@@ -344,7 +344,7 @@
           by reference, by constant value, and by constant reference. In addition,
           the object <code class="computeroutput"><span class="keyword">this</span></code> can be bound
           (eventually by constant value but never by reference or constant reference
- <sup>[<a name="id865420" href="#ftn.id865420" class="footnote">1</a>]</sup> ) from within a non-static member function (see the <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a>
+ <sup>[<a name="id865478" href="#ftn.id865478" class="footnote">1</a>]</sup> ) from within a non-static member function (see the <a class="link" href="boost_local/Tutorial.html" title="Tutorial">Tutorial</a>
           section). For example, the variable <code class="computeroutput"><span class="identifier">factor</span></code>
           is bound by constant value so it cannot be mistakenly modified by the local
           function body. The variable <code class="computeroutput"><span class="identifier">sum</span></code>
@@ -420,13 +420,13 @@
 </div>
 <div class="footnotes">
 <br><hr width="100" align="left">
-<div class="footnote"><p><sup>[<a id="ftn.id865420" href="#id865420" class="para">1</a>] </sup>
+<div class="footnote"><p><sup>[<a id="ftn.id865478" href="#id865478" class="para">1</a>] </sup>
             C++ does not allow to obtain a reference to the pointer <code class="computeroutput"><span class="keyword">this</span></code>.
           </p></div>
 </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: May 05, 2011 at 18:14:50 GMT</small></p></td>
+<td align="left"><p><small>Last revised: May 12, 2011 at 15:56:25 GMT</small></p></td>
 <td align="right"><div class="copyright-footer"></div></td>
 </tr></table>
 <hr>

Modified: sandbox/local/libs/local/doc/html/reference.html
==============================================================================
--- sandbox/local/libs/local/doc/html/reference.html (original)
+++ sandbox/local/libs/local/doc/html/reference.html 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -30,6 +30,7 @@
 <dt><span class="section">Header <boost/local/config.hpp></span></dt>
 <dt><span class="section">Header <boost/local/exit.hpp></span></dt>
 <dt><span class="section">Header <boost/local/function.hpp></span></dt>
+<dt><span class="section">Header <boost/local/function/overload.hpp></span></dt>
 <dt><span class="section">Header <boost/local/typeof.hpp></span></dt>
 <dt><span class="section">Header <boost/utility/identity.hpp></span></dt>
 </dl></div>
@@ -51,6 +52,7 @@
 
 <a class="link" href="BOOST_LOCAL_CONFIG_COMPLIANT.html" title="Macro BOOST_LOCAL_CONFIG_COMPLIANT">BOOST_LOCAL_CONFIG_COMPLIANT</a>
 <a class="link" href="BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html" title="Macro BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX">BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX</a>
+<a class="link" href="BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html" title="Macro BOOST_LOCAL_CONFIG_OVERLOAD_MAX">BOOST_LOCAL_CONFIG_OVERLOAD_MAX</a>
 <a class="link" href="BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html" title="Macro BOOST_LOCAL_CONFIG_THIS_PARAM_NAME">BOOST_LOCAL_CONFIG_THIS_PARAM_NAME</a></pre>
 </div>
 <div class="section">
@@ -75,6 +77,17 @@
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
+<a name="header.boost.local.function.overload_hpp"></a>Header &lt;boost/local/function/overload.hpp&gt;</h3></div></div></div>
+<pre class="synopsis"><span class="keyword">namespace</span> <span class="identifier">boost</span> <span class="special">{</span>
+ <span class="keyword">namespace</span> <span class="identifier">local</span> <span class="special">{</span>
+ <span class="keyword">namespace</span> <span class="identifier">function</span> <span class="special">{</span>
+ <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> F0<span class="special">,</span> <span class="keyword">typename</span> F1<span class="special">,</span> <span class="special">...</span> <span class="special">&gt;</span> <span class="keyword">class</span> <a class="link" href="boost/local/function/overload.html" title="Class template overload">overload</a><span class="special">;</span>
+ <span class="special">}</span>
+ <span class="special">}</span>
+<span class="special">}</span></pre>
+</div>
+<div class="section">
+<div class="titlepage"><div><div><h3 class="title">
 <a name="header.boost.local.typeof_hpp"></a>Header &lt;boost/local/typeof.hpp&gt;</h3></div></div></div>
 <p>Deduce the type of variables that are bound to local functions, local blocks, and local exits. </p>
 <pre class="synopsis">

Modified: sandbox/local/libs/local/doc/html/standalone_HTML.manifest
==============================================================================
--- sandbox/local/libs/local/doc/html/standalone_HTML.manifest (original)
+++ sandbox/local/libs/local/doc/html/standalone_HTML.manifest 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -8,6 +8,7 @@
 BOOST_LOCAL_BLOCK_END.html
 BOOST_LOCAL_CONFIG_COMPLIANT.html
 BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX.html
+BOOST_LOCAL_CONFIG_OVERLOAD_MAX.html
 BOOST_LOCAL_CONFIG_THIS_PARAM_NAME.html
 BOOST_LOCAL_EXIT.html
 BOOST_LOCAL_EXIT_TPL.html
@@ -15,6 +16,7 @@
 BOOST_LOCAL_FUNCTION_PARAMS.html
 BOOST_LOCAL_FUNCTION_PARAMS_TPL.html
 BOOST_LOCAL_FUNCTION_NAME.html
+boost/local/function/overload.html
 BOOST_LOCAL_TYPEOF.html
 BOOST_IDENTITY_TYPE.html
 BOOST_IDENTITY_VALUE.html

Modified: sandbox/local/libs/local/doc/qbk/advanced_topics.qbk
==============================================================================
--- sandbox/local/libs/local/doc/qbk/advanced_topics.qbk (original)
+++ sandbox/local/libs/local/doc/qbk/advanced_topics.qbk 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -191,7 +191,7 @@
 
 [endsect]
 
-[section Passing Local Functions]
+[section Assigning Local Functions]
 
 Local functions are functors so it is possible to assign them to other functors (like `__boost__function__`) in order to store the local function into a variable or to pass it as a parameter to another function.
 
@@ -250,7 +250,33 @@
 
 [endsect]
 
-[section Inlined Local Functions]
+[section Specifying Bound Types]
+
+While not required, it is possible to explicitly specify the type of the bound variables.
+When the bound variable type is explicitly specified by the programmers, the library will not use __Boost_Typeof__ to automatically deduce such a type.
+However, the library implementation will still internally use __Boost_Typeof__ to deduce the local function result and functor types (see the __Implementation__ section) even when __Boost_Typeof__ is not used to deduce any of the bound variable types.
+
+When specified, the bound variable type must follow the `bind` "keyword" and it must be wrapped within round parenthesis `()`:
+
+ bind(``/variable-type/``) ``/variable-name/`` // Bind by value with explicit type.
+ bind(``/variable-type/``)& ``/variable-name/`` // Bind by reference with explicit type.
+ const bind(``/variable-type/``) ``/variable-name/`` // Bind by constant value with explicit type.
+ const bind(``/variable-type/``)& ``/variable-name/`` // Bind by constant value with explicit type.
+ bind(``/class-type/``*) this // Bind object `this` with type.
+ const bind(``/class-type/``*) this // Bind object `this` by constant with type.
+
+The following example explicitly specifies the type of all bound variables (it is also possible to explicitly specify the type only for some of the bound variables in which case the library will automatically deduce the type of the rest of the bound variables using __Boost_Typeof__ as usual):
+
+[table
+[ [__Variadic_Macro_Syntax__] [__Sequencing_Macro_Syntax__] ]
+[ [ [add_this_typed_va_cpp] ] [ [add_this_typed_cpp] ] ]
+]
+
+Within the local function, local block, and local exit body it is possible to abstract the access to the type of a bound variable as usual using `__BOOST_LOCAL_TYPEOF__` (even if the bound variable type is specified explicitly).
+
+[endsect]
+
+[section Inlining Local Functions]
 
 Local functions can be declared inlined to increase the chances that the compiler will be able to reduce the local function call run-time by inlining the generated assembly code.
 A local function is declared inlined by prefixing the local function name passed to the `__BOOST_LOCAL_FUNCTION_NAME__` macro with the "keyword" `inline`:
@@ -259,7 +285,7 @@
         ...
     } __BOOST_LOCAL_FUNCTION_NAME__(inline ``/name/``)
 
-On ISO C++ compliant compilers (see __BOOST_LOCAL_CONFIG_COMPLIANT__), inlined local functions always have a run-time comparable to their equivalent implementation that uses local functors (see the __Alternatives__ section).
+On ISO C++ compliant compilers, inlined local functions always have a run-time comparable to their equivalent implementation that uses local functors (see the __Alternatives__ section).
 However, inlined local functions have the limitation that they cannot be assigned to other functors (like `__boost__function__`) and they cannot be passed as template parameters.
 [footnote
 *Rationale.*
@@ -268,7 +294,7 @@
 Therefore, inlined local functions do not use such indirect function pointer call (so they are more likely to be optimized) but because of that they cannot be passed as template parameters.
 The indirect function pointer call is needed on ISO C++ but it is not needed on C++0x (see __N2657__) thus this library automatically generates local function calls that can be inlined on C++0x compilers (even when the local function is not declared inlined).
 ]
-On C++0x compilers, `inline` has no effect because this library will automatically generate code that uses C++0x specific features to inline the local function calls whenever possible even if the local function is not declared inlined.
+On C++0x compilers, `inline` has no effect because this library will automatically generate code that uses C++0x specific features to inline the local function calls whenever possible even if the local function is not declared inlined (unless the `__BOOST_LOCAL_CONFIG_COMPLIANT__` configuration macro is defined).
 Furthermore, non C++0x local functions can always be passes as template parameters even when they are declared inlined.
 
 [important
@@ -304,7 +330,57 @@
 
 [endsect]
 
-[section Nested Declarations]
+[section Overloading Local Functions]
+
+It is possible to overload local functions by creating a `__boost__local__function__overload__` functor that aggregates together calls to different local functions with different signatures.
+Note that the header file `"boost/local/function/overload.hpp"` needs to be included when using the `__boost__local__function__overload__` functor.
+
+In the following example, the overloaded functor `print` can be called with signatures from either the local function `print_string`, or the local function `print_double`, or the local function `print_double` with the extra default parameter `name`, or the function pointer `print_add`:
+
+[table
+[ [__Variadic_Macro_Syntax__] [__Sequencing_Macro_Syntax__] ]
+[ [ [overload_va_cpp] ] [ [overload_cpp] ] ]
+]
+
+The implementation of the `__boost__local__function__overload__` functor is equivalent to the following:
+
+ namespace boost { namespace local { namespace function {
+
+ template<typename F0, typename F1, ...>
+ class overload {
+ public:
+ overload(const boost::function<F0>& f0, const boost::function<F1>& f1, ...):
+ f0_(f0), f1_(f1), ... {}
+
+ result_type<F0> operator()(arg0_type<F0> a0, arg1_type<F0> a1, ...) const {
+ return f0_(a0, a1, ...);
+ }
+ result_type<F1> operator()(arg0_type<F1> a0, arg1_type<F1> a1, ...) const {
+ return f1_(a0, a1, ...);
+ }
+ ...
+
+ private:
+ const boost::function<F0> f0_;
+ const boost::function<F1> f1_;
+ ...
+ };
+
+ }}} // namespace boost::local::function
+
+A `__boost__local__function__overload__` functor can be constructed from any function type that can be converted to a `__boost__function__` type (i.e., local functions but also function pointers and other function objects).
+[footnote
+The `__boost__local__function__overload__` functor can aggregate any functor and it is not at all specific to local functions.
+Therefore, it might be preferable to move `__boost__local__function__overload__` from __Boost_Local__ to __Boost_Function__ and to rename it as `boost::function::overload`.
+]
+The `__boost__local__function__overload__` functor provides overloaded call operators `operator()` that match the signatures of all the specified function types.
+
+The maximum number of function types that can be specified for overloading is controlled at compile-time by the configuration macro `__BOOST_LOCAL_CONFIG_OVERLOAD_MAX__`.
+The maximum number of parameters that can be passed to each of the overloaded function type is controlled at compile-time by the configuration macro `__BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX__`.
+
+[endsect]
+
+[section Nesting Local Constructs]
 
 It is possible to nest local function, local block, and local exit declarations into one another.
 
@@ -361,7 +437,7 @@
 
 [endsect]
 
-[section Limitations (overloading, operators, etc)]
+[section Limitations (operators, etc)]
 
 The following table summarizes all C++ function features indicating those features that are not supported by this library for local functions.
 
@@ -439,30 +515,6 @@
 ]
 ]
 
-[h5 Overloading]
-
-It is not possible to overload local functions.
-Declaring multiple local functions with the same name within the same enclosing scope generates a compile-time error (even if the different declarations specify different parameters).
-[footnote
-*Rationale.*
-This is because a local function is a functor declared as a local variable within the enclosing scope.
-Therefore, declaring two local functions with the same name within the same enclosing scope declares two local variables with the same name within the same scope and that is not allowed in C++.
-]
-
-For example, the following code will *not* compile:
-
- void f() {
- void __BOOST_LOCAL_FUNCTION_PARAMS__( (const int& i) ) {
- ...
- } __BOOST_LOCAL_FUNCTION_NAME__(l)
-
- void __BOOST_LOCAL_FUNCTION_PARAMS__( (const double& d) ) {
- ...
- } __BOOST_LOCAL_FUNCTION_NAME__(l) // Error: Cannot overload.
-
- ...
- }
-
 [h5 Operators]
 
 Local functions cannot be operators.
@@ -483,7 +535,7 @@
         bool __BOOST_LOCAL_FUNCTION_PARAMS__(
                 (const point& p) (const point& q) ) {
             return p.x == q.x && p.y == q.y;
- ) __BOOST_LOCAL_FUNCTION_NAME__(operator==) // Error: Cannot be `operator==`.
+ ) __BOOST_LOCAL_FUNCTION_NAME__(operator==) // Error: Cannot use `operator==`.
 
         ...
     }
@@ -496,13 +548,18 @@
 
     int f() {
         void __BOOST_LOCAL_FUNCTION_PARAMS__( (boost error) ) {
- if (error) goto failure; // Error: Cannot jump to enclosing label `failure`.
+ if (error) goto failure; // Error: Cannot jump to enclosing label `failure`.
+ else goto success; // Ok: Can jump within enclosing scope.
+
+ success:
+ std::cout << "done" << std::endl;
         } __BOOST_LOCAL_FUNCTION_NAME__(l)
 
         l(true);
 
         return 0;
     failure:
+ std::cout << "error" << std::endl;
         return -1;
     }
 

Modified: sandbox/local/libs/local/doc/qbk/local.qbk
==============================================================================
--- sandbox/local/libs/local/doc/qbk/local.qbk (original)
+++ sandbox/local/libs/local/doc/qbk/local.qbk 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -70,8 +70,12 @@
 [def __BOOST_LOCAL_EXIT_END__ [macroref BOOST_LOCAL_EXIT_END]]
 [def __BOOST_LOCAL_TYPEOF__ [macroref BOOST_LOCAL_TYPEOF]]
 [def __BOOST_LOCAL_CONFIG_COMPLIANT__ [macroref BOOST_LOCAL_CONFIG_COMPLIANT]]
+[def __BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX__ [macroref BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX]]
+[def __BOOST_LOCAL_CONFIG_OVERLOAD_MAX__ [macroref BOOST_LOCAL_CONFIG_OVERLOAD_MAX]]
+[def __BOOST_LOCAL_CONFIG_THIS_PARAM_NAME__ [macroref BOOST_LOCAL_CONFIG_THIS_PARAM_NAME]]
 [def __BOOST_IDENTITY_TYPE__ [macroref BOOST_IDENTITY_TYPE]]
 [def __BOOST_IDENTITY_VALUE__ [macroref BOOST_IDENTITY_VALUE]]
+[def __boost__local__function__overload__ [classref boost::local::function::overload]]
 
 [def __Variadic_Macro_Syntax__ Variadic Macro Syntax (C99 and later compilers)]
 [def __Sequencing_Macro_Syntax__ Sequencing Macro Syntax (all C++ compilers)]
@@ -147,6 +151,10 @@
 [import ../../example/add_using_0x_lambda.cpp]
 [import ../../example/add_using_boost_lambda.cpp]
 [import ../../example/add_using_boost_phoenix.cpp]
+[import ../../example/add_this_typed.cpp]
+[import ../../example/add_this_typed_va.cpp]
+[import ../../example/overload.cpp]
+[import ../../example/overload_va.cpp]
 
 The Boost Local library implements local functions, local blocks, and local exits for the C++ programming language.
 

Modified: sandbox/local/libs/local/doc/qbk/release_notes.qbk
==============================================================================
--- sandbox/local/libs/local/doc/qbk/release_notes.qbk (original)
+++ sandbox/local/libs/local/doc/qbk/release_notes.qbk 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -6,7 +6,7 @@
 
 [section:Release_Notes Release Notes]
 
-[section Version 0.1.1]
+[section Version 0.1.1 (2011-01-10)]
 
 # Uploaded library source into Boost SVN sandbox.
 # Fixed prev/next arrows and other minor layouts in documentation.
@@ -14,13 +14,13 @@
 
 [endsect]
 
-[section Version 0.1.0]
+[section Version 0.1.0 (2011-01-03)]
 
 # Shared with Boost for first round of comments.
 
 [endsect]
 
-[section Version 0.0.1]
+[section Version 0.0.1 (2010-12-15)]
 
 # Completed development, examples, and documentation.
 

Modified: sandbox/local/libs/local/doc/qbk/tutorial.qbk
==============================================================================
--- sandbox/local/libs/local/doc/qbk/tutorial.qbk (original)
+++ sandbox/local/libs/local/doc/qbk/tutorial.qbk 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -58,6 +58,9 @@
 [ [ [add_x_y_va_cpp] ] [ [add_x_y_cpp] ] ]
 ]
 
+The maximum number of parameters that can be passed to a local function (excluding eventual bound variables) is controlled at compile-time by the configuration macro `__BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX__`.
+The variadic macro syntax is always disabled when the configuration macro `__BOOST_LOCAL_CONFIG_COMPLIANT__` is defined.
+
 [endsect]
 
 [section:Empty_Parameters Empty Parameters]
@@ -99,6 +102,7 @@
 ]
 
 Note that not all compilers that support variadic macros also support empty macro parameters.
+Both the empty macro syntax and variadic macro syntax are always disabled when the configuration macro `__BOOST_LOCAL_CONFIG_COMPLIANT__` is defined.
 
 [endsect]
 
@@ -172,7 +176,7 @@
     
 Furthermore, the "keyword" `bind` can be prefixed by `const` to bind the variable by constant value:
     
- const bind ``/variable-name/`` // Bind by value.
+ const bind ``/variable-name/`` // Bind by constant value.
 
 Or by constant reference:
     
@@ -251,6 +255,8 @@
 [ [ [add_this_va_cpp] ] [ [add_this_cpp] ] ]
 ]
 
+The special name `this_` used to replace the bound object name `this` is controlled at compile-time by the configuration macro `__BOOST_LOCAL_CONFIG_THIS_PARAM_NAME__`.
+
 [endsect]
 
 [section Local Blocks]

Modified: sandbox/local/libs/local/example/Jamfile.jam
==============================================================================
--- sandbox/local/libs/local/example/Jamfile.jam (original)
+++ sandbox/local/libs/local/example/Jamfile.jam 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -44,6 +44,9 @@
 exe add_this : add_this.cpp ;
 exe add_this_va : add_this_va.cpp ;
 
+exe add_this_typed : add_this_typed.cpp ;
+exe add_this_typed_va : add_this_typed_va.cpp ;
+
 exe add_using_boost_local : add_using_boost_local.cpp ;
 exe add_using_boost_local_va : add_using_boost_local_va.cpp ;
 exe add_using_local_functor : add_using_local_functor.cpp ;
@@ -81,15 +84,15 @@
 exe nesting : nesting.cpp ;
 exe nesting_va : nesting_va.cpp ;
 
+exe overload : overload.cpp ;
+exe overload_va : overload_va.cpp ;
+
 exe params_all : params_all.cpp ;
 exe params_all_va : params_all_va.cpp ;
 
 exe print_map : print_map.cpp ;
 exe print_map_va : print_map_va.cpp ;
 
-exe overload : overload.cpp ;
-exe overload_va : overload_va.cpp ;
-
 exe profile_boost_local : profile_boost_local.cpp
         ../../..//libboost_chrono ../../..//libboost_system ;
 exe profile_boost_local_inline : profile_boost_local_inline.cpp

Modified: sandbox/local/libs/local/example/add_this.cpp
==============================================================================
--- sandbox/local/libs/local/example/add_this.cpp (original)
+++ sandbox/local/libs/local/example/add_this.cpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -23,6 +23,7 @@
             this_->sum_ += factor * num; // Use `this_` instead of `this`.
             std::cout << "Summed: " << this_->sum_ << std::endl;
         } BOOST_LOCAL_FUNCTION_NAME(add)
+ std::for_each(nums.begin(), nums.end(), add);
 
         BOOST_LOCAL_EXIT( (const bind this) ) {
             std::cout << "Exiting: " << this_->sum_ << std::endl;
@@ -33,7 +34,6 @@
             assert(this_->sum_ > 0.0);
         } BOOST_LOCAL_BLOCK_END
 
- std::for_each(nums.begin(), nums.end(), add);
         return sum_;
     }
 

Modified: sandbox/local/libs/local/example/add_this_va.cpp
==============================================================================
--- sandbox/local/libs/local/example/add_this_va.cpp (original)
+++ sandbox/local/libs/local/example/add_this_va.cpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -32,6 +32,7 @@
             this_->sum_ += factor * num; // Use `this_` instead of `this`.
             std::cout << "Summed: " << this_->sum_ << std::endl;
         } BOOST_LOCAL_FUNCTION_NAME(add)
+ std::for_each(nums.begin(), nums.end(), add);
 
         BOOST_LOCAL_EXIT(const bind this) {
             std::cout << "Exiting: " << this_->sum_ << std::endl;
@@ -42,7 +43,6 @@
             assert(this_->sum_ > 0.0);
         } BOOST_LOCAL_BLOCK_END
 
- std::for_each(nums.begin(), nums.end(), add);
         return sum_;
     }
 

Modified: sandbox/local/libs/local/example/overload.cpp
==============================================================================
--- sandbox/local/libs/local/example/overload.cpp (original)
+++ sandbox/local/libs/local/example/overload.cpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -13,16 +13,16 @@
 }
 
 int main() {
- char sep = '\n';
+ char end = '\n';
 
     void BOOST_LOCAL_FUNCTION_PARAMS( (const std::string& item)
- (const bind& sep) ) {
- std::cout << item << " (string)" << sep;
+ (const bind& end ) ) {
+ std::cout << item << " (string)" << end;
     } BOOST_LOCAL_FUNCTION_NAME(print_string)
 
     void BOOST_LOCAL_FUNCTION_PARAMS( (const double& item)
- (const char* name)(default " (double)") (const bind& sep) ) {
- std::cout << item << name << sep;
+ (const char* name)(default " (double)") (const bind& end) ) {
+ std::cout << item << name << end;
     } BOOST_LOCAL_FUNCTION_NAME(print_double)
     
     boost::local::function::overload<

Modified: sandbox/local/libs/local/example/overload_va.cpp
==============================================================================
--- sandbox/local/libs/local/example/overload_va.cpp (original)
+++ sandbox/local/libs/local/example/overload_va.cpp 2011-05-12 11:57:41 EDT (Thu, 12 May 2011)
@@ -22,16 +22,16 @@
 }
 
 int main() {
- char sep = '\n';
+ char end = '\n';
 
     void BOOST_LOCAL_FUNCTION_PARAMS(const std::string& item,
- const bind& sep) {
- std::cout << item << " (string)" << sep;
+ const bind& end) {
+ std::cout << item << " (string)" << end;
     } BOOST_LOCAL_FUNCTION_NAME(print_string)
 
     void BOOST_LOCAL_FUNCTION_PARAMS(const double& item,
- const char* name, default " (double)", const bind& sep) {
- std::cout << item << name << sep;
+ const char* name, default " (double)", const bind& end) {
+ std::cout << item << name << end;
     } BOOST_LOCAL_FUNCTION_NAME(print_double)
     
     boost::local::function::overload<


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