Bug#1088865: dolfin: autopkgtests fail

Drew Parsons dparsons at debian.org
Wed Jan 1 23:56:40 GMT 2025


Source: dolfin
Followup-For: Bug #1088865

All of the MESHITERATOR_MACRO functions in python/src/mesh.cpp are
affected (cells, facets, faces, edges, vertices)

so I guess the problem is somewhere in MESHITERATOR_MACRO:

#define MESHITERATOR_MACRO(TYPE, NAME) \
    py::class_<dolfin::MeshEntityIteratorBase<dolfin::TYPE>, \
               std::shared_ptr<dolfin::MeshEntityIteratorBase<dolfin::TYPE>>> \
      (m, #TYPE"Iterator", "DOLFIN "#TYPE"Iterator object") \
      .def(py::init<const dolfin::Mesh&>()) \
      .def("__iter__",[](dolfin::MeshEntityIteratorBase<dolfin::TYPE>& self) { self.operator--(); return self; }) \
      .def("__next__",[](dolfin::MeshEntityIteratorBase<dolfin::TYPE>& self) { \
          self.operator++(); \
          if (self.end()) \
            throw py::stop_iteration(""); \
          return *self; \
        }); \
 \
    m.def(#NAME, [](dolfin::Mesh& mesh, std::string opt)                          \
          { return dolfin::MeshEntityIteratorBase<dolfin::TYPE>(mesh, opt); }, \
          py::arg("mesh"), py::arg("type")="regular");                  \
    m.def(#NAME, [](dolfin::MeshEntity& meshentity)\
          { return dolfin::MeshEntityIteratorBase<dolfin::TYPE>(meshentity); })



More information about the debian-science-maintainers mailing list