Skip to content

Fix handling of double pointers #6

@kwabenantim

Description

@kwabenantim

Description
Wrappers generated for member functions with double pointer args do not compile.

Example:

class TysonNovak2001OdeSystem : public AbstractOdeSystemWithAnalyticJacobian
{
public:
    virtual void AnalyticJacobian(const std::vector<double>& rSolutionGuess, double** jacobian, double time, double timeStep);
};

produces:

.def(
    "AnalyticJacobian", 
    (void(TysonNovak2001OdeSystem::*)(::std::vector<double> const &, double * *, double, double)) &TysonNovak2001OdeSystem::AnalyticJacobian, 
    " " , py::arg("rSolutionGuess"), py::arg("jacobian"), py::arg("time"), py::arg("timeStep") )

Error

pybind11/include/pybind11/cast.h:1217
error: no matching function for call to ‘pybind11::detail::type_caster<double, void>::cast(double**&, pybind11::return_value_policy, std::nullptr_t)’

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions