Update crates/wiggle/src/lib.rs

This commit is contained in:
Pat Hickey
2020-06-23 21:08:05 -07:00
committed by GitHub
parent 67f6aad415
commit c6e599219a

View File

@@ -540,7 +540,7 @@ impl<'a> GuestPtr<'a, str> {
} }
impl<'a> GuestPtr<'a, [u8]> { impl<'a> GuestPtr<'a, [u8]> {
/// Returns a raw pointer to the string represented by a `[u8]` without /// Returns a pointer to the string represented by a `[u8]` without
/// validating whether each u8 is a utf-8 codepoint. /// validating whether each u8 is a utf-8 codepoint.
pub fn as_str_ptr(&self) -> GuestPtr<'a, str> { pub fn as_str_ptr(&self) -> GuestPtr<'a, str> {
GuestPtr::new(self.mem, self.pointer) GuestPtr::new(self.mem, self.pointer)