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 lint clippy::get-first #114

Merged
merged 1 commit into from Aug 19, 2022
Merged

Conversation

vbrandl
Copy link
Contributor

@vbrandl vbrandl commented Aug 19, 2022

A new clippy lint fails on slice.get(0) and proposes to use slice.first() instead. Here is an example of a failing build: https://github.com/vbrandl/hoc/runs/7832070989?check_suite_focus=true

And here is the lint in question: https://rust-lang.github.io/rust-clippy/master/index.html#get_first

@kaj
Copy link
Owner

kaj commented Aug 19, 2022

Seems pretty clear. Thanks for the contribution!

@kaj kaj merged commit e28e9e0 into kaj:master Aug 19, 2022
@vbrandl
Copy link
Contributor Author

vbrandl commented Aug 19, 2022

Could you also publish a new release to fix the lint in projects that consume the library?

@vbrandl vbrandl deleted the fix/clippy-get-first branch August 19, 2022 21:26
@kaj
Copy link
Owner

kaj commented Aug 19, 2022

Yes, there's something other fix that should get released as well. I wanted to make a release of rsass first and include an update of that, but can't seem to get that done. Will try to cut a release of at least ructe this weekend.

kaj added a commit that referenced this pull request Aug 20, 2022
kaj added a commit that referenced this pull request Aug 20, 2022
* Improve error reporting.  The debug output for `RucteError` is now the
  same as display, and the standard `Error::source` is implemented.
* Fix clippy lint clippy::get-first (PR #114).
* Update optional rsass to 0.25.0.

Thanks to @vbrandl for PR #114.
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.

None yet

2 participants