microsoft / microsoft/typespec

Add validations for customization when we are changing a model to struct

Open
#4,395 1 comment 0 reactions 0 assignees View on GitHub
emitter:client:csharp
Dominant language
Java
Stars
5.9k
Forks
394
Avg merge
1d 23h
Merged PRs (30d)
104

Description

We need to validate in our code when we see they want to change this model to a struct if it is possible, for example:
- when the model has a base or a discriminator, it cannot be changed to a struct.
- when the model is a base type of other types, it cannot be changed to a struct.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.