More built-in constants; Get/set parsing fixes; I64.toF64 fixes

This commit is contained in:
dcodeIO
2018-01-02 21:41:25 +01:00
parent 2b182b505e
commit 1221ff129d
14 changed files with 448 additions and 47 deletions

View File

@ -17,6 +17,18 @@ export class Array<T> {
}
}
@operator("[]")
get(index: i32): T {
assert(index > 0 && index < this.capacity);
throw new Error("not implemented");
}
@operator("[]=")
set(index: i32, value: T): void {
assert(index > 0 && index < this.capacity);
throw new Error("not implemented");
}
dispose(): void {
store<i64>(changetype<usize>(this), 0);
Heap.dispose(this.ptr);