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

Unified Diff: third_party/WebKit/Source/platform/CrossThreadCopier.h

Issue 2422793002: HTML MessagePort as mojo::MessagePipeHandle (Closed)
Patch Set: Add missing ScopedAsyncTaskScheduler instance for the new unit tests; required by a recent change t… Created 3 years, 10 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: third_party/WebKit/Source/platform/CrossThreadCopier.h
diff --git a/third_party/WebKit/Source/platform/CrossThreadCopier.h b/third_party/WebKit/Source/platform/CrossThreadCopier.h
index a46f9d606f4a430841ceaa3c084234b076f11c17..fd55b9cd583f4a3dd8314b5e52543bb8c321cfd1 100644
--- a/third_party/WebKit/Source/platform/CrossThreadCopier.h
+++ b/third_party/WebKit/Source/platform/CrossThreadCopier.h
@@ -149,6 +149,16 @@ struct CrossThreadCopier<std::unique_ptr<T, Deleter>> {
}
};
+template <typename T, size_t inlineCapacity, typename Allocator>
+struct CrossThreadCopier<
+ Vector<std::unique_ptr<T>, inlineCapacity, Allocator>> {
+ STATIC_ONLY(CrossThreadCopier);
+ using Type = Vector<std::unique_ptr<T>, inlineCapacity, Allocator>;
+ static Type copy(Type pointer) {
+ return pointer; // This is in fact a move.
+ }
+};
+
template <typename T>
struct CrossThreadCopier<CrossThreadPersistent<T>>
: public CrossThreadCopierPassThrough<CrossThreadPersistent<T>> {

Powered by Google App Engine
This is Rietveld 408576698