Skip to content

Ensure computed property names are always checked #37307

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

Merged

Conversation

weswigham
Copy link
Member

Fixes #37262

@weswigham
Copy link
Member Author

@sandersn the early bail code for object spread -

                    if (!isValidSpreadType(type)) {
                        error(memberDecl, Diagnostics.Spread_types_may_only_be_created_from_object_types);
                        return errorType;
                    }

may also be blocking other aspects of object literal checking. Would it make sense to remove the bail?

Copy link
Member

@sandersn sandersn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Current change looks fine, but you're right -- it would be better to not bail on invalid spread types.

@weswigham weswigham merged commit 4567fc4 into microsoft:master Mar 25, 2020
@weswigham weswigham deleted the ensure-computed-names-always-checked branch March 25, 2020 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

import missing with tsc 383
4 participants