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

Unified Diff: base/win/scoped_comptr.h

Issue 1467003002: Switch to static_assert in base/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: / 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 | « base/win/scoped_bstr.cc ('k') | base/win/scoped_variant.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/win/scoped_comptr.h
diff --git a/base/win/scoped_comptr.h b/base/win/scoped_comptr.h
index ade12fe549abb0c202708452e9ad12ffb9e817de..5ce60e2b688f603b2b681e42a270e41e6156f704 100644
--- a/base/win/scoped_comptr.h
+++ b/base/win/scoped_comptr.h
@@ -43,8 +43,9 @@ class ScopedComPtr : public scoped_refptr<Interface> {
~ScopedComPtr() {
// We don't want the smart pointer class to be bigger than the pointer
// it wraps.
- COMPILE_ASSERT(sizeof(ScopedComPtr<Interface, interface_id>) ==
- sizeof(Interface*), ScopedComPtrSize);
+ static_assert(
+ sizeof(ScopedComPtr<Interface, interface_id>) == sizeof(Interface*),
+ "ScopedComPtrSize");
}
// Explicit Release() of the held object. Useful for reuse of the
« no previous file with comments | « base/win/scoped_bstr.cc ('k') | base/win/scoped_variant.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698