wit-bindgen-cli 0.61.0

CLI tool to generate bindings for WIT documents and the component model.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//@ [lang]
//@ path = 'gen/interface/my/test/i/stub.mbt'

///|
pub async fn read_future(
  x : @async-core.Future[Unit],
  _background_group : @async-core.TaskGroup[Unit],
) -> Unit {
  let _ = x.get() catch { _ => () }
}

///|
pub async fn drop_future(
  x : @async-core.Future[Unit],
  _background_group : @async-core.TaskGroup[Unit],
) -> Unit {
  x.drop()
}