Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Improve]: Input limit of String.Join<> type #297

Open
anuraghazra opened this issue Mar 28, 2022 · 0 comments
Open

[Improve]: Input limit of String.Join<> type #297

anuraghazra opened this issue Mar 28, 2022 · 0 comments

Comments

@anuraghazra
Copy link

anuraghazra commented Mar 28, 2022

🐞 Bug Report

Describe the bug

Currently the Join<> type only works upto 22 input elements, after that It throws Type instantiation is excessively deep and possibly infinite.(2589)

Reproduce the bug

TSPlay

Expected behavior

Improve Join type to handle much larger inputs.

Possible Solution

Since 4.5, TS introduced tail recursion elimination on conditional types.

We can modify the Join function as such that it can handle inputs longer than 22 elements.

TSPlay

image

Screenshots

Current behaviour:
image

Additional context

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

No branches or pull requests

1 participant