import { __esmMin as e, __exportAll as t } from "../../../../_virtual/_rolldown/runtime.js";
//#region ../../node_modules/vscode-languageserver-types/lib/esm/main.js
var n = /* @__PURE__ */ t({
	AnnotatedTextEdit: () => S,
	ChangeAnnotation: () => b,
	ChangeAnnotationIdentifier: () => x,
	CodeAction: () => fe,
	CodeActionContext: () => de,
	CodeActionKind: () => ue,
	CodeActionTriggerKind: () => Y,
	CodeDescription: () => ne,
	CodeLens: () => pe,
	Color: () => d,
	ColorInformation: () => f,
	ColorPresentation: () => p,
	Command: () => v,
	CompletionItem: () => B,
	CompletionItemKind: () => P,
	CompletionItemLabelDetails: () => z,
	CompletionItemTag: () => I,
	CompletionList: () => V,
	CreateFile: () => w,
	DeleteFile: () => E,
	Diagnostic: () => _,
	DiagnosticRelatedInformation: () => m,
	DiagnosticSeverity: () => h,
	DiagnosticTag: () => g,
	DocumentHighlight: () => q,
	DocumentHighlightKind: () => K,
	DocumentLink: () => he,
	DocumentSymbol: () => le,
	DocumentUri: () => r,
	EOL: () => je,
	FoldingRange: () => te,
	FoldingRangeKind: () => ee,
	FormattingOptions: () => me,
	Hover: () => U,
	InlayHint: () => we,
	InlayHintKind: () => X,
	InlayHintLabelPart: () => Z,
	InlineCompletionContext: () => ke,
	InlineCompletionItem: () => Ee,
	InlineCompletionList: () => De,
	InlineCompletionTriggerKind: () => Oe,
	InlineValueContext: () => Ce,
	InlineValueEvaluatableExpression: () => Se,
	InlineValueText: () => be,
	InlineValueVariableLookup: () => xe,
	InsertReplaceEdit: () => L,
	InsertTextFormat: () => F,
	InsertTextMode: () => R,
	Location: () => l,
	LocationLink: () => u,
	MarkedString: () => H,
	MarkupContent: () => N,
	MarkupKind: () => M,
	OptionalVersionedTextDocumentIdentifier: () => A,
	ParameterInformation: () => W,
	Position: () => s,
	Range: () => c,
	RenameFile: () => T,
	SelectedCompletionInfo: () => Q,
	SelectionRange: () => ge,
	SemanticTokenModifiers: () => ve,
	SemanticTokenTypes: () => _e,
	SemanticTokens: () => ye,
	SignatureInformation: () => G,
	StringValue: () => Te,
	SymbolInformation: () => se,
	SymbolKind: () => J,
	SymbolTag: () => oe,
	TextDocument: () => Me,
	TextDocumentEdit: () => C,
	TextDocumentIdentifier: () => ie,
	TextDocumentItem: () => j,
	TextEdit: () => y,
	URI: () => i,
	VersionedTextDocumentIdentifier: () => ae,
	WorkspaceChange: () => re,
	WorkspaceEdit: () => D,
	WorkspaceFolder: () => Ae,
	WorkspaceSymbol: () => ce,
	integer: () => a,
	uinteger: () => o
}), r, i, a, o, s, c, l, u, d, f, p, ee, te, m, h, g, ne, _, v, y, b, x, S, C, w, T, E, D, O, k, re, ie, ae, A, j, M, N, P, F, I, L, R, z, B, V, H, U, W, G, K, q, J, oe, se, ce, le, ue, Y, de, fe, pe, me, he, ge, _e, ve, ye, be, xe, Se, Ce, X, Z, we, Te, Ee, De, Oe, Q, ke, Ae, je, Me, Ne, $, Pe = e((() => {
	(function(e) {
		function t(e) {
			return typeof e == "string";
		}
		e.is = t;
	})(r ||= {}), (function(e) {
		function t(e) {
			return typeof e == "string";
		}
		e.is = t;
	})(i ||= {}), (function(e) {
		e.MIN_VALUE = -2147483648, e.MAX_VALUE = 2147483647;
		function t(t) {
			return typeof t == "number" && e.MIN_VALUE <= t && t <= e.MAX_VALUE;
		}
		e.is = t;
	})(a ||= {}), (function(e) {
		e.MIN_VALUE = 0, e.MAX_VALUE = 2147483647;
		function t(t) {
			return typeof t == "number" && e.MIN_VALUE <= t && t <= e.MAX_VALUE;
		}
		e.is = t;
	})(o ||= {}), (function(e) {
		function t(e, t) {
			return e === Number.MAX_VALUE && (e = o.MAX_VALUE), t === Number.MAX_VALUE && (t = o.MAX_VALUE), {
				line: e,
				character: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && $.uinteger(t.line) && $.uinteger(t.character);
		}
		e.is = n;
	})(s ||= {}), (function(e) {
		function t(e, t, n, r) {
			if ($.uinteger(e) && $.uinteger(t) && $.uinteger(n) && $.uinteger(r)) return {
				start: s.create(e, t),
				end: s.create(n, r)
			};
			if (s.is(e) && s.is(t)) return {
				start: e,
				end: t
			};
			throw Error(`Range#create called with invalid arguments[${e}, ${t}, ${n}, ${r}]`);
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && s.is(t.start) && s.is(t.end);
		}
		e.is = n;
	})(c ||= {}), (function(e) {
		function t(e, t) {
			return {
				uri: e,
				range: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && c.is(t.range) && ($.string(t.uri) || $.undefined(t.uri));
		}
		e.is = n;
	})(l ||= {}), (function(e) {
		function t(e, t, n, r) {
			return {
				targetUri: e,
				targetRange: t,
				targetSelectionRange: n,
				originSelectionRange: r
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && c.is(t.targetRange) && $.string(t.targetUri) && c.is(t.targetSelectionRange) && (c.is(t.originSelectionRange) || $.undefined(t.originSelectionRange));
		}
		e.is = n;
	})(u ||= {}), (function(e) {
		function t(e, t, n, r) {
			return {
				red: e,
				green: t,
				blue: n,
				alpha: r
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && $.numberRange(t.red, 0, 1) && $.numberRange(t.green, 0, 1) && $.numberRange(t.blue, 0, 1) && $.numberRange(t.alpha, 0, 1);
		}
		e.is = n;
	})(d ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				color: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && c.is(t.range) && d.is(t.color);
		}
		e.is = n;
	})(f ||= {}), (function(e) {
		function t(e, t, n) {
			return {
				label: e,
				textEdit: t,
				additionalTextEdits: n
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && $.string(t.label) && ($.undefined(t.textEdit) || y.is(t)) && ($.undefined(t.additionalTextEdits) || $.typedArray(t.additionalTextEdits, y.is));
		}
		e.is = n;
	})(p ||= {}), (function(e) {
		e.Comment = "comment", e.Imports = "imports", e.Region = "region";
	})(ee ||= {}), (function(e) {
		function t(e, t, n, r, i, a) {
			let o = {
				startLine: e,
				endLine: t
			};
			return $.defined(n) && (o.startCharacter = n), $.defined(r) && (o.endCharacter = r), $.defined(i) && (o.kind = i), $.defined(a) && (o.collapsedText = a), o;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && $.uinteger(t.startLine) && $.uinteger(t.startLine) && ($.undefined(t.startCharacter) || $.uinteger(t.startCharacter)) && ($.undefined(t.endCharacter) || $.uinteger(t.endCharacter)) && ($.undefined(t.kind) || $.string(t.kind));
		}
		e.is = n;
	})(te ||= {}), (function(e) {
		function t(e, t) {
			return {
				location: e,
				message: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && l.is(t.location) && $.string(t.message);
		}
		e.is = n;
	})(m ||= {}), (function(e) {
		e.Error = 1, e.Warning = 2, e.Information = 3, e.Hint = 4;
	})(h ||= {}), (function(e) {
		e.Unnecessary = 1, e.Deprecated = 2;
	})(g ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return $.objectLiteral(t) && $.string(t.href);
		}
		e.is = t;
	})(ne ||= {}), (function(e) {
		function t(e, t, n, r, i, a) {
			let o = {
				range: e,
				message: t
			};
			return $.defined(n) && (o.severity = n), $.defined(r) && (o.code = r), $.defined(i) && (o.source = i), $.defined(a) && (o.relatedInformation = a), o;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && c.is(t.range) && $.string(t.message) && ($.number(t.severity) || $.undefined(t.severity)) && ($.integer(t.code) || $.string(t.code) || $.undefined(t.code)) && ($.undefined(t.codeDescription) || $.string(t.codeDescription?.href)) && ($.string(t.source) || $.undefined(t.source)) && ($.undefined(t.relatedInformation) || $.typedArray(t.relatedInformation, m.is));
		}
		e.is = n;
	})(_ ||= {}), (function(e) {
		function t(e, t, ...n) {
			let r = {
				title: e,
				command: t
			};
			return $.defined(n) && n.length > 0 && (r.arguments = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.string(t.title) && $.string(t.command);
		}
		e.is = n;
	})(v ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				newText: t
			};
		}
		e.replace = t;
		function n(e, t) {
			return {
				range: {
					start: e,
					end: e
				},
				newText: t
			};
		}
		e.insert = n;
		function r(e) {
			return {
				range: e,
				newText: ""
			};
		}
		e.del = r;
		function i(e) {
			let t = e;
			return $.objectLiteral(t) && $.string(t.newText) && c.is(t.range);
		}
		e.is = i;
	})(y ||= {}), (function(e) {
		function t(e, t, n) {
			let r = { label: e };
			return t !== void 0 && (r.needsConfirmation = t), n !== void 0 && (r.description = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && $.string(t.label) && ($.boolean(t.needsConfirmation) || t.needsConfirmation === void 0) && ($.string(t.description) || t.description === void 0);
		}
		e.is = n;
	})(b ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return $.string(t);
		}
		e.is = t;
	})(x ||= {}), (function(e) {
		function t(e, t, n) {
			return {
				range: e,
				newText: t,
				annotationId: n
			};
		}
		e.replace = t;
		function n(e, t, n) {
			return {
				range: {
					start: e,
					end: e
				},
				newText: t,
				annotationId: n
			};
		}
		e.insert = n;
		function r(e, t) {
			return {
				range: e,
				newText: "",
				annotationId: t
			};
		}
		e.del = r;
		function i(e) {
			let t = e;
			return y.is(t) && (b.is(t.annotationId) || x.is(t.annotationId));
		}
		e.is = i;
	})(S ||= {}), (function(e) {
		function t(e, t) {
			return {
				textDocument: e,
				edits: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && A.is(t.textDocument) && Array.isArray(t.edits);
		}
		e.is = n;
	})(C ||= {}), (function(e) {
		function t(e, t, n) {
			let r = {
				kind: "create",
				uri: e
			};
			return t !== void 0 && (t.overwrite !== void 0 || t.ignoreIfExists !== void 0) && (r.options = t), n !== void 0 && (r.annotationId = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && t.kind === "create" && $.string(t.uri) && (t.options === void 0 || (t.options.overwrite === void 0 || $.boolean(t.options.overwrite)) && (t.options.ignoreIfExists === void 0 || $.boolean(t.options.ignoreIfExists))) && (t.annotationId === void 0 || x.is(t.annotationId));
		}
		e.is = n;
	})(w ||= {}), (function(e) {
		function t(e, t, n, r) {
			let i = {
				kind: "rename",
				oldUri: e,
				newUri: t
			};
			return n !== void 0 && (n.overwrite !== void 0 || n.ignoreIfExists !== void 0) && (i.options = n), r !== void 0 && (i.annotationId = r), i;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && t.kind === "rename" && $.string(t.oldUri) && $.string(t.newUri) && (t.options === void 0 || (t.options.overwrite === void 0 || $.boolean(t.options.overwrite)) && (t.options.ignoreIfExists === void 0 || $.boolean(t.options.ignoreIfExists))) && (t.annotationId === void 0 || x.is(t.annotationId));
		}
		e.is = n;
	})(T ||= {}), (function(e) {
		function t(e, t, n) {
			let r = {
				kind: "delete",
				uri: e
			};
			return t !== void 0 && (t.recursive !== void 0 || t.ignoreIfNotExists !== void 0) && (r.options = t), n !== void 0 && (r.annotationId = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && t.kind === "delete" && $.string(t.uri) && (t.options === void 0 || (t.options.recursive === void 0 || $.boolean(t.options.recursive)) && (t.options.ignoreIfNotExists === void 0 || $.boolean(t.options.ignoreIfNotExists))) && (t.annotationId === void 0 || x.is(t.annotationId));
		}
		e.is = n;
	})(E ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return t && (t.changes !== void 0 || t.documentChanges !== void 0) && (t.documentChanges === void 0 || t.documentChanges.every((e) => $.string(e.kind) ? w.is(e) || T.is(e) || E.is(e) : C.is(e)));
		}
		e.is = t;
	})(D ||= {}), O = class {
		constructor(e, t) {
			this.edits = e, this.changeAnnotations = t;
		}
		insert(e, t, n) {
			let r, i;
			if (n === void 0 ? r = y.insert(e, t) : x.is(n) ? (i = n, r = S.insert(e, t, n)) : (this.assertChangeAnnotations(this.changeAnnotations), i = this.changeAnnotations.manage(n), r = S.insert(e, t, i)), this.edits.push(r), i !== void 0) return i;
		}
		replace(e, t, n) {
			let r, i;
			if (n === void 0 ? r = y.replace(e, t) : x.is(n) ? (i = n, r = S.replace(e, t, n)) : (this.assertChangeAnnotations(this.changeAnnotations), i = this.changeAnnotations.manage(n), r = S.replace(e, t, i)), this.edits.push(r), i !== void 0) return i;
		}
		delete(e, t) {
			let n, r;
			if (t === void 0 ? n = y.del(e) : x.is(t) ? (r = t, n = S.del(e, t)) : (this.assertChangeAnnotations(this.changeAnnotations), r = this.changeAnnotations.manage(t), n = S.del(e, r)), this.edits.push(n), r !== void 0) return r;
		}
		add(e) {
			this.edits.push(e);
		}
		all() {
			return this.edits;
		}
		clear() {
			this.edits.splice(0, this.edits.length);
		}
		assertChangeAnnotations(e) {
			if (e === void 0) throw Error("Text edit change is not configured to manage change annotations.");
		}
	}, k = class {
		constructor(e) {
			this._annotations = e === void 0 ? Object.create(null) : e, this._counter = 0, this._size = 0;
		}
		all() {
			return this._annotations;
		}
		get size() {
			return this._size;
		}
		manage(e, t) {
			let n;
			if (x.is(e) ? n = e : (n = this.nextId(), t = e), this._annotations[n] !== void 0) throw Error(`Id ${n} is already in use.`);
			if (t === void 0) throw Error(`No annotation provided for id ${n}`);
			return this._annotations[n] = t, this._size++, n;
		}
		nextId() {
			return this._counter++, this._counter.toString();
		}
	}, re = class {
		constructor(e) {
			this._textEditChanges = Object.create(null), e === void 0 ? this._workspaceEdit = {} : (this._workspaceEdit = e, e.documentChanges ? (this._changeAnnotations = new k(e.changeAnnotations), e.changeAnnotations = this._changeAnnotations.all(), e.documentChanges.forEach((e) => {
				if (C.is(e)) {
					let t = new O(e.edits, this._changeAnnotations);
					this._textEditChanges[e.textDocument.uri] = t;
				}
			})) : e.changes && Object.keys(e.changes).forEach((t) => {
				let n = new O(e.changes[t]);
				this._textEditChanges[t] = n;
			}));
		}
		get edit() {
			return this.initDocumentChanges(), this._changeAnnotations !== void 0 && (this._changeAnnotations.size === 0 ? this._workspaceEdit.changeAnnotations = void 0 : this._workspaceEdit.changeAnnotations = this._changeAnnotations.all()), this._workspaceEdit;
		}
		getTextEditChange(e) {
			if (A.is(e)) {
				if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0) throw Error("Workspace edit is not configured for document changes.");
				let t = {
					uri: e.uri,
					version: e.version
				}, n = this._textEditChanges[t.uri];
				if (!n) {
					let e = [], r = {
						textDocument: t,
						edits: e
					};
					this._workspaceEdit.documentChanges.push(r), n = new O(e, this._changeAnnotations), this._textEditChanges[t.uri] = n;
				}
				return n;
			} else {
				if (this.initChanges(), this._workspaceEdit.changes === void 0) throw Error("Workspace edit is not configured for normal text edit changes.");
				let t = this._textEditChanges[e];
				if (!t) {
					let n = [];
					this._workspaceEdit.changes[e] = n, t = new O(n), this._textEditChanges[e] = t;
				}
				return t;
			}
		}
		initDocumentChanges() {
			this._workspaceEdit.documentChanges === void 0 && this._workspaceEdit.changes === void 0 && (this._changeAnnotations = new k(), this._workspaceEdit.documentChanges = [], this._workspaceEdit.changeAnnotations = this._changeAnnotations.all());
		}
		initChanges() {
			this._workspaceEdit.documentChanges === void 0 && this._workspaceEdit.changes === void 0 && (this._workspaceEdit.changes = Object.create(null));
		}
		createFile(e, t, n) {
			if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0) throw Error("Workspace edit is not configured for document changes.");
			let r;
			b.is(t) || x.is(t) ? r = t : n = t;
			let i, a;
			if (r === void 0 ? i = w.create(e, n) : (a = x.is(r) ? r : this._changeAnnotations.manage(r), i = w.create(e, n, a)), this._workspaceEdit.documentChanges.push(i), a !== void 0) return a;
		}
		renameFile(e, t, n, r) {
			if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0) throw Error("Workspace edit is not configured for document changes.");
			let i;
			b.is(n) || x.is(n) ? i = n : r = n;
			let a, o;
			if (i === void 0 ? a = T.create(e, t, r) : (o = x.is(i) ? i : this._changeAnnotations.manage(i), a = T.create(e, t, r, o)), this._workspaceEdit.documentChanges.push(a), o !== void 0) return o;
		}
		deleteFile(e, t, n) {
			if (this.initDocumentChanges(), this._workspaceEdit.documentChanges === void 0) throw Error("Workspace edit is not configured for document changes.");
			let r;
			b.is(t) || x.is(t) ? r = t : n = t;
			let i, a;
			if (r === void 0 ? i = E.create(e, n) : (a = x.is(r) ? r : this._changeAnnotations.manage(r), i = E.create(e, n, a)), this._workspaceEdit.documentChanges.push(i), a !== void 0) return a;
		}
	}, (function(e) {
		function t(e) {
			return { uri: e };
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.string(t.uri);
		}
		e.is = n;
	})(ie ||= {}), (function(e) {
		function t(e, t) {
			return {
				uri: e,
				version: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.string(t.uri) && $.integer(t.version);
		}
		e.is = n;
	})(ae ||= {}), (function(e) {
		function t(e, t) {
			return {
				uri: e,
				version: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.string(t.uri) && (t.version === null || $.integer(t.version));
		}
		e.is = n;
	})(A ||= {}), (function(e) {
		function t(e, t, n, r) {
			return {
				uri: e,
				languageId: t,
				version: n,
				text: r
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.string(t.uri) && $.string(t.languageId) && $.integer(t.version) && $.string(t.text);
		}
		e.is = n;
	})(j ||= {}), (function(e) {
		e.PlainText = "plaintext", e.Markdown = "markdown";
		function t(t) {
			let n = t;
			return n === e.PlainText || n === e.Markdown;
		}
		e.is = t;
	})(M ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return $.objectLiteral(e) && M.is(t.kind) && $.string(t.value);
		}
		e.is = t;
	})(N ||= {}), (function(e) {
		e.Text = 1, e.Method = 2, e.Function = 3, e.Constructor = 4, e.Field = 5, e.Variable = 6, e.Class = 7, e.Interface = 8, e.Module = 9, e.Property = 10, e.Unit = 11, e.Value = 12, e.Enum = 13, e.Keyword = 14, e.Snippet = 15, e.Color = 16, e.File = 17, e.Reference = 18, e.Folder = 19, e.EnumMember = 20, e.Constant = 21, e.Struct = 22, e.Event = 23, e.Operator = 24, e.TypeParameter = 25;
	})(P ||= {}), (function(e) {
		e.PlainText = 1, e.Snippet = 2;
	})(F ||= {}), (function(e) {
		e.Deprecated = 1;
	})(I ||= {}), (function(e) {
		function t(e, t, n) {
			return {
				newText: e,
				insert: t,
				replace: n
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && $.string(t.newText) && c.is(t.insert) && c.is(t.replace);
		}
		e.is = n;
	})(L ||= {}), (function(e) {
		e.asIs = 1, e.adjustIndentation = 2;
	})(R ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return t && ($.string(t.detail) || t.detail === void 0) && ($.string(t.description) || t.description === void 0);
		}
		e.is = t;
	})(z ||= {}), (function(e) {
		function t(e) {
			return { label: e };
		}
		e.create = t;
	})(B ||= {}), (function(e) {
		function t(e, t) {
			return {
				items: e || [],
				isIncomplete: !!t
			};
		}
		e.create = t;
	})(V ||= {}), (function(e) {
		function t(e) {
			return e.replace(/[\\`*_{}[\]()#+\-.!]/g, "\\$&");
		}
		e.fromPlainText = t;
		function n(e) {
			let t = e;
			return $.string(t) || $.objectLiteral(t) && $.string(t.language) && $.string(t.value);
		}
		e.is = n;
	})(H ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return !!t && $.objectLiteral(t) && (N.is(t.contents) || H.is(t.contents) || $.typedArray(t.contents, H.is)) && (e.range === void 0 || c.is(e.range));
		}
		e.is = t;
	})(U ||= {}), (function(e) {
		function t(e, t) {
			return t ? {
				label: e,
				documentation: t
			} : { label: e };
		}
		e.create = t;
	})(W ||= {}), (function(e) {
		function t(e, t, ...n) {
			let r = { label: e };
			return $.defined(t) && (r.documentation = t), $.defined(n) ? r.parameters = n : r.parameters = [], r;
		}
		e.create = t;
	})(G ||= {}), (function(e) {
		e.Text = 1, e.Read = 2, e.Write = 3;
	})(K ||= {}), (function(e) {
		function t(e, t) {
			let n = { range: e };
			return $.number(t) && (n.kind = t), n;
		}
		e.create = t;
	})(q ||= {}), (function(e) {
		e.File = 1, e.Module = 2, e.Namespace = 3, e.Package = 4, e.Class = 5, e.Method = 6, e.Property = 7, e.Field = 8, e.Constructor = 9, e.Enum = 10, e.Interface = 11, e.Function = 12, e.Variable = 13, e.Constant = 14, e.String = 15, e.Number = 16, e.Boolean = 17, e.Array = 18, e.Object = 19, e.Key = 20, e.Null = 21, e.EnumMember = 22, e.Struct = 23, e.Event = 24, e.Operator = 25, e.TypeParameter = 26;
	})(J ||= {}), (function(e) {
		e.Deprecated = 1;
	})(oe ||= {}), (function(e) {
		function t(e, t, n, r, i) {
			let a = {
				name: e,
				kind: t,
				location: {
					uri: r,
					range: n
				}
			};
			return i && (a.containerName = i), a;
		}
		e.create = t;
	})(se ||= {}), (function(e) {
		function t(e, t, n, r) {
			return r === void 0 ? {
				name: e,
				kind: t,
				location: { uri: n }
			} : {
				name: e,
				kind: t,
				location: {
					uri: n,
					range: r
				}
			};
		}
		e.create = t;
	})(ce ||= {}), (function(e) {
		function t(e, t, n, r, i, a) {
			let o = {
				name: e,
				detail: t,
				kind: n,
				range: r,
				selectionRange: i
			};
			return a !== void 0 && (o.children = a), o;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && $.string(t.name) && $.number(t.kind) && c.is(t.range) && c.is(t.selectionRange) && (t.detail === void 0 || $.string(t.detail)) && (t.deprecated === void 0 || $.boolean(t.deprecated)) && (t.children === void 0 || Array.isArray(t.children)) && (t.tags === void 0 || Array.isArray(t.tags));
		}
		e.is = n;
	})(le ||= {}), (function(e) {
		e.Empty = "", e.QuickFix = "quickfix", e.Refactor = "refactor", e.RefactorExtract = "refactor.extract", e.RefactorInline = "refactor.inline", e.RefactorRewrite = "refactor.rewrite", e.Source = "source", e.SourceOrganizeImports = "source.organizeImports", e.SourceFixAll = "source.fixAll";
	})(ue ||= {}), (function(e) {
		e.Invoked = 1, e.Automatic = 2;
	})(Y ||= {}), (function(e) {
		function t(e, t, n) {
			let r = { diagnostics: e };
			return t != null && (r.only = t), n != null && (r.triggerKind = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.typedArray(t.diagnostics, _.is) && (t.only === void 0 || $.typedArray(t.only, $.string)) && (t.triggerKind === void 0 || t.triggerKind === Y.Invoked || t.triggerKind === Y.Automatic);
		}
		e.is = n;
	})(de ||= {}), (function(e) {
		function t(e, t, n) {
			let r = { title: e }, i = !0;
			return typeof t == "string" ? (i = !1, r.kind = t) : v.is(t) ? r.command = t : r.edit = t, i && n !== void 0 && (r.kind = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t && $.string(t.title) && (t.diagnostics === void 0 || $.typedArray(t.diagnostics, _.is)) && (t.kind === void 0 || $.string(t.kind)) && (t.edit !== void 0 || t.command !== void 0) && (t.command === void 0 || v.is(t.command)) && (t.isPreferred === void 0 || $.boolean(t.isPreferred)) && (t.edit === void 0 || D.is(t.edit));
		}
		e.is = n;
	})(fe ||= {}), (function(e) {
		function t(e, t) {
			let n = { range: e };
			return $.defined(t) && (n.data = t), n;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && c.is(t.range) && ($.undefined(t.command) || v.is(t.command));
		}
		e.is = n;
	})(pe ||= {}), (function(e) {
		function t(e, t) {
			return {
				tabSize: e,
				insertSpaces: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && $.uinteger(t.tabSize) && $.boolean(t.insertSpaces);
		}
		e.is = n;
	})(me ||= {}), (function(e) {
		function t(e, t, n) {
			return {
				range: e,
				target: t,
				data: n
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && c.is(t.range) && ($.undefined(t.target) || $.string(t.target));
		}
		e.is = n;
	})(he ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				parent: t
			};
		}
		e.create = t;
		function n(t) {
			let n = t;
			return $.objectLiteral(n) && c.is(n.range) && (n.parent === void 0 || e.is(n.parent));
		}
		e.is = n;
	})(ge ||= {}), (function(e) {
		e.namespace = "namespace", e.type = "type", e.class = "class", e.enum = "enum", e.interface = "interface", e.struct = "struct", e.typeParameter = "typeParameter", e.parameter = "parameter", e.variable = "variable", e.property = "property", e.enumMember = "enumMember", e.event = "event", e.function = "function", e.method = "method", e.macro = "macro", e.keyword = "keyword", e.modifier = "modifier", e.comment = "comment", e.string = "string", e.number = "number", e.regexp = "regexp", e.operator = "operator", e.decorator = "decorator";
	})(_e ||= {}), (function(e) {
		e.declaration = "declaration", e.definition = "definition", e.readonly = "readonly", e.static = "static", e.deprecated = "deprecated", e.abstract = "abstract", e.async = "async", e.modification = "modification", e.documentation = "documentation", e.defaultLibrary = "defaultLibrary";
	})(ve ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return $.objectLiteral(t) && (t.resultId === void 0 || typeof t.resultId == "string") && Array.isArray(t.data) && (t.data.length === 0 || typeof t.data[0] == "number");
		}
		e.is = t;
	})(ye ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				text: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t != null && c.is(t.range) && $.string(t.text);
		}
		e.is = n;
	})(be ||= {}), (function(e) {
		function t(e, t, n) {
			return {
				range: e,
				variableName: t,
				caseSensitiveLookup: n
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t != null && c.is(t.range) && $.boolean(t.caseSensitiveLookup) && ($.string(t.variableName) || t.variableName === void 0);
		}
		e.is = n;
	})(xe ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				expression: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return t != null && c.is(t.range) && ($.string(t.expression) || t.expression === void 0);
		}
		e.is = n;
	})(Se ||= {}), (function(e) {
		function t(e, t) {
			return {
				frameId: e,
				stoppedLocation: t
			};
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.defined(t) && c.is(e.stoppedLocation);
		}
		e.is = n;
	})(Ce ||= {}), (function(e) {
		e.Type = 1, e.Parameter = 2;
		function t(e) {
			return e === 1 || e === 2;
		}
		e.is = t;
	})(X ||= {}), (function(e) {
		function t(e) {
			return { value: e };
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && (t.tooltip === void 0 || $.string(t.tooltip) || N.is(t.tooltip)) && (t.location === void 0 || l.is(t.location)) && (t.command === void 0 || v.is(t.command));
		}
		e.is = n;
	})(Z ||= {}), (function(e) {
		function t(e, t, n) {
			let r = {
				position: e,
				label: t
			};
			return n !== void 0 && (r.kind = n), r;
		}
		e.create = t;
		function n(e) {
			let t = e;
			return $.objectLiteral(t) && s.is(t.position) && ($.string(t.label) || $.typedArray(t.label, Z.is)) && (t.kind === void 0 || X.is(t.kind)) && t.textEdits === void 0 || $.typedArray(t.textEdits, y.is) && (t.tooltip === void 0 || $.string(t.tooltip) || N.is(t.tooltip)) && (t.paddingLeft === void 0 || $.boolean(t.paddingLeft)) && (t.paddingRight === void 0 || $.boolean(t.paddingRight));
		}
		e.is = n;
	})(we ||= {}), (function(e) {
		function t(e) {
			return {
				kind: "snippet",
				value: e
			};
		}
		e.createSnippet = t;
	})(Te ||= {}), (function(e) {
		function t(e, t, n, r) {
			return {
				insertText: e,
				filterText: t,
				range: n,
				command: r
			};
		}
		e.create = t;
	})(Ee ||= {}), (function(e) {
		function t(e) {
			return { items: e };
		}
		e.create = t;
	})(De ||= {}), (function(e) {
		e.Invoked = 0, e.Automatic = 1;
	})(Oe ||= {}), (function(e) {
		function t(e, t) {
			return {
				range: e,
				text: t
			};
		}
		e.create = t;
	})(Q ||= {}), (function(e) {
		function t(e, t) {
			return {
				triggerKind: e,
				selectedCompletionInfo: t
			};
		}
		e.create = t;
	})(ke ||= {}), (function(e) {
		function t(e) {
			let t = e;
			return $.objectLiteral(t) && i.is(t.uri) && $.string(t.name);
		}
		e.is = t;
	})(Ae ||= {}), je = [
		"\n",
		"\r\n",
		"\r"
	], (function(e) {
		function t(e, t, n, r) {
			return new Ne(e, t, n, r);
		}
		e.create = t;
		function n(e) {
			let t = e;
			return !!($.defined(t) && $.string(t.uri) && ($.undefined(t.languageId) || $.string(t.languageId)) && $.uinteger(t.lineCount) && $.func(t.getText) && $.func(t.positionAt) && $.func(t.offsetAt));
		}
		e.is = n;
		function r(e, t) {
			let n = e.getText(), r = i(t, (e, t) => {
				let n = e.range.start.line - t.range.start.line;
				return n === 0 ? e.range.start.character - t.range.start.character : n;
			}), a = n.length;
			for (let t = r.length - 1; t >= 0; t--) {
				let i = r[t], o = e.offsetAt(i.range.start), s = e.offsetAt(i.range.end);
				if (s <= a) n = n.substring(0, o) + i.newText + n.substring(s, n.length);
				else throw Error("Overlapping edit");
				a = o;
			}
			return n;
		}
		e.applyEdits = r;
		function i(e, t) {
			if (e.length <= 1) return e;
			let n = e.length / 2 | 0, r = e.slice(0, n), a = e.slice(n);
			i(r, t), i(a, t);
			let o = 0, s = 0, c = 0;
			for (; o < r.length && s < a.length;) t(r[o], a[s]) <= 0 ? e[c++] = r[o++] : e[c++] = a[s++];
			for (; o < r.length;) e[c++] = r[o++];
			for (; s < a.length;) e[c++] = a[s++];
			return e;
		}
	})(Me ||= {}), Ne = class {
		constructor(e, t, n, r) {
			this._uri = e, this._languageId = t, this._version = n, this._content = r, this._lineOffsets = void 0;
		}
		get uri() {
			return this._uri;
		}
		get languageId() {
			return this._languageId;
		}
		get version() {
			return this._version;
		}
		getText(e) {
			if (e) {
				let t = this.offsetAt(e.start), n = this.offsetAt(e.end);
				return this._content.substring(t, n);
			}
			return this._content;
		}
		update(e, t) {
			this._content = e.text, this._version = t, this._lineOffsets = void 0;
		}
		getLineOffsets() {
			if (this._lineOffsets === void 0) {
				let e = [], t = this._content, n = !0;
				for (let r = 0; r < t.length; r++) {
					n &&= (e.push(r), !1);
					let i = t.charAt(r);
					n = i === "\r" || i === "\n", i === "\r" && r + 1 < t.length && t.charAt(r + 1) === "\n" && r++;
				}
				n && t.length > 0 && e.push(t.length), this._lineOffsets = e;
			}
			return this._lineOffsets;
		}
		positionAt(e) {
			e = Math.max(Math.min(e, this._content.length), 0);
			let t = this.getLineOffsets(), n = 0, r = t.length;
			if (r === 0) return s.create(0, e);
			for (; n < r;) {
				let i = Math.floor((n + r) / 2);
				t[i] > e ? r = i : n = i + 1;
			}
			let i = n - 1;
			return s.create(i, e - t[i]);
		}
		offsetAt(e) {
			let t = this.getLineOffsets();
			if (e.line >= t.length) return this._content.length;
			if (e.line < 0) return 0;
			let n = t[e.line], r = e.line + 1 < t.length ? t[e.line + 1] : this._content.length;
			return Math.max(Math.min(n + e.character, r), n);
		}
		get lineCount() {
			return this.getLineOffsets().length;
		}
	}, (function(e) {
		let t = Object.prototype.toString;
		function n(e) {
			return e !== void 0;
		}
		e.defined = n;
		function r(e) {
			return e === void 0;
		}
		e.undefined = r;
		function i(e) {
			return e === !0 || e === !1;
		}
		e.boolean = i;
		function a(e) {
			return t.call(e) === "[object String]";
		}
		e.string = a;
		function o(e) {
			return t.call(e) === "[object Number]";
		}
		e.number = o;
		function s(e, n, r) {
			return t.call(e) === "[object Number]" && n <= e && e <= r;
		}
		e.numberRange = s;
		function c(e) {
			return t.call(e) === "[object Number]" && -2147483648 <= e && e <= 2147483647;
		}
		e.integer = c;
		function l(e) {
			return t.call(e) === "[object Number]" && 0 <= e && e <= 2147483647;
		}
		e.uinteger = l;
		function u(e) {
			return t.call(e) === "[object Function]";
		}
		e.func = u;
		function d(e) {
			return typeof e == "object" && !!e;
		}
		e.objectLiteral = d;
		function f(e, t) {
			return Array.isArray(e) && e.every(t);
		}
		e.typedArray = f;
	})($ ||= {});
}));
//#endregion
Pe();
export { s as Position, c as Range, Pe as init_main, n as main_exports };
