]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #42904 - estebank:number-suggestions, r=nikomatsakis
authorbors <bors@rust-lang.org>
Thu, 6 Jul 2017 22:22:21 +0000 (22:22 +0000)
committerbors <bors@rust-lang.org>
Thu, 6 Jul 2017 22:22:21 +0000 (22:22 +0000)
Make suggestion include the line number

When there're more than one suggestions in the same diagnostic, they are
displayed in their own block, instead of inline. In order to reduce
confusion, those blocks now display the line number.

New output:

```
error[E0308]: mismatched types
  --> ../../src/test/ui/block-result/unexpected-return-on-unit.rs:19:5
   |
19 |     foo()
   |     ^^^^^ expected (), found usize
   |
   = note: expected type `()`
              found type `usize`
help: did you mean to add a semicolon here?
   |
19 |     foo();
   |          ^
help: possibly return type missing here?
   |
18 | fn bar() -> usize {
   |          ^^^^^^^^

error: aborting due to previous error(s)
```

Fix #39152.


Trivial merge