When printing C representation of AST, clang puts the "attribute" elements after the name of printed function.
In order for the generated code to be GCC compatible, these attributes should be printed at the beginning of function.
For example when executing clang -cc1 -ast-print test.c we recieve:
void test() __attribute__((cold)) {}
Instead we should see:
__attribute__((cold))void test() {}
because the former causes GCC incompatibility
warning: GCC does not allow 'cold' attribute in this position on a function definition [-Wgcc-compat]
clang-format not found in user’s local PATH; not linting file.