Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resolve: Add a test for issue #57539 #57551

Merged
merged 1 commit into from
Jan 18, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/test/ui/imports/issue-57539.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// edition:2018

mod core {
use core; //~ ERROR `core` is ambiguous
use crate::*;
}

fn main() {}
18 changes: 18 additions & 0 deletions src/test/ui/imports/issue-57539.stderr
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
error[E0659]: `core` is ambiguous (name vs any other name during import resolution)
--> $DIR/issue-57539.rs:4:9
|
LL | use core; //~ ERROR `core` is ambiguous
| ^^^^ ambiguous name
|
= note: `core` could refer to a built-in extern crate
= help: use `::core` to refer to this extern crate unambiguously
note: `core` could also refer to the module imported here
--> $DIR/issue-57539.rs:5:9
|
LL | use crate::*;
| ^^^^^^^^
= help: use `self::core` to refer to this module unambiguously

error: aborting due to previous error

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