-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
N api dataview #14382
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
N api dataview #14382
Changes from 1 commit
43ec67d
b56c76b
3839165
5fc5ffb
260ad4e
11362b5
b5fcb56
3fdc71e
dcac0ac
afca265
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1332,7 +1332,7 @@ JavaScript TypedArray Objects are described in | |
| of the ECMAScript Language Specification. | ||
|
|
||
|
|
||
| #### *napi_create_typedarray* | ||
| #### *napi_create_dataview* | ||
| <!-- YAML | ||
| added: v8.0.0 | ||
| --> | ||
|
|
@@ -1341,7 +1341,7 @@ napi_status napi_create_dataview(napi_env env, | |
| size_t length, | ||
| napi_value arraybuffer, | ||
| size_t byte_offset, | ||
| napi_value* result) { | ||
| napi_value* result) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you align the arguments vertically (i.e. |
||
|
|
||
| ``` | ||
|
|
||
|
|
@@ -1358,12 +1358,9 @@ This API creates a JavaScript DataView object over an existing ArrayBuffer. | |
| Dataview objects provide an array-like view over an underlying data buffer, | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Capitalization: |
||
| but one which allows items of different size and type in the ArrayBuffer. | ||
|
|
||
| It's required that (length * size_of_element) + byte_offset should | ||
| be <= the size in bytes of the array passed in. If not, a RangeError exception is | ||
| raised. | ||
|
|
||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There should one here as well, with "(length * size_of_element)" replaced with |
||
| JavaScript DataView Objects are described in | ||
| [Section 22.2](https://tc39.github.io/ecma262/#sec-dataview-objects) | ||
| [Section 24.3](https://tc39.github.io/ecma262/#sec-dataview-objects) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you move the link to the bottom of the file.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I see that every napi_create_x function refers to the ECMA standards within it's section through out the document. Shouldn't we stick to this format ?
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 👍
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should now just be |
||
| of the ECMAScript Language Specification. | ||
|
|
||
| ### Functions to convert from C types to N-API | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added: REPLACEME