Skip to content
This repository has been archived by the owner on Dec 1, 2024. It is now read-only.

Reverse Iterators should 'skip to previous' when start key doesn't exist #27

Closed
rvagg opened this issue Mar 29, 2013 · 2 comments · Fixed by #30
Closed

Reverse Iterators should 'skip to previous' when start key doesn't exist #27

rvagg opened this issue Mar 29, 2013 · 2 comments · Fixed by #30

Comments

@rvagg
Copy link
Member

rvagg commented Mar 29, 2013

LevelDB only does 'skip to next' when start key doesn't exist but when you want to iterate in reverse you want your start point to be the previous closest key where your actual start doesn't exist.
We can detect and handle this situation for reverse Iterators. Edge case is end-of-database which will cause !Valid().

@kesla
Copy link
Contributor

kesla commented Mar 29, 2013

Sounds like fun. I'm interested in fixing this. Give me a day or two and you should see a PR, if that works for you.

@rvagg
Copy link
Member Author

rvagg commented Mar 29, 2013

Cool. Work from 0.2-wip. It's pretty much ready for merging to master and releasing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants