Missing must_use tags
jonjove opened this issue · 2 comments
jonjove commented
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
.
leighmcculloch commented
@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 commented
I encountered this on 1.59.0. Doesn't seem to happen on 1.61.0.