diff options
author | Akira Hatanaka <ahatanaka@apple.com> | 2017-06-30 18:50:23 +0000 |
---|---|---|
committer | Akira Hatanaka <ahatanaka@apple.com> | 2017-06-30 18:50:23 +0000 |
commit | 539cb66beab99d1e1730a74e81442d9fdcff6568 (patch) | |
tree | 71dea06cdda283f75da2fbbeae4e4ed17cb98684 /libcxx/test/std/language.support/support.dynamic | |
parent | cd6d9f3e5aba061390a90505e109fc65fb8dea31 (diff) | |
download | bcm5719-llvm-539cb66beab99d1e1730a74e81442d9fdcff6568.tar.gz bcm5719-llvm-539cb66beab99d1e1730a74e81442d9fdcff6568.zip |
Revert "[libcxx] Annotate c++17 aligned new/delete operators with availability"
This reverts commit r306310.
r306310 causes clang to reject a call to an aligned allocation or
deallocation function if it is not implemented in the standard library
of the deployment target. This is not the desired behavior when users
have defined their own aligned functions.
rdar://problem/32664169
llvm-svn: 306859
Diffstat (limited to 'libcxx/test/std/language.support/support.dynamic')
-rw-r--r-- | libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.placement/new_deployment.fail.cpp | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.placement/new_deployment.fail.cpp b/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.placement/new_deployment.fail.cpp deleted file mode 100644 index f9f487dc7ef..00000000000 --- a/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.placement/new_deployment.fail.cpp +++ /dev/null @@ -1,36 +0,0 @@ -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -// UNSUPPORTED: c++98, c++03, c++11, c++14 -// REQUIRES: availability=macosx10.12 - -// test availability of new/delete operators introduced in c++17. - -#include <new> - -int main () { - int *p0 = new ((std::align_val_t)16) int(1); - (void)p0; - int *p1 = new ((std::align_val_t)16) int[1]; - (void)p1; - // expected-error@-4 {{call to unavailable function 'operator new': introduced in macOS 10.13}} - // expected-note@new:* {{candidate function has been explicitly made unavailable}} - // expected-note@new:* {{candidate function not viable: no known conversion from 'std::align_val_t' to 'const std::nothrow_t' for 2nd argument}} - // expected-note@new:* {{candidate function not viable: no known conversion from 'std::align_val_t' to 'void *' for 2nd argument}} - // expected-note@new:* {{candidate function not viable: requires single argument '__sz', but 2 arguments were provided}} - // expected-note@new:* {{candidate function not viable: requires 3 arguments, but 2 were provided}} - - // expected-error@-9 {{call to unavailable function 'operator new[]': introduced in macOS 10.13}} - // expected-note@new:* {{candidate function has been explicitly made unavailable}} - // expected-note@new:* {{candidate function not viable: no known conversion from 'std::align_val_t' to 'const std::nothrow_t' for 2nd argument}} - // expected-note@new:* {{candidate function not viable: no known conversion from 'std::align_val_t' to 'void *' for 2nd argument}} - // expected-note@new:* {{candidate function not viable: requires single argument '__sz', but 2 arguments were provided}} - // expected-note@new:* {{candidate function not viable: requires 3 arguments, but 2 were provided}} - return 0; -} |