Skip to content

Commit

Permalink
storage: shrink_to_fit storage pools
Browse files Browse the repository at this point in the history
  • Loading branch information
skypjack committed Jan 20, 2025
1 parent d1abac2 commit fae3345
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/entt/entity/storage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,7 @@ class basic_storage: public basic_sparse_set<Entity, typename std::allocator_tra
}

payload.resize(from);
payload.shrink_to_fit();
}

void swap_at(const std::size_t from, const std::size_t to) {
Expand Down

0 comments on commit fae3345

Please sign in to comment.