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

Unified Diff: base/message_loop_unittest.cc

Issue 4192012: Convert implicit scoped_refptr constructor calls to explicit ones, part 1 (Closed) Base URL: http://git.chromium.org/git/chromium.git
Patch Set: fix presubmit Created 10 years, 2 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 | « base/message_loop_proxy_impl.cc ('k') | base/metrics/field_trial_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop_unittest.cc
diff --git a/base/message_loop_unittest.cc b/base/message_loop_unittest.cc
index 8cce8ea5217fb6405f4b6895dfef6c8529dd9236..a3c330728ea2ef5d38d769cf13674ce60faf88ce 100644
--- a/base/message_loop_unittest.cc
+++ b/base/message_loop_unittest.cc
@@ -95,7 +95,7 @@ void RunTest_PostTask(MessageLoop::Type message_loop_type) {
MessageLoop loop(message_loop_type);
// Add tests to message loop
- scoped_refptr<Foo> foo = new Foo();
+ scoped_refptr<Foo> foo(new Foo());
std::string a("a"), b("b"), c("c"), d("d");
MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
foo.get(), &Foo::Test0));
@@ -111,7 +111,7 @@ void RunTest_PostTask(MessageLoop::Type message_loop_type) {
foo.get(), &Foo::Test2Mixed, a, &d));
// After all tests, post a message that will shut down the message loop
- scoped_refptr<QuitMsgLoop> quit = new QuitMsgLoop();
+ scoped_refptr<QuitMsgLoop> quit(new QuitMsgLoop());
MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
quit.get(), &QuitMsgLoop::QuitNow));
@@ -126,7 +126,7 @@ void RunTest_PostTask_SEH(MessageLoop::Type message_loop_type) {
MessageLoop loop(message_loop_type);
// Add tests to message loop
- scoped_refptr<Foo> foo = new Foo();
+ scoped_refptr<Foo> foo(new Foo());
std::string a("a"), b("b"), c("c"), d("d");
MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
foo.get(), &Foo::Test0));
@@ -142,7 +142,7 @@ void RunTest_PostTask_SEH(MessageLoop::Type message_loop_type) {
foo.get(), &Foo::Test2Mixed, a, &d));
// After all tests, post a message that will shut down the message loop
- scoped_refptr<QuitMsgLoop> quit = new QuitMsgLoop();
+ scoped_refptr<QuitMsgLoop> quit(new QuitMsgLoop());
MessageLoop::current()->PostTask(FROM_HERE, NewRunnableMethod(
quit.get(), &QuitMsgLoop::QuitNow));
« no previous file with comments | « base/message_loop_proxy_impl.cc ('k') | base/metrics/field_trial_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698