...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
|
Boost.PythonNews/Change Log |
std::wstring
conversionsstd::out_of_range
=> Python
IndexError
exception conversion, thanks to Raoul Goughstr
'\0'
) characters.operator()
); see the make_function docs for
more info.properties
unit tests contributed by Roman Yakovenko and documented
add_static_property
at his urging.arg
class contributed by Nikolay Mladenov which supplies the
ability to wrap functions that can be called with ommitted arguments
in the middle:
void f(int x = 0, double y = 3.14, std::string z = std::string("foo")); BOOST_PYTHON_MODULE(test) { def("f", f , (arg("x", 0), arg("y", 3.14), arg("z", "foo"))); }And in Python:
>>> import test >>> f(0, z = "bar") >>> f(z = "bar", y = 0.0)Thanks, Nikolay!
return_arg
policy from Nikolay Mladenov. Thanks,
Nikolay!boost::shared_ptr
. Now
any wrapped object of C++ class X
can be converted
automatically to shared_ptr<X>
, regardless of how it
was wrapped. The shared_ptr
will manage the lifetime of
the Python object which supplied the X
, rather than just
the X
object itself, and when such a
shared_ptr
is converted back to Python, the original
Python object will be returned.staticmethod
support from Nikolay Mladenov. Thanks,
Nikolay!enum_
values into enclosing
scope
.signed long
.make_getter
std::auto_ptr<>
added.Revised 11 September 2003
© Copyright Dave Abrahams 2002-2003. All Rights Reserved.