Skip to content

Commit

Permalink
chore: Update offset constant names after rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
spotandjake committed Feb 17, 2025
1 parent b37366d commit 68627d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions stdlib/array.gr
Original file line number Diff line number Diff line change
Expand Up @@ -162,13 +162,13 @@ provide let tryInit = (length: Number, fn: Number => Result<a, b>) => {
WasmI32.store(
array,
Memory.incRef(WasmI32.fromGrain(value)),
_ARRAY_START_OFFSET + i
_ARRAY_DATA_OFFSET + i
)
index += 1n
},
Err(e) => {
for (let mut j = 0n; j < i; j += 4n) {
ignore(Memory.decRef(WasmI32.load(array, _ARRAY_START_OFFSET + j)))
ignore(Memory.decRef(WasmI32.load(array, _ARRAY_DATA_OFFSET + j)))
}
Memory.free(array)
return Err(e)
Expand Down

0 comments on commit 68627d0

Please sign in to comment.