Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Completions are missing do #987

Closed
ndmitchell opened this issue Jan 24, 2020 · 4 comments · Fixed by haskell/ghcide#351
Closed

Completions are missing do #987

ndmitchell opened this issue Jan 24, 2020 · 4 comments · Fixed by haskell/ghcide#351

Comments

@ndmitchell
Copy link
Collaborator

When starting a file, and writing main = do, I get completions for drop etc. I suggest that keywords should be available as completions always. Particularly problematic because after do I often want a newline, but in this context enter inserts the word drop.

image

@fendor
Copy link
Collaborator

fendor commented Jan 24, 2020

Issue in haskell ide engine: haskell/haskell-ide-engine#953

@ocharles
Copy link
Contributor

This seems odd to me. Do other languages do this? E.g., if you write C#, does cla suggest class?

@cocreature
Copy link
Contributor

The linked issue explains why this is less of an issue in other languages: In something like C# completions are mostly triggered after a . and you only get relevant completions. Whereas in Haskell we don’t have that clear indicator (except for qualified definitions) so you end up completing in a context where do could be valid.

@ndmitchell
Copy link
Collaborator Author

That's the state of IDE completion as it was a decade ago. In C# you're always completing, and yes, it does complete class - but probably into a snippet that contains the braces and a highlighted name too.

@pepeiborra pepeiborra transferred this issue from haskell/ghcide Jan 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants