fixed nasty memory bug in pybind11, appearing only with python 2.7 but also potentially affecting 3.x
This commit is contained in:
+20
-24
@@ -53,19 +53,16 @@ m.def("slice", []
|
||||
}, __doc_igl_slice,
|
||||
py::arg("X"), py::arg("R"), py::arg("Y"));
|
||||
|
||||
// // TODO: problematic!
|
||||
// m.def("slice", []
|
||||
// (
|
||||
// const Eigen::MatrixXd& X,
|
||||
// const Eigen::MatrixXi& R
|
||||
// )
|
||||
// {
|
||||
// std::cerr << "Maybe also here?" << std::endl;
|
||||
// // assert_is_VectorX("R",R);
|
||||
// // return igl::slice(X,R);
|
||||
// return;
|
||||
// }, __doc_igl_slice,
|
||||
// py::arg("X"), py::arg("R"));
|
||||
m.def("slice", []
|
||||
(
|
||||
const Eigen::MatrixXd& X,
|
||||
const Eigen::MatrixXi& R
|
||||
)
|
||||
{
|
||||
assert_is_VectorX("R",R);
|
||||
return igl::slice(X,R);
|
||||
}, __doc_igl_slice,
|
||||
py::arg("X"), py::arg("A"));
|
||||
|
||||
m.def("slice", []
|
||||
(
|
||||
@@ -134,17 +131,16 @@ m.def("slice", []
|
||||
}, __doc_igl_slice,
|
||||
py::arg("X"), py::arg("R"), py::arg("Y"));
|
||||
|
||||
// TODO: Problematic
|
||||
// m.def("slice", []
|
||||
// (
|
||||
// const Eigen::MatrixXi& X,
|
||||
// const Eigen::MatrixXi& R
|
||||
// )
|
||||
// {
|
||||
// assert_is_VectorX("R",R);
|
||||
// return igl::slice(X,R);
|
||||
// }, __doc_igl_slice,
|
||||
// py::arg("X"), py::arg("R"));
|
||||
m.def("slice", []
|
||||
(
|
||||
const Eigen::MatrixXi& X,
|
||||
const Eigen::MatrixXi& R
|
||||
)
|
||||
{
|
||||
assert_is_VectorX("R",R);
|
||||
return igl::slice(X,R);
|
||||
}, __doc_igl_slice,
|
||||
py::arg("X"), py::arg("R"));
|
||||
|
||||
m.def("slice", []
|
||||
(
|
||||
|
||||
Reference in New Issue
Block a user