Azure / typespec-azure

About TypeSpec Azure Libraries
https://azure.github.io/typespec-azure/
MIT License
9 stars 29 forks source link

[defect] when Union has only one option, tcgc transform it as literal #1134

Closed chunyu3 closed 2 weeks ago

chunyu3 commented 2 weeks ago

When Union only has one option (see following), tcgc getClientType transform it as literal.

Union OneOptionUnion
{
 A: "A",
}

expected: return Union