Fix std::iterator inheritance

This commit is contained in:
Jérôme Leclercq 2020-03-19 18:41:05 +01:00 committed by GitHub
parent adf1233ef2
commit 1c9a390d67
1 changed files with 7 additions and 1 deletions

View File

@ -55,7 +55,7 @@ namespace Ndk
World* m_world;
};
class NDK_API EntityList::iterator : public std::iterator<std::forward_iterator_tag, const EntityHandle>
class NDK_API EntityList::iterator
{
friend EntityList;
@ -73,6 +73,12 @@ namespace Ndk
friend inline void swap(iterator& lhs, iterator& rhs);
using difference_type = std::ptrdiff_t;
using iterator_category = std::forward_iterator_tag;
using pointer = EntityHandle*;
using reference = EntityHandle&;
using value_type = EntityHandle;
private:
inline iterator(const EntityList* world, std::size_t nextId);