Skip to content

Fix iterable type parameter arity for TypeScript 6 - #531

Open
christopher-buss wants to merge 1 commit into
roblox-ts:masterfrom
christopher-buss:fix/typescript-6-iterables
Open

christopher-buss wants to merge 1 commit into
roblox-ts:masterfrom
christopher-buss:fix/typescript-6-iterables

Conversation

@christopher-buss

Copy link
Copy Markdown

TypeScript 6 checks the global Iterable type before allowing ES2015 iteration. The existing one-parameter declarations fail that lookup under noLib, producing TS2802 for string, Map, and Set spreads.

Add defaulted return and next parameters to the four iterable interfaces and forward them through their iterator signatures. Existing one-argument uses retain their previous defaults. This is a prerequisite for the roblox-ts TypeScript 6.0.3 upgrade.

Generated with Codex.

Forward return and next types through synchronous and asynchronous iterable interfaces while preserving their existing defaults.

Co-authored-by: Codex <noreply@openai.com>
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.

1 participant