-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Labels
wasm-proposal:gcIssues with the implementation of the gc wasm proposalIssues with the implementation of the gc wasm proposalwasmtime:unsafe-codeIssues related to `unsafe` blocks in Wasmtime over time, either reducing or scoping them typically.Issues related to `unsafe` blocks in Wasmtime over time, either reducing or scoping them typically.
Description
This line of code:
.grow(delta_pages_for_alloc, Some(self.traitobj().as_mut()))? |
expands a borrow of &mut StoreOpaque
(self
in this case) into a &mut dyn VMStore
which is effectively a &mut StoreInner<T>
. This is a "widening" operation which makes the original mutable borrow wider by encompassing more fields. This is not a sound operation because a caller might simultaneously be borrowing &mut StoreOpaque
and &mut T
or similarly.
Metadata
Metadata
Assignees
Labels
wasm-proposal:gcIssues with the implementation of the gc wasm proposalIssues with the implementation of the gc wasm proposalwasmtime:unsafe-codeIssues related to `unsafe` blocks in Wasmtime over time, either reducing or scoping them typically.Issues related to `unsafe` blocks in Wasmtime over time, either reducing or scoping them typically.