Skip to content

Unable to customize base model of generated model if spec has a base model #9180

@live1206

Description

@live1206

In MTG, we can only customize base model if input model doesn't have a base model already.

if (_inputModel.BaseModel == null)
{
// consider models that have been customized to inherit from a different model
if (CustomCodeView?.BaseType != null)
{
var baseType = CustomCodeView.BaseType;

There are cases, we need to customize the base model even the spec has specified the base model.

Metadata

Metadata

Assignees

Labels

emitter:client:csharpIssue for the C# client emitter: @typespec/http-client-csharp

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions