File: resources-export.wit

package info (click to toggle)
rust-wasmtime 26.0.1%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 48,492 kB
  • sloc: ansic: 4,003; sh: 561; javascript: 542; cpp: 254; asm: 175; ml: 96; makefile: 55
file content (43 lines) | stat: -rw-r--r-- 681 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package foo:foo;

world w {
  export simple-export;
  export export-using-import;

  export export-using-export1;
  export export-using-export2;
}

interface simple-export {
  resource a {
    constructor();
    static-a: static func() -> u32;
    method-a: func() -> u32;
  }
}

interface export-using-import {
  use transitive-import.{y};
  resource a {
    constructor(y: y);
    static-a: static func() -> y;
    method-a: func(y: y) -> y;
  }
}

interface transitive-import {
  resource y;
}

interface export-using-export1 {
  resource a {
    constructor();
  }
}

interface export-using-export2 {
  use export-using-export1.{a};
  resource b {
    constructor(a: a);
  }
}