pybind / pybind11

Seamless operability between C++11 and Python
https://pybind11.readthedocs.io/
Other
15.1k stars 2.05k forks source link

[eigen] Obey noconvert() in Eigen::Sparse type_caster #4937

Open EricCousineau-TRI opened 7 months ago

EricCousineau-TRI commented 7 months ago

Description

This is forwarding a fix from @jwnimmer-tri from our Drake fork (https://github.com/RobotLocomotion/pybind11/pull/69). See https://github.com/RobotLocomotion/drake/issues/20516 for how it affected us.

Suggested changelog entry:

Obey noconvert() in Eigen::Sparse type_caster
rwgk commented 7 months ago

Hi @EricCousineau-TRI, lgtm, but could you please also add a test that fails without this change?