]> git.proxmox.com Git - rustc.git/blame - src/test/compile-fail/use-from-trait-xc.rs
New upstream version 1.12.0+dfsg1
[rustc.git] / src / test / compile-fail / use-from-trait-xc.rs
CommitLineData
1a4d82fc
JJ
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
970d7e83
LB
11// aux-build:use_from_trait_xc.rs
12
1a4d82fc
JJ
13extern crate use_from_trait_xc;
14
15use use_from_trait_xc::Trait::foo;
16//~^ ERROR `foo` is not directly importable
17
e9174d1e
SL
18use use_from_trait_xc::Trait::Assoc;
19//~^ ERROR `Assoc` is not directly importable
20
21use use_from_trait_xc::Trait::CONST;
22//~^ ERROR `CONST` is not directly importable
23
1a4d82fc 24use use_from_trait_xc::Foo::new;
92a42be0 25//~^ ERROR unresolved import `use_from_trait_xc::Foo::new`
1a4d82fc 26
e9174d1e
SL
27use use_from_trait_xc::Foo::C;
28//~^ ERROR unresolved import `use_from_trait_xc::Foo::C`
29
1a4d82fc 30use use_from_trait_xc::Bar::new as bnew;
92a42be0 31//~^ ERROR unresolved import `use_from_trait_xc::Bar::new`
970d7e83 32
1a4d82fc 33use use_from_trait_xc::Baz::new as baznew;
5bcae85e 34//~^ ERROR unresolved import `use_from_trait_xc::Baz::new`
970d7e83 35
1a4d82fc 36fn main() {}