mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Move to to_owned rather than into_string.
into_string has been removed from Rust.
This commit is contained in:
parent
2d5b0e0855
commit
01ed338746
67 changed files with 473 additions and 383 deletions
|
@ -6,6 +6,7 @@
|
|||
|
||||
//! The `ByteString` struct.
|
||||
|
||||
use std::borrow::ToOwned;
|
||||
use std::hash::{Hash, sip};
|
||||
use std::str;
|
||||
use std::str::FromStr;
|
||||
|
@ -154,6 +155,6 @@ impl Hash for ByteString {
|
|||
|
||||
impl FromStr for ByteString {
|
||||
fn from_str(s: &str) -> Option<ByteString> {
|
||||
Some(ByteString::new(s.into_string().into_bytes()))
|
||||
Some(ByteString::new(s.to_owned().into_bytes()))
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue