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

LSP: narrow complete suggestions after a pipe #3297

Open
gusinacio opened this issue Jun 19, 2024 · 1 comment
Open

LSP: narrow complete suggestions after a pipe #3297

gusinacio opened this issue Jun 19, 2024 · 1 comment
Labels
help wanted Contributions encouraged priority:medium

Comments

@gusinacio
Copy link

gusinacio commented Jun 19, 2024

I don't know how functional languages LSPs usually handle this case but it would be nice if suggestions after a pipe are functions that contain the type as the first parameter. i.e:

"hello" |> // <- This would only suggest functions that have String as the first parameter type

If there are multiple pipes, the suggestions should be related to the last output value.

"2" |> int.parse |>  // <- This would only suggest functions that have Result as the first parameter type
@lpil lpil changed the title LSP: auto complete suggestions on pipes LSP: narrow complete suggestions after a pipe Jun 20, 2024
@lpil lpil added help wanted Contributions encouraged priority:medium labels Jun 20, 2024
@lpil
Copy link
Member

lpil commented Jun 20, 2024

Good suggestion, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Contributions encouraged priority:medium
Projects
Status: Unfinished
Development

No branches or pull requests

2 participants