fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
1.9 KiB43 linesraw
1error[E0277]: the size for values of type `[i32]` cannot be known at compilation time
2  --> $DIR/collect-into-slice.rs:6:9
3   |
4LL |     let some_generated_vec = (0..10).collect();
5   |         ^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
6   |
7   = help: the trait `Sized` is not implemented for `[i32]`
8   = note: all local variables must have a statically known size
9   = help: unsized locals are gated as an unstable feature
10
11error[E0277]: the size for values of type `[i32]` cannot be known at compilation time
12  --> $DIR/collect-into-slice.rs:6:38
13   |
14LL |     let some_generated_vec = (0..10).collect();
15   |                                      ^^^^^^^ doesn't have a size known at compile-time
16   |
17   = help: the trait `Sized` is not implemented for `[i32]`
18note: required by a bound in `collect`
19  --> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL
20
21error[E0277]: a slice of type `[i32]` cannot be built since `[i32]` has no definite size
22  --> $DIR/collect-into-slice.rs:6:38
23   |
24LL |     let some_generated_vec = (0..10).collect();
25   |                                      ^^^^^^^ try explicitly collecting into a `Vec<{integer}>`
26   |
27   = help: the trait `FromIterator<{integer}>` is not implemented for `[i32]`
28note: required by a bound in `collect`
29  --> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL
30
31error[E0277]: a slice of type `&[i32]` cannot be built since we need to store the elements somewhere
32  --> $DIR/collect-into-slice.rs:18:38
33   |
34LL |     let some_generated_vec = (0..10).collect();
35   |                                      ^^^^^^^ try explicitly collecting into a `Vec<{integer}>`
36   |
37   = help: the trait `FromIterator<{integer}>` is not implemented for `&[i32]`
38note: required by a bound in `collect`
39  --> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL
40
41error: aborting due to 4 previous errors
42
43For more information about this error, try `rustc --explain E0277`.