pisa-engine / pisa

PISA: Performant Indexes and Search for Academia
https://pisa-engine.github.io/pisa/book
Apache License 2.0
941 stars 65 forks source link

Address Codacy warnings #512

Closed elshize closed 1 year ago

elshize commented 1 year ago

Just addressing some warnings found by Codacy. See commit messages for more context for each change.

codecov[bot] commented 1 year ago

Codecov Report

Base: 93.03% // Head: 93.03% // Increases project coverage by +0.00% :tada:

Coverage data is based on head (05cf62d) compared to base (679fe44). Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #512 +/- ## ======================================= Coverage 93.03% 93.03% ======================================= Files 90 90 Lines 4494 4497 +3 ======================================= + Hits 4181 4184 +3 Misses 313 313 ``` | [Impacted Files](https://codecov.io/gh/pisa-engine/pisa/pull/512?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine) | Coverage Δ | | |---|---|---| | [include/pisa/codec/strict\_elias\_fano.hpp](https://codecov.io/gh/pisa-engine/pisa/pull/512?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine#diff-aW5jbHVkZS9waXNhL2NvZGVjL3N0cmljdF9lbGlhc19mYW5vLmhwcA==) | `100.00% <100.00%> (ø)` | | | [include/pisa/sequence/positive\_sequence.hpp](https://codecov.io/gh/pisa-engine/pisa/pull/512?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine#diff-aW5jbHVkZS9waXNhL3NlcXVlbmNlL3Bvc2l0aXZlX3NlcXVlbmNlLmhwcA==) | `100.00% <100.00%> (ø)` | | | [include/pisa/util/util.hpp](https://codecov.io/gh/pisa-engine/pisa/pull/512?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine#diff-aW5jbHVkZS9waXNhL3V0aWwvdXRpbC5ocHA=) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pisa-engine)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

elshize commented 1 year ago

But I am quite frankly amazed about the +[]{} lambda syntax (that is, + in front of a lambda turns it into a function pointer). I really had no idea about that...

Yeah, I remember reading about it a long time ago, but disregarded it as not very useful, and forgot about it until I found it again on google today. As it turns out, it has its uses...