]> git.lizzy.rs Git - rust.git/commit
Auto merge of #54011 - eddyb:anchored-in-the-future, r=petrochenkov
authorbors <bors@rust-lang.org>
Mon, 10 Sep 2018 10:28:53 +0000 (10:28 +0000)
committerbors <bors@rust-lang.org>
Mon, 10 Sep 2018 10:28:53 +0000 (10:28 +0000)
commit595345419d12c3ea860151df52f78744a31bafff
tree60b6af371b197266ec08e1a37e9a3a0ec65d1114
parentb8d45da2747c0b0943f48854e653ebe0d1ba60c9
parentd5da94a3b1e635eeb9520b87f6414ff3c24c8602
Auto merge of #54011 - eddyb:anchored-in-the-future, r=petrochenkov

rustc_resolve: inject `uniform_paths` canaries regardless of the feature-gate, on Rust 2018.

This PR is an attempt at future-proofing "anchored paths" by emitting the same ambiguity errors that `#![feature(uniform_paths)]` would, with slightly changed phrasing (see added UI tests).

Also, on top of #54005, this PR allows this as well:
```rust
use crate_name;
use crate_name::foo;
```
In that any ambiguity between an extern crate and an import *of that same crate* is ignored.

r? @petrochenkov cc @aturon @Centril @joshtriplett
src/librustc_resolve/resolve_imports.rs