Michele Caini 2 лет назад
Родитель
Сommit
88bf26a2f8
2 измененных файлов с 1 добавлено и 2 удалено
  1. 0 1
      TODO
  2. 1 1
      src/entt/entity/registry.hpp

+ 0 - 1
TODO

@@ -18,7 +18,6 @@ TODO (high prio):
 * pop_if to improve further destroying entities (drastically)
 * doc: exclude only views, storage entity (and diff between iterator and each based iteration), bump entities, signals on entity creation/destruction
 * registry: replace destroy with a drop-all method that doesn't care about validity
-* registry: review assign mechanism, maybe it's worth to drop it
 
 WIP:
 * get rid of observers, storage based views made them pointless - document alternatives

+ 1 - 1
src/entt/entity/registry.hpp

@@ -584,7 +584,7 @@ public:
      * @param destroyed The number of released entities.
      */
     template<typename It>
-    void assign(It first, It last, const size_type destroyed) {
+    [[deprecated("use .storage<Entity>().push(first, last) and .storage<Entity>().in_use(len) instead")]] void assign(It first, It last, const size_type destroyed) {
         ENTT_ASSERT(!shortcut->in_use(), "Non-empty registry");
         shortcut->push(first, last);
         shortcut->in_use(shortcut->size() - destroyed);