Skip to content

fix(console): inspect typed arrays and buffers with null prototypes - #37268

Open
hari714 wants to merge 1 commit into
denoland:mainfrom
hari714:fix/inspect-null-prototype-buffers
Open

hari714 wants to merge 1 commit into
denoland:mainfrom
hari714:fix/inspect-null-prototype-buffers

Conversation

@hari714

@hari714 hari714 commented Dec 2, 2026 •

Copy link
Copy Markdown

Fixes #20476.

When a typed array has a null prototype, Deno.inspect() now displays its element type. For ArrayBuffer and SharedArrayBuffer with a null prototype, it reads the byte length from the buffer even when the prototype getter is absent.

Added regression tests for numeric and BigInt typed arrays and for both buffer types. Both tests reproduced the issue on Deno 2.9.8. All 93 tests in tests/unit/console_test.ts passed on the patched macOS arm64 build.

AI disclosure: I used OpenAI Codex to investigate the issue.

Workspace lint stopped when the disk ran out of space during Clippy. All 93 console tests passed.

This branch has not been deployed

No deployments
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.

Deno.inspect inconsistent when formatting intrinsic objects

1 participant