1 // Copyright 2013-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.
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.
13 //! See [std::collections](../std/collections) for a detailed discussion of collections in Rust.
16 #![crate_name = "collections"]
18 #![crate_type = "rlib"]
19 #![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
20 html_favicon_url = "http://www.rust-lang.org/favicon.ico",
21 html_root_url = "http://doc.rust-lang.org/nightly/",
22 html_playground_url = "http://play.rust-lang.org/")]
24 #![allow(unknown_features)]
25 #![feature(unsafe_destructor, slicing_syntax)]
26 #![feature(old_impl_check)]
27 #![feature(unboxed_closures)]
36 #[cfg(test)] extern crate test;
37 #[cfg(test)] #[macro_use] extern crate std;
38 #[cfg(test)] #[macro_use] extern crate log;
40 pub use binary_heap::BinaryHeap;
42 pub use bitv_set::BitvSet;
43 pub use btree_map::BTreeMap;
44 pub use btree_set::BTreeSet;
46 pub use enum_set::EnumSet;
47 pub use ring_buf::RingBuf;
48 pub use string::String;
50 pub use vec_map::VecMap;
52 // Needed for the vec! macro
72 pub use bit::{Bitv, Iter};
77 pub use bit::{BitvSet, Union, Intersection, Difference, SymmetricDifference};
78 pub use bit::SetIter as Iter;
83 pub use btree::map::*;
88 pub use btree::set::*;
92 #[cfg(test)] mod bench;
94 // FIXME(#14344) this shouldn't be necessary
96 pub fn fixme_14344_be_sure_to_link_to_collections() {}
100 pub use core::fmt; // necessary for panic!()
101 pub use core::option; // necessary for panic!()
102 pub use core::clone; // deriving(Clone)
103 pub use core::cmp; // deriving(Eq, Ord, etc.)
105 pub use core::marker as kinds;
106 pub use core::marker; // deriving(Copy)
107 pub use core::hash; // deriving(Hash)
113 pub use core::borrow::IntoCow;
114 pub use core::clone::Clone;
115 pub use core::cmp::{PartialEq, Eq, PartialOrd, Ord};
116 pub use core::cmp::Ordering::{Less, Equal, Greater};
117 pub use core::iter::range;
118 pub use core::iter::{FromIterator, Extend, IteratorExt};
119 pub use core::iter::{Iterator, DoubleEndedIterator, RandomAccessIterator};
120 pub use core::iter::{ExactSizeIterator};
121 pub use core::marker::{Copy, Send, Sized, Sync};
122 pub use core::mem::drop;
123 pub use core::ops::{Drop, Fn, FnMut, FnOnce};
124 pub use core::option::Option;
125 pub use core::option::Option::{Some, None};
126 pub use core::ptr::PtrExt;
127 pub use core::result::Result;
128 pub use core::result::Result::{Ok, Err};
130 // in core and collections (may differ).
131 pub use slice::{AsSlice, SliceExt};
132 pub use str::{Str, StrExt};
134 // from other crates.
135 pub use alloc::boxed::Box;
136 pub use unicode::char::CharExt;
139 pub use slice::SliceConcatExt;
140 pub use string::{String, ToString};