Changeset 21d97e8 in mainline for uspace/lib/cpp/include/internal/rbtree_iterators.hpp
- Timestamp:
- 2018-07-05T21:41:23Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0fe0f32
- Parents:
- 5608106c
- git-author:
- Dzejrou <dzejrou@…> (2018-05-14 17:03:57)
- git-committer:
- Dzejrou <dzejrou@…> (2018-07-05 21:41:23)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/cpp/include/internal/rbtree_iterators.hpp
r5608106c r21d97e8 78 78 rbtree_iterator& operator++() 79 79 { 80 if (end_) 81 return *this; 82 80 83 if (current_) 81 84 { … … 102 105 if (end_) 103 106 { 104 try_undo_end_();107 end_ = false; 105 108 106 109 return *this; … … 145 148 node_type* current_; 146 149 bool end_; 147 148 void try_undo_end_()149 {150 if (!current_)151 return;152 153 /**154 * We can do this if we are past end().155 * This means we are the largest.156 */157 if (current_->find_largest() == current_)158 end_ = false;159 }160 150 }; 161 151 … … 224 214 rbtree_const_iterator& operator++() 225 215 { 216 if (end_) 217 return *this; 218 226 219 if (current_) 227 220 { … … 248 241 if (end_) 249 242 { 250 try_undo_end_();243 end_ = false; 251 244 252 245 return *this; … … 286 279 const node_type* current_; 287 280 bool end_; 288 289 void try_undo_end_()290 {291 if (!current_)292 return;293 294 /**295 * We can do this if we are past end().296 * This means we are the largest.297 */298 if (current_->find_largest() == current_)299 end_ = false;300 }301 281 }; 302 282
Note:
See TracChangeset
for help on using the changeset viewer.