CLion 2024.1 Help

Clangd

Clangd is used in CLion as an additional C++ language engine (refer to C++ Support). In this dialog, you can configure particular settings and check the LLVM Clang revision used for the engine.

Clangd settings

Item

Description

Show errors and warnings from clangd

Select this checkbox to turn on the Clangd warnings and errors, which will be shown in the editor instead of the CLion's code errors.

Use the field below the checkbox to specify the list of warnings from Clangd that you want to enable. The default set of warnings includes:

-Wno-unused-variable -Wno-shadow -Wshadow-field-in-constructor-modified -Wshadow-ivar -Wno-implicit-function-declaration -Wno-switch -Wno-parentheses -Wbitwise-op-parentheses -Wdangling-else -Wlogical-not-parentheses -Wlogical-op-parentheses -Woverloaded-shift-op-parentheses -Wparentheses-equality -Wshift-op-parentheses

Use clang-tidy via clangd

Select this checkbox to have clang-tidy working via Clangd. Enabling this option also turns on the following CLion inspections:

Inspection enabled automatically when Use clang-tidy via clangd is on

Use navigation via clangd

When this checkbox is selected, the following navigation and search actions are performed via Clangd:

CLion's own language engine is used for the rest of navigation and search actions. Besides, the results of navigation via Clangd can be adjusted in some cases: for example, Clangd goes to the constructor not class declaration, when navigating from the constructor call.

Use code completion via clangd

With this checkbox selected, code completion is fully provided by Clangd. CLion still uses the build-in engine to complete symbols for non-included files if Clangd-based completion fails to provide anything. In the case of a crash or another serious issue, CLion switches to the built-in engine as well.

Clear this checkbox if you want CLion to suggest only the results from the built-in engine.

Use the Always show clang completion results from inside namespaces option to control the code completion mechanism. Note that enabling it might degrade performance of the completion since namespaces scanning will be involved.

Use parameter info via clangd

When this checkbox is set, Parameter Info works via Clangd. When it's cleared, Parameter info is provided by CLion's built-in engine.

Last modified: 16 April 2024