Delete Utf8Lossy::from_str
This commit is contained in:
parent
e6b883c74f
commit
4b0a9c9bc3
1 changed files with 0 additions and 5 deletions
|
@ -12,11 +12,6 @@ pub struct Utf8Lossy {
|
|||
}
|
||||
|
||||
impl Utf8Lossy {
|
||||
#[must_use]
|
||||
pub fn from_str(s: &str) -> &Utf8Lossy {
|
||||
Utf8Lossy::from_bytes(s.as_bytes())
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn from_bytes(bytes: &[u8]) -> &Utf8Lossy {
|
||||
// SAFETY: Both use the same memory layout, and UTF-8 correctness isn't required.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue