]> git.lizzy.rs Git - rust.git/blob - src/test/compile-fail/import-shadow-3.rs
Update compile fail tests to use isize.
[rust.git] / src / test / compile-fail / import-shadow-3.rs
1 // Copyright 2014 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
4 //
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
10
11 // Test that import shadowing using globs causes errors
12
13 #![no_implicit_prelude]
14
15 use foo::Baz;
16 use bar::*; //~ERROR a type named `Baz` has already been imported in this module
17
18 mod foo {
19     pub type Baz = isize;
20 }
21
22 mod bar {
23     pub type Baz = isize;
24 }
25
26 mod qux {
27     pub use bar::Baz;
28 }
29
30 fn main() {}