Skip to content
Snippets Groups Projects
Commit ccb3d08c authored by Jan Trávníček's avatar Jan Trávníček
Browse files

allow operator -> on tree iterators

parent 937f5259
No related branches found
No related tags found
No related merge requests found
...@@ -151,6 +151,10 @@ public: ...@@ -151,6 +151,10 @@ public:
return node->getData ( ); return node->getData ( );
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
size_t operator -( const const_children_iterator other ) const { size_t operator -( const const_children_iterator other ) const {
return node - other.node; return node - other.node;
} }
...@@ -287,6 +291,10 @@ public: ...@@ -287,6 +291,10 @@ public:
return node->getData ( ); return node->getData ( );
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return level; return level;
} }
...@@ -356,6 +364,10 @@ public: ...@@ -356,6 +364,10 @@ public:
return * node; return * node;
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return node.getLevel ( ); return node.getLevel ( );
} }
...@@ -421,6 +433,10 @@ public: ...@@ -421,6 +433,10 @@ public:
return * node; return * node;
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return node.getLevel ( ); return node.getLevel ( );
} }
......
...@@ -173,6 +173,10 @@ public: ...@@ -173,6 +173,10 @@ public:
return node->getData ( ); return node->getData ( );
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
size_t operator -( const const_children_iterator other ) const { size_t operator -( const const_children_iterator other ) const {
return node - other.node; return node - other.node;
} }
...@@ -306,6 +310,10 @@ public: ...@@ -306,6 +310,10 @@ public:
return node->getData ( ); return node->getData ( );
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return level; return level;
} }
...@@ -375,6 +383,10 @@ public: ...@@ -375,6 +383,10 @@ public:
return * node; return * node;
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return node.getLevel ( ); return node.getLevel ( );
} }
...@@ -440,6 +452,10 @@ public: ...@@ -440,6 +452,10 @@ public:
return * node; return * node;
} }
   
const T * operator ->( ) const {
return & node->getData ( );
}
unsigned getLevel ( ) const { unsigned getLevel ( ) const {
return node.getLevel ( ); return node.getLevel ( );
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment