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

Unified Diff: courgette/difference_estimator.cc

Issue 857153003: Use "static_assert" in lieu of "COMPILE_ASSERT" in courgete (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 | « no previous file | courgette/encoded_program.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: courgette/difference_estimator.cc
diff --git a/courgette/difference_estimator.cc b/courgette/difference_estimator.cc
index 3b2cddc94dec0099107bfd6e643d2fc997cc1345..f2f09e15cc9cd92b6f0adcbdc88ef76ed09dd14f 100644
--- a/courgette/difference_estimator.cc
+++ b/courgette/difference_estimator.cc
@@ -18,7 +18,8 @@ const int kTupleSize = 4;
namespace {
-COMPILE_ASSERT(kTupleSize >= 4 && kTupleSize <= 8, kTupleSize_between_4_and_8);
+static_assert(kTupleSize >= 4 && kTupleSize <= 8,
+ "kTupleSize should be between 4 and 8");
size_t HashTuple(const uint8* source) {
size_t hash1 = *reinterpret_cast<const uint32*>(source);
« no previous file with comments | « no previous file | courgette/encoded_program.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698