When using libclang to parse a C headerfile containing several enum definitions, all Enums as well as all their respective variants are contained in the AST. However, parsing the file with -x c flag only finds a PARM_DECL and TYPE_REF node for each enum variant definition.
Changing the flag to -x c++ correctly detects a ENUM_CONSTANT_DECL node for each variant.
See also discussion here: #143264 (comment)