We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
If I describe an enum or class in an unnamed namespace, clang emits warnings, either (if the descriptor is not used)
warning: unused function 'boost_enum_descriptor_fn' [-Wunused-function]
or, if the descriptor is used:
warning: function 'boost_enum_descriptor_fn' is not needed and will not be emitted [-Wunneeded-internal-declaration]
Example: https://godbolt.org/z/qPrdcT5KG
#include <boost/describe.hpp> namespace { BOOST_DEFINE_ENUM(E, A); class S { BOOST_DESCRIBE_CLASS(S, (), (), (), ()); }; } using namespace boost::describe; using D = describe_enumerators<E>; using B = describe_bases<S, mod_any_access>; using M = describe_members<S, mod_any_access>;
It looks like these can be suppressed with [[maybe_unused]]; I'll submit a PR.
The text was updated successfully, but these errors were encountered:
Sprinkle [[maybe_unused]] on descriptors
e951d20
Suppresses Wunused-function / Wunneeded-internal-declaration (clang) on internal-linkage types boostorg#23
1fa1446
Add test for enums and classes in unnamed namespaces (refs #23)
d4ebe09
Thanks.
Sorry, something went wrong.
No branches or pull requests
If I describe an enum or class in an unnamed namespace, clang emits warnings, either (if the descriptor is not used)
or, if the descriptor is used:
Example: https://godbolt.org/z/qPrdcT5KG
It looks like these can be suppressed with [[maybe_unused]]; I'll submit a PR.
The text was updated successfully, but these errors were encountered: