Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(433)

Unified Diff: base/stack_container.h

Issue 10796020: Upgrade AlignedMemory to support dynamic allocations. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments. Remove unused imports. Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: base/stack_container.h
diff --git a/base/stack_container.h b/base/stack_container.h
index c5897836db96b163d144121e4337ca190476523d..310ca5d9a7a76024d6174ff6f452f2cd4f064be6 100644
--- a/base/stack_container.h
+++ b/base/stack_container.h
@@ -52,7 +52,7 @@ class StackAllocator : public std::allocator<T> {
// The buffer itself. It is not of type T because we don't want the
// constructors and destructors to be automatically called. Define a POD
// buffer of the right size instead.
- base::AlignedMemory<sizeof(T[stack_capacity]), ALIGNOF(T)> stack_buffer_;
+ base::AlignedMemory<ALIGNOF(T), sizeof(T[stack_capacity])> stack_buffer_;
#if defined(OS_ANDROID)
COMPILE_ASSERT(ALIGNOF(T) <= 16, crbug_115612);
#endif

Powered by Google App Engine
This is Rietveld 408576698