Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix clippy warnings #113

Merged
merged 4 commits into from
Jan 24, 2021

Conversation

boydjohnson
Copy link
Contributor

With this PR there will be CI failures on clippy warnings. I think this gives greater guarantees of idiomatic code.

@boydjohnson boydjohnson force-pushed the fix-clippy-warnings branch from 34a254b to 9d3d2a8 Compare June 8, 2020 17:45
@Volpe95 Volpe95 closed this Jan 24, 2021
@AnshulMalik AnshulMalik reopened this Jan 24, 2021
Allows MinHeap and MaxHeap new methods to return Heap

Fixes incorrect is_empty() implementation. is_empty should return true
when self.len() == 0.
This changes to use -= instead of manually implementing.
Removes a lifetime that can be elided.
@boydjohnson
Copy link
Contributor Author

Hi @AnshulMalik, There were a small amount of clippy lint that clippy --all complains about that are fixed in this PR. There is a fix for an incorrect impl of is_empty() on Heap. The main point of this PR is to turn on cargo clippy --all -- -D warnings in CI.

@AnshulMalik AnshulMalik merged commit fb88840 into TheAlgorithms:master Jan 24, 2021
@AnshulMalik
Copy link
Member

Thanks @boydjohnson

@boydjohnson boydjohnson deleted the fix-clippy-warnings branch January 29, 2021 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants