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

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

Issue 1914453002: Replace AllowCrossThreadAccess() + GCed pointers with wrapCrossThreadPersistent() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Kuroneko_2
Patch Set: Rebase. Created 4 years, 7 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 ea57c88ac758d3066d224c3da795fead247da9ee..9a4d395ac71fce24caeba9d9b22e7296385cd862 100644
--- a/third_party/WebKit/Source/platform/CrossThreadCopier.h
+++ b/third_party/WebKit/Source/platform/CrossThreadCopier.h
@@ -250,6 +250,7 @@ struct CrossThreadCopier<AllowCrossThreadAccessWrapper<T>> {
template <typename T>
AllowCrossThreadAccessWrapper<T*> AllowCrossThreadAccess(T* value)
{
+ static_assert(!blink::IsGarbageCollectedType<T>::value, "Use wrapCrossThreadPersistent() instead for garbage-collected pointers");
return AllowCrossThreadAccessWrapper<T*>(value);
}

Powered by Google App Engine
This is Rietveld 408576698