# Refactor link/wasm.zig to use offset table · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/ff5774d93d9d952a74fab3666d4480f534c770db)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: ff5774d93d9d952a74fab3666d4480f534c770db

Requested commit: ff5774d93d9d952a74fab3666d4480f534c770db

Commit: ff5774d93d9d952a74fab3666d4480f534c770db

Tree: 910dfe9685f5acd65efead91c86ef758a452e702

Author: Luuk de Gram

Committer: Luuk de Gram

## Message

```
Refactor link/wasm.zig to use offset table

This refactor inserts an offset table into wasm's data section
where each offset points to the actual data region.
This means we can keep offset indexes consistant and do not
have to perform any computer to determine where in the data section
something like a static string exists. Instead during runtime
it will load the data offset onto the stack.

```

## Parents

- [47f36427887fc7d1646cfb7ed8eeeeb14cd3555b](https://git.cafe/gitcafe/zig/commit/47f36427887fc7d1646cfb7ed8eeeeb14cd3555b?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/ff5774d93d9d952a74fab3666d4480f534c770db?format=markdown)
