I'm trying to implement a db cursor as simple InputRange. I can't
implement as forward range because using c-api I can't clone/save
cursor.
I wrote popFront() front() and empty() method and my range works
fine.
Using on a foreach() it browses all elements inside range until
range is exausthed.
If i do another foreach() it doesn't restart (empty() is called
and it returns true, of course).
Is it the correct behaviour of a inputrange or have i missed
something?
- Is this range behaviour correct? Andrea Fontana
-