refactor: module -> module_ with typedef (#2544)

* WIP: module -> module_ without typedef

* refactor: allow py::module to work again
This commit is contained in:
Henry Schreiner
2020-10-03 13:38:03 -04:00
committed by GitHub
parent 560ed3e34f
commit 6bcd220c8d
40 changed files with 132 additions and 127 deletions

View File

@@ -22,7 +22,7 @@ struct DtypeCheck {
template <typename T>
DtypeCheck get_dtype_check(const char* name) {
py::module np = py::module::import("numpy");
py::module_ np = py::module_::import("numpy");
DtypeCheck check{};
check.numpy = np.attr("dtype")(np.attr(name));
check.pybind11 = py::dtype::of<T>();
@@ -133,7 +133,7 @@ template <typename T, typename T2> py::handle auxiliaries(T &&r, T2 &&r2) {
static int data_i = 42;
TEST_SUBMODULE(numpy_array, sm) {
try { py::module::import("numpy"); }
try { py::module_::import("numpy"); }
catch (...) { return; }
// test_dtypes