arg_to_python_base.hpp 957 B

1234567891011121314151617181920212223242526272829303132
  1. // Copyright David Abrahams 2002.
  2. // Distributed under the Boost Software License, Version 1.0. (See
  3. // accompanying file LICENSE_1_0.txt or copy at
  4. // http://www.boost.org/LICENSE_1_0.txt)
  5. #ifndef ARG_TO_PYTHON_BASE_DWA200237_HPP
  6. # define ARG_TO_PYTHON_BASE_DWA200237_HPP
  7. # include <boost/python/handle.hpp>
  8. namespace boost { namespace python { namespace converter {
  9. struct registration;
  10. namespace detail
  11. {
  12. struct BOOST_PYTHON_DECL arg_to_python_base
  13. # if !defined(BOOST_MSVC) || BOOST_MSVC <= 1300 || _MSC_FULL_VER > 13102179
  14. : handle<>
  15. # endif
  16. {
  17. arg_to_python_base(void const volatile* source, registration const&);
  18. # if defined(BOOST_MSVC) && BOOST_MSVC > 1300 && _MSC_FULL_VER <= 13102179
  19. PyObject* get() const { return m_ptr.get(); }
  20. PyObject* release() { return m_ptr.release(); }
  21. private:
  22. handle<> m_ptr;
  23. # endif
  24. };
  25. }
  26. }}} // namespace boost::python::converter
  27. #endif // ARG_TO_PYTHON_BASE_DWA200237_HPP