[typeless extension receivers] Pin tests excluding throw expressions#83406
Draft
CyrusNajmabadi wants to merge 302 commits intodotnet:features/extension-members-on-typeless-receiversfrom
Conversation
added 7 commits
April 26, 2026 01:14
Consolidates four shape PRs (dotnet#83366, dotnet#83367, dotnet#83368, dotnet#83369) into a single tests PR for the NewExpression area (target-typed new() / new(args) receivers). - ClassicExtensionMethod: 4 tests. - ModernExtensionMethod: 3 tests. - ModernExtensionProperty: 3 tests. - ModernExtensionIndexer: 2 pin tests. Co-authored-by: Isaac
Consolidates four shape PRs (dotnet#83371, dotnet#83372, dotnet#83373, dotnet#83374) into a single tests PR for the NullLiteral area. - ClassicExtensionMethod: 5 tests. - ModernExtensionMethod: 3 tests. - ModernExtensionProperty: 2 tests. - ModernExtensionIndexer: 2 pin tests. Co-authored-by: Isaac
Consolidates four shape PRs (dotnet#83376, dotnet#83377, dotnet#83378, dotnet#83379). Co-authored-by: Isaac
Consolidates four shape PRs (dotnet#83381, dotnet#83382, dotnet#83383, dotnet#83384). Co-authored-by: Isaac
Consolidates four shape PRs (dotnet#83386, dotnet#83387, dotnet#83388, dotnet#83389). Co-authored-by: Isaac
Consolidates four shape PRs (dotnet#83391, dotnet#83392, dotnet#83393, dotnet#83394). Co-authored-by: Isaac
Consolidates two shape PRs (dotnet#83395, dotnet#83396) into a single tests PR for the ThrowExpression area. Throw expressions are explicitly excluded from the proposal; both tests pin that '(throw ...).M()' continues to report ERR_ThrowMisplaced. Per the agent's plan, throw is negative-only and only gets the two method shapes (no property/indexer applicability). Co-authored-by: Isaac
This was referenced Apr 25, 2026
…sOnTypelessReceiver Match the established convention in this file: call CheckFeatureAvailability for diagnostics but continue binding regardless of return value, so the SemanticModel and downstream features see the call as bound on every language version. Co-authored-by: Isaac
added 22 commits
April 26, 2026 14:46
When the speculative-binding redesign (in /product) made the typeless- receiver helper only engage when an extension candidate is in scope, these tests' "no extension found" assertions started reporting the legacy ERR_BadUnaryOp from the UnboundLambda rejection in BindMemberAccessWithBoundLeft instead of the new ERR_NoSuchMember. Updated three tests across Classic / ModernMethod / ModernProperty. Co-authored-by: Isaac
…nto extension-members-on-typeless-receivers/MethodGroup/Support
…port' into extension-members-on-typeless-receivers/MethodGroup/Tests
…llback
Three method-group "no extension found" tests now expect the legacy
ERR_BadSKunknown ('method is not valid in the given context') instead of
ERR_NoSuchMember, since the speculative-binding redesign falls back to
the legacy path when no extension candidate is in scope.
Co-authored-by: Isaac
…ts' into extension-members-on-typeless-receivers/NewExpression/Support
…upport' into extension-members-on-typeless-receivers/NewExpression/Tests
…fallback Three new()-receiver "no extension found" tests now expect the legacy ERR_ImplicitObjectCreationNoTargetType instead of ERR_NoSuchMember. Co-authored-by: Isaac
…ests' into extension-members-on-typeless-receivers/NullLiteral/Support
…port' into extension-members-on-typeless-receivers/NullLiteral/Tests
…llback Three null-receiver "no extension found" tests now expect the legacy ERR_BadUnaryOp on '<null>' instead of ERR_NoSuchMember. Co-authored-by: Isaac
…ts' into extension-members-on-typeless-receivers/DefaultLiteral/Support
…Support' into extension-members-on-typeless-receivers/DefaultLiteral/Tests
… fallback Three default-receiver "no extension found" tests now expect the legacy ERR_DefaultLiteralNoTargetType instead of ERR_NoSuchMember. Co-authored-by: Isaac
…Tests' into extension-members-on-typeless-receivers/ConditionalExpression/Support
…ession/Support' into extension-members-on-typeless-receivers/ConditionalExpression/Tests
…binding fallback Three conditional-receiver "no extension found" tests now expect the legacy ERR_InvalidQM (no common conditional type) instead of ERR_NoSuchMember. Co-authored-by: Isaac
…ession/Tests' into extension-members-on-typeless-receivers/SwitchExpression/Support
…n/Support' into extension-members-on-typeless-receivers/SwitchExpression/Tests
…ng fallback Three switch-receiver "no extension found" tests now expect the legacy ERR_SwitchExpressionNoBestType instead of ERR_NoSuchMember. Co-authored-by: Isaac
…n/Tests' into extension-members-on-typeless-receivers/TupleExpression/Support
…/Support' into extension-members-on-typeless-receivers/TupleExpression/Tests
…/Tests' into extension-members-on-typeless-receivers/ThrowExpression/Tests
Member
|
Test plan: #83428 |
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.
Championed issue: TBD
Speclet: TBD
Test plan: TBD
Summary
(throw ...).M()is always unreachable.(throw ...).M()continues to reportERR_ThrowMisplacedfor both classic and modern extension method shapes.Stacked: