summaryrefslogtreecommitdiffstats
path: root/libcxx
diff options
context:
space:
mode:
authorCasey Carter <Casey@Carter.net>2019-10-14 19:05:04 +0000
committerCasey Carter <Casey@Carter.net>2019-10-14 19:05:04 +0000
commitfcad66f165a778ee8aeb4ca7a9903b9d9b082df7 (patch)
tree736b1cd0f5e4c1e0dfac6215935a431ce5f5394d /libcxx
parent4e4b4f4099a6fdff9caba93535c8f5e23f10a40f (diff)
downloadbcm5719-llvm-fcad66f165a778ee8aeb4ca7a9903b9d9b082df7.tar.gz
bcm5719-llvm-fcad66f165a778ee8aeb4ca7a9903b9d9b082df7.zip
[libc++][test] Portability fix for std::any tests
Ensure that `large_tracked_t` defined in `any_helpers.h` is in fact too large to fit in `std::any`'s small object buffer. llvm-svn: 374806
Diffstat (limited to 'libcxx')
-rw-r--r--libcxx/test/support/any_helpers.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/test/support/any_helpers.h b/libcxx/test/support/any_helpers.h
index 099bcec4289..6bdc3fd4336 100644
--- a/libcxx/test/support/any_helpers.h
+++ b/libcxx/test/support/any_helpers.h
@@ -414,10 +414,10 @@ struct large_tracked_t {
: arg_types(&makeArgumentID<std::initializer_list<int>, Args...>()) {}
TypeID const* arg_types;
- int dummy[10];
+ int dummy[sizeof(std::any) / sizeof(int) + 1];
};
-static_assert(!IsSmallObject<large_tracked_t>::value, "must be small");
+static_assert(!IsSmallObject<large_tracked_t>::value, "must not be small");
template <class Type, class ...Args>
OpenPOWER on IntegriCloud