Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Rely on template argument deduction (sonar, c++17).
[simgrid.git] / src / xbt / xbt_replay.cpp
index 3915221..41c6d57 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2021. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2010-2022. The SimGrid Team. All rights reserved.          */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
@@ -81,7 +81,7 @@ static ReplayAction* get_action(const char* name)
         otherqueue = act->second;
       } else { // Damn. Create the queue of that guy
         otherqueue = new std::queue<ReplayAction*>();
-        action_queues.insert({evtname, otherqueue});
+        action_queues.try_emplace(evtname, otherqueue);
       }
       otherqueue->push(action);
     }