2024-01-25 12:17:36 -06:00
|
|
|
error: `core::iter::empty()` is the more idiomatic way
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/default_instead_of_iter_empty_no_std.rs:23:13
|
2024-01-25 12:17:36 -06:00
|
|
|
|
|
|
|
|
LL | let _ = core::iter::Empty::<usize>::default();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `core::iter::empty::<usize>()`
|
|
|
|
|
|
|
|
|
= note: `-D clippy::default-instead-of-iter-empty` implied by `-D warnings`
|
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::default_instead_of_iter_empty)]`
|
|
|
|
|
|
|
|
error: `core::iter::empty()` is the more idiomatic way
|
2024-02-27 08:25:18 -06:00
|
|
|
--> tests/ui/default_instead_of_iter_empty_no_std.rs:24:42
|
2024-01-25 12:17:36 -06:00
|
|
|
|
|
|
|
|
LL | let _foo: core::iter::Empty<usize> = core::iter::Empty::default();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `core::iter::empty()`
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|