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

Unified Diff: content/test/plugin/plugin_geturl_test.cc

Issue 791923003: replace COMPILE_ASSERT with static_assert in content/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixups 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 | « content/test/plugin/plugin_get_javascript_url_test.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/plugin/plugin_geturl_test.cc
diff --git a/content/test/plugin/plugin_geturl_test.cc b/content/test/plugin/plugin_geturl_test.cc
index ed686f2a8480883fd6351912056b05541b26e0ff..c230e4d1b2a54cbf77f83efe6e88b134a8742363 100644
--- a/content/test/plugin/plugin_geturl_test.cc
+++ b/content/test/plugin/plugin_geturl_test.cc
@@ -156,8 +156,8 @@ NPError PluginGetURLTest::NewStream(NPMIMEType type, NPStream* stream,
return NPERR_NO_ERROR;
}
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(stream->notifyData),
- cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(stream->notifyData),
+ "cast validity check");
if (expect_404_response_) {
NPObject *window_obj = NULL;
@@ -242,8 +242,8 @@ int32 PluginGetURLTest::WriteReady(NPStream *stream) {
return STREAM_CHUNK;
}
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(stream->notifyData),
- cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(stream->notifyData),
+ "cast validity check");
unsigned long stream_id = reinterpret_cast<unsigned long>(
stream->notifyData);
if (stream_id == BOGUS_URL_STREAM_ID)
@@ -276,8 +276,8 @@ int32 PluginGetURLTest::Write(NPStream *stream, int32 offset, int32 len,
return -1;
}
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(stream->notifyData),
- cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(stream->notifyData),
+ "cast validity check");
unsigned long stream_id = reinterpret_cast<unsigned long>(
stream->notifyData);
switch (stream_id) {
@@ -321,8 +321,8 @@ NPError PluginGetURLTest::DestroyStream(NPStream *stream, NPError reason) {
return NPERR_INVALID_PARAM;
}
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(stream->notifyData),
- cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(stream->notifyData),
+ "cast validity check");
if (expect_404_response_) {
if (npn_evaluate_context_) {
@@ -372,8 +372,8 @@ void PluginGetURLTest::StreamAsFile(NPStream* stream, const char* fname) {
return;
}
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(stream->notifyData),
- cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(stream->notifyData),
+ "cast validity check");
unsigned long stream_id =
reinterpret_cast<unsigned long>(stream->notifyData);
switch (stream_id) {
@@ -400,7 +400,7 @@ void PluginGetURLTest::URLNotify(const char* url, NPReason reason, void* data) {
if (check_cookies_)
return;
- COMPILE_ASSERT(sizeof(unsigned long) <= sizeof(data), cast_validity_check);
+ static_assert(sizeof(unsigned long) <= sizeof(data), "cast validity check");
unsigned long stream_id = reinterpret_cast<unsigned long>(data);
switch (stream_id) {
case SELF_URL_STREAM_ID:
« no previous file with comments | « content/test/plugin/plugin_get_javascript_url_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698