Closed ice1000 closed 3 years ago
- VSCode sends the LSP an instance of some subtype of
org.eclipse.lsp4j.TextDocumentPositionParams
(done in this client -- Idk how to do it, I need help!)
The client-side should send a named json request (for example aya/load
here):
https://github.com/aya-prover/aya-vscode/blob/8d1f833377d9e5ac68e6a870f33b00afc06c0fcb/src/server-daemon.ts#L126-L127
The server side should register a json request handler with the same name in AyaServer
:
- LSP finds an instance of
Doc
(which, probably we need to convert to plain text before sending to VSCode, but maybe HTML also works?) and a range (done in the compiler, I know how to do it, I don't need help!)
Yes. HTML works.
- VSCode selects the provided range and show the
Doc
somehow, maybe similar to how GHC-Simple shows the type of expressions (done in this client -- Idk how to do it, I need help!)
idk either. But I found this SO thread: https://stackoverflow.com/questions/47250698/set-selection-range-in-the-visual-studio-code-document
Yes. HTML works.
I thought they were sanitized away?
maybe similar to how GHC-Simple shows the type of expressions
But ghc-simple gives plaintext code annotations.
But ghc-simple gives plaintext code annotations.
Why not do better if we can
I think that kind of annotation (next to code) accepts only plaintext.
I think that kind of annotation (next to code) accepts only plaintext.
Then we'll just use plaintext backend of Doc
, I think it'll be fine
OMG turns out we have more problems (now we have a problem factory)
I added computeNF
, can you add vscode support for it too @imkiva
Btw, I've realized I cannot obtain the source code range for a CallTerm
. So sad.
@ice1000 I found an unreliable way to do this
I added
computeNF
, can you add vscode support for it too @imkiva
now vscode supports computeNF
Ok, closing.
I wanna implement a command like this:
org.eclipse.lsp4j.TextDocumentPositionParams
(done in this client -- Idk how to do it, I need help!)Doc
(which, probably we need to convert to plain text before sending to VSCode, but maybe HTML also works?) and a range (done in the compiler, I know how to do it, I don't need help!)Doc
somehow, maybe similar to how GHC-Simple shows the type of expressions (done in this client -- Idk how to do it, I need help!)@imkiva need your help!!