@pydantic/logfire-sqlls 0.1.0
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/logfire_sqlls_wasm.d.ts +163 -0
- package/logfire_sqlls_wasm.js +1018 -0
- package/logfire_sqlls_wasm_bg.wasm +0 -0
- package/package.json +16 -0
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
|
|
4
|
+
export class Completion {
|
|
5
|
+
private constructor();
|
|
6
|
+
free(): void;
|
|
7
|
+
[Symbol.dispose](): void;
|
|
8
|
+
get detail(): string | undefined;
|
|
9
|
+
set detail(value: string | null | undefined);
|
|
10
|
+
get documentation(): string | undefined;
|
|
11
|
+
set documentation(value: string | null | undefined);
|
|
12
|
+
get insert_text(): string | undefined;
|
|
13
|
+
set insert_text(value: string | null | undefined);
|
|
14
|
+
kind: CompletionKind;
|
|
15
|
+
name: string;
|
|
16
|
+
span: Span;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export enum CompletionKind {
|
|
20
|
+
Class = 0,
|
|
21
|
+
Field = 1,
|
|
22
|
+
Function = 2,
|
|
23
|
+
Keyword = 3,
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export class Diagnostic {
|
|
27
|
+
private constructor();
|
|
28
|
+
free(): void;
|
|
29
|
+
[Symbol.dispose](): void;
|
|
30
|
+
message: string;
|
|
31
|
+
get related_information(): RelatedInformation[] | undefined;
|
|
32
|
+
set related_information(value: RelatedInformation[] | null | undefined);
|
|
33
|
+
severity: Severity;
|
|
34
|
+
span: Span;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export class Location {
|
|
38
|
+
free(): void;
|
|
39
|
+
[Symbol.dispose](): void;
|
|
40
|
+
constructor(line: number, column: number);
|
|
41
|
+
/**
|
|
42
|
+
* Line column, starting from 1.
|
|
43
|
+
*
|
|
44
|
+
* Note: Column 0 is used for empty spans
|
|
45
|
+
*/
|
|
46
|
+
column: number;
|
|
47
|
+
/**
|
|
48
|
+
* Line number, starting from 1.
|
|
49
|
+
*
|
|
50
|
+
* Note: Line 0 is used for empty spans
|
|
51
|
+
*/
|
|
52
|
+
line: number;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export class RelatedInformation {
|
|
56
|
+
private constructor();
|
|
57
|
+
free(): void;
|
|
58
|
+
[Symbol.dispose](): void;
|
|
59
|
+
message: string;
|
|
60
|
+
span: Span;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export enum Severity {
|
|
64
|
+
Info = 0,
|
|
65
|
+
Warning = 1,
|
|
66
|
+
Error = 2,
|
|
67
|
+
Fatal = 3,
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export class Span {
|
|
71
|
+
private constructor();
|
|
72
|
+
free(): void;
|
|
73
|
+
[Symbol.dispose](): void;
|
|
74
|
+
end: Location;
|
|
75
|
+
start: Location;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export class Workspace {
|
|
79
|
+
free(): void;
|
|
80
|
+
[Symbol.dispose](): void;
|
|
81
|
+
checkQuery(query: string): Diagnostic[];
|
|
82
|
+
getCompletions(query: string, location: Location): Completion[];
|
|
83
|
+
constructor(options: any);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
|
87
|
+
|
|
88
|
+
export interface InitOutput {
|
|
89
|
+
readonly memory: WebAssembly.Memory;
|
|
90
|
+
readonly __wbg_completion_free: (a: number, b: number) => void;
|
|
91
|
+
readonly __wbg_diagnostic_free: (a: number, b: number) => void;
|
|
92
|
+
readonly __wbg_get_completion_detail: (a: number) => [number, number];
|
|
93
|
+
readonly __wbg_get_completion_documentation: (a: number) => [number, number];
|
|
94
|
+
readonly __wbg_get_completion_insert_text: (a: number) => [number, number];
|
|
95
|
+
readonly __wbg_get_completion_kind: (a: number) => number;
|
|
96
|
+
readonly __wbg_get_completion_name: (a: number) => [number, number];
|
|
97
|
+
readonly __wbg_get_completion_span: (a: number) => number;
|
|
98
|
+
readonly __wbg_get_diagnostic_related_information: (a: number) => [number, number];
|
|
99
|
+
readonly __wbg_get_diagnostic_severity: (a: number) => number;
|
|
100
|
+
readonly __wbg_get_diagnostic_span: (a: number) => number;
|
|
101
|
+
readonly __wbg_get_location_column: (a: number) => number;
|
|
102
|
+
readonly __wbg_get_location_line: (a: number) => number;
|
|
103
|
+
readonly __wbg_get_relatedinformation_span: (a: number) => number;
|
|
104
|
+
readonly __wbg_get_span_end: (a: number) => number;
|
|
105
|
+
readonly __wbg_get_span_start: (a: number) => number;
|
|
106
|
+
readonly __wbg_location_free: (a: number, b: number) => void;
|
|
107
|
+
readonly __wbg_relatedinformation_free: (a: number, b: number) => void;
|
|
108
|
+
readonly __wbg_set_completion_detail: (a: number, b: number, c: number) => void;
|
|
109
|
+
readonly __wbg_set_completion_documentation: (a: number, b: number, c: number) => void;
|
|
110
|
+
readonly __wbg_set_completion_insert_text: (a: number, b: number, c: number) => void;
|
|
111
|
+
readonly __wbg_set_completion_kind: (a: number, b: number) => void;
|
|
112
|
+
readonly __wbg_set_completion_name: (a: number, b: number, c: number) => void;
|
|
113
|
+
readonly __wbg_set_completion_span: (a: number, b: number) => void;
|
|
114
|
+
readonly __wbg_set_diagnostic_related_information: (a: number, b: number, c: number) => void;
|
|
115
|
+
readonly __wbg_set_diagnostic_severity: (a: number, b: number) => void;
|
|
116
|
+
readonly __wbg_set_diagnostic_span: (a: number, b: number) => void;
|
|
117
|
+
readonly __wbg_set_location_column: (a: number, b: number) => void;
|
|
118
|
+
readonly __wbg_set_location_line: (a: number, b: number) => void;
|
|
119
|
+
readonly __wbg_set_relatedinformation_span: (a: number, b: number) => void;
|
|
120
|
+
readonly __wbg_set_span_end: (a: number, b: number) => void;
|
|
121
|
+
readonly __wbg_set_span_start: (a: number, b: number) => void;
|
|
122
|
+
readonly __wbg_span_free: (a: number, b: number) => void;
|
|
123
|
+
readonly location_new: (a: number, b: number) => number;
|
|
124
|
+
readonly __wbg_get_diagnostic_message: (a: number) => [number, number];
|
|
125
|
+
readonly __wbg_get_relatedinformation_message: (a: number) => [number, number];
|
|
126
|
+
readonly __wbg_set_diagnostic_message: (a: number, b: number, c: number) => void;
|
|
127
|
+
readonly __wbg_set_relatedinformation_message: (a: number, b: number, c: number) => void;
|
|
128
|
+
readonly __wbg_workspace_free: (a: number, b: number) => void;
|
|
129
|
+
readonly workspace_checkQuery: (a: number, b: number, c: number) => [number, number];
|
|
130
|
+
readonly workspace_getCompletions: (a: number, b: number, c: number, d: number) => [number, number];
|
|
131
|
+
readonly workspace_new: (a: any) => [number, number, number];
|
|
132
|
+
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
133
|
+
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
134
|
+
readonly __wbindgen_exn_store: (a: number) => void;
|
|
135
|
+
readonly __externref_table_alloc: () => number;
|
|
136
|
+
readonly __wbindgen_externrefs: WebAssembly.Table;
|
|
137
|
+
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
138
|
+
readonly __externref_drop_slice: (a: number, b: number) => void;
|
|
139
|
+
readonly __externref_table_dealloc: (a: number) => void;
|
|
140
|
+
readonly __wbindgen_start: () => void;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
export type SyncInitInput = BufferSource | WebAssembly.Module;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* Instantiates the given `module`, which can either be bytes or
|
|
147
|
+
* a precompiled `WebAssembly.Module`.
|
|
148
|
+
*
|
|
149
|
+
* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
|
|
150
|
+
*
|
|
151
|
+
* @returns {InitOutput}
|
|
152
|
+
*/
|
|
153
|
+
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
|
|
157
|
+
* for everything else, calls `WebAssembly.instantiate` directly.
|
|
158
|
+
*
|
|
159
|
+
* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
|
|
160
|
+
*
|
|
161
|
+
* @returns {Promise<InitOutput>}
|
|
162
|
+
*/
|
|
163
|
+
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
|
|
@@ -0,0 +1,1018 @@
|
|
|
1
|
+
/* @ts-self-types="./logfire_sqlls_wasm.d.ts" */
|
|
2
|
+
|
|
3
|
+
export class Completion {
|
|
4
|
+
static __wrap(ptr) {
|
|
5
|
+
ptr = ptr >>> 0;
|
|
6
|
+
const obj = Object.create(Completion.prototype);
|
|
7
|
+
obj.__wbg_ptr = ptr;
|
|
8
|
+
CompletionFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
9
|
+
return obj;
|
|
10
|
+
}
|
|
11
|
+
__destroy_into_raw() {
|
|
12
|
+
const ptr = this.__wbg_ptr;
|
|
13
|
+
this.__wbg_ptr = 0;
|
|
14
|
+
CompletionFinalization.unregister(this);
|
|
15
|
+
return ptr;
|
|
16
|
+
}
|
|
17
|
+
free() {
|
|
18
|
+
const ptr = this.__destroy_into_raw();
|
|
19
|
+
wasm.__wbg_completion_free(ptr, 0);
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* @returns {string | undefined}
|
|
23
|
+
*/
|
|
24
|
+
get detail() {
|
|
25
|
+
const ret = wasm.__wbg_get_completion_detail(this.__wbg_ptr);
|
|
26
|
+
let v1;
|
|
27
|
+
if (ret[0] !== 0) {
|
|
28
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
29
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
30
|
+
}
|
|
31
|
+
return v1;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* @returns {string | undefined}
|
|
35
|
+
*/
|
|
36
|
+
get documentation() {
|
|
37
|
+
const ret = wasm.__wbg_get_completion_documentation(this.__wbg_ptr);
|
|
38
|
+
let v1;
|
|
39
|
+
if (ret[0] !== 0) {
|
|
40
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
41
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
42
|
+
}
|
|
43
|
+
return v1;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* @returns {string | undefined}
|
|
47
|
+
*/
|
|
48
|
+
get insert_text() {
|
|
49
|
+
const ret = wasm.__wbg_get_completion_insert_text(this.__wbg_ptr);
|
|
50
|
+
let v1;
|
|
51
|
+
if (ret[0] !== 0) {
|
|
52
|
+
v1 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
53
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
54
|
+
}
|
|
55
|
+
return v1;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* @returns {CompletionKind}
|
|
59
|
+
*/
|
|
60
|
+
get kind() {
|
|
61
|
+
const ret = wasm.__wbg_get_completion_kind(this.__wbg_ptr);
|
|
62
|
+
return ret;
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* @returns {string}
|
|
66
|
+
*/
|
|
67
|
+
get name() {
|
|
68
|
+
let deferred1_0;
|
|
69
|
+
let deferred1_1;
|
|
70
|
+
try {
|
|
71
|
+
const ret = wasm.__wbg_get_completion_name(this.__wbg_ptr);
|
|
72
|
+
deferred1_0 = ret[0];
|
|
73
|
+
deferred1_1 = ret[1];
|
|
74
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
75
|
+
} finally {
|
|
76
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* @returns {Span}
|
|
81
|
+
*/
|
|
82
|
+
get span() {
|
|
83
|
+
const ret = wasm.__wbg_get_completion_span(this.__wbg_ptr);
|
|
84
|
+
return Span.__wrap(ret);
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* @param {string | null} [arg0]
|
|
88
|
+
*/
|
|
89
|
+
set detail(arg0) {
|
|
90
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
91
|
+
var len0 = WASM_VECTOR_LEN;
|
|
92
|
+
wasm.__wbg_set_completion_detail(this.__wbg_ptr, ptr0, len0);
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* @param {string | null} [arg0]
|
|
96
|
+
*/
|
|
97
|
+
set documentation(arg0) {
|
|
98
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
99
|
+
var len0 = WASM_VECTOR_LEN;
|
|
100
|
+
wasm.__wbg_set_completion_documentation(this.__wbg_ptr, ptr0, len0);
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* @param {string | null} [arg0]
|
|
104
|
+
*/
|
|
105
|
+
set insert_text(arg0) {
|
|
106
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
107
|
+
var len0 = WASM_VECTOR_LEN;
|
|
108
|
+
wasm.__wbg_set_completion_insert_text(this.__wbg_ptr, ptr0, len0);
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* @param {CompletionKind} arg0
|
|
112
|
+
*/
|
|
113
|
+
set kind(arg0) {
|
|
114
|
+
wasm.__wbg_set_completion_kind(this.__wbg_ptr, arg0);
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* @param {string} arg0
|
|
118
|
+
*/
|
|
119
|
+
set name(arg0) {
|
|
120
|
+
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
121
|
+
const len0 = WASM_VECTOR_LEN;
|
|
122
|
+
wasm.__wbg_set_completion_name(this.__wbg_ptr, ptr0, len0);
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* @param {Span} arg0
|
|
126
|
+
*/
|
|
127
|
+
set span(arg0) {
|
|
128
|
+
_assertClass(arg0, Span);
|
|
129
|
+
var ptr0 = arg0.__destroy_into_raw();
|
|
130
|
+
wasm.__wbg_set_completion_span(this.__wbg_ptr, ptr0);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
if (Symbol.dispose) Completion.prototype[Symbol.dispose] = Completion.prototype.free;
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* @enum {0 | 1 | 2 | 3}
|
|
137
|
+
*/
|
|
138
|
+
export const CompletionKind = Object.freeze({
|
|
139
|
+
Class: 0, "0": "Class",
|
|
140
|
+
Field: 1, "1": "Field",
|
|
141
|
+
Function: 2, "2": "Function",
|
|
142
|
+
Keyword: 3, "3": "Keyword",
|
|
143
|
+
});
|
|
144
|
+
|
|
145
|
+
export class Diagnostic {
|
|
146
|
+
static __wrap(ptr) {
|
|
147
|
+
ptr = ptr >>> 0;
|
|
148
|
+
const obj = Object.create(Diagnostic.prototype);
|
|
149
|
+
obj.__wbg_ptr = ptr;
|
|
150
|
+
DiagnosticFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
151
|
+
return obj;
|
|
152
|
+
}
|
|
153
|
+
__destroy_into_raw() {
|
|
154
|
+
const ptr = this.__wbg_ptr;
|
|
155
|
+
this.__wbg_ptr = 0;
|
|
156
|
+
DiagnosticFinalization.unregister(this);
|
|
157
|
+
return ptr;
|
|
158
|
+
}
|
|
159
|
+
free() {
|
|
160
|
+
const ptr = this.__destroy_into_raw();
|
|
161
|
+
wasm.__wbg_diagnostic_free(ptr, 0);
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* @returns {string}
|
|
165
|
+
*/
|
|
166
|
+
get message() {
|
|
167
|
+
let deferred1_0;
|
|
168
|
+
let deferred1_1;
|
|
169
|
+
try {
|
|
170
|
+
const ret = wasm.__wbg_get_diagnostic_message(this.__wbg_ptr);
|
|
171
|
+
deferred1_0 = ret[0];
|
|
172
|
+
deferred1_1 = ret[1];
|
|
173
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
174
|
+
} finally {
|
|
175
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* @returns {RelatedInformation[] | undefined}
|
|
180
|
+
*/
|
|
181
|
+
get related_information() {
|
|
182
|
+
const ret = wasm.__wbg_get_diagnostic_related_information(this.__wbg_ptr);
|
|
183
|
+
let v1;
|
|
184
|
+
if (ret[0] !== 0) {
|
|
185
|
+
v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
186
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
187
|
+
}
|
|
188
|
+
return v1;
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* @returns {Severity}
|
|
192
|
+
*/
|
|
193
|
+
get severity() {
|
|
194
|
+
const ret = wasm.__wbg_get_diagnostic_severity(this.__wbg_ptr);
|
|
195
|
+
return ret;
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* @returns {Span}
|
|
199
|
+
*/
|
|
200
|
+
get span() {
|
|
201
|
+
const ret = wasm.__wbg_get_diagnostic_span(this.__wbg_ptr);
|
|
202
|
+
return Span.__wrap(ret);
|
|
203
|
+
}
|
|
204
|
+
/**
|
|
205
|
+
* @param {string} arg0
|
|
206
|
+
*/
|
|
207
|
+
set message(arg0) {
|
|
208
|
+
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
209
|
+
const len0 = WASM_VECTOR_LEN;
|
|
210
|
+
wasm.__wbg_set_diagnostic_message(this.__wbg_ptr, ptr0, len0);
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* @param {RelatedInformation[] | null} [arg0]
|
|
214
|
+
*/
|
|
215
|
+
set related_information(arg0) {
|
|
216
|
+
var ptr0 = isLikeNone(arg0) ? 0 : passArrayJsValueToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
217
|
+
var len0 = WASM_VECTOR_LEN;
|
|
218
|
+
wasm.__wbg_set_diagnostic_related_information(this.__wbg_ptr, ptr0, len0);
|
|
219
|
+
}
|
|
220
|
+
/**
|
|
221
|
+
* @param {Severity} arg0
|
|
222
|
+
*/
|
|
223
|
+
set severity(arg0) {
|
|
224
|
+
wasm.__wbg_set_diagnostic_severity(this.__wbg_ptr, arg0);
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* @param {Span} arg0
|
|
228
|
+
*/
|
|
229
|
+
set span(arg0) {
|
|
230
|
+
_assertClass(arg0, Span);
|
|
231
|
+
var ptr0 = arg0.__destroy_into_raw();
|
|
232
|
+
wasm.__wbg_set_diagnostic_span(this.__wbg_ptr, ptr0);
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
if (Symbol.dispose) Diagnostic.prototype[Symbol.dispose] = Diagnostic.prototype.free;
|
|
236
|
+
|
|
237
|
+
export class Location {
|
|
238
|
+
static __wrap(ptr) {
|
|
239
|
+
ptr = ptr >>> 0;
|
|
240
|
+
const obj = Object.create(Location.prototype);
|
|
241
|
+
obj.__wbg_ptr = ptr;
|
|
242
|
+
LocationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
243
|
+
return obj;
|
|
244
|
+
}
|
|
245
|
+
__destroy_into_raw() {
|
|
246
|
+
const ptr = this.__wbg_ptr;
|
|
247
|
+
this.__wbg_ptr = 0;
|
|
248
|
+
LocationFinalization.unregister(this);
|
|
249
|
+
return ptr;
|
|
250
|
+
}
|
|
251
|
+
free() {
|
|
252
|
+
const ptr = this.__destroy_into_raw();
|
|
253
|
+
wasm.__wbg_location_free(ptr, 0);
|
|
254
|
+
}
|
|
255
|
+
/**
|
|
256
|
+
* Line column, starting from 1.
|
|
257
|
+
*
|
|
258
|
+
* Note: Column 0 is used for empty spans
|
|
259
|
+
* @returns {number}
|
|
260
|
+
*/
|
|
261
|
+
get column() {
|
|
262
|
+
const ret = wasm.__wbg_get_location_column(this.__wbg_ptr);
|
|
263
|
+
return ret >>> 0;
|
|
264
|
+
}
|
|
265
|
+
/**
|
|
266
|
+
* Line number, starting from 1.
|
|
267
|
+
*
|
|
268
|
+
* Note: Line 0 is used for empty spans
|
|
269
|
+
* @returns {number}
|
|
270
|
+
*/
|
|
271
|
+
get line() {
|
|
272
|
+
const ret = wasm.__wbg_get_location_line(this.__wbg_ptr);
|
|
273
|
+
return ret >>> 0;
|
|
274
|
+
}
|
|
275
|
+
/**
|
|
276
|
+
* @param {number} line
|
|
277
|
+
* @param {number} column
|
|
278
|
+
*/
|
|
279
|
+
constructor(line, column) {
|
|
280
|
+
const ret = wasm.location_new(line, column);
|
|
281
|
+
this.__wbg_ptr = ret >>> 0;
|
|
282
|
+
LocationFinalization.register(this, this.__wbg_ptr, this);
|
|
283
|
+
return this;
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* Line column, starting from 1.
|
|
287
|
+
*
|
|
288
|
+
* Note: Column 0 is used for empty spans
|
|
289
|
+
* @param {number} arg0
|
|
290
|
+
*/
|
|
291
|
+
set column(arg0) {
|
|
292
|
+
wasm.__wbg_set_location_column(this.__wbg_ptr, arg0);
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* Line number, starting from 1.
|
|
296
|
+
*
|
|
297
|
+
* Note: Line 0 is used for empty spans
|
|
298
|
+
* @param {number} arg0
|
|
299
|
+
*/
|
|
300
|
+
set line(arg0) {
|
|
301
|
+
wasm.__wbg_set_location_line(this.__wbg_ptr, arg0);
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
if (Symbol.dispose) Location.prototype[Symbol.dispose] = Location.prototype.free;
|
|
305
|
+
|
|
306
|
+
export class RelatedInformation {
|
|
307
|
+
static __wrap(ptr) {
|
|
308
|
+
ptr = ptr >>> 0;
|
|
309
|
+
const obj = Object.create(RelatedInformation.prototype);
|
|
310
|
+
obj.__wbg_ptr = ptr;
|
|
311
|
+
RelatedInformationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
312
|
+
return obj;
|
|
313
|
+
}
|
|
314
|
+
static __unwrap(jsValue) {
|
|
315
|
+
if (!(jsValue instanceof RelatedInformation)) {
|
|
316
|
+
return 0;
|
|
317
|
+
}
|
|
318
|
+
return jsValue.__destroy_into_raw();
|
|
319
|
+
}
|
|
320
|
+
__destroy_into_raw() {
|
|
321
|
+
const ptr = this.__wbg_ptr;
|
|
322
|
+
this.__wbg_ptr = 0;
|
|
323
|
+
RelatedInformationFinalization.unregister(this);
|
|
324
|
+
return ptr;
|
|
325
|
+
}
|
|
326
|
+
free() {
|
|
327
|
+
const ptr = this.__destroy_into_raw();
|
|
328
|
+
wasm.__wbg_relatedinformation_free(ptr, 0);
|
|
329
|
+
}
|
|
330
|
+
/**
|
|
331
|
+
* @returns {string}
|
|
332
|
+
*/
|
|
333
|
+
get message() {
|
|
334
|
+
let deferred1_0;
|
|
335
|
+
let deferred1_1;
|
|
336
|
+
try {
|
|
337
|
+
const ret = wasm.__wbg_get_relatedinformation_message(this.__wbg_ptr);
|
|
338
|
+
deferred1_0 = ret[0];
|
|
339
|
+
deferred1_1 = ret[1];
|
|
340
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
341
|
+
} finally {
|
|
342
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
/**
|
|
346
|
+
* @returns {Span}
|
|
347
|
+
*/
|
|
348
|
+
get span() {
|
|
349
|
+
const ret = wasm.__wbg_get_relatedinformation_span(this.__wbg_ptr);
|
|
350
|
+
return Span.__wrap(ret);
|
|
351
|
+
}
|
|
352
|
+
/**
|
|
353
|
+
* @param {string} arg0
|
|
354
|
+
*/
|
|
355
|
+
set message(arg0) {
|
|
356
|
+
const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
357
|
+
const len0 = WASM_VECTOR_LEN;
|
|
358
|
+
wasm.__wbg_set_relatedinformation_message(this.__wbg_ptr, ptr0, len0);
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* @param {Span} arg0
|
|
362
|
+
*/
|
|
363
|
+
set span(arg0) {
|
|
364
|
+
_assertClass(arg0, Span);
|
|
365
|
+
var ptr0 = arg0.__destroy_into_raw();
|
|
366
|
+
wasm.__wbg_set_relatedinformation_span(this.__wbg_ptr, ptr0);
|
|
367
|
+
}
|
|
368
|
+
}
|
|
369
|
+
if (Symbol.dispose) RelatedInformation.prototype[Symbol.dispose] = RelatedInformation.prototype.free;
|
|
370
|
+
|
|
371
|
+
/**
|
|
372
|
+
* @enum {0 | 1 | 2 | 3}
|
|
373
|
+
*/
|
|
374
|
+
export const Severity = Object.freeze({
|
|
375
|
+
Info: 0, "0": "Info",
|
|
376
|
+
Warning: 1, "1": "Warning",
|
|
377
|
+
Error: 2, "2": "Error",
|
|
378
|
+
Fatal: 3, "3": "Fatal",
|
|
379
|
+
});
|
|
380
|
+
|
|
381
|
+
export class Span {
|
|
382
|
+
static __wrap(ptr) {
|
|
383
|
+
ptr = ptr >>> 0;
|
|
384
|
+
const obj = Object.create(Span.prototype);
|
|
385
|
+
obj.__wbg_ptr = ptr;
|
|
386
|
+
SpanFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
387
|
+
return obj;
|
|
388
|
+
}
|
|
389
|
+
__destroy_into_raw() {
|
|
390
|
+
const ptr = this.__wbg_ptr;
|
|
391
|
+
this.__wbg_ptr = 0;
|
|
392
|
+
SpanFinalization.unregister(this);
|
|
393
|
+
return ptr;
|
|
394
|
+
}
|
|
395
|
+
free() {
|
|
396
|
+
const ptr = this.__destroy_into_raw();
|
|
397
|
+
wasm.__wbg_span_free(ptr, 0);
|
|
398
|
+
}
|
|
399
|
+
/**
|
|
400
|
+
* @returns {Location}
|
|
401
|
+
*/
|
|
402
|
+
get end() {
|
|
403
|
+
const ret = wasm.__wbg_get_span_end(this.__wbg_ptr);
|
|
404
|
+
return Location.__wrap(ret);
|
|
405
|
+
}
|
|
406
|
+
/**
|
|
407
|
+
* @returns {Location}
|
|
408
|
+
*/
|
|
409
|
+
get start() {
|
|
410
|
+
const ret = wasm.__wbg_get_span_start(this.__wbg_ptr);
|
|
411
|
+
return Location.__wrap(ret);
|
|
412
|
+
}
|
|
413
|
+
/**
|
|
414
|
+
* @param {Location} arg0
|
|
415
|
+
*/
|
|
416
|
+
set end(arg0) {
|
|
417
|
+
_assertClass(arg0, Location);
|
|
418
|
+
var ptr0 = arg0.__destroy_into_raw();
|
|
419
|
+
wasm.__wbg_set_span_end(this.__wbg_ptr, ptr0);
|
|
420
|
+
}
|
|
421
|
+
/**
|
|
422
|
+
* @param {Location} arg0
|
|
423
|
+
*/
|
|
424
|
+
set start(arg0) {
|
|
425
|
+
_assertClass(arg0, Location);
|
|
426
|
+
var ptr0 = arg0.__destroy_into_raw();
|
|
427
|
+
wasm.__wbg_set_span_start(this.__wbg_ptr, ptr0);
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
if (Symbol.dispose) Span.prototype[Symbol.dispose] = Span.prototype.free;
|
|
431
|
+
|
|
432
|
+
export class Workspace {
|
|
433
|
+
__destroy_into_raw() {
|
|
434
|
+
const ptr = this.__wbg_ptr;
|
|
435
|
+
this.__wbg_ptr = 0;
|
|
436
|
+
WorkspaceFinalization.unregister(this);
|
|
437
|
+
return ptr;
|
|
438
|
+
}
|
|
439
|
+
free() {
|
|
440
|
+
const ptr = this.__destroy_into_raw();
|
|
441
|
+
wasm.__wbg_workspace_free(ptr, 0);
|
|
442
|
+
}
|
|
443
|
+
/**
|
|
444
|
+
* @param {string} query
|
|
445
|
+
* @returns {Diagnostic[]}
|
|
446
|
+
*/
|
|
447
|
+
checkQuery(query) {
|
|
448
|
+
const ptr0 = passStringToWasm0(query, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
449
|
+
const len0 = WASM_VECTOR_LEN;
|
|
450
|
+
const ret = wasm.workspace_checkQuery(this.__wbg_ptr, ptr0, len0);
|
|
451
|
+
var v2 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
452
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
453
|
+
return v2;
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* @param {string} query
|
|
457
|
+
* @param {Location} location
|
|
458
|
+
* @returns {Completion[]}
|
|
459
|
+
*/
|
|
460
|
+
getCompletions(query, location) {
|
|
461
|
+
const ptr0 = passStringToWasm0(query, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
462
|
+
const len0 = WASM_VECTOR_LEN;
|
|
463
|
+
_assertClass(location, Location);
|
|
464
|
+
var ptr1 = location.__destroy_into_raw();
|
|
465
|
+
const ret = wasm.workspace_getCompletions(this.__wbg_ptr, ptr0, len0, ptr1);
|
|
466
|
+
var v3 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
467
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
468
|
+
return v3;
|
|
469
|
+
}
|
|
470
|
+
/**
|
|
471
|
+
* @param {any} options
|
|
472
|
+
*/
|
|
473
|
+
constructor(options) {
|
|
474
|
+
const ret = wasm.workspace_new(options);
|
|
475
|
+
if (ret[2]) {
|
|
476
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
477
|
+
}
|
|
478
|
+
this.__wbg_ptr = ret[0] >>> 0;
|
|
479
|
+
WorkspaceFinalization.register(this, this.__wbg_ptr, this);
|
|
480
|
+
return this;
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
if (Symbol.dispose) Workspace.prototype[Symbol.dispose] = Workspace.prototype.free;
|
|
484
|
+
|
|
485
|
+
function __wbg_get_imports() {
|
|
486
|
+
const import0 = {
|
|
487
|
+
__proto__: null,
|
|
488
|
+
__wbg_Error_4577686b3a6d9b3a: function(arg0, arg1) {
|
|
489
|
+
const ret = Error(getStringFromWasm0(arg0, arg1));
|
|
490
|
+
return ret;
|
|
491
|
+
},
|
|
492
|
+
__wbg_String_8564e559799eccda: function(arg0, arg1) {
|
|
493
|
+
const ret = String(arg1);
|
|
494
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
495
|
+
const len1 = WASM_VECTOR_LEN;
|
|
496
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
497
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
498
|
+
},
|
|
499
|
+
__wbg___wbindgen_boolean_get_18c4ed9422296fff: function(arg0) {
|
|
500
|
+
const v = arg0;
|
|
501
|
+
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
502
|
+
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
503
|
+
},
|
|
504
|
+
__wbg___wbindgen_debug_string_ddde1867f49c2442: function(arg0, arg1) {
|
|
505
|
+
const ret = debugString(arg1);
|
|
506
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
507
|
+
const len1 = WASM_VECTOR_LEN;
|
|
508
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
509
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
510
|
+
},
|
|
511
|
+
__wbg___wbindgen_in_1064a108f4d18b9e: function(arg0, arg1) {
|
|
512
|
+
const ret = arg0 in arg1;
|
|
513
|
+
return ret;
|
|
514
|
+
},
|
|
515
|
+
__wbg___wbindgen_is_function_d633e708baf0d146: function(arg0) {
|
|
516
|
+
const ret = typeof(arg0) === 'function';
|
|
517
|
+
return ret;
|
|
518
|
+
},
|
|
519
|
+
__wbg___wbindgen_is_object_4b3de556756ee8a8: function(arg0) {
|
|
520
|
+
const val = arg0;
|
|
521
|
+
const ret = typeof(val) === 'object' && val !== null;
|
|
522
|
+
return ret;
|
|
523
|
+
},
|
|
524
|
+
__wbg___wbindgen_is_string_7debe47dc1e045c2: function(arg0) {
|
|
525
|
+
const ret = typeof(arg0) === 'string';
|
|
526
|
+
return ret;
|
|
527
|
+
},
|
|
528
|
+
__wbg___wbindgen_is_undefined_c18285b9fc34cb7d: function(arg0) {
|
|
529
|
+
const ret = arg0 === undefined;
|
|
530
|
+
return ret;
|
|
531
|
+
},
|
|
532
|
+
__wbg___wbindgen_jsval_loose_eq_1562ceb9af84e990: function(arg0, arg1) {
|
|
533
|
+
const ret = arg0 == arg1;
|
|
534
|
+
return ret;
|
|
535
|
+
},
|
|
536
|
+
__wbg___wbindgen_number_get_5854912275df1894: function(arg0, arg1) {
|
|
537
|
+
const obj = arg1;
|
|
538
|
+
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
539
|
+
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
540
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
541
|
+
},
|
|
542
|
+
__wbg___wbindgen_string_get_3e5751597f39a112: function(arg0, arg1) {
|
|
543
|
+
const obj = arg1;
|
|
544
|
+
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
545
|
+
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
546
|
+
var len1 = WASM_VECTOR_LEN;
|
|
547
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
548
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
549
|
+
},
|
|
550
|
+
__wbg___wbindgen_throw_39bc967c0e5a9b58: function(arg0, arg1) {
|
|
551
|
+
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
552
|
+
},
|
|
553
|
+
__wbg_call_73af281463ec8b58: function() { return handleError(function (arg0, arg1) {
|
|
554
|
+
const ret = arg0.call(arg1);
|
|
555
|
+
return ret;
|
|
556
|
+
}, arguments); },
|
|
557
|
+
__wbg_completion_new: function(arg0) {
|
|
558
|
+
const ret = Completion.__wrap(arg0);
|
|
559
|
+
return ret;
|
|
560
|
+
},
|
|
561
|
+
__wbg_diagnostic_new: function(arg0) {
|
|
562
|
+
const ret = Diagnostic.__wrap(arg0);
|
|
563
|
+
return ret;
|
|
564
|
+
},
|
|
565
|
+
__wbg_done_5aad55ec6b1954b1: function(arg0) {
|
|
566
|
+
const ret = arg0.done;
|
|
567
|
+
return ret;
|
|
568
|
+
},
|
|
569
|
+
__wbg_entries_28d32ba4cd93f5fc: function(arg0) {
|
|
570
|
+
const ret = Object.entries(arg0);
|
|
571
|
+
return ret;
|
|
572
|
+
},
|
|
573
|
+
__wbg_error_a6fa202b58aa1cd3: function(arg0, arg1) {
|
|
574
|
+
let deferred0_0;
|
|
575
|
+
let deferred0_1;
|
|
576
|
+
try {
|
|
577
|
+
deferred0_0 = arg0;
|
|
578
|
+
deferred0_1 = arg1;
|
|
579
|
+
console.error(getStringFromWasm0(arg0, arg1));
|
|
580
|
+
} finally {
|
|
581
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
582
|
+
}
|
|
583
|
+
},
|
|
584
|
+
__wbg_get_4920fefd3451364b: function() { return handleError(function (arg0, arg1) {
|
|
585
|
+
const ret = Reflect.get(arg0, arg1);
|
|
586
|
+
return ret;
|
|
587
|
+
}, arguments); },
|
|
588
|
+
__wbg_get_f09c3a16f8848381: function(arg0, arg1) {
|
|
589
|
+
const ret = arg0[arg1 >>> 0];
|
|
590
|
+
return ret;
|
|
591
|
+
},
|
|
592
|
+
__wbg_get_unchecked_3d0f4b91c8eca4f0: function(arg0, arg1) {
|
|
593
|
+
const ret = arg0[arg1 >>> 0];
|
|
594
|
+
return ret;
|
|
595
|
+
},
|
|
596
|
+
__wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
|
|
597
|
+
const ret = arg0[arg1];
|
|
598
|
+
return ret;
|
|
599
|
+
},
|
|
600
|
+
__wbg_instanceof_ArrayBuffer_15859862b80b732d: function(arg0) {
|
|
601
|
+
let result;
|
|
602
|
+
try {
|
|
603
|
+
result = arg0 instanceof ArrayBuffer;
|
|
604
|
+
} catch (_) {
|
|
605
|
+
result = false;
|
|
606
|
+
}
|
|
607
|
+
const ret = result;
|
|
608
|
+
return ret;
|
|
609
|
+
},
|
|
610
|
+
__wbg_instanceof_Uint8Array_2240b7046ac16f05: function(arg0) {
|
|
611
|
+
let result;
|
|
612
|
+
try {
|
|
613
|
+
result = arg0 instanceof Uint8Array;
|
|
614
|
+
} catch (_) {
|
|
615
|
+
result = false;
|
|
616
|
+
}
|
|
617
|
+
const ret = result;
|
|
618
|
+
return ret;
|
|
619
|
+
},
|
|
620
|
+
__wbg_isArray_fad08a0d12828686: function(arg0) {
|
|
621
|
+
const ret = Array.isArray(arg0);
|
|
622
|
+
return ret;
|
|
623
|
+
},
|
|
624
|
+
__wbg_iterator_fc7ad8d33bab9e26: function() {
|
|
625
|
+
const ret = Symbol.iterator;
|
|
626
|
+
return ret;
|
|
627
|
+
},
|
|
628
|
+
__wbg_length_5855c1f289dfffc1: function(arg0) {
|
|
629
|
+
const ret = arg0.length;
|
|
630
|
+
return ret;
|
|
631
|
+
},
|
|
632
|
+
__wbg_length_a31e05262e09b7f8: function(arg0) {
|
|
633
|
+
const ret = arg0.length;
|
|
634
|
+
return ret;
|
|
635
|
+
},
|
|
636
|
+
__wbg_new_09959f7b4c92c246: function(arg0) {
|
|
637
|
+
const ret = new Uint8Array(arg0);
|
|
638
|
+
return ret;
|
|
639
|
+
},
|
|
640
|
+
__wbg_new_1213b57bccbdbb66: function(arg0, arg1) {
|
|
641
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
642
|
+
return ret;
|
|
643
|
+
},
|
|
644
|
+
__wbg_new_227d7c05414eb861: function() {
|
|
645
|
+
const ret = new Error();
|
|
646
|
+
return ret;
|
|
647
|
+
},
|
|
648
|
+
__wbg_next_a5fe6f328f7affc2: function(arg0) {
|
|
649
|
+
const ret = arg0.next;
|
|
650
|
+
return ret;
|
|
651
|
+
},
|
|
652
|
+
__wbg_next_e592122bb4ed4c67: function() { return handleError(function (arg0) {
|
|
653
|
+
const ret = arg0.next();
|
|
654
|
+
return ret;
|
|
655
|
+
}, arguments); },
|
|
656
|
+
__wbg_prototypesetcall_f034d444741426c3: function(arg0, arg1, arg2) {
|
|
657
|
+
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
|
|
658
|
+
},
|
|
659
|
+
__wbg_relatedinformation_new: function(arg0) {
|
|
660
|
+
const ret = RelatedInformation.__wrap(arg0);
|
|
661
|
+
return ret;
|
|
662
|
+
},
|
|
663
|
+
__wbg_relatedinformation_unwrap: function(arg0) {
|
|
664
|
+
const ret = RelatedInformation.__unwrap(arg0);
|
|
665
|
+
return ret;
|
|
666
|
+
},
|
|
667
|
+
__wbg_stack_3b0d974bbf31e44f: function(arg0, arg1) {
|
|
668
|
+
const ret = arg1.stack;
|
|
669
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
670
|
+
const len1 = WASM_VECTOR_LEN;
|
|
671
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
672
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
673
|
+
},
|
|
674
|
+
__wbg_value_667dcb90597486a6: function(arg0) {
|
|
675
|
+
const ret = arg0.value;
|
|
676
|
+
return ret;
|
|
677
|
+
},
|
|
678
|
+
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
679
|
+
// Cast intrinsic for `Ref(String) -> Externref`.
|
|
680
|
+
const ret = getStringFromWasm0(arg0, arg1);
|
|
681
|
+
return ret;
|
|
682
|
+
},
|
|
683
|
+
__wbindgen_init_externref_table: function() {
|
|
684
|
+
const table = wasm.__wbindgen_externrefs;
|
|
685
|
+
const offset = table.grow(4);
|
|
686
|
+
table.set(0, undefined);
|
|
687
|
+
table.set(offset + 0, undefined);
|
|
688
|
+
table.set(offset + 1, null);
|
|
689
|
+
table.set(offset + 2, true);
|
|
690
|
+
table.set(offset + 3, false);
|
|
691
|
+
},
|
|
692
|
+
};
|
|
693
|
+
return {
|
|
694
|
+
__proto__: null,
|
|
695
|
+
"./logfire_sqlls_wasm_bg.js": import0,
|
|
696
|
+
};
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
const CompletionFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
700
|
+
? { register: () => {}, unregister: () => {} }
|
|
701
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_completion_free(ptr >>> 0, 1));
|
|
702
|
+
const DiagnosticFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
703
|
+
? { register: () => {}, unregister: () => {} }
|
|
704
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_diagnostic_free(ptr >>> 0, 1));
|
|
705
|
+
const LocationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
706
|
+
? { register: () => {}, unregister: () => {} }
|
|
707
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_location_free(ptr >>> 0, 1));
|
|
708
|
+
const RelatedInformationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
709
|
+
? { register: () => {}, unregister: () => {} }
|
|
710
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_relatedinformation_free(ptr >>> 0, 1));
|
|
711
|
+
const SpanFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
712
|
+
? { register: () => {}, unregister: () => {} }
|
|
713
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_span_free(ptr >>> 0, 1));
|
|
714
|
+
const WorkspaceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
715
|
+
? { register: () => {}, unregister: () => {} }
|
|
716
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_workspace_free(ptr >>> 0, 1));
|
|
717
|
+
|
|
718
|
+
function addToExternrefTable0(obj) {
|
|
719
|
+
const idx = wasm.__externref_table_alloc();
|
|
720
|
+
wasm.__wbindgen_externrefs.set(idx, obj);
|
|
721
|
+
return idx;
|
|
722
|
+
}
|
|
723
|
+
|
|
724
|
+
function _assertClass(instance, klass) {
|
|
725
|
+
if (!(instance instanceof klass)) {
|
|
726
|
+
throw new Error(`expected instance of ${klass.name}`);
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
function debugString(val) {
|
|
731
|
+
// primitive types
|
|
732
|
+
const type = typeof val;
|
|
733
|
+
if (type == 'number' || type == 'boolean' || val == null) {
|
|
734
|
+
return `${val}`;
|
|
735
|
+
}
|
|
736
|
+
if (type == 'string') {
|
|
737
|
+
return `"${val}"`;
|
|
738
|
+
}
|
|
739
|
+
if (type == 'symbol') {
|
|
740
|
+
const description = val.description;
|
|
741
|
+
if (description == null) {
|
|
742
|
+
return 'Symbol';
|
|
743
|
+
} else {
|
|
744
|
+
return `Symbol(${description})`;
|
|
745
|
+
}
|
|
746
|
+
}
|
|
747
|
+
if (type == 'function') {
|
|
748
|
+
const name = val.name;
|
|
749
|
+
if (typeof name == 'string' && name.length > 0) {
|
|
750
|
+
return `Function(${name})`;
|
|
751
|
+
} else {
|
|
752
|
+
return 'Function';
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
// objects
|
|
756
|
+
if (Array.isArray(val)) {
|
|
757
|
+
const length = val.length;
|
|
758
|
+
let debug = '[';
|
|
759
|
+
if (length > 0) {
|
|
760
|
+
debug += debugString(val[0]);
|
|
761
|
+
}
|
|
762
|
+
for(let i = 1; i < length; i++) {
|
|
763
|
+
debug += ', ' + debugString(val[i]);
|
|
764
|
+
}
|
|
765
|
+
debug += ']';
|
|
766
|
+
return debug;
|
|
767
|
+
}
|
|
768
|
+
// Test for built-in
|
|
769
|
+
const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
|
|
770
|
+
let className;
|
|
771
|
+
if (builtInMatches && builtInMatches.length > 1) {
|
|
772
|
+
className = builtInMatches[1];
|
|
773
|
+
} else {
|
|
774
|
+
// Failed to match the standard '[object ClassName]'
|
|
775
|
+
return toString.call(val);
|
|
776
|
+
}
|
|
777
|
+
if (className == 'Object') {
|
|
778
|
+
// we're a user defined class or Object
|
|
779
|
+
// JSON.stringify avoids problems with cycles, and is generally much
|
|
780
|
+
// easier than looping through ownProperties of `val`.
|
|
781
|
+
try {
|
|
782
|
+
return 'Object(' + JSON.stringify(val) + ')';
|
|
783
|
+
} catch (_) {
|
|
784
|
+
return 'Object';
|
|
785
|
+
}
|
|
786
|
+
}
|
|
787
|
+
// errors
|
|
788
|
+
if (val instanceof Error) {
|
|
789
|
+
return `${val.name}: ${val.message}\n${val.stack}`;
|
|
790
|
+
}
|
|
791
|
+
// TODO we could test for more things here, like `Set`s and `Map`s.
|
|
792
|
+
return className;
|
|
793
|
+
}
|
|
794
|
+
|
|
795
|
+
function getArrayJsValueFromWasm0(ptr, len) {
|
|
796
|
+
ptr = ptr >>> 0;
|
|
797
|
+
const mem = getDataViewMemory0();
|
|
798
|
+
const result = [];
|
|
799
|
+
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
800
|
+
result.push(wasm.__wbindgen_externrefs.get(mem.getUint32(i, true)));
|
|
801
|
+
}
|
|
802
|
+
wasm.__externref_drop_slice(ptr, len);
|
|
803
|
+
return result;
|
|
804
|
+
}
|
|
805
|
+
|
|
806
|
+
function getArrayU8FromWasm0(ptr, len) {
|
|
807
|
+
ptr = ptr >>> 0;
|
|
808
|
+
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
809
|
+
}
|
|
810
|
+
|
|
811
|
+
let cachedDataViewMemory0 = null;
|
|
812
|
+
function getDataViewMemory0() {
|
|
813
|
+
if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
|
|
814
|
+
cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
|
|
815
|
+
}
|
|
816
|
+
return cachedDataViewMemory0;
|
|
817
|
+
}
|
|
818
|
+
|
|
819
|
+
function getStringFromWasm0(ptr, len) {
|
|
820
|
+
ptr = ptr >>> 0;
|
|
821
|
+
return decodeText(ptr, len);
|
|
822
|
+
}
|
|
823
|
+
|
|
824
|
+
let cachedUint8ArrayMemory0 = null;
|
|
825
|
+
function getUint8ArrayMemory0() {
|
|
826
|
+
if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
|
|
827
|
+
cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
|
|
828
|
+
}
|
|
829
|
+
return cachedUint8ArrayMemory0;
|
|
830
|
+
}
|
|
831
|
+
|
|
832
|
+
function handleError(f, args) {
|
|
833
|
+
try {
|
|
834
|
+
return f.apply(this, args);
|
|
835
|
+
} catch (e) {
|
|
836
|
+
const idx = addToExternrefTable0(e);
|
|
837
|
+
wasm.__wbindgen_exn_store(idx);
|
|
838
|
+
}
|
|
839
|
+
}
|
|
840
|
+
|
|
841
|
+
function isLikeNone(x) {
|
|
842
|
+
return x === undefined || x === null;
|
|
843
|
+
}
|
|
844
|
+
|
|
845
|
+
function passArrayJsValueToWasm0(array, malloc) {
|
|
846
|
+
const ptr = malloc(array.length * 4, 4) >>> 0;
|
|
847
|
+
for (let i = 0; i < array.length; i++) {
|
|
848
|
+
const add = addToExternrefTable0(array[i]);
|
|
849
|
+
getDataViewMemory0().setUint32(ptr + 4 * i, add, true);
|
|
850
|
+
}
|
|
851
|
+
WASM_VECTOR_LEN = array.length;
|
|
852
|
+
return ptr;
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
function passStringToWasm0(arg, malloc, realloc) {
|
|
856
|
+
if (realloc === undefined) {
|
|
857
|
+
const buf = cachedTextEncoder.encode(arg);
|
|
858
|
+
const ptr = malloc(buf.length, 1) >>> 0;
|
|
859
|
+
getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
|
|
860
|
+
WASM_VECTOR_LEN = buf.length;
|
|
861
|
+
return ptr;
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
let len = arg.length;
|
|
865
|
+
let ptr = malloc(len, 1) >>> 0;
|
|
866
|
+
|
|
867
|
+
const mem = getUint8ArrayMemory0();
|
|
868
|
+
|
|
869
|
+
let offset = 0;
|
|
870
|
+
|
|
871
|
+
for (; offset < len; offset++) {
|
|
872
|
+
const code = arg.charCodeAt(offset);
|
|
873
|
+
if (code > 0x7F) break;
|
|
874
|
+
mem[ptr + offset] = code;
|
|
875
|
+
}
|
|
876
|
+
if (offset !== len) {
|
|
877
|
+
if (offset !== 0) {
|
|
878
|
+
arg = arg.slice(offset);
|
|
879
|
+
}
|
|
880
|
+
ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
|
|
881
|
+
const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
|
|
882
|
+
const ret = cachedTextEncoder.encodeInto(arg, view);
|
|
883
|
+
|
|
884
|
+
offset += ret.written;
|
|
885
|
+
ptr = realloc(ptr, len, offset, 1) >>> 0;
|
|
886
|
+
}
|
|
887
|
+
|
|
888
|
+
WASM_VECTOR_LEN = offset;
|
|
889
|
+
return ptr;
|
|
890
|
+
}
|
|
891
|
+
|
|
892
|
+
function takeFromExternrefTable0(idx) {
|
|
893
|
+
const value = wasm.__wbindgen_externrefs.get(idx);
|
|
894
|
+
wasm.__externref_table_dealloc(idx);
|
|
895
|
+
return value;
|
|
896
|
+
}
|
|
897
|
+
|
|
898
|
+
let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
|
|
899
|
+
cachedTextDecoder.decode();
|
|
900
|
+
const MAX_SAFARI_DECODE_BYTES = 2146435072;
|
|
901
|
+
let numBytesDecoded = 0;
|
|
902
|
+
function decodeText(ptr, len) {
|
|
903
|
+
numBytesDecoded += len;
|
|
904
|
+
if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
|
|
905
|
+
cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
|
|
906
|
+
cachedTextDecoder.decode();
|
|
907
|
+
numBytesDecoded = len;
|
|
908
|
+
}
|
|
909
|
+
return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
|
|
910
|
+
}
|
|
911
|
+
|
|
912
|
+
const cachedTextEncoder = new TextEncoder();
|
|
913
|
+
|
|
914
|
+
if (!('encodeInto' in cachedTextEncoder)) {
|
|
915
|
+
cachedTextEncoder.encodeInto = function (arg, view) {
|
|
916
|
+
const buf = cachedTextEncoder.encode(arg);
|
|
917
|
+
view.set(buf);
|
|
918
|
+
return {
|
|
919
|
+
read: arg.length,
|
|
920
|
+
written: buf.length
|
|
921
|
+
};
|
|
922
|
+
};
|
|
923
|
+
}
|
|
924
|
+
|
|
925
|
+
let WASM_VECTOR_LEN = 0;
|
|
926
|
+
|
|
927
|
+
let wasmModule, wasm;
|
|
928
|
+
function __wbg_finalize_init(instance, module) {
|
|
929
|
+
wasm = instance.exports;
|
|
930
|
+
wasmModule = module;
|
|
931
|
+
cachedDataViewMemory0 = null;
|
|
932
|
+
cachedUint8ArrayMemory0 = null;
|
|
933
|
+
wasm.__wbindgen_start();
|
|
934
|
+
return wasm;
|
|
935
|
+
}
|
|
936
|
+
|
|
937
|
+
async function __wbg_load(module, imports) {
|
|
938
|
+
if (typeof Response === 'function' && module instanceof Response) {
|
|
939
|
+
if (typeof WebAssembly.instantiateStreaming === 'function') {
|
|
940
|
+
try {
|
|
941
|
+
return await WebAssembly.instantiateStreaming(module, imports);
|
|
942
|
+
} catch (e) {
|
|
943
|
+
const validResponse = module.ok && expectedResponseType(module.type);
|
|
944
|
+
|
|
945
|
+
if (validResponse && module.headers.get('Content-Type') !== 'application/wasm') {
|
|
946
|
+
console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n", e);
|
|
947
|
+
|
|
948
|
+
} else { throw e; }
|
|
949
|
+
}
|
|
950
|
+
}
|
|
951
|
+
|
|
952
|
+
const bytes = await module.arrayBuffer();
|
|
953
|
+
return await WebAssembly.instantiate(bytes, imports);
|
|
954
|
+
} else {
|
|
955
|
+
const instance = await WebAssembly.instantiate(module, imports);
|
|
956
|
+
|
|
957
|
+
if (instance instanceof WebAssembly.Instance) {
|
|
958
|
+
return { instance, module };
|
|
959
|
+
} else {
|
|
960
|
+
return instance;
|
|
961
|
+
}
|
|
962
|
+
}
|
|
963
|
+
|
|
964
|
+
function expectedResponseType(type) {
|
|
965
|
+
switch (type) {
|
|
966
|
+
case 'basic': case 'cors': case 'default': return true;
|
|
967
|
+
}
|
|
968
|
+
return false;
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
|
|
972
|
+
function initSync(module) {
|
|
973
|
+
if (wasm !== undefined) return wasm;
|
|
974
|
+
|
|
975
|
+
|
|
976
|
+
if (module !== undefined) {
|
|
977
|
+
if (Object.getPrototypeOf(module) === Object.prototype) {
|
|
978
|
+
({module} = module)
|
|
979
|
+
} else {
|
|
980
|
+
console.warn('using deprecated parameters for `initSync()`; pass a single object instead')
|
|
981
|
+
}
|
|
982
|
+
}
|
|
983
|
+
|
|
984
|
+
const imports = __wbg_get_imports();
|
|
985
|
+
if (!(module instanceof WebAssembly.Module)) {
|
|
986
|
+
module = new WebAssembly.Module(module);
|
|
987
|
+
}
|
|
988
|
+
const instance = new WebAssembly.Instance(module, imports);
|
|
989
|
+
return __wbg_finalize_init(instance, module);
|
|
990
|
+
}
|
|
991
|
+
|
|
992
|
+
async function __wbg_init(module_or_path) {
|
|
993
|
+
if (wasm !== undefined) return wasm;
|
|
994
|
+
|
|
995
|
+
|
|
996
|
+
if (module_or_path !== undefined) {
|
|
997
|
+
if (Object.getPrototypeOf(module_or_path) === Object.prototype) {
|
|
998
|
+
({module_or_path} = module_or_path)
|
|
999
|
+
} else {
|
|
1000
|
+
console.warn('using deprecated parameters for the initialization function; pass a single object instead')
|
|
1001
|
+
}
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
if (module_or_path === undefined) {
|
|
1005
|
+
module_or_path = new URL('logfire_sqlls_wasm_bg.wasm', import.meta.url);
|
|
1006
|
+
}
|
|
1007
|
+
const imports = __wbg_get_imports();
|
|
1008
|
+
|
|
1009
|
+
if (typeof module_or_path === 'string' || (typeof Request === 'function' && module_or_path instanceof Request) || (typeof URL === 'function' && module_or_path instanceof URL)) {
|
|
1010
|
+
module_or_path = fetch(module_or_path);
|
|
1011
|
+
}
|
|
1012
|
+
|
|
1013
|
+
const { instance, module } = await __wbg_load(await module_or_path, imports);
|
|
1014
|
+
|
|
1015
|
+
return __wbg_finalize_init(instance, module);
|
|
1016
|
+
}
|
|
1017
|
+
|
|
1018
|
+
export { initSync, __wbg_init as default };
|
|
Binary file
|
package/package.json
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@pydantic/logfire-sqlls",
|
|
3
|
+
"type": "module",
|
|
4
|
+
"version": "0.1.0",
|
|
5
|
+
"files": [
|
|
6
|
+
"logfire_sqlls_wasm_bg.wasm",
|
|
7
|
+
"logfire_sqlls_wasm.js",
|
|
8
|
+
"logfire_sqlls_wasm.d.ts"
|
|
9
|
+
],
|
|
10
|
+
"main": "logfire_sqlls_wasm.js",
|
|
11
|
+
"types": "logfire_sqlls_wasm.d.ts",
|
|
12
|
+
"sideEffects": [
|
|
13
|
+
"./snippets/*"
|
|
14
|
+
],
|
|
15
|
+
"license": "UNLICENSED"
|
|
16
|
+
}
|