If I run clang-tidy src/main.cpp I get an output format as it follows:
/Users/ubaldot/.platformio/packages/toolchain-atmelavr/bin/../lib/gcc/avr/7.3.0/../../../../avr/include/stdlib.h:48:10: error: 'stddef.h' file not found [clang-diagnostic-error]
#include <stddef.h>
^~~~~~~~~~
/Users/ubaldot/Documents/arduino/freeRTOS/hello_world/src/main.cpp:10:10: warning: inclusion of deprecated C++ header 'stdlib.h'; consider using 'cstdlib' instead [modernize-deprecated-headers]
#include <stdlib.h>
^~~~~~~~~~
<cstdlib>
/Users/ubaldot/Documents/arduino/freeRTOS/hello_world/src/main.cpp:210:17: warning: 'atof' used to convert a string to a floating-point value, but function will not report conversion errors; consider using 'strtod' instead [cert-err34-c]
c = (float) atof((char*)Serial.read());
^
I am wondering if there is any flag to get a compact output, like e.g. the following:
src/main.cpp:10: [medium:warning] inclusion of deprecated C++ header 'stdlib.h'; consider using 'cstdlib' instead [hicpp-deprecated-headers,modernize-deprecated-headers]
src/main.cpp:16: [medium:warning] declaration must be declared within the '__llvm_libc' namespace [llvmlibc-implementation-in-namespace]
src/main.cpp:19: [medium:warning] declaration must be declared within the '__llvm_libc' namespace [llvmlibc-implementation-in-namespace]