File tree Expand file tree Collapse file tree
src/Curry/LanguageServer/Features Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -46,7 +46,6 @@ fetchCompletions store entry content pos = do
4646
4747 let completions = maybe [] id
4848 $ (takeIfNonEmpty $ expressionCompletions ast' pos)
49- <|> (takeIfNonEmpty $ declarationCompletions ast' pos)
5049 <|> (takeIfNonEmpty $ importCompletions store ast' pos)
5150 <|> (takeIfNonEmpty $ generalCompletions env ast' pos query)
5251
@@ -58,14 +57,7 @@ expressionCompletions :: Maybe (CS.Module a) -> J.Position -> [J.CompletionItem]
5857expressionCompletions ast pos = do
5958 expr <- maybeToList $ elementAt pos =<< (expressions <$> ast)
6059 case expr of
61- -- TODO: Implement expression completions
62- _ -> []
63-
64- declarationCompletions :: Maybe (CS. Module a ) -> J. Position -> [J. CompletionItem ]
65- declarationCompletions ast pos = do
66- expr <- maybeToList $ elementAt pos =<< (declarations <$> ast)
67- case expr of
68- -- TODO: Implement declaration completions
60+ -- TODO: Implement expression-specific completions
6961 _ -> []
7062
7163importCompletions :: IndexStore -> Maybe (CS. Module a ) -> J. Position -> [J. CompletionItem ]
@@ -84,6 +76,8 @@ generalCompletions env ast pos query = rmDupsOn (^. J.label) $ filter (matchesQu
8476 ++ typeCompletions env
8577 ++ keywordCompletions
8678
79+ -- TODO: Re-implement localCompletions using NestEnvs and bindings
80+
8781localCompletions :: Maybe (CS. Module a ) -> J. Position -> [J. CompletionItem ]
8882localCompletions ast pos = declarationToCompletions =<< (elementsAt pos $ declarations =<< maybeToList ast)
8983
You can’t perform that action at this time.
0 commit comments