mirror of
https://github.com/oven-sh/bun
synced 2026-02-17 22:32:06 +00:00
`ArrayBuffer.resize()` was typed as returning `ArrayBuffer` but per the ECMAScript spec it returns `undefined` (`void` in TS). The parameter was also made optional to match TypeScript's `lib.es2024.arraybuffer.d.ts`. `Promise.withResolvers().resolve` had its `value` parameter marked as optional, but it should be required per TypeScript's `lib.es2024.promise.d.ts`. The optional parameter caused type incompatibility errors with libraries like core-js that also declare these types. Adds a compatibility test that fetches type definitions from the upstream core-js v4-types branch at runtime to catch future regressions. Closes #26868 Co-Authored-By: Claude <noreply@anthropic.com>