You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This issue covers adding generation support for union extends as described in link. As part of this issue, we should enable and use the spector tests cases as a test of the implementation.
Add C# client generation support for inherited unions (union extends) according to the linked cross-language design, validated by the existing union Spector scenarios.
The affected component is @typespec/http-client-csharp. The compiler-side extends base type for unions was implemented separately in #2737; this request is specifically for the C# client emitter to represent those semantics in generated code. Related issues such as #7923 (adopting discriminated-union Spector scenarios) and #4202 (general heterogeneous-union generation) overlap in topic but do not describe the same request.
The implementation should follow the linked cross-language design and use the cases under packages/http-specs/specs/type/union as conformance coverage.
📝 Suggested next steps
Map inherited union metadata into the C# emitter's generated type model.
Enable the applicable type/union Spector scenarios for the C# client emitter.
Add focused generator tests for inheritance, serialization, and deserialization behavior.
Activity
github-actions commentedon Nov 3, 2026
🎯 Issue Triage
Add C# client generation support for inherited unions (
union extends) according to the linked cross-language design, validated by the existing union Spector scenarios.Category: Feature Request
Area:
emitter:client:csharp🔍 Analysis
The affected component is
@typespec/http-client-csharp. The compiler-sideextendsbase type for unions was implemented separately in #2737; this request is specifically for the C# client emitter to represent those semantics in generated code. Related issues such as #7923 (adopting discriminated-union Spector scenarios) and #4202 (general heterogeneous-union generation) overlap in topic but do not describe the same request.The implementation should follow the linked cross-language design and use the cases under
packages/http-specs/specs/type/unionas conformance coverage.📝 Suggested next steps
type/unionSpector scenarios for the C# client emitter.[http-client-csharp] Add discriminated union extends support (microso…