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

Unified Diff: mojo/public/bindings/sample/sample_service_unittests.cc

Issue 109103003: Mojo: abstract interface implementation from generated Stub classes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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: mojo/public/bindings/sample/sample_service_unittests.cc
diff --git a/mojo/public/bindings/sample/sample_service_unittests.cc b/mojo/public/bindings/sample/sample_service_unittests.cc
index 4ad4ae889a45e49932d87900f80a2dabfec2ab76..6a9333aca12050c479ea13e74516103fb8ed3774 100644
--- a/mojo/public/bindings/sample/sample_service_unittests.cc
+++ b/mojo/public/bindings/sample/sample_service_unittests.cc
@@ -238,7 +238,7 @@ static void DumpHex(const uint8_t* bytes, uint32_t num_bytes) {
}
}
-class ServiceImpl : public ServiceStub {
+class ServiceImpl : public Service {
public:
virtual void Frobinate(const Foo& foo, bool baz,
mojo::ScopedMessagePipeHandle port)
@@ -273,8 +273,8 @@ class SimpleMessageReceiver : public mojo::MessageReceiver {
// the system. It receives the incoming message.
ServiceImpl impl;
- ServiceStub* stub = &impl;
- return stub->Accept(message);
+ ServiceStub stub(&impl);
+ return stub.Accept(message);
}
};

Powered by Google App Engine
This is Rietveld 408576698