MCPcopy Create free account
hub / github.com/pybind/pybind11 / MoveIssue2

Class MoveIssue2

tests/test_copy_move.cpp:286–290  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

284 .def_readwrite("value", &MoveIssue1::v);
285
286 struct MoveIssue2 {
287 int v;
288 explicit MoveIssue2(int v) : v{v} {}
289 MoveIssue2(MoveIssue2 &&) = default;
290 };
291 py::class_<MoveIssue2>(m, "MoveIssue2")
292 .def(py::init<int>())
293 .def_readwrite("value", &MoveIssue2::v);

Callers 1

TEST_SUBMODULEFunction · 0.85

Calls

no outgoing calls

Tested by 1

TEST_SUBMODULEFunction · 0.68