]> git.lizzy.rs Git - rust.git/commitdiff
Rename `core::char::Char` to `CharExt` to match prelude guidelines.
authorHuon Wilson <dbau.pp+github@gmail.com>
Tue, 30 Dec 2014 02:53:20 +0000 (13:53 +1100)
committerHuon Wilson <dbau.pp+github@gmail.com>
Mon, 5 Jan 2015 01:30:30 +0000 (12:30 +1100)
Imports may need to be updated so this is a

[breaking-change]

src/libcollections/lib.rs
src/libcollections/str.rs
src/libcore/char.rs
src/libcore/fmt/float.rs
src/libcore/fmt/mod.rs
src/libcore/num/mod.rs
src/libcore/prelude.rs
src/librustdoc/clean/mod.rs
src/libstd/io/mod.rs
src/libstd/prelude/v1.rs
src/libunicode/lib.rs

index 944b224fed8546d6c9b6ed5e7522baabf21c5bcc..bf3b35b4f6817a86eedb7533dc2f02582fd344b3 100644 (file)
@@ -103,7 +103,7 @@ mod std {
 mod prelude {
     // from core.
     pub use core::borrow::IntoCow;
-    pub use core::char::Char;
+    pub use core::char::CharExt;
     pub use core::clone::Clone;
     pub use core::cmp::{PartialEq, Eq, PartialOrd, Ord};
     pub use core::cmp::Ordering::{Less, Equal, Greater};
index ed6a957d2acfacbbecfe4de8238e9c85e92f25e3..ecf17820d2d8f72c58f44bc97d18c59a3b8666e9 100644 (file)
@@ -55,7 +55,7 @@
 use self::DecompositionType::*;
 
 use core::borrow::{BorrowFrom, ToOwned};
-use core::char::Char;
+use core::char::CharExt;
 use core::clone::Clone;
 use core::iter::AdditiveIterator;
 use core::iter::{range, Iterator, IteratorExt};
index 708b0bf86372286f0a58c30c7e3d78da88e2a75b..ce530ae1d32e513bcbaceca72a31150484844291 100644 (file)
@@ -112,7 +112,7 @@ pub fn from_digit(num: uint, radix: uint) -> Option<char> {
 
 /// Basic `char` manipulations.
 #[stable]
-pub trait Char {
+pub trait CharExt {
     /// Checks if a `char` parses as a numeric digit in the given radix.
     ///
     /// Compared to `is_numeric()`, this function only recognizes the characters
index 9e62226220c0ee84970da6e8273d8774f8fd018f..f63242b4f859a451d9bddabff995532c9d1ec900 100644 (file)
@@ -15,7 +15,7 @@
 pub use self::SignFormat::*;
 
 use char;
-use char::Char;
+use char::CharExt;
 use fmt;
 use iter::{IteratorExt, range};
 use num::{cast, Float, ToPrimitive};
index f49f87ff329f06ec39730882c8ccba7efe5c8fc1..102836f8d3024831044766fe17c0ec2062f66af3 100644 (file)
@@ -388,7 +388,7 @@ pub fn pad_integral(&mut self,
                         prefix: &str,
                         buf: &str)
                         -> Result {
-        use char::Char;
+        use char::CharExt;
         use fmt::rt::{FlagAlternate, FlagSignPlus, FlagSignAwareZeroPad};
 
         let mut width = buf.len();
@@ -504,7 +504,7 @@ pub fn pad(&mut self, s: &str) -> Result {
     fn with_padding<F>(&mut self, padding: uint, default: rt::Alignment, f: F) -> Result where
         F: FnOnce(&mut Formatter) -> Result,
     {
-        use char::Char;
+        use char::CharExt;
         let align = match self.align {
             rt::AlignUnknown => default,
             _ => self.align
@@ -613,7 +613,7 @@ fn fmt(&self, f: &mut Formatter) -> Result {
 
 impl Show for char {
     fn fmt(&self, f: &mut Formatter) -> Result {
-        use char::Char;
+        use char::CharExt;
 
         let mut utf8 = [0u8; 4];
         let amt = self.encode_utf8(&mut utf8).unwrap_or(0);
index 6c3b153c00057ce3b9a17ca6f91d21a6f2300191..426c858d408adb142123fba77c491184a239d08e 100644 (file)
@@ -15,7 +15,7 @@
 #![stable]
 #![allow(missing_docs)]
 
-use char::Char;
+use char::CharExt;
 use clone::Clone;
 use cmp::{PartialEq, Eq};
 use cmp::{PartialOrd, Ord};
index 64f13a8f123a8a634f227205cd24cf0d02c3c577..d4aca1bb73c23659e987f6774abfc3c64708cef9 100644 (file)
@@ -38,7 +38,7 @@
 
 // Reexported types and traits
 
-pub use char::Char;
+pub use char::CharExt;
 pub use clone::Clone;
 pub use cmp::{PartialEq, PartialOrd, Eq, Ord};
 pub use iter::{Extend, IteratorExt};
index f4d0bb79d88d6b74268d4448d90eb5d16d44ed55..5f6c62f1d7a68fc4321a5b6212012f2cb7f7ae37 100644 (file)
@@ -50,7 +50,6 @@
 use std::rc::Rc;
 use std::u32;
 use std::str::Str as StrTrait; // Conflicts with Str variant
-use std::char::Char as CharTrait; // Conflicts with Char variant
 use std::path::Path as FsPath; // Conflicts with Path struct
 
 use core::DocContext;
index ae401a04a96f0a23db4d662ee0fd5658a755745a..51bf206f70e9f55dbb6bb5ccb3f7afbaf7639507 100644 (file)
 pub use self::FileAccess::*;
 pub use self::IoErrorKind::*;
 
-use char::Char;
+use char::CharExt;
 use clone::Clone;
 use default::Default;
 use error::{FromError, Error};
index a122cb81b8c423ed169d9259079b490ed3668f82..eda20fc7d603fc54b43fe9f31a733a7884d7faca 100644 (file)
@@ -22,7 +22,7 @@
 // Reexported types and traits
 
 #[stable] #[doc(no_inline)] pub use boxed::Box;
-#[stable] #[doc(no_inline)] pub use char::{Char, UnicodeChar};
+#[stable] #[doc(no_inline)] pub use char::{CharExt, UnicodeChar};
 #[stable] #[doc(no_inline)] pub use clone::Clone;
 #[stable] #[doc(no_inline)] pub use cmp::{PartialEq, PartialOrd, Eq, Ord};
 #[stable] #[doc(no_inline)] pub use iter::CloneIteratorExt;
index 1a619e57a9ce1ea8b73aaf092c59543711286881..170700fb4d5fe207dddcd65137f216de87be5249 100644 (file)
@@ -58,7 +58,7 @@
 /// however the converse is not always true due to the above range limits
 /// and, as such, should be performed via the `from_u32` function..
 pub mod char {
-    pub use core::char::{MAX, from_u32, from_digit, Char};
+    pub use core::char::{MAX, from_u32, from_digit, CharExt};
 
     pub use normalize::{decompose_canonical, decompose_compatible, compose};