-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix union as enum issues #328
Conversation
All changed packages have been documented. |
You can try these changes at https://cadlplayground.z22.web.core.windows.net/typespec-azure/prs/328/ Check the website changes at https://tspwebsitepr.z22.web.core.windows.net/typespec-azure/prs/328/ |
strictEqual(dogValue.enumType, petKind); | ||
strictEqual(dogValue.valueType, petKind.valueType); | ||
strictEqual(dogValue.kind, "enumvalue"); | ||
}); | ||
|
||
it("property of anonymous union as enum", async () => { | ||
await runner.compileWithBuiltInService(` | ||
model Pet { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't want to create an enum from an anonymous union, we only do it if the union is named. let me roll back this part of the pr, rest looks good as far as i can see
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this not true anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix: #326