To have inline syntax checks and auto-completions etc, follow the procedure below to setup the clangd language server for your labs.
Install clangd . In the recommended multipass ubuntu environment, you can do this by running sudo apt update && sudo apt install clangd directly.
Install VS Code extension for clangd .
Make sure you have the flag set(CMAKE_EXPORT_COMPILE_COMMANDS ON) presents in your project's root-level CMakeLists.txt .
Then build the lab to generate the compilation database JSON so the language server understands your codebase structure:
# cd to the project folder
$ mkdir -p build
$ cd build
$ cmake .. # configure
$ make -j$(nproc) # build
Finally, press Command + Shift + P and then select clangd: Restart language server .