mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-06-14 23:41:30 +00:00
More stdlib setup
This commit is contained in:
16
std/assembly/error.ts
Normal file
16
std/assembly/error.ts
Normal file
@ -0,0 +1,16 @@
|
||||
@global()
|
||||
export class Error {
|
||||
|
||||
name: string = "Error";
|
||||
message: string;
|
||||
stack: string = ""; // TODO
|
||||
|
||||
constructor(message: string = "") {
|
||||
this.message = message;
|
||||
}
|
||||
}
|
||||
|
||||
@global()
|
||||
export class RangeError extends Error {
|
||||
name: string = "RangeError";
|
||||
}
|
Reference in New Issue
Block a user