OpenCL-ICD-Loader
OpenCL-ICD-Loader copied to clipboard
Add clang-tidy, clean up some warnings
- Add initial .clang-tidy config
- Clear code base of found lints
It does not fully resolve #68 since we still need to enable a higher warning level in the compiler itself.
I've enabled all checks in clang-tidy and marked a few ones that I encountered while fixing the code as errors. misc-unused-parameters breaks on C, that's why I disabled it. We can change the concrete list of checks later on and tweak some parameters, but this PR cleans the code of all things found so far by clang-tidy.
The malloc of wrong size in one of the tests was a really good catch.
That's probably as good as we can get without converting the project to C++ (which, I mean, why not...)