Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Cosmetics: align with other similar declarations.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Fri, 6 Jan 2023 07:53:19 +0000 (08:53 +0100)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Wed, 11 Jan 2023 08:30:23 +0000 (09:30 +0100)
src/bindings/python/simgrid_python.cpp

index adb7be8..a7207af 100644 (file)
@@ -459,7 +459,7 @@ PYBIND11_MODULE(simgrid, m)
             Host::on_creation_cb([cb_p = cb.ptr()](Host& h) {
               const py::gil_scoped_acquire py_context; // need a new context for callback
               try {
-                py::function fun = py::reinterpret_borrow<py::function>(cb_p);
+                const auto fun = py::reinterpret_borrow<py::function>(cb_p);
                 fun(&h);
               } catch (const py::error_already_set& e) {
                 xbt_die("Error while executing the on_creation lambda : %s", e.what());