llvm-project/clang-tools-extra/clangd
Kadir Cetinkaya ec2f7376e3
[clangd][QueryDriver] Dont check for existence of driver
Execute implementations already checks for permissions and existence
and returns relevant errors as necessary, so instead of printing our own errors,
we just print theirs.

This also fixes a case in windows where the driver might be missing the `.exe`
suffix. Previously, clangd would reject such a driver because sys::fs::exists is
strict, whereas the underlying Execute implementation would check with `.exe`
suffix too.

Fixes https://github.com/clangd/clangd/issues/93

Differential Revision: https://reviews.llvm.org/D102431
2021-05-17 12:38:17 +02:00
..
benchmarks [cte][NFC] Remove all references to stdlib stream headers. 2021-03-02 21:57:16 +00:00
fuzzer [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
include-mapping
index [clangd][remote-client] Set HasMore to true for failure 2021-05-11 08:22:24 +02:00
indexer
quality Make clangd CompletionModel not depend on directory layout. 2021-05-05 19:25:34 +01:00
refactor [clangd] Use dirty filesystem when performing cross file tweaks 2021-04-20 17:13:44 +01:00
support [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
test [clangd][index-sever] Limit results in repsonse 2021-05-11 08:22:23 +02:00
tool [clangd] Set FileSystem for tweaks in Check tool. 2021-05-17 11:10:07 +02:00
unittests [clangd] Make unit test compatible with gtest 1.10.0 2021-05-14 19:37:46 +02:00
xpc
AST.cpp [clangd] Dont index deeply nested symbols 2021-04-27 12:34:56 +02:00
AST.h [clangd] Dont index deeply nested symbols 2021-04-27 12:34:56 +02:00
ASTSignals.cpp
ASTSignals.h
ClangdLSPServer.cpp [clangd] Fix data type of WorkDoneProgressReport::percentage 2021-05-10 14:57:20 +02:00
ClangdLSPServer.h [clangd] Split CC and refs limit and increase refs limit to 1000 2021-05-05 23:39:48 +02:00
ClangdServer.cpp [clangd][NFC] Remove unnecessary string captures in lambdas. 2021-04-30 13:27:24 +01:00
ClangdServer.h [clangd] Allow AST request without range 2021-04-23 21:35:42 +02:00
CMakeLists.txt [clangd] Add support for inline parameter hints 2021-04-14 02:31:20 -04:00
CodeComplete.cpp [clangd] Check if macro is already in the IdentifierTable before loading it 2021-05-06 08:24:06 +02:00
CodeComplete.h Revert "Revert "[clangd] Use ML Code completion ranking as default."" 2021-03-02 18:03:52 +01:00
CodeCompletionStrings.cpp
CodeCompletionStrings.h
CollectMacros.cpp
CollectMacros.h
CompileCommands.cpp [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
CompileCommands.h
Compiler.cpp [clangd] Always default to raw pch format 2021-05-14 16:34:57 +02:00
Compiler.h [clangd] Introduce ASTHooks to FeatureModules 2021-04-13 17:45:09 +02:00
Config.cpp
Config.h Revert "Revert "[clangd] Provide a way to disable external index"" 2021-04-13 11:24:32 +02:00
ConfigCompile.cpp [clangd] Only allow remote index to be enabled from user config. 2021-04-15 14:51:23 +02:00
ConfigFragment.h [clangd] Only allow remote index to be enabled from user config. 2021-04-15 14:51:23 +02:00
ConfigProvider.cpp [clangd] Only allow remote index to be enabled from user config. 2021-04-15 14:51:23 +02:00
ConfigProvider.h [clangd] Only allow remote index to be enabled from user config. 2021-04-15 14:51:23 +02:00
ConfigYAML.cpp Revert "Revert "[clangd] Provide a way to disable external index"" 2021-04-13 11:24:32 +02:00
CSymbolMap.inc
Diagnostics.cpp [clangd] Propagate data in diagnostics 2021-04-13 17:45:09 +02:00
Diagnostics.h [clangd] Propagate data in diagnostics 2021-04-13 17:45:09 +02:00
DraftStore.cpp [clangd][NFC] Silence some buildbot warnings after 0250b053 2021-03-09 14:55:55 +00:00
DraftStore.h [clangd][NFC] Silence some buildbot warnings after 0250b053 2021-03-09 14:55:55 +00:00
DumpAST.cpp [clangd] Allow AST request without range 2021-04-23 21:35:42 +02:00
DumpAST.h [clangd] Allow AST request without range 2021-04-23 21:35:42 +02:00
ExpectedTypes.cpp
ExpectedTypes.h
FeatureModule.cpp [clangd] Rename Module -> FeatureModule to avoid confusion. NFC 2021-03-05 10:04:00 +01:00
FeatureModule.h [clangd] Introduce ASTHooks to FeatureModules 2021-04-13 17:45:09 +02:00
Features.inc.in [clangd] Optionally add reflection for clangd-index-server 2021-03-15 21:07:25 +01:00
FileDistance.cpp
FileDistance.h
FindSymbols.cpp [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
FindSymbols.h
FindTarget.cpp [clangd][ObjC] Highlight Objc Ivar refs 2021-05-06 11:41:49 -04:00
FindTarget.h
Format.cpp [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
Format.h
FS.cpp
FS.h
FuzzyMatch.cpp
FuzzyMatch.h
GlobalCompilationDatabase.cpp [clangd] Expose absoluteParent helper 2021-02-19 13:40:21 +01:00
GlobalCompilationDatabase.h
Headers.cpp
Headers.h [clangd] Use flags from open files when opening headers they include 2021-03-01 09:43:59 +01:00
HeaderSourceSwitch.cpp
HeaderSourceSwitch.h
HeuristicResolver.cpp [clangd] Parameter hints for dependent calls 2021-05-03 02:03:16 -04:00
HeuristicResolver.h [clangd] Parameter hints for dependent calls 2021-05-03 02:03:16 -04:00
Hover.cpp Add type information to integral template argument if required. 2021-05-12 19:00:08 +00:00
Hover.h
IncludeFixer.cpp
IncludeFixer.h
InlayHints.cpp [clangd] Parameter hints for dependent calls 2021-05-03 02:03:16 -04:00
InlayHints.h [clangd] Add support for inline parameter hints 2021-04-14 02:31:20 -04:00
JSONTransport.cpp
LSPBinder.h [clangd] Bind outgoing calls through LSPBinder too. NFC 2021-02-17 10:56:06 +01:00
ParsedAST.cpp [clangd] Avoid including HeuristicResolver.h from ParsedAST.h 2021-05-03 00:55:22 -04:00
ParsedAST.h [clangd] Avoid including HeuristicResolver.h from ParsedAST.h 2021-05-03 00:55:22 -04:00
PathMapping.cpp
PathMapping.h
Preamble.cpp [cland] Dont emit missing newline warnings when building preamble 2021-04-23 08:56:32 +02:00
Preamble.h [clangd] Introduce pullDiags endpoint 2021-03-16 12:52:15 +01:00
Protocol.cpp [clangd][NFC] Reserve storage when creating semantic token encoding. 2021-04-28 22:39:54 +01:00
Protocol.h [clangd] Fix data type of WorkDoneProgressReport::percentage 2021-05-10 14:57:20 +02:00
Quality.cpp Revert "Revert "[clangd] Use ML Code completion ranking as default."" 2021-03-02 18:03:52 +01:00
Quality.h
QueryDriverDatabase.cpp [clangd][QueryDriver] Dont check for existence of driver 2021-05-17 12:38:17 +02:00
README.md
RIFF.cpp
RIFF.h
Selection.cpp
Selection.h
SemanticHighlighting.cpp [clangd] Fix build error in SemanticHighlighting.cpp 2021-05-03 01:19:07 -04:00
SemanticHighlighting.h [clangd] ObjC fixes for semantic highlighting and xref highlights 2021-03-03 20:16:08 +01:00
SemanticSelection.cpp
SemanticSelection.h
SourceCode.cpp [clangd] Replace usages of dummy with more descriptive words 2021-03-22 12:49:24 +01:00
SourceCode.h [clangd] Move DraftStore from ClangdLSPServer into ClangdServer. 2021-03-02 22:58:50 +01:00
StdSymbolMap.inc
TidyProvider.cpp [clangd] Expose absoluteParent helper 2021-02-19 13:40:21 +01:00
TidyProvider.h
Transport.h
TUScheduler.cpp [clangd] Use Dirty Filesystem for cross file rename. 2021-03-10 13:41:29 +00:00
TUScheduler.h [clangd] Use Dirty Filesystem for cross file rename. 2021-03-10 13:41:29 +00:00
URI.cpp
URI.h
XRefs.cpp [clangd] Find implementors only when index is present. 2021-05-03 17:16:33 +02:00
XRefs.h [clangd] Add SymbolID to LocatedSymbol. 2021-04-28 15:05:53 +02:00

clangd

clangd is a language server, and provides C++ IDE features to editors. This is not its documentation.

Communication channels

If you have any questions or feedback, you can reach community and developers through one of these channels:

Building and testing clangd

For a minimal setup on building clangd:

  • Clone the LLVM repo to $LLVM_ROOT.

  • Create a build directory, for example at $LLVM_ROOT/build.

  • Inside the build directory run: cmake $LLVM_ROOT/llvm/ -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra".

    • We suggest building in Release mode as building DEBUG binaries requires considerably more resources. You can check Building LLVM with CMake documentation for more details about cmake flags.
    • In addition to that using Ninja as a generator rather than default make is preferred. To do that consider passing -G Ninja to cmake invocation.
    • Finally, you can turn on assertions via -DLLVM_ENABLE_ASSERTS=On.
  • Afterwards you can build clangd with cmake --build $LLVM_ROOT/build --target clangd, similarly run tests by changing target to check-clangd.