@tombi-toml/wasm-lsp 1.5.1 → 1.5.3

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/dist/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "ya7010 <ya7010@outlook.com>"
6
6
  ],
7
7
  "description": "Tombi formatter, linter, and language server for WebAssembly",
8
- "version": "1.5.1",
8
+ "version": "1.5.3",
9
9
  "license": "MIT",
10
10
  "repository": {
11
11
  "type": "git",
@@ -1,115 +1,132 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
- export function start(): void;
4
- /**
5
- * Update one file in the browser-backed virtual workspace.
6
- */
7
- export function set_workspace_file(uri: string, text: string): void;
8
- /**
9
- * Remove one file from the browser-backed virtual workspace.
10
- */
11
- export function remove_workspace_file(uri: string): void;
12
- /**
13
- * Replace the virtual workspace files visible to the WASM language server.
14
- */
15
- export function set_workspace_files(files: any): void;
16
- /**
17
- * Replace the virtual workspace entries visible to the WASM language server.
18
- */
19
- export function set_workspace_entries(entries: any): void;
20
- /**
21
- * Serve Tombi LSP over byte streams using the standard LSP header framing.
22
- */
23
- export function serve(config: ServerConfig): Promise<void>;
24
3
  /**
25
4
  * The `ReadableStreamType` enum.
26
5
  *
27
6
  * *This API requires the following crate features to be activated: `ReadableStreamType`*
28
7
  */
29
- type ReadableStreamType = "bytes";
8
+
9
+ export type ReadableStreamType = "bytes";
10
+
30
11
  export class IntoUnderlyingByteSource {
31
- private constructor();
32
- free(): void;
33
- pull(controller: ReadableByteStreamController): Promise<any>;
34
- start(controller: ReadableByteStreamController): void;
35
- cancel(): void;
36
- readonly autoAllocateChunkSize: number;
37
- readonly type: ReadableStreamType;
12
+ private constructor();
13
+ free(): void;
14
+ [Symbol.dispose](): void;
15
+ cancel(): void;
16
+ pull(controller: ReadableByteStreamController): Promise<any>;
17
+ start(controller: ReadableByteStreamController): void;
18
+ readonly autoAllocateChunkSize: number;
19
+ readonly type: ReadableStreamType;
38
20
  }
21
+
39
22
  export class IntoUnderlyingSink {
40
- private constructor();
41
- free(): void;
42
- abort(reason: any): Promise<any>;
43
- close(): Promise<any>;
44
- write(chunk: any): Promise<any>;
23
+ private constructor();
24
+ free(): void;
25
+ [Symbol.dispose](): void;
26
+ abort(reason: any): Promise<any>;
27
+ close(): Promise<any>;
28
+ write(chunk: any): Promise<any>;
45
29
  }
30
+
46
31
  export class IntoUnderlyingSource {
47
- private constructor();
48
- free(): void;
49
- pull(controller: ReadableStreamDefaultController): Promise<any>;
50
- cancel(): void;
32
+ private constructor();
33
+ free(): void;
34
+ [Symbol.dispose](): void;
35
+ cancel(): void;
36
+ pull(controller: ReadableStreamDefaultController): Promise<any>;
51
37
  }
38
+
52
39
  /**
53
40
  * Browser streams used to exchange LSP messages with a Web Worker.
54
41
  */
55
42
  export class ServerConfig {
56
- free(): void;
57
- constructor(into_server: AsyncIterator<any>, from_server: WritableStream);
43
+ free(): void;
44
+ [Symbol.dispose](): void;
45
+ constructor(into_server: AsyncIterator<any>, from_server: WritableStream);
58
46
  }
59
47
 
48
+ /**
49
+ * Remove one file from the browser-backed virtual workspace.
50
+ */
51
+ export function remove_workspace_file(uri: string): void;
52
+
53
+ /**
54
+ * Serve Tombi LSP over byte streams using the standard LSP header framing.
55
+ */
56
+ export function serve(config: ServerConfig): Promise<void>;
57
+
58
+ /**
59
+ * Replace the virtual workspace entries visible to the WASM language server.
60
+ */
61
+ export function set_workspace_entries(entries: any): void;
62
+
63
+ /**
64
+ * Update one file in the browser-backed virtual workspace.
65
+ */
66
+ export function set_workspace_file(uri: string, text: string): void;
67
+
68
+ /**
69
+ * Replace the virtual workspace files visible to the WASM language server.
70
+ */
71
+ export function set_workspace_files(files: any): void;
72
+
73
+ export function start(): void;
74
+
60
75
  export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
61
76
 
62
77
  export interface InitOutput {
63
- readonly memory: WebAssembly.Memory;
64
- readonly __wbg_serverconfig_free: (a: number, b: number) => void;
65
- readonly remove_workspace_file: (a: number, b: number, c: number) => void;
66
- readonly serve: (a: number) => number;
67
- readonly set_workspace_entries: (a: number, b: number) => void;
68
- readonly set_workspace_file: (a: number, b: number, c: number, d: number, e: number) => void;
69
- readonly start: () => void;
70
- readonly set_workspace_files: (a: number, b: number) => void;
71
- readonly serverconfig_new: (a: number, b: number) => number;
72
- readonly __wbg_intounderlyingbytesource_free: (a: number, b: number) => void;
73
- readonly intounderlyingbytesource_autoAllocateChunkSize: (a: number) => number;
74
- readonly intounderlyingbytesource_cancel: (a: number) => void;
75
- readonly intounderlyingbytesource_pull: (a: number, b: number) => number;
76
- readonly intounderlyingbytesource_start: (a: number, b: number) => void;
77
- readonly intounderlyingbytesource_type: (a: number) => number;
78
- readonly __wbg_intounderlyingsink_free: (a: number, b: number) => void;
79
- readonly __wbg_intounderlyingsource_free: (a: number, b: number) => void;
80
- readonly intounderlyingsink_abort: (a: number, b: number) => number;
81
- readonly intounderlyingsink_close: (a: number) => number;
82
- readonly intounderlyingsink_write: (a: number, b: number) => number;
83
- readonly intounderlyingsource_cancel: (a: number) => void;
84
- readonly intounderlyingsource_pull: (a: number, b: number) => number;
85
- readonly __wbindgen_export_0: (a: number) => void;
86
- readonly __wbindgen_export_1: (a: number, b: number, c: number) => void;
87
- readonly __wbindgen_export_2: (a: number, b: number) => number;
88
- readonly __wbindgen_export_3: (a: number, b: number, c: number, d: number) => number;
89
- readonly __wbindgen_export_4: WebAssembly.Table;
90
- readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
91
- readonly __wbindgen_export_5: (a: number, b: number, c: number) => void;
92
- readonly __wbindgen_export_6: (a: number, b: number, c: number, d: number) => void;
93
- readonly __wbindgen_start: () => void;
78
+ readonly memory: WebAssembly.Memory;
79
+ readonly __wbg_intounderlyingbytesource_free: (a: number, b: number) => void;
80
+ readonly __wbg_intounderlyingsink_free: (a: number, b: number) => void;
81
+ readonly __wbg_intounderlyingsource_free: (a: number, b: number) => void;
82
+ readonly __wbg_serverconfig_free: (a: number, b: number) => void;
83
+ readonly intounderlyingbytesource_autoAllocateChunkSize: (a: number) => number;
84
+ readonly intounderlyingbytesource_cancel: (a: number) => void;
85
+ readonly intounderlyingbytesource_pull: (a: number, b: number) => number;
86
+ readonly intounderlyingbytesource_start: (a: number, b: number) => void;
87
+ readonly intounderlyingbytesource_type: (a: number) => number;
88
+ readonly intounderlyingsink_abort: (a: number, b: number) => number;
89
+ readonly intounderlyingsink_close: (a: number) => number;
90
+ readonly intounderlyingsink_write: (a: number, b: number) => number;
91
+ readonly intounderlyingsource_cancel: (a: number) => void;
92
+ readonly intounderlyingsource_pull: (a: number, b: number) => number;
93
+ readonly remove_workspace_file: (a: number, b: number, c: number) => void;
94
+ readonly serve: (a: number) => number;
95
+ readonly serverconfig_new: (a: number, b: number) => number;
96
+ readonly set_workspace_entries: (a: number, b: number) => void;
97
+ readonly set_workspace_file: (a: number, b: number, c: number, d: number, e: number) => void;
98
+ readonly set_workspace_files: (a: number, b: number) => void;
99
+ readonly start: () => void;
100
+ readonly __wasm_bindgen_func_elem_17146: (a: number, b: number, c: number, d: number) => void;
101
+ readonly __wasm_bindgen_func_elem_17148: (a: number, b: number, c: number, d: number) => void;
102
+ readonly __wasm_bindgen_func_elem_233: (a: number, b: number, c: number, d: number) => void;
103
+ readonly __wbindgen_export: (a: number, b: number) => number;
104
+ readonly __wbindgen_export2: (a: number, b: number, c: number, d: number) => number;
105
+ readonly __wbindgen_export3: (a: number) => void;
106
+ readonly __wbindgen_export4: (a: number, b: number, c: number) => void;
107
+ readonly __wbindgen_export5: (a: number, b: number) => void;
108
+ readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
109
+ readonly __wbindgen_start: () => void;
94
110
  }
95
111
 
96
112
  export type SyncInitInput = BufferSource | WebAssembly.Module;
113
+
97
114
  /**
98
- * Instantiates the given `module`, which can either be bytes or
99
- * a precompiled `WebAssembly.Module`.
100
- *
101
- * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
102
- *
103
- * @returns {InitOutput}
104
- */
115
+ * Instantiates the given `module`, which can either be bytes or
116
+ * a precompiled `WebAssembly.Module`.
117
+ *
118
+ * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
119
+ *
120
+ * @returns {InitOutput}
121
+ */
105
122
  export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
106
123
 
107
124
  /**
108
- * If `module_or_path` is {RequestInfo} or {URL}, makes a request and
109
- * for everything else, calls `WebAssembly.instantiate` directly.
110
- *
111
- * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
112
- *
113
- * @returns {Promise<InitOutput>}
114
- */
125
+ * If `module_or_path` is {RequestInfo} or {URL}, makes a request and
126
+ * for everything else, calls `WebAssembly.instantiate` directly.
127
+ *
128
+ * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
129
+ *
130
+ * @returns {Promise<InitOutput>}
131
+ */
115
132
  export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;