]> git.lizzy.rs Git - rust.git/blob - src/libcollectionstest/lib.rs
Unignore u128 test for stage 0,1
[rust.git] / src / libcollectionstest / lib.rs
1 // Copyright 2015 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 #![deny(warnings)]
12
13 #![feature(binary_heap_extras)]
14 #![feature(binary_heap_peek_mut_pop)]
15 #![feature(box_syntax)]
16 #![feature(btree_range)]
17 #![feature(collection_placement)]
18 #![feature(collections)]
19 #![feature(collections_bound)]
20 #![feature(const_fn)]
21 #![feature(exact_size_is_empty)]
22 #![feature(pattern)]
23 #![feature(placement_in_syntax)]
24 #![feature(rand)]
25 #![feature(step_by)]
26 #![feature(str_escape)]
27 #![feature(test)]
28 #![feature(unboxed_closures)]
29 #![feature(unicode)]
30
31 extern crate collections;
32 extern crate test;
33 extern crate std_unicode;
34
35 use std::hash::{Hash, Hasher};
36 use std::collections::hash_map::DefaultHasher;
37
38 #[cfg(test)]
39 #[macro_use]
40 mod bench;
41
42 mod binary_heap;
43 mod btree;
44 mod cow_str;
45 mod fmt;
46 mod linked_list;
47 mod slice;
48 mod str;
49 mod string;
50 mod vec_deque;
51 mod vec;
52
53 fn hash<T: Hash>(t: &T) -> u64 {
54     let mut s = DefaultHasher::new();
55     t.hash(&mut s);
56     s.finish()
57 }