[libcxx-commits] [PATCH] D103947: [libcxx] Fix using the vcruntime ABI with _HAS_EXCEPTIONS=0 defined
Petr Hosek via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Apr 20 16:17:44 PDT 2022
phosek added inline comments.
Comment at: libcxx/include/exception:141
+ const char* _Ptr;
> phosek wrote:
> > I wonder if we should annotate this with `[[maybe_unused]]` to avoid a compiler warning.
> That may be a good idea. Grep didn't reveal a macro that I saw, but I may have missed it. I do see that this file has a `_LIBCPP_DIAGNOISTIC_IGNORED(-Wunused-private-field)` maybe that is the correct approach here w/ a change to the warning?
I'd prefer defining a new macro, e.g. `_LIBCPP_MAYBE_UNUSED`, akin to `_NOEXCEPT` which would expand to `[[maybe_unused]]` (or `__attribute__((unused))` if `[[maybe_unused]]` is unavailable).
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
More information about the libcxx-commits