[iter] Add unary operator+ that returns a copy
This commit is contained in:
parent
fbab07f9b3
commit
2f5b1a9104
|
@ -69,6 +69,7 @@ struct hb_iter_t
|
|||
|
||||
/* Operators. */
|
||||
iter_t iter () const { return *thiz(); }
|
||||
iter_t operator + () const { return *thiz(); }
|
||||
explicit_operator bool () const { return thiz()->__more__ (); }
|
||||
unsigned len () const { return thiz()->__len__ (); }
|
||||
hb_remove_reference (item_t)* operator -> () const { return hb_addressof (**thiz()); }
|
||||
|
|
|
@ -135,7 +135,7 @@ main (int argc, char **argv)
|
|||
hb_array_t<hb_vector_t<int> > pa;
|
||||
pa->as_array ();
|
||||
|
||||
s
|
||||
+ s
|
||||
| hb_map (hb_identity)
|
||||
| hb_filter ()
|
||||
| hb_filter (hb_bool)
|
||||
|
|
Loading…
Reference in New Issue