Fix the release function in the ValuePtr class (#4490)

This commit is contained in:
Leila F. Rahman 2022-09-24 13:25:06 +02:00 committed by GitHub
parent 2808fc615e
commit 70c844ddfb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -53,8 +53,11 @@ public:
}
ValuePtr(ValuePtr&& rhs) : mPtr(std::move(rhs.mPtr)), mClone(std::move(rhs.mClone)) {}
pointer release() {
return mPtr.release();
/**
* Releases the shared_ptr's ownership of the managed object using the .reset() function
*/
void release() {
mPtr.reset();
}
T* get() NOEXCEPT {