-
In my attempts to port from pybind11 to nanobind I'm hitting a bit of a kink. I'm attempting to add an Eigen matrix as a default parameter to a constructor as something like this: .def(nb::init<Eigen::Matrix2d>(), "mat"_a=Eigen::Matrix2d::Identity()) which compiles fine, but upon importing the module in python, I get the following error, *** stack smashing detected ***: terminated Removing the default parameter removes this issue and everything seems to function properly. I wanted to check if this was supposed to be supported in nanobind? If so, I'd be happy to put together a small working example of this bug. If not, if you wouldn't mind providing a proper way of doing this, that'd be great. Thanks so much! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Seems suspicious, I think that should work. Please go ahead with the reproducer. |
Beta Was this translation helpful? Give feedback.
Seems suspicious, I think that should work. Please go ahead with the reproducer.