Rollup merge of #45856 - estebank:issue-45829, r=nikomatsakis

Fix help for duplicated names: `extern crate (...) as (...)`

On the case of duplicated names caused by an `extern crate` statement
with a rename, don't include the inline suggestion, instead using a span
label with only the text to avoid incorrect rust code output.

Fix #45829.
This commit is contained in:
kennytm 2017-11-10 17:07:05 +08:00 committed by GitHub
commit de083eb165
9 changed files with 74 additions and 8 deletions

View file

@ -18,5 +18,6 @@ extern crate libc as alloc;
//~^ ERROR E0259
//~| NOTE `alloc` reimported here
//~| NOTE `alloc` must be defined only once in the type namespace of this module
//~| NOTE You can use `as` to change the binding name of the import
fn main() {}