Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: Start Wasm table for the RTS at offset >= 1 (#4685)
Rust requires a table offset of at least 1 as the element index 0 is considered invalid and causes a debug null check to panic when called. On the other hand, `elem[0]` can be used by the Motoko backend code, as correct Rust-generated Wasm code does not call `elem[0]`. This bug is independent of `wasm32` and `wasm64`. This issue has been observed in https://github.com/dfinity/motoko/actions/runs/10703077671/job/29672766216?pr=4683 and happened only on Linux and only under `nix-build` (not `nix-shell`).
- Loading branch information