Răsfoiți Sursa

Fix MSVC 2017 warning C4458 (#43)

Fix MSVC 2017 warning C4458.
Nick Lange 8 ani în urmă
părinte
comite
f2cbb5306b
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      src/entt/entity/sparse_set.hpp

+ 2 - 2
src/entt/entity/sparse_set.hpp

@@ -614,11 +614,11 @@ public:
         auto to = other.end();
         auto to = other.end();
 
 
         pos_type pos = underlying_type::size() - 1;
         pos_type pos = underlying_type::size() - 1;
-        const auto *direct = underlying_type::data();
+        const auto *local = underlying_type::data();
 
 
         while(pos > 0 && from != to) {
         while(pos > 0 && from != to) {
             if(underlying_type::has(*from)) {
             if(underlying_type::has(*from)) {
-                if(*from != *(direct + pos)) {
+                if(*from != *(local + pos)) {
                     auto candidate = underlying_type::get(*from);
                     auto candidate = underlying_type::get(*from);
                     std::swap(instances[pos], instances[candidate]);
                     std::swap(instances[pos], instances[candidate]);
                     underlying_type::swap(pos, candidate);
                     underlying_type::swap(pos, candidate);