Skip to content

[Suggestion] Investigate inline parameter hints #123

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

Closed
DJMcNab opened this issue Oct 11, 2018 · 6 comments
Closed

[Suggestion] Investigate inline parameter hints #123

DJMcNab opened this issue Oct 11, 2018 · 6 comments

Comments

@DJMcNab
Copy link
Contributor

DJMcNab commented Oct 11, 2018

microsoft/vscode#16221 is the primary tracking/suggestion issue for this.

The exact design of the communication between the client and server for this feature has not been created, blocking a direct proposal in the language server protocol. This repository seems like a good place to prototype and investigate such a feature.

It has been suggested that such a feature could remove any need for explicit parameter naming at call sites in Rust, as linked in my comment in the attached issue.

Sorry if bad formatting! Written on mobile.

@aochagavia
Copy link
Contributor

Why does this need LSP support? It looks like it is already possible to implement something like this, even without changes to the LSP (see this extension for JavaScript/Typescript)

@DJMcNab
Copy link
Contributor Author

DJMcNab commented Oct 12, 2018

It's more that it should be implemented directly in tsserver if it is useful, which would be better if it was an explicit feature of the lsp. It is possible to use the custom protocols, but they are non-standard and need custom clientside code for every one (although we already have a lot of that, so 🤷‍♂️)

(That extension it would still uses another copy of the typescript library, so it has to store another version of the world state to work, which is a waste of memory).

@kjeremy
Copy link
Contributor

kjeremy commented Oct 12, 2018

Once #110 is merged we should have the machinery available to at least get function signature info.

@DJMcNab
Copy link
Contributor Author

DJMcNab commented Dec 25, 2018

Related for the goal of compiling into WASM: rust-lang/rust-playground#188

@matklad
Copy link
Member

matklad commented Feb 18, 2019

Closing as this is really an editor's feature, not a language-server one.

@matklad matklad closed this as completed Feb 18, 2019
@DJMcNab
Copy link
Contributor Author

DJMcNab commented Feb 18, 2019

It's an editor feature which needs information from the language server. I might try to make a quick prototype, see how it goes.

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

No branches or pull requests

4 participants