@bytecodealliance/preview2-shim 0.0.19 → 0.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +220 -0
- package/README.md +4 -6
- package/lib/browser/cli.js +79 -12
- package/lib/browser/filesystem.js +168 -198
- package/lib/browser/index.js +1 -5
- package/lib/browser/io.js +173 -29
- package/lib/common/io.js +6 -4
- package/lib/{http → common}/make-request.js +1 -1
- package/lib/nodejs/cli.js +5 -4
- package/lib/nodejs/filesystem.js +106 -73
- package/lib/nodejs/http.js +309 -3
- package/lib/nodejs/index.js +0 -5
- package/package.json +1 -1
- package/types/interfaces/wasi-cli-stderr.d.ts +1 -1
- package/types/interfaces/wasi-cli-stdin.d.ts +1 -1
- package/types/interfaces/wasi-cli-stdout.d.ts +1 -1
- package/types/interfaces/wasi-cli-terminal-stderr.d.ts +1 -1
- package/types/interfaces/wasi-cli-terminal-stdin.d.ts +1 -1
- package/types/interfaces/wasi-cli-terminal-stdout.d.ts +1 -1
- package/types/interfaces/wasi-clocks-monotonic-clock.d.ts +1 -1
- package/types/interfaces/wasi-clocks-timezone.d.ts +1 -1
- package/types/interfaces/wasi-filesystem-preopens.d.ts +1 -1
- package/types/interfaces/wasi-filesystem-types.d.ts +8 -8
- package/types/interfaces/wasi-http-incoming-handler.d.ts +19 -0
- package/types/interfaces/wasi-http-outgoing-handler.d.ts +23 -0
- package/types/interfaces/wasi-http-types.d.ts +371 -0
- package/types/interfaces/wasi-io-streams.d.ts +13 -21
- package/types/interfaces/wasi-sockets-instance-network.d.ts +1 -1
- package/types/interfaces/wasi-sockets-ip-name-lookup.d.ts +5 -5
- package/types/interfaces/wasi-sockets-tcp-create-socket.d.ts +4 -4
- package/types/interfaces/wasi-sockets-tcp.d.ts +7 -7
- package/types/interfaces/wasi-sockets-udp-create-socket.d.ts +4 -4
- package/types/interfaces/wasi-sockets-udp.d.ts +5 -5
- package/types/wasi-cli-command.d.ts +3 -3
- package/types/wasi-http-proxy.d.ts +13 -0
- package/lib/browser/poll.js +0 -53
- package/lib/http/wasi-http.js +0 -382
- package/lib/nodejs/poll.js +0 -9
- /package/lib/{http/synckit → synckit}/index.d.ts +0 -0
- /package/lib/{http/synckit → synckit}/index.js +0 -0
|
@@ -1,15 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { streams } from './io.js';
|
|
2
2
|
import { environment } from './cli.js';
|
|
3
3
|
|
|
4
|
-
const {
|
|
5
|
-
|
|
6
|
-
let _preopens = [[3, '/']], _rootPreopen = _preopens[0];
|
|
7
|
-
|
|
8
|
-
export function _setPreopens (preopens) {
|
|
9
|
-
_preopens = preopens;
|
|
10
|
-
descriptorCnt = 3 + _preopens.length;
|
|
11
|
-
_rootPreopen = _preopens.find(preopen => preopen[1] === '/');
|
|
12
|
-
}
|
|
4
|
+
const { InputStream, OutputStream } = streams;
|
|
13
5
|
|
|
14
6
|
let _cwd = null;
|
|
15
7
|
|
|
@@ -19,11 +11,7 @@ export function _setCwd (cwd) {
|
|
|
19
11
|
|
|
20
12
|
export function _setFileData (fileData) {
|
|
21
13
|
_fileData = fileData;
|
|
22
|
-
|
|
23
|
-
const fd = descriptorCnt++;
|
|
24
|
-
descriptorTable[fd] = { entry: fileData[key] };
|
|
25
|
-
return [fd, key];
|
|
26
|
-
}));
|
|
14
|
+
_rootPreopen[0] = new Descriptor(fileData);
|
|
27
15
|
const cwd = environment.initialCwd();
|
|
28
16
|
_setCwd(cwd || '/');
|
|
29
17
|
}
|
|
@@ -32,34 +20,20 @@ export function _getFileData () {
|
|
|
32
20
|
return JSON.stringify(_fileData);
|
|
33
21
|
}
|
|
34
22
|
|
|
35
|
-
let _fileData = {};
|
|
36
|
-
|
|
37
|
-
let descriptorCnt = 4;
|
|
38
|
-
const descriptorTable = {
|
|
39
|
-
0: { stream: 0 },
|
|
40
|
-
1: { stream: 1 },
|
|
41
|
-
2: { stream: 2 },
|
|
42
|
-
3: { entry: { dir: {} } },
|
|
43
|
-
};
|
|
23
|
+
let _fileData = { dir: {} };
|
|
44
24
|
|
|
45
25
|
const timeZero = {
|
|
46
26
|
seconds: BigInt(0),
|
|
47
27
|
nanoseconds: 0
|
|
48
28
|
};
|
|
49
29
|
|
|
50
|
-
function
|
|
51
|
-
|
|
52
|
-
if (!descriptor) throw 'bad-descriptor';
|
|
53
|
-
return descriptor;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
function getChildEntry (fd, subpath, openFlags) {
|
|
57
|
-
if (subpath === '.' && _rootPreopen && _rootPreopen[0] === fd) {
|
|
30
|
+
function getChildEntry (parentEntry, subpath, openFlags) {
|
|
31
|
+
if (subpath === '.' && _rootPreopen && descriptorGetEntry(_rootPreopen[0]) === parentEntry) {
|
|
58
32
|
subpath = _cwd;
|
|
59
|
-
if (subpath.startsWith('/'))
|
|
33
|
+
if (subpath.startsWith('/') && subpath !== '/')
|
|
60
34
|
subpath = subpath.slice(1);
|
|
61
35
|
}
|
|
62
|
-
let entry =
|
|
36
|
+
let entry = parentEntry;
|
|
63
37
|
let segmentIdx;
|
|
64
38
|
do {
|
|
65
39
|
if (!entry || !entry.dir) throw 'not-directory';
|
|
@@ -76,13 +50,6 @@ function getChildEntry (fd, subpath, openFlags) {
|
|
|
76
50
|
return entry;
|
|
77
51
|
}
|
|
78
52
|
|
|
79
|
-
function createChildDescriptor (fd, subpath, openFlags) {
|
|
80
|
-
const entry = getChildEntry(fd, subpath, openFlags);
|
|
81
|
-
const childFd = descriptorCnt++;
|
|
82
|
-
descriptorTable[childFd] = { entry };
|
|
83
|
-
return childFd;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
53
|
function getSource (fileEntry) {
|
|
87
54
|
if (typeof fileEntry.source === 'string') {
|
|
88
55
|
fileEntry.source = new TextEncoder().encode(fileEntry.source);
|
|
@@ -90,12 +57,12 @@ function getSource (fileEntry) {
|
|
|
90
57
|
return fileEntry.source;
|
|
91
58
|
}
|
|
92
59
|
|
|
93
|
-
class
|
|
60
|
+
class DirectoryEntryStream {
|
|
94
61
|
constructor (entries) {
|
|
95
62
|
this.idx = 0;
|
|
96
63
|
this.entries = entries;
|
|
97
64
|
}
|
|
98
|
-
|
|
65
|
+
readDirectoryEntry () {
|
|
99
66
|
if (this.idx === this.entries.length)
|
|
100
67
|
return null;
|
|
101
68
|
const [name, entry] = this.entries[this.idx];
|
|
@@ -107,117 +74,120 @@ class DirStream {
|
|
|
107
74
|
}
|
|
108
75
|
}
|
|
109
76
|
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
77
|
+
class Descriptor {
|
|
78
|
+
#stream;
|
|
79
|
+
#entry;
|
|
80
|
+
#mtime = 0;
|
|
81
|
+
|
|
82
|
+
_getEntry (descriptor) {
|
|
83
|
+
return descriptor.#entry;
|
|
113
84
|
}
|
|
114
|
-
}
|
|
115
85
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
86
|
+
constructor (entry, isStream) {
|
|
87
|
+
if (isStream)
|
|
88
|
+
this.#stream = entry;
|
|
89
|
+
else
|
|
90
|
+
this.#entry = entry;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
readViaStream(_offset) {
|
|
94
|
+
const source = getSource(this.#entry);
|
|
95
|
+
let offset = Number(_offset);
|
|
96
|
+
return new InputStream({
|
|
97
|
+
blockingRead (len) {
|
|
98
|
+
if (offset === source.byteLength)
|
|
99
|
+
throw { tag: 'closed' };
|
|
100
|
+
const bytes = source.slice(offset, offset + Number(len));
|
|
101
|
+
offset += bytes.byteLength;
|
|
102
|
+
return bytes;
|
|
127
103
|
}
|
|
128
104
|
});
|
|
129
|
-
}
|
|
105
|
+
}
|
|
130
106
|
|
|
131
|
-
writeViaStream(
|
|
132
|
-
const
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
entry: descriptor.entry,
|
|
107
|
+
writeViaStream(_offset) {
|
|
108
|
+
const entry = this.#entry;
|
|
109
|
+
let offset = Number(_offset);
|
|
110
|
+
return new OutputStream({
|
|
136
111
|
write (buf) {
|
|
137
|
-
const newSource = new Uint8Array(buf.byteLength +
|
|
138
|
-
newSource.set(
|
|
139
|
-
newSource.set(buf,
|
|
140
|
-
|
|
141
|
-
|
|
112
|
+
const newSource = new Uint8Array(buf.byteLength + entry.source.byteLength);
|
|
113
|
+
newSource.set(entry.source, 0);
|
|
114
|
+
newSource.set(buf, offset);
|
|
115
|
+
offset += buf.byteLength;
|
|
116
|
+
entry.source = newSource;
|
|
142
117
|
return buf.byteLength;
|
|
143
118
|
}
|
|
144
119
|
});
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
appendViaStream(
|
|
148
|
-
console.log(`[filesystem] APPEND STREAM
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
advise(
|
|
152
|
-
console.log(`[filesystem] ADVISE`,
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
syncData(
|
|
156
|
-
console.log(`[filesystem] SYNC DATA
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
getFlags(
|
|
160
|
-
console.log(`[filesystem] FLAGS FOR
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
getType(
|
|
164
|
-
if (
|
|
165
|
-
|
|
166
|
-
if (
|
|
167
|
-
if (descriptor.entry.dir) return 'directory';
|
|
168
|
-
if (descriptor.entry.source) return 'regular-file';
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
appendViaStream() {
|
|
123
|
+
console.log(`[filesystem] APPEND STREAM`);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
advise(descriptor, offset, length, advice) {
|
|
127
|
+
console.log(`[filesystem] ADVISE`, descriptor, offset, length, advice);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
syncData() {
|
|
131
|
+
console.log(`[filesystem] SYNC DATA`);
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
getFlags() {
|
|
135
|
+
console.log(`[filesystem] FLAGS FOR`);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
getType() {
|
|
139
|
+
if (this.#stream) return 'fifo';
|
|
140
|
+
if (this.#entry.dir) return 'directory';
|
|
141
|
+
if (this.#entry.source) return 'regular-file';
|
|
169
142
|
return 'unknown';
|
|
170
|
-
}
|
|
143
|
+
}
|
|
171
144
|
|
|
172
|
-
setFlags(
|
|
173
|
-
console.log(`[filesystem] SET FLAGS ${
|
|
174
|
-
}
|
|
145
|
+
setFlags(flags) {
|
|
146
|
+
console.log(`[filesystem] SET FLAGS ${JSON.stringify(flags)}`);
|
|
147
|
+
}
|
|
175
148
|
|
|
176
|
-
setSize(
|
|
177
|
-
console.log(`[filesystem] SET SIZE`,
|
|
178
|
-
}
|
|
149
|
+
setSize(size) {
|
|
150
|
+
console.log(`[filesystem] SET SIZE`, size);
|
|
151
|
+
}
|
|
179
152
|
|
|
180
|
-
setTimes(
|
|
181
|
-
console.log(`[filesystem] SET TIMES`,
|
|
182
|
-
}
|
|
153
|
+
setTimes(dataAccessTimestamp, dataModificationTimestamp) {
|
|
154
|
+
console.log(`[filesystem] SET TIMES`, dataAccessTimestamp, dataModificationTimestamp);
|
|
155
|
+
}
|
|
183
156
|
|
|
184
|
-
read(
|
|
185
|
-
const
|
|
186
|
-
const source = getSource(descriptor.entry);
|
|
157
|
+
read(length, offset) {
|
|
158
|
+
const source = getSource(this.#entry);
|
|
187
159
|
return [source.slice(offset, offset + length), offset + length >= source.byteLength];
|
|
188
|
-
}
|
|
160
|
+
}
|
|
189
161
|
|
|
190
|
-
write(
|
|
191
|
-
const descriptor = getDescriptor(fd);
|
|
162
|
+
write(buffer, offset) {
|
|
192
163
|
if (offset !== 0) throw 'invalid-seek';
|
|
193
|
-
|
|
164
|
+
this.#entry.source = buffer;
|
|
194
165
|
return buffer.byteLength;
|
|
195
|
-
}
|
|
166
|
+
}
|
|
196
167
|
|
|
197
|
-
readDirectory(
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
return
|
|
201
|
-
}
|
|
168
|
+
readDirectory() {
|
|
169
|
+
if (!this.#entry?.dir)
|
|
170
|
+
throw 'bad-descriptor';
|
|
171
|
+
return new DirectoryEntryStream(Object.entries(this.#entry.dir).sort(([a], [b]) => a > b ? 1 : -1));
|
|
172
|
+
}
|
|
202
173
|
|
|
203
|
-
sync(
|
|
204
|
-
console.log(`[filesystem] SYNC
|
|
205
|
-
}
|
|
174
|
+
sync() {
|
|
175
|
+
console.log(`[filesystem] SYNC`);
|
|
176
|
+
}
|
|
206
177
|
|
|
207
|
-
createDirectoryAt(
|
|
208
|
-
const entry = getChildEntry(
|
|
178
|
+
createDirectoryAt(path) {
|
|
179
|
+
const entry = getChildEntry(this.#entry, path, { create: true, directory: true });
|
|
209
180
|
if (entry.source) throw 'exist';
|
|
210
|
-
}
|
|
181
|
+
}
|
|
211
182
|
|
|
212
|
-
stat(
|
|
213
|
-
const descriptor = getDescriptor(fd);
|
|
183
|
+
stat() {
|
|
214
184
|
let type = 'unknown', size = BigInt(0);
|
|
215
|
-
if (
|
|
185
|
+
if (this.#entry.source) {
|
|
216
186
|
type = 'directory';
|
|
217
187
|
}
|
|
218
|
-
else if (
|
|
188
|
+
else if (this.#entry.dir) {
|
|
219
189
|
type = 'regular-file';
|
|
220
|
-
const source = getSource(
|
|
190
|
+
const source = getSource(this.#entry);
|
|
221
191
|
size = BigInt(source.byteLength);
|
|
222
192
|
}
|
|
223
193
|
return {
|
|
@@ -228,10 +198,10 @@ export const types = {
|
|
|
228
198
|
dataModificationTimestamp: timeZero,
|
|
229
199
|
statusChangeTimestamp: timeZero,
|
|
230
200
|
}
|
|
231
|
-
}
|
|
201
|
+
}
|
|
232
202
|
|
|
233
|
-
statAt(
|
|
234
|
-
const entry = getChildEntry(
|
|
203
|
+
statAt(_pathFlags, path) {
|
|
204
|
+
const entry = getChildEntry(this.#entry, path);
|
|
235
205
|
let type = 'unknown', size = BigInt(0);
|
|
236
206
|
if (entry.source) {
|
|
237
207
|
type = 'regular-file';
|
|
@@ -249,95 +219,95 @@ export const types = {
|
|
|
249
219
|
dataModificationTimestamp: timeZero,
|
|
250
220
|
statusChangeTimestamp: timeZero,
|
|
251
221
|
};
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
setTimesAt(fd) {
|
|
255
|
-
console.log(`[filesystem] SET TIMES AT`, fd);
|
|
256
|
-
},
|
|
257
|
-
|
|
258
|
-
linkAt(fd) {
|
|
259
|
-
console.log(`[filesystem] LINK AT`, fd);
|
|
260
|
-
},
|
|
261
|
-
|
|
262
|
-
openAt(fd, _pathFlags, path, openFlags, _descriptorFlags, _modes) {
|
|
263
|
-
return createChildDescriptor(fd, path, openFlags);
|
|
264
|
-
},
|
|
222
|
+
}
|
|
265
223
|
|
|
266
|
-
|
|
267
|
-
console.log(`[filesystem]
|
|
268
|
-
}
|
|
224
|
+
setTimesAt() {
|
|
225
|
+
console.log(`[filesystem] SET TIMES AT`);
|
|
226
|
+
}
|
|
269
227
|
|
|
270
|
-
|
|
271
|
-
console.log(`[filesystem]
|
|
272
|
-
}
|
|
228
|
+
linkAt() {
|
|
229
|
+
console.log(`[filesystem] LINK AT`);
|
|
230
|
+
}
|
|
273
231
|
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
232
|
+
openAt(_pathFlags, path, openFlags, _descriptorFlags, _modes) {
|
|
233
|
+
const childEntry = getChildEntry(this.#entry, path, openFlags);
|
|
234
|
+
return new Descriptor(childEntry);
|
|
235
|
+
}
|
|
277
236
|
|
|
278
|
-
|
|
279
|
-
console.log(`[filesystem]
|
|
280
|
-
}
|
|
237
|
+
readlinkAt() {
|
|
238
|
+
console.log(`[filesystem] READLINK AT`);
|
|
239
|
+
}
|
|
281
240
|
|
|
282
|
-
|
|
283
|
-
console.log(`[filesystem]
|
|
284
|
-
}
|
|
241
|
+
removeDirectoryAt() {
|
|
242
|
+
console.log(`[filesystem] REMOVE DIR AT`);
|
|
243
|
+
}
|
|
285
244
|
|
|
286
|
-
|
|
287
|
-
console.log(`[filesystem]
|
|
288
|
-
}
|
|
245
|
+
renameAt() {
|
|
246
|
+
console.log(`[filesystem] RENAME AT`);
|
|
247
|
+
}
|
|
289
248
|
|
|
290
|
-
|
|
291
|
-
console.log(`[filesystem]
|
|
292
|
-
}
|
|
249
|
+
symlinkAt() {
|
|
250
|
+
console.log(`[filesystem] SYMLINK AT`);
|
|
251
|
+
}
|
|
293
252
|
|
|
294
|
-
|
|
295
|
-
console.log(`[filesystem]
|
|
296
|
-
}
|
|
253
|
+
unlinkFileAt() {
|
|
254
|
+
console.log(`[filesystem] UNLINK FILE AT`);
|
|
255
|
+
}
|
|
297
256
|
|
|
298
|
-
|
|
299
|
-
console.log(`[filesystem]
|
|
300
|
-
}
|
|
257
|
+
changeFilePermissionsAt() {
|
|
258
|
+
console.log(`[filesystem] CHANGE FILE PERMISSIONS AT`);
|
|
259
|
+
}
|
|
301
260
|
|
|
302
|
-
|
|
303
|
-
console.log(`[filesystem]
|
|
304
|
-
}
|
|
261
|
+
changeDirectoryPermissionsAt() {
|
|
262
|
+
console.log(`[filesystem] CHANGE DIR PERMISSIONS AT`);
|
|
263
|
+
}
|
|
305
264
|
|
|
306
|
-
|
|
307
|
-
console.log(`[filesystem]
|
|
308
|
-
}
|
|
265
|
+
lockShared() {
|
|
266
|
+
console.log(`[filesystem] LOCK SHARED`);
|
|
267
|
+
}
|
|
309
268
|
|
|
310
|
-
|
|
311
|
-
console.log(`[filesystem]
|
|
312
|
-
}
|
|
269
|
+
lockExclusive() {
|
|
270
|
+
console.log(`[filesystem] LOCK EXCLUSIVE`);
|
|
271
|
+
}
|
|
313
272
|
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
delete descriptorTable[fd];
|
|
318
|
-
},
|
|
273
|
+
tryLockShared() {
|
|
274
|
+
console.log(`[filesystem] TRY LOCK SHARED`);
|
|
275
|
+
}
|
|
319
276
|
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
}
|
|
277
|
+
tryLockExclusive() {
|
|
278
|
+
console.log(`[filesystem] TRY LOCK EXCLUSIVE`);
|
|
279
|
+
}
|
|
323
280
|
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
}
|
|
281
|
+
unlock() {
|
|
282
|
+
console.log(`[filesystem] UNLOCK`);
|
|
283
|
+
}
|
|
327
284
|
|
|
328
|
-
metadataHash(
|
|
329
|
-
const descriptor = getDescriptor(fd);
|
|
285
|
+
metadataHash() {
|
|
330
286
|
let upper = BigInt(0);
|
|
331
|
-
upper += BigInt(
|
|
287
|
+
upper += BigInt(this.#mtime);
|
|
332
288
|
return { upper, lower: BigInt(0) };
|
|
333
|
-
}
|
|
289
|
+
}
|
|
334
290
|
|
|
335
|
-
metadataHashAt(
|
|
336
|
-
const descriptor = getDescriptor(fd);
|
|
291
|
+
metadataHashAt(_pathFlags, _path) {
|
|
337
292
|
let upper = BigInt(0);
|
|
338
|
-
upper += BigInt(
|
|
293
|
+
upper += BigInt(this.#mtime);
|
|
339
294
|
return { upper, lower: BigInt(0) };
|
|
340
295
|
}
|
|
296
|
+
}
|
|
297
|
+
const descriptorGetEntry = Descriptor.prototype._getEntry;
|
|
298
|
+
delete Descriptor.prototype._getEntry;
|
|
299
|
+
|
|
300
|
+
let _preopens = [[new Descriptor(_fileData), '/']], _rootPreopen = _preopens[0];
|
|
301
|
+
|
|
302
|
+
export const preopens = {
|
|
303
|
+
getDirectories () {
|
|
304
|
+
return _preopens;
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
export const types = {
|
|
309
|
+
Descriptor,
|
|
310
|
+
DirectoryEntryStream
|
|
341
311
|
};
|
|
342
312
|
|
|
343
|
-
export { types as filesystemTypes }
|
|
313
|
+
export { types as filesystemTypes }
|
package/lib/browser/index.js
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import * as clocks from "./clocks.js";
|
|
2
2
|
import * as filesystem from "./filesystem.js";
|
|
3
3
|
import * as http from "./http.js";
|
|
4
|
-
import * as io from "
|
|
5
|
-
import * as poll from "./poll.js";
|
|
4
|
+
import * as io from "./io.js";
|
|
6
5
|
import * as random from "./random.js";
|
|
7
6
|
import * as sockets from "./sockets.js";
|
|
8
7
|
import * as cli from "./cli.js";
|
|
@@ -12,10 +11,7 @@ export {
|
|
|
12
11
|
filesystem,
|
|
13
12
|
http,
|
|
14
13
|
io,
|
|
15
|
-
poll,
|
|
16
14
|
random,
|
|
17
15
|
sockets,
|
|
18
16
|
cli,
|
|
19
17
|
}
|
|
20
|
-
|
|
21
|
-
export { WasiHttp } from "../http/wasi-http.js";
|