meta: add c++ wrapper of core module
This commit is contained in:
20
core-mm/object.cpp
Normal file
20
core-mm/object.cpp
Normal file
@@ -0,0 +1,20 @@
|
||||
#include <blue/core/object.hpp>
|
||||
|
||||
namespace blue::core
|
||||
{
|
||||
|
||||
object::object(object &&other)
|
||||
{
|
||||
ptr_ = other.ptr_;
|
||||
other.ptr_ = nullptr;
|
||||
}
|
||||
|
||||
object::~object()
|
||||
{
|
||||
if (ptr_) {
|
||||
b_object_unref(ptr_);
|
||||
ptr_ = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user