Consistently error on circular constraints#30109
Merged
Merged
Conversation
Member
|
I'm guessing this will have some DT breaks |
RyanCavanaugh
approved these changes
Feb 27, 2019
Member
Author
|
@typescript-bot test this & @typescript-bot run dt |
Collaborator
|
Heya @ahejlsberg, I've started to run the Definitely Typed test suite on this PR at ecebc9f. You can monitor the build here. It should now contribute to this PR's status checks. |
Collaborator
|
Heya @ahejlsberg, I've started to run the extended test suite on this PR at ecebc9f. You can monitor the build here. It should now contribute to this PR's status checks. |
Member
Author
|
@RyanCavanaugh Best I can tell, none of the RWC and DT failures are related to this PR. And really, the only new failures this could cause are new circularity errors and there are none of those. |
weswigham
approved these changes
Feb 28, 2019
Member
|
The DT failures look like the ones from |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With this PR we consistently error when detecting circular constraints. In particular, we now report errors when circularities occur during instantiation but not when checking the original declaration. When the node currently being checked (the node referenced by
currentNode) is neither a descendant nor an ancestor of the constraint type node, we also report the current node as the associated source location in which the circularity originates.Fixes #29992.