Chromium Code Reviews| Index: mojo/public/python/src/common.h |
| diff --git a/mojo/public/python/src/common.h b/mojo/public/python/src/common.h |
| index 4eae72e51c4be1d7dd4768bd4f33d2f3cf6cc6ab..2ada2a411787bbea4d77d4c8571e195d23b101cc 100644 |
| --- a/mojo/public/python/src/common.h |
| +++ b/mojo/public/python/src/common.h |
| @@ -37,18 +37,19 @@ class ScopedPyRef { |
| public: |
| explicit ScopedPyRef(PyObject* object); |
| ScopedPyRef(PyObject* object, ScopedPyRefAcquire); |
| + ScopedPyRef(const ScopedPyRef& other); |
|
etiennej
2015/02/24 13:30:23
Then, unless I am missing something, you don't nee
qsr
2015/02/24 13:32:14
As discussed offline, I do, as the return value fo
|
| ~ScopedPyRef(); |
| // Releases ownership of the python object contained by this instance. |
| PyObject* Release(); |
| - operator PyObject*() const; |
| + operator PyObject*() const { return object_; } |
| + |
| + ScopedPyRef& operator=(const ScopedPyRef& other); |
| private: |
| PyObject* object_; |
| - |
| - MOJO_DISALLOW_COPY_AND_ASSIGN(ScopedPyRef); |
| }; |