https://maskray.me/blog/2018-12-25-ccls-release
新版https://github.com/MaskRay/ccls/releases/tag/0.20181225
workspace/didChangeWatchedFilesworks (tested on VSCode and coc.nvim) and file deletion will remove index symbols.cclsenhancement #171 added new directives%compile_commands.json%h%hpp%objective-c%objective-cpp-v=1dumps commandline options of files for parsing- fuzzy_match: when the completion filter begins with a letter, builtin macros prefixed with an underscore will not be returned
- Support
textDocument/declarationandLocationLink[]return types. - Properly handle
"exit"#159 - Support
signatureHelp.signatureInformationparameterInformation.labelOffsetSupportcf. https://github.com/Microsoft/language-server-protocol/issues/640 - codeAction: fixed an incompatibility issue with VSCode
Completion
- More precise diagnostics/completion: an included file that has been changed does not need to be saved to take effect.
- Decreased
Content-Length:from 32K to 25K for some cases - On clang < 8, fixed
#include <completion for-I dir - Macros are categorized as
Text, instead ofInterface - Refactor and rename (
clang_complete.cc->sema_manager.cc) - C++17 deduction guide #173
Others
- Support multiple
-init=: "initializationOptions" from client are applied first, then-init=. Scalar options will be overridden while arrays will get concatenated
重是
- 更加精的 diagnostics/completion(#include 中的依 unsaved buffers),之前 cquery/ccls 的做法都不好
- 案除、重命名:之前案都不清理掉除的案 #170
- #159 是之前 LSP exit
exit(0)(中一正在 cache 的 indexer thread 下次可能不出,但非常罕) - 全的其他大大小小改
- 如果一 textDocument 的索引未被加,request (
textDocument/documentHighlighttextDocument/hover等)告not indexed,示在 echo area,比人。我在pipeline.cc引入了一 backlog 解一,https://github.com/MaskRay/ccls/pull/176。code lens 可以用(add-hook 'lsp-after-open-hook #'ccls-code-lens-mode)而不需要(run-at-time 0.5 nil #'ccls-code-lens-mode)了 - 增
.ccls和compile_commands.json的作, Paul Smith 的分析https://github.com/MaskRay/ccls/issues/115#issuecomment-449455357
其他
- ccls/wiki/Emacs 拆分成wiki/lsp-mode和wiki/egot,後者比陋(迎)
- eglot 支援
workspace/didChangeWatchedFiles,lsp-mode 尚未 - 我 lsp-mode 加了
LocationLink支援,targetSelectRange可以指向名字,而targetRange指向廓。mouse hover 可以有可效果(於 Emacs 用途不大) - xref.el 的
xref-file-location非表示interface Range的良好,因能表示(line column),不能表示。lsp-ui-peek 需要信息 highlight 文本,法良好地用 xref 表,在 lsp-ui-peek 的有心(希望有人能改好)
;; xref.el (defclass xref-file-location (xref-location) ((file :type string :initarg :file) (line :type fixnum :initarg :line :reader xref-location-line) (column :type fixnum :initarg :column :reader xref-file-location-column)) :documentation "A file location is a file/line/column triple. Line numbers start from 1 and columns from 0.") ;; lsp-ui-peek.el (-if-let (uri (gethash "uri" x)) (-let (((&hash "start" (&hash "line" "character")) (gethash "range" x))) (lsp-ui-peek--goto-xref `(:file ,(lsp--uri-to-path uri) :line ,line :column ,character))) (-let (((&hash "start" (&hash "line" "character")) (or (gethash "targetSelectionRange" x) (gethash "targetRange" x)))) (lsp-ui-peek--goto-xref `(:file ,(lsp--uri-to-path (gethash "targetUri" x)) :line ,line :column ,character)))) - 非常希望看到有人能把 lsp-mode 的 hash tables+string keys (
(gethash "range" xx))都改成 plists + keyword keys ((plist-get xx :range)),我感是有希望的…… - code lens 我另外也在等待 eglot 的理:https://github.com/joaotavora/eglot/pull/71,lsp-mode 中的 issue 是https://github.com/emacs-lsp/lsp-mode/issues/361
