diff --git a/Sources/hylo-lsp/DocumentProvider.swift b/Sources/hylo-lsp/DocumentProvider.swift index 93d03d6..095d9e1 100644 --- a/Sources/hylo-lsp/DocumentProvider.swift +++ b/Sources/hylo-lsp/DocumentProvider.swift @@ -137,10 +137,10 @@ actor DocumentProvider { return resolveDocumentUrl(uri).absoluteString } - public func preloadDocument(_ textDocument: TextDocumentProtocol) -> DocumentBuildRequest { - let uri = DocumentProvider.resolveDocumentUri(textDocument.uri) - return preloadDocument(uri) - } + // public func preloadDocument(_ textDocument: TextDocumentProtocol) -> DocumentBuildRequest { + // let uri = DocumentProvider.resolveDocumentUri(textDocument.uri) + // return preloadDocument(uri) + // } private func preloadDocument(_ uri: DocumentUri) -> DocumentBuildRequest { let document = requestDocument(uri) diff --git a/Sources/hylo-lsp/HyloServer.swift b/Sources/hylo-lsp/HyloServer.swift index 4b9bd64..e2539e7 100644 --- a/Sources/hylo-lsp/HyloServer.swift +++ b/Sources/hylo-lsp/HyloServer.swift @@ -66,11 +66,12 @@ public struct HyloNotificationHandler : NotificationHandler { public func textDocumentDidOpen(_ params: TextDocumentDidOpenParams) async { - _ = await state.documentProvider.preloadDocument(params.textDocument) + // _ = await state.documentProvider.preloadDocument(params.textDocument) } public func textDocumentDidChange(_ params: TextDocumentDidChangeParams) async { - _ = await state.documentProvider.preloadDocument(params.textDocument) + // _ = await state.documentProvider.preloadDocument(params.textDocument) + // TODO: Handle changes from input (not stored on disk) } public func textDocumentDidClose(_ params: TextDocumentDidCloseParams) async {