Remove $ccls/base

Fangrui Song 2018-09-07 14:57:34 -07:00
parent 16618d7b48
commit c1fa202120
4 changed files with 9 additions and 6 deletions

@ -133,13 +133,11 @@ For a symbol named `Name::FooBar`, all of `FooBar`, `foo bar`, `nafoba` find the
Aside from definitions/references/workspace symbol, ccls provides some LSP extensions that find base/derived classes/methods, vars of a type, callers of a function. You may call:
```elisp
(lsp-find-custom "$ccls/base")
(lsp-find-custom "$ccls/callers")
; Use lsp-goto-implementation or lsp-ui-peek-find-implementation for derived types/functions
(lsp-find-custom "$ccls/vars")
; Use lsp-goto-implementation or lsp-ui-peek-find-implementation for derived types/functions
;; Alternatively, use lsp-ui-peek interface
(lsp-ui-peek-find-custom 'base "$ccls/base")
(lsp-ui-peek-find-custom 'callers "$ccls/callers")
(defun ccls/vars (kind) (lsp-ui-peek-find-custom 'vars "$ccls/vars" (plist-put (lsp--text-document-position-params) :kind kind)))

2
FAQ.md

@ -165,7 +165,7 @@ ccls will save a file in `cacheDirectory`:
* <code>extern int <kbd>a</kbd>;</code> If `ReferenceContext.includeDeclaration` is true, the definition and declarations are also listed.
* If no references is found but the point is on the first line, list `#include` lines referencing current file.
### `$ccls/base`
### `$ccls/memberHierarchy flat:true derived:false`
* <code>struct <kbd>A</kbd>:B{void <kbd>f</kbd>()override;};</code> lists `B` or `B::f()`

@ -51,6 +51,13 @@ You usually want to use `index.multiVersionBlacklist` to exclude system headers.
}
```
## `index.onChange`: re-index for every change
It is `false` by default which means to re-index when a document is saved.
Set it to `true` to re-index for every change to a document.
The performance will suffer a lot.
## `cacheFormat`: serialization format of cache files
Two cache serialization formats are supported.

@ -73,8 +73,6 @@ nn <silent> xl :call LanguageClient#findLocations({'method':'$ccls/navigate','di
### Custom cross references
```vim
" one-level base
nn <silent> xB :call LanguageClient#findLocations({'method':'$ccls/base'})<cr>
" bases of up to 3 levels
nn <silent> xb :call LanguageClient#findLocations({'method':'$ccls/inheritanceHierarchy','flat':v:true,'levels':3,'derived':v:false})<cr>
" derived of up to 3 levels