Why use xtensa-clang for clang-tidy in IDF Clang Tidy?
Posted: Wed Jul 05, 2023 9:29 am
Hi,
I am starting to use static analysis in my codebase for ESP32 project, and I read the guide in the IDF docs for using `idf.py clang-check`. This depends on installing the xtensa-clang binaries, but I wonder why it is recommended to use xtensa-clang instead of the native clang-tidy? I could install clang-tidy for my environment with `apt install clang-tidy`.
Because clang-tidy is analysing C code and not compiling it, can anyone explain why the clang-tidy from xtensa-clang is a better choice than the native clang-tidy?
Thank you
I am starting to use static analysis in my codebase for ESP32 project, and I read the guide in the IDF docs for using `idf.py clang-check`. This depends on installing the xtensa-clang binaries, but I wonder why it is recommended to use xtensa-clang instead of the native clang-tidy? I could install clang-tidy for my environment with `apt install clang-tidy`.
Because clang-tidy is analysing C code and not compiling it, can anyone explain why the clang-tidy from xtensa-clang is a better choice than the native clang-tidy?
Thank you