From 88c03a6ef422b0e84d6eb4966e783e026840988e Mon Sep 17 00:00:00 2001 From: Raoul Gough Date: Fri, 24 Oct 2003 18:06:45 +0000 Subject: [PATCH] Split value_traits specialization out of element_proxy.hpp [SVN r20478] --- .../suite/indexing/element_proxy_traits.hpp | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100755 include/boost/python/suite/indexing/element_proxy_traits.hpp diff --git a/include/boost/python/suite/indexing/element_proxy_traits.hpp b/include/boost/python/suite/indexing/element_proxy_traits.hpp new file mode 100755 index 00000000..a45d8a3a --- /dev/null +++ b/include/boost/python/suite/indexing/element_proxy_traits.hpp @@ -0,0 +1,42 @@ +// +// Header file element_proxy_traits.hpp +// +// Copyright (c) 2003 Raoul M. Gough +// +// Use, modification and distribution is subject to 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) +// +// History +// ======= +// 2003/10/23 rmg File creation +// +// $Id$ +// + +#ifndef BOOST_PYTHON_INDEXING_ELEMENT_PROXY_TRAITS_HPP +#define BOOST_PYTHON_INDEXING_ELEMENT_PROXY_TRAITS_HPP + +#include +#include +#include +#include + +namespace boost { namespace python { namespace indexing { + template + struct value_traits > + : public value_traits + { + template + static void visitor_helper (PythonClass &, Policy const &) + { + typedef element_proxy element_proxy_; + typedef typename ContainerProxy::raw_value_type raw_value_type; + + boost::python::register_ptr_to_python(); + boost::python::implicitly_convertible(); + } + }; +} } } + +#endif // BOOST_PYTHON_INDEXING_ELEMENT_PROXY_TRAITS_HPP