Revert temporary ITypeSymbol extension APIs#2822
Merged
Conversation
Co-authored-by: jjonescz <[email protected]>
Copilot
AI
changed the title
[WIP] Revert commit 5edf9a1 to resolve issue 80281
Revert temporary ITypeSymbol extension APIs
Oct 10, 2025
jjonescz
approved these changes
Oct 10, 2025
Member
|
@jjonescz is this still needed? |
Member
|
Yes, this removes a temporary workaround and it should be merged once green. I will try to update it |
Member
|
@333fred @dotnet/roslyn-infrastructure for reviews, thanks |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR removes temporary/obsolete extension APIs from the ITypeSymbol interface that were added as a workaround for a source build compatibility issue. The IsExtension and ExtensionParameter properties remain available through INamedTypeSymbol where they belong.
Changes:
- Removed obsolete
IsExtensionandExtensionParameterproperties fromITypeSymbolinterface - Removed
newkeyword from corresponding properties inINamedTypeSymbolsince they no longer hide base interface members - Cleaned up implementations in C#, Visual Basic, and code generation symbol classes
- Updated API tracking files to reflect the removal
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
src/roslyn/src/Compilers/Core/Portable/Symbols/ITypeSymbol.cs |
Removed obsolete IsExtension and ExtensionParameter property declarations from the interface |
src/roslyn/src/Compilers/Core/Portable/Symbols/INamedTypeSymbol.cs |
Removed new keyword from IsExtension and ExtensionParameter properties |
src/roslyn/src/Compilers/CSharp/Portable/Symbols/PublicModel/TypeSymbol.cs |
Removed C# implementation of the temporary extension properties |
src/roslyn/src/Compilers/VisualBasic/Portable/Symbols/TypeSymbol.vb |
Removed Visual Basic implementation of the temporary extension properties |
src/roslyn/src/Workspaces/SharedUtilitiesAndExtensions/Workspace/Core/CodeGeneration/Symbols/CodeGenerationTypeSymbol.cs |
Removed implementation from code generation symbol class |
src/roslyn/src/Compilers/Core/Portable/PublicAPI.Shipped.txt |
Removed API entries for the temporary properties |
src/roslyn/src/Tools/SemanticSearch/ReferenceAssemblies/Apis/Microsoft.CodeAnalysis.txt |
Removed API reference entries for the temporary properties |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
CyrusNajmabadi
approved these changes
Jan 19, 2026
333fred
approved these changes
Jan 19, 2026
3 tasks
This was referenced Jan 24, 2026
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.
Summary
This PR reverts the temporary extension APIs that were added to
ITypeSymbolinterface to resolve a source build compatibility issue. These APIs are now being removed as they are no longer needed.Fixes dotnet/roslyn#80281
Background
The
IsExtensionandExtensionParameterproperties were temporarily added to theITypeSymbolinterface (with[Obsolete]attributes) as a workaround for a source build issue where ILLink analyzer compiled against RC1 Roslyn couldn't work with the latest Roslyn that had removed these APIs fromITypeSymboland kept them only onINamedTypeSymbol.Changes
This PR removes:
ITypeSymbol.IsExtensionproperty - The obsolete property is removed from the baseITypeSymbolinterfaceITypeSymbol.ExtensionParameterproperty - The obsolete property is removed from the baseITypeSymbolinterfacenewkeyword fromINamedTypeSymbol- TheIsExtensionandExtensionParameterproperties onINamedTypeSymbolno longer need thenewkeyword since they're not hiding base interface membersTypeSymbol.csTypeSymbol.vbCodeGenerationTypeSymbol.csPublicAPI.Unshipped.txtandMicrosoft.CodeAnalysis.txtImpact
This change removes temporary/obsolete APIs. The functionality remains available through
INamedTypeSymbol.IsExtensionandINamedTypeSymbol.ExtensionParameterfor code that needs to check if a type is an extension type.Total changes: 7 files modified, 46 deletions, 2 insertions
Original prompt
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.