tcbrindle / flux

A C++20 library for sequence-orientated programming
https://tristanbrindle.com/flux/
Boost Software License 1.0
472 stars 29 forks source link

Fix out-of-bounds inc() in detail::advance #134

Closed tcbrindle closed 9 months ago

tcbrindle commented 9 months ago

If we passed a positive offset to the non-RA version of advance(), we were performing an initial inc() on the passed-in cursor without first checking whether it was at the end.

So let's not do that.

Fixes #132

codecov[bot] commented 9 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (bc97bee) 97.70% compared to head (173aa9d) 97.70%. Report is 2 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #134 +/- ## ======================================= Coverage 97.70% 97.70% ======================================= Files 67 67 Lines 2398 2400 +2 ======================================= + Hits 2343 2345 +2 Misses 55 55 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.