MaskRay / ccls

C/C++/ObjC language server supporting cross references, hierarchies, completion and semantic highlighting
Apache License 2.0
3.72k stars 254 forks source link

ccls does not recognize C attributes #965

Open computerscience-person opened 2 months ago

computerscience-person commented 2 months ago

Observed behavior

ccls gives an error on C attributes (feature was standardized in C23 and is supported by clang 9 and gcc 10).

Minimal example:

[[nodiscard]] void* identity(void* item) {
  return item;
}

Expected behavior

No error (feature standardized in C23).

Steps to reproduce

Minimal example:

[[nodiscard]] void* identity(void* item) {
  return item;
}

System information