Index: base/stack_container_unittest.cc |
diff --git a/base/stack_container_unittest.cc b/base/stack_container_unittest.cc |
index 175df36d3cdb9081b232f3b46d1ca09b0ca3a1d7..03b520a7cc8b433f8261e83f557b11f34bdfddb5 100644 |
--- a/base/stack_container_unittest.cc |
+++ b/base/stack_container_unittest.cc |
@@ -121,9 +121,17 @@ TEST(StackContainer, BufferAlignment) { |
doubles->push_back(0.0); |
EXPECT_ALIGNED(&doubles[0], ALIGNOF(double)); |
+ StackVector<AlignedData<16>, 1> aligned16; |
+ aligned16->push_back(AlignedData<16>()); |
+ EXPECT_ALIGNED(&aligned16[0], 16); |
+ |
+#if !defined(OS_ANDROID) |
+ // It seems that android doesn't respect greater than 16 byte alignment for |
+ // non-POD data on the stack, even though ALIGNOF(aligned256) == 256. |
StackVector<AlignedData<256>, 1> aligned256; |
aligned256->push_back(AlignedData<256>()); |
EXPECT_ALIGNED(&aligned256[0], 256); |
+#endif |
} |
#ifdef COMPILER_MSVC |