b2
b2 copied to clipboard
eliminate boilerplate for naming submodules in pybertini
this sucks:
scope current_scope;
std::string new_submodule_name(extract<const char*>(current_scope.attr("__name__")));
new_submodule_name.append(".config");
object new_submodule(borrowed(PyImport_AddModule(new_submodule_name.c_str())));
current_scope.attr("config") = new_submodule;
scope new_submodule_scope = new_submodule;
replace it with a macro or something. this appears like 15 or more times in the pybertini c++ codebase. eww. :nauseated_face: