Put context object behind a ref rather than mut ref

This commit puts context object, i.e., the implementor of the
WASI snapshot, behind a reference `&self` rather than a mutable
reference `&mut self`. As suggested by @alexcrichton, this gives
the implementor the possibility to determine how it handles its
interior mutability.
This commit is contained in:
Jakub Konka
2020-03-03 15:25:11 +01:00
committed by Jakub Konka
parent ea4d2d0535
commit 3764204250
13 changed files with 74 additions and 78 deletions

View File

@@ -11,7 +11,7 @@ impl_errno!(types::Errno);
impl pointers::Pointers for WasiCtx {
fn pointers_and_enums(
&mut self,
&self,
input1: types::Excuse,
input2_ptr: GuestPtrMut<types::Excuse>,
input3_ptr: GuestPtr<types::Excuse>,