From d0fb706fa8f3895538ddd777f43f7c87b1302457 Mon Sep 17 00:00:00 2001 From: Chris Penner Date: Thu, 7 Dec 2023 15:07:08 -0800 Subject: [PATCH] Fix build --- unison-cli/src/Unison/Codebase/Editor/HandleInput.hs | 4 ++-- unison-cli/src/Unison/LSP/Queries.hs | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/unison-cli/src/Unison/Codebase/Editor/HandleInput.hs b/unison-cli/src/Unison/Codebase/Editor/HandleInput.hs index 0fadfebce1..54708ecc15 100644 --- a/unison-cli/src/Unison/Codebase/Editor/HandleInput.hs +++ b/unison-cli/src/Unison/Codebase/Editor/HandleInput.hs @@ -560,7 +560,7 @@ loop e = do let nameSearch = NameSearch.makeNameSearch hqLength (NamesWithHistory.fromCurrentNames basicPrettyPrintNames) Cli.Env {codebase, runtime} <- ask mdText <- liftIO $ do - docRefs <- Backend.docsForDefinitionName codebase nameSearch docName + docRefs <- Backend.docsForDefinitionName codebase nameSearch NamesWithHistory.ExactName docName for docRefs $ \docRef -> do Identity (_, _, doc) <- Backend.renderDocRefs pped (Pretty.Width 80) codebase runtime (Identity docRef) pure . Md.toText $ Md.toMarkdown doc @@ -937,7 +937,7 @@ loop e = do let patchPath' = fromMaybe Cli.defaultPatchPath patchPath patch <- Cli.getPatchAt patchPath' QueryResult fromMisses' fromHits <- hqNameQuery NamesWithHistory.IncludeSuffixes [from] - QueryResult toMisses' toHits <- hqNameQuery NamesWithHistory.IncludeSuffixes [to] + QueryResult toMisses' toHits <- hqNameQuery NamesWithHistory.IncludeSuffixes [to] let termsFromRefs = termReferences fromHits termsToRefs = termReferences toHits typesFromRefs = typeReferences fromHits diff --git a/unison-cli/src/Unison/LSP/Queries.hs b/unison-cli/src/Unison/LSP/Queries.hs index f86f8faf5f..ca66e4ffcd 100644 --- a/unison-cli/src/Unison/LSP/Queries.hs +++ b/unison-cli/src/Unison/LSP/Queries.hs @@ -37,6 +37,7 @@ import Unison.LabeledDependency import Unison.LabeledDependency qualified as LD import Unison.Lexer.Pos (Pos (..)) import Unison.Name (Name) +import Unison.NamesWithHistory (SearchType (..)) import Unison.Parser.Ann (Ann) import Unison.Parser.Ann qualified as Ann import Unison.Pattern qualified as Pattern @@ -386,7 +387,7 @@ markdownDocsForFQN fileUri fqn = nameSearch <- lift $ getNameSearch Env {codebase, runtime} <- ask liftIO $ do - docRefs <- Backend.docsForDefinitionName codebase nameSearch name + docRefs <- Backend.docsForDefinitionName codebase nameSearch ExactName name for docRefs $ \docRef -> do Identity (_, _, doc) <- Backend.renderDocRefs pped (Pretty.Width 80) codebase runtime (Identity docRef) pure . Md.toText $ Md.toMarkdown doc