haskell-language-server icon indicating copy to clipboard operation
haskell-language-server copied to clipboard

Field and value completion does not work inside conditionals

Open VeryMilkyJoe opened this issue 1 year ago • 3 comments

Cabal completion seems to not be able to complete anything inside if statements.

Here, the default completion for vscode is suggested inside an if conditional, when it should be the library section fields: image Here, the exposed modules values should be completed instead of the default vscode completions: image

The fields we are checking for completion are defined here. I think to fix this we can check the parent sections recursively instead of simply the most direct parent to figure out the stanza the cursor is located in.

VeryMilkyJoe avatar Jun 08 '24 14:06 VeryMilkyJoe