-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
rustc_resolve: overhaul #![feature(uniform_paths)]
error reporting.
#53427
Conversation
@bors p=10 (somewhat blocking Edition Preview 2 testing) |
This comment has been minimized.
This comment has been minimized.
c81b481
to
a5bb0c6
Compare
This comment has been minimized.
This comment has been minimized.
a5bb0c6
to
bcf864d
Compare
📌 Commit bcf864db8993218f9e8a2affe0e83c5a9810d402 has been approved by |
⌛ Testing commit bcf864db8993218f9e8a2affe0e83c5a9810d402 with merge 8d83a20b14dec23b2c82c9e2fa655ead377e8d04... |
💔 Test failed - status-travis |
This comment has been minimized.
This comment has been minimized.
@bors retry |
⌛ Testing commit bcf864db8993218f9e8a2affe0e83c5a9810d402 with merge 60de86d7c8dece92a7c289a0924574b2cdef4c3e... |
💔 Test failed - status-appveyor |
bcf864d
to
7a87e30
Compare
@bors r=varkor (sadly I don't think this will make the nightly, oops) |
📌 Commit 7a87e30 has been approved by |
rustc_resolve: overhaul `#![feature(uniform_paths)]` error reporting. Fixes #53408 by only considering external crates to conflict within their (type/module) namespace, *not* with the value or macro namespaces, and also by adding a special-cased error for redundant `use crate_name;` imports (without actually allowing them). Also, all canaries for a given import are grouped into one diagnostic per namespace, in order to make block-scoped ambiguities clearer. See changed/added tests for more details. r? @petrochenkov cc @aturon @joshtriplett
☀️ Test successful - status-appveyor, status-travis |
| refers to external crate `::std` | ||
| defines `self::std`, shadowing itself | ||
| | ||
= help: remove or write `::std` explicitly instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't use ::somecrate;
be redundant as well, because extern_prelude
makes somecrate
already available?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's redundant for direct uses of the imported name but maybe you actually want use ::std as _;
or something.
Fixes #53408 by only considering external crates to conflict within their (type/module) namespace, not with the value or macro namespaces, and also by adding a special-cased error for redundant
use crate_name;
imports (without actually allowing them).Also, all canaries for a given import are grouped into one diagnostic per namespace, in order to make block-scoped ambiguities clearer.
See changed/added tests for more details.
r? @petrochenkov cc @aturon @joshtriplett