Reputation: 136
I have clang-tidy checking for unused return values with bugprone-unused-return-value
check. Unfortunately it only checks return values from list of functions specified with CheckedFunctions
parameter. I would like to check usage of return value from all functions, but am not able to figure out what to write to CheckedFunctions
to do this.
What should I write to bugprone-unused-return-value
's parameter CheckedFunctions
for it to check all functions?
Upvotes: 2
Views: 1113
Reputation: 2663
Unfortunately bugprone-unused-return-value
check is not built to check all functions.
You can either specify CheckedFunctions
or if you omit the specification then a default list of functions will be used. There is no possibility of using wildcards or regular expressions here.
See the documentation. I also checked the source code of the check just to be sure but in current version of clang-tidy (14) this can't be done.
Upvotes: 2