fix nextSetBit

- fix #4
- add tests for nextSetBit