[PATCH] D50341: [libcxx] Fix XFAILs for aligned allocation tests on older OSX versions

Marshall Clow via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 13 15:10:42 PDT 2018


mclow.lists added inline comments.


================
Comment at: libcxx/test/libcxx/memory/aligned_allocation_macro.pass.cpp:18
+// XFAIL: macosx10.8
+// XFAIL: macosx10.7
 
----------------
These should probably be `UNSUPPORTED` as well.


================
Comment at: libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/delete_align_val_t_replace.pass.cpp:15
 // Older Clang versions do not support this
 // XFAIL: clang-3, apple-clang-7, apple-clang-8
 
----------------
These should probably be `UNSUPPORTED` as well (though this is less important)



================
Comment at: libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_size_align.fail.cpp:15
 
 // UNSUPPORTED: c++98, c++03, c++11, c++14, c++17
 // UNSUPPORTED: clang-3.3, clang-3.4, clang-3.5, clang-3.6, clang-3.7, clang-3.8
----------------
ldionne wrote:
> vsapsai wrote:
> > In what cases are we supposed to run these tests? Such extensive collection of unsupported C++ standards looks suspicious and I guess that is the reason why I haven't seen test failures with older libc++ dylibs.
> That's an excellent question. I would assume those should be enabled in C++17 and above, I'm not sure why they're disabled. @mclow.lists was the one to introduce those tests, perhaps he can shed light on why they were disabled in C++17?
IIRC, this call - `operator new(std::size_t, std::align_val_t);` was introduced for C++17, and `[[nodiscard]]` was added for C++20.

this test is making sure that we get a warning when you call this and don't use the return value. It requires C++20 and above, hence the massive UNSUPPORTED list


Repository:
  rCXX libc++

https://reviews.llvm.org/D50341





More information about the cfe-commits mailing list