Assemble kernel on the client #1

Merged
cdo merged 72 commits from client-side-assembler into main 2026-03-18 15:21:33 +00:00
Showing only changes of commit 714973f052 - Show all commits

13
asm.js
View File

@@ -750,12 +750,17 @@ export class Assembler {
?? this.lookup_param(func, action.symbol)
?? this.lookup_local(func, action.symbol)
?? this.lookup_global(action.symbol)
?? this.lookup_def(action.symbol);
if (value == null) {
console.error(
`ERROR: Unable to resolve symbol ${action.symbol}`);
const def_value = this.lookup_def(action.symbol);
if (def_value == null) {
console.error(
`ERROR: Unable to resolve symbol ${action.symbol}`);
return;
}
func.body.push(...this.leb128(def_value));
} else {
func.body.push(value);
}
func.body.push(value);
}
action_mem(action) {