[libcxx-commits] [PATCH] D65667: [libcxx] Early-initialize error_category singletons
Marshall Clow via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Aug 16 14:47:09 PDT 2019
mclow.lists added inline comments.
Comment at: libcxx/src/future.cpp:83
+#if _LIBCPP_STD_VER > 11
Please don't write code like this. It's hard to read, and it's easy to have the attribute get disconnected from the thing it's referring to.
Instead, define a new macro `_LIBCPP_SAFE_STATIC_AFTER_CXX11` and use that.
It's clear what the intent is.
You have five `#ifdefs` in this patch.
I'd prefer to see only one ifdef, in `<__config>` where no one will ever look at it.
That's why we have macros like `_LIBCPP_CONSTEXPR_AFTER_CXX11`
CHANGES SINCE LAST ACTION
More information about the libcxx-commits