make it a wasi executable

This commit is contained in:
nora 2023-07-26 21:35:31 +02:00
parent 8dd7c174ee
commit 1d0e3a3aff
7 changed files with 87 additions and 13 deletions

View file

@ -17,8 +17,8 @@ const BUILTIN_SET = new Set<string>(BUILTINS);
export function resolve(ast: Ast): Ast {
const items = new Map<string, number>();
for (let i = 0; i < ast.length; i++) {
const item = ast[i];
for (let i = 0; i < ast.items.length; i++) {
const item = ast.items[i];
const existing = items.get(item.node.name);
if (existing !== undefined) {
throw new CompilerError(