File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -101,15 +101,15 @@ void init_Iteration(py::module &m)
101101 py::return_value_policy::copy,
102102 // garbage collection: return value must be freed before
103103 // Iteration
104- py::keep_alive<1 , 0 >()))
104+ py::keep_alive<0 , 1 >()))
105105 .def_property_readonly (
106106 " particles" ,
107107 py::cpp_function (
108108 [](Iteration &i) { return i.particles ; },
109109 py::return_value_policy::copy,
110110 // garbage collection: return value must be freed before
111111 // Iteration
112- py::keep_alive<1 , 0 >()));
112+ py::keep_alive<0 , 1 >()));
113113
114114 add_pickle (
115115 cl, [](openPMD::Series series, std::vector<std::string> const &group) {
Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ void init_ParticleSpecies(py::module &m)
5454 [](ParticleSpecies &ps) { return ps.particlePatches ; },
5555 py::return_value_policy::copy,
5656 // garbage collection: return value must be freed before Series
57- py::keep_alive<1 , 0 >()));
57+ py::keep_alive<0 , 1 >()));
5858 add_pickle (
5959 cl, [](openPMD::Series series, std::vector<std::string> const &group) {
6060 uint64_t const n_it = std::stoull (group.at (1 ));
Original file line number Diff line number Diff line change @@ -503,7 +503,7 @@ this method.
503503 [](Series &s) { return s.iterations ; },
504504 py::return_value_policy::copy,
505505 // garbage collection: return value must be freed before Series
506- py::keep_alive<1 , 0 >()))
506+ py::keep_alive<0 , 1 >()))
507507 .def (
508508 " read_iterations" ,
509509 [](Series &s) {
You can’t perform that action at this time.
0 commit comments