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

fix: crash on a recursive interface with an intersection type #1040

Merged
merged 2 commits into from Nov 30, 2021

Conversation

tuner
Copy link
Contributor

@tuner tuner commented Nov 30, 2021

This PR closes #1038

IntersectionTypeFormatter was doing some premature culling on the child types, which may have been a reasonable optimization previously. However, RemoveUnreachable.ts, which was introduced later as a post-processing step, seems to do the pruning properly, making the optimization in the formatter unnecessary.

This doesn't seem to cause performance regressions. Running the test suite took ~270s before and after the fix.

The test case fails on next branch, passes on this.

@domoritz
Copy link
Member

Thank you. This doesn't by any chance also fix #1029?

@tuner
Copy link
Contributor Author

tuner commented Nov 30, 2021

Doesn't seem to have effect on that. I just tested. The problem there is on the parser side (?) but this was in a formatter.

@domoritz
Copy link
Member

Thanks for checking.

@domoritz domoritz merged commit 70ce3a7 into vega:next Nov 30, 2021
@github-actions
Copy link

🚀 PR was released in v0.97.1-next.0 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Crash on a recursive interface with an intersection type at root
2 participants