generated from oovm/RustTemplate
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support extract definitions from wasm
- Loading branch information
Showing
9 changed files
with
96 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
mod exports; | ||
mod extractor; | ||
mod helpers; | ||
mod imports; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
namespace homestar.host; | ||
|
||
class Time { | ||
seconds: u64, | ||
milliseconds: u32, | ||
nanoseconds: u32, | ||
} | ||
|
||
⍝? Get current time in sub-seconds. | ||
#import("homestar:host/helpers", "get-current-time") | ||
micro get_current_time() -> Time {} | ||
|
||
⍝? Basic `print` helper. | ||
#import("homestar:host/helpers", "print") | ||
micro print(msg: Utf8Text) -> () {} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
enumerate Level { | ||
#export("trace") | ||
Trace, | ||
#export("debug") | ||
Debug, | ||
#export("info") | ||
Info, | ||
#export("warn") | ||
Warn, | ||
#export("error") | ||
Error, | ||
#export("critical") | ||
Critical, | ||
} | ||
|
||
#import("wasi:logging/logging", "log") | ||
micro log(level: Level, context: utf8, message: utf8) -> () { } | ||
|
This file was deleted.
Oops, something went wrong.