Browse Source

Add copy ctor to WeakPtr.

tags/v2.0.0
Andrew Belt 3 years ago
parent
commit
077064f069
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      include/weakptr.hpp

+ 3
- 0
include/weakptr.hpp View File

@@ -51,6 +51,9 @@ struct WeakPtr {
WeakPtr(T* ptr) {
set(ptr);
}
WeakPtr(const WeakPtr& other) {
set(other.get());
}
WeakPtr& operator=(const WeakPtr& other) {
set(other.get());
return *this;


Loading…
Cancel
Save