Commit 7f9ef66
authored
Fix clippy::needless_lifetimes warning (#113)
```
warning: the following explicit lifetimes could be elided: 'a
--> async-stream/src/yielder.rs:90:6
|
90 | impl<'a, T> Drop for Enter<'a, T> {
| ^^ ^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
= note: `#[warn(clippy::needless_lifetimes)]` on by default
help: elide the lifetimes
|
90 - impl<'a, T> Drop for Enter<'a, T> {
90 + impl<T> Drop for Enter<'_, T> {
|
warning: the following explicit lifetimes could be elided: 'a
--> async-stream/tests/stream.rs:164:19
|
164 | fn stream<'a>(&'a self) -> impl Stream<Item = &str> + 'a {
| ^^ ^^ ^ ^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
= note: `#[warn(clippy::needless_lifetimes)]` on by default
help: elide the lifetimes
|
164 - fn stream<'a>(&'a self) -> impl Stream<Item = &str> + 'a {
164 + fn stream(&self) -> impl Stream<Item = &str> + '_ {
|
```1 parent b0b2f22 commit 7f9ef66
2 files changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
90 | | - | |
| 90 | + | |
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
164 | | - | |
| 164 | + | |
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
| |||
0 commit comments