[iter] Add operator ->
This commit is contained in:
parent
d3976b7e63
commit
2790aad28c
|
@ -28,6 +28,7 @@
|
|||
#define HB_ITER_HH
|
||||
|
||||
#include "hb.hh"
|
||||
#include "hb-dsalgs.hh" // for hb_addressof
|
||||
#include "hb-null.hh"
|
||||
|
||||
|
||||
|
@ -60,6 +61,7 @@ struct hb_iter_t
|
|||
operator iter_t () { return iter(); }
|
||||
explicit_operator bool () const { return more (); }
|
||||
item_t& operator * () const { return item (); }
|
||||
item_t* operator -> () const { return hb_addressof (item ()); }
|
||||
item_t& operator [] (signed i) const { return item_at ((unsigned) i); }
|
||||
iter_t& operator += (unsigned count) { forward (count); return *thiz(); }
|
||||
iter_t& operator ++ () { next (); return *thiz(); }
|
||||
|
|
|
@ -631,7 +631,7 @@ template <typename T> struct hb_remove_pointer<T *> { typedef T value; };
|
|||
#include "hb-mutex.hh"
|
||||
#include "hb-null.hh"
|
||||
#include "hb-dsalgs.hh" // Requires: hb-null
|
||||
#include "hb-iter.hh" // Requires: hb-null
|
||||
#include "hb-iter.hh" // Requires: hb-dsalgs hb-null
|
||||
#include "hb-debug.hh" // Requires: hb-atomic hb-dsalgs
|
||||
#include "hb-array.hh" // Requires: hb-dsalgs hb-iter hb-null
|
||||
#include "hb-vector.hh" // Requires: hb-array hb-null
|
||||
|
|
Loading…
Reference in New Issue