Skip to content

Commit

Permalink
Fix docstring for MemoryView struct
Browse files Browse the repository at this point in the history
It says to use Memory.grow() to get a view, but
Memory.view() is what returns a MemoryView.
  • Loading branch information
vinnymeller committed Jul 9, 2023
1 parent c02f7a7 commit cd921ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/api/src/externals/memory_view.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use crate::sys::externals::memory_view as memory_view_impl;
/// A memory view is used to read and write to the linear memory.
///
/// After a memory is grown a view must not be used anymore. Views are
/// created using the Memory.grow() method.
/// created using the Memory.view() method.
#[derive(Debug)]
pub struct MemoryView<'a>(pub(crate) memory_view_impl::MemoryView<'a>);

Expand Down

0 comments on commit cd921ad

Please sign in to comment.