Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions std/assembly/builtins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2302,11 +2302,17 @@ export abstract class i31 { // FIXME: usage of 'new' requires a class :(

// @ts-ignore: decorator
@builtin
static new(value: i32): i31ref { return unreachable(); }
static new(value: i32): i31ref {
unreachable();
return changetype<i31ref>(0);
}

// @ts-ignore: decorator
@builtin
static get(i31expr: i31ref): i32 { return unreachable(); }
static get(i31expr: i31ref): i32 {
unreachable();
return 0;
}
}

/* eslint-disable @typescript-eslint/no-unused-vars */
Expand Down