This repository was archived by the owner on Jan 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 173
Support for type argument inference for direct recursions #576
Merged
Conversation
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
…signment (set-statements and copy-and-updates for arrays)
…hen the parameters are resolved by the call
Contributor
|
I've made some suggestions to the references in the test, but it's hard to tell if it was done intentionally or if it was just a copy-paste issue. It would really help if the tests were named in a way that conveyed what they were testing rather than the generic "VariableDeclaration#". Maybe a doc comment for each of them describing the scenario being tested would give a bit more room to be more verbose in explaining what they are for. Without that, it can be a bit difficult to tell what the goal was for each. |
bamarsha
reviewed
Aug 19, 2020
bamarsha
reviewed
Aug 19, 2020
bamarsha
approved these changes
Aug 19, 2020
Contributor
bamarsha
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only sort of understand the verification code, but it seems reasonable, thanks for fixing this!
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.
This PR
1.) adds support for inferring type arguments for direct recursions
2.) prevents the assignment of type parametrized callables within the parent callable, including
a) bindings in let, mutable, set, and return statements
b) we don't give separate diagnostics for copy-and-update expressions (already covered by a))
This fixes in particular #574.
More or less, 1. requires the changes in ExpressionVerification.fs, and 2. requires the changes in StatementVerification.fs.
This PR requires that microsoft/qsharp-runtime#351 is merged first.