New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add PCL_UNUSED to fix doxygen warnings #3932
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we could make this optional (eg: for OMP thread number), that would be heaven
* | ||
* Slightly better than `(void)x` as explained [here](https://stackoverflow.com/a/4030983/9926122). | ||
*/ | ||
#define PCL_UNUSED(x) ((void)(true ? 0 : ((x), void(), 0))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My eyes are struggling to mentally compile this expression.
By the way this PR introduced warnings in 18.04, g++ 7.5.0
|
This actually didn't work for:
(link)
(link) But it was perfect for Doxygen and MSVC. Maybe for the rest |
Fixes
warning: argument <arg> of command @param is not found in the argument list of <function>
If this seems reasonable I'll follow up with a PR aiming at using this macro instead of all the naked
(void)
casts.