Start working on a VFS implementation #22

Closed
apio wants to merge 44 commits from oop-vfs into main
2 changed files with 10 additions and 0 deletions
Showing only changes of commit e9e1bef89c - Show all commits

View File

@ -59,6 +59,11 @@ template <typename T> class OwnedPtr
return *m_ptr;
}
operator bool() const
{
return m_ptr != nullptr;
}
template <typename Type> friend Result<SharedPtr<Type>> adopt_shared_from_owned(OwnedPtr<Type>&&);
private:

View File

@ -99,6 +99,11 @@ template <typename T> class SharedPtr
return *m_ptr;
}
operator bool() const
{
return m_ptr != nullptr;
}
private:
T* m_ptr;
RefCount* m_ref_count;