// nor does the dynamic library shipped with z/OS.
// UNSUPPORTED: target={{.+}}-zos{{.*}}
-// TODO: Investigate why this fails on MinGW-shared
-// UNSUPPORTED: target={{.+}}-windows-gnu
-
#include <new>
#include <cstddef>
#include <cstdlib>
{
new_called = delete_called = 0;
OverAligned* x = new OverAligned[3];
- assert(static_cast<void*>(x) == DummyData);
- assert(new_called == 1);
+ ASSERT_WITH_OPERATOR_NEW_FALLBACKS(static_cast<void*>(x) == DummyData);
+ ASSERT_WITH_OPERATOR_NEW_FALLBACKS(new_called == 1);
delete[] x;
- assert(delete_called == 1);
+ ASSERT_WITH_OPERATOR_NEW_FALLBACKS(delete_called == 1);
}
// Test with a type that is right on the verge of being overaligned
// nor does the dynamic library shipped with z/OS.
// UNSUPPORTED: target={{.+}}-zos{{.*}}
-// TODO: Investigate why this fails on MinGW-shared
-// UNSUPPORTED: target={{.+}}-windows-gnu
-
#include <new>
#include <cstddef>
#include <cstdlib>
{
new_called = delete_called = 0;
OverAligned* x = new (std::nothrow) OverAligned[3];
- assert(static_cast<void*>(x) == DummyData);
+ ASSERT_WITH_OPERATOR_NEW_FALLBACKS(static_cast<void*>(x) == DummyData);
ASSERT_WITH_OPERATOR_NEW_FALLBACKS(new_called == 1);
delete[] x;
// XFAIL: libcpp-no-vcruntime
// XFAIL: LIBCXX-AIX-FIXME
-// TODO: Investigate why this fails on Windows
+// MSVC/vcruntime falls back from the nothrow array new to the nothrow
+// scalar new, instead of falling back on the throwing array new.
+// https://developercommunity.visualstudio.com/t/vcruntime-nothrow-array-operator-new-fal/10373274
// XFAIL: target={{.+}}-windows-msvc
#include <new>
// nor does the dynamic library shipped with z/OS.
// UNSUPPORTED: target={{.+}}-zos{{.*}}
-// TODO: Investigate why this fails on MinGW-shared
-// UNSUPPORTED: target={{.+}}-windows-gnu
-
#include <new>
#include <cstddef>
#include <cstdlib>
{
new_called = delete_called = 0;
OverAligned* x = new (std::nothrow) OverAligned;
- assert(static_cast<void*>(x) == DummyData);
+ ASSERT_WITH_OPERATOR_NEW_FALLBACKS(static_cast<void*>(x) == DummyData);
ASSERT_WITH_OPERATOR_NEW_FALLBACKS(new_called == 1);
delete x;