-
Notifications
You must be signed in to change notification settings - Fork 153
Description
I have a question about implementation "Signature for further properties" of the FormattingOptions (https://github.com/Microsoft/language-server-protocol/blob/master/protocol.md#document-formatting-request) . lsp4j java class FormattingOptions (https://github.com/eclipse/lsp4j/blob/master/org.eclipse.lsp4j/src/main/xtend-gen/org/eclipse/lsp4j/FormattingOptions.java#L25) to represents this model description contains field "properties" like a map. Is it correct? I'm working on investigation using Clangd language server and I see that lsp4j always send json with FormattingOptions which include field "properties":
{"jsonrpc":"2.0","id":"2","method":"textDocument/rangeFormatting","params":{"range":{"start":{"line":1,"character":4},"end":{"line":1,"character":12}},"textDocument":{"uri":"file:///home/antey/projects/cSimple/file.c"},"options":{"tabSize":4,"insertSpaces":true,"properties":{}}}}
Clangd doesn't send response message for such request message. But if I delete "properties" field -Clangd successfully send me response:
{"jsonrpc":"2.0","id":"2","method":"textDocument/rangeFormatting","params":{"range":{"start":{"line":1,"character":4},"end":{"line":1,"character":12}},"textDocument":{"uri":"file:///home/antey/projects/cSimple/file.c"},"options":{"tabSize":4,"insertSpaces":true}}}
I try to understand where is a problem? Inside lsp4j library, or this is a bug Clangd, or root of this problem is unclear language server specification for FormattingOptions?