Consistently extract synthesized delegate info from method symbol#64966
Merged
jjonescz merged 12 commits intodotnet:features/lambda-default-parametersfrom Nov 1, 2022
Merged
Conversation
jjonescz
commented
Oct 25, 2022
Member
Author
333fred
approved these changes
Oct 27, 2022
Member
333fred
left a comment
There was a problem hiding this comment.
One minor nit, otherwise LGTM
cston
reviewed
Oct 27, 2022
cston
reviewed
Oct 31, 2022
src/Compilers/CSharp/Test/Semantic/Semantics/NullableReferenceTypesTests.cs
Show resolved
Hide resolved
cston
reviewed
Oct 31, 2022
src/Compilers/CSharp/Test/Semantic/Semantics/NullableReferenceTypesTests.cs
Show resolved
Hide resolved
cston
reviewed
Oct 31, 2022
src/Compilers/CSharp/Test/Semantic/Semantics/NullableReferenceTypesTests.cs
Outdated
Show resolved
Hide resolved
cston
approved these changes
Oct 31, 2022
333fred
approved these changes
Oct 31, 2022
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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 consolidates learnings from #64823 and #64932 but without the actual attribute forwarding from lambdas to synthesized delegate types.
In particular,
Binder.GetMethodGroupOrLambdaDelegateTypeis updated to consistently derive information it needs fromMethodSymbolas suggested in #64823 (comment). (See the first commit: 27d5cfe.)This in turn fixes a bug where
DefaultParameterValuewas allowed withoutOptionalin lambdas. (See the second commit: 5a60ba7.)Tests of
[CallerMemberName]+friends and[AllowNull]+friends in lambdas were also enabled in this PR since the decision about attribute forwarding has been made. (See the rest of the commits.)Relates to test plan #62485.