]>
Commit | Line | Data |
---|---|---|
1a4d82fc JJ |
1 | // Copyright 2012-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 | // aux-build:issue13507.rs | |
c34b1796 | 12 | |
1a4d82fc JJ |
13 | extern crate issue13507; |
14 | use issue13507::testtypes; | |
15 | ||
85aaf69f | 16 | use std::any::TypeId; |
1a4d82fc JJ |
17 | |
18 | pub fn type_ids() -> Vec<TypeId> { | |
54a0048b SL |
19 | use issue13507::testtypes::*; |
20 | vec![ | |
21 | TypeId::of::<FooBool>(), | |
22 | TypeId::of::<FooInt>(), | |
23 | TypeId::of::<FooUint>(), | |
24 | TypeId::of::<FooFloat>(), | |
25 | TypeId::of::<FooStr>(), | |
26 | TypeId::of::<FooArray>(), | |
27 | TypeId::of::<FooSlice>(), | |
28 | TypeId::of::<FooBox>(), | |
29 | TypeId::of::<FooPtr>(), | |
30 | TypeId::of::<FooRef>(), | |
31 | TypeId::of::<FooFnPtr>(), | |
32 | TypeId::of::<FooNil>(), | |
33 | TypeId::of::<FooTuple>(), | |
34 | TypeId::of::<FooTrait>(), | |
35 | TypeId::of::<FooStruct>(), | |
36 | TypeId::of::<FooEnum>() | |
37 | ] | |
1a4d82fc JJ |
38 | } |
39 | ||
40 | pub fn main() { | |
54a0048b | 41 | let othercrate = issue13507::testtypes::type_ids(); |
1a4d82fc JJ |
42 | let thiscrate = type_ids(); |
43 | assert_eq!(thiscrate, othercrate); | |
44 | } |