Skip to content

Commit dfc429e

Browse files
committed
chore: bump @since to 0.3.0
WebAssembly/wasi-filesystem#164 (comment) Signed-off-by: Roman Volosatovs <[email protected]>
1 parent 8cc04c8 commit dfc429e

8 files changed

+73
-73
lines changed

Diff for: wit-0.3.0-draft/instance-network.wit

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11

22
/// This interface provides a value-export of the default network handle..
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
interface instance-network {
5-
@since(version = 0.2.0)
5+
@since(version = 0.3.0
66
use network.{network};
77

88
/// Get a handle to the default network.
9-
@since(version = 0.2.0)
9+
@since(version = 0.3.0
1010
instance-network: func() -> network;
1111
}

Diff for: wit-0.3.0-draft/ip-name-lookup.wit

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface ip-name-lookup {
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
use network.{network, error-code, ip-address};
55

66
/// Resolve an internet host name to a list of IP addresses.
@@ -23,10 +23,10 @@ interface ip-name-lookup {
2323
/// - <https://man7.org/linux/man-pages/man3/getaddrinfo.3.html>
2424
/// - <https://learn.microsoft.com/en-us/windows/win32/api/ws2tcpip/nf-ws2tcpip-getaddrinfo>
2525
/// - <https://man.freebsd.org/cgi/man.cgi?query=getaddrinfo&sektion=3>
26-
@since(version = 0.2.0)
26+
@since(version = 0.3.0
2727
resolve-addresses: func(network: borrow<network>, name: string) -> result<resolve-address-stream, error-code>;
2828

29-
@since(version = 0.2.0)
29+
@since(version = 0.3.0
3030
resource resolve-address-stream {
3131
/// Returns the next address from the resolver.
3232
///
@@ -40,7 +40,7 @@ interface ip-name-lookup {
4040
/// - `name-unresolvable`: Name does not exist or has no suitable associated IP addresses. (EAI_NONAME, EAI_NODATA, EAI_ADDRFAMILY)
4141
/// - `temporary-resolver-failure`: A temporary failure in name resolution occurred. (EAI_AGAIN)
4242
/// - `permanent-resolver-failure`: A permanent failure in name resolution occurred. (EAI_FAIL)
43-
@since(version = 0.2.0)
43+
@since(version = 0.3.0
4444
resolve-next-address: func() -> result<option<ip-address>, error-code>;
4545
}
4646
}

Diff for: wit-0.3.0-draft/network.wit

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface network {
33
/// An opaque resource that represents access to (a subset of) the network.
44
/// This enables context-based security for networking.
55
/// There is no need for this to map 1:1 to a physical network interface.
6-
@since(version = 0.2.0)
6+
@since(version = 0.3.0
77
resource network;
88

99
/// Error codes.
@@ -18,7 +18,7 @@ interface network {
1818
/// - `concurrency-conflict`
1919
///
2020
/// See each individual API for what the POSIX equivalents are. They sometimes differ per API.
21-
@since(version = 0.2.0)
21+
@since(version = 0.3.0
2222
enum error-code {
2323
/// Unknown error
2424
unknown,
@@ -92,7 +92,7 @@ interface network {
9292
permanent-resolver-failure,
9393
}
9494

95-
@since(version = 0.2.0)
95+
@since(version = 0.3.0
9696
enum ip-address-family {
9797
/// Similar to `AF_INET` in POSIX.
9898
ipv4,
@@ -101,26 +101,26 @@ interface network {
101101
ipv6,
102102
}
103103

104-
@since(version = 0.2.0)
104+
@since(version = 0.3.0
105105
type ipv4-address = tuple<u8, u8, u8, u8>;
106-
@since(version = 0.2.0)
106+
@since(version = 0.3.0
107107
type ipv6-address = tuple<u16, u16, u16, u16, u16, u16, u16, u16>;
108108

109-
@since(version = 0.2.0)
109+
@since(version = 0.3.0
110110
variant ip-address {
111111
ipv4(ipv4-address),
112112
ipv6(ipv6-address),
113113
}
114114

115-
@since(version = 0.2.0)
115+
@since(version = 0.3.0
116116
record ipv4-socket-address {
117117
/// sin_port
118118
port: u16,
119119
/// sin_addr
120120
address: ipv4-address,
121121
}
122122

123-
@since(version = 0.2.0)
123+
@since(version = 0.3.0
124124
record ipv6-socket-address {
125125
/// sin6_port
126126
port: u16,
@@ -132,7 +132,7 @@ interface network {
132132
scope-id: u32,
133133
}
134134

135-
@since(version = 0.2.0)
135+
@since(version = 0.3.0
136136
variant ip-socket-address {
137137
ipv4(ipv4-socket-address),
138138
ipv6(ipv6-socket-address),

Diff for: wit-0.3.0-draft/tcp-create-socket.wit

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface tcp-create-socket {
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
use network.{network, error-code, ip-address-family};
5-
@since(version = 0.2.0)
5+
@since(version = 0.3.0
66
use tcp.{tcp-socket};
77

88
/// Create a new TCP socket.
@@ -25,6 +25,6 @@ interface tcp-create-socket {
2525
/// - <https://man7.org/linux/man-pages/man2/socket.2.html>
2626
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock2/nf-winsock2-wsasocketw>
2727
/// - <https://man.freebsd.org/cgi/man.cgi?query=socket&sektion=2>
28-
@since(version = 0.2.0)
28+
@since(version = 0.3.0
2929
create-tcp-socket: func(address-family: ip-address-family) -> result<tcp-socket, error-code>;
3030
}

Diff for: wit-0.3.0-draft/tcp.wit

+25-25
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface tcp {
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
use wasi:clocks/monotonic-clock@0.3.0.{duration};
5-
@since(version = 0.2.0)
5+
@since(version = 0.3.0
66
use network.{network, error-code, ip-socket-address, ip-address-family};
77

8-
@since(version = 0.2.0)
8+
@since(version = 0.3.0
99
enum shutdown-type {
1010
/// Similar to `SHUT_RD` in POSIX.
1111
receive,
@@ -38,7 +38,7 @@ interface tcp {
3838
/// In addition to the general error codes documented on the
3939
/// `network::error-code` type, TCP socket methods may always return
4040
/// `error(invalid-state)` when in the `closed` state.
41-
@since(version = 0.2.0)
41+
@since(version = 0.3.0
4242
resource tcp-socket {
4343
/// Bind the socket to a specific network on the provided IP address and port.
4444
///
@@ -183,7 +183,7 @@ interface tcp {
183183
/// - <https://man7.org/linux/man-pages/man2/getsockname.2.html>
184184
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock/nf-winsock-getsockname>
185185
/// - <https://man.freebsd.org/cgi/man.cgi?getsockname>
186-
@since(version = 0.2.0)
186+
@since(version = 0.3.0
187187
local-address: func() -> result<ip-socket-address, error-code>;
188188

189189
/// Get the remote address.
@@ -196,19 +196,19 @@ interface tcp {
196196
/// - <https://man7.org/linux/man-pages/man2/getpeername.2.html>
197197
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock/nf-winsock-getpeername>
198198
/// - <https://man.freebsd.org/cgi/man.cgi?query=getpeername&sektion=2&n=1>
199-
@since(version = 0.2.0)
199+
@since(version = 0.3.0
200200
remote-address: func() -> result<ip-socket-address, error-code>;
201201

202202
/// Whether the socket is in the `listening` state.
203203
///
204204
/// Equivalent to the SO_ACCEPTCONN socket option.
205-
@since(version = 0.2.0)
205+
@since(version = 0.3.0
206206
is-listening: func() -> bool;
207207

208208
/// Whether this is a IPv4 or IPv6 socket.
209209
///
210210
/// Equivalent to the SO_DOMAIN socket option.
211-
@since(version = 0.2.0)
211+
@since(version = 0.3.0
212212
address-family: func() -> ip-address-family;
213213

214214
/// Hints the desired listen queue size. Implementations are free to ignore this.
@@ -220,7 +220,7 @@ interface tcp {
220220
/// - `not-supported`: (set) The platform does not support changing the backlog size after the initial listen.
221221
/// - `invalid-argument`: (set) The provided value was 0.
222222
/// - `invalid-state`: (set) The socket is in the `connect-in-progress` or `connected` state.
223-
@since(version = 0.2.0)
223+
@since(version = 0.3.0
224224
set-listen-backlog-size: func(value: u64) -> result<_, error-code>;
225225

226226
/// Enables or disables keepalive.
@@ -232,9 +232,9 @@ interface tcp {
232232
/// These properties can be configured while `keep-alive-enabled` is false, but only come into effect when `keep-alive-enabled` is true.
233233
///
234234
/// Equivalent to the SO_KEEPALIVE socket option.
235-
@since(version = 0.2.0)
235+
@since(version = 0.3.0
236236
keep-alive-enabled: func() -> result<bool, error-code>;
237-
@since(version = 0.2.0)
237+
@since(version = 0.3.0
238238
set-keep-alive-enabled: func(value: bool) -> result<_, error-code>;
239239

240240
/// Amount of time the connection has to be idle before TCP starts sending keepalive packets.
@@ -247,9 +247,9 @@ interface tcp {
247247
///
248248
/// # Typical errors
249249
/// - `invalid-argument`: (set) The provided value was 0.
250-
@since(version = 0.2.0)
250+
@since(version = 0.3.0
251251
keep-alive-idle-time: func() -> result<duration, error-code>;
252-
@since(version = 0.2.0)
252+
@since(version = 0.3.0
253253
set-keep-alive-idle-time: func(value: duration) -> result<_, error-code>;
254254

255255
/// The time between keepalive packets.
@@ -262,9 +262,9 @@ interface tcp {
262262
///
263263
/// # Typical errors
264264
/// - `invalid-argument`: (set) The provided value was 0.
265-
@since(version = 0.2.0)
265+
@since(version = 0.3.0
266266
keep-alive-interval: func() -> result<duration, error-code>;
267-
@since(version = 0.2.0)
267+
@since(version = 0.3.0
268268
set-keep-alive-interval: func(value: duration) -> result<_, error-code>;
269269

270270
/// The maximum amount of keepalive packets TCP should send before aborting the connection.
@@ -277,9 +277,9 @@ interface tcp {
277277
///
278278
/// # Typical errors
279279
/// - `invalid-argument`: (set) The provided value was 0.
280-
@since(version = 0.2.0)
280+
@since(version = 0.3.0
281281
keep-alive-count: func() -> result<u32, error-code>;
282-
@since(version = 0.2.0)
282+
@since(version = 0.3.0
283283
set-keep-alive-count: func(value: u32) -> result<_, error-code>;
284284

285285
/// Equivalent to the IP_TTL & IPV6_UNICAST_HOPS socket options.
@@ -288,9 +288,9 @@ interface tcp {
288288
///
289289
/// # Typical errors
290290
/// - `invalid-argument`: (set) The TTL value must be 1 or higher.
291-
@since(version = 0.2.0)
291+
@since(version = 0.3.0
292292
hop-limit: func() -> result<u8, error-code>;
293-
@since(version = 0.2.0)
293+
@since(version = 0.3.0
294294
set-hop-limit: func(value: u8) -> result<_, error-code>;
295295

296296
/// The kernel buffer space reserved for sends/receives on this socket.
@@ -303,13 +303,13 @@ interface tcp {
303303
///
304304
/// # Typical errors
305305
/// - `invalid-argument`: (set) The provided value was 0.
306-
@since(version = 0.2.0)
306+
@since(version = 0.3.0
307307
receive-buffer-size: func() -> result<u64, error-code>;
308-
@since(version = 0.2.0)
308+
@since(version = 0.3.0
309309
set-receive-buffer-size: func(value: u64) -> result<_, error-code>;
310-
@since(version = 0.2.0)
310+
@since(version = 0.3.0
311311
send-buffer-size: func() -> result<u64, error-code>;
312-
@since(version = 0.2.0)
312+
@since(version = 0.3.0
313313
set-send-buffer-size: func(value: u64) -> result<_, error-code>;
314314

315315
/// Initiate a graceful shutdown.
@@ -335,7 +335,7 @@ interface tcp {
335335
/// - <https://man7.org/linux/man-pages/man2/shutdown.2.html>
336336
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock/nf-winsock-shutdown>
337337
/// - <https://man.freebsd.org/cgi/man.cgi?query=shutdown&sektion=2>
338-
@since(version = 0.2.0)
338+
@since(version = 0.3.0
339339
shutdown: func(shutdown-type: shutdown-type) -> result<_, error-code>;
340340
}
341341
}

Diff for: wit-0.3.0-draft/udp-create-socket.wit

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface udp-create-socket {
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
use network.{network, error-code, ip-address-family};
5-
@since(version = 0.2.0)
5+
@since(version = 0.3.0
66
use udp.{udp-socket};
77

88
/// Create a new UDP socket.
@@ -25,6 +25,6 @@ interface udp-create-socket {
2525
/// - <https://man7.org/linux/man-pages/man2/socket.2.html>
2626
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock2/nf-winsock2-wsasocketw>
2727
/// - <https://man.freebsd.org/cgi/man.cgi?query=socket&sektion=2>
28-
@since(version = 0.2.0)
28+
@since(version = 0.3.0
2929
create-udp-socket: func(address-family: ip-address-family) -> result<udp-socket, error-code>;
3030
}

Diff for: wit-0.3.0-draft/udp.wit

+14-14
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
@since(version = 0.2.0)
1+
@since(version = 0.3.0
22
interface udp {
3-
@since(version = 0.2.0)
3+
@since(version = 0.3.0
44
use network.{network, error-code, ip-socket-address, ip-address-family};
55

66
/// A received datagram.
7-
@since(version = 0.2.0)
7+
@since(version = 0.3.0
88
record incoming-datagram {
99
/// The payload.
1010
///
@@ -20,7 +20,7 @@ interface udp {
2020
}
2121

2222
/// A datagram to be sent out.
23-
@since(version = 0.2.0)
23+
@since(version = 0.3.0
2424
record outgoing-datagram {
2525
/// The payload.
2626
data: list<u8>,
@@ -36,7 +36,7 @@ interface udp {
3636
}
3737

3838
/// A UDP socket handle.
39-
@since(version = 0.2.0)
39+
@since(version = 0.3.0
4040
resource udp-socket {
4141
/// Bind the socket to a specific network on the provided IP address and port.
4242
///
@@ -153,7 +153,7 @@ interface udp {
153153
/// - <https://man7.org/linux/man-pages/man2/getsockname.2.html>
154154
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock/nf-winsock-getsockname>
155155
/// - <https://man.freebsd.org/cgi/man.cgi?getsockname>
156-
@since(version = 0.2.0)
156+
@since(version = 0.3.0
157157
local-address: func() -> result<ip-socket-address, error-code>;
158158

159159
/// Get the address the socket is currently streaming to.
@@ -166,13 +166,13 @@ interface udp {
166166
/// - <https://man7.org/linux/man-pages/man2/getpeername.2.html>
167167
/// - <https://learn.microsoft.com/en-us/windows/win32/api/winsock/nf-winsock-getpeername>
168168
/// - <https://man.freebsd.org/cgi/man.cgi?query=getpeername&sektion=2&n=1>
169-
@since(version = 0.2.0)
169+
@since(version = 0.3.0
170170
remote-address: func() -> result<ip-socket-address, error-code>;
171171

172172
/// Whether this is a IPv4 or IPv6 socket.
173173
///
174174
/// Equivalent to the SO_DOMAIN socket option.
175-
@since(version = 0.2.0)
175+
@since(version = 0.3.0
176176
address-family: func() -> ip-address-family;
177177

178178
/// Equivalent to the IP_TTL & IPV6_UNICAST_HOPS socket options.
@@ -181,9 +181,9 @@ interface udp {
181181
///
182182
/// # Typical errors
183183
/// - `invalid-argument`: (set) The TTL value must be 1 or higher.
184-
@since(version = 0.2.0)
184+
@since(version = 0.3.0
185185
unicast-hop-limit: func() -> result<u8, error-code>;
186-
@since(version = 0.2.0)
186+
@since(version = 0.3.0
187187
set-unicast-hop-limit: func(value: u8) -> result<_, error-code>;
188188

189189
/// The kernel buffer space reserved for sends/receives on this socket.
@@ -196,13 +196,13 @@ interface udp {
196196
///
197197
/// # Typical errors
198198
/// - `invalid-argument`: (set) The provided value was 0.
199-
@since(version = 0.2.0)
199+
@since(version = 0.3.0
200200
receive-buffer-size: func() -> result<u64, error-code>;
201-
@since(version = 0.2.0)
201+
@since(version = 0.3.0
202202
set-receive-buffer-size: func(value: u64) -> result<_, error-code>;
203-
@since(version = 0.2.0)
203+
@since(version = 0.3.0
204204
send-buffer-size: func() -> result<u64, error-code>;
205-
@since(version = 0.2.0)
205+
@since(version = 0.3.0
206206
set-send-buffer-size: func(value: u64) -> result<_, error-code>;
207207
}
208208
}

0 commit comments

Comments
 (0)