This commit is contained in:
Folkert 2020-12-14 21:50:05 +01:00
parent 7b6cff6b49
commit 322fecb7fb

View file

@ -390,6 +390,7 @@ impl RocStr {
unsafe { core::slice::from_raw_parts(self.elements, self.length) }
}
}
#[allow(clippy::missing_safety_doc)]
pub unsafe fn as_str(&self) -> &str {
let slice = self.as_slice();