2018-08-16 07:59:33 -05:00
|
|
|
error: `Foo` import is ambiguous
|
|
|
|
--> $DIR/block-scoped-shadow.rs:21:9
|
2018-08-13 10:24:08 -05:00
|
|
|
|
|
2018-08-16 07:59:33 -05:00
|
|
|
LL | enum Foo { A, B }
|
|
|
|
| ----------------- can refer to `self::Foo`
|
|
|
|
...
|
2018-08-13 10:24:08 -05:00
|
|
|
LL | enum Foo {}
|
|
|
|
| ----------- shadowed by block-scoped `Foo`
|
|
|
|
LL | use Foo::*;
|
|
|
|
| ^^^
|
|
|
|
|
|
2018-08-16 07:59:33 -05:00
|
|
|
= help: write `self::Foo` explicitly instead
|
2018-08-13 10:24:08 -05:00
|
|
|
= note: relative `use` paths enabled by `#![feature(uniform_paths)]`
|
|
|
|
|
2018-08-16 07:59:33 -05:00
|
|
|
error: `std` import is ambiguous
|
|
|
|
--> $DIR/block-scoped-shadow.rs:28:9
|
|
|
|
|
|
|
|
|
LL | struct std;
|
|
|
|
| ----------- can refer to `self::std`
|
|
|
|
...
|
|
|
|
LL | enum std {}
|
|
|
|
| ----------- shadowed by block-scoped `std`
|
|
|
|
LL | use std as foo;
|
|
|
|
| ^^^ can refer to external crate `::std`
|
|
|
|
|
|
|
|
|
= help: write `::std` or `self::std` explicitly instead
|
|
|
|
= note: relative `use` paths enabled by `#![feature(uniform_paths)]`
|
|
|
|
|
|
|
|
error: `std` import is ambiguous
|
|
|
|
--> $DIR/block-scoped-shadow.rs:28:9
|
|
|
|
|
|
|
|
|
LL | struct std;
|
|
|
|
| ----------- can refer to `self::std`
|
|
|
|
...
|
|
|
|
LL | fn std() {}
|
|
|
|
| ----------- shadowed by block-scoped `std`
|
|
|
|
LL | enum std {}
|
|
|
|
LL | use std as foo;
|
|
|
|
| ^^^
|
|
|
|
|
|
|
|
|
= help: write `self::std` explicitly instead
|
|
|
|
= note: relative `use` paths enabled by `#![feature(uniform_paths)]`
|
|
|
|
|
|
|
|
error: aborting due to 3 previous errors
|
2018-08-13 10:24:08 -05:00
|
|
|
|