Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Implement Rust-side const ExternalOneByteStringResource subclass #1275

Merged
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 17 additions & 12 deletions src/binding.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1159,15 +1159,15 @@ void v8__ObjectTemplate__SetInternalFieldCount(const v8::ObjectTemplate& self,
ptr_to_local(&self)->SetInternalFieldCount(value);
}

void v8__ObjectTemplate__SetAccessor(const v8::ObjectTemplate& self,
const v8::Name& key,
v8::AccessorNameGetterCallback getter,
v8::AccessorNameSetterCallback setter,
const v8::Value* data_or_null,
v8::PropertyAttribute attr) {
ptr_to_local(&self)->SetAccessor(ptr_to_local(&key), getter, setter,
ptr_to_local(data_or_null),
v8::AccessControl::DEFAULT, attr);
void v8__ObjectTemplate__SetAccessor(
const v8::ObjectTemplate& self, const v8::Name& key,
v8::AccessorNameGetterCallback getter,
v8::AccessorNameSetterCallback setter,
const v8::Value* data_or_null,
v8::PropertyAttribute attr) {
ptr_to_local(&self)->SetAccessor(
ptr_to_local(&key), getter, setter, ptr_to_local(data_or_null), v8::AccessControl::DEFAULT,
attr);
}

void v8__ObjectTemplate__SetNamedPropertyHandler(
Expand Down Expand Up @@ -1471,6 +1471,12 @@ const v8::Value* v8__Object__GetOwnPropertyDescriptor(
ptr_to_local(&context), ptr_to_local(&key)));
}

const v8::Array* v8__Object__PreviewEntries(
const v8::Object& self,
bool* is_key_value) {
return maybe_local_to_ptr(ptr_to_local(&self)->PreviewEntries(is_key_value));
}

const v8::Array* v8__Array__New(v8::Isolate* isolate, int length) {
return local_to_ptr(v8::Array::New(isolate, length));
}
Expand Down Expand Up @@ -1816,9 +1822,8 @@ void v8__Context__UseDefaultSecurityToken(v8::Context& self) {
ptr_to_local(&self)->UseDefaultSecurityToken();
}

void v8__Context__AllowCodeGenerationFromStrings(v8::Context& self,
bool allow) {
ptr_to_local(&self)->AllowCodeGenerationFromStrings(allow);
void v8__Context__AllowCodeGenerationFromStrings(v8::Context& self, bool allow) {
ptr_to_local(&self)->AllowCodeGenerationFromStrings(allow);
}

bool v8__Context_IsCodeGenerationFromStringsAllowed(v8::Context& self) {
Expand Down
Loading