sparse_set: make capacity virtual

This commit is contained in:
Michele Caini
2021-07-19 00:01:59 +02:00
parent badbc5c66e
commit 15efe9f702
2 changed files with 2 additions and 2 deletions

View File

@@ -405,7 +405,7 @@ public:
* allocated space for.
* @return Capacity of the sparse set.
*/
[[nodiscard]] size_type capacity() const ENTT_NOEXCEPT {
[[nodiscard]] virtual size_type capacity() const ENTT_NOEXCEPT {
return reserved.second();
}

View File

@@ -415,7 +415,7 @@ public:
* allocated space for.
* @return Capacity of the storage.
*/
[[nodiscard]] size_type capacity() const ENTT_NOEXCEPT {
[[nodiscard]] size_type capacity() const ENTT_NOEXCEPT override {
return bucket.second() * packed_page;
}