blob: db722bd1386c289e6a66a4e82901695700ab7a42 (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
const { core } = Deno[Deno.internal];
const opPromise = core.read(Deno.stdin.rid, new Uint8Array(10));
core.unrefOpPromise(opPromise);
async function main() {
console.log(1);
await opPromise;
console.log(2);
}
main();
|