Skip to content

typings: add encodeIntoResults to EncodingBinding - #65350

Open
greenheadHQ wants to merge 1 commit into
nodejs:mainfrom
greenheadHQ:feat/encoding-binding-encode-into-results
Open

typings: add encodeIntoResults to EncodingBinding#65350
greenheadHQ wants to merge 1 commit into
nodejs:mainfrom
greenheadHQ:feat/encoding-binding-encode-into-results

Conversation

@greenheadHQ

Copy link
Copy Markdown
Contributor

This adds the existing encodeIntoResults Uint32Array property to the internal EncodingBinding declaration.

The native binding exposes this two-element result buffer, and lib/internal/encoding.js already consumes it for the read and written values returned by TextEncoder.encodeInto().

No runtime behavior is changed.

Tests:

  • make JOBS=10
  • ./node test/wpt/test-encoding.js
  • Targeted TypeScript check: TS2339 before the change and no diagnostics after

Signed-off-by: greenhead <shren0812@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants