[libcxx-commits] [PATCH] D119896: [libc++] Remove a few unneeded _LIBCPP_CXX03_LANG ifdefs

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Feb 16 07:59:02 PST 2022


Quuxplusone added inline comments.


================
Comment at: libcxx/include/type_traits:1835
     ~__nat() = delete;
-#endif
 };
 
----------------
Based on the weirdness of the test failure in https://reviews.llvm.org/harbormaster/unit/view/2687268/ , I don't think you should do this diff either.

Looks to me like maybe Clang's C++03 mode doesn't let you do `sizeof(foo())` unless `foo()`'s return type is destructible. We could probably fix this most simply by just //not deleting `~__nat()` in any mode//, but that's a majorly scary patch that should go in its own PR and be carefully audited for all the users of `__nat`. (Off the top of my head I don't know why `__nat` deletes //anything// — I think it should just be a plain old tag type — but, as always, I assume there is a reason, which means we need to go find out what that reason is.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D119896/new/

https://reviews.llvm.org/D119896



More information about the libcxx-commits mailing list