diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2018-08-02 17:33:33 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2018-08-02 17:33:33 +0000 |
commit | 315d10f09ee888005b1da55e7bbb57d8a79b8447 (patch) | |
tree | 99a16e8c2272e507281e63fac5970e0548df04ea /test/std/language.support/support.runtime/cstdlib.pass.cpp | |
parent | f36202620b428c45a1c8d91743727c9313424fb2 (diff) | |
download | src-315d10f09ee888005b1da55e7bbb57d8a79b8447.tar.gz src-315d10f09ee888005b1da55e7bbb57d8a79b8447.zip |
Vendor import of libc++ trunk r338536:vendor/libc++/libc++-trunk-r338536
Notes
Notes:
svn path=/vendor/libc++/dist/; revision=337143
svn path=/vendor/libc++/libc++-trunk-r338536/; revision=337144; tag=vendor/libc++/libc++-trunk-r338536
Diffstat (limited to 'test/std/language.support/support.runtime/cstdlib.pass.cpp')
-rw-r--r-- | test/std/language.support/support.runtime/cstdlib.pass.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/std/language.support/support.runtime/cstdlib.pass.cpp b/test/std/language.support/support.runtime/cstdlib.pass.cpp index 60f7d954db54..e9dda6cee4ee 100644 --- a/test/std/language.support/support.runtime/cstdlib.pass.cpp +++ b/test/std/language.support/support.runtime/cstdlib.pass.cpp @@ -13,6 +13,8 @@ #include <type_traits> #include <cassert> +#include "test_macros.h" + // As of 1/10/2015 clang emits a -Wnonnull warnings even if the warning occurs // in an unevaluated context. For this reason we manually suppress the warning. #if defined(__clang__) @@ -71,6 +73,14 @@ int main() static_assert((std::is_same<decltype(std::strtoull("", endptr,0)), unsigned long long>::value), ""); static_assert((std::is_same<decltype(std::rand()), int>::value), ""); static_assert((std::is_same<decltype(std::srand(0)), void>::value), ""); + +// Microsoft does not implement aligned_alloc in their C library +#ifndef TEST_COMPILER_C1XX +#if TEST_STD_VER > 14 && defined(TEST_HAS_C11_FEATURES) + static_assert((std::is_same<decltype(std::aligned_alloc(0,0)), void*>::value), ""); +#endif +#endif + static_assert((std::is_same<decltype(std::calloc(0,0)), void*>::value), ""); static_assert((std::is_same<decltype(std::free(0)), void>::value), ""); static_assert((std::is_same<decltype(std::malloc(0)), void*>::value), ""); |