Reorder fullfillment errors to keep more interesting ones first · rust-lang/rust@91b9ffe (original) (raw)

1

1

`error[E0282]: type annotations needed

`

2

2

` --> $DIR/E0282.rs:2:9

`

3

3

` |

`

4

``

`-

LL | let x = "hello".chars().rev().collect();

`

``

4

`+

LL | let x;

`

5

5

` | ^

`

6

6

` |

`

7

7

`` help: consider giving x an explicit type

``

8

8

` |

`

9

``

`-

LL | let x: Vec<_> = "hello".chars().rev().collect();

`

10

``

`-

| ++++++++

`

``

9

`+

LL | let x: /* Type */;

`

``

10

`+

| ++++++++++++

`

11

11

``

12

``

`-

error[E0283]: type annotations needed

`

13

``

`-

--> $DIR/E0282.rs:2:9

`

14

``

`-

|

`

15

``

`-

LL | let x = "hello".chars().rev().collect();

`

16

``

`-

| ^ ------- type must be known at this point

`

17

``

`-

|

`

18

``

`` -

= note: multiple impls satisfying _: FromIterator<char> found in the following crates: alloc, hashbrown, std:

``

19

``

`-

`

20

``

`-

`

21

``

`-

where T: Clone;

`

22

``

`-

`

23

``

`-

`

24

``

`-

`

25

``

`-

where T: Eq, T: Hash, S: BuildHasher, S: Default, A: Default, A: Allocator, A: Clone;

`

26

``

`-

`

27

``

`-

where T: Eq, T: Hash, S: BuildHasher, S: Default;

`

28

``

`-

`

29

``

`-

`

30

``

`-

where T: Ord;

`

31

``

`-

`

32

``

`-

where T: Ord;

`

33

``

`-

`

34

``

`-

`

35

``

`-

`

36

``

`-

`

37

``

`` -

note: required by a bound in collect

``

38

``

`-

--> $SRC_DIR/core/src/iter/traits/iterator.rs:LL:COL

`

39

``

`` -

help: consider giving x an explicit type

``

40

``

`-

|

`

41

``

`-

LL | let x: Vec<_> = "hello".chars().rev().collect();

`

42

``

`-

| ++++++++

`

43

``

-

44

``

`-

error: aborting due to 2 previous errors

`

``

12

`+

error: aborting due to previous error

`

45

13

``

46

``

`-

Some errors have detailed explanations: E0282, E0283.

`

47

``

`` -

For more information about an error, try rustc --explain E0282.

``

``

14

`` +

For more information about this error, try rustc --explain E0282.

``