Assemble kernel on the client #1
5
asm.js
5
asm.js
@@ -680,7 +680,8 @@ export class Assembler {
|
|||||||
?? this.lookup_global(action.symbol)
|
?? this.lookup_global(action.symbol)
|
||||||
?? this.lookup_def(action.symbol);
|
?? this.lookup_def(action.symbol);
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
console.error(`ERROR: Unable to resolve symbol {action.symbol}`);
|
console.error(
|
||||||
|
`ERROR: Unable to resolve symbol ${action.symbol}`);
|
||||||
value = 0;
|
value = 0;
|
||||||
}
|
}
|
||||||
func.body.push(value);
|
func.body.push(value);
|
||||||
@@ -710,7 +711,7 @@ export class Assembler {
|
|||||||
action_at(action) {
|
action_at(action) {
|
||||||
const mem = Object.keys(this.mems).indexOf(action.at.mem);
|
const mem = Object.keys(this.mems).indexOf(action.at.mem);
|
||||||
if (mem == -1) {
|
if (mem == -1) {
|
||||||
console.error(`ERROR: No memory named {action.at.mem}`);
|
console.error(`ERROR: No memory named ${action.at.mem}`);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.pos.mem = mem;
|
this.pos.mem = mem;
|
||||||
|
|||||||
Reference in New Issue
Block a user