Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines.
[simgrid.git] / src / mc / inspect / LocationList.cpp
index 07c7c3d..426b97b 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2004-2020. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2004-2021. 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. */
@@ -79,7 +79,7 @@ LocationList location_list(const simgrid::mc::ObjectInformation& info, Dwarf_Att
     else if (offset == -1)
       xbt_die("Error while loading location list");
 
-    std::uint64_t base_address = (std::uint64_t)info.base_address();
+    auto base_address = reinterpret_cast<std::uint64_t>(info.base_address());
 
     LocationListEntry::range_type range;
     if (start == 0)
@@ -88,7 +88,7 @@ LocationList location_list(const simgrid::mc::ObjectInformation& info, Dwarf_Att
     else
       range = {base_address + start, base_address + end};
 
-    locations.push_back({DwarfExpression(ops, ops + len), range});
+    locations.emplace_back(DwarfExpression(ops, ops + len), range);
   }
 
   return locations;