/usr/include/boost/python/detail
NameSizeModeActions
aix_init_module.hpp7400644editdlrm
api_placeholder.hpp5040644editdlrm
borrowed_ptr.hpp16970644editdlrm
caller.hpp85900644editdlrm
config.hpp44570644editdlrm
construct.hpp9750644editdlrm
convertible.hpp12300644editdlrm
copy_ctor_mutates_rhs.hpp5800644editdlrm
cv_category.hpp10380644editdlrm
dealloc.hpp5430644editdlrm
decorated_type_id.hpp24510644editdlrm
decref_guard.hpp5720644editdlrm
defaults_def.hpp91660644editdlrm
defaults_gen.hpp200650644editdlrm
def_helper.hpp65310644editdlrm
def_helper_fwd.hpp5750644editdlrm
dependent.hpp9490644editdlrm
destroy.hpp14910644editdlrm
enable_if.hpp9270644editdlrm
exception_handler.hpp12640644editdlrm
force_instantiate.hpp5760644editdlrm
if_else.hpp13930644editdlrm
indirect_traits.hpp4900644editdlrm
invoke.hpp36720644editdlrm
is_auto_ptr.hpp6630644editdlrm
is_shared_ptr.hpp6830644editdlrm
is_wrapper.hpp8390644editdlrm
is_xxx.hpp4440644editdlrm
make_keyword_range_fn.hpp25410644editdlrm
make_tuple.hpp10390644editdlrm
map_entry.hpp10250644editdlrm
mpl_lambda.hpp4480644editdlrm
msvc_typeinfo.hpp22170644editdlrm
none.hpp5970644editdlrm
not_specified.hpp4310644editdlrm
nullary_function_adaptor.hpp17680644editdlrm
operator_id.hpp10640644editdlrm
overloads_fwd.hpp6090644editdlrm
pointee.hpp7910644editdlrm
prefix.hpp6230644editdlrm
preprocessor.hpp23590644editdlrm
python_type.hpp9360644editdlrm
raw_pyobject.hpp11000644editdlrm
referent_storage.hpp19800644editdlrm
result.hpp42070644editdlrm
scope.hpp5190644editdlrm
sfinae.hpp4210644editdlrm
signature.hpp31360644editdlrm
string_literal.hpp12680644editdlrm
target.hpp29720644editdlrm
translate_exception.hpp21950644editdlrm
type_list.hpp12620644editdlrm
type_list_impl.hpp18260644editdlrm
type_traits.hpp33300644editdlrm
unwind_type.hpp48850644editdlrm
unwrap_type_id.hpp7060644editdlrm
unwrap_wrapper.hpp8840644editdlrm
value_arg.hpp7270644editdlrm
value_is_shared_ptr.hpp8100644editdlrm
value_is_xxx.hpp15540644editdlrm
void_ptr.hpp9820644editdlrm
void_return.hpp9800644editdlrm
wrapper_base.hpp20720644editdlrm
wrap_python.hpp65400644editdlrm
Edit: /usr/include/boost/python/detail/def_helper.hpp (6531B)
// Copyright David Abrahams 2002. // Distributed under the Boost Software License, Version 1.0. (See // accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) #ifndef DEF_HELPER_DWA200287_HPP # define DEF_HELPER_DWA200287_HPP # include # include # include # include # include # include # include # include # include # include # include namespace boost { namespace python { struct default_call_policies; namespace detail { // tuple_extract::extract(t) returns the first // element of a Tuple whose type E satisfies the given Predicate // applied to add_reference. The Predicate must be an MPL // metafunction class. template struct tuple_extract; // Implementation class for when the tuple's head type does not // satisfy the Predicate template struct tuple_extract_impl { template struct apply { typedef typename Tuple::head_type result_type; static typename Tuple::head_type extract(Tuple const& x) { return x.get_head(); } }; }; // Implementation specialization for when the tuple's head type // satisfies the predicate template <> struct tuple_extract_impl { template struct apply { // recursive application of tuple_extract on the tail of the tuple typedef tuple_extract next; typedef typename next::result_type result_type; static result_type extract(Tuple const& x) { return next::extract(x.get_tail()); } }; }; // A metafunction which selects a version of tuple_extract_impl to // use for the implementation of tuple_extract template struct tuple_extract_base_select { typedef typename Tuple::head_type head_type; typedef typename mpl::apply1::type>::type match_t; BOOST_STATIC_CONSTANT(bool, match = match_t::value); typedef typename tuple_extract_impl::template apply type; }; template struct tuple_extract : tuple_extract_base_select< Tuple , typename mpl::lambda::type >::type { }; // // Specialized extractors for the docstring, keywords, CallPolicies, // and default implementation of virtual functions // template struct doc_extract : tuple_extract< Tuple , mpl::not_< mpl::or_< indirect_traits::is_reference_to_class , indirect_traits::is_reference_to_member_function_pointer > > > { }; template struct keyword_extract : tuple_extract > { }; template struct policy_extract : tuple_extract< Tuple , mpl::and_< mpl::not_ > , indirect_traits::is_reference_to_class , mpl::not_ > > > { }; template struct default_implementation_extract : tuple_extract< Tuple , indirect_traits::is_reference_to_member_function_pointer > { }; // // A helper class for decoding the optional arguments to def() // invocations, which can be supplied in any order and are // discriminated by their type properties. The template parameters // are expected to be the types of the actual (optional) arguments // passed to def(). // template struct def_helper { // A tuple type which begins with references to the supplied // arguments and ends with actual representatives of the default // types. typedef boost::tuples::tuple< T1 const& , T2 const& , T3 const& , T4 const& , default_call_policies , detail::keywords<0> , char const* , void(not_specified::*)() // A function pointer type which is never an // appropriate default implementation > all_t; // Constructors; these initialize an member of the tuple type // shown above. def_helper(T1 const& a1) : m_all(a1,m_nil,m_nil,m_nil) {} def_helper(T1 const& a1, T2 const& a2) : m_all(a1,a2,m_nil,m_nil) {} def_helper(T1 const& a1, T2 const& a2, T3 const& a3) : m_all(a1,a2,a3,m_nil) {} def_helper(T1 const& a1, T2 const& a2, T3 const& a3, T4 const& a4) : m_all(a1,a2,a3,a4) {} private: // types typedef typename default_implementation_extract::result_type default_implementation_t; public: // Constants which can be used for static assertions. // Users must not supply a default implementation for non-class // methods. BOOST_STATIC_CONSTANT( bool, has_default_implementation = ( !is_same::value)); public: // Extractor functions which pull the appropriate value out // of the tuple char const* doc() const { return doc_extract::extract(m_all); } typename keyword_extract::result_type keywords() const { return keyword_extract::extract(m_all); } typename policy_extract::result_type policies() const { return policy_extract::extract(m_all); } default_implementation_t default_implementation() const { return default_implementation_extract::extract(m_all); } private: // data members all_t m_all; not_specified m_nil; // for filling in not_specified slots }; } }} // namespace boost::python::detail #endif // DEF_HELPER_DWA200287_HPP