static void construct(void * s, boost::python::handle<> i) { new (s) T(); T * a=static_cast<T *>(s); while (true) { boost::python::handle<> e(boost::python::allow_null(PyIter_Next(i.get()))); if (!e.get()) break; boost::python::object o(e); boost::python::extract<IT> p(o); H()(*a, p()); } }
static RT getNextValue(boost::python::handle<> i) { boost::python::handle<> e(boost::python::allow_null(PyIter_Next(i.get()))); if (!e.get()) boost::python::throw_error_already_set(); boost::python::object o(e); return boost::python::extract<RT>(o); }
bool TfPyIsNone(boost::python::handle<> const &obj) { return !obj.get() || obj.get() == Py_None; }