From 1c9a390d6788cf94e06dabf547c28fbcaab3445c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Leclercq?= Date: Thu, 19 Mar 2020 18:41:05 +0100 Subject: [PATCH] Fix std::iterator inheritance --- SDK/include/NDK/EntityList.hpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/SDK/include/NDK/EntityList.hpp b/SDK/include/NDK/EntityList.hpp index 0f89d0cad..3b4f1580a 100644 --- a/SDK/include/NDK/EntityList.hpp +++ b/SDK/include/NDK/EntityList.hpp @@ -55,7 +55,7 @@ namespace Ndk World* m_world; }; - class NDK_API EntityList::iterator : public std::iterator + 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);