morelinq / MoreLINQ

Extensions to LINQ to Objects
https://morelinq.github.io/
Apache License 2.0
3.7k stars 415 forks source link

Rewrite next permutation while-loop into a for-loop #926

Closed atifaziz closed 1 year ago

atifaziz commented 1 year ago

This PR refactors a while-loop into a simpler for-loop (with two loop variables) in the NextPermutation implementation of Permutations operator.

codecov[bot] commented 1 year ago

Codecov Report

Merging #926 (15f35f0) into master (fb29c31) will decrease coverage by 0.01%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #926      +/-   ##
==========================================
- Coverage   92.43%   92.41%   -0.02%     
==========================================
  Files         112      112              
  Lines        3436     3430       -6     
  Branches     1019     1019              
==========================================
- Hits         3176     3170       -6     
  Misses        199      199              
  Partials       61       61              
Impacted Files Coverage Δ
MoreLinq/Permutations.cs 96.42% <100.00%> (-0.35%) :arrow_down:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more