blob: 212936b8bdd7f9d2e015826474c3be616466c64f [file]
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:10:13
|
LL | let x = (x[0], x[1]);
| ^^^^^^^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
= note: `-D clippy::tuple-array-conversions` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::tuple_array_conversions)]`
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:12:13
|
LL | let x = [x.0, x.1];
| ^^^^^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:15:13
|
LL | let x = (x[0], x[1]);
| ^^^^^^^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:19:53
|
LL | let v1: Vec<[u32; 2]> = t1.iter().map(|&(a, b)| [a, b]).collect();
| ^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:21:38
|
LL | t1.iter().for_each(|&(a, b)| _ = [a, b]);
| ^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:23:55
|
LL | let t2: Vec<(u32, u32)> = v1.iter().map(|&[a, b]| (a, b)).collect();
| ^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:25:38
|
LL | t1.iter().for_each(|&(a, b)| _ = [a, b]);
| ^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:64:22
|
LL | let _: &[f64] = &[a, b];
| ^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:68:5
|
LL | (src, dest);
| ^^^^^^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:113:13
|
LL | let x = (x[0], x[1]);
| ^^^^^^^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: it looks like you're trying to convert a tuple to an array
--> tests/ui/tuple_array_conversions.rs:115:13
|
LL | let x = [x.0, x.1];
| ^^^^^^^^^^
|
= help: use `.into()` instead, or `<[T; N]>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:118:13
|
LL | let x = (x[0], x[1]);
| ^^^^^^^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: it looks like you're trying to convert an array to a tuple
--> tests/ui/tuple_array_conversions.rs:141:18
|
LL | do_something((a, b));
| ^^^^^^
|
= help: use `.into()` instead, or `<(T0, T1, ..., Tn)>::from` if type annotations are needed
error: aborting due to 13 previous errors