@@ -2447,7 +2447,8 @@ napi_status napi_get_arraybuffer_info(napi_env env, |
2447 | 2447 |
|
2448 | 2448 | * `[in] env`: The environment that the API is invoked under. |
2449 | 2449 | * `[in] arraybuffer`: `napi_value` representing the `ArrayBuffer` being queried. |
2450 | | -* `[out] data`: The underlying data buffer of the `ArrayBuffer`. |
| 2450 | +* `[out] data`: The underlying data buffer of the `ArrayBuffer`. If byte_length |
| 2451 | + is `0`, this may be `NULL` or any other pointer value. |
2451 | 2452 | * `[out] byte_length`: Length in bytes of the underlying data buffer. |
2452 | 2453 |
|
2453 | 2454 | Returns `napi_ok` if the API succeeded. |
@@ -2479,6 +2480,7 @@ napi_status napi_get_buffer_info(napi_env env, |
2479 | 2480 | * `[in] env`: The environment that the API is invoked under. |
2480 | 2481 | * `[in] value`: `napi_value` representing the `node::Buffer` being queried. |
2481 | 2482 | * `[out] data`: The underlying data buffer of the `node::Buffer`. |
| 2483 | + If length is `0`, this may be `NULL` or any other pointer value. |
2482 | 2484 | * `[out] length`: Length in bytes of the underlying data buffer. |
2483 | 2485 |
|
2484 | 2486 | Returns `napi_ok` if the API succeeded. |
@@ -2532,7 +2534,8 @@ napi_status napi_get_typedarray_info(napi_env env, |
2532 | 2534 | * `[out] length`: The number of elements in the `TypedArray`. |
2533 | 2535 | * `[out] data`: The data buffer underlying the `TypedArray` adjusted by |
2534 | 2536 | the `byte_offset` value so that it points to the first element in the |
2535 | | - `TypedArray`. |
| 2537 | + `TypedArray`. If the length of the array is `0`, this may be `NULL` or |
| 2538 | + any other pointer value. |
2536 | 2539 | * `[out] arraybuffer`: The `ArrayBuffer` underlying the `TypedArray`. |
2537 | 2540 | * `[out] byte_offset`: The byte offset within the underlying native array |
2538 | 2541 | at which the first element of the arrays is located. The value for the data |
@@ -2567,6 +2570,7 @@ napi_status napi_get_dataview_info(napi_env env, |
2567 | 2570 | properties to query. |
2568 | 2571 | * `[out] byte_length`: `Number` of bytes in the `DataView`. |
2569 | 2572 | * `[out] data`: The data buffer underlying the `DataView`. |
| 2573 | + If byte_length is `0`, this may be `NULL` or any other pointer value. |
2570 | 2574 | * `[out] arraybuffer`: `ArrayBuffer` underlying the `DataView`. |
2571 | 2575 | * `[out] byte_offset`: The byte offset within the data buffer from which |
2572 | 2576 | to start projecting the `DataView`. |
|