You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with recent rustc version we can use `repeat_n` instead of `repeat().take()`
```
error: this `repeat().take()` can be written more concisely
--> lightning-invoice/src/ser.rs:256:12
|
256 | Box::new(core::iter::repeat(Fe32::Q).take(to_pad).chain(fes))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `repeat_n()` instead: `core::iter::repeat_n(Fe32::Q, to_pad)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_repeat_n
= note: `-D clippy::manual-repeat-n` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::manual_repeat_n)]`
```
but to keep compatibility with older rustc versions we need to disable the warning
for the `repeat_n` lint.
Signed-off-by: Vincenzo Palazzo <[email protected]>
0 commit comments