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

Unified Diff: sandbox/win/src/policy_engine_opcodes.h

Issue 821693003: replace COMPILE_ASSERT with static_assert in sandbox/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 5 years, 11 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
« no previous file with comments | « sandbox/win/src/crosscall_params.h ('k') | sandbox/win/src/policy_low_level.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/win/src/policy_engine_opcodes.h
diff --git a/sandbox/win/src/policy_engine_opcodes.h b/sandbox/win/src/policy_engine_opcodes.h
index 741ebe39084d30616f371b8b85dba70f92530072..17d1764b1c860185141fbf2ed1ca5c410b90f7c2 100644
--- a/sandbox/win/src/policy_engine_opcodes.h
+++ b/sandbox/win/src/policy_engine_opcodes.h
@@ -154,7 +154,7 @@ class PolicyOpcode {
// from 0 to < kArgumentCount.
template <typename T>
void GetArgument(size_t index, T* argument) const {
- COMPILE_ASSERT(sizeof(T) <= sizeof(arguments_[0]), invalid_size);
+ static_assert(sizeof(T) <= sizeof(arguments_[0]), "invalid size");
*argument = *reinterpret_cast<const T*>(&arguments_[index].mem);
}
@@ -162,7 +162,7 @@ class PolicyOpcode {
// from 0 to < kArgumentCount.
template <typename T>
void SetArgument(size_t index, const T& argument) {
- COMPILE_ASSERT(sizeof(T) <= sizeof(arguments_[0]), invalid_size);
+ static_assert(sizeof(T) <= sizeof(arguments_[0]), "invalid size");
*reinterpret_cast<T*>(&arguments_[index].mem) = argument;
}
« no previous file with comments | « sandbox/win/src/crosscall_params.h ('k') | sandbox/win/src/policy_low_level.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698