From f676cc73067bf135d17de6a5553af177d93fc98d Mon Sep 17 00:00:00 2001 From: Jose Luis Blanco-Claraco Date: Thu, 22 Jun 2023 14:49:15 +0200 Subject: [PATCH] more armhf fixes --- python/patch-006.diff | 225 ++++++++++++++++++++++++++++++++++ python/src/std/stl_deque.cpp | 44 +++---- python/src/std/stl_map.cpp | 32 ++--- python/src/std/stl_vector.cpp | 28 ++--- 4 files changed, 277 insertions(+), 52 deletions(-) create mode 100644 python/patch-006.diff diff --git a/python/patch-006.diff b/python/patch-006.diff new file mode 100644 index 0000000000..d92257df58 --- /dev/null +++ b/python/patch-006.diff @@ -0,0 +1,225 @@ +diff --git a/python/src/std/stl_deque.cpp b/python/src/std/stl_deque.cpp +index 302018560..1638b4d29 100644 +--- a/python/src/std/stl_deque.cpp ++++ b/python/src/std/stl_deque.cpp +@@ -28,26 +28,26 @@ void bind_std_stl_deque(std::function< pybind11::module &(std::string const &nam + cl.def( pybind11::init( [](){ return new std::deque>(); } ) ); + cl.def( pybind11::init > &>(), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); +- cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); ++ cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); +- cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); ++ cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + + cl.def( pybind11::init( [](std::deque> const &o){ return new std::deque>(o); } ) ); + cl.def( pybind11::init > &, const class std::allocator > &>(), pybind11::arg("__x"), pybind11::arg("__a") ); + + cl.def("assign", (class std::deque > & (std::deque>::*)(const class std::deque > &)) &std::deque>::operator=, "C++: std::deque>::operator=(const class std::deque > &) --> class std::deque > &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); +- cl.def("assign", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); ++ cl.def("assign", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("get_allocator", (class std::allocator > (std::deque>::*)() const) &std::deque>::get_allocator, "C++: std::deque>::get_allocator() const --> class std::allocator >"); +- cl.def("size", (unsigned long (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> unsigned long"); +- cl.def("resize", (void (std::deque>::*)(unsigned long)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long) --> void", pybind11::arg("__new_size")); +- cl.def("resize", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); ++ cl.def("size", (size_t (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> size_t"); ++ cl.def("resize", (void (std::deque>::*)(size_t)) &std::deque>::resize, "C++: std::deque>::resize(size_t) --> void", pybind11::arg("__new_size")); ++ cl.def("resize", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("shrink_to_fit", (void (std::deque>::*)()) &std::deque>::shrink_to_fit, "C++: std::deque>::shrink_to_fit() --> void"); + cl.def("empty", (bool (std::deque>::*)() const) &std::deque>::empty, "C++: std::deque>::empty() const --> bool"); +- cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::operator[], "C++: std::deque>::operator[](unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); +- cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::at, "C++: std::deque>::at(unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::operator[], "C++: std::deque>::operator[](size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::at, "C++: std::deque>::at(size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("front", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::front, "C++: std::deque>::front() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); + cl.def("back", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::back, "C++: std::deque>::back() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); + cl.def("push_front", (void (std::deque>::*)(const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::push_front, "C++: std::deque>::push_front(const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__x")); +@@ -62,26 +62,26 @@ void bind_std_stl_deque(std::function< pybind11::module &(std::string const &nam + cl.def( pybind11::init( [](){ return new std::deque>(); } ) ); + cl.def( pybind11::init > &>(), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); +- cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); ++ cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); +- cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); ++ cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + + cl.def( pybind11::init( [](std::deque> const &o){ return new std::deque>(o); } ) ); + cl.def( pybind11::init > &, const class std::allocator > &>(), pybind11::arg("__x"), pybind11::arg("__a") ); + + cl.def("assign", (class std::deque > & (std::deque>::*)(const class std::deque > &)) &std::deque>::operator=, "C++: std::deque>::operator=(const class std::deque > &) --> class std::deque > &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); +- cl.def("assign", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); ++ cl.def("assign", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("get_allocator", (class std::allocator > (std::deque>::*)() const) &std::deque>::get_allocator, "C++: std::deque>::get_allocator() const --> class std::allocator >"); +- cl.def("size", (unsigned long (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> unsigned long"); +- cl.def("resize", (void (std::deque>::*)(unsigned long)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long) --> void", pybind11::arg("__new_size")); +- cl.def("resize", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); ++ cl.def("size", (size_t (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> size_t"); ++ cl.def("resize", (void (std::deque>::*)(size_t)) &std::deque>::resize, "C++: std::deque>::resize(size_t) --> void", pybind11::arg("__new_size")); ++ cl.def("resize", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("shrink_to_fit", (void (std::deque>::*)()) &std::deque>::shrink_to_fit, "C++: std::deque>::shrink_to_fit() --> void"); + cl.def("empty", (bool (std::deque>::*)() const) &std::deque>::empty, "C++: std::deque>::empty() const --> bool"); +- cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::operator[], "C++: std::deque>::operator[](unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); +- cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::at, "C++: std::deque>::at(unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::operator[], "C++: std::deque>::operator[](size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::at, "C++: std::deque>::at(size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("front", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::front, "C++: std::deque>::front() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); + cl.def("back", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::back, "C++: std::deque>::back() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); + cl.def("push_front", (void (std::deque>::*)(const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::push_front, "C++: std::deque>::push_front(const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__x")); +diff --git a/python/src/std/stl_map.cpp b/python/src/std/stl_map.cpp +index 793bf72f3..eb2b18335 100644 +--- a/python/src/std/stl_map.cpp ++++ b/python/src/std/stl_map.cpp +@@ -55,16 +55,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names + cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); + cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); + cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); +- cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); ++ cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); + cl.def("__getitem__", (std::string & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("at", (std::string & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); +- cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); ++ cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); + cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); + cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); + cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); +- cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); ++ cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); + cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); + } + { // std::map file:bits/stl_map.h line:100 +@@ -81,16 +81,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names + cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); + cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); + cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); +- cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); ++ cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); + cl.def("__getitem__", (double & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("at", (double & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); +- cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); ++ cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); + cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); + cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); + cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); +- cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); ++ cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); + cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); + } + { // std::map file:bits/stl_map.h line:100 +@@ -107,16 +107,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names + cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); + cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); + cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); +- cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); ++ cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); + cl.def("__getitem__", (double & (std::map::*)(const double &)) &std::map::operator[], "C++: std::map::operator[](const double &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("at", (double & (std::map::*)(const double &)) &std::map::at, "C++: std::map::at(const double &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); +- cl.def("erase", (unsigned long (std::map::*)(const double &)) &std::map::erase, "C++: std::map::erase(const double &) --> unsigned long", pybind11::arg("__x")); ++ cl.def("erase", (size_t (std::map::*)(const double &)) &std::map::erase, "C++: std::map::erase(const double &) --> size_t", pybind11::arg("__x")); + cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); + cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); + cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); +- cl.def("count", (unsigned long (std::map::*)(const double &) const) &std::map::count, "C++: std::map::count(const double &) const --> unsigned long", pybind11::arg("__x")); ++ cl.def("count", (size_t (std::map::*)(const double &) const) &std::map::count, "C++: std::map::count(const double &) const --> size_t", pybind11::arg("__x")); + cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const double &)) &std::map::equal_range, "C++: std::map::equal_range(const double &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); + } + { // std::map file:bits/stl_map.h line:100 +@@ -133,16 +133,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names + cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); + cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); + cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); +- cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); ++ cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); + cl.def("__getitem__", (class mrpt::poses::CPose3D & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> class mrpt::poses::CPose3D &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("at", (class mrpt::poses::CPose3D & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> class mrpt::poses::CPose3D &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); + cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); +- cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); ++ cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); + cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); + cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); + cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); +- cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); ++ cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); + cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); + } + } +diff --git a/python/src/std/stl_vector.cpp b/python/src/std/stl_vector.cpp +index e9110c758..f4c9f4013 100644 +--- a/python/src/std/stl_vector.cpp ++++ b/python/src/std/stl_vector.cpp +@@ -26,38 +26,38 @@ void bind_std_stl_vector(std::function< pybind11::module &(std::string const &na + cl.def( pybind11::init( [](){ return new std::vector(); } ) ); + cl.def( pybind11::init &>(), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0){ return new std::vector(a0); } ), "doc" , pybind11::arg("__n")); +- cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0){ return new std::vector(a0); } ), "doc" , pybind11::arg("__n")); ++ cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + +- cl.def( pybind11::init( [](unsigned long const & a0, const std::string & a1){ return new std::vector(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); +- cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); ++ cl.def( pybind11::init( [](size_t const & a0, const std::string & a1){ return new std::vector(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); ++ cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + + cl.def( pybind11::init( [](std::vector const &o){ return new std::vector(o); } ) ); + cl.def( pybind11::init &, const class std::allocator &>(), pybind11::arg("__x"), pybind11::arg("__a") ); + + cl.def("assign", (class std::vector & (std::vector::*)(const class std::vector &)) &std::vector::operator=, "C++: std::vector::operator=(const class std::vector &) --> class std::vector &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); +- cl.def("assign", (void (std::vector::*)(unsigned long, const std::string &)) &std::vector::assign, "C++: std::vector::assign(unsigned long, const std::string &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); ++ cl.def("assign", (void (std::vector::*)(size_t, const std::string &)) &std::vector::assign, "C++: std::vector::assign(size_t, const std::string &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("begin", (class __gnu_cxx::__normal_iterator > (std::vector::*)()) &std::vector::begin, "C++: std::vector::begin() --> class __gnu_cxx::__normal_iterator >"); + cl.def("end", (class __gnu_cxx::__normal_iterator > (std::vector::*)()) &std::vector::end, "C++: std::vector::end() --> class __gnu_cxx::__normal_iterator >"); + cl.def("cbegin", (class __gnu_cxx::__normal_iterator > (std::vector::*)() const) &std::vector::cbegin, "C++: std::vector::cbegin() const --> class __gnu_cxx::__normal_iterator >"); + cl.def("cend", (class __gnu_cxx::__normal_iterator > (std::vector::*)() const) &std::vector::cend, "C++: std::vector::cend() const --> class __gnu_cxx::__normal_iterator >"); +- cl.def("size", (unsigned long (std::vector::*)() const) &std::vector::size, "C++: std::vector::size() const --> unsigned long"); +- cl.def("max_size", (unsigned long (std::vector::*)() const) &std::vector::max_size, "C++: std::vector::max_size() const --> unsigned long"); +- cl.def("resize", (void (std::vector::*)(unsigned long)) &std::vector::resize, "C++: std::vector::resize(unsigned long) --> void", pybind11::arg("__new_size")); +- cl.def("resize", (void (std::vector::*)(unsigned long, const std::string &)) &std::vector::resize, "C++: std::vector::resize(unsigned long, const std::string &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); ++ cl.def("size", (size_t (std::vector::*)() const) &std::vector::size, "C++: std::vector::size() const --> size_t"); ++ cl.def("max_size", (size_t (std::vector::*)() const) &std::vector::max_size, "C++: std::vector::max_size() const --> size_t"); ++ cl.def("resize", (void (std::vector::*)(size_t)) &std::vector::resize, "C++: std::vector::resize(size_t) --> void", pybind11::arg("__new_size")); ++ cl.def("resize", (void (std::vector::*)(size_t, const std::string &)) &std::vector::resize, "C++: std::vector::resize(size_t, const std::string &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("shrink_to_fit", (void (std::vector::*)()) &std::vector::shrink_to_fit, "C++: std::vector::shrink_to_fit() --> void"); +- cl.def("capacity", (unsigned long (std::vector::*)() const) &std::vector::capacity, "C++: std::vector::capacity() const --> unsigned long"); ++ cl.def("capacity", (size_t (std::vector::*)() const) &std::vector::capacity, "C++: std::vector::capacity() const --> size_t"); + cl.def("empty", (bool (std::vector::*)() const) &std::vector::empty, "C++: std::vector::empty() const --> bool"); +- cl.def("reserve", (void (std::vector::*)(unsigned long)) &std::vector::reserve, "C++: std::vector::reserve(unsigned long) --> void", pybind11::arg("__n")); +- cl.def("__getitem__", (std::string & (std::vector::*)(unsigned long)) &std::vector::operator[], "C++: std::vector::operator[](unsigned long) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); +- cl.def("at", (std::string & (std::vector::*)(unsigned long)) &std::vector::at, "C++: std::vector::at(unsigned long) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("reserve", (void (std::vector::*)(size_t)) &std::vector::reserve, "C++: std::vector::reserve(size_t) --> void", pybind11::arg("__n")); ++ cl.def("__getitem__", (std::string & (std::vector::*)(size_t)) &std::vector::operator[], "C++: std::vector::operator[](size_t) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); ++ cl.def("at", (std::string & (std::vector::*)(size_t)) &std::vector::at, "C++: std::vector::at(size_t) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("front", (std::string & (std::vector::*)()) &std::vector::front, "C++: std::vector::front() --> std::string &", pybind11::return_value_policy::automatic); + cl.def("back", (std::string & (std::vector::*)()) &std::vector::back, "C++: std::vector::back() --> std::string &", pybind11::return_value_policy::automatic); + cl.def("data", (std::string * (std::vector::*)()) &std::vector::data, "C++: std::vector::data() --> std::string *", pybind11::return_value_policy::automatic); + cl.def("push_back", (void (std::vector::*)(const std::string &)) &std::vector::push_back, "C++: std::vector::push_back(const std::string &) --> void", pybind11::arg("__x")); + cl.def("pop_back", (void (std::vector::*)()) &std::vector::pop_back, "C++: std::vector::pop_back() --> void"); + cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__x")); +- cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, unsigned long, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, unsigned long, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__n"), pybind11::arg("__x")); ++ cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, size_t, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, size_t, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__n"), pybind11::arg("__x")); + cl.def("erase", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >)) &std::vector::erase, "C++: std::vector::erase(class __gnu_cxx::__normal_iterator >) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position")); + cl.def("erase", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, class __gnu_cxx::__normal_iterator >)) &std::vector::erase, "C++: std::vector::erase(class __gnu_cxx::__normal_iterator >, class __gnu_cxx::__normal_iterator >) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__first"), pybind11::arg("__last")); + cl.def("swap", (void (std::vector::*)(class std::vector &)) &std::vector::swap, "C++: std::vector::swap(class std::vector &) --> void", pybind11::arg("__x")); diff --git a/python/src/std/stl_deque.cpp b/python/src/std/stl_deque.cpp index 302018560c..1638b4d296 100644 --- a/python/src/std/stl_deque.cpp +++ b/python/src/std/stl_deque.cpp @@ -28,26 +28,26 @@ void bind_std_stl_deque(std::function< pybind11::module &(std::string const &nam cl.def( pybind11::init( [](){ return new std::deque>(); } ) ); cl.def( pybind11::init > &>(), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); - cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); + cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); - cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); + cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); cl.def( pybind11::init( [](std::deque> const &o){ return new std::deque>(o); } ) ); cl.def( pybind11::init > &, const class std::allocator > &>(), pybind11::arg("__x"), pybind11::arg("__a") ); cl.def("assign", (class std::deque > & (std::deque>::*)(const class std::deque > &)) &std::deque>::operator=, "C++: std::deque>::operator=(const class std::deque > &) --> class std::deque > &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); - cl.def("assign", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("assign", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); cl.def("get_allocator", (class std::allocator > (std::deque>::*)() const) &std::deque>::get_allocator, "C++: std::deque>::get_allocator() const --> class std::allocator >"); - cl.def("size", (unsigned long (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> unsigned long"); - cl.def("resize", (void (std::deque>::*)(unsigned long)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long) --> void", pybind11::arg("__new_size")); - cl.def("resize", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("size", (size_t (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> size_t"); + cl.def("max_size", (size_t (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> size_t"); + cl.def("resize", (void (std::deque>::*)(size_t)) &std::deque>::resize, "C++: std::deque>::resize(size_t) --> void", pybind11::arg("__new_size")); + cl.def("resize", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); cl.def("shrink_to_fit", (void (std::deque>::*)()) &std::deque>::shrink_to_fit, "C++: std::deque>::shrink_to_fit() --> void"); cl.def("empty", (bool (std::deque>::*)() const) &std::deque>::empty, "C++: std::deque>::empty() const --> bool"); - cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::operator[], "C++: std::deque>::operator[](unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); - cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::at, "C++: std::deque>::at(unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::operator[], "C++: std::deque>::operator[](size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::at, "C++: std::deque>::at(size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); cl.def("front", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::front, "C++: std::deque>::front() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); cl.def("back", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::back, "C++: std::deque>::back() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); cl.def("push_front", (void (std::deque>::*)(const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::push_front, "C++: std::deque>::push_front(const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__x")); @@ -62,26 +62,26 @@ void bind_std_stl_deque(std::function< pybind11::module &(std::string const &nam cl.def( pybind11::init( [](){ return new std::deque>(); } ) ); cl.def( pybind11::init > &>(), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); - cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0){ return new std::deque>(a0); } ), "doc" , pybind11::arg("__n")); + cl.def( pybind11::init > &>(), pybind11::arg("__n"), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); - cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0, const struct mrpt::bayes::CProbabilityParticle & a1){ return new std::deque>(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); + cl.def( pybind11::init &, const class std::allocator > &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); cl.def( pybind11::init( [](std::deque> const &o){ return new std::deque>(o); } ) ); cl.def( pybind11::init > &, const class std::allocator > &>(), pybind11::arg("__x"), pybind11::arg("__a") ); cl.def("assign", (class std::deque > & (std::deque>::*)(const class std::deque > &)) &std::deque>::operator=, "C++: std::deque>::operator=(const class std::deque > &) --> class std::deque > &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); - cl.def("assign", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("assign", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::assign, "C++: std::deque>::assign(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); cl.def("get_allocator", (class std::allocator > (std::deque>::*)() const) &std::deque>::get_allocator, "C++: std::deque>::get_allocator() const --> class std::allocator >"); - cl.def("size", (unsigned long (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> unsigned long"); - cl.def("resize", (void (std::deque>::*)(unsigned long)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long) --> void", pybind11::arg("__new_size")); - cl.def("resize", (void (std::deque>::*)(unsigned long, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(unsigned long, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("size", (size_t (std::deque>::*)() const) &std::deque>::size, "C++: std::deque>::size() const --> size_t"); + cl.def("max_size", (size_t (std::deque>::*)() const) &std::deque>::max_size, "C++: std::deque>::max_size() const --> size_t"); + cl.def("resize", (void (std::deque>::*)(size_t)) &std::deque>::resize, "C++: std::deque>::resize(size_t) --> void", pybind11::arg("__new_size")); + cl.def("resize", (void (std::deque>::*)(size_t, const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::resize, "C++: std::deque>::resize(size_t, const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); cl.def("shrink_to_fit", (void (std::deque>::*)()) &std::deque>::shrink_to_fit, "C++: std::deque>::shrink_to_fit() --> void"); cl.def("empty", (bool (std::deque>::*)() const) &std::deque>::empty, "C++: std::deque>::empty() const --> bool"); - cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::operator[], "C++: std::deque>::operator[](unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); - cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(unsigned long)) &std::deque>::at, "C++: std::deque>::at(unsigned long) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("__getitem__", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::operator[], "C++: std::deque>::operator[](size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("at", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)(size_t)) &std::deque>::at, "C++: std::deque>::at(size_t) --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); cl.def("front", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::front, "C++: std::deque>::front() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); cl.def("back", (struct mrpt::bayes::CProbabilityParticle & (std::deque>::*)()) &std::deque>::back, "C++: std::deque>::back() --> struct mrpt::bayes::CProbabilityParticle &", pybind11::return_value_policy::automatic); cl.def("push_front", (void (std::deque>::*)(const struct mrpt::bayes::CProbabilityParticle &)) &std::deque>::push_front, "C++: std::deque>::push_front(const struct mrpt::bayes::CProbabilityParticle &) --> void", pybind11::arg("__x")); diff --git a/python/src/std/stl_map.cpp b/python/src/std/stl_map.cpp index 793bf72f31..eb2b183358 100644 --- a/python/src/std/stl_map.cpp +++ b/python/src/std/stl_map.cpp @@ -55,16 +55,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); - cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); + cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); + cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); cl.def("__getitem__", (std::string & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("at", (std::string & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); - cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); + cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); - cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); + cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); } { // std::map file:bits/stl_map.h line:100 @@ -81,16 +81,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); - cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); + cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); + cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); cl.def("__getitem__", (double & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("at", (double & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); - cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); + cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); - cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); + cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); } { // std::map file:bits/stl_map.h line:100 @@ -107,16 +107,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); - cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); + cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); + cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); cl.def("__getitem__", (double & (std::map::*)(const double &)) &std::map::operator[], "C++: std::map::operator[](const double &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("at", (double & (std::map::*)(const double &)) &std::map::at, "C++: std::map::at(const double &) --> double &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); - cl.def("erase", (unsigned long (std::map::*)(const double &)) &std::map::erase, "C++: std::map::erase(const double &) --> unsigned long", pybind11::arg("__x")); + cl.def("erase", (size_t (std::map::*)(const double &)) &std::map::erase, "C++: std::map::erase(const double &) --> size_t", pybind11::arg("__x")); cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); - cl.def("count", (unsigned long (std::map::*)(const double &) const) &std::map::count, "C++: std::map::count(const double &) const --> unsigned long", pybind11::arg("__x")); + cl.def("count", (size_t (std::map::*)(const double &) const) &std::map::count, "C++: std::map::count(const double &) const --> size_t", pybind11::arg("__x")); cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const double &)) &std::map::equal_range, "C++: std::map::equal_range(const double &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); } { // std::map file:bits/stl_map.h line:100 @@ -133,16 +133,16 @@ void bind_std_stl_map(std::function< pybind11::module &(std::string const &names cl.def("assign", (class std::map & (std::map::*)(const class std::map &)) &std::map::operator=, "C++: std::map::operator=(const class std::map &) --> class std::map &", pybind11::return_value_policy::automatic, pybind11::arg("")); cl.def("get_allocator", (class std::allocator > (std::map::*)() const) &std::map::get_allocator, "C++: std::map::get_allocator() const --> class std::allocator >"); cl.def("empty", (bool (std::map::*)() const) &std::map::empty, "C++: std::map::empty() const --> bool"); - cl.def("size", (unsigned long (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> unsigned long"); + cl.def("size", (size_t (std::map::*)() const) &std::map::size, "C++: std::map::size() const --> size_t"); + cl.def("max_size", (size_t (std::map::*)() const) &std::map::max_size, "C++: std::map::max_size() const --> size_t"); cl.def("__getitem__", (class mrpt::poses::CPose3D & (std::map::*)(const std::string &)) &std::map::operator[], "C++: std::map::operator[](const std::string &) --> class mrpt::poses::CPose3D &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("at", (class mrpt::poses::CPose3D & (std::map::*)(const std::string &)) &std::map::at, "C++: std::map::at(const std::string &) --> class mrpt::poses::CPose3D &", pybind11::return_value_policy::automatic, pybind11::arg("__k")); cl.def("insert", (struct std::pair >, bool> (std::map::*)(const struct std::pair &)) &std::map::insert, "C++: std::map::insert(const struct std::pair &) --> struct std::pair >, bool>", pybind11::arg("__x")); - cl.def("erase", (unsigned long (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> unsigned long", pybind11::arg("__x")); + cl.def("erase", (size_t (std::map::*)(const std::string &)) &std::map::erase, "C++: std::map::erase(const std::string &) --> size_t", pybind11::arg("__x")); cl.def("swap", (void (std::map::*)(class std::map &)) &std::map::swap, "C++: std::map::swap(class std::map &) --> void", pybind11::arg("__x")); cl.def("clear", (void (std::map::*)()) &std::map::clear, "C++: std::map::clear() --> void"); cl.def("key_comp", (struct std::less (std::map::*)() const) &std::map::key_comp, "C++: std::map::key_comp() const --> struct std::less"); - cl.def("count", (unsigned long (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> unsigned long", pybind11::arg("__x")); + cl.def("count", (size_t (std::map::*)(const std::string &) const) &std::map::count, "C++: std::map::count(const std::string &) const --> size_t", pybind11::arg("__x")); cl.def("equal_range", (struct std::pair >, struct std::_Rb_tree_iterator > > (std::map::*)(const std::string &)) &std::map::equal_range, "C++: std::map::equal_range(const std::string &) --> struct std::pair >, struct std::_Rb_tree_iterator > >", pybind11::arg("__x")); } } diff --git a/python/src/std/stl_vector.cpp b/python/src/std/stl_vector.cpp index e9110c7580..f4c9f40137 100644 --- a/python/src/std/stl_vector.cpp +++ b/python/src/std/stl_vector.cpp @@ -26,38 +26,38 @@ void bind_std_stl_vector(std::function< pybind11::module &(std::string const &na cl.def( pybind11::init( [](){ return new std::vector(); } ) ); cl.def( pybind11::init &>(), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0){ return new std::vector(a0); } ), "doc" , pybind11::arg("__n")); - cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0){ return new std::vector(a0); } ), "doc" , pybind11::arg("__n")); + cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__a") ); - cl.def( pybind11::init( [](unsigned long const & a0, const std::string & a1){ return new std::vector(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); - cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); + cl.def( pybind11::init( [](size_t const & a0, const std::string & a1){ return new std::vector(a0, a1); } ), "doc" , pybind11::arg("__n"), pybind11::arg("__value")); + cl.def( pybind11::init &>(), pybind11::arg("__n"), pybind11::arg("__value"), pybind11::arg("__a") ); cl.def( pybind11::init( [](std::vector const &o){ return new std::vector(o); } ) ); cl.def( pybind11::init &, const class std::allocator &>(), pybind11::arg("__x"), pybind11::arg("__a") ); cl.def("assign", (class std::vector & (std::vector::*)(const class std::vector &)) &std::vector::operator=, "C++: std::vector::operator=(const class std::vector &) --> class std::vector &", pybind11::return_value_policy::automatic, pybind11::arg("__x")); - cl.def("assign", (void (std::vector::*)(unsigned long, const std::string &)) &std::vector::assign, "C++: std::vector::assign(unsigned long, const std::string &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); + cl.def("assign", (void (std::vector::*)(size_t, const std::string &)) &std::vector::assign, "C++: std::vector::assign(size_t, const std::string &) --> void", pybind11::arg("__n"), pybind11::arg("__val")); cl.def("begin", (class __gnu_cxx::__normal_iterator > (std::vector::*)()) &std::vector::begin, "C++: std::vector::begin() --> class __gnu_cxx::__normal_iterator >"); cl.def("end", (class __gnu_cxx::__normal_iterator > (std::vector::*)()) &std::vector::end, "C++: std::vector::end() --> class __gnu_cxx::__normal_iterator >"); cl.def("cbegin", (class __gnu_cxx::__normal_iterator > (std::vector::*)() const) &std::vector::cbegin, "C++: std::vector::cbegin() const --> class __gnu_cxx::__normal_iterator >"); cl.def("cend", (class __gnu_cxx::__normal_iterator > (std::vector::*)() const) &std::vector::cend, "C++: std::vector::cend() const --> class __gnu_cxx::__normal_iterator >"); - cl.def("size", (unsigned long (std::vector::*)() const) &std::vector::size, "C++: std::vector::size() const --> unsigned long"); - cl.def("max_size", (unsigned long (std::vector::*)() const) &std::vector::max_size, "C++: std::vector::max_size() const --> unsigned long"); - cl.def("resize", (void (std::vector::*)(unsigned long)) &std::vector::resize, "C++: std::vector::resize(unsigned long) --> void", pybind11::arg("__new_size")); - cl.def("resize", (void (std::vector::*)(unsigned long, const std::string &)) &std::vector::resize, "C++: std::vector::resize(unsigned long, const std::string &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); + cl.def("size", (size_t (std::vector::*)() const) &std::vector::size, "C++: std::vector::size() const --> size_t"); + cl.def("max_size", (size_t (std::vector::*)() const) &std::vector::max_size, "C++: std::vector::max_size() const --> size_t"); + cl.def("resize", (void (std::vector::*)(size_t)) &std::vector::resize, "C++: std::vector::resize(size_t) --> void", pybind11::arg("__new_size")); + cl.def("resize", (void (std::vector::*)(size_t, const std::string &)) &std::vector::resize, "C++: std::vector::resize(size_t, const std::string &) --> void", pybind11::arg("__new_size"), pybind11::arg("__x")); cl.def("shrink_to_fit", (void (std::vector::*)()) &std::vector::shrink_to_fit, "C++: std::vector::shrink_to_fit() --> void"); - cl.def("capacity", (unsigned long (std::vector::*)() const) &std::vector::capacity, "C++: std::vector::capacity() const --> unsigned long"); + cl.def("capacity", (size_t (std::vector::*)() const) &std::vector::capacity, "C++: std::vector::capacity() const --> size_t"); cl.def("empty", (bool (std::vector::*)() const) &std::vector::empty, "C++: std::vector::empty() const --> bool"); - cl.def("reserve", (void (std::vector::*)(unsigned long)) &std::vector::reserve, "C++: std::vector::reserve(unsigned long) --> void", pybind11::arg("__n")); - cl.def("__getitem__", (std::string & (std::vector::*)(unsigned long)) &std::vector::operator[], "C++: std::vector::operator[](unsigned long) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); - cl.def("at", (std::string & (std::vector::*)(unsigned long)) &std::vector::at, "C++: std::vector::at(unsigned long) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("reserve", (void (std::vector::*)(size_t)) &std::vector::reserve, "C++: std::vector::reserve(size_t) --> void", pybind11::arg("__n")); + cl.def("__getitem__", (std::string & (std::vector::*)(size_t)) &std::vector::operator[], "C++: std::vector::operator[](size_t) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); + cl.def("at", (std::string & (std::vector::*)(size_t)) &std::vector::at, "C++: std::vector::at(size_t) --> std::string &", pybind11::return_value_policy::automatic, pybind11::arg("__n")); cl.def("front", (std::string & (std::vector::*)()) &std::vector::front, "C++: std::vector::front() --> std::string &", pybind11::return_value_policy::automatic); cl.def("back", (std::string & (std::vector::*)()) &std::vector::back, "C++: std::vector::back() --> std::string &", pybind11::return_value_policy::automatic); cl.def("data", (std::string * (std::vector::*)()) &std::vector::data, "C++: std::vector::data() --> std::string *", pybind11::return_value_policy::automatic); cl.def("push_back", (void (std::vector::*)(const std::string &)) &std::vector::push_back, "C++: std::vector::push_back(const std::string &) --> void", pybind11::arg("__x")); cl.def("pop_back", (void (std::vector::*)()) &std::vector::pop_back, "C++: std::vector::pop_back() --> void"); cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__x")); - cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, unsigned long, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, unsigned long, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__n"), pybind11::arg("__x")); + cl.def("insert", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, size_t, const std::string &)) &std::vector::insert, "C++: std::vector::insert(class __gnu_cxx::__normal_iterator >, size_t, const std::string &) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position"), pybind11::arg("__n"), pybind11::arg("__x")); cl.def("erase", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >)) &std::vector::erase, "C++: std::vector::erase(class __gnu_cxx::__normal_iterator >) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__position")); cl.def("erase", (class __gnu_cxx::__normal_iterator > (std::vector::*)(class __gnu_cxx::__normal_iterator >, class __gnu_cxx::__normal_iterator >)) &std::vector::erase, "C++: std::vector::erase(class __gnu_cxx::__normal_iterator >, class __gnu_cxx::__normal_iterator >) --> class __gnu_cxx::__normal_iterator >", pybind11::arg("__first"), pybind11::arg("__last")); cl.def("swap", (void (std::vector::*)(class std::vector &)) &std::vector::swap, "C++: std::vector::swap(class std::vector &) --> void", pybind11::arg("__x"));