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

Missing must_use tags #72

Closed
jonjove opened this issue Jun 9, 2022 · 2 comments
Closed

Missing must_use tags #72

jonjove opened this issue Jun 9, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@jonjove
Copy link
Contributor

jonjove commented Jun 9, 2022

I got several errors like

error: this method could have a `#[must_use]` attribute
    --> src/curr.rs:7865:5
     |
7865 |     pub fn iter(&self) -> Iter<'_, PeerStats> {
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add the attribute: `#[must_use] pub fn iter(&self) -> Iter<'_, PeerStats>`
     |
     = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate

when generating from the XDR fields. The error always occurs on pub fn iter.

@jonjove jonjove added the bug Something isn't working label Jun 9, 2022
@leighmcculloch
Copy link
Member

leighmcculloch commented Jun 9, 2022

@jonjove Are you on latest stable of rust? 1.61.0. there just happens to have been a change to the iter() function in 1.61 that trips this up on older versions.

@jonjove
Copy link
Contributor Author

jonjove commented Jun 9, 2022

I encountered this on 1.59.0. Doesn't seem to happen on 1.61.0.

@jonjove jonjove closed this as completed Jun 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants