C Variable reference / function call highlighting (a la VSCode C tools)

Hi Everyone,

I’m new to Doom, and am migrating from VSCode. I’m really enjoying the keyboard-centric evil interface, but I’ve got one feature I haven’t been able to bring over yet - the highlighting of variable/symbol references in C code. Thanks for taking a look, and apologies if I missed anything!

What happened?

image When opening a familiar C file, Variable references and calls to local and imported functions show up white instead of a distinct colour. clangd is running and can be connected to.

Also tried installing treesitter since some others with this problem were told to.

What did you expect to happen?

image I expected a result similar to the above VSCode screenshot, where function calls are highlighted in blue, variables in red (the specific colour doesn’t matter, just that it highlights them)

Steps to reproduce

  1. Install Doom Emacs
  2. Enable lsp and (cc +lsp) in init.el
  3. Add compiler config at end of config.el
  4. run doom sync
  5. Install clangd (Fedora, so dnf)
  6. Restart Doom, open a c file.

System information


Loading data dump...