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

Unified Diff: cc/paint/paint_op_buffer.cc

Issue 2932053002: Use C++11 alignment primitives (Closed)
Patch Set: Put back ALIGNAS Created 3 years, 6 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: cc/paint/paint_op_buffer.cc
diff --git a/cc/paint/paint_op_buffer.cc b/cc/paint/paint_op_buffer.cc
index b52b55553bf29682c57af38e4a6d7cb4e6470dac..2c6a7a7e2ce8acda84f0118b2f69f9a73fd6a5a8 100644
--- a/cc/paint/paint_op_buffer.cc
+++ b/cc/paint/paint_op_buffer.cc
@@ -194,7 +194,7 @@ TYPES(M);
#undef M
#define M(T) \
- static_assert(ALIGNOF(T) <= PaintOpBuffer::PaintOpAlign, \
+ static_assert(alignof(T) <= PaintOpBuffer::PaintOpAlign, \
#T " must have alignment no bigger than PaintOpAlign");
TYPES(M);
#undef M
@@ -780,7 +780,7 @@ std::pair<void*, size_t> PaintOpBuffer::AllocatePaintOp(size_t sizeof_op,
push<NoopOp>();
} else {
op_count_++;
- return std::make_pair(first_op_.void_data(), 0);
+ return std::pair<void*, size_t>(&first_op_, 0);
}
}

Powered by Google App Engine
This is Rietveld 408576698