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

Unified Diff: base/callback_internal.h

Issue 8224026: Add a PassScopedPtr into base/memory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Anchroed PassOwnPtr with Bind. Created 9 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
Index: base/callback_internal.h
diff --git a/base/callback_internal.h b/base/callback_internal.h
index 4f0736f0eb6ae4556c52396bc9b6f7a39a918daf..c3747225a65a644abda138c45d54a94d13007b54 100644
--- a/base/callback_internal.h
+++ b/base/callback_internal.h
@@ -12,6 +12,7 @@
#include <stddef.h>
#include "base/base_export.h"
+#include "base/memory/pass_scoped_ptr.h"
#include "base/memory/ref_counted.h"
namespace base {
@@ -130,6 +131,13 @@ struct ParamTraits<T[]> {
typedef const T* StorageType;
};
+// See comment in PassScopedPtr<> for wanted behavior.
+template <typename T>
+struct ParamTraits<subtle::TransientPassScopedPtr<T> > {
+ typedef const PassScopedPtr<T>& ForwardType;
+ typedef subtle::PassScopedPtrAnchor<T> StorageType;
+};
+
} // namespace internal
} // namespace base

Powered by Google App Engine
This is Rietveld 408576698