node-api: provide napi_define_properties fast path#48440
Closed
gabrielschulhof wants to merge 1 commit intonodejs:mainfrom
Closed
node-api: provide napi_define_properties fast path#48440gabrielschulhof wants to merge 1 commit intonodejs:mainfrom
gabrielschulhof wants to merge 1 commit intonodejs:mainfrom
Conversation
Collaborator
|
Review requested:
|
e9a4032 to
d8299a4
Compare
Contributor
Author
|
d8299a4 to
9e08c8b
Compare
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: nodejs#45905 Signed-off-by: Gabriel Schulhof <Gschulhof@auction.com>
9e08c8b to
4049162
Compare
anonrig
approved these changes
Jun 14, 2023
Collaborator
Collaborator
Collaborator
tniessen
approved these changes
Jun 15, 2023
legendecas
approved these changes
Jun 15, 2023
|
|
||
| auto define_maybe = | ||
| obj->DefineProperty(context, property_name, descriptor); | ||
| defined_successfully = define_maybe.FromMaybe(false); |
Member
There was a problem hiding this comment.
I think we should distinguish the state that the DefineProperty operation is failed (e.g. when the object is frozen) or the DefineProperty operation is throwing (e.g. a throwing Proxy handler defineProperty) and returning a different napi_status. As this behavior is not introduced in this PR, I'll create a follow-up PR to do so.
gabrielschulhof
added a commit
that referenced
this pull request
Jun 16, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: #45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: #48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Contributor
Author
|
Landed in 3c35cd4. |
29 tasks
RafaelGSS
pushed a commit
that referenced
this pull request
Jul 3, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: #45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: #48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Merged
Ceres6
pushed a commit
to Ceres6/node
that referenced
this pull request
Aug 14, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: nodejs#45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: nodejs#48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Ceres6
pushed a commit
to Ceres6/node
that referenced
this pull request
Aug 14, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: nodejs#45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: nodejs#48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
ruyadorno
pushed a commit
that referenced
this pull request
Sep 8, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: #45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: #48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Merged
ruyadorno
pushed a commit
that referenced
this pull request
Sep 13, 2023
Implement defining properties via V8's `v8::Object::CreateDataProperty()`, which is faster for data-valued, writable, configurable, and enumerable properties. Re: #45905 Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com> PR-URL: #48440 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implement defining properties via V8's
v8::Object::CreateDataProperty(), which is faster for data-valued,writable, configurable, and enumerable properties.
Re: #45905