Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[lgtm] Ensure that the type casting is done before multiplication to prevent overflow.
[simgrid.git] / src / kernel / future.cpp
index 88a8461..1104a66 100644 (file)
@@ -8,15 +8,15 @@
 
 #include <simgrid/kernel/future.hpp>
 
-#include "src/simix/smx_private.hpp"
+#include "src/kernel/EngineImpl.hpp"
 
 namespace simgrid {
 namespace kernel {
 
 void FutureStateBase::schedule(simgrid::xbt::Task<void()>&& job) const
 {
-  simix_global->tasks.push_back(std::move(job));
+  EngineImpl::get_instance()->add_task(std::move(job));
 }
 
-}
-}
+} // namespace kernel
+} // namespace simgrid