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

Unified Diff: chrome/installer/setup/setup_main.cc

Issue 1468803002: Switch to static_assert. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@assert1
Patch Set: message cleanup Created 5 years, 1 month 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 | « chrome/browser/extensions/window_controller.cc ('k') | chrome/installer/util/channel_info.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/setup/setup_main.cc
diff --git a/chrome/installer/setup/setup_main.cc b/chrome/installer/setup/setup_main.cc
index 91a6cce7ff0b6bca6107feec4ca18e1f3a077430..c3c575a8a7b87c8b30a1d06cda15428b5cca8b3c 100644
--- a/chrome/installer/setup/setup_main.cc
+++ b/chrome/installer/setup/setup_main.cc
@@ -1499,9 +1499,8 @@ InstallStatus InstallProductsHelper(const InstallationState& original_state,
bool proceed_with_installation = true;
uint32 higher_products = 0;
- COMPILE_ASSERT(
- sizeof(higher_products) * 8 > BrowserDistribution::NUM_TYPES,
- too_many_distribution_types_);
+ static_assert(sizeof(higher_products) * 8 > BrowserDistribution::NUM_TYPES,
+ "too many distribution types");
const Products& products = installer_state.products();
for (Products::const_iterator it = products.begin(); it < products.end();
++it) {
@@ -1519,8 +1518,8 @@ InstallStatus InstallProductsHelper(const InstallationState& original_state,
}
if (higher_products != 0) {
- COMPILE_ASSERT(BrowserDistribution::NUM_TYPES == 3,
- add_support_for_new_products_here_);
+ static_assert(BrowserDistribution::NUM_TYPES == 3,
+ "add support for new products here");
int message_id = IDS_INSTALL_HIGHER_VERSION_BASE;
proceed_with_installation = false;
install_status = HIGHER_VERSION_EXISTS;
« no previous file with comments | « chrome/browser/extensions/window_controller.cc ('k') | chrome/installer/util/channel_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698