new object creation interface
This commit is contained in:
parent
ca1ae75b07
commit
cf3f8dbc9c
23 changed files with 103 additions and 84 deletions
|
|
@ -12,7 +12,7 @@ void StringObject::destructor(StringObject* self) { self->val.~basic_string(); }
|
|||
void StringObject::copy(StringObject* self, const StringObject* in) { self->val = in->val; }
|
||||
|
||||
StringObject* StringObject::create(const std::string& in) {
|
||||
auto out = objects_api::cast<StringObject>(NDO->create("str"));
|
||||
auto out = objects_api::create<StringObject>();
|
||||
out->val = in;
|
||||
return out;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue