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

Unified Diff: extensions/browser/api_test_utils.cc

Issue 598173003: Run clang-modernize -use-nullptr over src/extensions/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
Index: extensions/browser/api_test_utils.cc
diff --git a/extensions/browser/api_test_utils.cc b/extensions/browser/api_test_utils.cc
index b96f4a6c5a95d1c2c73b1a6fe4c39dbd62c5a6cf..cd31003aa5343070d177355b9df9c1aa1ff6675c 100644
--- a/extensions/browser/api_test_utils.cc
+++ b/extensions/browser/api_test_utils.cc
@@ -35,7 +35,7 @@ base::Value* ParseJSON(const std::string& data) {
base::ListValue* ParseList(const std::string& data) {
base::Value* result = ParseJSON(data);
- base::ListValue* list = NULL;
+ base::ListValue* list = nullptr;
result->GetAsList(&list);
return list;
}
@@ -53,7 +53,7 @@ class SendResponseDelegate
should_post_quit_ = should_quit;
}
- bool HasResponse() { return response_.get() != NULL; }
+ bool HasResponse() { return response_.get() != nullptr; }
bool GetResponse() {
EXPECT_TRUE(HasResponse());
@@ -104,12 +104,12 @@ base::Value* RunFunctionWithDelegateAndReturnSingleResult(
RunFunction(function, args, context, dispatcher.Pass(), flags);
EXPECT_TRUE(function->GetError().empty())
<< "Unexpected error: " << function->GetError();
- const base::Value* single_result = NULL;
- if (function->GetResultList() != NULL &&
+ const base::Value* single_result = nullptr;
+ if (function->GetResultList() != nullptr &&
function->GetResultList()->Get(0, &single_result)) {
return single_result->DeepCopy();
}
- return NULL;
+ return nullptr;
}
base::Value* RunFunctionAndReturnSingleResult(

Powered by Google App Engine
This is Rietveld 408576698