From 9edf06794e09427c0f1b8647e0eee154f45ab6c5 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 23 Feb 2018 16:00:42 +0100 Subject: [PATCH] Remove ptr_type typedef from wxList iterator classes This typedef is completely redundant with pointer_type which had been also available in these classes since the very beginning and seems to have been meant to be private originally, so it should be safe to just remove it, especially because I couldn't find any existing code using it. If we do find such code in the wild later, this commit could be reverted as it's not really indispensable. --- include/wx/list.h | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/include/wx/list.h b/include/wx/list.h index 7cd5205d90..8b67ccbd88 100644 --- a/include/wx/list.h +++ b/include/wx/list.h @@ -780,14 +780,13 @@ private: \ typedef nodetype Node; \ typedef iterator itor; \ - typedef value_type* ptr_type; \ \ Node* m_node; \ Node* m_init; \ public: \ /* Compatibility typedefs, don't use */ \ typedef reference reference_type; \ - typedef ptr_type pointer_type; \ + typedef pointer pointer_type; \ \ iterator(Node* node, Node* init) : m_node(node), m_init(init) {}\ iterator() : m_node(NULL), m_init(NULL) { } \ @@ -834,13 +833,12 @@ private: typedef nodetype Node; \ typedef const value_type& const_reference; \ typedef const_iterator itor; \ - typedef value_type* ptr_type; \ \ Node* m_node; \ Node* m_init; \ public: \ - typedef const_reference reference_type; \ - typedef const ptr_type pointer_type; \ + typedef reference reference_type; \ + typedef pointer pointer_type; \ \ const_iterator(Node* node, Node* init) \ : m_node(node), m_init(init) { } \ @@ -889,13 +887,12 @@ private: \ typedef nodetype Node; \ typedef reverse_iterator itor; \ - typedef value_type* ptr_type; \ \ Node* m_node; \ Node* m_init; \ public: \ typedef reference reference_type; \ - typedef ptr_type pointer_type; \ + typedef pointer pointer_type; \ \ reverse_iterator(Node* node, Node* init) \ : m_node(node), m_init(init) { } \ @@ -930,14 +927,13 @@ private: \ typedef nodetype Node; \ typedef const_reverse_iterator itor; \ - typedef value_type* ptr_type; \ typedef const value_type& const_reference; \ \ Node* m_node; \ Node* m_init; \ public: \ - typedef const_reference reference_type; \ - typedef const ptr_type pointer_type; \ + typedef reference reference_type; \ + typedef pointer pointer_type; \ \ const_reverse_iterator(Node* node, Node* init) \ : m_node(node), m_init(init) { } \