]> git.proxmox.com Git - rustc.git/blame - src/librustc_unicode/lib.rs
Imported Upstream version 1.2.0+dfsg1
[rustc.git] / src / librustc_unicode / lib.rs
CommitLineData
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//! # The Unicode Library
12//!
13//! Unicode-intensive functions for `char` and `str` types.
14//!
15//! This crate provides a collection of Unicode-related functionality,
16//! including decompositions, conversions, etc., and provides traits
17//! implementing these functions for the `char` and `str` types.
18//!
19//! The functionality included here is only that which is necessary to
20//! provide for basic string-related manipulations. This crate does not
21//! (yet) aim to provide a full set of Unicode tables.
22
c34b1796
AL
23// Do not remove on snapshot creation. Needed for bootstrap. (Issue #22364)
24#![cfg_attr(stage0, feature(custom_attribute))]
d9579d0f 25#![crate_name = "rustc_unicode"]
85aaf69f 26#![unstable(feature = "unicode")]
1a4d82fc
JJ
27#![staged_api]
28#![crate_type = "rlib"]
29#![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
62682a34 30 html_favicon_url = "https://doc.rust-lang.org/favicon.ico",
1a4d82fc 31 html_root_url = "http://doc.rust-lang.org/nightly/",
62682a34
SL
32 html_playground_url = "http://play.rust-lang.org/",
33 test(no_crate_inject))]
1a4d82fc 34#![no_std]
62682a34 35
85aaf69f 36#![feature(core)]
62682a34
SL
37#![feature(core_char_ext)]
38#![feature(core_prelude)]
39#![feature(core_slice_ext)]
40#![feature(core_str_ext)]
41#![feature(iter_arith)]
42#![feature(lang_items)]
43#![feature(no_std)]
44#![feature(staged_api)]
1a4d82fc
JJ
45
46extern crate core;
47
1a4d82fc
JJ
48mod normalize;
49mod tables;
1a4d82fc 50mod u_str;
c34b1796 51pub mod char;
1a4d82fc
JJ
52
53pub mod str {
d9579d0f 54 pub use u_str::{UnicodeStr, SplitWhitespace, Words, Graphemes, GraphemeIndices};
1a4d82fc
JJ
55 pub use u_str::{utf8_char_width, is_utf16, Utf16Items, Utf16Item};
56 pub use u_str::{utf16_items, Utf16Encoder};
57}
62682a34
SL
58
59// For use in libcollections, not re-exported in libstd.
60pub mod derived_property {
61 pub use tables::derived_property::{Cased, Case_Ignorable};
62}