Closed
Description
What it does
Suggests using the helper shortcut method, which is shorter.
https://doc.rust-lang.org/stable/std/io/trait.Seek.html#method.rewind
Lint Name
No response
Category
No response
Advantage
No response
Drawbacks
No response
Example
fn foo<T: io::Seek>(t: T) {
t.seek(io::SeekFrom::Start(0));
}
Could be written as:
fn foo<T: io::Seek>(t: T) {
t.rewind();
}