diff options
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/extfmt.rs | 4 | ||||
| -rw-r--r-- | src/libcore/option.rs | 2 | ||||
| -rw-r--r-- | src/libcore/str.rs | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/libcore/extfmt.rs b/src/libcore/extfmt.rs index 5acb45fdf1a..d41393c2393 100644 --- a/src/libcore/extfmt.rs +++ b/src/libcore/extfmt.rs @@ -329,11 +329,11 @@ pub mod rt { // For strings, precision is the maximum characters // displayed let mut unpadded = match cv.precision { - CountImplied => s.to_unique(), + CountImplied => s.to_owned(), CountIs(max) => if max as uint < str::char_len(s) { str::substr(s, 0u, max as uint) } else { - s.to_unique() + s.to_owned() } }; return unsafe { pad(cv, move unpadded, PadNozero) }; diff --git a/src/libcore/option.rs b/src/libcore/option.rs index f8bafe29fdd..50489a82029 100644 --- a/src/libcore/option.rs +++ b/src/libcore/option.rs @@ -225,7 +225,7 @@ pub fn swap_unwrap<T>(opt: &mut Option<T>) -> T { pub pure fn unwrap_expect<T>(opt: Option<T>, reason: &str) -> T { //! As unwrap, but with a specified failure message. - if opt.is_none() { fail reason.to_unique(); } + if opt.is_none() { fail reason.to_owned(); } unwrap(move opt) } diff --git a/src/libcore/str.rs b/src/libcore/str.rs index d32d35cbe1a..3122f3d7f32 100644 --- a/src/libcore/str.rs +++ b/src/libcore/str.rs @@ -2135,7 +2135,7 @@ pub trait StrSlice { pure fn trim() -> ~str; pure fn trim_left() -> ~str; pure fn trim_right() -> ~str; - pure fn to_unique() -> ~str; + pure fn to_owned() -> ~str; pure fn to_managed() -> @str; pure fn char_at(i: uint) -> char; } @@ -2258,7 +2258,7 @@ impl &str: StrSlice { pure fn trim_right() -> ~str { trim_right(self) } #[inline] - pure fn to_unique() -> ~str { self.slice(0, self.len()) } + pure fn to_owned() -> ~str { self.slice(0, self.len()) } #[inline] pure fn to_managed() -> @str { |
