2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-25 18:32:24 +00:00

Merged changes for #2981, #4166, and #4377 to release branch

[SVN r63523]
This commit is contained in:
Marshall Clow
2010-07-02 15:37:14 +00:00
parent 34b162738f
commit 63a3f188b8
2 changed files with 4 additions and 3 deletions

View File

@@ -101,7 +101,7 @@ namespace boost { namespace python
struct arg
{
template <class T>
arg &perator = (T const &value);
arg &operator = (T const &value);
explicit arg (char const *name){elements[0].name = name;}
};

View File

@@ -167,12 +167,13 @@ PyObject* postcall(PyObject* args, PyObject* result);
class Bar
{
public:
Bar(int x) : x(x) {}
int get_x() const { return x; }
void set_x(int x) { this->x = x; }
private:
int x;
}
};
class Foo
{
@@ -189,7 +190,7 @@ class Foo
using namespace boost::python;
BOOST_PYTHON_MODULE(internal_refs)
{
class_<Bar>("Bar")
class_<Bar>("Bar", init<int>())
.def("get_x", &Bar::get_x)
.def("set_x", &Bar::set_x)
;