Skip to content
This repository was archived by the owner on Nov 25, 2025. It is now read-only.

Commit afa82c7

Browse files
authored
Merge pull request #138 from WebAssembly/revert-137-update-wit-0.3.0-rc-2025-09-16
Revert "Update 0.3.0 WIT definitions to 0.3.0-rc-2025-09-16"
2 parents 48bfb9c + 2e0157a commit afa82c7

File tree

6 files changed

+68
-79
lines changed

6 files changed

+68
-79
lines changed

wit-0.3.0-draft/deps.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[clocks]
22
url = "https://github.com/WebAssembly/wasi-clocks/archive/main.tar.gz"
33
subdir = "wit-0.3.0-draft"
4-
sha256 = "d0257e056a4061eaab58a934d84b4b35534d90866667054e886da65c170aeef6"
5-
sha512 = "b033cd0171d9d0c908b17f98f792e47eaeee7534d4bca664c62bdab6f48a8046179e068d4ef11d1e333d3ca44777691b14293eb955e88fda701bdcf90637efae"
4+
sha256 = "626953ec28ae956ec1233c4350deab6e5cdcbdd9ae6d491e102ad7c6901cc8bf"
5+
sha512 = "ae375b002cfaacdbaa133bb87747d1b86675e13144067c3005d6c32cf5c37bb7a52b693ae46d5cd65fc4910a78d7255d0ada5142828a022497fd0eaacb61761f"

wit-0.3.0-draft/deps/clocks/monotonic-clock.wit

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,20 @@ package wasi:[email protected];
99
/// successive reads of the clock will produce non-decreasing values.
1010
@since(version = 0.3.0-rc-2025-08-15)
1111
interface monotonic-clock {
12-
use types.{duration};
13-
1412
/// An instant in time, in nanoseconds. An instant is relative to an
1513
/// unspecified initial value, and can only be compared to instances from
1614
/// the same monotonic-clock.
1715
@since(version = 0.3.0-rc-2025-08-15)
1816
type instant = u64;
1917

18+
/// A duration of time, in nanoseconds.
19+
@since(version = 0.3.0-rc-2025-08-15)
20+
type duration = u64;
21+
2022
/// Read the current value of the clock.
2123
///
2224
/// The clock is monotonic, therefore calling this function repeatedly will
2325
/// produce a sequence of non-decreasing values.
24-
///
25-
/// For completeness, this function traps if it's not possible to represent
26-
/// the value of the clock in an `instant`. Consequently, implementations
27-
/// should ensure that the starting time is low enough to avoid the
28-
/// possibility of overflow in practice.
2926
@since(version = 0.3.0-rc-2025-08-15)
3027
now: func() -> instant;
3128

@@ -40,7 +37,7 @@ interface monotonic-clock {
4037
when: instant,
4138
);
4239

43-
/// Wait for the specified duration to elapse.
40+
/// Wait for the specified duration has elapsed.
4441
@since(version = 0.3.0-rc-2025-08-15)
4542
wait-for: async func(
4643
how-long: duration,

wit-0.3.0-draft/deps/clocks/types.wit

Lines changed: 0 additions & 8 deletions
This file was deleted.

wit-0.3.0-draft/ip-name-lookup.wit

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
@since(version = 0.3.0-rc-2025-09-16)
1+
@since(version = 0.3.0-rc-2025-08-15)
22
interface ip-name-lookup {
3-
@since(version = 0.3.0-rc-2025-09-16)
3+
@since(version = 0.3.0-rc-2025-08-15)
44
use types.{ip-address};
55

66
/// Lookup error codes.
7-
@since(version = 0.3.0-rc-2025-09-16)
7+
@since(version = 0.3.0-rc-2025-08-15)
88
enum error-code {
99
/// Unknown error
1010
unknown,
@@ -57,6 +57,6 @@ interface ip-name-lookup {
5757
/// - <https://man7.org/linux/man-pages/man3/getaddrinfo.3.html>
5858
/// - <https://learn.microsoft.com/en-us/windows/win32/api/ws2tcpip/nf-ws2tcpip-getaddrinfo>
5959
/// - <https://man.freebsd.org/cgi/man.cgi?query=getaddrinfo&sektion=3>
60-
@since(version = 0.3.0-rc-2025-09-16)
60+
@since(version = 0.3.0-rc-2025-08-15)
6161
resolve-addresses: async func(name: string) -> result<list<ip-address>, error-code>;
6262
}

0 commit comments

Comments
 (0)