Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r68971 - in sandbox/local/libs/local/params_name/boost/local/aux_: . function_macros function_macros/code_
From: lorcaminiti_at_[hidden]
Date: 2011-02-17 15:01:26


Author: lcaminiti
Date: 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
New Revision: 68971
URL: http://svn.boost.org/trac/boost/changeset/68971

Log:
Adding abstract_function, function, and function_macros/.
Added:
   sandbox/local/libs/local/params_name/boost/local/aux_/abstract_function.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/file.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/binding.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/deduce_result_type.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/functor.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/param.hpp (contents, props changed)
   sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/params.hpp (contents, props changed)

Added: sandbox/local/libs/local/params_name/boost/local/aux_/abstract_function.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/abstract_function.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,83 @@
+
+// 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).
+
+#if !BOOST_PP_IS_ITERATING
+# ifndef BOOST_LOCAL_AUX_ABSTRACT_FUNCTION_HPP_
+# define BOOST_LOCAL_AUX_ABSTRACT_FUNCTION_HPP_
+
+# include "file.hpp"
+# include "../config.hpp"
+# include <boost/preprocessor/iteration/iterate.hpp>
+# include <boost/preprocessor/repetition/repeat.hpp>
+# include <boost/preprocessor/repetition/enum.hpp>
+# include <boost/preprocessor/punctuation/comma_if.hpp>
+# include <boost/preprocessor/arithmetic/sub.hpp>
+# include <boost/preprocessor/arithmetic/inc.hpp>
+# include <boost/preprocessor/cat.hpp>
+
+#define BOOST_LOCAL_AUX_arg_type(z, arg_n, unused) \
+ BOOST_PP_CAT(A, arg_n)
+
+#define BOOST_LOCAL_AUX_arg_typename(z, arg_n, unused) \
+ typename BOOST_LOCAL_AUX_arg_type(z, arg_n, unused)
+
+#define BOOST_LOCAL_AUX_abstract_operator_call(z, defaults_n, arity) \
+ virtual R operator()(BOOST_PP_ENUM_ ## z(BOOST_PP_SUB(arity, defaults_n), \
+ BOOST_LOCAL_AUX_arg_type, ~)) = 0;
+
+#define BOOST_LOCAL_AUX_template_name(defaults_count) \
+ BOOST_PP_CAT(BOOST_PP_CAT(functor_defaults, defaults_count), _base)
+
+namespace boost { namespace local { namespace aux {
+
+template<typename F, unsigned int defaults_count = 0> // Defaults count is opt.
+struct abstract_function {}; // Empty so never used directly.
+
+// Iteration within the namespace.
+# define BOOST_PP_ITERATION_PARAMS_1 \
+ (3, (0, BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX, \
+ BOOST_LOCAL_AUX_FILE_FUNCTION_BASE_HPP))
+# include BOOST_PP_ITERATE() // Iterate over arity.
+
+}}} // namespace boost::local::aux
+
+# undef BOOST_LOCAL_AUX_arg_type
+# undef BOOST_LOCAL_AUX_arg_typename
+# undef BOOST_LOCAL_AUX_abstract_operator_call
+# undef BOOST_LOCAL_AUX_template_name
+
+# endif // #include guard
+
+#elif BOOST_PP_ITERATION_DEPTH() == 1
+# define BOOST_LOCAL_AUX_arity BOOST_PP_FRAME_ITERATION(1)
+
+# define BOOST_PP_ITERATION_PARAMS_2 \
+ (3, (0, BOOST_LOCAL_AUX_arity, \
+ BOOST_LOCAL_AUX_FILE_FUNCTION_BASE_HPP))
+# include BOOST_PP_ITERATE() // Iterate over default params count.
+# undef BOOST_LOCAL_AUX_arity
+
+#elif BOOST_PP_ITERATION_DEPTH() == 2
+# define BOOST_LOCAL_AUX_defaults_count BOOST_PP_FRAME_ITERATION(2)
+
+template<typename R
+ BOOST_PP_COMMA_IF(BOOST_LOCAL_AUX_arity)
+ BOOST_PP_ENUM(BOOST_LOCAL_AUX_arity, BOOST_LOCAL_AUX_arg_typename, ~)
+>
+struct abstract_function<
+ R (BOOST_PP_ENUM(BOOST_LOCAL_AUX_arity, BOOST_LOCAL_AUX_arg_type, ~))
+ , BOOST_LOCAL_AUX_defaults_count
+> {
+ // INC for no dflt.
+ BOOST_PP_REPEAT(BOOST_PP_INC(BOOST_LOCAL_AUX_defaults_count),
+ BOOST_LOCAL_AUX_abstract_operator_call, BOOST_LOCAL_AUX_arity)
+};
+
+# undef BOOST_LOCAL_AUX_defaults_count
+
+#endif // iteration
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/file.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/file.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,18 @@
+
+// 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_FILE_HPP_
+#define BOOST_LOCAL_AUX_FILE_HPP_
+
+#define BOOST_LOCAL_AUX_FILE_FUNCTION_BASE_HPP \
+ "boost/local/aux_/function/base.hpp"
+
+#define BOOST_LOCAL_AUX_FILE_FUNCTION_REF_HPP \
+ "boost/local/aux_/function_ref.hpp"
+
+#endif // #include guard
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,117 @@
+
+// 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).
+
+// IMPORTANT: Even if this file is in the "aux_" directory, its macro names
+// must NOT be prefixed by "AUX" or be within the "aux" namespace. This is
+// because this file is an helper to automatically implement all `function`
+// template specializations which must leave outside the "aux" namespace.
+
+#if !BOOST_PP_IS_ITERATING
+# ifndef BOOST_LOCAL_AUX_FUNCTION_HPP_
+# define BOOST_LOCAL_AUX_FUNCTION_HPP_
+
+# include "abstract_function.hpp"
+# include "file.hpp"
+# include "../config.hpp"
+# include <boost/preprocessor/iteration/iterate.hpp>
+# include <boost/preprocessor/repetition/repeat.hpp>
+# include <boost/preprocessor/repetition/enum.hpp>
+# include <boost/preprocessor/punctuation/comma_if.hpp>
+# include <boost/preprocessor/arithmetic/sub.hpp>
+# include <boost/preprocessor/arithmetic/inc.hpp>
+# include <boost/preprocessor/cat.hpp>
+# include <cassert>
+
+#define BOOST_LOCAL_AUX_arg_type(z, arg_n, unused) \
+ BOOST_PP_CAT(A, arg_n)
+
+#define BOOST_LOCAL_AUX_arg_name(z, arg_n, unused) \
+ BOOST_PP_CAT(a, arg_n)
+
+#define BOOST_LOCAL_AUX_arg(z, arg_n, unused) \
+ BOOST_LOCAL_AUX_arg_type(z, arg_n, unused) \
+ BOOST_LOCAL_AUX_arg_name(z, arg_n, unused)
+
+#define BOOST_LOCAL_AUX_arg_typename(z, arg_n, unused) \
+ typename BOOST_LOCAL_AUX_arg_type(z, arg_n, unused)
+
+#define BOOST_LOCAL_AUX_concrete_operator_call(z, defaults_n, arity) \
+ inline R operator()(BOOST_PP_ENUM_ ## z(BOOST_PP_SUB(arity, defaults_n), \
+ BOOST_LOCAL_AUX_arg, ~)) { \
+ assert(ptr_); \
+ return (*ptr_)(BOOST_PP_ENUM_ ## z(BOOST_PP_SUB(arity, defaults_n), \
+ BOOST_LOCAL_AUX_arg_name, ~)); \
+ }
+
+// Iteration within the namespace.
+# define BOOST_PP_ITERATION_PARAMS_1 \
+ (3, (0, BOOST_LOCAL_CONFIG_FUNCTION_ARITY_MAX, \
+ BOOST_LOCAL_AUX_FILE_FUNCTION_HPP))
+# include BOOST_PP_ITERATE() // Iterate over arity.
+
+# undef BOOST_LOCAL_AUX_arg_type
+# undef BOOST_LOCAL_AUX_arg_name
+# undef BOOST_LOCAL_AUX_arg
+# undef BOOST_LOCAL_AUX_rg_typename
+# undef BOOST_LOCAL_AUX_concrete_operator_call
+
+# endif // #include guard
+
+#elif BOOST_PP_ITERATION_DEPTH() == 1
+# define BOOST_LOCAL_AUX_arity BOOST_PP_FRAME_ITERATION(1)
+
+# define BOOST_PP_ITERATION_PARAMS_2 \
+ (3, (0, BOOST_LOCAL_AUX_arity, \
+ BOOST_LOCAL_AUX_FILE_FUNCTION_HPP))
+# include BOOST_PP_ITERATE() // Iterate over default params count.
+# undef BOOST_LOCAL_AUX_arity
+
+#elif BOOST_PP_ITERATION_DEPTH() == 2
+# define BOOST_LOCAL_AUX_defaults BOOST_PP_FRAME_ITERATION(2)
+
+// Specializations of boost::local::function so not in aux namespace.
+namespace boost { namespace local {
+
+template<typename R
+ BOOST_PP_COMMA_IF(BOOST_LOCAL_AUX_arity)
+ BOOST_PP_ENUM(BOOST_LOCAL_AUX_arity, BOOST_LOCAL_AUX_arg_typename, ~)
+>
+class function<
+ R (BOOST_PP_ENUM(BOOST_LOCAL_AUX_arity, BOOST_LOCAL_AUX_arg_type, ~))
+ , BOOST_LOCAL_AUX_defaults
+> {
+ typedef aux::abstract_function<
+ R (BOOST_PP_ENUM(BOOST_LOCAL_AUX_arity, BOOST_LOCAL_AUX_arg_type, ~))
+ , BOOST_LOCAL_AUX_defaults
+ > abstract_function_type;
+
+public:
+ /* implicit */ function(): ptr_() {} // Default constructor.
+
+ /* implicit */ function(abstract_function_type& ref): ptr_(&ref) {}
+
+ function& operator=(abstract_function_type& ref) {
+ ptr_ = &ref;
+ return *this;
+ }
+
+ // Result operator(Arg1, ..., ArgN-1, ArgN) // iff defaults >= 0
+ // Result operator(Arg1, ..., ArgN-1) // iff defaults >= 1
+ // ... // etc
+ BOOST_PP_REPEAT(BOOST_PP_INC(BOOST_LOCAL_AUX_defaults), // INC for no dflt.
+ BOOST_LOCAL_AUX_concrete_operator_call, BOOST_LOCAL_AUX_arity)
+
+private:
+ abstract_function_type* ptr_;
+};
+
+}} // namespace boost::local
+
+# undef BOOST_LOCAL_AUX_defaults
+
+#endif // iteration
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/binding.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/binding.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,100 @@
+
+// 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_FUNCTION_CODE_BINDING_HPP_
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_HPP_
+
+#include "param.hpp"
+#include "../../symbol.hpp"
+#include "../../scope_exit/scope_exit.hpp" // Use this lib's ScopeExit impl.
+#include "../../preprocessor/sign/params_any_bind.hpp"
+#include <boost/detail/preprocessor/nilseq.hpp>
+#include <boost/preprocessor/control/iif.hpp>
+#include <boost/preprocessor/control/expr_iif.hpp>
+#include <boost/preprocessor/seq/for_each_i.hpp>
+#include <boost/preprocessor/cat.hpp>
+
+// Undefine local function bound args global variable. Actual declaration of
+// this variable is made using SFINAE mechanisms by each local function macro.
+extern boost::scope_exit::aux::undeclared
+ BOOST_LOCAL_AUX_SYMBOL_ARGS_VARIABLE_NAME;
+
+// PRIVATE //
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_IMPL()`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_WITH_TAGS_SEQ_( \
+ all_bind_nilseq, has_any_bind_this, id, typename_keyword) \
+ /* binding tags */ \
+ BOOST_PP_EXPR_IIF(has_any_bind_this, \
+ BOOST_SCOPE_EXIT_TYPEDEF_TYPEOF_THIS() \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_TYPE(id); \
+ ) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_TAG_DECL, \
+ id, all_bind_nilseq) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_CAPTURE_DECL, \
+ (id, typename_keyword), all_bind_nilseq) \
+ /* binding class */ \
+ struct BOOST_SCOPE_EXIT_AUX_PARAMS_T(id) { \
+ BOOST_PP_EXPR_IIF(has_any_bind_this, \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_TYPE(id) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_NAME; \
+ ) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_PARAM_DECL, \
+ (id, typename_keyword), all_bind_nilseq) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I(BOOST_SCOPE_EXIT_AUX_MEMBER, \
+ id, all_bind_nilseq) \
+ } 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_NOT( \
+ BOOST_DETAIL_PP_NILSEQ_IS_NIL(all_bind_nilseq)))) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_SCOPE_EXIT_AUX_PARAM_INIT, id, all_bind_nilseq) \
+ };
+
+// Assume has some bind param.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_( \
+ sign_params, id, typename_keyword) \
+ /* 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(sign_params), \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAS_ANY_BIND_THIS(sign_params), \
+ id, typename_keyword)
+
+// PUBLIC //
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING( \
+ sign_params, id, typename_keyword) \
+ /* deduce bound type and stores their values/references */ \
+ BOOST_PP_IIF(BOOST_PP_EXPAND( /* expand needed on MSVC */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAS_ANY_BIND(sign_params)), \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING_ \
+ , \
+ BOOST_PP_TUPLE_EAT(3) \
+ )(sign_params, id, typename_keyword) \
+ /* this `declared<>` must be present also when no bind param specified */ \
+ /* because `...args.value` is ued by `NAME` macro (to constructor */ \
+ /* functor) without knowing if binds were specified or not */ \
+ boost::scope_exit::aux::declared< boost::scope_exit::aux::resolve< \
+ /* cannot prefix with `::` as in `sizeof(:: ...` because the name */ \
+ /* must refer to the local variable name to allow multiple local */ \
+ /* functions (and exits) within the same scope (however this */ \
+ /* does not allow for nesting because local variables cannot be */ \
+ /* used in nested code blocks) */ \
+ sizeof(BOOST_LOCAL_AUX_SYMBOL_ARGS_VARIABLE_NAME) \
+ >::cmp1<0>::cmp2 > BOOST_LOCAL_AUX_SYMBOL_ARGS_VARIABLE_NAME; \
+ /* stores bound types/values into `...args` variable (args variable */ \
+ /* can be accessed by `NAME` macro because doesn't use __LINE__ id) */ \
+ BOOST_PP_EXPR_IIF(BOOST_PP_EXPAND( /* expand needed on MSVC */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAS_ANY_BIND(sign_params)), \
+ BOOST_LOCAL_AUX_SYMBOL_ARGS_VARIABLE_NAME.value = \
+ &BOOST_LOCAL_AUX_SYMBOL_PARAMS_LOCAL_VARIABLE_NAME(id); \
+ )
+
+#endif // #include guard
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/deduce_result_type.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/deduce_result_type.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,19 @@
+
+#ifndef BOOST_LOCAL_AUX_FUNCTION_CODE_DEDUCE_RESULT_TYPE_HPP_
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_DEDUCE_RESULT_TYPE_HPP_
+
+#include "../../symbol.hpp"
+// Use this lib's ScopeExit impl (for TYPEOF).
+#include "../../scope_exit/scope_exit.hpp"
+
+// This must follow the result type.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_DEDUCE_RESULT_TYPE( \
+ id, typename_keyword) \
+ /* declare function expr with preceeding result type and no param */ \
+ /* result type here */ BOOST_LOCAL_AUX_SYMBOL_DEDUCE_RESULT_TYPE(id)(); \
+ typedef boost::function_tratis::result_type<BOOST_TYPEOF( \
+ BOOST_LOCAL_AUX_SYMBOL_DEDUCE_RESULT_TYPE(id))>::type \
+ BOOST_LOCAL_AUX_SYMBOL_RESULT_TYPE(id);
+
+#endif // #include guard
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/functor.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/functor.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,258 @@
+
+// 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_FUNCTION_CODE_FUNCTOR_HPP_
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_HPP_
+
+#include "param.hpp"
+#include "../base.hpp"
+#include "../../symbol.hpp"
+#include "../../preprocessor/sign/params/unbind.hpp"
+#include "../../preprocessor/sign/params/const_bind_names.hpp"
+#include "../../preprocessor/sign/params/bind_names.hpp"
+#include "../../preprocessor/sign/params/has_unbind.hpp"
+#include "../../preprocessor/sign/params/has_const_bind.hpp"
+#include "../../preprocessor/sign/params/has_bind.hpp"
+#include "../../preprocessor/sign/params/has_any_bind.hpp"
+#include "../../preprocessor/sign/params/this.hpp"
+#include "../../scope_exit/scope_exit.hpp" // Use Boost.ScopeExit internal impl.
+#include "../../../config.hpp"
+#include "../../../function_ref.hpp"
+#include <boost/detail/preprocessor/sign/name.hpp>
+#include <boost/detail/preprocessor/sign/result_type.hpp>
+#include <boost/detail/preprocessor/sign/inline.hpp>
+#include <boost/detail/preprocessor/sign/params/fold_left.hpp>
+#include <boost/detail/preprocessor/sign/params/enum.hpp>
+#include <boost/detail/preprocessor/sign/params/first_n.hpp>
+#include <boost/detail/preprocessor/nilseq.hpp>
+#include <boost/preprocessor/punctuation/comma_if.hpp>
+#include <boost/preprocessor/logical/bitand.hpp>
+#include <boost/preprocessor/logical/and.hpp>
+#include <boost/preprocessor/logical/bitor.hpp>
+#include <boost/preprocessor/logical/or.hpp>
+#include <boost/preprocessor/arithmetic/inc.hpp>
+#include <boost/preprocessor/facilities/empty.hpp>
+#include <boost/preprocessor/control/iif.hpp>
+#include <boost/preprocessor/control/expr_if.hpp>
+#include <boost/preprocessor/tuple/eat.hpp>
+#include <boost/type_traits.hpp>
+
+// PRIVATE //
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_DEFAULTS_COUNT_OP_(s, \
+ defaults_count, param) \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_PARAMS_HAS_DEFAULT( \
+ param), \
+ BOOST_PP_INC(defaults_count) \
+ , \
+ defaults_count \
+ )
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_DEFAULTS_COUNT_(sign_params) \
+ BOOST_PP_SEQ_FOLD_LEFT( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_DEFAULTS_COUNT_OP_, \
+ 0 /* start with defaults_count to 0 */, \
+ BOOST_DETAIL_PP_NILSEQ_TO_SEQ( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(sign_params)))
+
+// Expand to the function type `R (A1, ...)`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_F_(sign_params, id) \
+ BOOST_LOCAL_AUX_SYMBOL_RESULT_TYPE(id) \
+ ( \
+ BOOST_DETAIL_PP_SIGN_PARAMS_ENUM( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_TYPE, ~, \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND( \
+ BOOST_DETAIL_PP_SIGN_PARAMS(sign))) \
+ )
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_CALL_(z, \
+ sign_params, \
+ unbind_params, \
+ const_bind_names, has_const_bind_this, \
+ bind_names, has_bind_this, \
+ id) \
+ BOOST_LOCAL_AUX_SYNBOL_RESULT_TYPE(id) operator()( \
+ BOOST_DETAIL_PP_SIGN_PARAMS_ENUM_Z(z, \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_DECL, \
+ ~, unbind_params) \
+ ) { \
+ /* just forward call to member function with local func name */ \
+ return BOOST_LOCAL_AUX_SYMBOL_BODY_FUNCTION_NAME( \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND, \
+ (id, 0 /* no offset */), \
+ const_bind_names) \
+ /* pass plain binds */ \
+ BOOST_PP_COMMA_IF(BOOST_PP_NOT( \
+ BOOST_DETAIL_PP_NILSEQ_IS_NIL(bind_names))) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND, \
+ (id \
+ /* offset param index of # of preceeding */ \
+ /* const-bind params (could be 0)*/ \
+ , BOOST_DETAIL_PP_NILSEQ_SIZE(const_bind_names) \
+ ), \
+ bind_names) \
+ /* pass bind `this` */ \
+ BOOST_PP_COMMA_IF(BOOST_PP_BITOR( \
+ has_const_bind_this, has_bind_this)) \
+ BOOST_PP_EXPR_IIF( \
+ BOOST_PP_BITOR(has_const_bind_this, has_bind_this), \
+ BOOST_LOCAL_AUX_SYMBOL_BINDS_VARIABLE_NAME-> \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_NAME_ \
+ ) \
+ /* pass unbind params */ \
+ BOOST_PP_COMMA_IF(BOOST_DETAIL_PP_SIGN_PARAMS_SIZE( \
+ unbind_params)) \
+ BOOST_DETAIL_PP_SIGN_PARAMS_ENUM_Z(z, \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_NAME, \
+ ~, unbind_params) \
+ ); \
+ }
+
+// Return unbind params but without last (default) params specified by count.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_UNBIND_DEFAULTS_REMOVE_N_( \
+ defaults_count, unbind_params) \
+ BOOST_PP_SEQ_FIRST_N(BOOST_PP_SUB(BOOST_DETAIL_PP_SIGN_PARAMS_SIZE( \
+ unbind_params), defaults_count), unbind_params)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_CALL_FOR_DEFAULTS_(z, \
+ n, params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_CALL_(z \
+ , BOOST_PP_TUPLE_ELEM(7, 0, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ , BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_UNBIND_DEFAULTS_REMOVE_N_( \
+ n, BOOST_PP_TUPLE_ELEM(7, 1, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id)) \
+ , BOOST_PP_TUPLE_ELEM(7, 2, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ , BOOST_PP_TUPLE_ELEM(7, 3, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ , BOOST_PP_TUPLE_ELEM(7, 4, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ , BOOST_PP_TUPLE_ELEM(7, 5, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ , BOOST_PP_TUPLE_ELEM(7, 6, \
+ params_unbind_constbind_hasconstthis_bind_hasthis_id) \
+ )
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_IMPL()`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_( \
+ sign_params, \
+ unbind_params, defaults_count, \
+ const_bind_names, has_const_bind_this, \
+ bind_names, has_bind_this, \
+ id, typename_keyword) \
+ class BOOST_LOCAL_AUX_SYMBOL_FUNCTOR_CLASS_NAME(id) : \
+ public ::boost::local::aux::function_base< \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_F_(sign_params, id), \
+ defaults_count> { \
+ public: \
+ /* constructor */ \
+ explicit BOOST_LOCAL_AUX_SYMBOL_FUNCTOR_CLASS_NAME(id)( \
+ void* binds) \
+ BOOST_PP_EXPR_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAS_ANY_BIND( \
+ sign_params) \
+ : BOOST_LOCAL_AUX_SYMBOL_BINDS_VARIABLE_NAME( \
+ static_cast<BOOST_SCOPE_EXIT_AUX_PARAMS_T(id)*>( \
+ binds) \
+ ) { \
+ /* init needs func name so programmed later by `NAME` macro */ \
+ BOOST_LOCAL_AUX_SYMBOL_INIT_RECURSION_FUNCTION_NAME() \
+ } \
+ /* implement base functor `operator()` (and for all default params) */ \
+ BOOST_PP_REPEAT( \
+ BOOST_PP_INC(defaults_count), /* PP_INC to handle no dflt */ \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_CALL_FOR_DEFAULTS_,\
+ (sign_params, unbind_params, const_bind_names, \
+ has_const_bind_this, bind_names, has_bind_this, id)) \
+ private: \
+ typedef ::boost::local::function_ref< \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_F_(sign_params, id), \
+ defaults_count> \
+ /* This symbol cannot have ID postfix because it is used */ \
+ /* the `NAME` macro (because this symbol is within functor */ \
+ /* class it doesn't have to have ID postfix). */ \
+ BOOST_LOCAL_AUX_SYMBOL_FUNCTOR_TYPE; \
+ /* bind params member variable (note -- signle bind param cannot */ \
+ /* be represented as single member variables because their names */ \
+ /* might be prefixed by `&` so they are not know to pp) */ \
+ BOOST_PP_EXPR_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_ANY_BIND( \
+ sign_params), \
+ BOOST_SCOPE_EXIT_AUX_PARAMS_T(id)* \
+ BOOST_LOCAL_AUX_SYMBOL_BINDS_VARIABLE_NAME; \
+ ) \
+ BOOST_PP_EXPR_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAS_ANY_BIND( \
+ sign_params) \
+ BOOST_SCOPE_EXIT_AUX_PARAMS_T(id)* \
+ BOOST_LOCAL_AUX_SYMBOL_BINDS_VARIABLE_NAME; \
+ ) \
+ /* body function */ \
+ BOOST_LOCAL_AUX_SYMBOL_RESULT_TYPE(id) \
+ BOOST_LOCAL_AUX_SYMBOL_BODY_FUNCTION_NAME( \
+ /* const binds */ \
+ BOOST_PP_COMMA_IF(BOOST_PP_NOT( \
+ BOOST_DETAIL_PP_NILSEQ_IS_NIL(const_bind_names))) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_CONST_BIND_DECL, \
+ (id, typename_keyword, 0 /* no offset */), \
+ const_bind_names) \
+ /* plain binds */ \
+ BOOST_PP_COMMA_IF(BOOST_PP_NOT( \
+ BOOST_DETAIL_PP_NILSEQ_IS_NIL(bind_names))) \
+ BOOST_DETAIL_PP_NILSEQ_FOR_EACH_I( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_BIND_DECL, \
+ (id, typename_keyword, \
+ /* offset param index of # of preceeding */ \
+ /* const-bindparams (could be 0)*/ \
+ BOOST_DETAIL_PP_NILSEQ_SIZE(const_bind_names)),\
+ bind_names) \
+ /* `this` bind */ \
+ BOOST_PP_COMMA_IF(BOOST_PP_BITOR( \
+ has_const_bind_this, has_bind_this)) \
+ BOOST_PP_EXPR_IIF(has_const_bind_this, \
+ typename_keyword ::contract::detail::add_pointed_const< \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_TYPE_(id) \
+ >::type \
+ BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
+ ) \
+ BOOST_PP_EXPR_IIF(has_bind_this, \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_TYPE_(id) \
+ BOOST_LOCAL_CONFIG_THIS_PARAM_NAME \
+ ) \
+ /* unbind params (last because they can have defaults) */ \
+ BOOST_PP_COMMA_IF(BOOST_DETAIL_PP_SIGN_PARAMS_SIZE( \
+ unbind_params)) \
+ BOOST_DETAIL_PP_SIGN_PARAMS_ENUM( \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_DECL_WITH_DEFAULT, \
+ ~, unbind_params) \
+ ) /* end body function params */ \
+ /* user local function definition `{ ... }` will follow here */ \
+ /* `NAME` macro will close function class decl `};` here */
+
+// PUBLIC //
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR( \
+ sign_params, id, typename_keyword) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_( \
+ /* unbind params (might have defaults) */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND(sign_params), \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_FUNCTOR_DEFAULTS_COUNT_( \
+ sign_params), \
+ /* const bind vars (without `this`) */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_CONST_BIND(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_NAMES(sign_params), \
+ /* eventual bind (not const) `this` */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_BIND_THIS(params), \
+ /* etc */ \
+ id, typename_keyword)
+
+#endif // #include guard
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/param.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/code_/param.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,132 @@
+
+// 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_FUNCTION_CODE_PARAM_HPP_
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_HPP_
+
+#include "../../symbol.hpp"
+#include "../../scope_exit/scope_exit.hpp" // Use this lib's ScopeExit impl.
+#include "../../type_traits/add_pointed_const.hpp"
+#include <boost/detail/preprocessor/keyword/this.hpp>
+#include <boost/detail/preprocessor/keyword/auto.hpp>
+#include <boost/detail/preprocessor/keyword/register.hpp>
+#include <boost/local/aux_/preprocessor/sign/params_unbind.hpp>
+#include <boost/type_traits.hpp>
+#include <boost/preprocessor/punctuation/comma_if.hpp>
+#include <boost/preprocessor/control/expr_if.hpp>
+#include <boost/preprocessor/control/iif.hpp>
+#include <boost/preprocessor/arithmetic/add.hpp>
+#include <boost/preprocessor/tuple/elem.hpp>
+#include <boost/preprocessor/tuple/eat.hpp>
+#include <boost/preprocessor/cat.hpp>
+
+// Param named `this`.
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_TYPE(id) \
+ BOOST_PP_CAT(se_this_type, id) // Using ScopeExit prefix `se_...`.
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_THIS_NAME \
+ se_this // Using ScopeExit prefix `se_...`.
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_RENAME_THIS_(param_name) \
+ /* can't use `PP_KEYWORD_IS_THIS_FRONT()` because some `param_name` */ \
+ /* might start with non-alphanumeric symbol `&` (but never for `this`) */ \
+ BOOST_PP_IIF(BOOST_DETAIL_PP_KEYWORD_IS_THIS_BACK(param_name), \
+ BOOST_LOCAL_AUX_SYMBOL_THIS_PARAM_NAME \
+ , \
+ param_name \
+ )
+
+// Tag param.
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_TAG_DECL()`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_TAG_DECL(r, id, i, var) \
+ typedef void (*BOOST_SCOPE_EXIT_AUX_TAG(id,i))(int \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_RENAME_THIS_(var) );
+
+// Bound param (const and non-const).
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_TYPE( \
+ id_typename_offset, i, var) \
+ BOOST_SCOPE_EXIT_AUX_PARAMS_T( \
+ BOOST_PP_TUPLE_ELEM(3, 0, id_typename_offset)):: \
+ BOOST_SCOPE_EXIT_AUX_PARAM_T( \
+ BOOST_PP_TUPLE_ELEM(3, 0, id_typename_offset), \
+ BOOST_PP_ADD(i, BOOST_PP_TUPLE_ELEM(3, 2, id_typename_offset)),\
+ var)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_VALUE( \
+ id_offset, i, var) \
+ BOOST_LOCAL_AUX_SYMBOL_PARAMS_VARIABLE_NAME-> \
+ BOOST_SCOPE_EXIT_AUX_PARAM( \
+ BOOST_PP_TUPLE_ELEM(2, 0, id_offset), \
+ BOOST_PP_ADD(i, BOOST_PP_TUPLE_ELEM(2, 1, id_offset)), \
+ var).value
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_ARG_DECL()`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_DECL_( \
+ r, id_typename_offset, i, var, const01) \
+ BOOST_PP_COMMA_IF(i) \
+ BOOST_PP_TUPLE_ELEM(3, 1, id_typename_offset) /* eventual typename */ \
+ BOOST_PP_EXPR_IF(const01, \
+ BOOST_PP_IIF( \
+ BOOST_DETAIL_PP_KEYWORD_IS_TRAILING_THIS(var), \
+ ::boost::local::aux::add_pointed_const< /* pointed obj const */ \
+ , \
+ ::boost::add_const< /* outer type const */ \
+ ) \
+ BOOST_PP_TUPLE_ELEM(3, 1, id_typename_offset) /* eventual typename */ \
+ ) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_TYPE( \
+ id_typename_offset, i, var) \
+ BOOST_PP_EXPR_IF(const01, >::type) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_RENAME_THIS_(var)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_CONST_BIND_DECL( \
+ r, id_typename_offset, i, var) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_DECL_( \
+ r, id_typename_offset, i, var, 1 /* force const */)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_BIND_DECL( \
+ r, id_typename_offset, i, var) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_DECL_( \
+ r, id_typename_offset, i, var, 0 /* do not force const */)
+
+// Adapted from `BOOST_SCOPE_EXIT_AUX_ARG()`.
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND( \
+ r, id_offset, i, var) \
+ BOOST_PP_COMMA_IF(i) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_MAYBECONST_BIND_VALUE( \
+ id_offset, i, var)
+
+// Unbind param.
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_DECL( \
+ z, param, unused) \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_PARAM_DECL(param)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_DECL_WITH_DEFAULT( \
+ z, param, unused) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_DECL( \
+ z, param, unused) \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_PARAM_HAS_DEFAULT( \
+ param), \
+ = BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_PARAM_DEFAULT \
+ , \
+ BOOST_PP_TUPLE_EAT(1) \
+ )(param)
+
+#define BOOST_LOCAL_AUX_FUNCTION_CODE_PARAM_UNBIND_TYPE_AND_NAME( \
+ z, param, unused) \
+ BOOST_DETAIL_PP_KEYWORD_AUTO_REMOVE( \
+ BOOST_DETAIL_PP_KEYWORD_REGISTER_REMOVE( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_UNBIND_PARAM_DECL(param) \
+ ) \
+ )
+
+#endif // #include guard
+

Added: sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/params.hpp
==============================================================================
--- (empty file)
+++ sandbox/local/libs/local/params_name/boost/local/aux_/function_macros/params.hpp 2011-02-17 15:01:14 EST (Thu, 17 Feb 2011)
@@ -0,0 +1,49 @@
+
+#ifndef BOOST_LOCAL_AUX_FUNCTION_PARAMS_HPP_
+#define BOOST_LOCAL_AUX_FUNCTION_PARAMS_HPP_
+
+#include "code_/binding.hpp"
+#include "code_/functor.hpp"
+#include "code_/deduce_result_type.hpp"
+#include "../preprocessor/sign/parse_params.hpp"
+#include "../preprocessor/sign/params_error.hpp"
+#include <boost/mpl/assert.hpp>
+#include <boost/preprocessor/control/iif.hpp>
+
+// PRIVATE //
+
+#define BOOST_LOCAL_AUX_FUNCTION_PARAMS_OK_(sign_params, id, typename_keyword) \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_BINDING(sign_params, id, typename_keyword) \
+ BOOST_LOCAL_AUX_FUNCTION_BODE_FUNCTOR(sign_params, id, typename_keyword)
+
+#define BOOST_LOCAL_AUX_FUNCTION_PARAMS_ERROR_( \
+ sign_params, id, typename_keyword) \
+ ; /* close eventual previous statements, otherwise it has no effect */ \
+ BOOST_MPL_ASSERT_MSG(false, /* always fails (there's an error) */ \
+ BOOST_LOCAL_AUX_PP_SIGN_PARAMS_ERROR_MSG(sign_params), ()) \
+ ; /* must close ASSERT macro for eventual use within class scope */
+
+// sign_params: parsed parenthesized params.
+#define BOOST_LOCAL_AUX_FUNCTION_PARAMS_(sign_params, id, typename_keyword) \
+ /* this must follow the result type (this code must be always present */ \
+ /* even if there's an error because result type always present) */ \
+ BOOST_LOCAL_AUX_FUNCTION_CODE_DEDUCE_RESULT_TYPE(id, typename_keyword) \
+ /* rest of the code */ \
+ BOOST_PP_IIF(BOOST_LOCAL_AUX_PP_SIGN_PARAMS_HAVE_ERROR(sign_params), \
+ BOOST_LOCAL_AUX_FUNCTION_PARAMS_ERROR_ \
+ , \
+ BOOST_LOCAL_AUX_FUNCTION_PARAMS_OK_ \
+ )(sign_params, id, typename_keyword)
+
+// PUBLIC //
+
+// typename_keyword: `typename` in type depended context (i.e., templates),
+// `EMPTY()` otherwise.
+#define BOOST_LOCAL_AUX_FUNCTION_PARAMS( \
+ parenthesized_params, typename_keyword) \
+ BOOST_LOCAL_AUX_FUNCTION_PARAMS_( \
+ BOOST_LOCAL_AUX_PP_SIGN_PARSE_PARAMS(parenthesized_params), \
+ __LINE__, typename_keyword)
+
+#endif // #include guard
+


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