C/C++/ObjC language server supporting cross references, hierarchies, completion and semantic highlighting
APACHE-2.0 License
Bot releases are visible (Hide)
Published by MaskRay 6 months ago
Published by MaskRay about 2 years ago
Published by MaskRay over 3 years ago
Fix short_name_size when getNameAsString does not return a prefix (#784)
Published by MaskRay almost 4 years ago
This release supports Clang 7~11.
serverInfo
$/progress
(WorkDoneProgressBegin/WorkDoneProgressReport/WorkDoneProgressEnd).ccls
filescompletion.placeholder
: change client.snippetSupport: false to drop (
and <
#412CLANG_LINK_CLANG_DYLIB
(some distributions use this to provide libclang-cpp.so
instead of libclang*.a
or libclang*.so
. This option is needed to link against libclang-cpp.so
)textDocument/documentSymbol
: support unopened files #548Published by MaskRay over 4 years ago
This release supports Clang 7~10.
null
as initializationOptions
declarationProvider
in server capabilities. Some client may need this capability to enable textDocument/declaration
textDocument/hover
#373VersionedTextDocumentIdentifier.version
was omitted. If one renames something spanning more than one document and some documents are not opened, the client may not apply the textDocument/rename
change. #387index.onChange: true
support non-existent files #443textDocument/definition
: don't jump to the type definition.ccls
in #384.ccls
: support CUDA files with the %cu
directivecompilationDatabaseDirectory
can be absolute. #466compile_commands.json
"... but not so well for projects with separate include and source directories, e.g. "inc/long/path/to/my_file.h" and "src/long/path/to/my_file.cc" #441$ccls/fileInfo
: can optionally dump dependencies, includes and skipped_rangesclang::FileEntry::getName
on Arch Linux #487Published by MaskRay over 4 years ago
Building ccls requires at least clang 7. Support for Clang 6 was dropped. This release supports Clang 7, 8 and 9.
-DSYSTEM_CLANG=on
should not be used. clang/llvm auto-download mechanism was deleted.
-DUSE_SYSTEM_RAPIDJSON=on
is the default: use system rapidjson (instead of git submodule) if available.
-DLLVM_ENABLE_RTTI=
and -DUSE_SHARED_LLVM=
should not be used. Since #313, LLVMConfig.cmake
ClangConfig.cmake
are consulted to set sane values for the two variables.
index.maxInitializerLines
. Made someServerCapabilities
toggable.cacheDirectory
was renamed to cache.directory
#278cache.hierarchicalPath
to work around NAME_MAX$directory/a/b/c.cc.blob
instead of$directory/a@[email protected]
#278cache.retainInMemory: 2
: change to 1 to avoid cache corruption if-log-file=stderr
is the default #219TemplateTypeParmDecl
and ParmVarDecl
in declarations for clang >= 90~65535
(was: 0~32767
)index.initialNoLinkage: false
: by default, the background indexer doesn't handle names of no linkage. This saves a lot of memory.textDocument/hover
more detailed: When hovering on a class, ccls tries hard to get the definition and displays struct D : B {}
. It may display a forward declaration struct D
before.textDocument/rename
: mitigate edits in the same place and edits in macro replacement #296textDocument/documentSymbol
, override declaration's range/selectionRange with definition's #309Published by MaskRay almost 5 years ago
Lots of improvement
Hierarchies have been renamed to:
$ccls/call
$ccls/member
$ccls/inheritance
and are available for flattened view (read custom cross references sections on wiki/LanguageClient-neovim and wiki/Emacs)
Completion and diagnostics have been refactored from libclang to Clang C++.
New $ccls/navigate for semantic navigation
Experimental index.onChange: true
, index.multiVersion: true
and cacheDirectory: ""
https://github.com/MaskRay/ccls/wiki/Initialization-options
Published by MaskRay almost 5 years ago
Published by MaskRay almost 6 years ago
textDocument/documentLink
#include
are represented as hyperlinks in vscodetextDocument/foldingRange
$ccls/setSkippedRanges
-> $ccls/publishSkippedRanges
$ccls/publishSemanticHighlighting
-> $ccls/publishSemanticHighlight
textDocument/typeDefinition
resultMessage handling has been refactored.
*.cu
CUDA files-DSYSTEM_CLANG=off
(default) downloads Clang 7.0.0 prebuilt archives from <releases.llvm.org> now (6.0.1 before)ccls -index ~/llvm
=> index ~/llvm
without starting the language serverPublished by MaskRay almost 6 years ago
textDocument/{formatting,onTypeFormatting,rangeFormatting}
formatting/rangeFormatting can be used as replacement of the command line utility clang-format
$ccls/info
: server status.
with ->
or replace ->
with .
The client-side support of additionalTextEdits
is required.SymbolRef, Ref, Use, DeclRef
. Decreased memory usage.$ccls/member
on namespaces. anonymous namespaces/extern "C" are skipped, etcPublished by MaskRay almost 6 years ago
workspace/didChangeWatchedFiles
works (tested on VSCode and coc.nvim) and file deletion will remove index symbols.ccls
enhancement #171 added new directives %compile_commands.json
%h
%hpp
%objective-c
%objective-cpp
-v=1
dumps command line options of files for parsingtextDocument/declaration
and LocationLink[]
return types."exit"
#159signatureHelp.signatureInformationparameterInformation.labelOffsetSupport
cf. https://github.com/Microsoft/language-server-protocol/issues/640
Content-Length:
from 32K to 25K for some cases#include <
completion for -I dir
Text
, instead of Interface
clang_complete.cc
-> sema_manager.cc
)-init=
: "initializationOptions" from client are applied first, then -init=
. Scalar options will be overridden while arrays will get concatenatedtextDocument/codeAction
used incorrect range intersection%h %hpp
didn't take effectfile->symbol2refcnt
could be modified in message_handler.cc
. Affected old releases. Tagged 0.20181010.1 0.20181024.1 0.20181111.2 0.20181225.4, respectively.project.cc:GetSearchDirs
recognize clang.extraArgs
; on Windows, normalize the drive letter used in g_config->cacheDirectory
workspace/didChangeWatchedFiles
conservative https://github.com/MaskRay/ccls/issues/184#issuecomment-455095089
.ccls
nor compile_commands.json
is specified, textDocument/didSave
did not trigger re-index. The fix for the old issue (a plethora of "not indexed" errors) didn't take effectindexer.cc
shouldn't use std::shared_lock
to guard root2folder
being concurrently written.Published by MaskRay almost 6 years ago
Switched to Clang's native #include
completion if clang >= 8. include_completion.cc
is kept for clang<8
Refactored message handlers, deleted related static constructors and removed many ls
prefixes from class/struct names.
textDocument/references
and workspace/symbol
get a new parameter vector<string> folders;
to return results confined in specified folders.
hierarchical textDocument/documentSymbol
lists member functions without definitions.
Fixed EnumConstantDecl
's kind & EnumDecl
's vars. $ccls/member
on scoped enumerations lists its enumeration constants.
Fixed/worked around some preamble bugs
Fixed MSVC 2017 compatibility issues
tobik added a FreeBSD port
Success stories with ClickHouse, Linux, and v8
Published by MaskRay about 6 years ago
Published by MaskRay about 6 years ago
Nothing makes me feel more heartbroken: you solved ccls-fringe and left, with the # of its stargazers unchanged.
Published by MaskRay over 6 years ago
emacs-ccls is available at https://melpa.org/#/ccls
Arch Linux users may install aur/ccls-git archlinuxcn/ccls-git