-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Bug: [no-unsafe-argument] Maximum call stack size exceeded for recursive types #7298
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
Comments
Minimal reproduction: playground It seems that infinite recursion occurs in this function
|
any updates here? here is my reproducible setup: https://github.com/CycloneDX/cyclonedx-node-npm/tree/87bb87b7ee50f8625c53c84dbba98a75aa56d105
|
We are a community run project. The volunteer maintainers spend most of their time triaging issues and reviewing PRs. This means that most issues will not progress unless a member of the community steps up and champions it. If this issue is important to you — consider being that champion. |
Before You File a Bug Report Please Confirm You Have Done The Following...
Playground Link
https://typescript-eslint.io/play/#ts=5.1.6&fileType=.tsx&code=FAFwngDgpgBAKgJyrAvDA2gOwK4FsBGUCANPElOgLqXDABm2mAxiAJYD2mMuAhhIsgAUIcgC4yyUnUzjBMmDgJEAlDBQA%2BBXkIJl4gbADewGDCacAziAyYp7JFcpqYI5CZhIQ2BF3TS5ynYOIAB0vBCCwvrkqhrcfAbCUpjKyjQAvkA&eslintrc=N4KABGBEAOCGBOBnApvSAuKABALgT2mUQGN4BLaHAWiIBsyA7HAejiVUgBpwp4BXWkQxhQECJFwEipCtTqMWDAPZU%2BDRLABmyKggDmfALbImwyKnhK0PAL4gbQA&tsconfig=N4XyA&tokens=false
Repro Code
ESLint Config
tsconfig
Expected Result
I expect eslint to run without errors.
Actual Result
Additional Info
It works if I add an explicit empty array as alternative type:
type Tree = [number, Tree[] | []]
instead of:
type Tree = [number, Tree[]]
See playground example.
Result:
The text was updated successfully, but these errors were encountered: