Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[sonar] Declare functions "const" in src/xbt/.
[simgrid.git] / include / xbt / config.hpp
index dbd27f4..7dedb71 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2016-2019. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2016-2020. 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. */
@@ -286,7 +286,7 @@ public:
   template<class U>
   Flag& operator=(U const& that) { value_ = that; return *this; }
   template<class U>
-  Flag& operator=(U && that)     { value_ = that; return *this; }
+  Flag& operator=(U&& that) { value_ = std::forward<U>(that); return *this; }
   template<class U>
   bool operator==(U const& that) const { return value_ == that; }
   template<class U>