Files
gem5/ext/pybind11/tests/test_cmake_build/main.cpp
Andreas Sandberg 6914a229a0 ext: Upgrade PyBind11 to version 2.1.1
Change-Id: I16870dec402d661295f9d013dc23e362b2b2c169
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-by: Curtis Dunham <curtis.dunham@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/3225
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
2017-05-22 17:15:09 +00:00

11 lines
209 B
C++

#include <pybind11/pybind11.h>
namespace py = pybind11;
PYBIND11_PLUGIN(test_cmake_build) {
py::module m("test_cmake_build");
m.def("add", [](int i, int j) { return i + j; });
return m.ptr();
}