-
-
Notifications
You must be signed in to change notification settings - Fork 658
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
COMP: Fix the WDocumentation warnings for enum class. #4661
base: master
Are you sure you want to change the base?
COMP: Fix the WDocumentation warnings for enum class. #4661
Conversation
Used with clang
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.
Thank you for contributing a pull request! 🙏
Welcome to the ITK community! 🤗👋☀️
We are glad you are here and appreciate your contribution. Please keep in mind our community participation guidelines. 📜
More support and guidance on the contribution process can be found in our contributing guide. 📖
This is an automatic message. Allow for time for the ITK community to be able to read the pull request and comment
on it.
@dzenanz @hjmjohnson @N-Dekker : @andrei-sandor is a student working with me this summer, and he's going to take a stab at fixing some warnings in ITK with the goal of being able to enable a few more warning flags on our nightly submissions to cdash. |
Thanks @andrei-sandor ! Cool! I'm interested to hear if these changes will affect the Doxygen output, for example at https://itk.org/Doxygen/html/classitk_1_1CommonEnums.html The proposed changes look fine to me, but they caused some (undeserved) KWStyle errors. Looking at https://open.cdash.org/tests/1552684315
Probably coming from https://github.com/Kitware/KWStyle/blob/6971e89ec4c763601edf1d0ea0d6f71d42fbca5d/kwsCheckComments.cxx#L203 Do you (or anyone) know how to address those as well? |
Maybe this condition needs to be updated to consider |
* \class CellGeometry | ||
* \enum CellGeometry | ||
* \ingroup ITKCommon | ||
* Enums used to specify cell type */ | ||
enum class CellGeometry : uint8_t |
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.
Ideally I think Doxygen should be able to automatically "defer" that CellGeometry
is an enum, just by looking at the code. So then the whole line saying * \... CellGeometry
might simply be removed. But that may be beyond the scope of this pull request, so for now replacing \class
with \enum
looks fine to me.
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.
Indeed. We could do this instead. But it would be a massive change touching many files.
Is there some reason ITK is explicitly using \class
? Did someone think it was required? Is it a stylistic preference to be explicit? Or...?
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.
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 it works, that's fine with me.
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.
After removing the \enum, the following warning is produced Modules/Core/Common/include/itkFloatingPointExceptions.h:37: error: comment doesn't have \class
. What are the possible options? Should a modification be done like here style overwrite rules? Or maybe here this condition (adding an enum might be more complex)?
Used with clang
Replaced \class Doxygen annotations with \enum to avoid warnings