Skip to content

Make sure an ArrayBuffer never has a NULL data pointer - #1437

Merged
saghul merged 1 commit into
masterfrom
uint8array-not-null
Apr 1, 2026
Merged

saghul merged 1 commit into
masterfrom
uint8array-not-null

Conversation

@saghul

@saghul saghul commented Apr 1, 2026

Copy link
Copy Markdown
Contributor

This reverts 6734b76.

I was wrong on the direction of that fix. The reulting API is very
un-ergonomic: one needs to check for exceptions in case of a NULL return
since it would've been legit, and creaes an asymetry with string APIs
that return a pointer, but NULL on error.

This reverts 6734b76.

I was wrong on the direction of that fix. The reulting API is very
un-ergonomic: one needs to check for exceptions in case of a NULL return
since it would've been legit, and creaes an asymetry with string APIs
that return a pointer, but NULL on error.
@saghul

saghul commented Apr 1, 2026

Copy link
Copy Markdown
Contributor Author

@bnoordhuis PTAL. I had tunnel vision here, and only realized this was wrong after trying to make it work in txiki.js: saghul/txiki.js@9f0dda2 yeah, bad idea...

@saghul
saghul merged commit f4b23b2 into master Apr 1, 2026
122 checks passed
@saghul
saghul deleted the uint8array-not-null branch April 1, 2026 19:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants