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.
- Loading branch information
Showing
21 changed files
with
3,235 additions
and
3,216 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
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 |
---|---|---|
@@ -1,16 +1,14 @@ | ||
namespace 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 {} | ||
↯import("homestar:host/helpers", "get-current-time") | ||
micro get_current_time() -> Time { } | ||
|
||
⍝? Basic `print` helper. | ||
#import("homestar:host/helpers", "print") | ||
micro print(msg: Utf8Text) -> () {} | ||
↯import("homestar:host/helpers", "print") | ||
micro print(msg: utf8) -> () { } | ||
|
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,12 +1,10 @@ | ||
{ | ||
"name": "homestar.host", | ||
"version": "0.0.1", | ||
"description": "Legion", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"author": "Jonathan Hersh", | ||
"description": "Legion", | ||
"binary": "file://c/real/path/sha.256.wasm", | ||
"license": "MIT", | ||
"dependencies": { | ||
} | ||
} | ||
} |
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,23 @@ | ||
Currently, `wasmtime`'s error in wat text files are based on the compilation offset. | ||
|
||
When an error occurs, it is very confusing where the error occurred. | ||
|
||
I would like to attach some source language location information to point out the error location. | ||
|
||
Similar to: | ||
|
||
```wat | ||
;; @url: file://path/position.wasm:line:column | ||
(type $test-type (externref)) | ||
;; @url: file://path/position.wasm:offset | ||
(func $test-function | ||
;; @file: main.rs:12:24 | ||
(block $test-block | ||
) | ||
) | ||
``` | ||
|
||
`binaryen` supports similar features | ||
like: https://github.com/WebAssembly/binaryen/blob/921644ca65afbafb84fb82d58dacc4a028e2d720/test/lit/debug/full.wat#L49-L64 | ||
|
Oops, something went wrong.