Browse Source

Clarify doc for WeakPtr.

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

+ 2
- 1
include/weakptr.hpp View File

@@ -41,7 +41,8 @@ Example:
delete foo; delete foo;
weakFoo.get(); // returns nullptr weakFoo.get(); // returns nullptr


Caveat: In multithreaded environments, the object pointed to by the WeakPtr could be deleted at any time after obtaining its pointer from WeakPtr.
Not thread safe.
In multithreaded environments, the object pointed to by the WeakPtr could be deleted at any time after obtaining its pointer from WeakPtr.
*/ */
template <typename T> template <typename T>
struct WeakPtr { struct WeakPtr {


Loading…
Cancel
Save